Lab 03: Laplace Transforms & Transfer Functions in Control Systems with Matlab, Exams of Chemistry

Instructions on how to calculate laplace transforms and inverse laplace transforms using matlab in the context of control systems. It includes examples of finding laplace transforms of various functions, defining transfer functions, and using the inverse laplace transform to find time-domain responses. Students will learn how to use matlab to perform these calculations and understand the concepts behind them.

Typology: Exams

2014/2015

Uploaded on 10/15/2015

fahim_ullah_farhad
fahim_ullah_farhad 🇵🇰

1 document

1 / 3

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
Lab # 03
Control Systems
Objective:
The main objective of this lab is to make the students understand how we can
calculate the Laplace transform and inverse Laplace transform. While calculating the
inverse Laplace transform we often need to solve the partial fractions. Matlab has a
command to obtain the partial fraction expansion of a function in the form B(s)/A(s).
LAPLACE TRANSFORM
To find the Laplace transform of a function f(t) we know that:
=
0
)()]([ dtetftfL st
In Matlab we can use just one command laplace(f(t)) to calculate the Laplace
transform.
Example
>> syms t //define a symbolic object
>> y=t
y =
t
>> laplace(t)
ans =
1/s^2
Lab Task 1: Find the Laplace transform of the following functions.
1. g(t)= )sin( t
ω
2. g(t)=
)20sin( t
3. g(t)=
2
t
4. g(t)=
at
e
5.
t
tetg 5
5)(
=
6.
)2sin(2)( 2tetg t
=
DEFINING A TRANSFER FUNCTION
To define a transfer function in Matlab we can use the command tf to declare a
transfer function.
(Note: tf stands for transfer function)
>> syms s
>> A=[1 1 0] //where 1,1 and 0 are the coefficients of the denominator
A =
1 1 0
pf3

Partial preview of the text

Download Lab 03: Laplace Transforms & Transfer Functions in Control Systems with Matlab and more Exams Chemistry in PDF only on Docsity!

Lab # 03

Control Systems

Objective: The main objective of this lab is to make the students understand how we can calculate the Laplace transform and inverse Laplace transform. While calculating the inverse Laplace transform we often need to solve the partial fractions. Matlab has a command to obtain the partial fraction expansion of a function in the form B(s)/A(s).

LAPLACE TRANSFORM To find the Laplace transform of a function f(t) we know that:

0

L [ f ( t )] f ( t ) estdt

In Matlab we can use just one command laplace(f(t)) to calculate the Laplace transform. Example

syms t //define a symbolic object y=t y = t

laplace(t) ans =

1/s^

Lab Task 1: Find the Laplace transform of the following functions.

1. g(t)= sin( ω t )

  1. g(t)= sin( 20 t )
  2. g(t)= t^2
  3. g(t)= eat
  4. g ( t )= 5 te −^5 t
  5. g ( t )= 2 e −^2 t sin( 2 t )

DEFINING A TRANSFER FUNCTION To define a transfer function in Matlab we can use the command tf to declare a transfer function. (Note: tf stands for transfer function)

syms s A=[1 1 0] //where 1,1 and 0 are the coefficients of the denominator

A =

1 1 0

B=[2 1] //where 2 and 1 are the coefficients of the numerator

B =

2 1

G=tf(B,A)

Transfer function: B 2 s + 1 --- = ---------- A s^2 + s

Task 2: Define the following transfer functions in Matlab.

2 ( 1 )

s

s s As

Bs

3 2

5 4 3 2 s s s

s s s s s As

Bs

s s s s

s s As

Bs 12 44 48

4 3 2

2

INVERSE LAPLACE TRANSFORM

To find the inverse Laplace Transform of a function F(s) we can use the command ilaplace in Matlab.

Find the inverse laplace transform of the following functions.

  1. G(s)=(5s+3)/(s+1)(s+2)(s+3)
  2. G(s)=1/s(s+1)^3 (s+2)
  3. s s s s

s s As

Bs 12 44 48

4 3 2

2

ss s

s As

Bs

PARTIAL-FRACTION EXPANSIONS

MATLAB has a command to obtain the partial fraction expansion of B(s)/A(s) to obtain the poles and zeros of B(s)/A(s).

Consider the following functions B(s)/A(s)

n n n

n n n s as a

bs bs b As

B s

− ...

1 1

1 0 1

[R,P,K]=residue(B,A) finds the residues, poles and direct term of a partial fraction expansion of the ratio of two polynomials B(s)/A(s).

If there are no multiple roots,