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

MATH 207 B.

Kuryel

23.12.2023

Midterm_02

1. Solve the following ordinary differential equation by Laplace transform. Find the
value of the response after 1.2 units of time.

 0; t 0
dy 
 5y  f (t )  10; 0  t  7
dt  0
 t 7
y(0)  0

f (t )  10 u(t )  u(t  7)


10
sy(s)  y(0)  5y(s)  (1  e7s )
s
10 10
(s  5)y(s)  (1  e 7s )  y(s)  (1  e 7s )
s s(s  5)
10 A B
   A  2, B  2
s(s  5) s s 5
2 2  7s
y(s)     (1  e )
 s s  5 
2 2 2e7s 2e7s
y(s)    
s s 5 s s 5
y(t )  2u(t )  2u(t )e 5t  2u(t  7)  u(t  7)e5(t  7)

t  7 : y(t )  2u(t )  2u(t )e 5t  2(1  e 5t )


y(1.2)  1.9950

1
MATH 207 B. Kuryel

2. Solve the following initial value problem by Laplace transform:

d2y dy
2
2  2y  et , y(0)  0 ve y (0)  1.
dt dt

1
s2 y(s)  sy(0)  y (0)  2  sy(s)  y(0)  2y(s) 
s 1
1
s2 y(s)  1  2sy(s)  2y(s) 
s 1
1 s2 s2
(s2  2s  2)y(s)  1   y(s) 
s 1 s 1 (s  1)(s2  2s  2)
s2 A Bs  C 1 1 8
y(s)     A  ,B   ,C 
(s  1)(s  2s  2) s  1 s  2s  2
2 2 5 5 5
1 1 1 s 8 1
y(s)   
5 s  1 5 s  2s  2 5 s  2s  2
2 2

1 1 1 s 8 1
y(s)   
5 s  1 5 (s  2s  1)  1 5 (s  2s  1)  1
2 2

1 1 1 s 8 1
y(s)   
5 s  1 5 (s  1)  1 5 (s  1)2  1
2

1 1 1 s 11 8 1
y(s)   
5 s  1 5 (s  1)2  1 5 (s  1)2  1
1 1 1 s 1 7 1
y(s)   
5 s  1 5 (s  1)2  1 5 (s  1)2  1
1 t 1 t 7
y(t )  e  e cos t  et sin t
5 5 5

3. Find the solution of the following integro differential equation:

t 2
y (t )  0 e y(t   )d  3; y(0)  0

1 3
sy(s)  y(0)  y(s) 
s2 s
 1  3  s2  2s  1  3
y(s)  s    y(s)   
 s  2  s 
 s2  s
3s  6 A B C
y(s)      A  6, B  6, C  3
s(s  1)2 s s  1 (s  1)2
y(t )  6  6et  3tet

2
MATH 207 B. Kuryel

4. Solve the following first-order initial value problem by the “Explicit Euler” and
“Improved Euler (Heun)” methods and compare the %relative errors of the two
methods for two steps:

dy t 1
 , y(0)  1, 0  t  1, h  0.5
dt y 1

The exact solution is y(t )  t 2  2t  4  1

Result =

t yexp yHeun yexact RE%_Explicit RE%_Implicit


___ ______ ______ ______ ___________ ___________

0 1 1 1 0 0
0.5 1.25 1.2917 1.2913 3.1974 0.029337
1 1.5833 1.6462 1.6458 3.7927 0.028479

5. Solve the following boundary value problem numerically by approximating the first and
second derivatives by central differences:

y   4y   4y  cos(x)
y(0)  1
y(2)  3

Use 4 internal points. u  2a  hb, v  4a  2h2c, w  2a  hb

u=0.4000, v=-2.7200, w=3.6000

Augmented Matrix

-2.72 3.60 0.00 0.00 -0.11


0.40 -2.72 3.60 0.00 0.22
0.00 0.40 -2.72 3.60 0.12
0.00 0.00 0.40 -2.72 -10.81

Upper Triangular Form

-2.72 3.60 0.00 0.00 -0.11


0.00 -2.19 3.60 0.00 0.21
0.00 0.00 -2.06 3.60 0.15
0.00 0.00 0.00 -2.02 -10.78

3
MATH 207 B. Kuryel

Solution =

x y
___ ______

0 1
0.4 19.991
0.8 15.075
1.2 9.2306
1.6 5.3315
2 3

6. Bonus

Show that the two solutions of the system x   Ax ,

 2 1
x1  et   and x2  e2t   are linearly independent.
1 0

2et e2t  t
W    e  0 . So, they are linearly independent.
 1 0 

—///—

You might also like