33 research outputs found
Fibrational induction meets effects
This paper provides several induction rules that can be used to prove properties of effectful data types. Our results are semantic in nature and build upon Hermida and Jacobs’ fibrational formulation of induction for polynomial data types and its extension to all inductive data types by Ghani, Johann, and Fumex. An effectful data type μ(TF) is built from a functor F that describes data, and a monad T that computes effects. Our main contribution is to derive induction rules that are generic over all functors F and monads T such that μ(TF) exists. Along the way, we also derive a principle of definition by structural recursion for effectful data types that is similarly generic. Our induction rule is also generic over the kinds of properties to be proved: like the work on which we build, we work in a general fibrational setting and so can accommodate very general notions of properties, rather than just those of particular syntactic forms. We give examples exploiting the generality of our results, and show how our results specialize to those in the literature, particularly those of Filinski and Støvring
Fibrational Induction Meets Effects
This paper provides several induction rules that can be used to prove properties of effectful data types. Our results are semantic in nature and build upon Hermida and Jacobs’ fibrational formulation of induction for polynomial data types and its extension to all inductive data types by Ghani, Johann, and Fumex. An effectful data type µ(T F ) is built from a functor F that describes data, and a monad T that computes e?ects. Our main contribution is to derive induction rules that are generic over all functors F and monads T such that µ(T F ) exists. Along the way, we also derive a principle of definition by structural recursion for effectful data types that is similarly generic. Our induction rule is also generic over the kinds of properties to be proved: like the work on which we build, we work in a general fibrational setting and so can accommodate very general notions of properties, rather than just those of particular syntactic forms. We give examples exploiting the generality of our results, and show how our results specialize to those in the literature, particularly those of Filinski and Støvring
Fibrational Initial Algebra-Final Coalgebra Coincidence over Initial Algebras: Turning Verification Witnesses Upside Down
The coincidence between initial algebras (IAs) and final coalgebras (FCs) is a phenomenon that underpins various important results in theoretical computer science. In this paper, we identify a general fibrational condition for the IA-FC coincidence, namely in the fiber over an initial algebra in the base category. Identifying (co)algebras in a fiber as (co)inductive predicates, our fibrational IA-FC coincidence allows one to use coinductive witnesses (such as invariants) for verifying inductive properties (such as liveness). Our general fibrational theory features the technical condition of stability of chain colimits; we extend the framework to the presence of a monadic effect, too, restricting to fibrations of complete lattice-valued predicates. Practical benefits of our categorical theory are exemplified by new "upside-down" witness notions for three verification problems: probabilistic liveness, and acceptance and model-checking with respect to bottom-up tree automata
Codensity Lifting of Monads and its Dual
We introduce a method to lift monads on the base category of a fibration to
its total category. This method, which we call codensity lifting, is applicable
to various fibrations which were not supported by its precursor, categorical
TT-lifting. After introducing the codensity lifting, we illustrate some
examples of codensity liftings of monads along the fibrations from the category
of preorders, topological spaces and extended pseudometric spaces to the
category of sets, and also the fibration from the category of binary relations
between measurable spaces. We also introduce the dual method called density
lifting of comonads. We next study the liftings of algebraic operations to the
codensity liftings of monads. We also give a characterisation of the class of
liftings of monads along posetal fibrations with fibred small meets as a limit
of a certain large diagram.Comment: Extended version of the paper presented at CALCO 2015, accepted for
publication in LMC
Reasoning about Unreliable Actions
We analyse the philosopher Davidson's semantics of actions, using a strongly
typed logic with contexts given by sets of partial equations between the
outcomes of actions. This provides a perspicuous and elegant treatment of
reasoning about action, analogous to Reiter's work on artificial intelligence.
We define a sequent calculus for this logic, prove cut elimination, and give a
semantics based on fibrations over partial cartesian categories: we give a
structure theory for such fibrations. The existence of lax comma objects is
necessary for the proof of cut elimination, and we give conditions on the
domain fibration of a partial cartesian category for such comma objects to
exist
Tracing monadic computations and representing effects
In functional programming, monads are supposed to encapsulate computations,
effectfully producing the final result, but keeping to themselves the means of
acquiring it. For various reasons, we sometimes want to reveal the internals of
a computation. To make that possible, in this paper we introduce monad
transformers that add the ability to automatically accumulate observations
about the course of execution as an effect. We discover that if we treat the
resulting trace as the actual result of the computation, we can find new
functionality in existing monads, notably when working with non-terminating
computations.Comment: In Proceedings MSFP 2012, arXiv:1202.240
A Fibrational Account of Local States
International audienceOne main challenge of the theory of computational effects is to understand how to combine various notions of effects in a meaningful way. Here, we study the particular case of the local state monad, which we would like to express as the result of combining together a family of global state monads parametrized by the number of available registers. To that purpose, we develop a notion of indexed monad inspired by the early work by Street, which refines and generalizes Power's recent notion of indexed Lawvere theory. One main achievement of the paper is to integrate the block structure necessary to encode allocation as part of the resulting notion of indexed state monad. We then explain how to recover the local state monad from the functorial data provided by our notion of indexed state monad. This reconstruction is based on the guiding idea that an algebra of the indexed state monad should be defined as a section of a 2-categorical notion of fibration associated to the indexed state monad by a Grothendieck construction
Generic Trace Semantics via Coinduction
Trace semantics has been defined for various kinds of state-based systems,
notably with different forms of branching such as non-determinism vs.
probability. In this paper we claim to identify one underlying mathematical
structure behind these "trace semantics," namely coinduction in a Kleisli
category. This claim is based on our technical result that, under a suitably
order-enriched setting, a final coalgebra in a Kleisli category is given by an
initial algebra in the category Sets. Formerly the theory of coalgebras has
been employed mostly in Sets where coinduction yields a finer process semantics
of bisimilarity. Therefore this paper extends the application field of
coalgebras, providing a new instance of the principle "process semantics via
coinduction."Comment: To appear in Logical Methods in Computer Science. 36 page