Stay organized with collections
Save and categorize content based on your preferences.
FloatMath
open class FloatMath
Math routines similar to those found in java.lang.Math
.
Historically these methods were faster than the equivalent double-based java.lang.Math
methods. On versions of Android with a JIT they became slower and have since been re-implemented to wrap calls to java.lang.Math
. java.lang.Math
should be used in preference.
All methods were removed from the public API in version 23.
Summary
Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2025-02-10 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-02-10 UTC."],[],[],null,["# FloatMath\n\nAdded in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels) \nDeprecated in [API level 22](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)\n\nFloatMath\n=========\n\n*** ** * ** ***\n\nKotlin \\|[Java](/reference/android/util/FloatMath \"View this page in Java\") \n\n```\nopen class FloatMath\n```\n\n|---|-----------------------------|\n| [kotlin.Any](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html) ||\n| ↳ | [android.util.FloatMath](#) |\n\n*** ** * ** ***\n\n| **This class was deprecated in API level 22.**\n|\n| Use [java.lang.Math](../../java/lang/Math.html#) instead.\n\nMath routines similar to those found in [java.lang.Math](../../java/lang/Math.html#).\n\nHistorically these methods were faster than the equivalent double-based [java.lang.Math](../../java/lang/Math.html#) methods. On versions of Android with a JIT they became slower and have since been re-implemented to wrap calls to [java.lang.Math](../../java/lang/Math.html#). [java.lang.Math](../../java/lang/Math.html#) should be used in preference.\n\nAll methods were removed from the public API in version 23.\n\nSummary\n-------"]]