Solving Differential Equations Using the Laplace Transformation

Chapter 4: Solving Differential Equations using the Laplace Transform In previous chapters we have investigated solvin

Views 82 Downloads 0 File size 239KB

Report DMCA / Copyright

DOWNLOAD FILE

Recommend stories

Citation preview

Chapter 4:

Solving Differential Equations using the Laplace Transform

In previous chapters we have investigated solving differential equations of the form:

a n y n + a n −1 y n −1 + " + a1 y '+ a 0 y = g (t )

(1)

(Note: An nth-order linear non-homogeneous differential equation can be transformed into a non-homogeneous system of n linear, 1st-order differential equations). We have seen that if the coefficients an, an-1, . . . , a0 are numbers, we can find the general solution of the above, by first solving the corresponding homogeneous system and then adding the particular solution of the non-homogeneous equation. The degree of difficulty in obtaining a solution for (1), depends on the nature of g(x). If g(x) is a smooth continuous function we have investigated two techniques: i) Method of undetermined coefficients; ii) Method of variation of parameters. On the other hand, if g(x) is a non-smooth function, such as a piecewise-function, solving (1) using the known techniques can become very difficult. In this chapter, we investigate a technique that transforms (1) into an algebraic equation that can often be easily solved, so that the solution to the differential equation can be obtained. It works for smooth and non-smooth functions g(x). Furthermore, the technique is also valid, even if the coefficients of the left had-side of (1) are functions of the independent variable t. The new technique, classified as an integral transformation, is referred to as: Laplace Transform.

4.0 Introduction and Background Information Definition: Let f(t) be a function on the interval [0, ∞). The Laplace Transform of f(t) is the function (in terms of s ): ∞

L{ f (t )} = ∫ e − st f (t )dt 0

Because the Laplace transform yields a function of s, we often use the notation L{ f(t) } = F(s) to denote the Laplace transform of f(t).

The Laplace transforms of functions f(t) can be computed by hand. Clearly the calculations can become very complex and tedious, depending on the nature of f(t). A Computer Algebra System, can be used to directly evaluate the Laplace transform of a given function. In Maple the laplace function is in the library inttrans. Lets use Maple to calculate some Laplace transformations:

Example: Calculate the Laplace transformations of the functions:

i) f(t) = eat ii) f(t) = sin( at); iii) f(t) = cos(at); iv) f(t) = tn v) f(t) = 5t + e4t – sin3t Solution: First we invoke the library inttrans and then use the function laplace:

> restart: > with(inttrans); [ addtable , fourier, fouriercos, fouriersin, hankel, hilbert, invfourier, invhilbert, invlaplace, invmellin, laplace, mellin, savetable ] > > laplace( exp(a*t), t, s);

> laplace(sin(a*t), t, s);

1 s−a a s + a2 2

> laplace( cos(a*t), t, s);

s s + a2 2

> assume( n>0); > laplace(t^n, t, s); s

The above can also be written as: Note that : Γ(n+ 1) = n! > laplace(t^5, t, s);

( −n~ − 1 )

n! s n +1

Γ( n~ + 1 )

120

1 s6

> laplace( 5 *t + exp(4*t) - sin(3*t), t, s); 5

1 1 3 + − 2 2 s−4 s +9 s

The Laplace transformation obeys the linearity property which is stated by the following theorem: Theorem 1: Let a and b be constants. Then the Laplace transformation of a linear combination of functions f(t) and g(t) is: L{ a f(t) + b g(t) } = a L{ f(t) } + b L { g(t) }

In Calculus, we have seen that improper integrals may diverge. Thus the Laplace tranform may not exist for some functions. The following definition and theorem provide an understanding about the types of functions for which the Laplace transform exists. Definition: A function f is of exponential order b if there are numbers b, M >0 and T >0 such that:

| f(t) | ≤ M eb t for t > T. For example, the functions f(t) = 5t, f(t) = e-t and f(t) =10 sint are all of exponential of order 1, since: | 5 t| ≤ et

|e- t| ≤ et and |10 sint | ≤ et for t > T

Definition: A function is piecewise continuous on interval [0, ∞ ) if in any interval a ≤ t ≤ b there are at most a finite number of points tk at which f has discontinuities and is continuous on each interval tk – 1 < t < tk Theorem 2: Suppose f is a piecewise continuous function on the interval [0, ∞ ) and that is of exponential order b for t > T. Then the Laplace transform L { f(t) } exists for s > b.

Throughout the chapter we will only be concerned with functions that have a Laplace transform.

− 1 0 ≤ t ≤ 4 Example: Find the Laplace transform of f(t) =  t>4 1 Solution: We first present a solution finding the Laplace transform by hand. Certainly the given function is of exponential order (bounded by an exponential), so the Laplace transform exists. ∞

4



L{ f (t )} = ∫ f (t )e dt = ∫ (−1)e dt + ∫ 1e − st dt − st

0

− st

0

4

t =4

t =M

=

 e − st   e − st    + lim −   s  t = 0 M →∞  s  t = 4

=

1 −4s 1 e − 1 − lim e − Ms − e − 4 s s s M →∞

=

1 −4s 2e − 1 s

(

(

)

(

)

)

Now let’s use Maple to calculate the Laplace transform: > restast: > with(inttrans): First we use the command "piecewise" to define the given function: > f:= piecewise( t>=0 and t 4, 1);

f := {

-1 1

−t ≤ 0 and t < 4 4 plot( Heaviside(t -4) - Heaviside(4 -t), t = 0..8);

Taking the Laplace transform of the above: > laplace(Heaviside(t -4) - Heaviside(4 -t), t, s); 2

e

( −4 s )

s



1 s

An important function in modeling many physical situations is the unit step function Ua(t) which is defined as: Definition: The unit step function

U(t – a) = Ua(t) is defined as:

0, 0 ≤ t < a U(t – a) = Ua(t) =  t≥a 1, Clearly: U(t – a) = Ua(t) = Heaviside( t – a) For the special case where a =0, we define: U(t-0) = U(t) = Heaviside(t) The unit step function is useful in defining functions that are piecewise continuous. Thus the function:

 g (t ), 0 ≤ t < a f (t ) =  t≥a  h(t ), can be re-defined as: f(t) = g(t) [ U(t –0) – U(t –a) ] + h(t) U(t-a) = = g(t) [ 1 – U(t-a) ] + h(t) U(t –a) (Check to verify the validity of the above definition. See also exercise #4 for an extension)

Besides the unit step function, other functions are needed to model situations where a mechanical (or electrical system) are acted upon by an external force of large magnitude for a very short period of time. For example, a mass on a spring could be given a sharp blow, a ball (baseball, golf ball, tennis ball) could be send soaring when struck violently by some kind of club ( baseball bat, golf club, tennis racket). To model such force we use the following functions.

Definition: The unit impulse function δa ( t – t0) is defined as:

 0,  1 δ a (t − t 0 ) =   2a  0,

0 ≤ t < t0 − a t0 − a ≤ t < t0 + a t ≥ t0 + a

Note, that from small values of a the above function is essentially a constant function of very large magnitude that is “on” for just a very short time, around t0 ∞

The above function also posses the property :

∫δ

a

(t − t 0 )dt = 1

0

(this results from the fact, that the area under the curve is equal to 1)

In practice it is also convenient to work with another function, a function that approximates the unit impulse function: Definition: The Dirac delta function is defined as:

δ (t − t 0 ) = lim δ a (t − t 0 ) a →0

Thus the Dirac delta function has the properties:

∞, t = t 0 δ (t − t 0 ) =   0, t ≠ t 0



and

∫ δ (t − t

0

)dt = 1

0

In Maple the Laplace transforms of the Dirac delta functions can easily be found: > with(inttrans): > assume (t0 > 0): > laplace(Dirac(t - t0), t, s); e

( −s t0~ )

> laplace(Dirac(t), t, s); 1

> laplace(Dirac(t - Pi), t,s); e

( −s π )

Properties of the Laplace Transform: A number of properties are stated to make the Laplace transform of various functions easier to calculate. The properties are direct consequences of properties of integrals: Shifting Property:

If L{ f(t) } = F(s), then

L{ ea t f(t)} = F( s –a)

In order to be able to use the Laplace transform to solve differential equations, we need to be able to compute the Laplace transform of the derivatives of arbitrary functions: Laplace Transform of 1st Derivative: L{ f’ (t) } = s L{ f(t)} - f(0)

Laplace Transform of Higher Derivatives: L{ f(n) (t) } = sn L{ f(t) } – s n –1 f(0) - s n –2 f’ (0) - . . . – s f(n –2) (0) - f(n –1)(0)

Derivatives of the Laplace Tranform: L{ tn f(t) } = (−1) n

d n F ( s) ds n

Laplace transform involving the unit step function: L{ F(t – a) U(t –a)} = e-a s F(s), where F(s) = L{f(t)}

Laplace transform of the Dirac delta function:

L{δ (t − t 0 )} = e − st0

Inverse Laplace Transform: So far we have seen how to find the Laplace transform of a function. In this section, we reverse the process: given a function F(s) we want to find a function f(t) such that L{ f(t) } = F(s) Definition: The Inverse Laplace Transform of a function F(s) is the unique continuous function f(t) on [0, ∞ ) that satisfies L { f(t) } = F(s). We denote the inverse of the Laplace transform of F(s) as:

f(t) = L-1 { F(s) } The inverse Laplace transforms of functions F(s)) can be computed by hand. Clearly the calculations can become very complex and tedious, depending on the nature of F(s). A Computer Algebra System, can be used to directly evaluate the inverse Laplace transform of a given function. In Maple the invlaplace function is in the library inttrans. Lets use Maple to calculate some inverse Laplace transformations: > restart: > with(inttrans): > > invlaplace(s/(s^2 + 2* s + 5), s , t); e

( −t )

1 ( −t ) cos( 2 t ) − e sin( 2 t ) 2

> invlaplace((3*s -4)/(s^2 - 4*s), s ,t); 1+2e

(4 t)

> invlaplace((2*s^3 - 4*s)/((s^2 - s)*(s^2 + 9)), s,t); 1 11 11 − e t + cos( 3 t ) + sin( 3 t ) 5 5 15

Properties of the inverse Laplace Transform: Linearity Property: Let L-1{ F(s) } and L-1{ G(s) } be the inverse laplace transforms for f(t) and g(t) respectively. Let a and b be constants. Then: L-1 {a F(s) + b G(s) } = a L-1{ F(s)} + b L-1{ G(s) }

Note: The inverse Laplace transform does not always exists. The following statement provides a condition that F(s) must satisfy in order for L-1{ F(s) } to exist:

Existence of the inverse Laplace transform:

If the limit:

lim F ( s ) = lim L{ f (t )} = 0 s →∞

s →∞

then the inverse Laplace transform exists as a continuous or a piecewise continuous function. Otherwise, it does not exist. Inverse Laplace transform involving the step function: L-1{e- a s F(s) } = f(t – a) U(t –a), where L { f(t) } = F(s)

4.1 Solving a Differential Equation using Laplace Transformations Laplace transforms can be used to solve initial value problems, by transforming a differential equation to an algebraic equation. The overall method can be summarized as follows: Method: • Compute the Laplace transform of each term of the differential equation • Solve the resulting (algebraic) equation for L{ y(t)} = Y(s) • Determine the function y(t) by computing the inverse laplace transform of Y(s)

Consider the initial value problem:

dny d n −1 y a n n + a n−1 n−1 + " + a0 y = g (t ) dt dt y(0) = y0, y’(0) = y1, . . . , y(n-1)(0) = yn-1 Taking the Laplace transform of each term, yields:  d n −1 y  d n y  a n L  n  + a n −1 L  n −1  + " + a 0 L{ y} = L{g (t )}  dt   dt 

Using the property of the laplace transformations of derivatives, we obtain:

[

]

[

]

a n s n Y ( s ) − s n −1 y (0) − " − y ( n −1) (0) + a n −1 s n −1Y ( s ) − s n − 2 y (0) − " − y ( n − 2 ) (0) + + " + a 0Y ( s ) = G ( s ) We solve the resulting algebraic equation for Y(s) and then take the inverse laplace transform to obtain the expression for Y(t). Example: Solve the initial value problem, using the laplace transform:

y’’’ + y’’ – 6 y’ = sin4t, Plot the solution

y(0) = 2, y’(0) =0, y’’(0) = -1

Solution: We will use Maple to implement the steps of the solution methodology.

> with(inttrans): We define the given differential equation: > dfe:=diff(y(t),t$3) + diff(y(t), t$2) - 6*diff(y(t), t)= sin(4*t); ∂  ∂3   ∂2  dfe :=  3 y( t )  +  2 y( t )  − 6  y( t )  = sin( 4 t )  ∂t   ∂t   ∂t 

>

Take the Laplace transform of both sides: > step1:= laplace(dfe, t,s); (2)

step1 := s ( s ( s laplace( y( t ), t, s ) − y( 0 ) ) − D( y )( 0 ) ) − ( D )( y )( 0 ) + s ( s laplace( y( t ), t, s ) − y( 0 ) ) − D( y )( 0 ) − 6 s laplace( y( t ), t, s ) + 6 y( 0 ) = 1 4 2 s + 16

> Note that Maple displays the terms of the left side, using the property of the laplace transform of the derivatives. (multiply out the terms in the nested parentheses) Let's substitute on the above the initial conditions (Be careful on the syntax of the command): > step2:= subs({y(0) = 2, D(y)(0) =0, (D@@2)(y)(0)=-1}, step1); step2 := s 2 ( s laplace( y( t ), t, s ) − 2 ) + 13 + s ( s laplace( y( t ), t, s ) − 2 ) − 6 s laplace( y( t ), t, s ) 1 =4 2 s + 16

> Recall that laplace(y(t),t,s) = Y(s). Thus we can solve the above algebraic equation for Y(s): > step3:=simplify(solve(step2, laplace(y(t), t,s))); step3 :=

2 s 4 + 19 s 2 − 204 + 2 s 3 + 32 s s ( s 4 + 10 s 2 + s 3 + 16 s − 96 )

> We now compute the inverse laplace ransform of the above: > solution:= invlaplace(step3, s,t); solution :=

17 2 ( 2 t ) 7 ( −3 t ) 11 1 e cos( 4 t ) − sin( 4 t ) − e − + 8 25 125 1000 500

The solution can be easily plotted as: > plot(solution, t = -2..2);

> Example: Solve the initial value problem:

1, 0 ≤ t < π y’’ + 8 y = f(t) where f (t ) =  t ≥π 0,

and y(0) = y’(0) =0

Solution: We can solve the problem for each branch of f(t), using the techniques for 2nd order linear differential equations. This will be a time consuming and error-prone method. The power of the Laplace transform can be used to directly solve this problem where f(t) is a step function. First we re-define the piecewise continuous functions using the Heaviside function. Using the “formula” presented in the previous section:

f(t) = 1[ 1 – U(t - π) ] + 0 U(t - π) = 1 – U(t - π) = 1 – Heaviside(t - π) Let’s use Maple to define f(t), and then solve the DFE using the Laplace transform: > with(inttrans): > > f:=t-> 1 - Heaviside(t -Pi); f := t → 1 − Heaviside( t − π )

> dfe:= diff(y(t), t$2) + 8 * y(t) = f(t);  ∂2  dfe :=  2 y( t )  + 8 y( t ) = 1 − Heaviside( t − π )  ∂t 

We take the Laplace transforms of both sides: > step1:=laplace(dfe, t,s);

( −s π )

1 e step1 := s ( s laplace( y( t ), t, s ) − y( 0 ) ) − D( y )( 0 ) + 8 laplace( y( t ), t, s ) = − s s

We apply the initial conditions to the previous step: > step2:=subs({y(0) =0, D(y)(0) =0}, step1); ( −s π )

1 e step2 := s laplace( y( t ), t, s ) + 8 laplace( y( t ), t, s ) = − s s 2

Solve the above for laplace(y(t), t,s) = Y(s) : > step3:= simplify(solve(step2, laplace(y(t), t,s))); ( −s π )

−1 + e step3 := − s ( s2 + 8 )

Find the solution by taking the inverse Laplace transfrom of the above: > sol:= invlaplace(step3, s,t); 1 1 1 1 sol :=  − + cos( 2 2 ( −t + π ) )  Heaviside( t − π ) + − cos( 2 2 t ) 8 8 8 8  

> plot(sol, t = 0..6);

>

4.2 Solving Systems of Differential Equations using the Laplace Transform Laplace transforms can be used to solve initial value problems that involve a system of linear differential equations. The method is applied in much the same way as demonstrated for the case of a single initial value problem Method: • Compute the Laplace transform of each term for each of the differential equations • Solve the resulting (algebraic) system for the Laplace transform of each unknown function • Determine the unknown functions by taking the inverse Laplace transform for each of the expressions resulting from the previous step. Example: Solve the system: x’’ = -2 x – 4y - cost y’’ = -x – 2y + sint x(0) = 0, x’(0) = 0, y(0) =0, y’(0) =0 Solution: Let’s use Maple, and follow the steps outlined in the above method:

> with(inttrans): First we define the system of differential equations: > sys:={diff(x(t), t$2) = - 2*x(t) - 4*y(t) - cos(t), diff(y(t),t$2) = -x(t) - 2*y(t) + sin(t)}; ∂2 ∂2 sys := { 2 x( t ) = −2 x( t ) − 4 y( t ) − cos( t ), 2 y( t ) = −x( t ) − 2 y( t ) + sin( t ) } ∂t ∂t

Apply the Laplace transform to each equation: > step1:=laplace(sys, t,s); step1 := { s ( s laplace( x( t ), t, s ) − x( 0 ) ) − D( x )( 0 ) = s , −2 laplace( x( t ), t, s ) − 4 laplace( y( t ), t, s ) − 2 s +1 s ( s laplace( y( t ), t, s ) − y( 0 ) ) − D( y )( 0 ) = 1 −laplace( x( t ), t, s ) − 2 laplace( y( t ), t, s ) + 2 } s +1

Apply the initial conditions: > step2:= subs({x(0)=0, D(x)(0) =0, y(0)=0, D(y)(0)=0}, step1); step2 := { s 2 laplace( x( t ), t, s ) = −2 laplace( x( t ), t, s ) − 4 laplace( y( t ), t, s ) − s 2 laplace( y( t ), t, s ) = −laplace( x( t ), t, s ) − 2 laplace( y( t ), t, s ) +

s , s +1 2

1 } s +1 2

Solve the resulting algebraic system for X(s) and Y(s): > step3:= solve(step2,{laplace(x(t), t,s), laplace(y(t),t,s) } ); step3 := { laplace( y( t ), t, s ) =

s2 + s + 2 s3 + 2 s + 4 , laplace ( x ( t ) , t , s ) = − } s2 ( 4 + s4 + 5 s2 ) s2 ( 4 + s4 + 5 s2 )

Take the inverse Laplace transform of the each term of the above expression: > sol:=invlaplace(step3, s,t); 1 1 1 1 1 1 sol := { y( t ) = t + + cos( 2 t ) − sin( 2 t ) − cos( t ) − sin( t ), 2 4 12 12 3 3 1 1 1 1 4 x( t ) = −t − + cos( 2 t ) − sin( 2 t ) + cos( t ) + sin( t ) } 2 6 6 3 3 >

4.3 Application Models using the Laplace Transform Example: A double pendulum consists of two masses m1 and m2 attached to strings of lengths l1 and l2 respectively. For oscillations, of small displacements, in a vertical plane, the system of differential equations describing the motion is:

d 2θ 1 d 2θ 2 (m1 + m2 )l + m2 l1l 2 + (m1 + m2 )l1 gθ 1 = 0 dt 2 dt 2 2 1

m2l22

d 2θ 2 d 2θ 1 + m l l + m2 l2 gθ 2 = 0 2 1 2 dt 2 dt 2

and

Assuming that m1 =3, m2 = 1, l1 = l2 = 16, g = 32, solve the equations of motion to determine θ1(t) and θ2(t). Are the motions periodic? Assume that the initial conditions are: θ1(0) = 1, θ2(0) = 0, θ1’(0) = 0, θ2’(0) = -1 Plot the solutions. Solution: Since we assume small oscillations, we can use the approximations: sin θ 1 ≈ θ 1

and

sin θ 2 ≈ θ 2

Substituting the given values to the equations of motion, we obtain: 4 ⋅ 16 2 θ 1 ' '+16 2 θ 2 ' '+4 ⋅ 16 ⋅ 32θ 1 = 0 16 2 θ 1 ' '+16 2 θ 2 ' '+16 ⋅ 32θ 2 = 0 which simplifies to: 4 θ1’’ + θ2’’ + 8θ1 = 0 θ1’’ + θ2’’ + 2 θ2 = 0 Let’s use Maple, and solve the above system with the Laplace transforms: > with(inttrans): We define the system of equations of motion: > sys:= {4*diff(theta1(t), t$2) + diff(theta2(t), t$2) + 8*theta1(t) =0, diff(theta1(t), t$2) + diff(theta2(t), t$2) + 2*theta2(t) = 0}; sys :=  ∂2   ∂2    ∂2   ∂2 { 4  2 θ1( t )  +  2 θ2( t )  + 8 θ1( t ) = 0,  2 θ1( t )  +  2 θ2( t )  + 2 θ2( t ) = 0 }  ∂t   ∂t   ∂t   ∂t 

Taking the Laplce transorms of each equation: > step1:= laplace(sys, t,s); step1 := { s ( s laplace( θ1( t ), t, s ) − θ1( 0 ) ) − D( θ1 )( 0 ) + s ( s laplace( θ2( t ), t, s ) − θ2( 0 ) ) − D( θ2 )( 0 ) + 2 laplace( θ2( t ), t, s ) = 0, 4 s ( s laplace( θ1( t ), t, s ) − θ1( 0 ) ) − 4 D( θ1 )( 0 ) + s ( s laplace( θ2( t ), t, s ) − θ2( 0 ) ) − D( θ2 )( 0 ) + 8 laplace( θ1( t ), t, s ) = 0 }

Subtituting the initial conditions: > step2:= subs({theta1(0) =1, D(theta1)(0) =0, theta2(0) =0, D(theta2)(0) = -1}, step1); step2 := { s ( s laplace( θ1( t ), t, s ) − 1 ) + 1 + s 2 laplace( θ2( t ), t, s ) + 2 laplace( θ2( t ), t, s ) = 0, 4 s ( s laplace( θ1( t ), t, s ) − 1 ) + 1 + s 2 laplace( θ2( t ), t, s ) + 8 laplace( θ1( t ), t, s ) = 0 }

Solving for the laplace transform of each of the unknown functions: > step3:= solve(step2,{laplace(theta1(t), t,s), laplace(theta2(t), t,s) } ); step3 := { laplace( θ2( t ), t, s ) = −

8 − 8 s + 3 s2 −2 + 3 s 3 + 8 s , } laplace ( θ1 ( t ) , t , s ) = 3 s 4 + 16 s 2 + 16 3 s 4 + 16 s 2 + 16

Taking the inverse Laplace of each of the terms in the above expression: > sol:= invlaplace(step3, s,t); 1 2 1 2 1 1 sol := { θ1( t ) = cos 3 t  − 3 sin 3 t  + cos( 2 t ) + sin( 2 t ), 2 8 3  8 3  2 1 2 1 2 θ2( t ) = −cos( 2 t ) − sin( 2 t ) + cos 3 t  − 3 sin 3 t  } 4 3 4 3    

> Plotting each of the solutions as a function of time: > assign(sol); > plot(theta1(t), t = 0..44);

> plot(theta2(t), t = 0..44);

Observe that the motion of the pendulums is not periodic.

We can also generate the phase plane portrait of the solution as: > plot([theta1(t), theta2(t), t =0..45], numpoints=200);

The above plot is known as the Lissajous curves.

Example: Two tanks T1 and T2 are connected with two pipes, so fluid can flow from one to another and vice versa. Tank T1 contains initially 100 gal of pure water. Tank T2 contains initially 100 gal or pure water in which 150 lb of salt are dissolved. The inflow into T1 is 2 gal/min fm T2 and 6 gal/min containing 6 lb of salt from the outside. The inflow into T2 is 8 gal / min from T1. The outflow from T2 is 8 gal/min. • Set up a model for the concentrate of salt in each tank • Solve the model • Plot the solution(s) Solution: Let y1(t) and y2(t) represent the solution concentrations of salt in T1 and T2 tanks respectively.

Observe that: (Rate of change in concentration) = ( Inflow / min ) – (Outflow / min) Thus:

y1 ' = − y2 ' =

8 2 y1 + y2 + 6 100 100

8 8 y1 − y2 100 100

The initial conditions for the model are: y1(0) = 0 and y2(0) = 150 Note that the above is linear 1st-order non-homogeneous system. We can use the (power of) Laplace transform to solve the above system: > > restart: > with(inttrans): We define the system of equations of motion: > sys:= {diff(y1(t), t) = -0.08*y1(t) + 0.02*y2(t) diff(y2(t), t) = 0.08*y1(t) - 0.08*y2(t)}; sys := {

+ 6,

∂ ∂ y1( t ) = −.08 y1( t ) + .02 y2( t ) + 6, y2( t ) = .08 y1( t ) − .08 y2( t ) } ∂t ∂t

Taking the Laplce transforms of each equation: > step1:= laplace(sys, t,s); step1 := { s laplace( y2( t ), t, s ) − 1. y2( 0. ) = .08000000000 laplace( y1( t ), t, s ) − .08000000000 laplace( y2( t ), t, s ), s laplace( y1( t ), t, s ) − 1. y1( 0. ) = −.08000000000 laplace( y1( t ), t, s ) + .02000000000 laplace( y2( t ), t, s ) +

6. } s 1.

Substituting the initial conditions: > step2:= subs({y1(0.) =0, y2(0.) =150}, step1); step2 := { s laplace( y2( t ), t, s ) − 150. = .08000000000 laplace( y1( t ), t, s ) − .08000000000 laplace( y2( t ), t, s ), s laplace( y1( t ), t, s ) = −.08000000000 laplace( y1( t ), t, s ) + .02000000000 laplace( y2( t ), t, s ) +

6. } s 1.

Solving for the laplace transfrom of each of the unknown functions: > step3:= solve(step2,{laplace(y1(t), t,s), laplace(y2(t), t,s) } ); 75. s + 4. step3 := { laplace( y1( t ), t, s ) = 75. , s ( 3. + 625. s 2 + 100. s ) 2. + 50. s + 625. s 2 } s ( 3. + 625. s 2 + 100. s )

laplace( y2( t ), t, s ) = 150.

Taking the inverse Laplace of each of the terms in the above expression: > sol:= invlaplace(step3, s,t); sol := { y1( t ) = 100. − 62.50000000 e y2( t ) = 100. + 125. e

>

( −.1200000000 t )

( −.1200000000 t )

− 75. e

− 37.50000000 e

( −.04000000000 t )

}

( −.04000000000 t )

,

Plotting each of the solutions as a function of time: > assign(sol); > plot(y1(t), t = 0..150);

> plot(y2(t), t = 0..150);

Superimposing the plots: > plot([y1(t), y2(t)], t =0..150);

> We can observe that an equilibrium is "eventually" achieved where each concentration levels off to the value of 100 lb. Clearly the same result is obtained by taking the limit, in the expressions obtained for y1(t) and y(t), as t approaches infinity.

4.4 Problems and Projects Problems:

1) Find the following Laplace transforms using Maple. Rewrite each function using the Heaviside . Make sure to verify that the re-definition of your function in terms of the Heaviside function is correct:



0 ≤ t