Math Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
The class Math
contains methods for performing basic
numeric operations such as the elementary exponential, logarithm,
square root, and trigonometric functions.
[Android.Runtime.Register("java/lang/Math", DoNotGenerateAcw=true)]
public sealed class Math : Java.Lang.Object
[<Android.Runtime.Register("java/lang/Math", DoNotGenerateAcw=true)>]
type Math = class
inherit Object
- Inheritance
- Attributes
Remarks
Java documentation for java.lang.Math
.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.
Fields
E |
The |
Pi |
The |
Properties
Class |
Returns the runtime class of this |
Handle |
The handle to the underlying Android instance. (Inherited from Object) |
JniIdentityHashCode | (Inherited from Object) |
JniPeerMembers | |
PeerReference | (Inherited from Object) |
ThresholdClass |
This API supports the Mono for Android infrastructure and is not intended to be used directly from your code. (Inherited from Object) |
ThresholdType |
This API supports the Mono for Android infrastructure and is not intended to be used directly from your code. (Inherited from Object) |
Methods
Abs(Double) |
Returns the absolute value of a |
Abs(Int32) |
Returns the absolute value of an |
Abs(Int64) |
Returns the absolute value of a |
Abs(Single) |
Returns the absolute value of a |
AbsExact(Int32) | |
AbsExact(Int64) | |
Acos(Double) |
Returns the arc cosine of a value; the returned angle is in the range 0. |
AddExact(Int32, Int32) |
Returns the sum of its arguments,
throwing an exception if the result overflows an |
AddExact(Int64, Int64) |
Returns the sum of its arguments,
throwing an exception if the result overflows a |
Asin(Double) |
Returns the arc sine of a value; the returned angle is in the range -pi/2 through pi/2. |
Atan(Double) |
Returns the arc tangent of a value; the returned angle is in the range -pi/2 through pi/2. |
Atan2(Double, Double) |
Returns the angle theta from the conversion of rectangular
coordinates ( |
Cbrt(Double) |
Returns the cube root of a |
Ceil(Double) |
Returns the smallest (closest to negative infinity)
|
Clone() |
Creates and returns a copy of this object. (Inherited from Object) |
CopySign(Double, Double) |
Returns the first floating-point argument with the sign of the second floating-point argument. |
CopySign(Single, Single) |
Returns the first floating-point argument with the sign of the second floating-point argument. |
Cos(Double) |
Returns the trigonometric cosine of an angle. |
Cosh(Double) |
Returns the hyperbolic cosine of a |
DecrementExact(Int32) |
Returns the argument decremented by one, throwing an exception if the
result overflows an |
DecrementExact(Int64) |
Returns the argument decremented by one, throwing an exception if the
result overflows a |
Dispose() | (Inherited from Object) |
Dispose(Boolean) | (Inherited from Object) |
Equals(Object) |
Indicates whether some other object is "equal to" this one. (Inherited from Object) |
Exp(Double) |
Returns Euler's number e raised to the power of a
|
Expm1(Double) |
Returns e<sup>x</sup> -1. |
Floor(Double) |
Returns the largest (closest to positive infinity)
|
FloorDiv(Int32, Int32) |
Returns the largest (closest to positive infinity)
|
FloorDiv(Int64, Int32) |
Returns the largest (closest to positive infinity)
|
FloorDiv(Int64, Int64) |
Returns the largest (closest to positive infinity)
|
FloorMod(Int32, Int32) |
Returns the floor modulus of the |
FloorMod(Int64, Int32) |
Returns the floor modulus of the |
FloorMod(Int64, Int64) |
Returns the floor modulus of the |
Fma(Double, Double, Double) |
Returns the fused multiply add of the three arguments; that is,
returns the exact product of the first two arguments summed
with the third argument and then rounded once to the nearest
|
Fma(Single, Single, Single) |
Returns the fused multiply add of the three arguments; that is,
returns the exact product of the first two arguments summed
with the third argument and then rounded once to the nearest
|
GetExponent(Double) |
Returns the unbiased exponent used in the representation of a
|
GetExponent(Single) |
Returns the unbiased exponent used in the representation of a
|
GetHashCode() |
Returns a hash code value for the object. (Inherited from Object) |
Hypot(Double, Double) |
Returns sqrt(x<sup>2</sup> +y<sup>2</sup>) without intermediate overflow or underflow. |
IEEEremainder(Double, Double) |
Computes the remainder operation on two arguments as prescribed by the IEEE 754 standard. |
IncrementExact(Int32) |
Returns the argument incremented by one, throwing an exception if the
result overflows an |
IncrementExact(Int64) |
Returns the argument incremented by one, throwing an exception if the
result overflows a |
JavaFinalize() |
Called by the garbage collector on an object when garbage collection determines that there are no more references to the object. (Inherited from Object) |
Log(Double) |
Returns the natural logarithm (base e) of a |
Log10(Double) |
Returns the base 10 logarithm of a |
Log1p(Double) |
Returns the natural logarithm of the sum of the argument and 1. |
Max(Double, Double) |
Returns the greater of two |
Max(Int32, Int32) |
Returns the greater of two |
Max(Int64, Int64) |
Returns the greater of two |
Max(Single, Single) |
Returns the greater of two |
Min(Double, Double) |
Returns the smaller of two |
Min(Int32, Int32) |
Returns the smaller of two |
Min(Int64, Int64) |
Returns the smaller of two |
Min(Single, Single) |
Returns the smaller of two |
MultiplyExact(Int32, Int32) |
Returns the product of the arguments,
throwing an exception if the result overflows an |
MultiplyExact(Int64, Int32) |
Returns the product of the arguments, throwing an exception if the result
overflows a |
MultiplyExact(Int64, Int64) |
Returns the product of the arguments,
throwing an exception if the result overflows a |
MultiplyFull(Int32, Int32) |
Returns the exact mathematical product of the arguments. |
MultiplyHigh(Int64, Int64) |
Returns as a |
NegateExact(Int32) |
Returns the negation of the argument, throwing an exception if the
result overflows an |
NegateExact(Int64) |
Returns the negation of the argument, throwing an exception if the
result overflows a |
NextAfter(Double, Double) |
Returns the floating-point number adjacent to the first argument in the direction of the second argument. |
NextAfter(Single, Double) |
Returns the floating-point number adjacent to the first argument in the direction of the second argument. |
NextDown(Double) |
Returns the floating-point value adjacent to |
NextDown(Single) |
Returns the floating-point value adjacent to |
NextUp(Double) |
Returns the floating-point value adjacent to |
NextUp(Single) |
Returns the floating-point value adjacent to |
Notify() |
Wakes up a single thread that is waiting on this object's monitor. (Inherited from Object) |
NotifyAll() |
Wakes up all threads that are waiting on this object's monitor. (Inherited from Object) |
Pow(Double, Double) |
Returns the value of the first argument raised to the power of the second argument. |
Random() |
Returns a |
Rint(Double) |
Returns the |
Round(Double) |
Returns the closest |
Round(Single) |
Returns the closest |
Scalb(Double, Int32) |
Returns |
Scalb(Single, Int32) |
Returns |
SetHandle(IntPtr, JniHandleOwnership) |
Sets the Handle property. (Inherited from Object) |
Signum(Double) |
Returns the signum function of the argument; zero if the argument is zero, 1. |
Signum(Single) |
Returns the signum function of the argument; zero if the argument is zero, 1. |
Sin(Double) |
Returns the trigonometric sine of an angle. |
Sinh(Double) |
Returns the hyperbolic sine of a |
Sqrt(Double) |
Returns the correctly rounded positive square root of a
|
SubtractExact(Int32, Int32) |
Returns the difference of the arguments,
throwing an exception if the result overflows an |
SubtractExact(Int64, Int64) |
Returns the difference of the arguments,
throwing an exception if the result overflows a |
Tan(Double) |
Returns the trigonometric tangent of an angle. |
Tanh(Double) |
Returns the hyperbolic tangent of a |
ToArray<T>() | (Inherited from Object) |
ToDegrees(Double) |
Converts an angle measured in radians to an approximately equivalent angle measured in degrees. |
ToIntExact(Int64) |
Returns the value of the |
ToRadians(Double) |
Converts an angle measured in degrees to an approximately equivalent angle measured in radians. |
ToString() |
Returns a string representation of the object. (Inherited from Object) |
Ulp(Double) |
Returns the size of an ulp of the argument. |
Ulp(Single) |
Returns the size of an ulp of the argument. |
UnregisterFromRuntime() | (Inherited from Object) |
Wait() |
Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>. (Inherited from Object) |
Wait(Int64, Int32) |
Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>, or until a certain amount of real time has elapsed. (Inherited from Object) |
Wait(Int64) |
Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>, or until a certain amount of real time has elapsed. (Inherited from Object) |
Explicit Interface Implementations
IJavaPeerable.Disposed() | (Inherited from Object) |
IJavaPeerable.DisposeUnlessReferenced() | (Inherited from Object) |
IJavaPeerable.Finalized() | (Inherited from Object) |
IJavaPeerable.JniManagedPeerState | (Inherited from Object) |
IJavaPeerable.SetJniIdentityHashCode(Int32) | (Inherited from Object) |
IJavaPeerable.SetJniManagedPeerState(JniManagedPeerStates) | (Inherited from Object) |
IJavaPeerable.SetPeerReference(JniObjectReference) | (Inherited from Object) |
Extension Methods
JavaCast<TResult>(IJavaObject) |
Performs an Android runtime-checked type conversion. |
JavaCast<TResult>(IJavaObject) | |
GetJniTypeName(IJavaPeerable) |