Two expressions are equivalent (or equal) when they produce the same output on every row of the truth table. They are then two ways of writing one boolean function, and a circuit built from either does exactly the same job.
There are two ways to show equivalence:
- Truth table (perfect induction): compare the output columns row by row. All must match.
- Algebra (algebraic proof): rewrite one expression into the other using the laws of boolean algebra.
To show two expressions are not equivalent, one row where they differ is enough. That row is a counterexample.
Equivalence is what makes simplification safe. Every law is an equivalence, so each step keeps the function the same while the expression gets cheaper.
A quick self-check after any simplification: plug in a couple of rows, ideally ones where the terms you changed matter. It won't prove you are right, but it catches most slips.
| 0 | 0 | 0 | 0 | 0 |
| 0 | 0 | 1 | 0 | 0 |
| 0 | 1 | 0 | 1 | 1 |
| 0 | 1 | 1 | 1 | 1 |
| 1 | 0 | 0 | 0 | 0 |
| 1 | 0 | 1 | 1 | 1 |
| 1 | 1 | 0 | 0 | 0 |
| 1 | 1 | 1 | 1 | 1 |