Proof by Contrapositive

What is Proof by Contrapositive?

You want to prove: “If P, then Q.”

But sometimes the direct path is hard. So you prove the backwards opposite instead.


The Key Idea

Remember from logical equivalences:

PQ¬Q¬PP \to Q \equiv \neg Q \to \neg P

Negate both. Swap positions. They mean the same thing.


Example in plain English:

  • Original: “If it’s raining, the ground is wet.”
  • Contrapositive: “If the ground is NOT wet, it’s NOT raining.”

Same meaning. Proving one proves the other.


The Method

To prove PQP \to Q:

  1. Rewrite as the contrapositive: ¬Q¬P\neg Q \to \neg P
  2. Assume ¬Q\neg Q (the opposite of what you want to prove)
  3. Show ¬P\neg P follows
  4. Done — the original is proven

Can’t go forward? Go backward.


When to Use It

Use contrapositive when:

  • Direct proof gets stuck
  • The conclusion Q is hard to work with directly
  • The negation ¬Q gives you something concrete to start with

Example 1: Even Squares

Claim: If n2n^2 is even, then nn is even.


Why is direct proof hard?

You’d start with ”n2n^2 is even” and try to show ”nn is even.”

But n2=2kn^2 = 2k doesn’t easily tell you what nn is. Square roots get messy.


Contrapositive approach:

OriginalContrapositive
n2n^2 is even \to nn is evennn is odd \to n2n^2 is odd

Proof:

  • Assume nn is odd
  • So n=2k+1n = 2k + 1 for some integer kk

Square it:

n2=(2k+1)2=4k2+4k+1=2(2k2+2k)+1\begin{aligned} n^2 &= (2k + 1)^2 \\ &= 4k^2 + 4k + 1 \\ &= 2(2k^2 + 2k) + 1 \end{aligned}
  • That’s 2(something)+12(\text{something}) + 1 — which is odd

We proved odd → odd. So the original even → even is true.


Example 2: Odd Products

Claim: If a×ba \times b is odd, then aa is odd.


Why is direct proof hard?

Starting with “product is odd” doesn’t easily tell you about aa alone.


Contrapositive approach:

OriginalContrapositive
abab is odd \to aa is oddaa is even \to abab is even

Proof:

  • Assume aa is even
  • So a=2ka = 2k for some integer kk

Multiply:

a×b=2k×b=2(kb)\begin{aligned} a \times b &= 2k \times b \\ &= 2(kb) \end{aligned}
  • That’s 2×(something)2 \times (\text{something}) — which is even

Even times anything is even. Simple.


Example 3: Trapped Variables

Claim: If 3n+23n + 2 is odd, then nn is odd.


Why is direct proof hard?

Starting with 3n+2=2k+13n + 2 = 2k + 1 gives you 3n=2k13n = 2k - 1.

Now what? Dividing by 3 is messy. The variable nn is “trapped.”


Contrapositive approach:

OriginalContrapositive
3n+23n + 2 is odd \to nn is oddnn is even \to 3n+23n + 2 is even

Proof:

  • Assume nn is even
  • So n=2kn = 2k for some integer kk

Substitute:

3n+2=3(2k)+2=6k+2=2(3k+1)\begin{aligned} 3n + 2 &= 3(2k) + 2 \\ &= 6k + 2 \\ &= 2(3k + 1) \end{aligned}
  • That’s 2×(something)2 \times (\text{something}) — which is even

Contrapositive “frees” the trapped variable. Start with n, not 3n + 2.