My understanding is that "decimal", in the context of programming, is a less-precise term to mean floating-point (i.e. encompassing IEEE 754 floats, double- vs single-precision, etc), because they're all binary numbers if you dig deep enough, right?
But apparently I am incorrect/underinformed about this.
What is "decimal", then?
as posted below:
For anyone that wants a physical version, SwissMicros makes a calculator based off of Free42: https://www.swissmicros.com/product/dm42
That website mentions that they use decimal floating point. Since free42 is licensed under gpl3, they have released the source.
https://github.com/swissmicros/DM42PGM/tree/master/lib
https://github.com/swissmicros/free42/tree/master/inteldecim...
They use Intel's library for decimal floating point: https://software.intel.com/en-us/articles/intel-decimal-floa...
It's still not the real HP-42S with its quirks, but it's nice to have decimal floating point operations.
Weird obscure fact: The printer head for HP calculator printer was still available as new parts as late as 2019, coz it was used in variety of devices, I bought cheap non-working one and just replaced the head
The HP-42S represents numbers with a 12-digit decimal mantissa, and an exponent from 10^−499 to 10^499; Free42 Decimal uses a 34-digit decimal mantissa, and an exponent from 10^−6143 to 10^6144; and Free42 Binary uses native binary floating-point, which on all currently supported platforms is IEEE-754 double precision, with a 53-bit binary mantissa which is roughly equivalent to 16 decimal digits, with an exponent from 10^−308 to 10^308.
In other words, results will not be exactly the same as a real HP-42S. For a more authentic HP-42S experience, there's Emu42.
Also, just about every dedicated calculator uses decimal floating point for several reasons, such as simpler circuitry in the ASIC and keeping the human intuition that 0.1 + 0.1 is actually 0.2.