Logical Conditional (p ⇒ q): Truth Table Explained | Truth Tables

// reference · IF

⇒ Conditional_

The conditional, also called material implication, expresses "if p, then q". The expression p ⇒ q is false in exactly one case: when the antecedent p is true and the consequent q is false. It is the connective students find most confusing, precisely because it is true whenever p is false.

Symbol

Binary (2 operands)

Also written as

Example

p ⇒ q

Open in the calculator →

Truth table: p ⇒ q

pqp ⇒ q
TTT
TFF
FTT
FFT
4 combinations2 variables1 step

Classification: Contingency · 4 rows

Definition

In p ⇒ q, the proposition p is called the antecedent (or hypothesis) and q the consequent (or conclusion). The conditional asserts that the antecedent cannot hold without the consequent; it does not claim that p causes q, nor that p actually happens.

Textbooks write p → q, p ⊃ q (Russell's notation) or p ⇒ q. The calculator uses ⇒ as its canonical symbol and also accepts →. Do not confuse this operator with the "therefore" of a proof: here it is just a truth function.

How to read it

p ⇒ q is read "if p, then q", "p implies q", "p is sufficient for q", "q is necessary for p", "q if p" or "p only if q". All these phrasings share the same truth table.

Be careful with "p only if q": it means p ⇒ q, not q ⇒ p. And "p if q" means q ⇒ p. Correctly identifying the antecedent is the key step when formalizing.

When it is true

The table has four rows. With p = T and q = T, p ⇒ q = T (the promise is kept). With p = T and q = F, p ⇒ q = F (the only false case: true antecedent, false consequent). With p = F and q = T, p ⇒ q = T. With p = F and q = F, p ⇒ q = T.

The last two rows are known as vacuous truth: if the antecedent does not hold, the conditional is not refuted and is considered true by convention. Think of a promise: "if you pass, I'll take you to dinner". If you don't pass, I haven't broken my promise no matter what I do.

Everyday example

"If it rains, the street gets wet." If it rains and the street is wet, the statement is true. If it rains and the street is dry, it is false. If it does not rain, the statement is never put to the test: the street may be wet for another reason (a sprinkler truck) or dry, and in both cases the conditional remains true.

In programming, the guarantee "if the user is authenticated, then they have a session" is violated only when you find an authenticated user without a session.

Properties and equivalences

Material implication: p ⇒ q ≡ ¬p ∨ q. This equivalence lets you eliminate conditionals from any formula and underlies many simplifications.

Contrapositive: p ⇒ q ≡ ¬q ⇒ ¬p. They are logically identical, which is why proving the contrapositive is a valid proof technique.

Negation: ¬(p ⇒ q) ≡ p ∧ ¬q. The only way a conditional is false is for the antecedent to occur without the consequent. Also: p ⇒ q ≡ ¬(p ∧ ¬q) and p ⇒ q ≡ q ← p (the converse conditional with operands swapped).

The conditional is NOT commutative or associative: p ⇒ q is not equivalent to q ⇒ p (its converse) nor to ¬p ⇒ ¬q (its inverse). It is, however, transitive: from p ⇒ q and q ⇒ r you get p ⇒ r (hypothetical syllogism).

Common mistakes

Confusing the conditional with its converse. "If it rains, the street gets wet" being true does not make "if the street is wet, it rains" true. This fallacy is called affirming the consequent.

Believing p ⇒ q is false when p is false. In classical logic it is vacuously true. If that feels odd, remember that the conditional's table is exactly that of ¬p ∨ q.

Reading implication as causation. "If 2 + 2 = 5, then the Moon is made of cheese" is a true conditional (false antecedent), even though the propositions have nothing to do with each other.

Equivalent expressions

Try it yourself

Edit the expression in the calculator and watch how every step of the table changes.

Open in the calculator →

Related laws and rules

Frequently asked questions

Why is p ⇒ q true when p is false?

Because a conditional only promises something when its antecedent occurs. If p does not occur, the promise is never tested and cannot be false — it is said to be vacuously true. It is equivalent to ¬p ∨ q, which is true whenever ¬p is.

Is p ⇒ q the same as q ⇒ p?

No. q ⇒ p is the converse and has a different table: they differ in the rows (T, F) and (F, T). Only the contrapositive ¬q ⇒ ¬p is equivalent to p ⇒ q.

Which is the only false row of the conditional?

When the antecedent is true and the consequent is false: p = T, q = F. That is why ¬(p ⇒ q) ≡ p ∧ ¬q.

What is the difference between → and ⇒?

None in basic propositional logic: both denote the material conditional. Some texts reserve ⇒ for logical implication between formulas, but in the calculator they are interchangeable.

All operators