15 October 2026
Understanding the electricity behind logic gates
It sounds like a trick question from a GCSE Computer Science exam: if a NOT gate turns a zero into a one, where does that one actually come from? Surely computers can’t create something from nothing?
The answer lies in understanding what zero and one really mean in digital logic. A logical zero doesn’t mean there’s no electricity. Instead, it represents a specific voltage level, usually close to zero volts. A logical one represents a voltage closer to the chip’s supply voltage.
In other words, the electricity was there all along!
How does a NOT gate work?
A NOT gate is one of the simplest logic gates in Computer Science. Its job is to invert its input: if the input is 0, the output is 1; if the input is 1, the output is 0.
But how does it achieve this physically?
Inside a modern NOT gate is a circuit called a CMOS inverter, built using two types of transistor: PMOS and NMOS. These tiny electronic switches connect the output to either the power supply, known as VDD, or ground.
When the input is low, the PMOS transistor switches on while the NMOS switches off. This connects the output to the power supply, producing a logical 1.
When the input is high, the opposite happens. The PMOS switches off and the NMOS switches on, connecting the output to ground and producing a logical 0.
The NOT gate isn’t creating electricity. It’s simply controlling where the output voltage comes from.
From tiny transistors to powerful processors
This simple process is fundamental to modern computing. Billions of transistors work together inside CPUs, following carefully designed patterns to process data and carry out instructions.
When we talk about a processor making decisions, we’re ultimately talking about electronic circuits switching between different voltage levels.
Understanding how transistors work helps students connect the theory of logic gates and Boolean logic with the physical components inside a computer. It’s a great example of how abstract Computer Science concepts translate into real-world technology.
Why zero and one aren’t quite so simple
There’s one final detail worth understanding: digital logic uses voltage thresholds rather than requiring perfectly exact values.
A logical 0 doesn’t always have to be precisely zero volts, and a logical 1 doesn’t have to equal the supply voltage exactly. Circuits use defined voltage ranges to decide whether a signal should be interpreted as high or low.
These thresholds help computers handle small variations in voltage and electrical noise reliably.
So, the next time someone asks where the 1 comes from when a NOT gate receives a 0, remember: the chip was powered the whole time. The gate simply switches the output to the appropriate voltage level.
Watch the video and explore more
Watch the video to see how a NOT gate works and discover the electronics behind digital logic.
Visit the Craig’n’Dave website at Craigndave.org for more Computer Science videos, teaching resources and revision tools to support your learning.
