5.5  Proving “There Exists”: Exhibit a Witness

Sections 5.3 and 5.4 gave the two rules for “for every”: ∀E uses a universal statement, and ∀I proves one. This section starts on the other quantifier. It gives the rule that proves an existential statement, ∃I, and the habit that goes with it: when the goal is “there exists”, do not guess the object, but wait until a line of the derivation shows it. The sequent ∀xP(x)⊢∃xP(x), which no rule so far can finish, is finished here in three lines.

5.5.1. Showing that something exists

How does a mathematician prove that there is a natural number N with 1/(N+1)<1/100? By naming one. “Take N=100: then 1/(N+1)=1/101, and 1/101<1/100.” Nobody asks for more, and nobody objects that N=1000 would also have done. The proof exhibits a witness, checks that it has the property, and stops.

Look at what the proof does with the witness at the end. The statement proved, “there is an N with 1/(N+1)<1/100”, does not say which N; the 100 still in it belongs to the bound 1/100, not to N. The number was needed to establish the claim and is then forgotten: a reader of the conclusion learns that some N works, not which one.

Chapter 1 used the same pattern from its first page. It recalled that an integer n is even when n=2k for some integer k, and said that the word “some” has rules of its own, to come in Chapter 5. Here is the first of them. To show that 6 is even, take k=3: then 6=2⋅3. The statement “6 is even” is ∃k(6=2⋅k), and the proof passes from the instance 6=2⋅3 to it. The second rule for “some”, how to use “n=2k for some k”, is the subject of Section 5.6.

There is a helpful way to see the step, which Section 5.1’s reading of ∃ suggests. Over a domain with three elements named a, b, c, the sentence ∃xP(x) says what the disjunction P(a)∨P(b)∨P(c) says (grouped to the right, as in Section 4.5): at least one of the three has P. An existential is a long “or”, with one disjunct for each object of the domain. Proving a disjunction from one of its sides is ∨I (Definition 1.5.1), and proving an existential from one instance is the rule of this section. The analogy is only a guide (a domain such as N has infinitely many elements, and a formula cannot be infinitely long), but it predicts the rule’s behavior exactly: it throws information away, and it must never be run backwards.

5.5.2. The rule of existential introduction

To prove that something has a property, show that one particular thing has it.

Definition 5.5.1 (Existential Introduction)
iφ[t/x]
k∃xφ∃I i

The rule given by this schema is called ∃I (existential introduction). Here φ is any formula, x any variable, and t any term, subject to one side condition: t is free for x in φ (Definition 5.2.6). Line i must be available at line k (Definition 1.4.2).

  • Schema: the block above: one cited line, no box, no fresh name.
  • Reading: from a line that says something about the term t, write “something has that property”: mark some occurrences of t with a variable x to get φ, and write ∃xφ.
  • Example: from 6=2⋅3, marking the 3 gives ∃k(6=2⋅k).

Which occurrences? Any you like, as the table below shows; the term t is the witness, and it may be a constant, a compound term or a variable: a variable used elsewhere in the derivation, a flag such as x0, or even the variable x itself. Check two things. First, φ[t/x] must be exactly the cited line: choose a variable x that does not appear in the line and mark some occurrences of t with it, and this marking recipe guarantees it; with an x that does appear, check directly (from R(x,c), marking c gives R(x,x), and R(x,x)[c/x] is R(c,c), not the line). Second, t must be free for x in φ, the condition of Definition 5.2.6 that ∀E also carries. With a bound, ∃x∈Aφ, the witness needs the line t∈A too; “A bounded witness” below shows the two steps.

One line, several readings. Let line i be R(c,c), with R a two-place predicate symbol and c a constant. The witness is c, and c occurs twice. Each occurrence may be marked with x or left alone, and each choice is a different φ:

φ φ[c/x] (the cited line) the new line ∃xφ
R(x,c) R(c,c) ∃xR(x,c)
R(c,x) R(c,c) ∃xR(c,x)
R(x,x) R(c,c) ∃xR(x,x)

All three are legal steps. Read over N with R(x,y) as “x≤y” and c as 5: the cited line says 5≤5, and the three useful conclusions say that something is at most 5, that 5 is at most something, and that something is at most itself. Each is a true and weaker statement.

Second readingA witness that is not marked

A fourth row is legal too:

φ φ[c/x] (the cited line) the new line ∃xφ
R(c,c) R(c,c) ∃xR(c,c)

The last row is the degenerate choice: φ has no free x, so φ[c/x] is φ (Section 5.2) and the new line ∃xR(c,c) quantifies over nothing. It is legal, and it says nothing that line i did not.

Why this rule. Under the reading of Section 5.1, ∃xφ is true when at least one element of the domain, put in for x, makes φ true. If φ[t/x] is true, then the object that t names is such an element, so ∃xφ is true. The side condition is what makes “φ[t/x] says about t what φ says about x” correct: that was the content of “free for” in Section 5.2.

∃I forgets the witness, and keeps the truth.

Quick check. Line 1 is x0+1>x0. Give an ∃I line with the witness x0, and one with the witness x0+1.

Solution. Marking both occurrences of x0 with y gives φ=(y+1>y) and the line ∃y(y+1>y); marking the term x0+1 gives φ=(y>x0) and the line ∃y(y>x0). In both, y appears nowhere in line 1, and the formula has no quantifier, so the witness is free for y.

A nonexample: capture. Let line 1 be ∀yR(y,y). With φ=∀yR(x,y) and t=y, the definition of substitution gives φ[y/x]=∀yR(y,y), which is line 1. So it is tempting to write ∃x∀yR(x,y) by ∃I.

1∀yR(y,y)
2∃x∀yR(x,y)∃I 1

Line 2 breaks the side condition: the free occurrence of x in φ lies in the scope of ∀y, and y is the variable of the term t, so y is not free for x in φ. The step would be wrong. Read over Z with R(x,y) as “x≤y”: line 1 says that every integer is at most itself, which is true, and line 2 says that some integer is at most every integer, that is, that there is a least integer, which is false. The y put in for x was meant to name one object, and it was captured by ∀y and made to range over all of them.

Warning. The witness must be written on a line. “There is an N with 1/(N+1)<1/100: take N large enough” is not an application of ∃I, because “large enough” is not a term, and the rule asks for an instance φ[t/x] on an available line. In a written proof, “large enough” is a promise to name the witness, and the promise is kept by a term such as N=100, followed by the check that it works (1/101<1/100). Until then nothing has been proved.

Quick check. Let line 1 be 2+2=4. Which of ∃x(x+x=4),∃x(x+2=4),∃x(2+2=x) may line 2 be, justified by one application of ∃I to line 1? For each that may, name φ and the witness t.

Solution. All three. For ∃x(x+x=4), take φ=(x+x=4) and t=2: both 2’s of line 1 are marked. For ∃x(x+2=4), take φ=(x+2=4) and t=2: only the first 2 is marked, and the second is written out in φ. For ∃x(2+2=x), take φ=(2+2=x) and t=4: the witness is a different term. In each case φ[t/x] is exactly line 1, and φ has no quantifier, so t is free for x.

5.5.3. From “for every” to “there exists”

The sequent ∀xP(x)⊢∃xP(x) looks like the easiest in the chapter, and it has a small puzzle in it. To use ∃I, the goal needs an instance P(t) on a line. The premise gives an instance for every term, by ∀E. But the sequent mentions no constant, so which term?

Proposition 5.5.1 (Every Implies Some)

∀xP(x)⊢∃xP(x).

Proof. The following is a derivation.

1∀xP(x)
2P(x)∀E 1
3∃xP(x)∃I 2

Line 2 is ∀E at the term x: with φ=P(x), the instance φ[x/x] is P(x), and the variable x is free for x in every formula (Section 5.2). Line 3 is ∃I with the same φ and the witness x. This proves the proposition.

The puzzle is answered by the paragraph “Which occurrences?” after Definition 5.5.1: the witness may be a variable, the variable x itself included, so no constant is needed. The line P(x) has x free; it says that P holds of whatever x names. Nothing in the derivation says what that is, and nothing needs to. The same three lines prove ∀xφ⊢∃xφ for every formula φ, since φ[x/x]=φ (Section 5.2).

Remark. The rules accept this derivation in any case; it leads from a true premise to a true conclusion only because every domain has at least one element, the convention of Section 5.1. Over an empty domain, ∀xP(x) would be true with nothing to check and ∃xP(x) false with no witness; the convention enters at line 2, where P(x) treats x as naming an object, and there must be one to name.

Second readingThe empty set, again

This does not clash with the empty set of Section 5.1, where ∀x∈∅φ is true and ∃x∈∅φ is false. A bounded quantifier is an abbreviation (Definition 5.1.1): ∀x∈∅φ is ∀x(x∈∅→φ), and ∃x∈∅φ is ∃x(x∈∅∧φ). The domain is still non-empty; it is the set ∅ that has no elements. Running the three lines on the bounded premise gives ∀E at x, the line x∈∅→φ, and then ∃I gives only ∃x(x∈∅→φ), an existential with → inside. No line x∈∅ is available to fire the implication, so the bounded “every implies some” is not derived, and it should not be.

5.5.4. An existential goal: postpone the witness

The search method of Section 3.1 asks two questions at each gap: what is the goal, and what are the resources? Sections 5.3 and 5.4 added a step for each side of ∀. Now ∃ can be a goal.

If the goal is ∃xφ, its last line can be ∃I, and then the new goal is φ[t/x] for a term t of our choosing. That is the same situation as a goal φ∨ψ, where ∨I left us to choose a side, and the danger is the same. A wrong t can leave a goal that does not follow from the resources, although the existential does. Section 3.1 met the danger for ∨ and answered it by postponing; the answer here is the same.

Postpone the witness: choose the term t of a goal ∃xφ only when an available line shows an instance φ[t/x].

Quick check. Premises: ∀x(P(x)→Q(x+1)) and P(2). The goal is ∃yQ(y). Which witness will the search find, and after which steps?

Solution. The term 2+1: ∀E at 2 gives P(2)→Q(2+1), →E gives Q(2+1), and only then does ∃I have an instance to cite. (Writing the witness as 3 instead needs the line 2+1=3 and the equality rule of Section 5.7.)

Until then, work on the premises and on the other goals, and watch what terms appear. Often the witness is a term that only appears late, built by ∀E or →E from the premises. Here are four derivations, in order of difficulty, each with an Idea that says why each rule was chosen.

Example (Derivations with existential introduction)

Show that:

  • (a) P(c)∧Q(c)⊢∃x(P(x)∧Q(x));
  • (b) R(c,c)⊢∃xR(x,c)∧∃xR(x,x); and decide whether one ∃I step leads from ∃xR(x,x) to ∃xR(x,c);
  • (c) ∀xR(x,x)⊢∀x∃yR(x,y);
  • (d) ∀x(P(x)→Q(f(x))), P(c)⊢∃yQ(y).

Solution.

  • (a) Idea. The goal is an existential, and the premise already is an instance of a suitable φ: mark both occurrences of c. One goal-directed step finishes.
    1P(c)∧Q(c)
    2∃x(P(x)∧Q(x))∃I 1

    Here φ=P(x)∧Q(x) and t=c. Marking only the first c, with φ=P(x)∧Q(c), would give the legal but weaker line ∃x(P(x)∧Q(c)), which is not the goal.

  • (b) Idea. The goal is a conjunction, so it splits into two goals (Section 1.2), and each is an existential with the line R(c,c) as an instance, read in two different ways (the first and third rows of the table above). The goal at the bottom (left); then the two subgoals that ∧I asks for (right).
    1R(c,c)
    ⋮
    4∃xR(x,c)∧∃xR(x,x)?
    1R(c,c)
    ⋮
    2∃xR(x,c)?
    ⋮
    3∃xR(x,x)?
    4∃xR(x,c)∧∃xR(x,x)∧I 2, 3
    1R(c,c)
    2∃xR(x,c)∃I 1
    3∃xR(x,x)∃I 1
    4∃xR(x,c)∧∃xR(x,x)∧I 2, 3

    Line 2 uses φ=R(x,c) and line 3 uses φ=R(x,x), both with the witness c.

    Now the second question. From the line ∃xR(x,x), the step to ∃xR(x,c) is not an ∃I step. The new line is ∃xφ with φ=R(x,c), so the cited line would have to be R(t,c) for some term t. The line ∃xR(x,x) is not of that form: its main symbol is ∃x, not R. The rule passes from an instance to an existential, never from one existential to another. Nor is the step safe by any other route: read over Z with R(x,y) as “x⋅y=1” and c as 0, the line ∃xR(x,x) is true (take x=1), and ∃xR(x,c), “some integer times 0 is 1”, is false.

  • (c) Idea. The goal is a ∀, so the step of Section 5.4 opens a flagged box with a fresh name x0, and the new goal is ∃yR(x0,y). That is an existential: postpone it and look at the premise. The premise is a ∀; instantiate it at the term the goal mentions, x0. The result, R(x0,x0), shows the witness: it is x0 itself, a variable used as a term, as x was in Proposition 5.5.1. The box with its postponed goal (left); then the instance that shows the witness (right).
    1∀xR(x,x)
    x0⋮
    3∃yR(x0,y)?
    4∀x∃yR(x,y)?
    1∀xR(x,x)
    2x0R(x0,x0)∀E 1
    3∃yR(x0,y)?
    4∀x∃yR(x,y)?
    1∀xR(x,x)
    2x0R(x0,x0)∀E 1
    3∃yR(x0,y)∃I 2
    4∀x∃yR(x,y)∀I 2–3

    Line 3 uses φ=R(x0,y), the variable y, and the witness x0; it marks the second occurrence of x0 and keeps the first. Line 4 is ∀I with the flag x0 (Definition 5.4.1): x0 appears in no premise, there is no open assumption, and x0 does not appear in line 4. The ∃I inside the box needed no box of its own, although its witness is a fresh name. Read over N with R(x,y) as “x≤y”: every number is at most itself, so every number is at most something.

  • (d) Idea. The goal ∃yQ(y) is an existential, and no line yet has the form Q(t). Postpone, and work forwards. The premise ∀x(…) is a ∀; the only term in sight is c, so instantiate at c (Section 5.3), and →E with the premise P(c) fires. The result Q(f(c)) shows the witness: the compound term f(c). In the Givens/Goal table:
Givens Goal
∀x(P(x)→Q(f(x))), P(c) ∃yQ(y): postponed, no instance yet
+ P(c)→Q(f(c)) (∀E at c) ∃yQ(y)
+ Q(f(c)) (→E) ∃yQ(y) ✓ by ∃I, witness f(c)

The postponed goal (left); then the two forward steps, after which the witness is visible (right).

1∀x(P(x)→Q(f(x)))
2P(c)
⋮
5∃yQ(y)?
1∀x(P(x)→Q(f(x)))
2P(c)
3P(c)→Q(f(c))∀E 1
4Q(f(c))→E 3, 2
5∃yQ(y)?
1∀x(P(x)→Q(f(x)))
2P(c)
3P(c)→Q(f(c))∀E 1
4Q(f(c))→E 3, 2
5∃yQ(y)∃I 4

Line 5 uses φ=Q(y) and t=f(c). Now see what choosing the witness first would have done. The term in sight at the start is c, and “take y=c” leaves the goal Q(c). Nothing gives it: the premise speaks of Q only at terms of the form f(…), and Q(c) need not hold at all. Read over Z with P as “odd”, Q as “even”, f(x) as x+1, and c as 3: the premises say that the successor of every odd integer is even and that 3 is odd, the conclusion says that some integer is even, and the witness the derivation finds is f(3)=4, while Q(c) says that 3 is even. The search stalls exactly because it chose the witness before the derivation had produced it.

The four Ideas share a pattern. In (a) and (b) the witness stood on a premise line from the start; in (c) and (d) it appeared only after other rules had run, and in (d) it was a term that no line mentioned at the start. Postponing costs nothing in (a) to (c), where the right witness was already a term in sight when the existential goal appeared (in (c) the goal names x0), and it is necessary in (d), where the only term in sight at the start, c, is the wrong witness.

5.5.5. How this rule looks in a mathematical proof

In a written proof, ∃I is the word “take”, followed by a check. “6 is even: take k=3; then 6=2⋅3.” Over Z, with one line of school arithmetic justified “arith” as in Section 5.3:

16=2⋅3arith
2∃k(6=2⋅k)∃I 1

Line 2 marks the 3 with k, and keeps the 6 and the 2: φ=(6=2⋅k). In the same way “7 is odd: take k=3, since 7=2⋅3+1” is an ∃I with φ=(7=2⋅k+1).

A bounded witness. Analysis states its existentials with bounds. “There is an N∈N with 1/(N+1)<1/100” abbreviates ∃N(N∈N∧1/(N+1)<1/100) (Definition 5.1.1), so the witness must satisfy both conjuncts. Taking N=100 is two steps: ∧I puts the bound and the inequality together, and ∃I forgets the witness.

1100∈Narith
21/(100+1)<1/100arith
3100∈N∧1/(100+1)<1/100∧I 1, 2
4∃N(N∈N∧1/(N+1)<1/100)∃I 3

Line 4 marks two of the three occurrences of 100 in line 3 and keeps the one on the right. The witness 100 is the least that works, since N=99 gives 1/100, which is not less than 1/100; but the proof does not need the least witness, only one.

A witness built from what is available. Often the witness is a term made from other names. To show that for every integer n there is an odd integer greater than 2n, a proof says “let n be an integer; 2n+1 will do, since it is odd and greater than 2n”. The words “let n be an integer” open the flagged box of Section 5.4, and “2n+1 will do” is ∃I with the compound witness 2n+1, as in (d) above. In general, the witness may be any term the reader can check.

Warning. ∃I runs one way only. From P(c) it gives ∃xP(x); from ∃xP(x) it gives nothing, and in particular not P(c). “Some integer is even” is true and “3 is even” is false: the existential does not say which object has the property, so it cannot be read back as a statement about a named one. Using an existential takes a rule of its own, with a box, and that is Section 5.6.

5.5.6. The rule card

Before the card, the rule at work on lines larger than R(c,c). The schema sees the cited line as φ[t/x] however much is inside t and φ.

Example (Instances of ∃I)
Cited line φ Witness t New line
P(f(f(c)))∧Q(f(c)) P(f(x))∧Q(x) f(c) ∃x(P(f(x))∧Q(x))
|a−b|<ε/2 |a−b|<δ ε/2 ∃δ(|a−b|<δ)
(n+1)⋅(n+1)=n⋅n+2⋅n+1 m⋅m=n⋅n+2⋅n+1 n+1 ∃m(m⋅m=n⋅n+2⋅n+1)

In each row φ[t/x] is exactly the cited line, and the marked places are whole occurrences of t (in the third, both factors on the left; the n’s on the right are not occurrences of n+1, and they stay).

Not an instance. From P(c)∧Q(d), the line ∃x(P(x)∧Q(x)) is not written by ∃I: φ[t/x] puts one term in every marked place, and no single t turns P(x)∧Q(x) into P(c)∧Q(d).

Quick check. Line 1 is Q(g(c),c). Write the ∃I line with the witness c that marks only the c inside g(c), and name its φ.

Solution. ∃xQ(g(x),c), with φ=Q(g(x),c); φ[c/x] is line 1.

Chapters 1 and 2’s thirteen rules are on the card at the end of Section 3.1; here are this chapter’s so far. Nothing later depends on the last column, and Section 5.7 collects the whole table.

Rule Shape Side condition You write Lean
∀E ∀xφ ⟹ φ[t/x] t free for x in φ “In particular, for x=t, …”; “applying the hypothesis to t, …” h t (or specialize h t)
∀I box [x0] … φ[x0/x] ⟹ ∀xφ x0 in no premise, in no open assumption, not in ∀xφ “Let x be arbitrary. … Since x was arbitrary, …” intro x
∃I φ[t/x] ⟹ ∃xφ t free for x in φ “Take x=t. Then …”; “2k+1 will do.” use t (or Exists.intro t h)

The phrase names the witness and then checks it. A proof that names the witness without the check (“take N=100.”) has written the line ∃xφ without the instance φ[t/x] it cites; the reader must supply the instance, and should be able to.

In the Givens/Goal table, ∃I ticks off the goal ∃xφ once a Given is an instance φ[t/x]; until then the goal row waits.

Warning (Not allowed: ∃I). Each step is offered as one application of ∃I; each breaks the rule where shown.

  • “From P(c)∧Q(d), write ∃x(P(x)∧Q(x))”: the cited line must be exactly φ[t/x], with one term t in every marked place.
  • “From ∀y(y<y+1), write ∃x∀y(y<x)”: the side condition; the witness y+1 is not free for x in ∀y(y<x).
  • “From P(t), write ∃x∈AP(x)”: the cited line must be the instance; the bounded form is ∃x(x∈A∧P(x)), whose instance is t∈A∧P(t) (“A bounded witness”).

The search method: one more step. Each rule section adds a step to the method of Section 3.1.

  • Goal ∃xφ. Postpone. Work on the premises and on other goals until an available line is an instance φ[t/x], with t free for x in φ; then ∃I. The witness may be a compound term that appears only after other rules have run, as f(c) did in (d).

5.5.7. Exercises

A. Check your understanding

Exercise (A1)
  • (a) State ∃I as a schema, with its side condition.
  • (b) Line 1 of a derivation is R(c,f(c)). Which of the following may line 2 be, by one application of ∃I to line 1? For each that may, give φ and the witness t; for each that may not, say why.
    • (i) ∃xR(x,f(c)); (ii) ∃xR(c,x); (iii) ∃xR(x,f(x)); (iv) ∃xR(x,x); (v) ∃xR(f(c),x).
  • (c) Line 1 of a derivation is ∀y(y≤y⋅y). Is ∃x∀y(y≤x⋅x) a legal ∃I step from line 1? Read both lines over Z: which is true?
  • (d) True or false, with a reason: from the line ∃xP(x), one application of ∃I gives P(c).
  • (e) The current goal of a search is ∃xφ and no available line is an instance of φ. What does the search method say to do, and why not choose a witness now?

Solution. (a) From φ[t/x] on an available line i, write ∃xφ on line k, justified “∃I i”. Side condition: t is free for x in φ.

(b) (i) Yes: φ=R(x,f(c)), t=c; only the first c is marked. (ii) Yes: φ=R(c,x), t=f(c); the witness is the compound term. (iii) Yes: φ=R(x,f(x)), t=c; both occurrences of c are marked, and φ[c/x] is R(c,f(c)). (iv) No: the conclusion fixes φ=R(x,x), whose instances R(t,t) have equal arguments, while the arguments c and f(c) of line 1 differ. (v) No: the conclusion fixes φ=R(f(c),x), whose instances R(f(c),t) have f(c) as first argument, while line 1 has c there. (Read over N with R(x,y) as “x<y”, f(x) as x+1, and c as 0: line 1 says 0<1, and (v) says that something exceeds 1, true but not by this step; (iv) says that some number is less than itself, which is false.)

(c) No. With φ=∀y(y≤x⋅x), the formula φ[y/x] is line 1, so the witness would be the variable y; but the free occurrences of x in φ lie in the scope of ∀y, so y is not free for x in φ. Over Z, line 1 is true: for y≤0, y≤0≤y⋅y, and for y≥1, y≤y⋅y after multiplying 1≤y by y>0. The other line is false: whatever integer x is proposed, y=x⋅x+1 gives y>x⋅x. So the step would lead from a true line to a false one, which is what the side condition prevents.

(d) False. ∃I concludes an existential from an instance; it never concludes an instance. The line P(c) does not follow from ∃xP(x) at all: over Z with P as “even” and c as 3, the first is true and the second false.

(e) Postpone the goal: work on the premises (∀E at the terms the goal mentions, →E, and so on) until a line φ[t/x] appears, then use ∃I. A witness chosen now leaves the goal φ[t/x], which may not follow from the resources even when ∃xφ does, as “take y=c” did in Example (Derivations with existential introduction) (d).

Exercise (A2: Drill)

Each part takes a line or two. The parts run from single steps, through a missing line, a justification column and steps to judge, to short derivations.

  • (a) Line 1 is 3+4=7. Name φ and t so that ∃I gives ∃x(x+4=7).
  • (b) Line 2 is c+c=2⋅c. Write the ∃I lines with the witness c that mark (i) all three occurrences of c, (ii) the two on the left only.
  • (c) Line 1 is P(f(c)). Give two different ∃I conclusions.
  • (d) Line 5 is ∃y(y>x0+1), justified “∃I 4”. Give two possible lines 4, with their witnesses.
  • (e) Justify each line: 1 ∀x(P(x)→Q(f(x))), premise; 2 P(c), premise; 3 P(c)→Q(f(c)); 4 Q(f(c)); 5 P(c)∧Q(f(c)); 6 ∃x(P(x)∧Q(f(x))).
  • (f) Line 1 is R(c,c). Which of ∃xR(x,c), ∃xR(c,x), ∃xR(x,y) can one ∃I not give?
  • (g) Line 1 is ∀y(y=y). Is ∃x∀y(x=y) a legal ∃I line?
  • (h) True or false: ∃I may cite ∃xP(x) and write P(c).
  • (i) Premises P(a), Q(b); goal ∃x(P(x)∧Q(x)). Should a witness be chosen now?
  • (j) Derive P(c)⊢∃x(P(x)∨Q(x)).
  • (k) Derive ∀xP(x)⊢∃xP(f(x)).
  • (l) Derive ∀x∀yR(x,y)⊢∃x∃yR(y,x).

Solution.

  • (a) φ=(x+4=7), t=3.

  • (b)
    • (i) ∃x(x+x=2⋅x); (ii) ∃x(x+x=2⋅c).
  • (c) ∃xP(x) (witness f(c)) and ∃xP(f(x)) (witness c).

  • (d) Any line t>x0+1 with t free for y (every term is, since the formula has no quantifier): for example x0+2>x0+1 (witness x0+2) or 7>x0+1 (witness 7).

  • (e) 3 ∀E 1 (at c); 4 →E 3, 2; 5 ∧I 2, 4; 6 ∃I 5 (witness c, marking the c of P(c) and the one inside f(c)).

  • (f) ∃xR(x,y): its instances R(t,y) have y in the second place, and line 1 has c.

  • (g) No: the witness would be y, which ∀y captures. Over Z line 1 is true and the other line, “some integer equals every integer”, false.

  • (h) False: ∃I goes from an instance to an existential, never back.

  • (i) No: neither a nor b has both properties on a line. In fact a counter-reading exists: the domain {a,b}, with P true of a only and Q of b only.

  • (j) 2 P(c)∨Q(c), ∨I 1; 3 ∃x(P(x)∨Q(x)), ∃I 2.

  • (k) 2 P(f(x)), ∀E 1 (at the term f(x)); 3 ∃xP(f(x)), ∃I 2 (with φ=P(f(x)) and the witness x).

  • (l) 2 ∀yR(x,y), ∀E 1 (at x); 3 R(x,x), ∀E 2; 4 ∃yR(y,x), ∃I 3 (witness x, marking the first place); 5 ∃x∃yR(y,x), ∃I 4 (witness x).

B. Practice

Exercise (B1: Postpone, then choose)

A search for ∀x(P(x)→Q(x)), P(a)⊢∃x(P(x)∧Q(x)) has reached the stage below. Name the move, then complete it, saying for each line whether the goal or a premise chose it.

1∀x(P(x)→Q(x))
2P(a)
⋮
6∃x(P(x)∧Q(x))?

Solution. The move is postpone the witness.

Idea. The goal is an existential: postpone it. The premise ∀x(…) is instantiated at the only term in sight, a, and →E with P(a) gives Q(a); both steps are premise-directed. Now the witness a is visible, and the instance the goal needs is P(a)∧Q(a), which ∧I builds. The last step is the postponed ∃I.

1∀x(P(x)→Q(x))
2P(a)
3P(a)→Q(a)∀E 1
4Q(a)→E 3, 2
5P(a)∧Q(a)∧I 2, 4
6∃x(P(x)∧Q(x))∃I 5

Line 6 uses φ=P(x)∧Q(x) and the witness a.

Exercise (B2)

Over R, with the premise ∀x(x+(−x)=0), derive ∀x∃y(x+y=0), the true sentence (i) of Example (Swapping two quantifiers). Say what the witness is, and what it depends on.

Solution. Idea. The goal is a ∀: open a flagged box with a fresh name x0 (Section 5.4); the new goal is ∃y(x0+y=0). Postpone it, and instantiate the premise at the term the goal mentions, x0. The line x0+(−x0)=0 shows the witness: −x0.

1∀x(x+(−x)=0)
2x0x0+(−x0)=0∀E 1
3∃y(x0+y=0)∃I 2
4∀x∃y(x+y=0)∀I 2–3

Line 3 uses φ=(x0+y=0) and the witness −x0, which contains no variable bound in φ. At line 4, x0 appears in no premise, there is no open assumption, and x0 does not appear in the conclusion, so ∀I applies (Definition 5.4.1).

The witness −x0 is built from x0, so it depends on x0: a different number for each x. That is legal, because ∃I is applied inside the box, where x0 is available as a term. It is the box picture of the game of Section 5.1: the ∃y is played after the ∀x, and may use it.

Exercise (B3)

Over Z, prove “there is an integer n with n2=n+2” as a derivation whose only line not justified by a rule is one line of arithmetic justified “arith”; write n2 as n⋅n. Then write the proof as one sentence.

Solution. The witness 2 works, since 2⋅2=4=2+2.

12⋅2=2+2arith
2∃n(n⋅n=n+2)∃I 1

Line 2 uses φ=(n⋅n=n+2) with the witness 2. Line 1 contains four 2’s, and φ marks three of them: both factors on the left and the first term of the sum on the right. The last 2 is the constant of the statement and stays. Marking all four would give ∃n(n⋅n=n+n), a different statement.

In one sentence: Take n=2; then n2=4=n+2.

The witness −1 works too, since (−1)⋅(−1)=1=−1+2; a proof needs only one.

Exercise (B4: Derive or break)

For each claim, derive it with the rules of Chapters 1–2, ∀E, ∀I and ∃I, or break it with a counter-reading (Section 5.3).

  • (a) ∀xP(x)⊢∃x(P(x)∨Q(x)).
  • (b) ∃xP(x)⊢∀xP(x).
  • (c) R(c,d)∧R(d,c)⊢∃xR(x,x).
  • (d) R(c,d)∧R(d,c)⊢∃x∃y(R(x,y)∧R(y,x)).
  • (e) ∀xR(x,f(x))⊢∀x∃yR(x,y).
  • (f) ∀xR(x,f(x))⊢∃y∀xR(x,y).
  • (g) ⊢∃x(P(x)→P(x)).

Solution.

  • (a) Derive. Instantiate at the variable x, weaken, and forget the witness.
    1∀xP(x)
    2P(x)∀E 1
    3P(x)∨Q(x)∨I 2
    4∃x(P(x)∨Q(x))∃I 3

    Line 4 uses φ=P(x)∨Q(x) and the witness x.

  • (b) Break. The domain {0,1}, with P true of 0 only. The premise holds (at 0), and the conclusion fails at 1.

  • (c) Break. The domain {0,1}, with c naming 0, d naming 1, and R true of the pairs (0,1) and (1,0) only. The premise holds, and no element is related to itself.

  • (d) Derive. Two witnesses, one for each place, forgotten one at a time.

    1R(c,d)∧R(d,c)
    2∃y(R(c,y)∧R(y,c))∃I 1
    3∃x∃y(R(x,y)∧R(y,x))∃I 2

    Line 2 uses φ=R(c,y)∧R(y,c) and the witness d; line 3 uses φ=∃y(R(x,y)∧R(y,x)) and the witness c, which is free for x since it is a constant.

  • (e) Derive. Fix x0 first; the witness f(x0) is found after the flag.
    1∀xR(x,f(x))
    2x0R(x0,f(x0))∀E 1
    3∃yR(x0,y)∃I 2
    4∀x∃yR(x,y)∀I 2–3

    At line 4, x0 appears in no premise, no box is open, and x0 is not in line 4.

  • (f) Break. The domain {0,1}, with f the identity (f(0)=0, f(1)=1) and R true of (0,0) and (1,1) only. The premise holds, since each element is related to itself; and no y has both R(0,y) and R(1,y).

  • (g) Derive. A box with its assumption as its only line, then ∃I at the variable x.

1P(x)asm, for →I
2P(x)→P(x)→I 1–1
3∃x(P(x)→P(x))∃I 2

Line 3 has the witness x; the variable names an object, since domains are not empty (Section 5.1).

The pairs: (c) and (d) are look-alikes (one witness for both places, against two witnesses); (e) and (f) differ only in the order of ∀ and ∃, the swap of Section 5.1, and the witness f(x0) in (e) depends on the flag; (b) is the converse of Proposition 5.5.1. Worked examples of these types: Example (Derivations with existential introduction); Proposition 5.5.1.

Marking scheme. (10 points)

  • 1 each: (a), (b), (c), (d), (f), (g), with the derivation or the counter-reading in full.
  • 2: (e), with the flag opened first and the witness f(x0) found after it.
  • 2: the closing pairing.

Fatal errors (0 for the claim): an ∃I whose witness is not free for the variable; a “break” in which the premise is false.

C. Going deeper

Exercise (C1: The conclusion clause of for-all-introduction, used later)

The side condition of ∀I (Definition 5.4.1) has three clauses about the flag x0: it appears in no premise, in no assumption of a box still open at the ∀I line, and not in the conclusion ∀xφ. Show that the third clause is needed: give a “derivation” that breaks only that clause, from a premise that is true over N to a sentence (Definition 5.2.4) that is false over N. Check that every other step is legal.

Solution (Hint 1). The conclusion of the illegal ∀I still mentions the flag, so it is not yet a sentence. Which rule of this section can replace a name on a line by a bound variable?

Solution (Hint 2). Start from the premise ∀x(x≤x), and open a flagged box with the name y0.

Solution.

1∀x(x≤x)
2y0y0≤y0∀E 1
3∀x(x≤y0)∀I 2–2
4∃y∀x(x≤y)∃I 3

The illegal line. Line 3 is ∀I with the flag y0 and φ=(x≤y0): the instance φ[y0/x] is y0≤y0, the last line of the box. The flag y0 appears in no premise (line 1 has no y0), and there is no open assumption at all. But y0 appears in the conclusion ∀x(x≤y0), so the third clause fails, and only it.

The other lines are legal. Line 2 is ∀E at the term y0, which is free for x in x≤x since that formula has no quantifier. Line 4 is ∃I with φ=∀x(x≤y) and the witness y0: φ[y0/y] is line 3, and y0 is free for y in φ, since the only quantifier of φ is on x.

Over N. Line 1 says that every natural number is at most itself: true. Line 4 says that some natural number is at least every natural number, that is, that there is a largest natural number: false, since for any y, x=y+1 is larger.

What the clause prevents. The box proved y0≤y0, a fact about y0 in which the two sides are the same name. Line 3 generalized only one side and kept the other, so it claimed that one fixed y0 is at least every x: a claim about y0 that the box never proved. The flag is “let y0 be arbitrary”; it must not survive into the statement that “since y0 was arbitrary” produces. Line 4 then shows the damage, by turning the leaked name into a witness.

Marking scheme. (10 points) - 3: a derivation whose only illegal line is a ∀I whose flag appears in its conclusion. - 2: checks the other two clauses at that line (no premise, no open assumption contains the flag). - 2: checks the remaining lines (here ∀E and ∃I, with free-for). - 3: shows the premise true and the conclusion false over N, with the witness of the falsity (y+1). Fatal errors (0 for the step): a second illegal line (for instance a capture in ∃I); a premise that is false over N.

Exercise (C2: A witness is not a name, used later)

Explain why the rules so far (Chapters 1–2 and ∀E, ∀I, ∃I) cannot derive ∃xP(x)⊢P(c). Go through the rules that could produce the last line P(c), and say what each would need. Then say, in one sentence, why no rule for using ∃ should give P(c).

Solution. The argument below is informal: it explains why every search stalls, and it does not by itself prove that no derivation exists. Section 7.2 gives a model in which the premise is true and P(c) is false. With the soundness theorem stated there (and proved in the optional Section 7.3), that model shows no derivation exists.

Which rules could write P(c). The line P(c) is atomic, so no introduction rule writes it: ∧I, →I, ∨I, ¬I, ↔I, ∀I and ∃I all write a line whose main symbol is their own connective or quantifier. The remaining rules take P(c) out of something larger: ∧E needs a conjunction with P(c) as a side; →E needs an implication ψ→P(c) and ψ; ↔E a biconditional with P(c) as a side; ∨E a disjunction and two boxes each ending in P(c); ∀E a universal ∀xψ with ψ[c/x]=P(c); ¬E writes only ⊥, never P(c); ⊥E the line ⊥; RAA a box from ¬P(c) to ⊥; and R the line P(c) itself.

The derived rules of Chapter 2 abbreviate derivations in these rules (Definition 2.3.1), so they add no new way to write P(c).

What the premise can supply. The only premise is ∃xP(x), whose main symbol is ∃. No rule so far looks inside an existential: each elimination rule needs a cited line that is ⊥ (for ⊥E) or whose main symbol is ∧, →, ∨, ↔, ¬ or ∀, and ∃I produces existentials rather than using them. So the premise can enter a derivation only as a whole: copied, built into a larger formula, set against a line ¬∃xP(x) by ¬E, or cited as the side ψ beside a line ψ→χ or ψ↔χ by →E or ↔E. None of these reaches the information inside it, and the lines the rules above need (a conjunction containing P(c), an implication ending in it, a biconditional with it as a side, a disjunction for ∨E, a universal with it as an instance, a contradiction) have nowhere to come from. A search therefore stalls at once.

Why it should stall. The premise says that something has P and does not say what; the conclusion says that the object named c has P. Over Z with P as “even” and c as 3, the premise is true and the conclusion false. So no rule for using an existential may give P(c), and the rule of Section 5.6 does not: it names the witness with a fresh variable, about which nothing else is known, instead of with c.

Marking scheme. (10 points) - 3: identifies that P(c) is atomic, so only elimination rules, ⊥E, RAA or R can write it, and names what each needs. - 3: observes that no rule so far uses a line whose main symbol is ∃, so the premise cannot supply what those rules need. - 2: says that this explains the stall but is not a proof of non-derivability (that needs a counter-model together with soundness, Sections 7.2–7.3). - 2: gives a reading with the premise true and P(c) false, and the one-sentence reason (the premise does not say which object has P). Fatal errors (0 for the step): claiming that ∃I read backwards gives P(c); claiming that a failed search proves the sequent underivable.