On the Use of Automata Techniques to Decide Satisfiability Mia Minnes May 3, 2005.

Slides:



Advertisements
Similar presentations
Model Checking Lecture 3. Specification Automata Syntax, given a set A of atomic observations: Sfinite set of states S 0 Sset of initial states S S transition.
Advertisements

Model Checking Lecture 2. Three important decisions when choosing system properties: 1automata vs. logic 2branching vs. linear time 3safety vs. liveness.
PARIXIT PRASAD December 4, 2013 Parixit Prasad | CSA - IISC 1 Deciding Presburger Arithmetic Using Automata Department of Computer Science and Automaton.
NP-Hard Nattee Niparnan.
CS 267: Automated Verification Lecture 8: Automata Theoretic Model Checking Instructor: Tevfik Bultan.
Lecture 24 MAS 714 Hartmut Klauck
Automatic Verification Book: Chapter 6. What is verification? Traditionally, verification means proof of correctness automatic: model checking deductive:
An Introduction to the Model Verifier verds Wenhui Zhang September 15 th, 2010.
Linked List Implementation class List { private List next; private Object data; private static List root; private static int size; public static void addNew(Object.
Timed Automata.
CIS 540 Principles of Embedded Computation Spring Instructor: Rajeev Alur
January 5, 2015CS21 Lecture 11 CS21 Decidability and Tractability Lecture 1 January 5, 2015.
Computability and Complexity 5-1 Classifying Problems Computability and Complexity Andrei Bulatov.
1 Introduction to Computability Theory Lecture12: Decidable Languages Prof. Amos Israeli.
Decision Procedures for Presburger Arithmetic Presented by Constantinos Bartzis.
1 Deciding separation formulas with SAT Ofer Strichman Sanjit A. Seshia Randal E. Bryant School of Computer Science, Carnegie Mellon University.
The Theory of NP-Completeness
Sanjit A. Seshia and Randal E. Bryant Computer Science Department
Chapter 11: Limitations of Algorithmic Power
CS5371 Theory of Computation Lecture 4: Automata Theory II (DFA = NFA, Regular Language)
1 Completeness and Complexity of Bounded Model Checking.
1 A propositional world Ofer Strichman School of Computer Science, Carnegie Mellon University.
Decision Procedures for Presburger Arithmetic Presented by Constantinos Bartzis.
Systems of Linear Equations
Solving Systems of Linear Equations by Graphing
Regular Model Checking Ahmed Bouajjani,Benget Jonsson, Marcus Nillson and Tayssir Touili Moran Ben Tulila
Nattee Niparnan. Easy & Hard Problem What is “difficulty” of problem? Difficult for computer scientist to derive algorithm for the problem? Difficult.
Dana Nau: Lecture slides for Automated Planning Licensed under the Creative Commons Attribution-NonCommercial-ShareAlike License:
Model Checking Lecture 3 Tom Henzinger. Model-Checking Problem I |= S System modelSystem property.
Transformation of Timed Automata into Mixed Integer Linear Programs Sebastian Panek.
DECIDABILITY OF PRESBURGER ARITHMETIC USING FINITE AUTOMATA Presented by : Shubha Jain Reference : Paper by Alexandre Boudet and Hubert Comon.
Automatic Structures Bakhadyr Khoussainov Computer Science Department The University of Auckland, New Zealand.
The Complexity of Optimization Problems. Summary -Complexity of algorithms and problems -Complexity classes: P and NP -Reducibility -Karp reducibility.
ENM 503 Lesson 1 – Methods and Models The why’s, how’s, and what’s of mathematical modeling A model is a representation in mathematical terms of some real.
Cost-Optimal Symbolic Pattern Database Planning with State Trajectory and Preference Constraints Stefan Edelkamp University of Dortmund.
Week 10Complexity of Algorithms1 Hard Computational Problems Some computational problems are hard Despite a numerous attempts we do not know any efficient.
EMIS 8373: Integer Programming NP-Complete Problems updated 21 April 2009.
CSCI 3160 Design and Analysis of Algorithms Tutorial 10 Chengyu Lin.
Umans Complexity Theory Lectures Lecture 1a: Problems and Languages.
NP-Complete Problems. Running Time v.s. Input Size Concern with problems whose complexity may be described by exponential functions. Tractable problems.
1.5 Solving Inequalities. Write each inequality using interval notation, and illustrate each inequality using the real number line.
Approximation Algorithms Department of Mathematics and Computer Science Drexel University.
CIS 540 Principles of Embedded Computation Spring Instructor: Rajeev Alur
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.
Strings Basic data type in computational biology A string is an ordered succession of characters or symbols from a finite set called an alphabet Sequence.
The decidability of Presburger Arithmetic By Guillermo Guillen 04/13/05 Dr. Smith COT 6421 FIU Spring 2005.
Daniel Kroening and Ofer Strichman Decision Procedures An Algorithmic Point of View Deciding Combined Theories.
NPC.
Variants of LTL Query Checking Hana ChocklerArie Gurfinkel Ofer Strichman IBM Research SEI Technion Technion - Israel Institute of Technology.
Young CS 331 D&A of Algo. NP-Completeness1 NP-Completeness Reference: Computers and Intractability: A Guide to the Theory of NP-Completeness by Garey and.
2009/6/30 CAV Quantifier Elimination via Functional Composition Jie-Hong Roland Jiang Dept. of Electrical Eng. / Grad. Inst. of Electronics Eng.
Decision Support Systems
Systems of Linear Equations
Formal Methods in software development
CIS Automata and Formal Languages – Pei Wang
PROPERTIES OF REGULAR LANGUAGES
CSE 105 theory of computation
Review for the Midterm Exam
Jaya Krishna, M.Tech, Assistant Professor
Arithmetic Constraints and Automata
Jaya Krishna, M.Tech, Assistant Professor
Objective of This Course
Alternating tree Automata and Parity games
Decidable Languages Costas Busch - LSU.
Chapter 11 Limitations of Algorithm Power
Formal Methods in software development
NP-Completeness Reference: Computers and Intractability: A Guide to the Theory of NP-Completeness by Garey and Johnson, W.H. Freeman and Company, 1979.
Translating Linear Temporal Logic into Büchi Automata
Graphical solution A Graphical Solution Procedure (LPs with 2 decision variables can be solved/viewed this way.) 1. Plot each constraint as an equation.
Presentation transcript:

On the Use of Automata Techniques to Decide Satisfiability Mia Minnes May 3, 2005

Motivation We’ve seen how useful ILP formulations can be. Often, the main question is whether such a system (of linear equations and inequalities) has a solution, and if so, what it is. Omega is nice, but can we do better? Moreover, can we have a general framework for solving such systems which is amenable to extension? –E.g. to Mixed Integer Linear Programming –E.g. to more general systems (with quantifiers).

Motivation One possible such framework is Finite Automata. Why are we interested in it? It worked before…MONA (model checking for LTL). Automata are amenable to algorithmic manipulation. It often has a compact representation.

Goal Given a system of linear equations and inequalities, construct an automaton which accepts exactly those vectors which are solutions to the system. In order to get there, we’ll need to 1.Define the systems of equations / inequalities 2.Define automata 3.Formulate algorithm.

1. The Systems Presburger Arithmetic is the first order theory (sentences involving , , Boolean combinations) of Atomic (basic) formulas are of the form: or

1. The Systems A formula  ( x 1,…, x n ) in Presburger Arithmetic is SATISFIABLE if there are integers c 1,…, c n such that  ( c 1,…, c n ) is true. Examples:    Presburger (1927) gave decision method. ILP Problem ?

2. Automata A finite state AUTOMATON is a “machine” which reads input bit-by-bit and changes state according to the current state and input. It has designated initial and accepting states, and a transition function which gives the rule for moving between states. Example: 0 0,1 1 sisi smsm sfsf    Sample Input:

3. Algorithm 1.Given , a formula in Presburger Arithmetic 2.Construct A , the automaton accepting exactly those words satisfying  3.Check if the set of words accepted by A  is empty 4.If yes,  is not satisfiable; if no, it is. Observe: The hardest part of this algorithm is (2). Why? Cf. (Wolper, Boigelot ‘02, extending Boudet, Comon ‘96)

3. Algorithm To tackle the translation of formulas to automata: 1.First construct A  for atomic  2.Then define automata corresponding to Boolean op’ns 3.Finally, define automata for quantified formulas. (Note that the third step is not important for ILP problems.)

3. Algorithm: Equations Some implementation details: 1.Integers encoded in 2’s complement binary notation. 2.Read numbers MSB first. 3.States represent current value of sum. Hence,

3. Algorithm: Forward Construction sisi Inputs (b): ,11 x-y=2 a = (1,-1) … …

3. Algorithm: Pruning Construction sisi , ,01,10,11 x-y=2 sbsb Note: this is not yet minimal!

3. Algorithm: Backward Construction sisi , ,01,10,11 x-y=2 H={s i,2} L={2}  =(  0 +a.b)/2  Z?  =-a.b?  0   via b H={s i,2,1,0} L={0} H={s i,2,1,0} L= empty H={s i,2,1} L={1} Note: this is minimal!

3. Algorithm: Inequalities 1.For forward construction: include all states representing numbers less than RHS as accepting (plus modify bad states). 2.For backward construction, add transitions for all

sisi , ,01,10,11 x-y <= 2 sbsb Also need to add transitions! sgsg 3. Algorithm: Inequalities

3. Algorithm: General Formulas 1.We’ve taken care of any atomic formula. 2.For negation, conjunction, and disjunction of formulas, use the standard techniques for complementation, intersection, and union of finite automata. Complementation: switch accepting / non-accepting states Intersection: run both automata simultaneously Union: run the automata side by side 3.To eliminate quantifiers, use the projection operation on automata.

Complexity Results If  is a quantifier free formula, then the minimal automaton for  has at most 1+(  +  ) |  | states, where |  | is the number of terms in ,  and  depend on the absolute values of the coefficients in the linear terms. If  is an arbitrary formula of length, the minimal automaton for  has at most states. Moreover, there is an example requiring this many states, so the bound is tight. Cf. (Klaedtke ‘03)

Evaluation of Aut. Decision Proc. Relatively simple algorithm. Handles general case well (Pres. Arithmetic). Uses graph theoretic simplifications. Exhibits solution if one exists. Doesn’t use native arithmetic so will spend more time on computation. Calculates a lot of data that may not be necessary for specific question.

Experimental Results: Quant. Free Satisfiability problem for quantifier free Presburger Arithmetic is NP complete, so experiments were designed to determine which classes of formulas were handled well by each technique (LASH vs. ILP vs. Omega) 25 runs with parameters: # atomic formulas # variables LASH was able to complete nearly all test runs, and do so correctly. ILP, Omega were faster when they worked but were prone to error / failure. Cf. (Ganesh, Berezin, Dill ‘02)

Extension: Mixed Integers and Reals Hybrid systems and timed systems require systems of equations in which some of the variables have real values and some have integer values. To use the automata techniques in this case we have two challenges: 1.How to encode real numbers as binary input to automata? 2.How to design automata which accept particular sets of reals? A nice feature of the design which follows is that the set of integers is automata recognizable. Cf. (Boigelot, Bronne, Rassart ‘97 Boigelot, Jodogne, Wolper ‘01 Boigelot, Wolper ‘02)

Encoding Real Numbers Given  a real number, we encode it in binary with MSB first, using 2’s complement for negative numbers. Result is an infinite word  =  I *  F where  I encodes the integer part of  as a finite binary word, and  F encodes the fractional part of  as an infinite binary word.

Automata Accepting Real Numbers Decompose the problem as follows: Using a finite automaton (as before) to accept the integer part of the real number Concatenating with a special automaton which only accepts * And then appending a new kind of automaton which will have to be able to accept the fractional (infinite) part of the real number. Finite Automaton Buchi Automaton *

Automata Accepting Real Numbers What is a Buchi Automaton? A finite state automaton where the notion of “accepting a word” is different: The automaton accepts a word  if, on reading , the automaton enters an accepting state infinitely many times. By the Buchi characterization theorem, the set of words accepted by a Buchi automaton is nonempty exactly if there is a “lasso” path in the underlying directed graph from an initial state to an accepting state and then looping back to the accepting state. smsm sfsf sisi 0 0,1 1 Accepts e.g …

Automata Accepting Real Numbers Now the satisfiability question is: Does the integer part automaton accept a non- empty set of words? And, Does the fractional part automaton accept a non- empty set of words? Since both of these are answerable (in linear time) by graph algorithms, we’re in good shape.

Future Directions & Open Questions Further, more extensive, comparative studies For general formulas (with quantifiers) In the mixed case (compare to Fourier-Motzkin approach) Explore different encoding schemes LSB vs. MSB first Expand/ optimize existing toolsets.

References Boigelot, Bronne, Rassart (CAV ‘97) “An Improved Reachability Analysis for Strongly Linear Hybrid Systems”. Wolper, Boigelot (TACAS ‘00) “On the Construction of Automata from Linear Arithmetic Constraints”. Boigelot, Jodogne, Wolper (IJCAR ‘01) “On the Use of Weak Automata for Deciding Linear Arithmetic with Integer and Real Variables”. Boigelot, Wolper (ICLP ‘02) “Representing Arithmetic Constraints with Automata: An Overview”. Ganesh, Berezin, Dill (FMCAD ‘02) “Deciding Presburger Arithmetic by Model Checking and Comparison with Other Methods”. Klaedtke (Technical Report, ‘03; LICS ‘04) “On the Automata Size for Presburger Arithmetic”.