Skip to content
Tactiverge

Digital logic

Flip binary inputs to watch signals move through logic gates, then wire your own gates to match a target truth table.

Equation
A NAND B = NOT (A AND B)
Equation
A XOR B = (A AND NOT B) OR (NOT A AND B)
Equation
Half adder: sum = A XOR B, carry = A AND B

Explorer 05 — Digital logic

Build answers out of ones and zeros

Every digital chip is built from a handful of simple gates. Flip the inputs to watch signals travel through a circuit, then wire your own gates to meet a target truth table.

ONE GATE · 1 GATE DEEP0A0BAND= 0G10Y
  • 1 (high)
  • 0 (low)
  • Unknown
  • Inverting output
Mode
Starting circuit

A single two-input gate. Change its type and watch the truth table change.

Inputs

Gates (1 of 8)

  1. G1 = 0

Add a gate

Outputs

Gates
1
Depth
1
Longest chain of gates a signal passes through
Rows
4
2^2 input combinations
Check
—
Truth table
Set inputsABY
000
010
100
111

State

Inputs A = 0, B = 0. Outputs Y = 0.

Inputs A = 0, B = 0. Outputs Y = 0.

How to read this

Signals flow left to right. Circles on the left are the inputs, boxes are gates and squares on the right are outputs. A thick bright wire carries a 1, a thin grey wire carries a 0, and each gate shows the value it outputs. A small circle on a gate's output means it inverts (NOT, NAND, NOR, XNOR).

The truth table lists every possible input combination and what the circuit outputs for each, so it describes the circuit completely. Two circuits with the same truth table are equivalent, however differently they are built. That is why NAND alone can make any other gate. Choose a row to set the inputs to it.

Assumptions & limitations
  • Ideal logic: every wire is exactly 0 or 1. Real gates use voltage ranges (for example near 0 V and near 3.3 V or 5 V) and an input between them is undefined.
  • Gates switch instantly here. Real gates take nanoseconds each, so a deeper circuit is slower, and outputs can glitch briefly while signals race through different paths.
  • Only combinational circuits are allowed: no output may feed back into its own input. Feedback is how memory (latches and flip-flops) works, but it needs timing this model does not simulate, so loops are reported as an error.
  • Gates here have one input (NOT) or two inputs. Real chips also have three- and four-input gates, and limits on how many inputs one output can drive (fan-out).
  • Gate counts are a simple measure of size; real designs also weigh speed, power and the number of transistors per gate.

Guided experiments

Set up the lab as described, then enter what you measure. Answers are checked on the server.

  1. E1A vote of three

    1. Build a majority-of-three circuit: the output is 1 when at least two of A, B and C are 1.
    2. One way: (A AND B) OR (B AND C) OR (A AND C). Toggle the inputs and read the truth table.

  2. E2Everything from NAND

    1. Open challenge mode and choose “XOR from NAND only”.
    2. Build it, then try to use as few gates as you can.