We can use the javascript library in CoffeeScript
code. Hence we can use all the methods of math object in javascript.
Some math function
present in the math object
:
* abs()
: This function returns the absolute value of a number.
* acos() : This function returns arccosine (in radians) of a number.
* asin() : This function returns arcsine (in radians) of a number.
* atan() : This function returns arctangent (in radians) of a number.
* atan2()
: This function returns arctangent of the quotient of its arguments.
* ceil()
: This function returns the smallest integer greater than or equal to the given number.
* cos()
: This function returns the cosin of the given number.
* exp()
: This function returns EN, Where N is the argument, and E is the Euler's constant, the base of the natural logarithm.
* floor()
: This function returns the largest integer less than equal to the number.
* log()
: This function returns natural logarithm (base E) of a number.
* max()
: This function returns largest of zero or more numbers.
* min()
: This function returns the smallest of zero or more numbers.
* pow()
: This function returns the base exponent of the given number.
* random()
: This function returns the pseudo-random number between 0 and 1.
* round()
: This function returns the value of the number rounded to the nearest integer.
* sin()
: This function returns the sine of the given number.
* sqrt()
: This function returns the square root of the specified number.
* tan()
: This function returns the tangent of the specified number.