Implementation of a Database System with Boolean Algebra Constraints András Salamon University of Nebraska - Lincoln

Implementation of a Database System with Boolean Algebra Constraints András Salamon University of Nebraska - Lincoln

University of Nebraska - Lincoln DigitalCommons@University of Nebraska - Lincoln Computer Science and Engineering: Theses, Computer Science and Engineering, Department of Dissertations, and Student Research 5-1998 Implementation of a Database System with Boolean Algebra Constraints András Salamon University of Nebraska - Lincoln Follow this and additional works at: https://digitalcommons.unl.edu/computerscidiss Part of the Computer Engineering Commons Salamon, András, "Implementation of a Database System with Boolean Algebra Constraints" (1998). Computer Science and Engineering: Theses, Dissertations, and Student Research. 141. https://digitalcommons.unl.edu/computerscidiss/141 This Article is brought to you for free and open access by the Computer Science and Engineering, Department of at DigitalCommons@University of Nebraska - Lincoln. It has been accepted for inclusion in Computer Science and Engineering: Theses, Dissertations, and Student Research by an authorized administrator of DigitalCommons@University of Nebraska - Lincoln. Implementation of a Database System with Bo olean Algebra Constraints by Andras Salamon A THESIS Presented to the Faculty of The Graduate College at the University of Nebraska In Partial Fulllment of Requirements For the Degree of Master of Science Ma jor Computer Science Under the Sup ervision of Professor Peter Z Revesz Lincoln Nebraska May Implementation of a Database System with Bo olean Algebra Constraints Andras Salamon MS University of NebraskaLincoln Advisor Peter Z Revesz This thesis describ es an implementation of a constraint database system with constraints over a Bo olean Algebra of sets The system allows within the input database as well as the queries equality subsetequality and monotone inequality constraints b etween Bo olean Algebra terms built up using the op erators of union intersection and complement Hence the new system extends the earlier DISCO system which only allowed equality and subsetequality constraints b etween Bo olean algebra variables and constants The new system allows Datalog with Bo olean Algebra constraints as the query lan guage The implementation includes an extension of Naive and SemiNaive evaluation metho ds for Datalog programs and algebraic optimization techniques for relational algebra formulas The thesis also includes three example applications of the new system in the area of family tree genealogy genome map assembly and twoplayer game analysis In each of these three cases the optimization provides a signicant improvement in the running time of the queries ACKNOWLEDGMENTS I would like to express my deep est appreciation to my advisor Dr Peter Revesz for his guidance and encouragement on this pro ject I also thank Dr JeanCamille Birget and Dr Spyros Magliveras for serving on my advisory committee and for their time I would like to dedicate my thesis for the memories of my grandfathers Karoly Nemeth and Sandor Salamon Contents Datalog with Bo olean Algebra Constraints Bo olean Algebra Syntax of Datalog Queries with Bo olean Constraints Quantier elimination Elimination metho d for equality constraints Elimination metho d for precedence and monotone inequality constraints Naive and Seminaive evaluation metho ds Naive metho d SemiNaive metho d EVAL function EVAL INCR function Implementation The implemented Bo olean Algebra Sets Implemented quantier elimination metho ds Hardware and Software Java program Packages Relational Algebra Formulas Relational Algebra Formulas Converting a Rule Converting a Relation Optimization of Relational Algebra Formulas Algebraic Manipulation Laws Principles The Algorithm Calculating multiple joins Users Manual Switches Commands Input le format Examples Ancestors example The problem The input database The Datalog program The output database Execution complexity Runtime results Genome Map The problem Solution Concrete examples Unavoidable Sets Problem Solution Example Multisets Introduction Extension of the program An example The problem The solution Concrete example Further Work Introduction Although among the database systems the relational database systems are the wide spreadest systems at this moment constraint databases is a very p ersp ective approach to change them Constraint databases can contain quantierfree rstorder formulas With the help of these formulas constraint databases are able to express more than traditional relational databases For instance one tuple can contain innite number of traditional tuples Constraint database systems can b e categorized according to the type of the con straint Some of the wellknown constraint types are for instance linear constraints p olynomial constraints integer gap constraints In this system the constraints are Bo olean Constraint hence the name of the system is Datalog with Boolean Constraint This system extends the p ossibilities of a previous system D atalog with Integer Set COnstraint DISCO which was im plemented in the department DISCO system allows only subsetequality constraints b etween Bo olean Algebra variables and constants this system allows subsetequality equality and monotone inequality constraints b etween Bo olean Algebra terms A description of the DISCO system can b e found in First there is a theoretical overview Chapter based on then a chapter ab out the current implementation Chapter what kind of Bo olean Algebra is implemented the main structure of the program Because one really imp ortant part of the program is related to Relational Alge bra Chapter describ es the Relational Algebra formulas how to store convert and optimize these formulas The name of the implemented program is GreenCoat Chapter gives informa tion ab out the user interface of the program The predecessor of this program was implemented in the previous semester by Song Liu and I Chapter describ es some examples and try to demonstrate the p ossibilities of the system The system also supp orts the use of some multiset op erators Chapter contains more information ab out the multisets Chapter Datalog with Bo olean Algebra Constraints In this chapter I give an overview of the Datalog with Boolean Algebra Constraint This was introduced by Kanellakis et al and extended by Peter Z Revesz First I present the basic denitions necessary to understand the concept Later I dene the syntax metho ds Bo olean Algebra The following denition is taken from more information can b e found ab out Bo olean Algebras in A Bo olean algebra is a sextuple where is the domain set and are binary op erators is a unary op erator and are two sp ecial elements of the domain They are also called zero and identity elements Every Bo olean algebra satises the following axioms x y x y y x x y y x x y z x y x z x y z x y x z x x x x x x x x Bo olean term All the elements of including and are Bo olean terms All the elements of V set of variables and all the elements of C where C is the set of constants except and are Bo olean terms If t and t are b oth Bo olean terms 1 2 than t t t t t are also Bo olean terms 1 2 1 2 1 Precedence constraint If a constraint has the following form x y where x y V C then we call this constraint precedence constraint and denote with x y Monotone Bo olean function A g Bo olean function is monotone if x i y i n g x x g y y i 1 n 1 n Monotone inequality constraint g x x is a monotone inequality 1 n constraint if g is a monotone Bo olean function The following is a wellknown fact for Bo olean terms Prop osition Every t Boolean term can be converted to disjunctive normal form DNF W a a a n 1 2 tz z z ta a a z z z 1 2 n 1 2 n n 1 2 n a f g 0 0 where z denotes z and z denotes z Syntax of Datalog Queries with Bo olean Con straints The following basic denitions can also b e found in Every Datalog program contains a set of facts constraint tuples and a set of rules The facts can b e seen as sp ecial rules as well The general form of the facts is R x x f x x g x x g x x 1 k 1 k 1 1 k l 1 k where f and g i l are Bo olean terms i The general

View Full Text

Details

  • File Type
    pdf
  • Upload Time
    -
  • Content Languages
    English
  • Upload User
    Anonymous/Not logged-in
  • File Pages
    73 Page
  • File Size
    -

Download

Channel Download Status
Express Download Enable

Copyright

We respect the copyrights and intellectual property rights of all users. All uploaded documents are either original works of the uploader or authorized works of the rightful owners.

  • Not to be reproduced or distributed without explicit permission.
  • Not used for commercial purposes outside of approved use cases.
  • Not used to infringe on the rights of the original creators.
  • If you believe any content infringes your copyright, please contact us immediately.

Support

For help with questions, suggestions, or problems, please contact us