10.5
Math and Numerical Functions
This section describes the Math and Numerical functions of the Instruction Set:
•
Standard Math Functions: Addition, Subtraction, Multiplication, Division
•
Modulo Division
•
Scaling Function
•
Square Root
•
Trigonometric functions
•
Logarithmic/Expontial functions
•
Convert to Degrees
•
Convert to Radians
Converting Data for the Math and Numerical Functions
The program may need to include logic to convert data to a different type before using a
Math or Numerical function. The description of each function includes information about
appropriate data types. The section Data Type Conversion Functions explains how to
convert data to a different type.
10.5.1
Math and Numerical Functions Add, Subtract,
Multiply, Divide
The standard math functions are Addition, Subtraction, Multiplication, and Division. The
Division function rounds down; it does not round to the closest integer. (For example, 24
DIV 5 = 4.)
When a math function receives power flow, the operation is performed on input
parameters I1 and I2. Parameters I1, I2, and output Q must be the same data type.
Input 1
Input 2
Output
OK
Enable
ADD_
INT
I1 Q
I2
The math functions pass power if there is no math overflow. If an overflow occurs, the
result is the largest value with the proper sign and no power flow.
10.5.1.1
Parameters of the Standard Math Functions
Input/ Output
Choices
Description
enable
flow
When the function is enabled, the operation is
performed.
I1
All data types: R, AI, AQ,
constant
INT data type only: I, Q,
M, T, G
I1 contains a constant or reference for the first
value used in the operation. (I1 is on the left side
of the mathematical expression, as in I1 + I2).
Range for constants in doubleprecision signed
integer operations is minimum/maximum DINT.
162
GFK-1503E
VersaMax PLC User Manual
For public disclosure
Содержание VersaMax PLC
Страница 1: ...GE Intelligent Platforms GFK 1503E VersaMax PLC User Manual September 2015 For public disclosure ...
Страница 16: ...Notes 16 GFK 1503E VersaMax PLC User Manual For public disclosure ...
Страница 38: ...Notes 38 GFK 1503E VersaMax PLC User Manual For public disclosure ...
Страница 50: ...Notes 50 GFK 1503E VersaMax PLC User Manual For public disclosure ...
Страница 92: ...Notes 92 GFK 1503E VersaMax PLC User Manual For public disclosure ...
Страница 112: ...Notes 112 GFK 1503E VersaMax PLC User Manual For public disclosure ...
Страница 224: ...Notes 224 GFK 1503E VersaMax PLC User Manual For public disclosure ...
Страница 292: ...Notes 292 GFK 1503E VersaMax PLC User Manual For public disclosure ...
Страница 316: ...Notes 316 GFK 1503E VersaMax PLC User Manual For public disclosure ...
Страница 317: ......
Страница 318: ...GE Intelligent Platforms 1 800 433 2682 1 434 978 5100 www ge ip com GFK 1503E For public disclosure ...