Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Exploring IEEE754 floating point bit patterns.

by BrowserUk (Pope)
on Jul 28, 2012 at 05:05 UTC ( #984141=CUFP: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    #! perl -slw
    use strict;
    ...
        NEG_ZERO, NEG_DENORM_1ST, NEG_DENORM_LST, NEG_NORM_1ST, NEG_NORM_L
    +ST,
        NEG_INF, NEG_SNAN_1ST, NEG_SNAN_LST,
        NEG_IND, NEG_QNAN_1ST, NEG_QNAN_LST;
    
  2. or download this
    C:\test>ieee.pl
                          0 : 0000000000000000
    ...
                    -1.#IND : fff8000000000000
                   -1.#QNAN : fff8000000000001
                   -1.#QNAN : ffffffffffffffff
    
  3. or download this
    #include <stdio.h>
    #include <float.h>
    ...
                FPClassAsText( _fpclass( asDouble( dblPatns[ i ] ) ) )
            );
    }
    
  4. or download this
    C:\test>qnan
    0000000000000000 :                       0 Positive zero (+0)
    ...
    fff8000000000000 :                 -1.#IND Quiet NaN
    fff8000000000001 :                -1.#QNAN Quiet NaN
    ffffffffffffffff :                -1.#QNAN Quiet NaN
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: CUFP [id://984141]
Approved by marto
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others about the Monastery: (11)
As of 2014-09-03 08:31 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite cookbook is:










    Results (35 votes), past polls