Learning Objectives
- Translate each gate in a circuit into a logic operation.
- Use brackets to preserve the order of gate processing.
- Write expressions for circuits containing branches and intermediate outputs.
- Avoid simplifying the expression away from the drawn structure.
Key Terms
- Logic expression
- A written representation of how Boolean inputs are combined.
- Operator
- A gate word such as NOT, AND, OR, NAND, NOR or XOR.
- Bracket
- A symbol grouping the operation that must be completed first.
- Sub-expression
- A smaller operation that forms part of a larger expression.
- Scope
- The exact variable or grouped result to which an operator applies.
- Final expression
- The complete written rule for the circuit output.

Translate One Gate At A Time
Each gate can be written as a short expression. An AND gate receiving A and B produces A AND B. A NOT gate receiving C produces NOT C. A NAND gate receiving P and Q produces P NAND Q or NOT (P AND Q), depending on the requested style.
For a multi-gate circuit, assign temporary names to intermediate outputs. Then substitute their expressions into the final gate expression.
This method keeps the written expression aligned with the circuit structure.
Example With Two First-Stage Gates
Suppose A and B enter OR to produce P, while C enters NOT to produce Q. P and Q enter AND to produce X.
Write P = A OR B and Q = NOT C. Then X = P AND Q. Substitute to obtain X = (A OR B) AND (NOT C).
The brackets are essential because the two first-stage results must be calculated before the final AND.
Brackets And Scope
NOT A AND B is ambiguous if written carelessly. Use (NOT A) AND B when only A is inverted. Use NOT (A AND B) when the combined AND result is inverted.
A circuit bubble shows the scope visually. A bubble after an AND shape applies to the complete AND result, so the expression is NOT (A AND B), which is NAND.
Brackets should mirror the gate boundaries in the circuit.
Expressions For The Six Gates
| Gate | Expression For Inputs A And B |
|---|---|
| NOT | NOT A |
| AND | A AND B |
| OR | A OR B |
| NAND | A NAND B or NOT (A AND B) |
| NOR | A NOR B or NOT (A OR B) |
| XOR (EOR) | A XOR B |
Branches In Expressions
If input A branches to two gates, A appears in two sub-expressions. For example, A and B enter AND to produce P, while A enters NOT to produce Q. If P and Q enter OR, then X = (A AND B) OR (NOT A).
The repeated use of A does not create a second input variable. The truth table still has inputs A and B only.
Follow every branch so that no gate path is omitted.
Cascaded Gates
For A and B entering AND, with the result and C entering XOR, the expression is X = (A AND B) XOR C.
For A entering NOT, then that result and B entering NOR, write X = (NOT A) NOR B, or equivalently NOT ((NOT A) OR B) if the gate operations must be expanded.
Keep the level of detail consistent with the question. If it asks for an expression from named gate symbols, gate words are acceptable and clear.
No Simplification
The syllabus states that circuits must be drawn from statements without simplification. The same principle is useful when writing expressions from circuits: represent what is actually drawn.
If a circuit contains two NOT gates in sequence, write NOT (NOT A) rather than reducing it to A. If it contains an AND gate followed by a separate NOT gate, preserve those stages unless the question explicitly asks for the gate name NAND.
This allows the expression to be checked directly against the diagram.
Checking The Expression
Read the final expression from the inside out and compare it with the circuit from left to right. Every gate should correspond to one operator and every wire entering a gate should appear as an operand.
Count the external input variables and confirm no invented variable remains after substitution. Intermediate letters may be shown separately, but the final expression should normally be written using the original inputs.
Worked Examples
Circuit To Expression
Question: A and B enter NAND to give P. P and C enter OR to give X. Write X.
- Write P = A NAND B.
- The final gate is OR with inputs P and C.
- Substitute P.
Answer: X = (A NAND B) OR C, or X = NOT (A AND B) OR C with brackets showing the NAND result.
Branched Input
Question: A and B enter AND. A also enters NOT. The two outputs enter XOR. Write X.
- First path: A AND B.
- Second path: NOT A.
- Final operation: XOR.
Answer: X = (A AND B) XOR (NOT A).
Examination Guidance
- Write an intermediate expression for every gate.
- Use brackets to show gate boundaries and NOT scope.
- Follow all branches.
- Substitute intermediate variables into the final output expression.
- Preserve the drawn structure instead of simplifying.
Common Mistakes
- Writing operators in the wrong order.
- Omitting a branch path.
- Failing to bracket the input to NOT.
- Leaving P or Q undefined in the final answer.
- Simplifying two stages into a different-looking expression.
Knowledge Check
1. What should brackets represent?
2. How is an output bubble expressed?
3. Does a repeated A create another truth table input?
4. What is the expression for an OR gate fed by A AND B and C?
5. Should NOT (NOT A) automatically be simplified?