Math Functions
List of math functions
SUM
MIN
MAX
AVG
COUNT
MEDIAN
CEILING
FLOOR
ROUND
ROUNDE
EXP
POW
ABS
+
−
*
/
Summation (SUM)
Sums up numerical values.
Takes any number of arguments greater than 0.
Each argument must be a number or a variable.
Alternatively, SUM can take an array of numbers in any argument.
Minimum (MIN)
Returns the smallest number from those provided.
Takes any number of arguments greater than 0.
Each argument must be a number or a variable.
Alternatively, MIN can take an array of numbers in any argument.
Maximum (MAX)
Returns the largest number from those provided.
Takes any number of arguments greater than 0.
Each argument must be a number or a variable.
Alternatively, MAX can take an array of numbers in any argument.
Average (AVG)
Returns the average (arithmetic mean) of the arguments.
Takes any number of arguments greater than 0.
Each argument must be a number or a variable.
Alternatively, AVG can take an array of numbers in any argument.
Count (COUNT)
Counts the number of its arguments or elements of provided arrays.
Takes any number of arguments greater than 0.
When given an array, it looks inside the array and counts in its elements.
Median (MEDIAN)
Returns the median of the given numbers. The median is the number in the middle of a set of numbers.
Takes any number of arguments greater than 0.
Each argument must be a number or a variable.
Alternatively, MEDIAN can take an array of numbers in any argument.
Ceiling (CEILING)
Returns a number rounded up to the nearest whole number.
Takes 1 argument.
The argument must be a number or a variable.
Floor (FLOOR)
Returns a number rounded down to the nearest whole number.
Takes 1 argument.
The argument must be a number or a variable.
Round (ROUND)
Rounds a number to the closest number of the specified decimal place.
Takes 1 or 2 arguments.
The first argument is the number to be rounded.
The second optional argument is the number of decimal spaces.
The second argument should be a whole number.
If the second argument is not given, it defaults to 0.
The second argument allows negative values.
Round to Even (ROUNDE)
The round-to-even method is used in engineering, finance, and computer science to reduce bias when you use rounded numbers to estimate sums and averages. The round-to-even method works like this:
If the difference between the number and the nearest integer is less than 0.5, round to the nearest integer. This familiar rule is used by many rounding methods.
If the difference between the number and the nearest integer is exactly 0.5, look at the integer part of the number. If the integer part is EVEN, round towards zero. If the integer part of the number is ODD, round away from zero. In either case, the rounded number is an even integer.
Exponential (EXP)
Returns the value of exponential function of the given numerical argument.
Takes 1 argument.
The argument must be a number or a variable.
Power (POW)
Returns an arbitrary power of an arbitrary number.
Takes 2 arguments.
Both arguments have to be numbers or a variables.
The first argument is the base, the second argument is the exponent.
Absolute value (ABS)
Returns the absolute value of a number.
Takes 1 argument.
The argument has to be a number or a variable.
Arithmetic operations
Besides the above described functions, basic arithmetic operations can be also used.
Plus (+)
Takes 2 arguments.
Both arguments have to be numbers or a variables.
Minus (-)
Takes 1 or 2 arguments, yet the second argument always has to be there.
Both arguments have to be numbers or a variables.
For the minus operation to work correctly, it is necessary to use brackets to specify the desired order of the operations, e.g. write (1-1)-1 or (-3)*5 instead of merely 1 - 1 - 1 or -3*5, respectively.
Times (*)
Divided (/)
You may use the above described basic operations in the usual way, writing more complex expressions with the use of brackets (), for example:
It is also possible to use arithmetic operations together with other functions:
Last updated