3.1.8 · D2Boolean Algebra & Logic Gates

Visual walkthrough — De Morgan's theorems

1,591 words7 min readBack to topic

Step 0 — The alphabet we are allowed to use

Before any theorem, we agree on five words, and we draw each one.

Figure — De Morgan's theorems

Look at the picture: series = AND (one path, needs both), parallel = OR (two paths, needs either). Keep these two shapes in your head — the entire proof is about them swapping.


Step 1 — Draw what actually asks

WHAT. Take the AND lamp (series switches). Put one long bar over the whole thing: . This is a NAND — "not both".

WHY. We must know exactly when this output is 1 before we can find a matching expression. The cleanest way to see "when is it 1?" is to ask the opposite question: "when is itself 1?" — because the bar just flips that answer.

PICTURE. The series lamp lights only in the single case both switches ON. So the barred lamp is dark in that one case and lit in the other three.

Figure — De Morgan's theorems

The red cell (both ON) is the only place NAND = 0. Everywhere else it is 1. Remember that shape — three lit, one dark.


Step 2 — Re-read those three lit cases in words

WHAT. List the three cases where : (A off, B off), (A off, B on), (A on, B off).

WHY. We want a single sentence that captures all three at once, because a sentence turns straight into a Boolean expression. Notice what they share: in every lit case, at least one switch is OFF.

  • = " is off" — a bubble on just .
  • = " is off" — a bubble on just .
  • the OR appears because either one being off is enough.

PICTURE. Shade the row/column of "A off" and "B off"; their union covers exactly the three lit cells.

Figure — De Morgan's theorems

That union — orange region plus green region — is precisely the three lit NAND cells from Step 1. Same picture, read two ways.


Step 3 — The AND has just become an OR

WHAT. Put Steps 1 and 2 side by side. Both describe the same map of lit cells, so:

WHY. This is Theorem 1. The long bar broke into two short bars, and the underneath turned into a . That operator flip is not a trick — it is forced by "both ON" (rare) becoming "at least one OFF" (common). A rare condition negated becomes a common one, and common = OR.

PICTURE. The circuit redrawing: a NAND (series + one big bubble) becomes an OR (parallel) fed by two small input bubbles. This is exactly Bubble Pushing — the bubble slides through the gate and the gate body flips shape.

Figure — De Morgan's theorems

Watch the big output bubble split into two input bubbles as the series wires spread into parallel. That spreading is AND→OR.


Step 4 — Now the mirror: draw

WHAT. Repeat, but start from OR (parallel switches) and bar the whole thing: . This is a NOR — "neither".

WHY. By symmetry we expect the opposite swap (OR→AND). But we do not assume it — we look. First ask when : the parallel lamp lights if either is ON, so it is dark only when both are OFF.

PICTURE. The parallel lamp is lit in three cases, dark in one (both OFF). Barring it flips the map: NOR is lit in exactly one cell — both OFF.

Figure — De Morgan's theorems

Notice this is the photo-negative of Step 1: NAND was three-lit-one-dark, NOR is one-lit-three-dark.


Step 5 — Read the single lit cell, get Theorem 2

WHAT. happens in one case only: A off AND B off.

WHY. " off and off" is . The word and appears because both must hold — a strict, rare condition, and rare = AND. So:

PICTURE. The NOR (parallel + output bubble) redraws as an AND (series) with two input bubbles — the mirror of Step 4's circuit.

Figure — De Morgan's theorems

Parallel wires collapse into a single series path as the output bubble splits inward: that collapsing is OR→AND.


Step 6 — The degenerate cases (never leave a gap)

We must check the inputs are not just "both variables". What if a constant or a repeated variable shows in?

PICTURE. The one to burn in: tie both NAND inputs together and it becomes an inverter.

Figure — De Morgan's theorems

This is the seed of NAND and NOR Universal Gates — a single NAND type builds NOT, and from NOT+NAND everything else.


The one-picture summary

Everything above is one diagram: a bubble crossing a gate flips the gate's shape (series↔parallel, AND↔OR) and lands as bubbles on the far side.

Figure — De Morgan's theorems
Recall Feynman: retell the walkthrough with no symbols

Two switches feed a lamp. Series (both needed) = AND; parallel (either works) = OR. Now put a "NOT" over the whole lamp. Ask a simpler question: when was the plain lamp on? Flip that answer to get when the NOT-lamp is on. For AND, "on" was the rare case both-ON — flip it and you get the common case at-least-one-OFF, which is an OR of two NOTs. For OR, "on" was the common case either-ON — flip it and you get the rare case both-OFF, which is an AND of two NOTs. So negating turns a rare "both" into a common "either" and vice-versa. In circuit pictures the output bubble just walks backward through the gate, and as it passes, the gate body morphs between series and parallel. That morph is De Morgan.


Connections

Concept Map

bar the AND

bar the OR

read lit cells

read lit cells

rare both to common either

common either to rare both

redraw circuit

redraw circuit

tie inputs

series = AND, parallel = OR, bubble = NOT

NAND: three lit one dark

NOR: one lit three dark

ask when plain lamp is ON then flip

Theorem 1: AND flips to OR

Theorem 2: OR flips to AND

bubble walks through gate

one NAND builds NOT