Mitsubishi Electronics FX1S Welding System User Manual


 
FX Series Programmable Controllers Devices in Detail 4
4-45
4.15.2 Floating Point Format
Floating point format extends the abilities and ranges provided by Scientific Notation with the
ability to represent fractional portions of whole numbers, for example;
Performing and displaying the calculation of 22 divided by 7 would yield the following results:
a) Normal FX operation using decimal (integers) numbers would equal 3 remainder 1
b) In floating point it would equal 3.14285 (approximately)
c) In Scientific format this calculation would be equal to 3142 10
-3
So it can be seen that a greater degree of accuracy is provided by floating point numbers, i.e.
through the use of larger numerical ranges and the availability of more calculable digits.
Hence, calculations using floating point data have some significant advantages. Decimal data
can be converted in to floating point by using the FLT, float instruction (FNC 49). When this
same instruction is used with the float fag M8023 set ON, floating point numbers can be
converted back to decimal. see page 5-49 for more details.
The following points should be remembered about the use of Floating Point within appropriate
FX units;
Floating point numbers, no matter what numerical value, will always occupy two consecu-
tive data registers (or 32 bits).
Floating point values cannot be directly monitored, as they are stored in a special format
recommended by the I.E.E.E (Institute of Electrical and Electronic Engineers) for personal
and micro computer applications.
Floating point numbers have both mantissa and exponents (see Scientific Notation for an
explanation of these terms). In the case of floating point exponents, only 8 bits are used.
Additionally there is a single sign bit
for the mantissa. The remaining bits
of the 32 bit value, i.e. 23 bits, are
used to ‘describe’ the mantissa
value.
Valid ranges for floating point numbers as used in FX Main Processing Units:
Description Sign
Exponent
(bit pattern)
Mantissa
(bit pattern)
Remark
Normal Float
0 or 1
11111110
00000001
11111111111111111111111
11111111111111111111110
00000000000000000000001
00000000000000000000000
Largest number +/- 3.403
10
38
Accuracy: 7 significant figures
Smallest number +/- 1.175
10
-38
Zero
0 or 1
00000000 00000000000000000000000 All digits are 0 (zero)
b15 b0
Data register ’D+1’
(16 bits)
b15 b0
Data register ’D’
(16 bits)
Sign bit
Exponet
(8 bits)
Mantissa
(23 bits)
FX Data Register Contruction
Floating Point Format