Thursday, January 31, 2013

HW submission while D2L is down

Since it appears that problems with the D2L system could take more time, please use this alternative method to submit your work: send your files as email attachments to ecen5807@gmail.com. The due date for HW2 stays the same: Friday, February 1, 10am Mountain time.

error resolving equations

I was not able to successfully run the simulation from the first homework assignment. Matlab gave me an error that it was 'unable to resolve equation'. My state equations match those given in the solutions, and I followed the same set of steps as given in the step-by-step guide. If there is any suggestions that anyone can give on what might be giving this type of error I would appreciate it.

Laura

Wednesday, January 30, 2013

HW2 Prob 2A Stuck on Algebra

Hello:

I am having major trouble with the algebra for problem 2A.  There must be something that I am missing.

The voltage equation is fine and okay to put into the model.  However, when solving for i2, I cannot isolate (d'/d)*<i1> and when solving for i1, I cannot isolate (d/d')*<i2>.  Therefore I cannot solve the transformer.

The approach I am taking is to solve for Ion and then plug into the other current equation.  This leaves the currents multiplied by a factor of 1/(d+(tr/Ts)).  I can combine all of the terms by taking the common denominator, but this leaves a very messy numerator term which does not help much.

Also, if I add the two current equations, I can eliminate a lot of variables.  This results in <i1>+<i2> = Ion which is not much help.

Any assistance will be much appreciated!  Just some small hint will probably help me get to the next step so that I can proceed with the assignment.

If anyone is having similar problems, let's put our heads together to solve this.  I can email you what I have so far and then we can go from there.  I also am available for email, gchat, fb, or cell phone.

Thank you,
Alex

HW2 pblm 2

Do we have to use CCM5 model already present in switch.lib or can we create another model ? I havent got the model that is available in CCM5 my model looks different.

Tuesday, January 29, 2013

HW2: 1(b)

Is the idea that HW2: 1(b) requires us to write a MATLAB script (or modify Salient) to find the Load at which the pair RHP zeroes appear? Pretty simple by trial and error (esp w/i 10%), but want to clarify the the perceived requirement...anyone?

Netlist error?

I have the following CCM5 netlist (see below) as part of a larger schematic.  I get the following errors when I "run" it:
"Questionable use of curly braces in "b§er 1 1x v=v(5)*i(et)*{ron}+(1-v(5))*({et})*{rd}"
    Error: undefined symbol in: "[et]"
Questionable use of curly braces in "b§gd 4 3 i=({qr}/{ts})+({tr}/{ts})*i(et)+(1-v(5))*({et})"
    Error: undefined symbol in: "[et]"
Fatal Error: u1:gd:  -- Syntax Error --
Unknown symbol: et"

Any ideas why LtSpice does not like Et?

Also, is the CCM5 model found in switch.lib the correct model for HW2, problem 2?

Thank you,
CD

**********************************************************
* MODEL:    CCM5
* Application:    two switch PWM converters, includes
*         conduction loses due to Ron, VD, RD, Qr,
*        and tr for Ts
* Limits:    CCM only, no transformer
*
* Implementation:
* i1, v2 = independent variables
* v1, i2 = dependent variables
* <v1> = d(<i1>*Ron) + d'( <i1>*RD + VD + <v2>)
* <i2> = Qr/Ts + (tr/Ts)*<i1> + d'(<i1>)
**********************************************************

* Parameters:
*    Ron = transistor on-resistance, ohms
*    VD  = diode forward voltage drop, volts
*    RD  = diode on-resistance, ohms
*    Qr  = recovered charge, coulombs
*    tr  = recovery time, seconds
*    Ts  = sample frequency period, seconds
**********************************************************

* Nodes:
* 1: transistor positive (drain for an n-channel MOS)
* 2: transistor negative (source for an n-channel MOS)
* 3: diode cathode
* 4: diode anode
* 5: duty cycle control input
**********************************************************
.subckt CCM5 1  2  3  4  5
+params: Ron = 0.01 VD = 1 RD = 0 Qr = 0.00000015 tr =0.00000003 Ts = 0.000005
Er 1 1x value = {v(5)*i(Et)*Ron + (1-v(5))*(Et)*RD}
Et 1x 2 value = {(1-v(5))*(VD + v(3,4))}
Gd 4  3 value = {(Qr/Ts) + (tr/Ts)*i(Et)+(1-v(5))*(Et) }
.ends
**********************************************************

HW2 Prob 2A

Hello:

Since we will be solving this problem for a boost converter, can we use the equiv switch network for the Boost Converter (Fig 7.50b) for this problem?

Thanks,
Al

HW1 Solutions 7.16A

Good Morning:

On HW1 Solutions for problem 7.16A, why does Vd not appear in the equations or in the model?

Thanks,
Alex

Monday, January 28, 2013

HW 2 problem 2

I am having problems getting the ratio between the two currents to match the ratio between the two voltages (i.e. I can't use a transformer to model the equations I am coming up with).  Is it a requirement for the equivalent circuit we create to have a transformer, or can we use dependent voltage and current sources in our equivalent circuit?

fprintf function in MATLAB

Maybe somewhat trivial, but the fprintf function should print to the screen, correct?

Library function help

Can someone please describe how to use the library function "salient"?  I am new to MatLab and have NO IDEA how to use this script.  Am I supposed to edit the library file, or create a new script with salient('syncbuck_OL_LPfilter') embedded?  Do we ever edit the library files?  I've attempted to create a new script similar to when getSSM is used, but get the error below:


EDU>> salient_script
Undefined function 'zero' for input arguments of type 'char'.

Error in salient (line 6)
z = zero(sys);

Error in salient_script (line 11)
filter = salient('syncbuck_OL_LCfilter');

Any advice is appreciated.

Can't figure out how to use getSSM

I have had absolutely no success trying to use the getSSM library function.  I did see the "algebraic loop" error Colin mentioned - it was buried in a host of other errors.  I tried to back up and start simply: 
* I made sure I had linearization I/O points defined in the syncbuck_OL model and ran the bodeplotter on the model with success. 
* This left "ssm" defined in the workspace, so I ran >>salient(ssm) and got results consistent with the bode plot.
* However >>ssm = getSSM(syncbuck_OL) produced 3 error messages, probably all related to the first message:
"Error using linearize.ModelLinearizationParamMgr.getInstance (line 63)
Unexpected error. The getInstance method requires a model name argument."
Somehow a model name is missing??
Can anyone point me to some tutorial examples using this function?  This class is my first experience with MATLAB.  With such a fundamental level of failure, I have no idea where to start...

Algebraic loop issues with HW2 Problem 1

Does anyone else see algebraic loop issues with HW2 Problem 1 even with a gain block in the 'ig' path to invoke the Matlab algebraic loop solver?

I see issues if Rload is below a threshold.  No issues simulating with Rload above that threshold though.  Not sure if this has anything to do with the LHP -> RHP pole threshold or not.

Sunday, January 27, 2013

Regarding input filter design

Hi,
As it was discussed in Friday session, the filter design is done after control loop design. Then it is suggested to minimize the effect of the filter design in the overall design using the proposed theory.
I was wondering why the filter design is not performed before control loop design. This would provide the chance to design the control loop in such a way to compensate for both filter and converter working together. What is the disadvantage of that approach?
Regards,

Netlist to Schematic?

Is it possible to convert the netlists listed on the course website to schematics as displayed in appendix B?

If so then what are the steps?

If we are expected to build a schematic from scratch then how does one add the (I'm guessing) component CCMx?

Thank you,
CD


HW2 Prob 2

Hi All,

I am getting a little confused on how to combine models I guess... When I try and incorporate switching loss and conduction loss in the same model, I am getting what I feel as an incomplete model... since the switching loss shows up as a current, when I use i1 and i2 as my ports to incorporate them in the model, the Ron and Vd don't come into play for the large signal model... I get a model that is very similar to Fig 7.56, with the exception of some different d(t) and d'(t) values... I assume that the large signal model should also have Ron and Vd in it, am I incorrect in my thinking?

Friday, January 25, 2013

Simplification of circuit for 7.15b

For problem 7.15b, after setting dhat to zero, I end up with the same small-signal equivalent circuit as shown in Fig 7.53 of the text (without the conduction loss terms). I tried to use the transfer function derivation shown in section 8.2.1 of the text, but I ran into difficulty handling the fact that the inductor is connected through the bottom of the ideal transformer and it is not clear how to "push" this impedance through the transformer in order to simply the circuit. Any suggestions?

7.15 Transfer function derivation

Hello:

For problem 7.15:

What is the method used to derive Gvg from the average switch small signal model?  I am not able to derive a transfer function because in my model, the positive side of the inductor is connected to the negative side of the primary, the positive side (dot) of the secondary, and the tail of the arrow for the current source.

I am trying to manipulate this into the canonical form, and I am able to push the current source to the primary side.  However, it is not apparent on how to push the inductor to the secondary.

Does the transformer need to be split apart into two transformers?

Thanks,
Alex

Input Filter CCM-Buck: OL or CL?

Good Morning:

For problem 2 (input filter), a value of D = 0.36 is given.  On the schematic given in Figure 1,
there are no feedback control loop elements shown except for Vc and VM.  Are the other feedback elements assumed to be in the circuit and not pictured in Figure 1?

Does this mean that we are to simulate the sync-buck converter with input filter in "open-loop" form?

I understand that in order to get the transfer functions requested, we will have to use the averaged model (uncheck the "switching model?") box.  This would lead one to believe that the given information of D = 0.36 is irrelevant to the questions being asked.

Thanks,
Alex

Thursday, January 24, 2013

Problem 7.15

Hi All,
For Prob. 7.15, do I need to prove the two approaches give out the same equivalent circuit, or only to prove they have the same Gvg?
Thank you.
Zhiyuan

Mac OS 10.8 Mountain Lion Not Fully Compatible with Matlab

After upgrading to Mountain Lion over the break, Matlab starts, but can not compile functions in Simulink.  The following is Matlab's official compatibility policy:
http://www.mathworks.com/support/solutions/en/data/1-IXBVKD/index.html?solution=1-IXBVKD

Matlab is not guaranteed to work with Mountain Lion, except r2012b, which is not available as a student version.  There is no student version available that they guarantee to work with Mountain Lion.

They have FAQ's which supposedly help some users:
http://www.mathworks.com/matlabcentral/answers/56413-help-on-cpp-mex-file-compile-failed
http://www.mathworks.com/support/solutions/en/data/1-FR6LXJ/

Personally, I have reinstalled Mountain Lion, Matlab r2012a, and experimented with both Xquartz and Xcode 4.5.2 without success at Simulink compiling.

Has anyone else run across issues with Matlab on Mountain Lion and found a solution?

Frequency range setting for bode plots

I cleared most of the original post to unclutter the blog...  a summary:
1) re: original post -- I had bad state equations, but got no errors and had a very limited frequency range for a bode plot with no apparent data.  ...should have kept trouble-shooting before posting.
2) If you want to explicitly control the bode plot frequency range, the reply below has an example of one way to do that.
3) I'm still curious if anyone knows how Matlab/simulink determines the frequency range for our ac analyses.  (But it's not an urgent question.)
4) Many thanks to Dr. Maksimovic for extending the HW deadline and to whoever asked for the extension!

SRC PCs' Compiler Issue


Warning.

The ECEE SRC computers do not have the proper installation for Matlab/Simulink to compile Matlab/C functions.  Every time the SRC PCs are restarted (and booted from an image), they need to have .NET 4.0, then Windows SDK installed, which takes 10's of minutes to complete.  The following Matlab support page has links to both installs:
http://www.mathworks.com/support/compilers/R2012a/win64.html

After spending the time to complete the install on one SRC PC, I was able to perform HW#1, but do not know if all compiler issues are resolved.

The people in charge of the SRC images have been notified, but may not be able to do anything this semester, as they usually do not change images mid-semester to avoid deleting student information which may be present.

I do not know if this information applies to Matlab/Simulink as installed in other university labs.

OL vs CL plots

Whenever I plot the transfer functions of Gvg and output impedance, I get identical plots for the open loop and closed loop cases. This doesn't seem correct to me. All that I did was change the locations of the inputs and outputs. Is there something else that I need to do that I am overlooking?

Wednesday, January 23, 2013

Outpout Impedance Plot

Hello Everyone,

I have a question that someone may know better than me while doing the Bode plot for output impedance.  It seems that in Simulink you will get a plot of iLoad/vout if you plot it normally.  Do we plot 1/smm or smm (in the coding terms of BodePlotter_script.m) while using iLoad and Vout as the variables?

I would expect the output impedance to be in a "v" form like on Figure 8.65 in the text, but it looks inverted to me when I plot smm... any insights?

Zipped MatLab files OK?

Does anyone know if it will be acceptable to submit our MatLab scripts and models as a single zip file, perhaps one .zip per problem? 
(Will Dr. Maksimovic accept these and will D2L allow .zip file submissions?)

-Thanks!

Tuesday, January 22, 2013

Algebraic loop in syncbuck with input filter

After building the LC filter as described in homework 1, I tested it to make sure the simulation runs. To add the input filter to the syncbuck converter, I connected the output of the syncbuck, ig, to the input of the LC filter, ig. I also connected the output of the LC filter, vg, to the input vg of the syncbuck. When I try and simulate the system, I get an error stating that there is an algebraic loop present. Has anyone encountered this same error, and if so, any suggestions on how to fix it?

Saturday, January 19, 2013

Open loop check option

When we check "Open loop check options" for the output node in Simulink, what does the "Open loop check options" function do?
Because it is not checked in "syncbuck_OL" simulation, but it checked in "syncbuck_CL".

HW1 Prob 1 Clarification

Hi All,

In problem 1 it asks to plot the open loop and closed loop output impedance and "input-to-output (i.e. line-to-output)".

By "input-to-output (i.e. line-to-output)" I assume that means line to output transfer function, Gvg... AKA (v^/vg^), is this the correct interpretation?

Tuesday, January 15, 2013

Lecture Recording Download Link?

Is there a download link for the recorded lectures available for non-CAETE students?

Monday, January 14, 2013

MATLAB/Simulink & C Compiler Problems

Last weekend I thought I would try to run some of the models to make sure everything was working with my copy of MATLAB/Simulink (I am off campus and have the commercial version, R2012a).  I wanted to give those working with their own MATLAB/Simulink installations a heads up on problems I found.

When trying to run the model I received an error message from MATLAB about a C compiler not being found.  As instructed I ran the MATLAB  mex -setup command.  It did not find a compatible compiler even though I had the Visual C/C++ Express 2010 toolset installed.  It only wanted the Visual C/C++ Professional 2010 version or the version found in the Windows 7 Software Development Kit (SDK).

When I tried to install the Windows SDK the install kept failing.  It would find the Visual C/C++ Express 2010 compiler but it was a later build than the one in Windows SDK (4nnn versus 3mmm).  The Windows SDK said that it was not necessary to uninstall the later version of the compiler.

Liar.  I had to completely uninstall the Visual C/C++ Express 2010 kit before the Windows SDK would install.  I spent several hours of Web searching and debugging before getting the SDK to install.

Once the Windows SDK was installed the models from the class ran fine.

I have not tried to re-install the Visual C/C++ Express 2010 kit.  To me this a failure on Mathworks' part in that they do not recognize or cannot use a valid compiler.  It is also a failure on Microsoft's part in that the Windows SDK won't install with a later version of the compiler already installed.

I hope that my experience helps someone else avoid a frustrating, hair pulling experience trying to get the Simulink models to run.

Friday, January 4, 2013

Welcome to Spring 2013 ECEN5807 blog

I would like to encourage both on-campus and off-campus students to use this blog to exchange questions, comments, ideas, discussions or pointers related to class materials or homework assignments. I may use the blog to answer posted questions for the benefit of the class. However, I will  not moderate or edit your posts (except in cases of course policy violations), so you should not assume that any comments or ideas posted by other students here have been approved, verified for correctness, or endorsed by the instructor. 

The blog includes an archive of posts from Spring 2011. You are welcome to look through these old posts, but keep in mind that references to specific homework problems may be wrong since Spring 2013 assignments and lectures may be modified and updated.