% FILE: EETSepic.m % Based on extra-credit work by Riley Pack - ECEN 5807 Homework #3 % DESCRIPTION: This script shows how the getZDZN function can be used to % get Bode plots of ZD, ZN, and Gvd in a SEPIC converter % where capacitor C1 is considered extra element % In the Simulink model 'syncSEPIC_EET' C1 is replaced by a voltage test source. % % The results show impedance interactions, as well as Gvd_old, and Gvd % without and with damping clear all close all clc % Values used to plot Gvd for the Sepic once ZN, ZD, and Gold are known. C1 = 3.3e-6; Rd = 4.4; Cd = 10*C1; s = tf('s'); % % undamped extra-element impedance Z = 1/s/C1; % damping: series connection of Rd and Cd Zdamping = Rd + 1/s/Cd; % damped extra-element impendace Zdamped = Z*Zdamping/(Z+Zdamping); % Find the EET transfer functions for the SEPIC in CCM with voltage % injection at the port where C1 is connected. [ZD ZN Gopen Gshort] = getZDZN('syncSEPIC_EET', 'vc', 'SyncSEPIC/vout', 'v1', 'SyncSEPIC/i1'); % Plot the results. % Impedances figure % Bode plots bode(ZN,ZD,Z,Zdamped,{2*pi*10,2*pi*1e5}); % Set line widths to 2, and show legend linew = findobj(gcf,'Type','Line'); set(linew,'LineWidth',2); legend('Show','Location','West'); % Gvd transfer functions % Plot the damped Gvd when a series RC network is placed in parallel with % C1 to cause ZD and ZN to interact with a resistive element instead of a % capacitive element. figure % Gvd_old is Gvd with the extra element C1 open Gvd_old = Gopen; % Gvd is the transfer function with C1, but without damping Gvd = minreal(Gopen*(1+ZN/Z)/(1+ZD/Z)); % Gvd_damp is the transfer function with damping Gvd_damp = minreal(Gopen*(1+ZN/Zdamped)/(1+ZD/Zdamped)); % Bode plots bode(Gopen,Gvd,Gvd_damp,{2*pi*10,2*pi*1e5}); % Set line widths to 2, and show legend linew = findobj(gcf,'Type','Line'); set(linew,'LineWidth',2); legend('Show','Location','SouthWest');