Kirchhoff's laws solve circuits that series and parallel rules cannot. Drag the five sliders below — the two EMFs and three resistances of a two-loop circuit — and watch all three branch currents solve live, with each arrow flipping direction the instant its current changes sign.
Two batteries feed a shared resistor. Drag the five sliders and the three branch currents solve live — arrows on the circuit flip direction when a current goes negative. A negative current isn't an error; it's the answer telling you the real direction of flow.

The Kirchhoff's law simulator is a free interactive physics lab that runs in your browser — nothing to install and no sign-up. Drag two EMFs and three resistances and watch the branch currents flip sign live, solving I1 + I2 = I3 as you go.
| Control | Range | Step |
|---|---|---|
| EMF of source | 0 – 24 V | 0.5 |
| Resistance R1 | 0.5 – 20 Ω | 0.5 |
| EMF of source | 0 – 24 V | 0.5 |
| Resistance R2 | 0.5 – 20 Ω | 0.5 |
| Shared resistance R | 0.5 – 20 Ω | 0.5 |
This simulator drives the article's two-loop circuit and re-solves it on every drag. The five sliders each feed one part of the network: ε1 and ε2 set how hard each battery pushes, while R1, R2 and the shared R3 set how much each branch resists. Move any one and the branch currents respond first, before the power panel updates — so you can trace exactly which input drove the change.
Two readouts do the teaching. The three currents always obey the junction rule, I1 + I2 = I3, no matter what you drag — the sum is enforced, never coincidental. And the power check always balances: the power delivered by the sources equals the power dissipated in the resistors, because that is energy conservation, the loop rule written in watts. Under the hood the sim solves the same closed form the calculator uses — it computes det = R1·R2 + R1·R3 + R2·R3, then I1 = (ε1·(R2+R3) - ε2·R3) / det and its partner for I2 — so the numbers on screen are the exact solution, not an approximation.
The reason this page exists is the misconception no static diagram can fix. Push ε2 down while ε1 stays high and watch I2 fall through zero and go negative — its arrow flips right there on the canvas. A negative current is not an error; it is the answer telling you the real direction of flow. Source 2, too weak to push against source 1, is now being charged, and the sim shows it as a reversed arrow and a “charging” status. Put exact numbers to any configuration with the Kirchhoff's Law calculator, read the full derivation in Kirchhoff's Laws (Current & Voltage), revisit the V = IR that each loop equation is built from, or open another model from the full simulation collection.
Everything on the canvas assumes two ideal EMFs: ε1 and ε2 hold their voltage however much current you draw. No real cell does. Every source has internal resistance, so its terminal voltage sags the harder you load it — hundredths of an ohm for a car battery, tenths for a small alkaline cell. So read R1 honestly: not just the resistor you soldered in, but that resistor plus the source's own internal resistance plus the wire and contact resistance of the branch. Set ε1 = 12.0 V and ε2 = 11.5 V with R1 = R2 = 0.5 ohm and R3 = 2.0 ohm and the branches carry 3.11 A and 2.11 A; raise both branch resistances to 5.0 ohm and the same batteries manage only 1.36 A and 1.26 A.
The second assumption is that a resistance is a number. It is a number at one temperature. Every resistor carrying current warms up and its resistance moves with it. The default setup dissipates 34.0 W across three resistors, enough to cook an ordinary quarter-watt part, and on a bench the currents half a minute after switch-on are not the ones at the instant it closed.
The loop rule carries a condition that is easy to miss: voltages around a closed loop sum to zero only when no changing magnetic flux threads that loop. Faraday's law says a changing flux drives its own EMF around the loop, and then the rule fails outright — two voltmeters on the same two nodes read genuinely different voltages depending on how their leads are routed. On a small DC board this never bites; beside a transformer or inside a switching supply it does.
Finally, the arithmetic and the chemistry can disagree. When I2 goes negative the simulator reports battery 2 as charging, and as circuit theory that is exactly right: current is forced backwards through it and it absorbs energy. Whether the real part survives is another question. A rechargeable cell accepts that current; a primary alkaline cell driven backwards heats, generates gas internally and can vent. Hence the blocking diode or charge controller in real two-source circuits.
A car with the engine running. The alternator and the battery sit across the same load, which is exactly this circuit. The regulator holds the alternator near 14.4 V while a charged lead-acid battery rests at about 12.6 V, so the alternator wins and the battery's current reverses. Set ε1 = 14.5 V, R1 = 0.5 ohm, ε2 = 12.5 V, R2 = 0.5 ohm, R3 = 5.0 ohm: the readouts give I1 = 3.29 A, I2 = -0.714 A, I3 = 2.57 A. The alternator carries the whole 2.57 A load and pushes 0.714 A back into the battery — that negative sign is your car charging.
Two supplies in parallel. Wire two of them to one load hoping they will share it and they will not: the split follows their voltage mismatch against each branch's resistance. The settings above — 12.0 V against 11.5 V through 0.5 ohm each — give 3.11 A and 2.11 A, a 4% mismatch making one supply deliver almost 50% more current. At 5.0 ohm per branch it is 1.36 A and 1.26 A: same mismatch, imbalance down tenfold from 1.00 A to 0.10 A. Hence the deliberate series resistance in paralleled supplies and battery strings.
DC traction fed from both ends. A metro train on a 750 V third rail draws from substations either side of it, each share fixed by its feeder resistance, so the more distant one contributes less. Equal sources with unequal branches — ε1 = ε2 = 12.0 V, R1 = 1.0 ohm, R2 = 3.0 ohm, R3 = 0.5 ohm — return I1 = 7.20 A against I2 = 2.40 A, exactly 3 to 1, the inverse of the resistance ratio. A train pulling a megawatt at 750 V takes about 1,300 A; brake it regeneratively and it becomes a source, flipping the feeder current's sign as I2 does here.
A negative sign means the current flows opposite to the direction drawn for that branch — the arrow flips on screen to show it. The magnitude is still exactly right: a reading of -1 A is a real 1 A flowing the other way. This is the simulator's whole point. It usually happens to I2 when source 2 is too weak to push against source 1, so current is forced backwards through it and it is being charged rather than delivering.
They set the two EMFs and the three resistances of the article's two-loop circuit: ε1 and R1 in the first source branch, ε2 and R2 in the second, and R3 in the branch the two loops share. Every time you move one, the simulator re-solves the junction and loop equations and updates all three branch currents at once.
Because energy is conserved — it is Kirchhoff's voltage law written in terms of power. The power delivered by the sources always equals the power dissipated in the resistors, no matter how you set the sliders. When a battery shows a negative current it is absorbing energy (being charged), so it counts as a load rather than a source, and the totals still match.
No — the sliders clamp at 0.5 ohm. A true zero-resistance branch is an ideal short circuit, which is not a lumped resistor and would make the network equations singular, leaving the current undefined. Keeping every resistance above zero guarantees the solver always has a well-defined answer.
No, the simulator is DC only: fixed EMFs and pure resistances. The same two rules — the junction rule and the loop rule — do extend to AC, but there you work with phasors and impedance instead of plain voltages and resistances, because capacitors and inductors introduce phase shifts. Master the DC case here first; the structure carries over.