Formulation of Circuit Equations Lecture 2 Alessandra Nardi Thanks to Prof. Sangiovanni-Vincentelli and Prof. Newton.

Slides:



Advertisements
Similar presentations
FIRST AND SECOND-ORDER TRANSIENT CIRCUITS
Advertisements

Introduction to SPICE. History  SPICE stands for Simulation Program with Integrated Circuit Emphasis  In 1960 ECAP was developed by a team of IBM programmers.
Computer-Aided Verification of Electronic Circuits and Systems EE219A – Fall 2002 Professor: Prof. Alberto Sangiovanni-Vincentelli Instructor: Alessandra.
CSE245: Computer-Aided Circuit Simulation and Verification Lecture 1: Introduction and Formulation Winter 2013 Chung-Kuan Cheng.
CSE 245: Computer Aided Circuit Simulation and Verification Fall 2004, Nov Nonlinear Equation.
CSE245: Computer-Aided Circuit Simulation and Verification
CSE245: Computer-Aided Circuit Simulation and Verification Lecture Note 2: State Equations Prof. Chung-Kuan Cheng 1.
Chapter 3 Methods of Analysis
S. Ross and W. G. OldhamEECS 40 Fall 2002 Lecture 8 Copyright, Regents University of California 1 CIRCUIT ELEMENTS AND CIRCUIT ANALYSIS Last time: Terminology:
1 Nodal Analysis Discussion D2.3 September 2006 Chapter 2 Section 2-7.
Week2bEECS 42, Spring 2005Prof. White Find i 2, i 1 and i o Circuit w/ Dependent Source Example.
Lecture 4, Slide 1EE 40 Fall 2004Prof. White Lecture #4 OUTLINE Resistors in series –equivalent resistance –voltage-divider circuit –measuring current.
EECS 42, Spring 2005Week 3a1 Announcements New topics: Mesh (loop) method of circuit analysis Superposition method of circuit analysis Equivalent circuit.
CSE245: Computer-Aided Circuit Simulation and Verification Spring 2006 Chung-Kuan Cheng.
Methods of Analysis PSUT 1 Basic Nodal and Mesh Analysis Al-Qaralleh.
Lecture 5, Slide 1EECS40, Fall 2004Prof. White Notes 1.Be sure to take your completed Pre-Lab sheet to each lab! 2.Here are some useful books in the Engineering.
Lecture 281 Loop Analysis. Lecture 282 Loop Analysis Nodal analysis was developed by applying KCL at each non-reference node. Loop analysis is developed.
ECE 552 Numerical Circuit Analysis Chapter Two EQUATION FORMULATION Copyright © I. Hajj 2015 All rights reserved.
1 Chapter 3 Methods of Analysis Copyright © 2013 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
1 Mesh Analysis Discussion D2.4 Chapter 2 Section 2-8.
EE EE 616 Computer Aided Analysis of Electronic Networks Lecture 2 Instructor: Dr. J. A. Starzyk, Professor School of EECS Ohio University Athens,
Chapter 3 Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Kevin D. Donohue, University of Kentucky
1 Chapter 3 Methods of Analysis Copyright © 2013 The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Fundamentals of Electric Circuits Chapter 8
CSE245: Computer-Aided Circuit Simulation and Verification Lecture Note 2: State Equations Prof. Chung-Kuan Cheng.
E E 1205 Circuit Analysis Lecture 2 - Circuit Elements and Essential Laws.
FIRST ORDER TRANSIENT CIRCUITS
Electric Circuit Theory
Passive components and circuits - CCP Lecture 3 Introduction.
ARRDEKTA INSTITUTE OF TECHNOLOGY GUIDED BY. GUIDED BY. Prof.Y.B.Vaghela. Prof.Y.B.Vaghela. Asst.prof in electrical Asst.prof in electrical Department Department.
Lecture 2: Circuit Elements & Schematics Nilsson ENG17 (Sec. 2): Circuits I Spring April 3, 2014.
EE212 Passive AC Circuits Lecture Notes 2a EE 212.
1 Introduction to Model Order Reduction Thanks to Jacob White, Kin Sou, Deepak Ramaswamy, Michal Rewienski, and Karen Veroy I.2.a – Assembling Models from.
Series Circuits EE 2010: Fundamentals of Electric Circuits Mujahed AlDhaifallah.
Graph Theory, Topological Analysis ECE Graph Theory, Topological Analysis - Terms Topological Analysis: General, systematic, suited for CAD Graph:
EE2301: Basic Electronic Circuit Quick Summary of Last Lecture Block A Unit 1 Three Basic Laws EE2301: Block A Unit 21.
CSE 245: Computer Aided Circuit Simulation and Verification Instructor: Prof. Chung-Kuan Cheng Winter 2003 Lecture 1: Formulation.
Chapter 19 DC Circuits. Objective of the Lecture Explain Kirchhoff’s Current and Voltage Laws. Demonstrate how these laws can be used to find currents.
CSE245: Computer-Aided Circuit Simulation and Verification Lecture 1: Introduction and Formulation Spring 2008 Chung-Kuan Cheng.
First-Order RL&RC Circuits DONE BY AL-AHMED, UTHMAN SULTAN ELECTRICAL ENGINEERING DEPARTMENT.
CIRCUIT ANALYSIS USING LAPLACE TRANSFORM
Lecture 2: Circuit Elements and Series/Parallel Resistors Nilsson , ENG17 (Sec. 1): Circuits I Summer June 24, 2014.
Fundamentals of Electric Circuits
General Methods of Network Analysis Node Analysis Mesh Analysis Loop Analysis Cutset Analysis State variable Analysis Non linear and time varying network.
CSE245: Computer-Aided Circuit Simulation and Verification Lecture 1: Introduction and Formulation Spring 2010 Chung-Kuan Cheng.
EE EE 616 Computer Aided Analysis of Electronic Networks Lecture 2 Instructor: Dr. J. A. Starzyk, Professor School of EECS Ohio University Athens,
Grossman/Melkonian Chapter 3 Resistive Network Analysis.
Objective of Lecture Provide step-by-step instructions for nodal analysis, which is a method to calculate node voltages and currents that flow through.
Direct Methods for Linear Systems Lecture 3 Alessandra Nardi Thanks to Prof. Jacob White, Suvranu De, Deepak Ramaswamy, Michal Rewienski, and Karen Veroy.
Ch 3: Methods of Analysis
ECE 4991 Electrical and Electronic Circuits Chapter 3.
CSE245: Computer-Aided Circuit Simulation and Verification Lecture Note 2: State Equations Spring 2010 Prof. Chung-Kuan Cheng.
Chapter 1 Variables and Circuit Elements. SUB TOPICS : Introduction International System of Units, SI Current and Voltage Power and Energy Ideal Basic.
Lecture 4, Slide 1EECS40, Spring 2004Prof. Sanders Lecture #4 OUTLINE Resistors in series –equivalent resistance –voltage-divider circuit –measuring current.
Dan O. Popa, Intro to EE, Freshman Seminar, Spring 2015 EE 1105 : Introduction to EE Freshman Seminar Lecture 4: Circuit Analysis Node Analysis, Mesh Currents.
Chapter 3 Methods of Analysis
Chapter 3 Methods of Analysis
Discussion D2.3 Chapter 2 Section 2-7
5. Modeling of Electrical Systems
Introducing Supernodes!!!
Lecture 2 - Circuit Elements and Essential Laws
CSE245: Computer-Aided Circuit Simulation and Verification
Alexander-Sadiku Fundamentals of Electric Circuits
Lecture 2 Kirchhoff’s Laws & Circuit Analysis
Chapter 3 Methods of Analysis
Lecture 2 - Circuit Elements and Essential Laws
Circuit w/ Dependent Source Example
طرق تحليل الدوائر الكهربائية
Chapter 3 – Methods of Analysis
Presentation transcript:

Formulation of Circuit Equations Lecture 2 Alessandra Nardi Thanks to Prof. Sangiovanni-Vincentelli and Prof. Newton

219A: Course Overview Fundamentals of Circuit Simulation –Approximately 12 lectures Analog Circuits Simulation –Approximately 4 lectures Digital Systems Verification –Approximately 3 lectures Physical Issues Verification –Approximately 6 lectures E.g.: SPICE, HSPICE, PSPICE, SPECTRE, ELDO ….

SPICE history Prof. Pederson with “a cast of thousands” : Prof. Roher and a class project –CANCER: Computer Analysis of Nonlinear Circuits, Excluding Radiation : Prof. Roher and Nagel –Develop CANCER into a truly public-domain, general-purpose circuit simulator 1972: SPICE I released as public domain –SPICE: Simulation Program with Integrated Circuit Emphasis 1975: Cohen following Nagel research –SPICE 2A released as public domain 1976 SPICE 2D New MOS Models 1979 SPICE 2E Device Levels (R. Newton appears) 1980 SPICE 2G Pivoting (ASV appears)

Circuit Simulation Simulator: Solve dx/dt=f(x) numerically Input and setup Circuit Output Types of analysis: –DC Analysis –DC Transfer curves –Transient Analysis –AC Analysis, Noise, Distorsion, Sensitivity

Program Structure (a closer look) Numerical Techniques: – Formulation of circuit equations – Solution of linear equations – Solution of nonlinear equations – Solution of ordinary differential equations Input and setup Models Output

Formulation of Circuit Equations Circuit with B branches N nodes Simulator Set of equations Set of unknowns

Formulation of Circuit Equations Unknowns –B branch currents(i) –N node voltages(e) –B branch voltages(v) Equations –N+B Conservation Laws –B Constitutive Equations

Branch Constitutive Equations (BCE) Determined by the mathematical model of the electrical behavior of a component –Example: V=R·I In most of circuit simulators this mathematical model is expressed in terms of ideal elements

Ideal Elements: Reference Direction Branch voltages and currents are measured according to the associated reference directions –Also define a reference node (ground) + _ v i Two-terminal + _ v1v1 i1i1 Two-port i1i1 + _ v2v2 i2i2 i2i2

Branch Constitutive Equations (BCE) Ideal elements ElementBranch Eqn Resistorv = R·i Capacitori = C·dv/dt Inductorv = L·di/dt Voltage Sourcev = v s, i = ? Current Sourcei = i s, v = ? VCVSv s = A V · v c, i = ? VCCSi s = G T · v c, v = ? CCVSv s = R T · i c, i = ? CCCSi s = A I · i c, v = ?

Conservation Laws Determined by the topology of the circuit Kirchhoff’s Voltage Law (KVL): Every circuit node has a unique voltage with respect to the reference node. The voltage across a branch e b is equal to the difference between the positive and negative referenced voltages of the nodes on which it is incident Kirchhoff’s Current Law (KCL): The algebraic sum of all the currents flowing out of (or into) any circuit node is zero.

Equation Formulation - KCL R1R1 G2v3G2v3 R3R3 R4R4 I s5 A i = 0 Kirchhoff’s Current Law (KCL) N equations

Equation Formulation - KVL R1R1 G2v3G2v3 R3R3 R4R4 I s5 v - A T e = 0 Kirchhoff’s Voltage Law (KVL) B equations

Equation Formulation - BCE R1R1 G2v3G2v3 R3R3 R4R4 I s5 K v v + i = i s B equations

Equation Formulation Node-Branch Incidence Matrix j B 12iN12iN branches nodesnodes (+1, -1, 0) { A ij = +1 if node i is terminal + of branch j -1 if node i is terminal - of branch j 0 if node i is not connected to branch j PROPERTIES A is unimodular 2 nonzero entries in each column

Equation Assembly (Stamping Procedures) Different ways of combining Conservation Laws and Constitutive Equations –Sparse Table Analysis (STA) Brayton, Gustavson, Hachtel –Modified Nodal Analysis (MNA) McCalla, Nagel, Roher, Ruehli, Ho

Sparse Tableau Analysis (STA) 1.Write KCL: Ai=0 (N eqns) 2.Write KVL:v -A T e=0 (B eqns) 3.Write BCE:K i i + K v v=S(B eqns) N+2B eqns N+2B unknowns N = # nodes B = # branches Sparse Tableau

Sparse Tableau Analysis (STA) Advantages It can be applied to any circuit Eqns can be assembled directly from input data Coefficient Matrix is very sparse Problem Sophisticated programming techniques and data structures are required for time and memory efficiency

Nodal Analysis (NA) 1.Write KCL A·i=0 (N eqns, B unknowns) 2.Use BCE to relate branch currents to branch voltages i=f(v)(B unknowns  B unknowns) 3.Use KVL to relate branch voltages to node voltages 4.v=h(e)(B unknowns  N unknowns) Y n e=i ns N eqns N unknowns N = # nodes Nodal Matrix

Nodal Analysis - Example R3R R1R1 G2v3G2v3 R4R4 I s5 1.KCL:Ai=0 2.BCE:K v v + i = i s  i = i s - K v v  A K v v = A i s 3.KVL:v = A T e  A K v A T e = A i s Y n e = i ns

Nodal Analysis Example shows NA may be derived from STA Better: Y n may be obtained by direct inspection (stamping procedure) –Each element has an associated stamp –Y n is the composition of all the elements’ stamps

Spice input format: Rk N+ N- Rkvalue Nodal Analysis – Resistor “Stamp” N+ N- N+ N- N+ N- i RkRk KCL at node N+ KCL at node N- What if a resistor is connected to ground? …. Only contributes to the diagonal

Spice input format: Gk N+ N- NC+ NC- Gkvalue Nodal Analysis – VCCS “Stamp” NC+ NC- N+ N- N+ N- GkvcGkvc NC+ NC- +vc-+vc- KCL at node N+ KCL at node N-

Spice input format: Ik N+ N- Ikvalue Nodal Analysis – Current source “Stamp” N+ N- N+ N- N+ N- IkIk

Nodal Analysis (NA) Advantages Yn is often diagonally dominant and symmetric Eqns can be assembled directly from input data Yn has non-zero diagonal entries Yn is sparse (not as sparse as STA) and smaller than STA: NxN compared to (N+2B)x(N+2B) Limitations Conserved quantity must be a function of node variable –Cannot handle floating voltage sources, VCVS, CCCS, CCVS

Modified Nodal Analysis (MNA) i kl cannot be explicitly expressed in terms of node voltages  it has to be added as unknown (new column) e k and e l are not independent variables anymore  a constraint has to be added (new row) How do we deal with independent voltage sources? i kl kl +- E kl klkl

MNA – Voltage Source “Stamp” ikik N+N- +- EkEk Spice input format: ESk N+ N- Ekvalue N+ N- Branch k N+ N- i k RHS

Modified Nodal Analysis (MNA) How do we deal with independent voltage sources? Augmented nodal matrix Some branch currents In general:

MNA – General rules A branch current is always introduced as and additional variable for a voltage source or an inductor For current sources, resistors, conductors and capacitors, the branch current is introduced only if: –Any circuit element depends on that branch current –That branch current is requested as output

MNA – CCCS and CCVS “Stamp”

MNA – An example Step 1: Write KCL i1 + i2 + i3 = 0(1) -i3 + i4 - i5 - i6 = 0(2) i6 + i8 = 0(3) i7 – i8 = 0(4) G2v3G2v3 R4R4 I s5 R1R1 E S6 -+ R8R8 3 E7v3E7v3 -+ 4

MNA – An example Step 2: Use branch equations to eliminate as many branch currents as possible 1/R1·v1 + G2 ·v3 + 1/R3·v3 = 0(1) - 1/R3·v3 + 1/R4·v4 - i6 = is5(2) i6 + 1/R8·v8 = 0(3) i7 – 1/R8·v8 = 0(4) Step 3: Write down unused branch equations v6 = ES6(b6) v7 – E7·v3 = 0(b7)

MNA – An example Step 4: Use KVL to eliminate branch voltages from previous equations 1/R1·e1 + G2·(e1-e2) + 1/R3·(e1-e2) = 0(1) - 1/R3·(e1-e2) + 1/R4·e2 - i6 = is5(2) i6 + 1/R8·(e3-e4) = 0(3) i7 – 1/R8·(e3-e4) = 0(4) (e3-e2) = ES6(b6) e4 – E7·(e1-e2) = 0(b7)

MNA – An example

Modified Nodal Analysis (MNA) Advantages MNA can be applied to any circuit Eqns can be assembled directly from input data MNA matrix is close to Y n Limitations Sometimes we have zeros on the main diagonal and principle minors may also be singular.