Logic for Computer Scientists/Induction

From Wikibooks, open books for an open world
< Logic for Computer Scientists
Jump to: navigation, search


Induction plays a crucial role at least in two aspect throughout this book. Firstly, it is one of main proof principles in mathematics and of course in logics. In particular it can be used to investigate properties of infinite sets. Very often it is used as natural induction, namely over the natural numbers. We will introduce it as a more general principle over well founded partial orders, which is called structural induction. The second aspect is, that it can be used as well to define infinite structures, as the set of well formed formulae in a particular logic or the set of binary trees.

We start with a very general structure over arbitrary sets, namely partial orders. A relation over is a partial order iff is reflexive, transitive and anti-symmetric (i.e. ) . Partial ordered sets (p.o. sets) are usually written as .

Definition 1[edit]

The necessary structure for our induction principle is a partial order, such that there exist minimal elements. Given a p.o. set , we define:

  • iff and .
  • is called well-founded iff there is no infinite sequence and .
  • is called a chain iff or
  • is a total ordering iff is a chain.

Lemma 1[edit]

is well-founded, if every non-empty subset of has a minimal Element. Proof can be done by contradiction and will be given as an exercise.

We finally have the machinery to introduce the principle of complete induction:

Definition 2 (Complete (structural) induction)[edit]

Given a well-founded p.o. set and a predicate , i.e. . The principle of induction is given by the following (second order) formula

Lemma 2[edit]

The induction principle holds for every well-founded set.

Proof: The proof is given by contradiction: Assume the principle is wrong; i.e. the implication is wrong, which means, that we have to assume the premise as true:

and the conclusion as wrong:

Hence we can assume that the set is not empty.

Since is a subset of a well-founded set, it has a minimal element, say . From assumption (premise) we conclude

Now we can distinguish two cases:

  • is minimal in : Hence there is no , such that . Hence the premise of the implication in (inst) is true, which implies that the conclusion is true. This is a contradiction to the assumption that
  • is not minimal in : holds and it must be that is true, because otherwise it would be that and not minimal in . Hence, again the premise of the implication in (inst) is true, which implies that the conclusion is true. This is a contradiction to the assumption that !

An Example[edit]

In this subsection we will carry out a proof with induction in detail. For this we need the extension of p.O. sets:

Definition 3 (Lexicographic Ordering)[edit]

A p.O. set induces an ordering over : iff

  • and or
  • or
  • and

Lemma 3[edit]

If is a well-founded set, then is well-founded as well.

Theorem 1[edit]

The Ackermann-function defined by the following recursion is a total function over

  ACK(x,y) = 
    if x=0  then y+1 else
                     if y=0 then ACK(x-1,1) 
                            else ACK(x-1,ACK(x, y-1))

Proof: For the induction start we take the minimal element of the well-founded set,
, where is the lexicographic ordering induced by . Hence, assume . By definition of
, we conclude and hence defined. Assume for an an arbitrary , that

is defined for all , if

We distinguish the following cases:

  • : i.e. and hence defined.
  • and : We know that and . From the induction hypothesis we know that is defined, and hence as well.
  • and : According to the definition of we have two cases to consider:
    • and : From the induction hypothesis we conclude immediately that is defined.
    • and : Independent from the values of and . If we assume
      and , we again can conclude from the hypothesis, that is defined and hence as well

Altogether we proved, that is defined for all .


Problem 1 (Induction)[edit]

Prove the following lemma: If is well founded also .

Note: The lexicographical Order is defined as follows:

Problem 2 (Induction)[edit]

How many points of intersection could straight lines have at most? Find a recursive and explicit formula and show

Problem 3 (Induction)[edit]

Prove that a number is even if and only if is even.

Problem 4 (Induction)[edit]

Point by an indirect proof that there is not any greatest prime number!

Problem 5 (Induction)[edit]

Which prerequisite do you need that the following order


  1. partial ordered
  2. total ordered
  3. well-founded?

Problem 6 (Induction)[edit]

An example of a well founded set is the power set over a finite set which is comparable over the relation of the subset . If then is e.g. but and are not comparable. Give a definition of a relation in this way that is total ordered and well founded.

Problem 7 (Induction)[edit]

Examine which of the following partial order are total and which are well founded!

  1. with is the power set for natural numbers.
  2. with marks the relation "`is factor of"'.
  3. with iff or ( and ).
  4. with is the lexicographical .
  5. for , i.e.

Problem 8 (Induction)[edit]

Give for the natural numbers an order relation, that is

  1. both well-founded and total,
  2. total but not well-founded,
  3. well-founded but not total and
  4. neither well-founded nor total.

Problem 9 (Induction)[edit]

Prove, that a partial order is well-founded iff every non-empty partial set of (at least) contains a minimum element.

Problem 10 (Induction)[edit]

A root tree consists (a) of a single node or (b) of a node - that's the root of the tree - and at least one, but only at most finite many (part)trees, this one is bandaged over an edge with the root. Point formally by means of induction, that in every tree the number of the nodes around is taller than the number of the edges , i.e. .

Problem 11 (Induction)[edit]

Prove: If ε is a quality of the natural numbers and it is valid

  1. ε(0) and
  2.  : [ε(n) ε(n+1)].

then  : ε(n) is valid.

Note: The proof can be done by the fact that the principle of the complete induction in (which should be proved) can be reduced to the principle of the transfinite induction for well founded orders.