|Casio 115 and solvers [long]|
Message #10 Posted by Crawl on 25 Oct 2004, 8:36 p.m.,
in response to message #9 by Norris
>-- The 115 has an equation solver, but I believe that it
>only handles cubic and quadratic equations. It is not
>nearly as versatile as the solver in the 33S.
The quadratic and cubic solvers can give imaginary and real roots. But it also has a general solver that can find a real root to (virtually) any equation with something like Newton's method.
Actually, virtually *any* current 2-line algebraic calculator with an "ANS" memory key can fairly easily find roots. Just enter any number as a seed, hit equals, then type "ANS - f(ANS)/f'(ANS)", (with f and f' being the function you're zeroing and its derivative) and hit "=" over and over to iterate. (This could be used, for example, with the TI-30XII, which doesn't have a solver)
But the 115 does it better, since you don't need to find the derivative, and it iterates automatically, without need to hit "=" over and over.
BUT, the 115 has an overlooked feature that I have used to solve 2 variable equations with Newton's method!
It's based on the line copy feature. It's possible to copy several commands to one line, and then repeatedly step through all of them by hitting "=" over and over. The example the manual gives makes this seem like a completely useless feature, until you realize the lines can both make use of variables and update them.
It's not that great compared to calculators that can *really* program, and this method only works for simple cases (there's something like a 70 keystroke limit). But maybe some calculator junkies would be interested nevertheless.
As an example, I once tried to solve the complex equation Z = exp(Z), or (x + y i) = exp(x)(cos(y) + isin(y)), or
x - exp(x)cos(y) = 0 = a y - exp(x)sin(y) = 0 = b
So, Newton's method would involve
[da/dx da/dy] [-dx]
[db/dx db/dy] [-dy]
It turns out for this example, da/dx = db/dy, da/dy = -db/dx. To store da/dx, I used the variable "C", and for da/dy I used "D".
So, this is how you type in the problem.
2 -> X
2 -> Y [Arbitrary seeds]
X-eXcosY -> A
Y-eXsinY -> B
eXsinY -> D
X + (BD - AC)/(C2 + D2 -> X
Y - (CB + DA)/ (C2 + D2 -> Y [Cramer's rule]
After this, you hit "up" enough times to take you to the first non-seed line ( X-eXcosY -> A ) and hit copy. Then hitting "=" over and over iterates. This sure beats typing in those formulas over and over for every step, and it converges pretty quickly, too.
You can also use this sort of trick with this calculator to, for example, making adding series easier.