HP Forums
Errors in CAS and Geometry - 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: Errors in CAS and Geometry (/thread-18959.html)



Errors in CAS and Geometry - Jan 11 - 10-14-2022 04:16 PM

I'd like to report any bugs in equation solving where LN (x) and LOG (x) appear. This applies to the CAS computing module.
Let me give you some examples:
1. Solve (x ^ 2 - 30 = LN (x - 2)). The equation has two solutions, the calculator gives only one solution, x = {5.59}. He doesn't find the second solution, x = 2.
2. Solve (x ^ 2 -6) = LN (x ^ 2 - 3)). There are 4 solutions and they were all given correctly: {-2.74, -1.75, 1.75, 2.74}. This is ok.
3. Solve (x ^ 2 - 30 = LOG (x-2)). There are 2 roots {2, 5.53}, but the calculator only gives one root {5.53}, the second is x = 2, it doesn't.
4. Solve (x ^ 2 - 20 = LOG (x ^ 2 -3). There are 4 roots {-4.61, -1.73, 1.73, 4.61}. The calculator only finds two {-4.61, 4.61}.
And now I want to show you similar errors occurring in the Geometry application.
1. I am looking for intersections for the functions y = x ^ 2 -10 and y = LN (x). There are two intersection points and both are shown. OKAY
2. I am looking for the intersection points for the functions y = x ^ 2 -10 and y = LN (x + 2). There are two intersection points, but the calculator finds only one.
3. I am looking for intercepts for the functions y = x ^ 2 -10 and y = LN (x ^ 2 - 2). There are 4 intersection points, but the calculator only finds 2 intersections
4. Similar errors occur for the LOG (x) function.
I think the above bugs will be fixed in the next update.[attachment=11250][attachment=11251][attachment=11252][attachment=11253][attachment=11254]


RE: Errors in CAS and Geometry - KeithB - 10-14-2022 04:29 PM

Have you tried solving (x ^ 2 - 30 = LN (x - 2)) when x = 2?


RE: Errors in CAS and Geometry - Jan 11 - 10-14-2022 04:43 PM

(10-14-2022 04:29 PM)KeithB Wrote:  Have you tried solving (x ^ 2 - 30 = LN (x - 2)) when x = 2?
Yes, I tried. Without success. This is a system error.


RE: Errors in CAS and Geometry - KeithB - 10-14-2022 07:20 PM

To be a bit less facetious, LN(x-2) when x = 2 is undefined.


RE: Errors in CAS and Geometry - Albert Chan - 10-14-2022 08:02 PM

Quote:1. Solve (x ^ 2 - 30 = LN (x - 2)).

Let x = 2+ε, solve for ε

CAS> solve(exp((2+ε)^2-30) = ε, ε)

{5.10908902817e−12, 3.59275599271}


RE: Errors in CAS and Geometry - klesl - 10-14-2022 08:06 PM

the result x = 2 is not solution, ln(0) is not defined
Plot x ^ 2 - 30 against LN (x - 2)
the 2nd equation has clearly 2 roots only


RE: Errors in CAS and Geometry - Jan 11 - 10-14-2022 08:06 PM

(10-14-2022 07:20 PM)KeithB Wrote:  To be a bit less facetious, LN(x-2) when x = 2 is undefined.
Indeed, at x = 2, the function LN (x-2) is discontinuous. So x must be greater than 2, e.g. = 2,0001. But there is such an intersection point and it can be assumed to be (2.0001, -26). So the calculator should show this point as a solution.


RE: Errors in CAS and Geometry - klesl - 10-14-2022 08:21 PM

for x=2.0001
x^2-30=-26
ln(x-2)=-9.21
-26 doesn't equal to -9.21

A little bit mathematics:
ln(x-2), where x is close to 2 can be rewritten as ln(d), d=x-2=1/10^n=ln(1)-ln(1/10^n)=0-ln(1)-ln(10^n)=0-0-n×ln(10)=-2.303n,
n is number of decimal places (order), e.g. x=2.0001 so n=4 and ln(2.0001-2)=-4*2.303=-9.21
Based on the calculation above the order is between 11 (-25.328) and 12 (-27.631) and with respect to the order are whole number only (you cannot have 11.5 decimal places) this solution clearly doesn't exists


RE: Errors in CAS and Geometry - Jan 11 - 10-14-2022 09:04 PM

(10-14-2022 08:21 PM)klesl Wrote:  for x=2.0001
x^2-30=-26
ln(x-2)=-9.21
-26 doesn't equal to -9.21

A little bit mathematics:
ln(x-2), where x is close to 2 can be rewritten as ln(d), d=x-2=1/10^n=ln(1)-ln(1/10^n)=0-ln(1)-ln(10^n)=0-0-n×ln(10)=-2.303n,
n is number of decimal places (order), e.g. x=2.0001 so n=4 and ln(2.0001-2)=-4*2.303=-9.21
Based on the calculation above the order is between 11 (-25.328) and 12 (-27.631) and with respect to the order are whole number only (you cannot have 11.5 decimal places) this solution clearly doesn't exists
There is a number that is a solution to this equation, and it is a number very close to 2, but not 2, obviously greater than 2 (that is, the domain of the logarithm). Well, let's count
(x ^ 2 - 30) I for x = 2.00000000001, f (x) = -26
LN (x -2) I for x = 2.00000000001. f (x) = -25.329.
So you can take the number x = 2.00000000001 as the second root of this equation.


RE: Errors in CAS and Geometry - KeithB - 10-15-2022 01:34 PM

A CAS is a mathematician, not an engineer. 8^)
2.00000000001 is not 2.


RE: Errors in CAS and Geometry - ijabbott - 10-15-2022 05:43 PM

(10-15-2022 01:34 PM)KeithB Wrote:  A CAS is a mathematician, not an engineer. 8^)
2.00000000001 is not 2.

The actual root will be irrational, so any root shown by the calculator will not be the actual root. The problem in this case is that only one of the two representable numbers on either side of the actual root lies within the domain of the function.


RE: Errors in CAS and Geometry - mfleming - 10-15-2022 10:00 PM

(10-15-2022 01:34 PM)KeithB Wrote:  A CAS is a mathematician, not an engineer. 8^)
2.00000000001 is not 2.
Yup! I get it Smile


RE: Errors in CAS and Geometry - Jan 11 - 06-19-2023 06:54 PM

These errors are still there. Update 2.1.14730 (2023 04 13) did not remove them. I hope that the next update announced for the summer will change that.


RE: Errors in CAS and Geometry - StephenG1CMZ - 06-19-2023 08:06 PM

Where was that update announced please?


RE: Errors in CAS and Geometry - Liamtoh Resu - 06-19-2023 08:33 PM

Check this url:

https://hpcalcs.com/download/

It's a relatively new link.


RE: Errors in CAS and Geometry - StephenG1CMZ - 06-19-2023 10:22 PM

I'm not sure "summer" has reached the UK yet Sad

I'm not seeing anything since April in that URL (and no Android Pro app).