Results 1 to 4 of 4

Thread: How is 252.0 = 406F 8000 ?

  1. #1

    Thread Starter
    pathfinder NotLKH's Avatar
    Join Date
    Apr 2001
    Posts
    2,397

    How is 252.0 = 406F 8000 ?

    I'm not sure how to approach this, but here's my problem.

    I'm trying to hash some job administration data files, made on a UNIX platform, with either some C flavor, or JAVA program.

    These files consist of properties of print jobs, and I've got 80 % of them defined. Now I'm working on an apparent single precision data type, but in a half hour I've gotten relatively nowhere. I figure the best method would be to 2's complement the values and analyze the relationship between the unaltered sequence, the 2's complement sequence, and the VB Single byte sequence, but I won't be able to get to this for anther day or two.

    So, perhaps one of the Geni here might have some quick insight.

    Here's some values:



    Can anyone explain a way for mapping the extracted data back to its decimal equivalent, or suggest a good way to google for a way?

    -Lou
    Attached Images Attached Images  

  2. #2
    transcendental analytic kedaman's Avatar
    Join Date
    Mar 2000
    Location
    0x002F2EA8
    Posts
    7,221
    try IEEE 754 standard
    Use
    writing software in C++ is like driving rivets into steel beam with a toothpick.
    writing haskell makes your life easier:
    reverse (p (6*9)) where p x|x==0=""|True=chr (48+z): p y where (y,z)=divMod x 13
    To throw away OOP for low level languages is myopia, to keep OOP is hyperopia. To throw away OOP for a high level language is insight.

  3. #3

  4. #4

    Thread Starter
    pathfinder NotLKH's Avatar
    Join Date
    Apr 2001
    Posts
    2,397
    from http://www.psc.edu/general/software/...ieee/ieee.html
    Double Precision
    The IEEE double precision floating point standard representation requires a 64 bit word, which may be represented as numbered from 0 to 63, left to right. The first bit is the sign bit, S, the next eleven bits are the exponent bits, 'E', and the final 52 bits are the fraction 'F':

    S EEEEEEEEEEE FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF
    0 1________11 12________________________________________________63

    The value V represented by the word may be determined as follows:


    If E=2047 and F is nonzero, then V=NaN ("Not a number")
    If E=2047 and F is zero and S is 1, then V=-Infinity
    If E=2047 and F is zero and S is 0, then V=Infinity
    If 0<E<2047 then V=(-1)**S * 2 ** (E-1023) * (1.F) where "1.F" is intended to represent the binary number created by prefixing F with an implicit leading 1 and a binary point.
    If E=0 and F is nonzero, then V=(-1)**S * 2 ** (-1022) * (0.F) These are "unnormalized" values.
    If E=0 and F is zero and S is 1, then V=-0
    If E=0 and F is zero and S is 0, then V=0

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width