1 / 19

CS 1502 Formal Methods in Computer Science

CS 1502 Formal Methods in Computer Science. Lecture Notes 11. Example. Infer A  C from A  B and B  C. A  B B  C A  C This argument is known as the Transitivity of the Biconditional. Using Resolution. A  B is ( A  B)  (B  A)

vega
Download Presentation

CS 1502 Formal Methods in Computer Science

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. CS 1502 Formal Methods in Computer Science Lecture Notes 11

  2. Example • Infer A  C from A  B and B  C. • A B B  C A  C This argument is known as the Transitivity of the Biconditional.

  3. Using Resolution • A  B is (A  B)  (B  A) • B  C is (B  C)  (C  B) • (A  C) is (A  C )  (A  C) {A, B} {B,A} {B, C} {C, B} {A, C} {A, C} Resolution Proof: In Lecture

  4. Using Fitch

  5. A Tautology Law of Excluded Middle • P  P

  6. Exercise 6.33 (in the pdf solution)

  7. Exercise 6.33 (shorter version)

  8. Using DeMorgan’s, with Taut Con doing the work for you

  9. Using DeMorgan’s, but we do the work…(turns out to be redundant)

  10. Law of Excluded Middle • P  P Use with V-Elim in Proofs! To introduce it: Use Taut Con, if the rules allow Otherwise, insert proof 6.33

  11. Exercise 8.53 (on LPL Web site) Note: Fitch lines after line 4 And 11 were eaten by adobe. They should be there.

  12. Example • Prove this argument is valid from no premises. (P  Q) (P  Q) Logical truth

  13. Example

  14. Prove this argument • Horned(unicorn)  (Elusive(unicorn)  Dangerous(unicorn)) (Elusive(unicorn) Mythical(unicorn))  Rare(unicorn) Mammal(unicorn)  Rare(unicorn)Horned(unicorn)   Mammal(unicorn) • Proof is on the next slide; Go through it for practice on your own.

  15. 1. Horned(unicorn)  (Elusive(unicorn)  Dangerous(unicorn) 2. (Elusive(unicorn) Mythical(unicorn))  Rare(unicorn) 3. Mammal(unicorn)  Rare(unicorn) 4. Horned(unicorn) 5. Elusive(unicorn)  Dangerous(unicorn)  Elim 1,4 6. Elusive(unicorn)  Elim 57. Elusive(unicorn)  Mythical(unicorn)  Intro8. Rare(unicorn)  Elim 2,79. Mammal(unicorn) 10. Rare(unicorn)  Elim 3,911.   Intro 8,1012.  Mammal(unicorn)  Intro 9-1113.Horned(unicorn)   Mammal(unicorn) Intro 4-12

  16. Informal Proof Example • Prove there exists irrational numbers b and c such that bc is rational.Proof:Consider  = 22. This number is either rational or irrational. If  is rational we are finished since b = c = 2 . Assume  is irrational. Consider   2 = 2. Again we are finished since b =  and c = 2.

  17. English Translation EGsP  Q If P then Q (If you are human then you are a mammal) P implies Q (Being a human implies being a mammal) If P, Q (If you are human, you are a mammal) P only if Q (You’ll live a long time only if you eat veggies) P is sufficient for Q (Knowing you’re living a long time is sufficient to know you eat veggies) Q is necessary for P (Eating veggies is necessary to live a long time) Q if P (You are a mammal if you are human)

  18. P  Q Home(max)  Library(claire)Large(b)  Cube(b) If not P then QIf Max is not home, then Claire is at the library If b is not large, then it is a cube Unless P, QUnless Max is at home, Claire is at the library Unless b is large, b is a cube Q, unless P Claire is at the library unless Max is home B is a cube unless b is large Why not  for last two? (section 7.3 and lecture)

  19. Lecture: look at related questions on Assignment 3, in 7.12 and 7.15

More Related