13.29
Date Code 20171006 Instruction Manual SEL-400 Series Relays
SELOGIC Control Equation Programming
SEL
OGIC Control Equation Operators
Math Operators
Use math operators when writing math SELOGIC control equations. Math
SEL
OGIC control equations manipulate numerical values and provide a numerical
base 10 result. Table 13.22 summarizes the operators available for math SEL
OGIC
control equations.
Parentheses
Use parentheses to control the order in which the relay evaluates math operations
within a math SEL
OGIC control equation. Also use parentheses to group expres-
sions that you use as arguments to function operators such as SIN and COS.
Include as many as 14 levels of nested parentheses in your math SEL
OGIC control
equation. Example 13.12 shows how parentheses affect the operation and evalua-
tion of math operations.
Math Error Detection
If a math operation results in an error, the relay turns on the math error bit,
MATHERR, in the Relay Word. A settings change or the STATUS SC command
resets this bit. For example, if you attempt to take the square root of a negative
number (SQRT –5), the math error bit will be asserted until you clear the bit with
a STATUS SC command or change settings.
Table 13.22 Math Operator Summary
Operator Description
( ) Parentheses
+, –, *, / Arithmetic
SQRT Square root
LN, EXP, LOG Natural logarithm, exponentiation of e, base 10 loga-
rithm
COS, SIN, ACOS, ASIN Cosine, sine, arc cosine, arc sine
ABS Absolute value
CEIL Rounds to the nearest integer toward infinity
FLOOR Rounds to the nearest integer toward minus infinity
– Negation
Example 13.12 Using Parentheses in Math Equations
The freeform math SELOGIC control equations below show examples of
parentheses usage.
# Examples of parenthesis usage
AMV001 := AMV005 * (AMV004 + AMV003) # Calculate sum first,
then product
AMV002 := AMV010 * (AMV009 + (AMV016 / AMV015)) # Nest
parentheses
AMV003 := SIN (AMV037 + PMV42) # Group terms for a function