Detlovs Podnieks Math Logic.Pdf (1.129Mb)
Total Page:16
File Type:pdf, Size:1020Kb
1 Version released: August 25, 2014 Introduction to Mathematical Logic Hyper-textbook for students by Vilnis Detlovs, Dr. math., and Karlis Podnieks, Dr. math. University of Latvia This work is licensed under a Creative Commons License and is copyrighted © 2000-2014 by us, Vilnis Detlovs and Karlis Podnieks. Sections 1, 2, 3 of this book represent an extended translation of the corresponding chapters of the book: V. Detlovs, Elements of Mathematical Logic, Riga, University of Latvia, 1964, 252 pp. (in Latvian). With kind permission of Dr. Detlovs. Vilnis Detlovs. Memorial Page In preparation – forever (however, since 2000, used successfully in a real logic course for computer science students). This hyper-textbook contains links to: Wikipedia, the free encyclopedia; MacTutor History of Mathematics archive of the University of St Andrews; MathWorld of Wolfram Research. 2 Table of Contents References..........................................................................................................3 1. Introduction. What Is Logic, Really?.............................................................4 1.1. Total Formalization is Possible!..............................................................5 1.2. Predicate Languages.............................................................................10 1.3. Axioms of Logic: Minimal System, Constructive System and Classical System..........................................................................................................26 1.4. The Flavor of Proving Directly.............................................................38 1.5. Deduction Theorems.............................................................................41 2. Propositional Logic......................................................................................51 2.1. Proving Formulas Containing Implication only...................................51 2.2. Proving Formulas Containing Conjunction..........................................52 2.3. Proving Formulas Containing Disjunction...........................................55 2.4. Formulas Containing Negation – Minimal Logic.................................58 2.5. Formulas Containing Negation – Constructive Logic..........................64 2.6. Formulas Containing Negation – Classical Logic................................66 2.7. Constructive Embedding. Glivenko's Theorem....................................69 2.8. Axiom Independence. Using Computers in Mathematical Proofs........72 3. Predicate Logic.............................................................................................87 3.1. Proving Formulas Containing Quantifiers and Implication only..........87 3.2. Formulas Containing Negations and a Single Quantifier.....................89 3.3. Proving Formulas Containing Conjunction and Disjunction................99 3.4. Replacement Theorems.......................................................................101 3.5. Constructive Embedding.....................................................................107 4. Completeness Theorems (Model Theory)..................................................116 4.1. Interpretations and Models.................................................................116 4.2. Classical Propositional Logic − Truth Tables.....................................129 4.3. Classical Predicate Logic − Gödel's Completeness Theorem.............138 4.4. Constructive Propositional Logic – Kripke Semantics.......................157 5. Normal Forms. Resolution Method............................................................177 5.1. Prenex Normal Form..........................................................................179 5.2. Skolem Normal Form.........................................................................189 5.3. Conjunctive and Disjunctive Normal Forms......................................194 5.4. Clause Form........................................................................................199 5.5. Resolution Method for Propositional Formulas..................................205 5.6. Herbrand's Theorem............................................................................214 5.7. Resolution Method for Predicate Formulas........................................220 6. Miscellaneous.............................................................................................233 6.1. Negation as Contradiction or Absurdity.............................................233 3 References Hilbert D., Bernays P. [1934] Grundlagen der Mathematik. Vol. I, Berlin, 1934, 471 pp. (Russian translation available) Kleene S.C. [1952] Introduction to Metamathematics. Van Nostrand, 1952 (Russian translation available) Kleene S.C. [1967] Mathematical Logic. John Wiley & Sons, 1967 (Russian translation available) Mendelson E. [1997] Introduction to Mathematical Logic. Fourth Edition. International Thomson Publishing, 1997, 440 pp. (Russian translation available) Podnieks K. [1997] What is Mathematics: Gödel's Theorem and Around. 1997-2012 (available online, Russian version available). 4 1. Introduction. What Is Logic, Really? WARNING! In this book, predicate language is used as a synonym of first order language, formal theory – as a synonym of formal system, deductive system, constructive logic – as a synonym of intuitionistic logic, algorithmically solvable – as a synonym of recursively solvable, algorithmically enumerable – as a synonym of recursively enumerable. What is logic? See also Factasia Logic by Roger Bishop Jones. In a sense, logic represents the most general means of reasoning used by people and computers. Why are means of reasoning important? Because any body of data may contain not only facts visible directly. For example, assume the following data: the date of birth of some person X is January 1, 2000, and yesterday, September 14, 2010 some person Y killed some person Z. Then, most likely, X did not kill Z. This conclusion is not represented in our data directly, but can be derived from it by using some means of reasoning – axioms (“background knowledge”) and rules of inference. For example, one may use the following statement as an axiom: “Most likely, a person of age 10 can´t kill anybody”. There may be means of reasoning of different levels of generality, and of different ranges of applicability. The above “killer axiom” represents the lowest level – it is a very specific statement. But one can use laws of physics to derive conclusions from his/her data. Theories of physics, chemistry, biology etc. represent a more general level of means of reasoning. But can there be means of reasoning applicable in almost every situation? This – the most general – level of means of reasoning is usually regarded as logic. Is logic absolute (i.e. unique, predestined) or relative (i.e. there is more than one kind of logic)? In modern times, an absolutist position is somewhat inconvenient – you must defend your “absolute” concept of logic against heretics and dissidents, but very little can be done to exterminate these people. They may freely publish their concepts on the Internet. So let us better adopt the relativist position, and define logic(s) as any common framework for building theories. For example, the so-called 5 absolute geometry can be viewed as a common logic for both the Euclidean and non-Euclidean geometry. Group axioms serve as a common logic for theories investigating mathematical structures that are subtypes of groups. And, if you decide to rebuild all mathematical theories on your favorite set theory, then you can view set theory as your logic. Can there be a common logic for the entire mathematics? To avoid the absolutist approach let us appreciate all the existing concepts of mathematics – classical (traditional), constructivist (intuitionist), New Foundations etc. Of course, enthusiasts of each of these concepts must propose some specific common framework for building mathematical theories, i.e. some specific kind of logic. And they do. Can set theory (for example, currently, the most popular version of it – Zermelo-Fraenkel's set theory) be viewed as a common logic for the classical (traditional) mathematics? You may think so, if you do not wish to distinguish between the first order notion of natural numbers (i.e. discrete mathematics) and the second order notion (i.e. "continuous" mathematics based on set theory or a subset of it). Or, if you do not wish to investigate in parallel the classical and the constructivist (intuitionist) versions of some theories. 1.1. Total Formalization is Possible! Gottlob Frege (1848-1925) Charles S. Peirce (1839-1914) Bertrand Russell (1872-1970) David Hilbert (1862-1943) How far can we proceed with the mathematical rigor – with the axiomatization of some theory? Complete elimination of intuition, i.e. full reduction of all proofs to a list of axioms and rules of inference, is this really possible? The work by Gottlob Frege, Charles S. Peirce, Bertrand Russell, David Hilbert and their colleagues showed how this can be achieved even with the most complicated mathematical theories. All mathematical theories were indeed reduced to systems of axioms and rules of inference without any admixture of sophisticated human skills, intuitions etc. Today, the logical techniques developed by these brilliant people allow ultimate axiomatization of any theory that is based on a stable, self-consistent system of principles (i.e. of any mathematical theory). What do they look like – such "100% rigorous" theories? They are called formal theories (the terms “formal systems”