CS1502 Formal Methods in Computer Science - PowerPoint PPT Presentation

1 / 10
About This Presentation
Title:

CS1502 Formal Methods in Computer Science

Description:

... you don't *need* any of the con rules. 3. 6 Fitch Proofs ... use only Intro/Elim rules ... basketball. Some teachers do not have time for basketball. 5 ... – PowerPoint PPT presentation

Number of Views:39
Avg rating:3.0/5.0
Slides: 11
Provided by: gan7
Category:

less

Transcript and Presenter's Notes

Title: CS1502 Formal Methods in Computer Science


1
CS1502 Formal Methods in Computer Science
  • Notes 15
  • Problem Sessions

2
Preliminaries
  • 3 proofs we will be able replace with Taut Con
  • 1 proof we will be able to replace with FO Con
  • First 4 proofs in
  • http//www.cs.pitt.edu/wiebe/courses/CS1502/lectu
    res/lec15solutions.pdf
  • Why?
  • Review
  • Illustrate that you dont need any of the con
    rules

3
6 Fitch Proofs
  • Well do them in Fitch in lecture
  • Next 6 proofs in
  • http//www.cs.pitt.edu/wiebe/courses/CS1502
    /lectures/lec15solutions.pdf
  • Problems 1-3 use only Intro/Elim rules
  • Problem 4 may use Taut Con on at most two
    support sentences
  • Problems 5-6 May use FO Con on at most one
    support sentence, and Taut Con for the resolution
    step

4
Problem 7
  • Prove the argument below is valid using a
    Fitch-style proof. Some teachers are
    scholars. No scholar has time for either
    football or basketball.? Some teachers
    do not have time for basketball.

5
Informal Proof
  • Prove that if the square of an integer is even,
    then so is that integer.
  • Proving the contrapositive is easier If an
    integer is not even, then its square isnt even
    either.
  • Let n be an integer. Assume Even(n), i.e.,
    Odd(n). Then we can express n as 2m 1 for some
    m. But we see that nn 2(2mm 2m) 1,
    showing that nn is odd. Thus, we have shown
    Even(n) ? Even(nn)

6
Review Questions around 10.13, 10.17 (see next
slide)
  • Recall the circles from lecture
  • inner tautological consequence
  • middle FO but not tautological cons
  • Outer logical but not FO cons
  • Outside the circle not a logical cons
  • Here are answers10.10 2 10.13 1 10.14 3
    10.15 2 10.16 1 10.17 3
  • Varations in lecture

7
Necessary S is always true Possible Satisfiable S could be true Equivalence S and S always have the same truth values Consequence Whenever P1Pn are true, Q is also true
Tautological Translate sentences into propositional logic using TFF algorithm S is a tautology S is Tautologically possible S and S are Tautologically equivalent Q is a tautological consequence of P1Pn
First Order (FO) Replace predicates with nonsense names S is an FO validity S is FO possible (FO satisfiable) S and S are FO equivalent Q is a FO consequence of P1Pn
Logical S is logically necessary (a logical truth) (logically valid) S is logically possible (satisfiable) S and S are logically equivalent Q is a logical consequence of P1Pn
8
Problem 8
  • Does ?x ? y P(x, y) follow from
  • ?x ? y P(x, y)?
  • Hint does ?x ? y SameRow(x, y) follow from ?x
    ? y SameRow(x, y)?

9
Problem 9
  • Does ?x ? y P(x, y) ? Q(x) follow from
  • ?x ?y P(x, y) ? Q(x)?
  • Hint does ?x ? y LeftOf(x,y) ?
    Large(x)follow from
  • ?x ?y LeftOf(x,y) ? Large(x)?

10
Problem 10
all x (P(x) ? Q(x)) all x (Q(x) ? P(x)) ----- All
x (P(x) ?? Q(x))
Write a Comment
User Comments (0)
About PowerShow.com