2 numerical functions, 1 abs, 2 sqrt – Lenze DDS v2.3 User Manual
Page 297: 3 ln, 4 log, 5 exp, Sqrt, Drive plc developer studio
Advertising
Drive PLC Developer Studio
IEC 61131-3 Standard functions
14-5
l
DDS EN 2.3
14.2
Numerical functions
14.2.1
ABS
Returns the absolute value of a number
Examples
IL
ST
FBD
LD -2
ABS
ST i (* i=2 *)
i:=ABS(-2);
14.2.2
SQRT
Returns the square root of a number
Examples
IL
ST
FBD
LD 16
SQRT
ST q (* q=4 *)
q:=SQRT(16);
14.2.3
LN
Returns the natural logarithm of a number
Examples
IL
ST
FBD
LD 45
LN
ST q (* q=3.806663 *)
q:=LN(45);
14.2.4
LOG
Returns the logarithm to the base of 10 of a number
Examples
IL
ST
FBD
LD 314.5
LOG
ST q (* q=2.497621 *)
q:=LOG(314.5);
14.2.5
EXP
Returns the exponential function
Examples
IL
ST
FBD
LD 23
EXP
ST q (* q=9.744791e+009 *)
q:=EXP(23);
Show/Hide Bookmarks
Advertising