Skip to content

Formula

Defines Formula, formulas, well-formed formula
Requires
  • ./connective.md
  • ./quantifier.md

Let L\mathcal{L} be a formal language with a signature Σ\Sigma consisting of constant symbols, function symbols (each with a specified arity), relation symbols (each with a specified arity), and a countable set of variables.

Definition. The set Form(L)\mathrm{Form}(\mathcal{L}) of well-formed formulas (or simply formulas) of L\mathcal{L} is the smallest set satisfying:

  1. Atomic formulas. If RR is an nn-ary relation symbol and t1,,tnt_1, \ldots, t_n are terms of L\mathcal{L}, then R(t1,,tn)Form(L)R(t_1, \ldots, t_n) \in \mathrm{Form}(\mathcal{L}). In particular, ,Form(L)\top, \bot \in \mathrm{Form}(\mathcal{L}).
  2. Connectives. If φ,ψForm(L)\varphi, \psi \in \mathrm{Form}(\mathcal{L}), then (φψ)(\varphi \wedge \psi), (φψ)(\varphi \vee \psi), (φψ)(\varphi \to \psi), and (¬φ)(\neg\varphi) are in Form(L)\mathrm{Form}(\mathcal{L}).
  3. Quantifiers. If φForm(L)\varphi \in \mathrm{Form}(\mathcal{L}) and xx is a variable, then (x.φ)(\forall x.\, \varphi) and (x.φ)(\exists x.\, \varphi) are in Form(L)\mathrm{Form}(\mathcal{L}).

A term of L\mathcal{L} is built from variables and constant symbols by iterated application of function symbols.

Proposition. Every formula φForm(L)\varphi \in \mathrm{Form}(\mathcal{L}) has a unique parse tree.

Proof sketch. By structural induction on the definition, using the fact that the outermost constructor (connective, quantifier, or atomic predicate) is uniquely determined by the formula’s syntax. \square

Definition. A variable xx occurs free in φ\varphi if it is not in the scope of any quantifier x\forall x or x\exists x within φ\varphi. A sentence (or closed formula) is a formula with no free variables. An open formula defines a property or relation depending on the values assigned to its free variables.

Examples.

  • Propositional logic. Σ\Sigma has no function or relation symbols beyond nullary propositional variables p,q,r,p, q, r, \ldots and no quantifiers. Formulas are built by clauses (1) and (2) alone.
  • First-order arithmetic. Σ={0,S,+,×,<}\Sigma = \{0, S, +, \times, <\}. The sentence x.y.(x<y)\forall x.\, \exists y.\, (x < y) is a closed formula; x<yx < y is an open formula with free variables xx and yy.

A formula is a purely syntactic object. It becomes a proposition only when interpreted in a model. The study of which formulas are satisfied by which models is model theory.

Relations

Date created
Mathematical object
Formal language
Requires
  • . connective.md
  • . quantifier.md

Cite

@misc{emsenn2025-formula,
  author    = {emsenn},
  title     = {Formula},
  year      = {2025},
  url       = {https://emsenn.net/library/math/domains/logic/terms/formula/},
  publisher = {emsenn.net},
  license   = {CC BY-SA 4.0}
}