# Combinational Circuit Design

Computer Science I · Basic Digital Design · https://tryals.app/learn/computer-science-i/combinational-circuit-design

## Wiring Up a Function

A **combinational circuit** has outputs depending **only** on current inputs—it has **no memory**. (Circuits with memory are **sequential**).

Designing follows a strict recipe:
1. **Specify**: Build a **truth table** listing outputs for every input combo.
2. **Derive**: Read 1-rows to form a **sum-of-products** formula.
3. **Draw**: Map terms to gates (AND, OR, NOT).

| Circuit Type | Behavior | Output Logic |
| --- | --- | --- |
| **Odd Detector** | Outputs 1 when 2-bit input is odd | Passes low bit directly |
| **Majority Circuit** | Outputs 1 when $\ge 2$ inputs are 1 | Sum of AND-pairs |

Any truth table maps mechanically to hardware.

## Real-World Limits

Practical design involves strict physical constraints:

* **Fan-in**: Max inputs a single gate accepts (wide functions use gate trees).
* **Fan-out**: Max gate inputs one output can safely drive.
* **Gate Count & Depth**: Fewer gates reduce cost; fewer gates **in series** (shallow depth) reduce propagation delay.

| Feature | Combinational | Sequential |
| --- | --- | --- |
| **Memory** | None (pure function of present inputs) | Yes (latches and flip-flops) |

> **Common Pitfall:** Expecting a combinational circuit to remember past states. The same inputs **always** yield the exact same outputs.

## Practice questions

2 of this lesson's 10 practice questions, with answers. The full set is in the app.

### 1. A combinational circuit can give different outputs for the same inputs, depending on what came before.

**Answer:** False

**Why:** False. With no storage element there is nothing to hold history, so the output is a pure function of the present inputs. Adding feedback through a latch is exactly what creates state and makes a circuit **sequential**: and that is the dividing line between the two families.

Page: https://tryals.app/practice/computer-science-i/combinational-circuit-design/a-combinational-circuit-can-give-different-outputs-for-the-same

### 2. A combinational circuit's output momentarily flickers to the wrong value after its inputs change, then settles correctly. Why does a synchronous design tolerate this?

A. Because glitches are eliminated by the combinational logic itself
B. Because registers filter out short pulses electrically
C. Because registers sample only after the glitch has resolved
D. Because glitches only occur in faulty circuits

**Answer:** C. Because registers sample only after the glitch has resolved

**Why:** Unequal path delays make glitches inevitable, and synchronous design does not remove them, it arranges never to look during them. That is what the clock period buys, and it is why asynchronous design is so much harder: without a sampling instant, every transient is potentially observed.

Page: https://tryals.app/practice/computer-science-i/combinational-circuit-design/a-combinational-circuits-output-momentarily-flickers-to-the-wrong
