SECTION 04 / 5

Multilevel Logic and Timing Diagrams

3 min read
On this page 5 headings

Start here A room has three doors, with a light switch at each one. Flip any switch and the bulb should change: on to off, or off to on. How would you build that circuit? You’ll solve it on this page, and you’ll learn to read the “wave pictures” (timing diagrams) that exams love.

Flip any one switch and the bulb changes. Keep this picture in mind; the answer is at the end of the page.
Flip any one switch and the bulb changes. Keep this picture in mind; the answer is at the end of the page.
Open image ↗
One bulb, three switches

Multilevel logic

So far we’ve built two-level circuits (AND then OR). Real circuits often use more levels, because that can save gates.

Y=(A+B)(C‾+D)+E‾Y = \left(A + B\right) \left(\overline{C} + D\right) + \overline{E} uses three levels of gates, but fewer gates than its two-level version.
Y=(A+B)(C‾+D)+E‾Y = \left(A + B\right) \left(\overline{C} + D\right) + \overline{E} uses three levels of gates, but fewer gates than its two-level version.
Open image ↗
A multilevel circuit

Example: Y=(A+B)⋅(C‾+D)+E‾Y = \left(A + B\right) \cdot \left(\overline{C} + D\right) + \overline{E}

  • Multilevel: 2 ORs → 1 AND → 1 OR (plus inverters).
  • Two-level SOP: multiply out → AC‾+AD+BC‾+BD+E‾A \overline{C} + A D + B \overline{C} + B D + \overline{E}. That’s 4 ANDs + one big 5-input OR. More gates.

Trade-off: multilevel = fewer gates (cheaper) but more levels = slower (the signal passes through more gates).

Five cooks working at once finish fast. Three cooks passing one plate along need fewer people but take longer. Gates work the same way.
Five cooks working at once finish fast. Three cooks passing one plate along need fewer people but take longer. Gates work the same way.
Open image ↗
Cooks and levels

Timing diagrams

A timing diagram shows how signals change over time. Each signal is a line that is high (1) or low (0).

Cut the diagram into time slices. Each slice gives one row of the truth table.
Cut the diagram into time slices. Each slice gives one row of the truth table.
Open image ↗
Reading a timing diagram

How to turn a timing diagram into a function

  1. Draw vertical lines wherever any input changes. This cuts time into slices.
  2. In each slice, read every input (0 or 1) and the output.
  3. Write each slice as a row of a truth table.
  4. Rows that never appear are “don’t care” (you can choose 0 or 1, whichever makes the circuit smaller).
  5. Simplify to get the function.

Example (from the slides):

Slice x1x_{1} x2x_{2} f
1 0 0 1
2 0 1 1
3 1 0 0
4 1 1 1

f=Σm(0,1,3)=x1‾x2‾+x1‾x2+x1x2=f = \Sigma m \left(0 , 1 , 3\right) = \overline{x_{1}} \overline{x_{2}} + \overline{x_{1}} x_{2} + x_{1} x_{2} = x1‾+x2\overline{x_{1}} + x_{2}

Check: x1‾+x2\overline{x_{1}} + x_{2} is 0 only when x1=1x_{1} = 1 and x2=0x_{2} = 0, which is slice 3 ✓.

The three-switch light

Flip any one switch and the bulb changes. That’s exactly what XOR does.
Flip any one switch and the bulb changes. That’s exactly what XOR does.
Open image ↗
Three switches, one bulb

Think: flipping one switch must flip the bulb. Which gate flips its output when any one input flips? XOR!

Bulb = X⊕Y⊕ZX \oplus Y \oplus Z (on when an odd number of switches are up).

With 2-input XOR gates: (X⊕Y)⊕Z→\left(X \oplus Y\right) \oplus Z \to 2 XOR gates.

In one line: Multilevel circuits save gates but add delay; to read a timing diagram, slice it where inputs change, make a truth table, and simplify. Three switches controlling one bulb is a 3-input XOR. Exam words: multilevel logic, gate levels, delay vs cost, timing diagram, time slice, don’t care, parity, XOR.


Quick check

Why use multilevel logic? It usually needs fewer gates (cheaper), though the signal passes through more levels (slower).
In a timing diagram, an input combination never appears. What is the output for it? A don’t care: you can treat it as 0 or 1, whichever gives the simpler circuit.
Four switches, one bulb, any switch toggles it. Function? Gates? A⊕B⊕C⊕DA \oplus B \oplus C \oplus D, using 3 two-input XOR gates.
YOUR STUDY PROGRESS

Finished this section? Save your progress.

Back to top ↑