Chapter 4: Classical Propositional Semantics

Similar documents
CHAPTER 4 CLASSICAL PROPOSITIONAL SEMANTICS

Chapter 11: Automated Proof Systems (1)

Chapter 11: Automated Proof Systems

CHAPTER 10. Gentzen Style Proof Systems for Classical Logic

Tecniche di Verifica. Introduction to Propositional Logic

Compound Propositions

Section 1.2 Propositional Equivalences. A tautology is a proposition which is always true. A contradiction is a proposition which is always false.

Chapter 2: Introduction to Propositional Logic

Lecture 2. Logic Compound Statements Conditional Statements Valid & Invalid Arguments Digital Logic Circuits. Reading (Epp s textbook)

CSC Discrete Math I, Spring Propositional Logic

Propositional Language - Semantics

Example. Logic. Logical Statements. Outline of logic topics. Logical Connectives. Logical Connectives

Logic: Propositional Logic (Part I)

2.2: Logical Equivalence: The Laws of Logic

Knowledge base (KB) = set of sentences in a formal language Declarative approach to building an agent (or other system):

CSE 20: Discrete Mathematics

Logic as a Tool Chapter 1: Understanding Propositional Logic 1.1 Propositions and logical connectives. Truth tables and tautologies

Artificial Intelligence

2. The Logic of Compound Statements Summary. Aaron Tan August 2017

cse541 LOGIC FOR COMPUTER SCIENCE

Propositional Resolution Introduction

Propositional Resolution Part 1. Short Review Professor Anita Wasilewska CSE 352 Artificial Intelligence

Applied Logic. Lecture 1 - Propositional logic. Marcin Szczuka. Institute of Informatics, The University of Warsaw

Natural Deduction. Formal Methods in Verification of Computer Systems Jeremy Johnson

Propositional Logic Language

Section 1.1 Propositional Logic. proposition : true = T (or 1) or false = F (or 0) (binary logic) the moon is made of green cheese

INTRODUCTION TO LOGIC. Propositional Logic. Examples of syntactic claims

COMP219: Artificial Intelligence. Lecture 20: Propositional Reasoning

Propositional Logic: Models and Proofs

Discrete Mathematics and Its Applications

Description Logics. Foundations of Propositional Logic. franconi. Enrico Franconi

Propositional Logic Basics Propositional Equivalences Normal forms Boolean functions and digital circuits. Propositional Logic.

Learning Goals of CS245 Logic and Computation

Propositional logic (revision) & semantic entailment. p. 1/34

A brief introduction to Logic. (slides from

Logical Structures in Natural Language: Propositional Logic II (Truth Tables and Reasoning

EXERCISE 10 SOLUTIONS

Truth-Functional Logic

The Calculus of Computation: Decision Procedures with Applications to Verification. Part I: FOUNDATIONS. by Aaron Bradley Zohar Manna

15414/614 Optional Lecture 1: Propositional Logic

Syntax of propositional logic. Syntax tree of a formula. Semantics of propositional logic (I) Subformulas

Introduction to Artificial Intelligence Propositional Logic & SAT Solving. UIUC CS 440 / ECE 448 Professor: Eyal Amir Spring Semester 2010

Introduction. Applications of discrete mathematics:

02 Propositional Logic

We last time we began introducing equivalency laws.

Natural Deduction for Propositional Logic

PROPOSITIONAL LOGIC. VL Logik: WS 2018/19

PHIL12A Section answers, 16 February 2011

Language of Propositional Logic

Propositional Languages

CHAPTER 11. Introduction to Intuitionistic Logic

Announcements. CS243: Discrete Structures. Propositional Logic II. Review. Operator Precedence. Operator Precedence, cont. Operator Precedence Example

Discrete Structures & Algorithms. Propositional Logic EECE 320 // UBC

Announcements. CS311H: Discrete Mathematics. Propositional Logic II. Inverse of an Implication. Converse of a Implication

Overview, cont. Overview, cont. Logistics. Optional Reference #1. Optional Reference #2. Workload and Grading

Section 1.2: Propositional Logic

ECE473 Lecture 15: Propositional Logic

Overview. I Review of natural deduction. I Soundness and completeness. I Semantics of propositional formulas. I Soundness proof. I Completeness proof.

Comp487/587 - Boolean Formulas

Propositional Logic. Jason Filippou UMCP. ason Filippou UMCP) Propositional Logic / 38

Logic and Truth Tables

DISCRETE STRUCTURES WEEK5 LECTURE1

COMP219: Artificial Intelligence. Lecture 19: Logic for KR

A statement is a sentence that is definitely either true or false but not both.

The Importance of Being Formal. Martin Henz. February 5, Propositional Logic

First-Degree Entailment

PROPOSITIONAL CALCULUS

Propositional Logic: Equivalence

Advanced Topics in LP and FP

PL: Truth Trees. Handout Truth Trees: The Setup

Proofs. Joe Patten August 10, 2018

1.1 Language and Logic

UNIT-I: Propositional Logic

Introduction to first-order logic:

Propositional Logics and their Algebraic Equivalents

CHAPTER 2 INTRODUCTION TO CLASSICAL PROPOSITIONAL LOGIC

INF3170 Logikk Spring Homework #8 For Friday, March 18

B1.1 Motivation. Theory of Computer Science. Theory of Computer Science. B1.1 Motivation. B1.2 Syntax. B1.3 Semantics

Philosophy 220. Truth-Functional Equivalence and Consistency

Agenda. Artificial Intelligence. Reasoning in the Wumpus World. The Wumpus World

a. ~p : if p is T, then ~p is F, and vice versa

Logic. Definition [1] A logic is a formal language that comes with rules for deducing the truth of one proposition from the truth of another.

Description Logics. Deduction in Propositional Logic. franconi. Enrico Franconi

Tautologies, Contradictions, and Contingencies

Sample Problems for all sections of CMSC250, Midterm 1 Fall 2014

n logical not (negation) n logical or (disjunction) n logical and (conjunction) n logical exclusive or n logical implication (conditional)

Propositional Equivalence

Propositional natural deduction

Logic: Propositional Logic Truth Tables

1.1 Language and Logic

Artificial Intelligence. Propositional logic

Logic Overview, I. and T T T T F F F T F F F F

What is Logic? Introduction to Logic. Simple Statements. Which one is statement?

Propositional logic ( ): Review from Mat 1348

Computation and Logic Definitions

Formal Logic Lecture 11

COMP219: Artificial Intelligence. Lecture 19: Logic for KR

1.3 Propositional Equivalences

Propositional logic. First order logic. Alexander Clark. Autumn 2014

Propositional Logic: Part II - Syntax & Proofs 0-0

Transcription:

Chapter 4: Classical Propositional Semantics Language : L {,,, }. Classical Semantics assumptions: TWO VALUES: there are only two logical values: truth (T) and false (F), and EXTENSIONALITY: the logical value of a formula depends only on a main connective and logical values of its sub-formulas. We define formally a classical semantics for L in terms of two factors: classical truth tables and a truth assignment. 1

We summarize now here the chapter 2 tables for L {,,, } in one simplified table as follows. A B A (A B) (A B) (A B) T T F T T T T F F F T F F T T F T T F F T F F T Observe that The first row of the above table reads: For any formulas A, B, if the logical value of A = T and B = T, then logical values of A = T, (A B) = T, (A B) = T and (A B) = T. We read and write the other rows in a similar manner. 2

Our table indicates that the logical value of of propositional connectives depends only on the logical values of its factors; i.e. it is independent of the formulas A, B. EXTENSIONAL CONNECTIVES : The logical value of a given connective depend only of the logical values of its factors. We write now the last table as the following equations. T = F, F = T ; (T T ) = T, (T F ) = F, (F T ) = F, (F F ) = F ; (T T ) = T, (T F ) = T, (F T ) = T, (F F ) = F ; (T T ) = T, (T F ) = F, (F T ) = T, (F F ) = T. 3

Observe now that the above equations describe a set of unary and binary operations (functions) defined on a set {T, F } and a set {T, F } {T, F }, respectively. Negation is a function: : {T, F } {T, F }, such that T = F, F = T. Conjunction is a function: : {T, F } {T, F } {T, F }, such that (T T ) = T, (T F ) = F, (F T ) = F, (F F ) = F. 4

Dissjunction is a function: : {T, F } {T, F } {T, F }, such that (T T ) = T, (T F ) = T, (F T ) = T, (F F ) = F. Implication is a function: : {T, F } {T, F } {T, F }, such that (T T ) = T, (T F ) = F, (F T ) = T, (F F ) = T. Observe that if we have have a language L {,,,, } containing also the equivalence connective we define : {T, F } {T, F } {T, F }, as a function such that (T T ) = T, (T F ) = F, (F T ) = F, (T T ) = T. 5

We write these definitions of connectives as the following tables, usually called the classical truth tables. Negation : T F F T Conjunction : T F T T F F F F Disjunction : T F T T T F T F Implication : T F T T F F T T Equivalence : T F T T F F F T 6

A truth assignment is any function v : V AR {T, F }. Observe that the truth assignment is defined only on variables (atomic formulas). We define its extension v to the set F of all formulas of L as follows. is such that v : F {T, F } (i) for any a V AR, v (a) = v(a); 7

(ii) and for any A, B F, v ( A) = v (A); v (A B) = v (A) v (B); v (A B) = v (A) v (B); v (A B) = v (A) v (B), v (A B) = v (A) v (B), where the symbols on the left-hand side of the equations represent connectives in their natural language meaning and the symbols on the right-hand side represent connectives in their logical meaning given by the classical truth tables. 8

Example Consider a formula ((a b) a)) a truth assignment v such that v(a) = T, v(b) = F. We calculate the logical value of the formula A as follows: v (A) = v ((a b) a)) = v (a b) v ( a) = (v(a) v(b)) v(a) = (T F ) T = F F = F. Observe that we did not need (and usually we don t) to specify the v(x) of any x V AR {a, b}, as these values do not influence the computation of the logical value v (A). 9

SATISFACTION relation Definition: Let v : V AR {T, F }. We say that v satisfies a formula A F iff v (A) = T Notation: v = A. Definition: We sat that v does not satisfy a formula v (A) T. A F iff Notation: v = A. REMARK In our classical semantics we have that v = A iff v (A) = F and we say that v falsifies the formula A. 10

OBSERVE v (A) T is is equivalent to the fact that v (A) = F ONLY in 2-valued logic! This is why we adopt the following Definition: For any v, v does not satisfy a formula v (A) T A F iff 11

Example A = ((a b) a)) v : V AR {T, F } such that v(a) = T, v(b) = F. Calculation of v (A) using the short hand notation: (T F ) T = F F = F. v = ((a b) a)). Observe that we did not need (and usually we don t) to specify the v(x) of any x V AR {a, b}, as these values do not influence the computation of the logical value v (A). 12

Example A = ((a b) c) v : V AR {T, F } such that v(a) = T, v(b) = F, v(c) = T. Calculation in a short hand notation: (T F ) T = (T T ) F = T F = T. v = ((a b) c). 13

Formula: A = ((a b) c). Consider now v 1 : V AR {T, F } such that v 1 (a) = T, v 1 (b) = F, v 1 (c) = T, and v 1 (x) = F, for all x V AR {a, b, c}, Observe: v(a) = v 1 (a), v(b) = v 1 (b), v(c) = v 1 (c), so we get v 1 = ((a b) c). 14

Consider v 2 : V AR {T, F } such that v 2 (a) = T, v 2 (b) = F, v 2 (c) = T, v 2 (d) = T, and v 2 (x) = F, for all x V AR {a, b, c, d}, Observe: v(a) = v 2 (a), v(b) = v 2 (b), v(c) = v 2 (c), so we get v 2 = ((a b) c). 15

We are going to prove that there are as many of such truth assignments as real numbers! but they are all the same as the first v with respect to the formula A. When we ask a question: How many truth assignments satisfy/fasify a formula A? we mean to find all assignment that are different on the formula A, not just different on a set V AR of all variables, as all of our v 1, v 2 s were. To address and to answer this question formally we first introduce some notations and definitions. 16

Notation: for any formula A, we denote by V AR A a set of all variables that appear in A. Definition: Given a formula A F, any function w : V AR A {T, F } is called a truth assignment restricted to A. 17

Example A = ((a b) c) V AR A = {a, b, c} A is any func- Truth assignment restricted to tion: w : {a, b, c} {T, F }. We use the following theorem to count all possible truth assignment restricted to A. Counting Functions Theorem (1) For any finite sets A and A, if A has n elements and B has m elements, then there are m n possible functions that map A into B. There are 2 3 = 8 truth assignment restricted to A = ((a b) c). 18

General case For any A there are 2 V AR A possible truth assignments w restricted to A.

All w restricted to A are listed in the table below. A = ((a b) c) w a b c w (A) computation w (A) w 1 T T T (T T ) T = T F = T T w 2 T T F (T T ) F = T T = T T w 3 T F F (T F ) F = F T = T T w 4 F F T (F F ) T = T F = T T w 5 F T T (F T ) T = T F = T T w 6 F T F (F T ) F = T T = T T w 7 T F T (T F ) T = F F = F F w 8 F F F (F F ) F = T T = T T Model for A is a v such that v = A. w 1, w 2, w 3, w 4 w 5, w 6, w 8 are models for A. Counter- Model for A is a v such that v = A. w 7 is a counter- model for A. 19

Tautology : A is a tautology iff any v is a model for A, i.e. v (v = A). Not a tautology : A is not a tautology iff there is v : V AR {T, F }, such that v is a countermodel for A, i.e. v (v = A). Tautology Notation = A Example = ((a b) c) because the truth assignment w 7 is a countermodel for A. 20

Tautology Verification Truth Table Method: list and evaluate all possible truth assignments restricted to A. Example: (a (a b)). v a b v (A) computation v (A) v 1 T T (T (T T )) = (T T ) = T T v 2 T F (T (T F )) = (T T ) = T T v 3 F T (F (F T )) = (F T ) = T T v 4 F F (F (F F )) = (F F ) = T T for all v : V AR {T, F }, v = A, i.e. = (a (a b)). 21

Proof by Contradiction Method One works backwards, trying to find a truth assignment v which makes a formula A false. If we find one, it means that A is not a tautology, if we prove that it is impossible, it means that the formula is a tautology. Example A = (a (a b) Step 1 Assume that = A, i.e. A = F. 22

Step 2 Analyze Strep 1: (a (a b)) = F iff a = T and a b = F. Step 3 Analyze Step 2: a = T and a b = F, i.e. T b = F. This is impossible by the definition of. Conclusion: = (a (a b)). Observe that exactly the same reasoning proves that for any formulas A, B F, = (A (A B)). 23

Observe that he following formulas are tautologies ((((a b) c) ((((a b) c) d)), (((a b) C) d) e) (((a b) C) d) e) ((a e))) because they are of the form (A (A B)). 24

Tautologies, Contradictions T = {A F : = A}, C = {A F : v (v = A)}. 25

Theorem 1 For any formula A F the following conditions are equivalent. (1) A is a tautology (2) A T (3) A is a contradiction (4) A C (5) v (v (A) = T ) (6) v (v = A) (7) Every v is a model for A 26

Theorem 2 For any formula A F the following conditions are equivalent. (1) A is a contradiction (2) A C (3) A is a tautology (4) A T (5) v (v (A) = F ) (6) v (v = A) (7) A does not have a model. 27