How does a computer make a decision?
A computer does not understand uncertainty in the way a person does. It works with clear binary states.
A decision is reduced to two possible answers: TRUE or FALSE, ON or OFF, and 1 or 0.
Logic gates are tiny electronic decision-makers. They receive binary inputs, apply a rule and produce one binary output.
A computer does not understand uncertainty in the way a person does. It works with clear binary states.
A decision is reduced to two possible answers: TRUE or FALSE, ON or OFF, and 1 or 0.
Each gate receives one or more binary inputs. The type of gate determines the rule that is applied.
A switch can be either off or on. A light can also be off or on.
The wiring between the switches and the light acts like a rule. Different wiring rules produce different results.
Logic gates perform the same job electronically. They decide whether the output should switch on.
The exact output depends on which logic-gate rule is used.
A single gate makes one very small decision. Digital devices combine huge numbers of gates to perform useful tasks.
Imagine an alarm system with two inputs:
The door opens, so input A becomes 1. The system is armed, so input B is also 1. A logic gate uses these inputs to decide whether output X should become 1 and activate the alarm.
A logic gate stores binary data for later.
A logic gate processes binary inputs and immediately produces an output.