Mathematics · Notes

Logic: propositions and quantifiers

25 September 2026

This note collects the definitions and conventions used in Tool 01. It states what the symbols mean; the tool is where you test your understanding of them.

Propositions and connectives

A proposition is a statement that is either true (T) or false (F). Compound propositions are built from simpler ones with connectives, each defined by its truth table:

ppqq¬p\neg pp∧qp \land qp∨qp \lor qp→qp \to qp↔qp \leftrightarrow q
TTFTTTT
TFFFTFF
FTTFTTF
FFTFFTT

Three points deserve attention.

Reading formulas without brackets. ¬\neg applies first, then ∧\land, ∨\lor, →\to and ↔\leftrightarrow, in that order. So ¬p∧q\neg p \land q means (¬p)∧q(\neg p) \land q, and p∧q→rp \land q \to r means (p∧q)→r(p \land q) \to r. Implication groups to the right: p→q→rp \to q \to r means p→(q→r)p \to (q \to r). When in doubt, use brackets.

Logical equivalence

Two formulas φ\varphi and ψ\psi are logically equivalent, written φ≡ψ\varphi \equiv \psi, if they have the same truth value under every assignment of truth values to their variables. In other words, they agree on every row of their joint truth table. With nn variables there are 2n2^n rows.

To show that two formulas are not equivalent, one row is enough: an assignment on which they differ is a counterexample.

Two equivalences are used constantly:

¬(p∧q)≡¬p∨¬q,¬(p∨q)≡¬p∧¬q(De Morgan’s laws)\neg(p \land q) \equiv \neg p \lor \neg q, \qquad \neg(p \lor q) \equiv \neg p \land \neg q \qquad \text{(De Morgan's laws)} p→q  ≡  ¬q→¬p(the contrapositive)p \to q \;\equiv\; \neg q \to \neg p \qquad \text{(the contrapositive)}

The converse of p→qp \to q is q→pq \to p. It is not equivalent to p→qp \to q: the row p=Fp = \text{F}, q=Tq = \text{T} separates them.

Any other claimed equivalence can be settled with a truth table. Deriving them is the purpose of the first exercise set in the tool.

Negation normal form. A formula is in negation normal form if every ¬\neg applies directly to a variable, as in ¬p\neg p, never to a compound formula, as in ¬(p∧q)\neg(p \land q). Every formula can be rewritten in this form by pushing each ¬\neg inwards.

Restricted connectives. Each of the sets {¬,∧}\{\neg, \land\}, {¬,∨}\{\neg, \lor\} and {¬,→}\{\neg, \to\} is enough to express every connective in the table above. Finding the expressions is the second exercise set in the tool.

Mathematical English

Mathematical writing uses a small number of fixed phrases, each with a precise meaning.

PhraseSymbols
if pp, then qq;   q\;q if pp;   p\;p implies qqp→qp \to q
pp only if qqp→qp \to q
pp is sufficient for qqp→qp \to q
pp is necessary for qqq→pq \to p
pp if and only if qq;   p\;p is necessary and sufficient for qqp↔qp \leftrightarrow q
pp unless qq¬q→p\neg q \to p, equivalently p∨qp \lor q
neither pp nor qq¬p∧¬q\neg p \land \neg q
pp but qqp∧qp \land q

Two of these cause most mistakes.

Quantifiers

∀x  P(x)\forall x\; P(x) means that P(x)P(x) is true for every xx in the domain under discussion. ∃x  P(x)\exists x\; P(x) means that P(x)P(x) is true for at least one xx.

Bounded quantifiers restrict the range of the variable:

∀x∈A  P(x)   means   ∀x (x∈A→P(x)),∃x∈A  P(x)   means   ∃x (x∈A∧P(x)).\forall x \in A\; P(x) \;\text{ means }\; \forall x\,(x \in A \to P(x)), \qquad \exists x \in A\; P(x) \;\text{ means }\; \exists x\,(x \in A \land P(x)).

Expressions such as ∀ε>0\forall \varepsilon > 0 and ∃n≥N\exists n \ge N are read in the same way.

The order of different quantifiers matters. In ∀x ∃y  P(x,y)\forall x\, \exists y\; P(x, y), the yy may depend on xx. In ∃y ∀x  P(x,y)\exists y\, \forall x\; P(x, y), a single yy must work for every xx. The second statement implies the first, but not conversely. On R\mathbb{R}, for example, ∀x ∃y  (y>x)\forall x\, \exists y\; (y > x) is true, while ∃y ∀x  (y>x)\exists y\, \forall x\; (y > x) is false. Adjacent quantifiers of the same kind can be swapped: ∀x ∀y\forall x\, \forall y means the same as ∀y ∀x\forall y\, \forall x, and likewise for ∃\exists.

Truth on a finite set. A universal statement is shown false by a single counterexample, and shown true only by checking every element. An existential statement is shown true by a single witness. A universal implication ∀x (P(x)→Q(x))\forall x\,(P(x) \to Q(x)) is vacuously true when no xx satisfies P(x)P(x).

Negating quantified statements

The two basic rules are

¬ ∀x  P(x)  ≡  ∃x  ¬P(x),¬ ∃x  P(x)  ≡  ∀x  ¬P(x).\neg\, \forall x\; P(x) \;\equiv\; \exists x\; \neg P(x), \qquad \neg\, \exists x\; P(x) \;\equiv\; \forall x\; \neg P(x).

Bounds stay as they are. For example, ¬ ∀x∈A  P(x)≡∃x∈A  ¬P(x)\neg\, \forall x \in A\; P(x) \equiv \exists x \in A\; \neg P(x). To see why, unpack the bound and use the rule for negating an implication:

¬(p→q)  ≡  p∧¬q.\neg(p \to q) \;\equiv\; p \land \neg q .

So ¬ ∀x (x∈A→P(x))≡∃x ¬(x∈A→P(x))≡∃x (x∈A∧¬P(x))\neg\, \forall x\,(x \in A \to P(x)) \equiv \exists x\,\neg(x \in A \to P(x)) \equiv \exists x\,(x \in A \land \neg P(x)).

Negated relations become their complements. For real numbers,

¬(a<b)≡a≥b,¬(a≤b)≡a>b,¬(a=b)≡a≠b.\neg(a < b) \equiv a \ge b, \qquad \neg(a \le b) \equiv a > b, \qquad \neg(a = b) \equiv a \ne b .

Note that the complement of a strict inequality includes equality.

Recipe. To negate a statement fully, flip each quantifier (∀↔∃\forall \leftrightarrow \exists) and keep its bound. Then push ¬\neg inwards until it reaches the innermost claims, and replace each negated claim by its complement.

Example. The function ff is bounded on AA:

∃M  ∀x∈A:∣f(x)∣≤M.\exists M\; \forall x \in A : \lvert f(x) \rvert \le M .

Its negation, “ff is unbounded on AA”, is

∀M  ∃x∈A:∣f(x)∣>M.\forall M\; \exists x \in A : \lvert f(x) \rvert > M .

Whatever bound MM is proposed, some x∈Ax \in A has ∣f(x)∣>M\lvert f(x) \rvert > M.

Practise these rules in Tool 01. Its last two exercise sets negate the definitions of convergence and continuity, and evaluate quantified statements on a finite relation drawn as a graph.