Math

<< Click to Display Table of Contents >>

Current:  Create Calculated Field > Calculated Field Functions List 

Math

Previous pageReturn to chapter overviewNext page

Functions

Syntax

Instructions

Examples

abs

abs(number)

Returns the absolute value of the given data

For example:

abs(-7) = 7

abs(col['sales'])

acos

acos(number)

Returns the inverse cosine function value of the parameter. The parameter range is [-1, 1]. An error will be reported if it is not in the domain

For example:

acos(-1) = 3.14159265358979

acos(col['angle'])

asin

asin(number)

Returns the arcsine function value of the parameter. The parameter range is [-1, 1]. An error will be reported if it is not in the domain

For example:

asin(1) = 1.570796326795

asin(col['angle'])

atan

atan(number)

Returns the arctangent function value of the argument.

For example:

atan(0) = 0

atan(col['angle'])

atan2

atan2(number x, number y)

Returns the arc tangent of the x and y axes of the specified coordinate axis

For example:

atan2(2,1) = 1.10714871779409

atan2(col['x'],col['y'])

ceiling

ceiling(number , number significance)

Returns the parameter rounded up(in the direction of absolute value increase) to the nearest multiple of the specified base

For example:

ceiling(3.1415, 1)=4.0

cos

cos(number)

Returns the cosine of the argument

For example:

cos(3.1415962/4)=0.707

cos(col['angle'])

cot

cot(number)

 

Returns the cotangent of an angle. Specify the angle in radians

 

For example:cot(pi() /4) = 1

degrees

degrees(number)

Converts a given number in radians to degrees

For example:

degrees(pi()/4) = 45.0

exp

exp(number)

returns the exponent value base e

For example:

exp(2)=7.389

floor

floor(number , number significance)

Returns the parameter rounded down(in the direction of absolute value reduction) to the nearest multiple of the specified base

For example:

floor(3.1415,1)floor(3.1415,1)=3.0

ln

ln(number)

returns the natural logarithm of the parameter

For example:

ln(exp(5))=5

log

log(number , number base)

Returns the logarithm of a specified number in a specified base

For example:

log(256, 2) = 8

pi

pi()

Returns the numeric constant pi

For example:

pi() = 3.1415926

power

power(number , number power)

Returns the power of a given number

For example:

power(5,2)=25

radians

radians(number)

Returns the radian angle in degrees

For example:

radians(180) = 3.14159

randbetween

randbetween(number x, number y)

Returns a random integer greater than or equal to the specified minimum value and less than the specified maximum value

For example:

randbetween(1, 100)

round

round(number , int accurate)

Returns a number rounded to a specified number of digits

For example:

round(3.1415, 1)=3.1

roundDown

roundDown(number,int)

Round down numbers by specified digits

For example:

roundDown(3.1316, 3)=3.131

roundUp

roundUp(number,int)

Rounds up to the specified number of digits after the specified number of digits

For example:

roundUp(3.1312, 3) = 3.132

sign

sign(number)

Returns the sign of a number. Returns 1 if the number is positive, 0 if it is zero, and -1 if it is negative

For example:

sign(10) = 1

sin

sin(number)

Returns the sine of the argument

For example:

sin(pi() / 2) = 1

sqr

sqr(number)

Returns the squared value of the given data

For example:

sqr(2) = 4)

sqrt

sqrt(number)

Returns the square root of the argument

For example:

sqrt(16) = 4

tan

tan(number)

Returns the tangent of the argument

For example:

tan(pi()/4) = 1

trunc

trunc(number,int)

truncates the decimal part of the value and returns an integer

For example:

trunc(3.1312, 2)=3