HP Forums

Full Version: An equation that hp prime can't solve
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello everyone, I am back. I recently encountered a system of equations, hp prime not only can not solve the exact solution, even the numerical solution can not be solved.
Code:
f:=(λ,μ)->(λ^4+λ^3*μ^2+λ^2*μ^2+λ^2*μ+λ^2+λ*μ^4+λ*μ^2+3*λ*μ*sqrt(λ^4+4*λ^3*μ+4*λ^3+2*λ^2​*μ^2+4*λ^2*μ+2*λ^2+4*λ*μ^3+4*λ*μ^2+4*λ*μ+4*λ+μ^4+4*μ^3+2*μ^2+4*μ+1)+μ^3+μ)/(λ^3*μ+λ*μ^3+λ*μ);fsolve([(∂(f(x,y),x))=0,(∂(f(x,y),y))=0],[x,y])

But when x=1, y=1 is indeed a set of solutions to the equation.
In fact we can test it

Code:
simplify((∂(f(x,y),x))|x=1,y=1);simplify((∂(f(x,y),y))|x=1,y=1)

PHP Code:
Is this not a BUG


Looking forward to the first firmware release in 2019, I hope CAS will be updated to 1.51-29
(02-17-2019 06:14 AM)yangyongkang Wrote: [ -> ]
PHP Code:
Is this not a BUG

I would not jump to the conclusion that it is a "BUG". It is most likely the user's fault due to not understanding the calculator or not entering the input correctly.

I was able to solve this problem using my HP 50g, a calculator I know VERY well. I understand how it works and I know what tools to use. See the screenshot titled "Proof" to see that I actually solved it with my HP 50g.

(02-17-2019 06:14 AM)yangyongkang Wrote: [ -> ]Hello everyone, I am back. I recently encountered a system of equations, hp prime not only can not solve the exact solution, even the numerical solution can not be solved.

Now, I will help you on how to solve this with your HP Prime.

After playing around with this equation (what a pain to enter in), the problem most likely lies with using a function ( the f(x,y) part) with the differentiate command. The 50g spits out a symbolic answer when I use the DERIV command on the f(x,y). See pictures #1 & #2. But when I attempt this on Prime, I get something I do not understand. See picture #3. So try to derive the function and get a symbolic answer, like my 50g. Maybe then fsolve() will work.

Unfortunately for you, I cannot tell you exactly what to do to get the answer because I am not good at using the HP Prime. That being said, keep working on it and good luck!! Wink
fsolve works best if you give it a starting point. If:

PHP Code:
(f(λ,μ)) := (λ^4+λ^3*μ^2+λ^2*μ^2+λ^2*μ+λ^2+λ*μ^4+λ*μ^2+3*λ*μ*sqrt(λ^4+4*λ^3*μ+4*λ^3+2*λ^2*μ^2+4*λ^2*μ+2*λ^2+4*λ*μ^3+4*λ*μ^2+4*λ*μ+4*λ+μ^4+4*μ^3+2*μ^2+4*μ+1)+μ^3+μ)/(λ^3*μ+λ*μ^3+λ*μ);

dfx := (simplify((f(x,y),x)));

dfy := (simplify((f(x,y),y))); 

then fsolve({dfx = 0,dfy = 0},{x,y},{1.1,1.1}) returns {1.,1.}.

I gave up waiting for solve([dfx=0,dfy=0],[x,y]) to return an answer.

-road
Reference URL's