Справочник Пользователя для Mitsubishi Electronics QCPU
7-306
BSQR(P),BDSQR(P)
7.12.28
BCD 4-digit and 8-digit square roots
(BSQR(P),BDSQR(P))
BSQR(P),BDSQR(P)
Function
BSQR
(1) Returns the square root of the value designated at
, and stores the operation result in the
device number designated at
.
(2) Values that can be designated at
are BCD values with a maximum of 4 digits
(from 0 to 9999).
(3) The operation results of
and
+1 are stored as their respective BCD values of between
0 and 9999.
(4) Operation results are rounded off from the fifth decimal place.
For this reason, the fourth decimal place has an error of
±
1.
: Data of which the square root is obtained or the number of the device where the data is stored
(BSQR(P): BCD 4 digits, BDSQR(P): BCD 8 digits)
: Head number of the devices where the square root calculation result will be stored (BCD 4 digits)
Setting
Data
Internal Devices
R, ZR
J
\
U
\G
Zn
Constants
K, H
Other
Bit
Word
Bit
Word
––
––
––
Process
High
performance
Redundant Universal
Basic
Command
Command
P
S
D
S
D
BSQR,BDSQR
BSQRP,BDSQRP
BSQR/BDSQR
S
D
S
D
S
D
+1
D
S
D
Integer part
Decimal fraction part
.
S
D
D