[comp.lang.pascal] Numerical Methods for Poynomial Root Finding?

blombardi@x102c.ess.harris.com (Bob Lombardi 44139) (01/12/91)

Greetings,

Now that I've decided to buy Borland's Turbo Pascal Numerical Methods
Toolbox, I find that they have discontinued the product.  (I have noticed
this phenomenon before, and it indeed is a law of nature, derived from 
electro-weak theory.) :):)

Does anyone have it that would like to sell it?

If not, can anyone point me to a reference that explains the Laguerre
algorithm that they use, so that I can write my own?  The Laguerre 
algorithm finds all roots of polynomials from entered coefficients.  
I have what I thought was a good collection of post-calculus math books,
but none have anything by this name.  

Lacking that (I get three strikes, don't I?) can anyone refer me to 
source code in Pascal, BASIC, or FORTRAN that finds the roots of 
polynomials?  I can usually translate the other two languages into TP
if I get code in them. 

Since I've posted this to several groups, I'd appreciate reply by email
to save net bandwidth. 



Thanks,
Bob



Bob Lombardi WB4EHS     >>>>>>> Internet: blombardi@x102c.ess.harris.com
M/S 102-4826, Harris Corp GASD, P.O. Box 94000, Melbourne, FL 32902   
Hobbies:  ********  on hold thanks to being a gradual student in EE ******
aspiring classical pianist.   Professional: electrical engineer, writer.

price@helios.unl.edu (Chad Price) (01/13/91)

blombardi@x102c.ess.harris.com (Bob Lombardi 44139) writes:


>If not, can anyone point me to a reference that explains the Laguerre
>algorithm that they use, so that I can write my own?  The Laguerre 
>algorithm finds all roots of polynomials from entered coefficients.  
>I have what I thought was a good collection of post-calculus math books,
>but none have anything by this name.  

See page 279 of Numerical Recipes in C by Press,Flannery,Teukolsky, and
Vetterlingg (1988, Cambridge Univ Press) for explanation and source
code. There is also a Fortran version of the book.

chad price
price@fergvax.unl.edu

oze3@quads.uchicago.edu (james daniel ozeran) (01/13/91)

In article <price.663718555@helios> price@helios.unl.edu (Chad Price) writes:
>
>See page 279 of Numerical Recipes in C by Press,Flannery,Teukolsky, and
>Vetterlingg (1988, Cambridge Univ Press) for explanation and source
>code. There is also a Fortran version of the book.
>
There's also a Pascal version of the book with attendant coding
examples.

					D. Ozeran

--
J. Daniel Ozeran	   |	Depts. of Biochemistry and
oze3@midway.uchicago.edu   |	Molecular Biology and of
jozeran@biovax.uchicago.edu|	Pediatrics
			   |	University of Chicago

rcollins@altos86.Altos.COM (Robert Collins) (01/15/91)

In article <5231@trantor.harris-atd.com> blombardi@x102c.ess.harris.com (Bob Lombardi 44139) writes:
>
>Lacking that (I get three strikes, don't I?) can anyone refer me to 
>source code in Pascal, BASIC, or FORTRAN that finds the roots of 
>polynomials?  I can usually translate the other two languages into TP
>if I get code in them. 
>

I'm not familiar with the algortithm you mentioned, but I programmed a
polynomial ROOT algorithm using BAIRSTOW's method in 8087 assembler.
It's short, and most definitely fast -- some 28X faster than compiled
QUICK-BASIC.  BAIRSTOW's method uses partial derivatives to force
convergence of polynomial roots.  It finds all real and complex roots.
Each root of a 7th degree polynomial can usually be solved in less than
10 iterations to an accuracy of 1E-6.  I wrote the assember to interface
to (most) any high-level language, using any memory model size (through
changing compile-time switches).  So I would think this algorithm could
be interfaced to Turbo-Pascal...though I have never tried it.
If memory serves me correctly, the algorithm has tunable parameters. 
For example, the size of the polynomial can be variable -- at run time,
the convergence factor is also tunable, but only at compile-time.

If interested, I'd be happy to send anybody a copy of the source code.

-- 
"Worship the Lord your God, and serve him only."  Mat. 4:10
Robert Collins                 UUCP:  ...!sun!altos86!rcollins
HOME:  (408) 225-8002
WORK:  (408) 432-6200 x4356