533
EXPD, EXPDP
1
2
3
4
4
6
7
8
7.12
Special function
instructions
7.12.2
2
EXP
D, EXP
DP
Program
E
xamp
l
e
(1) The following program performs an exponent operation on the value set by the 2 BCD digits at X20 to X31, and stores
the results as a 64-bit floating decimal point real number at D0 to D3.
[Ladder Mode]
[List Mode]
[Operations involved when value designated by X20 to X31 is 13]
*1:
The operation result will be under 2
1024
if the BCD value of X20 to X31 is less than 709, from the calculation
loge 2
1024
= 709.7832.
Because setting a value of over 710 will return an operation error, turn M0 ON if a value of over 710 has been set to avoid the
error.
Conversion from natural logarithm to common logarithm
In the CPU module, calculation is made using a natural logarithm.
To obtain a common logarithm value, enter in,
a common logarithm value divided by 0.43429.
I
nputs
data
used
for
exponent
operat
i
on
(
)
.
Con
v
erts
the
i
nput
data
i
nto
a
6
4-
b
i
t
f
l
oat
i
ng
-
po
i
nt
rea
l
number
(
)
.
E
xecutes
exponent
operat
i
on
(
)
.
Checks
the
range
of
the
v
a
l
ue
used
for
operat
i
on
.
*1
1
2
3
Step
I
nstruct
i
on
De
vi
ce
X31
BCD
v
a
l
ue
0
D20
1 3
X20
Con
v
ers
i
on
to
B
IN
B
IN
b15
b0
B
IN v
a
l
ue
13
Con
v
ers
i
on
to
f
l
oat
i
ng
-
po
i
nt
FLT
D
E
XP
operat
i
on
E
XPD
D11
13
D10
D13 D12
D1
44
2
4
13
.4
D0
D3
D2
6
4-
b
i
t
f
l
oat
i
ng
-
po
i
nt
rea
l
number
6
4-
b
i
t
f
l
oat
i
ng
-
po
i
nt
rea
l
number
1
2
3
S