

Multiplexers
In this lesson you will see how multiplexers work and how they are implemented with logic gates.
In electronics, a multiplexer (or MUX) is a device that selects a signal from among multiple input signals and forwards it to a single output line. In the context of digital circuits, the inputs are digital (bits), although multiplexers for analog signals also exist.
Multiplexers can also be used to implement Boolean functions of multiple variables.
Example: 2-input Multiplexer
Imagine we have two different data sources, possibly two sensors, and we need a circuit that selects which of these signals will be sent to a processor.
We will design a 2-input multiplexer (in_1, in_2) and 1 output (out). A special input is the selector (Sel), responsible for choosing which of the two inputs will be sent to out.
In this example we want:
- When
, the output should be . - When
, the output should be .
First, we construct the truth table with all possible values of the inputs and the selector:
Truth table
| 0 | 0 | 0 | 0 |
| 0 | 1 | 0 | 1 |
| 1 | 0 | 0 | 0 |
| 1 | 1 | 0 | 1 |
| 0 | 0 | 1 | 0 |
| 0 | 1 | 1 | 0 |
| 1 | 0 | 1 | 1 |
| 1 | 1 | 1 | 1 |
The simplified Boolean expression for the output is:
Next we draw the associated logic circuit:

Jutge.org exercises: [Introduction to Digital Circuit Design]
Remember that to access the exercises and for the Judge to evaluate your solutions you must be enrolled in the course. You will find all instructions here.



Xavier Casas, Francesc Madrid
Lliçons.jutge.org
© Universitat Politècnica de Catalunya, 2026
