Notes:
1. Floating point (also known as floating-point float, double-digit or real-number) can be defined with any of the following syntax:
<?php
$a = 1.234;
$b = 1.2e3;
$c = 7E-10;
?>
2. The length of the floating-point number is relative to the platform, although the usual maximum value is 1.8e308 and has a precision of 14-bit decimal digits (64-bit IEEE format).
3. A rational number that can be accurately represented in decimal, such as 0.1 or 0.7, cannot be converted to binary format without losing a little bit of precision, regardless of how many of the mantissa can be accurately represented by the binary used internally. This can result in confusion: for example, floor ((0.1+0.7) *10 typically returns 7 instead of 8 as expected because the internal representation of the result is actually similar to 7.9999999999999991118 ....
4. So never believe that the floating-point number is accurate to the last one, and never compare two floating-point numbers for equality. If you do need a higher precision, you should use any mathematical or GMP function of any precision.
5.NaN
Some mathematical operations produce a result that is represented by a constant NAN. This result represents a value that is undefined or not expressed in a floating-point operation. Any loose or strictly comparable result of this value to any other value is FALSE.
Since Nan represents any different value, it should not be compared with other values, including itself, and should be checked with Is_nan ().
Php-manual Learning----"Language Reference"----"type"-----"float floating-point"