Science

De Morgan's Laws

The opposite of 'it's both rainy and windy' isn't 'it's neither rainy nor windy'—it simply means 'at least one of those isn't true.'

  • 2 min read
  • 2 figures
  • Verified 2026-10-12

Definition

De Morgan's laws are fundamental rules in logic and mathematics stating that when you negate a combined statement, 'AND' flips to 'OR', and 'OR' flips to 'AND'. They help simplify complicated logical conditions and sets by neatly turning statements inside out.

Who Misses Out on the Discount?

Imagine a restaurant runs a special promotion: "Discounts only for guests who are over six feet tall and wearing glasses." Who gets left out? At first glance, you might only think of someone who is short and doesn't wear glasses. But that's not the full story.

A tall person who doesn't wear glasses misses the discount. Someone wearing glasses who isn't over six feet tall misses it too. To break the rule of "you must satisfy both conditions," failing just one condition is enough.

In everyday life, when reversing a bundled requirement, people often assume every single factor must turn into its exact opposite. In reality, breaking a single piece is enough to break the entire requirement. De Morgan's laws cleanly describe this subtle logic of negation.

Open the Parentheses, Flip the Sign

Looking at logic notation makes this principle crystal clear. When you apply a NOT to the combined condition '(A AND B)', the parentheses dissolve, negating both A and B individually, while 'AND' flips into 'OR'.

What happens when you negate '(A OR B)'? Suppose you declare, "I will order pizza or a burger." The direct opposite of that statement is "I will not order pizza and I will not order a burger." Denying an 'OR' statement forces both sides to be rejected with an 'AND'. Remember that in formal logic, 'OR' includes the case where both are true.

In mathematics, this symmetry is written with set theory symbols: intersection (∩) and union (∪). When the complement symbol outside parentheses enters inside, an intersection flips into a union, and a union flips into an intersection.

Behind the Scenes: Computer Chips and Search Engines

To be more precise, De Morgan's laws aren't just theoretical puzzles; they form the backbone of computer engineering and microchips. Computers perform calculations using binary logic signals: TRUE (1) when current flows and FALSE (0) when it doesn't.

The more complex the logic gates inside a processor, the more transistors it needs and the more heat it generates. By using De Morgan's laws, circuit designers can convert combinations of AND and OR gates into uniform gates like NAND or NOR, which are cheaper and easier to manufacture. This keeps silicon chips compact and power-efficient.

These rules also work behind the scenes in search engines. When you search using complex filters and exclusions, query processors apply De Morgan's laws to simplify search criteria so database engines can return matching web pages in milliseconds.

Common misconceptions

Myth

The opposite of 'A AND B' is always 'neither A nor B.'

Fact

Both do not need to be false. If either one fails, the original statement is already broken. Therefore, the proper negation is 'not A, OR not B.'

Where you meet it

  1. The opposite of 'it will rain and be windy this weekend' is 'it won't rain, or it won't be windy.'

  2. Missing out on 'scoring 100 in math OR scoring 100 in English' means 'not scoring 100 in math AND not scoring 100 in English.'

In one sentence

A logical rule showing that when negating grouped statements, 'AND' flips to 'OR', and 'OR' flips to 'AND'.

Created 2024-12-24 Updated 2026-10-12 Verified 2026-10-12