Post Reply 
HP 11C real root finder [Newton Method]
01-14-2014, 08:56 PM
Post: #6
RE: HP 11C real root finder [Newton Method]
If you only want to solve polynomials with real coefficients Bairstow's Method can be used.
In a nutshell: instead of a root a quadratic factor is found in each iteration. To find the roots of this factor the classic formula is used.

Example:

\(x^3-3x^2-6x+8=0\)

First enter the coefficients of the polynomial. Always start with register 9:

1 STO 9
-3 STO .0
-6 STO .1
8 STO .2


Then specify the order of the polynomial with a loop-control value. It defines the registers you used for the coefficients:

9.012 STO 6


And now give an initial guess. Probably {1, 1} will do in all cases:

1 STO 7
STO 8


Start the program B:

GSB B


Now the coefficients of the quadratic factor can be found in registers 7 and 8:

RCL 7
1.000000

RCL 8
-2.000000


The coefficient of the first term is always 1. Thus the factor is \(x^2+x-2\).
Now we can solve this quadratic equation using program A:

1
RCL 7
RCL 8
GSB A

1.000000
X<>Y
-2.000000


Thus: \(x^2+x-2=(x-1)(x+2)\).

What is left? Let's have a look at it:

RCL 6
9.010

RCL 9
1.000000

RCL .0
-4.000000


This is a linear factor. Thus we end up with the following factorization: \(x^3-3x^2-6x+8=(x-1)(x+2)(x-4)\)
Therefore the solutions are: {1, -2, 4}


Example from Bunuel66's solution to the crossed ladders problem

\(C^4-30C^3+700C^2-21,000C+157,500=0\)

Enter the coefficients of the polynomial:

1 STO 9
-30 STO .0
700 STO .1
21,000 STO .2
157,500 STO .3


Specify the loop-control value:

9.013 STO 6


Use the initial guess {1, 1}:

1 STO 7
STO 8


Start the program:

GSB B


The coefficients of the quadratic factor are in registers 7 and 8:

RCL 7
-35.178025

RCL 8
248.596895


Solve this quadratic equation using program A:

1
RCL 7
RCL 8
GSB A

25.384938
X<>Y
9.793087


What about the rest?

RCL 6
9.011

RCL 9
1.000000

RCL .0
5.178025

RCL .1
633.555781


If we try to solve this quadratic equation we get an Error 0.
That's because we're trying to calculate the square root of a negative value.
However we can still get the desired result:

RCL 9
RCL .0
RCL .1
GSB B
Error 0

<-
CHS
626.852796

\(\sqrt{x}\)
25.037029

X<>Y
-2.589012

Thus the final list of solutions is:
  • 25.384938
  • 9.793087
  • -2.589012\(\pm\)25.037029i

Cheers
Thomas
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: HP 11C real root finder [Newton Method] - Thomas Klemm - 01-14-2014 08:56 PM



User(s) browsing this thread: 1 Guest(s)