implementation("io.github.plumsoftware:more-math:0.0.8")
Это KMP библиотека слегка упрощающая работу с математикой.