<< Click to Display Table of Contents >> Navigation: Reference Manual > Equations > Arithmetic Functions |
Returns the absolute value of a number, e.g., Abs(5.3)=Abs(-5.3)=5.3.
Returns e (Euler's number) raised to the power of x, e.g., Exp(2.2)=e2.2=9.02501.
Returns the natural logarithm of the Gamma function (Γ(x)), e.g., Gammaln(2.2)=0.0969475.
Returns the greatest common integer divisor of its two integer arguments n and k, e.g., GCD(15,25)=5. When the arguments are not integers, their fractional part is ignored.
Returns positive infinity. For negative infinity, please use -Inf().
Returns the least common integer multiple of its two integer arguments n and k, e.g., LCM(15,25)=75.When the arguments are not integers, their fractional part is ignored.
Returns the natural logarithm of x, which has to be non-negative, e.g., Ln(10)=2.30259.
Returns the base b logarithm of x, which has to be non-negative, e.g., Log(10,2)=3.32193.
Returns decimal logarithm of x, which has to be non-negative, e.g., Log10(100)=2.
Returns 10 raised to the power of x, e.g., Pow10(2)=102=100.
Returns the integer that is nearest to x, e.g., Round(2.2)=2, Round(3.5)=4.
Returns 1 if x>0, 0 when x=0, and -1 if x<0, e.g., Sign(2.2)=1, Sign(0)=0, Sign(-3.5)=-1.
Returns the square root of x, which has to be non-negative, e.g., Sqrt(2)=1.41421.
Returns the sum of its arguments, e.g., Sum(2.2, 3.5, 1.3)=7.0. Sum() requires at least two arguments.
Returns the sum of squares of its arguments, e.g., SumSq(2.2, 3.5, 1.3)=18.78. SumSq() requires at least two arguments.
Trim(x,lo,hi)
Trims the value of the argument x to a value in the interval <lo, hi>. If x≤lo, the function returns lo, if x≥hi, the function returns hi, if lo<x<hi, the function returns x. The function is a shortcut to two nested conditional functions If() and is equivalent to If(x<lo,lo,If(x>hi,hi,x)). For example, Trim(-0.5,0,1)=0, Trim(0.5,0,1)=0.5, Trim(1.5,0,1)=1.
Returns the integer part of x, e.g., Truncate(2.2)=2.