HP Forums

Full Version: Non-linear system of eqtns
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Dear friends,

WOuld you be kind enough as to teach me how to solve systems of equations like this one and larger using the Prime?

z*y - x^2 + y = -53
x^2 + y^2 - z = 47
x*y - x + z = -11

initial guess would be {x,y,z}={1,5,0}

Thank you
purge(x,y,z);
eq1:=z*y - x^2 + y = -53;
eq2:=x^2 + y^2 - z = 47;
eq3:=x*y - x + z = -11;
soln:=fsolve([eq1,eq2,eq3],[x,y,z]=[1,5,0]);

Now check your answer:

subst(eq1,[x,y,z]=soln);
subst(eq2,[x,y,z]=soln);
subst(eq3,[x,y,z]=soln);

In each of these three cases, the left hand side should equal the right hand side (or be very close).

Finally, delete the variable 'soln' and the three equations (if you no longer need them):

purge(soln,eq1,eq2,eq3);

EDIT: forgot to mention this should be done in CAS view.
or simply use the Solve App ...
(01-27-2015 09:04 PM)Maro Wrote: [ -> ]or simply use the Solve App ...

The solve app works just as well. Do keep in mind that it requires you to restrict your variables to either the built-in global variables, or variables which you have created yourself prior to running the app. It also limits you to 10 equations.

If your system is simple, use the solve app. If you have more than 10 equations, then use fsolve in the CAS view.
So simple. Thank you very much. I just ordered mine online.
Reference URL's