HP Forums
Fireworks while trying to solve system of equations - Printable Version

+- HP Forums (https://www.hpmuseum.org/forum)
+-- Forum: HP Calculators (and very old HP Computers) (/forum-3.html)
+--- Forum: HP Prime (/forum-5.html)
+--- Thread: Fireworks while trying to solve system of equations (/thread-17198.html)



Fireworks while trying to solve system of equations - dah145 - 07-02-2021 05:22 PM

Trying to solve this system of non linear equations makes my HP Prime display some nice fireworks:

solve([z^3=y^2*x,sqrt(x)=log(3*z^2),5*z*x=y^x],[x,y,z])

It also crashes the virtual calculator on PC.


RE: Fireworks while trying to solve system of equations - Albert Chan - 07-03-2021 12:35 AM

Quote:solve([z^3=y^2*x,sqrt(x)=log(3*z^2),5*z*x=y^x],[x,y,z])

This crash on XCas as well.

We can simplify system of equations into 1 equation.
For real solutions, equating y:

CAS> z := sqrt(exp(sqrt(x))/3)
CAS> fsolve(sqrt(z^3/x) = (5*z*x)^(1/x), x)

[0.281669416538, 11.005909666]


RE: Fireworks while trying to solve system of equations - dah145 - 07-03-2021 07:20 PM

(07-03-2021 12:35 AM)Albert Chan Wrote:  
Quote:solve([z^3=y^2*x,sqrt(x)=log(3*z^2),5*z*x=y^x],[x,y,z])

This crash on XCas as well.

We can simplify system of equations into 1 equation.
For real solutions, equating y:

CAS> z := sqrt(exp(sqrt(x))/3)
CAS> fsolve(sqrt(z^3/x) = (5*z*x)^(1/x), x)

[0.281669416538, 11.005909666]

I was testing out some equations I found in different places, I got that particular system from here: https://www.youtube.com/watch?v=OUO1P5ZgH2s

Thank you for your input.


RE: Fireworks while trying to solve system of equations - Albert Chan - 07-03-2021 08:25 PM

(07-03-2021 07:20 PM)dah145 Wrote:  I was testing out some equations I found in different places, I got that particular system from here: https://www.youtube.com/watch?v=OUO1P5ZgH2s

The video assumed log() is really log10().
log(x) vs ln(x) — The curse of scientific computing

HP Prime home mode, both log and LOG meant log10.
CAS mode have different meanings (log = ln, LOG = log10, same as XCAS)

CAS> fsolve([z^3=y^2*x,sqrt(x)=log(3*z^2),5*z*x=y^x],[x,y,z]=[1,1,1])

[0.281669416538, 1.23071511956, 0.75280920719]

CAS> fsolve([z^3=y^2*x,sqrt(x)=LOG(3*z^2),5*z*x=y^x],[x,y,z]=[1,1,1])

[0.235667688071, 2.0897828558, 1.00964210847]


RE: Fireworks while trying to solve system of equations - dah145 - 07-04-2021 01:51 AM

(07-03-2021 08:25 PM)Albert Chan Wrote:  
(07-03-2021 07:20 PM)dah145 Wrote:  I was testing out some equations I found in different places, I got that particular system from here: https://www.youtube.com/watch?v=OUO1P5ZgH2s

The video assumed log() is really log10().
log(x) vs ln(x) — The curse of scientific computing

HP Prime home mode, both log and LOG meant log10.
CAS mode have different meanings (log = ln, LOG = log10, same as XCAS)

CAS> fsolve([z^3=y^2*x,sqrt(x)=log(3*z^2),5*z*x=y^x],[x,y,z]=[1,1,1])

[0.281669416538, 1.23071511956, 0.75280920719]

CAS> fsolve([z^3=y^2*x,sqrt(x)=LOG(3*z^2),5*z*x=y^x],[x,y,z]=[1,1,1])

[0.235667688071, 2.0897828558, 1.00964210847]

Duly noted, thanks.