Root (Root) - IDEC FC4A-C10R2 User Manual

Fc4a series microsmart micro programmable logic controller
Table of Contents

Advertisement

ROOT (Root)

ROOT(W)
*****
Applicable CPU Modules
FC4A-C10R2/C
FC4A-C16R2/C
X
Valid Operands
Operand
S1 (Source 1)
D1 (Destination 1)
For the valid operand number range, see pages 6-1 and 6-2.
Since the ROOT instruction is executed in each scan while input is on, a pulse input from a SOTU or SOTD instruction
should be used as required.
The ROOT instruction cannot be used in an interrupt program. If used, a user program execution error will result, turning
on special internal relay M8004 and the ERR LED on the CPU module.
Valid Data Types
W (word)
I (integer)
X
Examples: ROOT
ROOT(W)
D10
I0
ROOT(W)
D11
I1
ROOT(W)
D12
I2
ROOT(W)
D13
I3
ROOT(W)
D14
I4
ROOT(W)
D15
I5
S1 → D1
S1
D1
When input is on, the square root of operand designated by S1 is extracted and
*****
is stored to the destination designated by D1.
Valid values are 0 to 65535. The square root is calculated to two decimals, omit-
ting the figures below the second place of decimals.
FC4A-C24R2/C
X
X
Function
Binary data
Destination to store results
When a word operand such as D (data register) is designated as the source or destination, 1
point (word data type) is used.
S1
D1
D10 → D20
D20
S1
D1
D11 → D21
D21
S1
D1
D12 → D22
D22
S1
D1
D13 → D23
D23
S1
D1
D14 → D24
D24
S1
D1
D15 → D25
D25
« FC4A M
11: B
FC4A-D20K3/S3
X
I
Q
— — — — — —
— — — — — —
Before Execution
2
D10
3
D11
4
D12
55
D13
D14
9997
D15
9998
S
U
'
M
ICRO
MART
SER
S
ANUAL
A
INARY
RITHMETIC
FC4A-D20RK1/RS1 & FC4A-D40K3/S3
X
M
R
T
C
D
Constant
X
X
After Execution
141
D20
173
D21
200
D22
741
D23
D24
9998
D25
9998
»
I
NSTRUCTIONS
Repeat
X
2
=
1.41
3
=
1.73
4
=
2.00
55
=
7.4161
9997
=
99.98
9998
=
99.98
11-7

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents