Bertram Ludäscher LUDAESCH@SDSC.EDU Department of Computer Science & Engineering University of California, San Diego CSE-291: Ontologies in Data Integration.

Slides:



Advertisements
Similar presentations
Predicate Logic Colin Campbell. A Formal Language Predicate Logic provides a way to formalize natural language so that ambiguity is removed. Mathematical.
Advertisements

Completeness and Expressiveness
1 Logic Logic in general is a subfield of philosophy and its development is credited to ancient Greeks. Symbolic or mathematical logic is used in AI. In.
Logic.
Outline Recap Knowledge Representation I Textbook: Chapters 6, 7, 9 and 10.
Computability and Complexity 9-1 Computability and Complexity Andrei Bulatov Logic Reminder (Cnt’d)
Formal Logic Proof Methods Direct Proof / Natural Deduction Conditional Proof (Implication Introduction) Reductio ad Absurdum Resolution Refutation.
Computability and Complexity 8-1 Computability and Complexity Andrei Bulatov Logic Reminder.
Knowledge Representation I (Propositional Logic) CSE 473.
From Chapter 4 Formal Specification using Z David Lightfoot
Knoweldge Representation & Reasoning
Predicate Calculus.
1 First order theories. 2 Satisfiability The classic SAT problem: given a propositional formula , is  satisfiable ? Example:  Let x 1,x 2 be propositional.
Deciding a Combination of Theories - Decision Procedure - Changki pswlab Combination of Theories Daniel Kroening, Ofer Strichman Presented by Changki.
Logic in Computer Science - Overview Sep 1, 2011 POSTECH 박성우.
1st-order Predicate Logic (FOL)
Pattern-directed inference systems
Propositional Logic Dr. Rogelio Dávila Pérez Profesor-Investigador División de Posgrado Universidad Autónoma Guadalajara
Chapter Three Truth Tables 1. Computing Truth-Values We can use truth tables to determine the truth-value of any compound sentence containing one of.
LDK R Logics for Data and Knowledge Representation PL of Classes.
Propositional Calculus CS 270: Mathematical Foundations of Computer Science Jeremy Johnson.
ARTIFICIAL INTELLIGENCE [INTELLIGENT AGENTS PARADIGM] Professor Janis Grundspenkis Riga Technical University Faculty of Computer Science and Information.
Logical Agents Chapter 7. Outline Knowledge-based agents Logic in general Propositional (Boolean) logic Equivalence, validity, satisfiability.
CS6133 Software Specification and Verification
LDK R Logics for Data and Knowledge Representation First Order Logics (FOL) Originally by Alessandro Agostini and Fausto Giunchiglia Modified by Fausto.
Nikolaj Bjørner Microsoft Research DTU Winter course January 2 nd 2012 Organized by Flemming Nielson & Hanne Riis Nielson.
1 First order theories (Chapter 1, Sections 1.4 – 1.5) From the slides for the book “Decision procedures” by D.Kroening and O.Strichman.
Logic Programming. Formal Logics- Recap Formulas – w/out quantifiers Free Variables Bound Variables Assignments and satisfaction Validity and satisfiability.
CSE-291: Ontologies in Data Integration Department of Computer Science & Engineering University of California, San Diego CSE-291: Ontologies in Data Integration.
Semantics of Predicate Calculus For the propositional calculus, an interpretation was simply an assignment of truth values to the proposition letters of.
CSE-291: Ontologies in Data Integration Department of Computer Science & Engineering University of California, San Diego CSE-291: Ontologies in Data Integration.
Knowledge Repn. & Reasoning Lec. #5: First-Order Logic UIUC CS 498: Section EA Professor: Eyal Amir Fall Semester 2004.
Chapter 7. Propositional and Predicate Logic Fall 2013 Comp3710 Artificial Intelligence Computing Science Thompson Rivers University.
LDK R Logics for Data and Knowledge Representation Propositional Logic Originally by Alessandro Agostini and Fausto Giunchiglia Modified by Fausto Giunchiglia,
Software Verification 1 Deductive Verification Prof. Dr. Holger Schlingloff Institut für Informatik der Humboldt Universität und Fraunhofer.
Albert Gatt LIN3021 Formal Semantics Lecture 3. Aims This lecture is divided into two parts: 1. We make our first attempts at formalising the notion of.
ARTIFICIAL INTELLIGENCE [INTELLIGENT AGENTS PARADIGM] Professor Janis Grundspenkis Riga Technical University Faculty of Computer Science and Information.
First-Order Logic Semantics Reading: Chapter 8, , FOL Syntax and Semantics read: FOL Knowledge Engineering read: FOL.
Propositional Logic Rather than jumping right into FOL, we begin with propositional logic A logic involves: §Language (with a syntax) §Semantics §Proof.
ARTIFICIAL INTELLIGENCE Lecture 2 Propositional Calculus.
Logics for Data and Knowledge Representation ClassL (part 1): syntax and semantics.
Daniel Kroening and Ofer Strichman 1 Decision Procedures An Algorithmic Point of View Basic Concepts and Background.
CSE-291: Ontologies in Data Integration Department of Computer Science & Engineering University of California, San Diego CSE-291: Ontologies in Data Integration.
Discrete Mathematical Structures: Theory and Applications 1 Logic: Learning Objectives  Learn about statements (propositions)  Learn how to use logical.
1 Section 7.1 First-Order Predicate Calculus Predicate calculus studies the internal structure of sentences where subjects are applied to predicates existentially.
Logics for Data and Knowledge Representation ClassL (part 1): syntax and semantics.
March 3, 2016Introduction to Artificial Intelligence Lecture 12: Knowledge Representation & Reasoning I 1 Back to “Serious” Topics… Knowledge Representation.
CENG 424-Logic for CS Introduction Based on the Lecture Notes of Konstantin Korovin, Valentin Goranko, Russel and Norvig, and Michael Genesereth.
Propositional Logic (a.k.a. Sentential Logic)
Chapter 7. Propositional and Predicate Logic
Propositional Calculus: Boolean Functions and Expressions
Knowledge Representation and Reasoning
The Propositional Calculus
Logics for Data and Knowledge Representation
Propositional Calculus: Boolean Functions and Expressions
Lecture 2 Propositional Logic
Logics for Data and Knowledge Representation
Logics for Data and Knowledge Representation
Logics for Data and Knowledge Representation
1st-order Predicate Logic (FOL)
Back to “Serious” Topics…
MA/CSSE 474 More Math Review Theory of Computation
Computer Security: Art and Science, 2nd Edition
Logical Agents Chapter 7.
Logics for Data and Knowledge Representation
Chapter 7. Propositional and Predicate Logic
Search techniques.
Logics for Data and Knowledge Representation
Representations & Reasoning Systems (RRS) (2.2)
1st-order Predicate Logic (FOL)
Presentation transcript:

Bertram Ludäscher LUDAESCH@SDSC.EDU Department of Computer Science & Engineering University of California, San Diego CSE-291: Ontologies in Data Integration Spring 2004 Bertram Ludäscher LUDAESCH@SDSC.EDU

Introduction to Reasoning in First-order [Predicate] Logic and Description Logic(s) Introduction to FO (aka PL) Syntax, Semantics Two decidable fragments: propositional logic description logic(s) Reasoning w/ Tableaux Description Logic Reasoning … Discussion of Topics / Assignments

Syntax vs Semantics Syntax Semantics a.k.a. “formation rules”; “grammar”; … prescribes what a well-formed formula is (syntactically) Semantics the “meaning” of well-formed formulas defined via a mapping called interpretation

Propositional Logic: Syntax <logic> (or "propositional calculus") A system of symbolic logic using symbols to stand for whole propositions and logical connectives. Propositional logic only considers whether a proposition is true or false. In contrast to predicate logic, it does not consider the internal structure of propositions. http://wombat.doc.ic.ac.uk/foldoc/foldoc.cgi?propositional+logic Logical symbols: conjunction: , disjunction: , negation: , implication: , equivalence: , parentheses:   Non-logical symbols: propositional variables p, q, r, ... signature: set of propositional variables  = {p, q, r, ...} Formation rules for well-formed formulas (wff) an atomic formula (propositional variable) is a formula if F, G are formulas, so are: FG, F  G,  F, FG , FG,  F 

Propositional Logic: Semantics Propositions can be assigned a truth-value: either true or false (classical 2-valued logic: tertium non datur) other propositional logics exist: 3-valued, 4-valued, temporal, … (modal logics), …, fuzzy logic An interpretation I over a signature  is a mapping I:   {true, false} , associating a truth value to every propositional variable Truth tables describe how to extend I from atomic to composite formulas (Boolean Algebra): FG, F  G,  F, FG , FG

Boolean Algebra, Truth Tables http://wombat.doc.ic.ac.uk/foldoc/foldoc.cgi?two-valued+logic

Different Logical Bases Often: ,  ,  Alternatively: ,   ,  NAND NOR XOR What about: ite(A,B,C) … if A then B else C ?

Reasoning in Propositional Logic A formula F is … valid if it is true for all interpretations I satisfiable if it is true for some interpretation I unsatisfiable if it is true for no interpretation I Try these: p  q p  p p  p p  p p  p  p  p

Reasoning in Propositional Logic Def. “models” relationship “|=”: If a formula F evaluates to true for an interpretation I then I is called a model of F; written I |= F I is a model of {F1,…, Fk}, written I |= {F1,…, Fk},if I is a model of each Fj Automated deduction setting: Show that A1,,…, An (axioms) imply T (theorem), that is, every model of the axioms is also a model of the theorem: That is: if I |= {A1,,…, An } then I |= T Short: {A1,,…, An } |= T Often: Show that A1  …  An  T is unsatisfiable We need a procedure / reasoning algorithm: Predicate Calculus (in fact calculi: resolution, tableaux, …)

Example {p, p  q } |= q Truth table Resolution Tableaux

Example: Reasoning with Binary Decision Trees (see also: Binary Decision Diagrams, or BDDs) A  B A A A if-false if-true 1 1 B B false true 1 1  A …  B A  B A if-false if-true A A 1 true false B 1 B 1 1 1

Syntax of First-Order Logic (FO) Logical symbols: , , , , ,  ,  (“for all”),  (“exists”), ... Non-logical symbols: A FO signature  consists of constant symbols: a,b,c, ... function symbols: f, g, ... predicate (relation) symbols: p,q,r, .... function and predicate symbols have an associated arity; we can write, e.g., p/3, f/2 to denote the ternary predicate p and the function f with two arguments First-order variables: x, y, ... Formation rules for terms: constants and variables are terms if t1,…,tk are terms and f is a k-ary function symbols then f(t1,...,tk) is a term

Syntax of First-Order Logic (FO) Formation rules for formulas: if t1,…, tk are terms and p/k is a predicate symbol (of arity k) then p(t1, …, tk) is an atomic formula (short: atom) all variable occurrences in p(t1, …, tk) are free if F,G are formulas and x is a variable, then the following are formulas: FG, F  G,  F, FG , FG,  F , x: F (“for all x: F(x,...) is true”) x: F (“there exists x such that F(x,...) is true”) the occurrences of a variable x within the scope of a quantifier are called bound occurrences.

Examples x man(x)  person(x). man(bill). child(marriage(bill,hillary),chelsea). Variable: x Constants (0-ary function symbols): bill/0, hillary/0, chelsea/0 Function symbols: marriage/2 Predicate symbols: man/1, person/1, child/2

Semantics of Predicate Logic Let D be a non-empty domain (a.k.a. universe of discourse). A structure is a pair I = (D,I), with an interpretation I that maps ... each constant symbols c to an element I(c) D each predicate symbol p/k to a k-ary relation I(p)  Dk, each function symbol f/k to a k-ary function I(f): DkD Let I be a structure,  : Vars  D a variable assignment. A valuation valI, maps Term to D and Fml to {true, false} valI, (x) =  (x) ; for x  Vars valI, (f(t1,...,tk)) = I(f)( valI, (t1),..., valI, (tk) ) ; for f(t1,...,tk)  Term valI, (p(t1,...,tk)) = I(p)( valI, (t1),..., valI, (tk) ) ; for p(t1,...,tk)  At valI, (F  G) = valI, (F) and valI, (G) are true ; for F,G Fml valI, (F  G) = valI, (F) or valI, (G) is true ; for F,G Fml valI, ( F) = true (false) if valI, (F) is false (true) ; for FFml valI, ( x F) = valI,[x/t] (F) is true for some t  D ; for FFml valI, ( x F) = valI,[x/t] (F) is true for all t  D ; for FFml

Example Let’s pick an interpretation I: Formula F = x man(x)  person(x). Domain D = {b, h, c, d, e} Let’s pick an interpretation I: I(bill) = b, I(hillary) = h, I(chelsea) = c I(person) = {b, h, c} I(man) = {b} Under this I, the formula F evaluates to true. If we choose I’ like I but I’(man) = {b,d}, then F evaluates to false Thus, I is a model of F, while I’ is not: I |= F I’ |=/= F

FO Semantics (cont’d) F entails G (G is a logical consequence of F) if every model of F is also a model of G: F |= G F is consistent or satisfiable if it has at least one model F is valid or a tautology if every interpretation of F is a model Proof Theory: Let F,G, ... be FO sentences (no free variables). Then the following are equivalent: F_1, ..., F_k |= G F_1  ...  F_k  G is valid F_1  ...  F_k   G is unsatisfiable (inconsistent)

Proof Theory A calculus is formal proof system to establish F1,…, Fk |= T via formal (syntactic) derivations F1,…, Fk |– ... |– T, where the “|–” denotes allowed proof steps Examples: Hilbert Calculus, Gentzen Calculus, Tableaux Calculus, Natural Deduction, Resolution, ... First-order logic is “semi-decidable”: the set of valid sentences is recursively enumerable, but not recursive (decidable) Some inference engines: http://www.semanticweb.org/inference.html

Querying vs. Reasoning Querying: Reasoning: given a DB instance I (= logic interpretation), evaluate a query expression (e.g. SQL, FO formula, Prolog program, ...) boolean query: check if I |=  (i.e., if I is a model of ) (ternary) query: { (X, Y, Z) | I |=  (X,Y,Z) } => check happyFathers in a given database Reasoning: check if I |=  implies I |=  for all databases I, i.e., if  =>  undecidable for FO, F-logic, etc. Descriptions Logics are decidable fragments concept subsumption, concept hierarchy, classification semantic tableaux, resolution, specialized algorithms

Reasoning Example (1) p(0) (2) x p(x)  p(s(x)) (3) p(s(s(0))). We want to show that (1) & ... & (2) implies (3) Approach: assume negation of (3) and show that it leads to a contradiction with {(1), (2)} Question: Why is this sound?

“Types” of Formulas () rule for F = A  B (and other disjunctions) (and other conjunctions) () rule for F = x: A(X,...) substitute a -variable X with an arbitrary term t () rules for F = x: A(X,...) substitute a -variable X with a new constant c

(Semantic) Tableaux Rules t arbitrary c new () rule for F = A  B () rule for F = A  B () rule for F = x: A(X,...) substitute a -variable X with an arbitrary term t () rules for F = x: A(X,...) substitute a -variable X with a new constant c A branch is closed if it contains complementary formulas A tableaux is closed if every branch is closed

FO Tableaux Calculus Theorem (Soundness, Completeness of Tableaux calculus): Let A1,..., Ak and F be first-order logic sentences. (Recall: a sentence is a closed formula, i.e., has no free variables) Then the following are equivalent: A1, ..., Ak |= F A1  ...  Ak  F is unsatisfiable (inconsistent) There is a closed tableaux for {A1, ..., Ak ,  F}

Reasoning with DLs (Shawn Bowers)