A logic diagram consists of the following symbols (AND, OR, NOT) called gates:
Each gate has exactly one output (out)
and 1 or 2 inputs (called left, right
where the gate output is at the top and inputs are arranged at the
bottom as shown above). A wire has 2 ports: from, to. A wire connects from the output of one gate to the input of another. A pin is a label that is assigned to a
gate input or output.
A simple logic diagram D1 is shown
below. There are 5 pin labels (a, b, c, d, e). There are 4 gates: and1, and2, or3,
not4. Pin c corresponds to the left input of and2. There are 3 wires
(w1, w2, w3). Wire w2 connects the output of and2 to the right
input of or3.
Here is diagram D2 with 4 pins (a-d), 3 gates, 2 wires: