Time response analysis, Frequency response analysis , Matlab
Size: 2.3 MB
Language: en
Added: Sep 26, 2024
Slides: 119 pages
Slide Content
Control Engineering with Matlab Application Dr.P.Anbarasan Department of EEE St.Joseph’s College of Engineering
Why Control ? Modern society have sophisticated control system which are crucial to their successful operation. Reason to build control system Power amplification Remote control Convenience of input form Compensation for disturbances Radar Antenna Robotic control Solar Panel
Control System A control system is an interconnection of components forming a system configuration that will provide a desired system response .
Open loop & Closed loop System
Modern Control System
System Modeling Modeling is a process of abstraction of a real system. The abstracted model may be logical or mathematical. A mathematical model consists of a collection of equations describing the behavior of the system. Differential equations relating to input and output Transfer function model State space model
State Space Analysis The state variable approach is a powerful technique for the analysis and design of control system
Modeling of mechanical system Mechanical Translational system Mass Spring Dash-pot Analogy Force Voltage Force Current Mechanical Rotational system Moment of Inertia Tortional spring Rotational dash-pot Analogy Torque Voltage Torque Current
Modeling of Train System Newton’s laws are used in the mathematical modeling of mechanical systems.
A = [ 0 1 ; -5 -2 ]; B = [ 0 ; 3 ]; C = [ 1 0 ]; D = 0; H = ss (A,B,C,D) Matlab Program-State space representation
Constructing State space model of DC motor R= 2.0 % Ohms L= 0.5 % Henrys Km = .015 % %torque constant Kb = .015 % emf constant Kf = 0.2 % Nms J= 0.02 % kg.m^2 A = [-R/L - Kb/L; Km/J - Kf /J] B = [1/L; 0]; C = [0 1]; D = [0]; sys_dc = ss (A,B,C,D)
Converting State space model of DC motor to Transfer function model State Space Model R= 2.0 % Ohms L= 0.5 % Henrys Km = .015 % %torque constant Kb = .015 % emf constant Kf = 0.2 % Nms J= 0.02 % kg.m^2 A = [-R/L -Kb/L; Km/J - Kf /J] B = [1/L; 0]; C = [0 1]; D = [0]; sys_dc = ss (A,B,C,D) Conversion from SS model to TF model sys_tf = tf(sys_dc)
Time response analysis? The variation of output with respect to time. To obtain the satisfactory performance of the system Output behavior of the system Stability of the system Accuracy of the system For example, aircraft is manufactured, it should made flight-worthy before it should takes off. The various disturbances occurs externally to the aircraft are made tested using various test signals to obtain satisfactory performance.
Time Response Behaviour How the system behaves for the given input and disturbances? For example If we consider a mercury in glass thermometer as a system with an input of temperature and output of the level of thermometer is suddenly immersed in hot water, i.e., given a step input? In residential heating system, input temperature is constant. But we cannot predict the main disturbance – outdoor temperature. If we use motor as system and feedback to move a work piece in an automatic machining operation, how will the output i.e., the displacement of the work piece vary with time when the input gradually increased with the time with the aim of gradually increasing the displacement of work piece?
Time Response Types Transient Response When the response of the system is changed from equilibrium it takes some time to settle down Steady State Response The part of response that remains constant after the transient have died out is steady state response
Standard Test Signals In most cases, the input signals to a control system are not known prior to design of control system To analyse the performance of control system it is excited with standard test signals These inputs are chosen because they capture many of the possible variations that can occur in an arbitrary input signal Step signal (Sudden change) Ramp signal (Constant velocity) Parabolic signal (Constant acceleration) Impulse signal (Sudden shock) Sinusoidal signal
r(t) =A; t ≥0 = 0; t<0 u(t) =1; t≥0 = 0; t<0 Step Signal Unit Step Ramp Signal r(t) =At; t ≥0 = 0; t<0 Unit ramp r(t) =t; t≥0 = 0; t<0 Parabolic Signal Impulse Signal δ (t) = ꝏ; t=0 = 0; t ≠0 r(t) =At 2 /2 ; t≥0 = 0 ; t<0 Unit parabolic r (t ) = t 2 /2; t ≥0 = 0; t<0 r (t ) =A; t=0 = 0; t≠0 Unit Impulse
Time Response of the system Transient response depends upon the system poles and not on the type of the system It is sufficient to analyze the transient response using a step input The steady state response depends on system dynamics and the input quantity
System Representation Transfer Function in pole zero form Transfer Function in time constant form
Order & Type The order of the system is given by the maximum power of s in the denominator transfer functions. The type number is specified for loop transfer function G(s)H(s). The number of poles lying at the origin decides the type number of the system.
Step Response of 1 st Order System Consider the following 1 st order system In order to find out the inverse Laplace of the above equation, we need to break it into partial fraction expansion Taking Inverse Laplace of above equation
Response of 1 st order system for Unit Step
Response of 1 st order system for different time constant Higher time constant leads to sluggish response Lower time constant leads to faster response
Response of 1 st order system for different gain
Impulse Response of 1 st Order System Consider the following 1 st order system t δ (t) 1 Taking Laplace Transform
Relation Between Step and impulse response The step response of the first order system is Differentiating c(t) with respect to t yields
Practical Determination of Transfer Function of 1 st Order Systems Often it is not possible or practical to obtain a system's transfer function analytically. Perhaps the system is closed, and the component parts are not easily identifiable. The system's step response can lead to a representation even though the inner construction is not known. With a step input, we can measure the time constant and the steady-state value, from which the transfer function can be calculated. If we can identify τ and K empirically we can obtain the transfer function of the system.
Practical Determination of Transfer Function of 1 st Order Systems For example, assume the unit step response given in figure. From the response, we can measure the time constant, that is, the time for the amplitude to reach 63% of its final value. Since the final value is about 0.72 the time constant is evaluated where the curve reaches 0.63 x 0.72 = 0.45, or about 0.13 second. τ=0.13s K=0.72 K is simply steady state value. Thus transfer function is obtained as:
Example 1 Find the time response for the closed transfer function
Second Order System We have discussed the affect of location of poles and zeros on the transient response of 1 st order systems. Compared to the simplicity of a first-order system, a second-order system exhibits a wide range of responses that must be analyzed and described. Varying a first-order system's parameter ( τ , K) simply changes the speed and offset of the response Whereas, changes in the parameters of a second-order system can change the form of the response. A second-order system can display characteristics much like a first-order system or, depending on component values, display damped or pure oscillations for its transient response .
Second Order System A general second-order system is characterized by the following transfer function. (E.g. Series RLC circuit, Position Servo mechanism) un-damped natural frequency of the second order system, which is the angular frequency at which system oscillate in the absence of damping. damping ratio , a dimensionless quantity describing the decay of oscillations during transient response.
Damping and its types Damping is an effect created in an oscillatory system that reduces, restricts or prevents the oscillations in the system. System can be classified as follows depending on damping effect Overdamped system: Transients in the system exponentially decays to steady state without any oscillations Critically damped system: Transients in the system exponentially decays to steady state without any oscillations in shortest possible time Underdamped system: System transient oscillate with the amplitude of oscillation gradually decreasing to zero Undamped system: System keeps on oscillating at its natural frequency without any decay in amplitude
Damping ratio on pole location
Step Response of 2 nd order system The partial fraction expansion of above equation is given as Step Response 42 Case 1: Underdamped system
Step Response of 2 nd order underdamped System Above equation can be written as Where , is the frequency of transient oscillations and is called damped natural frequency . The inverse Laplace transform of above equation can be obtained easily if C(s) is written in the following form: 43
Step Response of 2 nd order underdamped System 44
Step Response of 2 nd order underdamped System
Step Response of 2 nd order underdamped System
Step Response of 2 nd order System Here Case 2: Undamped system
Step Response of 2 nd order System Here Case 3: Critically damped system
Step Response of 2 nd order System Here Case 4: Over damped system
Step Response of 2 nd order Over damped System
Response of II nd order system for Unit Step
Response for the TF
Best Damping Ratio for a Control System Selection of damping ratio for industrial control applications requires a trade-off between relative stability and speed of response. Many system are designed for damping ratio in the range 0.4-0.7 ( peak overshoot of 25%) If allowed by rise time consideration, damping ratio close to 0.7 is the most obvious choice because it results in minimum normalized settling time For navigation purpose, the transient response is not primary performance criterion to optimize: minimum steady state error is the major objective. Therefore damping ratio is as small as possible (steady state error proportional to damping ratio)
Application of Damped System Overdamped system Push button water tap shut-off valves Automatic door closers Critically damped system Elevator mechanism Gun mechanism (Return to neutral position in shortest possible time) Underdamped system All string instruments, bells are under damped to make sound appealing Analog electrical and mechanical measuring instruments
Matlab Program-Step response of the system To find the step response of a system n=[25]; d=[1 4 25]; step ( n,d ) title('Step response of second order system'); grid
Matlab Program-Impulse response of the system To find the impulse response of a system n=[25]; d=[1 4 25]; impulse ( n,d ) title(‘Impulse response of second order system'); grid
Matlab Program-Ramp response of the system To find the ramp response of a system t=0:0.1:10 alpha=2 ramp= alpha*t % Your input signal model= tf ([25],[1 4 25]); % Your transfer function [ y,t ]= lsim ( model,ramp,t ) plot( t,y )
Matlab Simulink -Test inputs Ramp input from the step Parabolic input from the ramp
Transient Response Specifications 59 For 0< <1 and ω n > 0 , the 2 nd order system’s response due to a unit step input is as follows. Important timing characteristics: delay time, rise time, peak time, maximum overshoot, and settling time .
Delay Time 60 The delay ( t d ) time is the time required for the response to reach half the final value the very first time.
Rise Time 61 The rise time is the time required for the response to rise from 10% to 90%, 5% to 95%, or 0% to 100% of its final value. For underdamped second order systems, the 0% to 100% rise time is normally used. For overdamped systems, the 10% to 90% rise time is commonly used.For critically damped systems, the 5% to 95% is used 61
Peak Time 62 The peak time is the time required for the response to reach the first peak of the overshoot. 62 62
Maximum Overshoot 63 The maximum overshoot is the maximum peak value of the response curve measured from unity. If the final steady-state value of the response differs from unity, then it is common to use the maximum percent overshoot. It is defined by The amount of the maximum (percent) overshoot directly indicates the relative stability of the system.
Settling Time 64 The settling time is the time required for the response curve to reach and stay within a range about the final value of size specified by absolute percentage of the final value (usually 2% or 5%).
Time Response Specifications Delay Time Rise Time Peak Time Maximum Overshoot Settling Time
Steady State Error If the output of a control system at steady state does not exactly match with the input, the system is said to have steady state error Any physical control system inherently suffers steady-state error in response to certain types of inputs. A system may have no steady-state error to a step input, but the same system may exhibit nonzero steady-state error to a ramp input. The magnitudes of the steady-state errors due to these individual inputs are indicative of the goodness of the system.
Steady State Error Steady state error depends upon both input and type of the system As the type number is increased, accuracy is improved. However, increasing the type number aggravates the stability problem. A compromise between steady-state accuracy and relative stability is always necessary.
Steady State Error It is a value of error signal when t tends to infinity E(s) = Error Signal E(s) = R(s) - C(s) .H(s) Output signal C(s) = E(s).G(s) Substituting C(s) in E(s) E(s) = R(s) - E(s).G(s) H(s) Let e(t) error signal in time domain
Steady State Error Let e ss = steady state error The final value theorem states that Steady state error,
Static Error Constant Type-0 system will have constant steady state error when input is step signal Positional Error Constant Type-1 system will have constant steady state error when input is ramp signal Velocity Error Constant Type-2 system will have constant steady state error when input is parabolic signal Acceleration Error Constant
Steady state error for Step Input Where
To find K p Type-0 Type-1
Steady state error for Ramp Input Where
To find K v Type-0 Type-1
Type-2
Steady state error for Parabolic Input
Type-0 Type-1 Type-2 Type-3 To find K a
Type Steady State Error Unit Step Unit Ramp Unit Parabolic 1 2 3
Significance of Static Error Constants The static error constants are figures of merit of control systems. The higher the constants, the smaller the steady-state error. As the steady state error is inversely proportional to static error constant. Increasing the gain increases the static error constant. Thus in general increases the system gain decreases the steady state error.
Matlab response of Steady State Error for Type o system
Matlab response of Steady State Error for Type 1 system
Matlab response of Steady State Error for Type 2 system
Dynamic Error Coefficient The drawback in static error coefficient is that it does not show variation of error with time and input should be standard input. The dynamic error constant gives steady state error as a function of time. Using this method, the steady state error can be found for any type of input. The error signal is given by w here
Dynamic Error Coefficient The error signal is obtained by dynamic error coefficients, Steady state error C , C 1 , C 2 ,…… are called dynamic error coefficients
Integral performance Criteria Integral Squared Error (ISE) Integral Absolute Error (IAE) Integral Time-weighted Absolute Error (ITAE ) ISE integrates the square of the error over time. ISE will penalise large errors more than smaller ones (since the square of a large error will be much bigger ). Control systems specified to minimise ISE will tend to eliminate large errors quickly, but will tolerate small errors persisting for a long period of time. Often this leads to fast responses, but with considerable, low amplitude, oscillation. It is desirable to access the quality of control system by evaluating a performance index that can either be calculated or measured In the area of adaptive control, we can adjust certain parameters that will minimize the value of performance index, also known as Cost function
IAE integrates the absolute error over time. It doesn't add weight to any of the errors in a systems response. It tends to produce slower response than ISE optimal systems, but usually with less sustained oscillation. ITAE integrates the absolute error multiplied by the time over time. What this does is to weight errors which exist after a long time much more heavily than those at the start of the response. ITAE tuning produces systems which settle much more quickly than the other two tuning methods. The downside of this is that ITAE tuning also produces systems with sluggish initial response (necessary to avoid sustained oscillation). Integral performance Criteria
Increases in Type no. (or) Adding pole at origin reduces the Steady State Error
Addition of pole very close to imaginary axis, system becomes oscillatory
Adding a zero increases the peak-overshoot
Controller PROPORTIONAL PROPRTIONAL INTEGRAL PROPORTIONAL DERIVATIVE PROPORTIONAL INTEGRAL DERIVATIVE
Proportional Controller It produces an output signal which is proportional to error signal Its transfer function is represented by K p It amplifies the error signal and increase the loop gain of the system Steady state tracking accuracy Disturbance signal rejection Relative stability Drawback Produces constant steady state error Decreases the sensitivity of the system − actuating error signal e(t) reference input r(t) error detector feed back signal b(t) Controller output u(t) K p
PI Controller The transfer function of PI controller Let open loop TF is given by
There is a increase in order by one and introduces zero in the system The increase in order of the system results in less stable The type number of the open loop system increases by one ,this will reduces the steady state error Increase in zero increases the peak overshoot
PD Controller
Increase in zero and damping ratio Increase in zero increases the peak overshoot But Increase in damping ratio reduces the peak overshoot
PID Controller t u(t) proportional only PD control action PID control action Proportional controller stabilizes the gain but produces a steady state error The integral controller eliminates the steady state error The derivative controller reduces the overshoot of the response
With out controller System response using PD controller Using PD Controller Overshoot is very much reduced but steady state error is present
System response using PI controller With out controller Using PI Controller Steady error is reduced using PI controller but overshoot is present
System response using PID controller With out controller Using PID Controller Bothe Steady error and overshoot is reduced using PID controller
Effect of Increasing K p , K i and K d Parameter Rise Time Overshoot Settling Time Steady State Error K p Decreases Increases Small Change Decreases K i Decreases Increases Increases Eliminate K d Small Change Decreases Decreases None
Trial and Error Method Set integral and derivative terms to zero first and then increase the proportional gain until the output of the control loop oscillates at a constant rate. This increase of proportional gain should be in such that response the system becomes faster provided it should not make system unstable. Once the P-response is fast enough, set the integral term, so that the oscillations will be gradually reduced. Change this I-value until the steady state error is reduced, but it may increase overshoot. Once P and I parameters have been set to a desired values with minimal steady state error, increase the derivative gain until the system reacts quickly to its set point. Increasing derivative term decreases the overshoot of the controller response.
Ziegler Nichols Tuning Technique First Method
Ziegler Nichols Tuning Technique It is very similar to the trial and error method where integral and derivative terms are set to the zero, i.e., making Ti infinity and Td zero. Increase the proportional gain such that the output exhibits sustained oscillations. If the system does not produce sustained oscillations then this method cannot be applied. The gain at which sustained oscillations produced is called as critical gain (K cr ). Once the sustain oscillations are produced, set the values of Ti and Td as per the given table for P, PI and PID controllers based on critical gain and critical period. Second Method
Stability Analysis A system is stable if its output is bounded for any bounded input
Location of roots & its stability Roots on left half of s plane -Stable Roots on right half of s plane -Unstable
Location of roots & its stability Single pair of roots on imaginary axis-Marginally Stable Repeated roots on imaginary axis One or more non repeated roots on imaginary axis Unstable
Location of roots & its stability Single pole at origin - Stable Double pole at origin - Unstable
Fuel Cell based Converter Topologies Characteristics Conventional Interleaved SEPIC Peak Overshoot 27V 2.4V 19.7 Peak Time 0.025secs 0.018secs 0.057secs Settling Time 0.27secs 0.105secs 0.24secs Ripple Voltage 2.41V 2.5V 6.7V
PI Controller for Buck converter to regulate the voltage
FREQUENCY RESPONSE ANALYSIS It is the steady state response of a system when the input of the system is sinusoidal signal In TF T(s), s is replaced by j ω T(j ω ) is called sinusoidal TF
Frequency Response Plots Bode Plot Polar Plot Nyquist plot Nichols Plot M and N circles Nichols Chart
Bode Plot for state space system A=[0 1;-25 -4]; B=[0;25]; C=[1 0]; D=[0]; bode (A,B,C,D);
Matlab Program-Root Locus num=[48]; den = [ 1 6 8 0]; rlocus (num,den) grid
Reference Books S.No Title of the Book Author Publisher 1. Control Systems, Principles and Design M. Gopal, Tata McGraw Hill 2. Control System Engineering S.K.Bhattacharya Pearson 3. Control System Engineering Norman S Nise John wiley & Sons 4. Control System Engineering A.Nagoor Kani RPA Publications 5. Control System – Theory and Applications Smarajit Ghosh Pearson