You are here:

Advanced Math/Root-Finding algorithm

Advertisement


Question
Dear Ahmed,

  I have a some functions that I am trying to find their root quickly and
efficiently.  I can't seem to find a root-finding algorithm that is both fast
and stable enough.  The Newton-Raphson method is unstable with these functions, because if its nature, while bisection is not quite fast enough. The
following function is an approximation of the functions' basic nature:

  f(x) = {
    
    1200000000000000 * 2.32 *
    (2*(0.945*x+0.426)) * ((0.945*x+0.426)-0.9) + 7504272000000.28

    when x <= 1, or

    1000000+1004.81955188*1.0000479385*(x-1)

         when x > 1
    
     }

  where

  0 <= x <= 2

  the root of f(x) is where x = 1
  (the approximation may not have a root of exactly 1)

  f(x) = function to find root of

  (Note that the real functions do not have exact parabolas, or
  exact lines, but they are very similar).

  I need a function that will perform this operation more efficiently and
quickly than bisection.  For instance, if I iterate up to 6 or 7 decimal places
using bisection, it will take around 35 evaluations of f(x); I need something
to cut that number down to around 20.


Thanks for all help and consideration,

  Grant Davis

Answer
Hi Grant,
I can't really understand your function but i would tell you this.
The Bisection method could at times be inefficient due to its "brute force" nature and in situations like this we could make use of the False-Position method and see what happens.
The Newton-Raphson method quicker but could be unstable maybe due to derivatives of these functions or the rate of convergence may be slow. You can therefore try out the Secant method and again see what happens.
Unfortunately, i am not able to give you the algorithms myself but you would do well to examine them where you can find them.
Here they are again; False-Position method and the Secant method.
I really hope you find these helpful.
Regards.

Advanced Math

All Answers


Answers by Expert:


Ask Experts

Volunteer


Ahmed Salami

Expertise

I can provide good answers to questions dealing in almost all of mathematics especially from A`Level downwards. I can as well help a good deal in Physics with most emphasis directed towards mechanics.

Experience

An engineering graduate. I have been doing maths and physics all my life.

©2012 About.com, a part of The New York Times Company. All rights reserved.