P. 1
Reshma Control Lab Manual

# Reshma Control Lab Manual

|Views: 308|Likes:

See more
See less

01/02/2013

pdf

text

original

## Sections

• EXPERIMENT NO: 1
• EXPERIMENT NO: 2
• EXPERIMENT NO: 3
• EXPERIMENT NO: 4
• EXPERIMENT NO: 5
• EXPERIMENT NO: 6
• EXPERIMENT NO: 7
• EXPERIMENT NO: 8
• EXPERIMENT NO: 9
• EXPERIMENT NO: 10
• EXPERIMENT NO: 11
• EXPERIMENT NO: 12
• EXPERIMENT NO: 13
• EXPERIMENT NO: 14
• EXPERIMENT NO: 15

# SREE NARAYANA GURUKULAM COLLEGE OF ENGINEERING

CONTROL SYSTEM LAB MANUAL

SEVENTH SEMESTER ELECTRICAL AND ELECTRONICS ENGINEERING

CONTROL SYSTEM LAB

List of experiments 1) 2) 3) 4) 5) 6) 7) 8) Transfer function of separately excited DC generator. Transfer function of armature controlled DC motor. Transfer function of field controlled DC motor. AC servo motor speed torque characteristics. DC position servo control system. Synchro transmitter and receiver characteristics. AC synchro differential generator. Use of MATLAB for simulating transfer functions, closed loop systems etc.

EXPERIMENT NO: 1 TRANSFER FUNCTION OF SEPARATELY EXCITED DC GENERATOR Aim: To obtain transfer function of separately excited generator using the formula
E (s) o E (s) f KgZo ( s ) [ Rg + sLg + Zo ( s )][ Rf + sLf ]

=

Apparatus required: Sl.no: 1 2 3 Theory: Transfer Function of separately excited DC generator is given by
KgZo ( s ) [ Rg + sLg + Zo ( s )][ Rf + sLf ]

Apparatus Voltmeter Ammeter Rheostat

specification 0-300V, MC 0-60V,MC 0-250V, MI 0-2A, MC 0-5A, MC 0-10A, MI 0-1000mA, MI 200Ω, 1.5A

Quantity 1 1 1 2 1 1 1 2

E (s) o E (s) f

=

Where

Kg is generator constant Rg is generator resistance

Lg is the generator inductance Rf is field resistance Lf is field inductance

Procedure: Connections are made as shown in the motor-generator set circuit diagram. The motor is started using starter. The resistance of DC motor is kept in minimum position and generator field resistance in maximum position. The generator field is excited from a separated DC source ie from same supply as DC motor field. The rheostat of generator side is varied till the motor attains rated speed. Armature terminal is kept open. Field rheostat of generator is varied so that open circuit voltage varies. Now OCC is plotted for open circuit voltage Vs field current. Slope of OCC gives Kg. The armature resistance, field resistance, armature reactance, field reactance are measured. Substitute Kg, Rg, Lg, Rf, Lf in the given formula of transfer function.

Circuit Diagram Observations Voltage (volts) If (A) .

To find Rf Voltmeter Reading (V) Ammeter Reading (A) Field Resistance Rf (Ω) To find Lf .

Voltmeter Reading (V) Ammeter Reading (A) Field Inductance Zf (Ω) Xf = √ (Zf2-Rf2 ) To determine Ra Voltmeter Reading (V) Ammeter Reading (A) Armature Resistance Ra (Ω) .

To determine La Voltmeter Reading (V) Ammeter Reading (A) Armature Impedance Za (Ω) Xa = √ (Za2-Ra2 ) .

Result: Determined the transfer function of separately excited DC generator. .

MC 0-30V. 5A 200Ω. 1. (i) (ii) (iii) Back emf constant Kb Torque constant Kt Mechanical time constant Tm Apparatus required: Sl. MI 50 Ω. MC 0-10A.MC 0-125V.5A ------ Quantity 1 1 1 2 1 1 1 2 1 1 Theory: Transfer Function of Armature controlled DC motor is given by W (s) o E (s) o = Kt / RaB s[(1 + sTa )(1 + sTb ) + KtKb / RaB ] . MC 0-10A. MC 0-5A. MI 0-2A.no: 1 2 Apparatus Voltmeter Ammeter 3 4 Rheostat DPDT switch specification 0-300V.EXPERIMENT NO: 2 TRANSFER FUNCTION OF ARMATURE CONTROLLED DC MOTOR Aim: To determine transfer function of armature controlled DC motor by finding the following constants.

which is to be kept constant. Noted the value of If. The motor is switched on keeping DPDT switch in 1-1’ position. (1400 rpm). V. Ia. (i) To find torque constant Kb: The armature rheostat is varied till rated speed (approximately 1400 rpm) is attained. (ii) To find friction constant B: The armature rheostat is varied till motor speed attains a constant value. Every time the armature rheostat is varied till it reaches 1400 rpm. The field rheostat (200Ω. Ta = La/Ra and Tm = Tb = J/B where La is armature inductance and J is moment of inertia. Kb is calculated from the given formula. B is calculated from . The armature rheostat is varied and the corresponding Ia. Similarly 3 or 4 sets of readings are noted. Also Kt=Kb. Procedure: Connections are done as shown in the first circuit diagram. 5A) in maximum position. The corresponding Ia. V. Similarly 4 or 5 sets of readings are taken. N are also noted.Where Kt is torque constant Ta is electrical time constant Tb is back emf time constant Kb is back emf constant Ra is armature resistance B is friction constant. N are also noted.5A) is kept in minimum position and the armature rheostat (50 Ω. 1. The field rheostat is varied and corresponding If. V are noted. Also the rheostat connected to 2-2’ position of the DPDT switch is kept in maximum position.

J is calculated from the calculation given below. The above procedure is repeated while the switch is brought from 1-1’ position to open position. . V1. The DPDT switch is switched on to 2-2’ position. (1400 rpm). (iii) To find moment of inertia J: The armature rheostat is varied till motor speed attains a constant value. Substituted all the values in the given formula of transfer function. If2.the graph given below. Noted the corresponding If1. The time taken for the motor to reach 900 rpm (about 70% of rated speed) is noted. V2 are also noted at the very same second. Ia2. Ia1.

J Observations To find Torque constant.Circuit Diagram To find Kb. Kb If = a constant value Sl:no: Voltage V (volts) Speed N (rpm) Ia (A) IaRa (Volts) Eb = VKb = Eb/ IaRa (2ΠN/60) (volts) (volt/(rad/sec)) . B.

To find Friction constant. J Excitation Mode Speed N (rpm) If (A) If1 = If2 = If1 = If2 = Ia (A) Ia1 = Ia2 = Ia1 = Ia2 = Voltage (V) V1 = V2 = V1 = V2 = Time (sec) t2 = Switch 1-1’ to N1 = 1400 switch 2-2’ N2 = 900 Switch 1-1’ to N1 = 1400 switch open N2 = 900 t1 = . B N = a constant value Sl:no: Voltage V (volts) If (A) Ia (A) VIa (W) Ia2Ra (W) Ws = VIaIa2Ra (W) To find Moment of imertia.

To determine Ra Voltmeter Reading (V) Ammeter Reading (A) Armature Resistance Ra (Ω) To determine La .

Voltmeter Reading (V) Ammeter Reading (A) Armature Impedance Za (Ω) Xa = √ (Za2-Ra2 ) Calculations To find B B = Y intercept/(2ΠN/60) .

.To find J: Average of voltmeter reading during time t2= Vav= (V1+V2)/2 Average of ammeter reading during time t2= Iav= (Ia1+Ia2)/2 W’ = Vav Iav Power used to overcome the inertia of motor = W= W’t2/(t1-t2) W = (2П/60)2JN (dN/dT) W = (2П/60)2JN (N1-N2/t1-t2) In the above equation the only unknown is J which can be calculated. Result: Determined the transfer function of armature controlled DC motor. .

MC 0-30 V. Tf Apparatus required: Sl.EXPERIMENT NO: 3 TRANSFER FUNCTION OF FIELD CONTROLLED DC MOTOR Aim: To determine transfer function of field controlled DC motor by finding the following constants. MC 2 3 Rheostat 4 DPDT switch 50Ω. Tm Field time constant. MC 0-1000mA. Ktf Mechanical time constant. 5 A 200 Ω.5 A -----2 1 1 Ammeter 0-5 A. MI Quantity 1 1 3 1 . (i) (ii) (iii) Torque constant.no: 1 Apparatus Voltmeter specification 0-250 V. 1.

Take all meter readings at no load. When it runs at rated speed note Ia. Now load the motor slightly.Theory: Transfer Function of Field controlled DC motor is given by O( s) V (s) f K m s[(1 +sTf )(1 +sTm )] = Where Km is motor gain constant Ktf is torque constant Tf is field time constant Tm is mechanical time constant Kb is back emf constant Rf is field resistance B is friction constant Tf = Lf/Rf and Tm = Tb = J/B where Lf is field inductance and J is moment of inertia. Now vary the motor field rheostat slightly . The speed should be maintained constant. Ktf: Connections are made as shown in figure. Also Kt=Kb. This is maintained constant. Run machine at rated speed (1400 rpm) by varying armature rheostat. Note all meter readings. Vary armature rheostat to obtain earlier value of Ia. Procedure: (i) To find torque constant. The DPDT switch should be in 1-1’ position. (ii) To find friction constant B: Run the machine at rated speed by varying armature rheostat. Keep switch in 1-1’ position. Note various readings. Unload the motor and turn off supply. Initially field rheostat should be kept in minimum position and armature rheostat in maximum position.

Substituted all the values in the given formula of transfer function. (iii) To find moment of inertia J: The armature rheostat is varied till motor speed attains a constant value. Calculate power and plot graph with Ws along Y axis and If along X axis. J is calculated from the calculation given below. V1. Ia2. Adjust speed to 1400 rpm by varying armature rheostat. Calculate B = Y intercept/(2ПN/60). (1400 rpm). Repeat for different values of If. Take all the meter readings. Noted the corresponding If1. . The time taken for the motor to reach 900 rpm (about 70% of rated speed) is noted. The above procedure is repeated while the switch is brought from 1-1’ position to open position.so that If is a notable value. The DPDT switch is switched on to 2-2’ position. Ia1. If2. V2 are also noted at the very same second.

Circuit Diagram To find Ktf Ia = a constant value Observations To find Torque constant.8 (Nm) Ktf = T/If No load Load . Ktf Sl:no: Speed N (rpm) Voltage (volts) If (A) S1 (kg) S2 (kg) T = (S1S2)*R*9.

J Excitation Mode Speed N (rpm) If (A) If1 = If2 = If1 = If2 = Ia (A) Ia1 = Ia2 = Ia1 = Ia2 = Voltage (V) V1 = V2 = V1 = V2 = Time (sec) t2 = Switch 1-1’ to N1 = 1400 switch 2-2’ N2 = 900 Switch 1-1’ to N1 = 1400 switch open N2 = 900 t1 = .To find Friction constant. B N = a constant value Sl:no: Voltage V (volts) If (A) Ia (A) VIa (W) Ia2Ra (W) Ws = VIaIa2Ra (W) To find Moment of imertia.

To determine Ra Voltmeter Reading (V) Ammeter Reading (A) Armature Resistance Ra (Ω) To find Rf Voltmeter Reading (V) Ammeter Reading (A) Field Resistance Rf (Ω) .

To find Lf

Field Inductance Zf (Ω)

Xf = √ (Zf2-Rf2 )

Calculations To find B

B = Y intercept/(2ΠN/60)

To find J: Average of voltmeter reading during time t2= Vav= (V1+V2)/2 Average of ammeter reading during time t2= Iav= (Ia1+Ia2)/2 W’ = Vav Iav Power used to overcome the inertia of motor = W= W’t2/(t1-t2) W = (2П/60)2JN (dN/dT) W = (2П/60)2JN (N1-N2/t1-t2) In the above equation the only unknown is J which can be calculated. Result: Determined the transfer function of field controlled DC motor.

EXPERIMENT NO: 4 AC SERVO MOTOR SPEED – TORQUE CHARACTERISTICS

Aim:

To study the speed- torque characteristics of AC servo motor.

Apparatus required:

Sl:no: 1

Apparatus Voltmeter

Specification 0-3V, MC

Quantity 1

2

Connecting chords

------

2

Theory: An AC servo motor is basically a two- phase induction motor except for special design features. Rotor of the servo motor is built with high resistance so that its X/R ratio is small which results in linear speed- torque characteristics. Moreover in AC servo motor, excitation voltage applied to stator windings should have a phase difference of 90°.

It . These curves show a large torque at zero speed. Due to the interaction of the rotor and stator flux. This is the requirement for a servo motor to provide rapid acceleration. Slowly increase P1 (speed control pot) so that the AC servo motor starts rotating. The torque. Keep potentiometer P1 and P2 in fully anti clock wise direction.Working: Stator windings are excited by voltages of equal rms magnitude and 90° phase difference. The rotating magnetic field sweeps over the rotor conductors. Procedure: (i) (ii) (iii) (iv) Switch off the switches S1 and S2. Speed.Torque curves: These have negative slope. These currents give rise to a rotating magnetic field of constant magnitude. motor develops a decelerating torque and so motor stops. This circulates current in the short circuited rotor conductors and currents create rotor flux. Switch on the AC servo motor by putting on switch S1. We may have to give higher voltages to start the AC servo motor then we may decrease the voltage for lower speed. Connect the supply and switch on the unit.phase voltage is zero. (v) Connect Dc voltmeter across TP3 and record this back emf in the table 1 corresponding to the speed as indicated by the rpm meter. (The voltmeter reading will be negative because it is the back emf. This results in currents I1 and I2 that are phase displaced by 90°.speed curves are non-linear except in low speed region. These currents are having equal rms values. Let S2 be in the off position. When the control. Voltages are induced in the rotor conductors. a mechanical force is developed on the rotor and so rotor starts moving in same direction as rotating magnetic field.

Plot its speed. Let S1 be also in the on position. Observe and record the current meter reading on the panel with respect to the corresponding speed. 2000 rpm. (ix) (x) Complete the table 2 and plot the speed Vs torque characteristics. Calculate the torque for these for speeds 1100. Choose 2 or 3 consecutive Eb readings from table 2 and their corresponding ammeter reading and rewritten in table 3.torque characteristics. The AC servo motor rotates and hence the DC motor also rotates due to which back emf is generated.) (vi) Vary the speed of the AC servo motor as indicated by the potentiometer P1 in steps and record the corresponding back emf in table 1. 1300……. Keep P2 (load control pot) in anti clock wise position and increase P1 to get maximum speed. (vii) Now switch on S2. (viii) Slowly increase potentiometer P2 in steps and record speed and current meter reading in table 2. 1200. .is nothing but the output of a motor coupled to the AC servo motor. Rewrite the back emf readings in table 2 from table 1..

Observations: Table 1: Sl: No: 1 2 3 4 5 6 7 Speed N(rpm) Back emf (V) Table 2: Sl: No: 1 2 3 4 5 6 7 Ia (mA) N (rpm) Eb (from table 1) (V) P = IaEb (W) T= P*60/2ПN (Nm) .

. 2000 T= P*60/2ПN (Nm) 1 2 . . . .Table 3: Sl: No: Eb (from table 2) (V) Ia (from table 2) (mA) N (rpm) 1100 1200. . . . 2000 1100 1200. .

Expected Graphs .

.Result: Studied and plotted speed.torque characteristics of an AC servomotor.

Input voltage Vs deflection in slave pointer in degrees.EXPERIMENT NO: 5 DC POSITION SERVO CONTROL SYSTEM Aim: To study DC position servo control system and to plot: (i) (ii) (iii) (iv) Deflection in master dial potentiometer in degrees Vs deflection of slave pointer in degrees. The output of this stage is positive (say). This voltage is power amplified. The DC motor is mechanically coupled with variable of rebalance (feedback) pot. The output of power amplifier drives DC servo motor. Apparatus required: Sl:no: 1 2 Apparatus Digital voltmeter Connecting chords Quantity 1 1 Theory: The input is fed to error amplifier. The motor drives feedback pots in such a way that feedback voltage equals input voltage. Difference between the input voltage Vi and error voltage Vf is amplified. Measure the dead zone of the given DC position servo control system. When feedback voltage equals input voltage difference between two voltages becomes . Gain versus settling time.

Thus motor is saved from damaging. which in turn may damage motor. The input to inverting terminal is the sum of zero adjust. linearity and resolution. If output of amplifier A1. Servo system is a closed loop negative feedback control system. no drift. dead zone. high sensitivity. it may overheat the respective transistor. This input is given to the non. which under such circumstances limits the input to the base of transistors by limiting the input to about 50% of original value. good repeatability. by any change remains at high or low state. which in turn rotates motor in the clock wise direction by turning on corresponding transistor. This is the null point of system. To avoid such damage to the motor. (ii) Switch on the trainer kit. The motor will rotate in counter clock wise direction if position of master dial is less than position of motor. DC servo motor rotates in both directions depending upon voltage polarity applied to it. The master dial input (Vref) varies from 0 to 2. high accuracy. . The output of amplifier A1 will be either a high level or low level depending on the position of master dial with respect to position of motor. noise free. If the position of master dial is greater than motor position.7 V corresponding to 0 to 270° respectively.zero. Keep the gain pot (P4) in the midway position. output does not respond. span adjust. gain adjust and rebalance pot. hunting. output of A1 will be approximately 12 V. Procedure: (i) Connect shorting link at the input and also a digital voltmeter of 20 V range (DC) at the input terminals. a power limiting circuit or killing circuit is incorporated. Hence output change remains at high or low state and output of power amplifier would be 0 V which will make the motor stop.inverting terminal of comparator (A1). Dead zone is defined as the zone in which when maximum input is applied. Also its speed is very high (5000 rpm) DC servo system has the following characteristics like fast response.

Rotate master dial from 0° to 270°. 50% …. The settling time decreases as gain increases. the slave dial starts moving. To plot gain Vs settling time graph: Keep P4 at 30% position ant the master and slave dial at 0°. Also keep the master dial at 90° and looking at the slave dial move the master dial till.100%).(iii) Adjust the master potentiometer to 0° and then switch on the motor. . The distance in degrees for which the slave does not respond is dead zone. Note the time taken for slave dial to reach 270° with the help of stop-watch. (iv) (v) (vi) Now adjust the master potentiometer to 270° and adjust the slave potentiometer also to 270° with the help of span adjust pot (P3). Now take down the reading for different positions of the pointer as in the observation table. (vii) Now increase span to maximum and repeat the experiment. (viii) Plot deflection in master potentiometer Vs deflection in slave potentiometer dial and also input voltage Vs deflection in slave pointer dial. Repeat the above for different positions of P4 (40%. Also note the corresponding input voltage from digital voltmeter. Adjust with zero adjust pot (P2) such that the slave pointer is also at 0°. To measure dead zone: Keep P4 at approximately 30% position.

Dial (degrees) Input voltage (V) Table 2: Sl: No: 1 2 3 4 5 6 7 8 Gain adjust (%) 30 40 50 60 70 80 90 100 Time (sec) . Dial (degrees) 270 180 135 90 0 Deflection in slave pot.Observations: Table 1: Sl: No: 1 2 3 4 5 Deflection in master pot.

.

Expected Graphs .

.Result: Studied the DC position servo control system and plotted the graphs.

This induces an emf in stator coil. The generated emf of sychro transmitter is applied as input to stator coils of the control transformer. MI Quantity 1 2 Connecting chords ------ 7 Theory: A synchro is an electromagnetic transducer commonly used to convert an angular position of shaft into an electrical signal. rotor current flows and a magnetic field is produced. The rotor shaft is connected to load whose position has to be maintained at desired value. Depending on current position of rotor and the applied emf on stator. Effective induced voltage depends upon angular position of coil axis with respect to rotor axis.EXPERIMENT NO: 6 SYNCHRO TRANSMITTER AND RECEIVER CHARACTERISTICS Aim: To study sychro characteristics by plotting angular position Vs stator voltages and input angular position Vs output angular position. . an emf is induced on rotor winding. Apparatus required: Sl:no: 1 Apparatus Voltmeter Specification 0-125 V. When the rotor of sychro transmitter is excited by AC voltage.

e. Vary the shaft position of the transmitter and observe the corresponding change in the shaft position of the receiver. EXP: 2 (i) (ii) (iii) (iv) (v) (vi) Connect power supply output to R1-R2 terminals of the transmitter and receiver.Procedure: EXP: 1 In this part of experiment because of transformer action the angular position of rotor of sychro transmitter is transferred into a unique set of stator voltages . S3 of receiver.. Do not inter connect S1. Short S1-S1. S3 of transmitter to S1. Repeat the above steps for different angles of the shaft of the transmitter and tabulate as in table 2. Vs2s3 in sequential manner. (ii) (iii) Switch on main supply for unit and transmitter rotor supply. . S2-S2 and S3-S3 windings of transmitter and receiver with the help of connecting chords. (i) Connect power supply output to R1-R2 terminals of the transmitter with the help of cables provided. S2. Vs3s1. As the power is switched on transmitter and receiver shaft will come to the same position on the dial. Switch on the supply unit. S2. Starting from zero position note down the voltage between stator winding terminal i. Vs1s2. Enter readings as in table 1 and plot a graph of angular position Vs stator voltages for all 3 phases.

Connection Diagram .

. . . 330 Vs3s1 Vs1s2 Vs2s3 . . . . . .Observations: Table 1: Sl:No: 1 2 3 4 5 6 7 8 9 10 11 12 Table 2: Sl:No: 1 2 3 4 5 6 7 8 9 10 11 12 Transmitter Receiver angular angular position in position in degrees degrees 0 30 60 . 330 Rotor position in degrees 0 30 60 . . . . . . .

.

.Result: Studied the synchro transmitter and receiver characteristics and plotted the angular position Vs stator voltage curve and also input angular position Vs output angular position.

S2. S1. Plot the error graph between the two. Differential synchros are designed to operate as either transmitter or receiver. synchro differential generator and connecting chords. Keep the shaft of receiver at 0° position and note the corresponding position in differential generator. R3 of synchro differential generator and S1.. (i) The connection is to be done as shown in figure 1. S2. . 40……340 and also note the corresponding position in differential generator. 70°. S3 of synchro receiver. Apparatus required: Synchro transmitter and receiver unit.EXPERIMENT NO: 7 AC SYNCHRO DIFFERENTIAL GENERATOR Aim: To plot an error graph when the differential synchro is connected for addition and subtraction. i. S2. S3 of synchro differential generator to S1.e. Hold the shaft of transmitter at a constant position i. Also connect power supply output to R1. Procedure: The synchro differential generator is to be used with the synchro transmitter and receiver unit.R2 terminals of receiver and transmitter. A differential sychro produces a shaft displacement which is equal to sum or difference between angular position of two other shafts.e.. S3 of synchro transmitter to R1. Theory: A synchro is an electromagnetic transducer commonly used to convert an angular position of shaft into an electrical signal. R2. Vary the shaft of receiver to 20.

40……340 and also note the corresponding shaft position of receiver (it will be approximately equal in magnitude but opposite in direction).. Then plot the error graph.Then hold the shaft of differential generator at a constant position i. Vary the shaft of transmitter from 0. Vary shaft of receiver from 0.340 and note the corresponding position in the receiver. S1 of differential generator is connected to S3 of receiver and S3 of differential generator to S1 of receiver. . (ii) The connection is to be done as shown in figure 2 with only two changes from the above connection i. 295°. 20………340 and note the corresponding shaft position of differential generator (it will be approximately equal in magnitude but opposite in direction).. Plot the error graph. Vary the shaft of transmitter from 0. 20. 20…….e. Hold the differential generator at 295° position. Hold the transmitter shaft at 70° position..e. Then plot the error graph.

Connection Diagram Differential Synchro connected for subtraction Differential Synchro connected for addition .

340 Differential generator angular position = 295° Transmitter angular position (degrees) 0 20 40 .Observations: Differential synchro connected for subtraction: Transmitter position = 70° Differential generator angular position (degrees) Receiver angular position (degrees) 0 20 40 . . . . . . . . . 340 Receiver angular position (degrees) .

. .Differential synchro connected for addition: Transmitter position = 70° Differential generator angular position (degrees) Receiver angular position (degrees) 0 20 40 . . 340 Receiver angular position (degrees) . . . . . 340 Differential generator angular position = 295° Transmitter angular position (degrees) 0 20 40 . .

Expected Graphs Differential Synchro connected for subtraction .

Differential Synchro connected for addition .

.Result: Plotted the error graphs when synchro differential generator is connected for addition and subtraction.

numerical solutions of ODEs. There are also several optional ‘Tool Boxes’ available from developers of MATLAB. MATLAB works through three basic windows. such as PCs and Macs MATLAB provides its own built-in editor. These toll boxes are collections of functions written for special applications such as that of symbolic computation. Graphics window: The output of all graphics commands typed in the command window are flashed to the graphics or figure window. quadrature and many other types of scientific computations. optimization. The basic building block of MATLAB is the matrix. a separate gray window with (default) white back ground color. data analysis.MATLAB MATLAB is a software package for high performance numerical computation and visualization. The fundamental data type is the array. On most systems. including those for running user written programs are typed in this window at the MATLAB prompt. MAT Lab’s built-in functions provide excellent tools for linear algebra computations. MATLAB even promises an external interface to run those programs from within MATLAB. (ii) (iii) . edit. It is characterized by MATLAB command prompt ’>>’. It provides an interactive environment with hundreds of built-in functions for technical computation. graphics and animation. The user can create as many figure windows as the system memory will allow. BASICS OF MATLAB MATLAB WINDOWS: On all PCs. Edit window: This is where you write. statistics. create and save your own programs in files called ‘ M-files’. There are numerous functions for 2-D and 3-D graphics as well as for animation.the art algorithms. Also for those who cannot do without their FORTRAN or C. real matrices and complex matrices all are automatically handled as special cases of basic data type. You can use any text editor to carry out these tasks. scalars. The name MATLAB stands for MATRIX LABORATORY. Most of these functions use state -of. Vectors. When you launch the application program.codes. All commands. It also provides easy extensibility with its own high level programming language. signal processing. image processing. MATLAB puts you in this window. (i) Command window: This is the main window. control system design and neural network.

Output display: The output of every command is displayed on screen unless MATLAB is directed otherwise. A semicolon at the end of a command suppresses the screen output except for graphics and on.e. (iii) (ii) (iii) (iv) (v) . It encompasses several distinct data objects. integers. Type demo at the MATLAB prompt to invoke the demonstration program and follow the instructions on the screen. Input. You can turn case sensitivity on and off with case sensitive commands. character strings. Dimensioning: It is automatic in MATLAB.ON-LINE HELP (i) (ii) On-line documentation: MATLAB provides on-line documentation for all its built-in functions and programming language constructs. These commands can be recalled with up arrow key. doublers (real numbers) matrices. Most MATLAB commands and built-in function calls are typed in lower case letters. In addition it can read input files and write output files. it differentiates between lower case and upper case letters.output. The program includes a tutorial introduction that is worth trying. The following features hold good for all forms of input.sensitive i. taking the input from the screen and flushing the output to the screen. Case sensitivity: MATLAB is case. Demo: MATLAB has a demonstration program that shows many of its features.output: MATLAB supports interactive computation. (i) Data types: The fundamental data type in MATLAB is the array. Command history: MATLAB saves previously typed commands in a buffer. This helps in editing previous commands. structures and cells. You can also recall a previous command by typing first few characters and then pressing up arrow key. No dimension statements are required for vectors or arrays.line help commands. You can find the dimensions of an existing matrix or a vector with the size and length (for vectors only) commands.

The data is written in a special format that only MATLAB can read. (ii) Mat files: These are binary files with a mat extension to file name. (iii) Mex. Mat files are created by MATLAB when you save the data with save command. Mat-files can be loaded into MATLAB with load command. (i) M-files: These are standard ASCII files with an extension to file name.programs with a mex extension to file name. . Some built-in functions are provided with source code in readable M-files so that they can be copied and modified. All built-in functions in MATLAB are M-files most of which reside on your computer in precompiled format. There are two types of these files: SCRIPT files and FUNCTION files.FILE TYPES MATLAB has three types of files for storing information.files: These are MATLAB.callable FORTRAN and C.

den) creates a continuous time transfer function ‘sys’ with numerator num(s) and denominator den(s). Functions used: (i) tf (): This function creates or converts transfer function.EXPERIMENT NO: 8 ROOT LOCUS AND BODE PLOT Aim: To plot the root locus and bode plot of the system G(s) = K/ s(s+2)(s+3). . sys = tf(num. Assume K= 20. The output is a transfer function of object. (ii) rlocus(G): Root locus of given transfer function G is obtained. (iv) margin(G): Phase margin and gain margin of given transfer function G is obtained. (iii) bode(G): Bode plot of given transfer function G is obtained.

G=tf(num.09 rad/sec) 50 0 Magnitude (dB) Phase (deg) -50 -100 -150 -90 -135 -180 -225 -270 10 -1 10 0 10 1 10 2 10 3 Frequency (rad/sec) .den). den=[1 10 16 0].den).num=[0 0 0 20]. G=tf(num. den=[1 10 16 0]. num=[0 0 0 20].1 dB (at 4 rad/sec) .7 deg (at 1. Pm = 53. bode(G). rlocus(G) Bode Diagram Gm = 18. margin(G).

.Root Locus 20 15 10 5 Imaginary Axis 0 -5 -10 -15 -20 -25 -20 -15 -10 Real Axis -5 0 5 10 Result: The root locus and bode plot for the given system is plotted using MATLAB program.

The cross hair can be positional with the mouse (or with an arrow key on some computers). If ‘x’ is a scalar and ‘y’ is a vector length.k.y): plots vector ’y’ versus vector ‘x’. Zeta(z) = sum((1/k)z. Zeta: Symbolic Riemann zeta function. xlabel (‘text’): Adds desired text besides x-axis on the current axis. puts up a cross hair and waits for a mouse button or keypad keys to be pressed. If ‘x’ or ‘y’ is a matrix and vector is plotted verses rows or columns of matrix whichever line up.inf) Zeta(nz) = nth derivative of zeta(z) (ii) (iii) (iv) (v) .1. Pressing a mouse button or any key writes the text on to graph at selected location. ylabel (‘text’): Adds the text to y axis. gtext (‘string’): Displays graphics window.EXPERIMENT NO: 9 STEP RESPONSE OF A SECOND ORDER SYSTEM Aim: To write a program to find step response of second order system Functions used: (i) plot(x.

zeta=0.6 1. den=[1 2*zeta 1].1 1.x.1 0 5 10 15 20 25 time(s) 30 35 40 45 50 .8 0.4 1.1. num=[0 0 1]. ylabel ('response').1'). gtext('zeta=0.2 0 zeta=0.8 1. t=0:1:50. [y.6 0.den. plot(t.t]=step(num.1').t). STEP RESPONSE OF SECOND ORDER SYSTEM WITH OMEGA n=1 and zeta=0.4 0. title('STEP RESPONSE OF SECOND ORDER SYSTEM WITH OMEGA n=1 and zeta=0. xlabel ('time(s)').2 response 1 0.y).

.Result: Step response of second order system is obtained.

‘s’) prints transfer function as a ratio of two polynomials in transform variable ‘s’. tf2zp (x. den1. poles and direct term of a partial fraction expansion of the ratio of two polynomials.y): To find the residues of values contained in the matrix variables x/y.EXPERIMENT NO: 10 PARTIAL FRACTION EXPANSION OF SYSTEM WITH MATLAB Aim: To find the partial fraction expansion of given system of transfer function Y(s)/U(s) = (2s3+5s2+3s+6)/(s3+6s2+11s+6) with MATLAB. Functions used: (i) residue (x. printsys(num1. printsys(): This function prints system in pretty format. k] = residue(num1. [r. den1) finds the residue. p. (ii) (iii) .y): To convert the transfer function form to zero pole form to find zeros and poles from x/y polynomial.

%PARTIAL FRACTION EXPANSION WITH MATLAB %y(s)/u(s)=(2s^3+5s^2+3s+6)/(s^3+6s^2+11s+6) num1=[2 5 3 6].'s') %FINDING POLES AND ZEROS FROM NUM AND DEN POLYNOMIALS [z.den1) %NUM AND DEN POLYNOMIALS FROM RESIDUES [num1.k) %TRANSFER FUNCTION FROM NUM AND DEN POLYNOMIALS printsys(num1.den1.p. den1=[1 6 11 6].p.den1) .k]=tf2zp(num1.den1]=residue(r.k]=residue(num1. %RESIDUES FROM NUMERATOR AND DENOMINATOR POLYNOMIALS [r.p.

0000 k= 2 Result: Partial fraction expansion is obtained by MATLAB programming.0000 -1.0000 -1.1177i -0.0000 3.0000 6.0518 .3965 -0.0000 k= 2 num1 = 2.0000 p= -3.0000 6.0000 -2.0000 den1 = 1.1177i p= -3.0000 3.r= -6.0000 num/den = 2 s^3 + 5 s^2 + 3 s + 6 ----------------------s^3 + 6 s^2 + 11 s + 6 z= -2.0000 -4.1.0000 11.0000 .0000 6. 5.0518 + 1.0000 -2.

C. The numerator coefficients are returned in matrix num with as many rows as there in output Y. (ii) (iii) Calculation of transfer function: H(s) = num(s)/den = sC(sI-A)B+D of the systems: X = AX+BU Y = CX+DU Vector denominator contains coefficients of denominator in decreasing power of s. D. B. state space matrices A. Given that the transfer function of system is: Y(s)/U(s) = s/(s+10)(s2+4s+16). 1]: Here reverse action takes place. D. [num. den]= ss2tf[A. Here the conversion from transfer function to state space and vice versa are done by using following functions: (i) [ A B C D] = tf2ss(num. B. . C. conv(): This function provides convolution and polynomial multiplication. D are converted to transfer function form. den): The numerator and denominator matrices that are in transfer function form is converted into state space and values are assigned in matrices A. C.ie. Functions used: MATLAB has its own built in functions to convert one form to another. B.EXPERIMENT NO: 11 TRANSFORMATION OF MATHEMATICAL MODEL Aim: To find the transformation of mathematical model.

D. %CONVERSION FROM TRANSFER FUNCTION TO STATE SPACE [A.C.%TRANSFORMATION OF MATHEMATICAL MODEL %y(s)/u(s)=s(s+10)/(s^2+4s+16). num=[1 0].B.C.D]=tf2ss(num.den) %CONVERSION FROM STATE SPACE TO TRANSFER FUNCTION [num.1) .den]=ss2tf(A.[1 4 16]).B. %PRODUCT OF TWO POLYNOMIALS den=conv([1 10].

0000 56.0000 160.0000 14.0000 Result: Transformation of mathematical model to state model and back to transfer function is performed.A= -14 -56 -160 1 0 0 0 1 0 B= 1 0 0 C= 0 D= 0 num = 0 den = 0.0000 1.0000 -0. .0000 1 0 1.

margin (sys) plots open loop bode plot with gain and phase margin marked with a vertical line. Assume K=5.2 ess = 1/Kv Kv = lim sG(s)H(s) = K s→0 K= 1/0.5. If the phase margin is less than desired value. ωgcn = 0.2 = 5. The output is a transfer function of object. (ii) (iii) . Determine parameter β of the compensator.0 (i) Draw the bode plot for uncompensated system and determine the phase margin . sys = tf(num. den) creates a continuous time transfer function ‘sys’ with numerator num(s) and denominator den(s).EXPERIMENT NO: 12 LAG COMPENSATOR USING BODE PLOT Aim: To plot the bode plot for the unity feedback system whose open loop transfer function is given by K/s(1+2s) and design a lag compensator so that the phase margin is 40° and steady state error to ramp input is <= 0. Functions used: (i) tf (): This function creates or converts transfer function. (ii) margin (): This function computes gain and phase margin and cross over frequencies. β = 10 Agcn/20 = 10. lag compensator is designed. Take ε = 5° and determine the new gain cross over frequency. G(s) = K/s(1+2s) Given steady state error = 0.2.

F = 10(1+20s)/(1+200s). (vi) Draw the bode plot for compensated system and obtain the phase margin. T = 10/ ωgcn = 20. . Open loop transfer function = 5(1+20s)/s(1+2s)(1+200s). T.(iv) Transfer function = (s+1/T)/(s+1/ βT). (iv) Determine open loop transfer function of compensated system.

.den). margin(sys3). num=[200 10]. den=[200 1]. den=[2 1 0]. margin(sys1). figure(3).den). bode(sys1). sys1=tf(num. sys3=tf(num.den). figure(1). sys2=tf(num. bode(sys3).num=[0 0 5]. num=[0 0 100 5]. bode(sys2). den=[400 202 1 0]. figure(2). margin(sys2).

Bode Diagram Gm = Inf dB (at Inf rad/sec) .54 rad/sec) 60 40 Magnitude (dB) Phase (deg) 20 0 -20 -40 -90 -135 -180 10 -2 10 -1 10 Frequency (rad/sec) 0 10 1 Bode Diagram Gm = Inf . Pm = -180 deg (at Inf rad/sec) 20 15 Magnitude (dB) Phase (deg) 10 5 0 0 -30 -60 10 -4 10 -3 10 -2 10 -1 10 0 Frequency (rad/sec) . Pm = 18 deg (at 1.

. Pm = 45.Bode Diagram Gm = Inf dB (at Inf rad/sec) .395 rad/sec) 100 50 Magnitude (dB) Phase (deg) 0 -50 -100 -90 -135 -180 10 -4 10 -3 10 -2 10 -1 10 0 10 1 Frequency (rad/sec) Result: The lag compensator for the given system is designed and bode plot is obtained using MATLAB program.2 deg (at 0.

margin(sys) plots the open loop bode plot with gain and phase margin marked with a vertical line. sys = tf(num. G(s) = K/s(s+1) Given steady state error.EXPERIMENT NO: 13 LEAD COMPENSATOR USING BODE PLOT Aim: To plot the bode plot for the unity feedback system whose open loop transfer function is given by K/s(s+1) and design a lead compensator so that phase margin of the system is ≥ 45° and steady state error for a unit ramp input is ≤ 1/15 and gain cross over frequency of the system must be less than 7. den) creates a continuous time transfer function with numerator num(s) and denominator den(s). ess ≤1/15 ess = 1/Kv = 1/15 Kv = 15 Kv = lim s G(s) H s→0 Here G(s) = K/s(s+1) and H(s) = 1 Kv = lim s (K/s(s+1)) = K s→0 (ii) . The output sys is transfer function of object. Functions used: (i) tf(): This function creates or converts the transfer function. margin(): This function computes gain and phase margin and cross over frequencies.5 rad/sec.

8)/(s+11. Фm = 37°. lead compensator is designed.(i) Draw the bode plot for uncompensated system and determine the phase margin.6 radians/sec T = 1/(ωm √ α) = 0. . If the phase margin is less than the desired value.248 ωm = -20log(1/√ α) = -6 db. ωm = 5. α = (1-sin Фm)/ (1+sin Фm) = 0. Take ε = 5° and determine the new gain cross over frequency.09s)s(s+1) (vi) Draw the bode plot of compensated system and obtain the phase margin and gain margin. (v) Determine the open loop transfer function of compensated system Open loop transfer function = 15(1+0.358 (ii) (iii) (iv) Transfer function = (s+1/T)/ (s+1/αT) = (s+2.2).36s)/(1+0.

25]. figure(2). sys3=tf(num. den=[1 1 0]. num=[0 0 5. den=[.den). sys2=tf(num. bode(sys2).09 1].den). sys1=tf(num. bode(sys1). num=[. figure(3). den=[.09 1. figure(1). . margin(sys2).num=[0 0 15].09 1 0].den).4 15]. margin(sys1). margin(sys3).09 . bode(sys3).

Pm = 14. Pm = -180 deg (at Inf rad/sec) 0 Magnitude (dB) Phase (deg) -5 -10 -15 40 30 20 10 0 10 -1 10 0 10 1 10 2 10 3 Frequency (rad/sec) .81 rad/sec) 100 Magnitude (dB) Phase (deg) 50 0 -50 -90 -135 -180 10 -2 10 -1 10 0 10 1 10 2 Frequency (rad/sec) Bode Diagram Gm = Inf .Bode Diagram Gm = Inf dB (at Inf rad/sec) .7 deg (at 3.

Pm = 47.Bode Diagram Gm = Inf dB (at Inf rad/sec) .38 rad/sec) 100 50 Magnitude (dB) Phase (deg) 0 -50 -100 -90 -135 -180 10 -2 10 -1 10 0 10 1 10 2 10 3 Frequency (rad/sec) Result: The lead compensator for the given system is designed and bode plot is obtained using MATLAB program. .4 deg (at 5.

sys = tf(num. Kv = 80. velocity error constant.33s)(1+0.167s) . The output sys is transfer . G(s) = K/s(s+3)(s+6) For unity feedback system. den) creates a continuous time transfer function with numerator num(s) and denominator den(s). margin(sys) plots the open loop bode plot with gain and phase margin marked with a vertical line.lead compensator so that the phase margin of the given system is ≥ 35° and velocity error constant. function of object. Functions used: (i) tf(): This function creates or converts the transfer function. (ii) margin(): This function computes gain and phase margin and cross over frequencies.EXPERIMENT NO: 14 LAG-LEAD COMPENSATOR USING BODE PLOT Aim: To plot the bode plot for the unity feedback system whose open loop transfer function is given by G(s) = K/s(s+3)(s+6) and design a lag. Kv = lim s G(s) s→0 Given that Kv = 80 lim s K/(s(s+3)(s+6)) = 80 s→0 K = 1440 G(s) = 1440/s(s+3)(s+6) = 80/s(1+0.

8.0625 T = 1/(ωm √ α) (ii) (iii) (iv) (v) (vi) (vii) Transfer function of lead compensator = 0. Choose . . Take ε = 5° and choose a new gain cross over frequency.2s)/(1+40s)(1+0. β = 10 Agcl/20 = 16.33s)(1+0. ωgcn = 1.(i) Draw the bode plot for uncompensated system and determine the phase margin.5s)(1+0.0625(1+0. laglead compensator is designed. Determine the parameter β. (x) Draw the bode plot of compensated system and obtained the phase margin.014s) (viii) Transfer function of lag. Transfer function of lead compensator = (s+1/T)/ (s+1/αT).lead compensator = (1+2.014s) (1+0.014s) (ix) Open loop transfer function = 80(1+2. Transfer function = (s+1/T)/ (s+1/βT) = 16(1+2.167s). α = 1/β = 0.2s)/s(1+40s)(1+0.5s)/(1+40s). If the phase margin is less than the desired value. The new gain cross over frequency.5s)(1+0. ωgcl = 4 radian/sec.2s)/(1+40s)(1+0.

sys1=tf(num. figure(2).0154 1]. sys3=tf(num.7 rad/sec) 60 40 Magnitude (dB) Phase (deg) 20 0 -20 -40 -60 -90 -135 -180 -225 -270 10 -1 10 0 10 Frequency (rad/sec) 1 10 2 . margin(sys2).den). den=[0 0 0 44 216 80]. num=[. bode(sys2). figure(3).99 35. bode(sys3).7 1].num=[0 0 0 80].19 17.055 . bode(sys1).55 2. den=[.26 rad/sec) . figure(1). den=[.5 1 0].497 1 0]. sys2=tf(num. num=[.den).den).9 dB (at 4.8 deg (at 10.029 2. Pm = -44. Bode Diagram Gm = -18.539 35. margin(sys1). margin(sys3).

88 rad/sec) 200 150 Magnitude (dB) Phase (deg) 100 50 0 -50 -100 270 225 180 135 90 10 -3 10 -2 10 -1 10 0 10 1 10 2 10 3 10 4 Frequency (rad/sec) . Pm = -37 deg (at 3. Pm = -169 deg (at 319 rad/sec) 5 0 Magnitude (dB) Phase (deg) -5 -10 -15 -20 -25 90 45 0 -45 -90 10 -3 10 -2 10 -1 10 0 10 1 10 2 10 3 10 4 Frequency (rad/sec) Bode Diagram Gm = -22.Bode Diagram Gm = Inf .1 dB (at 16.4 rad/sec) .

Result: The lag-lead compensator for the given system is designed and bode plot is obtained using MATLAB program. .

Kv ≥ 10.plane grid of constant damping factors and natural frequency. ωn) [kk poles cl]: To locate the closed loop poles. ωn = 12 radian/sec.EXPERIMENT NO: 15 LEAD COMPENSATOR USING ROOT LOCUS Aim: To design a lead compensator using root locus for the unity feedback system whose open loop transfer function is given by G(s) = K/s(s+8) to meet the following specifications (i) Percentage peak overshoot = 9. Kv = dcgain(): To find the DC gain. rlocus (G): Root locus of transfer function G is obtained. den) creates a continuous time transfer function with numerator num (s) and denominator den (s). (ii) Natural frequency of oscillation. (iii) Velocity error constant. Functions used: (i) tf (): This function creates or converts the transfer function. sys = tf(num. Syntax: sgrid sgrid(z.5%. sgrid (): Generates an s. (ii) (iii) (iv) (v) . The output sys is transfer function of object.

jωn √(1.Determine the dominant pole. % Mp = 9.j 9. % Mp = e (– ξωπ/√(1.ξ2) ωn = 12 radian/sec.ξ2) * 100 ξ = 0.6 .6 Sd = -7.2 +/. Sd Sd = -ξωn +/.5%.

5 1 0.5 -2 0.12).5 0 -0. figure(2). beta=input('enter trial value of beta '). sgrid(.5 -8 -7 -6 -5 -4 Real Axis -3 -2 -1 0 Imaginary Axis . close all.clear all.0]).6 2 1.12).3]. [kk polesCL]=rlocfind(d*g).[1. sgrid(. kv=dcgain(gv) Root Locus 2.6. rlocus(d*g). gv=tf([1 0]. rlocus(g).6.[1 beta]).8.5 -1 -1. d=tf([1 7.5 0.1)*kk*d*g. figure(1).6 -2. g=tf(1.

1765 + 9.enter trial value of beta 9 Select a point in the graphics window selected_point = -7.9101 .5963i kv = 11.

.6 -10 -9 -8 -7 -6 -5 -4 -3 -2 -1 0 Imaginary Axis Real Axis Result: Designed the lead compensator using root locus for the given system.6 8 6 4 2 0 -2 -4 -6 -8 0.Root Locus 10 0.

scribd
/*********** DO NOT ALTER ANYTHING BELOW THIS LINE ! ************/ var s_code=s.t();if(s_code)document.write(s_code)//-->