1 / 84

Agenda

Agenda. Review Minggu 1 : Partition Topik Minggu 2 : Propositions Conditional Propositions & Logical Equivalence Arguments & Rules of Inference Quantifiers Nested Quantifiers Latihan Soal. Review: Partition.

aarturo
Download Presentation

Agenda

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Agenda • ReviewMinggu 1: • Partition • Topik Minggu 2: • Propositions • Conditional Propositions & Logical Equivalence • Arguments & Rules of Inference • Quantifiers • Nested Quantifiers • LatihanSoal

  2. Review: Partition • A partition of a set X is a set of nonempty subsets of X such that every element x in X is in exactly one of these subsets  X is a disjoint union of the subsets. • A family of sets Pis a partition of X if and only if all of the following conditions hold: • P does not contain the empty set. • The union of the sets in P is equal to X. (The sets in P are said to coverX.) • The intersection of any two distinct sets in P is empty. (We say the elements of P are pairwise disjoint .

  3. Propositions

  4. Propositions/Statements • A statement (or proposition) is a sentence that is true or false but not both. • The truth value of a proposition is either TRUE / T / 1 or FALSE / F / 0. • Ex. • two plus two equals four • Proposition? Yes • Truth value: true • Jakarta is the capital of Singapore • Proposition? Yes • Truth value: false

  5. Examples • Two plus two equals five • Proposition? Yes • Truth value: False • An elephant is bigger than an ant • Proposition? Yes • Truth value: true • He is a university student • Proposition? No • Truth value: depends on who he is • C is bigger than 10 • Proposition? No • Truth value: unknown • F plus G equals 9 • Proposition? No • Truth value: unknown

  6. Examples: • Dimanaletakkampus UMN? • Proposition? No (pertanyaan) • Janganmemakai sandal kekampus • Proposition? No (perintah) • Mudah-mudahanjalantidakmacet • Proposition? No (harapan) • Indahnyabulanpurnama • Proposition? No (ketakjuban / keheranan)

  7. Compound Propositions / Compound Statements • A composition of two or more propositions / statement that is true or false but not both • Example: • Budi is studying at UMN, he is a university student • Compound statement? Yes • Truth value : True • Jika x = 1 dan y = 2 maka x lebih besar daripada y • Compound Statement? Yes • Truth value: False

  8. Examples • x ≤ a means x < a or x = a • a ≤ x ≤ b means a ≤ x and x ≤ b • 2 ≤ x ≤ 1 • compound statement? Yes • Truth value: False

  9. Formalization of (Compound) Statements • Translating a (compound) statement to symbols (such as x, y, z) and logical operator. • Logical operator: ~ , ¬ not Ù and  or

  10. Examples ¬p : not p, negation of p p Ù q : p and q, conjunction of p and q p  q : p or q, disjunction of p and q • Order of operation : ( … ) ~, ¬ Ù  Example: ¬p Ù q = (¬p) Ù q p Ù q  r Is it (p Ù q)  r or p Ù (q  r) ? To be safe, use (…)

  11. Examples • p: Today is Friday • Negation: ~p: Today is not Friday • p: At least 10 inches of rain fell today in Jakarta • Negation: ~p: Less than 10 inches of rain fell today in Jakarta

  12. Examples • p = it is hot; q = it is sunny • It is not hot but sunny • It is not hot and it is sunny ~p Ù q • It is neither hot nor sunny • It is not hot and it is not sunny ~p Ù ~q

  13. Truth Table The list of all possible truth values of a compound statement. Truth Table for Negation

  14. Truth Table for Conjunction p Ù q It is hot and it is sunny

  15. Truth Table for Disjunction p  q It is hot or it is sunny

  16. Truth Table for Exclusive Or It is hot or it is sunny, but not both Definition: (p  q) Ù ~(p Ù q) : p  q, p XOR q,

  17. Evaluating the Truth of more General Compound Statements ~p Ù q = (~p) Ù q Steps: • Evaluate the expressions within the innermost parentheses • Evaluate the expressions within the next innermost set of parentheses • Until you have the truth values for the complete expression.

  18. Evaluating the Truth of more General Compound Statements

  19. Tautology and Contradiction Tautology: True (for any truth values of their variables) Contradiction: False (for any truth values of their variables) Contoh: Tautology Contradiction

  20. Notes on Programming Language p Ù q = p && q p  q = p || q ~p = !p

  21. Conditional Propositions&Logical Equivalence

  22. Conditional Proposition Definition • Let p and q be propositions. The conditional propositionp  q is the proposition “if p then q”. p is called the hypothesis (or antecedent or premise) and q is called the conclusion (or consequence). • “p implies q” “p  q”; p: hypothesis, q: conclusion. • Conditional: the truth of statement q is conditioned on the truth of statement p • Example: IF 36 is divisible by 6, THEN 36 is divisible by 3

  23. Conditional Proposition • IF Maria learns discrete mathematics, THEN she will find a good job. • p: Maria learns discrete mathematics • q: she will find a good job. • p  q • Under what circumstances is the above sentence false? • False when Maria learns discrete mathematics but not find a good job • IF you show up for work Monday morning, THEN you will get the job. • Under what circumstances is the above sentence false?

  24. Truth Table for Conditional Proposition • Definition • p  q is false when p is true and q is false; otherwise it is true.

  25. Example:

  26. Biconditional Proposition Definition • Given statement variables p and q, the biconditional of p and q is “ p if and only if q” and is denoted p  q. The words if and only if are sometimes abbreviated iff.

  27. Priority • Logical operator: ( ) ~, ¬ not Ù and  or ,   if-then, iff

  28. Logical Equivalence Definition: • Two statement forms are called logically equivalent if, and only if, they have identical truth values for each possible substitution of statements for their statement variable. P = p Ù q Q = q Ù p • The logical equivalence of statement forms P and Q is denoted by writing P  Q

  29. ~(~p)  p

  30. Are ~(p Ù q) and ~p Ù ~q logically equivalent?

  31. De Morgan’s Laws Definition: • The negation of an AND statement is logically equivalent to the OR statement in which each component is negated. ~(p Ù q)  ~p  ~q • The negation of an OR statement is logically equivalent to the AND statement in which each component is negated. ~(p  q)  ~p Ù ~q

  32. De Morgan’s Laws: Truth Table

  33. De Morgan’s Laws: Exercise • Use De Morgan’s Laws to find the negation of each of the following statements: • Jan is rich and happy • Carlos will bicycle or run tomorrow • Melani walks or takes the bus to class • Ibrahim is smart and hard working

  34. Representation of IF-THEN as OR • p: you do not get to work on time • q: you are fired • IF you do not get to work on time THEN you are fired • ~p: you get to work on time • You get to work on time OR you are fired p  q  ~p  q

  35. Negation,Contrapositive,Converse,Inverse

  36. The Negation of a Conditional Proposition • The negation of “IF p THEN q” is logically equivalent to “p and not q” ~(p  q)  p Ù ~q • Show the equivalence by using Morgan Law: ~(p  q)  ~(~p  q)  ~(~p) Ù ~q  p Ù ~q

  37. The Negation of a Conditional Proposition • Exercise: Truth table for ~(p  q)  p Ù ~q

  38. The Negation of a Conditional Proposition • ~(IF my car is in the repair shop, THEN I cannot get the class) • My car is in the repair shop and I can get to class • ~(IF Sara lives in Jakarta, THEN she lives in Indonesia) • Sara lives in Jakarta and she does not live in Indonesia

  39. Biconditional Proposition • Is “ p if, and only if, q” logically equivalent with “ if p then q “and “if q then p”? p q  (p  q) Ù(q  p)

  40. Biconditional Proposition: Truth Table

  41. The Contrapositive of a Conditional Proposition Definition • The contrapositive of a conditional statement of the form “IF p THEN q” is “IF ~q THEN ~p” • The contrapositive of p  q is ~q  ~p • Are they logically equivalent? Construct the truth table • A conditional statement is logically equivalent to its contrapositive.

  42. Contrapositive: Examples • IF Howard can swim across the lake, THEN Howard can swim to the island • IF Howard cannot swim to the island, THEN Howard cannot swim across the lake • IF today is Easter, THEN tomorrow is Monday • IF tomorrow is not Monday, THEN today is not Easter

  43. The Converse and Inverse of a Conditional Statement Definition • Suppose a conditional statement of the form “IF p THEN q” is given. • The converse is “IF q THEN p” • The inverse is “IF ~p THEN ~q” Symbolically • The converse of p  q is q  p • The inverse of p  q is ~p  ~q Are they logically equivalent? Construct the truth table

  44. Converse and Inverse: Truth Table

  45. Converse and Inverse: Examples • IF Howard can swim across the lake, THEN Howard can swim to the island • Converse: IF Howard can swim to the island THEN Howard can swim across the lake • Inverse: IF Howard cannot swim across the lake, THEN Howard cannot swim to the island. • IF today is Easter, THEN tomorrow is Monday • Converse: IF tomorrow is Monday, THEN today is Easter • Inverse: IF today is not Easter, THEN tomorrow is not Monday

  46. Arguments&Rules of Inference

  47. Argument The bug is either in module 17 or in module 81 The bug is a numerical error Module 81 has no numerical error Conclusion: The bug is module 17 • Deductive reasoning: drawing a conclusion from a sequence of propositions.

  48. Argument Definition • A (deductive) argument is a sequence of hypotheses that ends with a conclusion. IF premise-1, ….., premise-n THEN conclusion • An argument is valid if and only if it is impossible for all the premises to be true and the conclusion to be false. If the premises are all true, then the conclusion is also true, otherwise the argument is invalid.

  49. Argument premise-1 premise-2 . . . premise-n q • The symbol , read “therefore”

  50. Example • If you have a current password, then you can log onto the network • You have a current password • Therefore, • You can log onto the network p  q p q • Construct the truth table p  q, p q

More Related