Courses / Computer Science I
Basic Digital Design

Adders, Multiplexers, and Decoders

Computer Science I 188 words Free to read

Building Blocks: Adders

Instead of raw gates, engineers use standard building blocks: reliable combinational modules acting like Lego pieces.

The half adder adds two bits to output a sum (ABA \oplus B) and a carry (ABA \cdot B). A full adder adds three bits including a carry-in, outputting a sum and carry-out.

Chaining nn full adders builds a ripple-carry adder for nn-bit numbers. Wider numbers take longer because the carry must ripple through every stage.

MUX vs. Decoder

A multiplexer (MUX) is a data selector routing one of 2k2^k inputs to a single output using kk select lines (2k inputsk select lines2^k \text{ inputs} \Rightarrow k \text{ select lines}). It acts as hardware if/else.

A decoder does the opposite: a kk-bit input activates exactly one of 2k2^k outputs. Its inverse is an encoder.

BlockStructureFunction
MUXMany inputs, 1 outputRoutes chosen data
Decoderkk inputs, 2k2^k outputsActivates one line
Common pitfall: MUXes narrow many inputs to one; decoders fan a small input out to many outputs.
Adders, Multiplexers, and Decoders

Practise this lesson

The explanation above is free to read. The graded practice for this lesson lives in the Tryals app.

10practice questions
2interactive scenes

Basic Digital Design