Presentation is loading. Please wait.

Presentation is loading. Please wait.

COS 150 Discrete Structures Assoc. Prof. Svetla Boytcheva Fall semester 2014.

Similar presentations


Presentation on theme: "COS 150 Discrete Structures Assoc. Prof. Svetla Boytcheva Fall semester 2014."— Presentation transcript:

1 COS 150 Discrete Structures Assoc. Prof. Svetla Boytcheva Fall semester 2014

2 Lecture № 2 Fundamentals of Logic

3 Outline  Logical Form and Logical Equivalence  Logical Equivalence; Tautologies and Contradictions;  Summary of Logical Equivalences  Conditional Statements  Representation of If-Then As Or ;  The Negation of a Conditional Statement;  The Contrapositive of a Conditional Statement;  The Converse and Inverse of a Conditional Statement; Only If and the Biconditional;  Necessary and Sufficient Conditions;  Valid and Invalid Arguments  Modus Ponens and Modus Tollens;  Additional Valid Argument Forms: Rules of Inference;

4 Playing with implication 10/23/2015

5 Playing with implication 10/23/2015

6 Truth Table of equivalence 10/23/2015

7 Logically Equivalent Statements 10/23/2015

8 Tautologies 10/23/2015

9 Contradictions 10/23/2015

10 Logic Equivalences 10/23/2015 or

11 Why this is important? 10/23/2015

12 Examples 10/23/2015

13 Examples 10/23/2015

14 Equivalence and Tautology 10/23/2015

15 Example 10/23/2015

16 Examples 10/23/2015

17 Truth Tables 10/23/2015 pq pqpqqpqppqpq pp qq pqpq  (p  q)  p  q FFFFTTTTTT FTTTTTFTFF TFTTFFTFFF TTTTTFFTFF

18 Double Negation 10/23/2015

19 DeMorgan’s Laws 10/23/2015 pq pqpqpqpq pp qq  p  q  (p  q)  (p  q)  p  q FFFFTTTTTT FTTFTFTFTF TFTFFTTFTF TTTTFFFFFF

20 Example  Write in C++ the condition for floating point variable size, in which the message “Present” will be displayed for the following code fragment if ( size > 25 || size == 19 ) cout<<”Future”; else if ( size 2) cout<<"Past"; else cout <<"Present"; 10/23/2015

21 “Algebraic” Laws of Logic 10/23/2015

22 “Logic” Laws of Logic 10/23/2015

23 Number of Rows in Truth Table 10/23/2015

24 Expressing Connectives 10/23/2015

25 Example 10/23/2015

26 Example 10/23/2015

27 Example: Decreasing number of comparisons 10/23/2015

28 Example: Decreasing number of comparisons 10/23/2015

29 Example 10/23/2015

30 Example 10/23/2015

31 Logic Inference

32 First Law of Substitution 10/23/2015

33 Second Law of Substitution 10/23/2015

34 Logic inference 10/23/2015

35

36 Inference and Tautology 10/23/2015

37

38 General Definition of Inference 10/23/2015

39 Examples  Tautology  X   X  Logical Contradiction  X   X  Negation of Tautology  Valid – if all values are true – the logic value is true  X  Y  X  Y  Logic Equivalence 10/23/2015 and

40 Inference Rules  “Modus ponens"  "Modus tollens” 10/23/2015

41 Modus Ponens 10/23/2015

42 Rule of Tollens 10/23/2015

43 Example 10/23/2015

44 MORE READING: CHAPTER 2 SUSANNA S. EPP, DISCRETE MATHEMATICS WITH APPLICATIONS Questions? 10/23/2015


Download ppt "COS 150 Discrete Structures Assoc. Prof. Svetla Boytcheva Fall semester 2014."

Similar presentations


Ads by Google