Use Kirchhoff's current and voltage laws and mesh analysis to solve a two-loop circuit.
Why it matters
Series and parallel reduction stops working as soon as a circuit has two sources or a resistor shared between two loops. Kirchhoff's two laws work on any circuit, however tangled. Engineers use them to write the equations that simulators solve, technicians use them to check whether a set of measurements adds up, and they are the foundation of mesh and nodal analysis that you will meet in power and electronics courses.
Kirchhoff's current law (KCL)
The total current flowing into a node equals the total current flowing out. A node is any point where two or more components meet. Charge does not pile up in a wire, so what goes in must come out.
If 3 A and 2 A flow into a node, and one wire leaves it,
that wire carries 3 + 2 = 5 A out.
A common way to write it: the currents into a node, counted positive in and negative out, sum to zero.
Kirchhoff's voltage law (KVL)
Around any closed loop, the voltage rises equal the voltage drops. Equivalently, the signed voltages around a loop sum to zero. Energy given to charge by sources is all used by the loads before the charge returns to where it started.
To apply it, pick a direction to walk around the loop and stick to it:
- Walking through a battery from − to +: a rise of its voltage.
- Walking through a resistor in the same direction as the current you assumed: a drop of
I × R. - Walking against the assumed current: a rise of
I × R.
You do not need to guess current directions correctly. If you guess wrong, the answer simply comes out negative, which tells you the current flows the other way.
Mesh analysis: a two-loop example
Mesh analysis applies KVL with a loop current for each "window" of the circuit.
The circuit: a 12 V battery V1 on the left side and a 6 V battery V2 on the right side, both with their + terminal at the top. Along the top, R1 = 2 Ω sits on the left and R2 = 4 Ω on the right. A shared resistor R3 = 6 Ω runs vertically down the middle.
+--- R1 (2 Ω) ---+--- R2 (4 Ω) ---+
| | |
V1 12 V R3 (6 Ω) V2 6 V
| | |
+----------------+----------------+
Assign a clockwise mesh current I1 to the left window and I2 to the right window. R3 carries both: its current is I1 − I2 (downward).
Loop 1 (left, clockwise): rise through V1, drop across R1, drop across R3.
V1 = I1·R1 + (I1 − I2)·R3
12 = 8·I1 − 6·I2
Loop 2 (right, clockwise): up through R3, across R2, then down through V2 from + to −, which is a drop of 6 V.
0 = (I2 − I1)·R3 + I2·R2 + V2
−6 = −6·I1 + 10·I2
Two equations, two unknowns. Solve by substitution or Cramer's rule:
det = (8)(10) − (−6)(−6) = 80 − 36 = 44
I1 = (12·10 − (−6)(−6)) / 44 = 84 / 44 = 1.909 A
I2 = (8·(−6) − (−6)(12)) / 44 = 24 / 44 = 0.545 A
I_R3 = I1 − I2 = 1.364 A (downward)
Check with KCL and Ohm's law. The voltage at the top middle node is 12 − 1.909 × 2 = 8.18 V. Then R3 carries 8.18 / 6 = 1.364 A and R2 carries (8.18 − 6) / 4 = 0.545 A. At the top node, 1.909 A comes in and 1.364 + 0.545 = 1.909 A goes out. KCL holds.
Notice what I2 being positive means: current flows into the + terminal of V2. The 12 V battery is charging the 6 V one. Real batteries do not like that, which is one reason chargers include current limiting.
A general recipe
- Label every component and value; draw a mesh current in each window, all clockwise.
- Write one KVL equation per mesh. Shared resistors use the difference of the two mesh currents.
- Collect terms into the form
a·I1 + b·I2 = c. - Solve the system (by hand for two loops; with software for more).
- Find branch currents from the mesh currents, then check with KCL at a node.
Common mistakes
- Changing direction partway round a loop. Pick one direction and follow it all the way.
- Sign errors on sources. Ask: am I going from − to + (rise) or + to − (drop)?
- Using I1 alone for a shared resistor. A resistor between two meshes carries
I1 − I2. - Panicking at a negative answer. It only means the real current is opposite to your arrow.
- Not checking. A KCL check at one node catches most arithmetic slips.
Recap
- KCL: current in = current out at every node.
- KVL: rises = drops around every closed loop.
- Mesh analysis writes one KVL equation per window and solves the system.
Try it
Open the Do tab and write the loop 1 equation for a two-mesh solver in Python.