Mod

This function computes the integer modulus of two numbers.

Description

Integer modulus of two numbers.

Type

NUMERIC

Arguments

Type

Meaning

1

NUMERIC

the numerator

2

NUMERIC

the units to which to convert the numerator

3

NUMERIC

the denominator

4

NUMERIC

the units to which to convert the denominator

Evaluation

Converts numerator and denominator into the specified units, then returns the integral modulus of the converted values, where integral modulus of x and y returns the integral remainder after integral division of x and y, which can be defined as:

 

 

Comments

If the denominator is equal to zero, the run is aborted with an error.
Each of the units arguments must have units which are compatible with the value they are associated with, otherwise the run is aborted with an error.

Note that this function does not use the scalar portion of either of the units arguments.

 
Mod(3.9 "m", 0.0 "ft", 5.0 "sec", 0.0 "sec")
 
2.0