Discrete Math9 min read

Converse, Inverse, and Contrapositive

Three rearrangements of one if–then sentence, and only one of them means the same thing. Getting it wrong is the most expensive two seconds on a logic test — and it is entirely mechanical to get right.

Start with a promise#

Here is a promise: “If it rains, I will bring an umbrella.”

Below are three rearrangements. Decide which ones mean the same thing as the promise before you read the answers. Most people get one of these wrong, and it is the same one every time.

  • “If I brought an umbrella, then it rained.” — No. I might carry one on a cloudy day just in case. Bringing an umbrella does not prove it rained.
  • “If it does not rain, I will not bring an umbrella.” — No, and for the same reason. I never promised to leave it at home on dry days.
  • “If I did not bring an umbrella, then it was not raining.” — Yes. That one is the original promise, said backwards. If I always bring one when it rains, a day with no umbrella has to be a day with no rain.

Two of those three are different promises. Exactly one is the same promise. The first one — umbrella, therefore rain — is the one almost everybody accepts by mistake. In real life we usually do carry an umbrella because it is raining. The promise never said that. The promise never said that. The rest of this page gives them names, and a way to build each without mixing them up.

What each rearrangement is called#

An if–then sentence is called a conditional. The two halves get letters: p is the “if” half and q is the “then” half, so the whole thing is written p → q. The arrow is read “if … then”, and ¬ in front of something means “not”.

In the umbrella promise, p is “it rains” and q is “I bring an umbrella”.

NameFormWhat changed
Originalp → q—
Converseq → pSwapped
Inverse¬p → ¬qNegated
Contrapositive¬q → ¬pNegated and swapped

Matching them to what you just decided: the converse was the umbrella-so-it-rained one, the inverse was the no-rain-so-no-umbrella one, and the contrapositive was the one that meant the same thing.

The one fact to carry into the exam

A conditional always means the same as its contrapositive, and never means the same as its converse or its inverse. Separately, the converse and the inverse mean the same as each other.

That second sentence is not a bonus fact to memorize. It falls out of the first: the inverse ¬p → ¬q is itself the contrapositive of the converse q → p. Every equivalence on this page is really the same one used twice.

Building each one without slipping#

Do it in two separate passes, not one. Trying to negate and swap in a single motion is exactly how the inverse and the contrapositive get mixed up.

  • Write down p and q separately before touching anything. Say them out loud.
  • Swap only → that is the converse.
  • Negate only → that is the inverse.
  • Do both → that is the contrapositive.

Try it on a real one. Take: “If n is an even whole number bigger than 2, then n is the sum of two primes.”

Here p is “n is an even whole number bigger than 2” and q is “n is the sum of two primes”.

  • Converse: If n is the sum of two primes, then n is an even whole number bigger than 2.
  • Inverse: If n is not an even whole number bigger than 2, then n is not the sum of two primes.
  • Contrapositive: If n is not the sum of two primes, then n is not an even whole number bigger than 2.

Look at the converse. It is plainly false: 5 = 2 + 3 is a sum of two primes, and 5 is not even. Meanwhile the original statement is a famous unsolved problem — nobody knows whether it is true. One of them is definitely false and the other is an open question, so they cannot be the same statement. The contrapositive, on the other hand, is exactly as unsolved as the original, because it is the original.

The table that settles it#

Four rows, and every claim on this page is visible in them. A truth table just lists every possible combination of true and false for p and q, then works out what each statement comes to.

1 means true and 0 means false — the notation used in the truth tables below.

pqp → qq → p¬p → ¬q¬q → ¬p
111111
100110
011001
001111

Read the columns, not the rows. Column 3 (the original) and column 6 (the contrapositive) are identical all the way down — that is the equivalence, sitting there in plain sight. Columns 4 and 5, the converse and the inverse, are identical to each other and different from the first pair. The two disagreements both sit in the middle rows, exactly where p and q have opposite values.

Notice the bottom two rows are all 1. When p is false, the whole if–then comes out true no matter what q does. A promise about rainy days is not broken by a sunny one.

Why the contrapositive earns its keep#

This equivalence is not trivia. It is what lets you prove something by proving its contrapositive instead — assume ¬q, work your way to ¬p, and you are done. That is allowed precisely because the two are the same statement.

It pays off whenever the backwards version is easier to compute with. Take: if n² is even, then n is even. Starting from “n² is even” gives you n² = 2k, and getting anything about n out of that is hard work. Starting from the contrapositive — assume n is odd — gives you n = 2m + 1 straight away. Then n² = 4m² + 4m + 1 = 2(2m² + 2m) + 1, which is odd. Three lines, no machinery.

A rule of thumb

If the “if” half is a negative — “is not divisible by”, “has no solution”, “is irrational” — try the contrapositive first. Negatives are awkward to calculate with. Their opposites usually are not.

The words that cause the swap#

Most converse mistakes do not happen in symbols. They happen one step earlier, in English, when the sentence gets translated. All four of these mean p → q:

EnglishSymbolsWhy
If p, then qp → qThe plain version.
p only if qp → qThe “only if” part is the second half.
q whenever pp → qEvery time p happens, q happens.
q is necessary for pp → qYou cannot have p without q.

And these two mean the reverse, q → p:

EnglishSymbolsWhy
p if qq → pA bare “if” introduces the first half.
q is sufficient for pq → pq on its own is enough to get p.

The pair worth burning in is necessary versus sufficient. Sufficient goes in front of the arrow. Necessary goes behind it. “Only if” behaves like “necessary”, which is why it points the opposite way from a plain “if” — a genuinely confusing fact about English, not about logic.

“If and only if” is neither. It claims both directions at once, and is written p ↔ q. It says more than p → q does, so translating a one-way sentence that way is wrong.

Where these go wrong#

  • Assuming the converse. The headline error, and it survives well outside the classroom — “all fraud is unusual, so anything unusual is fraud” is this mistake wearing a suit. Proving q → p when you were asked for p → q earns nothing, however good the work is.
  • Negating without swapping. That gives the inverse, not the contrapositive. If your two halves are still in the same order, you did not build the contrapositive.
  • Negating only one half. ¬q → p and q → ¬p are none of the three named forms. Both halves change, or neither does.
  • Negating an “and” carelessly. The opposite of “n is even and n > 2” is “n is odd or n ≤ 2”. The connective flips too. Leaving it as “and” is a quiet error that makes everything after it unfixable.
  • Reading “only if” as “if”. It is the reverse. When a sentence uses “only if”, “necessary” or “sufficient”, stop and translate on purpose instead of by feel.
  • Forgetting that a false first half makes the whole thing true. The bottom two rows of the table are both 1. A claim about every member of an empty collection is automatically true, and that is not a technicality — it decides real exam questions.

Test yourself in the free Kestrel Exams app

Discrete Math practice is free and works offline — topic-selectable drills on conditionals, equivalences, quantifiers, proof methods, and induction.

Drill logical equivalences →

Frequently asked questions#

What is the difference between the converse, the inverse, and the contrapositive?

Start from “if p then q”. The converse swaps the two halves: “if q then p”. The inverse negates both without swapping: “if not p then not q”. The contrapositive does both — swap and negate: “if not q then not p”. Only the contrapositive means the same thing as the original.

Is a conditional equivalent to its contrapositive?

Yes, always. If you memorize one fact from this page, memorize that one. A truth table shows the two columns matching in every row. It is what allows proof by contraposition: to prove “if p then q”, you may instead assume q is false and show p must be false too.

Why is the converse not the same as the original?

Because “if it rains I bring an umbrella” does not promise anything about days when I carry one anyway. A sharper example: “if n is even and bigger than 2, then n is a sum of two primes” is an open problem, while its converse is plainly false since 5 = 2 + 3 is a sum of two primes and is not even. One is false and the other is unknown, so they cannot be the same statement.

Does “only if” mean the same as “if”?

No — it points the other way, which is the most common translation error in this topic. “p only if q” means “if p then q”. A bare “p if q” means “if q then p”. Sufficient goes in front of the arrow, necessary goes behind it, and “only if” behaves like necessary.

Suggest a change

Something here not clear? A topic you wish we covered? Tell us. We read every message, and a request is the fastest way to get a guide written — several of these exist because somebody asked.