3. Instructions
538
CS/CJ/NSJ Series Instructions Reference Manual (W474)
SQRTD
Applicable Program Areas
Operands
îš„ Operand Specifications
Flags
Instruction Mnemonic Variations
Function
code
Function
DOUBLE SQUARE ROOT SQRTD @SQRTD 857
Calculates the square root of a double-precision
(64-bit) floating-point number and places the result
in the specified result words.
Symbol
SQRTD
Area
Function block
definitions
Block program areas Step program areas Subroutines Interrupt tasks
SFC action or
transition programs
Usage OK OK OK OK OK OK
Operand Description Data type Size
S First source word LREAL 4
D First destination word LREAL 4
Area
Word addresses
Indirect DM/EM
addresses
Con-
stants
Registers Flags
Pulse
bits
TR
bits
CIO WR HR AR T C DM EM
@DM
@EM
*DM
*EM
DR IR
Indirect
using IR
TK CF
S
OK OK OK OK OK OK OK OK OK OK --- --- --- OK --- --- --- ---
D
Name Label Operation
Error Flag P_ER • ON if the input data is not recognized as floating-point data.
• ON if the source data is negative.
• ON if the source data is not a number (NaN).
• OFF in all other cases.
Equals Flag P_EQ • ON if both the exponent and mantissa of the result are 0.
• OFF in all other cases.
Overflow Flag P_OF • ON if the absolute value of the result is too large to be expressed as a double-precision (64-bit) float-
ing-point value.
• OFF in all other cases.
Underflow Flag P_UF Unchanged
Negative Flag P_N Unchanged
SQRTD(857)
S
D
D: First destination word
S: First source word