🤹🏼Formal Logic II Unit 4 – First–Order Theories and Models

First-order theories and models extend propositional logic by introducing quantifiers, variables, and predicates. This unit explores the syntax and semantics of first-order logic, including well-formed formulas, interpretations, and the concept of satisfaction. The study delves into proof systems, inference rules, and model theory basics. It covers important concepts like soundness, completeness, and the relationship between theories and their models. Applications in mathematics, computer science, and philosophy are also discussed.

Key Concepts and Definitions

  • First-order logic extends propositional logic by introducing quantifiers, variables, and predicates
  • Predicates are symbols that represent relations or properties of objects
  • Variables are symbols that stand for arbitrary objects in the domain of discourse
  • Quantifiers (universal \forall and existential \exists) express the scope and quantity of variables
  • Terms are expressions that refer to objects and can be variables, constants, or function applications
  • Formulas are well-formed expressions that can be atomic (predicates applied to terms) or compound (built using logical connectives and quantifiers)
  • Theories are sets of formulas, often used to axiomatize a particular domain or structure
    • A theory can be seen as a set of assumptions or axioms that define a specific context or system
  • Models are interpretations that assign meaning to the symbols in a first-order language and satisfy a given theory
    • A model consists of a non-empty domain (or universe) and an interpretation function that maps symbols to elements, relations, or functions in the domain

Syntax and Formation Rules

  • The syntax of first-order logic specifies the rules for constructing well-formed formulas
  • Alphabet consists of variables, constants, function symbols, predicate symbols, and logical symbols (connectives and quantifiers)
  • Terms are built recursively from variables, constants, and function symbols
    • If t1,,tnt_1, \ldots, t_n are terms and ff is an nn-ary function symbol, then f(t1,,tn)f(t_1, \ldots, t_n) is a term
  • Formulas are built recursively from atomic formulas using logical connectives and quantifiers
    • If PP is an nn-ary predicate symbol and t1,,tnt_1, \ldots, t_n are terms, then P(t1,,tn)P(t_1, \ldots, t_n) is an atomic formula
    • If ϕ\phi and ψ\psi are formulas, then so are ¬ϕ\neg \phi, (ϕψ)(\phi \land \psi), (ϕψ)(\phi \lor \psi), (ϕψ)(\phi \to \psi), and (ϕψ)(\phi \leftrightarrow \psi)
    • If ϕ\phi is a formula and xx is a variable, then xϕ\forall x \phi and xϕ\exists x \phi are formulas
  • Free variables are those not bound by a quantifier, while bound variables are those within the scope of a quantifier
  • Sentences are formulas with no free variables

Semantics and Interpretations

  • Semantics assigns meaning to the symbols and formulas in a first-order language
  • An interpretation I\mathcal{I} consists of a non-empty domain DD and a function that maps:
    • Constants to elements in DD
    • nn-ary function symbols to functions from DnD^n to DD
    • nn-ary predicate symbols to relations (subsets of DnD^n)
  • A variable assignment ss is a function that maps variables to elements in DD
  • The value of a term under an interpretation I\mathcal{I} and assignment ss is denoted by I[t]s\mathcal{I}[t]_s
  • The satisfaction relation Iϕ[s]\mathcal{I} \models \phi[s] defines when an interpretation I\mathcal{I} satisfies a formula ϕ\phi under an assignment ss
    • For atomic formulas, IP(t1,,tn)[s]\mathcal{I} \models P(t_1, \ldots, t_n)[s] iff (I[t1]s,,I[tn]s)I(P)(\mathcal{I}[t_1]_s, \ldots, \mathcal{I}[t_n]_s) \in \mathcal{I}(P)
    • For compound formulas, satisfaction is defined recursively using the truth tables for connectives and the semantics of quantifiers
  • A formula ϕ\phi is satisfiable if there exists an interpretation I\mathcal{I} and assignment ss such that Iϕ[s]\mathcal{I} \models \phi[s]
  • A formula ϕ\phi is valid (tautology) if for all interpretations I\mathcal{I} and assignments ss, Iϕ[s]\mathcal{I} \models \phi[s]

Proof Systems and Inference Rules

  • Proof systems provide a syntactic method for deriving formulas from a set of axioms and inference rules
  • Natural deduction is a common proof system that uses introduction and elimination rules for each logical connective and quantifier
    • Introduction rules allow inferring a formula with a specific connective or quantifier (e.g., \land-intro, \to-intro, \forall-intro)
    • Elimination rules allow using a formula with a specific connective or quantifier to infer simpler formulas (e.g., \land-elim, \to-elim, \forall-elim)
  • Sequent calculus is another proof system that uses sequents (expressions of the form ΓΔ\Gamma \vdash \Delta) and left/right introduction rules
  • Inference rules are schema that allow deriving new formulas from existing ones
    • Modus ponens: from ϕ\phi and ϕψ\phi \to \psi, infer ψ\psi
    • Universal instantiation: from xϕ\forall x \phi, infer ϕ[t/x]\phi[t/x] for any term tt
    • Existential generalization: from ϕ[t/x]\phi[t/x], infer xϕ\exists x \phi
  • A proof is a sequence of formulas, each of which is either an axiom or derived from previous formulas using inference rules
  • A formula ϕ\phi is provable from a theory TT (denoted TϕT \vdash \phi) if there exists a proof of ϕ\phi using axioms from TT and inference rules

Model Theory Basics

  • Model theory studies the relationship between theories and their models
  • A model of a theory TT is an interpretation that satisfies all the formulas (axioms) in TT
  • A theory TT is consistent if it has at least one model
  • A theory TT is complete if for every sentence ϕ\phi in the language, either TϕT \vdash \phi or T¬ϕT \vdash \neg \phi
  • The compactness theorem states that a theory TT has a model iff every finite subset of TT has a model
    • This implies that a theory is consistent iff every finite subset is consistent
  • The Löwenheim-Skolem theorem states that if a theory TT has an infinite model, then it has models of all infinite cardinalities
    • The downward version states that if TT has an infinite model, it has a countable model
    • The upward version states that if TT has an infinite model, it has models of arbitrarily large cardinalities
  • Elementary equivalence: two structures A\mathcal{A} and B\mathcal{B} are elementarily equivalent if they satisfy the same first-order sentences
  • Isomorphism: two structures A\mathcal{A} and B\mathcal{B} are isomorphic if there exists a bijective function f:ABf: A \to B that preserves the interpretations of all symbols
    • Isomorphic structures are elementarily equivalent, but the converse is not always true

Soundness and Completeness

  • Soundness and completeness are fundamental properties connecting syntax (provability) and semantics (validity)
  • Soundness: if a formula ϕ\phi is provable from a theory TT (TϕT \vdash \phi), then ϕ\phi is valid in all models of TT (TϕT \models \phi)
    • In other words, if a formula can be derived using a proof system, it must be true in all models satisfying the axioms
  • Completeness: if a formula ϕ\phi is valid in all models of a theory TT (TϕT \models \phi), then ϕ\phi is provable from TT (TϕT \vdash \phi)
    • In other words, if a formula is true in all models satisfying the axioms, it can be derived using a proof system
  • Gödel's completeness theorem establishes the completeness of first-order logic with respect to the standard proof systems (natural deduction, sequent calculus, Hilbert-style)
  • The compactness theorem and Löwenheim-Skolem theorems are important consequences of the completeness theorem
  • Soundness and completeness together imply that syntax and semantics are equivalent ways of characterizing logical consequence in first-order logic

Applications and Examples

  • First-order logic is widely used in mathematics, computer science, and philosophy to formalize and reason about various domains
  • In mathematics, first-order theories are used to axiomatize structures like groups, rings, fields, and ordered sets
    • Example: the theory of groups consists of axioms for associativity, identity, and inverses
  • In computer science, first-order logic is used in formal specification, verification, and automated theorem proving
    • Example: Hoare logic is a first-order theory for reasoning about the correctness of imperative programs
  • In philosophy, first-order logic is used to analyze and formalize arguments, theories, and concepts
    • Example: the theory of mereology (parthood relations) can be axiomatized using first-order logic
  • Many interesting mathematical structures can be characterized up to isomorphism by first-order theories
    • Example: the theory of dense linear orders without endpoints characterizes the structure of the rational numbers (Q,<)(\mathbb{Q}, <)
  • First-order logic is also used in the foundations of mathematics, such as in Zermelo-Fraenkel set theory (ZFC) and Peano arithmetic (PA)
    • These theories aim to provide a rigorous basis for all of mathematics using first-order axioms

Common Challenges and Tips

  • Translating natural language statements into first-order formulas can be challenging due to ambiguity and implicit assumptions
    • Tip: break down complex statements into simpler components and identify the key predicates, quantifiers, and logical connectives
  • Choosing the right signature (symbols) and axioms to model a particular domain requires careful consideration
    • Tip: start with a minimal set of symbols and axioms, and incrementally add more as needed to capture the essential properties of the domain
  • Understanding the scope and order of quantifiers is crucial for correctly formalizing statements
    • Tip: use parentheses to clearly indicate the scope of quantifiers and remember that the order of quantifiers matters (e.g., xy\forall x \exists y is different from yx\exists y \forall x)
  • Constructing proofs can be difficult, especially for complex formulas or theories
    • Tip: break down the goal into smaller subgoals, use proof strategies like induction or contradiction, and look for applicable axioms and previously proven lemmas
  • Interpreting models and counterexamples requires a good understanding of the semantics and the specific domain being modeled
    • Tip: carefully examine the interpretations of symbols and the satisfaction of formulas in the model, and try to identify the key properties that make it a counterexample
  • Dealing with equality in first-order logic requires special attention, as it has its own axioms and proof rules
    • Tip: use the reflexivity, symmetry, transitivity, and substitution axioms for equality, and be aware of the difference between syntactic and semantic equality


© 2024 Fiveable Inc. All rights reserved.
AP® and SAT® are trademarks registered by the College Board, which is not affiliated with, and does not endorse this website.

© 2024 Fiveable Inc. All rights reserved.
AP® and SAT® are trademarks registered by the College Board, which is not affiliated with, and does not endorse this website.