# nLab logic

‘Contrariwise,’ continued Tweedledee, ‘if it was so, it might be; and if it were so, it would be; but as it isn’t, it ain’t. That’s logic.’

(Lewis Carroll, Through the Looking Glass)

foundations

(0,1)-category

(0,1)-topos

# Logic

## Idea

Traditionally, as a discipline, logic is the study of correct methods of reasoning. Logicians have principally studied deduction, the process of passing from premises to conclusion in such a way that the truth of the former necessitates the truth of the latter. In other words, deductive logic studies what it is for an argument to be valid. A second branch of logic studies induction, reasoning about how to assess the plausibility of general propositions from observations of their instances. This has often been done in terms of probability theory, particularly Bayesian.

Some philosophers, notably Charles Peirce, considered there to be third variety of reasoning for logic to study, namely, abduction. This is a process whereby one reasons to the truth of an explanation from its ability to account for what is observed. It is therefore sometimes also known as inference to the best explanation. At least some aspects of this can also be studied using Bayesian probability.

Deductive logic is the best developed of the branches. For centuries, treatments of the syllogism were at the forefront of the discipline. In the nineteenth century, however, spurred largely by the needs of mathematics, in particular the need to handle relations and quantifiers, a new logic emerged, known today as predicate logic.

As we said above, logic is traditionally concerned with correct methods of reasoning, and philosophers (and others) have had much to say prescriptively about logic. However, one can also study logic descriptively, taking it to be the study of methods of reasoning, without attempting to determine whether these methods are correct. One may study constructive logic, or a substructural logic, without saying that it should be adopted. Also psychologists study how people actually reason rapidly in situations without full information, such as by the fast and frugal approach.

A logic is a specific method of reasoning. There are several ways to formalise a logic as a mathematical object; see at Mathematical Logic below.

## Mathematical logic

Mathematical logic or symbolic logic is the study of logic and foundations of mathematics as, or via, formal systems – theories – such as first-order logic or type theory.

### Classical subfields

The classical subfields of mathematical logic are

### Categorical logic

By a convergence and unification of concepts that has been named computational trinitarianism, mathematical logic is equivalently incarnated in

The logical theory that is specified by and specifies a given category $\mathcal{C}$ – called its internal logic, see there for more details and also see internal language, syntactic category. – is the one

• whose types are the objects $A$ of $\mathcal{C}$;

• whose contexts are the slice categories $\mathcal{C}_{/A}$;

• whose propositions in context are the (-1)-truncated objects $\phi$ of $\mathcal{C}_{/A}$;

• whose proofs $A \vdash PhiIsTrue : \phi$ are the generalized elements of $\phi$.

Hence pure mathematical logic in the sense of the study of propositions is identified with (0,1)-category theory: where one concentrates only on (-1)-truncated objects. Genuine category theory, which is about 0-truncated objects, is the home for logic and set theory, or rather type theory, the 0-truncated objects being the sets/types/h-sets.

For instance,

Generally, (∞,1)-category theory, which is about untruncated objects, is the home for logic and types with a constructive notion of equality, the identity types in homotopy type theory.

## Entries on logic

basic symbols used in logic

$\phantom{A}$symbol$\phantom{A}$$\phantom{A}$meaning$\phantom{A}$
$\phantom{A}$$\in$$\phantom{A}$element relation
$\phantom{A}$$\,:$$\phantom{A}$typing relation
$\phantom{A}$$=$$\phantom{A}$equality
$\phantom{A}$$\vdash$$\phantom{A}$$\phantom{A}$entailment / sequent$\phantom{A}$
$\phantom{A}$$\top$$\phantom{A}$$\phantom{A}$true / top$\phantom{A}$
$\phantom{A}$$\bot$$\phantom{A}$$\phantom{A}$false / bottom$\phantom{A}$
$\phantom{A}$$\Rightarrow$$\phantom{A}$implication
$\phantom{A}$$\Leftrightarrow$$\phantom{A}$logical equivalence
$\phantom{A}$$\not$$\phantom{A}$negation
$\phantom{A}$$\neq$$\phantom{A}$negation of equality / apartness$\phantom{A}$
$\phantom{A}$$\notin$$\phantom{A}$negation of element relation $\phantom{A}$
$\phantom{A}$$\not \not$$\phantom{A}$negation of negation$\phantom{A}$
$\phantom{A}$$\exists$$\phantom{A}$existential quantification$\phantom{A}$
$\phantom{A}$$\forall$$\phantom{A}$universal quantification$\phantom{A}$
$\phantom{A}$$\wedge$$\phantom{A}$logical conjunction
$\phantom{A}$$\vee$$\phantom{A}$logical disjunction
$\phantom{A}$$\otimes$$\phantom{A}$$\phantom{A}$multiplicative conjunction$\phantom{A}$
$\phantom{A}$$\oplus$$\phantom{A}$$\phantom{A}$multiplicative disjunction$\phantom{A}$

## References

### General

For centuries, logic was Aristotle's logic of deduction by syllogism. In the 19th century the idea of objective logic as metaphysics was influential

This “old logic” was famously criticized

as opposed to the “new logic” of Peano and Frege, contemporary predicate logic.

Textbooks on mathematical logic:

### On categorical logic

• Michael Makkai and Gonzalo Reyes, First Order Categorical Logic: Model-theoretical methods in the theory of topoi and related categories, Lecture Notes in Math. 611, Springer-Verlag, 1977. re-written by Francisco Marmolejo in 2018 (web announcement, pdf)

### Logic in natural languages

• Pieter A. M. Seuren, The logic of language, vol. II of Language from within; (vol. I: Language in cognition) Oxford University Press 2010