# Double root of equation with Newton Raphson

## Homework Statement

Find a double root of the equation ## f(x)= x^3+15.87x+24.34 ## correct to 3 decimal places.

## Homework Equations

By Newton Raphson's Formula,
## x_{n+1}=x_n + \frac{f(x_n)}{f'(x_n)} ##
##f'(x)=3x^2+15.87 ##

## The Attempt at a Solution

Does a double root means to find two roots or a root which is repeated two times?
I checked analytically with my calculator and this equation has 1 real root and 2 complex roots.
So how to proceed?

Related Calculus and Beyond Homework Help News on Phys.org
S.G. Janssens
Does a double root means to find two roots or a root which is repeated two times?
The latter. More generally, if ##f: \mathbb{R} \to \mathbb{R}## is not a polynomial but still a smooth function, then ##x_0## is called a root of order ##n \ge 1## if all coefficients of orders strictly smaller than ##n## vanish in a Taylor expansion of ##f## around ##x_0## while the ##n##th order coefficient itself is non-zero.
I checked analytically with my calculator and this equation has 1 real root and 2 complex roots.
So how to proceed?
I agree with you and don't see any double roots here.

Raghav Gupta
The latter. More generally, if ##f: \mathbb{R} \to \mathbb{R}## is not a polynomial but still a smooth function, then ##x_0## is called a root of order ##n \ge 1## if all coefficients of orders strictly smaller than ##n## vanish in a Taylor expansion of ##f## around ##x_0## while the ##n##th order coefficient itself is non-zero.

I agree with you and don't see any double roots here.
But suppose we don't know analytically before and we apply this formula,
## x_{n+1}=x_n +2 \frac{f(x_n)}{f'(x_n)} ##
Since multiplicity is 2.
What we can infer from that?
Eventually it will also give a root.
How many iterations to do and what initial guess value to take?

S.G. Janssens
But suppose we don't know analytically before and we apply this formula,
##x_{n+1}=x_n +2 \frac{f(x_n)}{f'(x_n)}##
Since multiplicity is 2.
What we can infer from that?
Eventually it will also give a root.
How many iterations to do and what initial guess value to take
When you start "Newton" close to a root that is not simple, you are going to run into trouble because ##f'(x_0) = 0##. I don't understand why you would put a "2" in front of the quotient, this is not going to help. "Newton" can only be used when ##f## is regular at ##x_0##. Incidentally, you got a sign incorrect, it should be
$$x_{n+1}=x_n - \frac{f(x_n)}{f'(x_n)}$$
But in any case, for your function there are no double roots and using Newton you will only be able to find the one real root.

Ray Vickson
Homework Helper
Dearly Missed
But suppose we don't know analytically before and we apply this formula,
## x_{n+1}=x_n +2 \frac{f(x_n)}{f'(x_n)} ##
Since multiplicity is 2.
What we can infer from that?
Eventually it will also give a root.
How many iterations to do and what initial guess value to take?
NO! You cannot just modify Newton-Raphson like you have done. The fact is that Newton-Raphson will fail in the case of a root of multiplicity > 1 (double root, triple root, etc). Because of roundoff errors and other finite-wordlength arithmetical errors, it will also be unreliable (or fail) if the root is not double, but if there are two separate roots "very close together". Good numerical schemes must build in safeguards against such difficulties.

Anyway, Newton-Raphson works perfectly well in this example, because there are no double roots.

Last edited:
SammyS
Staff Emeritus
Homework Helper
Gold Member

## Homework Statement

Find a double root of the equation ## f(x)= x^3+15.87x+24.34 ## correct to 3 decimal places.

## Homework Equations

By Newton Raphson's Formula,
## x_{n+1}=x_n + \frac{f(x_n)}{f'(x_n)} ##
##f'(x)=3x^2+15.87 ##

## The Attempt at a Solution

Does a double root means to find two roots or a root which is repeated two times?
I checked analytically with my calculator and this equation has 1 real root and 2 complex roots.
So how to proceed?
I used Wolfram Alpha to graph the function.

Clearly there is only one real root. Of course this is apparent if one considers the first derivative, which is positive definite.

Changing the sign of the linear term gives ##\ x^3-15.87x+24.34 \ ##, which still has only one real root, but does have a minimum of ≈ 0.006 .

Finally, subtracting 0.006 gives the function ##\ g(x)=x^3-15.87x+24.334 \ ##. It appears that g(x) has two roots, one of which is a double root.

Maybe there are two typos in the posted problem.

(Ray makes a good point in the following post.)

Last edited:
Ray Vickson
Homework Helper
Dearly Missed
I used Wolfram Alpha to graph the function.

Clearly there is only one real root. Of course this is apparent if one considers the first derivative, which is positive definite.

Changing the sign of the linear term gives ##\ x^3-15.87x+24.34 \ ##, which still has only one real root, but does have a minimum of ≈ 0.006 .

Finally, subtracting 0.006 gives the function ##\ g(x)=x^3-15.87x+24.334 \ ##. It appears that g(x) has two roots, one of which is a double root.

Maybe there are two typos in the posted problem.
This root-counting is apparent even without plotting. For x > 0 there are no roots of p(x) (as you have pointed out) because all terms are > 0. For x < 0 there is a single root (as determined, for example, by Descarte's Rule of signs, applied to q(x) = p(-x).

SammyS