MOD

Returns the remainder when one expression representing a numerical value is divided by another expression that represents a numerical value:
MOD(a1, a2) = a1 - INT(a1/a2) * a2  
 
Note:  
MOD is generally discontinuous. Use this function expression with care when specifying force or motion input.

Format

MOD(x1,x2)

Arguments

 
x1
Any valid expression that evaluates to a real number.
x2
Any valid expression that evaluates to a real number.

Examples

The following examples illustrate the use of the MOD function:
 
Function
MOD(45, 15)
Result
0
 
Function
MOD(45, 16)
Result
13