Warm-up · True or false?
Slide 3Decide whether each claim is true or false. How sure are you, and why?
(a) All prime numbers are odd.
Show answerHide answer
Answer
False.
Why
2 is prime and even, so 2 is a counterexample. One counterexample is enough to disprove a “for all” claim.
(b) n2+n+41 is prime for every
n∈N.
Show answerHide answer
Answer
False, although it works for
n=0 to
39.
Why
For
n=40:
1600+40+41=1681=412. Many examples never prove a statement about infinitely many cases, but one counterexample disproves it.
(c) The sum of two odd numbers is even.
Show answerHide answer
Answer
True.
Why
Checking examples such as
3+5=8 is not a proof. We prove this in Lesson 3.
(d) If
x2=9, then
x=3.
Show answerHide answer
Answer
False.
Why
x=−3 satisfies
x2=9 but not
x=3, so it is a counterexample.
What is a proof? The road map for this unit
Slide 2Definition
ProofA logical argument showing that a statement is always true. A single counterexample shows that it is not.
In this unit you will learn the language of logic, then several ways to build a proof.
A proof is written for other readers, so clear setting out and signposts are part of the mark.
Key terms and notation
Slide 4The syllabus writes = between logically equivalent statements; here we write ≃ to avoid confusion with equality. Both appear in exam papers. The converse, equivalence, contrapositive and quantifiers are developed in Lesson 2.
Statements
Slide 5Definition
Statement (proposition)A statement is a sentence that is either true or false, but not both. Its logical value is true or false.
We name statements with capital letters, starting at P. For example, P: n is a multiple of 3.
Example 1 · Which are statements? If so, true or false?
(a) There are kangaroos in Australia.
Show answerHide answer
Answer
A statement, and it is true.
Why
It is a sentence that is either true or false.
(b) Close the door.
Show answerHide answer
Answer
Not a statement.
Why
It is a command, so it is neither true nor false.
Show answerHide answer
Answer
Not a statement until
x is known.
Why
Its logical value depends on
x. It becomes a statement with a quantifier, for example
∃x∈R such that
x+1=5, which is true (Lesson 2).
(d) 16 is an odd number.
Show answerHide answer
Answer
A statement, and it is always false.
Why
A statement can be false. What matters is that it has a definite logical value.
(e) History is more interesting than Science.
Show answerHide answer
Answer
Not a statement.
Why
It is an opinion, which has no logical value.
Examples and counterexamples
Slides 6, 7Definition
Proving and disproving with examplesProof by exhaustion: check every possible case. It is valid, but only practical when there are few cases.
Counterexample: one example showing that a statement is not always true. One counterexample disproves a statement.
No number of examples can prove a statement about infinitely many cases.
Example 2 · Exhaustion and counterexample
(a) Prove by exhaustion: all odd integers between 16 and 20 are prime.
Show answerHide answer
Answer
The odd integers between 16 and 20 are 17 and 19. Both are prime, so the statement is proved.
Why
There are only two cases, so we can check them all. That is what makes the proof valid.
(b) Disprove: all primes are odd.
Show answerHide answer
Answer
2 is prime and even, so the statement is false.
Why
A single counterexample is enough to disprove a “for all” statement.
HSC practice · A counterexample
Slide 8Adapted from 2020 HSC Q7Consider the claim: “If
n is prime, then
2n−1 is prime.” Which value of
n is a counterexample?
A n=2B n=3C n=7D n=11 Show answerHide answer
Answer
D
Why
211−1=2047=23×89, and 11 is prime. For A, B and C:
22−1=3,
23−1=7 and
27−1=127 are all prime, so they agree with the claim and are not counterexamples. A counterexample must make the “if” part true and the “then” part false.
Negation
Slide 9Definition
Negation ¬P“not P”. It has the opposite logical value to P. Also written ∼P.
Watch the word “all”
P: All cats are fluffy.
Correct ¬P: Not all cats are fluffy, so there exists a cat that is not fluffy.
Incorrect: “All cats are not fluffy.” This says no cat is fluffy, which is too strong.
Test: exactly one of P and ¬P is true. If you can imagine both being false, your negation is wrong.
Example 3 · Negation
Slide 10Write the negation of each statement.
Show answerHide answer
Answer
It is not raining.
Why
The simplest case:
¬P is “not
P”.
2. Q: All dogs are brown.
Show answerHide answer
Answer
Not all dogs are brown: there is a dog that is not brown.
Why
Do not write “all dogs are not brown”. That says no dog is brown, which is too strong.
3. R: The bottle of water is full.
Show answerHide answer
Answer
The bottle of water is not full.
Why
Not “empty”. A half-full bottle is neither full nor empty.
4. S: Some students ride to school.
Show answerHide answer
Answer
No students ride to school.
Why
The opposite of “some” is “none”.
Show answerHide answer
Answer
Why
Not
x<4. The negation must include the boundary case
x=4.
6. U:
−3≤x≤8 Show answerHide answer
Answer
x<−3 or
x>8 Why
The “and” hidden in
−3≤x≤8 (that is,
x≥−3 and
x≤8) becomes “or”. This previews the negation rules later in the lesson.
“And” and “or”
Slide 11Definition
And (∧) and Or (∨)P∧Q is true only when both P and Q are true.
P∨Q is true when at least one of P, Q is true (inclusive or).
Truth tables use 1 for true and 0 for false. Order of precedence: ¬, then ∧, then ∨.
Capital letters are reserved for statements, so truth values are written 1 and 0 rather than T and F.
Example 4 · P: 6 is even, Q: 6 is prime
(a) Is
P∧Q true?
Show answerHide answer
Answer
No,
P∧Q is false.
Why
P is true and
Q is false. Both must be true for “and”.
(b) Is
P∨Q true?
Show answerHide answer
Answer
Yes,
P∨Q is true.
Why
At least one must be true, and 6 is even.
Implication
Slide 12Definition
Implication P⇒QP⇒Q (or P→Q) is read “if P then Q” or “P implies Q”.
Bob to Jane: “If you give me $100, then I will go shopping.” P: Jane gives Bob $100. Q: Bob goes shopping.
When has Bob lied? Complete the truth table for
P⇒Q,
¬P and
¬P∨Q. Then complete:
P⇒Q is false only when …
Show answerHide answer
Answer
P⇒Q is false only when
P is true and
Q is false.
Why
Bob only lies when Jane pays and he does not go shopping (row 2). If Jane never pays, Bob cannot have broken his promise, so
P⇒Q is true. This is called being vacuously true. The columns for
P⇒Q and
¬P∨Q are identical, so
P⇒Q≃¬P∨Q.
| P | Q | P⇒Q | ¬P | ¬P∨Q |
|---|
| 1 | 1 | 1 | 0 | 1 |
| 1 | 0 | 0 | 0 | 0 |
| 0 | 1 | 1 | 1 | 1 |
| 0 | 0 | 1 | 1 | 1 |
No causal link needed
“If ABCD is a rectangle, then today is Sunday.” An implication needs no causal link between P and Q. Its truth depends only on the truth values of P and Q.
Example 5 · Testing an implication
Slide 13P:
x is a multiple of 6.
Q:
x is divisible by 9. Complete a truth table for
P⇒Q, giving a value of
x for each row. Is the implication always true?
Show answerHide answer
Answer
No.
x=24 is a counterexample, so
P⇒Q is not always true.
Why
One value of
x for each row:
| P | Q | Example of x | P⇒Q |
|---|
| 1 | 1 | 18 | 1 |
| 1 | 0 | 24 | 0 |
| 0 | 1 | 27 | 1 |
| 0 | 0 | 25 | 1 |
Rows 3 and 4 are true because
P is false (vacuously true). Row 2 is the only row where the implication fails: 24 is a multiple of 6 but not divisible by 9.
Negating “and”, “or”, “if…then”
Slide 14Useful equivalence
P⇒Q≃¬P∨Q≃¬(P∧¬Q)“If P then Q” only fails when P is true and Q is false. So ¬(P⇒Q) says exactly that: P∧¬Q.
De Morgan’s laws for sets: A∩B=A∪B and A∪B=A∩B. Same pattern: ∧ matches ∩ and ∨ matches ∪.
Common error
Writing ¬(P⇒Q) as P⇒¬Q. The negation of an implication is an “and” statement, not another implication.
Example 6 · Negating compound statements
Slide 15Write the negation of each statement.
(a) x>2 and
x is even.
Show answerHide answer
Answer
x≤2 or
x is odd.
Why
Negating “and” gives “or”, and each part is negated:
¬(P∧Q)≃¬P∨¬Q. (For an integer
x, “not even” means odd.)
(b) n is odd or
n is a multiple of 3.
Show answerHide answer
Answer
n is even and
n is not a multiple of 3.
Why
Negating “or” gives “and”:
¬(P∨Q)≃¬P∧¬Q. Both parts have to fail.
(c) If
n is even, then
n2 is even.
Show answerHide answer
Answer
n is even and
n2 is odd.
Why
¬(P⇒Q)≃P∧¬Q. Keep the hypothesis and deny the conclusion. Do not write “if
n is even then
n2 is odd”, which is another implication.
(d) If I live in Tasmania, then I live in Australia.
Show answerHide answer
Answer
I live in Tasmania and I do not live in Australia.
Why
Again
P∧¬Q. (The original is true, so this negation is false for everyone.)
Exit ticket
Slide 161. Which is the negation of “If
n is prime, then
n is odd”?
A n is not prime and n is even.B n is prime and n is even.C If n is odd, then n is prime.D n is not prime or n is odd. Show answerHide answer
Answer
B
Why
¬(P⇒Q)≃P∧¬Q: “
n is prime and
n is not odd”, and not odd means even. A negates both parts. C is the converse. D is equivalent to the original statement (
¬P∨Q).
2. Which is logically equivalent to
P⇒Q?
A Q⇒PB P∧¬QC ¬P∨QD ¬P∧Q Show answerHide answer
Answer
C
Why
P⇒Q≃¬P∨Q, as the truth table shows. B is the negation of
P⇒Q. A is the converse. D is false when
P and
Q are both true, but
P⇒Q is true then.