5.3 Standard Arithmetic Functions
146
FXCPU Structured Programming Manual
(Application Functions)
5.3.6
EXPT(_E)
Outline
This function obtains raised result, and outputs it.
1. Format
*1.
Output variable
2. Set data
In explanation of functions, I/O variables inside ( ) are described.
Explanation of function and operation
This function raises float (single precision) data stored in a device specified in
(to the power of the value
stored in a device specified in
), and outputs the operation result to a device specified in
.
Cautions
1) Use the function having "_E" in its name to connect a bus.
2) When handling 32-bit data in structured programs, you cannot specify 16-bit devices directly, different
from simple projects. Use labels when handling 32-bit data.
You can specify 32-bit counters directly, however, because they are 32-bit devices.
Use global labels when specifying labels.
FX
3U(C)
FX
3G
FX
2N(C)
FX
1N(C)
FX
1S
FX
U
/FX
2C
FX
0N
FX
0(S)
Function name
Expression in each language
Structured ladder
ST
EXPT
EXPT(In1,In2);
Example:
Label 2:=
EXPT(Label 1,D10);
EXPT_E
EXPT_E(EN,In1,In2,Output
label);
Example:
EXPT_E(X000,Label 1,D10,
Label 2);
Variable
Description
Data type
Input
variable
EN
Execution condition
Bit
In1
(
)
Data to be raised, or word device which stores such data
FLOAT (Single Precision)
In2
(
)
Power data, or word device which stores such data
ANY_NUM
Output
variable
ENO
Execution status
Bit
*1
(
)
Word device which will store the operation result
FLOAT (Single Precision)
EXPT
*1
Label 2
Label 1
In1
D10
In2
EXPT_E
EN
ENO
*1
Label 2
X000
Label 1
In1
D10
In2
s1
s2
d
s1
s2
d
4.0
2
Word
[signed] data
16.0
s2
Float (single
precision) data
s1
Float (single
precision) data
d