16C internal floating point format?
04-06-2021, 02:37 PM
Post: #7
 billf Junior Member Posts: 14 Joined: Apr 2021
RE: 16C internal floating point format?
BTW, slight correction - I meant big-endian. The internal format is rather delightful - if anyone's curious, here's my description:

Code:
/// /// Stored in what I think is the 16C's internal format /// /// This format is interesting.  It's big-endian BCD.  The mantissa is /// sign-magnitude, with the sign in a nybble that is 0 for positive, and /// 9 for negative.  The exponent is 1000's complement BCD, with a magnitude /// between 0 and 99 (inclusive).  So it looks like: /// ///      smmmmmmmmmmeee /// /// s = mantissa sign (0/9) /// m = mantissa magnitude /// e = exponent (1 is 001, -1 is 0x999, -2 is 0x998, etc) /// /// The most significant digit of the mantissa is always non-zero.  In other words, /// 0.1e-99 underflows to zero.  The mantissa is NOT stored in complement form.  So, a /// mantissa of -4.2 is 0x94200000000. /// /// Note that I didn't refer to a ROM image to figure this out, or anything /// like that.  I just asked what the behavior of the real calculator is /// for a couple of data points. /// cf. https://www.hpmuseum.org/forum/thread-16595-post-145554.html#pid145554 ///
 « Next Oldest | Next Newest »

 Messages In This Thread 16C internal floating point format? - billf - 04-03-2021, 08:48 PM RE: 16C internal floating point format? - ThomasF - 04-03-2021, 10:39 PM RE: 16C internal floating point format? - billf - 04-04-2021, 12:21 AM RE: 16C internal floating point format? - Joe Horn - 04-04-2021, 01:24 AM RE: 16C internal floating point format? - billf - 04-04-2021, 01:52 AM RE: 16C internal floating point format? - KF6GPE - 04-04-2021, 02:32 AM RE: 16C internal floating point format? - billf - 04-06-2021 02:37 PM RE: 16C internal floating point format? - ThomasF - 04-06-2021, 05:29 PM RE: 16C internal floating point format? - billf - 04-14-2021, 07:58 PM RE: 16C internal floating point format? - ThomasF - 04-14-2021, 08:26 PM New 16C simulator - alpha on web - billf - 05-01-2021, 10:19 PM RE: 16C internal floating point format? - KF6GPE - 05-02-2021, 02:31 AM RE: 16C internal floating point format? - KimH - 05-02-2021, 05:37 AM

User(s) browsing this thread: 1 Guest(s)