FE MONITOUCH V8 SERIES Reference: Additional Functions page 375

Table of Contents

Advertisement

23
Macro
F0 = COS (F1) (F) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . FLOAT
Function: Cosine
This macro command is used to store a cosine of the angle (in radians) specified for [F1] in [F0].
Specify values for [F0] and [F1] in the format of decimal floating-point data (FLOAT).
FLOAT
COS
Available memory
F0
F1
Range
F0
F1
Example
• To obtain the value for cos 0° in radians;
$u200 = RAD (0) (F)
$u100 = COS ($u200) (F)
The operation result of "1" is stored in $u100.
* For more information on cosθ of the trigonometric functions, refer to "Example" of sine on
page 23-5.
Supplementary information
• $s1056 stores the result of macro execution.
Code (DEC)
* An indefinite value is stored in [F0].
• To convert the unit of an angle, use the macro command of DEG (page 23-11) or RAD (page
23-12).
23-6
F1+1
F1
Internal Memory
IEEE 32-bit single precision real number
0
1
2
FLOAT
F0+1
F0
PLC1 - PLC8
Memory Card
Memory
: Setting enabled (indirect designation disabled)
: Setting enabled (indirect designation enabled)
Value
Contents
Normal
Overflow*
Underflow*
Constant

Advertisement

Table of Contents
loading

Table of Contents