Omron SYSMAC CJ - REFERENCE MANUAL 08-2008 Reference Manual page 630

Programmable controllers
Hide thumbs Also See for SYSMAC CJ - REFERENCE MANUAL 08-2008:
Table of Contents

Advertisement

Floating-point Math Instructions
Number of Digits
Floating-point Data
Special Numbers
Writing Floating-point
Data
590
s
e–127
Real number = (–1)
2
s: Sign
e: Exponent
f: Mantissa
The floating-point data format conforms to the IEEE754 standards. Data is
expressed in 32 bits, as follows:
Sign
Exponent
s
e
31
30
23
Data
No. of bits
s: sign
1
e: exponent
8
f: mantissa
23
The number of effective digits for floating-point data is seven digits for deci-
mal.
The following data can be expressed by floating-point data:
• –
38
• –3.402823 x 10
• 0
–45
• 1.402398 x 10
• +
• Not a number (NaN)
1.402398 x 10
38
–3.402823 x 10
The formats for NaN,
NaN*: e = 255, f
0
+ :
e = 255, f = 0, s= 0
– :
e = 255, f = 0, s= 1
0:
e = 0
*NaN (not a number) is not a valid floating-point number. Executing floating-
point calculation instructions will not result in NaN.
When floating-point is specified for the data format in the I/O memory edit dis-
play in the CX-Programmer, standard decimal numbers input in the display
are automatically converted to the floating-point format shown above
(IEEE754-format) and written to I/O Memory. Data written in the IEEE754-for-
mat is automatically converted to standard decimal format when monitored on
the display.
(1.f)
Mantissa
f
22
0: positive; 1: negative
The exponent (e) value ranges from 0 to 255.
The actual exponent is the value remaining after
127 is subtracted from e, resulting in a range of
–127 to 128. "e=0" and "e=255" express special
numbers.
The mantissa portion of binary floating-point
data fits the formal 2.0 > 1.f 1.0.
–45
value
–1.402398 x 10
38
value
3.402823 x 10
–45
0
1
–1
, and 0 are as follows:
Section 3-15
0
Contents
–45
1.402398 x 10
+
38
3.402823 x 10

Advertisement

Table of Contents
loading

This manual is also suitable for:

Sysmac cs seriesSysmac one nsj seriesSysmac cj series

Table of Contents