scholarly journals Bottom-Up beta-Substitution: Uplinks and lambda-DAGs

2004 ◽  
Vol 11 (38) ◽  
Author(s):  
Olin Shivers ◽  
Mitchell Wand

Terms of the lambda-calculus are one of the most important data structures we have in computer science. Among their uses are representing program terms, advanced type systems, and proofs in theorem provers. Unfortunately, heavy use of this data structure can become intractable in time and space; the typical culprit is the fundamental operation of beta reduction.<br /> <br />If we represent a lambda-calculus term as a DAG rather than a tree, we can efficiently represent the sharing that arises from beta reduction, thus avoiding combinatorial explosion in space. By adding uplinks from a child to its parents, we can efficiently implement beta reduction in a bottom-up manner, thus avoiding combinatorial explosion in time required to search the term in a top-down fashion.<br /> <br />We present an algorithm for performing beta reduction on lambda terms represented as uplinked DAGs; describe its proof of correctness; discuss its relation to alternate techniques such as Lamping graphs, the suspension lambda-calculus (SLC) and director strings; and present some timings of an implementation.<br /> <br />Besides being both fast and parsimonious of space, the algorithm is particularly suited to applications such as compilers, theorem provers, and type-manipulation systems that may need to examine terms in-between reductions - i.e., the ``readback'' problem for our representation is trivial.<br /> <br />Like Lamping graphs, and unlike director strings or the suspension lambda-calculus, the algorithm functions by side-effecting the term containing the redex; the representation is not a ``persistent'' one. <br /> <br />The algorithm additionally has the charm of being quite simple; a complete implementation of the core data structures and algorithms is 180 lines of fairly straightforward SML.

1995 ◽  
Vol 06 (03) ◽  
pp. 265-298 ◽  
Author(s):  
IAN MASON ◽  
CAROLYN TALCOTT

VTLoE (Variable Type Logic of Effects) is a logic for reasoning about imperative functional programs inspired by the variable type systems of Feferman. The underlying programming language, λ mk , extends the call-by-value lambda calculus with primitives for arithmetic, pairing, branching, and reference cells (mutable data). In VTLoE one can reason about program equivalence and termination, input/output relations, program contexts, and inductively (and co-inductively) define data structures. In this paper we present a refinement of VTLoE. We then introduce a notion of object specification and establish formal principles for reasoning about object systems within VTLoE. Objects are self-contained entities with local state. The local state of an object can only be changed by action of that object in response to a message. In λ mk objects are represented as closures with mutable data bound to local variables. A semantic principle called simulation induction was introduced in our earlier work as a means of establishing equivalence relations between streams, object behaviors, and other potentially infinite structures. These are formulated in VTLoE using the class apparatus. The use of these principles is illustrated by validating a variety of basic tranformation rules.


2021 ◽  
Vol 61 (SI) ◽  
pp. 122-134
Author(s):  
Tomáš Oberhuber ◽  
Jakub Klinkovský ◽  
Radek Fučík

We present Template Numerical Library (TNL, www.tnl-project.org) with native support of modern parallel architectures like multi–core CPUs and GPUs. The library offers an abstract layer for accessing these architectures via unified interface tailored for easy and fast development of high-performance algorithms and numerical solvers. The library is written in C++ and it benefits from template meta–programming techniques. In this paper, we present the most important data structures and algorithms in TNL together with scalability on multi–core CPUs and speed–up on GPUs supporting CUDA.


2021 ◽  
Author(s):  
Taher Mun ◽  
Nae-Chyun Chen ◽  
Ben Langmead

AbstractMotivationAs more population genetics datasets and population-specific references become available, the task of translating (“lifting”) read alignments from one reference coordinate system to another is becoming more common. Existing tools generally require a chain file, whereas VCF files are the more common way to represent variation. Existing tools also do not make effective use of threads, creating a post-alignment bottleneck.ResultsLevioSAM is a tool for lifting SAM/BAM alignments from one reference to another using a VCF file containing population variants. LevioSAM uses succinct data structures and scales efficiently to many threads. When run downstream of a read aligner, levioSAM completes in less than 13% the time required by an aligner when both are run with 16 threads.Availabilityhttps://github.com/alshai/[email protected], [email protected]


Author(s):  
V. Chandru ◽  
M. Manivannan ◽  
S. Manohar

Abstract Feature-based design has evolved as a fundamental paradigm for present-day CAD systems. Voxel-based modeling has many advantages over traditional representation schemes but lacks structural information which is lost in voxelization of the objects. In this paper, we propose to augment voxel models with features by a) storing the sequence of modeling operations along with voxel models and b) by defining feature operators. We have implemented these ideas in our prototype system Sirpi as regularised Minkowski operators using simple data structures and algorithms.


Sign in / Sign up

Export Citation Format

Share Document