1,166 research outputs found

    A Logic of Reachable Patterns in Linked Data-Structures

    Get PDF
    We define a new decidable logic for expressing and checking invariants of programs that manipulate dynamically-allocated objects via pointers and destructive pointer updates. The main feature of this logic is the ability to limit the neighborhood of a node that is reachable via a regular expression from a designated node. The logic is closed under boolean operations (entailment, negation) and has a finite model property. The key technical result is the proof of decidability. We show how to express precondition, postconditions, and loop invariants for some interesting programs. It is also possible to express properties such as disjointness of data-structures, and low-level heap mutations. Moreover, our logic can express properties of arbitrary data-structures and of an arbitrary number of pointer fields. The latter provides a way to naturally specify postconditions that relate the fields on entry to a procedure to the fields on exit. Therefore, it is possible to use the logic to automatically prove partial correctness of programs performing low-level heap mutations

    Weighted Automata and Monadic Second Order Logic

    Full text link
    Let S be a commutative semiring. M. Droste and P. Gastin have introduced in 2005 weighted monadic second order logic WMSOL with weights in S. They use a syntactic fragment RMSOL of WMSOL to characterize word functions (power series) recognizable by weighted automata, where the semantics of quantifiers is used both as arithmetical operations and, in the boolean case, as quantification. Already in 2001, B. Courcelle, J.Makowsky and U. Rotics have introduced a formalism for graph parameters definable in Monadic Second order Logic, here called MSOLEVAL with values in a ring R. Their framework can be easily adapted to semirings S. This formalism clearly separates the logical part from the arithmetical part and also applies to word functions. In this paper we give two proofs that RMSOL and MSOLEVAL with values in S have the same expressive power over words. One proof shows directly that MSOLEVAL captures the functions recognizable by weighted automata. The other proof shows how to translate the formalisms from one into the other.Comment: In Proceedings GandALF 2013, arXiv:1307.416

    Boundedness in languages of infinite words

    Full text link
    We define a new class of languages of Ļ‰\omega-words, strictly extending Ļ‰\omega-regular languages. One way to present this new class is by a type of regular expressions. The new expressions are an extension of Ļ‰\omega-regular expressions where two new variants of the Kleene star Lāˆ—L^* are added: LBL^B and LSL^S. These new exponents are used to say that parts of the input word have bounded size, and that parts of the input can have arbitrarily large sizes, respectively. For instance, the expression (aBb)Ļ‰(a^Bb)^\omega represents the language of infinite words over the letters a,ba,b where there is a common bound on the number of consecutive letters aa. The expression (aSb)Ļ‰(a^Sb)^\omega represents a similar language, but this time the distance between consecutive bb's is required to tend toward the infinite. We develop a theory for these languages, with a focus on decidability and closure. We define an equivalent automaton model, extending B\"uchi automata. The main technical result is a complementation lemma that works for languages where only one type of exponent---either LBL^B or LSL^S---is used. We use the closure and decidability results to obtain partial decidability results for the logic MSOLB, a logic obtained by extending monadic second-order logic with new quantifiers that speak about the size of sets

    Expansions of MSO by cardinality relations

    Full text link
    We study expansions of the Weak Monadic Second Order theory of (N,<) by cardinality relations, which are predicates R(X1,...,Xn) whose truth value depends only on the cardinality of the sets X1, ...,Xn. We first provide a (definable) criterion for definability of a cardinality relation in (N,<), and use it to prove that for every cardinality relation R which is not definable in (N,<), there exists a unary cardinality relation which is definable in (N,<,R) and not in (N,<). These results resemble Muchnik and Michaux-Villemaire theorems for Presburger Arithmetic. We prove then that + and x are definable in (N,<,R) for every cardinality relation R which is not definable in (N,<). This implies undecidability of the WMSO theory of (N,<,R). We also consider the related satisfiability problem for the class of finite orderings, namely the question whether an MSO sentence in the language {<,R} admits a finite model M where < is interpreted as a linear ordering, and R as the restriction of some (fixed) cardinality relation to the domain of M. We prove that this problem is undecidable for every cardinality relation R which is not definable in (N,<).Comment: to appear in LMC

    Modal mu-calculi

    Get PDF

    Counterpart semantics for a second-order mu-calculus

    Get PDF
    We propose a novel approach to the semantics of quantified Ī¼-calculi, considering models where states are algebras; the evolution relation is given by a counterpart relation (a family of partial homomorphisms), allowing for the creation, deletion, and merging of components; and formulas are interpreted over sets of state assignments (families of substitutions, associating formula variables to state components). Our proposal avoids the limitations of existing approaches, usually enforcing restrictions of the evolution relation: the resulting semantics is a streamlined and intuitively appealing one, yet it is general enough to cover most of the alternative proposals we are aware of

    Query Containment for Highly Expressive Datalog Fragments

    Get PDF
    The containment problem of Datalog queries is well known to be undecidable. There are, however, several Datalog fragments for which containment is known to be decidable, most notably monadic Datalog and several "regular" query languages on graphs. Monadically Defined Queries (MQs) have been introduced recently as a joint generalization of these query languages. In this paper, we study a wide range of Datalog fragments with decidable query containment and determine exact complexity results for this problem. We generalize MQs to (Frontier-)Guarded Queries (GQs), and show that the containment problem is 3ExpTime-complete in either case, even if we allow arbitrary Datalog in the sub-query. If we focus on graph query languages, i.e., fragments of linear Datalog, then this complexity is reduced to 2ExpSpace. We also consider nested queries, which gain further expressivity by using predicates that are defined by inner queries. We show that nesting leads to an exponentially increasing hierarchy for the complexity of query containment, both in the linear and in the general case. Our results settle open problems for (nested) MQs, and they paint a comprehensive picture of the state of the art in Datalog query containment.Comment: 20 page
    • ā€¦
    corecore