ECE 201, Section 4Lecture 7Prof. Peter BermelJanuary 25, 2012Recap• Nodal analysis required for general circuits• Allows one to calculate unknown voltages and currents by applying KCL, Ohm’s law, and matrix algebra• Can calculate by hand or with software1/25/2012 ECE 201-4, Prof. BermelSoftware• Licensed software:– Best way to access MATLAB for free is whirlpool.ecn.purdue.edu. Requirements:• ECN account• ssh client (e.g., PuTTY)• X server (e.g., Cygwin, available on PULS).• Upload with WinSCP (http://winscp.net )• Free software:– Download Octave from http://octave.sourceforge.net/1/25/2012 ECE 201-4, Prof. BermelMATLAB Code for Example1/25/2012 ECE 201-4, Prof. BermelG4G2G3G1BCG5Va+ -I3I1I4I2I5IoAIoCalling from MATLAB1/25/2012 ECE 201-4, Prof. BermelG4G2G3G1BCG5Va+ -I3I1I4I2I5IoAIoCurrent Source Example1/25/2012 ECE 201-4, Prof. Bermel• Using KCL:ܫ= ܫଵ+ ܫଷ+ ܫସܫ= ܫସ+ ܫହܫଵ= ܫ௦= ܫଶܫହ= ܫଶ+ ܫଷ• Using Ohm’s Law:ܫ= ܫ௦+ ܩଷܸ− ܸ+ ܩସܸܫ= ܩସܸ+ ܩହܸܩହܸ= ܫ௦+ ܩଷ(ܸ− ܸ)G4G2G3G1BG5I3I1I4I5AIoI2IsCurrent Source Example• Combining & grouping terms:−ܩଷܸ+ ܩଷ+ ܩହܸ= ܫ௦ܩସܸ+ ܩହܸ= ܫ• In matrix form:−ܩଷܩଷ+ ܩହܩସܩହܸܸ=ܫ௦ܫ• Why doesn’t solution depend on G1or G2?1/25/2012 ECE 201-4, Prof. BermelMATLAB Code1/25/2012 ECE 201-4, Prof. BermelCalling the Code1/25/2012 ECE 201-4, Prof. BermelVoltage vs. Source Current1/25/2012 ECE 201-4, Prof. BermelControlled Sources1/25/2012 ECE 201-4, Prof. BermelG4G2G3G1BG5I3I1I4I5AIoI1RnI4- +gmVAB• Using KCL:ܫ= ܫଵ+ ܫଷ+ ܫସܫ= ܫସ+ ܫହܫଵ+ ܫଷ= ܫହ= ݃(ܸ−ܸ)• Using KVL:ܸ− ܸ= ܫଵܴଵ+ ܴଶ+ ܴܫସ• Using Ohm’s Law:ܸ− ܸ= (ܫ−ܫଷ− ܫସ)ܴଵଶ+ ܴܩସܸ− ܸܫ= ܩସܸ− ܸ− ܩହܸܸ݃−ܸ=−ܩହܸCControlled Sources• Rearranging:ܩଷସܴଵଶ+ ܴܩସ+ 1 ܸ− ܩଷܴଵଶ+ 1 ܸ+ ܴ− ܴଵଶܩସܸ= ܫܴଵଶܩସܸ− (ܩସ+ ܩହ)ܸ= ܫܸ݃− ܸ݃+ ܩହܸ= 01/25/2012 ECE 201-4, Prof. BermelMATLAB code1/25/2012 ECE 201-4, Prof. BermelCalling the code1/25/2012 ECE 201-4, Prof. BermelContour Plot of Va1/25/2012 ECE 201-4, Prof. BermelG=(0.5, G2, G3, 0.5, 0.8, 2.0, 1.0)Homework• HW #5 solution posting this morning• HW #6 due today by 4 pm at EE 325B• HW #7 due Friday: DeCarlo & Lin, Chapter 3:– Problem 2– Problem 6(a)1/25/2012 ECE 201-4, Prof.
View Full Document