Additional Information
When you typecast your floating point number into an array of Booleans, you will only get a Boolean element for each byte in your number. For example, if you have a double precision number (8 bytes), you will get a Boolean array with a size of 8 elements. Although a Boolean element could theoretically only take one bit of memory, they each actually consume a whole byte.
LabVIEW floating point numbers are stored in IEEE 754 format. The following table shows the layout for single (32-bit) and double (64-bit) precision floating-point values. The number of bits for each field are shown (bit ranges are in square brackets):
| Sign | Exponent | Fraction | Bias |
---|
Single Precision | 1 [31] | 8 [30-23] | 23 [22-00] | 127 |
---|
Double Precision | 1 [63] | 11 [62-52] | 52 [51-00] | 1023 |
---|
Note: When running the example code from the image below, the bytes will be swapped on an Intel based computer because of the Little Endian format. So the order of the bytes will be as follows (by row of the array, starting at index 0): 7, 8, 5, 6, 3, 4, 1, 2.