Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Please answer ASAP and comment again if you are still working on the problem. Please box final answers and answer all portions of the question

Please answer ASAP and comment again if you are still working on the problem.

Please box final answers and answer all portions of the question correctly and you will be given thumbs up. See attached Matlab program below photo (Matlab code is titled Hart's Example 7.9)

image text in transcribed

Hart's Example 7.9 Matlab Code:

%Example 7.9 OF HART(page 314) %Bode plots of Plant Gp(s), controller G(s), and the loop transfer function of the Closed-loop system %Also, examines input regulation, and load regulation for both open and %closed-loop systems %This is a modified version of the old program clear all; close all;clc format short e %Bode plots of Switch-Filter-Load transfer function, Gp(s) D=0.5; Vs=10;Vp=3; f=100e3; L=100e-6; C=100e-6; R=5;rC=0.5; rL=0; Vp=3; num_Gp=Vs*[C*R*rC R]; % Numerator of Gp(s) (from class handout) % den=[L*C*(R+rC) rL*C*(R+rC)+L+rC*R*C R+rL] % poles=roots(den) % Gp=tf(num,den) Approx_den_Gp=Vp*[L*C*R rL*R*C+L+rC*R*C R]; % Approximate denominator of Gp(s) (from class handout) den_Gp=Approx_den_Gp; disp('Approximate Plant transfer function, Gp(s) ') Gp=tf(num_Gp,den_Gp) disp('Poles of approximate Plant transfer function, Gp(s) ') Open_Loop_Poles=roots(den_Gp) figure(1) bode(Gp);grid title('Bode plot of Open Loop Plant, Gp(s), in Example 7.9 (HART)') %Bode plots of the designed Compensator, G(s) C1=13.4e-9;C2=1.25e-9; R1=1000;R2=3880; wz=1/(R2*C1); wp=(C1+C2)/(R2*C1*C2); %wp=1/(R2*C2); num_G=-(1/(R1*C2))*[1 wz]; % Numerator of G(s) (from class handout) den_G=[1 wp 0]; % Approximate denominator of G(s) (from class handout) % den=[L*C*(R+rC) rL*C*(R+rC)+L+rC*R*C R+rL] % poles=roots(den) % Gp=tf(num,den) disp('Compensator transfer function, G(s) ') G=tf(num_G,den_G) figure(2) bode(G);grid title('Bode plot of Compensator, G(s), designed in Example 7.9 (HART)') %Bode plots of Closed-Loop System's Loop Gain, G(s)Gp(s) [num_GpG,den_GpG]=series(num_G,den_G,num_Gp,den_Gp); %Numerator of G(s)Gp(S) (from class handout) GpG=tf(num_GpG,den_GpG) figure(3) bode(GpG);grid title('Bode plot of Closed-Loop System Loop Gain, G(S)Gp(s), in Example 7.9 (HART)') % CLOSED-LOOP SENSITIVITY ANALYSIS % Analysis of input-output transfer function in open and closed loops %NOTE: First we must change the sign of G(s), because negative sign was used %only for design convenience. See HART Fig. 7.27 Simulation diagram on page 316 num_G=-num_G; num_A=(D*Vp/Vs)*num_Gp; den_A=den_Gp; disp('Open Loop Input-Output transfer function, A(s) ') A=tf(num_A,den_A) num_Acl=(D*Vp/Vs)*conv(num_Gp,den_G); temp=conv(num_G,num_Gp); den_Acl=conv(den_G,den_Gp)+[0 0 temp]; disp('Closed-loop Input-Output transfer function, Acl(s) = A(s)/[1+T(s)] ') Acl=tf(num_Acl,den_Acl) disp('Poles of Closed-loop Input-Output transfer function, Acl(s) ') Closed_Loop_Poles=roots(den_Acl) dt=1e-5; t=[0:dt:1.5e-3]; [Yo,To]=step(A,t); [Ycl,Tcl]=step(Acl,t); figure(4) subplot(211) plot(To,Yo) title('Unit step response of Open Loop Input-Output transfer function, A(s) ') axis([0 t(end) 0 0.8]) subplot(212) plot(Tcl,Ycl) title('Unit step response of Closed Loop Input-Output transfer function, Acl(s) ') axis([0 t(end) 0 0.8]) % [Yo,To]=step(A); % [Ycl,Tcl]=step(Acl); % figure(4) % subplot(211) % plot(To,Yo) % title('Unit step response of Open Loop Input-Output transfer function, A(s) ') % subplot(212) % plot(Tcl,Ycl) % title('Unit step response of Closed Loop Input-Output transfer function, Acl(s) ') % Analysis of Output Impedance function in open and closed loops num_Zo=(Vp/Vs)*conv([L 0],num_Gp); den_Zo=den_Gp; disp('Open Loop Output Impedance function, Zo(s) ') Zo=tf(num_Zo,den_Zo) temp1=conv(num_Gp,den_G); num_Zocl=(Vp/Vs)*conv([L 0],temp1); den_Zocl=den_Acl; disp('Closed-loop Output Impedance function, Zocl(s) = Zo(s)/[1+T(s)] ') Zocl=tf(num_Zocl,den_Zocl) disp('Poles of Closed-loop Output Impedance function, Zocl(s) ') Closed_Loop_Poles=roots(den_Zocl) dt=1e-5; t=[0:dt:1.5e-3]; [Yzo,Tzo]=step(Zo,t); [Yzocl,Tzocl]=step(Zocl,t); figure(5) subplot(211) plot(Tzo,Yzo) title('Unit step response of Open Loop Output Impedance function, Zo(s) ') axis([0 t(end) 0 0.8]) subplot(212) plot(Tzocl,Yzocl) title('Unit step response of Closed Loop Output Impedance function, Zocl(s) ') axis([0 t(end) 0 0.8]) %Analysis of Output Impedance function in open and closed loops (for interemittent load %changes) dt=1e-5; t=[0:dt:1.5e-3]; u=zeros(size(t)); u(41:50)=0.3*ones(1,10); %u(91:100)=-0.2*ones(1,10); u(111:120)=-0.2*ones(1,10); [Yzo,Tzo]=lsim(Zo,u,t); [Yzocl,Tzocl]=lsim(Zocl,u,t); % figure(6) % subplot(311) % plot(t,u) % title('Intermittent load current changes, io(t) ') % subplot(312) % plot(Tzo,Yzo) % title('Intermittent Load Change Response of Open Loop Output Impedance function, Zo(s) ') % axis([0 t(end) -0.3 0.3]) % subplot(313) % plot(Tzocl,Yzocl) % title('Intermittent Load Change response of Closed Loop Output Impedance function, Zocl(s) ') % axis([0 t(end) -0.3 0.3]) Vo=D*Vs; Io=Vo/R; io=Io+u; vo_open=Vo+Yzo; vo_closed=Vo+Yzocl; figure(6) subplot(311) plot(t,u) title('Intermittent load current changes, io(t) ') subplot(312) plot(Tzo,vo_open) title('Ouput voltage of Open Loop system due to intermittent load changes ') axis([0 t(end) 4.5 5.5]) subplot(313) plot(Tzocl,vo_closed) title('Ouput voltage of Closed Loop system due to intermittent load changes ') axis([0 t(end) 4.5 5.5]) %Analysis of Input-Output Transfer function in open and closed loops (for %interemittent changes in input) dt=1e-5; t=[0:dt:1.5e-3]; u=zeros(size(t)); u(31:40)=0.5*ones(1,10); %u(91:100)=-0.2*ones(1,10); u(101:110)=-0.4*ones(1,10); [Yo,To]=lsim(A,u,t); [Ycl,Tcl]=lsim(Acl,u,t); vs=Vs+u; vo_open=Vo+Yo; vo_closed=Vo+Ycl; figure(7) subplot(311) plot(t,vs) title('Intermittent input voltage changes, Vs(t) ') axis([0 t(end) 9 11]) subplot(312) plot(To,vo_open) title('Ouput voltage of Open Loop system due to intermittent input-voltage changes ') axis([0 t(end) 4.8 5.25]) subplot(313) plot(Tcl,vo_closed) title('Ouput voltage of Closed Loop system due to Intermittent input-voltage changes ') axis([0 t(end) 4.8 5.25]) % END OF HART'S EXAMPLE 7.9 
*3. Consider a buck converter, operating in CCM, with the following parameters: L = 200 uH, C = 200 pF, = 0.12, rc = 0.42, f= 120 KHz, Vs = 20 V, V rep = 8 V, P, = 13 W, Vp = 3 V. The duty cycle is adjusted continuously to regulate the output voltage a) Using Matlab, make a Bode plot of the open loop transfer function. b) Design a Type 2 compensator similar to Hart's Example 7.9 to give a gain crossover frequency, fco = 12 KHz, and a phase margin of 500 c) Attach Bode plots of the compensated error amplifier and the overall closed-loop transfer function. Does your design meet the goals? d) Using the attached/posted Matlab program, compare the input regulation characteristics of the open and closed loop systems designed above by injecting short positiveegative fluctuations of Vs of amplitude (5%-10%) of V.. e) Using the attached/posted Matlab program, compare the load regulation characteristics of the open and closed loop systems designed above by injecting short positiveegative fluctuations of I, of amplitude (10% - 20%) of I.. *3. Consider a buck converter, operating in CCM, with the following parameters: L = 200 uH, C = 200 pF, = 0.12, rc = 0.42, f= 120 KHz, Vs = 20 V, V rep = 8 V, P, = 13 W, Vp = 3 V. The duty cycle is adjusted continuously to regulate the output voltage a) Using Matlab, make a Bode plot of the open loop transfer function. b) Design a Type 2 compensator similar to Hart's Example 7.9 to give a gain crossover frequency, fco = 12 KHz, and a phase margin of 500 c) Attach Bode plots of the compensated error amplifier and the overall closed-loop transfer function. Does your design meet the goals? d) Using the attached/posted Matlab program, compare the input regulation characteristics of the open and closed loop systems designed above by injecting short positiveegative fluctuations of Vs of amplitude (5%-10%) of V.. e) Using the attached/posted Matlab program, compare the load regulation characteristics of the open and closed loop systems designed above by injecting short positiveegative fluctuations of I, of amplitude (10% - 20%) of

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Introductory Relational Database Design For Business With Microsoft Access

Authors: Jonathan Eckstein, Bonnie R. Schultz

1st Edition

1119329418, 978-1119329411

Students also viewed these Databases questions

Question

Convert from spherical to rectangular coordinates. (3,0,

Answered: 1 week ago

Question

=+ Who will be their chief spokesperson?

Answered: 1 week ago

Question

How do Excel Pivot Tables handle data from non OLAP databases?

Answered: 1 week ago