0% found this document useful (0 votes)
106 views21 pages

Familiarization With Digital Control System.: Experiment No 7

The document describes an experiment to familiarize with digital control systems using MATLAB. It involves converting transfer functions from continuous to discrete domains using different methods like zero-order hold, first-order hold, and Tustin's approximation. The procedures include writing MATLAB code to perform these conversions and obtaining the discrete transfer functions. Assignments are given involving these conversions on sample transfer functions. Key aspects like sampling, the role of the zero-order hold device, and pole zero mappings are also discussed.

Uploaded by

Mohammed Jaafer
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
106 views21 pages

Familiarization With Digital Control System.: Experiment No 7

The document describes an experiment to familiarize with digital control systems using MATLAB. It involves converting transfer functions from continuous to discrete domains using different methods like zero-order hold, first-order hold, and Tustin's approximation. The procedures include writing MATLAB code to perform these conversions and obtaining the discrete transfer functions. Assignments are given involving these conversions on sample transfer functions. Key aspects like sampling, the role of the zero-order hold device, and pole zero mappings are also discussed.

Uploaded by

Mohammed Jaafer
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 21

Experiment No 7.

Familiarization With Digital Control System.


Objective:
Using matlab M/File to represent familiarize in digital control system.
Convert from continuous domain to discrete domain by transfer function.
Convert from continuous domain to digital domain by transfer function.
Pole zero map (pzm) of discrete transfer function.
Introduction:
In the control systems, we have discussed so far, the signal at every point in the
system is a continuous function of time. In such control systems analog controllers
are used to produce continuous time varying control signals. The controller is the
portion of the system that does the controlling operation. The portion of the system
that is to be controlled is called the plant or the controlled system.In analog control
system the controller is made up of resistors, capacitors, operational amplifiers, etc.
A digital controller is in the form of programmed digital computer. Digital
controllers will have analog devices for interfacing with the plant or the control
system.
Procedure:
*Firstly we open matlab program and create new model.
*Then we start to write the matlab code as we want as shown below:
Case 1:
In order to convert from continuous to discrete domain by transfer function (sys) at
sampling time of Ts we write the code as shown below:

1
After we write the program in M/File and start (run) the program we get:

Case 2:
In order to convert a transfer function (sys) from continuous to discrete domain at
sampling time of Ts using zero order hold method as shown below:

2
After we write the program in M/File and start (run) the program we get:

Case 3:
In order to convert a transfer function (sys) from continuous to discrete domain at
sampling time of Ts we use FOH method as shown below:

After we write the program in M/File and start (run) the program we get:

3
Case 4:
In order to convert a transfer function (sys) from continuous to discrete domain at a
sampling time of Ts we using Tustin method as shown below:

After we write the program in M/File and start (run) the program we get:

4
Case 5:
Using pole zero map (pzmap) of a discrete transfer function as shown below:

After we write the program in M/File and start (run) the program we get:

5
If we write feedback code as shown below:

We get as shown below:

6
7
If we enter (pzmap) as shown below:

After we write the program in M/File and start (run) the program we get:

8
Assignments:

𝟏
1. G(s)=
𝒔𝟐 +𝒔+𝟒

a- ZOH method:

9
10
b- FOH method:

11
c- Tustin method:

12
𝟓
2- G(s)=
𝒔𝟐 +𝟗

a- ZOH method:

13
b- FOH method:

14
c- Tustin method:

15
𝟏
3- G(s)=(𝒔𝟐
+𝟑𝒔+𝟓)(𝒔+𝟑)(𝒔+𝟓)

a-ZOH method:

16
b-FOH method:

17
c- Tustin method:

18
Discussion:
1-why continuous signal is to be converted in discrete domain:
The c2d command discretizes continuous-time models. Conversely, d2c converts
discrete-time models to continuous time. Both commands support several
discretization and interpolation methods
2- what is the function of ZOH device:
The Zero-Order Hold (ZOH) method provides an exact match between the
continuous- and discrete-time systems in the time domain for staircase inputs.
The following block diagram illustrates the zero-order-hold discretization Hd(z) of a
continuous-time linear model H(s).

The ZOH block generates the continuous-time input signal u(t) by holding each
sample value u(k) constant over one sample period:
u(t)=u[k], kTs≤t≤(k+1)Ts
The ZOH discrete-to-continuous conversion has the following limitations:
• d2c cannot convert LTI models with poles at z = 0.
• For discrete-time LTI models having negative real poles, ZOH d2c conversion
produces a continuous system with higher order. The model order increases
because a negative real pole in the z domain maps to a pure imaginary value in
the s domain. Such mapping results in a continuous-time model with complex data.
To avoid this issue, the software instead introduces a conjugate pair of complex
poles in the s domain. See Convert Discrete-Time System to Continuous Time for
an example.
3-what is sampling:
In signal processing, sampling is the reduction of a continuous-time signal to
a discrete-time signal. A common example is the conversion of a sound wave (a
continuous signal) to a sequence of samples (a discrete-time signal).
A sample is a value or set of values at a point in time and/or space.

19
A sampler is a subsystem or operation that extracts samples from a continuous
signal.
A theoretical ideal sampler produces samples equivalent to the instantaneous value
of the continuous signal at the desired points.
Sampling is a process by which a continuous time system can be converted to
discrete domain. Discrete time signal x[n] often arises from periodic sampling of
continuous time signal xc(t):
x[n] = xc (nT) -∞<n<∞
This system is called continuous to discrete time converter or sampler

fs = 1/T
Ωs=2πfs rad/sec.
After sampling a continuous signal an impulse train will be obtained. That
impulses are difficult to generate and transmit. So it is more convenient to generate
sample signal in form of Zero order hold.
The transfer function of ZOH is
𝟏−𝒆−𝑻𝒔
G(s) zoh =
𝐬
𝟐
𝟏−𝒆−𝑻𝒔 𝑻𝒔+𝟏
G(s)foh=( ) ( )
𝒔 𝑻

After we sampling the signal we get to the:

And if we make ZOH we get to:

20
If the zeros in the right hands side the phase will be positive (not minimum phase).
If the zeros in left hand side the phase will be negative (minimum phase).

21

You might also like