Logic for Computer Science - Week 2 The Syntax of Propositional Logic
|
|
- Damian Harrington
- 5 years ago
- Views:
Transcription
1 Logic for Computer Science - Week 2 The Syntax of Propositional Logic Ștefan Ciobâcă November 30, An Introduction to Logical Formulae In the previous lecture, we have seen what makes an argument valid. We have seen that several valid arguments could follow the same pattern. For example, take the following two arguments: A1: 1. All men are mortal. 2. Socrates is a man. 3. So, Socrates is mortal. A2: 1. All students are smart. 2. John is a man. 3. So, The Earth is round. Both of the arguments are obviously instances of the same pattern: P1 1. All F are G. 2. x is F. 3. So, x is G. In fact, any instance of this pattern (i.e. argument obtained by replacing F and G by properties and x by a particular individual is valid. Here is another example of argument pattern: P2 1. Either P or Q. 2. Not P. 1
2 3. So, Q. Any instance of this pattern is valid as well. Here are two such instances that we have seen in the previous lecture: Oranges are either fruits or musical instruments. Oranges are not fruits. Therefore, oranges are musical instruments. Either John is in the library or in the bar. John is not in the library. Therefore, John is in the bar. The schematic propositions that appear in such argument patterns such as Either P or Q are called logical forms, or, more modernly and simpler, formulae. Propositional logic is concerned with the systematic study with formulae such as those appearing in the second argument patterns, namely the formulae that can be constructed from atomic propositions such as P and Q and logical connectives such as and, or, not. Formulae such as those appearing in the first argument pattern (e.g., All F are G. are called first-order formulae and we will study them in the second part of this course. 1.1 On the Use of Natural Language As we have seen in the previous lecture, natural language (English, French, Romanian, etc. features inherent ambiguities. We have already seen an example of such an ambiguity: John and Mary are married could mean either that they are married to each other or that they are married, not necessarily to each other. We are no anticipating first-order logic (discussed during the second half of the course. When we will get to first-order logic, we will see that we can disambiguate between the two possible meanings of the sentence by: either using a two-argument predicate MarriedToEachOther(X, Y that means that X and Y are married to each other and writing the sentence as MarriedToEachOther(John, Mary ; or using a single-argument predicate Married(X that means that X is married (without saying who X is married to and writing the sentence as Married(John and Married(Mary. End of divagation into first-order logic. Such ambiguities also occur in (informal propositional logic. Take the sentence It is not true that John is tall and Jane is short. It could either mean that the conjunction John is tall and Jane is short is not true, or simply that John is not tall and Jane is short. Such ambiguities impede the study of propositional logic. Therefore we will design a formal language, the language of propositional logic, where no ambiguity can occur. 2
3 Normally, when people say formal, they mean it in a bad way, such as having to dress or act formally to go to dinner. However, in computer science (and in mathematics, formal is a good thing: it means making things so precise that there is no possibility of misunderstanding. 2 The Formal Syntax of Propositional Logic Propositional formulae will be strings (sequences of characters over the alphabet of propositional logic. The alphabet of propositional logic is simply a set of symbols. The symbols are categorised as follows: 1. A = {p, q, r, p, q 1,...} is an infinite set of propositional variables that we fix from the very beginning; 2. {,, } is the set of logical connectives; 3. {(, } is the set of auxiliary symbols; in our case, it consists of two symbols called brakets. The set L = A {,,, (, } is called the alphabet of propositional logic. We call a set an alphabet in computers science when we will use the elements of the set to make words. Here are a few examples of words over L: p, (p, (p q. Words, or strings, are simply sequences of symbols of the alphabet L. Some of these words will be formulae or, equivalently, well-formed formulae (wff. Some authors prefer to use the terminology wff, but we will simply use formula by default in these lecture notes. As an example, the last word above, (p q is a formula of propositional logic, but (p is not. The following definition captures exactly the set of propositional formulae. Definition 2.1 (The Set of Propositional Formulae (PL. The set of formulae of propositional logic, denoted PL from hereon, is the only set of word over L satisfying the following conditions: 1. (Base Case Any propositional variable, seen as a 1-symbol word, is in PL (equivalently, A PL; 2. (Inductive Step i If ϕ PL, then ϕ PL (equivalently, if the word ϕ is a propositional formula, then so is the word starting with the symbol and continuing with the symbols in ϕ; 3. (Inductive Step ii If ϕ 1, ϕ 2 PL, then (ϕ 1 ϕ 2 PL (equivalently, exercise; 4. (Inductive Step iii If ϕ 1, ϕ 2 PL, then (ϕ 1 ϕ 2 PL (equivalently, exercise; 3
4 5. (Minimality Constraint No other word (other than those constructible using the rules above is in PL. Here are examples of elements of PL: p q p q p p 1 (p q (p q (p q ( p q ( p p ((p q r (p (q r Here are examples of words not in PL: pp q q q p p + q The definition of the set PL is an example of an inductive definition. Such definitions are really important in computer science and it is a must to understand them very well. In inductive definitions of set, there are usually some base cases, which say what base elements are part of the set and some inductive cases, which explain how to obtain new elements of the set from old elements. Another important part of an inductive definition is the minimality constraint, which says that nothing other than what is provable by the base case(s and the inductive case(s belongs to the set. It can be shown that the above set PL exists and is unique, but the proof is beyond the scope of this course. 2.1 Showing That a Word Is In PL We can show that a word belongs to PL by explaining how the rules of the inductive definition were applied. Here is an example of a proof that (p q PL: 1. p PL (by the Base Case, because p A; 2. q PL (by the Base Case, as q A; 3. (p q PL (by the Inductive Case ii, with ϕ 1 = p and ϕ 2 = q; 4. (p q PL (by the Inductive Case i, with ϕ = (p q. We can rearrange the above into an equivalent annotated construction tree for the formula (p q: Base Case Base Case p PL q PL (p q PL (p q PL Inductive Case ii Inductive Case i You will see this notation several times in Computer Science and it is worth getting to know it. Each line is called an inference; below each line is the 4
5 conclusion of the inference and above the lines are the hypotheses (0, 1 or more. Besides each lines is the name of the rule that was applied. If we drop all annotation, we obtain the following bare construction tree for the formula: it. p q (p q (p q It is easy to see that a word belongs to PL iff there is a construction tree for 2.2 The Main Connective of a Formula A formula that consists of a single propositional variable, such as p or q, is called an atomic formula. This explains why the set A of propositional variables is called A (A stands for atomic. More complex formulae, such as p or p q, are called molecular (to distinguish them from atomic formulae. Each molecular formula has a main connective, which is given by the last inference in its construction tree. For example, the main connective of the formula (p q is (the disjunction, while the main connective of the fomrula ( p q, is (the negation. We call formulae whose main connective is conjunctions. Similarly, if the main connective of a formula is a, it is a disjunction and if the main connective is, then it is a negation. 2.3 Showing That a Word Is Not in PL It is somewhat more difficult (or rather more verbose to show that a word is not in PL. If the word is not over the right alphabet, such as the three-symbol word p + q, which uses a foreign symbol +, then we can easily dismiss it as PL only contains words over L. However, if the word is over the right alphabet and we want to show that it is not part of PL, we must make use of the minimality condition. Here is an example showing that (p q PL: Let s assume (by contradiction that (p q PL. Then, by the minimality condition, it follows that (p q PL must be explained by one of the rules Base Case, Inductive Case i iii. But we cannot apply the Base Case to show that (p q PL, since (p q A. But we cannot apply the Inductive Case i either, because there is no formula ϕ such that (p q = ϕ (no matter how we would choose ϕ PL, the first symbol of the word on the lhs would be (, while the first symbol of the word on the rhs would be. 5
6 But we cannot apply the Inductive Case ii either, because there are no formulae ϕ 1, ϕ 2 PL such that (p q = (ϕ 1 ϕ 2 (no matter how we would choose ϕ 1, ϕ 2 PL, the word on the lhs would not contain the symbol, while while the the word on the rhs would contain it. By similar reasons, we cannot apply Inductive Case iii either. But this contradicts our assumption and therefore it must be the case that (p q PL. 2.4 Unique Readability The definition of PL has an important property called unique readability: Theorem 2.1 (Unique Readability of Propositional Formulae. For any word ϕ PL, there is a unique construction tree. The property above is also sometimes called unambiguity of the grammar. Proving the Unique Readability Theorem is beyond the scope of the present lecture notes. Instead we will try to understand the importance of the property above by showing how an alternative, fictive, definition of the set PL would be ambiguous: Beginning of Wrong Definition of PL. Imagine that the Inductive Case ii would read:. 3. (Inductive Step ii If ϕ 1, ϕ 2 PL, then ϕ 1 ϕ 2 PL (equivalently, exercise;. The only difference would be that we do not place parantheses around disjunctions. With this alternative, fictive, definition of PL, we have that the word p q PL. However, this word has two different construction trees: p p q q p q p p q p q Such an ambiguity would be very troubling, because we would not know if p q is a disjunction (if we would use the construction tree on the right or a negation (the construction tree on the left. In fact, avoiding such syntactic ambiguities was the main reason why we left natural language and began studying formal logic. End of Wrong Definition of PL. I hope that you can now see that the Unique Readability Theorem is nontrivial (as an exercise to the more mathematically inclined students, I suggest 6
7 that you try to prove it and that it is a very important property of our definition of formulae, since it essential says that any propositional formula can be read unambiguously. 3 Functions Defined Inductively on PL Reminder 3.1. Recall that when X is a set, by 2 X we denote the powerset of X, that is, the set of all subsets of X. For example, if X = {1, 2, 3}, then 2 X = {, {1}, {2}, {3}, {1, 2}, {1, 3}, {2, 3}, {1, 2, 3}}. When X is finite, note that 2 X = 2 X, which partly explains this notation. You might have used the notation P(X instead of 2 X in highschool. Whenever a set is inductively defined, we can define recursive functions that operate on the elements of the set, function which make use of the structure of the elements. Here is an example of a function computing the set of subformulae of a formula: subf : PL 2 PL, defined by: {ϕ}, if ϕ A; ( {ϕ} subf (ϕ, if ϕ = ϕ and ϕ PL; subf ϕ = {ϕ} subf (ϕ 1 subf (ϕ 2, if ϕ = (ϕ 1 ϕ 2 and ϕ 1, ϕ 2 PL; {ϕ} subf (ϕ 1 subf (ϕ 2, if ϕ = (ϕ 1 ϕ 2 and ϕ 1, ϕ 2 PL. ( Here is how we can compute subf ϕ when ϕ = (p q: ( subf (p q ( = { (p q} subf (p q ( = { (p q} {(p q} subf p = { (p q} {(p q} {p} {q} = { (p q, (p q, p, q}. ( subf q Notice that we use two different types of brackets in the computation above. On one hand, we have the brackets that surround the argument to the function subf, and on the other hand we have the usual brackets that are part of the alphabet L. The former brackets are the usual brakets in mathematics, while the later brackets are simply symbols in our alphabet. In order to differentiate between them, we adopt the convention to use bigger brakets for the function call and the usual brackets for the auxiliary symbols in L. Note ( that both are important. ( For example, it would be an error to write subf p q instead of subf (p q, as the word p q PL is not a formula. The function subf is the first in a long line of functions defined recursively on the structure of a formula ϕ PL. These functions are called structurally recursive. 7
8 It is very important to understand how such functions operate in order to understand the remainder of this course. Here are several more examples of such functions. Here is an example of a function computing the abstract syntax tree of a formula: ast : PL Trees, defined by: F, if ϕ A; ( ast ϕ =, if ϕ = ϕ ast (ϕ and ϕ PL; ast (ϕ 1, if ϕ = (ϕ 1 ϕ 2 and ϕ 1, ϕ 2 PL; ast (ϕ 2 ast (ϕ 1, if ϕ = (ϕ 1 ϕ 2 and ϕ 1, ϕ 2 PL. ast (ϕ 2 Here is the computation of the abstract syntax tree of the formula ((p q r. ( ast ((p q r = ( ast (p q ( ast r = ( ast p ( ast q r = p ( ast q r 8
9 = p r q Note that Trees is the set of labeled, rooted trees, considered here intuitively, without a formal definition. Note that abstract syntax trees are very important. In fact, conceptually, a propositional formula is its abstract syntax tree. However, because writing trees is cumbersome, we have resort to the more conventional left-to-right notation. Here are three more examples of functions defined by structural recursion on formulae. The first function, height : PL N, computes the height of the ast o formula: 1, if ϕ A; ( height ϕ = 1 + height (ϕ, if ϕ = ϕ and ϕ PL; ( 1 + max height (ϕ 1, height (ϕ 2, if ϕ = (ϕ 1 ϕ 2 and ϕ 1, ϕ 2 PL; ( 1 + max height (ϕ 1, height (ϕ 2, if ϕ = (ϕ 1 ϕ 2 and ϕ 1, ϕ 2 PL. The next function, size : PL N, computes the size of the ast o formula (i.e. the number of nodes: 1, if ϕ A; ( 1 + size (ϕ, if ϕ = ϕ and ϕ PL; size ϕ = 1 + size (ϕ 1 + size (ϕ 2, if ϕ = (ϕ 1 ϕ 2 and ϕ 1, ϕ 2 PL; 1 + size (ϕ 1 + size (ϕ 2, if ϕ = (ϕ 1 ϕ 2 and ϕ 1, ϕ 2 PL. The final example function, prop : PL 2 A, compute the set of propositional variables occurring in a formula: {ϕ}, if ϕ A; ( prop (ϕ, if ϕ = ϕ and ϕ PL; prop ϕ = prop (ϕ 1 prop (ϕ 2, if ϕ = (ϕ 1 ϕ 2 and ϕ 1, ϕ 2 PL; prop (ϕ 1 prop (ϕ 2, if ϕ = (ϕ 1 ϕ 2 and ϕ 1, ϕ 2 PL. Make sure that you are proficient at understanding, defining and computing with functions such as those given above. 3.1 Proofs by Structural Induction We will sometimes do proofs by structural induction. You are already familiar with proofs by induction on the naturals. 9
10 In order to prove a theorem of the form For all n N, it is true that P (n, the mathematical induction principle postulates that it is sufficient to show that: 1. (Base Case P (0 holds; 2. (Induction Case P (k implies P (k + 1 for all k N. Proofs by structural induction generalize the principle above to any inductively defined set such as PL. For the case of PL, the structural induction principle is that, in order to show a theorem of the form ( For any propositional formula ϕ PL, it is true that P ϕ, it is sufficient to prove that: 1. (Base Case P (ϕ holds for any atomic formula ϕ A (otherwise put, the property P holds of every atomic formula; 2. (Inductive Case i P ( ϕ holds whenever P (ϕ holds; ( 3. (Inductive Case ii P (ϕ 1 ϕ 2 holds whenever P (ϕ 1 and P (ϕ 2 hold; ( 4. (Inductive Case iii P (ϕ 1 ϕ 2 holds whenever P (ϕ 1 and P (ϕ 2 hold; Here is an example of a theorem and its proof by structural induction: Theorem 3.1 (Example of Theorem Provable by ( Structural ( Induction. For any propositional formula ϕ, we have that height ϕ size ϕ. Proof. ( We proceed ( by structural induction (the property P (ϕ is simply that height ϕ size ϕ. It is sufficient to show that: 1. (Base Case height (ϕ size (ϕ (ϕ for any propositional variable ϕ A. But by definition, height = 1 and size (ϕ = 1 when ϕ A. And 1 1, which is what we had to show. 2. (Inductive Case i Assuming that height (ϕ size (ϕ, we show that height ( ϕ size ( ϕ. But by definition, height ( ϕ = 1 + height (ϕ and size ( ϕ = 1 + size (ϕ. And 1 + height (ϕ 1 + size (ϕ (what we had to show, as we already know height (ϕ size (ϕ. 10
11 3. (Inductive Case ii Assuming that height (ϕ 1 ( ( (ϕ 2 size (ϕ 1 and height (ϕ 2 size, we show height (ϕ 1 ϕ 2 size (ϕ 1 ϕ 2. ( ( But, by definition, height (ϕ 1 ϕ 2 = 1+max height (ϕ 1, height (ϕ 2 and, as ( max(a, b a + b (for any naturals a, b N, we have that height (ϕ 1 ϕ height (ϕ 1 + height (ϕ 2. But height (ϕ i ( size (ϕ i (1 i 2 by our hypothesis, and therefore height (ϕ 1 ( ϕ size (ϕ 1 + size (ϕ 2. But, by definition, size (ϕ 1 ϕ 2 = ( ( 1+size (ϕ 1 +size (ϕ 2, and therefore height (ϕ 1 ϕ 2 size (ϕ 1 ϕ 2, what we had to prove. 4. (Inductive Case iii Similar to Inductive Case ii. 11
Proseminar on Semantic Theory Fall 2013 Ling 720 Propositional Logic: Syntax and Natural Deduction 1
Propositional Logic: Syntax and Natural Deduction 1 The Plot That Will Unfold I want to provide some key historical and intellectual context to the model theoretic approach to natural language semantics,
More informationLogic for Computer Science - Week 5 Natural Deduction
Logic for Computer Science - Week 5 Natural Deduction Ștefan Ciobâcă November 30, 2017 1 An Alternative View of Implication and Double Implication So far, we have understood as a shorthand of However,
More informationINTRODUCTION TO LOGIC. Propositional Logic. Examples of syntactic claims
Introduction INTRODUCTION TO LOGIC 2 Syntax and Semantics of Propositional Logic Volker Halbach In what follows I look at some formal languages that are much simpler than English and define validity of
More informationIntroduction to Metalogic
Philosophy 135 Spring 2008 Tony Martin Introduction to Metalogic 1 The semantics of sentential logic. The language L of sentential logic. Symbols of L: Remarks: (i) sentence letters p 0, p 1, p 2,... (ii)
More informationcis32-ai lecture # 18 mon-3-apr-2006
cis32-ai lecture # 18 mon-3-apr-2006 today s topics: propositional logic cis32-spring2006-sklar-lec18 1 Introduction Weak (search-based) problem-solving does not scale to real problems. To succeed, problem
More informationAI Principles, Semester 2, Week 2, Lecture 5 Propositional Logic and Predicate Logic
AI Principles, Semester 2, Week 2, Lecture 5 Propositional Logic and Predicate Logic Propositional logic Logical connectives Rules for wffs Truth tables for the connectives Using Truth Tables to evaluate
More informationPropositional Logic: Part II - Syntax & Proofs 0-0
Propositional Logic: Part II - Syntax & Proofs 0-0 Outline Syntax of Propositional Formulas Motivating Proofs Syntactic Entailment and Proofs Proof Rules for Natural Deduction Axioms, theories and theorems
More informationLogic. Propositional Logic: Syntax
Logic Propositional Logic: Syntax Logic is a tool for formalizing reasoning. There are lots of different logics: probabilistic logic: for reasoning about probability temporal logic: for reasoning about
More informationLecture 7. Logic. Section1: Statement Logic.
Ling 726: Mathematical Linguistics, Logic, Section : Statement Logic V. Borschev and B. Partee, October 5, 26 p. Lecture 7. Logic. Section: Statement Logic.. Statement Logic..... Goals..... Syntax of Statement
More informationStructural Induction
Structural Induction In this lecture we ll extend the applicability of induction to many universes, ones where we can define certain kinds of objects by induction, in addition to proving their properties
More informationExamples: P: it is not the case that P. P Q: P or Q P Q: P implies Q (if P then Q) Typical formula:
Logic: The Big Picture Logic is a tool for formalizing reasoning. There are lots of different logics: probabilistic logic: for reasoning about probability temporal logic: for reasoning about time (and
More informationPropositional Logic: Syntax
Logic Logic is a tool for formalizing reasoning. There are lots of different logics: probabilistic logic: for reasoning about probability temporal logic: for reasoning about time (and programs) epistemic
More information3. Only sequences that were formed by using finitely many applications of rules 1 and 2, are propositional formulas.
1 Chapter 1 Propositional Logic Mathematical logic studies correct thinking, correct deductions of statements from other statements. Let us make it more precise. A fundamental property of a statement is
More informationA Little Deductive Logic
A Little Deductive Logic In propositional or sentential deductive logic, we begin by specifying that we will use capital letters (like A, B, C, D, and so on) to stand in for sentences, and we assume that
More informationMathematical Preliminaries. Sipser pages 1-28
Mathematical Preliminaries Sipser pages 1-28 Mathematical Preliminaries This course is about the fundamental capabilities and limitations of computers. It has 3 parts 1. Automata Models of computation
More informationLogic for Computer Science - Week 4 Natural Deduction
Logic for Computer Science - Week 4 Natural Deduction 1 Introduction In the previous lecture we have discussed some important notions about the semantics of propositional logic. 1. the truth value of a
More informationLecture 4: Proposition, Connectives and Truth Tables
Discrete Mathematics (II) Spring 2017 Lecture 4: Proposition, Connectives and Truth Tables Lecturer: Yi Li 1 Overview In last lecture, we give a brief introduction to mathematical logic and then redefine
More informationMathematics 114L Spring 2018 D.A. Martin. Mathematical Logic
Mathematics 114L Spring 2018 D.A. Martin Mathematical Logic 1 First-Order Languages. Symbols. All first-order languages we consider will have the following symbols: (i) variables v 1, v 2, v 3,... ; (ii)
More informationPropositional Logic Not Enough
Section 1.4 Propositional Logic Not Enough If we have: All men are mortal. Socrates is a man. Does it follow that Socrates is mortal? Can t be represented in propositional logic. Need a language that talks
More informationPropositional Logic and Semantics
Propositional Logic and Semantics English is naturally ambiguous. For example, consider the following employee (non)recommendations and their ambiguity in the English language: I can assure you that no
More informationThe Importance of Being Formal. Martin Henz. February 5, Propositional Logic
The Importance of Being Formal Martin Henz February 5, 2014 Propositional Logic 1 Motivation In traditional logic, terms represent sets, and therefore, propositions are limited to stating facts on sets
More informationSyllogistic Logic and its Extensions
1/31 Syllogistic Logic and its Extensions Larry Moss, Indiana University NASSLLI 2014 2/31 Logic and Language: Traditional Syllogisms All men are mortal. Socrates is a man. Socrates is mortal. Some men
More informationLogical Structures in Natural Language: Propositional Logic II (Truth Tables and Reasoning
Logical Structures in Natural Language: Propositional Logic II (Truth Tables and Reasoning Raffaella Bernardi Università degli Studi di Trento e-mail: bernardi@disi.unitn.it Contents 1 What we have said
More informationA Little Deductive Logic
A Little Deductive Logic In propositional or sentential deductive logic, we begin by specifying that we will use capital letters (like A, B, C, D, and so on) to stand in for sentences, and we assume that
More informationTHE LOGIC OF COMPOUND STATEMENTS
CHAPTER 2 THE LOGIC OF COMPOUND STATEMENTS Copyright Cengage Learning. All rights reserved. SECTION 2.1 Logical Form and Logical Equivalence Copyright Cengage Learning. All rights reserved. Logical Form
More informationKRIPKE S THEORY OF TRUTH 1. INTRODUCTION
KRIPKE S THEORY OF TRUTH RICHARD G HECK, JR 1. INTRODUCTION The purpose of this note is to give a simple, easily accessible proof of the existence of the minimal fixed point, and of various maximal fixed
More informationTecniche di Verifica. Introduction to Propositional Logic
Tecniche di Verifica Introduction to Propositional Logic 1 Logic A formal logic is defined by its syntax and semantics. Syntax An alphabet is a set of symbols. A finite sequence of these symbols is called
More informationNatural Deduction for Propositional Logic
Natural Deduction for Propositional Logic Bow-Yaw Wang Institute of Information Science Academia Sinica, Taiwan September 10, 2018 Bow-Yaw Wang (Academia Sinica) Natural Deduction for Propositional Logic
More informationLogic. Propositional Logic: Syntax. Wffs
Logic Propositional Logic: Syntax Logic is a tool for formalizing reasoning. There are lots of different logics: probabilistic logic: for reasoning about probability temporal logic: for reasoning about
More informationLogic. Readings: Coppock and Champollion textbook draft, Ch
Logic Readings: Coppock and Champollion textbook draft, Ch. 3.1 3 1. Propositional logic Propositional logic (a.k.a propositional calculus) is concerned with complex propositions built from simple propositions
More informationLecture Notes on Inductive Definitions
Lecture Notes on Inductive Definitions 15-312: Foundations of Programming Languages Frank Pfenning Lecture 2 August 28, 2003 These supplementary notes review the notion of an inductive definition and give
More informationEquivalent Forms of the Axiom of Infinity
Equivalent Forms of the Axiom of Infinity Axiom of Infinity 1. There is a set that contains each finite ordinal as an element. The Axiom of Infinity is the axiom of Set Theory that explicitly asserts that
More informationIntermediate Logic. Natural Deduction for TFL
Intermediate Logic Lecture Two Natural Deduction for TFL Rob Trueman rob.trueman@york.ac.uk University of York The Trouble with Truth Tables Natural Deduction for TFL The Trouble with Truth Tables The
More informationProseminar on Semantic Theory Fall 2013 Ling 720 First Order (Predicate) Logic: Syntax and Natural Deduction 1
First Order (Predicate) Logic: Syntax and Natural Deduction 1 A Reminder of Our Plot I wish to provide some historical and intellectual context to the formal tools that logicians developed to study the
More informationPL: Truth Trees. Handout Truth Trees: The Setup
Handout 4 PL: Truth Trees Truth tables provide a mechanical method for determining whether a proposition, set of propositions, or argument has a particular logical property. For example, we can show that
More informationIntroducing Proof 1. hsn.uk.net. Contents
Contents 1 1 Introduction 1 What is proof? 1 Statements, Definitions and Euler Diagrams 1 Statements 1 Definitions Our first proof Euler diagrams 4 3 Logical Connectives 5 Negation 6 Conjunction 7 Disjunction
More informationCOMP219: Artificial Intelligence. Lecture 19: Logic for KR
COMP219: Artificial Intelligence Lecture 19: Logic for KR 1 Overview Last time Expert Systems and Ontologies Today Logic as a knowledge representation scheme Propositional Logic Syntax Semantics Proof
More informationFirst Order Logic Semantics (3A) Young W. Lim 8/9/17
First Order Logic (3A) Young W. Lim Copyright (c) 2016-2017 Young W. Lim. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version
More informationPropositional logic (revision) & semantic entailment. p. 1/34
Propositional logic (revision) & semantic entailment p. 1/34 Reading The background reading for propositional logic is Chapter 1 of Huth/Ryan. (This will cover approximately the first three lectures.)
More informationThe semantics of propositional logic
The semantics of propositional logic Readings: Sections 1.3 and 1.4 of Huth and Ryan. In this module, we will nail down the formal definition of a logical formula, and describe the semantics of propositional
More informationPropositional logic. First order logic. Alexander Clark. Autumn 2014
Propositional logic First order logic Alexander Clark Autumn 2014 Formal Logic Logical arguments are valid because of their form. Formal languages are devised to express exactly that relevant form and
More informationFor all For every For each For any There exists at least one There exists There is Some
Section 1.3 Predicates and Quantifiers Assume universe of discourse is all the people who are participating in this course. Also let us assume that we know each person in the course. Consider the following
More informationLearning Goals of CS245 Logic and Computation
Learning Goals of CS245 Logic and Computation Alice Gao April 27, 2018 Contents 1 Propositional Logic 2 2 Predicate Logic 4 3 Program Verification 6 4 Undecidability 7 1 1 Propositional Logic Introduction
More information22c:145 Artificial Intelligence
22c:145 Artificial Intelligence Fall 2005 Propositional Logic Cesare Tinelli The University of Iowa Copyright 2001-05 Cesare Tinelli and Hantao Zhang. a a These notes are copyrighted material and may not
More informationLogical Structures in Natural Language: First order Logic (FoL)
Logical Structures in Natural Language: First order Logic (FoL) Raffaella Bernardi Università degli Studi di Trento e-mail: bernardi@disi.unitn.it Contents 1 How far can we go with PL?................................
More informationFirst Order Logic Semantics (3A) Young W. Lim 9/17/17
First Order Logic (3A) Young W. Lim Copyright (c) 2016-2017 Young W. Lim. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version
More informationDeduction by Daniel Bonevac. Chapter 3 Truth Trees
Deduction by Daniel Bonevac Chapter 3 Truth Trees Truth trees Truth trees provide an alternate decision procedure for assessing validity, logical equivalence, satisfiability and other logical properties
More informationDeductive Systems. Lecture - 3
Deductive Systems Lecture - 3 Axiomatic System Axiomatic System (AS) for PL AS is based on the set of only three axioms and one rule of deduction. It is minimal in structure but as powerful as the truth
More informationLIN1032 Formal Foundations for Linguistics
LIN1032 Formal Foundations for Lecture 5 Albert Gatt In this lecture We conclude our discussion of the logical connectives We begin our foray into predicate logic much more expressive than propositional
More informationCOMP219: Artificial Intelligence. Lecture 19: Logic for KR
COMP219: Artificial Intelligence Lecture 19: Logic for KR 1 Overview Last time Expert Systems and Ontologies Today Logic as a knowledge representation scheme Propositional Logic Syntax Semantics Proof
More informationSupplementary Notes on Inductive Definitions
Supplementary Notes on Inductive Definitions 15-312: Foundations of Programming Languages Frank Pfenning Lecture 2 August 29, 2002 These supplementary notes review the notion of an inductive definition
More informationIntroduction to Metalogic 1
Philosophy 135 Spring 2012 Tony Martin Introduction to Metalogic 1 1 The semantics of sentential logic. The language L of sentential logic. Symbols of L: (i) sentence letters p 0, p 1, p 2,... (ii) connectives,
More informationLogic: The Big Picture
Logic: The Big Picture A typical logic is described in terms of syntax: what are the legitimate formulas semantics: under what circumstances is a formula true proof theory/ axiomatization: rules for proving
More informationcse541 LOGIC FOR COMPUTER SCIENCE
cse541 LOGIC FOR COMPUTER SCIENCE Professor Anita Wasilewska Spring 2015 LECTURE 2 Chapter 2 Introduction to Classical Propositional Logic PART 1: Classical Propositional Model Assumptions PART 2: Syntax
More informationPropositional Logic: Models and Proofs
Propositional Logic: Models and Proofs C. R. Ramakrishnan CSE 505 1 Syntax 2 Model Theory 3 Proof Theory and Resolution Compiled at 11:51 on 2016/11/02 Computing with Logic Propositional Logic CSE 505
More informationIntroduction to Sets and Logic (MATH 1190)
Introduction to Sets Logic () Instructor: Email: shenlili@yorku.ca Department of Mathematics Statistics York University Sept 18, 2014 Outline 1 2 Tautologies Definition A tautology is a compound proposition
More informationComp487/587 - Boolean Formulas
Comp487/587 - Boolean Formulas 1 Logic and SAT 1.1 What is a Boolean Formula Logic is a way through which we can analyze and reason about simple or complicated events. In particular, we are interested
More informationPredicate Logic: Sematics Part 1
Predicate Logic: Sematics Part 1 CS402, Spring 2018 Shin Yoo Predicate Calculus Propositional logic is also called sentential logic, i.e. a logical system that deals with whole sentences connected with
More informationCITS2211 Discrete Structures. Propositional Logic
CITS2211 Discrete Structures Propositional Logic Unit coordinator: Rachel Cardell-Oliver July 31, 2017 Highlights This lecture will address the following questions: 1 What is a proposition? 2 How are propositions
More informationCS 2800: Logic and Computation Fall 2010 (Lecture 13)
CS 2800: Logic and Computation Fall 2010 (Lecture 13) 13 October 2010 1 An Introduction to First-order Logic In Propositional(Boolean) Logic, we used large portions of mathematical language, namely those
More informationMathematical Logic Prof. Arindama Singh Department of Mathematics Indian Institute of Technology, Madras. Lecture - 15 Propositional Calculus (PC)
Mathematical Logic Prof. Arindama Singh Department of Mathematics Indian Institute of Technology, Madras Lecture - 15 Propositional Calculus (PC) So, now if you look back, you can see that there are three
More informationCHAPTER 2 INTRODUCTION TO CLASSICAL PROPOSITIONAL LOGIC
CHAPTER 2 INTRODUCTION TO CLASSICAL PROPOSITIONAL LOGIC 1 Motivation and History The origins of the classical propositional logic, classical propositional calculus, as it was, and still often is called,
More informationIt rains now. (true) The followings are not propositions.
Chapter 8 Fuzzy Logic Formal language is a language in which the syntax is precisely given and thus is different from informal language like English and French. The study of the formal languages is the
More informationLecture 10: Predicate Logic and Its Language
Discrete Mathematics (II) Spring 2017 Lecture 10: Predicate Logic and Its Language Lecturer: Yi Li 1 Predicates and Quantifiers In this action, we show you why a richer language should be introduced than
More informationPřednáška 12. Důkazové kalkuly Kalkul Hilbertova typu. 11/29/2006 Hilbertův kalkul 1
Přednáška 12 Důkazové kalkuly Kalkul Hilbertova typu 11/29/2006 Hilbertův kalkul 1 Formal systems, Proof calculi A proof calculus (of a theory) is given by: A. a language B. a set of axioms C. a set of
More informationUNIT-I: Propositional Logic
1. Introduction to Logic: UNIT-I: Propositional Logic Logic: logic comprises a (formal) language for making statements about objects and reasoning about properties of these objects. Statements in a logical
More information3/29/2017. Logic. Propositions and logical operations. Main concepts: propositions truth values propositional variables logical operations
Logic Propositions and logical operations Main concepts: propositions truth values propositional variables logical operations 1 Propositions and logical operations A proposition is the most basic element
More informationLogic as a Tool Chapter 1: Understanding Propositional Logic 1.1 Propositions and logical connectives. Truth tables and tautologies
Logic as a Tool Chapter 1: Understanding Propositional Logic 1.1 Propositions and logical connectives. Truth tables and tautologies Valentin Stockholm University September 2016 Propositions Proposition:
More informationCONTENTS. Appendix C: Gothic Alphabet 109
Contents 1 Sentential Logic 1 1.1 Introduction............................ 1 1.2 Sentences of Sentential Logic................... 2 1.3 Truth Assignments........................ 7 1.4 Logical Consequence.......................
More information3 Propositional Logic
3 Propositional Logic 3.1 Syntax 3.2 Semantics 3.3 Equivalence and Normal Forms 3.4 Proof Procedures 3.5 Properties Propositional Logic (25th October 2007) 1 3.1 Syntax Definition 3.0 An alphabet Σ consists
More informationAutomata theory. An algorithmic approach. Lecture Notes. Javier Esparza
Automata theory An algorithmic approach Lecture Notes Javier Esparza July 2 22 2 Chapter 9 Automata and Logic A regular expression can be seen as a set of instructions ( a recipe ) for generating the words
More informationSupplementary Logic Notes CSE 321 Winter 2009
1 Propositional Logic Supplementary Logic Notes CSE 321 Winter 2009 1.1 More efficient truth table methods The method of using truth tables to prove facts about propositional formulas can be a very tedious
More information1 FUNDAMENTALS OF LOGIC NO.10 HERBRAND THEOREM Tatsuya Hagino hagino@sfc.keio.ac.jp lecture URL https://vu5.sfc.keio.ac.jp/slide/ 2 So Far Propositional Logic Logical connectives (,,, ) Truth table Tautology
More informationFirst Order Logic (FOL) 1 znj/dm2017
First Order Logic (FOL) 1 http://lcs.ios.ac.cn/ znj/dm2017 Naijun Zhan March 19, 2017 1 Special thanks to Profs Hanpin Wang (PKU) and Lijun Zhang (ISCAS) for their courtesy of the slides on this course.
More informationLecture Notes on Inductive Definitions
Lecture Notes on Inductive Definitions 15-312: Foundations of Programming Languages Frank Pfenning Lecture 2 September 2, 2004 These supplementary notes review the notion of an inductive definition and
More informationMarie Duží
Marie Duží marie.duzi@vsb.cz 1 Formal systems, Proof calculi A proof calculus (of a theory) is given by: 1. a language 2. a set of axioms 3. a set of deduction rules ad 1. The definition of a language
More informationSymbolic Logic 3. For an inference to be deductively valid it is impossible for the conclusion to be false if the premises are true.
Symbolic Logic 3 Testing deductive validity with truth tables For an inference to be deductively valid it is impossible for the conclusion to be false if the premises are true. So, given that truth tables
More informationProofs: A General How To II. Rules of Inference. Rules of Inference Modus Ponens. Rules of Inference Addition. Rules of Inference Conjunction
Introduction I Proofs Computer Science & Engineering 235 Discrete Mathematics Christopher M. Bourke cbourke@cse.unl.edu A proof is a proof. What kind of a proof? It s a proof. A proof is a proof. And when
More informationProof Techniques (Review of Math 271)
Chapter 2 Proof Techniques (Review of Math 271) 2.1 Overview This chapter reviews proof techniques that were probably introduced in Math 271 and that may also have been used in a different way in Phil
More informationFirst-Order Logic. Chapter Overview Syntax
Chapter 10 First-Order Logic 10.1 Overview First-Order Logic is the calculus one usually has in mind when using the word logic. It is expressive enough for all of mathematics, except for those concepts
More informationLogic Background (1A) Young W. Lim 12/14/15
Young W. Lim 12/14/15 Copyright (c) 2014-2015 Young W. Lim. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any
More information1 Completeness Theorem for First Order Logic
1 Completeness Theorem for First Order Logic There are many proofs of the Completeness Theorem for First Order Logic. We follow here a version of Henkin s proof, as presented in the Handbook of Mathematical
More informationThe statement calculus and logic
Chapter 2 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 You will have encountered several languages
More informationPropositional Logic George Belic
1 Symbols and Translation (Ch 6.1) Our aim for the rest of the course is to study valid (deductive) arguments in symbolic systems. In this section, (Ch. 6-7) we look at the symbolic system of propositional
More informationWhat is logic, the topic of this course? There are at least two answers to that question.
Applied Logic Lecture 1 CS 486 Spring 2005 Tuesday, January 25, 2005 What is Logic? What is logic, the topic of this course? There are at least two answers to that question. General logic: critical examination
More informationPropositional Logic: Logical Agents (Part I)
Propositional Logic: Logical Agents (Part I) This lecture topic: Propositional Logic (two lectures) Chapter 7.1-7.4 (this lecture, Part I) Chapter 7.5 (next lecture, Part II) Next lecture topic: First-order
More informationFormal Logic. Critical Thinking
ormal Logic Critical hinking Recap: ormal Logic If I win the lottery, then I am poor. I win the lottery. Hence, I am poor. his argument has the following abstract structure or form: If P then Q. P. Hence,
More informationClassical Propositional Logic
The Language of A Henkin-style Proof for Natural Deduction January 16, 2013 The Language of A Henkin-style Proof for Natural Deduction Logic Logic is the science of inference. Given a body of information,
More informationTHE LOGIC OF COMPOUND STATEMENTS
THE LOGIC OF COMPOUND STATEMENTS All dogs have four legs. All tables have four legs. Therefore, all dogs are tables LOGIC Logic is a science of the necessary laws of thought, without which no employment
More informationThe predicate calculus is complete
The predicate calculus is complete Hans Halvorson The first thing we need to do is to precisify the inference rules UI and EE. To this end, we will use A(c) to denote a sentence containing the name c,
More informationTopics in Logic and Proofs
Chapter 2 Topics in Logic and Proofs Some mathematical statements carry a logical value of being true or false, while some do not. For example, the statement 4 + 5 = 9 is true, whereas the statement 2
More information10 Propositional logic
10 The study of how the truth value of compound statements depends on those of simple statements. A reminder of truth-tables. and A B A B F T F F F F or A B A B T F T F T T F F F not A A T F F T material
More informationGödel s Incompleteness Theorems
Seminar Report Gödel s Incompleteness Theorems Ahmet Aspir Mark Nardi 28.02.2018 Supervisor: Dr. Georg Moser Abstract Gödel s incompleteness theorems are very fundamental for mathematics and computational
More informationAll psychiatrists are doctors All doctors are college graduates All psychiatrists are college graduates
Predicate Logic In what we ve discussed thus far, we haven t addressed other kinds of valid inferences: those involving quantification and predication. For example: All philosophers are wise Socrates is
More informationESSLLI 2007 COURSE READER. ESSLLI is the Annual Summer School of FoLLI, The Association for Logic, Language and Information
ESSLLI 2007 19th European Summer School in Logic, Language and Information August 6-17, 2007 http://www.cs.tcd.ie/esslli2007 Trinity College Dublin Ireland COURSE READER ESSLLI is the Annual Summer School
More informationLing 130 Notes: Syntax and Semantics of Propositional Logic
Ling 130 Notes: Syntax and Semantics of Propositional Logic Sophia A. Malamud January 21, 2011 1 Preliminaries. Goals: Motivate propositional logic syntax and inferencing. Feel comfortable manipulating
More informationAutomated Reasoning Lecture 2: Propositional Logic and Natural Deduction
Automated Reasoning Lecture 2: Propositional Logic and Natural Deduction Jacques Fleuriot jdf@inf.ed.ac.uk Logic Puzzles 1. Tomorrow will be sunny or rainy. Tomorrow will not be sunny. What will the weather
More informationINDUCTIVE DEFINITION
1 INDUCTIVE DEFINITION OUTLINE Judgements Inference Rules Inductive Definition Derivation Rule Induction 2 META-VARIABLES A symbol in a meta-language that is used to describe some element in an object
More informationGlossary of Logical Terms
Math 304 Spring 2007 Glossary of Logical Terms The following glossary briefly describes some of the major technical logical terms used in this course. The glossary should be read through at the beginning
More informationProposition logic and argument. CISC2100, Spring 2017 X.Zhang
Proposition logic and argument CISC2100, Spring 2017 X.Zhang 1 Where are my glasses? I know the following statements are true. 1. If I was reading the newspaper in the kitchen, then my glasses are on the
More information