# Real Analog: Chapter 3

Chapter 3 Materials

## 3. Introduction and Chapter Objectives

In Chapters 1 & 2, we introduced several tools in circuit analysis:

• Ohm's Law
• Kirchhoff's laws
• Circuit reduction

Circuit reduction, it should be noted, is not fundamentally different from direct application of Ohm's and Kirchhoff's laws - it is simply a convenient re-statement of these laws for specific combinations of circuit elements.

In Chapter 1, we saw that direct application of Ohm's law and Kirchhoff's laws to a specific circuit using the exhaustive method often results in a large number of unknowns - even if the circuit is relatively simple. A correspondingly large number of equations must be solved to determine these unknowns. Circuit reduction allows us, in some cases, to simplify the circuit to reduce the number of unknowns in the system. Unfortunately, not all circuits are reducible and even analysis of circuits that are reducible depends upon the engineer “noticing” certain resistance combinations and combining them appropriately.

In cases where circuit reduction is not feasible, approaches are still available to reduce the total number of unknowns in the system. Nodal analysis and mesh analysis are two of these. Nodal and mesh analysis approaches still rely upon application of Ohm's law and Kirchhoff's laws - we are just applying these laws in a very specific way in order to simplify the analysis of the circuit. One attractive aspect of nodal and mesh analysis is that the approaches are relatively rigorous - we are assured of identifying a reduced set of variables, if we apply the analysis rules correctly. Nodal and mesh analysis are also more general than circuit reduction methods - virtually any circuit can be analyzed using nodal or mesh analysis.

Since nodal and mesh analysis approaches are fairly closely related, section 3.1 introduces the basic ideas and terminology associated with both approaches. Section 3.2 provides details of nodal analysis, and mesh analysis is presented in section 3.3.

### After Completing this Chapter, You Should be Able to:

• Use nodal analysis techniques to analyze electrical circuits
• Use mesh analysis techniques to analyze electrical circuits

## 3.1 Introduction and Terminology

As noted in the introduction, both nodal and mesh analysis involve identification of a “minimum” number of unknowns, which completely describe the circuit behavior. That is, the unknowns themselves may not directly provide the parameter of interest, but any voltage or current in the circuit can be determined from these unknowns. In nodal analysis, the unknowns are the node voltages. In mesh analysis, the unknowns are the mesh currents. We introduce the concept of these unknowns via an example below.

Consider the circuit shown in Fig. 3.1(a). The circuit nodes are labeled in Fig. 3.1(a), for later convenience. The circuit is not readily analyzed by circuit reduction methods. If the exhaustive approach toward applying KCL and KVL is taken, the circuit has 10 unknowns (the voltages and currents of each of the five resistors), as shown in Fig. 3.1(b). Ten circuit equations must be written to solve for the ten unknowns. Nodal analysis and mesh analysis provide approaches for defining a reduced number of unknowns and solving for these unknowns. If desired, any other desired circuit parameters can subsequently be determined from the reduced set of unknowns.

In nodal analysis, the unknowns will be node voltages. Node voltages, in this context, are the independent voltages in the circuit. It will be seen later that the circuit of Fig. 3.1 contains only two independent voltages - the voltages at nodes b and c1). Only two equations need be written and solved to determine these voltages! Any other circuit parameters can be determined from these two voltages.

### Basic Idea

In nodal analysis, Kirchhoff's current law is written at each independent voltage node; Ohm's law is used to write the currents in terms of the node voltages in the circuit.

In mesh analysis, the unknowns will be mesh currents. Mesh currents are defined only for planar circuits; planar circuits are circuits which can be drawn in a single plane such that no elements overlap one another. When a circuit is drawn in a single plane, the circuit will be divided into a number of distinct areas; the boundary of each area is a mesh of the circuit. A mesh current is the current flowing around a mesh of the circuit. The circuit of Fig. 3.1 has three meshes:

1. The mesh bounded by $V_s$, node a, and node d
2. The mesh bounded by node a, node c, and node b
3. The mesh bounded by node b, node c, and node d

These three meshes are illustrated schematically in Fig. 3.2. Thus, in a mesh analysis of the circuit of Fig. 3.1, three equations must be solved in three unknowns (the mesh currents). Any other desired circuit parameters can be determined from the mesh currents.

### Basic Idea

In mesh analysis, Kirchhoff's voltage law is written around each mesh loop; Ohm's law is used to write the voltage in terms of the mesh currents in the circuit. Since KVL is written around closed loops in the circuit, mesh analysis is sometimes known as loop analysis.

### Section Summary

• In nodal analysis:
• Unknowns in the analysis are called the node voltages
• Node voltages are the voltages at the independent nodes in the circuit
• Two nodes connected by a voltage source are not independent. The voltage source constrains the voltages at the nodes relative to one another. A node which is not independent is also called dependent.
• In mesh analysis:
• Unknowns in the analysis are called mesh currents.
• Mesh currents are defined as flowing through the circuit elements which form the perimeter of the circuit meshes. A mesh is any enclosed, non-overlapping region in the circuit (when the circuit schematic is drawn on a piece of paper).

### Exercises

1. The circuit below has three nodes, A, B, and C. Which two nodes are dependent? Why?

2. Identify meshes in the circuit below.

## 3.2 Nodal Analysis

As noted in section 3.1, in nodal analysis we will define a set of node voltages and use Ohm's law to write Kirchhoff's current law in terms of these voltages. The resulting set of equations can be solved to determine the node voltages; and other circuit parameters (e.g. currents) can be determined from these voltages.

The steps used in nodal analysis are provided below. The steps are illustrated in terms of the circuit of Fig. 3.3.

### Step 1: Define Reference Voltage

One node will be arbitrarily as a reference node or datum node. The voltages of all other nodes in the circuit will be defined to be relative to the voltage of this node. Thus, for convenience, it will be assumed that the reference node voltage is zero volts. It should be emphasized that this definition is arbitrary - since voltages are actually potential differences, choosing the reference voltage as zero is primarily a convenience.

For our example circuit, we will choose node d as our reference node and define the voltage at this node to be 0V, as shown in Fig. 3.4.

### Step 2: Determine Independent Nodes

We now define the voltages at the independent nodes. These voltages will be the unknowns in our circuit equations. In order to define independent nodes:

• “Short-circuit” all voltage sources
• “Open-circuit” all current sources

After removal of the sources, the remaining nodes (with the exception of the reference node) are defined as independent nodes (the nodes which were removed in this process are dependent nodes. The voltages at these nodes are sometimes said to be constrained). Label the voltages at these nodes - they are the unknowns for which we will solve.

For our example circuit of Fig. 1, removal of the voltage source (replacing it with a short circuit) results in nodes remaining only at nodes b and c. This is illustrated in Fig. 3.5.

### Step 3: Replace Sources in the Circuit and Identify Constrained Voltages

With the independent voltages defined as in Step 2, replace the sources and define the voltages at the dependent nodes in terms of the independent voltages and the known voltage difference.

For our example, the voltage at node a can be written as a known voltage $V_s$ above the reference voltage, as shown in Fig. 3.6.

### Step 4: Applying KCL at Independent Nodes

Define currents and write Kirchhoff's current law at all independent nodes. Currents for our example are shown in Fig. 3.7 below. The defined currents include the assumed direction of positive current - this defines the sign convention for our currents. To avoid confusion, these currents are defined consistently with those shown in Fig. 3.1(a). The resulting equations are (assuming that currents leaving the node are defined as positive):

Node b:

$$-i_1+i_3+i_4=0 \qquad (Eq. 3.1)$$

Node c:

$$-i_2-i_3+i_5=0 \qquad (Eq. 3.2)$$

### Step 5: Use Ohm's Law to Write the Equations From Step 4 in Terms of Voltages

The currents defined in Step 4 can be written in terms of the node voltages defined previously. For example, from Fig. 3.7: $i_1= \frac{V_S-V-b}{R_1}$, $i_3=\frac{V_b-V_c}{R_3}$, and $i_4=\frac{V_b-0}{R_4}$, so equation (3.1) can be written as:

$$-\frac{V_s-V_b}{R_1} + \frac{V_b-V_c}{R_3} + \frac{V_b-0}{R_4} = 0$$

So the KCL equation for node b becomes:

$$\left( \frac{1}{R_1} + \frac{1}{R_3} + \frac{1}{R_4} \right) V_b - \frac{1}{R_3} V_c = \frac{1}{R_1}V_S \qquad (Eq. 3.3)$$

Likewise, the KCL equation for node c can be written as:

$$-\frac{1}{R_3} V_b + \left( \frac{1}{R_3} + \frac{1}{R_2} + \frac{1}{R_5} \right) V_c = \frac{1}{R_2} V_S \qquad (Eq. 3.4)$$

### Double-checking Results

If the circuit being analyzed contains only independent sources, and the sign convention used in KCL equations is the same as used above (currents leaving nodes are assumed positive), the equations written at each node will have the following form:

• The term multiplying the voltage at that node will be the sum of the conductances connected to that node. For the example above, the term multiplying $V_b$ in the equation for node b is $\frac{1}{R_1} + \frac{1}{R_3} + \frac{1}{R_4}$ while the term multiplying $V_c$ in the equation for node c is $\frac{1}{R_3} + \frac{1}{R_2} + \frac{1}{R_5}$.
• The term multiplying the voltages adjacent to the node will be the negative of the conductance connecting the two nodes. For the example above, the term multiplying $V_c$ in the equation for node b is $-\frac{1}{R_3}$, and the term multiplying $V_b$ in the equation for node c is $-\frac{1}{R_3}$.

If the circuit contains dependent sources, or a different sign convention is used when writing the KCL equations, the resulting equations will not necessarily have the above form.

### Step 6: Solve the System of Equations Resulting From Step 5

Step 5 will always result in N equations in N unknowns, where N is the number of independent nodes identified in Step 2. These equations can be solved for the independent voltages. Any other desired circuit parameters can be determined from these voltages.

The example below illustrates the above approach.

### Example 3.1

Find the voltage V for the circuit shown below:

Steps 1, 2, and 3:Choosing the reference voltage as shown below, identifying voltages at dependent nodes, and defining voltages $V_A$ and $V_B$ at the independent nodes results in the circuit schematic shown below:

Steps 4 and 5: Writing KCL at nodes A and B and converting currents to voltages using Ohm's law results in the following two equations:

Node A:

$$\frac{V_A - 6}{2} + \frac{V_A - V_B}{2} + \frac{V_A - V_B}{1} = 0 \Rightarrow \left( \frac{1}{2} + \frac{1}{2} + \frac{1}{1} \right) V_A - V_B = 3 \Rightarrow 2V_A - V_B = 3$$

Node B:

$$\frac{V_B-V_A}{1} + \frac{V_B-0}{0.5} + 16 = 0 \Rightarrow \left( \frac{1}{1} + \frac{1}{0.5} \right) V_B - V_A = -16 \Rightarrow 3V_B - V_A = 16$$

Step 6: Solving the above equations results in $V_A=5V$ and $V_B=7V$. The voltage $V$ is:

$$V=V_A - V_B = -2V$$

1. Steps 4 and 5 (applying KCL at each independent node and using Ohm's law to write these equations in terms of voltages) have been combined into a single step. This approach is fairly common, and can provide a significant savings in time.

2. There may be a perceived inconsistency between the two node equations, in the assumption of positive current direction in the 1Ω resistor. In the equation for node A, the current is apparently assumed to be positive from node A to node B, as shown below:

This leads to the corresponding term in the equation for node A becoming: $\frac{V_A - V_B}{1}$. In the equation for node B, however, the positive current direction appears to be from node B to node A, as shown below:

This definition leads to the corresponding term in the equation for node B becoming: $\frac{V_B - V_A}{1}$.

The above inconsistency in sign is, however, insignificant. Suppose that we had assumed (consistently with the equation for node A) that the direction of positive current for the node B equation is from Node A to B. Then, the corresponding term in the equation for node B would have been: $-\frac{V_A - V_B}{1}$ (note that a negative sign has been applied to this term to accommodate our assumption that currents flowing into nodes are negative). This is equal to $\frac{V_B - V_A}{1}$, which is exactly what our original result was.

3. The current source appears directly in the nodal equations.

### Note

When we write nodal equations in these chapters, we will generally assume that any unknown currents are flowing away from the node for which we are writing the equation, regardless of any previous assumptions we have made for the direction of that current. The signs will work out, as long as we are consistent in our sign convention between assumed voltage polarity and current direction and our sign convention relative to positive currents flowing out of nodes.

The sign applied to currents induced by current sources must be consistent with the current direction assigned by the source.

### Supernodes

In the previous examples, we identified dependent nodes and determined constrained voltages. Kirchhoff's current law was then only written at independent nodes. Many readers find this somewhat confusing, especially if the dependent voltages are not relative to the reference voltage. We will thus discuss these steps in more detail here in the context of an example, introducing the concept of a supernode in the process.

Example: for the circuit below, determine the voltage difference, V, across the 2mA source.

### Step 1: define Reference Node

Choose reference node (somewhat arbitrarily) as shown below; label the reference node voltage, $V_R$, as zero volts.

### Step 2: Define Independent Nodes

Short circuit voltage sources, open circuit current sources as shown below and identify independent nodes/voltages. For our example, this result in only one independent voltage, labeled as $V_A$ below.

### Step 3: Replace Sources and Label any Known Voltages

The known voltages are written in terms of node voltages identified above. There is some ambiguity in this step. For example, either of the representations below will work equally well - either side of the voltage source can be chosen as the node voltage, and the voltage on the other side of the source written in terms of this node voltage. Make sure, however, that the correct polarity of the voltage source is preserved. In our example, the left side of the source has a potential that is three volts higher than the potential of the right side of the source. This fact is represented correctly by both of the choices below.

### Step 4: Apply KCL at the Independent Nodes

It is this step that sometimes causes confusion among readers, particularly when voltage sources are present in the circuit. Conceptually, it is possible to think of two nodes connected by an ideal voltage source as forming a single supernode (some authors use the term generalized node rather than supernode). A node is rigorously defined as having a single, unique voltage. However, although the two nodes connected by a voltage source do not share the same voltage, they are not entirely independent - the two voltages are constrained by one another. This allows us to simplify the analysis somewhat.

For our example, we will arbitrarily choose the circuit to the left above to illustrate this approach. The supernode is chosen to include the voltage source and both nodes to which it is connected, as shown below. We define two currents leaving the supernode, $i_1$ and $i_2$, as shown. KCL, applied at the supernode, results in:

$$-2mA + i_1 + i_2 = 0$$

As before, currents leaving the node are assumed to be positive. This approach allows us to account for the current flowing through the voltage source without ever explicitly solving for it.

### Step 5: Use Ohm's Law to Write the KCL Equations in Terms of Voltages

For the single KCL equation written above, this results in:

$$-2mA + \frac{V_A - 0}{3k \Omega} + \frac{(V_A - 3) - 0}{6k \Omega} = 0$$

### Step 6: Solve the System of Equations to Determine the Nodal Voltages

Solution of the equation above results in $V_A = 5V$. Thus, the voltage difference across the current source is $V=5V$.

### Alternate Approach: Constraint Equations

The use of supernodes can be convenient, but is not a necessity. An alternate approach, for those who do not wish to identify supernodes, is to restrain separate nodes on either side of the voltage source and then write a constraint equation relating these voltages. Thus, in cases where the reader does not recognize a supernode, the analysis can proceed correctly. We now revisit the previous example, but use constraint equations rather than the previous supernode technique.

In this approach, Steps 2 and 3 (identification of independent nodes) are not necessary. One simply writes Kirchhoff's current law at all nodes and then writes constraints equations for the voltage sources. A disadvantage of this approach is that currents through voltage sources must be accounted for explicitly; this result in a greater number of unknowns (and equations to be solved) than the supernode technique.

Example (revisited): for the circuit below, determine the voltage difference, V, across the 2mA source.

Choice of a reference voltage proceeds as previously. However, now we will not concern ourselves too much with identification of independent nodes. Instead, we will just make sure we account for voltages and currents everywhere in the circuit. For our circuit, this results in the node voltages and currents shown below. Notice that we have now identified two unknown voltages ($V_A$ and $V_B$) and three unknown currents, one of which ($i_3$) is the current through the voltage source.

Now we write KCL at each of the identified nodes, making sure to account for the current through the voltage source. This results in the following equations (assuming currents leaving the node are positive):

Node A: $-2mA+i_1+i_3=0$

Node B: $-i_3+i_2=0$

Using Ohm's law to convert the currents $i_1$ and $i_2$ to voltages results in:

Node A: $-2mA+ \frac{V_A - 0}{3k \Omega} + i_3 = 0$

Node B: $-i_3 + \frac{V_B - 0}{6k \Omega} = 0$

Notice that we cannot, by inspection, determine anything about the current $i_3$ from the voltages; the voltage-current relationship for an ideal source is not known.

The two equations above have three unknowns - we cannot solve for the node voltages from them without a third equation. This third equation is the constraint equation due to the presence of the voltage source. For our circuit, the voltage source causes a direct relationship between $V_A$ and $V_B$:

$$V_B=V_A-3$$

These thee equations (the two KCL equations, written in terms of the node voltages and the constraint equation) constitute three equations in three unknowns. Solving these for the node voltage $V_A$ results in $V_A=5V$, so the voltage across the current source is $V=5V$.

The example below uses the concept of a supernode to write the governing KCL equations. In the example below, Steps 1, 2, and 3 have been condensed into a single process, as have Steps 4 and 5. It is suggested that the reader re-do the example below using constraint equations. Note again that the current sources appear directly in the KCL equations.

### Example 3.2

For the circuit below, find the power generated or absorbed by the 2V source and the power generated or absorbed by the 2A source.

Steps 1, 2, and 3: we choose our reference node (arbitrarily) as shown below. Shorting voltage sources and open-circuiting current sources identifies three independent node voltages (labeled below as $V_A$, $V_B$, and $V_C$) and one dependent node, with voltage labeled below as $V_A-2$.

Steps 4 and 5: Writing KCL at nodes A, B, and C and converting the currents to voltages using Ohm's law results in the equations below. Note that we have (essentially) assumed that all unknown currents at a node are flowing out of the node, consistent with our node 2 for example 1 above.

Node A:

$$2A+ \frac{V_A - 0V}{4 \Omega} + \frac{( V_A-2V) -V_B}{4 \Omega} + \frac{(V_A - 2V) - V_C}{8\Omega} = 0 \Rightarrow 5V_A - 2V_B - V_C = -10$$

Node B:

$$\frac{V_B - 0V}{3\Omega} + \frac{(V_A - 2V)}{4\Omega} + 3A = 0 \Rightarrow 7V_B - 3V_A = 42$$

Node C:

$$\frac{V_C - (V_A - 2)}{8\Omega} - 3A = 0 \Rightarrow V_C - V_A = 22$$

Step 6: Solving the above results in $V_A = 0V$, $V_B = -6V$, and $V_C=22V$. Thus, the voltage difference across the 2A source is zero volts, and the 2A source delivers no power. KCL at node A indicates that the current through the 2V source is 2A, and the 2V source generates 4W.

### Dependent Sources

In the presence of dependent sources, nodal analysis proceeds approximately as outlined above. The main difference is the presence of additional equations describing the dependent source. As before, we will discuss the treatment of dependent sources in the context of examples.

### Example 3.3

Write the nodal equations for the circuit below. The dependent source is a voltage controlled voltage source. $I_S$ is an independent current source.

As always, the choice of reference node is arbitrary. To determine independent voltages, dependent voltage sources are short-circuited in the same way as independent voltage sources. Thus, the circuit below has two independent nodes; the dependent voltage source and the nodes on either side of it form a supernode. The reference voltage, independent voltages, supernode, and resulting dependent voltage are shown below.

We now, as previously, write KCL for each independent node, taking into account the dependent voltage resulting from the presence of the supernode:

$$\frac{(V_A-2V_X)-0}{R_3} + \frac{V_A-0}{R_4} + \frac{V_A-V_B}{R_2}=0$$

$$\frac{V_B-V_A}{R_2} + \frac{V_B-(V_A+2V_X)}{R_1} -I_S=0$$

The above equations result in a system with two equations and three unknowns: $V_A$, $V_B$, and $V_X$ ($I_S$ is a known current). We now write any equations governing the dependent sources. Writing the controlling voltage in terms of the independent voltages results in:

$$V_X=V_A-V_B$$

We now have three equations in three unknowns, which can be solved to determine the independent voltages, $V_A$ and $V_B$.

### Example 3.4

Write the nodal equations for the circuit below.

The reference node, independent voltages and dependent voltages ae shown on the figure below. A supernode, consisting of the 4V source and the nodes on either side of it, exists but is not shown explicitly on the figure.

Applying KCL for each independent node results in:

$$\frac{(V_A+4V)-3V}{2\Omega} + \frac{(V_A + 4V)-0}{4\Omega} + \frac{V_A-0}{5\Omega} + \frac{V_A-V_B}{3\Omega} = 0$$

$$\frac{V_B-V_A}{3\Omega}-3I_X=0$$

This consists of two equations with three unknowns. The equation governing the dependent current source provides the third equation. Writing the controlling current in terms of independent voltages results in:

$$I_X= \frac{V_A-0}{5\Omega}$$

### Section Summary

• Basic steps in nodal analysis are:
• Define a reference node. All node voltages will be relative to this reference voltage.
• Identify independent nodes. This can be done by short-circuiting voltage sources, open-circuiting current sources, and identifying the remaining nodes in the circuit. The voltages at these nodes are the node voltages.
• Determine dependent voltages. This can be done by replacing the sources in the circuit schematic, and writing voltage constraints introduced by voltage sources.
• Use Ohm's law to write KCL at each independent node, in terms of the node voltages. This will result in N equations in N unknowns, where N is the number of node voltages. Independent “nodes” can be supernodes; supernodes typically contain a voltage source; this minimizes the number of equations being written by taking advantage of voltage constraints introduced in step 3.
• Solve the equations of step 4 to determine the node voltages.
• Use the node voltages to determine any other desired voltages/currents in the circuit.
• Modifications to the above approach are allowed. For example, it is not necessary to define supernodes in step 4 above. Once can define unknown voltages at either terminal of a voltage source and write KCL at each of these nodes. However, the unknown current through the voltage source must be accounted for when writing KCL - this introduces an additional unknown into the governing equations. This added unknown requires an additional equation. This equation is obtained by explicitly writing a constraint equation relating the voltages at the two terminals of the voltage source.

### Exercises

1. Use nodal analysis to write a set of equations from which you can find $I_1$, the current through the $12\Omega$ resistor. Do not solve the equations.

2. Use nodal analysis to find the current I flowing through the $10\Omega$ resistor in the circuit below.

## 3.3: Mesh Analysis

In mesh analysis, we will define a set of mesh currents and use Ohm's law to write Kirchhoff's voltage law in terms of these voltages. The resulting set of equations can be solved to determine the mesh currents; any other circuit parameters (e.g. voltages) can be determined from these currents.

Mesh analysis is appropriate for planar circuits. Planar circuits can be drawn in a single plane2) such that no elements overlap one another. Such circuits, when drawn in a single plane will be divided into a number of distinct areas; the boundary of each area is a mesh of the circuit. A mesh current is the current flowing around a mesh of the circuit.

The steps used in mesh analysis are provided below. The steps are illustrated in terms of the circuit of Fig. 3.8.

### Step 1: Define Mesh Currents

In order to identify our mesh loops, we will turn off all sources, much like what we did in nodal analysis. To do this, we:

• Short-circuit all voltage sources.
• Open-circuit all current sources.

Once the sources have been turned off, the circuit can be divided into a number of non-overlapping areas, each of which is completely enclosed by circuit elements. The circuit elements bounding each of these areas form the meshes of our circuit. The mesh currents flow around these meshes. Our example circuit has two meshes after removal of the sources, the resulting mesh currents are as shown in Fig. 3.9.

#### Note

We will always choose our mesh currents as flowing clockwise around the meshes. This assumption is not fundamental to the application of mesh analysis, but it will result in a special form for the resulting equations which will later allow us to do some checking of our results.

### Step 2: Replace Sources and Identify Constrained Loops

The presence of current sources in our circuit will result in the removal of some meshes during Step 1. We must now account for these meshes in our analysis by returning the sources to the circuit and identifying constrained loops.

We have two rules for constrained loops:

1. Each current must have one and only one constrained loop passing through it.
2. The direction and magnitude of the constrained loop current must agree with the direction and magnitude of the source current.

For our example circuit, we choose our constrained loop as shown below. It should be noted that constrained loops can, if desired, cross our mesh loops - we have, however, chosen the constrained loop so that is does not overlap any of our mesh loops.

### Step 3: Write KVL Around the Mesh Loops

We will apply Kirchhoff's voltage law around each mesh loop in order to determine the equations to be solved. Ohm's law will be used to write KVL in terms of the mesh currents and constrained loop currents as identified in Steps 1 & 2 above.

Note that more than one mesh current may pass through a circuit element. When determining voltage drops across individual elements, the contributions from all mesh currents passing through that element must be included in the voltage drop.

When we write KVL for a given mesh loop, we will base our sign convention for the voltage drops on the direction of the mesh current for that loop.

For example, when we write KVL for the mesh current $i_1$ in our example, we choose voltage polarities for resistors $R_1$ and $R_4$ as shown in the figure below - these polarities agree with the passive sign convention for voltages relative to the direction of the mesh current $i_1$.

From the above figure, the voltage drops across the resistor $R_1$ can then be determined as:

$$V_1 = R_1 i_1$$

Since only mesh current $i_1$ passes through the resistor $R_1$. Likewise, the voltage drop for the resistor $R_4$ is

Since mesh currents $i_1$ and $i_4$ both pass through $R_4$ and the current $i_2$ is in the opposite direction to our assumed polarity for the voltage $V_4$.

Using the above expressions for $V_1$ and $V_4$, we can write KVL for the first mesh loop as:

$$-V_S + R_1 i_1 + R_4 (i_1 - i_2) =0$$

When we write KVL for the mesh current $i_2$ in our example, we choose voltage polarities for resistors $R_4$, $R_2$, and $R_5$ as shown in the figure below – these polarities agree with the passive sign convention for voltages relative to the direction of the mesh current $i_2$. Please note that these sign conventions do not need to agree with the sign conventions used in the equations for other mesh currents.

Using the above sign conventions, KVL for the second mesh loop becomes:

$$R_4 \left( i_2-i_1 \right) + R_2i_2 + R_5 \left( i_2 + I_S \right) = 0$$

Please note that the currents $i_2$ and $I_s$ are in the same direction in the resistor $R_5$, resulting in a summation of these currents in the term corresponding to the voltage drop across the resistor $R_5$.

#### Notes:

1. Assumed sign conventions on voltage drops for a particular mesh loop are based on the assumed direction of that loop's mesh current.
2. The current passing through an element is the algebraic sum of all mesh and constraint currents passing through that element. This algebraic sum of currents is used to determine the voltage drop of the element.

### Step 4: Solve the System of Equations to Determine the Mesh Currents of the Circuit

Step 3 will always result in N equations in N unknowns, where N is the number of mesh currents identified in Step 1. These equations can be solved for the mesh currents. Any other desired circuit parameters can be determined from the mesh currents.

The example below illustrates the above approach.

### Example 3.5

In the circuit below, determine the voltage drop, $V$, across the 3Ω resistor.

Removing the sources results in a single mesh loop with mesh current $i_1$, as shown below.

Replacing the sources and defining one constrained loop per source results in the loop definitions shown below (note that each constrained loop goes through only one source and that the amplitude and direction of the constrained currents agrees with source).

Applying KVL around the loop $i_1$ and using Ohm's law to write voltage drops in terms of currents:

$$-3V+7\Omega \left( i_1 + 1A \right) + 3\Omega \left( i_1 + 1A + 3A \right) + 4\Omega \left( i_1 + 3A \right) = 0 \Rightarrow i_1 = -2A$$

Thus, the current $i_1$ is 2A, in the opposite direction to that shown. The voltage across the $3\Omega$ resistor is $V = 3\Omega \left( i_1 + 3A + 1A \right) = 3\Omega \left( -2A +3A +1A \right) = 3 \left( 2A \right) = 6V$.

### Alternate Approach to Constraint Loops: Constraint Equations

In the above examples, the presence of current sources resulted in a reduced number of meshes. Constraint loops were then used to account for current sources. An alternate approach, in which we retain additional mesh currents and then apply constraint equations to account for the current sources, is provided here. We use the circuit of the previous example to illustrate this approach.

Example: determine the voltage, $V$, in the circuit below.

Define three mesh currents for each of the three meshes in the above circuit and define unknown voltages $V_1$ and $V_3$ across the two current sources as shown below.

Applying KVL around the three mesh loops results in three equations with five unknowns:

$$V_1 + 3\Omega \cdot \left(i_1 - i_3 \right) + 7\Omega \cdot \left( i_1 - i_2 \right) = 0$$

$$-3V + 7\Omega \cdot \left(i_2 - i_1 \right) + V_3 = 0$$

$$-V_3 + 3\Omega \cdot \left(i_3 - i_1 \right) + 4\Omega \cdot i_3 = 0$$

Two additional constrain equations are necessary. These can be determined by the requirement that the algebraic sum of the mesh currents passing through a current source must equal the current provided by the source. Thus, we obtain:

$$-i_2 + i_3 = 3A$$

$$-i_1 = 1A$$

Solving the five simultaneous equations above results in the same answer determined previously.

### Clarification: Constraint Loops

Previously, it was claimed that the choice of constraint loops is somewhat arbitrary. The requirements are that each source has only one constraint loop passing through it, and that the magnitude and direction of the constrained loop current be consistent with the source. Since constraint loops can overlap other mesh loops without invalidating the mesh analysis approach, the choice of constraint loops is not unique. The examples below illustrate the effect of different choices of constraint loops on the analysis of a particular circuit.

### Example 3.6: Version 1

Using mesh analysis, determine the current, $i$, through the 4Ω resistor.

#### Step 1: Define mesh loops

Replacing the two current sources with open circuits and the two voltage sources with short circuits results in a single mesh current, $i_1$, as shown below.

#### Step 2: Constrained loops, version 1

Initially, we choose the constrained loops shown below. Note that each loop passes through only one source and has the magnitude and direction imposed by the source.

#### Step 3: Write KVL around the mesh loops

Our example has only one mesh current, so only one KVL equation is required. This equation is:

$$-8V + 2\Omega \left( i_1 + 1A - 2A \right) + 4\Omega \left( i_1 - 2A \right) + 10V + 6\Omega \left( i_1 \right) = 0$$

#### Step 4: Solve the system of equations to determine the mesh currents of the circuit

Solving the above equation results in $i_1 = 0.667A$. The current through the $4\Omega$ resistor is then, accounting for the 2A constrained loop passing through the resistor, $i = i_1 -2A = -1.333A$.

### Example 3.6: Version 2

In this version, we choose an alternate set of constraint loops. The alternate set of loops is shown below; all constraint loops still pass through only one current source, and retain the magnitude and direction of the source current.

Now, writing KVL for the single mesh results in:

$$-8V + 2\Omega \left( i_1 + 1A \right) + 4\Omega \cdot i_1 + 10V + 6\Omega \left( i_1 +2A \right) = 0$$

Solving for the mesh current results in $i_1 = -1.333A$; note that this result is different than previously. However, we determine the current through the $4\Omega$ resistor as $i=i_1 = -1.333A$, which is the same result as previously.

#### Note

Choice of alternate constrained loops may change the values obtained for the mesh currents. The currents through the circuit elements, however, do not vary with choice of constrained loops.

### Example 3.6: Version 3

In this version, we choose yet another set of constrained loops. These loops are shown below. Again, each loop passes through one current source and retains that source's current direction and amplitude.

KVL around the mesh loop results in:

$$-8V + 2\Omega \cdot i_1 + 4\Omega \left( i_1 - 1A \right) + 10V + 6\Omega \left( i_1 - 1A + 2A \right) = 0$$

Which results in $i_1 =-0.333A$. Again, this is different from the result from our first two approaches. However, the current through the $4\Omega$ resistor is $i=i_1 - 1A = -1.333A$, which is the same result as previously.

### Dependent Sources

As with nodal analysis, the presence of dependent sources does not significantly alter the overall mesh analysis approach. The primary difference is simply the addition of the additional equations necessary to describe the dependent sources. We discuss the analysis with dependent sources in the context of the following examples.

### Example 3.7

Determine the voltage V in the circuit below.

Shorting both of the voltage sources in the circuit above results in two mesh circuits. These are shown in the figure below.

Writing KVL around the two mesh loops results in:

$$-2V + 2\Omega \cdot i_1 + 3\Omega \left( i_1-i_2 \right) = 0$$

$$2I_X + 3\Omega \left( i_2 - i_1 \right) + 4\Omega \cdot i_2 = 0$$

we have two equations and three unknowns. We need an additional equation to solve the system of equations. The third equation is obtained by writing the dependent source's controlling current in terms of the mesh currents:

$$I_X = i_1$$

The above three equations can be solved to obtain $i_1 = 0.4375 \Omega$ and $i_2 = 0.0625 \Omega$. The desired voltage $V=4i_2 = 0.25V$.

### Example 3.8

Write mesh equations for the circuit shown below.

Mesh loops and constraint loops are identified as shown below:

Writing KVL for the two mesh loops results in:

$$4\Omega \cdot i_1 + 2\Omega \left(i_1 - 3V_X \right) + 12V = 0$$

$$-12V + 3\Omega \left(i_2-3V_X \right) + 5\Omega \cdot i_2 = 0$$

Writing the controlling voltage $V_X$ in terms of the mesh currents results in:

$$V_X = 5\Omega \cdot i_2$$

The above consist of three equations in three unknowns, which can be solved to determine the mesh currents. Any other desired circuit parameters can be determined from the mesh currents.

### Section Summary

• Basic steps in mesh analysis are:
• Identify mesh currents. This can be done by short-circuiting voltage sources, open-circuiting current sources, and identifying the enclosed, non-overlapping regions in the circuit. The perimeters of these areas are the circuit meshes. The mesh currents flow around the circuit meshes.
• Determine constrained loops. The approach in Step 1 will ensure that no mesh currents will pass through the current sources. The current source currents can be accounted for by defining constrained loops. Constrained loops are defined as loop currents which pass through the current sources. Constrained loops are identified by replacing the sources in the circuit schematic, and defining mesh currents which pass through the current sources; these mesh currents form the constrained loops and must match both the magnitude and direction of the current in the current sources.
• Use Ohm's law to write KVL around each mesh loop, in terms of the mesh currents. This results in N equations in N unknowns, where N is the number of mesh currents. Keep in mind that the voltage difference across each element must correspond to the voltage difference induced by all the mesh currents which pass through that element.
• Solve the equations of Step 4 to determine the mesh currents.
• Use the mesh currents to determine any other desired voltages/currents in the circuit.
• The constrained loops in Step 2 above are not unique. Their only requirement is that they must account for the currents through the current sources.
• Modifications to the above approach are allowed. For example, it is not necessary to define constrained loops in Step 3 above. One can define (unknown) mesh currents which pass through the current sources and write KVL for these additional mesh currents. However, the unknown voltage across the current source must be accounted for when writing KVL - this introduces an additional unknown into the governing equations. This added unknown requires an additional equation which is obtained by explicitly writing a constraint equation equating algebraic sum of the mesh currents passing through a current source to the current provided by the source.

### Exercises

1. Use mesh analysis to write a set of equations from which you can find $I_1$, the current through the $12\Omega$ resistor. Do not solve the equations.

2. Use mesh analysis to find the current $I$ flowing through the $10\Omega$ resistor in the circuit below. Compare your result to your solution to exercise 2 of section 3.2.

1)
The voltages at nodes a and d are not independent; the voltage source vs constrains the voltage at node a relative to the voltage at node d (KVL around the leftmost loop indicates the vab=Vs
2)
Essentially, you can draw the schematic on a piece of paper without ambiguity.