Math Object

Top  Previous  Next

Performs basic numeric operations like elementary exponential, logarithm, square root, and trigonometric functions.

Description

In CellScript, Math object allows you to perform mathematical operations.

Constants

E

Returns the Euler's number, the base of the natural logarithms.

LN10

Returns the natural logarithm of 10.

LN2

Returns the natural logarithm of 2.

LOG10E

Returns the base-10 logarithm of E.

PI

Returns the the value of pi.

SQRT1_2

Returns the the value of square root of 1/2.

SQRT2

Returns the the value of square root of 2.

Static Functions

abs

Gets the absolute value of a number.

acos

Returns the arccosine of a number as a value value between 0 and PI radians.

asin

Returns the arcsine of a number as a value between -PI/2 and PI/2 radians.

atan

Returns the arctangent of a number as a value between -PI/2 and PI/2 radians.

atan2

Returns the arctangent of the quotient of its arguments, as a numeric value between PI and -PI radians.

ceil

Rounds a number upward to it's nearest integer.

cos

Returns the cosine of a number.

exp

Returns the exponential value of the argument provided.

log

Returns the natural logarithm (base E) of a number.

max

Returns the number with the highest value.

min

Returns the number with the lowest value.

floor

Rounds a number downward to its nearest integer.

pow

Returns the value of a number to the power of a number.

random

Returns a random value between 0 and 1.

round

Rounds a number to the nearest integer.

sin

Returns the sine of a number.

sqrt

Return the square root of a number.

tan

Returns a number that represents the tangent of an angle.