Logic Gates
Logic gates are what allow computers and calculators to add, subtract, multiply and divide using only electric current.
A logic gate is simply an electric circuit with (usually) two inputs and an output . When the gate receives the two inputs it compares them, and depending on how they compare, it sends out a new electric current - (either on or off) . What that output is depends on what type of gate it is. There a lots of types but for KS3 / GSCE we only need to look at 3.
Each gate has its own diagram , notation (shown in brackets after the name of the gate) and truth table which shows the various inputs and outputs - In the truth table inputs and outputs are shown as 0 (off) and 1 (on)
AND Gate: (^)
If the two inputs are the same the AND gate gives a positive response.
OR Gate: (v)
If either of the inputs are positive the output is positive
NOT Gate : (¬)
Only takes 1 input and It reverses the input - if the input is on, output is off. If the input is off output is on.
Inputs | Output | |
A | B | O |
1 | 1 | 1 |
1 | 0 | 0 |
0 | 1 | 0 |
0 | 0 | 1 |
Inputs | Output | |
A | B | O |
1 | 1 | 1 |
1 | 0 | 1 |
0 | 1 | 1 |
0 | 0 | 0 |
Inputs | Output |
A | O |
1 | 0 |
0 | 1 |