ELE 111 Electrical Circuits Dr. Ahmed Nader Professor Faculty of Engineering, Galala University Spring 2024 1 Techniques of Circuit Analysis Nodal Analysis Mesh Analysis 2 Methods of Solving DC Circuits • Step by Step Simplification • Applying KCL and KVL • Nodal analysis and Mesh analysis 3 Simplification of Electrical Circuits • Resistors in series can be replaced by one resistor N Req Ri i 1 • Resistors in parallel can be replaced by one resistor N Geq Gi i 1 • Voltage sources in series can be replaced by one source N Veq Vi i 1 • Current sources in parallel can be replaced by one source N I eq I i i 1 4 Overview • With Ohm’s and Kirchhoff’s law established, they may now be applied to circuit analysis. • Two techniques will be presented in this chapter: Nodal analysis, which is based on Kirchhoff current law (KCL). Mesh analysis, which is based on Kirchhoff voltage law (KVL). • Any linear circuit can be analyzed using these two techniques. • The analysis will result in a set of simultaneous equations which may be solved by Cramer’s rule or computationally (using MATLAB for example). • Circuit simulator such as MultiSim or Pspice can be also 5 used. Nodal Analysis • Analyze circuits using node voltages as circuit variables. • Given a circuit with n nodes, without voltage sources, the nodal analysis is accomplished via three steps: 1. Select a node as the reference node. Assign voltages v1 , v2 , …., vn-1 to the remaining (n-1) nodes. Voltage of other nodes are referred to the reference node. 2. Apply KCL to each of the (n-1) non-reference nodes. Use Ohm’s law to express the branch currents in terms of node voltages. 3. Solve resulting (n-1) simultaneous equations to obtain the unknown node voltages (elimination, matrix, software, etc.) Note: Symbol of reference commonly referred to as the ground since its voltage is by default zero. 6 Reference Node • In shown circuit v1 is actually v10 (voltage difference between node 1 and node 0) • Note that voltage difference between node 1 & node 2 v12 = v10-v20 = v1-v2 3 1 2 v1 v2 7 Nodal Analysis • This circuit has a node that is designed as ground. We will use that as reference node (node 0). • The remaining two nodes are designed 1 and 2 and assigned voltages v1 and v2. • Applying KCL at each nonreference node • 𝐼1 = 𝐼2 + 𝑖1 + 𝑖2 • 𝐼2 + 𝑖2 = 𝑖3 8 Nodal Analysis • Applying Ohm’s law and keep in mind that current flows from high voltage to low voltage 𝑖1 = 𝑣1 −0 𝑅1 𝑖2 = 𝑣1 −𝑣2 𝑅2 𝑖3 = 𝑣2 −0 𝑅3 = 𝐺1 𝑣1 = 𝐺2 𝑣1 − 𝑣2 = 𝐺3 𝑣2 • 𝐼1 = 𝐼2 + 𝑖1 + 𝑖2 ⇒ 𝐼1 = 𝐼2 + 𝐺1 𝑣1 + 𝐺2 (𝑣1 − 𝑣2 ) • 𝐼2 + 𝑖2 = 𝑖3 ⇒ 𝐼2 + 𝐺2 𝑣1 − 𝑣2 = 𝐺3 𝑣2 • Rearranging the previous equations: 𝐼1 − 𝐼2 = 𝐺1 + 𝐺2 𝑣1 − 𝐺2 𝑣2 𝐼2 = −𝐺2 𝑣1 + (𝐺2 + 𝐺3 )𝑣2 9 Nodal Analysis By Inspection 𝐺1 + 𝐺2 −𝐺2 𝑣1 −𝐺2 𝐼1 − 𝐼2 = 𝑣 𝐼2 𝐺2 + 𝐺3 2 In general 𝐼𝑡1 𝐺11 −𝐺12 𝑣1 = 𝑣 𝐼𝑡2 −𝐺21 𝐺22 2 – Gkk is the summation of conductances connected to node k – Gkj = Gjk is the summation of conductances connecting nodes j and k – vk is the unknown voltage at node k – Itk summation of all independent current sources directly connected to node k with current entering the node treated as positive 10 Example V1 V2 11 Solving Linear Equations Obtain the currents 12 Nodal Analysis By Inspection 3/4 −1/4 𝑣1 5 • = −1/4 5/12 𝑣2 5 • Using Cramer's rule • 𝑣1 = Δ1 /Δ, 𝑣2 = Δ2 /Δ 3/4 • Δ= −1/4 −1/4 = 0.25 5/12 5 −1/4 • Δ1 = = 3.33 5 5/12 3/4 • Δ2 = −1/4 • 𝑣1 = Δ1 Δ 5 =5 5 = 13.33 V, 𝑣2 = Δ2 Δ = 20𝑉 13 Nodal Analysis By Inspection I • There is a faster way to construct a matrix for solving a circuit by nodal analysis. • It requires that all current sources within the circuit be independent. • In general, for a circuit with N non-reference nodes, the node-voltage equations may be written as: 14 Nodal Analysis By Inspection II • Each diagonal term on the conductance matrix is the sum of conductances connected to the node indicated by the matrix index. • The off diagonal terms, Gjk are the negative of the sum of all conductances connected between nodes j and k with j k. • The unknown voltages are denoted as vk • The sum of all independent current sources directly connected to node k are denoted as ik. Current entering the node are treated as positive and vice versa. • This matrix equation can be solved for the unknown values of the nodal voltages. 15 Example 4 −2 0 𝑣1 6 −2 7 −4 𝑣2 = −9 0 −4 6 𝑣3 6 Solution: v1 = 1.2V v2 = -0.6V v3 = 0.6V v4 = 0V V1 V2 V4 V3 16 What is a Circuit Simulator? • Circuit simulation is a process in which a model of an electronic circuit is created and analyzed using various software algorithms, which predict and verify the behavior and performance of the circuit. • Since fabrication of electronic circuits, especially integrated circuits (ICs), is expensive and time-consuming, it is faster and more costeffective to verify the behavior and performance of the circuit using a circuit simulator before fabrication. • There are different types of circuit simulators: • Analog simulators: solve accurate representations of the electronic circuits. They offer high accuracy and are commonly used to simulate small circuits. • Digital simulators: use functional representations of electronic circuits, typically described using hardware description languages (HDL). These offer the highest performance and capacity, but at relatively lower levels of accuracy. Simulate very large circuits. 17 Dependent Current Sources V1 V2 V3 18 Solution 19 Including Voltage Sources Depending on what nodes the source is connected to, approach varies. Between the reference node and a non-reference node: • Set the voltage at the non-reference node to the voltage of the source. • In the example circuit v1 = 10V. Between two non-reference nodes: • The two nodes form a supernode. 20 Nodal Analysis Including Independent Voltage Sources 21 Including Dependent Sources Use the nodal method to find the power dissipated in the 5Ω resistor in the circuit. 3 1 v1 2 4 v2 Node 1: Node 2: 22 Supernode • A super node is formed by enclosing a voltage source (dependent or independent) connected between two nonreference nodes and any elements connected in parallel with it. • Why? Nodal analysis requires applying KCL. The current through the voltage source cannot be known in advance (Ohm’s law does not apply). By lumping the nodes together, the current balance can still be described. 23 Supernode Analysis 𝑖1 + (−𝑖2 ) = 𝑖 𝑖 = 𝑖3 + (−𝑖4 ) 𝑖1 + (−𝑖2 ) = 𝑖3 + (−𝑖4 ) 𝑖1 + 𝑖4 = 𝑖2 + 𝑖3 In the example circuit node 2 and 3 form a supernode. The current balance can be expressed as: v1 v2 v1 v3 v2 0 v3 0 2 4 8 6 24 Example 25 Supernode 𝒗𝟏 = 𝟓𝟎𝑽 Node 2: Node 3: 26 Two Supernodes 27 Mesh (Loop) Analysis • Another general procedure for analyzing circuits is to use the mesh currents as the circuit variables. • Using mesh currents instead of element currents is convenient and reduces the number of equations that must be solved simultaneously. • Recall: A loop is a closed path with no node passed more than once. A mesh is a loop that does not contain any other loop within it (independent). 28 Mesh Analysis Steps • Identify independent loops • Assign current in each independent loop (Clockwise direction) to the n meshes (i1, i2,…, in) • Apply KVL to each of the n mesh currents & Use Ohm’s law to express the branch voltage in terms of loop current. • Solve the resulting n simultaneous equations to get the mesh currents. 29 Mesh Method 30 Example METHOD 2: Cramer’s Rule 31 Planar versus Non-Planar • Mesh analysis is limited in one aspect: It can only apply to circuits that can be rendered planar. • A planar circuit can be drawn in a plane such that there are no crossing branches. Non-Planar Circuit: The branch with the 13Ω resistor prevents the circuit from being drawn without crossing branches. 32 Planar Circuit Circuit can be redrawn to avoid crossing branches 33 Mesh Analysis By Inspection 𝑣1 (𝑅1 +𝑅3 ) −𝑅3 𝑖𝑎 = −𝑣 −𝑅3 (𝑅2 +𝑅3 ) 𝑖𝑏 2 34 Mesh Analysis by Inspection I • There is a similarly fast way to construct a matrix for solving a circuit by mesh analysis. • It requires that all voltage sources within the circuit be independent. • In general, for a circuit with N meshes, the mesh-current equations may be written as: • Each diagonal term on the resistance matrix is the sum of resistances in the mesh indicated by the matrix index. 35 Mesh Analysis by Inspection II • Rkk is the sum of all resistances in mesh k • The off diagonal terms, Rjk are the negative of the sum of all resistances in common with meshes j and k with j k. • The unknown mesh currents in the clockwise direction are denoted as ik. • The sum taken clockwise of all voltage sources in mesh k are denoted as vk. Voltage rises are treated as positive. • This matrix equation can be solved for the values of the unknown mesh currents. 36 Mesh Analysis with Dependent Sources Mesh 1: Mesh 2: Mesh 3: Constraint: 37 Example 𝑰𝟎 = 𝑰𝟏 − 𝑰𝟐 38 Mesh Analysis with Current Sources • The presence of a current source makes the mesh analysis simpler in that it reduces the number of equations. • If the current source is located on only one mesh, the current for that mesh is defined by the source. • For example: • Here, the current i2 is equal to −5A. 39 Supermesh • Similar to the case of nodal analysis where a voltage source is shared between two non-reference nodes, current sources (dependent or independent) that are shared by more than one mesh need special treatment. • The two meshes must be joined together, resulting in a supermesh. • The supermesh is constructed by merging the two meshes and excluding the shared source and any elements in series with it • A supermesh is required because mesh analysis uses KVL. • But the voltage across a current source cannot be known in advance. • Intersecting supermeshes in a circuit must be combined to for 40 a larger supermesh. Creating a Supermesh 𝟐𝟎 = 𝟔𝒊𝟏 + 𝟏𝟒𝒊𝟐 • In this example, a 6A current source is shared between mesh 1 and 2. • The supermesh is formed by merging the two meshes The current source and the 2Ω resistor in series with it are removed. • Apply KCL to the branch where the two meshes intersect 41 𝟔 = 𝒊𝟐 − 𝒊𝟏 Supermesh Example Mesh a: Mesh c: Supermesh Mesh b: Constraint: 42 Example (Continued) 43 Two Supermeshes 44 Nodal Vs. Mesh Analysis 45 Selecting an Appropriate Approach • In principle both the nodal analysis and mesh analysis are useful for any given circuit. • What then determines if one is going to be more efficient for solving a circuit problem? • There are two factors that dictate the best choice: The nature of the particular network. The second factor is the information required. 46 Nodal analysis if… • If the network contains: Current sources Many parallel connected elements Supernodes reduced unknowns A circuit with fewer nodes than meshes reduced equations • If node voltages are what is being solved for. • Non-planar circuits can only be solved using nodal analysis. 47 Mesh analysis when… • If the network contains: Voltage sources. Many series connected elements. Supermeshes reduced unknowns A circuit with fewer meshes than nodes reduced equations • If branch or mesh currents are what is being solved for. • Mesh analysis is the only suitable analysis for transistor circuits. 48