# datalog - Winter 2006 COSC-6490B Issues in Information...

This preview shows pages 1–5. Sign up to view the full content.

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: Winter 2006 COSC-6490B: Issues in Information Integration —Godfrey p. 1 Propositional Logic Programs / Databases Recall our example conjunctive normal form (CNF) formula: ¬ a ∨ b ¬ b ∨ ¬ f ∨ h ¬ a ∨ c ¬ c ∨ ¬ d ∨ h ¬ b ∨ d ∨ e ¬ e ∨ ¬ g ∨ h ¬ c ∨ f ∨ g a This is written in the common shorthand for CNF: There are implicit ∧ ’s between the clauses. A clause is of the form l 1 ∨ . . . ∨ l k , in which each l i is a positive occurrence of a proposition (e.g., a ) or a negative occurrence of a proposition (e.g., ¬ a ). Oddly, let us call such a CNF formula as above a program , or even a database . It will become clearer as we progress why these names really are not so odd. Denote the program above as P . Winter 2006 COSC-6490B: Issues in Information Integration —Godfrey p. 2 Propositional Logic Queries Prove h from P . In other words, we are asking the query , is h true , given that P is true ? What does this query mean? It means for us to show that h logically follows from P . There are several approaches to do this. • Model Theory Approach: Show that in any situation in which P is true , h is also true . • Proof Theory Approach: Show that there is a sequence of inference steps that lead from the premise P to the conclusion h . Winter 2006 COSC-6490B: Issues in Information Integration —Godfrey p. 3 The Example Simplified Let us simplify our example P some so we do not have to work as hard. ¬ a ∨ b ¬ b ∨ ¬ f ∨ h ¬ a ∨ c ¬ c ∨ ¬ d ∨ h ¬ b ∨ d ∨ e ¬ e ∨ ¬ g ∨ h ¬ c ∨ f ∨ g a Does a have to be true for P to be true ? Clearly yes. If a were false , P is necessarily false . So a is true in all situations (in which P is true ). We also easily see then that b is true and that c is true . So for any clause that contains a positive occurrence of a (or b or c ), we can drop that clause from P since we now know that clause is true . For any clause that contains ¬ a (or ¬ b or ¬ c ), we can drop the ¬ a (or ¬ b or ¬ c ) from it since we know ¬ a (and ¬ b and ¬ c ) is false . (We have to keep the rest of the clause though, because it still could be either true or false . Thus our modified program, P ′ , is d ∨ e ¬ d ∨ h f ∨ g ¬ e ∨ ¬ g ∨ h ¬ f ∨ h P and P ′ —with a , b , and c as facts in P ′ —are logically equivalent. Winter 2006 COSC-6490B: Issues in Information Integration —Godfrey p. 4 Truth Tables (Models) We can guess for each proposition whether it is true or it is false , and see whether that makes P overall true or false , with respect to these guesses. Each possible truth assignment—having assigned each proposition (e.g., a, . . . , h ) to true or to false —is called an interpretation ....
View Full Document

{[ snackBarMessage ]}

### Page1 / 36

datalog - Winter 2006 COSC-6490B Issues in Information...

This preview shows document pages 1 - 5. Sign up to view the full document.

View Full Document
Ask a homework question - tutors are online