The Math object allows you to perform advanced mathematical operations. This object is always available in a form of predefined Math global variable.
// calculate sine of 90 degrees var Sine90 = Math.Sin(90); |
Abs | Returns the absolute value of a number |
Acos | Returns the arccosine of a number |
Asin | Returns the arcsine of a number |
Atan | Returns the arctangent of a number |
Atan2 | Returns the angle (in radians) from the X axis to a point (y,x) |
Ceil | Returns the smallest integer greater than or equal to the specified number |
Cos | Returns the cosine of a number |
Cosh | Returns the hyperbolic cosine of a number |
Exp | Returns e (the base of natural logarithms) raised to a power |
Floor | Returns the greatest integer less than or equal to the specified number |
Log | Returns the natural logarithm of a number |
Log10 | Returns the base-10 logarithm of a number |
Pow | Returns the value of a Base value taken to a specified power |
Sin | Returns the sine of a number |
Sinh | Returns the hyperbolic sine of a number |
Tan | Returns the tangent of a number |
Tanh | Returns the hyperbolic tangent of a number |
Sqrt | Returns the square root of a number |
DegToRad | Converts an angle from degrees to radians |
RadToDeg | Converts an angle from radians to degrees |
Type (read only) | Returns always "math" |
PI (read only) | Returns the ratio of the circumference of a circle to its diameter, approximately 3.141592653589793 |
Returns the absolute value of a number
Returns the arccosine of a number
Returns the arcsine of a number
Returns the arctangent of a number
Returns the angle (in radians) from the X axis to a point (y,x)
Returns the smallest integer greater than or equal to the specified number
Returns the cosine of a number
Returns the hyperbolic cosine of a number
Returns e (the base of natural logarithms) raised to a power
Returns the greatest integer less than or equal to the specified number
Returns the natural logarithm of a number
Returns the base-10 logarithm of a number
Returns the value of a Base value taken to a specified power
Returns the sine of a number
Returns the hyperbolic sine of a number
Returns the tangent of a number
Returns the hyperbolic tangent of a number
Returns the square root of a number
Converts an angle from degrees to radians
Returns the converted angle (in radians)
Converts an angle from radians to degrees
Returns the converted angle (in degrees)