Issues with the SLV command in WP34s


I've tested now the new error message "Solve failed" for the SLV command and in principle it is working. But in my tests I saw that SLV is still working unreliable.

I've used the simple function x^2-3 and found that the solver has big problems when the 2 initial guesses are equal - and this may happen quite quickly when the user presses the ENTER key after his 2nd guess and before calling SLV.

Ok, I know that this is in fact an user error, but who has really never done this before: entering 2 start values? - well, 0 ENTER 1 ENTER - and now call the solver? - ok, [f]SLV.

But now of course X=1 and Y=1 and SLV is called with 2 equal guesses - and it fails! Unfortunately not with the new error message "Solve failed" but with completely wrong 'results' in X and Y, and a function value in Z which is far away from 0 (what it should be) - but for THIS problem a bit later.

For the above mentioned function x^2-3 this happens for all initial guesses from -1.7 to +1.7 whenever both guesses are the same.

So I would say that the SLV routine should definitely make sure that it is NOT called with 2 equal inital guesses - either it should give any error message in this case, or the 2nd guess should automatically be changed a bit. One possible solution might be the following short code at the begin of the SLV routine:


INC X (or any other change of X)

This might of course lead to another problem when the changed X-value is not within the definition interval of the function, but this would certainly happen not very often and would definitely be better than a wrong result.

And now to the other problem mentioned before: also if (because of such 2 equal start values) the solver fails, it should of course not give wrong results but display the new implemented error message - but it doesn't do it (at least not for the above function and all values -1.7...+1.7.

So there must still be something not ok in the SLV routine; it should in fact NEVER provide a 'solution' (which is none) whenever the function value in Z is not (at least nearly) zero - not even if the last 2 calculated argument values (which are in X and Y) are very close to each other.

You see, this SLV routine needs indeed some further improvements ...



Should be fixed now.

- Pauli

Possibly Related Threads...
Thread Author Replies Views Last Post
  [HP-Prime CAS] "Warning, ^ (Command) Is ambiguous on non square matrices"?? CompSystems 1 694 12-07-2013, 07:15 PM
Last Post: CompSystems
  HP Prime - most favorite command bluesun08 2 566 11-12-2013, 11:29 AM
Last Post: bluesun08
  hp prime - command syntax bluesun08 6 860 11-10-2013, 11:57 AM
Last Post: bluesun08
  HP PRIME: command to read the SERIAL ? Joseph Ec 9 1,908 11-01-2013, 12:43 AM
Last Post: Joe Horn
  Re: [WP34S] Flashing Issues Les Wright 22 2,438 10-30-2013, 02:16 PM
Last Post: Les Wright
  Connectivty Kit for HP Prime needs an "Import Program" Command Eddie W. Shore 3 648 10-23-2013, 03:37 PM
Last Post: Eddie W. Shore
  HP Prime MOUSE command SanS 3 548 10-15-2013, 12:15 PM
Last Post: Han
  HP-Prime: issues in entering expressions fhub 30 2,350 10-02-2013, 12:32 AM
Last Post: Tim Wessman
  [HP-Prime] randPoly command CompSystems 0 320 09-26-2013, 08:49 AM
Last Post: CompSystems
  [HP-Prime xCAS] BUG: string command =( CompSystems 6 685 09-10-2013, 06:38 PM
Last Post: CompSystems

Forum Jump: