The Foundations: Logic and Proof, Sets, and Foundations PROPOSITIONS A proposition is a declarative sentence that is either True or False, but not the.

Slides:



Advertisements
Similar presentations
Propositional Equivalences
Advertisements

Propositional Equivalences. L32 Agenda Tautologies Logical Equivalences.
Discrete Mathematics. Agenda Course policies Quick Overview Logic.
UNIT-I Statements and Notations Connectives Normal Forms
Copyright 2013, 2010, 2007, Pearson, Education, Inc. Section 3.2 Truth Tables for Negation, Conjunction, and Disjunction.
1 Section 1.2 Propositional Equivalences. 2 Equivalent Propositions Have the same truth table Can be used interchangeably For example, exclusive or and.
1 Math 306 Foundations of Mathematics I Math 306 Foundations of Mathematics I Goals of this class Introduction to important mathematical concepts Development.
First Order Logic. Propositional Logic A proposition is a declarative sentence (a sentence that declares a fact) that is either true or false, but not.
Chapter 2: The Logic of Compound Statements 2.1 Logical Forms and Equivalence 12.1 Logical Forms and Equivalences Logic is a science of the necessary laws.
3.2 – Truth Tables and Equivalent Statements
Copyright 2013, 2010, 2007, Pearson, Education, Inc. Section 3.2 Truth Tables for Negation, Conjunction, and Disjunction.
Discrete Mathematics Goals of a Discrete Mathematics Learn how to think mathematically 1. Mathematical Reasoning Foundation for discussions of methods.
Propositions and Truth Tables
Chapter 1 Section 1.4 More on Conditionals. There are three statements that are related to a conditional statement. They are called the converse, inverse.
Propositions and Truth Tables. Proposition: Makes a claim that may be either true or false; it must have the structure of a complete sentence.
The Foundations: Logic and Proofs
MATERI II PROPOSISI. 2 Tautology and Contradiction Definition A tautology is a statement form that is always true. A statement whose form is a tautology.
Discrete Mathematics and Its Applications
Discrete Mathematics CS 285. Lecture 12 Section 1.1: Logic Axiomatic concepts in math: Equals Opposite Truth and falsehood Statement Objects Collections.
Mathematical Structures A collection of objects with operations defined on them and the accompanying properties form a mathematical structure or system.
1 Logic Logic is a discipline that studies the principles and methods used in correct reasoning It includes: A formal language for expressing statements.
CS 285- Discrete Mathematics Lecture 2. Section 1.1 Propositional Logic Propositions Conditional Statements Truth Tables of Compound Propositions Translating.
Chapter 1 The Logic of Compound Statements. Section 1.1 Logical Form and Logical Equivalence.
Chapter 1: The Foundations: Logic and Proofs
BY: MISS FARAH ADIBAH ADNAN IMK. CHAPTER OUTLINE: PART III 1.3 ELEMENTARY LOGIC INTRODUCTION PROPOSITION COMPOUND STATEMENTS LOGICAL.
Discrete Mathematics. Propositional Logic 10/8/2015 What’s a proposition? PropositionsNot Propositions = 32Bring me coffee! CS173 is Bryan’s favorite.
Chapter 5 – Logic CSNB 143 Discrete Mathematical Structures.
Logical Form and Logical Equivalence Lecture 2 Section 1.1 Fri, Jan 19, 2007.
Discrete Mathematics MCA 105 LOGICS Preeti Mehta.
Discrete Mathematics Lecture1 Miss.Amal Alshardy.
The Foundations Logic and Proofs by raedRASHEED 2014.
CSNB143 – Discrete Structure LOGIC. Learning Outcomes Student should be able to know what is it means by statement. Students should be able to identify.
Tautologies, contradictions, contingencies
Reading: Chapter 4 (44-59) from the text book
CS 381 DISCRETE STRUCTURES Gongjun Yan Aug 25, November 2015Introduction & Propositional Logic 1.
Chapter 7 Logic, Sets, and Counting
Propositional Logic. Propositions Any statement that is either True (T) or False (F) is a proposition Propositional variables: a variable that can assume.
Lecture 9 Conditional Statements CSCI – 1900 Mathematics for Computer Science Fall 2014 Bill Pine.
Chapter 7 Logic, Sets, and Counting Section 1 Logic.
Section 1.2: Propositional Equivalences In the process of reasoning, we often replace a known statement with an equivalent statement that more closely.
Discrete Mathematics CS 285. Lecture 12 Quick Overview The conceptual center of computer science is the ALGORITHM.
Propositional Logic ITCS 2175 (Rosen Section 1.1, 1.2)
Logical Form and Logical Equivalence Lecture 1 Section 1.1 Wed, Jan 12, 2005.
Chapter 2 Logic 2.1 Statements 2.2 The Negation of a Statement 2.3 The Disjunction and Conjunction of Statements 2.4 The Implication 2.5 More on Implications.
CS203 Discrete Mathematical Structures
Chapter 1: The Foundations: Logic and Proofs
Conditional Statements – Page 1CSCI 1900 – Discrete Structures CSCI 1900 Discrete Structures Conditional Statements Reading: Kolman, Section 2.2.
Section 1.1. Section Summary Propositions Connectives Negation Conjunction Disjunction Implication; contrapositive, inverse, converse Biconditional Truth.
Joan Ridgway. If a proposition is not indeterminate then it is either true (T) or false (F). True and False are complementary events. For two propositions,
Symbolic Logic The Following slide were written using materials from the Book: The Following slide were written using materials from the Book: Discrete.
LECTURE 1. Disrete mathematics and its application by rosen 7 th edition THE FOUNDATIONS: LOGIC AND PROOFS 1.1 PROPOSITIONAL LOGIC.
رياضيات متقطعة لعلوم الحاسب MATH 226. Text books: (Discrete Mathematics and its applications) Kenneth H. Rosen, seventh Edition, 2012, McGraw- Hill.
Section 1.1. Propositions A proposition is a declarative sentence that is either true or false. Examples of propositions: a) The Moon is made of green.
Mathematics for Computing Lecture 2: Computer Logic and Truth Tables Dr Andrew Purkiss-Trew Cancer Research UK
Mathematics for Comter I Lecture 3: Logic (2) Propositional Equivalences Predicates and Quantifiers.
L 11 Discrete Computational Structures. L 12 Lectures and Notes Lectures are electronic and will be available online after class.
1 Georgia Tech, IIC, GVU, 2006 MAGIC Lab Rossignac Lecture 01: Boolean Logic Sections 1.1 and 1.2 Jarek Rossignac.
CS104 The Foundations: Logic and Proof 1. 2 What is Discrete Structure?  Discrete Objects  Separated from each other (Opposite of continuous)  e.g.,
Chapter 1. Chapter Summary  Propositional Logic  The Language of Propositions (1.1)  Logical Equivalences (1.3)  Predicate Logic  The Language of.
Chapter 1 Propositional Logic
2. The Logic of Compound Statements Summary
COT 3100, Spr Applications of Discrete Structures
(CSC 102) Discrete Structures Lecture 2.
Propositional Equivalences
Information Technology Department
Propositional Equivalence (§1.2)
Discrete Mathematics and Its Applications Kenneth H
Lecture 2: Propositional Equivalences
Discrete Mathematics CMP-200 Propositional Equivalences, Predicates & Quantifiers, Negating Quantified Statements Abdul Hameed
Logic Logic is a discipline that studies the principles and methods used to construct valid arguments. An argument is a related sequence of statements.
Presentation transcript:

The Foundations: Logic and Proof, Sets, and Foundations PROPOSITIONS A proposition is a declarative sentence that is either True or False, but not the both. Example: 1. Washington is the capital of United states of America, 2. Toronto is the capital of Canada = = 3 Proposition 1 and 3 are True whereas 2 and 4 are False.

The Foundations: Logic and Proof, Sets, and Foundations Consider the following sentences 1. What time is it? 2. Read this carefully. 3. x+1 = 2 4. x+y = 3 1 and 2 are not Propositions because they are not declarative sentences. 3 and 4 are not Propositions because they are neither True nor False. Truth value of proposition is true, denoted by T and truth value of proposition is false denoted F. The area of logic that deals with propositions is called the propositional calculus or propositional logic. Developed by the Greek philosopher Aristotle 2300 years back.

Logical Connectives OperatorSymbolUsage Negation  not Conjunction  and Disjunction  or Exclusive or  xor Conditional  if,then Biconditional  iff

Compound Propositions: Examples p = “Cruise ships only go on big rivers.” q = “Cruise ships go on the Hudson.” r = “The Hudson is a big river.”  r = “The Hudson is not a big river.” p  q = “Cruise ships only go on big rivers and go on the Hudson.” p  q  r = “If cruise ships only go on big rivers and go on the Hudson, then the Hudson is a big river.”

Negation This just turns a false proposition to true and the opposite for a true proposition. EG: p = “23 = 15 +7” p happens to be false, so  p is true.

Negation – truth table Logical operators are defined by truth tables –tables which give the output of the operator in the right-most column. Here is the truth table for negation: p pp FTFT TFTF

Conjunction Conjunction is a binary operator in that it operates on two propositions when creating compound proposition. On the other hand, negation is a unary operator (the only non-trivial one possible).

Conjunction Conjunction is supposed to encapsulate what happens when we use the word “and” in English. I.e., for “p and q ” to be true, it must be the case that BOTH p is true, as well as q. If one of these is false, than the compound statement is false as well.

Conjunction EG. p = “Clinton was the president.” q = “Hilary was the president.” r = “The meaning of is is important.” Assuming p and r are true, while q false. Out of p  q, p  r, q  r only p  r is true.

Conjunction – truth table pq pqpq TTFFTTFF TFTFTFTF TFFFTFFF

Disjunction – truth table Conversely, disjunction is true when at least one of the components is true: pq pqpq TTFFTTFF TFTFTFTF TTTFTTTF

Disjunction – Example EG. p = “Clinton was the president.” q = “Hilary was the president.” r = “The meaning of is is not important.” Assuming p is true, while q and r are false. Out of p  q, p  r, q  r only q  r is false.

Review NOT, AND, OR What is the disjumction --- or What is the conjunction – and Negation – not Construct the TT for all above

Disjunction – caveat A: The entrée is served with soup or salad. Most restaurants definitely don’t allow you to get both soup and salad so that the statement is false when both soup and salad is served. To address this situation, exclusive-or is introduced next.

Exclusive-Or – truth table pq p  q TTFFTTFF TFTFTFTF FTTFFTTF

Conditional (Implication) This one is probably the least intuitive. It’s only partly akin to the English usage of “if, then” or “implies”. DEF: p  q is true if q is true, or if p is false. In the final case (p is true while q is false) p  q is false. Semantics: “p implies q ” is true if one can mathematically derive q from p.

Conditional -- truth table pq p  q TTFFTTFF TFTFTFTF TFTTTFTT

Biconditional Let P and Q be propositions. The biconditional P ↔ Q is the proposition that is True when P and Q have the same truth values, and is False otherwise. P if and only if Q P→Q and Q→ P P is necessary and sufficient for Q

Biconditional truth table PQ P ↔Q TTFFTTFF TFTFTFTF TFFTTFFT

Let P and Q be the propositions P: It is below freezing. Q: It is snowing. Express each of these propositions as an English sentences P  Q, P  Q,  P  Q, P  Q, P→Q, P↔Q Answers: It is below freezing and snowing. It is below freezing but not snowing. It is not below freezing and it is not snowing. It is below freezing or snowing. If it is below freezing then it is snowing. It is below freezing iff it is snowing

Propositional Equivalences

Tautologies, contradictions, contingencies DEF: A compound proposition is called a tautology if no matter what truth values its atomic propositions have, its own truth value is T. EG: p  ¬ p (Law of excluded middle) The opposite to a tautology, is a compound proposition that ’ s always false – a contradiction. EG: p  ¬ p On the other hand, a compound proposition whose truth value isn ’ t constant is called a contingency. EG: p  ¬ p

Tautologies and contradictions The easiest way to see if a compound proposition is a tautology/contradiction is to use a truth table. TFTF FTFT pp p TTTT p  p TFTF FTFT pp p FFFF p  p

Tautology example Demonstrate that [ ¬ p  (p  q )]  q is a tautology in two ways: 1.Using a truth table – show that [ ¬ p  (p  q )]  q is always true 2.Using a proof (will get to this later).

Tautology by truth table pq ¬p¬p p  q ¬ p  (p  q )[ ¬ p  (p  q )]  q TT TF FT FF

Tautology by truth table pq ¬p¬p p  q ¬ p  (p  q )[ ¬ p  (p  q )]  q TTF TFF FTT FFT

Tautology by truth table pq ¬p¬p p  q ¬ p  (p  q )[ ¬ p  (p  q )]  q TTFT TFFT FTTT FFTF

Tautology by truth table pq ¬p¬p p  q ¬ p  (p  q )[ ¬ p  (p  q )]  q TTFTF TFFTF FTTTT FFTFF

Tautology by truth table pq ¬p¬p p  q ¬ p  (p  q )[ ¬ p  (p  q )]  q TTFTFT TFFTFT FTTTTT FFTFFT

Logical Equivalences DEF: Two compound propositions p, q are logically equivalent if their biconditional joining p  q is a tautology. Logical equivalence is denoted by p  q. EG: The contrapositive of a logical implication is the reversal of the implication, while negating both components. I.e. the contrapositive of p  q is ¬ q  ¬ p. As we ’ ll see next: p  q  ¬ q  ¬ p

Logical Equivalence of Conditional and Contrapositive The easiest way to check for logical equivalence is to see if the truth tables of both variants have identical last columns: p  q qp Q: why does this work given definition of  ? ¬q¬p¬q¬p p ¬p¬pq ¬q¬q

Logical Equivalence of Conditional and Contrapositive The easiest way to check for logical equivalence is to see if the truth tables of both variants have identical last columns: TFTTTFTT TFTFTFTF TTFFTTFF p  q qp Q: why does this work given definition of  ? ¬q¬p¬q¬p p ¬p¬pq ¬q¬q

Logical Equivalence of Conditional and Contrapositive The easiest way to check for logical equivalence is to see if the truth tables of both variants have identical last columns: TFTTTFTT TFTFTFTF TTFFTTFF p  q qp Q: why does this work given definition of  ? TTFFTTFF ¬q¬p¬q¬p p ¬p¬p TFTFTFTF q ¬q¬q

Logical Equivalence of Conditional and Contrapositive The easiest way to check for logical equivalence is to see if the truth tables of both variants have identical last columns: TFTTTFTT TFTFTFTF TTFFTTFF p  q qp Q: why does this work given definition of  ? TTFFTTFF ¬q¬p¬q¬p p ¬p¬p TFTFTFTF q FTFTFTFT ¬q¬q

Logical Equivalence of Conditional and Contrapositive The easiest way to check for logical equivalence is to see if the truth tables of both variants have identical last columns: TFTTTFTT TFTFTFTF TTFFTTFF p  q qp Q: why does this work given definition of  ? TTFFTTFF ¬q¬p¬q¬p p FFTTFFTT ¬p¬p TFTFTFTF q FTFTFTFT ¬q¬q

Logical Equivalence of Conditional and Contrapositive The easiest way to check for logical equivalence is to see if the truth tables of both variants have identical last columns: TFTTTFTT TFTFTFTF TTFFTTFF p  q qp Q: why does this work given definition of  ? TFTTTFTT TTFFTTFF ¬q¬p¬q¬p p FFTTFFTT ¬p¬p TFTFTFTF q FTFTFTFT ¬q¬q

Logical Equivalences A: p  q by definition means that p  q is a tautology. Furthermore, the biconditional is true exactly when the truth values of p and of q are identical. So if the last column of truth tables of p and of q is identical, the biconditional join of both is a tautology.

Logical Non-Equivalence of Conditional and Converse The converse of a logical implication is the reversal of the implication. I.e. the converse of p  q is q  p. EG: The converse of “ If Donald is a duck then Donald is a bird. ” is “ If Donald is a bird then Donald is a duck. ” As we ’ ll see next: p  q and q  p are not logically equivalent.

Logical Non-Equivalence of Conditional and Converse pq p  qq  p(p  q)  (q  p)

Logical Non-Equivalence of Conditional and Converse pq p  qq  p(p  q)  (q  p) TTFFTTFF TFTFTFTF

Logical Non-Equivalence of Conditional and Converse pq p  qq  p(p  q)  (q  p) TTFFTTFF TFTFTFTF TFTTTFTT

Logical Non-Equivalence of Conditional and Converse pq p  qq  p(p  q)  (q  p) TTFFTTFF TFTFTFTF TFTTTFTT TTFTTTFT

Logical Non-Equivalence of Conditional and Converse pq p  qq  p(p  q)  (q  p) TTFFTTFF TFTFTFTF TFTTTFTT TTFTTTFT TFFTTFFT

Derivational Proof Techniques When compound propositions involve more and more atomic components, the size of the truth table for the compound propositions increases Q1: How many rows are required to construct the truth-table of: ( (q  (p  r ))  (  (s  r)  t) )  (  q  r ) Q2: How many rows are required to construct the truth-table of a proposition involving n atomic components?

Derivational Proof Techniques A1: 32 rows, each additional variable doubles the number of rows A2: In general, 2 n rows Therefore, as compound propositions grow in complexity, truth tables become more and more unwieldy. Checking for tautologies/logical equivalences of complex propositions can become a chore, especially if the problem is obvious.

Derivational Proof Techniques EG: consider the compound proposition (p  p )  (  (s  r)  t) )  (  q  r ) Q: Why is this a tautology?

Derivational Proof Techniques A: Part of it is a tautology (p  p ) and the disjunction of True with any other compound proposition is still True: (p  p )  (  (s  r)  t ))  (  q  r )  T  (  (s  r)  t ))  (  q  r )  T Derivational techniques formalize the intuition of this example.

Tables of Logical Equivalences Identity laws Like adding 0 Domination laws Like multiplying by 0 Idempotent laws Delete redundancies Double negation “ I don ’ t like you, not ” Commutativity Like “ x+y = y+x ” Associativity Like “ (x+y)+z = y+(x+z) ” Distributivity Like “ (x+y)z = xz+yz ” De Morgan

Tables of Logical Equivalences Excluded middle Negating creates opposite Definition of implication in terms of Not and Or

DeMorgan Identities DeMorgan ’ s identities allow for simplification of negations of complex expressions Conjunctional negation:  (p 1  p 2  …  p n )  (  p 1  p 2  …  p n ) Disjunctional negation:  (p 1  p 2  …  p n )  (  p 1  p 2  …  p n )

Tautology example (1.2.8.a) Part 2 Demonstrate that [ ¬ p  (p  q )]  q is a tautology in two ways: 1.Using a truth table (did above) 2.Using a proof.

Tautology by proof [ ¬ p  (p  q )]  q

Tautology by proof [ ¬ p  (p  q )]  q  [( ¬ p  p)  ( ¬ p  q)]  qDistributive

Tautology by proof [ ¬ p  (p  q )]  q  [( ¬ p  p)  ( ¬ p  q)]  qDistributive  [ F  ( ¬ p  q)]  q ULE

Tautology by proof [ ¬ p  (p  q )]  q  [( ¬ p  p)  ( ¬ p  q)]  qDistributive  [ F  ( ¬ p  q)]  q ULE  [ ¬ p  q ]  q Identity

Tautology by proof [ ¬ p  (p  q )]  q  [( ¬ p  p)  ( ¬ p  q)]  qDistributive  [ F  ( ¬ p  q)]  q ULE  [ ¬ p  q ]  q Identity  ¬ [ ¬ p  q ]  q ULE

Tautology by proof [ ¬ p  (p  q )]  q  [( ¬ p  p)  ( ¬ p  q)]  qDistributive  [ F  ( ¬ p  q)]  q ULE  [ ¬ p  q ]  q Identity  ¬ [ ¬ p  q ]  q ULE  [ ¬ ( ¬ p)  ¬ q ]  q DeMorgan

Tautology by proof [ ¬ p  (p  q )]  q  [( ¬ p  p)  ( ¬ p  q)]  qDistributive  [ F  ( ¬ p  q)]  q ULE  [ ¬ p  q ]  q Identity  ¬ [ ¬ p  q ]  q ULE  [ ¬ ( ¬ p)  ¬ q ]  q DeMorgan  [p  ¬ q ]  q Double Negation

Tautology by proof [ ¬ p  (p  q )]  q  [( ¬ p  p)  ( ¬ p  q)]  qDistributive  [ F  ( ¬ p  q)]  q ULE  [ ¬ p  q ]  q Identity  ¬ [ ¬ p  q ]  q ULE  [ ¬ ( ¬ p)  ¬ q ]  q DeMorgan  [p  ¬ q ]  q Double Negation  p  [ ¬ q  q ] Associative

Tautology by proof [ ¬ p  (p  q )]  q  [( ¬ p  p)  ( ¬ p  q)]  qDistributive  [ F  ( ¬ p  q)]  q ULE  [ ¬ p  q ]  q Identity  ¬ [ ¬ p  q ]  q ULE  [ ¬ ( ¬ p)  ¬ q ]  q DeMorgan  [p  ¬ q ]  q Double Negation  p  [ ¬ q  q ] Associative  p  [q  ¬ q ] Commutative

Tautology by proof [ ¬ p  (p  q )]  q  [( ¬ p  p)  ( ¬ p  q)]  qDistributive  [ F  ( ¬ p  q)]  q ULE  [ ¬ p  q ]  q Identity  ¬ [ ¬ p  q ]  q ULE  [ ¬ ( ¬ p)  ¬ q ]  q DeMorgan  [p  ¬ q ]  q Double Negation  p  [ ¬ q  q ] Associative  p  [q  ¬ q ] Commutative  p  T ULE

Tautology by proof [ ¬ p  (p  q )]  q  [( ¬ p  p)  ( ¬ p  q)]  qDistributive  [ F  ( ¬ p  q)]  q ULE  [ ¬ p  q ]  q Identity  ¬ [ ¬ p  q ]  q ULE  [ ¬ ( ¬ p)  ¬ q ]  q DeMorgan  [p  ¬ q ]  q Double Negation  p  [ ¬ q  q ] Associative  p  [q  ¬ q ] Commutative  p  T ULE  T Domination

Exercises Construct the truth table for the following Propositions: 1, (P  Q) →Q 2, (P  Q) →(P  Q) 3, (P→Q)  (  P→  Q) 4, (P  Q)  (P  Q) 5, (P↔Q)  (P↔  Q) Show that the following by constructing the truth table: 1, (P↔Q)  (P→Q)  (Q→P) 2, (P→Q)  P  Q 3, P  (Q  R)  (P  Q)  (P  R)

Exercises Show that (P  Q)→(P  Q) is a tautology. Show that [  P  (P  Q)]→Q is a tautology. Determine whether the proposition [  P  (P → Q)]→Q is a tautology or not. Determine whether the proposition [P  (P → Q)]→Q is a tautology or not. Determine whether the proposition [  Q  (P → Q)]→  Q is a tautology or not. Show that  (P→Q)→  Q is a tautology. Show that  (P→Q)→  P is a tautology. Show that  (P  (  P  Q)) and  P  Q are logically equivalent.