5.2 Standard Functions of One Numeric Variable
5.2.1 Absolute value
5-121
5
APPLICATION
FUNCTIONS
ABS(_E)
ABS(_E)
Operation Error
No operation error occurs in the execution of the ABS(_E) function.
Program Example
The program which outputs the absolute value of word (signed), double word (signed) or single-
precision real type data input to from in the same data type as that of .
(a) Function without EN/ENO (ABS)
[Structured ladder]
[ST]
g_int2:= ABS(g_int1);
(b) Function with EN/ENO (ABS_E)
[Structured ladder]
[ST]
g_bool3 := ABS_E(g_bool1, g_int1, g_int2);
s
d
s