36

Notes Section 6 Integration Differentials and Differential Equations

Embed Size (px)

Citation preview

Page 1: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 1/36

Page 2: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 2/36

1

Honours Introductory Maths Course 2011

Integration, Differential and Difference Equations

Reading: Chiang Chapter 14

Note: These notes do not fully cover the material in Chiang, but are meant to

supplement your reading in Chiang.

Thus far the optimisation you have covered has been static in nature, that is optimising the value of a

function without any reference to time. In static optimisation and comparative static analysis we make the

assumption that the process of economic adjustment leads to an equilibrium, and we then examine the

effect of changes of the exogenous variables on the equilibrium values of the endogenous variables. With

dynamic analysis, time is explicitly considered in the analysis. While we are not covering dynamic analysis

at this point, certain mathematic tools are required for dynamic analysis, such as integration and differential

equations. Without these tools, it becomes impossible to consider problems which are not static in nature.

We will be covering both of these topics in a mainly mathematical way, leaving economic problems for alater date.

Integration is the reverse process of differentiation. If a function )( xF  has first derivative )( x f  then the

integral of  )( x f  will yield )( xF  . The notation to denote integration is as follows:

∫ dx x f  )( , where the integral sign is an elongated S. )( x f  is referred to as the integrand, and the dx  

sign reminds us that we are integrating with respect to the variable  x. We go through the following

explanation to determine where this notation comes from.

Suppose we are given an arbitrary function )( x f  and asked to find the area of the curve between 2 points,

for example the area under the curve  f(x) between 5 and 10.

5 10 15 20

100

200

300

400

 

Figure 1.1

With a linear function, this equates to finding the area of a triangle and a rectangle as follows:

Page 3: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 3/36

2

 

Figure 1.2

However with a non-linear function the problem becomes slightly more complex. What we can do,

however, is attempt to find the area under the curve using a number of approximating rectangles as follows:

Figure 1.3

We let each of the rectangles have equal width and we call this width  ∆ x. Each rectangle has a height equal

to the function value, for example the height of the last rectangle where  x=10 is equal to f (10)=20. Thus the

area of the last rectangle is equal to 20( ∆ x), as area of a rectangle equals length times breadth, and here

breadth is  ∆ x and length is  f (10)=20. The area of any of the rectangles is equal to length times breadth,

which equals  f(x) times  ∆ x, as all rectangles have equal breadth equal to  ∆ x. To find the area under the

curve we add up the area of each of the rectangles. This gives us the expression:

 x x f  An

i

i ∆= ∑=1

)(  

Where

n = number of rectangles

 xi = the value of  x at each point

∑ = the sum of all the areas, starting from the first one (i = 1) and ending at the nth one (i = 1).

Obviously this sum will not be a very accurate representation of the area. But perhaps if we make our  ∆ xsmaller, then this expression will become a more accurate representation of the area under the curve, as

there will be less overshooting by each rectangle. If initially we had ten rectangles, the area given by the

sum of these rectangles’ areas would obviously be more of an over-estimate (or maybe underestimate) than

if we doubled the number of rectangles, and then summed their area. The more rectangles we use in this

approximating process the better our estimate for the area under the curve.

For example, imagine we wish to find the area under the curve f(x) = x2 between 0 and 1.

Page 4: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 4/36

3

0.2 0.4 0.6 0.8 1

0.2

0.4

0.6

0.8

1

 

Figure 1.4

We could take four rectangles, each with a breadth  ∆ x equal to 0.25, and take the heights from the right

hand side of each rectangle. Hence the height for each rectangle will be:

(0.25)2 

(0.5)2 

(0.75)2 

12

Therefore the entire area equals to

0.25(0.25)2

+ 0.25(0.5)2+0.25(0.75)

2+0.25(1)

2= 15/32=0.46875

If we double the amount of rectangles from four to eight, we will use a  ∆ x of 0.125, and the following right

hand heights (remember the height of the rectangle is given by the function value f(x)).

(0.125)2

(0.25)2 

(0.375)2

(0.5)2

(0.625) 2 (0.75) 2

(0.875)2

12

The corresponding total area is given by the sum of each of the areas which is  ∆ x multiplied by each

function value: The final value we get is 0.3984375

As can be seen in figure 1.3, using right end points for the rectangles for an increasing function will give an

over-estimate, while using right end points for a decreasing function will yield an over-estimate. Thus

doubling the number of rectangles while trying to estimate the area under the graph  f(x)=x2 will begin to

bring our estimate down to its true value. It appears that as the number of rectangles increases, our

estimations become better and better approximations of the area. If we let the number of rectangles tend to

infinity, we will obtain a perfectly accurate estimate for the area under our graph.

Our expression for the area under the curve now becomes:

 x x f  An

i

in

∆= ∑=

∞→1

)(lim  

This gives us the expression for the definite integral, which gives us a way of finding the area under the

continuous function f(x) between x=a and x=b: 

 x x f dx x f n

i

in

b

a

∆= ∑∫=

∞→1

)(lim)(  

An explanation of the terminology:

Page 5: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 5/36

4

∫ The integration sign is an elongated S, and was so chosen because an integral is a limit of sums.

ba, are the limits of integration,

a is the lower limit of integrationb is the upper limit of integration.

)( x f  is known as the integrand.

dx has no meaning by itself, but merely reminds us that we are integrating with respect to the variable

 x. 

Fortunately when we want to find the area under a curve, we do not have to go into the long process of 

finding an expression for the sum of the area of  n rectangles: a number of theorems make the process

easier.

Before we set out the properties of the definite integral, some rules of integration are as follows: (see page

439 and onwards in Chiang for examples).

1.  The Power Rule

11( 1)

1

n n x dx x c n

n

+= + ≠ −

+∫  

2.  The Exponential Rule

 x xe dx e c= +∫  

3.  The Logarithmic Rule

1ln ( 0)dx x c x

 x

= + >∫  

Properties of the definite integral:

∫ −=

b

a

abccdx )(.1  

∫ ∫∫ +=+

b

a

b

a

b

a

dx xgdx x f dx xg x f  )()()]()([.2  

∫∫ =

b

a

b

a

dx x f cdx xcf  )()(.3  

∫ ∫∫ −=−

b

a

b

a

b

a

dx xgdx x f dx xg x f  )()()]()([.4  

5. ( ) ( ) ( )c b c

a a b

 f x dx f x dx f x dx= +∫ ∫ ∫  

Property 1 states that the integral of a constant function y=c is the constant times the length of the interval,

as seen in figure 1.5

Page 6: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 6/36

5

 

Figure 1.5

Property 2 says that the integral of a sum is the sum of the integrals. The area under  f+g is the area under f 

plus the area under g. This property follows from the property of limits and sums.

Property 3 tells us that a constant (but only a constant) can be taken in front of an integral sign. This also

follows from the properties of limits and sums.Property 4 follows from property 2 and 3, using c=-1.

Property 5 tells us we can find the area under the graph between a and c, by splitting it up into two areas,

between a and b, and between b and c. 

We now find our rule for evaluating the definite integral:

∫ −=

b

a

aF bF dx x f  )()()(  

where the derivative of F(x) is f(x), i.e. F is any anti-derivative of  f .

For example, if we differentiate 3)(

3 x

 xF  = we obtain2

)( x x f  = , so F(x) is an anti-derivative of  f(x).

Thus .3

10

3

1

3)0()1(

1

0

31

0

2=−==−=∫

xF F dx x  

Therefore the area under the curve  f(x) = x2

between 0 and 1, is equal to a third, or 0.33 recurring.

Incidentally this answers our previous question which we attempted using the sum of the areas of n

rectangles.

The fundamental theorem of calculus motivates this use of the evaluation theorem. In short, it states that

differentiation and integration are opposite processes. Thus, if we start with a function F(x), and

differentiate it to obtain f(x), [ i.e. )()( x f  xF  =′ ], if we then integrate the function f(x), the result will be

the initial function F(x). Similarly if we integrate f(x) to obtain F(x), [ i.e. C  xF dx x f  +=∫ )()( where Cis an arbitrary constant

1]. Thus to find the integral of a function  f(x), we must find the function which when

differentiated yields  f(x). This theorem is very useful to us, as otherwise whenever we wish to find the

value of the area that lies underneath a curve, we have to go through the entire process of finding the limitof the sum of the areas of n approximating rectangles, which is a time consuming process! Prior to the

discovery of the fundamental theorem, finding areas, volumes and other similar types of problems were

nigh on impossible.

For completeness, the fundamental theorem is presented below:

1More about the arbitrary constant a little later

Page 7: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 7/36

6

The fundamental theorem of calculus:

Suppose f(x) is a continuous function on the closed interval [a,b]

1. If  ∫=

 x

a

dt t  f  xg )()( then )()( x f  xg =′ i.e. )()()( x f dt t  f dx

d  xg

 x

a

=

=′ ∫  

2. ∫ −=

b

a

aF bF dx x f  )()()(  

where the derivative of F(x) is f(x), i.e. F is any anti-derivative of  f . What it says, roughly speaking, is that

if you integrate a function and then differentiate the result, you retrieve the original function.

We now need to discuss two different types of integrals – definite and indefinite. A definite integral

involves finding the integral of a function between two number limits i.e.∫

b

a

dx x f  )( . The answer to a

definite integral is a number, as we know according to the evaluation rule the answer to this is just the anti-

derivative F(x) evaluated between a and b, i.e. F(b)-F(a). An indefinite integral yields a function of  x as its

answer (if we are integrating with respect to  x). An indefinite integral is an integral of the form

∫ dx x f  )( (i.e without upper and lower limits) and the solution is

C  xF dx x f  +=∫ )()(  

where C is an arbitrary constant which can take on any value.

The reason we include the arbitrary constant is illustrated in the following example.

Given the problem:

∫ dx x 23 a potential solution is3

 x as this is an antiderivative of the cubic function (If we differentiate

3 x we obtain23 x . However 43

+ x is also a solution to this problem, as is 1003− x . This is because

when differentiating these expressions, the constant differentiated moves to zero. So it would appear that

the most general form to give the answer to this problem would be as follows:

∫ += C  xdx x 323 ,

where C is an arbitrary constant.

Just a small note on arbitrary constants – when we add two together, we obtain a third one which has

aggregated the first two, when multiplying, dividing adding or subtracting a number by/to/from an arbitrary

constant, the result is just the arbitrary constant. However the arbitrary constant when multiplied by afunction of  x, will stay as just that:

∫ ++=+++=+ C  xG xF C  xGC  xF dx xg x f  )()()()()()( 21 

where C 1  and C 2 are two arbitrary constants, and F(x) and G(x) are two anti-derivates of  f(x) and g(x) 

respectively.

∫ +=+=+= C  xF C  xF C  xF dx x f  )(33)(3])([3)(3  

However:

Page 8: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 8/36

7

∫ +=+= Cx x xF C  xF  xdx x f  x )(])([)(  

We now turn to some rules of integration (definite and indefinite) and then some examples.

1. ∫ ∫= dx x f cdx xcf  )()(  

2. ( ( ) ( )) ( ) ( ) f x g x dx f x dx g x dx+ = +∫ ∫ ∫  

3. C n

 xdx x

nn

++

=∫+

1

1

(n cannot equal –1)

4. C  xdx x

+=∫ ln1

 

5. C edxe x x+=∫  

6. C a

adxa x

 x+=∫ ln

 

7. C  x xdx +−=∫ cossin  

8. C  x xdx +=∫ sincos  

Remember – to check the answer to any integration sum just differentiate it and you should arrive back at

the original function.

Some examples:

1.

∫+= C  xdx

33 

2. ∫ += C  xdx  

3. ∫ ∫ +== C  xdx xdx x 2

5

2

3

3

5

4.

22 2 34

4

1 1 1

1 1 1 7( )

3 24 3 24

 xdx x dx

 x

−= = = − − − =

−∫ ∫  

5.  C  x xC  x x

dx x x +−=+−=+∫ cos2cos5

10]sin10[

55

6.  75.600)9(34

813

426

4)6(

3

0

243

0

243

0

3−=+−−=−=−=−∫ x

 x x xdx x x  

7. 

603.174

1ln5

219ln)243(

5

281

ln5

2)2()2(

129

1

2

5

2

9

1

12

39

1

1

9

1

22

=

+−−−+=

−+=−+=−+=−+

∫∫∫−− t t t dt t t t dt t t t t dt 

t t t 

 

Page 9: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 9/36

8

8.2

96

23)6(

4

1

234

1

2−=−−=−−∫ t 

t t dt t t   

A few more useful properties:

∫∫

=

−=

a

a

a

b

b

a

dx x f 

dx x f dx x f 

0)(.2

)()(.1

 

We are going to be looking at two very useful techniques used in integration: use of substitution, and

integration by parts. There are a whole host of other techniques which can be useful, however it is these

two which are most useful to us in economics.

Integration using Substitution

We use substitution, when the integrand contains a function and its own derivative. i.e:

∫ ′ dx x f  x f  )()(  

For example:

∫ +−+ dx x x x x )103)(105( 223 

If this is the case, we can make use of the following substitution: We let u equal to the function whose

derivative we can spot (or create, using a constant: more about this later).

Let u = 105 23−+ x x  

Then we know that

dx x xdu )103( 2+=  

When we then substitute the values of u and du into the integral, we obtain the following integral:

∫udu  

which has the answer

C u

udu +=∫ 2

2

 

but: u = 10523

−+ x x  

Therefore our final answer is

C  x x

dx x x x x +−+

=+−+∫ 2

)105()103)(105(

223223

 

Thus the general rule solution for the problem is as follows:

C  x f 

dx x f  x f  +=′∫ 2

)]([)()(

2

or more simply C  f 

dx f  f  +=′∫ 2).(

2

 

Page 10: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 10/36

9

However the substitution rule can be used for more complicated examples, when our function  f(x) whose

derivative we can spot occurs inside another function:

For example:

∫ ′ dx f g f  )( or ∫ −++ dx x x x )23183()186(2

 

In these cases the procedure does not change at all – we still make the substitution as follows:

Let u = f(x)

Therefore du=f`(x)dx

And proceed as usual:

Some examples:

1. ∫ −++ dx x x x )23183()186(2

 

Let )23183( 2−+= x xu  

Therefore dx xdu )186( +=  

Therefore our transformed integral is as follows:

C  x x

C u

duuduu +−+

=+==∫∫ 3

)23183(2

3

2 2

3

22

3

2

1

 

2. Sometimes we can find a function whose derivative we can create as follows: However only if we

introduce a constant function.

For example:

dxe x

∫+ )54(  

If we let u = (4x+5), we know du = 4dx. However while we have the dx, we do not have a 4. This is easily

solved however through the following manipulation:

dxe x

∫+ )54(4

4

This integral now contains a function and its derivative, thus substitution can be used:

Therefore let u = (4x+5), and du = 4dx. The integral becomes:

C eC eduexuu

+=+=+

∫)54(

4

1

4

1

4

Remember, the substitution of u into this function is a device that we employ. Therefore our final answer

ought not to contain u, as the original problem does not contain it. Always remember to substitute back for

u. 

Note: Unlike differentiation, there exists no general formula giving the integral of a product of two

function i.t.o. the separate integrals of those functions. There is also no general formula giving the integral

of a quotient of 2 functions in terms of their separate integrals. As a result, integration is trickier than

differentiation, on the whole.

Page 11: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 11/36

I n t e g r a t i o n b y P a r t s  

W e u s e t h i s t e c h n i q u e w h e n w e h a v e t o i n t e g r a t e a p r o d u c t :

E . g .

ˆ f (x).g(x)dx

W h e n w e a r e g i v e n t h i s t y p e o f e x a m p l e , w e m a k e u s e o f t h e f o l l o w i n g f o r m u l a :

  

  ˆ 

f (x).g(x)dx = f (x).g(x)−ˆ 

f (x).g(x)dx

F o r e x a m p l e :  

ˆ xe

x

dx

W e p i c k  

f a s t h e f u n c t i o n w h i c h i s e a s y t o d i e r e n t i a t e , a n d  

ga s t h e f u n c t i o n w h i c h i s e a s y t o i n t e g r a t e .

O f t e n p i c k i n g a s q u a r e d o r c u b i c t e r m f o r y o u r   f  i s a g o o d i d e a , a s   f  w i l l h a v e a p o w e r t h a t i s t h e n o n e  

l o w e r , a n d h e n c e s i m p l e r . I t i s a v e r y g o o d i d e a t o m a k e y o u r s e l f a m i n i t a b l e w i t h   f  , g , f  a n d  g , t o 

k e e p t h i n g s s t r a i g h t . A l s o , n o t e t h a t w h e n n d i n g   g , w e d o n o t b o t h e r w i t h t h e a r b i t r a r y c o n s t a n t .

ˆ xexdx

T h e r e f o r e :

f  = x g = ex

f  = 1 g = ex

ˆ xexdx = xex −

ˆ (1)exdx

= xex − ex + C 

T h u s w e h a v e m a n a g e d t o u s e t h e f o r m u l a t o i n t e g r a t e o u r o r i g i n a l q u e s t i o n .

( C a n a l s o u s e t h e a l t e r n a t i v e n o t a t i o n u s e d i n C h i a n g : w h e r e  

´ vdu = uv − ´ 

udv ) 

A n o t h e r e x a m p l e :  

ˆ xsinxdx

T h e r e f o r e :

f  = x g = sin x

f  = 1 g = − cos x

ˆ xexdx = −x cos x +

ˆ cos xdx

= −x cos x + sin x + C 

Page 12: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 12/36

A n e x a m p l e w i t h a t r i c k :  

ˆ ln xdx

O b v i o u s l y w e d o n o t k n o w t h e i n t e g r a l o f  ln x, t h a t i s w h y w e a r e u s i n g t h i s m e t h o d . S o w e m a k e   ln x

e q u a l t o  

f , a n d w e c a n t h e n n d i t s d e r i v a t i v e . B u t t h e n w h a t w i l l o u r  

gb e ? S i m p l e , m a k e i t 1 .

f  = ln x g = 1

f  = 1x

g = x

ˆ ln xdx = x ln x −

ˆ x

1

x

dx

= x ln x − x + C 

T h i s i s a h a n d y t r i c k w h i c h c a n a l s o b e u s e d t o n d t h e i n t e g r a l s o f s o m e o f t h e t r i g o n o m e t r i c f u n c t i o n s .

S o m e m o r e e x a m p l e s :  

ˆ xe2xdx

T h e r e f o r e :

f  = x g = e2x

f  = 1 g = e2x

2

ˆ xe2xdx =

xe2x

2−

ˆ e2x

2dx

=xe2x

2− e2x

4+ C 

W h i c h c a n t h e n b e r e - w r i t t e n i f w e w a n t t o :

ˆ xe

2x

dx =

e2x

2

x −1

2

+ C 

A n o t h e r e x a m p l e :  

ˆ x ln xdx

f  = ln x g = x

f  = 1x

g = x2

2

Page 13: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 13/36

ˆ x ln xdx =

x2

2ln x −

ˆ 1

x

x2

2dx

=x2

2ln x −

ˆ x

2dx

=x2

2ln x − x2

4+ C 

A n o t h e r e x a m p l e :  

ˆ (ln x)

2dx

f  = (ln x)2 g = 1

f  = 2 (ln x) 1x

g = x

ˆ (ln x)2 dx = x (ln x)2 −

ˆ x.2 ln x

1

x

dx

= x (ln x)2 −ˆ 

2 ln xdx

= x (ln x)2 − 2 (x ln x − x) + C 

T h e l a s t l i n e u s e s a r e s u l t t h a t w e p r o v e d a f e w e x a m p l e s a g o .

N o w l e t ' s t r y a d e n i t e i n t e g r a l u s i n g i n t e g r a t i o n b y p a r t s :  

ˆ 10

te−tdt

f  = t g = e−t

f  = 1 g = −e−t

W e r s t c a l c u l a t e t h e i n d e n i t e i n t e g r a l , t h e n g o b a c k a n d s u b s t i t u t e i n t h e l i m i t s .

ˆ te−tdt = −te−t +

ˆ e−tdt

= −te−t − e−t + C 

T h e r e f o r e :

ˆ 10

te−tdt =−te−t − e−t

10

= −1e−1

−e−1

− −e−0

= 1 − 2e−1

= 1 − 2

e

Page 14: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 14/36

Y o u s h o u l d n o w m a k e s u r e y o u c a n d o t h e i n t e g r a t i o n p r a c t i c e q u e s t i o n s .

A n e x a m p l e o f a n e c o n o m i c a p p l i c a t i o n o f i n t e g r a l s :  

O n e s i m p l e a p p l i c a t i o n i s t o n d a ` t o t a l ' q u a n t i t y f r o m a ` m a r g i n a l ' q u a n t i t y . S u p p o s e a r m h a s a  

m a r g i n a l c o s t   C (x) = 1 + 2ex

3w h e r e   x d e n o t e s o u t p u t . T h e n t o t a l c o s t i s :

C (x) =

ˆ  1 + 2e

x

3

dx

= x + 6ex

3 + B,

w h e r e B i s t h e c o n s t a n t o f i n t e g r a t i o n .

D i e r e n t i a l E q u a t i o n s  

A D E i s a n e q u a t i o n c o n t a i n i n g a f u n c t i o n   y = f (x) a n d o n e o r m o r e o f i t s d e r i v a t i v e s , i . e . y , y e t c . I t  

s h o w s t h e r e l a t i o n s h i p b e t w e e n t h e f u n c t i o n a n d i t s d e r i v a t i v e s . I f o n l y t h e r s t d e r i v a t i v e  

dydt

i s p r e s e n t ,

t h e d i e r e n t i a l e q u a t i o n i s s a i d t o b e o f t h e r s t o r d e r .

S o m e e x a m p l e s i n c l u d e :  

y = y + y

dy

dx+ xy = x

3y − 2y = x

A s y o u c a n s e e , t h e s e e q u a t i o n s c o n t a i n a d e p e n d e n t v a r i a b l e   y , s o m e o r m o r e o f i t s d e r i v a t i v e s   y , y

a n d s o m e o c c u r r e n c e s o f t h e i n d e p e n d e n t v a r i a b l e , i n t h e s e c a s e s   x. O u r a i m w i t h d i e r e n t i a l e q u a t i o n s  

i s t o s o l v e f o r o u r f u n c t i o n   y , i n t e r m s o f t h e i n d e p e n d e n t v a r i a b l e   x , w i t h n o n e o f t h e d e r i v a t i v e s s t i l l  

p r e s e n t . H o w w e d o t h i s d e p e n d s l a r g e l y o n t h e t y p e o f d i e r e n t i a l e q u a t i o n p r e s e n t . W h a t f o r m a D E  

t a k e s w i l l d e t e r m i n e h o w w e s o l v e i t . Y o u r m a i n t a s k i n t h i s s e c t i o n i s t o i d e n t i f y t h e t y p e o f D E . O n c e  

t h i s i s d o n e i t i s u s u a l l y f a i r l y s i m p l e t o p r o c e e d f r o m t h e r e .

W e w i l l b e c o n s i d e r i n g 4 t y p e s o f d i e r e n t i a l e q u a t i o n s :

1 . D i r e c t l y i n t e g r a b l e D E s  

2 . S e p a r a b l e D E s  

3 . 1 s t O r d e r L i n e a r D E s  

4 . 2 n d O r d e r D E s  

Page 15: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 15/36

1 D i r e c t l y I n t e g r a b l e D i e r e n t i a l E q u a t i o n s :  

T h i s t y p e o f D E c o n t a i n s o n l y o n e o f t h e f u n c t i o n ' s d e r i v a t i v e s , a n d a f u n c t i o n o f t h e i n d e p e n d e n t v a r i a b l e .

F o r e x a m p l e :

1 .

y

= x2

+ 2

2 .

d2ydx2

+ x = ex

3 . y = 6

S o l v i n g t h e s e D E ' s j u s t r e q u i r e s t h a t w e i n t e g r a t e a s m a n y t i m e s a s i s n e c e s s a r y , i n c l u d i n g t h e n e c e s s a r y  

c o n s t a n t s o f i n t e g r a t i o n . E g :

1 .

y = x2 + 2

y = x3

3 + 2x + C 

2 .

d2y

dx2 + x = ex

d2y

dx2= ex − x

dydx

= ex − x2

2 + C 

y = ex − x3

6+ Cx + D

3 . y = 6

y = 6x + C 

y = 3x2 + Cx + D

y = x3 + Cx2

2+ Dx + E 

T h i s p r o c e d u r e g i v e s u s t h e   g e n e r a l   s o l u t i o n f o r t h e s e D E ' s . T o o b t a i n t h e s p e c i c s o l u t i o n , i . e . w i t h o u t  

t h e p r e s e n c e o f a r b i t r a r y c o n s t a n t s , w e r e q u i r e s o m e   i n i t i a l c o n d i t i o n s  

.

E g : y(0) = 2o r  y(0) = 1

T o s o l v e f o r t h e s p e c i c s o l u t i o n t o o n e o f t h e s e D E ' s , w e u s e t h e i n i t i a l c o n d i t i o n s a s f o l l o w s :

y = 6

y(0) = 1

y(0) = 2

W e k n o w t h a t t h e g e n e r a l s o l u t i o n t o t h i s p r o b l e m i s :

y = 6x + C 

y = 3x2 + Cx + D

T h e r e f o r e w e s u b s t i t u t e i n t h e i n i t i a l c o n d i t i o n s , o b t a i n s o m e s i m p l e s i m u l t a n e o u s e q u a t i o n s , a n d s o l v e  

f o r t h e t w o a r b i t r a r y c o n s t a n t s .

y = 3x2 + Cx + D

y(0) = 1 = D

y(0) = 2 = C 

y = 3x2 + 2x + 1

D i r e c t l y i n t e g r a b l e D E ' s a r e t h e s i m p l e s t t y p e o f D E , a n d s a d l y w e w o n ' t e n c o u n t e r t h e m v e r y o f t e n .

Page 16: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 16/36

2 S e p a r a b l e D E ' s  

T h e g e n e r a l f o r m f o r a s e p a r a b l e D E i s :

    

dy

dx = f (x).g(y)

i . e . t h e R H S c a n b e s e p a r a t e d i n t o a f u n c t i o n o f  x t i m e s a f u n c t i o n o f  y . S o m e t i m e s y o u m a y h a v e t o d o  

s o m e m a n i p u l a t i o n t o a c h i e v e t h i s .

E . g .

(1 + x)dy − ydx = 0

(1 + x)dy = ydx

b e c o m e s  

dy

dx=

y

1 + x

= y.1

1 + x

w h i c h i s s e p a r a b l e .

E . g .

xy4dx +

y2 + 2

e−3xdy = 0

b e c o m e s  

dy

dx =e3x.

−xy4

y2 + 2

w h i c h i s s e p a r a b l e .

T o s o l v e a s e p a r a b l e D E , w e r e w r i t e i t a s f o l l o w s , a n d t h e n i n t e g r a t e b o t h s i d e s w i t h r e s p e c t t o   x a n d  y .'

&

   $

   %

dy

dx= f (x).g(y)

1

g(y)dy = f (x)dx

ˆ 1

g(y)

dy = ˆ  f (x)dx

S i n c e t h e L H S i n v o l v e s o n l y  

ya n d t h e R H S i n v o l v e s o n l y  

x, t h e s o l u t i o n m e t h o d i s k n o w n a s s e p a r a t i n g  

t h e v a r i a b l e s . I f p o s s i b l e , o n e t h e n s o l v e s f o r  

yi n t e r m s o f  

x, b u t i f n o t , o n e s i m p l y l e a v e s t h e e q u a t i o n  

i n s i m p l e s t f o r m , m a k i n g s u r e t h e d e r i v a t i v e s a r e n o l o n g e r p r e s e n t .

F o r e x a m p l e :

1 .

dydx

= y

1+x1y

dy = 11+x

dx

´ 1y dy =

´  1

1+xdxln y = ln(1 + x) + C 

eln y = eln(1+x)+C 

Page 17: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 17/36

y = A(1 + x),

w h e r e  

A = eC 

2 .

dy

dx= −x

y

ydy =−

xdx´ ydy =

´ −xdxy2

2 = −x2

2 + C 

I t i s o f t e n h a r d o r a l m o s t i m p o s s i b l e t o s o l v e e x p l i c i t l y f o r   y i n t e r m s o f  x i n a s e p a r a b l e D E . W e t h e n  

u s u a l l y a r e c o n t e n t t o j u s t s o l v e t h e D E , i . e . e l i m i n a t e t h e p r e s e n c e o f d e r i v a t i v e s . Y o u w i l l w a s t e l a r g e  

p o r t i o n s o f t i m e i n y o u r e x a m i f y o u d o n o t r e a l i s e t h i s .

E . g .

dy

dt=

t3 + 1

y6 + 1ˆ  y6 + 1

dy =

ˆ  t3 + 1

dx

y7

7+ y =

t4

4+ t + C 

I t i s i m p o s s i b l e h e r e t o s o l v e f o r   y i n t e r m s o f  t, s o w e j u s t l e a v e i t a s i s .

A n i n i t i a l v a l u e p r o b l e m :  

dy

dx= y

−4

y(7) = 5´ 

1y−4

dy =´ 

dx

ln(y − 4) = x + C 

S u b i n   y(7) = 5

ln(5 − 4) = 7 + C 

ln1 = 7 + C 

C  = −7

ln(y − 4) = x − 7

y − 4 = ex−7

y = 4 + ex−7

S o m e m o r e e x a m p l e s :  

1 . dx + e3xdy = 0

dy = −e−3xdx´ dy =

´ −e−3xdx

y = e−3x

3+ C 

Page 18: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 18/36

2 .

(x + 1) dy

dx= x + 6´ 

dy =´ 

x+6x+1dx´ 

dy =´ 

x+1+5x+1 dx´ 

dy =´ 

1 + 5x+1dx

y = x + 5 ln(x + 1) + C 

T h e n e x t e x a m p l e u s e s   i n t e g r a t i o n b y p a r t s  :

ex dy

dx= 2x

´ dy =

´ 2xe−xdx

F o r 

´ 2xe−xdx

:

f  = 2x

f  = 2

g = e−x

g = −e−x

´ 2xe−xdx = −2xe−x − 2e−x + C 

y = −2xe−x − 2e−x + C 

S o l v e t h e d i e r e n t i a l e q u a t i o n  

dy

dt+ ay = 0

, w h e r e  

ai s n o n - z e r o c o n s t a n t .

S e p a r a t i n g t h e v a r i a b l e g i v e s  

´ y−1dy =

´ (−a)dt.

I n t e g r a t i n g w e o b t a i n :

ln y = −at + C , w h e r e   C  i s a n a r b i t r a r y c o n s t a n t .

H e n c e  

y = eC −at = eC e−at

S e t t i n g  

A = eC , w e m a y w r i t e t h e g e n e r a l s o l u t i o n a s  

y = Ae−at, w h e r e  

Ai s a c o n s t a n t .

T h e n e x t t y p e o f d i e r e n t i a l e q u a t i o n w e e n c o u n t e r :

3 F i r s t O r d e r L i n e a r D i e r e n t i a l E q u a t i o n s :  

T h e g e n e r a l f o r m o f a r s t o r d e r l i n e a r D E i s :

    dy

dx+ P (x)y = Q(x)

N B : I f y o u r e q u a t i o n i s N O T i n t h i s f o r m a t , y o u m u s t R E W R I T E i t b e f o r e y o u c a n w o r k w i t h i t . T h e  

g e n e r a l m e t h o d f o r a l i n e a r r s t o r d e r D E i s a s f o l l o w s :

1 . P u t i t i n t o s t a n d a r d f o r m .

dy

dx+ P (x)y = Q(x)

2 . I d e n t i f y   P (x)a n d n d t h e i n t e g r a t i n g f a c t o r   I , w h i c h i s e q u a l t o :

I  = e´ P (x)dx

Page 19: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 19/36

3 . M u l t i p l y L H S a n d R H S b y  

I .

e´ P (x)dx dy

dx+ e

´ P (x)dxP (x)y = e

´ P (x)dxQ(x)

4 . T h e L H S b e c o m e s t h e d e r i v a t i v e o f t h e p r o d u c t o f   I  a n d  y , s o w e r e w r i t e i t a s s u c h . W e a r e  

e s s e n t i a l l y d o i n g t h e p r o d u c t r u l e f o r d i e r e n t i a t i o n h e r e , b u t i n R E V E R S E . I n s t e a d o f g o i n g f r o m  

(f.g) = f g + f g, w e a r e m o v i n g f r o m t h e R H S t o t h e L H S . T h u s t h e L H S o f t h e e q u a t i o n i n s t e p  

t h r e e b e c o m e s :

d

dx(I.y ) = Q(x).I 

5 . W e t h e n i n t e g r a t e b o t h s i d e s . F o r t h e L H S , t h i s i s s i m p l e , a s t h e i n t e g r a l a n d d e r i v a t i v e s i g n s c a n c e l  

e a c h o t h e r o u t , a n d w e s i m p l y o b t a i n  

I.yo n t h a t s i d e .

ˆ d

dx(I.y ) =

ˆ [Q(x).I ] dx

I.y =

ˆ [Q(x).I ] dx

6 . T h e l a s t s t e p i s s i m p l y t o s o l v e f o r  

y. L i k e t h e s e p a r a b l e e q u a t i o n s , i t i s s o m e t i m e s n o t p o s s i b l e t o  

s o l v e e x p l i c i t l y f o r  

yi n t e r m s o f  

x, a n d w e j u s t w o r k t o w a r d s e l i m i n a t i n g d e r i v a t i v e s .

E x a m p l e :  

G i v e n :

x.dy

dx− 4y = x6ex

1 . R e w r i t e i n s t a n d a r d f o r m .

dy

dx− 4

xy = x5ex

2 . F i n d t h e i n t e g r a t i n g f a c t o r .

P (x) = − 4

x

I  = e´ −

4xdx

= e−4 lnx

= elnx−4

= x−4

3 . M u l t i p l y L H S a n d R H S b y i t .

x−4 dy

dx− x−4 4

xy = x−4x5ex

x−4 dy

dx− 4x−5y = xex

4 . R e w r i t e t h e L H S a s  

ddx

(I.y ).

d

dxx−4y = xex

Page 20: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 20/36

5 . I n t e g r a t e b o t h s i d e s .

ˆ d

dx

x−4y

=

ˆ xexdx

x−4y = xex − ex + C 

6 . S o l v e f o r  

y( w h i c h i s p o s s i b l e i n t h i s c a s e ) .

y = x5ex − x4ex + Cx4

A n o t h e r e x a m p l e :  

( N o t e : a l t h o u g h i t i s a s e p a r a b l e D E b u t w e s o l v e i t u s i n g t h e m e t h o d f o r r s t - o r d e r l i n e a r D E ' s ) .

(x2 + 9)dy

dx

+ xy = 0

dy

dx+

x

(x2 + 9)y = 0

I  = e´ 

x

(x2+9)dx

= e12

´ 2x

(x2+9)dx

= e12 ln(x2+9)

= eln√ 

(x2+9)

=  x2 + 9

N o w m u l t i p l y t h e L H S a n d R H S b y t h e i n t e g r a t i n g c o n s t a n t :

 x2 + 9

dy

dx+ 

x2 + 9x

(x2 + 9)y = 0

d

dx

 x2 + 9.y

= 0ˆ 

d

dx

 x2 + 9.y

=

ˆ 0dx

 x2 + 9.y = C 

y =C √ 

x2 + 9

A n o t h e r e x a m p l e , u s i n g a n i n i t i a l v a l u e :  

S o l v e  

xdy

dx+ y = 2x

, w h e r e  

y(1) = 0.

S o l u t i o n :  

dy

dx+

1

xy = 2

Page 21: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 21/36

E x a m p l e 2 :  

3dy

dx+ 12y = 9

dy

dx+ 4y = 3

I  = e´ 4dx

= e4x

e4xdy

dx+ 4e4xy = 3e4x

d

dx

e4x

.y

= 3e4x

ˆ d

dx

e4x.y

=

ˆ 3e4xdx

e4xy =3e4x

4+ C 

y =3

4+ Ce−4x

H o m o g e n e o u s a n d N o n - H o m o g e n e o u s C a s e s o f D i e r e n t i a l E q u a t i o n s :  

T h e e q u a t i o n  

dydx

+ ay = 0, w h e r e  

ai s s o m e c o n s t a n t , i s s a i d t o b e h o m o g e n o e u s o n a c c o u n t o f t h e z e r o  

c o n s t a n t t e r m . T h i s e q u a t i o n c a n b e r e - w r i t t e n a s  

1

y

dy

dt= −a

T h e s o l u t i o n s t o t h i s D E a r e a s f o l l o w s :

y(t) = Ae−at[ g e n e r a l s o l u t i o n ]

y(t) = y(0)e−at[ d e n i t e s o l u t i o n ]

N o n - H o m o g e n o u s C a s e :  

W h e n a c o n s t a n t t a k e s t h e p l a c e o f t h e z e r o i n t h e a b o v e e q u a t i o n s , w e h a v e a   n o n - h o m o g e n e o u s   l i n e a r  

d i e r e n t i a l e q u a t i o n :

dy

dt+ ay = b

T h e s o l u t i o n t o t h i s e q u a t i o n c o n s i s t s o f t h e s u m o f t w o t e r m s , o n e o f w h i c h i s c a l l e d t h e   c o m p l e m e n t a r y  

f u n c t i o n ( d e n o t e d b y   yc ) a n d t h e o t h e r k n o w n a s t h e   p a r t i c u l a r i n t e g r a l  , d e n o t e d b y   y p .

I n t h i s c a s e :

Page 22: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 22/36

yc = Ae−at[ g e n e r a l s o l u t i o n ]

y p = ba

, a = 0[ d e n i t e s o l u t i o n ]

G e n e r a l s o l u t i o n o f t h e c o m p l e t e e q u a t i o n i s t h e s u m o f   yc a n d  y p :

y(t) = yc + y p

= Ae−at +b

a

T r y t h e f o l l o w i n g e x e r c i s e a n d s e e i f y o u g e t t h e s a m e a n s w e r :

xy + y = ex

y(1) = 2

T h e s o l u t i o n i s :

x.y = ex(x − 1) + 2

O u r l a s t t y p e o f p r o b l e m i n v o l v e s :

4 2 n d O r d e r D i e r e n t i a l E q u a t i o n s  

G e n e r a l F o r m :

    y + a1y + a2y = b

W h e r e   a1 , a2 a n d  b a r e c o n s t a n t s .

2 n d o r d e r D E ' s c a n i n v o l v e c a s e s w h e r e  

a1 ,

a2 a n d 

ba r e n o t c o n s t a n t b u t f o r o u r p u r p o s e s w e d o n ' t n e e d  

t o w o r r y a b o u t t h e s e .

A g e n e r a l s o l u t i o n f o r t h e D E a b o v e i s :

    y = yc + y p

w h e r e  

yc d e n o t e s t h e   c o m p l e m e n t a r y f u n c t i o n   a n d 

y p d e n o t e s t h e   p a r t i c u l a r i n t e g r a l  .

W e n d   yc a n d  y p u s i n g t h e f o l l o w i n g s e t o f r u l e s :

I n s o l v i n g f o r t h e p a r t i c u l a r i n t e g r a l , w e c a n d i s t i n g u i s h b e t w e e n 3 d i e r e n t c a s e s :

C a s e 1 :   I f  a2 i s n o n - z e r o  

y p =b

a2

Page 23: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 23/36

C a s e 2 :   I f a 2 = z e r o  

y p =b

a1t

C a s e 3 :   B o t h   a2 a n d  a1 a r e z e r o  

y p =

b

2t2

A n d t o n d   yc , w e n d t h e s o l u t i o n t o t h e h o m o g e n e o u s v e r s i o n o f t h e D E , i . e . yc i s t h e s o l u t i o n t o :

    y + a1y + a2y = 0

W h i c h i s t h e s a m e a s s a y i n g t h a t  

b = 0.

T h e c o m p l e m e n t a r y s o l u t i o n t o t h e s e c o n d - o r d e r d i e r e n t i a l e q u a t i o n t a k e s t h e f o r m :

y(t) = A1er1t + A2er2t

w h e r e   A1 , A2 a r e t w o a r b i t r a r y c o n s t a n t s a n d   r1 a n d  r2 a r e t h e r o o t s f r o m t h e c h a r a c t e r i s t i c e q u a t i o n :

r2 + ar + b = 0

g i v e n b y  

r1,r2 =1

2

−a ±

 a2 − 4ab

I n o t h e r w o r d s :

T o s o l v e t h i s , w e f o r m t h e c o r r e s p o n d i n g c h a r a c t e r i s t i c e q u a t i o n :

    r2 + a1r + a2 = 0

A n d s o l v e f o r   r1 a n d  r2 , w h i c h a r e t h e r o o t s o f t h e c h a r a c t e r i s t i c e q u a t i o n .

T h e s e t h e n y i e l d t h e f o l l o w i n g g e n e r a l s o l u t i o n s f o r   yc :

I n t h e c a s e  

r1a n d 

r2, a r e u n e q u a l :  

  

  r1 = r2

yc = Aer1t + Ber2t

I n t h e c a s e w h e r e   r1 a n d  r2 , a r e e q u a l :  

  

  r1 = r2yc = Aert + Btert

Page 24: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 24/36

T h e r e i s a l s o t h e c a s e w h e r e  

r1 a n d 

r2 , a r e c o m p l e x r o o t s , w h i c h w e i g n o r e f o r o u r p u r p o s e s . H o p e f u l l y  

y o u a l l h a v e n o t f o r g o t t e n t h e f o r m u l a t o s o l v e a q u a d r a t i c e q u a t i o n , b u t i n c a s e y o u h a v e :#

"

   

   !ax2 + bx + c = 0

x = −b±√ b2 − 4ac2a

S o o u r n a l s o l u t i o n i s :

    y = yc + y p

W h e r e w e h a v e f o u n d   yc a n d  y p u s i n g t h e r e l e v a n t r u l e s .

S o m e e x a m p l e s :  

y + y − 2y = −10

T h e r e f o r e :

a1 = 1 a2 = −2 b = −10

W e n d t h e a p p r o p r i a t e c a s e f o r  

y p , w h i c h i s t h e r s t o n e , i . e .

a2 i s n o n - z e r o .

y p =b

a2=−10

−2= 5

W e t h e n n d t h e s o l u t i o n f o r  

yc w h i c h i s t h e s o l u t i o n t o :

y + y − 2y = 0

r2 + r − 2 = 0

(r + 2)(r − 1) = 0

r1 = −2 r2 = 1

T h i s i s t h e c a s e o f u n e q u a l r o o t s :

r1 = r2

yc = Aer1t + Ber2t

= Ae−2t + Bet

y = yc + y p

y p = 5

y = 5 + Ae−2t + Bet

G i v e n i n i t i a l c o n d i t i o n s , w e c o u l d a l s o s o l v e f o r  

Aa n d 

B.

F o r e x a m p l e , g i v e n t h a t   y(0) = 12, y(0) = −2

Page 25: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 25/36

W e c a n n o w s o l v e f o r t h e s p e c i c s o l u t i o n :

y = 5 + Ae−2t + Bet

12 = 5 + A + B

7 = A + B

y = −2Ae−2t + Bet

−2 = −2A + B

7 = A + B

−2 = −2A + B

−9 = −3A

A = 3B = 4

y = 5 + 3e−2t + 4et

E x a m p l e T w o :   ( T h i s i s a c a s e o f r e p e a t e d r o o t s )  

y + 6y + 9y = 27

y(0) = 5 y(0) = −5

a1 = 1 a2 = 6 b = 27

y p =27

9= 3

y + 6y + 9y = 0

r2 + 6r + 9 = 0

(r + 3)(r + 3) = 0

r = −3

r1 = r2

yc = Aert + Btert

= Ae−3t + Bte−3t

y p = 3

y(t) = yc + y p

= Ae−3t + Bte−3t + 3

y(t) =

−3Ae−3t + Be−3t

−3Bte−3t

y(0) = 5

Page 26: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 26/36

5 = 3 + A

A = 2

y(0) = −5

−5 = −3A + B

B = 1

y = 3 + 2e−3t + te−3t

Page 27: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 27/36

27

 

DIFFERENCE EQUATIONS

What are difference equations?

Whereas differential equations deal with problems in continuous time, difference equations are concerned

with problems in discrete time. Here the variable t is allowed to take integer values only, making the

concept of a derivative or differential no longer appropriate.

Instead the pattern of change of the variable y must be described by ‘differences’, rather than by derivatives

or differentials of  y(t). 

When we are dealing with discrete time, the value of variable y will change only when the variable t  

changes from one integer value to the next, such as from t =1 to t=2. Meanwhile nothing is supposed to

happen to y. It is therefore more convenient to interpret the values of t as referring to periods – rather than

 points – of time, with t =1 denoting period 1, t=2 denoting period 2 and so forth. Then we can regard y as

having one unique value in each time period.In view of this interpretation, the discrete-time version of economic dynamics is often referred to as period 

analysis.

In difference equations, the pattern of change is represented by the difference quotient y

∆. t can only take

integer values, so if we compare the values of  y in two consecutive periods, we must have t = 1. For this

reason the difference quotient y

∆can be simplified to the expression  y∆ ; this is called the first-

difference of  y. 

This refers to the rate of change of  y in period t , which is equal to 1t t  y y+

− .

We can therefore define the forward difference operator ∆ byt  y∆ =

1t t  y y+

− .

Application of the operator ∆ may be regarded as the discrete-time counterpart of differentiation withrespect to time.

Difference equations are therefore like differential equations, except that derivatives are replaced by

differences. This the discrete-time analogue of the differential equationdy

ay bdt 

+ = , where a and b are

constants, is the first-order difference equation

t  y∆ + t ay b= .

Recalling the definition of the operator ∆ , we may write this equation as:

1t t  y cy b+

+ = , where c=-1.

Since this equation simply relates the value of  y in a period to its value in the previous period, it can be

written in the equivalent form:

1t t  y cy b−

+ =  

Page 28: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 28/36

28

Solving first-order difference equations.

In this section we are concerned with difference equations which contain 1 2and , but nott t t  y y y

+ +or

further terms in the sequence.

Before looking at a general method to solve difference equations, we will consider an iterative method,

which will additionally provide some insight into the nature of the solution to a difference equation.

Particularly in the case of first order difference equations, simple iteration of the differencing or recursive

rule ‘plays out’ the recursive rule over a number of time periods, in order to see whether we can depict a

general characterisation of the time path in y(t).

For example:

1 02, 15.t t  y y y+

= + =  

From this equation we can deduce step-by-step that:

1 0

2 1 0 0

3 2 0 0

0

2

2 ( 2) 2 2(2)

2 [ 2(2)] 2 2(2)

.......

And in general, for any period

(2) 15 2t 

 y y

 y y y y

 y y y y

 y y t t 

= +

= + = + + = +

= + = + + = +

= + = +

 

This equation indicates the y value of any time period and therefore constitutes the solution of the

difference equation.

This method is crude and quickly runs into limitations and essentially corresponds to the process of direct

integration, which is feasible for certain types of differential equations. For this reason we have to use more

general solution methods.

General Solutions

To find the general solution of the difference equation means finding a formula giving all sequences {t  y }

which satisfy 1t t  y cy b−

+ = . As in the differential equation case this will contain an arbitrary constant

which will be tied down if we specify the value of  t  y for some particular t. 

We start with the simple case where b = 0. Then 1t t  y cy+ = − for all t  and hence:

1 0

2

2 1 0

3

3 0

( )

( )

 y cy

 y cy c y

 y c y

= −

= − = −

= −

 

and so on. It follows that:

0( ) for 0,1, 2....t 

t  y c y t = − = .

Page 29: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 29/36

29

To summarise, if b = 0, (i.e. a linear, homogenous difference equation) the general solution to

1t t  y cy b+

+ = is ( )t 

t  y A c= − , where A is an arbitrary constant which may be interpreted as y0.

In the case where 0b ≠ , (a liner, non-homogenous DE) we use a method similar to the one we used to

solve the analogous differential equation.

The general solution will consist of the sum of two components: a particular solution y p , which is any of 

the complete non-homogenous equation 1t t  y cy b−

+ = , and a complementary function yc , which is the

general solution of the reduced equation 1 0t t  y cy−

+ = .

First we consider the complementary function:

Our experience with the example above suggests that we might try a solution of the form ( )t 

t  y A c= − .

Now we must look for the particular solution, which relates to the complete equation 1t t  y cy b+

+ = .

We note that for y p  we can choose any solution of  1t t  y cy b+

+ = . Therefore, if a trial solution of the

simplest form t  y k = (a constant) can work out, no real difficulty will be encountered.

Now, if t  y k = , then y will maintain the same constant value over time and we must have 1t  y k 

+= . If 

we substitute these values into 1t t  y cy b+

+ = , we get:

k ck b+ = and1

bk 

c=

+.

Since this particular value of k satisfies the equation, the particular solution can be written as:

( ) ( 1)1

 p

b y k c

c= = ≠ −

+.

Since this is a constant, a stationary equilibrium is indicated in this case.

What if  1c = − ?

If  1c = − , the particular solution1

 p

b y

c=

+is not defined and some other solution of the non-

homogenous equation 1t t  y cy b+

+ = must be found.

In this case we use the trick of trying a solution of the form 1. This implies that ( 1).t t  y kt y k t +

= = +  

Substituting these into 1t t  y cy b+

+ = we find:

( 1)

[becasue 1]1

( ) p

k t ckt b

and 

bk b c

t ct 

 y kt bt 

+ + =

= = = −+ +

∴ = =

 

Page 30: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 30/36

30

This form of the particular solution is a non-constant function of t, it therefore represents a moving

equilibrium.

Adding c y and  p y together, we may now write the general solution in one of the two following forms:

( )t 

t  y A c= − + [general solution, case of 1]1

bc

c≠ −

( )t 

t  y A c= − + bt  [general solution, case where 1] A bt c= + = − .

To eliminate the arbitrary constant., we have to use the initial condition that 0 when 0t  y y t = = .

Letting 0t = , we have:

For 1c = − :

0

0

and1 1

( )( )1 1

b b y A A y

c c

b b y y c

c c

= + = −+ +

∴ = − − ++ +

 

and for 1c ≠ −  

0   y A= , so the definite version of this equation is:

0t  y y ct = +  

Example:

Find the solution of the difference equation1

1 22

t t  y y+

− = , which satisfies the boundary condition

0 2 y = .

As a particular solution  p y we try t  y k = (a constant).

This satisfies the equation provided :

12.

2

4

k k 

− =

∴ =

 

We can findc y by trying a solution ( )t 

t  y A c= −  

I.e.1

( )2

t  y A= , where  A is an arbitrary constant.

The general solution to the difference equation is therefore:1

4 ( ) 4 22

t t 

t  y A A−

= + = +  

It remains to use the boundary condition 0 2 y = to find A. Setting t =0 in the general solution we have

Page 31: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 31/36

31

1

2 4

2

4 2 t 

 A

 A

and 

 y−

= +

∴ =

= −

 

Second-Order Difference Equations

A second-order difference equation is one that involves an expression2

t  y∆ , called the second-difference

of  t  y , but contains no differences of order higher than 2. The symbol2

∆ is an instruction to take the

second-difference as follows:

2

1

2 1 1

2 1

( ) ( )

( ) ( )

2

t t t t  

t t t t  

t t t 

 y y y y

 y y y y

 y y y

+

+ + +

+ +

∆ = ∆ ∆ = ∆ −

= − − −

= − +

 

A simple variety of second-order difference equation takes the form:

(1) 2 1 1 2t t t  y a y a y c+ +

+ + =  

This equation is linear, non-homogenous and with constant coefficients 1 2,a a and constant term c.

As before, the solution has two components: a particular solution y p , and a complementary function yc ,

The particular solution – defined as any solution of the complete equation – can be found simply by trying

a solution of the form t  y k = . Substituting this value into (1) above, gives:

1 2

1 2

1 2

1 2

1 2

1

Thus, so long as (1 ) 0, the particular solution is:

( ) , where 11

 p

k a k a k c

ck 

a a

a a

c y k a a

a a

+ + =

∴ =+ +

+ + ≠

= = + ≠ −+ +

 

Example: Find the particular solution of 

2 1

1 2

1 2

3 4 6.

3, 4, 6

61, 3

1 3 4

t t t 

 p

 y y y

 Here a a c

Since a a y

+ +− + =

= − = =

+ ≠ − = =− +

 

Case where 1 2 1a a+ = − :

Page 32: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 32/36

32

Here the trial solutiont  y k = breaks down and it is necessary to try

t  y kt = instead.

Substituting this into (1) above and keeping in mind that we now have:

1

2

1 2

1 2

1 2 1 1

( 1)

( 2)

( 2) ( 1)

[since 1](1 ) 2 2

 y k t 

 y k t 

k t a k t a kt c

and 

c ck a a

a a t a a

+

+

= +

= +

∴ + + + + =

= = + = −+ + + + +

 

Thus we can write the particular solution as1 2 1

1

( ) , where 1, 22

 p

c y kt t a a a

a= = + = − ≠ −

+.

Example: Find the particular solution of  2 1 2 12.t t t  y y y+ +

+ − =  

The Complementary Solution:

To find the complementary function, we must concentrate on the reduced equation:

(2) 2 1 1 2 0t t t  y a y a y+ +

+ + =  

The solution procedure involves solving the for the roots of the characteristic equation. In this case the

characteristic equation is2

1 2 0b ba a+ + = and it possesses two characteristic roots:

21 1 2

1 2

4,

2

a a ab b

− ± −= .

Three possible situations may be encountered with regard to the characteristic roots:

1.  Distinct real roots, i.e. 1 2b b≠ .

If the characteristic equation has got two distinct real roots, the solution is:

1 1 2 2 1 2, where and are constantst t 

c y Ab A b A A= +  

2.  Repeated real roots, i.e. 1 2b b=  

If the characteristic equation has co-incident roots, 11 2

2

ab b b= = = − , then the solution is as

follows:

1 2 1 2 3( + ) =t t t t  

c y Ab A b A A b A b= + =  

BUT since the two components have collapsed into a single term, we are short of a constant. We

therefore have to supply the missing component. We use the trick of multiplyingt 

b by the

variable t.

The complementary function for the repeated-root case is therefore:

Page 33: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 33/36

33

3 4

t t 

c y A b A tb= +  

3.  Complex roots.

If 2

1 24a a< , we have complex conjugate roots. We won’t deal with this possibility in this

course.

SYSTEMS OF DIFFERENTIAL & DIFFERENCE EQUATIONS

Refer to Chiang, Chapter 18

So far we have solved only stand-alone differential and difference equations. However, we may be

confronted with simultaneous differential and difference equations.

When?

These arise from a set of interacting changes, e.g. in multi-sector markets when changes in one market

affects conditions in another.

To deal with systems of equations, we have to transform higher-order equations into a more manageable

form (i.e. all of the first-order).

Suppose we have:

2 1 1 2t t t  y a y a y c+ +

+ + =  

Then we can let:

1

1 2

t t 

t t 

 x y

 x y

+

+ +

=

⇒ = 

This gives us:

1 1 2

10

t t t 

t t 

 x a x a y c

 x y

+

+

+ + =

− = 

Similarly we can transform a nth

order differential equation into a system of n first-order equations. Given

the differential equation

1 2''( ) '( ) ( ) 0 y t a y t a y t + + = we introduce a new variable x(t) defined by

( ) '( ) [implying '( ) ''( )] x t y t x t y t = =  

Then we can re-write the differential equation as the following system of two first-order equations:

1 2'( ) ( ) ( ) 0

'( ) ( ) 0

 x t a x t a y t 

 y t x t 

+ + =

− = 

We therefore have to transform any higher order difference/ differential equation into a system of 

first-order difference or differential equations.

Page 34: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 34/36

34

 

Solving Systems of Dynamic Equations:

The methods for solving simultaneous differential equations and simultaneous difference equations arequite similar. We’ll only consider linear equations with constant coefficients.

1.  Simultaneous Difference Equations

Suppose we have

1

1

6 9 4

0

t t t 

t t 

 x x y

 y x

+

+

+ + =

− = 

Since particular solutions represent intertemporal equilibrium values, let us denote them by  x  

and  y . As before we first try constant solutions, namely 1 1andt t t t   x x x y y y+ +

= = = = .

This works in the present case, because when we substitute these into the system of equations we

get:

7 9 4

0

1

4

 x y

 x y

 x y

+ =

− + =

⇒ = =

 

(If these constant solutions don’t work then you have to try solutions of the form

1 2,t t  x k t y k t = = etc.

For the complementary functions, we should – using our previous experience – adopt trial

solutions of the form:

and , where and are arbitrary constants and the base

represents the characteristic root.

t t 

t t  x mb y nb n m b= =

 

It is automatically implied that1 1

1 1andt t 

t t  x mb y nb+ +

+ += = .

To simplify matters we are using the same base b for both variables, although their coefficients

are allowed to differ.

It is our aim to find the values of b, m and n that can make the trial solutions above satisfy the

reduced homogenous version of 1

1

6 9 4

0

t t t 

t t 

 x x y

 y x

+

+

+ + =

− =.

Upon substituting the trial solutions into the reduced versions of 1

1

6 9 4

0

t t t 

t t 

 x x y

 y x

+

+

+ + =

− =and

cancelling the common factor 0t b ≠ , we obtain two equations:

Page 35: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 35/36

35

( 6) 9 0

0

b m n

m bn

+ + =

− + = 

This can be considered as a linear homogenous-equation system in two variables m and n

(considering b as a parameter for the time being).

Rule out the trivial solution of m = n = 0, by requiring the coefficient matrix of the system to be

singular. That is, we require the determinant of the matrix to be equal to zero:

2

1 2

6 9det 6 9 0

1

( ) 3

bb b

b

b b b

+ = + + =

∴ = = = −

 

The above equation is called the characteristic equation and its roots the characteristic roots, of the

given simultaneous difference-equation system.

Given the value of b, we can get the values of m and n from( 6) 9 0

0

b m n

m bn

+ + =

− + =.

Since the system is homogenous, an infinite number of solutions for (m, n) will emerge,

expressible in the form of the equation m = kn, where k is a constant.

In fact, for each root bi, there will in general be a distinct equation mi =k ini,. Even with repeated

roots, we should still use two such equations m1 =k 1n1, and m2 =k 2n2  in the complementary

functions.

Moreover, with repeated roots, we recall that we can write the complementary functions as:

1 2

1 2

( 3) ( 3)

( 3) ( 3)

t t 

t t 

 x m m t 

 y n n t 

= − + −

= − + − 

The factors of proportionality between mi and ni  must of course satisfy the given equation system

which mandates that1t t  y x

+= , i.e.

1 1

1 2 1 2

1 2 1 2

1 2 2 1 2

( 3) ( 1)( 3) ( 3) ( 3)

Dividing through by ( 3) :

3 3 ( 1)

3( ) 3

t t t t  

n n t m m t  

n n t m m t  

or n n n t m m t  

+ +− + + − − − + −

− − + = +

− + − = +

 

Equating terms with t on two sides of the equals sign and similarly for the terms without t, we

find that

Page 36: Notes Section 6 Integration Differentials and Differential Equations

7/30/2019 Notes Section 6 Integration Differentials and Differential Equations

http://slidepdf.com/reader/full/notes-section-6-integration-differentials-and-differential-equations 36/36

1 1 2

2 2

1 3 2 4,

1 3 4

2 4

3( )

3

If we now write and then it follows that:

3( )

3

m n n

and 

m n

n A n A

m A A

m A

= − +

= −

= =

= − +

= −

 

Thus the complementary functions can be written as:

3 4 4

3 4

3 4

3( )( 3) 3 ( 3)

3 ( 3) 3 ( 1)( 3)

( 3) ( 3)

t t 

c

t t 

t t c

 x A A A t 

 A A t 

and 

 y A A t 

= − + − − −

= − − − + −

= − + −

 

2.  Simultaneous Differential Equations

The solution to a first-order linear differential equation is similar. The only major modification is

to change the trial solutions to:

( )

( )

rt 

rt 

 x t me

and 

 y t ne

=

=

 

This implies that '( ) and '( )rt rt   x t rme y t rne= = .