The Museum of HP Calculators

HP Forum Archive 21

[ Return to Index | Top of Index ]

[WP34S] Register use by functions.
Message #1 Posted by Chris Tvergard on 11 May 2012, 5:54 p.m.

Is there any documentation related to which registers functions like NORML, RAN#, and ISG use internally when called? In particular I use the REG I for using STO->I my results into R00-R99. Sometimes REG I is affected by some program function. REGs J,K seem stable for probability distribution parameters. I am not using complex numbers.

      
Re: [WP34S] Register use by functions.
Message #2 Posted by Paul Dale on 11 May 2012, 8:28 p.m.,
in response to message #1 by Chris Tvergard

As a rule, internal functions do not make any changes to your state. At least unless that is the whole purpose of the function.

Register I is the complex equivalent of last X (L). Thus, complex operations change I, but nothing else should. J and K hold statistical distribution parameters -- refer to the manual for details as they vary, these are never changed. A, B, C & D are either general purpose or part of the stack. X, Y, Z, T & L are part of the stack and last X.

You three examples in turn:

Norml takes the mean from J, the variance from K and does the appropriate statistical calculation.

RAN# uses special internal state and accesses no registers.

ISG uses the register you give it as an argument and no others.

- Pauli

            
Re: [WP34S] Register use by functions.
Message #3 Posted by Chris Tvergard on 11 May 2012, 11:36 p.m.,
in response to message #2 by Paul Dale

Pauli,

Many thanks for your detailed answer. I appreciate that very much.

I must be doing something wrong in the program lines.

I assume that you are one of the original inventors of the 34S concept and I want to thank you and the others for this great project. Not only is your concept implementation creating the world's greatest scientific calculator, but I truly believe that the 34S is the world's best business calculator as well. Using the probability distributions and their inverses one can get a better picture of say stock or option prices and strike prices than what a simple deterministic or stock graph will provide. Further I can generate stock data from the inverse cumulative dist. and thus do Monte Carlo simulations which help in wait time studies between low/high stock prices. The 34S gives all this to me faster and wherever I am located. You guys are changing the business world too. The 34S is awesome!

Thanks.

Chris

                  
Re: [WP34S] Register use by functions.
Message #4 Posted by Paul Dale on 12 May 2012, 12:22 a.m.,
in response to message #3 by Chris Tvergard

Yes, I'm the P from the device name :-)

I doubt we're changing the business calculator world, we're missing way too much functionality for that.

- Pauli

                  
Re: [WP34S] Register use by functions.
Message #5 Posted by Dominic Richens on 12 May 2012, 1:29 p.m.,
in response to message #3 by Chris Tvergard

I have found the best way to debug programs now is to use the emulator with the T flag set (trace) and the HP82240B emulator running. You get a complete trace in all it's glorious details.

I can't image using this with a real printer - the amount of paper I'd go through...

            
Re: [WP34S] Register use by functions.
Message #6 Posted by Walter B on 12 May 2012, 3:35 a.m.,
in response to message #2 by Paul Dale

Chris,

Please take a look to page 20 - it should answer your questions regarding I, J, and K.


[ Return to Index | Top of Index ]

Go back to the main exhibit hall