CSCE 222 Lecture 5

From Notes
Jump to navigation Jump to search

« previous | Friday, January 28, 2011 | next »


Predicate Logic

A Predicate is a function that filters from a domain by returning true or false:

EX: domain is all integers; predicate could be P(x) → x > 3
P(4) is true, but P(2) is false

"Predicate holds for all elements of a domain" written as

(be aware of what the domain is)

If a predicate holds for any one or more element of a domain, then Avoid using set notation (∈)

  • returns false if no value of in satisfies
  • is false if one value of in satisfies


Equivalence of Predicates


Example