Skip to content
BetterDL

Circuit analysis

Also called: logic circuit analysis, analyzing a logic circuit, tracing a circuit, circuit tracing, gate-level analysis

Working out what a gate circuit does: finding its Boolean expression, evaluating it for given inputs, or building its full truth table.

Circuit analysis means taking a drawn circuit and working out what it computes. There are three common jobs, and they use the same habit: go gate by gate, left to right.

  1. Find the expression. Label the output of each gate fed directly by inputs. Feed those labels into the next gates. The last gate gives the outermost operation of the final boolean expression.
  2. Evaluate for given inputs. Write each gate's output value on its wire, again left to right. A gate can only be evaluated once all of its inputs are known.
  3. Build the truth table. Repeat the evaluation for all 2ⁿ input rows, or simplify the expression first and read the table from that.

Brackets matter when you write the expression. AND binds tighter than OR, so an OR feeding an AND must be bracketed: A OR B, then AND C, is , not .

Watch for fan out: when one input feeds two gates, it has the same value at both.

The reverse job, working backwards, starts from a required output. Ask what the last gate needs (a NAND is 0 only if all its inputs are 1, an OR is 0 only if all its inputs are 0), then repeat for the gates feeding it.

Analysis is the opposite of design, where you start from a specification and build the logic diagram.

ABCY

Worked example

Example

Expression, value and truth table

Analyze the circuit above: a NAND of A and B and an OR of B and C both feed an AND.

Y
0000
0011
0101
0111
1000
1011
1100
1110
  1. 1.

    First level: the NAND gives and the OR gives .

  2. 2.

    Last gate: Y = .

  3. 3.

    Evaluate A = 1, B = 1, C = 0: the NAND gives 0, the OR gives 1, and the AND gives 0. So Y = 0.

  4. 4.

    Full table: Y = 1 needs the NAND at 1 (not both A and B) and the OR at 1 (B or C).

  5. 5.

    That holds for ABC = 001, 010, 011 and 101, so Y is 1 in 4 of the 8 rows.

Common mistakes

  • Dropping brackets when an OR feeds an AND. and are different functions.

  • Evaluating a gate before all its inputs are known. Work in order from the inputs toward the output.

  • Giving a fanned-out input different values at different gates. It's one wire, so one value.

Practice Circuit analysis

Interactive questions with instant feedback and a worked solution for every wrong answer.

Learn it step by step

Circuit analysis is taught in Logic Gates and Combinational Logic.