California University of Pennsylvania

Department of Applied Engineering & Technology

Electrical Engineering Technology

EET 410: Automatic Control Systems

Spring 2016

Lab1: Second Order System

Do Not Print

Use the electronic copy to verify to instructor

Answer all questions

Work must appear professional, complete and must be correct to receive credit

Lab Date: 09/06/2016

Must Read

MUST NOT add names(s) of laboratory partners if they did not contribute significantly to this lab. Being in lab and doing minimal work is considered as no contribution. Doing documentation work, typing, fetching components is not the goal of this lab, these are just side things. Thus, all lab partners must be actively involved in all aspects of the experiments.

Name: Signature: Date:

Name: Signature: Date:

Name: Signature: Date:

Objective:

The laboratory experiments objective is to review basic concepts regarding the behavior of a second order system.

Preface: Read everything, otherwise this lab becomes confusing.

Previous knowledge of LaPlace Transforms, Ordinary Differential Equations, and Matlab, along with Basic electric circuits are essentials for successful completion and understanding of this exercise.

Learning Outcomes:

Students will demonstrate the ability to:

- investigate the transfer function of a second order system to obtain damping characteristics

- use software tools (Matlab) to obtain the transient response of a closed loop and an open loop system and use the data to make conclusions

- use circuit simulations tools to simulate a system’s response and use the data to make conclusions.

- use laboratory test equipment to construct and test the behavior of a second order system. Also, use the responses to make conclusion.

Introduction:

Second and first order systems are most widely used in real-life representations of physical systems. System’s whose order is above a second order are typically broken down into coupled first order systems. Such coupling is typically represented in state space models.

In typical control strategies, the transient and/or the frequency response of a system under consideration are investigated prior to designing and implementing a controller. The system’s response is investigated for transient characteristics (steady state value, rise time, settling time and % over-shoot.) Additionally, the frequency characteristics are investigated for bandwidth, natural frequency, and gain and phase margins.

In this experiment, we will focus on the transient response characteristics and some of the frequency response characteristics of the uncompensated (un-controlled) system.

The system:

Figure-1. shows the circuit schematic of a second order RC network.

The network’s transfer function is also given in equation -1.

Figure 1: Second Order Network

Let G represent the open loop transfer function (no feedback).

Gs= 1R2C2s2 + 3RC s + 1R2C2 (1)

Where R1 = R2 = R and C1 = C2 = C

The standard second order transfer function is given as:

Gs=ωn2(s2+2ζωns+ωn2) (2)

The Experiment

This laboratory experiment is divided into three parts as flows:

Part -1 : Theoretical Calculations of the open loop and closed loop system

Part -2: Simulation (Matlab and Multisim)

Part-1: Theoretical Calculations.

A- Open Loop System

Use equations (1) and (2) to determine equations for the damping ratio and the natural frequency. Afterwards, substitute components values to determine numerical results for these two parameters.

Theoretical Results:

The equations are:

·  ωn = rad/sec.

·  fn = Hz.

·  ζ =

·  The cut –off frequency may be calculated as follows:

wc=wn1-2ζ 2+2-4ζ 2+4ζ 4 = rad/sec. (3)

·  The steady state value (ssv) due to a unit step input is given to be 1. (Discussed later in the course)

·  If ζ is greater than 1, then the system does not have an overshoot (0%)

·  The rise time and settling times are estimated, respectively, to be:

tr = (1.2 - 0.45* ζ + 2.6* ζ ^2)/wn for ζ <1.2;

and tr = (4.7* ζ -1.2)/wn for ζ >1.2 (4)


ts = -0.5*log( (1- ζ ^2)/400) )/( ζ *wn) for ζ <0.7;

and ts = (6.6* ζ -1.6)/wn for ζ >0.7 (5)

Tabulate your numerical results in Table-1 below. Ensure to use proper units.

Table 1: Numerical Results of the open-loop system characteristics

Parameter / Value
ζ
ωn
ωc
fn
fc
ssv
%overshoot
tr
ts

B- Closed Loop System

The system will have a unity negative feedback, thus, the closed Loop transfer function is given by:

GCLs=G1+G (6)

Substituting for G from equation (1), yield with the equation:

GCLs= 1R2C2s2 + 3RC s + 2R2C2 (7)

Show work to prove equation (7)

As can be seen, all the parameters have now changed since ωn has changed.

The new value of ωn is:

wn= 2R2C2 = 2RC (8)

and the new steady state value due to a unit step input is now equal to 0.5

Calculate the new ζ and then using equations (3), (4), (5) and (8), complete the table below.

Table 2: Numerical Results of the closed-loop system characteristics

Parameter / Value
ζ
ωn
ωc
fn
fc
ssv
%overshoot
tr
ts

Questions:

Answer the following questions to make observations:

1- Did the rise time increase or decrease in the closed loop case------?

2- Did the settling time increase or decrease in the closed loop case ------?

3- Does the closed loop system have any overshoot? ------?

Part-2: Simulation (Matlab and Multisim).

In this section the system will be simulated using software tools.

Although this time the code is given to help you recall steps, in the future most code will have to be written by you.

Ensure to correctly and appropriately comment the code.

A- Simulation using Matlab.

Write a Matlab code to plot the step and frequency response of the closed loop and open loop system.

1- Open loop system step response

Enter this code and from the step response, determine the system characteristics (%overshoot, ssv, rise time, and settling time). Enter the data in Table 3 below.

Firgure out how to have Matlab display thwese characteristics o nthe plot.

clear all

clc

C=0.1e-6;R=100e3;

num=[1/(C^2*R^2)];

den=[1 3/(C*R) num];

G = tf(num,den);

step(G)

2- Open loop frequency response

Modify the code above to plot the frequency response. Move the cursor on the magnitude plot to determine the 3dB point (cut-off frequency.) Then, using modified equation (3) to calculate the natural frequency.

Add your results to Table 3.

clear all

clc

C=0.1e-6;R=100e3;

num=[1/(C^2*R^2)];

den=[1 3/(C*R) num];

G = tf(num,den);

bode(G)

Table 3: Numerical Results of the Open loop system characteristics (Using Matlab)

Parameter / Value
ωn
ωc
fn
fc
ssv
%overshoot
tr
ts

·  Demonstrate this to the lab instructor to verify that the theoretical (Table 1) and simulated (Table 3) results agree.

:

3- Closed loop system step response

Enter this code and from the step response, determine the system characteristics (%overshoot, ssv, rise time, and settling time). Enter the data in Table 4 below.

clear all

clc

C=0.1e-6;R=100e3;

num=[1/(C^2*R^2)];

den=[1 3/(C*R) num];

G = tf(num,den);

Gcl=feedback(G,1); %Closed loop system with unity feedback,

step(Gcl)

4- Closed loop frequency response

Modify the code above to plot the frequency response. Move the cursor on the magnitude plot to determine the 3dB point (cut-off frequency.) Then, using modified equation (3) to calculate the natural frequency.

Add your results to Table 4.

clear all

clc

C=0.1e-6;R=100e3;

num=[1/(C^2*R^2)];

den=[1 3/(C*R) num];

G = tf(num,den);

Gcl=feedback(G,1); %Closed loop system with unity feedback,

bode(Gcl)

Table 4: Numerical Results of the closed loop system characteristics (Using Matlab)

Parameter / Value
ωn
ωc
fn
fc
ssv
%overshoot
tr
ts

·  Demonstrate this to the lab instructor to verify that the theoretical (Table 2) and simulated (Table 4) results agree.

Instructor Signature:

B- Simulation Using Multisim

1- Open Loop response

Construct the circuit of Figure -1 on Multisim and perform transient and frequency response analysis as follows:

a-  Transient analysis:

Apply a 1VDC input and then invoke the transient analysis. Set the initial conditions to zero and the final time is 0.2 seconds.

Use the cursors to determine the rise time and steady state value. Place the results in Table 5.

(Demonstrate to instructor)

Instructor Signature:

b-  Frequency response:

Apply a 1Vpk sine wave (frequency does not matter) and set the frequency response analysis to be as follows:

minimum frequency = 0.01 Hz, Maximum = 1KHz, decibel mode.

Move the cursor on the plot to determine the 3-dB point.

(Demonstrate to instructor)

Instructor Signature:

Table 5: Multisim results for the Open-Loop System

Parameter / Value
ωc
fc
ssv
%overshoot
tr

2- Closed Loop System

In order to construct the closed loop system using Multisim, it is recommended that the system is reduced to a sub-circuit to reduce clutter.

a- Save your original circuit

b- Remove the input

c- place junctions so the circuit looks like the one shown here in Figure 2..

Figure 2: Plant (Open Loop System)

d- Select the whole circuit (Excluding the junction wires for inputs and outputs) then right click and select (“Change to sub-circuit”) Call it Plant in the dialog box

you should end up with something similar to this:

e- right click anywhere in a blank area on the Multisim screen, select properties, check the “Hide all”

f- double click on the sub-circuit block, choose the display tab, and uncheck everything. You should end up with this figure:

g- clean up the connections and enter a text into the sub-circuit box as shown.

h- Now, the system is ready to be in a closed loop configuration.

i- Build the system on Multisim to be as shown below.

Transient and Frequency Response:

Repeat the steps of Part 2: B-1-a and B-1- b and complete Table 6 below.

Table 6: Multisim results for the Closed-Loop System

Parameter / Value
ωc
fc
ssv
%overshoot
tr

(Demonstrate to instructor)

Instructor Signature:

Questions

Do the results of Table 5 agree with those of Table 1 ------?

Do the results of Table 6 agree with those of Table 2 ------?

Part-3: Circuit construction and test with LabVIEW Integration.

For Lab No. 2 of next week. (possibly)