10 research outputs found
On almost cylindrical languages and the decidability of the D0L and PWD0L primitivity problems
AbstractPrimitive words and their properties have always been of fundamental importance in the study of formal language theory. Head and Lando in Periodic D0L Languages proposed the idea of deciding whether or not a given D0L language has the property that every word in it is a primitive word. After reducing the general problem to the case in which h is injective, it will be shown that primitivity is decidable when ((A)h)â is an almost cylindrical set. Moreover, in this case, it is shown that the set of words which generate primitive sequences (given a particular D0L scheme) is an algorithmically constructible context-sensitive language. An undecidability result for the PWD0L primitivity problem and decidability results for cases of the RWD0L primitivity problem are also given
Adding dependent types to class-based mutable objects
Tese de doutoramento, InformĂĄtica (CiĂȘncia da Computação), Universidade de Lisboa, Faculdade de CiĂȘncias, 2018In this thesis, we present an imperative object-oriented language featuring a dependent type system designed to support class-based programming and inheritance. The system brings classes and dependent types into play so as to enable types (classes) to be refined by value parameters (indices) drawn from some constraint domain. This combination allows statically checking interesting properties of imperative programs that are impossible to check in conventional static type systems for objects. From a pragmatic point of view, this work opens the possibility to combine the scalability and modularity of object orientation with the safety provided by dependent types in the form of index refinements. These may be used to provide additional guarantees about the fields of objects, and to prevent, for example, a method call that could leave an object in a state that would violate the class invariant. One key feature is that the programmer is not required to prove equations between indices issued by types, but instead the typechecker depends on external constraint solving. From a theoretic perspective, our fundamental contribution is to formulate a system that unifies the three very different features: dependent types, mutable objects and class-based inheritance with subtyping. Our approach includes universal and existential types, as well as union types. Subtyping is induced by inheritance and quantifier instantiation. Moreover, dependent types require the system to track type varying objects, a feature missing from standard type systems in which the type is constant throughout the objectâs lifetime. To ensure that an object is used correctly, aliasing is handled via a linear type discipline that enforces unique references to type varying objects. The system is decidable, provided indices are drawn from some decidable theory, and proved sound via subject reduction and progress. We also formulate a typechecking algorithm that gives a precise account of quantifier instantiation in a bidirectional style, combining type synthesis with checking. We prove that our algorithm is sound and complete. By way of example, we implement insertion and deletion for binary search trees in an imperative style, and come up with types that ensure the binary search tree invariant. To attest the relevance of the language proposed, we provide a fully functional prototype where this and other examples can be typechecked, compiled and run. The prototype can be found at http://rss.di.fc.ul.pt/tools/dol/
Dependent Types for Class-based Mutable Objects
We present an imperative object-oriented language featuring a dependent type system designed to support class-based programming and inheritance. Programmers implement classes in the usual imperative style, and may take advantage of a richer dependent type system to express class invariants and restrictions on how objects are allowed to change and be used as arguments to methods. By way of example, we implement insertion and deletion for binary search trees in an imperative style, and come up with types that ensure the binary search tree invariant. This is the first dependently-typed language with mutable objects that we know of to bring classes and index refinements into play, enabling types (classes) to be refined by indices drawn from some constraint domain. We give a declarative type system that supports objects whose types may change, despite being sound. We also give an algorithmic type system that provides a precise account of quantifier instantiation in a bidirectional style, and from which it is straightforward to read off an implementation. Moreover, all the examples in the paper have been run, compiled and executed in a fully functional prototype that includes a plugin for the Eclipse IDE
Strategic logics : complexity, completeness and expressivity
by transferring normative attributes from an agent to another. Such interactions are called delegation. Formal models of delegation and control were studied in, e.g., [189, 149, 191]. In this work, we consider the scenario where agents delegate control over propositions to other agents. The distinction between controllable and uncontrollable propositions stems from areas like discrete event systems and control theory, where, e.g., Boutilier [39] studied control in the context of deontic logic. Control and controllable propositions were also studied in [52, 66, 249, 248]. We now give an overview of the thesis. The main purpose of Chapter 2 is to introduce basic concepts and notation and to review relevant literature. The first section presents a brief survey on modal logic. Then, in sections 2.2, 2.3 and 2.4, we introduce epistemic, temporal and strategic modal logics and state known results that characterise their expressivity and computational complexity. In particular, we consider variants of ATL as extensions of branching-time logics. With such ATL-like logics we can describe dynamic multi-agent interactions. In Section 2.5, we discuss extensions of ATL with epistemic notions. Additionally, we suggest a framework for memory-bounded strategic reasoning. In particular, we introduce an epistemic variant of ATL that accounts for agents with limited memory resources as this case was neglected in the literature to date. In Chapter 3, we investigate the computational complexity of ATL and its epistemic extension ATEL. We show in detail how 'the complexity of the satisfiability problem for both logics can be settled at ExpTIME-complete. The part of the chapter about ATL is based on the paper 'ATL Satisfiability is Indeed ExpTIME-COmplete' by Walther, Lutz, Wolter and Wooldridge in the Journal of Logic and Computation, 2006 (265)' and the part about ATEL is based on the paper 'ATEL with Common and Distributed Knowledge is ExpTime-Complete' by Walther which was presented at the 4th Workshop on Methods for Modalities, Humbolt University, Berlin, December 1-2, 2005 [264]. In Chapter 4, we aim to extend the expressiveness of ATL without increasing its computational complexity. We introduce explicit names for strategies in the object language and extend modal operators with the possibility to bind agents to strategy names. In this way, we can fix the decisions of agents that possibly belong to several coalitions. By identifying the behaviqur of agents, we can reason about the effects of agents changing coalitions. Dynamic coalitions provide more flexibility to adapt abilities to a changing environment. We investigate the expressivity of the resulting logic ATLES and compare it to ATL and ATL*. Moreover, we formulate two model checking problems for ATLES and investigate their complexity as well as the complexity of the satisfiability problem for ATLES. Additionally, we present a complete axiomatisation. This chapter is based on the paper 'Alternating-time Temporal Logic with Explicit Strategies' by Walther, van der Hoek and Wooldridge which is going to presented at the 11th Conference on Theoretical Aspects of Rationality and Knowledge (TARK), Brussels, Belgium, June 25-27, 2007 [266]
Property driven verification framework: application to real time property for UML MARTE software design
Les techniques formelles de la famille « vĂ©rification de modĂšles » (« model checking ») se heurtent au problĂšme de lâexplosion combinatoire. Ceci limite les perspectives dâexploitation dans des projets industriels. Ce problĂšme est provoquĂ© par la combinatoire dans la construction de lâespace des Ă©tats possibles durant lâexĂ©cution des systĂšmes modĂ©lisĂ©s. Le nombre dâĂ©tats pour des modĂšles de systĂšmes industriels rĂ©alistes dĂ©passe rĂ©guliĂšrement les capacitĂ©s des ressources disponibles en calcul et stockage. Cette thĂšse dĂ©fend lâidĂ©e quâil est possible de rĂ©duire cette combinatoire en spĂ©cialisant les outils pour des familles de propriĂ©tĂ©s. Elle propose puis valide expĂ©rimentalement un ensemble de mĂ©thodes pour le dĂ©veloppement de ce type dâoutils en suivant une approche guidĂ©e par les propriĂ©tĂ©s appliquĂ©e au contexte temps rĂ©el. Il sâagit donc de construire des outils dâanalyse performants pour des propriĂ©tĂ©s temps rĂ©el qui soient exploitables pour des modĂšles industriels de taille rĂ©aliste. Les langages considĂ©rĂ©s sont, dâune part UML Ă©tendu par le profil MARTE pour la modĂ©lisation par les utilisateurs, et dâautre part les rĂ©seaux de Petri temporisĂ©s comme support pour la vĂ©rification. Les propositions sont validĂ©es sur un cas dâĂ©tude industriel rĂ©aliste issu du monde avionique : lâĂ©tude de la latence et la fraicheur des donnĂ©es dans un systĂšme de gestion des alarmes exploitant les technologies dâAvionique Modulaire IntĂ©grĂ©e. Ces propositions ont Ă©tĂ© mise en oeuvre comme une boite Ă outils qui intĂšgre les cinq contributions suivantes: la dĂ©finition de la sĂ©mantique dâexĂ©cution spĂ©cifiques aux propriĂ©tĂ©s temps rĂ©el pour les modĂšles dâarchitecture et de comportement spĂ©cifiĂ©s en UML/MARTE; la spĂ©cification des exigences temps rĂ©el en sâappuyant sur un ensemble de patrons de vĂ©rification atomiques dĂ©diĂ©s aux propriĂ©tĂ© temps rĂ©el; une mĂ©thode itĂ©rative dâanalyse Ă base dâobservateurs pour des rĂ©seaux de Petri temporisĂ©s; des techniques de rĂ©duction de lâespace dâĂ©tats spĂ©cifiques aux propriĂ©tĂ©s temps rĂ©el pour des RĂ©seaux de Petri temporisĂ©s; une approche pour lâanalyse des erreurs dĂ©tectĂ©es par « vĂ©rification des modĂšles » en sâappuyant sur des idĂ©es inspirĂ©es de la « fouille de donnĂ©es » (« data mining »). ABSTRACT : Automatic formal verification such as model checking faces the combinatorial explosion issue. This limits its application in indus- trial projects. This issue is caused by the explosion of the number of states during systemâs execution , as it may easily exceed the amount of available computing or storage resources. This thesis designs and experiments a set of methods for the development of scalable verification based on the property-driven approach. We propose efficient approaches based on model checking to verify real-time requirements expressed in large scale UML-MARTE real-time system designs. We rely on the UML and its profile MARTE as the end-user modeling language, and on the Time Petri Net (TPN) as the verification language. The main contribution of this thesis is the design and implementation of a property-driven verification prototype toolset dedicated to real-time properties verification for UML-MARTE real-time software designs. We validate this toolset using an avionic use case and its user requirements. The whole prototype toolset includes five contributions: definition of real-time property specific execution semantics for UML-MARTE architecture and behavior models; specification of real- time requirements relying on a set of verification dedicated atomic real- time property patterns; real-time property specific observer-based model checking approach in TPN; real-time property specific state space reduction approach for TPN; and fault localization approach in model checking
A foundation for synthesising programming language semantics
Programming or scripting languages used in real-world systems are seldom designed
with a formal semantics in mind from the outset. Therefore, the first step for developing well-founded analysis tools for these systems is to reverse-engineer a formal
semantics. This can take months or years of effort.
Could we automate this process, at least partially? Though desirable, automatically reverse-engineering semantics rules from an implementation is very challenging,
as found by Krishnamurthi, Lerner and Elberty. They propose automatically learning
desugaring translation rules, mapping the language whose semantics we seek to a simplified, core version, whose semantics are much easier to write. The present thesis
contains an analysis of their challenge, as well as the first steps towards a solution.
Scaling methods with the size of the language is very difficult due to state space
explosion, so this thesis proposes an incremental approach to learning the translation
rules. I present a formalisation that both clarifies the informal description of the challenge by Krishnamurthi et al, and re-formulates the problem, shifting the focus to the
conditions for incremental learning. The central definition of the new formalisation is
the desugaring extension problem, i.e. extending a set of established translation rules
by synthesising new ones.
In a synthesis algorithm, the choice of search space is important and non-trivial,
as it needs to strike a good balance between expressiveness and efficiency. The rest
of the thesis focuses on defining search spaces for translation rules via typing rules.
Two prerequisites are required for comparing search spaces. The first is a series of
benchmarks, a set of source and target languages equipped with intended translation
rules between them. The second is an enumerative synthesis algorithm for efficiently
enumerating typed programs. I show how algebraic enumeration techniques can be applied to enumerating well-typed translation rules, and discuss the properties expected
from a type system for ensuring that typed programs be efficiently enumerable.
The thesis presents and empirically evaluates two search spaces. A baseline search
space yields the first practical solution to the challenge. The second search space is
based on a natural heuristic for translation rules, limiting the usage of variables so that
they are used exactly once. I present a linear type system designed to efficiently enumerate translation rules, where this heuristic is enforced. Through informal analysis
and empirical comparison to the baseline, I then show that using linear types can speed
up the synthesis of translation rules by an order of magnitude
Verified programming with explicit coercions
Type systems have proved to be a powerful means of specifying and proving
important program invariants. In dependently typed programming languages
types can depend on values and hence express arbitrarily complicated
propositions and their machine checkable proofs. The type-based approach
to program specification allows for the programmer to not only transcribe
their intentions, but arranges for their direct involvement in the proving
process, thus aiding the machine in its attempt to satisfy difficult obligations.
In this thesis we develop a series of patterns for programming in a correct-by-construction style making use of constraints and coercions to prove
properties within a dependently typed host. This allows for the development
of a verified, kernel which can be built upon using the host system features.
In particular this should allow for the development of âtacticsâ or semiautomated
solvers invoked when coercing types all within a single language.
The efficacy of this approach is given by the development of a system of
expressions indexed by their, exposing a case analysis feature serving to
generate value constraints. These constraints are directly reflected into
the host allowing for their involvement in the type-checking process. A
motivating use case of this design shows how a termâs semantic index
information admits an exact, formalized cost analysis amenable to reasoning
within the host. Finally we show how such a system is used to identify
unreachable dead-code, trivially admitting the design and verification of
an SSA style compiler with this optimization. We think such a design
of explicitly proving the local correctness of type-transformations in the
presence of accumulated constraints can form the basis of a flexible language
in concert with a variety of trusted solver