We develop a calculus for lazy functional programming based on recursion operators associated with data type definitions. For these operators we derive various algebraic laws that are useful in deriving and manipulating programs. We shall show that all example Functions in Bird and Wadler's "Introduction to Functional Programming" can be expressed using these operators.
Alignment of application architecture to business architecture is a central problem in the design, acquisition and implementation of information systems in current large-scale information-processing organizations. Current research in architecture alignment is either too strategic or too software implementation-oriented to be of use to the practicing information systems architect. This paper presents a framework to analyze the alignment problem and operationalizes this as an approach to application architecture design given a business context. We summarize guidelines for application architecture design and illustrate our approach and guidelines with an example.
To better serve users' information needs without requiring comprehensive queries from users, a simple yet effective technique is to explore the preferences of users. Since these preferences can differ for each context of the user, we introduce context-aware preferences. To anchor the semantics of context-aware preferences in a traditional probabilistic model of information retrieval, we present a semantics for context-aware preferences based on the history of the user. An advantage of this approach is that the inherent uncertainty of context information, due to the fact that context information is often acquired through sensors, can be easily integrated in the model. To demonstrate the feasibility of our approach and current bottlenecks we provide a naive implementation of our technique based on database views.
Consider a rst order typed language, with semantics ] ] for expressions and types. Adding subtyping means that a partial order on types is de ned and that the typing rules are extended to the e ect that expression e has type whenever e has type and . We s h o w h o w to adapt the semantics ] ] i n a simple set-theoretic way, obtaining a semantics f g ] that satis es, in addition to some obvious requirements, also the property: f g] f g], whenever .whether there exists a (mathematical) semantics for types (and subtyping). Let us denote the semantics of closed expressions e and types by e] ] and ] ], respectively. It would be nice if the semantics ] ] o f t ype is merely a set such t h a t e] ] 2 ] ] w h e n e v er e has type . However, only for simple (so-called rst order, non-recursive) types such a simple set-theoretic semantics seems possible. Most often one nds types interpreted as \domains" (continuous lattices or the like) and sometimes a set-theoretic interpretation is proved to beimpossible Reynolds 1984]. The semantics of subtyping is our prime concern in this paper.We set out to construct, by simple set-theoretic means, a semantics for types {in the presence of subtyping{ such t h a t ] ]] ] whenever This poses serious semantical problems. Consider for example the following situation: Assume that ( ! )] ] = some non-empty set of functions that have domain ] ] and co-domain ] ]Assume that int] ] real] ] Assume that int real, so that, as motivated in Section 3, (real! ) (int ! ) We then nd that the desire (real! )] ] (int ! )] ] c o n tradicts the following two observations:Functions f 2 (real! )] ] cannot belong to (int ! )] ] because the domain of f di ers from int] ] Our solution, on the contrary, is as simple as e ective, and can bestated in a single line. Given a semantics ] ] for the language without subtyping, we form a new semantics f g] when subtyping is added, by de ning f g] = ] ]For now w e h a ve, when , that f g] = S ] ] S ] ] (transitivity of , )Note that we have used only elementary, primary school set-theoretic constructions in the de nition of f g] for types. However, this still leaves us with the problem of de ning f g] for expressions in such a w ay that
Using the well-known categorical notion of 'functor', one may define the concept of datatype (algebra) without being forced to introduce a signature (that is, names and typings for the individual sorts (types) and operations involved). This has proved to be advantageous for those theory developments where one is not interested in the syntactic appearance of an algebra. The categorical notion of 'transformer' developed in this paper allows the same approach to laws: without using signatures one can define the concept of law for datatypes (lawful algebras), and investigate the equational specification of datatypes in a syntax-free manner. A transformer is a special kind of functor and also a natural transformation on the level of dialgebras. Transformers are quite expressive, satisfy several closure properties, and are related to naturality and Wadler's Theorems For Free Theorem. In fact, any colimit is an initial lawful algebra. Downloaded: 13 Apr 2015 IP address: 132.239.1.230 M. M. Fokkinga 2or any of the operations involved. Functors satisfy just one or two very simple axioms, and -almost unbelievably -that is all that is needed to develop a large body of useful theorems about algebras. The problem for which we propose a solution, is the following.Formalise the notion of 'law' (an equation or conditional equation for the operations of an algebra) without introducing signatures, in particular naming and setting up a syntax of terms.Remarkably, in all texts where functors are used to characterise algebras, signatures (or sketches) are introduced when it comes to laws. Clearly, this is a hindrance to theory development, since it forces us to deal with aspects (syntax) that should have been abstracted from. On the subject of the use of functors to describe algebras, Pierce (1991, Remark 2.2.3) explicitly says 'The framework has apparently never been extended to include algebras with equations'.
scite is a Brooklyn-based organization that helps researchers better discover and understand research articles through Smart Citations–citations that display the context of the citation and describe whether the article provides supporting or contrasting evidence. scite is used by students and researchers from around the world and is funded in part by the National Science Foundation and the National Institute on Drug Abuse of the National Institutes of Health.
hi@scite.ai
10624 S. Eastern Ave., Ste. A-614
Henderson, NV 89052, USA
Copyright © 2024 scite LLC. All rights reserved.
Made with 💙 for researchers
Part of the Research Solutions Family.