HP Forums
HP41 Mcode Entrypoint for 'high precision numbers' - Printable Version

+- HP Forums (https://archived.hpcalc.org/museumforum)
+-- Forum: HP Museum Forums (https://archived.hpcalc.org/museumforum/forum-1.html)
+--- Forum: Old HP Forum Archives (https://archived.hpcalc.org/museumforum/forum-2.html)
+--- Thread: HP41 Mcode Entrypoint for 'high precision numbers' (/thread-139367.html)



HP41 Mcode Entrypoint for 'high precision numbers' - PeterP - 07-29-2008

Hi,

In PPCJ-V10-N7 Charles Bouldin talks about the normal arithmetic entrypoints ADD2_10 etc. In his first paragraph he also says "... additional entry points for high precision numbers which occupy a pair of addresses exist but will not be discussed here".

Does anyone else know about this entry-points and how to use them?

Thanks!

Cheers

Peter


Re: HP41 Mcode Entrypoint for 'high precision numbers' - Eric Smith - 07-29-2008

Addresses (hexadecimal):

ad2-10   1807
ad1-10 1809
ad2-13 180c

mp2-10 184d
mp1-10 184f
mp2-13 1852

dv2-10 1898
dv1-10 189a
dv2-13 189d

Comments from the source code:

******************************************************
* common math entries ***
* if number is 2-10, ***
* then form is: ***
* A has 10 digit form ***
* C has 10 digit form ***
* if number is 1-10, ***
* then form is: ***
* A has sign and exp ***
* B has 13 digit mantissa ***
* C has 10 digit form ***
* if number is 2-13, ***
* then form is: ***
* A and B as in 1-10 ***
* M has sign and exp ***
* C has 13 digit mantissa ***
* ***
* on exit, C has 10 digit form ***
* A and B have 13 digit form ***
* ***
******************************************************



Re: HP41 Mcode Entrypoint for 'high precision numbers' - PeterP - 07-30-2008

Thanks Eric! Now I just have to figure out how to use them :-)

Cheers

Peter
PS: it would appear that they are not double precision but just 13 digits instead of 10, correct?


Re: HP41 Mcode Entrypoint for 'high precision numbers' - Eric Smith - 07-30-2008

Yes, 13-digit mantissa. The intent was that they provide more precision for intermediate results in calculations of the elementary functions (trig, logs, exponentials, etc). The extra 3 digits makes a big difference, though it isn't sufficient to guarantee correct rounding for all cases.