07-30-2019, 01:10 PM
Program use for Equation Solving solution of f(x)=0
This program can be use for three type of solvers
[A] Bisection Method use Two Guess X1 [ENTER] X2
[B] Secant Method use Two Guess X1 [ENTER] X2
[C] Newton Method Use One Guess
The accuracy result is based on you decimal setting. FIX 0 - 9
Program is credit to J T Patterson who make this possible.
More information at his page at: http://www.jepspectro.com/htmDoc/BisecnewtP.htm
--------------------------------------------
Example:
To solve for X^X = 12345
Put f(x) = 0 routine at [LBL] E
LN
LSTx
x
RCL 6 // use Storage Register 6 for 12345
LN
-
RTN
Steps to run solver: USER mode and FIX 5
12345 STO 6
4 ENTER 6 [A] display 5.51659
Answer: X = 5.51659 using guess X1_4 and X2_6
---------------------------------------------
Program:
Gamo
This program can be use for three type of solvers
[A] Bisection Method use Two Guess X1 [ENTER] X2
[B] Secant Method use Two Guess X1 [ENTER] X2
[C] Newton Method Use One Guess
The accuracy result is based on you decimal setting. FIX 0 - 9
Program is credit to J T Patterson who make this possible.
More information at his page at: http://www.jepspectro.com/htmDoc/BisecnewtP.htm
--------------------------------------------
Example:
To solve for X^X = 12345
Put f(x) = 0 routine at [LBL] E
LN
LSTx
x
RCL 6 // use Storage Register 6 for 12345
LN
-
RTN
Steps to run solver: USER mode and FIX 5
12345 STO 6
4 ENTER 6 [A] display 5.51659
Answer: X = 5.51659 using guess X1_4 and X2_6
---------------------------------------------
Program:
Code:
LBL A // Bisection
STO 0
Rv
STO 1
LBL 1
SF1
RCL 0
GSB E
STO 3
RCL 1
RCL 0
+
2
÷
STO 2
GSB E
STO 4
RCL 3
x
X<0
GSB 3
F1
GSB 2
RCL 4
RND
X≠0
GTO 1
RCL 2
RTN
LBL2
RCL 2
STO 0
RTN
LBL 3
RCL 2
STO 1
CF1
RTN
------------
LBL B // Secant
STO 0
Rv
STO 1
RAN#
STO 3
LBL 4
RCL 0
RCL 1
-
STO 2
RCL 1
GSB E
STO 4
RCL 1
RCL 4
RCL 2
x
RCL 3
RCL 4
-
X=0
RAN#
÷
-
STO 5
RCL 1
STO 0
RCL 4
STO 3
RCL 5
STO 1
RCL 4
RND
X≠0
GTO 4
RCL 1
RTN
-----------
LBL C // Newton
STO 1
LBL 5
RCL 1
GSB E
STO 4
RCL 1
X=0
e^x
EEX
4
÷
STO 2
RCL 1
+
GSB E
RCL 4
-
RCL 2
÷
RCL 4
X<>Y
÷
STO-1 // Store Arithmetic Subtraction
RCL 4
RND
X≠0
GTO 5
RCL 1
RTN
--------
LBL D // Result Answer
RCL 1
RTN
-------
LBL E // f(x)
.
.
.
.
.
.
RTN
Gamo