Skip to content

Contrapositive in logic: meaning and examples

The contrapositive of A -> B is NOT B -> NOT A: both parts negated and the arrow reversed. A conditional and its contrapositive are logically equivalent, so either can stand in for the other.

“If it rains, the ground is wet” has the contrapositive “if the ground is not wet, it is not raining”, and the two say the same thing: both fail only when it rains onto dry ground. Contraposition is the one transformation of a conditional that preserves meaning; the converse and the inverse do not. It is also the basis of modus tollens, the inference from A -> B and NOT B to NOT A, and of proof by contraposition in mathematics.

The artefact on this page compares implication = A -> B with contrapositive = NOT B -> NOT A. Both columns read true, true, false, true, and the differing-rows list is empty. The equivalence check holds, with the summary that the two formulas agree on every assignment, 4 rows in all. The one false row is row 2, A = TRUE, B = FALSE, for both: there the original has a true antecedent and false consequent, and the contrapositive has NOT B true and NOT A false, the same failure seen from the other end.

Contrapositives are useful whenever the negative direction is easier to state or to check: “no entry without a ticket” is the contrapositive of “anyone inside has a ticket”. In testing, a rule and its contrapositive must pass the same cases, which makes one a check on the other. The term is confused with the converse (arrow reversed, nothing negated) and with the inverse (negated, arrow not reversed), both of which are the original's equivalent of each other but not of it.

Example

implication := A -> B · outputcontrapositive := NOT B -> NOT A · output

Exact checks

Always true (tautology)? No Counterexample: A = T, B = F · Exhaustively checked and solver cross-checked · 3 rows
Always false (contradiction)? No Counterexample: A = F, B = F · Exhaustively checked and solver cross-checked · 1 rows
Can be true? Yes Example assignment: A = F, B = F · Exhaustively checked and solver cross-checked · 1 rows
Are implication and contrapositive equivalent? Yes · Exhaustively checked and solver cross-checked · 4 rows

Truth table (4 rows)

Contrapositive in logic: meaning and examples
#ABimplicationcontrapositive
0FALSEFALSETRUETRUE
1FALSETRUETRUETRUE
2TRUEFALSEFALSEFALSE
3TRUETRUETRUETRUE

Plain-language reading

Beginnerimplication is true exactly when the following holds: if A is true, then B is true.
In every other case, implication is false.
About the operators:
- An “if … then” condition only constrains the case where its “if” part holds: when the “if” part is false, the condition is satisfied whatever the “then” part is. It does not say the reverse.
Intermediateimplication is true exactly when the following holds: if A is true, then B is true.
In every other case, implication is false.
Advancedimplication is true exactly when the following holds: if A is true, then B is true [material implication →].
In every other case, implication is false.
Formal notation: A → B

The common slip

Negating only one side when forming the contrapositive. NOT B -> A and B -> NOT A are neither the contrapositive nor equivalent to the original; both parts must be negated and swapped. The equivalence check on this page passes only for the complete transformation.

Questions

Why is the contrapositive equivalent but the converse is not?

Because A -> B is NOT A OR B, and NOT B -> NOT A is NOT NOT B OR NOT A, which double negation and commutativity turn into the same formula. The converse, NOT B OR A, is a different disjunction, and the table shows where it differs.

Related

Guides

See also

Glossary

Generated from the Tangibool engine, semantics tangibool-semantics/1, engine 1.0.0, build . Every table, map, simplification and verdict on these pages was computed by the Tangibool engine when the site was built, and every claim was re-checked by the same exact checker the app uses. Limits are stated where they apply. © 2026 Foreranger LTD.