At present, the most efficient implementations of Arrowized functional reactive programming (AFRP), such as Scalable FRP (SFRP), do not support the loop combinator. This prevents us from expressing fundamental program...
详细信息
ISBN:
(纸本)9798400711022
At present, the most efficient implementations of Arrowized functional reactive programming (AFRP), such as Scalable FRP (SFRP), do not support the loop combinator. This prevents us from expressing fundamental programs in such implementations, which limits AFRP's use in domains where both performance and expressivity are required. We introduce Oxbow, which extends SFRP with support for the loop combinator by leveraging an improved variant of the rearrange technique. In benchmarks, Oxbow performs at least 2.2x better than Yampa, an AFRP implementation that supports the loop combinator.
functional reactive programming (FRP) is an approach to the development of reactive systems which provides a pure functional interface, but which may be implemented as an abstraction of an imperative event-driven laye...
详细信息
ISBN:
(纸本)9781450323260
functional reactive programming (FRP) is an approach to the development of reactive systems which provides a pure functional interface, but which may be implemented as an abstraction of an imperative event-driven layer. FRP systems typically provide a model of behaviours (total time-indexed values, implemented as pull systems) and event sources (partial time-indexed values, implemented as push systems). In this paper, we investigate a type system for event-driven FRP programs which provide liveness guarantees, that is every input event is guaranteed to generate an output event. We show that FRP can be implemented on top of a model of sets and relations, and that the isomorphism between event sources and behaviours corresponds to the isomorphism between relations and set-valued functions. We then implement sets and relations using a model of continuations using the usual double-negation CPS transform. The implementation of behaviours as pull systems based on futures, and of event sources as push systems based on the observer pattern, thus arises from first principles. We also discuss a Java implementation of the FRP model.
functional reactive programming (FRP) has come to mean many things. Yet, scratch the surface of the multitude of realisations, and there is great commonality between them. This paper investigates this commonality, tur...
详细信息
ISBN:
(纸本)9781450344340
functional reactive programming (FRP) has come to mean many things. Yet, scratch the surface of the multitude of realisations, and there is great commonality between them. This paper investigates this commonality, turning it into a mathematically coherent and practical FRP realisation that allows us to express the functionality of many existing FRP systems and beyond by providing a minimal FRP core parameterised on a monad. We give proofs for our theoretical claims and we have verified the practical side by bench-marking a set of existing, non-trivial Yampa applications running on top of our new system with very good results.
functional reactive programming (FRP) makes it possible to express temporal aspects in a declarative way. Traditional approaches to FRP cannot handle objects like widgets in a graphical user interface or files in a fi...
详细信息
functional reactive programming (FRP) makes it possible to express temporal aspects in a declarative way. Traditional approaches to FRP cannot handle objects like widgets in a graphical user interface or files in a file system. Therefore, programmers have to resort to ordinary methods of effectful programming when working with objects. In this paper, we devise a variant of FRP with support for objects, called "resourceful FRP", and develop an abstract categorical semantics for this FRP variant. (C) 2016 Elsevier Inc. All rights reserved.
Computation methods using custom circuits are frequently employed to improve the throughput and power efficiency of computing systems. Hardware development, however, can incur significant development costs because des...
详细信息
Computation methods using custom circuits are frequently employed to improve the throughput and power efficiency of computing systems. Hardware development, however, can incur significant development costs because designs at the register-transfer level (RTL) with a hardware description language (HDL) are time-consuming. This paper proposes a hardware and software co-design environment, named Mulvery, which is designed for non-professional hardware designer We focus on the similarities between functional reactive programming (FRP) and dataflow in computation. This study provides an idea to design hardware with a dynamic typing language, such as Ruby, using FRP and provides the proof-of-concept of the method. Mulvery, which is a hardware and software co-design tool based on our method, reduces development costs. Mulvery exhibited high performance compared with software processing techniques not equipped with hardware knowledge. According to the experiment, the method allows us to design hardware without degradation of performance. The sample application applied a Laplacian filter to an image with a size of 128 x 128 and processed a convolution operation within one clock.
functional reactive programming provides mechanisms of describing dynamic systems in a declarative and type-safe manner, which is traditional domain of functional languages in general and Haskell, which we use here, i...
详细信息
functional reactive programming provides mechanisms of describing dynamic systems in a declarative and type-safe manner, which is traditional domain of functional languages in general and Haskell, which we use here, in particular. We explore ways, in which it may be applied to programming web applications, specifically, we design a domain specific language intended for writing web pages as a part of a Haskell program, which would generate the actual code served to the client, and enriching them with dynamic content; and also find out to what extent we may broaden the expressive power of such library given certain inherent constraints of the chosen method. In doing so, we utilize the tree-like structure of the HTML page, which is quite suitable to be written as a source code in a programming language and to which we embed additional entities providing the dynamics and interactivity.
Highly critical application domains, like medicine and aerospace, require the use of strict design, implementation and validation techniques. functional languages have been used in these domains to develop synchronous...
详细信息
Highly critical application domains, like medicine and aerospace, require the use of strict design, implementation and validation techniques. functional languages have been used in these domains to develop synchronous dataflow programming languages for reactive systems. Causal stream functions and functional reactive programming capture the essence of those languages in a way that is both elegant and robust. To guarantee that critical systems can operate under high stress over long periods of time, these applications require clear specifications of possible faults and hazards, and how they are being handled. Modeling failure is straightforward in functional languages, and many functionalreactive abstractions incorporate support for failure or termination. However, handling unknown types of faults, and incorporating fault tolerance into functional reactive programming, requires a different construction and remains an open problem. This work presents extensions to an existing functionalreactive abstraction to facilitate tagging reactive transformations with hazard tags or confidence levels. We present a prototype framework to quantify the reliability of a reactive construction, by means of numeric factors or probability distributions, and demonstrate how to aid the design of fault-tolerant systems, by constraining the allowed reliability to required boundaries. By applying type-level programming, we show that it is possible to improve static analysis and have compile-time guarantees of key aspects of fault tolerance. Our approach is powerful enough to be used in systems with realistic complexity, and flexible enough to be used to guide their analysis and design, to test system properties, to verify fault tolerance properties, to perform runtime monitoring, to implement fault tolerance during execution and to address faults during runtime. We present implementations in Haskell and in Idris.
Many types of interactive applications, including video games, raise particular challenges when it comes to testing and debugging. Reasons include de-facto lack of reproducibility and difficulties of automatically gen...
详细信息
Many types of interactive applications, including video games, raise particular challenges when it comes to testing and debugging. Reasons include de-facto lack of reproducibility and difficulties of automatically generating suitable test data. This paper demonstrates that certain variants of functional reactive programming (FRP) implemented in pure functional languages can mitigate such difficulties by offering referential transparency at the level of whole programs. This opens up for a multi-pronged approach for assisting with testing and debugging that works across platforms, including assertions based on temporal logic, recording and replaying of runs (also from deployed code), and automated random testing using QuickCheck. The approach has been validated on real, non-trivial games implemented in the FRP system Yampa through a tool providing a convenient Graphical User Interface that allows the execution of the code under scrutiny to be controlled, moving along the execution time line, and pin-pointing of violations of assertions on PCs as well as mobile platforms.
functional reactive programming (FRP) is an approach to the development of reactive systems which provides a pure functional interface, but which may be implemented as an abstraction of an imperative event-driven laye...
详细信息
functional reactive programming (FRP) is an approach to the development of reactive systems which provides a pure functional interface, but which may be implemented as an abstraction of an imperative event-driven layer. FRP systems typically provide a model of behaviours (total time-indexed values, implemented as pull systems) and event sources (partial time-indexed values, implemented as push systems). In this paper, we investigate a type system for event-driven FRP programs which provide liveness guarantees, that is every input event is guaranteed to generate an output event. We show that FRP can be implemented on top of a model of sets and relations, and that the isomorphism between event sources and behaviours corresponds to the isomorphism between relations and set-valued functions. We then implement sets and relations using a model of continuations using the usual double-negation CPS transform. The implementation of behaviours as pull systems based on futures, and of event sources as push systems based on the observer pattern, thus arises from first principles. We also discuss a Java implementation of the FRP model.
The SuperCollider audio synthesis environment allows the definition of Synths, digital instruments which generate sound using a graph of interconnected unit generators. In SuperCollider the definition of a Synth is mo...
详细信息
ISBN:
(纸本)9781450358569
The SuperCollider audio synthesis environment allows the definition of Synths, digital instruments which generate sound using a graph of interconnected unit generators. In SuperCollider the definition of a Synth is mostly declarative, on the other hand the logic for controlling parameters of a Synth using musical controllers is usually implemented in a different context using callbacks and explicit state. This paper presents a different approach where functional reactive programming (FRP) is used to define the control logic of the instrument, taking inputs from musical controllers, mobile apps or graphical user interface (GUI) widgets and sending outputs to the audio graph. Both audio and FRP graphs are defined in the same context and compiled simultaneously avoiding a hard division between audio and control logic. An FRP implementation is used in the NNdef class to enable livecoding of both audio and FRP code, with hotswap allowing an interactive workflow. Also included is a system to persist the state in the FRP network in order to save and recall the instrument at a later time.
暂无评论