1-to-2 demultiplexer: circuit and truth table, live
A 1-to-2 demultiplexer sends one data input D to one of two outputs, chosen by a select input S: with S = 0 the data appears on Y0, with S = 1 on Y1, and the unselected output stays 0. It takes one NOT gate and two AND gates: Y0 = D AND NOT S, Y1 = D AND S.
A demultiplexer is the mirror image of a 2-to-1 multiplexer: the mux picks one of two inputs for a single output, the demux steers a single input to one of two outputs. Put the two together with the same select line and you have a way to share one wire between two pairs of devices, which is the idea behind time-division multiplexing. With D held at 1, the circuit is a 1-to-2 decoder: S picks which output goes high, and D works as an enable. Larger demultiplexers grow the same way: the 1-to-4 demultiplexer uses a 2-bit select and four AND gates, and the 1-to-8 demultiplexer a 3-bit select. All four input rows are checked before the page is built.
Open this circuit in the lab →
What you need
- 1× NOT: NOT S
- 2× AND: Y0 = D AND NOT S, Y1 = D AND S
Step by step
- Place inputs
D(data) andS(select) and probesY0andY1. - Invert S with a NOT gate.
- AND D with NOT S for
Y0, and D with S forY1. - Set D = 1 and flip S: the 1 moves from Y0 to Y1.
1-to-2 demultiplexer truth table
| S | D | Y0 | Y1 |
|---|---|---|---|
| 0 | 0 | 0 | 0 |
| 0 | 1 | 1 | 0 |
| 1 | 0 | 0 | 0 |
| 1 | 1 | 0 | 1 |
The selected output copies D; the other output is 0. Read with D as an enable, the same table is a 1-to-2 decoder: each value of S makes exactly one output high.
You can also read the full theory in the lesson on encoders and demultiplexers. Prefer to build it yourself from scratch? Open the digiwleea lab and place the gates on the canvas, or start from the logic gate simulator.
Build more parts from gates
Each of these is one step from a transistor to a working CPU. Build every gate from CMOS transistors and work all the way up in the free digiwleea lab, with the free theory reference alongside.
Open the 1-to-2 demultiplexer in the lab →Frequently asked
What is a 1-to-2 demultiplexer?
A circuit with one data input D, one select input S and two outputs. It routes D to Y0 when S = 0 and to Y1 when S = 1, holding the other output at 0.
How many gates does a 1-to-2 demultiplexer need?
Three: one NOT gate for NOT S and two AND gates, Y0 = D AND NOT S and Y1 = D AND S.
What is the difference between a demultiplexer and a decoder?
A decoder turns a code into one active output; a demultiplexer also has a data input that is copied to the selected output. A demultiplexer with its data input held at 1 is a decoder, and a decoder with an enable input is a demultiplexer.
How do you make a 1-to-4 demultiplexer from 1-to-2 demultiplexers?
Use three: the first, selected by the high select bit, sends D to one of two second-level demultiplexers, which are both selected by the low bit and give the four outputs.