Design a logic circuit to convert a single digit BCD number to the number modulo six as follows (Do not detect illegal input): A. Write the truth table for all bits. Label the input bits I3, I2, I1, I0 with I0 as the least significant bit. Label the output bits O2, O1, O0 with O0 as the least significant bit. Use 1 to signify truth. B. Draw the circuit for each output bit using altogether, two two-input AND gates, one two-input OR gate and one NOT gate.

GATE 2000 · Digital Logic · Min No Gates · medium

Answer: 4 gates (two two-input AND gates + one two-input OR gate + one NOT gate)

  1. Build the truth table for BCD mod-6: Input 0(0000)->0(000), 1(0001)->1(001), 2(0010)->2(010), 3(0011)->3(011), 4(0100)->4(100), 5(0101)->5(101), 6(0110)->0(000), 7(0111)->1(001), 8(1000)->2(010), 9(1001)->3(011). For inputs 10-15 (illegal): don't care.
  2. Derive minimal Boolean expressions and count gates: After K-map simplification, each output bit can be realized using at most 2 AND + 1 OR + 1 NOT. The problem statement confirms: 'draw the circuit for each output bit using altogether two two-input AND gates, one two-input OR gate and one NOT gate.' Total gates = 2 + 1 + 1 = 4.