What are Numeric expressions?

Unless otherwise stated in this manual, expressions refer to numeric expressions which consist of elements (attributes, variables, distributions, and constants) combined with normal mathematical operators ( + , – , etc.) that result in a numeric value. A numeric expression may be as simple as a variable name or as complex as a formula.

Expression Elements

The following table illustrates the expression elements.

ElementMeaningExamples
attribute nameAttribute’s current valuea_Weight
a_Pkg_Qty
a_SerialNumber
variable nameVariable’s current valuev_Num_In_System
v_Qty_To_Go
v_Total_Pieces
distributionA probability distributionT(5, 15, 45)
N(34, 3)
U(50, 5)
constantA specific number5
10.25
19.01

Mathematical Operators

The following table illustrates the use of mathematical operators.

ItemMeaningExamples
+additiona_Weight + 2.5
a_Pkg_Qty + 3.4
subtractionv_Num_In_System – 5
100 – v_Qty_To_Go
*multiplication5 * v_Total_Pieces
a_Weight * 0.98
/divisionv_Total_Pieces / 100
a_Pkg_Qty / v_Bin_Qty
()parentheses(v_Total_Pieces – v_Total) / 100
a_Pkg_Qty / (v_Bin_Qty – 100)
**exponentiationa_Pkg_Qty ** v_Total_Pieces
2 ** v_Bin_Qty
 modulus a_Value1 = 10
a_Value2 = 4
a_Div = a_Value1 / a_Value2
v_Remainder = a_Value1 – (a_Div * a_Value2)// Where a_Div is an integer.

Examples of Numeric Expressions

You may combine items to form a compound expression. Parentheses may be used to set off parts of the expression to be evaluated first. For information on the order in which operators are evaluated to determine the expression’s value, see Operator Precedence below.

a_Attr1
50.91
v_Var1 + 5
v_Total_Pieces + 5 * a_Pkg_Qty
(a_Weight + 5) * (a_Pkg_Qty / 2)
N(25, 4.8) + a_Weight * (v_Total_Pieces – 10)

What are Boolean expressions?

Was this article helpful?

Need Support?

Can't find the answer you're looking for?
Contact Support
Go to Top