Datalog Evaluation. Linh Anh Nguyen. Institute of Informatics University of Warsaw

Size: px
Start display at page:

Download "Datalog Evaluation. Linh Anh Nguyen. Institute of Informatics University of Warsaw"

Transcription

1 Datalog Evaluation Linh Anh Nguyen Institute of Informatics University of Warsaw

2 Outline Simple Evaluation Methods Query-Subquery Recursive Magic-Set Technique Query-Subquery Nets [2/64] Linh Anh Nguyen Datalog Evaluation

3 Simple Evaluation Algorithms Methods to evaluate Datalog program P on database instance I, derived from the different equivalent definitions of the semantics: Model-theoretic definition: Enumerate all subsets J B(P, I) and check modelhood pick smallest such J. Fixpoint definition: Augment I using operator T P until a fixpoint is reached. Proof-theoretic definition: Use SLD-resolution (bottom-up or top-down) [3/64] Linh Anh Nguyen Datalog Evaluation

4 Classes of Datalog Evaluation Two major classes of evaluation approaches: Bottom-Up, Forward Chaining: Proceed in the proof tree from the leaves to the root Apply the datalog rules from body to head (forward) Top-Down, Backward Chaining: Proceed in the proof tree from the root to the leaves Apply the datalog rules from head to body (backward) [4/64] Linh Anh Nguyen Datalog Evaluation

5 Naive Evaluation Follow the bottom-up approach Compute the minimum fixpoint of T P containing I (= T ω P (I)) Given datalog program P, database instance I 1 Start by assuming all idb relations are empty. 2 Repeatedly evaluate the rules using the edb and the previous idb, to get a new idb. 3 End when no change to idb. Disadvantages Relations have to be computed always from scratch, Relations must be copied, Iteration on all relations, even if they do not recursively depend on each other. [5/64] Linh Anh Nguyen Datalog Evaluation

6 Semi-naive Evaluation Since the edb never changes, on each round we only get new idb tuples if we use at least one idb tuple that was obtained on the previous round. Saves work, lets us avoid rediscovering most known facts. [6/64] Linh Anh Nguyen Datalog Evaluation

7 Adornment An adornment for an m-ary predicate p is a string α of length m made up of b (bound) and f (free), let p α be the predicate p adorned by α. The general algorithm for adorning a rule (i) All occurrences of each bound variable in the rule head are bound; (ii) All occurrences of constants are bound; (iii) If a variable X occurs in the rule body, then all occurrences of X in subsequent literals are bound; (iv) The remaining occurrences of variables are free. A different ordering of the rule body would yield different adornments. [7/64] Linh Anh Nguyen Datalog Evaluation

8 Adornment - Example Consider the following positive logic program P: r 1 : ancestor(x, y) parent(x, y) r 2 : ancestor(x, y) parent(x, z), ancestor(z, y) where x, y, z are variables parent is an extensional predicate, ancestor is an intensional predicate, parent(x, y) means x is a parent of y, ancestor(x, y) means x is an ancestor of y. Let the query be ancestor(john, y)?, asking John is an ancestor of whom?. The task is to find all the descendants of John. [8/64] Linh Anh Nguyen Datalog Evaluation

9 Adornment - Example Consider the following positive logic program P: r 1 : ancestor(x, y) parent(x, y) r 2 : ancestor(x, y) parent(x, z), ancestor(z, y) The adorned version (denoted by P ad ) of the program P and the query ancestor(john, y)?: r 1 : ancestor bf (x, y) parent(x, y) r 2 : ancestor bf (x, y) parent(x, z), ancestor bf (z, y) query f (y) ancestor bf (John, y) [9/64] Linh Anh Nguyen Datalog Evaluation

10 Outline Simple Evaluation Methods Query-Subquery Recursive Magic-Set Technique Query-Subquery Nets [10/64] Linh Anh Nguyen Datalog Evaluation

11 Query-Sub-Query Recursive (QSQR) Top-down, direct evaluation; Avoid the calculation of tuples that are not used for deriving answer; Begin with constants in a query pushing them from goals to subgoals; Use sideways information passing to pass constant binding information from one atom to the next in subgoals. [11/64] Linh Anh Nguyen Datalog Evaluation

12 QSQR - Example Reconsider the following adorned program P ad : r 1 : ancestor bf (x, y) parent(x, y) r 2 : ancestor bf (x, y) parent(x, z), ancestor bf (z, y) query f (y) ancestor bf (John, y) [12/64] Linh Anh Nguyen Datalog Evaluation

13 QSQR - Example [13/64] Linh Anh Nguyen Datalog Evaluation

14 QSQR - Example [14/64] Linh Anh Nguyen Datalog Evaluation

15 QSQR - Example [15/64] Linh Anh Nguyen Datalog Evaluation

16 QSQR - Example [16/64] Linh Anh Nguyen Datalog Evaluation

17 QSQR - Example [17/64] Linh Anh Nguyen Datalog Evaluation

18 QSQR - Example [18/64] Linh Anh Nguyen Datalog Evaluation

19 QSQR - Example [19/64] Linh Anh Nguyen Datalog Evaluation

20 QSQR - Example [20/64] Linh Anh Nguyen Datalog Evaluation

21 QSQR - Example [21/64] Linh Anh Nguyen Datalog Evaluation

22 QSQR - Example [22/64] Linh Anh Nguyen Datalog Evaluation

23 QSQR - Example [23/64] Linh Anh Nguyen Datalog Evaluation

24 QSQR - Example [24/64] Linh Anh Nguyen Datalog Evaluation

25 QSQR - Example [25/64] Linh Anh Nguyen Datalog Evaluation

26 QSQR - Example [26/64] Linh Anh Nguyen Datalog Evaluation

27 QSQR - Example [27/64] Linh Anh Nguyen Datalog Evaluation

28 QSQR - Example [28/64] Linh Anh Nguyen Datalog Evaluation

29 QSQR - Example [29/64] Linh Anh Nguyen Datalog Evaluation

30 QSQR - Example [30/64] Linh Anh Nguyen Datalog Evaluation

31 QSQR - Example [31/64] Linh Anh Nguyen Datalog Evaluation

32 QSQR - Example [32/64] Linh Anh Nguyen Datalog Evaluation

33 QSQR - Example [33/64] Linh Anh Nguyen Datalog Evaluation

34 QSQR - Example [34/64] Linh Anh Nguyen Datalog Evaluation

35 Outline Simple Evaluation Methods Query-Subquery Recursive Magic-Set Technique Query-Subquery Nets [35/64] Linh Anh Nguyen Datalog Evaluation

36 Magic-Set technique The Magic-Set technique is a rule-rewriting method that generates from a given set of rules a new set of rules, which is equivalent to the original set w.r.t. the original query. After rewriting, the new program can be evaluated by a simple bottom-up algorithm, usually the (improved) semi-naive evaluation method. This method takes advantages of reducing irrelevant facts and restricting the search space. It combines the pros of top-down and bottom-up methods. The Generalized Supplementary Magic Sets algorithm uses some special predicates called supplementary magic predicates in order to eliminate the duplicate work during the processing. [36/64] Linh Anh Nguyen Datalog Evaluation

37 Magic-Set technique - Example The Magic-Set rule-rewriting corresponding to the adorned program P ad (denoted by P mg ): magic ancestor bf (z) magic ancestor bf (x), parent(x, z) ancestor bf (x, y) magic ancestor bf (x), parent(x, y) ancestor bf (x, y) magic ancestor bf (x), parent(x, z), ancestor bf (z, y) magic ancestor bf (John). [37/64] Linh Anh Nguyen Datalog Evaluation

38 Magic-Set technique - Example Applying improved semi-naive evaluation method for P mg : iteration 1: magic ancestor bf (Ruth), magic ancestor bf (Lois) added. iteration 2: magic ancestor bf (Andy), magic ancestor bf (Mark) added. iteration 3: ancestor bf (John, Lois), ancestor bf (John, Ruth), ancestor bf (Lois, Andy), ancestor bf (Lois, Mark), ancestor bf (John, Andy), ancestor bf (John, Mark) added. iteration 4: fixpoint (no more tuples were added). [38/64] Linh Anh Nguyen Datalog Evaluation

39 Magic-Set technique - Example Generalized Supplementary Magic Sets (denoted by P gmg ): sup magic2 2(x, z) magic ancestor bf (x), parent(x, z) ancestor bf (x, y) magic ancestor bf (x), parent(x, y) ancestor bf (x, y) magic ancestor bf (z) sup magic2 2(x, z), ancestor bf (z, y) sup magic2 2 (x, z) magic ancestor bf (John). [39/64] Linh Anh Nguyen Datalog Evaluation

40 Magic-Set technique - Example Applying improved semi-naive evaluation method for P gmg : iteration 1: sup magic2 2(John, Ruth), sup magic2 2 (John, Lois), magic ancestor bf (Ruth), magic ancestor bf (Lois) added. iteration 2: sup magic2 2(Lois, Andy), sup magic2 2 (Lois, Mark), magic ancestor bf (Andy), magic ancestor bf (Mark) added. iteration 3: ancestor bf (John, Lois), ancestor bf (John, Ruth), ancestor bf (Lois, Andy), ancestor bf (Lois, Mark), ancestor bf (John, Andy), ancestor bf (John, Mark) added. iteration 4: fixpoint (no more tuples were added). [40/64] Linh Anh Nguyen Datalog Evaluation

41 Outline Simple Evaluation Methods Query-Subquery Recursive Magic-Set Technique Query-Subquery Nets [41/64] Linh Anh Nguyen Datalog Evaluation

42 Query-Subquery Nets Make a QSQ-net structure from a program P and use it as a flow control network to choose the processing order of transferring data, in an efficient way. The intention is to increase efficiency of query processing by: eliminating redundant computation, increasing flexibility, reducing the number of accesses to the secondary storage. The framework forms a generic evaluation method called QSQN. It has the following nice properties: the approach is goal-directed, each subquery is processed only once, each supplement tuple, if desired, is transferred only once, operations are done set-at-a-time, any control strategy can be used. [42/64] Linh Anh Nguyen Datalog Evaluation

43 Query-Subquery Nets Definition 1. QSQ-net Structure A QSQ-net structure of a positive logic program P is a tuple (V, E, T ) such that: V is a set of nodes, E is a set of edges, T is a function, called the memorizing type of the net structure. We call the pair (V, E) the QSQ-net topological structure of P. Definition 2. QSQ-net A QSQ-net of P is a tuple N = (V, E, T, C) such that: (V, E, T ) is a QSQ-net structure of P, C is a mapping that associates each node v V with a structure call the content of v. [43/64] Linh Anh Nguyen Datalog Evaluation

44 Query-Subquery Nets Definition 1. QSQ-net Structure A QSQ-net structure of a positive logic program P is a tuple (V, E, T ) such that: V is a set of nodes, E is a set of edges, T is a function, called the memorizing type of the net structure. We call the pair (V, E) the QSQ-net topological structure of P. Definition 2. QSQ-net A QSQ-net of P is a tuple N = (V, E, T, C) such that: (V, E, T ) is a QSQ-net structure of P, C is a mapping that associates each node v V with a structure call the content of v. [43/64] Linh Anh Nguyen Datalog Evaluation

45 Query-Subquery Nets A subquery is a pair of the form (t, δ), where t is a generalized tuple and δ is an idempotent substitution such that dom(δ) Vars(t) =. Subqueries are transferred through edges and processed at nodes. Formally, the processing of a subquery has following properties: every subquery / input tuple / answer tuple subsumed by another one is ignored; every subquery / input tuple / answer tuple with term-depth greater than a fixed bound L is ignored; the processing is divided into smaller steps which can be delayed to maximize flexibility and allow various control strategies; the processing is done set-at-a-time (e.g., for all the unprocessed subqueries accumulated in a given node). [44/64] Linh Anh Nguyen Datalog Evaluation

46 QSQN - Example Reconsider the program P: ancestor(x, y) parent(x, y) ancestor(x, y) parent(x, z), ancestor(z, y). The QSQ-net topological structure of P is constructed as follows: [45/64] Linh Anh Nguyen Datalog Evaluation

47 QSQN - Example [46/64] Linh Anh Nguyen Datalog Evaluation

48 QSQN - Example [47/64] Linh Anh Nguyen Datalog Evaluation

49 QSQN - Example [48/64] Linh Anh Nguyen Datalog Evaluation

50 QSQN - Example [49/64] Linh Anh Nguyen Datalog Evaluation

51 QSQN - Example [50/64] Linh Anh Nguyen Datalog Evaluation

52 QSQN - Example [51/64] Linh Anh Nguyen Datalog Evaluation

53 QSQN - Example [52/64] Linh Anh Nguyen Datalog Evaluation

54 QSQN - Example [53/64] Linh Anh Nguyen Datalog Evaluation

55 Query-Subquery Nets Control strategies are used: Disk Access Reduction (DAR), which tries to reduce the number of accesses to the secondary storage; Depth-First Search (DFS), which gives priority to the order of clauses in the positive logic program defining intensional predicates and thus allows the user to control the evaluation to a certain extent; Improved Depth-First Control Strategy (IDFS), which is an improved version of DFS and the aim is to accumulate as many as possible tuples or subqueries at each node of the QSQ-net before processing it. [54/64] Linh Anh Nguyen Datalog Evaluation

56 QSQN - Example Reconsider the program P: ancestor(x, y) parent(x, y) ancestor(x, y) parent(x, z), ancestor(z, y). The query: ancestor(john, y)? [55/64] Linh Anh Nguyen Datalog Evaluation

57 QSQN - Example [56/64] Linh Anh Nguyen Datalog Evaluation

58 QSQN - Example [57/64] Linh Anh Nguyen Datalog Evaluation

59 QSQN - Example [58/64] Linh Anh Nguyen Datalog Evaluation

60 QSQN - Example [59/64] Linh Anh Nguyen Datalog Evaluation

61 QSQN - Example [60/64] Linh Anh Nguyen Datalog Evaluation

62 QSQN - Example [61/64] Linh Anh Nguyen Datalog Evaluation

63 QSQN - Example [62/64] Linh Anh Nguyen Datalog Evaluation

64 QSQN - Example [63/64] Linh Anh Nguyen Datalog Evaluation

65 QSQN - Example At this point, some edges are active without affecting to the ans ancestor relation. When all the attributes unprocessed, unprocessed subqueries, unprocessed subqueries 2 and unprocessed tuples of the nodes in the net are empty sets, the algorithm terminates and returns the set tuples(ans ancestor) = {(John, Lois), (John, Ruth), (John, Mark), (John, Andy)}. for the query ancestor(john, y)? [64/64] Linh Anh Nguyen Datalog Evaluation

Foundations of Databases

Foundations of Databases Foundations of Databases Free University of Bozen Bolzano, 2004 2005 Thomas Eiter Institut für Informationssysteme Arbeitsbereich Wissensbasierte Systeme (184/3) Technische Universität Wien http://www.kr.tuwien.ac.at/staff/eiter

More information

DATABASE THEORY. Lecture 12: Evaluation of Datalog (2) TU Dresden, 30 June Markus Krötzsch

DATABASE THEORY. Lecture 12: Evaluation of Datalog (2) TU Dresden, 30 June Markus Krötzsch DATABASE THEORY Lecture 12: Evaluation of Datalog (2) Markus Krötzsch TU Dresden, 30 June 2016 Overview 1. Introduction Relational data model 2. First-order queries 3. Complexity of query answering 4.

More information

DATABASE THEORY. Lecture 15: Datalog Evaluation (2) TU Dresden, 26th June Markus Krötzsch Knowledge-Based Systems

DATABASE THEORY. Lecture 15: Datalog Evaluation (2) TU Dresden, 26th June Markus Krötzsch Knowledge-Based Systems DATABASE THEORY Lecture 15: Datalog Evaluation (2) Markus Krötzsch Knowledge-Based Systems TU Dresden, 26th June 2018 Review: Datalog Evaluation A rule-based recursive query language father(alice, bob)

More information

Datalog Evaluation. Serge Abiteboul. 5 mai 2009 INRIA. Serge Abiteboul (INRIA) Datalog Evaluation 5 mai / 1

Datalog Evaluation. Serge Abiteboul. 5 mai 2009 INRIA. Serge Abiteboul (INRIA) Datalog Evaluation 5 mai / 1 Datalog Evaluation Serge Abiteboul INRIA 5 mai 2009 Serge Abiteboul (INRIA) Datalog Evaluation 5 mai 2009 1 / 1 Datalog READ CHAPTER 13 lots of research in the late 80 th top-down or bottom-up evaluation

More information

DATABASE THEORY. Lecture 11: Introduction to Datalog. TU Dresden, 12th June Markus Krötzsch Knowledge-Based Systems

DATABASE THEORY. Lecture 11: Introduction to Datalog. TU Dresden, 12th June Markus Krötzsch Knowledge-Based Systems DATABASE THEORY Lecture 11: Introduction to Datalog Markus Krötzsch Knowledge-Based Systems TU Dresden, 12th June 2018 Announcement All lectures and the exercise on 19 June 2018 will be in room APB 1004

More information

Conjunctive queries. Many computational problems are much easier for conjunctive queries than for general first-order queries.

Conjunctive queries. Many computational problems are much easier for conjunctive queries than for general first-order queries. Conjunctive queries Relational calculus queries without negation and disjunction. Conjunctive queries have a normal form: ( y 1 ) ( y n )(p 1 (x 1,..., x m, y 1,..., y n ) p k (x 1,..., x m, y 1,..., y

More information

Logic As a Query Language. Datalog. A Logical Rule. Anatomy of a Rule. sub-goals Are Atoms. Anatomy of a Rule

Logic As a Query Language. Datalog. A Logical Rule. Anatomy of a Rule. sub-goals Are Atoms. Anatomy of a Rule Logic As a Query Language Datalog Logical Rules Recursion SQL-99 Recursion 1 If-then logical rules have been used in many systems. Most important today: EII (Enterprise Information Integration). Nonrecursive

More information

}Optimization Formalisms for recursive queries. Module 11: Optimization of Recursive Queries. Module Outline Datalog

}Optimization Formalisms for recursive queries. Module 11: Optimization of Recursive Queries. Module Outline Datalog Module 11: Optimization of Recursive Queries 11.1 Formalisms for recursive queries Examples for problems requiring recursion: Module Outline 11.1 Formalisms for recursive queries 11.2 Computing recursive

More information

}Optimization. Module 11: Optimization of Recursive Queries. Module Outline

}Optimization. Module 11: Optimization of Recursive Queries. Module Outline Module 11: Optimization of Recursive Queries Module Outline 11.1 Formalisms for recursive queries 11.2 Computing recursive queries 11.3 Partial transitive closures User Query Transformation & Optimization

More information

Data Integration: Datalog

Data Integration: Datalog Data Integration: Datalog Jan Chomicki University at Buffalo and Warsaw University Feb. 22, 2007 Jan Chomicki (UB/UW) Data Integration: Datalog Feb. 22, 2007 1 / 12 Plan of the course 1 Datalog 2 Negation

More information

D2R2: Disk-oriented Deductive Reasoning in a RISC-style RDF Engine

D2R2: Disk-oriented Deductive Reasoning in a RISC-style RDF Engine D2R2: Disk-oriented Deductive Reasoning in a RISC-style RDF Engine Mohamed Yahya and Martin Theobald Max-Planck Institute for Informatics, Saarbrücken, Germany {myahya,mtb}@mpi-inf.mpg.de Abstract. Deductive

More information

Chapter 6: Bottom-Up Evaluation

Chapter 6: Bottom-Up Evaluation 6. Bottom-Up Evaluation 6-1 Deductive Databases and Logic Programming (Winter 2009/2010) Chapter 6: Bottom-Up Evaluation Evaluation of logic programs with DB techniques. Predicate dependency graph. Seminaive

More information

Database Theory: Beyond FO

Database Theory: Beyond FO Database Theory: Beyond FO CS 645 Feb 11, 2010 Some slide content based on materials of Dan Suciu, Ullman/Widom 1 TODAY: Coming lectures Limited expressiveness of FO Adding recursion (Datalog) Expressiveness

More information

Program Analysis in Datalog

Program Analysis in Datalog CS 510/08 Program Analysis in Datalog Majority of the slides compiled from John Whaley s Outline Challenges Essential Background Using the Tools Developing Advanced Analyses Challenges Most DF analyses

More information

Implementation Techniques

Implementation Techniques Web Science & Technologies University of Koblenz Landau, Germany Implementation Techniques Acknowledgements to Angele, Gehrke, STI Word of Caution There is not the one silver bullet In actual systems,

More information

Deductive Databases. Motivation. Datalog. Chapter 25

Deductive Databases. Motivation. Datalog. Chapter 25 Deductive Databases Chapter 25 1 Motivation SQL-92 cannot express some queries: Are we running low on any parts needed to build a ZX600 sports car? What is the total component and assembly cost to build

More information

An Extended Magic Sets Strategy for a Rule. Paulo J Azevedo. Departamento de Informatica Braga, Portugal.

An Extended Magic Sets Strategy for a Rule. Paulo J Azevedo. Departamento de Informatica Braga, Portugal. An Extended Magic Sets Strategy for a Rule language with Updates and Transactions Paulo J Azevedo Departamento de Informatica Universidade do Minho, Campus de Gualtar 4700 Braga, Portugal pja@diuminhopt

More information

CMPS 277 Principles of Database Systems. https://courses.soe.ucsc.edu/courses/cmps277/fall11/01. Lecture #11

CMPS 277 Principles of Database Systems. https://courses.soe.ucsc.edu/courses/cmps277/fall11/01. Lecture #11 CMPS 277 Principles of Database Systems https://courses.soe.ucsc.edu/courses/cmps277/fall11/01 Lecture #11 1 Limitations of Relational Algebra & Relational Calculus Outline: Relational Algebra and Relational

More information

Encyclopedia of Database Systems, Editors-in-chief: Özsu, M. Tamer; Liu, Ling, Springer, MAINTENANCE OF RECURSIVE VIEWS. Suzanne W.

Encyclopedia of Database Systems, Editors-in-chief: Özsu, M. Tamer; Liu, Ling, Springer, MAINTENANCE OF RECURSIVE VIEWS. Suzanne W. Encyclopedia of Database Systems, Editors-in-chief: Özsu, M. Tamer; Liu, Ling, Springer, 2009. MAINTENANCE OF RECURSIVE VIEWS Suzanne W. Dietrich Arizona State University http://www.public.asu.edu/~dietrich

More information

Plan of the lecture. G53RDB: Theory of Relational Databases Lecture 14. Example. Datalog syntax: rules. Datalog query. Meaning of Datalog rules

Plan of the lecture. G53RDB: Theory of Relational Databases Lecture 14. Example. Datalog syntax: rules. Datalog query. Meaning of Datalog rules Plan of the lecture G53RDB: Theory of Relational Databases Lecture 14 Natasha Alechina School of Computer Science & IT nza@cs.nott.ac.uk More Datalog: Safe queries Datalog and relational algebra Recursive

More information

Datalog. Susan B. Davidson. CIS 700: Advanced Topics in Databases MW 1:30-3 Towne 309

Datalog. Susan B. Davidson.   CIS 700: Advanced Topics in Databases MW 1:30-3 Towne 309 Datalog Susan B. Davidson CIS 700: Advanced Topics in Databases MW 1:30-3 Towne 309 http://www.cis.upenn.edu/~susan/cis700/homepage.html 2017 A. Alawini, S. Davidson Homework for this week Sign up to present

More information

Ontology and Database Systems: Foundations of Database Systems

Ontology and Database Systems: Foundations of Database Systems Ontology and Database Systems: Foundations of Database Systems Part 5: Datalog Werner Nutt Faculty of Computer Science European Master in Computational Logic A.Y. 2015/2016 Motivation Relational Calculus

More information

Learning Rules. Learning Rules from Decision Trees

Learning Rules. Learning Rules from Decision Trees Learning Rules In learning rules, we are interested in learning rules of the form: if A 1 A 2... then C where A 1, A 2,... are the preconditions/constraints/body/ antecedents of the rule and C is the postcondition/head/

More information

CSE 344 JANUARY 26 TH DATALOG

CSE 344 JANUARY 26 TH DATALOG CSE 344 JANUARY 26 TH DATALOG ADMINISTRATIVE MINUTIAE HW3 and OQ3 out HW3 due next Friday OQ3 due next Wednesday HW4 out next week: on Datalog Midterm reminder: Feb 9 th RELATIONAL ALGEBRA Set-at-a-time

More information

CS521 \ Notes for the Final Exam

CS521 \ Notes for the Final Exam CS521 \ Notes for final exam 1 Ariel Stolerman Asymptotic Notations: CS521 \ Notes for the Final Exam Notation Definition Limit Big-O ( ) Small-o ( ) Big- ( ) Small- ( ) Big- ( ) Notes: ( ) ( ) ( ) ( )

More information

Database Theory VU , SS Introduction to Datalog. Reinhard Pichler. Institute of Logic and Computation DBAI Group TU Wien

Database Theory VU , SS Introduction to Datalog. Reinhard Pichler. Institute of Logic and Computation DBAI Group TU Wien Database Theory Database Theory VU 181.140, SS 2018 2. Introduction to Datalog Reinhard Pichler Institute of Logic and Computation DBAI Group TU Wien 13 March, 2018 Pichler 13 March, 2018 Page 1 Database

More information

Lecture 9: Datalog with Negation

Lecture 9: Datalog with Negation CS 784: Foundations of Data Management Spring 2017 Instructor: Paris Koutris Lecture 9: Datalog with Negation In this lecture we will study the addition of negation to Datalog. We start with an example.

More information

A SQL-Middleware Unifying Why and Why-Not Provenance for First-Order Queries

A SQL-Middleware Unifying Why and Why-Not Provenance for First-Order Queries A SQL-Middleware Unifying Why and Why-Not Provenance for First-Order Queries Seokki Lee Sven Köhler Bertram Ludäscher Boris Glavic Illinois Institute of Technology. {slee95@hawk.iit.edu, bglavic@iit.edu}

More information

Range Restriction for General Formulas

Range Restriction for General Formulas Range Restriction for General Formulas 1 Range Restriction for General Formulas Stefan Brass Martin-Luther-Universität Halle-Wittenberg Germany Range Restriction for General Formulas 2 Motivation Deductive

More information

FOUNDATIONS OF DATABASES AND QUERY LANGUAGES

FOUNDATIONS OF DATABASES AND QUERY LANGUAGES FOUNDATIONS OF DATABASES AND QUERY LANGUAGES Lecture 14: Database Theory in Practice Markus Krötzsch TU Dresden, 20 July 2015 Overview 1. Introduction Relational data model 2. First-order queries 3. Complexity

More information

( D. Θ n. ( ) f n ( ) D. Ο%

( D. Θ n. ( ) f n ( ) D. Ο% CSE 0 Name Test Spring 0 Multiple Choice. Write your answer to the LEFT of each problem. points each. The time to run the code below is in: for i=n; i>=; i--) for j=; j

More information

University of Cape Town

University of Cape Town /o,! )' LNEAR LBRARY 0068 1611 ll! 1111111 1 l f Department of Computer Science University of Cape Town Semantic Optimisation in Datalog Programs by Mark P.Wassell A Thesis Prepared Under the Supervision

More information

Datalog Recursive SQL LogicBlox

Datalog Recursive SQL LogicBlox CS 500: Fundamentals of Databases Datalog Recursive SQL LogicBlox supplementary material: Foundations of Databases by Abiteboul, Hull, Vianu, Ch. 12 class notes slides are based on teaching materials by

More information

Efficiently Computing Provenance Graphs for Queries with Negation

Efficiently Computing Provenance Graphs for Queries with Negation Efficiently Computing Provenance Graphs for Queries with Negation Seokki Lee, Sven Köhler, Bertram Ludäscher, Boris Glavic IIT DB Group Technical Report IIT/CS-DB-26-3 26- http://www.cs.iit.edu/ dbgroup/

More information

Expressive capabilities description languages and query rewriting algorithms q

Expressive capabilities description languages and query rewriting algorithms q The Journal of Logic Programming 43 (2000) 75±122 www.elsevier.com/locate/jlpr Expressive capabilities description languages and query rewriting algorithms q Vasilis Vassalos a, *, Yannis Papakonstantinou

More information

Announcements. What is Datalog? Why Do We Learn Datalog? Database Systems CSE 414. Midterm. Datalog. Lecture 13: Datalog (Ch

Announcements. What is Datalog? Why Do We Learn Datalog? Database Systems CSE 414. Midterm. Datalog. Lecture 13: Datalog (Ch Announcements Database Systems CSE 414 Lecture 13: Datalog (Ch 5.3 5.4) HW3 is due Tomorrow WQ4 moved to Sunday it will be useful review for the midterm finish it early if you have time Midterm on Friday,

More information

Algorithms for Finding Dominators in Directed Graphs

Algorithms for Finding Dominators in Directed Graphs Department of Computer Science Aarhus University Master s Thesis Algorithms for Finding Dominators in Directed Graphs Author: Henrik Knakkegaard Christensen 20082178 Supervisor: Gerth Støling Brodal January

More information

Foundations of AI. 9. Predicate Logic. Syntax and Semantics, Normal Forms, Herbrand Expansion, Resolution

Foundations of AI. 9. Predicate Logic. Syntax and Semantics, Normal Forms, Herbrand Expansion, Resolution Foundations of AI 9. Predicate Logic Syntax and Semantics, Normal Forms, Herbrand Expansion, Resolution Wolfram Burgard, Andreas Karwath, Bernhard Nebel, and Martin Riedmiller 09/1 Contents Motivation

More information

The NEXT Framework for Logical XQuery Optimization

The NEXT Framework for Logical XQuery Optimization The NEXT Framework for Logical XQuery Optimization Alin Deutsch Yannis Papakonstantinou Yu Xu University of California, San Diego deutsch,yannis,yxu @cs.ucsd.edu Abstract Classical logical optimization

More information

Safe Stratified Datalog With Integer Order Does not Have Syntax

Safe Stratified Datalog With Integer Order Does not Have Syntax Safe Stratified Datalog With Integer Order Does not Have Syntax Alexei P. Stolboushkin Department of Mathematics UCLA Los Angeles, CA 90024-1555 aps@math.ucla.edu Michael A. Taitslin Department of Computer

More information

n 2 C. Θ n ( ) Ο f ( n) B. n 2 Ω( n logn)

n 2 C. Θ n ( ) Ο f ( n) B. n 2 Ω( n logn) CSE 0 Name Test Fall 0 Last Digits of Mav ID # Multiple Choice. Write your answer to the LEFT of each problem. points each. The time to find the maximum of the n elements of an integer array is in: A.

More information

( ) ( ) C. " 1 n. ( ) $ f n. ( ) B. " log( n! ) ( ) and that you already know ( ) ( ) " % g( n) ( ) " #&

( ) ( ) C.  1 n. ( ) $ f n. ( ) B.  log( n! ) ( ) and that you already know ( ) ( )  % g( n) ( )  #& CSE 0 Name Test Summer 008 Last 4 Digits of Mav ID # Multiple Choice. Write your answer to the LEFT of each problem. points each. The time for the following code is in which set? for (i=0; i

More information

Prolog Programming. Lecture Module 8

Prolog Programming. Lecture Module 8 Prolog Programming Lecture Module 8 Prolog Language Prolog is unique in its ability to infer facts from the given facts and rules. In Prolog, an order of clauses in the program and goals in the body of

More information

Implementação de Linguagens 2016/2017

Implementação de Linguagens 2016/2017 Implementação de Linguagens Ricardo Rocha DCC-FCUP, Universidade do Porto ricroc @ dcc.fc.up.pt Ricardo Rocha DCC-FCUP 1 Logic Programming Logic programming languages, together with functional programming

More information

( ) 1 B. 1. Suppose f x

( ) 1 B. 1. Suppose f x CSE Name Test Spring Last Digits of Student ID Multiple Choice. Write your answer to the LEFT of each problem. points each is a monotonically increasing function. Which of the following approximates the

More information

Lecture 1: Conjunctive Queries

Lecture 1: Conjunctive Queries CS 784: Foundations of Data Management Spring 2017 Instructor: Paris Koutris Lecture 1: Conjunctive Queries A database schema R is a set of relations: we will typically use the symbols R, S, T,... to denote

More information

A Retrospective on Datalog 1.0

A Retrospective on Datalog 1.0 A Retrospective on Datalog 1.0 Phokion G. Kolaitis UC Santa Cruz and IBM Research - Almaden Datalog 2.0 Vienna, September 2012 2 / 79 A Brief History of Datalog In the beginning of time, there was E.F.

More information

Datalog. Rules Programs Negation

Datalog. Rules Programs Negation Datalog Rules Programs Negation 1 Review of Logical If-Then Rules body h(x, ) :- a(y, ) & b(z, ) & head subgoals The head is true if all the subgoals are true. 2 Terminology Head and subgoals are atoms.

More information

Arbori Starter Manual Eugene Perkov

Arbori Starter Manual Eugene Perkov Arbori Starter Manual Eugene Perkov What is Arbori? Arbori is a query language that takes a parse tree as an input and builds a result set 1 per specifications defined in a query. What is Parse Tree? A

More information

Introduction to Data Management CSE 344. Lecture 14: Datalog (guest lecturer Dan Suciu)

Introduction to Data Management CSE 344. Lecture 14: Datalog (guest lecturer Dan Suciu) Introduction to Data Management CSE 344 Lecture 14: Datalog (guest lecturer Dan Suciu) CSE 344 - Winter 2017 1 Announcements WQ 4 and HW 4 due on Thursday Midterm next Monday in class This week: Today:

More information

CSE 344 JANUARY 29 TH DATALOG

CSE 344 JANUARY 29 TH DATALOG CSE 344 JANUARY 29 TH DATALOG ADMINISTRATIVE MINUTIAE HW3 due Friday OQ due Wednesday HW4 out Wednesday Exam next Friday 3:30-5:00 WHAT IS DATALOG? Another query language for relational model Designed

More information

CS 310 Advanced Data Structures and Algorithms

CS 310 Advanced Data Structures and Algorithms CS 0 Advanced Data Structures and Algorithms Weighted Graphs July 0, 07 Tong Wang UMass Boston CS 0 July 0, 07 / Weighted Graphs Each edge has a weight (cost) Edge-weighted graphs Mostly we consider only

More information

Supporting Positional Predicates in Efficient XPath Axis Evaluation for DOM Data Structures

Supporting Positional Predicates in Efficient XPath Axis Evaluation for DOM Data Structures Supporting Positional Predicates in Efficient XPath Axis Evaluation for DOM Data Structures Torsten Grust Jan Hidders Philippe Michiels Roel Vercammen 1 July 7, 2004 Maurice Van Keulen 1 Philippe Michiels

More information

yqgm_std_rules documentation (Version 1)

yqgm_std_rules documentation (Version 1) yqgm_std_rules documentation (Version 1) Feng Shao Warren Wong Tony Novak Computer Science Department Cornell University Copyright (C) 2003-2005 Cornell University. All Rights Reserved. 1. Introduction

More information

Access Patterns (Extended Version) Chen Li. Department of Computer Science, Stanford University, CA Abstract

Access Patterns (Extended Version) Chen Li. Department of Computer Science, Stanford University, CA Abstract Computing Complete Answers to Queries in the Presence of Limited Access Patterns (Extended Version) Chen Li Department of Computer Science, Stanford University, CA 94305 chenli@db.stanford.edu Abstract

More information

XDO2: AN XML DEDUCTIVE OBJECT- ORIENTED QUERY LANGUAGE

XDO2: AN XML DEDUCTIVE OBJECT- ORIENTED QUERY LANGUAGE XDO2: AN XML DEDUCTIVE OBJECT- ORIENTED QUERY LANGUAGE ZHANG WEI NATIONAL UNIVERSITY OF SINGAPORE 2004 XDO2: AN XML DEDUCTIVE OBJECT- ORIENTED QUERY LANGUAGE ZHANG WEI (B.Comp.(Hons.) NUS) A THESIS SUBMITTED

More information

FOUNDATIONS OF SEMANTIC WEB TECHNOLOGIES

FOUNDATIONS OF SEMANTIC WEB TECHNOLOGIES FOUNDATIONS OF SEMANTIC WEB TECHNOLOGIES RDFS Rule-based Reasoning Sebastian Rudolph Dresden, 16 April 2013 Content Overview & XML 9 APR DS2 Hypertableau II 7 JUN DS5 Introduction into RDF 9 APR DS3 Tutorial

More information

Distributed RDFS Reasoning Over Structured Overlay Networks

Distributed RDFS Reasoning Over Structured Overlay Networks J Data Semant (2013) 2:189 227 DOI 10.1007/s13740-013-0018-0 ORIGINAL ARTICLE Distributed RDFS Reasoning Over Structured Overlay Networks Zoi Kaoudi Manolis Koubarakis Received: 23 February 2012 / Revised:

More information

Mining Frequent Patterns without Candidate Generation

Mining Frequent Patterns without Candidate Generation Mining Frequent Patterns without Candidate Generation Outline of the Presentation Outline Frequent Pattern Mining: Problem statement and an example Review of Apriori like Approaches FP Growth: Overview

More information

Query Processing & Optimization

Query Processing & Optimization Query Processing & Optimization 1 Roadmap of This Lecture Overview of query processing Measures of Query Cost Selection Operation Sorting Join Operation Other Operations Evaluation of Expressions Introduction

More information

COMPILATION AND EVALUATION OF NESTED LINEAR RECURSIONS: A DEDUCTIVE DATABASE APPROACH

COMPILATION AND EVALUATION OF NESTED LINEAR RECURSIONS: A DEDUCTIVE DATABASE APPROACH COMPILATION AND EVALUATION OF NESTED LINEAR RECURSIONS: A DEDUCTIVE DATABASE APPROACH Tong Lu B.S., East China Normal University, Shanghai, China, 1990 A THESISUBMITTED IN PARTIAL FULFILLMENT OF THE REQUIREMENTS

More information

Lecture 3: Graphs and flows

Lecture 3: Graphs and flows Chapter 3 Lecture 3: Graphs and flows Graphs: a useful combinatorial structure. Definitions: graph, directed and undirected graph, edge as ordered pair, path, cycle, connected graph, strongly connected

More information

QueryPIE: Hybrid Reasoning With The OWL RL Rules

QueryPIE: Hybrid Reasoning With The OWL RL Rules Undefined 0 (2012) 1 0 1 IOS Press QueryPIE: Hybrid Reasoning With The OWL RL Rules Jacopo Urbani a,, Robert Piro b Frank van Harmelen a Henri Bal a a Department of Computer Science, Vrije Universiteit

More information

Pushing Semantics inside Recursion: A General Framework for. Semantic Optimization of Recursive Queries

Pushing Semantics inside Recursion: A General Framework for. Semantic Optimization of Recursive Queries Appears in: ICDE'95. Pushing Semantics inside Recursion: A General Framework for Semantic Optimization of Recursive Queries Laks V.S. Lakshmanan Dept. of Comp. Sci. Concordia University Montreal, Canada

More information

Logic Programming and Resolution Lecture notes for INF3170/4171

Logic Programming and Resolution Lecture notes for INF3170/4171 Logic Programming and Resolution Lecture notes for INF3170/4171 Leif Harald Karlsen Autumn 2015 1 Introduction This note will explain the connection between logic and computer programming using Horn Clauses

More information

contribution of this paper is to demonstrate that rule orderings can also improve eciency by reducing the number of rule applications. In eect, since

contribution of this paper is to demonstrate that rule orderings can also improve eciency by reducing the number of rule applications. In eect, since Rule Ordering in Bottom-Up Fixpoint Evaluation of Logic Programs Raghu Ramakrishnan Divesh Srivastava S. Sudarshan y Computer Sciences Department, University of Wisconsin-Madison, WI 53706, U.S.A. Abstract

More information

Posets, graphs and algebras: a case study for the fine-grained complexity of CSP s

Posets, graphs and algebras: a case study for the fine-grained complexity of CSP s Posets, graphs and algebras: a case study for the fine-grained complexity of CSP s Part 1: Preliminaries on Complexity and CSP s Benoit Larose 1 2 1 Department of Mathematics and Statistics Concordia University,

More information

D. Θ nlogn ( ) D. Ο. ). Which of the following is not necessarily true? . Which of the following cannot be shown as an improvement? D.

D. Θ nlogn ( ) D. Ο. ). Which of the following is not necessarily true? . Which of the following cannot be shown as an improvement? D. CSE 0 Name Test Fall 00 Last Digits of Mav ID # Multiple Choice. Write your answer to the LEFT of each problem. points each. The time to convert an array, with priorities stored at subscripts through n,

More information

( ) D. Θ ( ) ( ) Ο f ( n) ( ) Ω. C. T n C. Θ. B. n logn Ο

( ) D. Θ ( ) ( ) Ο f ( n) ( ) Ω. C. T n C. Θ. B. n logn Ο CSE 0 Name Test Fall 0 Multiple Choice. Write your answer to the LEFT of each problem. points each. The expected time for insertion sort for n keys is in which set? (All n! input permutations are equally

More information

6.001 Notes: Section 4.1

6.001 Notes: Section 4.1 6.001 Notes: Section 4.1 Slide 4.1.1 In this lecture, we are going to take a careful look at the kinds of procedures we can build. We will first go back to look very carefully at the substitution model,

More information

Logical Query Languages. Motivation: 1. Logical rules extend more naturally to. recursive queries than does relational algebra. Used in SQL recursion.

Logical Query Languages. Motivation: 1. Logical rules extend more naturally to. recursive queries than does relational algebra. Used in SQL recursion. Logical Query Languages Motivation: 1. Logical rules extend more naturally to recursive queries than does relational algebra. Used in SQL recursion. 2. Logical rules form the basis for many information-integration

More information

Knowledge Representation. CS 486/686: Introduction to Artificial Intelligence

Knowledge Representation. CS 486/686: Introduction to Artificial Intelligence Knowledge Representation CS 486/686: Introduction to Artificial Intelligence 1 Outline Knowledge-based agents Logics in general Propositional Logic& Reasoning First Order Logic 2 Introduction So far we

More information

Constraint Solving. Systems and Internet Infrastructure Security

Constraint Solving. Systems and Internet Infrastructure Security Systems and Internet Infrastructure Security Network and Security Research Center Department of Computer Science and Engineering Pennsylvania State University, University Park PA Constraint Solving Systems

More information

Negation wrapped inside a recursion makes no. separated, there can be ambiguity about what. the rules mean, and some one meaning must

Negation wrapped inside a recursion makes no. separated, there can be ambiguity about what. the rules mean, and some one meaning must Stratied Negation Negation wrapped inside a recursion makes no sense. Even when negation and recursion are separated, there can be ambiguity about what the rules mean, and some one meaning must be selected.

More information

Midterm. Introduction to Data Management CSE 344. Datalog. What is Datalog? Why Do We Learn Datalog? Why Do We Learn Datalog? Lecture 13: Datalog

Midterm. Introduction to Data Management CSE 344. Datalog. What is Datalog? Why Do We Learn Datalog? Why Do We Learn Datalog? Lecture 13: Datalog Midterm Introduction to Data Management CSE 344 Lecture 13: Datalog Guest lecturer: Laurel Orr Monday, February 8 th in class Content Lectures 1 through 13 Homework 1 through 4 (due Feb 10) Webquiz 1 through

More information

Query Evaluation Strategies

Query Evaluation Strategies Introduction to Search Engine Technology Term-at-a-Time and Document-at-a-Time Evaluation Ronny Lempel Yahoo! Research (Many of the following slides are courtesy of Aya Soffer and David Carmel, IBM Haifa

More information

QueryPIE: Hybrid Reasoning With The OWL RL Rules

QueryPIE: Hybrid Reasoning With The OWL RL Rules Undefined 0 (2012) 1 0 1 IOS Press QueryPIE: Hybrid Reasoning With The OWL RL Rules Jacopo Urbani a,, Robert Piro b Frank van Harmelen a Henri Bal a a Department of Computer Science, Vrije Universiteit

More information

Trees and Tree Traversal

Trees and Tree Traversal Trees and Tree Traversal Material adapted courtesy of Prof. Dave Matuszek at UPENN Definition of a tree A tree is a node with a value and zero or more children Depending on the needs of the program, the

More information

Query Containment for Data Integration Systems

Query Containment for Data Integration Systems Query Containment for Data Integration Systems Todd Millstein University of Washington Seattle, Washington todd@cs.washington.edu Alon Levy University of Washington Seattle, Washington alon@cs.washington.edu

More information

Knowledge Representation and Reasoning Logics for Artificial Intelligence

Knowledge Representation and Reasoning Logics for Artificial Intelligence Knowledge Representation and Reasoning Logics for Artificial Intelligence Stuart C. Shapiro Department of Computer Science and Engineering and Center for Cognitive Science University at Buffalo, The State

More information

n 2 ( ) ( ) Ο f ( n) ( ) Ω B. n logn Ο

n 2 ( ) ( ) Ο f ( n) ( ) Ω B. n logn Ο CSE 220 Name Test Fall 20 Last 4 Digits of Mav ID # Multiple Choice. Write your answer to the LEFT of each problem. 4 points each. The time to compute the sum of the n elements of an integer array is in:

More information

Answering Queries with Useful Bindings

Answering Queries with Useful Bindings Answering Queries with Useful Bindings CHEN LI University of California at Irvine and EDWARD CHANG University of California, Santa Barbara In information-integration systems, sources may have diverse and

More information

Graph Algorithms Using Depth First Search

Graph Algorithms Using Depth First Search Graph Algorithms Using Depth First Search Analysis of Algorithms Week 8, Lecture 1 Prepared by John Reif, Ph.D. Distinguished Professor of Computer Science Duke University Graph Algorithms Using Depth

More information

Dynamically Ordered Semi-Naive Evaluation of Recursive Queries

Dynamically Ordered Semi-Naive Evaluation of Recursive Queries Applications NORTH- HOLLAND Dynamically Ordered Semi-Naive Evaluation of Recursive Queries KI-HYUNG HONG* YOON-JOON LEE and KYU-YOUNG WHANG Department of Computer Science, Korea Advanced Institute of Science

More information

Database Theory: Datalog, Views

Database Theory: Datalog, Views Database Theory: Datalog, Views CS 645 Mar 8, 2006 Some slide content courtesy of Ramakrishnan & Gehrke, Dan Suciu, Ullman & Widom 1 TODAY: Coming lectures Adding recursion: datalog Summary of Containment

More information

Parser: SQL parse tree

Parser: SQL parse tree Jinze Liu Parser: SQL parse tree Good old lex & yacc Detect and reject syntax errors Validator: parse tree logical plan Detect and reject semantic errors Nonexistent tables/views/columns? Insufficient

More information

Knowledge-Based Systems and Deductive Databases

Knowledge-Based Systems and Deductive Databases Knowledge-Based Systems and Deductive Databases Wolf-Tilo Balke Christoph Lofi Institut für Informationssysteme Technische Universität Braunschweig http://www.ifis.cs.tu-bs.de Next Lecture 7.1 Implementation

More information

Monadic Datalog Containment on Trees

Monadic Datalog Containment on Trees Monadic Datalog Containment on Trees André Frochaux 1, Martin Grohe 2, and Nicole Schweikardt 1 1 Goethe-Universität Frankfurt am Main, {afrochaux,schweika}@informatik.uni-frankfurt.de 2 RWTH Aachen University,

More information

Logic: TD as search, Datalog (variables)

Logic: TD as search, Datalog (variables) Logic: TD as search, Datalog (variables) Computer Science cpsc322, Lecture 23 (Textbook Chpt 5.2 & some basic concepts from Chpt 12) June, 8, 2017 CPSC 322, Lecture 23 Slide 1 Lecture Overview Recap Top

More information

Trees. 3. (Minimally Connected) G is connected and deleting any of its edges gives rise to a disconnected graph.

Trees. 3. (Minimally Connected) G is connected and deleting any of its edges gives rise to a disconnected graph. Trees 1 Introduction Trees are very special kind of (undirected) graphs. Formally speaking, a tree is a connected graph that is acyclic. 1 This definition has some drawbacks: given a graph it is not trivial

More information

SORTING AND SELECTION

SORTING AND SELECTION 2 < > 1 4 8 6 = 9 CHAPTER 12 SORTING AND SELECTION ACKNOWLEDGEMENT: THESE SLIDES ARE ADAPTED FROM SLIDES PROVIDED WITH DATA STRUCTURES AND ALGORITHMS IN JAVA, GOODRICH, TAMASSIA AND GOLDWASSER (WILEY 2016)

More information

A NETWORK OF COMMUNICATING LOGIC PROGRAMS AND ITS SEMANTICS. Susumu Yamasaki. Department of Information Science, Kyoto University Sakyo, Kyoto, Japan

A NETWORK OF COMMUNICATING LOGIC PROGRAMS AND ITS SEMANTICS. Susumu Yamasaki. Department of Information Science, Kyoto University Sakyo, Kyoto, Japan A NETWORK OF COMMUNICATING LOGIC PROGRAMS AND ITS SEMANTICS Susumu Yamasaki Department of Information Science, Kyoto University Sakyo, Kyoto, Japan ABSTRACT In this paper, a network of communicating loqic

More information

Plan for today. Query Processing/Optimization. Parsing. A query s trip through the DBMS. Validation. Logical plan

Plan for today. Query Processing/Optimization. Parsing. A query s trip through the DBMS. Validation. Logical plan Plan for today Query Processing/Optimization CPS 216 Advanced Database Systems Overview of query processing Query execution Query plan enumeration Query rewrite heuristics Query rewrite in DB2 2 A query

More information

CS261: Problem Set #1

CS261: Problem Set #1 CS261: Problem Set #1 Due by 11:59 PM on Tuesday, April 21, 2015 Instructions: (1) Form a group of 1-3 students. You should turn in only one write-up for your entire group. (2) Turn in your solutions by

More information

Relational Databases

Relational Databases Relational Databases Jan Chomicki University at Buffalo Jan Chomicki () Relational databases 1 / 49 Plan of the course 1 Relational databases 2 Relational database design 3 Conceptual database design 4

More information

11/6/17. Outline. FP Foundations, Scheme. Imperative Languages. Functional Programming. Mathematical Foundations. Mathematical Foundations

11/6/17. Outline. FP Foundations, Scheme. Imperative Languages. Functional Programming. Mathematical Foundations. Mathematical Foundations Outline FP Foundations, Scheme In Text: Chapter 15 Mathematical foundations Functional programming λ-calculus LISP Scheme 2 Imperative Languages We have been discussing imperative languages C/C++, Java,

More information

Faster and Dynamic Algorithms For Maximal End-Component Decomposition And Related Graph Problems In Probabilistic Verification

Faster and Dynamic Algorithms For Maximal End-Component Decomposition And Related Graph Problems In Probabilistic Verification Faster and Dynamic Algorithms For Maximal End-Component Decomposition And Related Graph Problems In Probabilistic Verification Krishnendu Chatterjee Monika Henzinger Abstract We present faster and dynamic

More information

An introduction to logic programming with Prolog

An introduction to logic programming with Prolog An introduction to logic programming with Prolog Dr. Constantinos Constantinides Department of Computer Science and Software Engineering Concordia University A running example: A family genealogy tree

More information

Element Algebra. 1 Introduction. M. G. Manukyan

Element Algebra. 1 Introduction. M. G. Manukyan Element Algebra M. G. Manukyan Yerevan State University Yerevan, 0025 mgm@ysu.am Abstract. An element algebra supporting the element calculus is proposed. The input and output of our algebra are xdm-elements.

More information

This lecture. Lecture 6: Search 5. Other Time and Space Variations of A* Victor R. Lesser. RBFS - Recursive Best-First Search Algorithm

This lecture. Lecture 6: Search 5. Other Time and Space Variations of A* Victor R. Lesser. RBFS - Recursive Best-First Search Algorithm Lecture 6: Search 5 Victor R. Lesser CMPSCI 683 Fall 2010 This lecture Other Time and Space Variations of A* Finish off RBFS SMA* Anytime A* RTA* (maybe if have time) RBFS - Recursive Best-First Search

More information