# 数学函数

• 函数参数用逗号分隔
• 表达式可用作参数
• 可选的函数参数（或参数部分）用 `<` `>` 表示

abs (value)

0 - 值相等
1 - 值不同

=> abs(last(/host/key))>10

'1' 和 '5' = `4`
'3' 和 '1' = `2`
'0' 和 '-2.5' = `2.5`
acos (value)

=> acos(last(/host/key))
asin (value)

=> asin(last(/host/key))
atan (value)

=> atan(last(/host/key))
atan2 (value,abscissa)

abscissa - 横坐标值

=> atan2(last(/host/key),2)
avg (<value1>,<value2>,...)

=> avg(avg(/host/key),avg(/host2/key2))
cbrt (value)

=> cbrt(last(/host/key))
ceil (value)

=> ceil(last(/host/key))

cos (value)

=> cos(last(/host/key))
cosh (value)

=> cosh(last(/host/key))
cot (value)

=> cot(last(/host/key))
degrees (value)

=> degrees(last(/host/key))
e

=> e()
exp (value)

=> exp(last(/host/key))
expm1 (value)

=> expm1(last(/host/key))
floor (value)

=> floor(last(/host/key))

log (value)

=> log(last(/host/key))
log10 (value)

=> log10(last(/host/key))
max (<value1>,<value2>,...)

=> max(avg(/host/key),avg(/host2/key2))
min (<value1>,<value2>,...)

=> min(avg(/host/key),avg(/host2/key2))
mod (value,denominator)

denominator - 除数

=> mod(last(/host/key),2)
pi

=> pi()
power (value,power value)

power value - 要使用的幂次

=> power(last(/host/key),3)

rand

=> rand()
round (value,decimal places)

decimal places - 指定四舍五入的小数位数（0也是可能的）

=> round(last(/host/key),2)
signum (value)

=> signum(last(/host/key))
sin (value)

=> sin(last(/host/key))
sinh (value)

=> sinh(last(/host/key))
sqrt (value)

=> sqrt(last(/host/key))
sum (<value1>,<value2>,...)

=> sum(avg(/host/key),avg(/host2/key2))
tan (value)

=> tan(last(/host/key))
truncate (value,decimal places)

decimal places - 指定截断的小数位数（0也是可能的）

=> truncate(last(/host/key),2)

<%= selection %>
To toggle search highlight, press Ctrl+Alt+H
Have an improvement suggestion for this page? Select the text that could be improved and press Ctrl+Enter to send it to the editors.
To toggle search highlight, press Command+Alt+H
Have an improvement suggestion for this page? Select the text that could be improved and press Command+Enter to send it to the editors.
Suggest an example