SECANT METHOD
by Daniel Wedge
*** MORE GAMES AND PROGRAMS FOR CASIO CALCULATORS AT ***
******** http://www.student.uwa.edu.au/~wedgey *********
This is a simple program which will determine the x values
for which a function equals zero. You need to enter the function
which is equal to zero, and assign it to a function memory (below).
You will also need two guesses of the intersection point.
The program will exit when it finds two consecutive identical answers,
this is to prevent divide by zero errors.
You need to make sure that your function is equal to zero.
e.g. 2X + ln X - 2 = 0
NOT 2X + ln X = 2
If you can't make something equal to zero, then you probably
shouldn't have the need to do this kind of stuff!
To use function memories, press shift+F-MEM (usually shift+zero)
and for f1, press fn+1. You must use the variable X in the formula.
SYMBOLS USED:
@ display symbol (triangle)
-> assign key (arrow)
f1 function memory 1 (above)
SIZE: 129 bytes
THE CODE:
'SECANT METHOD
"FORMULA => f1"? -> X
"X0"? -> B
"X1"? -> A
"ITERATIONS:"
Lbl 0
A -> X
f1 -> U
B -> X
f1 -> U
U=V => Goto 1
A-U(A-B)/(U-V) -> C@
A -> B
C -> A
Goto 0
Lbl 1
"FINISHED"