Download as pdf or txt
Download as pdf or txt
You are on page 1of 16

Numerical Analysis

by
Dr. Anita Pal
Assistant Professor
Department of Mathematics
National Institute of Technology Durgapur
Durgapur-713209
email: anita.buie@gmail.com

1
.

Chapter 4

Solution of Non-linear Equation

Module No. 2

Roots of a Polynomial Equation


......................................................................................

Derivation of all roots of a polynomial equation is a very important task. In many


applications of science and engineering all roots of a polynomial equations are needed
to solve a particular problem. For example, to find the poles, singularities, etc. of a
function, the zeros of the denominator (polynomial) are needed. The available analytic
methods are useful when the degree of the polynomial is at most four. So, numerical
methods are required to find the roots of the higher degree polynomial equations.
Fortunately, many direct and iterated numerical methods are developed to find all the
roots of a polynomial equation. In this module, two iterated methods, viz. Birge-Vieta
and Bairstow methods are discussed.

2.1 Roots of polynomial equations

Let Pn (x) be a polynomial in x of degree n. If a0 , a1 , . . . , an are coefficients of Pn (x),


then equation Pn (x) = 0 can be written in explicit form as

Pn (x) ≡ a0 xn + a1 xn−1 + · · · + an−1 x + an = 0. (2.1)

Here, we assumed that the coefficients a0 , a1 , . . . , an are real numbers.


A number ξ (may be real or complex) is a root of the polynomial equation Pn (x) = 0
if and only if Pn (ξ) = 0. That is, Pn (x) is exactly divisible by x − ξ. If Pn (x) is exactly
divisible by (x − ξ)k (k ≥ 1), but it is not divisible by (x − ξ)k+1 , then ξ is called a root
of multiplicity k. The roots of multiplicity k = 1 are called simple roots or single
roots.
From fundamental theorem of algebra, we know that every polynomial equation has a
root. More precisely, every polynomial equation Pn (x) = 0, (n ≥ 1) with any numerical
coefficients has exactly n, real or complex roots.
The roots of any polynomial equation are either real or complex. If the coefficients
of the equation are real and it has a complex root α + iβ of multiplicity k, then α − iβ
must be another complex root of the equation with multiplicity k.
Let

a0 xn + a1 xn−1 + · · · + an−1 x + an = 0, (2.2)

be a polynomial equation, where a0 , a1 , . . . , an are real coefficients. Also, let A =


1
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Roots of a Polynomial Equation

max{|a1 |, |a2 |, . . . , |an |} and B = max{|a0 |, |a1 |, . . . , |an−1 |}. Then the magnitude of a
1 A
root of the equation (2.2) lies between and 1 + .
1 + B/|an | |a0 |

The other methods are also available to find the upper bound of the positive roots of
the polynomial equation. Two such results are stated below:
Theorem 2.1 (Lagrange’s). If the coefficients of the polynomial

a0 xn + a1 xn−1 + · · · + an−1 x + an = 0

satisfy the conditions a0 > 0, a1 , a2 , . . . , am−1 ≥ 0, am < 0, for some m ≤ n, then the
p
upper bound of the positive roots of the equation is 1 + m B/a0 , where B is the greatest
of the absolute values of the negative coefficients of the polynomial.

Theorem 2.2 (Newton’s). If for x = c the polynomial

f (x) = a0 xn + a1 xn−1 + · · · + an−1 x + an

and its derivatives f 0 (x), f 00 (x), . . . assume positive values then c is the upper bound of
the positive roots of the equation f (x) = 0.

In the following sections, two iteration methods, viz. Birge-Vieta and Bairstow meth-
ods are discussed to find all the roots of a polynomial equation of degree n.

2.2 Birge-Vieta method

In Module 1 of this chapter, Newton-Raphson method is described to find a root of


an algebraic and transcendental equations. The rate of convergence of this method is
quadratic. So, Newton-Raphson method can be used to find a root of a polynomial
equation as polynomial equation is an algebraic equation. Birge-Vieta method is based
on the Newton-Raphson method.
Let ξ be a root of the polynomial equation Pn (x) = 0 (Pn (x) is a polynomial in x of
degree n). Then (x − ξ) is a factor of the polynomial Pn (x). Thus, the problem is to
find the root ξ. This root can be determined by Newton-Raphson method. Then Pn (x)
is divided by the factor (x − ξ) and obtained the quotient Qn−1 (x) of degree n − 1.
2
......................................................................................

Let the polynomial equation be

Pn (x) = xn + a1 xn−1 + a2 xn−2 + · · · + an−1 x + an = 0. (2.3)

Assume that Qn−1 (x) and R be the quotient and remainder when Pn (x) is divided
by the factor (x − ξ). Here, Qn−1 (x) is a polynomial of degree (n − 1), so it can be
written as

Qn−1 (x) = xn−1 + b1 xn−2 + b2 xn−3 + · · · + bn−2 x + bn−1 . (2.4)

Thus,
Pn (x) = (x − ξ)Qn−1 (x) + R. (2.5)

If ξ is an exact root of the equation Pn (x) = 0, then R must be zero. Thus, the value
of R depends on the accuracy of ξ. The Newton-Raphson method or any other method
be used to find the value of ξ starting from an initial guess x0 such that

R(ξ) = Pn (ξ) = 0. (2.6)

The Newton-Raphson iteration scheme for the equation Pn (x) = 0 is

Pn (xk )
xk+1 = xk − , k = 0, 1, 2, . . . . (2.7)
Pn0 (xk )
This method determines the approximate value of ξ, so for this ξ, R is not exactly 0,
but it is a small number.
Since Pn (x) is a polynomial, so it is differentiable everywhere. Also, the values of
Pn (xk ) and Pn0 (xk ) can be determined by synthetic division or any other method. To
find the polynomial Qn−1 (x) and R, comparing the coefficient of like powers of x on
both sides of the equation (2.5). Thus we get the following equations.

a1 = b1 − ξ b 1 = a1 + ξ
a2 = b2 − ξb1 b2 = a2 + ξb1
.. ..
. .
ak = bk − ξbk−1 bk = ak + ξbk−1
.. ..
. .
an = R − ξbn−1 R = an + ξbn−1
3
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Roots of a Polynomial Equation

From equation (2.5),

Pn (ξ) = R = bn (say). (2.8)

Thus,

bk = ak + ξbk−1 , k = 1, 2, . . . , n, with b0 = 1. (2.9)

Therefore, bn is the value of Pn .


To determine the value of Pn0 , the equation (2.5) is differentiated with respect to x,
i.e.

Pn0 (x) = (x − ξ)Q0n−1 (x) + Qn−1 (x).

That is,

Pn0 (ξ) = Qn−1 (ξ) = ξ n−1 + b1 ξ n−2 + · · · + bn−2 ξ + bn−1 . (2.10)

Again,

Pn0 (xi ) = xn−1


i + b1 xn−2
i + · · · + bn−2 xi + bn−1 . (2.11)

Thus, the evaluation of Pn0 (x) is same as Pn (x). Differentiating (2.9) with respect to
ξ, we get

dbk dbk−1
= bk−1 + ξ . (2.12)
dξ dξ

We denote
dbk
= ck−1 . (2.13)

Then the equation (2.12) reduces to

ck−1 = bk−1 + ξck−2

Therefore, the recurrence relation of ck is

ck = bk + ξck−1 , k = 1, 2, . . . , n − 1. (2.14)
4
......................................................................................

Now, from equation (2.8), we have

dR dbn
Pn0 (ξ) = = = cn−1 [using (2.13)].
dξ dξ

Hence, the iteration scheme (2.7) becomes

bn
xk+1 = xk − , k = 0, 1, 2, . . . . (2.15)
cn−1

This method is known as Birge-Vieta method.


The values of bk and ck are generally written in a tabular form shown in Table 2.1.

x0 1 a1 a2 · · · an−2 an−1 an
x0 x0 b1 · · · x0 bn−3 x0 bn−2 x0 bn−1
x0 1 b1 b2 · · · bn−2 bn−1 bn = R
x0 x0 c1 · · · x0 cn−3 x0 cn−2
1 c1 c2 · · · cn−2 cn−1 = Pn0 (x0 )
Table 2.1: Tabular form of b’s and c’s.

Example 2.1 Find all the roots of the polynomial equation x4 +x3 −8x2 −11x−3 = 0.

Solution. Let P4 (x) = x4 + x3 − 8x2 − 11x − 3 be the given polynomial. Also, let the
initial guess be x0 = −0.5.
First iteration for first root

–0.5 1 1 –8 –11 –3
–0.500000 –0.250000 4.125000 3.437500
–0.5 1 0.500000 –8.250000 –6.875000 0.437500 =b4 = P4 (x0 )
–0.500000 –0.000000 4.125000
1 0.000000 –8.250000 –2.750000=c3 = P40 (x0 )

Therefore,
b4 0.437500
x1 = x0 − = −0.500000 − = −0.340909.
c3 −2.750000
This is the first iterated value.

5
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Roots of a Polynomial Equation

Second iteration for first root

–0.340909 1 1 –8 –11 –3
–0.340909 –0.224690 2.803872 2.794135
–0.340909 1 0.659091 –8.224690 –8.196128 –0.205865=b4
–0.340909 –0.108471 2.840850
1 0.318182 –8.333161 –5.355278=c3

Then the second iterated root is


b4 −0.205865
x2 = x1 − = −0.340909 − = −0.379351.
c3 −5.355278
Third iteration for first root

–0.379351 1 1 –8 –11 –3
–0.379351 –0.235444 3.124121 2.987720
–0.379351 1 0.620649 –8.235444 –7.875879 –0.012280=b4
–0.379351 –0.091537 3.158846
1
0.241299 –8.326981 –4.717033=c3
b4 −0.012280
Therefore, x3 = x2 − = −0.379351 − = −0.381954.
c3 −4.717033

Fourth iteration for first root

–0.381954 1 1 –8 –11 –3
–0.381954 –0.236065 3.145798 2.999944
–0.381954 1 0.618046 –8.236065 –7.854202 –0.000056=b4
–0.381954 –0.090176 3.180241
1
0.236092 –8.326241 –4.673960=c3
b4 −0.000056
Then x4 = x3 − = −0.381954 − = −0.381966.
c3 −4.673960

Therefore, one root of the equation is −0.38197.


The reduce polynomial is x3 + 0.618034x2 − 8.236068x − 7.854102 = 0 (obtained from
the third row of the above table).
First iteration for second root
Let x0 = 1.0.
6
......................................................................................

1 1 0.618034 –8.236068 –7.854102


1.000000 1.618030 –6.618040
1 1 1.618030 –6.618040 –14.472139=b3
1.000000 2.618030
1 2.618030 –4.000010= c2

Therefore,
b3 −14.472139
x1 = x0 − = 1.000000 − = −2.618026.
c2 −4.000010
Second iteration for second root

–2.618026 1 0.618034 –8.236068 –7.854102


–2.618026 5.236043 7.854150
–2.618026 1 –1.999996 –3.000027 0.000050=b3
–2.618026 12.090104
1 –4.618022 9.090076= c2

The second iterated value is


b3 0.000050
x2 = x1 − = −2.618026 − = −2.618032.
c2 9.090076
It is seen that x = −2.61803 is another root. The next reduced equation is

x2 − 2.00000x − 3.00003 = 0.

Roots of this equation are x = 3.00001, 1.00000.


Hence, the roots of the given equation are −0.38197, −2.61803, 3.00001, 1.00000.

Note 2.1 The Birga-Vieta method is used to find all real roots of a polynomial equation.
But, the current form of this method is not applicable to find the complex roots. After
modification, this method may be used to find all roots (real or complex) of a polynomial
equation. Since the method is based on Newton-Raphson method, the rate of convergent
of this method is quadratic, as the rate of convergent of Newton-Raphson method is
quadratic.

7
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Roots of a Polynomial Equation

2.3 Bairstow method

This method is also an iterative method. In this method, a quadratic factor is ex-
tracted from the polynomial Pn (x) by iteration. As a by product the deflated polynomial
(the polynomial obtained by dividing Pn (x) by the quadratic factor) is also obtained. It
is well known that the determination of roots (real or complex) of a quadratic equation
is easy. Therefore, by extracting all quadratic factors one can determine all the roots of
a polynomial equation. This is the basic principle of Bairstow method.
Let the polynomial Pn (x) of degree n be

xn + a1 xn−1 + a2 xn−2 + · · · + an−1 x + an . (2.16)

Let x2 + px + q be a factor of the polynomial Pn (x), n > 2. When this polynomial is


divided by the factor x2 + px + q, then the quotient is a polynomial of degree (n − 2)
and remainder is a linear polynomial. Let the quotient and the remainder be denoted
by Qn−2 (x) and M x + N , where M and N are two constants.
Using this notation, Pn (x) can be written as
Pn (x) = (x2 + px + q)Qn−2 (x) + M x + N. (2.17)

The polynomial Qn−2 (x) is called deflated polynomial and let it be

Qn−2 (x) = xn−2 + b1 xn−3 + · · · + bn−3 x + bn−2 . (2.18)

It is obvious that the values of M and N depends on p and q. If x2 + px + q is an


exact factor of Pn (x), then the remainder M x + N , i.e. M and N must be zero. Thus
the main aim of Bairstow method is to find the values of p and q such that
M (p, q) = 0 and N (p, q) = 0. (2.19)

These are two non-linear equations in p and q and these equations can be solved by
Newton-Raphson method for two variables (discussed in Module 3 of this chapter).
Let (pT , qT ) be the exact values of p and q and ∆p, ∆q be the (errors) corrections to
p and q. Therefore,

pT = p + ∆p and qT = q + ∆q.
8
......................................................................................

Hence,

M (pT , qT ) = M (p + ∆p, q + ∆q) = 0 and N (pT , qT ) = N (p + ∆p, q + ∆q) = 0.

By Taylor’s series expansion, we get


∂M ∂M
M (p + ∆p, q + ∆q) = M (p, q) + ∆p + ∆q + ··· = 0
∂p ∂q
∂N ∂N
and N (p + ∆p, q + ∆q) = N (p, q) + ∆p + ∆q + · · · = 0.
∂p ∂q
All the derivatives are evaluated at the approximate value (p, q) of (pT , qT ). Neglect-
ing square and higher powers of ∆p and ∆q, as they are small, the above equations
become

∆pMp + ∆qMq = −M (2.20)


∆pNp + ∆qNq = −N. (2.21)

Therefore, the values of ∆p and ∆q are obtained by the formulae


M Nq − N Mq N Mp − M Np
∆p = − , ∆q = − . (2.22)
Mp Nq − Mq Np Mp Nq − Mq Np
It is expected that in this stage the values of ∆p and ∆q are either 0 or very small.
Now, the coefficients of the deflated polynomial Qn−2 (x) and the expressions for M
and N in terms of p and q are computed below.
From equation (2.17)

xn + a1 xn−1 + a2 xn−2 + · · · + an−1 x + an


= (x2 + px + q)(xn−2 + b1 xn−3 + · · · + bn−3 x + bn−2 ) + M x + N. (2.23)

Comparing both sides, we get

a1 = b1 + p b1 = a1 − p
a2 = b2 + pb1 + q b2 = a2 − pb1 − q
.. ..
. .
ak = bk + pbk−1 + qbk−2 bk = ak − pbk−1 − qbk−2 (2.24)
.. ..
. .
an−1 = M + pbn−2 + qbn−3 M = an−1 − pbn−2 − qbn−3
an = N + qbn−2 N = an − qbn−2 .
9
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Roots of a Polynomial Equation

In general,

bk = ak − pbk−1 − qbk−2 , k = 1, 2, . . . , n. (2.25)

The values of b0 and b−1 are taken as 1 and 0 respectively.


With this notation, the expressions for M and N are
M = bn−1 , N = bn + pbn−1 . (2.26)

Note that M and N depend on b’s. Differentiating the equation (2.25) with respect
to p and q to find the partial derivatives of M and N .
∂bk ∂bk−1 ∂bk−2 ∂b0 ∂b−1
= −bk−1 − p −q , = =0 (2.27)
∂p ∂p ∂p ∂p ∂p
∂bk ∂bk−1 ∂bk−2 ∂b0 ∂b−1
= −bk−2 − p −q , = =0 (2.28)
∂q ∂q ∂q ∂q ∂q
For simplification, we denote

∂bk
= −ck−1 , k = 1, 2, . . . , n (2.29)
∂p
∂bk
and = −ck−2 . (2.30)
∂q
With this notation, the equation (2.27) simplifies as
ck−1 = bk−1 − pck−2 − qck−3 . (2.31)

Also, the equations (2.28) becomes


ck−2 = bk−2 − pck−3 − qck−4 . (2.32)

Hence, the recurrence relation for ck is

ck = bk − pck−1 − qck−2 , k = 1, 2, . . . , n − 1 and c0 = 1, c−1 = 0. (2.33)

Therefore,
∂bn−1
Mp = = −cn−2
∂p
∂bn ∂bn−1
Np = +p + bn−1 = bn−1 − cn−1 − pcn−2
∂p ∂p
∂bn−1
Mq = = −cn−3
∂q
∂bn ∂bn−1
Nq = +p = −(cn−2 + pcn−3 ).
∂q ∂q
10
......................................................................................

From the equation (2.22), the explicit expressions for ∆p and ∆q, are obtained as
follows:
bn cn−3 − bn−1 cn−2
∆p = −
c2n−2
− cn−3 (cn−1 − bn−1 )
bn−1 (cn−1 − bn−1 ) − bn cn−2
∆q = − 2 . (2.34)
cn−2 − cn−3 (cn−1 − bn−1 )
Therefore, the improved values of p and q are p + ∆p and q + ∆q. Thus if p0 , q0 be
the initial guesses of p and q, then the first approximate values of p and q are

p1 = p0 + ∆p and q1 = q0 + ∆q. (2.35)

Table 2.2 is helpful to calculate the values of bk ’s and ck ’s, where p0 and q0 are taken
as initial values of p and q.

1 a1 a2 ··· ak ··· an−1 an


−p0 −p0 −p0 b1 ··· −p0 bk−1 ··· −p0 bn−2 −p0 bn−1
−q0 −q0 ··· −q0 bk−2 ··· −q0 bn−3 −q0 bn−2
1 b1 b2 ··· bk ··· bn−1 bn
−p0 −p0 −p0 c1 ··· −p0 ck−1 ··· −p0 cn−2
−q0 −q0 ··· −q0 ck−2 ··· −q0 cn−3
1 c1 c2 ··· ck ··· cn−1
Table 2.2: Tabular form of b’s and c’s.

The second approximate values p2 , q2 of p and q are determined from the equations:
p2 = p1 + ∆p, q2 = q1 + ∆q.
In general,
pk+1 = pk + ∆p, qk+1 = qk + ∆q, (2.36)

the values of ∆p and ∆q are calculated at p = pk and q = qk .


The iteration process to find the values of p and q will be terminated when both |∆p|
and |∆q| are very small.
The next quadratic factor can be obtained by similar process from the deflated poly-
nomial Qn−2 (x).
The values of ∆p and ∆q are obtained by applying Newton-Raphson method for two
variables case. Also, the rate of convergence of Newton-Raphson method is quadratic.
Hence, the rate of convergence of this method is quadratic.

11
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Roots of a Polynomial Equation

Example 2.2 Extract all the quadratic factors from the equation x4 + 2x3 + 3x2 + 4x +
1 = 0 by using Bairstow method and hence solve this equation.

Solution. Let the initial guess of p and q be p0 = 0.5 and q0 = 0.5.

First iteration

1 2.000000 3.000000 4.000000 1.000000


−0.500000 −0.500000 −0.750000 −0.875000 −1.187500
−0.500000 −0.500000 −0.750000 −0.875000
1 1.500000 1.750000 2.375000 −1.062500
−0.500000 −0.500000 −0.500000 −0.375000
−0.500000 −0.500000 −0.500000
1 1.000000 0.750000 1.500000
= c1 = c2 = c3

b4 c1 − b3 c2 b3 (c3 − b3 ) − b4 c2
∆p = − = 1.978261, ∆q = − = 0.891304
c22 − c1 (c3 − b3 ) c22 − c1 (c3 − b3 )

Therefore, p1 = p0 + ∆p = 2.478261, q1 = q0 + ∆q = 1.391304.

Second iteration

1.00000 4.00000 −7.00000 −22.00000 24.00000


−1.38095 −1.38095 −3.61678 11.11025 5.73794
2.57143 2.57143 6.73469 −20.68805
1.00000 2.61905 −8.04535 −4.15506 9.04989
−1.38095 −1.38095 −1.70975 9.92031
2.57143 2.57143 3.18367
1.00000 1.23810 −7.18367 8.94893

∆p = 0.52695, ∆q = −0.29857.
p2 = p1 + ∆p = 1.90790, q2 = q1 + ∆q = −2.86999.
12
......................................................................................

Third iteration

1 2.000000 3.000000 4.000000 1.000000


−2.478261 −2.478261 1.185256 −6.924140 5.597732
−1.391304 −1.391304 0.665407 −3.887237
1 −0.478261 2.793951 −2.258734 2.710495
−2.478261 −2.478261 7.327033 −21.634426
−1.391304 −1.391304 4.113422
1 −2.956522 8.729680 −19.779737

∆p = −0.479568, ∆q = −0.652031.
p3 = p2 + ∆p = 1.998693, q3 = q2 + ∆q = 0.739273.

Fourth iteration

1 2.000000 3.000000 4.000000 1.000000


−1.998693 −1.998693 −0.002613 −4.513276 1.027812
−0.739273 −0.739273 −0.000967 −1.669363
1 0.001307 2.258114 −0.514242 0.358449
−1.998693 −1.998693 3.992159 −11.014794
−0.739273 −0.739273 1.476613
1 −1.997385 5.511000 −10.052423

∆p = −0.187110, ∆q = −0.258799.
p4 = p3 + ∆p = 1.811583, q4 = q3 + ∆q = 0.480474.

Fifth iteration

1 2.000000 3.000000 4.000000 1.000000


−1.811583 −1.811583 −0.341334 −3.945975 0.066131
−0.480474 −0.480474 −0.090530 −1.046566
1 0.188417 2.178192 −0.036504 0.019565
−1.811583 −1.811583 2.940498 −8.402511
−0.480474 −0.480474 0.779889
1 −1.623165 4.638216 −7.659126

∆p = −0.015050, ∆q = −0.020515.
p5 = p4 + ∆p = 1.796533, q5 = q4 + ∆q = 0.459960.
13
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Roots of a Polynomial Equation

Sixth iteration

1 2.000000 3.000000 4.000000 1.000000


−1.796533 −1.796533 −0.365535 −3.906570 0.000282
−0.459960 −0.459960 −0.093587 −1.000184
1 0.203467 2.174505 −0.000157 0.000098
−1.796533 −1.796533 2.861996 −8.221908
−0.459960 −0.459960 0.732746
1 −1.593066 4.576541 −7.489319

∆p = −0.000062, ∆q = −0.000081.
p6 = p5 + ∆p = 1.796471, q6 = q5 + ∆q = 0.459879.
Note that, ∆p and ∆q are correct up to four decimal places. Thus p = 1.7965, q =
0.4599 correct up to four decimal places.
Therefore, a quadratic factor is x2 + 1.7965x + 0.4599 and the deflated polynomial is
Q2 (x) = P4 (x)/(x2 + 1.7965x + 0.4599) = x2 + 0.2035x + 2.1745.
Thus, P4 (x) = (x2 + 1.7965x + 0.4599)(x2 + 0.2035x + 2.1745).
Hence, the roots of the given equation are
−0.309212, −1.487258, (−0.1018, 1.4711), (−0.1018, −1.4711).

14

You might also like