Multiplexer (MUX) and Demultiplexer (DEMUX)
Multiplexers and demultiplexers are combinational logic circuits that control where signals go in a digital system. A multiplexer picks one of many inputs and sends it to a single output. A demultiplexer does the reverse: it takes one input and routes it to one of many outputs. These two devices show up constantly in data routing, telecommunications, and computer networks, so understanding them well will pay off throughout the course.
Multiplexer (MUX) Fundamentals
A multiplexer (MUX) is a combinational circuit that selects one of several input signals and forwards it to a single output line. Think of it as a rotary switch controlled by a binary code.
The key relationship to remember: select lines determine which input reaches the output. With select lines, a MUX can handle up to inputs.
- 2-to-1 MUX: 2 data inputs, 1 select line ()
- 4-to-1 MUX: 4 data inputs, 2 select lines ()
- 8-to-1 MUX: 8 data inputs, 3 select lines ()
For a 4-to-1 MUX with inputs and select lines : when (binary for 2), the output equals . The select lines act as a binary address pointing to the desired input.
Demultiplexer (DEMUX) Fundamentals
A demultiplexer (DEMUX) works in the opposite direction. It takes a single input and routes it to one of several output lines, again controlled by select lines.
The same formula applies: with select lines, a DEMUX can have up to outputs.
- 1-to-2 DEMUX: 1 input, 2 outputs, 1 select line
- 1-to-4 DEMUX: 1 input, 4 outputs, 2 select lines
- 1-to-8 DEMUX: 1 input, 8 outputs, 3 select lines
For a 1-to-4 DEMUX: when the select lines read (binary for 3), the input signal appears on output , and all other outputs are held at 0 (or inactive).

Select Lines, Data Inputs, and Data Outputs
Select lines are the control mechanism for both MUXes and DEMUXes. The binary value on the select lines acts as an address:
- In a MUX, the select lines choose which input passes through to the single output.
- In a DEMUX, the select lines choose which output receives the single input.
You can describe the behavior of any MUX or DEMUX with a truth table. For example, a 2-to-1 MUX truth table looks like this:
| Output | |
|---|---|
| 0 | |
| 1 |
You can also express MUX/DEMUX behavior as a logic diagram built from AND, OR, and NOT gates. For the 2-to-1 MUX above, the Boolean expression for the output is:
Being comfortable moving between truth tables, Boolean expressions, and gate-level diagrams is important for exam problems.
Advanced Concepts and Applications

Cascading Multiplexers and Demultiplexers
A single MUX or DEMUX has a fixed number of inputs or outputs. Cascading connects multiple smaller devices together to handle more signals than one device can manage alone.
Here's how to build an 8-to-1 MUX from two 4-to-1 MUXes and one 2-to-1 MUX:
- Feed inputs through into the first 4-to-1 MUX. Feed inputs through into the second 4-to-1 MUX.
- Connect the two lower-order select lines () to both 4-to-1 MUXes so each one selects among its four inputs.
- Route the outputs of both 4-to-1 MUXes into a 2-to-1 MUX.
- Connect the highest-order select line () to the 2-to-1 MUX. When , the output comes from the first group (–); when , it comes from the second group (–).
Cascading DEMUXes follows the same idea in reverse: the higher-order select line directs the input to one sub-DEMUX, and the lower-order select lines pick the specific output within that stage.
Applications in Data Routing and Signal Processing
Multiplexers and demultiplexers appear in many real systems:
- Shared communication channels: In a computer network, several devices may need to send data over a single wire. A MUX selects which device's data gets transmitted at any given moment, letting multiple sources share one channel (this is the basis of time-division multiplexing).
- Signal distribution: A DEMUX can route a single video signal to one of several displays. The select lines determine which screen is active, so you can switch between monitors without duplicating hardware.
- Function generation: A MUX can implement any Boolean function by wiring the truth table outputs directly to the data inputs and using the function's variables as select lines. This is a common design trick that reduces gate count.
These components are building blocks you'll see again in memory addressing, bus architectures, and communication protocols.