Professional Documents
Culture Documents
Generate polynomials
Manipulate polynomials
Generate transfer function
Manipulate transfer function
Perform partial fraction expansions
Minimum Required Software Package: MATLAB and the Control System Toolbox.
Background Theory and Concept:
The Laplace transform is a frequency-domain approach for continuous time signals
irrespective of whether the system is stable or unstable. The Laplace transform of a function
f(t), defined for all real numbers t 0, is the function F(s), which is a unilateral transform
defined by
F ( s )= est f (t) dt
0
Answer 1:
a.
clc
clear all
close all
P1=[1 7 2 9 10 12 15]
roots(P1)
Result:
P1 = 1
7
2
ans =
-6.8731
0.7632
0.7632
-1.0000
+
+
+
0.0000i
1.0822i
1.0822i
0.0000i
10
12
15
-0.3266 + 1.0667i
-0.3266 - 1.0667i
b.
clc
clear all
close all
P2=[1 9 8 9 12 15 20]
roots(P2)
Result:
P2 = 1
9
8
ans =
-8.1330
0.6996
0.6996
-1.2183
-0.5240
-0.5240
+
+
+
+
-
+
+
+
+
-
10
+
+
+
-
15
20
18
22
27
35
0.0000i
1.0281i
1.0281i
0.0000i
1.0751i
1.0751i
d.
clc
clear all
close all
P4=P1-P2
roots(P4)
Result:
P4 =0
-2
ans =
-3.0818
0.6463
0.6463
-0.6054
-0.6054
12
0.0000i
0.9880i
0.9880i
0.0000i
1.0501i
1.0501i
c.
clc
clear all
close all
P3=P2+P1
roots(P3)
Result:
P3 = 2
16
ans =
-7.4691
0.7215
0.7215
-1.1042
-0.4348
-0.4348
-6
-2
-3
-5
0.0000i
0.7809i
0.7809i
0.6504i
0.6504i
e.
clc
clear all
close all
P5=conv(P1,P2)
roots(P5)
Result:
P5 =1
300
16
73
92
182
291
433
599
523
609
560
465
ans =
-6.8731
-8.1330
0.7632
0.7632
0.6996
0.6996
-1.2183
-1.0000
-0.5240
-0.5240
-0.3266
-0.3266
+
+
+
+
+
+
+
+
-
0.0000i
0.0000i
1.0822i
1.0822i
0.9880i
0.9880i
0.0000i
0.0000i
1.0501i
1.0501i
1.0667i
1.0667i
Result:
P6 = -7
-8
-3
-5
-9 -10
ans =
1
42
718
6372
30817
76530
75600
3.
a. Represent the following as numerator divided by denominator
polynomial.
G ( S )=
b.
20(s+2)( s+3)(s+6)(s+ 8)
s (s +7)(s +9)( s+10)(s+15)
Result:
p1 =
20
380
2480
6480
5760
41
613
3975
9450
p2 =
G1 =
20 s^4 + 380 s^3 + 2480 s^2 + 6480 s + 5760
------------------------------------------s^5 + 41 s^4 + 613 s^3 + 3975 s^2 + 9450 s
Continuous-time transfer function.
b.
clc
clear all
close all
num=roots([1 17 99 223 140])
den=roots([1 32 363 2092 5052 4320])
G2=zpk(num,den,1)
Result:
num =
-7.0000
-5.0000
-4.0000
-1.0000
den =
-16.7851
-5.5591
-5.5591
-2.0483
-2.0483
+
+
+
-
0.0000i
5.1669i
5.1669i
0.5221i
0.5221i
G2 =
(s+7) (s+5) (s+4) (s+1)
-----------------------------------------------------(s+16.79) (s^2 + 4.097s + 4.468) (s^2 + 11.12s + 57.6)
Continuous-time zero/pole/gain model.
a.
s
s ( 2+8 s+15)
5( s+ 2)
G 6=
b.
s
s ( 2+6 s+9)
5( s+ 2)
G 7=
c.
s
s ( 2+6 s+34)
5( s +2)
G 8=
Answer4:
a.
clc
clear all
close all
num=[5 10]
den=[1 8 15 0]
[K,p,k]=residue(num,den)
Result:
num =
5
10
den =
1
K=
-1.5000
0.8333
0.6667
p=
-5
-3
0
15
k = []
b.
clc
clear all
close all
num=[5 10]
den=[1 6 9 0]
[K,p,k]=residue(num,den)
Result:
num =
5
10
den =
1
K =
-1.1111
1.6667
1.1111
p =
-3
-3
0
k = []
c.
clc
clear all
close all
num=[5 10]
den=[1 6 34 0]
[K,p,k]=residue(num,den)
Result:
num =
5
10
den =
1
34
K =
-0.1471 - 0.4118i
-0.1471 + 0.4118i
0.2941 + 0.0000i
p =
-3.0000 + 5.0000i
-3.0000 - 5.0000i
0.0000 + 0.0000i
k =[]
Objective 2: To use the symbolic math tool box in MATLAB to find Laplace
Transform and the inverse Laplace Transform Of the given function.
Software Required : MATLAB.
Questions and Answers:
1) Find the Laplace transform of
s
s( s+ 8)( 2+10 s+100)
2(s +3)(s +5)(s +7)
F 1 ( S )=
Answers:
1.
clc
clear all
close all
syms f t
f=0.0075-0.00034*exp(-2.5*t)*cos(22*t)+0.087*exp(-2.5*t)*sin(22*t)0.0072*exp(-8*t)
k=laplace(f)
pretty(k)
Result:
f =
(87*sin(22*t)*exp(-(5*t)/2))/1000 - (17*cos(22*t)*exp(-(5*t)/2))/50000 (9*exp(-8*t))/1250 + 3/400
k =
3/(400*s) - 9/(1250*(s + 8)) - (17*(s + 5/2))/(50000*((s + 5/2)^2 + 484)) +
957/(500*((s + 5/2)^2 + 484))
2.
clc
clear all
close all
syms s
p1=(2*((s+3)*(s+5)*(s+7)))
p2=(s*(s+8)*(s^2 +10*s+ 100))
g=p1/p2
f=ilaplace(g)
pretty(f)
Result:
p1 =
2*(s + 3)*(s + 5)*(s + 7)
p2 =
s*(s + 8)*(s^2 + 10*s + 100)
g =
(2*(s + 3)*(s + 5)*(s + 7))/(s*(s + 8)*(s^2 + 10*s + 100))
f =
(5*exp(-8*t))/112 + (237*exp(-5*t)*(cos(5*3^(1/2)*t) +
(3^(1/2)*sin(5*3^(1/2)*t))/9))/140 + 21/80