English
Related papers

Related papers: Monads and "do" notation in the Wolfram Language

200 papers

Strong monads are important for several applications, in particular, in the denotational semantics of effectful languages, where strength is needed to sequence computations that have free variables. Strength is non-trivial: it can be…

Logic in Computer Science · Computer Science 2022-07-05 Dylan McDermott , Tarmo Uustalu

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…

Programming Languages · Computer Science 2012-02-15 Maciej Piróg , Jeremy Gibbons

Grammatic is a tool for grammar definition and manipulation aimed to improve modularity and reuse of grammars and related development artifacts. It is independent from parsing technology and any other details of target system…

Programming Languages · Computer Science 2009-01-19 Andrey Breslav

This paper studies the design of programming languages with handlers of higher-order effectful operations -- effectful operations that may take in computations as arguments or return computations as output. We present and analyse a core…

Programming Languages · Computer Science 2025-11-11 Zhixuan Yang , Nicolas Wu

A simple dynamically-typed, (purely) object-oriented language is defined. A structural operational semantics as well as a Hoare-style program logic for reasoning about programs in the language in multiple notions of correctness are given.…

Programming Languages · Computer Science 2016-01-12 Björn Engelmann , Ernst-Rüdiger Olderog

We continue our investigation into hybrid polyadic multi-sorted logic with a focus on expresivity related to the operational and axiomatic semantics of rogramming languages, and relations with first-order logic. We identify a fragment of…

Logic in Computer Science · Computer Science 2020-07-06 Ioana Leuştean , Natalia Moangă , Traian Florin Şerbănuţă

TheBench is a tool to study monadic structures in natural language. It is for writing monadic grammars to explore analyses, compare diverse languages through their categories, and to train models of grammar from form-meaning pairs where…

Computation and Language · Computer Science 2024-06-05 Cem Bozsahin

For the purposes of tool development, computer languages are usually described using context-free grammars with annotations such as semantic actions or pretty-printing instructions. These descriptions are processed by generators which…

Programming Languages · Computer Science 2010-01-19 Andrey Breslav

In this paper an algorithm is designed which generates in-equivalent Boolean functions of any number of variables from the four Boolean functions of single variable. The grammar for such set of Boolean function is provided. The Turing…

Logic in Computer Science · Computer Science 2008-02-29 Birendra Kumar Nayak , Sudhakar Sahoo

We introduce a novel quantum programming language featuring higher-order programs and quantum controlflow which ensures that all qubit transformations are unitary. Our language boasts a type system guaranteeingboth unitarity and…

Logic in Computer Science · Computer Science 2024-03-06 Alejandro Díaz-Caro , Emmanuel Hainry , Romain Péchoux , Mário Silva

In this work we define formal grammars in terms of free monoidal categories, along with a functor from the category of formal grammars to the category of automata. Generalising from the Booleans to arbitrary semirings, we extend our…

Formal Languages and Automata Theory · Computer Science 2020-01-13 Dan Shiebler , Alexis Toumi , Mehrnoosh Sadrzadeh

We introduce formal languages over infinite alphabets where words may contain binders. We define the notions of nominal language, nominal monoid, and nominal regular expressions. Moreover, we extend history-dependent automata (HD-automata)…

Formal Languages and Automata Theory · Computer Science 2011-02-17 Alexander Kurz , Tomoyuki Suzuki , Emilio Tuosto

Natural language processing for programming aims to use NLP techniques to assist programming. It is increasingly prevalent for its effectiveness in improving productivity. Distinct from natural language, a programming language is highly…

Computation and Language · Computer Science 2023-08-08 Qingfu Zhu , Xianzhen Luo , Fang Liu , Cuiyun Gao , Wanxiang Che

We define a notion of grading of a monoid T in a monoidal category C, relative to a class of morphisms M (which provide a notion of M-subobject). We show that, under reasonable conditions (including that M forms a factorization system),…

Logic in Computer Science · Computer Science 2023-08-01 Flavien Breuvart , Dylan McDermott , Tarmo Uustalu

One of the main reasons for the correspondence of regular languages and monadic second-order logic is that the class of regular languages is closed under images of surjective letter-to-letter homomorphisms. This closure property holds for…

Logic in Computer Science · Computer Science 2022-01-26 Mikołaj Bojańczyk , Bartek Klin , Julian Salamanca

Creating linguistic annotations requires more than just a reliable annotation scheme. Annotation can be a complex endeavour potentially involving many people, stages, and tools. This chapter outlines the process of creating end-to-end…

Computation and Language · Computer Science 2016-02-19 Mark A. Finlayson , Tomaž Erjavec

We have designed a new logic programming language called LM (Linear Meld) for programming graph-based algorithms in a declarative fashion. Our language is based on linear logic, an expressive logical system where logical facts can be…

Programming Languages · Computer Science 2020-02-19 Flavio Cruz , Ricardo Rocha , Seth Copen Goldstein , Frank Pfenning

The use of monoids in the study of word languages recognized by finite-state automata has been quite fruitful. In this work, we look at the same idea of "recognizability by finite monoids" for other monoids. In particular, we attempt to…

Formal Languages and Automata Theory · Computer Science 2025-02-12 Pranshu Gaba , Arnab Sur

We express quantum computations (with measurements) using the arrow calculus extended with monadic constructions. This framework expresses quantum programming using well-understood and familiar classical patterns for programming in the…

Quantum Physics · Physics 2009-04-11 Juliana Kaizer Vizzotto , Andre Rauber Du Bois , Amr Sabry

We propose a general framework to allow: (a) specifying the operational semantics of a programming language; and (b) stating and proving properties about program correctness. Our framework is based on a many-sorted system of hybrid modal…

Logic in Computer Science · Computer Science 2025-12-01 Ioana Leustean , Natalia Moanga , Traian Florin Serbanuta