3-to-8 Decoder
How the 2-to-4 decoder pattern scales to three select bits and eight one-hot output lines.
Updated 2026-07-09
A 3-to-8 decoder receives a three-bit select value and drives exactly one of eight output lines high. The three select bits name eight possible binary values, from 000 through 111, so the output bus needs eight bits.
The implementation pattern is the same as a 2-to-4 decoder: assign the entire output bus to zero at the top of the combinational block, then use one case item per input value to set the matching output bit to 1. That top-level default leaves every non-selected output low and prevents a previous value from being retained on an uncovered path.
For example, select value 3'b101 maps to y[5], producing 8'b00100000. The select's binary value and the asserted output index always match.