Quick viewing(Text Mode)

California State University, Northridge Origin

California State University, Northridge Origin

CALIFORNIA STATE UNIVERSITY, NORTHRIDGE

ORIGIN, DEVELOPMENT OF SOLUTION METHODS, Ql AND APPLICATION OF DI.l!,JPERENCE EQUATIONS.

A thesis submitted in partial satisfaction of the requirements for the degree of Master of Science in Mathematics.

by Ronald P. Thomas

June, 1977 p '

The Thesis of Ronald P. Thomas is approved:

Tung------~------Po ~in, Chairman

California State University, Northridge ACKNOWLEDGEMENTS I would like to express my appreciation to the following who were instrumental in making this achievement possible: To the CSUN Department of Mathematics for allowing me to serve as a Graduate Assistant and as a Part Time Instructor and to their faculty for their expert instruction in mathematics.

To Mr. Neil H. Jacoby, Jr., an Engineer and neighbo~ who helped me over the years master mathematical skills. And most j_mportantly To Dr. T.P. Lin, who was the professor for Math Models when I was enrolled in the Spring 1975 semester, for his inspiring teaching and for bringing to my atteLtion the topic of this thesis, for his time given to me in guiding the preparation of th~s thesis. ------TABLE OF CONTENTS

Title Page i Approval Page ii Acknowledgements iii Table of Contents iv Abstract v

Part I - Introduction 1 - 3 Part II - Origin of Di.f.ference Eq'uations 4 - 6 Part III - Development o.f Methods o.f Solution 7 - 27 Part IV - The Application o.f Di.f.ference Equations 28 - 58

Bibliography 59 ABSTHACT

ORIGIN, DEVELOPfJ!ENT Olt' SUJJUTION METHODS, AND APPLICATION OF DIFFEREnCE EQUATIONS.

·by

Ronald P~ Thomas Master of Science - Mathematics

This paper presents an elemetry study of difference equations. Difference equations are defined and their origin in the works of Brook Taylor and James Stirling, circa -- 1715, is viewed in the perspective of broad developments ... _:, . . ~~:~.~~),' of mathematics to that time. Methods of solving various types of difference equations are presented. These include linear difference equations with constant coefficients an·d with variable coefficients. Difference equations are applied to problems in areas where work is done in discrete intervals. Discussion centers on examples of their application in sequences of numbers, systems of difference equations (pythagorean triples), finding the zeros of certain polynomials, biological-population dynamics and in numerical approximation of difference equations. PART I - INTRODUCTION Difference equations are equations of the form

F (X' y' !J. y' JS..y' NY' ... }),"" j ) = 0 (1) where x, .Y are descrete variables and (y, /).y, •. ) are

diff~rences of various orders. Equati~n (1) can be written in the form of G(x, f(x), f(x+h), f(x+2h), ... f(x+nh)) = 0 (2). where y = f(x) is an unknown function and h is a constant. The forms of difference equations shown in (1) and (2) are not the usually encountered forms. Subscript notation is frequently used. Let- x =a+ kh, a is a

constant and yk = f(a+kh). Now equation (2) can be written as H k, yk' yk+l' •••• , yk+n = 0 (3) It is this form that difference equations will take in this thesis. Y = f(x) is a solution to equation (2) or Yk =f(a+kh) is a solution to equation.(3) if the -functions will reduce the given equation, after proper substitution, to an identity. There are many different types of difference ·equations. The various types depend on the configuration of subscripts, coefficients, constants or functions that are imbedded in the equation. Of particular, though not exclusive, interest in this thesis are Linear Difference Equations. 2

The reader who is familiar with differential equations will see many similarities between them and difference equations. This is as it should be. In defin­ ing a difference a finite increme~t h was added to the independent variable. Ih difference equations this h is kept finite. In differential equations this h is allowed to approach 0.

Introduction to Applications The application of difference equations are many. The author's first encounter with them was in relation to sequences of numbers. They are used as recursion formulas. By applying the methods of solution given in Part III of this thesis. it is possible to find the value of a number in a sequence given the position of the number in the sequence (3rd term, lOth term, etc.). Difference equations are also used in finding the zeros of polynomial functions, numerical approximations to differential equations, pop­ ulation studies-at finite time intervals, and other pro­ blems where the interval of difference does not have to approach zero.

Notations Used in Thesis The following are examples of notations used in this thesis: 3

Yk ~s used to indicate the kth value of the variable Y. Subscripts used on the other variables have a similar meaning.

y(h) is used to indicate the solution to the k homogeneous difference equation or to the homogeneous part of the equation. y~P) is used to indicate the particular solution to a non-hornogenedus difference equation. yCl) is used to indicate the first solution to a k difference equation • . (2) yk the second solution to an equation. y(n) t·he Nth solution to an equation. k p '

PART II - THE ORIGIN. Oli' DIFFERENCE EQUATIONS

A description of the various branches of mathematics existing to 1715 is being provided so that the reader will have knowledge of the mathematical methods that were

available. 1. Number systems were developed as a means of expressing

"different quanti ties. Various bases w.ere used.

2. Arithmetic, which originated in Babylonia and Egypt, supplied a way of relating numbers by certain rules; 2 ie: +, -, x, -, I , ( ) , etc. 3. Algebra, which had its beginnings in Babylonia, is

concerned with solving problems via equations (linear, second and some 3rd and 4th degree). Also of concern were problems of' applied geometry.

·4. Geometry (Babylonian, Pythagorean, Euclidean) had its

beginnings as a concern for measure~ent of land. Many

problems expressed in geometric terms were really algebraic in.nature. Various geometric figures were

considered. It was the formalization by the Greeks (Euclid in particular) that created geometry as a

mathematical system of its own. This ca~e about as many people were concerned as to why certain things were

~rue (a circie is bisected by its diameter). 5. TrigonQmetry had its beginnings with the early Baby- lonian astronomers who were concerned with various

4 5

astronomical phenomena. The period of th~ mbon's rev­

olution about the earth and the inclination of its

orbit. were two of these.· The Greeks used trigonometry

as a means of locating places on earth (longitude

and latitude). t1odern trigonometry, complete with the

usual trigonometric functions, was developed by Euro­

.pean mathematicians; arnong'tbem Pitcus, Rheticus and

Fincke. A table of trigonometric values was published by Rheticus in 1583. 6 .. Analytic Geometry, sometimes called coordinate geometry, was developed primarily by Descartes in 1637. He applied algebra to the study of geometric theorems and

problems. Uut of this came some of the coordinate

systems we use today. 7. The was developed by Newton and Leibniz in the latter 1600's. The-work is based on the ideas and

concepts of limits, convergence and · of

a function. Also the rates of change of a function at

a point, of a to a curve at a point

were considered.

With the development of mathematics up through the calculus of Newton and Leibniz certain problems were not ye·t. solvable. Problems such as interpolating for inter­ mediate values in a table or finding a function to fit observed data derived from sor.J.e experiment. The work of 6

Brook Taylor and James Stirling provided the means for

solving these problems.

Br0ok Taylor's work "Methodus Incrementorium" con­

cerned itself with functions and rates of changes of the

function for a given change, or increment, of the inde­ pendent variable. Also considered is how these differences interrelate. This work led to'his development of the

expansion of a function about a point which now

bears his name. James Stirling's work "Methodus Differentailis" concerned itself with infinite series, summation of those

series and interpolation formulas. The work with infinite

series dealt with ways of expressing series, differences between terms and dj._fferences between vari-ous partial

.sums. Series of various types were considered. The work

on interpolation formulas dealt with ~ays of finding values between those in a table of a mathematical relation

Div~ded differences were the end result of this work. Since then Lagrange, Euler and others have made use of difference equations in developing techniques of num­ erical analysis. With the advent of computers, some tech­ niques in nucierical analysis involving difference equa­

tions can now be efficiently performed. This has.caused an increased interest in difference equations. PART III - DEVELOH'IEW.r OF f1IETHODS OF SOLUTION

TO DIJ?l!,EHENCE EQUATIONS

The method os solution to various types of

difference equations will be presented and proved in this

part. Of primary interest w~ll be Linear Difference

equations with constant coefficients. Also considered will be Linear Difference equations with variable coefficients.

Section 1. Linear Difference Equations with

Constant Coefficients. Defn: A difference equation is linear over a set S

.of integers if it can be written in the form

where f , f , ••• fn' G are defined functions of k 0 1 : vk Es. Equation (4) is said to be a linear difference

equation with constant coefficients if ·all f fn 0 ·are constant functions.

Defn: A function Yk = f(k) is a solution of a .difference equation over a setS if the values of Yk reduce the difference equation to an identity over S.

-Linear difference equations with a constant coeffi­

cients are classified according to order and homogeneity.

The order of the equation is determined by the value of n

in equation (4). This value of n determines whether the

? B

eq\lations have first, second, third, e~q~ gtff.e;-ence§l ?-11 them~ The homogenaity of the equation i~ g~t~~mtJ1~d 9! (}(k) ;in equation (4). If G(k):: o, Vk e §,then equat:L9n

(4) ;is a homogeneous equation. Otherwis~ ~t ;is non-

~omogeneous.

~n .f:j_nding the complete solution to e I19J1-:--h()mogeneous equation, the so+ution to the. homogeneo~e part :ts gomb:i11ed wiih the particular solution to the non~h9ffl()geJ1eous p~rtr

Now to the methods of solution

Q~deF 1 equations ()f the form Yk+l =.A~~ ·t ~ {~) wh~~~ A and B ~~e const?nts will be con~i~~p~g f~~§t;;, ~h~:rl ~ases where B is a funct;;:Loi1 of k, \1~ E §,

There are three cases to consider: !i A~Q? ~~; A#~!

~I~; A=J.-.

Case I: A~ 0 in ~k+l ¥1 = Q yo + B y2 = 0 yl + B

¥k+l? O ~k + ~ ~k = B Qase II: A I + :i_n Yk+l = A Yk + B

~1 -- f\ ¥o + B "'; 2 -- A ~ 1 + B - A ( AY: o + ~ ~ t :§

A?Y + B(A ± 1} - ... -9 - . 7 _,_ / 9

2 A y2 + B = A A Y +. B(A + 1) + B y3 = 0 2 A3Y + BA BA + B = 0 + = A3Y + B (A2 + A+ 1) 0 etc. From this one can see a pattern begin to develop: Yk =Ak Y + B(A- k 1 +Ak-2 + .•.• +A2 +A+ 1) (6) 0 2 This would be a good result if (Ak-l + ~·· +A +A +1) (7) could be reduced to a simple expression. Fortunately this is possible. Equation (7) is a geometric progression

whose sum is 1 - Ak if A -1 0 (8) -r-=A:- Thus the solution becomes Y = AkY + B(l_- A~) k o \1 - A (9) as a result of substituting equations (8) for (7) in (6). Case III; A = l in Yk+l = A Yk + B For the case where A = 1 the solution given by equation (9) does not hold as it becomes 0/0, an inde­ terminent result. The expression (7) becomes a series of l 's as (lk-1 + -lk-2 + ••• + 1 2 + 1 + l ) • One raised to any power is one. Thus expression (7) is k ones being added together. The solution now becomes 10

In summary = B for A = 0 ky 1 - Ak = A + B A 1 (10) 0 y-::-A for f. .for A = 1

The solution given in equations (10) is the

solution to equation (5) for a given Y • What follows is 0 a demonstration of the. validity of equations (10).

Part 1 A = O, yk+l = A Yk + B (11) Equation (11) reduces to yk+l = B which is the same as yk = B Part 2 A I l, 0 Yk+l = A Yk + B This will be proved by substitution. Let k = 0 Equation (lOb) reduces to 0 Y AOy + B { 1 - A \ 1 = 0 \1 - A)

( 1L~) -A

y = 0 This is an identity. Now assume equation (lOb) is true for k and show it is true i'or k + 1, ie show y Ak+ly + B(_l_~) k+l = o · \ 1 - A is equivalent to yk+l = A yk + B where Yk = Akyo + B (l-=L)1 - A 11

" '

Doing the necessary algebra

A AkY + B(:l=._~~) '+ B (12) yk+l = 0 l - A

AAkY + B . A (_1 - A~-) + B = 0 l - A 1-- A = Ak+ly + B k) + 1 . 0 A(----1 -A .

Now + 1 =

So (12) becomes k+ly l - Ak+1 yk+1 = A o + B -y-=~- The case· for A .P. 0, 1 has been shown valid \7 k E S.

Part 3 for A = 1. Again use substitution of (13) into

Doing this one gets an identity.

Yk+1 +·B(k+1) a Yk~l + Bk + B

The case for A = 1 has been shown valid 'rfk E: S. Therefore the solutions given in equations (10) is the solution to Yk+ = A Y + B for a given Y , A and B 1 0 0 which are constants. When B = 0, the equation is a homogeneous equation of order 1. When B is a non-~ero constant~ the discussion 12

covers a particular type of non-homogeneous ~quation.

It will not be proved but it can easily be shown that if the solution to equation (5) given in (10) is multiplied by a constant, this solution is also valid.

Now let us consider Yk+l = A Yk + B(k) (1~ where A is a constant and B(k) is any arbitrary non-

constant function of k. The complete solution to equation (15) will be the

sum of the solution to Yk+l = A Yk + 0 (16) and one particular solution to equation (15). The form will be y(h) k + Now Y~h) = C (Ak) is a solution to the homogeneous part

·Of equation (15). This can be verified by equation (lOb)~ To solve the complete equation one tries to find a particular solution yCP) which is a function of the same k type as B(k). Then try to evaluate the various coeffic-

ients that appear in the yCP)k that. one is trying. This method is called the method of undetermined coefficients.

It is this author's opinion that the method of undetermined coefficients is the best and the easiest to

use. :B!or those functions that can·not be worked by this method, an alternative method described at the end of

this part may be used.

The method of undetermined coefficients is best 13

illustrated by two examples: 2 1. Find the complete solution of Yk+l +3Yk = k (17)

First, the solution to the ho~ogeneous part:

yk+l = -3Yk

By equation (lOb) Yk = C (-3)k is the solution. Now· try a particular solution of the form: 2 y~P) = F k -+ G k + H (18a) also needed is 2 y(p) = F (k + 1) + G (k + 1) + H, (18b) k 2 = Fk + 2Fk + F + Gk + G + H Substituting equations (18a,l8b) into (17), one gets: 2 2 2 Fk + 2Fk + F + Gk + G + H + 3(J!'k + Gk + H) = k or on removing parenthesis 2 2 2 .Fk + 2Fk + F + Gk + G + H + 3Fk + 3Gk + 3H = k Separating the terms by powers of k 2 2 (F +. 3F)k = (2F + G + 3G)k + (F + G + H + 3H) = k simplifying where possible 2 2 (4F)k + (2F + 4G)k + (F + G + 4H) = k Solve for F, G and H be equating coefficients of like powers-:

2F + 4G = O•k F + G + 4H = 0 14

Solving for F, G and H 2 2 4Fk = k 4F = 1 ·F 1/4

2Fk + 4Gk - 0 2/4 + ~G =0 G .= ~/8

F t G + ~H = 0 1/4- 1/8 + ~H 0 4H =·:-1/8 H = -1/32 Therefore

The· ~omp~ete solution is y ~ yC~) + yCP) -k. -k . -k or after substitution

~k ~ ~ (:-~)k j- ~k2/~ ~ ~~~ ~ 1/~2)

(19)

¥~~st, the solution to the ~~m~g~~eous part: 0 ¥-k+l

yk+l = 4 yk

By equation (lOb) Y~h) = C (4)k is the solution

Now try a particular solution of the form: yC p) (6)k k -· c (20a)

yC p) c (6)k::t-~ 6C (~)k (20b) -k - -

Both ~·gu~t~o~~ ( ~Oa ,?()b) <:lr~ neeQ.ed for substitution into (~9)~ P<:l~I1g this one g~ts ~g \~)~ ~ ~G (~)~ _ 6~ 15

c = l/2 .This was done by ·equating coefficients of like terms and solving. ·Therefore

The complete solution is yk = y~h) ·+ y~P) or after substitution

Now let us consider linear difference equations of higher order (2 and 3). Both homogeneous and non-homo­ geneous types will be considered.· To illustrate the pro­ cedure, I will discuss the solution to equations oi order two and three, with constant coefficients. Ord,er two homogeneous equations are of tho form

where A1 and A2 are constants •. Homogeneous difference equations have an associated 2 characteristic equation: M + A M + A 0 1 2 = (22)

This equation (22) is found by substituting Yk = JVlk into equation (21) and by suitable algebraic techniques generates the characteristic equation ·(22) • . One can find the solution to equation (21) in the k . . form of Yk = M for suitable values oi M. These values forM are the roqts of equation (22). The nature of the 16

solution will depend on the values of M. If the two roots o.f (22) are· real and equal, the solution (23)

If the two roots of (22) are real and unequal, the solu- tion has the .form: (24)

If the two roots of ( 22) are yomplex nwabers in the form of R Cis( 0), the solution has the form~

Yk C RkCos(k9) + C RkSin(k9) = 1 2 (25)

I.f 0 R 1 then the solution converges ~s k J otherwise i~ diverges.

Example: Find the solution of (26) Yk+2 + 2Yk+l - 15Yk = 0 2 The characteristic equation is M + 2M - 15 = 0

Its roots are M = 3, -5 Thus the solutions are

By Theorem 3.1 in (goldberg 1958) the general solution to an order two homogeneous equation will be a linear combin- ation of y(l) and yC 2 ) expressed as yk =C y(l) +C y(2) k k 1 k 2 k • 1 2 Proof:· By hypothesis Y~ ) and yCk ) . are solutions to

Yk+2 + A1 Yk+i + A2Yk = O. We need to show that c1 y~l) +,C 2Y~2 ) is also a solution. By substitution and suitable algebraic techniques one gets: cl[ y~!~ +AIy~!f +A2Y~ 1~ + C2ry~:~ +Aly~:l +A2Y~ 2~ = 0 17

That this sum is equal to zero should be· clear as each sum

in parenthesis is zero. Thus the theorem is prove~.

The exact form will depend on the roots of the charac-

teristic equation •. In this example the general k k solution to (26) is Yk = c1 (3) + c2 (-5) This was an example of the case where the roots are

real and unequal.

Order two non-homogeneous difference equations are (27)

where A and A are constants and B(k) is a function of 1 2 k, \fkEs. All non-homogeneous difference equations have as

part of their solutions the solution of the corresponding "homogeneous equation. For instance consider the equation 2 Yk+ 2 + 2Yk+l - 15Yk = 4k -· 2k + 5 (28) Part of the solution to equation (28) will be the solution to the homogeneous equation

(29)

The solution to this equation (29)_begins on the previous page of this thesis. The complete solution to equation (28) is a linear combination of the particular sqlution

to equation_(28) and the solution to (29).

As an example of finding the complete solution to 18 0 .

a non-homogeneous equation, lets use equation (28)o 2 Yk+2 + 2Yk+l - 15Yk ~ 4k - 2k + 5 (28) The solution to the homogeneous part is

yk = Cl(3~) + C2(-5)k (29)

which is found on the top of· page 17 of this thesis.

To £ind the solution to.the non-homogeneous equa- tion, one tries a solution in the form: 2 Yk = (a function in the form 4-k - 2k + 5). In this example the trial solution is

y~ P) = Ak2 + Bk + C (30) K The constants A, B and C will be evaluated when y~P) .is substituted into equation (28). One also neads these two forms of (30)

yk+l = A(k + 1)2 + B(k + 1) + c

yk+2 = A(k + 2)2 + B(k + 2) + c

Substituting these into equation (28) one gets 2 2 A(k + 2) + B(k + 2) + C + 2(A(k + 1) + B(k+l) 2 2 + C) - 15(Ak + Bk + C) ~ 4k - 2k + 5 .Removing parenthesis 2 2 Ak + 4Ak +4A + Bk + 2B +C + 2Ak + 4Ak +2A +2Bk 2 2 +2B +2C - 15Ak -15Bk -15C = 4k - 2k + 5

Collecting like te~ms and simplifying 2 (A + 2A - l5A)k + (4A + B + 4A + 2B - 15B)k + 2 (4A + 2B +C + 2A + 2B + 2C - 15C) = 4k -2k +5 19

which simplifies to 2 (-12A)k + (8A - 12B)k + (6A + 2B - 12C) = i • 2 4k 2k + 5 . Equating coefficients of like terms 2 2 (-12A)k = 4k A = -1/3 (8A - 12B)k = -2k B = -1/18

(6A + 2B - 12C) = + ~ C = -65/108 Thus the particular solution to equation (28) is

yCP) = -k2/3 -k/18 -65/108 k The complete solution is 2 Yk C (3)k + (-5)k -k /3 -k/18 -65/108 = 1 c2 which is a combination of the homogeneous solution and

the particular (non-homogeneous) solution

IMPORTANT NOTE: For the method of Undetermined Coefficients to work, no term in the homogeneous solution can appear in the

trial solution. If any term in the trial solution does appear in the solution of the homogeneous part, the trial

solution must be multiplied by a positive integral power

of k which is just large enough so that no term of the new trial solution will appear in the solution to the homogeneous part. If this procedu~e is not followed the particular solution, when substituted into the equation being solved, will produce a zero result. This makes no contribution to the B(k) function for the problem. (See 20

equation (27).) When the procedure is followed the par­ ticular solution, when substituted into the equation being solved, will p~oduce the required B(k) function fo~ the problem. Example: Find the 'complete solution of . k k Yk+2 - 4Yk+l + 4Yk = 3·2 + 5·4 The solution to the homogeneous part is

y~h) = c (2)k + c k(2)k (See pg 16 for method) 1 2 Under normal circumstances the trial solution would be

k This trial solution will not work as the term c (2) 3 appears in the solution to the homogeneous part. So it is 2 2 multiplied by k yielding c k (2)k. This is not in that 3 solution so it is acceptable. Thus the trial solution is

y~P) = 03k2(2)k + 04(4)k

The (4)k term was left alone as it did not appear in the c4 solution to the- homogeneous part of the equation.

NOTE 2:

Sometimes the method of undetermined coefficients will not work at all in finding a particular solution to a linear difference equation with constant coefficients.

An alternate method, a form of variation of parameters, can be used. It uses the following procedure: 21

1. The solutions to the homogeneo~s part of the equation will be designated as y~l), Y~ 2 ) etc. These solutions are computed in the manner described elsewhere in this thesis. 2. The ~ronskian ·wk(y(l), Y( 2 )) is computed using the

formula W (Y(l) yC 2 )) - y(l)y( 2 ) - yC 2 )y(l) (31) k ' . .,- 'k k-1 k k-1 3. Two auxiliary equations are computed: B(j+l) y\2 ) ------riJJ_\2;-- w.1CY ,Y ) t==o J+ (32) ~ B(j+l) yC.l) ~ ------rr;J~2;-­ t--;O \vj+l(Y ,Y )

where B(j+l) is the function B(n) evaluated ·at j+l. 4. The particular £unction for the given equation will be: Y(p) - u y(l) + v y(2) k - k k k k (33) This procedure was presented by Dro W. Nathanson in a Numerical Analysis course at CSU-Northridge (Spring 1977)o

Example: Consider the equation

Xn ·+ 2X n-l + Xn- 2 = 1/n (34) Solution to the homogeneous part: By following procedures on pages 15-17 of this thesis one obtains the characteristic equation 2 M + 2M + 1 = 0 The roots are M = -1, -1. The solution to.the homogeneous· 22

part becomes: (35)

The solutions (-l)n and n(-l)n-l will ba designated as y(l) ~nd Y( 2 ) respectively. n n

Solution to the non-homogeneous part: Since the method o.f undetermined coefficients does not work for this problem, the method just described must be 2 resorted to. Computing the Wk+l(y(l),Y( )) by procedure

found on page 21 of this thesis its .found to be = -1 k.

By making proper substitutions into equations (32a,b) one gets un = ~~(-l)j+l(j/(j+l)) f=O (36) Vn = ~~(-l)j+l(l/(j+l)) t=() The partic~lar solution, yCP), is found by substitution . n "of equations (36a,b) into equation (33).

The ~omplete solution is :

yn = y~h) + y~~) = Cl(-l)n + C2(-l)n-l + . hL. (-l)nL (-l)j+l(j/(j+l)) + n(-l)n-lf~-l)j+l(l/(j+l)) 1-:o J--;0 . 23

Section 2. Linear Difference Equations with

Variable Co~fficients. Linear difference equations with variable coeffi­

cient;s o.f the i'irst order can al·.~ays be solved. Those of higher orders are not always solvable. The procedure frequently used involves a variation of parameters tech­ nique, As for equations with constant coefficients, linear equations with variable coefficients are divided into homogeneous and non-homogeneous types. The procedure, similar to equations with constant coefficients, requires solution th the homogeneous part as well as the non-homogeneous part. The solution to the homogeneous part will be done first as this solution will be used in determining the solution to the non-homogeneous part,.

Lets consider the e~uation Yk+l - A(k)·Yk = B(k) (37)

First the solution to the homogeneous part:

yk+l - A(k) yk = 0 (38) which can be rewritten as (39)

From equation (39) one gets the following sequence:

yk = A(k-1) yk-1

yk-1 = A(k-2 ) yk-2 24

etc. to

Substituting appropriately one equation into another the above series of equations, one gets:

Yk A(k-l)A(k-2) .••• A(l) Y (40) ~ 1 §inc~ Y (40) 1 is an arbitrary constant, equation can be rewritten as

y(h) = c A(k-l)A(k-2) A(l) (41) k 1 Now the solution to the non-homogeneous part. To do this replace in equation (41) with a function K(k). c1 The equa~ion now becomes !~p) ~ K(k)A(k-l)A(k-2) ••• A(l) (42) !<(}<:) ie to be determined so that when equation ( 42)

~~ §Ub~tituted into· (35) the equasion is satisfied. ·when substitution is made, equation (35) looks like: K(ktl)A (k)A(k-1) ••• A(l) - A(k)K(k)A(k-l) •.. A(l) = B(K) (43) Not~ce that A(k) ..• A(l) is in both terms on the left

side of equation (43). It can be factored out. Now divide both sides of the equation by this factor. Equation (43)

becomes K(k+l) - K(k) = ~(!D."'"" __ _ . A{i{)A(k-1) ••• A(T) §ub~t~~ut~ng K for K(k+l) - K(k) this becomes (44) 25

/\-1 Using the inverse operator ~ on (42) ·one gets A-I B(k2 K(k) = ~-T~-TA\kJA\k-1; ·--,------~) ..• A\1

(45)

Now take equation (45) and substitute it into equation (42).· Doing this one gets

y~P) = A(k)A(k-1) A( 1) ~ -r::~J1{1?2 ___1-i" (46) . . . -p-;1 A\PJ •••• A\1) Combining equation (46) with (41) one gets _.j B(_p) Yk = c1 A(k-1) • • . A( 1) + A(k) • . • A(l) j;j 'lt(p):-. :--'Ati) as the solution to equation (37) Example: Solve the equation (47)

First the solution to the homogeneous part: (48)

Equation (~8) can be rewritten as

(49) From equation (49) one gets the following sequence of equations: yk = (k-l)Yk_2 yk-1 = (k-2)Yk_2 etc. to

y2 = (l)Y1 26

Thus by appropriate substitutioris with the above sequence one gets: Y~h) = (k-l)(k-2) ••• (l)Y1 = (k-1) !Y 1

Since Y is an arbitrary constant, it can be replaced 1 with cl. (50)

Now for the solution to the non-homogeneous part: The trial solution is: . y~P) = K(k) (k-1)! (51)

which is found by replacing c1 with K(k) in (50). Next compute the particular solution for k+l y(P) = K(k+l) (k)! (52) k+l . Next K(k) is determined by substituting equations (51,52)

into (47~. Doing this one gets: K(k+l) (k)! - kK(k) (k-1)! = k . (53) Factoring out (k)! which appears in both terms,

one gets: (K(l_(+l) - K(k)] (k)! = k Dividing both sides by (k)! k 1 K(k+l) - K(k) = -rkJT = tk=IJ! (54) Using the !J.. operator in place of K(k+l) ·-K(k) ~ K(k) = 1/(k-l)! Now determine K(k) by using the inverse operator

1 K(k) = b- ~/(k-1) y ?-7.

Expressing the result in summation form I< K(k) = :£ 1/( p-1)! . f' =-1 Therefore Yk(p) = (k-1)! {i;(p-1)! (55) 1':::-f And therefore the complete solution is k Yk = c (k-l)! + (k-1)! 2 1/(p-1)! 1 p=r PART IV THE APPLICATION OF DIFFERENCE EQUATIONS

Difference equations have useful application in fields o.f study where quantitative work is done on - , discrete intervals. Examples of how difference equations can be used in selected areas of study will be given in this part. The topics that are included are: 1. Sequences of Numbers 2. Pythagorean Triples 3. Finding Certain Zeros of a P(x)o 4. Biological-Population Dynamics 5. Numerical Approximation to Differential Equations

This _part will be divided into sections according to the topics listed. In each section will be presented a discussion o.f the methodology used as well as examples to illu_strate the procedures developed

28 29

Section 1. Sequences of Numbers

The authorJs first encounter of difference equations came as ·a result of their use as recursion formulas for sequences of numbers. At that time the label "difference equation" was not· used. Consider the number sequence

5' 8' 11' 14' 17' 20' ••• (56) This sequence of numbers is an arithmetic sequence as the difference between consecutive terms is constant. In this case the difference is 3. Thus each term can be found by adding 3 to the previous term. From this one can determine arecursion formula for (56), namely:

= An- l + 3 (57) In form it is a difference equation4 It is a first order difference equation and An can be solved for in terms of n. As equation (57) can be rewritten as

it is a first order difference equation of the form where A and B are constants. In this case A = 1 and B = 3. Its solution, found on pages 8-10 of this thesis, is of the form Yk =. Y0 + Bk, where Y0 is an initial constant. In this problem An is being used for Yk, thus the solution is 30

(58)

Geometric series have difference equations as

their recursion formulas also. Consider the sequence

3, 6, 12' 24' (59) Geometric number sequences, unlike arithmetic sequences,

have p common ratio from one term to the next. In this

example, the common ratio is 2. This rat~o will appear

as the coefficient t6 the An term. Thus the recursion formula is (60) An+ l = 2A n Solving equation (60) for A , using the results on n pages 8-10 of this thesis, one finds A = 2, B = 0. The solution becomes

which is equivalent to A = 2n(A ) n o (61) A .can be found by substituting terms from the sequence 0 (59) in to the solution, equation (61). Doing this it is found. that A = 1.5. Therefore 0 (62) . In each of these two examples the expression for An in equations (58) and t62) giyes the value for the term in a sequence knowing what position it holds in that sequence. ~he term 'position in the sequence' is used 31

here to mean first term (n =l), second term (n = 2), third term (n = 3), etc.

Arithmetic and geometric sequences are not the only classification of number sequences. An example of a sequence that is neither arithmetic nor geometric is the Fibbonaci sequence 0' l' l' 2' 3' 5' 8' 13' . . . (63) Here the n-th term is equal to the sum of the two preceding terms. The recursion formula is:

An = An- l + A n- 2 (64)

It can be rewritten as (65)

As a difference equation, it is of order two and homogeneous. It's associated characteristic equation is: m2 - m - 1 = 0 (66) The roots of equation (66) are: l - l ---2--f5 m = ---2-+ 1i-

Thus the solution to equation (65) is

An = cl ( _J:_~--lf2"jn + c2 ( _1_ 2--~n (67)

Now let us evaluate and in For computational c1 c2 (67). purposes, equation (67) will be rewritten as . -32 values of and can be found by solving a system of c1 c2 two equations and two unknowns. Doing this one gets:

c1 = o.27639, c2 = 0.72093 The solution, equation (68), becomes:

+ An = 0.27639(1.618039887)n 0.72093(-0.618039887)n (69)

Ot!her number seq~ences have their own recursion formulas. As difference equations, they have solutions that express the value of any term, given the position it holds in the number sequence. ..33

Section 2. Pythagorean Triples or a System of Difference Equations

Difference equations may appear as a system of equations where the solution of one may depend on the solution of one or r.tore of the other equations. If one equation can be solved by itself, the solution of the system is made easier. An interesting system of difference equations generates pythagorean triples X, Y, Z such that 2 2 2 x + Y = z • The difference equations are:

xt == xt-l + 2

Yt = Yt-1 + xt + xt-1 (70)

v . l .Z t "" ~'t· +

The initial conditions are:

(71)

The solution of the system: Equation (70a) is an order one equation. It can be solved via procedure found on pages 8-10 of this thesis. Doing this one gets: xt = 1 + 2t (72)

Equation (70b) is also of order one, but has Xt terms. Substitution of equation (72) into (70b) one gets: yt = yt-1 + (1 + 2t) + (1 + 2(t-l)) which, after some simplification, becomes:

yt = .Yt'""l + 4t (73)

Rew~it~ng equation (73) as: (74)

QI1~ j.mmediateJ_y :recognizes it as fin order one non- homogeneous dj_fferenc E3 equati<;m. J!,o)_J_o\

!~p) ::= At + ~ (79)

t§ t9 -~e ysed, However, a§ ~ t~~m :in th:is trial solution also appears in the solution _to the homo­

geneous pa~t, equation (76)'s right side must be multiplied by an integer power of t large enough so that no term in (76) appears in (75). In this case t 1 does quite well. So the trial solution to be used

is: (?7).

The !o~~ fo~ t~)_ i?: Y~E{ = A(t ··- ((8) 35

Substituting equations (77) and (78) into (74) and following procedure, one gets: 2 2 At + Bt - (At - 2At + A + Bt - B) = 4t Removing parenthesis 2 2 At + Bt - At + 2At - A - Bt + B = 4t Simplifying, collecting and factoring like terms: 2 (A - A)t + (B + 2A - B)t + (-A + B) = 4t Equating coefficients of like terms:

A - A = 0 A is a constant B + 2A. - B = 4 A = 2, B is a constant -A + B = 0 B = 2

Thus th~ particular solution becomes

y~P) = 2t2 .+ 2t (79)

Combining y(h) and yCP) one gets Yt = 2t2 + 2t +.a constant (80)

Using Y1 = 4, the constant in (80) will be evaluated. 2 4 = 2(1) + 2(i) + a constant

4 = 2 + 2 + a constant For this last equation to be true the constant has

to be zero. Thus the constant in equati~n (80) is zero. Therefore the solution to (70b) is: 2 yt = 2t + 2t (81)

Equation ( 70c) makes use of equation ( 70b). In .fact if the solution to (70b) is substituted into 36

(70c), the solution is obtained

zt = 2t 2 + 2t + 1 (82)

THEOREf1:.The equations (70a, 70b, 70c) whose solutions are given as equations '(72, 81, 82) will generate pythagorean triples satisfying:

X 2 + y 2 = z 2 (83) t t t :for all t E. z+.

PROOF: I:f equations (72' 81' 82); xt = 1 + 2t, 2 2 yt = 2t + 2t and zt = 2t + 2t + 1·, wili generate 2 2 triples E: z+ z 2 pythagorean t ' xt + yt = t will have to be satisfied. By substituting equations (72,

81, 82) appropriat~ly into (83) one gets:

(1 + 2t)2 + (2t2 + 2t)2 = (2t2 + 2t + 1)2 (84) If this equation will reduce to an identity the theorem is proved~ Expanding and simplifying (84) as necessary

(1 ·;4-t +'+t2 ) + (4t4 +8t3 +4t2 ) = (4t4 +8t3 +8t2 +'+t +1) Removing parenthesis and collecting like terms

As this last equation is an identity t € z+, the theorem is proved. Q. E. D. .. 37

Section 3. FindiP-g the Zeros of a P(x)

The Bernoulli Nethod of finding the largest zero of a P(x) ~ay be explained by using difference equations. The method starts with the general polynomial equation P(x) = A Xn + A Xn-l + • • • + A X1 + A (85) n n-1 1 0 This equation gives us the coefficients for an Nth order Di1~ference equation as follows:

If the roots of (85) are real and distinct, then

(86)

The various Ci depend on the initial conditions necessary to solve equation { 85). Order the roots by their magnitude with being the largest root and then one c\ 1 can write

ffl c{ k uk = ~c .. = c 1 o\1 k + c i o( i I ~ ~ 2

= c 0 1 ~ 1 [l /f~!]-:z. c1 ,~u a\1' cl ~ Limit uk+l If c1 1 o one gets k-+CO -uk- = o(l (87)

"The essence of the Bernoulli Method is to find sucessive valu·es of Uk until the ratio in equation (87) converges to a limit. For the method to work I 0. As it turns out all c1 38 p '

the various Ci may be taken to be 1. This is by a theorem in (Ralston 1965} page 365.

~he ~nitial conditions are all determined by .... (88) + A· n,.. M+ 1u1 + M An- M = 0 whe~e M = 1, 2, 3, ' . . ' n. ~o use this equation, look at the original P(x) to

~etermine the highest power of X. Write the P(x) starting with the t;erm of the highest power of X and go~_ng down­ ward j..n power of X to the constant term. Be sure all powers of X are represented, even when the coefficients

~~e ~ero. ~he iL~tial , first condition, u1 is !ound by

~§ipg 1:;w6 terms 9f equation (88). u1 has the coe!fiGient 9! the highest power of X and the constant term in

~quation (88) is the coefficient of the next highest power of X multiplied by M = 1.

An· u 1 + 1 An- . l = 0

The second initial conditipn, u2 , is found by using three terms of equation (88). u2 now has the coefficient of the highest power of X, u the next highest power of X, and 1 the ~opstant term in (88) the third highest power Qf X multiplied now by M ~ 2.

APU. 2 + An~~U~ + 2An_2 = 0 For more than two initial conditions the pattern is

Pimi~a~. The process continues until all coefficients are used. 39

To illustrate Bernoulli's Method two examples follow:

Example 1. Find the largest root of 2 x3 - 5X - 17X + 21 = 0 using equation (88) as described above

ul + (1)(-5) = 0 ul = 5

u2 - 5U1 + (2)(-17) ;:: 0 u2 = 59

Now using equation (86) in the form of

or for e.asier computation

one generates several values of Uk fork= 4, 5, 6, ••• until the limit in (87) converges. The results of· such computation is shown in Table I.

TABLE I

The values of uk, Uk/lk-1 for k = 4 to 13

k uk Uk/1k-l 4 2,483 7.83 5 16,565 6.67 6 118,379 7-15 7 821,357 6·.94 8 5,771,363 7.-.03 9 40,333,925 6.989" 10 282,534,299 7.0048 11 1,977,149,597 6.9979 12 13,841,818,640 7.0009 13 96,887,416,090 6.9996 . .40

It looks like the Limit Uk A'rk-l =. f<-CO /- 7 It may be verified that ~1 -= 7 is the largest root of 2 P(x) = x3 - 5X - 17X + 21. To find the remaining roots· of P(x), divide P(x) by X - 7 and apply the procedure again to find the next largest root.

The next example will show what happens when the root(s) of the largest magnitude are complex numbers. Before the example is shown, some further discussion is necessary. If the root(s) of the largest magnitude of equation (85) are complex, equation (87) is still evaluated as before and will be found not to c~nverge. This is the clue that the root(s) of largest magnitude of equation (85) are complex. In this case the following two ratios will be computed: 2 -----uk - uk+l uk-1 2 (89) (uk-1) - uk uk-2

Limit k 400 (90)

Both equations (89) and (90) will be iterated with k increasing until the convergence of the two limits is recognized. The roots in this case will have the form z = (91) where and f3, f7, an9, 7l_ are all real numbers Example 2. J:t,ind the largest root( s) of 2 z5 + 12z - 21 = o (93) Since equation (93) does not. have all the powers of Z represented, it should be rewritten so that it does. z5 + o z4 + o z3 + 12z2 + o z - 21 = o (94)

No·w using equation ( 88) as before, one gets:

ul + (1)(0) = 0 ul = 0

+ + (2)(0) 0 u2 o u1 = 0 u2 =

u.3 + o u2 + o u1 + (3)(12) = 0 u3 = -36 u4 + o u3 + o u2 + 12U1 + (4)(0) = 0 u4 ·= 0 o u + o u + 12U + o u + (5)(-21) 0 u :;: 105 u5 + 4 3 2 1 5 Using a difference equation of the form of equation (85b), one gets:

uk + o uk-l + o uk_2 + 12uk_3 + o uk_4 -21uk_5 = o or with the terms containing zero coefficients dropped

uk + 12 uk_3 - 21uk_5 = o (95) Rewriting equation (95) for easier computation (95b) Now compute Uk fork= 5, 6, 7, •.• until the limits in equations (89) and (90) both show evidence of 42

convergence. The results are shown in Table.II.

TABLE II The values o.f uk' f3k') t:;k for k = 5 to 23 k uk fk sk 5 105 1.70783 2.05714 6 432 4.11429 2.05714 ? 0 2.16025 0.56?13 8 -2016 2.16025 1.285714 9 -5184 2.77597 1.285?14 10 2205 2.37932 0.888108 11 33064 2.33818 1.016266 12 66208 2.52055 1.145634 13 -68796 2.42908 1.024600 14 -508032 2.40360 1.080290 15 -700191 2.45435 1.096984 16 15211-100 2.43636 _1.065068 17 7402750 2.42652 1.076052 18 6957580 2.43836 1.081978. 19 -28957800 2.43568 1.075030 20 ~103537000 2.43313 1.076518 21 -51484900 2.43509 1.077848 22 502952000 2.43490 1.076954 23 1388550000 2.434-66 1.077016

Using the va1ue·s from line 23 in table II, P= 2.4347 and s= 1 .. 0770

Equation (92) allows one to find '1(_. 2 2 "L= J2.4347 - 1.0770 . (96)

Therefore the root(s) of largest magnitude o.f 2 z5 + 12 z - 21 = o is

z = 1.077 ± 2.1835i 43

t>ection 4. Biological - Population Dynamics

Difference equations are used in the study o! pop­

ulation dynamics where information is desired only at

certain t~me intervals.

To illustrate their use in population dynamics two examples are taken from this author's notes for Math 525, Mathematical Models, taught by Dr. T.P. Lin at CSU, Northridge in the spring 1975 semester. I will use two examples fr6m that course. While the examples apply specifically to rabbits the ideas presented will apply to

any animal.

Example 1. Population of Rabbits

The problem is "Find the number of pairs of rabbits

in the Tth month under the following assumptions:

A. Every pair of rabbits produces two pairs of rabbits in every month except during the first month after birth.

B. No rabbit will die.

C. lnitially there is one pair of new born rabbits.

To solve this problem two additional assumptions have to be made concerning missing information: l. All events occur at the same time of each month. 2. Each pair of rabbits consists of one male and one

female rabbit and are able to reproduc~.

Solution:

To get an idea of what the information that is given I •

looks like, lets construct a table showing how the population of rabbits will increase with time.

TABLE III Month Reproducing New born 1 month old Total rabbit pairs rabbits rabbit pairs 0 0 1 0 1 1 0 0 1 1 2 1 2 0 3 3 l 2 2 5 4 3 6 2 11 5 5 10 6 21 6 11 22 10 43 7 21 42 22 85 8 43 86 42 171 9 85 170 86 341 10 171 .342 170 683

Now it is necessary to determine if possible, the existance o.f a difference equation relating the data. It looks like to .find the value for the current month in each column, add the values for the preceding month to twice the value of the month before that. This translates to the difference equation: (98)

"Using procedure described in Part III of this thesis it will be found that equation (98) is a second order homogeneous difference equation with constant coefficient~ To readily solve equation (98), it should be rewritten as 45 ~ .

or as (99)

Following procedures outlined on pages 15-19 of this thesis, equation (99) has the associated characteristic equation 2 M - M - 2 = O. (100) Its solutions are M = 2, -1. At will have a solution of the form t t At = c1(2) + c2(-l)

To find the values of c1 and c2 , use data from lines 5 and 6 from the "Total" column from Table III. This is done as one is concerned here with finding an expression for the"total rabbit population versus time in months.

t = 5 At - 21 t = 6 At = 4.3

21 = ·cl(2)5 + C2(-1)5 6 (101) 4.3 = Cl(2)6 + c 2 (-1) Solving equations (101) for cl and c2, one gets c 1 = 2/.3, c2 = 1/.3 Therefore the solution is

At = (2/.3)(2)t + (1/.3)(-l)t (102) This gives the total number of pairs of rabbits at any time t months after the start of the experiment as 46

required by the problem.

·Commentary This problem, as presented, is of limited scope in

that certain as~ects of living things were not considered. Among them were: 1. All living things eventually die. This can be handled by using an average life time and making a subtraction accordingly. This can be done by using a -An- k term in equation (98) where k is the number of time units of the average'life of the species, and all negative subscripted terms have a value of zero. (Third term.) 2. Variations in the birth rate can be handled by appropriate constants in equation (98). The coeffi­ cient of the second term depends on the birth rate, which may be constant or variable. The time at which the specie.s can give birth will determine the sub­ script of the second term. 3. Living thing? do not, as a rule, reproduce during their entire life time. There is usually a period after birth and before death where reproduction does not occur. This can be accounted for by appropriately modifying the second term of equation (98). Although this problem dealt with rabbits, this problem is readily adaptable to any living thing by

. appropriate chan~es in the constants of equation (98). 47

Example 2 .. Food consumption in. ·Example l.

"If every pair of rabbits in Example 1 consumes one barrel of carrots per month, find the total number· of barrels of carrots consumed to the end of the Tth month."

This problem is also taken from the author's notes for Math 525.

Solution: As in ·the previous example a table will be con- structed to show how the data is related.

TABLE IV Month Total rabbit Barrels of Total pop. in pairs carrots consumed consumption 0 1 1 1 1 1 1 2. 2 3 3 5 3 5 5 10 4 11 ll 21 5 21 21 42 6 -43 43 85 7 85 85 170 8 171 171 341 9 341 341 682 10 683 683 1375

By much trial and errcr, the difference equation for total consumption is found to be (103) 48

As An = (2/3)(2)n + (1/3)(-l)n found previously, this can be substituted into equation (103) for An. Now C C + (2/3)C2)n + (1/3)(-l)n (104) n = n-1 Rewriting (104)

(105)

Equat~on (105) ~s a first ord~r non-homogeneous difference equation with constant coefficients. Solving, by procedures on pages 8-10 of this thesis, the homo­ geneous part of equation (105) one gets the solution:

c(h) = A(+l)n = A n (106) Using procedures on pages 11-15 of this thesis, one now solves for the non-homogeneous part of (105). The particular solution to (105) will have the form

c~P) = a(2/3)(2)n + B(l/3)(-l)n (107) By substituting (107) into equation (105) and follow- ing procedure, one finds A = 2, B = 1/2 Thus· C(p) = (4/3)(2)n + (1/6)(-l)n· n (108) The complete solution to equation (105) is

en = (4/3)(2)n + (1/6)(-l)n + A (109) By using data: -from Table IV, one can determine the constant A. It is found that A = -1/2 Therefore the complete solution to equation (105) 49

with all constants evaluated is: 50

Section 5. Numerical Approximation to Differential .Equations.

Iri·some work of applied mathematics it becomes necessary to solve, by numerical approximation, a differ- ential equation when the equation is too difficult to solve exactly. In this section we will concern ourselves with a description of the Euler Method and a modification of it.

The Euler r1ethod Consider the differential equation dY/dX = f(X, Y) (110) with initial conditions Y(X ) = Y 0 0

If Xk+l -- Xk = h, a constant, k, we shall show tnat equation (110) can be approximated by the differential equation (111)

Proof: From the·differential equation (110) one gets

dY = (112) by separation of the dX and dY terms in dY/dX o.f equation (110) and integrating. If one considers .f(X,Y) to be a constant between Xk and Xk+l' then equation (112) becomes dX (113)

This \'Jill give us on integration: y . k+l - yk = f(Xk,Yk)(Xk+l - Xk) (114)

Equation (114) can be rewritten as

yk+l = yk + f(Xk,Yk)(Xk+l - Xk) (115)

If Xk+l - Xk is constant over the entire interval, then equation (115) can be written as: (116) which is what we wanted to show.

The Modified Euler Method The modification that is often applied involves the trapazoi~a1 rule in approximating integrals. The integral in equation (112) is approximated by

~ [ f(Xk,Yk) + f(Xk+1'yk+l)J (Xk+l- Xk) The final form of equation. (112) will be: (117) yk+l = yk + (l/2) [ f(Xk,Yk) + f(Xk+1'yk+l) J(Xk+1 - Xk) if (Xk+1 - Xk) is not constant, or yk+l = yk + (h/2 ) [ i'(Xk,Yk) + i'(Xk-1-l'yk+l) J (118)

The demonstration of this follows the same pattern as for the Euler Method. . 52

The method is best demonstrated by example. The Euler Method will be used first followed by the Modi­ fied Euler Method.

Example 1. Find the value of Y when X = 2.5 using the differential equation dY/dX = 3X - 2Y where Y(l) = 2 (119) Euler Method solution:

Let X = 1, Y = 2 and h = Ool 0 0 In letting h = 0.1 we are using a constant interval between each value of Xk. The actual value assigned to h is arbitrary and is chosen by the one solving the equation. The difference equation is

or after substituting h = 0.1 (120)

This problem may now be solved either by iteration or by-the method of difference equations. Both ways of solution will be showno

First by iteration. To solve by iteration, enough iterations to go from xo to the desired xk will have to be made for the given h. In this example X = 1, the 0 desired Xk = 2.5 and h = 0.1, thus 15 iterations will be needed. The results are shown in Table V. 53

TABLE V ) k xk yk .f(Xk,Yk = h f(Xk,Yk) Y,K+ .;. . = xk 3Xk -·2yk (h=Ool) +h•.f(Xk,Yk) 0 1.0 2.0 -1.0 -0.1 1.9 l 1.1· lo9 -Oo5 -Oo05 1.85 2 1o2 1.85 -0.1 -O.Ol 1.84 3 1.3 l.BL~ 0.22 0.022 1.862 4 lo4 1.862 Oo476 0.0476 1.9096 5 1.5 1.9096 0.6808 0.0681 1.9771 6 1.6 1.9771 0 .. 8458 0.0846 2.0617 ? 1.7 . 2.0617 0.9766 0.0977 2.1594 8 1.8 2.1594· 1.0813 0.1081 2.2675 9 1.9 2.2675 1.1649 0.1165 2.3840 10 2.0 2.3840 1.2320 0.1232 2.5072 11 2.i 2.5072 1.2856 0.1286 2.6358 12 . 2.2 2.6358 . 1.3284 0.1328 2.7686 13 2.3 2.7686 1.3627 0.1363 2.9049 14 2.4: 2.9049 1.3903 0.1390 3.C439 15 2.5 3.0439

From Table V one obtains .for X = 2.5 the value Y = 3.0439, which is what was wanted.

Before going on to the Modified Euler Method it might be worth while to consider solving the difference equation obtained as equation (120). Se~ting up equation (120) .for this problem one gets (121)

As Xk is nothing more than a multiple of h added on to an x one gets: 0 54'

xk. = x0 + h·k (122) fiow substitute equation (122) into (121) and one gets

·yk+l ~ Yk + ·o.l (3. (X + O.lk) - 2Yk) 0

= rk + O.?X0 + 0.03k - 0.2Yk

' Q.8):k + o. 3 + 0.03k (123) as X·o ~ 1 and h = 0.1.

~qu~tion (123) is a first order non-homogeneous ·

~quation. By following procedures on pages 11~15 of this th~eis, its solut~on is (124)

As ~t ~~s ~ep~red to find Y for X = 2.5, deterrn~ne the numqer of iterations required. This was done previously and found to be 15. So let k = 15. Substitute ~ = ~5

!nt9 equation (124) and one obt~ins Y = 3.0440~ This 15 agrees with the solution obtained by itetation. Suppose now it was desired to determine Y(7.3). One could procede as follows: Determine the value of k

Now p~bst~tute k = 63 ~nto equation (124) 63 l~? ? ~,25(0.8) + 0.~5(63) + 0.75 = ~9.~9

Thus Y ~0.20, 63 = . 55

The Modified Euler Method solution: Using the same equation as before · dY/dX = 3X - 2Y, · Y(l) = 2 find the value of Y(2.5). The difference equation now used is

Yk + 1 = Yk +

To get this equation into a more usable form make all the substitutions. As before f(Xk,Yk) = 3Xk - 2Yk' and h = 0.1 (126)

Since Xk+l - Xk = h (or Xk+l = Xk + h) and h is constant at 0.1 some simplification of equation (126) is possible.

yk+l = yk + 0.05( 3(Xk + xk+l) - (2Yk + 2Yk+l))

+ 0.05( -2Y yk+l = yk 3(Xk + xk + h) k - 2Yk+l)

yk+l = yk + 0.05( 3(2Xk + 0.1) - 2Yk - 2Yk+l) (127)

To get the procedure started, one iteration by the J£uler 1"1ethod is-required.

At each level of iteration Yk+l will be estimated and then refined. Using equation (l27) the following is obtained: yl = 2.0 + 0.05( 3(2.0 + 0.1) - 2(2.0 + 1.9)) = 1.1925 56

y1 = 2.0 + 0.05( 3(2.0 + 0.1) _. 2(2.0 +1.925)) = 1.9225

.Y 1 = 2.0 + 0.05( "3(2.0 + 0.1)- 2(2.0 +1.9225)) = 1.9227

At this point Y1 is now taken to be 1.923 as three place accuracy is all that is required. If Dare accuracy were desired more refinements would be necessary.

For the next round of iterations the following values are used yl ;; 1.923

y2 = 1.923

•· The initial guess for Y2 is Y1 Repeating the procedure as above one gets the results shown in Table VI, ~Ihich is shown on the next page.

Thus Y(2~5) = 3.0616

To get an idea as to how good the results are lets compare the results obtained. Exact value of Y(2.5) = 3·.25272 which is obtained by integration. The Euler Method yei.lds Y(2,5) = 3.0439. The Modified Euler t1ethod yeilds Y(2.5) - }.0616. Both of these results are smaller than the actual value, but are within 7%. 5?

TABLE VI

The results tif the iteration using equation (127). y k xk yk Estimates of k+1 yk+l 0 1.0 2.0 1.9 lo 1.1 1.9 1.925 1o9225 1o9228 1.9227 2 1.2 1.9227 1.8832 1.8871 .1.8867 1.8868 3 1.3 1.8868 1.8844 1.8847 1.884-6 1.8846 4 1.4 1.8846 1.9127 1.9099 1.9102 1.9102 5 1.5 1.9102 1.9631 1.9578 1.9584 1.9583 6 1.6 1.9583 2.0316 2.0243 2.0250 2.0250 7 1.7 2.0250 2.1150 2.1060 2.1069 2.1068 8 1.8 2.1068 2.2104 2.2001 2.2011 2.2010 9 1 .. 9 2.2010 2.3158 2;.3043 2.3055 2.3053 10 2.0 2.3053 2.4293 2.Lt-'169 2.4181 2.4180 11 2.1 2.4180 2.5494 2.5363 2.5376 2.5374 12 .2.2 2.5374 2·.6'?50 2.6612 2.6626 2.6624 13 2.3 2.6624 2.8050 2.7907 2.7907 2.7920 14 2 .Li- 2.7920 2.9386 2.9239 2.9254 2.9252 15 2.5 2.9252 3-0752 3.0602 3.0617 3.0616 @ '

1. Goldberg, Samuel; In~r2£~£~io!!._ to _Diff~~g~_§.su!~ti9_Q~. New York: John Wiley & Sons, Inc., 1958.

2. Hildebrand, F.B.; !.BE£2£uci!2!!..:_~2-1'i~~~£!£~!.~B~1.;y§.is. New York: McGraw-Hill, 1956o

3. Ralston, Anthony; !_Eirst Q~E~~!E ~~me£ic~l An~l~· New York: McGraw-Hill, 1965o

4. Spiegel, Hurray R~; Calc~1~_£:f Finit£_Diff~~!!£~_and Di£f~~£~.-~~~ti£!:!§.. New York: Schaum's Outline Series, McGraw-Hill, 1971.

5. Stirling, James; £1~1hodus Diffe£!,;_!}tialis. Londini: Typis Gul. Bowyer, 1730.

6. Taylor, Brook; Me~QQdu~In~~ntoriuf!!. Londini: Pearsonianis, 1715.