Hilbert system
In logic, and more specifically proof theory, a Hilbert system is a type of formal proof system. It is also called a Hilbert calculus, Hilbert-style system, Hilbert-style proof system, Hilbert-style deductive system or Hilbert–Ackermann system. It is linked to Gottlob Frege and David Hilbert. These deductive systems are most often studied for first-order logic, but they are also of interest for other logics.
A Hilbert system is a deductive system that creates theorems from axioms and inference rules. It is especially like this when the only inference rule is modus ponens. Every Hilbert system is an axiomatic system. Many authors use this general term for their Hilbert systems without naming any more specific terms. In this way, Hilbert systems are compared with natural deduction systems, which use no axioms and only inference rules. Different sources define "Hilbert system" in different ways. For example, Troelstra defines it as a system with axioms and with →E and ∀I as the only inference rules. Some people also use the name for a specific set of axioms. The term "Hilbert-style" is used by many writers because of the influence of Hilbert and Ackermann's book Principles of Mathematical Logic (1928). Some sources use it for systems whose axioms are written in schematic form, as in the § Schematic form of P2 section below.
Hilbert systems balance a trade-off between logical axioms and rules of inference in a particular way. They usually have a large number of schemas of logical axioms and only a small set of rules of inference. Natural deduction systems do the opposite, with many deduction rules and very few or no axiom schemas. The most commonly studied Hilbert systems have one rule of inference, modus ponens, for propositional logics, or two rules for predicate logics, where generalisation is added. They also have several infinite axiom schemas. Hilbert systems for alethic modal logics, sometimes called Hilbert-Lewis systems, also need the necessitation rule. Some systems use a finite list of concrete formulas as axioms instead of infinite axiom schemas, and in that case the uniform substitution rule is needed.
A key feature of Hilbert systems is that the context does not change in any of their rules of inference. In contrast, both natural deduction and sequent calculus include some rules that change the context. Because of this, if someone is only interested in whether tautologies can be derived, Hilbert systems can be written so that their rules contain only judgments of a fairly simple form. The other two deduction systems cannot be set up this way. Since their context changes in some rules, they cannot avoid hypothetical judgments, even when they are used only to prove that tautologies can be derived.
Formal deductions
In a Hilbert system, a formal deduction (or proof) is a list of formulas, one after another. Each formula is either an axiom or comes from earlier formulas by a rule of inference. These deductions are meant to mirror proofs written in everyday language, but they are much more detailed.
Hilbert systems use many logical axioms. An axiom schema is a pattern that creates an endless set of axioms by putting in all formulas of one form. Logical axioms also include any generalization of these axioms, made by adding "for all" in front of a formula. Sets of formulas called hypotheses, such as axioms for group theory or set theory, can also be used. The notation Γ⊢ϕ means that ϕ can be proved using only logical axioms and the formulas in Γ.
Propositional logic
Several Hilbert systems have been used in propositional logic. One of them, the schematic form of P2, is also considered a Frege system. Axiomatic proofs have been used in mathematics since the Ancient Greek textbook Euclid's Elements of Geometry, written around 300 BC. The first known fully formalized proof system that counts as a Hilbert system dates back to Gottlob Frege's Begriffsschrift from 1879. Frege's system used only implication and negation and had six axioms. Frege used these together with modus ponens and a substitution rule to build a complete and consistent system for classical propositional logic.
Jan Łukasiewicz showed that one of Frege's axioms was unnecessary and that the last three could be replaced by a single sentence written in Polish notation, which can be converted into infix notation. Łukasiewicz is credited with a system of three axioms, which Alonzo Church gave again and helped make popular as P2. The schematic version of P2, which uses symbols that stand for any well-formed formulas, is attributed to John von Neumann and is also attributed to Hilbert. It is used in the Metamath "set.mm" proof database, and the idea of using axiom schemas in place of a substitution rule is also attributed to von Neumann.
Predicate logic (example system)
There are endless ways to set up predicate logic, because you can choose different starting rules (axioms) and ways of reasoning. This section describes one system with nine axioms and only one reasoning rule, called modus ponens. The first axiom can be worked out from the others (proof). The first four axioms describe classical propositional logic. Without the fourth axiom, the system becomes positive implicational logic. Changing one axiom gives Minimal logic, and adding other axioms gives Intuitionistic logic.
Three more axioms deal with "for all" statements, which extend the system to classical predicate logic. An alternative approach uses a rule called Generalization instead of two of these axioms. The last two axioms handle statements that use equals signs.
Conservative extensions
It is common to include in a Hilbert system only axioms for the logical operators implication and negation, which is enough to reach functional completeness. With these axioms, it is possible to form conservative extensions of the deduction theorem that allow the use of additional connectives. These extensions are called conservative because a formula using new connectives can be rewritten as a logically equivalent formula using only negation, implication, and universal quantification. The original formula can be derived in the extended system if and only if the rewritten version can be derived in the original system. When fully extended, a Hilbert system looks more like a system of natural deduction.
The extensions also cover existential quantification, conjunction, and disjunction. Existential quantification has rules for introduction and elimination, where the elimination rule applies only when the variable is not a free variable of the other part. Conjunction ("and") has rules for joining two parts and for taking either part on its own. Disjunction ("or") has rules for adding either part to form an "or" statement, and for using an "or" statement to reach the same conclusion from each possibility.

Quiz time!
5 questions about Hilbert system
Which inference rule is used by the most commonly studied Hilbert systems for propositional logic?
Keep exploring
This article is a child-friendly adaptation of the Wikipedia article on Hilbert system, available under CC BY-SA 4.0.
Images from Wikimedia Commons. Tap any image to view credits and license.