You are on page 1of 8

De La Salle University

Electronics and Communications Engineering


LTI System Interconnection
Laboratory Experiment No. 3
I.

Objectives:
-

II.

To learn how to use different MATLAB functions in interconnecting LTI systems.


To be able to implement multiple system reduction.
To learn how to use SIMULINK 4.0 in building systems.

Primer:

Block diagrams are used to describe the component parts of systems. Each block in the system are
represented by a transfer function, which indicate a proportional relationship between two Laplacetransformed signals known as transmittance. The transmittance relates the incoming and outgoing signals
as indicate within each block of the system.
Cascaded Form
Blocks can be interconnected in many ways. If a number of blocks are connected in series, they
can be combined into a single block whose transfer function is the product of the individual transmittances.
The combination of these blocks is in cascaded form. Fig. 1 depicts the cascaded form structure with its
corresponding overall transfer function in (1).

Fig. 1. Cascaded system.

G (s ) = G1 (s )G2 (s )LG N (s )
N

G (s ) = Gk (s )

(1)

k =1

The transmittances of each element in the system can be modeled using transfer functions, statespace models, or zero-pole-gain models. In MATLAB, let each element be represented by LTI models
sys1, sys2, , sysn, the overall transfer function sys can be obtained by system multiplication or by
using the MATLAB function series.
>> sys = sys1 * sys2 * * sysn
or
>> sys = series(sys1,sys2)
Take note that the series function can only be used with two transmittances.
As an example, consider two transfer functions (2) and (3).

Feedlab

Laboratory Experiment No. 3. Rev. 1.1 (05/2004)

2s + 1
s + 10 s 2 2 s + 1
s2
G2 (s ) =
(s + 3)(s 3)

G1 (s ) =

(2)
(3)

To get the system transfer function, we have


>> sys1 = tf([2 1],[1 10 2 1]);
>> sys2 = zpk([2],[-3 3],[1]);
>> sys = series(sys1,sys2)
Zero/pole/gain:
(s-2)
----------(s+3) (s-3)
>>
Parallel Form
If two blocks are connected in parallel, they can be combined into a single block whose transfer
function is the sum of the individual transmittances. The combination of these blocks is in parallel form.
Fig. 2 depicts the parallel form structure with its corresponding overall transfer function in (4).

Fig. 2. Parallel connection of two transmittances.

G (s ) = G1 (s ) + G2 (s ) + LGN (s )
N

G (s ) = G k (s )

(4)

k =1

In MATLAB, let each element be represented by LTI models sys1, sys2, , sysn, the overall
transfer function sys can be obtained by system addition or by using the MATLAB function parallel.

Feedlab

Laboratory Experiment No. 3. Rev. 1.1 (05/2004)

>> sys = sys1 + sys2 + + sysn


or
>> sys = parallel(sys1,sys2)
Take note that the parallel function can only be used with two transmittances.
As an example, consider again the two transfer functions (2) and (3). To get the system transfer
function, we have
>> sys1 = tf([2 1],[1 10 2 1]);
>> sys2 = zpk([2],[-3 3],[1]);
>> sys = parallel(sys1,sys2)
Zero/pole/gain:
(s+11.71) (s-2.323) (s^2 + 0.6175s + 0.4044)
----------------------------------------------(s+10.21) (s+3) (s-3) (s^2 - 0.2056s + 0.09799)
>>
Feedback Form
If two blocks are connected in such a way that the system output is fed back to the input via the
other transmittance, the combination of these blocks is in feedback form. Fig. 3 depicts the feedback form
structure with its corresponding overall transfer function in (5).

G1 (s )
m

G 2 (s )
Fig. 3. Two transmittances in feedback connection.

G (s ) =

G1 (s )
1 G1 (s )G2 (s )

(5)

To reduce this system into a single transfer function, we can use the MATLAB function
feedback, which is the successor of the obsolete command cloop.
>> sys = feedback(sys1,sys2,+1) to apply positive feedback
or
>> sys = feedback(sys1,sys2,-1) to apply negative feedback.

Feedlab

Laboratory Experiment No. 3. Rev. 1.1 (05/2004)

Considering (2) as the plant, and (3) as the feedback element, applying negative feedback to the
system, we have
>> sys1 = tf([2 1],[1 10 2 1]);
>> sys2 = zpk([2],[-3 3],[1]);
>> sys = feedback(sys1,sys2,-1)
Zero/pole/gain:
2 (s-3) (s+3) (s+0.5)
---------------------------------------------------(s+10.23) (s+2.94) (s-2.99) (s^2 - 0.1795s + 0.1223)
>>
Block Diagram Reduction
System reduction in a very complicated system using series, parallel, and feedback
functions could be tedious. Instead, we use the blkbuild and connect command. This can be done by
first numbering the transfer function blocks sequentially from one to the number of blocks. nblock
defines the total number of blocks and bldblocks converts each block to an unconnected state-space
representation. The statement [A,B,C,D]=connect(a,b,c,d,q,iu,iy) connects up the blocks
according to a predefined matrix q that specifies the interconnections. The first element of each row of the
q matrix is the block number. The remaining elements indicate the source of the blocks summing input.
When the input to the summing junction is negative, the block number is entered with a negative sign. The
iu and iy are two row vectors indicating retaining input and output blocks. Finally, to obtain the overall
transfer function, use the MATLAB function ss2tf.

Fig. 4. Example block diagram.


The following is the procedure to simplify the system shown in Fig. 4 into its equivalent transfer function.
Step 1.
Number each blocks sequentially from 1 to the number of blocks similar to Fig. 4.
Step 2.
Enter the numerator and denominator polynomials of each block. Take note that the numerator and
denominator of ith block is defined by ni and di, respectively. For the block diagram shown above, the
numerator and denominator polynomials are as follows:

Feedlab

Laboratory Experiment No. 3. Rev. 1.1 (05/2004)

>>
>>
>>
>>
>>
>>
>>
>>

n1=1; d1=1;
n2=0.5; d2=1;
n3=4; d3=[1 4];
n4=1; d4=[1 2];
n5=1; d5=[1 3];
n6=2; d6=1;
n7=5; d7=1;
n8=1; d8=1;

Note: The order of the numerator polynomial must be less than the denominator polynomial otherwise an
error will occur in the script file blkbuild.
Step 3.
Specify the total number of blocks. Use the variable nblocks. Type the script file blkbuild to
build a block diagonal state space structure from a block diagram of transfer functions.
>> nblocks = 8;
>> blkbuild;
Step 4.
Write a matrix that indicates the block diagram configurations. For Fig. 4, the matrix can be
written as follows:
>>
>>
>>
>>
>>
>>
>>
>>

q
2
3
4
5
6
7
8

q =

=
1
2
3
4
3
4
5

[1 0 0 0 0
6 7 8
0 0 0
0 0 0
0 0 0
0 0 0
0 0 0
0 0 0]

1
2
3
4
5
6
7
8

0
1
2
3
4
3
4
5

0
-6
0
0
0
0
0
0

0
-7
0
0
0
0
0
0

0
-8
0
0
0
0
0
0

>>
Step 5.
Specify the input and output for the connected system. For Fig. 4, the input is connected to the
first block and the output is connected to the 5th block.
>> iu = [1];
>> iy = [5];
Step 6.
Type the following statement:
>> [A,B,C,D]=connect(a,b,c,d,q,iu,iy);

Feedlab

Laboratory Experiment No. 3. Rev. 1.1 (05/2004)

Step 7.
Create a state-space object.
>> sys = ss(A,B,C,D);
Step 8.
Use the MATLAB function TF to convert the state-space representation to its transfer function.
>> sys = tf(sys)
Transfer function:
2
-----------------------s^3 + 13 s^2 + 56 s + 80
>>
Building Systems Using SIMULINK 4.0
SIMULINK is a MATLAB tool that provides a simple and easy-to-learn means of constructing
systems from building blocks, driving them with a variety of inputs, and observing the result. It is primarily
a tool for simulating systems. It is particularly useful for studying the effects of nonlinearities on the
behavior of systems.
To start SIMULINK, it is necessary to start MATLAB. Once MATLAB is running, simply enter
the command simulink and wait. Shortly, a box with icons, pull-down menu heads, and the word
Simulink Library Browser in its header bar will appear on the screen, as shown in Fig. 5

Fig. 5. Simulink library browser.

Feedlab

Laboratory Experiment No. 3. Rev. 1.1 (05/2004)

We now construct a system in this window. Go back to SIMULINK window click


FILE>NEW>MODEL. This will create another window named untitled. On the SIMULINK window,
double-click the Continuous icon and drag the Transfer Fcn icon into the untitled window. Then chose
the Math icon and drag the Gain icon into the untitled window. Repeat the process by placing the
Integrator icon located in the Continuous menu. From Sources menu, drag the Step icon to the untitled
window. From the Sink menu, drage the Scope icon to the untitled window. Continue searching for some
icons until Fig. 6 is obtained. To change component properties just double click the element.

Fig. 6. The untitled window.


III.

Laboratory Exercises:
1.

Determine the total transfer function of the following systems connected in series:

G1 (s ) =

G2 (s ) =

2s + 5
s 5s + 7
2

G 3 (s ) =

s2
(s 2)(s + j5)(s j5)

2.

Using the given data on the previous question, determine the total transfer function if they are
all connected in parallel.

3.

Considering Fig. 7 and using the given data and previous data. Determine the total transfer
function.

G4 (s ) =

Feedlab

2
s+3

2s + 1
s2 + 3

G 5 (s ) =

s4
2
s 2s + 2

s 1
G6 (s ) = 1
2 s + 3s 2 + s 3

4.

Determine the step response of the reduced transfer function using step(sys).

5.

Plot the step response of the overall system by incorporating Fig. 7 individually into
SIMULINK. Save the file. Make an analysis report of its step response.

Laboratory Experiment No. 3. Rev. 1.1 (05/2004)

Fig. 7. An example of a complicated block diagram.

Feedlab

Laboratory Experiment No. 3. Rev. 1.1 (05/2004)

You might also like