public class Math extends Objs
Objs.Constructor<T extends Objs>, Objs.Property<T>
Modifier and Type | Field and Description |
---|---|
static double |
E
The mathematical constant e.
|
static double |
LN10
The natural logarithm of 10.
|
static double |
LN2
The natural logarithm of 2.
|
static double |
LOG10E
The base-10 logarithm of e.
|
static double |
LOG2E
The base-2 logarithm of e.
|
static double |
PI
Pi.
|
static double |
SQRT1_2
The square root of 0.5, or, equivalently, one divided by the square root of 2.
|
static double |
SQRT2
The square root of 2.
|
Modifier | Constructor and Description |
---|---|
protected |
Math(Objs.Constructor<?> c,
Object js) |
Modifier and Type | Method and Description |
---|---|
static Math |
$as(Object obj) |
static double |
abs(double x)
Returns the absolute value of a number (the value without regard to whether it is positive or negative).
|
static double |
acos(double x)
Returns the arc cosine (or inverse cosine) of a number.
|
static double |
asin(double x)
Returns the arcsine of a number.
|
static double |
atan(double x)
Returns the arctangent of a number.
|
static double |
atan2(double y,
double x)
Returns the angle (in radians) from the X axis to a point.
|
static double |
ceil(double x)
Returns the smallest number greater than or equal to its numeric argument.
|
static double |
cos(double x)
Returns the cosine of a number.
|
static double |
exp(double x)
Returns e (the base of natural logarithms) raised to a power.
|
static double |
floor(double x)
Returns the greatest number less than or equal to its numeric argument.
|
static double |
log(double x)
Returns the natural logarithm (base e) of a number.
|
static double |
max(double... values)
Returns the larger of a set of supplied numeric expressions.
|
static double |
min(double... values)
Returns the smaller of a set of supplied numeric expressions.
|
static double |
pow(double x,
double y)
Returns the value of a base expression taken to a specified power.
|
static double |
random()
Returns a pseudorandom number between 0 and 1.
|
static double |
round(double x)
Returns a supplied numeric expression rounded to the nearest number.
|
static double |
sin(double x)
Returns the sine of a number.
|
static double |
sqrt(double x)
Returns the square root of a number.
|
static double |
tan(double x)
Returns the tangent of a number.
|
$as, $cast, $delete, $get, $js, $set, create, create, defineProperties, defineProperty, freeze, getOwnPropertyDescriptor, getOwnPropertyNames, getPrototypeOf, hasOwnProperty, isExtensible, isFrozen, isPrototypeOf, isSealed, keys, newObject, newObject, preventExtensions, propertyIsEnumerable, seal, toLocaleString, toString, valueOf
public static double E
public static double LN10
public static double LN2
public static double LOG2E
public static double LOG10E
public static double PI
public static double SQRT1_2
public static double SQRT2
protected Math(Objs.Constructor<?> c, Object js)
public static double abs(double x)
x
- A numeric expression for which the absolute value is needed.public static double acos(double x)
x
- A numeric expression.public static double asin(double x)
x
- A numeric expression.public static double atan(double x)
x
- A numeric expression for which the arctangent is needed.public static double atan2(double y, double x)
y
- A numeric expression representing the cartesian y-coordinate.x
- A numeric expression representing the cartesian x-coordinate.public static double ceil(double x)
x
- A numeric expression.public static double cos(double x)
x
- A numeric expression that contains an angle measured in radians.public static double exp(double x)
x
- A numeric expression representing the power of e.public static double floor(double x)
x
- A numeric expression.public static double log(double x)
x
- A numeric expression.public static double max(double... values)
values
- Numeric expressions to be evaluated.public static double min(double... values)
values
- Numeric expressions to be evaluated.public static double pow(double x, double y)
x
- The base value of the expression.y
- The exponent value of the expression.public static double random()
public static double round(double x)
x
- The value to be rounded to the nearest number.public static double sin(double x)
x
- A numeric expression that contains an angle measured in radians.public static double sqrt(double x)
x
- A numeric expression.public static double tan(double x)
x
- A numeric expression that contains an angle measured in radians.Copyright © 2018. All rights reserved.