Multiplexer
Multiplexer / Mux: If-statements for circuits (connect different paths based on $s$)
- Have $n$ selectors ($s$), $2^n$ inputs ($d$) and one output
- 2:1 Multiplexer: When $s=0$, return $d_0$. When $s=1$, return $d_1$
- 4:1 Multiplexer: Choose from 4 inputs $(d_0, \dots d_4)$ based on 2 selectors $s_0,s_1$
Can be implemented using three 2:1 multiplexers.
Demultiplexer / Demux: Reverse multiplexer, $s$ choose which output to connect to
- Have one input $d$, $n$ selector inputs ($s$), $2^n$ outputs
Encoder & Decoder
Encoder: $2^N\to N$
- Binary one-hot input translated to N-bit output
- One-hot: Exactly one input bit is 1, others are 0.
Decoder: $N\to 2^N$
- Connect one output pin (one-hot output) based on N-bit input
Delay
- Measured from the half-way point between A and Y

- Propagation Delay: $t_{pd}$ Max time from input change until all outputs finish changing
Contamination Delay: Min time from input change until any output starts changing
- Each logic gate has a delay in picoseconds (NOT: 30, AND: 60, 3-input AND: 80, etc.)
- Critical Path: Slowest path through the circuit
Short Path: Fastest path through the circuit
- Delay of a circuit is equal to the delay of the critical path
Arithmetic