IIT Madras
- Dept. of Computer Science & Engineering
CS 210
Foundations of Computer Science
Debdeep Mukhopadhyay
CS 210 Foundations of Computer Science Debdeep Mukhopadhyay - - PowerPoint PPT Presentation
IIT Madras Dept. of Computer Science & Engineering CS 210 Foundations of Computer Science Debdeep Mukhopadhyay Mathematical Reasoning Foundations of Logic Mathematical Logic is a tool for working with elaborate compound statements. It
Debdeep Mukhopadhyay
Topic #1 – Propositional Logic
George Boole (1815-1864)
Topic #1 – Propositional Logic
Topic #1 – Propositional Logic
Topic #1.0 – Propositional Logic: Operators
Topic #1.0 – Propositional Logic: Operators
Topic #1.0 – Propositional Logic: Operators
ND”
Topic #1.0 – Propositional Logic: Operators
Topic #1.0 – Propositional Logic: Operators
After the downward- pointing “axe” of “∨ ∨” ” splits the wood, you splits the wood, you can take 1 piece OR can take 1 piece OR the other, or both. the other, or both.
Topic #1.0 – Propositional Logic: Operators
Topic #1.0 – Propositional Logic: Operators
Topic #1.0 – Propositional Logic: Operators
Topic #1.0 – Propositional Logic: Operators
Topic #1.0 – Propositional Logic: Operators
Note difference from OR.
Topic #1.0 – Propositional Logic: Operators
Topic #1.0 – Propositional Logic: Operators
Topic #1.0 – Propositional Logic: Operators
⇒
Topic #1.0 – Propositional Logic: Operators
For simplicity, I shall denote the implication operator by the symbol and the iff operator by ↔
Topic #1.0 – Propositional Logic: Operators
Topic #1.0 – Propositional Logic: Operators
If p is true, that is enough, q has to be true for the implication to hold (sufficiency) If q is false, p cannot be true; It is necessary that q be true for p to be true (necessicity)
Topic #1.0 – Propositional Logic: Operators
Topic #1.0 – Propositional Logic: Operators
Topic #1.0 – Propositional Logic: Operators 2004 I’m still here! 2005
Topic #1.0 – Propositional Logic: Operators
Topic #1.0 – Propositional Logic: Operators
Name:
Propositional logic:
Boolean algebra:
C/C++/Java (wordwise): !
C/C++/Java (bitwise):
Logic gates:
Topic #1.0 – Propositional Logic: Operators
Topic #2 – Bits
John Tukey (1915-2000)
Topic #2 – Bits
Topic #2 – Bits
Topic #2 – Bits
Topic #1.1 – Propositional Logic: Equivalences
Topic #1.1 – Propositional Logic: Equivalences
Topic #1.1 – Propositional Logic: Equivalences
Topic #1.1 – Propositional Logic: Equivalences
Topic #1.1 – Propositional Logic: Equivalences
Topic #1.1 – Propositional Logic: Equivalences
Topic #1.1 – Propositional Logic: Equivalences
Augustus De Morgan (1806-1871)
Topic #1.1 – Propositional Logic: Equivalences
Topic #1.1 – Propositional Logic: Equivalences
Topic #1.1 – Propositional Logic: Equivalences
Topic #1.1 – Propositional Logic: Equivalences
Topic #1 – Propositional Logic
Topic #3 – Predicate Logic
Topic #3 – Predicate Logic
Topic #3 – Predicate Logic
Topic #3 – Predicate Logic
Topic #3 – Predicate Logic
Topic #3 – Predicate Logic
Topic #3 – Predicate Logic
Topic #3 – Predicate Logic
Topic #3 – Predicate Logic
– i.e., “For each parking space at IITM, that space is full.” Topic #3 – Predicate Logic
Topic #3 – Predicate Logic
Topic #3 – Predicate Logic
Topic #3 – Predicate Logic
Topic #3 – Predicate Logic
Topic #3 – Predicate Logic
Topic #3 – Predicate Logic
– Verifier: Wants to demonstrate that the proposition is true. – Falsifier: Wants to demonstrate that the proposition is false.
– Read the quantifiers from left to right, picking values of variables. – When you see “∀”, the falsifier gets to select the value. – When you see “∃”, the verifier gets to select the value.
Topic #3 – Predicate Logic
Your turn, as falsifier: You pick any x → (so-and-so)
My turn, as verifier: I pick any y → (such-and-such)
Topic #3 – Predicate Logic
Topic #3 – Predicate Logic
Topic #3 – Predicate Logic
Topic #3 – Predicate Logic
Topic #3 – Predicate Logic
Topic #3 – Predicate Logic
Topic #3 – Predicate Logic
Topic #3 – Predicate Logic
Topic #3 – Predicate Logic
Topic #3 – Predicate Logic
Topic #3 – Predicate Logic
Topic #3 – Predicate Logic
Topic #3 – Predicate Logic