🏠 Home β€Ί 🧠 Logic β€Ί Lesson 3

🎯 AND, OR β€” Compound Inequalities, Absolute Value, De Morgan, and Systems

πŸ“– Lesson 3 of 10

πŸ“Œ Key idea of this section

AND is strict: BOTH parts must be true. AND shrinks a truth set to the overlap.
OR is generous: AT LEAST ONE part must be true β€” both is fine! OR glues truth sets together.
Negating swaps them: ¬(p ∧ q) = ¬p ∨ ¬q, and ¬(p ∨ q) = ¬p ∧ ¬q.

Glue two statements with AND or OR and the truth of the combo follows iron rules. Logicians write p ∧ q for "p AND q" and p ∨ q for "p OR q". The whole machine in one table:

p        q        p ∧ q      p ∨ q
──────   ──────   ────────   ───────
true     true     true       true
true     false    false      true
false    true     false      true
false    false    false      false

AND is only happy in the first row; OR is happy everywhere except the last. Warning about OR: in math, "p or q" means p, or q, or BOTH. So "2 is even OR 2 is prime" is TRUE β€” both halves true, and that's allowed.

Now watch what AND and OR do to open sentences β€” this is where it gets useful. Since an open sentence has a truth set, combining two of them combines their truth sets:

AND  =  the OVERLAP:  only the x's that make BOTH true
OR   =  the UNION:    every x that makes at least one true

Worked example 1 β€” an AND of two inequalities. Find the truth set of "2x + 3 ≀ 15 AND x βˆ’ 1 > 2".

Solve each half separately, every step with its reason:

2x + 3 ≀ 15                        x βˆ’ 1 > 2
2x ≀ 12          subtract 3        x > 3           add 1
x ≀ 6            divide by 2

AND means the overlap β€” the x's that satisfy BOTH: x ≀ 6 and x > 3. On a number line, the first ray covers everything left of 6 (including 6), the second covers everything right of 3 (excluding 3). Where they overlap:

Truth set:  3 < x ≀ 6
CHECK the boundary x = 6:  2(6) + 3 = 15 ≀ 15 βœ“  and  6 βˆ’ 1 = 5 > 2 βœ“  β€” in!
CHECK x = 3:  3 βˆ’ 1 = 2, and 2 > 2 is FALSE β€” out, as it should be.

Worked example 2 β€” an OR that can't be one chain. Find the truth set of "x + 4 < 2 OR 3x β‰₯ 21".

x + 4 < 2                          3x β‰₯ 21
x < βˆ’2           subtract 4        x β‰₯ 7           divide by 3

OR means the union β€” anything in EITHER piece counts:

Truth set:  x < βˆ’2 OR x β‰₯ 7.  (Two separate rays β€” no single chain can write this.)

Absolute value is AND and OR in disguise. Remember: |x| is the distance from x to 0, and distance is never negative.

|x| ≀ 4   means   "distance to 0 is at most 4"   β†’   βˆ’4 ≀ x ≀ 4      (an AND: x β‰₯ βˆ’4 AND x ≀ 4 β€” near 0)
|x| > 4   means   "distance to 0 is more than 4" β†’   x > 4 OR x < βˆ’4 (an OR: two far-away rays)

Memory hook: "less than" clusters close (AND, one piece); "greater than" splits far (OR, two pieces).

Worked example 3 β€” unlock an absolute value, AND style. Solve |x βˆ’ 3| ≀ 5.

βˆ’5 ≀ x βˆ’ 3 ≀ 5            "distance" reading: x βˆ’ 3 sits between βˆ’5 and 5
βˆ’5 + 3 ≀ x ≀ 5 + 3        add 3 to ALL THREE parts β€” keeps both inequalities true
βˆ’2 ≀ x ≀ 8                simplify
Truth set: βˆ’2 ≀ x ≀ 8.  CHECK x = βˆ’2: |βˆ’2 βˆ’ 3| = |βˆ’5| = 5 ≀ 5 βœ“.  CHECK x = 9: |9 βˆ’ 3| = 6 > 5 β€” out βœ“.

Worked example 4 β€” unlock an absolute value, OR style. Solve |x + 1| > 4.

x + 1 > 4  OR  x + 1 < βˆ’4     greater-than splits into two far rays
x > 3      OR  x < βˆ’5         subtract 1 from both sides of each piece
Truth set: x > 3 OR x < βˆ’5.
CHECK x = 4:  |4 + 1| = 5 > 4 βœ“ in.   CHECK x = βˆ’6: |βˆ’6 + 1| = |βˆ’5| = 5 > 4 βœ“ in.
CHECK x = 0:  |0 + 1| = 1, not > 4 β€” out βœ“.   CHECK the boundary x = βˆ’5: |βˆ’4| = 4, NOT > 4 β€” correctly excluded βœ“.

And now the gem β€” De Morgan's laws, for flipping a statement with AND or OR inside:

¬(p ∧ q)  =  ¬p ∨ ¬q
¬(p ∨ q)  =  ¬p ∧ ¬q

The NOT slips inside, and AND/OR SWAP. Why the swap? Think about failing each test: to fail an AND test you only blow ONE part ("you can't have cake AND ice cream" means no cake OR no ice cream β€” you're missing at least one, maybe just one). To fail an OR test you must blow BOTH ("not open Saturday OR Sunday" means closed Saturday AND closed Sunday). The law works for three parts too: Β¬(p ∧ q ∧ r) = Β¬p ∨ Β¬q ∨ Β¬r.

Worked example 5 β€” De Morgan with comparisons. Rewrite NOT (x > 2 AND x ≀ 9) without the leading NOT.

Β¬(x > 2  AND  x ≀ 9)
= Β¬(x > 2)  OR  Β¬(x ≀ 9)     De Morgan: NOT slips in, AND β†’ OR
= x ≀ 2  OR  x > 9           flip each comparison β€” boundaries switch teams (Lesson 2)
Sanity check: the original AND was true only on 2 < x ≀ 9; the flip should cover everything
OUTSIDE that β€” and x ≀ 2 OR x > 9 is exactly everything outside βœ“.
(Look back at Lesson 2's coming attraction: this is why the flip of the chain 2 < x ≀ 9
is x ≀ 2 OR x > 9. A chain is an AND, and De Morgan flips it into an OR.)

Worked example 6 β€” the other direction. Rewrite NOT (x < βˆ’1 OR x β‰₯ 6).

Β¬(x < βˆ’1  OR  x β‰₯ 6)
= Β¬(x < βˆ’1)  AND  Β¬(x β‰₯ 6)   De Morgan: NOT slips in, OR β†’ AND
= x β‰₯ βˆ’1  AND  x < 6         flip each comparison
= βˆ’1 ≀ x < 6                 AND = overlap, written as one chain

One last powerhouse for this section. A system of two equations is just an AND of two open sentences with two variables β€” and "solve the system" means find the overlap of the two truth sets: the pairs (x, y) that make BOTH true.

Worked example 7 β€” a system is an AND, by elimination. Solve: x + y = 12 AND x βˆ’ y = 4.

x + y = 12
x βˆ’ y = 4
2x = 16          add the two equations β€” equal plus equal stays equal;
                 the +y and βˆ’y cancel, which is the whole point
x = 8            divide both sides by 2
8 + y = 12       substitute x = 8 into the first equation β€” the value must work THERE too
y = 4            subtract 8 from both sides
CHECK BOTH β€” AND demands both!  First: 8 + 4 = 12 βœ“.  Second: 8 βˆ’ 4 = 4 βœ“.
Truth set: the single pair (8, 4).

Worked example 8 β€” a system by substitution. Solve: 2x + 3y = 24 AND x = y + 2.

The second equation hands you x ready-made β€” so plug it into the first:

2(y + 2) + 3y = 24      substitute x = y + 2 into 2x + 3y = 24 β€” replacing x with
                        an equal expression keeps the truth set unchanged
2y + 4 + 3y = 24        distribute the 2: 2Β·y + 2Β·2
5y + 4 = 24             combine like terms: 2y + 3y = 5y
5y = 20                 subtract 4 from both sides
y = 4                   divide both sides by 5
x = 4 + 2 = 6           substitute y = 4 back into x = y + 2
CHECK BOTH:  2(6) + 3(4) = 12 + 12 = 24 βœ“.  6 = 4 + 2 βœ“.
Truth set: the single pair (6, 4).

(If you ever graph these: each equation's truth set is a line, and the AND-overlap is exactly where the lines cross.)

✏️ Your Turn!

  • (a)
    Find the truth set: 3x βˆ’ 2 ≀ 13 AND x > 2.
  • (b)
    Rewrite |x| β‰₯ 2 without absolute value.
  • (c)
    Rewrite NOT (x β‰₯ 4 AND x < 12) without the leading NOT.
  • (d)
    Solve |x + 2| ≀ 3.
πŸ‘€ Show the answers

Answers: (a) 3x ≀ 15 β†’ x ≀ 5; overlap with x > 2 gives 2 < x ≀ 5. (b) x β‰₯ 2 OR x ≀ βˆ’2 (greater-than splits into two far rays). (c) De Morgan: x < 4 OR x β‰₯ 12 β€” the flip covers everything outside the original chain βœ“. (d) βˆ’3 ≀ x + 2 ≀ 3 β†’ subtract 2 from all three parts β†’ βˆ’5 ≀ x ≀ 1. CHECK x = βˆ’5: |βˆ’5 + 2| = |βˆ’3| = 3 ≀ 3 βœ“. CHECK x = 2: |2 + 2| = 4 > 3 β€” out βœ“.

V.3.1