Вы находитесь на странице: 1из 31

Control System Design

Introduction to the laboratory sessions


Ir J. Verspecht
Control Engineering and System Analysis Department
Faculty of Applied Science
Universite Libre de Bruxelles (U.L.B.)
Brussels, Belgium
corresponding author email: jonathan.verspecht@ulb.ac.be
september 2012

ii

Contents
1 Getting Started
1.1 What to do Before Turning On the Plant . . . .
1.2 The Plant Interface Panel . . . . . . . . . . . . .
1.3 The Data AcQuisition Interface (DAQ Interface)
1.4 The Matlab Code . . . . . . . . . . . . . . . . . .

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

3
3
3
4
4

2 The Ball and Beam


2.1 Plant description . . . . . . . . . . . . . . . .
2.1.1 Intrumentation . . . . . . . . . . . . .
2.2 Specications . . . . . . . . . . . . . . . . . .
2.2.1 Basic requirements . . . . . . . . . . .
2.2.2 More advanced requirements . . . . .
2.3 Documentation . . . . . . . . . . . . . . . . .
2.3.1 Infra-red distance sensor . . . . . . . .
2.3.2 Current - velocity static characteristic

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

7
7
7
7
7
7
8
8
8

3 The Ball in the tube


3.1 Plant description . . . . . . . . . . . . . . . . . . . .
3.1.1 Intrumentation . . . . . . . . . . . . . . . . .
3.2 Specications . . . . . . . . . . . . . . . . . . . . . .
3.2.1 Basic requirements . . . . . . . . . . . . . . .
3.2.2 More advanced requirements . . . . . . . . .
3.3 Documentation . . . . . . . . . . . . . . . . . . . . .
3.3.1 Velocity sensor: Maxon motor DCT 22 tacho
3.3.2 Infra-red distance sensor . . . . . . . . . . . .
3.3.3 Current - velocity static characteristic . . . .

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

11
11
11
11
11
11
11
11
12
12

4 The Elevator
4.1 Plant description . . . . . . . . . . . . . . . . . . . . . . . . .
4.1.1 Intrumentation . . . . . . . . . . . . . . . . . . . . . .
4.2 Specications . . . . . . . . . . . . . . . . . . . . . . . . . . .
4.2.1 Basic requirements . . . . . . . . . . . . . . . . . . . .
4.2.2 More advanced requirements . . . . . . . . . . . . . .
4.3 Documentation . . . . . . . . . . . . . . . . . . . . . . . . . .
4.3.1 Position sensor . . . . . . . . . . . . . . . . . . . . . .
4.3.2 Voltage - current static characteristic of the DC motor

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.

15
15
15
15
15
15
15
15
16

5 The Heat Exchanger


5.1 Plant description . . . . .
5.1.1 Intrumentation . .
5.2 Specications . . . . . . .
5.2.1 Basic requirements

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

17
17
17
17
17

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.

.
.
.
.
.
.
.
.

.
.
.
.

.
.
.
.

iii

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

iv

CONTENTS

5.3

5.2.2 More advanced requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .


Documentation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
5.3.1 Heating - air temperature static characteristic (without recycling) . . . . . . . . . . . . . . . .

6 The Fluid Mixer


6.1 Plant description . . . . . . . . . . . . . .
6.1.1 Intrumentation . . . . . . . . . . .
6.2 Specications . . . . . . . . . . . . . . . .
6.2.1 Basic requirements . . . . . . . . .
6.2.2 More advanced requirements . . .
6.3 Documentation . . . . . . . . . . . . . . .
6.3.1 Opening - ow static characteristic

17
17
17

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

19
19
19
19
19
19
19
19

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

21
21
21
21
21
21
21
21

. . . . . . .
. . . . . . .
. . . . . . .
. . . . . . .
. . . . . . .
. . . . . . .
DC motor

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

23
23
23
23
23
23
23
23

9 System modeling and identification for dummies


9.1 Refresher . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
9.1.1 Response of linear time-invariant systems . . . . . . . . . . .
9.2 System modeling . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
9.2.1 Modeling of linear time-invariant systems . . . . . . . . . . .
9.3 Identication procedure . . . . . . . . . . . . . . . . . . . . . . . . .
9.3.1 Parameter estimation: the least-squares method . . . . . . .
9.4 Example of identication using Matlab: program getdataexample
9.5 Deal with a real plant . . . . . . . . . . . . . . . . . . . . . . . . . .
9.5.1 Properties of the plant . . . . . . . . . . . . . . . . . . . . . .
9.5.2 Identication experiment . . . . . . . . . . . . . . . . . . . .
9.5.3 Validation of the model . . . . . . . . . . . . . . . . . . . . .

.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.

25
25
25
26
26
26
26
26
27
27
27
27

7 The Home Temperature simulator


7.1 Plant description . . . . . . . . . . . . .
7.1.1 Intrumentation . . . . . . . . . .
7.2 Specications . . . . . . . . . . . . . . .
7.2.1 Basic requirements . . . . . . . .
7.2.2 More advanced requirements . .
7.3 Documentation . . . . . . . . . . . . . .
7.3.1 Heating - wall temperature static

. . . . . . . .
. . . . . . . .
. . . . . . . .
. . . . . . . .
. . . . . . . .
. . . . . . . .
of the valves

. . . . . . . .
. . . . . . . .
. . . . . . . .
. . . . . . . .
. . . . . . . .
. . . . . . . .
characteristic

8 The DC motor position control


8.1 Plant description . . . . . . . . . . . . . . . . .
8.1.1 Intrumentation . . . . . . . . . . . . . .
8.2 Specications . . . . . . . . . . . . . . . . . . .
8.2.1 Basic requirements . . . . . . . . . . . .
8.2.2 More advanced requirements . . . . . .
8.3 Documentation . . . . . . . . . . . . . . . . . .
8.3.1 Voltage - velocity static characteristic of

. .
. .
. .
. .
. .
. .
the

.
.
.
.
.
.
.

General Organization of the laboratory


sessions
The Control System Design laboratories is a project where students will have some control objectives to achieve on a
real plant. During the laboratoires sessions, students will be treated as professionnal. Nobody will tell the students
the right solution exactly like it would happen in a company. Students will be resposible to nd the most appropriate
techniques to face the challenges and convice the jury the validity of the proposed solution. The professor and teaching
assistant will be available to give hints, to discuss proposed solutions, issues, unexpected behaviors but will NEVER
tell you what to do.

Before the laboratory sessions


Before the laboratory sessions, students will be grouped in teams (composed of 2 to 4 people). Each team will be
assigned to one pilot plant to control and have at least to reach the basic specications explain within the corresponding
chapter of the actual document. The group composition and the pilot plant assignement will be decided by the teaching
assistant (Proposed schedule : begin October).
Students have to keep in mind their objectives for the laboratory sessions during the lectures.

During the laboratory sessions


The goal of the project is to make the design choices, parameters tuning, simulative and experimental tests so as to
develop control schemes able to perform as well as possible with respect to the required specications.
During the laboratory sessions, students will have acces to at least one xed computer equiped with a data
acquisition system, Matlab and Simulink program (with Data acquisition toolbox, control system toolbox and symbolic
math toolbox).

Organization of the evaluation


The last week of course will be devoted to the evaluations. Each team will write a report containing a description with
the nal results and a discussion on the design choices done. A 20 minutes presentation will be done using a projector.
These presentations will take place in front of all the students composing the laboratory session. The presentation will
be followed by a question time. During the question time students are invited to ask questions to the other teams.

Assessment criteria
The nal mark received for the project will be inuenced by the following criterias:
Capability to reach the control objectives
Performance and quality of the porposed solutions
Possible comparison between alternative solutions
1

CONTENTS
Capability to motivate and defend your design choices
Capability to face unexpected problem dur the real nature of the system and to formulate hypothesis able to
explain anomalous behaviors
Quality of the oral presentation
Quality of the written report
Quality of the proposed question to other groups
Capability to asnswer questions
Involvement in the project (evaluation done by the teaching assistant during the laboratory sessions)
The nal project mark is a personal evaluation and may vary depending on the individual performances.

Chapter 1

Getting Started
1.1

What to do Before Turning On the Plant

Before doing anything else, it is important to carefully analyze the system to be controlled and the related required
specications. In particular it is very important to:
1. have clear which are the sensors and actuators available
2. have clear the specications of the control (basic objectives, more advanced ones, other possible optional objectives it can make sense to dene)
3. to have an intuition of how the system works
Part of the above information can be found in the plants description chapters.
Before starting doing anything it is in general a good idea to plan an overall strategy it can be convenient to follow
for the rest of the day. Very probably this strategy will be partially changed as things go on, but it is a good practice
to avoid trying things with no plans and no clear ideas in mind. The above steps may seem obvious, but most of
the time people fail to reach objectives since they have not a clear plan of what to do. Clearly the main tasks are the
identication of the system and its control. In line of principle it is possible to perform these tasks in many dierent
ways and sequences. The two extreme strategies are:
to identify the entire model and then to focus on the control
to identify a part of the model, to control the subpart and, one after the others, to identify the model pertaining
to the various external loops.
Depending on the plant and on the goals, it is possible to choose one strategy or the other, or to do something
intermediate. This point is a design decision that is up to the students.
Another thing should be said on the identication phase is that one can use both a black-box approach (without
assuming any knowledge of the physics of the system) or a white/gray-box approach where considerations on the
physics of the system are done and used in a way more or less extensive. Whatever is the choice of your modeling
is a good rule to predict which should be the system dynamics on the basis of the physics of the system. To have
a good physical explanation of your ndings helps to validate the correctness of your results and to explain possible
nonstandard behaviors.

1.2

The Plant Interface Panel

All the plants have a plant input/output interface panel composed of a set of female connectors. The formalisms used
for all the electronical equipment in the lab is the following:
Red female Connector : signal that comes out of the connector
3

CHAPTER 1. GETTING STARTED


Yellow female Connector: signal that goes into the connector

As a consequence in the plant interface panel:


Red Connectors identify the signals from the sensors
Yellow Connector identify the signals to the actuators
For some of the plants, a set of green female plugs are placed as internal electrical connection to another green interface
closer to the DAQ interface (can be used to avoid the use of long cables or of complicate connections).

1.3

The Data AcQuisition Interface (DAQ Interface)

In this course, all data acquisition and control functions can be done through Matlab. Clearly this is a simplication
of what may happens in more general digital control contexts where micro-controller programmed in C or in some
assembly code could be used. The interface between the analog world represented by the Plant Interface Panel and
the computer will be the data acquisition/control board. The DAQ board used in the lab is composed of eight
Analog-to-Digital and two Digital-to-Analog converters ables to :
measure voltages from 8 analog input channels
set a voltage command on 2 analog output channels
Following the previous formalism we will have that:
The yellow female plug from 1-8 are the analog input channels
The red female plug from 1-2 are the analog output channels
Note that, the sensors of the plant panel interface (signal coming OUT OF the plant, red plug) have to be connected
with the input of the acquisition board (signal going INTO the acquisition board, yellow plug), while the actuators
(signal going INTO the plant, yellow plug) have to be connected with the output of the acquisition board (signal
coming OUT OF the acquisition boards, red plug).

1.4

The Matlab Code

After the right connections have been performed it is possible to nally start with the data acquisition and the real
time control doing in Matlab. An example code to do this is provided to the students in the RealTimeLoop.m whose
main parts will be hereafter described.
RealTimeLoop.m
%***********************************************************************************************%
%
This part corresponds to the initialization of the experiment
%***********************************************************************************************%
openinout
% The openinout command initializes the DAQ Analogic Inputs (8) and Outputs (2). Always remember to open
% it otherwise it will not communicate with the Acquisition Board
Tcycle=0.01;
% This is the Sampling Time (s) you can choose. The minimum sampling time compatible with the acquisition
% board is 10 ms
N0=4*3600/Tcycle;
Data = zeros(8,N0);
DataCommands = zeros(2,N0);
% This part of code initializes 2 huge matrices (up to 4 h) to store the sensors signals (in Data)

1.4. THE MATLAB CODE

% and the actuator signals (in DataCommands)


cond=1;
% this is the initialization of the condition to remain in the loop. Whenever cond is set to zero we will exit from
% the loop
i=0; % counter initialization
%***********************************************************************************************%
%
This part corresponds to the real timed loop
%***********************************************************************************************%
while cond==1, % Untill cond==1
tic; %Tic, initialize the time clock
[in1,in2,in3,in4,in5,in6,in7,in8]=anain;
% anain is the function to read the Measurements. It will give in output the 8 voltage value
% PLACE YOUR CONTROL LAW HERE. It is a good engineering practice to make it as fast as possible
% The controller will compute the value of out1 and out2 in the basis of the measurments
% for instance
out1= 3*in1;
out2= 0;
anaout(out1,out2);
% anaout is the function that applies the desired voltage on the card output channels
%***********************************************************************************************%
%
Save in real time
%***********************************************************************************************%
% Saving in real time without memory constraints ll a previously initalized vector/matrix.
% The following part of code is meant to save all the sensor measurements and the commands respectively
% in the Data and DataCommands matrices.
% Please note that this is very important to save datas in order to analyze and plot your results later on
i = i+1;
Data(:,i)=[in1,in2,in3,in4,in5,in6,in7,in8];
DataCommands(:,i)=[out1,out2];
%***********************************************************************************************%
%
End of Experiment?
%***********************************************************************************************%
% This part of code contains end experiment conditions that set cond to zero.
% In this particular code the experiment ends when a voltage bigger then 1 is placed in the 5th input channel
% Other stop conditions can be implemented if wished.
if abs(in5)>1
cond=0;
end
%***********************************************************************************************%
%
Realization of a timed loop
%***********************************************************************************************%
% This last part of the cycle contains the instructions to guarantee the correct sampling time

CHAPTER 1. GETTING STARTED

t=toc; % it measure how much time passed from the beginning of the cycle.
if t>Tcycle
disp (Sampling time to small);
% in the case computation time is higher than the sampling time, launch a warning
% Adapt your sampling time or improve your programming if this warning repeats themself
else
while toc Tcycle end % wait untill next sampling time
end
% DON T PUT ANY CODE HERE
end
%***********************************************************************************************%
%
Conclude the experiment
%***********************************************************************************************%
closeinout % At the end of the cycle close the DAQ Inputs and Outputs
% to close the communication with the board is VERY IMPORTANT to avoid strange behaviours
% Process the acquired data
Data(:,i+1:end) = []; % Discard unused memory
DataCommands(:,i+1:end) = []; % Discard unused memory
tps = 0:Tcycle:(i-1)*Tcycle; % Create the time scale
. . . % THE REST IS UP TO YOU

Chapter 2

The Ball and Beam


2.1

Plant description

A small ball is placed upon a longitudinal gutter that constrains the displacements of the ball along its direction. The
purpose is to control the position of the ball along the beam by adjusting its angle. The beam is attached at one end
to a roller support, and at the other end to a slider that can move vertically along a linear guide by means of a ball
screw drive. The shaft of the ball screw is actuated by a current-driven DC motor. The objective of this plant is to
stabilize the ball at an arbitrary position of the beam.

2.1.1

Intrumentation

Sensors:
The velocity of the DC motor is measured by a tachometer generator.
The horizontal angle of the beam is measured by a potentiometer.
The position of the ball along the beam is measured by an infra-red distance sensor.
Actuator: The slider is moved by a voltage/current ? DC motor.

2.2
2.2.1

Specifications
Basic requirements

Stabilize the ball at any available position with no steady state error.
Reject external disturbances with minimum oscillations.

2.2.2

More advanced requirements

Switch between to dierent set points with maximum 1cm overshoot.


Switch between to dierent set points with maximum 0.5cm overshoot in maximum 1s.

2.3
2.3.1

CHAPTER 2. THE BALL AND BEAM

Documentation
Infra-red distance sensor

Figure 2.1: Ball and Beam: Infra-red distance sensor

2.3.2

Current - velocity static characteristic

2.3. DOCUMENTATION

Figure 2.2: Ball and Beam: Current - velocity static characteristic

10

CHAPTER 2. THE BALL AND BEAM

Chapter 3

The Ball in the tube


3.1

Plant description

A light ball is placed within a tube constrainning its displasment. A fan generates a air ux capable of lifting the ball.
The objective is to control the vertical position of the ball.

3.1.1

Intrumentation

Sensors:
The velocity of the fan is measured by a dedicated velocity sensor.
The position of the ball is meassured by means of an InfraRed distance sensor
Actuator: The fan is actuated by the current driven DC motor.

3.2
3.2.1

Specifications
Basic requirements

Stabilize the ball at any available position with no steady state error.

3.2.2

More advanced requirements

Switch between to dierent set points with maximum 1cm overshoot.


Switch between to dierent set points with maximum 1cm overshoot in maximum 2s.

3.3
3.3.1

Documentation
Velocity sensor: Maxon motor DCT 22 tacho

linearity between 500 and 5000 min1 : 0.2%


Output voltage per 1000 min1 : 0.52V

11

12

3.3.2

CHAPTER 3. THE BALL IN THE TUBE

Infra-red distance sensor

Figure 3.1: Ball in the tube: Infra-red distance sensor

3.3.3

Current - velocity static characteristic

3.3. DOCUMENTATION

Figure 3.2: Ball in the tube plant: Current - velocity static characteristic

13

14

CHAPTER 3. THE BALL IN THE TUBE

Chapter 4

The Elevator
4.1

Plant description

A lift is placed between two vertcical guides. This lift is connected through a cable to a DC motor shaft. The objective
is to switch between the three available oorlevel of an elevator.

4.1.1

Intrumentation

Sensors:
position sensor: 1 global sensor for the lift and local sensors at each oor
1 velocity sensor for the motor
1 current sensor for the motor
Actuator: The system is actuated by the voltage driven DC motor
The load considered as a distubance in the lift may be changed.

4.2
4.2.1

Specifications
Basic requirements

Move to any oor with no overshoot and zero steady state error.

4.2.2

More advanced requirements

Limit the acceleration of the lift


Generate the faster solution with limited acceleration.

4.3
4.3.1

Documentation
Position sensor

The sensor is calibrated in such a way than one level correspond to 3V .


ground level: 150mV
rst oor: 3.1V
second oor: 6.05V
15

16

CHAPTER 4. THE ELEVATOR


third oor: 9V

Beware that mecanical security activates when you go to low or to high. So all the test have to be realized between
the rst and the third oor ( [3.1, 9]V ).

4.3.2

Voltage - current static characteristic of the DC motor

Figure 4.1: Elevator: Current - velocity static characteristic

Chapter 5

The Heat Exchanger


5.1

Plant description

The heat exchanger is composed of two circuits. The rst one is an air circuit with possibility to partially recycled
air. This circuit includes a heating section. The second circuit is a water circuit. Both circuit are interconnected by
a heat exchanger between the air and the water. The objective is to deliver water at a given temperature.

5.1.1

Intrumentation

Sensors:
4 Water temperature sensors: 1 at the entry, 1 after 33% and 1 after 66% of the exchanger and 1 at the exit.
4 Air temperature sensors: 1 at the entry and 1 at the exit of the heating section an 1 at the entry and the exit
of the exchanger
Actuator: A warming resistor is installed on the air circuit.
One may manually allow partial or full recycling of the air and variation of the water ow.

5.2
5.2.1

Specifications
Basic requirements

Considering the delivery water ow constant and no air recycling, warm the water ow at a given temperature with
zero steady state error and no overshoot.

5.2.2

More advanced requirements

Follow a water temperature trajectory (Simulating a given temperature prole for a chemical reaction)

5.3
5.3.1

Documentation
Heating - air temperature static characteristic (without recycling)

17

18

CHAPTER 5. THE HEAT EXCHANGER

Figure 5.1: Heat exchanger: Voltage - Ait temperature static characteristic

Chapter 6

The Fluid Mixer


6.1

Plant description

The plant is composed of two pressurized tank containing two substances to mix. In this case both substances are
water where one is colored. The two tank are connceted to a mixing tank. The mixture is used by client. The objective
is to control the level and the concentration (of colorant) of water in this mixture delivered to the client.

6.1.1

Intrumentation

Sensors:
1 level sensor
3 ow sensors: 1 for the water, 1 for the colorant and 1 for the delivery ow
1 delivery ow concentration sensor
Actuator: The system is actuated by 3 valves: 1 for the water, 1 for the colorant and 1 for the ow at the exit of
the cylinder.
The valve at the exit of the cylinder is manually xed by the operator, the corresponding ow is considered as a
measurable disturbance.

6.2
6.2.1

Specifications
Basic requirements

Reach any concentration with zero steady state error for a constant delivery ow. Stabilize the level to an arbitrary
value with an error always lower than 1cm.

6.2.2

More advanced requirements

Deal with a varying delivery ow.

6.3
6.3.1

Documentation
Opening - flow static characteristic of the valves

19

20

CHAPTER 6. THE FLUID MIXER

Figure 6.1: Fluid mixer: Opening - ow static characteristic

Chapter 7

The Home Temperature simulator


7.1

Plant description

The house-temperature simulator is composed of a copper tube representinf the house wall connected to a heating
ring replacing the house heating system. The objective is to stabilize the air temperature inside a cylinder to any
admissible temperature and reject the disturbances.

7.1.1

Intrumentation

Sensors:
1 air temperature sensor
1 temperature sensor of the wall
Actuator: The system is actuated by a warming ring and a fan.

7.2
7.2.1

Specifications
Basic requirements

Considering the fan as a disturbance, reach any higher temperature without overshoot and steady state error and in
the faster possible way.

7.2.2

More advanced requirements

Using the fan as a controllable input, reach any temperature (higher or lower) without overshoot and steady state
error and in the faster possible way.
Switch between to dierent set points with maximum 1cm overshoot.
Switch between to dierent set points with maximum 1cm overshoot in maximum 2s.

7.3
7.3.1

Documentation
Heating - wall temperature static characteristic

21

22

CHAPTER 7. THE HOME TEMPERATURE SIMULATOR

Figure 7.1: Home Temperature simulator: Heating - wall temperature static characteristic

Chapter 8

The DC motor position control


8.1

Plant description

This plant is composed of two DC motor and one break acting on the same shaft. The objective is to track any
position trajectory.

8.1.1

Intrumentation

Sensors:
1 velocity sensor
2 position sensors
Actuator: The DC motors are voltage driven.

8.2
8.2.1

Specifications
Basic requirements

Considering only one motor, the objective is to reach any given constant position without overshoot or steady state
error. The faster the response is the better. Perform position changes with and without activating the brakes.

8.2.2

More advanced requirements

Track a sinusoidal reference with no steady state error.


Synchronize the two motors to increase the power.

8.3
8.3.1

Documentation
Voltage - velocity static characteristic of the DC motor

23

24

CHAPTER 8. THE DC MOTOR POSITION CONTROL

Figure 8.1: DC motor: Voltage - velocity static characteristic

Chapter 9

System modeling and identification for


dummies
Introduction
Given a certain system 1 , modeling somehow attempt to characterize the link between the inputs and the outputs.
The aim of modeling and identication is to nd a link one may use in order to predict the output of a system by
knowing only the inputs. This model can be used for simulation, model based controller design, ...
The present document addressed an introduction to modeling and identication. It will present only one structure
of model namely the ARX model and only one method for the identication of the parameter of such a model.

9.1
9.1.1

Refresher
Response of linear time-invariant systems

Consider the system with a scalar input u(t) and the scalar output y(t). The system is linear time-invariant if:
linearity property if for a linear combination of inputs the output response is the same linear combination of the
output responses of the individual inputs
time-invariant property if the response of a system to a certain signal do not depend on absolute time
Finally a a system is said to be causal if the output at a certain time only depends ont the inputs up to that time.
Under all this conditions the response of the system can be described by:

y(t) =
g( )u(t )d
(9.1)
0

where g( ) is known as the impulse response. Consequently the impulse response of a linear time-invariant causal
system completely dened its input/output response.
Taking the Laplace transforms Y (s) = L(y(t)), U (s) = L(u(t)) and G(s) = L(g(t)), one obtains:
Y (s) = G(s)U (s)

(9.2)

G(s) is also refered as the transfer function of the linear system (9.1).
1 Not formally, a system is an object aected by external stimuli in which variables of dierent kinds interact and produce observable
signals. The observable signals of interest are called outputs, while the stimuli are divided in two part: the inputs (possibly manipulated)
and the disturbances

25

26

CHAPTER 9. SYSTEM MODELING AND IDENTIFICATION FOR DUMMIES

9.2
9.2.1

System modeling
Modeling of linear time-invariant systems

A common way of parameterizing G is to represent it as a rational function. A simple input-output relationship is


obtained through an Ordinary Dierential Equation (ODE):
a0 y(t) + a1

dy
d2 y
dna y
du
d2 u
dnb u
(t) + a2 2 (t) + + ana na = b0 u(t) + b1
+ b2 2 + + bnb n
dt
dt
dt
dt
dt
dt b

(9.3)

The parameters are in this case:


= [a0 , a1 , . . . , ana , b0 , . . . , bnb ]
The corresponding transfert function is:

(9.4)

nb
bi si
G = ni=0
a
i
i=0 ai s

(9.5)

y(t, ) = L1 (G (s)U (s))

(9.6)

One way to predict the output y(t) is:

9.3
9.3.1

Identification procedure
Parameter estimation: the least-squares method

Considering the sampled signals u(k) (the input) and y(k) (the output) (k = 1,2,. . . ,N, the sampling instant) and
using the prediction (9.6), the prediction error is dened by:
(k, ) = y(k) y(k, )

(9.7)
LS

Using as cost function a quadratic function of the prediction error (9.8), the optimal parameters
square sense is dened by (9.9).
J LS () =

2 (k, )

in the least

(9.8)

k=1

LS = argmin(J LS ())

9.4

(9.9)

Example of identification using Matlab: program getdataexample

Lets consider the continuous-time system dened by its transfer function sys.
sys(s) =

Y (s)
1
=
U (s)
s+1

(9.10)

The step response of such a system for t 0 is (9.11) when the system is at rest for t < 0 (y(0 ) = 0)
y(t) = 1 et

(9.11)

If the signals are sampled at 2Hz here is the data:


y(k) = [0, 0.3935, 0.6321, 0.7769, 0.8647, 0.9179, 0.9502, 0.9698, 0.9817, 0.9889, 0.9933, 0.9959, 0.9975]
u(k) = [1, . . . , 1]

(9.12)

These datas are generated by the lsim matlab function for every example system sys. The parameters of a selected
transfert function structure are identied by the home made IdentifySystem function. This function is based on the
procedure described before.

9.5. DEAL WITH A REAL PLANT

9.5

27

Deal with a real plant

Here is a common methodology for the identication of linear time-invariant model (LTI model):
1. Verify the properties of the plant.
2. Make one experiment to characterize the plant (at least)
3. Validate the result of the identication

9.5.1

Properties of the plant

The rst step in order to identify a LTI model is to verify that the plant is indeed linear and time-invariant.
Linearity
It may be sometimes quite complicate to arm that a plant is linear. The nonlinearities of a real plant can roughly
be split in two categories: a static gain dependent of the input or a time response dependent of the input. To check
the dependency of the static gain, one way is the static characteristic of the plant. For the dependency of the time
response, one should check the dynamical response for dierent amplitude of input signals.
Time-invariance
The time-invariance is often assumed to be fullled but from time to time some experiment are required to assess the
validity of this assumption.

9.5.2

Identification experiment

Books exist on the design of a experiment in order to perform an identication. The aim of this chapter isnt to
present all the technics but only to informed about the basics properties of the experimental input.
First,one have to use a input signal who dont violate the LTI properties. Second, the input has to fully excite
the plant. One way to achieve these properties is by using a step response between two values within the linear
behavior of the plant.

9.5.3

Validation of the model

After running the identication procedure, one have to validate the results they obtain. The easiest way is by visually
compare the response of the model of the plant with some real response (with the same inputs). One can also used
dierent experiments for the identication and the validation, in this case you performed cross validation.

Вам также может понравиться