abs
($arg as xs:anyAtomicType) as xs:anyAtomicType
Compute the abs of a numeric value. |
cast-as-numeric
($number as xs:anyAtomicType) as xs:anyAtomicType
Cast the xs:anyAtomicType to a numeric type. |
ceiling
($number as xs:anyAtomicType, $significance as xs:anyAtomicType) as xs:anyAtomicType
Returns number rounded up, away from zero, to the nearest multiple of significance. |
degrees
($radian as xs:double) as xs:integer
Converts radians into degrees. |
even
($number as xs:anyAtomicType) as xs:anyAtomicType
Returns number rounded up to the nearest even integer. |
fact
($number as xs:anyAtomicType) as xs:integer
Returns the factorial of a number. |
factdouble
($number as xs:integer) as xs:integer
Returns the double factorial of a number. |
floor
($number as xs:anyAtomicType, $significance as xs:anyAtomicType) as xs:anyAtomicType
Rounds number down, toward zero, to the nearest multiple of significance. |
gcd
($numbers as xs:integer+) as xs:integer
Returns the greatest common divisor GCD of a sequence of integers. |
int
($number as xs:anyAtomicType) as xs:integer
Rounds a number down to the nearest integer. |
is-a-number
($value as xs:anyAtomicType) as xs:boolean
Checks if the xs:anyAtomicType argument is actually a numeric type or can be converted to numeric. |
lcm
($numbers as xs:integer+) as xs:integer
Returns the least common multiple of integers. |
mod
($number as xs:anyAtomicType, $divisor as xs:anyAtomicType) as xs:anyAtomicType
Returns the remainder after number is divided by divisor. |
mround
($number as xs:anyAtomicType, $multiple as xs:anyAtomicType) as xs:anyAtomicType
Returns a number rounded to the desired multiple. |
odd
($number as xs:anyAtomicType) as xs:integer
Returns number rounded up to the nearest odd integer, away from zero. |
pi
() as xs:decimal
Return the value of PI as decimal with 15 digits. |
power
($number as xs:anyAtomicType, $power as xs:integer) as xs:anyAtomicType
Returns the result of a number raised to a power. |
product
($numbers as xs:anyAtomicType*) as xs:anyAtomicType
Multiplies all the numbers given as arguments and returns the product. |
quotient
($numerator as xs:anyAtomicType, $denominator as xs:anyAtomicType) as xs:integer
Returns the integer portion of a division. |
radians
($degree as xs:integer) as xs:decimal
Converts degrees to radians. |
roman
($number as xs:integer) as xs:string
Converts an arabic numeral to roman, as text. |
round
($number as xs:anyAtomicType, $precision as xs:integer) as xs:anyAtomicType
Rounds a number to a specified number of digits. |
rounddown
($number as xs:anyAtomicType, $precision as xs:integer) as xs:anyAtomicType
Rounds a number down, toward zero. |
roundup
($number as xs:anyAtomicType, $precision as xs:integer) as xs:anyAtomicType
Rounds a number up, away from 0 (zero). |
sign
($number as xs:anyAtomicType) as xs:integer
Determines the sign of a number. |
sort-numbers
($numbers as xs:anyAtomicType*) as xs:anyAtomicType*
Helper function. |
sum
($numbers as xs:anyAtomicType*) as xs:anyAtomicType
Adds all the numbers in the sequence. |
trunc
($number as xs:anyAtomicType) as xs:integer
Truncates a number to an integer by removing the fractional part of the number. |
trunc
($number as xs:anyAtomicType, $precision as xs:integer) as xs:anyAtomicType
Truncates a number down to precision. |
declare function excel:abs($arg as xs:anyAtomicType) as xs:anyAtomicType
declare function excel:cast-as-numeric($number as xs:anyAtomicType) as xs:anyAtomicType
declare function excel:ceiling($number as xs:anyAtomicType, $significance as xs:anyAtomicType) as xs:anyAtomicType
declare function excel:degrees($radian as xs:double) as xs:integer
declare function excel:even($number as xs:anyAtomicType) as xs:anyAtomicType
declare function excel:fact($number as xs:anyAtomicType) as xs:integer
declare function excel:factdouble($number as xs:integer) as xs:integer
declare function excel:floor($number as xs:anyAtomicType, $significance as xs:anyAtomicType) as xs:anyAtomicType
declare function excel:gcd($numbers as xs:integer+) as xs:integer
declare function excel:int($number as xs:anyAtomicType) as xs:integer
declare function excel:is-a-number($value as xs:anyAtomicType) as xs:boolean
declare function excel:lcm($numbers as xs:integer+) as xs:integer
LCM for two numbers is computed by multiplying them and dividing with GCD.
The function is applied recursively replacing the first two numbers in the sequence with their LCM.
declare function excel:mod($number as xs:anyAtomicType, $divisor as xs:anyAtomicType) as xs:anyAtomicType
declare function excel:mround($number as xs:anyAtomicType, $multiple as xs:anyAtomicType) as xs:anyAtomicType
declare function excel:odd($number as xs:anyAtomicType) as xs:integer
declare function excel:pi() as xs:decimal
declare function excel:power($number as xs:anyAtomicType, $power as xs:integer) as xs:anyAtomicType
declare function excel:product($numbers as xs:anyAtomicType*) as xs:anyAtomicType
declare function excel:quotient($numerator as xs:anyAtomicType, $denominator as xs:anyAtomicType) as xs:integer
declare function excel:radians($degree as xs:integer) as xs:decimal
declare function excel:roman($number as xs:integer) as xs:string
M is the largest digit, it represents 1000. Numbers bigger than 2000 will be represented by a sequence of "M".
D = 500, C = 100, L = 50, X = 10, V = 5, I = 1.
declare function excel:round($number as xs:anyAtomicType, $precision as xs:integer) as xs:anyAtomicType
declare function excel:rounddown($number as xs:anyAtomicType, $precision as xs:integer) as xs:anyAtomicType
declare function excel:roundup($number as xs:anyAtomicType, $precision as xs:integer) as xs:anyAtomicType
declare function excel:sign($number as xs:anyAtomicType) as xs:integer
declare function excel:sort-numbers($numbers as xs:anyAtomicType*) as xs:anyAtomicType*
Sorts a sequence of numbers or arguments castable to numeric. It first casts all arguments to numeric and then sorts ascending.
declare function excel:sum($numbers as xs:anyAtomicType*) as xs:anyAtomicType
declare function excel:trunc($number as xs:anyAtomicType) as xs:integer
declare function excel:trunc($number as xs:anyAtomicType, $precision as xs:integer) as xs:anyAtomicType