The basic content of this section is Lemma 1.4 and Definitions 1.5 and 1.6. The lemma guarantees that the terms and formulas of any language in L1 can be deciphered in a unique way, and it serves as a basis for most inductive argu- ments. (The reader may take the lemma on faith for the time being, provided that he was able independently to verify the last formula in 3.7 of Chapter I.
However, the proof of the lemma will be needed in (§4 of Chapter VII.) It is important to remember that the theory of any formal language begins by check- ing that the syntactic rules are free of ambiguity.
We begin with the standard combinatoric definitions, in order to fix the terminology.
1.1. Let A be a set. By a sequence of length n of elements of A we mean a mapping from the set{1, . . . , n} toA. The image ofiis called theith term of the sequence. Corresponding to n= 0 we have the empty sequence. Sequences of length 1 will sometimes be identified with elements ofA.
A sequence of length n can also be written in the form a1, . . . , ai, . . . , an, where ai is its ith term. The number i is called the index of the term ai. If P = (a1, . . . , an) andQ= (b1, . . . , bm) are two sequences, their concatenation P Qis the sequence (a1, . . . , an, b1, . . . , bm) of lengthm+nwhoseith term isai
forinandbi−nforn+ 1in+m. We similarly define the concatenation of a finite sequence of sequences.
An occurrence of the sequence Q in P is any representation of P as a concatenationP1QP2. Substituting a sequenceRin place of a given occurrence ofQ inPamounts to constructing the sequenceP1RP2.
Let Π+,Π− be two disjoint subsets of (1, . . . , n). A map c : Π+ → Π− is called a parentheses bijection if it is bijective and satisfies the following conditions:
(a) c(i)> ifor alli∈Π+;
(b) for everyiandj, j∈[i, c(i)] if and only ifc(j)∈[i, c(i)].
19 Yu. I. Manin, A Course in Mathematical Logic for Mathematicians, Second Edition,
Graduate Texts in Mathematics 53, DOI 10.1007/978-1-4419-0615-1_2,
© Yu. I. Manin 2010
1.2. Lemma. Given Π+ and Π−, if a parentheses bijection exists, then it is unique.
This lemma will be applied to expressions in languages in L1: Π+ will consist of the indices of the places in the expression at which “(” occurs, Π− will consist of the indices of the places at which “)” occurs, and the map c correlates to each left parenthesis the corresponding right parenthesis.
Proof of the lemma. Let the functionε:{1, . . . , n} → {0,±1}take the value 1 on Π+ , –1 on Π−, and 0 everywhere else. We claim that for everyi ∈Π+, for any parentheses bijectionc: Π+→Π−, and for anyk,1kc(i)−i, we have the relations
c(i) j=1
εεε(j) = 0,
c(i)−k j=1
εεε(j)>0.
The lemma follows immediately from these relations, since we obtain the following recipe for determining c from Π+ and Π−;c(i) is the least l > ifor whichl
j=iε(j) = 0.
The first relation holds because the elements of Π+ and Π− that appear in the interval [i, c(i)] do so in pairs (j, c(j)), andε(j) +ε(c(j))= 0.
To prove the second relation, suppose that for some i and k we have c(i)−k
j=i ε(j) 0. Sinceε(i) = 1, it follows that c(i)−k
j=i+1ε(j)< 0. Hence, the number of elements of Π− in the interval [i+ 1,c(i)−k] is strictly greater than the number from Π+. Letc(j0)∈Π− be an element in the interval such that j0 ∈[i+ 1, c(i)−k]. Thenj0 i, and in fact,j0 < i, sincec(i) is outside the interval. But then only one element of the pair j0, c(j0) lies in [i, c(i)], which
contradicts the definition ofc.
1.3. Now let A be the alphabet of a languageL in L1 (see §2 of Chapter I).
Finite sequences of elements ofAare the expressions in this language. Certain expressions have been distinguished as formulas or terms. We recall that the definitions in§2 of Chapter I imply that:
(a) Any term in L either is a constant, is a variable, or is represented in the form f(t1, . . . , tr), where fis an operation of degreer, andt1, . . . , trare terms shorter in length.
(b) Any formula inL is represented either in the formp(t1, . . . , tr), where pis a relation of degreerandt1, . . . , trare terms shorter in length, or in one of the seven forms
(P)⇔Q, (P)⇒(Q), (P)∨(Q), (P)∧(Q),
¬(P), ∀x(P), ∃x(P),
whereP andQare formulas shorter in length, andxis a variable.
The following result is then obtained by induction on the length of the expression: if E is a term or a formula, then there exists a parentheses bijec- tion between the set Π+ of indices of left parentheses in E and the set Π− of indices of right parentheses. In fact, the new parentheses in 1.3(a) and (b)
have a natural bijection, while the old ones (which might be contained in the terms t1, . . . , tr or the formulasP, Q) have such a bijection by the induction assumption. In addition, the new parentheses never come between two paired old parentheses.
We can now state the basic result of this section:
1.4. Unique Reading Lemma. Every expression in L is either a term, or a formula, or neither. These alternatives, as well as all of the alternatives listed in 1.3(a) and (b), are mutually exclusive. Every term (resp. formula) can be represented in exactly one of the forms in1.3(a) (resp.1.3(b)), and in a unique way.
In addition, in the course of the proof we show thatif an expression is the concatenation of a finite sequence of terms, then it is uniquely representable as such a concatenation.
Proof. Using induction on the length of the expression E, we describe an informal algorithm for syntactic analysis, which uniquely determines which alternative holds.
(a) If there are no parentheses inE, thenE is either a constant term, a variable term, or neither a term nor a formula.
(b) IfEcontains parentheses, but there is no parentheses bijection between the left and right parentheses, thenE is neither a term nor a formula.
(c) SupposeEcontains parentheses with a parentheses bijection. Then either Eis uniquely represented in one of the nine forms
f(E0) (wheref is an operation), p(E0) (wherepis a relation),
(E1)⇔(E2), (E1)⇒(E2), (E1)∨(E2), (E1)∧(E2),
¬(E3), ∀x(E3), ∃x(E3),
or elseE is neither a term nor a formula. Here the pairs of parentheses we have written out are connected by the unique parentheses bijection that is assumed to exist inE; this is what ensures uniqueness. In fact, we obtain the formf(E0) if and only if the first element of the expression is a function, the second element is “(”, and the last element is the “)” that corresponds under the bijection: and similarly for the other forms.
We have thereby reduced the problem to the syntactic analysis of the expressionsE0, E1, E2, E3, which are shorter in length. This almost completes our description of the algorithm, since what remains to be determined about E1, E2, E3 is whether they are formulas. However, for E0 we must determine whether this expression is a concatenation of the right number of terms, and we must ask whether such a representation must be unique.
The answer to the latter question is positive. We have the following recipe for breaking off terms from left to right in a union of terms.
(d) LetE0 be an expression having a parentheses bijection between its left and right parentheses. If E0 can be represented in the form tE0, where t is
a term, then this representation is unique. In fact, either E0 can be uniquely represented in one of the forms
xE0, cE0, f(E0)E0
(wherexis a variable,cis a constant, andf is an operation whose parentheses correspond under the unique parentheses bijection in E0), or else E0 cannot be represented in the form tE0, where t is a term. In the cases E0 = xE0 or E0 =cE0, this is obviously the only way to break off a term from the left. In the caseE0=f(E0)E0, the question reduces to whetherE0is a concatenation of degree–(f ) terms. By induction on the length of E0, we may assume that either E0 is not such a concatenation, or else it is uniquely representable as a
concatenation of terms. The lemma is proved.
Exercise:State and prove a unique reading lemma for the “parentheses-less” dialect ofL1 described in 2(a) of “Digression: Syntax” in Chapter I.
Here is the first inductive description of the difference between free and bound occurrences of a variable in terms and formulas. The correctness of the following definitions is ensured by Lemma 1.4.
1.5. Definition.
(a) Every occurrence of a variable in an atomic formula or term is free.
(b) Every occurrence of a variable in¬(P) or in (P1)∗(P2) (where∗is any of the connectives “∨”, “∧”, “⇒”, “⇔”) is free (respectively bound) if and only if the corresponding occurrence in P, P1, or P2 is free (respectively bound).
(c) Every occurrence of the variable x in ∀x(P) and ∃x(P) is bound. The occurrences of other variables in ∀x(P) and ∃x(P) are the same as the corresponding occurrences inP.
Suppose the quantifier∀(or∃) occurs in the formulaP. It follows from the definitions that it must be followed in P by a variable and a left parenthesis.
The expression that begins with this variable and ends with the corresponding right parenthesis is called the scope of the given (occurrence of the) quanti- fier.
1.6. Definition. Suppose we are given a formulaP, a free occurrence of the variable xin P, and a termt. We say that tis free for the given occurrence of xin Pif the occurrence does not lie in the scope of any quantifier of the form
∃yor ∀y, wherey is a variable occurring int.
In other words, ift is substituted in place of the given occurrence ofx, all free occurrences of variables in tremain free inP.
We usually have to substitute a term for each free occurrence of a given variable. It is important to note that this operation takes terms into terms and
formulas into formulas (induction on the length). Iftis free for each free occur- rence ofxin Pwe simply say thattis free forxin P.
1.7. We shall start working with Definitions 1.5 and 1.6 in the next section.
Here we shall only give some intuitive explanations.
Definition 1.5 allows us to introduce the important class ofclosedformulas.
By definition, this consists of formulas without free variables. (They are also called sentences.) The intuitive meaning of the concept of a closed formula is as follows. A closed formula corresponds to an assertion that is completely deter- mined (in particular, regarding truth or falsity); indeterminate objects of the theory are mentioned only in the context “all objectsxsatisfy the condition. . .”
or “there exists an objecty with the property. . . .” Conversely, a formula that is not closed, such as x∈ y or ∃x(x∈ y), may be true or false depending on what sets are being designated by the names xand y (for the first) or by the namey(for the second). Here truth or falsity is understood to mean for a fixed interpretation of the language, as will be explained in§2.
In particular, Definition 1.6 gives the rules of hygiene for changing notation.
If we want to call an indeterminate object x by another name y in a given formula, we must be sure that x does not appear in the parts of the formula where this name y is already being used to denote anarbitrary indeterminate object (after a quantifier). In other words,y must be free forx. Moreover, if we want to say that xis obtained from certain operations on other indeterminate objects (x= a term containingy1, . . . , yn), then the variablesy1, . . . , yn must not be bound.
There is a close parallel to these rules in the language of analysis: in- stead ofx
1 f(y)dy we may confidently writex
1 f(z)dzbut we must not write x
1 f(x)dx; the variabley is bound, in the scope of
f(y)dy.