Post Reply 
Equation solvers, HP 41CV etc.
12-03-2017, 03:31 AM
Post: #1
Equation solvers, HP 41CV etc.
I just realized that HP 41CV (which I just ordered, and still waiting for) does not have an equation solver. Eeep! OK no worries, I think I found a simple program for it here, but people also talk about a module for this. Which module would that be, and is it otherwise recommended? I am fine with with either 32SII (entering equations more or less as they look on paper) or 42S style (entering equation in RPN =0 ). I am guessing the latter would be the 41C way of doing it.

Bonus question: which HP calculators from the 70s have equation solvers? Looks like 34C has, but does HP 65/67 have this?
Find all posts by this user
Quote this message in a reply
12-03-2017, 04:15 AM
Post: #2
RE: Equation solvers, HP 41CV etc.
(12-03-2017 03:31 AM)Trond Wrote:  I just realized that HP 41CV (which I just ordered, and still waiting for) does not have an equation solver. Eeep! OK no worries, I think I found a simple program for it here, but people also talk about a module for this. Which module would that be, and is it otherwise recommended? I am fine with with either 32SII (entering equations more or less as they look on paper) or 42S style (entering equation in RPN =0 ). I am guessing the latter would be the 41C way of doing it.

Bonus question: which HP calculators from the 70s have equation solvers? Looks like 34C has, but does HP 65/67 have this?

If you're looking for HP-made ROMs, both the Math Pac and Advantage Pac include solvers; the Advantage Pac offers much more as it was introduced much later and includes matrix functions from the CCD ROM, and Solver and Integration programs (originally 15C versions) from another 3rd party.

If you will consider getting a 41CL upgrade or a NoVRAM module, you can load some of Angel's recent 41 Modules (made in the last 5-10 years) which offer much more powerful and flexible capabilities.

Bonus Answer: From the 70's, only the 34C has a solver built-in. It was the first (HP for sure, maybe all?) calculator to offer this feature. There were programs published for the '67/'97, 29C and likely the '65 as well.

--Bob Prosperi
Find all posts by this user
Quote this message in a reply
12-03-2017, 05:24 AM
Post: #3
RE: Equation solvers, HP 41CV etc.
Thanks very much for the info!

Do the Math Pac and Advantage Pac use one of those keyboard overlays to reassign the keys?
Find all posts by this user
Quote this message in a reply
12-03-2017, 08:25 AM (This post was last modified: 12-03-2017 09:06 AM by Ángel Martin.)
Post: #4
RE: Equation solvers, HP 41CV etc.
(12-03-2017 05:24 AM)Trond Wrote:  Thanks very much for the info!

Do the Math Pac and Advantage Pac use one of those keyboard overlays to reassign the keys?

Not really. These modules only have a basic SOLVE (in user code the MathPac and in MCODE the Advantage) to solve f(x)=0 conditions.

For an equation solver case this needs to be wrapped around more code to handle the variable selection and other management routines.

There are two "modern" implementations offering that, one is in the "Interchangeable Solutions" Module, based on the SandMath's FROOT in the same classic way as SOLVE - and the other is the "Equation Evaluation" from Mark Fleming - based on the Formula Evaluation ROM.
Both come with a basic equation library so you can use those examples to create your own equations.

You can find manuals and QRG for the first reference and the Formula Eval ROM here:
http://systemyde.com/hp41/documents.html

and more information on the second reference here: (scroll the list to the items in question)
http://www.hpmuseum.org/forum/thread-8795.html

There's another option provided by Greg McClure, he modified the "wrapper" in the Interchangeable Solutions to use the Formula Eval method - you can look into this one as well:
http://www.hpmuseum.org/forum/thread-8741.html
Find all posts by this user
Quote this message in a reply
12-03-2017, 03:28 PM
Post: #5
RE: Equation solvers, HP 41CV etc.
(12-03-2017 04:15 AM)rprosperi Wrote:  If you're looking for HP-made ROMs, both the Math Pac and Advantage Pac include solvers

As I know, these ROM routines can to copy to the RAM and possible to modify. Therefore is it available somewhere the program list of the original HP's SOLVE routine? I guess it is no any copyright problem to post freely because it is copyable.

Can anybody post here the program list?

Thanks!
Csaba
Find all posts by this user
Quote this message in a reply
12-03-2017, 04:01 PM
Post: #6
RE: Equation solvers, HP 41CV etc.
(12-03-2017 04:15 AM)rprosperi Wrote:  Bonus Answer: From the 70's, only the 34C has a solver built-in. It was the first (HP for sure, maybe all?) calculator to offer this feature. There were programs published for the '67/'97, 29C and likely the '65 as well.

The HP-25 Applications Programs book also includes a numerical solver, based on Newton's method. The program takes up 35 lines, leaving only 14 for the function, but still, pretty neat!
Visit this user's website Find all posts by this user
Quote this message in a reply
12-03-2017, 04:46 PM
Post: #7
RE: Equation solvers, HP 41CV etc.
I am starting to see how my 41CV could potentially become my best calculator. I have always wanted more statistics for my HP calculators, and I found out about the statistics pac. This is sounding very good. Smile
Find all posts by this user
Quote this message in a reply
12-03-2017, 05:37 PM (This post was last modified: 12-03-2017 05:45 PM by Dieter.)
Post: #8
RE: Equation solvers, HP 41CV etc.
(12-03-2017 03:31 AM)Trond Wrote:  I just realized that HP 41CV (which I just ordered, and still waiting for) does not have an equation solver. Eeep! OK no worries, I think I found a simple program for it here, but people also talk about a module for this. Which module would that be, and is it otherwise recommended?

There are countless root solvers available for the HP41 series. Even the standard applications booklet that came with the calculator included such a program. And of course the Math ROM (or the combined Math/Stat ROM) feature this.

About the same time the HP41 was introduced, the HP34C was the first calculator with a dedicated Solve function, which was explained in detail in the manual. The same is true for the later 15C. Since the 41-series, being the top-of-the-line models at that time, lacked this feature, HP introduced the Advantage Pac. This ROM module included a Solver that seems to use the same algorithm as the ones in the 34C or 15C. And, most important, this is not a regular user code program like the ones in the Math ROM or the Standard Pac, it is written in HP41 machine code. So you cannot copy and modify it by means of the COPY command, but it runs faster, and it uses the state-of-the-art HP-Solve algorithm.

The Advantage Pac seems to be something that offers many benefits to HP41 users. The price of a used ROM module reflects this. If you can, get one.

(12-03-2017 03:31 AM)Trond Wrote:  I am fine with with either 32SII (entering equations more or less as they look on paper) or 42S style (entering equation in RPN =0 ). I am guessing the latter would be the 41C way of doing it.

Yes. The Advantage Pac's solver expects two initial guesses in X and Y and the name of the program to solve in Alpha.

(12-03-2017 03:31 AM)Trond Wrote:  Bonus question: which HP calculators from the 70s have equation solvers? Looks like 34C has, but does HP 65/67 have this?

No, this was a HP34C first. Since it appeared in 1979 there are no other calculators of the seventies with this feature.

Well... the TI58/59 Standard ROM (Master Library module ML-01) that came with the calculator also had a – yet very simple – equation solver. So one can argue if this counts as a calculator feature. If it does this would also apply to the HP67 and others where a solver program was delivered on magnetic cards. ;-)

Dieter
Find all posts by this user
Quote this message in a reply
12-03-2017, 05:39 PM
Post: #9
RE: Equation solvers, HP 41CV etc.
(12-03-2017 03:28 PM)Csaba Tizedes Wrote:  As I know, these ROM routines can to copy to the RAM and possible to modify. Therefore is it available somewhere the program list of the original HP's SOLVE routine? I guess it is no any copyright problem to post freely because it is copyable.

While the Math Pac includes a regular user code program, the Advantage Pac's Solver is Mcode. So it cannot be copied to RAM, and I wonder if the HP Solve algorithm (or the Integrate code, for that matter) has ever been published.

Dieter
Find all posts by this user
Quote this message in a reply
12-03-2017, 06:22 PM
Post: #10
RE: Equation solvers, HP 41CV etc.
(12-03-2017 05:39 PM)Dieter Wrote:  I wonder if the HP Solve algorithm (or the Integrate code, for that matter) has ever been published.

There is an HP Journal article by William Kahan (don't remember the exact reference, but it's in the MoHPC document set) where he explains some aspects of the algorithm, but the complete algorithm or source code have never been published, as far as I'm aware. I would have loved to use that algorithm in Free42! However, you can suss out a thing or two by giving it a pathological function, say, y=2, or y=x^2+1, and then observing the successive guesses it comes up with.

(I ended up taking some inspiration from HP solve on the 42S, in how to deal with unhelpful starting guesses, and used a combination of bisection, secant method, and Ridders' method, for root refinement. It's fairly close to the 42S solve in terms of convergence, but there's still room for improvement, in terms of convergence, and in terms of handling pathological cases.)
Visit this user's website Find all posts by this user
Quote this message in a reply
12-03-2017, 06:24 PM
Post: #11
RE: Equation solvers, HP 41CV etc.
OK thanks for the info everyone!

I would also be very interested in how you like the statistics pac and if there are different alternatives to look for.
Find all posts by this user
Quote this message in a reply
12-03-2017, 07:58 PM
Post: #12
RE: Equation solvers, HP 41CV etc.
(12-03-2017 06:22 PM)Thomas Okken Wrote:  … an HP Journal article by William Kahan (don't remember the exact reference …
Personal Calculator Has Key to Solve Any Equation f(x)=0 at SOLVEkey.Pdf

BEST!
SlideRule
Find all posts by this user
Quote this message in a reply
12-03-2017, 07:59 PM
Post: #13
RE: Equation solvers, HP 41CV etc.
The article I mentioned earlier: http://www.hpl.hp.com/hpjournal/pdfs/Iss...979-12.pdf Starts at page 20.
Visit this user's website Find all posts by this user
Quote this message in a reply
12-03-2017, 08:30 PM (This post was last modified: 12-03-2017 08:31 PM by rprosperi.)
Post: #14
RE: Equation solvers, HP 41CV etc.
(12-03-2017 05:39 PM)Dieter Wrote:  ... the Advantage Pac's Solver is Mcode. So it cannot be copied to RAM, and I wonder if the HP Solve algorithm (or the Integrate code, for that matter) has ever been published.

The Advantage ROM uses a port of the HP-15C Solver. From the Advantage ROM Acknowledgements on p. 3:

Quote:The matrix operations in this pac were based on the CCD ROM, written by
W & W Software Products GmbH, 5060 Bergisch Gladbach 2, West
Germany.

The root-finding and numerical-integration routines in this pac were
adapted from those in the HP-15C by Firmware Specialists, Inc., 605 NW
5th Street #2A, Corvallis, Oregon 97330.

The original concept for the content and user interface of this pac was developed
by Chris Bunsen, Corvallis, Oregon.

It's easy to forget (today) that the Advantage Pac came out very late in the life of the 41, well after the 15C had been introduced. The company Firmware Specialists included several key ex-HP employees, so they likely were given access to the 15C code (nut MCODE) to create the 41C Advantage ROM port (also nut MCODE).

--Bob Prosperi
Find all posts by this user
Quote this message in a reply
Post Reply 




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