EasyManua.ls Logo

Inovance H3U Series - Page 112

Inovance H3U Series
737 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
111
4
4 Instructions 4.4.1 Four Arithmetic Operations
Operands
Operand
Bit Element Word Element
System·User System·User Bit Designation Indexed Address Constant
Real
Number
S1 X Y M T C S SM D R T C SD KnX KnY KnM KnS KnSM
V,Z
Modication K H E
S2 X Y M T C S SM D R T C SD KnX KnY KnM KnS KnSM
V,Z
Modication K H E
D X Y M T C S SM D R T C SD KnX KnY KnM KnS KnSM
V,Z
Modication K H E
Note: The elements in gray background are supported.
Function
One binary oating-point number is divided by another.
S1 and S2 are respectively the dividend and divider of a binary oating point division.
D is the head address for storing the quotient of a binary oating point division.
If the constant K or H is used as the operand S1 or S2, the value is converted to a binary oating-point
number before the division operation.
The zero ag M8020 is set if the result of the calculation is 0.
The carry ag M8022 is set if the absolute value of the calculation result is greater than the maximum
oating-point value.
The borrow ag M8021 is set if the absolute value of the calculation result is less than the minimum
oating-point value.
The divider cannot be 0; otherwise, a calculation error will occur, and M8067 and M8068 are set to ON to
identify this error.
Example:
DEDIV D2 D4 D10
X14
DS1 S2
DEDIVP D10 K10 D10
X15
When X14 = ON, the quotient of dividing the binary oating-point number in (D3, D2) by that in (D5, D4) is
stored in (D11, D10).
When X15 switches from OFF to ON, the binary oating-point number in (D11, D10) is divided by 10 and
the result is stored in (D11, D10). The constant K10 is changed to a binary oating-point number before the
division operation.
If the unit that stores the quotient is the same as the dividend or divider storage unit, use the DEDIVP
instruction of the pulse execution type. If the continuous execution type is used, calculation is performed
upon every program scan.

Table of Contents

Other manuals for Inovance H3U Series

Related product manuals