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

NonlinearEquations

3.1 Introduction
In the previouschapterwe dealtwith'linear'equationswhich did not involve powersof
'nonlinear'
the unknowns. A common form of equations which frequently arises in
practice does contain such powers, for example

x 1 3* 2 x r x 2 * xr2:4
( 3l )
x1*4x1x2*3xr2:7

would be a pair o[nonlinear equationssatisfiedby variouscombinationsof xt and xr.


In the simplest situation, we might have a single nonlinear equation, such as

y: f(x):x3-x- 1:0 (3.2)

A graphicalinterpretationhelps us to understandthe nature of the solutionsfor


I
h x whichsatisfyeq.3.2. x is shownin Fig.3.1.Where/(x)intersects
A plot of f(x) versus
l theline/:0 is clearlya solutionof the equation,oftencalleda'root',whichin thiscase
h a s t h e v a l u ex : 1 . 3 2 4 5 .
I Note that we could also write eq. 3.2 as

Y:s6):x3-x:1 (3.3)
and look for the intersectionof 9(x) with the line y: I as a solution of the equation, also
1; shown in the figure.
I Since we now knowthat x::1.324is a solution, we can factorise/(x) to yield
i (3.4)
f ( x ) = ( x - 1 . 3 2 4 ) ( x z+ 1 . 3 2 4 x + 0 . 7 5 5 ) : 6
Taking the roots of the quadratic equation in eq. 3.4, we arrive at solutions

- r.324t
x= (3.5)

showingthat the remainingtwo roots are imaginaryones.


It is immediatelyapparentthat finding solutionsto generalsets of nonlinear
equationswill be quite a formidablenumericaltask.As in the last chapter,wherewe
said that many physicalsystemsproduceddiagonallydominant and/or symmetric
systemsof linearequations,it is fortunatethat in manyphysicalsituationswhichgive
62
N O N L I N E A RE O U A T I O N S

1.0

t<- Rnnl

Fig. 3.1 Rootof .f(x): x3- x - I :0 obtainedgraphically

riseto nonlinearsetsof equations,the natureof the problemlimits the possiblevalues


that the rootsmay have.For example,we may know in advancethat all the roots must
be real, or even that they must all be real and positive.In this chapter we shall
concentrate on theselimitedproblems.
C H A P T E R3

We shali also see that methods for solving nonlinear equations are intrinsically
iterative in character.Referringto Fig. 3.1, it should be clear that such an iterative
processmight depend strongly on the quality of an initial guessedsolution. For
example,a guessof x : I or x :2 in that casemight have much more chanceof success
t h a n a g u e s so f x : - 1 0 0o r x : * 1 0 0 .

F2Q) Fr ( x l

tr
r(x)

Fig. 3.2 Different choices of x:F(x) in eq. 3.7

i -
N O N L I N E A RE O U A T I O N S

3.2 lterative substitution


A simple iterative process is to replace an equation like eq. 3.2 which had the form

f(x):x' -x- 1:o (3 2)


b y a n e q u i v a l e n te q u a t i o n

x: F(x) (3.6)

The iterativeproc€ssproceedsby a guessbeingmadefor x, substitutionof thisguesson


the right-handsideof eq. 3.6,and comparisonof the resultwith the guessedx. In the
unlikelyeventth3t e.rua!ityresults,
thesolutionhasbeenfound.[f not, the newF(x)is
assumedto be a betterestimateof x and the proc€ssis repeated.
An immediatedilemmais that thereis no singlewayof determiningF(x).In thecase
of eq. 3.2, we could write

x:Fr(x):x3-l (a)

I
x:F:(x): . . (b) (3.7)
x-- I

x:Fs(x): rJr+l (c)


When theseare plotted, as in Fig. 3.2,further difficulties are apparent. In each casethe
root is correctly given by the intersectionof y:f'(x) with.V:x. The function F3(x),
however, has no real value for x < - 1.0 and the function Fr(x) has singular points at
x: *1.0. It can also be seen that Ft(x) and F2(x) are changing very rapidly in the
region of the root (x= 1.3245)in contrastto F3(x)which is changingvery slowly. In fact
we shall seethat the simple iterativesubstitutionmethodjust describedwill only yield
a correct result if eq. 3.7(c)is used with a starting guess of x> -1.0. In order to
demonstratethis, we use the simple program listed as Program 3.1.

Program 3.1. Simple iteration method for a nonlinearequation


The meanings of the quantities used in the program are as follows

X0 Starting guess for x


'Tolerance', i.e. relative change in x in consecutiveiterations
TOL
ITS Maximum number of iterations allowed
Xl New value of x: F(x)
ITERS Current number of iterations
ICON Flag which is set to 1 by subroutine cHECK if convergenceachieved

The program expectsF(x) to be supplied by the user as a FoRTRAN FUNCTION. For example,
the function F3(x) is generated as shown at the end of the program in ruNcttoN F using the
identity

j6+1:exp[]log"(x+1)l (3.8)
The program merely reads a starting value xs, and calculatesa new value x1 : f(xo). If x1 is close
66 CHAPTER 3

PROGRAM P31
C
c PROGRAM3.I ITERATTVE SUBSTITUTION FOR SINGLE ROOT

READ (5,*) X0,TOL,TTS


WRITE(6, *) ( | **********a***** SIMPLE ITERATION ************** t
)
wRrTE(6,*)
WRITE(6,*) ('INTTIAL VALUE')
wRrTE (6,100) Xo
WRITE(6, *)
ITERS = O
ICON = o
r X1 = F(Xo)
C A L L C H E C K( X ] . , X O , T O L , I C O N )
ITERS=ITERS+1
IF (ICON.EQ.O .AND. ITERS.LT.TTS) cO T O 1
WRITE(6,*)
hRITE(6,*) ( . S O L U I I O N A N D T T E R A T T O N STO COI{VERGENCE')
r,rRrrE (6, 1oo) xl, rTERS
100 FoRMAT (812.4, I10)
SIIOP
END
c
FUNCTION F(X)

c THIS FUNCTTON PROVIDES T H E V A L U E O r F ( X )


AND WILL VARY FROM ONE PROBI,EM TO THE NEXT
c
F : ExP(Loc(X+1.o) /3.o)
RETIJRN
END
I
l

h
t
Initial value

Tolerance
XO
1.2
TOL
1.8-5
Iteration limit ITS
100
Fig. 33(a) Input data for Program3.1
l

**************** SIMPLE ITERATION *******i t***t*

INITIAL VAIUE
.1200E+01

SOLUTION A}.ID TTER,ATIONS TO CONVERGENCE


.1325E+01 7

Fig. 33(b) Resultsfrom Program3.1

enoughto xs, checkedby library subroutinecHEcK the processterminates. To guardagainst


divergentsolutions,a maxifnumnumberof iterationsis prescribed. Input andoutputareshown
in Figs 3.3(a)and (b) respcctively.
One might questionr{hetherthe startingguessinfluences the computationvery much (as
long as,of course,-x6) + 1.0).Table 3.1showsthat the influenceis smallin this case.
N O N L I N E A RE O U A T I O N S 67

Tsble 3.1. Influenceof startingguesson


iterationcount

Startingvalue Number of iterations


x6 to convergence

0 8
t.2 7
l.J 6
10.0 9
100.0 10

If F(x) is changedto Fr(x), a divergentresult will be obtainedwith x: -20593.4 after


7 iterations.If F(x) is changedto F2(x),againdivergence will beobtainedwith x:0.869 x l0-2r
after 10 iterations.We shallmerelystatethat convergence will only occurif ldf/dxl < I in the
.vicinity o[ the root; that is, the slopeof f(x) is less
than the slope of the line-y: x. It is thenclear
from Fig. 3.2 that only the useof F.(x) will do.

Example 3.1

Use direct iteration to find a root closeto x:1.3 of the function

f(x):x3 -x- l:o

Solution 3.1

We couldwrite(1) x:x3-l

Q)x:-J-
-x2-l

(3)x:ii;JT
In this case,arrangement(3) is the only one that converges,
hence
xo: 1.3
",:{/3+t :1.32006

*r:{lL32cr,6L: 1.3238

,r:{rnts+t :1.3245erc.

3.3 Multiple roots and other difficulties


It can readily be shown that the nonlinearequation

f(x): xo- 6x3+ l2xz- lox + 3:o (3.e)


CHAPTER
3

can be factorisedinto

,f(x):(r-3)(x- 1)(x- l)(x- 1):0 (3.10)


so that of the four roots, thrpe are coincident.This function is iliustratedin Fig. 3.4.
Following our experiencewith eq.3.2, we may think of expressingthe equation for
iterative purposesas

x: F(x):i, l 2 x 2+ ( 3 .rr)

-3

Fig. 3.4 Functions of f(x) and F(x) in eqs 3.10 and 3.11

This function is also shown in Fig. 3.4 where it can be seenthat for x < 1.0,F(x) becomes
imaginary.For x just greaterthan 1.0,dFldx> l, although in the vicinity of the root at
x:3, dFldx<1.
When Program 3.1is usedto attempt to solvethis problem,a startingguessxo: 1.1
convergesto the root x:3 in 3ll iterations while starting guessesof xo:l.Q sn6
xo:4.0 converge to the root x:3 in close to 100 iterations. We can see that
convergenceis slow, and that it is impossible to converge on the root x: 1 at all. We
thereforeturn to other methods, beginning with those basedon interpolation between
two estimatesto find a root.

3.4 Interpolationmethods
This classof methods is basedon the assumption that the function changessign in the
vicinity of a root. In fact if, for the type of function shown in eq. 3.10,there had been
a double root rather than a triple one, no sign change would have occurred at the
double root, but this occurrence is relatively rare. Let us begin by assuming that the
vicinity of a root, involving a change in sign of the function, has beenlocated - perhaps
graphicaliy. The next two sections describe methods whereby the root can be
N O N L I N E A BE O U A T I O N S OY

accuratelyevaluated.The methodsare sometimescalled'bisection'and'falseposition'


respectively.

3.4.1 Method of bisection

To take a typical example, we know that the function given by eq.3.2, namely

f(x):x3 -x- 1:0


$.2)
has a root closeto 1.3,and that /(x) changessign at that root (seeFig. 3.1).To carry out
the bisectionprocess,we.would begin with an underestimateof the root, sa] x:1.0,
and proceed to evaluate f (x) at equal incrementsof x until a sign changeoccurs. This
can be checked, for example, by noting that the product of
f(x,a1 ) and /(x") is
negative.We avoid for the moment the obvious difficulties in this process,namely that
. we may choosesteps which are too small and involve excessivework or that for more
complicated functions we may choose steps which are too big and miss two or more
roots which have involved a double change of sign of the function.
Having establisheda changeof signof f (x),wehavetwo estimatesof the root which
bracket it. The value of the function half way between the estimatesis then found. i.e.
.fl(r"*t+x")l2f or /(x-,0). If the sign of the function at this midpoint is the same as
that of /(x,), the root is closer to xn*, and x-i6 replacesxn for the next bisection.
Alternatively, of course, it replaces x,*r. when successivevalues of x.,o are .close
enough', i.e. within a certain tolerance, the iteration can be stopped.

Example3.2

Use the bisectionmethod to find a root of the function

f(x):x' -x- l:o


that liesin the range1.3<x<1.4.

Solution3-2
A tabular approachis useful,i.e.
x f (x)
1.3 -0.1030
t.4 0.3440
1.3s 0.1104
r.325 0.0012
r.312\ - 0.0515
1 . 31 8 7 5 -0.0253
1.32188 - 0.0r
2r
1.32344 -0.0055
r.32422 - 0.0021etc
70 C H A P T E R3

Hence at this stage the root lies in the range

1.32422<x<1.325

Program 3.2. Bisection method


The bisection method is encapsulatedin Program 3.2, which employs the foltowing nomenclature

XN Underestimate of the root, x"


XNl Overestimate of the root, xn*1
XMID Averageofxn and xn*,
TOL Iterative tolerance
ITFRS Current number of iterations
ITS Maximum number of iterations allowed
ICON Convergencecriterion in cnlcr

The pr6gram'sinput and output areasshownin Figs 3.5(a)and (b) respectively.


Numbersto be
input arethefirstunderestimate
of theroot,thefirst overestimate,
theiterationtoleranceand the
maximumnumberof iterationsallowed.

PROGRAM P32
C
C PROGRAM 3.2 BTSECTION METHOD FOR A STNGLE ROOT
c
READ(5,*) XN,XNI,TOL,rTS
WRITE(6, *) ( I *a************* B I S E q f I O N M E T H O D* * * * * * * * * * * * * * * |\
WRITE(6, *)
wRrTE(6,*) ('INITIAL V A L U E S ')
wRrTE (6,100) xN,xN1
ITERS : O
ICoN : o
l-o XoLD = XN
1 rF (rcoN.EQ.0 .AND. ITERS.LE.ITS) THEN
XHID : q.5* (XN+XNl)
PRoD = F(xN)*F()a{ID)
IF (PROD.LT..0) THEN
XNl" = )OIID

t'
i';
ELSE

END IF
XN = XMID

C A L L C H E C K( X M T D , X O L D , T O L , I C O N )
fTERs:ITERS+1
G O T O l
END IF
WRITE(6,*)
WRITE(6,*) (ISOLUTION AND ITERATIONS TO CONVERGENCE')
wRrTE (6,200) )(I\{ID,ITERS
10o FoRMAT (2812.4)
200 FoRMAT (E12.4,r10)
STOP
END

FUNCTION F(X)
c
C THIS FTINCTION PROVIDES THE VALUE OF F(X)
c AND WILL VARY FROM ONE PROBLEM TO THE NEXT
c
c
F = X * * 3 _ X _ 1 . 0
RETI'RN
END
N O N L I N E A RE O U A T I O N S 71

Initial values XN XNl


1.0 2.0
Tolerance TOL
l.E-5
Iterationlimit ITS
100
Fig. 35(a) Input data for Program 3.2

********rr***** B I S E C I I I O N M E T H O D* * * * * * * * * * * * ***

INITTAL VALUES
.1000E+01 .2000E+01

SOLIJ1TION AND ITERATIONS TO CONVERGENCE


.13258+01 L7

fig. 3.{b) Results from Program 3.2

As long as convergencehas not been achieved,or the iteration limit reached,the estimatesof
the root are bisected to give x*;6, and the lower or upper estimate are updated as required.
A library routine cnrcx checksif any convergencehas been obtained. (This is done in the same
way as cHEcoN usesfor arrays.)
When the tolerancehas been achieved.or the iterations exhausted.the current estimate of the
root is printed together with the number of iterations to achieve it.
As shown in Fig. 3.5(b),for the tolerance of I x l0- 5, the bisection method takes 17 iterations
to converge from lower and upper starting limits of 1.0 and 2.0.

3.4.2 False position method

Again this is based on finding roots of opposite sign and interpolating between them,
but by a method which is generally more efficient than bisection.
F i g u r e 3 . 6 s h o w s a p l o t o f / 1 ( x ) v e r s u s x w i t h a r o o t i n t h e r e g i o no f x : 2 . 5 . S u p p o s e
our interpolation guesseS8r€ xn:1.0 and xn+r:4.0. The false position method
interpolateslinearlybetweenfxn, f @^))and [x,* r, f (xn+t)], taking the intersectionof
the interpolating line with the x-axis as an improved guessat the root. Using the same
procedure as in bisection,the improved guessreplaceseither the lower bound or upper
bound previous guessas the case may be. The interpolation can be written
--l
l- -
xn"*:Xn-.ftr,ll=i!* | oszl
L.f(x,*r)-,f(x,U

Example3.3

Use the falsepositionmethod to find a root of the function

f(x):x'-x- 1:o
in the range 1.3< x < 1.4.
C H A P T E R3

f, (x)

f2 ( x \

First ii t
estimate
/r/
of root //

Fig. 3.6 Falsepositionmethodfor different/(x)

Solutioni.3

False position formula

_,,_/(,,)[ ^n+ t- Xn I
Xaa*
f( X n + ' )_(/_J-
)- ("fx")l

x ,f("x)
l.J
- 0.1030
1.4 0.3440
t.32304 -0.0071
r.32460 -0.0005
|
1.3247 -0.0000

Program3.3. Falsepositionmethod
This program illustratesthe processdescribedby eq.3.12. Comparisonwith the previous
p.og."* will showthat thedifference limitedto oneline,in whicheq.3.12replaces
is essentially
the bisectionstatement.For clarity x.16[XMID) in the bisectionProgramis replacedby
x."*[XNEW) in thefalsepositionprogram.Whenthe progtamis run with thedataof Fig. 3.7(a)'
theconverged result(Fig.3.7(b)will befoundto havebeenachievedin l3 iterationscomparedto
17.
bisection's
PROGRAM P33
c
C PROGRAH 3.3 FALSE POSITION METHOD FOR A SINGLE ROOT
c
R E A D( 5 , * ) X N , X N l , T O L , I T S
vrnrtrie, *1 ( t********** F A L S E P o s r r r o N M E T H o D* * * * * * * * * * * * * * * r )
wRITE(6,*)
I
W R I T E ( 6 ,* ) ( I I N I T I A L V A L U E S)
NONLINEAR EOUATIONS 73

wRrTE (6,1o0) XN,XN1


ITERS = 0
ICON = o
XOLD : XN
1 IF (ICON.EQ.O.AND. ITERS.LE.ITS) THEN
XNEW = xN - F(XN) * (xNl-xN) / (F(Xl,r1)-F(xN) )
PRoD = F(XN)*F(XNEW)
IF (PROD.LT..O) THEN
XNl = XNEW
ELSE
XN = XNEW
END IF
C A L L C H E C K( X N E W , X O L D , T O L . I C O N )
ITERS=ITERS+1
XoLD = XNEW
GO TO l-
END IF
WRITE(6,*)
wRrTE(6,*) (TSOLUTTON AND ITERATTONS rO CONVERGENCE')
wRrTE (6,2oo) XNEW,ITERS
100 FoRMAT (2E72.4)
2oo FoRMAT (E12.4,I10)
STOP
END

FUNCTTONF(X)
c
'rr{IS
FUNCTfON PROVIDES THE VALUE OF F(X)
c AND WILL VARY FROM ONE PROBLEM TO THE NEXT
c
c
F = X**3 x - 1.o
RETURN
END

Initial values XN XNI


1.0 2.0
Tolerance TOL
l.E-5
Iteration limit ITS
100

Fig. 3.7(a) Input data for Program 3.3

********** FALSE POSITION HETHOD ****r**********

INITIAI, VATUES
.10008+01 .20008+01

SOLUTTON AND ITER,ATTONS TO CONVERGENCE


.1325E+01 13

Fig. 3.7(b) Resultsfrom Program 3.3

This increasedefficiencywill generallybefound unlessthefunctionvariesrather sharplyclose


to one of the guessedroots. For example,Fig. 3.6shows/2(x) for which linear interpolation
yieldsa slowly cohvergingapproachto the root closeto 1.0for startingguesses of 1.0and 4.0.
C H A P T E R3

3.5 Extrapolation methods


A disadvantageof interpolation methods is the need to find sign changesin the function
before carrying out the calculation. Extrapolation methods do not suffer from this
problem, but this is not to say that convergencedifficulties are avoided,as we shall see.
Probably the most widely used of all extrapolation methods is often called the
Newton-Raphson method. It basesits extrapolation procedure on the slope of the
function at the guessedroot.

3.5.1 Newton-Raphson method

Supposewe expand a Taylor seriesabout a single guessat a root, xn. For a small step
ft in the x direction the Taylor expansion is

"{t^)* . (3.I 3)
f (*^* r)L f (x^+h): f (x,)+ hf' (x^)*\ f

Consequently xa+r is a root, i.e. f(x,+h):O if, dropping terms in the expansion
',
higher than f
'(x"):O
f ( x ^ )+ h f
(3.14)

/(x^) + (x" * 1- x,)/'(x") : Q


Rearranging, we have the condition for a root

Xn+t:Xn-
f (x^) (3.r 5)
,-

Obviously this has a simple graphical interpretation as shown in Fig. 3.8. The
extrapolation isjust tangential to the function at the guessedpoint xn. The new feature
of the method is the needto calculatethe derivative of the function, and this can present
difliculties (seeChapter 5). However, for simple algebraic expressionslike eq. 3.2 the
differentiationis easily done, and the derivative returned as a FoRTRANFUNCTIoN.

Fig. 3.8 The Newton-Raphsonprocess


N O N L I N E A RE O U A T I O N S

Example 3.4

Use the Newton-Raphson method to find a rool close to x:2 of the function

.f(x):xt-x-1:0

Solution 3.4

N e w t o n - R a p h s o nf o r m u l a x n * , : * ^ - H

xn3-xn- l
h e n c ei n t h i s c a s e ,x n * t : x ^ - -
3X^_2 |

x. f (x)
z s.0000
1.5455 l.I 458
1 . 3 5 9 6 0.l 537
1.3258 0.0046
t.3247 0.0000

Program 3.4. Newton-Raphson method


A program for Newton-Raphson iteration is listed as Program 3.4. It is based on the simple
iteration Program 3.1, and in fact differs from it only in one line, in which x, (called X0 in the
program) is updated to xn+r (called Xl in the program) according to eq.3.15. In addition to
a FUNCTIoN F delivering /(x) there is the extra FUNCTToN FDASH dclivering /'(x).

PROGRAM P34

C PROGRAI'13.4 NEITTON-RAPHSON METHOD FOR SINGLE ROOT

READ (5,*) XO,TOL,TTS


wRITE(6, *) ( | *i******** NEWTON-RAPHSON M E T H O D* * * * * * * * * * * * * * * ' )
WRITE(6,*)
VIRITE(6, *) ( IINITIAL VALUEI )
wRrTE (6,100) XO
ITERS : O
ICoN = 0
1 X1 = xo - F(xo)/FDASH(Xo)
C A L L C H E C X( X 1 , X o , T o L , r C O N )
ITERS=ITERS+1
IF (ICON.EQ.O .AND. ITERS.LT.TTS) Go To I
WRITE(6,*)
wRrTE(6,*) ( : S O L U : r I O N A N D T T E R A T T O N ST O coNvERGENCE ' )
wRrTE (6,1OO) Xl,rrERS
r-oo FoRMAT (E12.4r10)
STOP
END

FUNCUON F(X)
c
76 CHAPTER 3

C THIS FUNCTION PROVIDES T H E V A L U E O F F ( X )


c AND WILL VARY FROU ONE P R O B L E M T O T H E N E X T

c
F = X * * 3 - X - 1 . O
RETURN
END
c
FUNCTION FDASH(X)
C
THIS FUNSIION PROVTDES THE VALUE OF DF/DX
AND WILL VARY FROM ONE P R O B L E M T O T H E N E X T
c
FDASH:3.O*X**2-1.0
RETURN
END

Initial vaJue X0
r.2
Tolerance TOL
l.E-5
Iteration limit ITS
100

Fig. 3.9(a) Input data for Program 3.4

* * * * * * * * * * NEWITON-RAPHSON I'IETHOD * * * * * * * t * * * * * * *

INITIAL VAI,UE
- 12 0oE+O1

SOLUTION AND ITERATIONS TO CONVERGENCE


.1325E+O1 4

Fig. 3.9(b) Resultsfrom Program3.4

is now achievedin
When the programis run with the data from Fig. 3.9(a),convergence
4 iterations as shown in Fig. 3.9(b).

3.5.2 A modifiedNewton-Raphsonmethod

For largesystemsof equations,the needto beforevercalculatingderivatives canmake


the iterationprocessexpeosive.
A modified method can be used (thereare many other
'modified'methods)in which the first evaluationol '(x,) is usedfor all furtherextra-
f
polations.This is shown graphicallyin Fig. 3.10(b),which contrastswith the basic
method shown in Fig. 3.10(a).

Example 3.5

Use the modified Newton-Raohson method to find a root closeto x:2 of the function

f(x):x3 -x- 1:0


N O N L I N E A RE O U A T I O N S 77

Fig. 3.10 convergence of Newton-Raphson proc€ss€s(a) Newton-Raphson, (b) modified


Newton-Raphson

Solution 3.5

ModifiedNewton-Raphson
formula)cn*r:xn- f (x^)
f'(xo)

letxo:.2,hencein thiscase,,^*r:r^-#*

.
Xat l:Xr-
.f (x^)
ll

x .f (x)
2 5.0000
r.5455 1.1458
t.44t3 0.5528
r.3910 0.3006
1.3637 0.1724
1.3480 0.1016
1.3388 0.0609
1.3333 0.0368
r.3299 0.0223
1.3279 0.01 36
1.3267 0.0083etc
7B C H A P T E R3

The convergencein this caseis rather slow becausethe gradient at x:2, which remains
unchanged,is a poor approximation to the'correct'gradient at x=1.3247.

Program 3.5. Modified Newton-Raphson method


The program is almost identical to the previous one. The initial derivative is called FD and used
thereafter as a constant. When the program is run with the data of Fig. 3.11(a)for the two
different initial values, the results on each iteration are listed in Figs 3.11(b) and (c), which
illustrate one of the typical problems of Newton-Raphson type methods. It can be seen that
with a starting value of 1.0 the estimated root oscillates between two constant values,and will
never converge to the correct solution. On the other hand, if the starting guessis changed to
1.2,convergenceoccurs in 8 iterations.
We can seethat the processis far from automatic and that the closer to the solution the initial
guess is, the better-

PROGRAM P35
C
C PROGRAM 3.5 MODIFIED NEWTON-RAPHSON FOR SINGLE ROOT
c
READ (5,*) X0,TOL,ITS
WRITE(6,*) ( r****** N E T H O D* * * * * * * * * * * r
M o D I F T E D N E W T O N - R A P H S OM )
WRITE(6, *)
WRITE(6, *) ( ' INITIAL VALUE')
wRrTE (6,10o) Xo
WRITE(6,*)
WRITE(6,*) ('VALUE OF X AT EACH ITERATIONI)
ITERS = O
ICON : O
FD = FDASH(Xo)
1 X1: xo - F(xo)/rD
C A L L C H E C K( X 1 , X 0 , T O L , I C O N )
ITERS=ITERS+1
WRITE(6,1O0) X1, ITERS
rF (ICON.EQ.O .AND. rTERS-LT.ITS) GO rO 1
WRITE(6,*)
VTRITE(6,*) ( rsol,tiltloN AND ITERATIONS TO CONVERGENCE')
wRrTE (6, l-00) xl-, rTERS
100 FoRMAT (EL2.4,rl.o)
h; STOP
END
U
FTINCTION F(X)
c
c THIS FUNCTION PROVTDES THE VALUE OF T(X)
c AND WILL VARY FROM ONE PROBLE}.I TO THE NEXT
c
c
F = X * * 3 - X - 1 . 0
RETURN
END

FUNCTION FDASH(X)
c
c T H I S F U N C T I O N P R O V I D E S THE VALUE OF DF/DX
c AND WILL VARY FROM ONE PROBLE}I TO THE NEXT
c
C
FDASH=3.0*X**2-1.O
RETURN
END
N O N L I N E A RE O U A T I O N S 79

Initial value XO
1.0(1.2)
Tolerance TOL
LE_5
Iterationlimit ITS
100
Fig. 3.ll(a) Input data for program 3.5

** * * ** II{ODIFIED NEW]FON-RAPHSON HETHOD * * * * * * * * * * *

TNITIAL VALUE
.1000E+o1

VALUE OF X AT EACH TTER.ATTON


.1500E+O1 1
.10628+01 2
.1494E+O1 3
' .1074E+ot 4
.14928+01 5

: :
.1081E+O1 95
.14908+01 97
. r-o81E+O1 98
.1{90E+01 99
.108LE+O1 100

SOLTITION AND ITERATTONS TO CONVERGENCE


.1081E+O1 100
Fig. 3.11(b) Resultsfrom Program3.5with X0:1.0

****** UoDIFIED N E W : I O N - R A P H S O NM E T H O D * * * * * * * * * * *

INTTTAL VALUE
.1200E+O1

VALUE OF X AT EACH ITERATTON


.13428+01 1
.13198+01 2
.1326E+O1 3
.1324E+O1 4
.1325E+01 5
.13258+01 6
.13258+01 7
.13258+01 8

SOLT]:PTON AND ITERATIONS TO CONVERGENCE


.1325E+01 I
Fig. 3.11(c) Resultsfrom Program 3.5 with X0: 1.2

3.6 Accelerationof convergence


For slowly convergent iterative calculations, 'Aitken's 62 accnleration' process is
sometimeseffectivein extrapolating from the converging solutions to the converged
result.
The method can be simply stated.If we have threeestimatesof a root, x1,x* * and
,
CHAPTER
3

x1*2 the d2 processextrapolatesto a new solution

XrXt + 2- X** t2
--ncw (3.16)
x1r',2-2x1*a1*xy

The processis far from universally successfulbut can lead to much improved con-
vergenc€rates.

3.7 Systemsof nonlinearequations


For.simplicity of presentation,we have so far concentrated on a single nonlinear
equation. In practicewe usually have many equations to solve simultaneously.For
exampleconsiderthe two equations

2 x 1 2+ x r 2: 4 . J )
(3.17)
xr'-xrt--0

By inspection,theseequationshave a root in the vicinity of x, : l, xz: l, and in fact in


this simple case we see a solution is x1 :x2:1.2. Amongst the methods already
described,iterative substitution and Newton-Raphson are most easily applicable and
in this sectionwe shall apply them to systemsof equations.

3.7.1 Iterative substitution for systems

Equations 3.17can be cast in the form

,, : r/zte - t, |: F(xr,xz)
(3.r8)
x,:a874 :G(x62)

and the iterative procedure followed as before. For example, a starting guessof xt :
xz:1.0 leadsto solutions
Iterationnumber 0 I 2 3 4 5 6
X1 1.0 r.29 1.29 1 . 1 6 t . r 6 r . 2 2 1 . 1 9
^2 1.0 1.0 1.29 t . 2 9 1 . 1 6 1 . 1 6 1 . 1 9
which are clearly converging to the correct result. In the manner of Gauss-Seidel
iteration, the convergencecould be improved by using updated values as soon as they
becomeavailable.

Program 3.6. Simple iteration for a system of equations


A program for solution of a system of equations by simple iteration now follows:
Simple uariables
N Numbero[ equations
TOL Iterationtolerance
ITS Maximum numberof iterations
ITERS Currentnumberof iterations
ICON Convergence criterionin cHECON
N O N L I N E A RE O U A T I O N S

Variable length arrays


XO Values of Xr, X2,.. . , xn iteration
X1 Values of xr, x2,.. ., .xry4t end of iteration

PARAMETERrestrictions
IN>N
PROGRAM P36
c
c PROGRAM 3.6 TTERATIVE SUBSTITI,ITION FOR UANY EQUATIONS
c
c ALTER NEXT LINE TO CHANGE PROBLEI,I SIZE

PARAMETER (IN=2o)

REAL X0(rN),x1(rN)
c
READ(5,*) N, (Xo(I),I=1,N)
READ (5,*) TOL,ITS
WRITE(6,T) (I** SIMPLE ITERATION FOR A SYSTEM OF EQUATIONS **')
wRrTE(6,*)
wRrTE(6,*) ( t T N I T I A L V A L U E S T)
CALL PRINTV(XO,N,6)
WRITE(6,*)
ITERS : O
ICON = O
1 CALL F(Xo,Xl)
CALL CHECON (X1, Xo. N, TOL, rCON)
ITERS=ITERS+1
rF (rcoN.EQ.O .AND. ITERS.LT.ITS) Go To 1
WRITE(6.*) ( ' S O L U T I O N S A N D I T E R A T I O N S T O CoNVERGENCE| )
CALL PRrNW(Xl,N,6)
WRITE(6, IOO) ITERS
1oo FoRMAT (r10)
STOP
END

S U B R O U T I N EF ( X O , X 1 )

c THIS SUBROUTINE PROVIDES THE VALUES OF T H E F U N C T I O N S


OF X AND WILL VARY FROM ONE PROBLE}'I TO THE NEXj|
c
c
REAL XO1*;,X1(*)
c
xr(1) = SQRT(21
. 6-0-s*Xo(2)*xo(2) )
xl(2) - xs111
RETURN
END

Number of unknowns N
z

Initial values x O ( I ) , I : 1 ,N
1.0 1.0
Tolerance TOL
1.E-5
Iteration limit ITS
100

Fig. 3.12(a) Input data for Program 3.6


C H A P T E R3

** SIMPLE ITERATION FOR A SYSTEM OF EQUATIONS **

INITIAL VALUES
.1000E+01 .1000E+01

SOLUTIONS AND ITERATTONS TO CO}TVERGENCE


.12008+01 .1200E+01
31

Fig. 3.12(b) Resultsfrom Program 3.6

Input data and output resultsare shown in Figs 3.12(a)and (b) respectively.The program is really
just a copy of Program 3.1 with arrays in place of simple variables.The functions F and G in eqs
3.18 are user-suppliedin the form ofa subroutine called F. For theseequations and the starting
guess .xr:xz:1.0, convergenceis achieved in 31 iterations.

Sincd,for a single equation, convergencewas conditional on the magnitude of the


gradient of the function, we can guessthat a similar restriction will apply to systems
of equations.In fact,it can be shown that equations like 3.18will only have convergent
iterative solutions of this type if

AF AF
^ ^ <l
oxr QXz

and (3.re)
lac AG
F'
!
l ^
Ioxr
^
oXz
<1

This restriction can limit the use of the method in practice


I
i
I'
I I
3.7.2 Newton-Raphson for systems

This is basedon Taylor expansionsin severalvariables.For example,in the caseof two


equations,such as eqs 3.17,which could be written

f (xr, xrl:g (3.20)


g(xvx):0
* t, xrr*'). The Taylor
suppose (xr*,xr*) whichis closeto a root (xr*
we makea guess
expansionsare

0/(a*'x,*)
f ( * , . r * r , r r r * r ) : f ( x , * , x r r )+ ( x , r * r - r , * , + ( x 2 r *, - r r r r j f ( * J " " r ) *...
0x, dx,
(3.2t)

09(1 *,tr' ) * x'r)


g(xrk nr,rr* *, ) : g(x,.,xrr)+ (x r** r - r r*, + (x2r t - x 2k)9g$-'r' * ...
0x, A x ,
N O N L I N E A RE O U A T I O N S

Again neglectingderivatives higher than the first, eqs 3.21 gle an improved estimate
of a root in the form

0f (xrk,xrkl - rt
(x,r*r -x,k) J + ( x z k *' - * r * ) Y6 if i(ux ,:t -f(xrr,xzr) (3'221
or,

(xr** I - r, *; 9QLd4 (t
+ (xz,* t - x 2r)ag -' |) - - s(xJ, x 2k)

These are readily expressedin terms of changesin x, and x2

/xr:7r*+ t -tr*

and Q.23)
a

/x2-yrk+t-*rr

so that eqs 3.22 become

. a f a f -
l xr;-+ /xr - - :- : t
oXr oXz
G'24\
oq oa - g
lxr;:+/x2::
OXr OXz

'\
f af af 1( I r
lI +o x r "o x_z ll l l / * ' |l l| - f Il
I l{ ):( i e.2s)
l a o o ol l I I I
L*, ;)lo") l-n)
Thusfor a systemof N simultaneous nonlinearequations, wemustsolveN simultaneous
linearequationsto find the changes/x1 and/x2 in everyiteration.The matrix on the
left-handsideof eqs3.25is calledthe 'Jacobian'matrix J and its determinantsimply
'the Jacobian'.Clearly,if the Jacobianis zero, the process
fails, and if it is closeto
zero,slow convergence may be anticipated.
For a startingguessof x1: vr: 1.0,the iterationmatrix for the first iterationon eqs
3 . 1 7i s :

Il+
z]ft,,l r.rz'l
r ( ) -- (f
lz -zl [zx,J [o )r
which yieldsthe solution/xr:7*r:0.22 and hencean improvedsolutionx, :
xz:1.22.
C H A P T E R3

Examplej.6

Use the Newton-Raphsonmethodto find a root of the equations


xy :1
x2+y2:4
Closeto x:1.8, -y:0.5.

Solution3.6

Arrangeequationas follows:

f(x,y):xy-l:Q
f (*,y):{'+y2 -4:0
l' 'l
':Lr' 2vl
r ^
/.y -xll
I I
J-': 'r'-z*'
[-" rJ
1st iteration
Initial guessx: 1.8,1l:0.5

f -o.rotz o.3orol
J-r:L
0.6020-0.08361
-o:en o.3orolr
Ir'l_l {o }_{o.r:es}
-0.08361
lzyj-L 0.6020 [o.stJ-[o.otzej
2nd iteration
x:1.8+0.1368:1.9368
/:0.5 +0.0176:0'5176
[ - o.r+se o.2z8ol
J-':L o.s56o -o.oi43-l
r+se 027801
{o,\ _[-o {-o.oozs}_{-o.oo+r}
lty|-L 0.5560-0.07431
[-o.otstJ [ 0.0000J

3rd iteration
-0.0049: 1.9319
x: 1.9368
v:0.5176 =0.5176 etc.
N O N L I N E A RE Q U A T I O N S 85

Program 3.7. Newton-Raphson method flor a system


of equations
A program for solution of a systemof equations by the
Newton-Raphson method now follows.

Simple oariables
N Number of equations
TOL Convergencetolerance
ITS Maximumnumberof iterationsallowed
ITERS Currentnumberof iterations
ICON Convergence
criterionin cHEcoN

P R O G R A MP 3 7
c
c PROGRAM 3.7 NEWTON-RAPHSON FOR HANY EQUATIONS
c
ALTER NEXT LINE TO CHANGE PROBLEM
SIZE
o
PARAMETER (IN=20)
c
REALX(IN),X1(IN),DELX(TN),F(IN),DF(IN,
IN)
READ (s, *) N, (x(I) , r=1,N)
READ (5,*) TOL,rTs
( r r*** NE!']ToN-RAPHSoN
FoRA svsrEMoF EeuArroNS**** '
ffiiIE[E;:i )
wRrTE(6,*) ( ' T N I T T A L V A L U E S .)
CALL PRINTV(X,N,6)
wRrTE(6,*)
ITERS = 0
ICON = 0
1 C A L L F A N D D F ( X . F , D F ,I N , N )
CALL MATINV(DF,TN,N)
CALL MWULT (DF, TN, F. N, N, DELX)
C A L L V E C S U B( X , D E L X , X 1 , N )
C A L L C H E C O N( X 1 , X , N , T O L , I C O N )
rTERS-ITERS+1
IF (TCON.EQ.O .AND. ITERS.LT.TTS) GO TO
wRrrE(6,*) ('soLUTroNSaro rrEnairoNs ToT coNvERcENcEr)
CALL PRINTV(X1,N,6)
wRrTE (6,100) rTERS
100 FORMAT (I10)
STOP
END
c
S U B R O U T T N E F A N D D F( X , F , D F , I N , N )
c
c THTS SUBROUIINE PROVIDES THE VALUES
OF THE FI'NCTTONS'
c OF X AND THEIR DERIVATIVES, AND WTLL VARY T'NOIT OHT
c PROBLE}I TO THE NEXT
c
c
REALX(*),F(*),DF(rN, *)
c
=
I t l l = 2 . 0 * x ( 1 ) * x ( 1 )+ x ( 2 ) * x ( 2 ) - 4 . 3 2
IDl F?(l1 , 1 ) x =( 1 ) * x ( 1 ) - x ( 2 ) * x ( 2 )
4.0*X(1)
DF(2,1) : 2.OrX(1)
DF(1,2) = 2.0*X(2)
DF(2,2) = -2.o*X(2)
RETI'RN
END
86 C H A P T E R3

Variable length anays


X Values of Xt, x.-,.. . xp' at start of iteration
Xl Values of xt, X2,.. . Xp at end of iteration
DELX Change in solution vector in an iteration
F The function in eq. 3.19
DF The first derivativesin eq. 3.25 arranged as a twodimensional array

PARAMETERTCSTTiCI|ON
IN>N
Number of unknowns N
2

Initial values X0(I), I: I, N


1.0 1.0
Tolerance TOL
1.8-5
Iterationlimit ITS
100

Fig. 3.13(a) Input data for Program3.7

**** NEI{rON-RAPHSON FOR A SYSTil OF EQUATTONS ****

INITIAL VALUES
. 10008+01 .1000E+01

SOLT]TTONS AND ITERATIONS TO COIIVERGENCE

F .12OOE+O1 .120OE+01

t
Fig. 3.13(b) Results from Program 3.7

The input data and output results are given in Figs 3.13(a) and (b) respectively. The number of
l
l equations, an initial guessof the solution vector, the iteration tolerance and the number of
f1 iterations allowed must be read in by the program. The actual functions and their derivations
are contained in the user-suppliedsubroutine FANDDF.
Library routines MATINv and t',tvt'luLt complete the equation solution required by eqs
3.25,resulting in the changesin X held in DELX. Vector X is then incrementedby DELX and the
cHECoN subroutine called. Note that for large systems,MATINv should be replaced by the
solution algorithms describedin Chapter 2. Figure 3.13(b)shows that convergencewas achieved
in this simple case in 4 iterations.

3.7.3 Modified Newton-Raphson method for systems

The presenceof subroutine MArrNv inside the iteration loop will mean substantial
calculations if N becomeslarge. We describedpreviously a modified method which, in
this case,would mean that the matrix on the left-hand side of eqs 3.25need be inverted
once only, at the first iteration. This method is programmed as Program 3.8.

L
N O N L I N E A RE O U A T I O N S

Example3.7

Use the modifiedNewton-Raphsonmethodto find a root of the equations


e'+y :0
coshy-x:3.5
Closeto x: -2.4,.),: -0.1

Solution3.7

Arrangeequatiorisas follows

f1(x,y):e' a y:Q
- f r ( r ,y ) : - x f c o s h y - 3 . 5 : o
a _

.r:l ex I I
sinhyJ
L-l

I -ll
J-,: f s l n r r r
l*e'sinhy[_ I .']

EvaluateJ-r usingthe initial valuex: -2.4, y: -e.1

-
"r_,: [-o.ron r.oo92-l
L r.ooe2o.oer
sJ
In the modified Newton-Raphson method, J-r is not altered at each iteration.
Hence

lst iteration

x: -2.4, -0.1
/:

ir'l:[-o.rou -r.00e21
fo.oorl
_ f_o.oroal
lorJ I r.oorz00er5J
ioorsoj-i0.0r8rJ
2nd iteration
x : - 2.4- 0.0968 : - 2.4968
/ : - 0 . 1 + 0 . 0 1 8:1 - 0 . 0 8 1 9
-
[z']_[-o rorr 1.00e21
[-ooo*l f o.ooozl
lzv) [ r.oorz0oer5J
i-oooozj:i-o*j
C H A P T E R3

3rd iteration

x - - 2.4968+ 0.0002: 2.4966


t -
-0.0819-0.0004
:0.0823 etc.

Program 3.8. Modified Newton-Raphson method for a system of equations

PROGRAM P38
c
C P R O G R A M3 . 8 MODIFTED N E W T O N - R A P H S O NF O R H A N Y E Q U A T I O N S
c
C ALETR NEXT LINE TO CHANGE PROBLEM SIZE
c
no*ETER (IN=2o)
.
REALx(rN),X1(rN),DELX(rN),F(rN),DF(rN,IN)
c
gEAD (5,*) N, (X(r),1:1,N)
READ (5,*) ToL,ITS
WRITE(6,*) ( r************ M O D I F I E D N E W T O N - R A P H S O*N* * * * * * * * * * * * r )
l.lRITE(6,*) (r*********** F O R A S Y S T E M O F E Q U A T I O N S* * * * * * * * * * * * r )
I{RITE(6,*)
W R I T E ( 6 , * ) ( ' T N I T I A L V A L U E S I)
CALL PRINTV(X,N,6)
I{RITE(6, *)
ITERS : O
ICON = O
C A L L F A N D D F( X , F , D F , I N , N )

i CALL MATIIIV(DF, IN,N)


1 CALL FLjN(X,F)
C A L L M W f U L T( D F , T N , F , N , N , D E L X )

F
C A L L V E C S U B ( X ,D E L X , X 1 , N )
C A L L C H E C O N( X 1 , X , N , T O L . r C O N )
ITERS:ITERS+1
rF (rcoN.EQ.0 .AND. TTERS.LT-rrs) Go ro 1

l WRITE(6,*)
CALL PRINTV(X1,N,6)
WRITE (6,1o0)
('SOLUTTONS AND TTERATIONS TO COITVERGENCET)

rrERS

r,
b

c
10o FoRMAT (I1O)
STOP
END

S U B R O U T I N E F A N D D F ( X ,F , D F , I N , N )

c THIS SUBROUITNE PROVIDES THE VALUES OF THE FUNCTTONS


OF X AND THEIR DERTVATTVES, AND WIIL VARY FROM ONE
PROBLEU TO THE NEXT
c
c
R E A LX ( * ) , F ( * ) , D F ( r N , * )
c
r ( 1 ) = 2 . 0 * X ( 1 ) * X ( 1 )+ X ( 2 ) * X ( 2 ) - 4 . 3 2
F(2) : x(1)*x(1) - x(2)*y121
Dr(l-,1) : a.0*x(1)
DF(2,1)= 2.0*X(1)
DF(1,2)= 2.o*x(2)
DF(2,2, = -2.o*x(2)
RETURN
XND
c
SUBROUTINEFIJN(X,F)
c
c PROVIDESTHE VALUES OF THE FUNCTIONS
THIS SUBROL]IIINE
N O N L I N E A RE O U A T I O N S QO

c OF X AND WILL VARY FROM ONE PROBLEM TO THE NEXT


c
REAL X(*) , F(*)

F(1) :2.o*X(1)*X(1) + x(2)*x(2) - 4.32


F ( 2 ) = X ( 1 1* Y ( 1 ) - x ( 2 ) * x ( 2 )
RETURN
END

Number of unknowns N
2
Initial values X0(I),I: l,N
1.0 1.0
Tolerance TOL
1.8-5
Ilerationlimit ITS
100
Fig. 3.14(a) Input data for Program3.8

* * * * * * * * * * * * I,IODf FI ED NEI{TON-RAPHSON * * * * r * * * * i t * *
*****r***** FoR A SySTEl,roF EQUATIONS ************

INITIAL VAIUES
.1OOOE+O1 .10OOE+o1

SOLUTIONS AND ITERATIONS TO CO}N/ERGENCE


.12008+01 .1200E+01
I

Fig. 3.la@) Resultsfrom Program3.8

A new subroutinecalledruru is usedafterthe first iteration,and untlNv is movedoutsidethe


iterationloop.Otherwisetheprogramis identicalto Program3.7.Whenrun with thedatagiven
in Fig. 3.14(a)it producesthe resultsshownin Fig. 3.la(b).
In this simplecase,convergence is reachedin seveniterationsusingthe modifiedmethodand,
in general,it will requiremoreiterationsthan the basicNewton-Raphsonprocedure.It will be
a questionin practiceof whetherthe increasein iterationsin the modifiedmethodmore than
compensates for the reductionin equationsolving.

3.8 Exercises
I Find a root of the equationx4-8x3 +23x2+ l6x-50:0 in the vicinityof 1.0by simple
iteration.
Answer:1.4142

2 Find the root of the equationx3-3x2+zx-0.375:0 in the vicinityof 1.0 by simple


iterationin the form 1:[(x3+2x-O.375)Fltt2.
Answer:0.5in 95 iterationsfor a tolerance
of 1x l0-5.

3 Find a root of the equationin ExerciseI in the range 1.0< x < 2.0 by bisection.
Answer:l.4l42in l7 iterationsfor a toleranceof I x l0-s.
90 3
CHAPTER

4 Find a root of the equationin Exercise 1 in the range1.0<x<2.0 by'falseposition'.


Answer:1.4142 for a tolerance
in 3 iterations of I x 10-5.

5 Find a root of the equationin Exercise2 in the range0.35<x<1.0 by bisection.


Answer:0.5in 17 iterationsfor a tolerance of 1x 10-s.

6 Find a root of the equationin Exercise2 in the range0.4<x<0.6 by'falseposition'.


Answer'.0.5 for a tolerance
in 12 iterations of 1x 10-s.

7 Find a root of the equationin ExerciseI in the vicinity of 1.0by the Newton-Raphson
process.
Answer:l.4l42in 3 iterations for a toleranceof 1x l0-s.

8 Find a root of the equationin Exercise2 in the vicinity of 1.0by the Newton-Raphson
process.
Answer:0.5 of 1x I0-5.
in 6 iterationsfor a tolerance

9 Find a root of the equation in ExerciseI in the vicinity of 1.0 by the modified
Newton-Raphsonprocess.
Answer:1.4142in 5 iterationsfor a toleranceof I x 10-5.

l0 Find a root of the equation in Exercise2 in the vicinity of 1.0 by the modified
Newton-Raphsonprocess.
Answer:0.5in 30 iterationsfor a tolerance
of 1x 10-5.

ll Solvethe equations
:
1 1* x 2 - 1 r r l 2 - 9 . 2 5 : g
I

8 x r 2 +1 6 x r - 8 x 1 x 2 - 5 : 0

by simple iteration from a starting guess

xt:xz-l'

Answer:xr:0.5, xz:0.25 in ll iterationsfor a toleranceof 1x l0-5.

12 Solve the equations

2 x 1 2_ 4 x 1 x 2 - x z 2: O
2 x 2 2+ l l x y - x 1 2- 4 x r x 2 - 5 : 0

by the Newton-Raphson procedure starting from

xr:icz - l'

Answer:xr:0.58, xz:0.26 in 5 iterationsfor a toleranceof 1x l0-5.

13 Solve the equations in Exercise 12 by the modified Newton-Raphson procedure starting


from
(a) x, :1r:1 and (b) xt:9.5, xu:0.25.

Answer: xl:0.58, xz:0.26 in (a) 1470 iterations and (b) 6 iterations for a tolerance of
1x 10-s.
N O N L I N E A RE O U A T I O N S 91

14 Solvethe equationsin Exercisell by


(a) the Newton-Raphsonprocedureand
(b) the modifiedNewton-Raphson procedurestartingfrom x1:1.0, xz:0.1.
A n s w e rx:r : 0 . 5 , x z : 0 . 2 5i n ( a ) 5 i t e r a t i o n s a n d (2b0) i t e r a t i o n s f o r a t o l e r a n c 1
e xo f1 0 - 5 .

3.9 Further reading


Baker, C. and C. Phillips (eds) (1981). The Numerical Solution of Nonlinear Problems, Clarendon Press,
Oxford, England.
Byrne, G. and C. Hall, eds (1973). Numerical Solution of Systemsof Nonlinear Algebraic Equations, Academic
Press, New York.
Gill, P., W. Murray and M. Wright (1981). Practical Optimisation. Academic Press, New York.
Hiebert, K. (1982).An evaluation of mathematical software that solve systemsof nonlinear equatiots. ACM
Trans. Math. Softw., 11,250-262.
Houscholder, A.(1970).The Nurnerical Treatment of asingle Nonlinear Equation, McGraw-Hill, New York.
More, J., B. Garbow and K. Hillstrom (1980). User Guide for MINPACK-I. Argonne Nat. Lab. Rep.
' ANL-80-74.
Ortega, J. and W. Rheinboldt (1970).Iteratiue Solutionof Nonlinear Equationsin SeveralVariables,Academic
Press, New York.
Peters,G. and J. Wilkinson (1971).Practical problems arising in the solution of polynomial equations,J. /nsr.
Math. and its Appl.8, l6*35.
Rheinboldt, W. (1974). Methods for Soluing Sysrems of Nonlinear Equations, Society for Industrial and
Applied Mathematics, Philadelphia.
Traub, J. (1964). Iteratioe Methods for the Solution of Equations. Prentice-Hall, Englewood Cliffs, New
Jersev.

You might also like