1,536 research outputs found

    Type-Directed Weaving of Aspects for Polymorphically Typed Functional Languages

    Get PDF
    Incorporating aspect-oriented paradigm to a polymorphically typed functional language enables the declaration of type-scoped advice, in which the effect of an aspect can be harnessed by introducing possibly polymorphic type constraints to the aspect. The amalgamation of aspect orientation and functional programming enables quick behavioral adaption of functions, clear separation of concerns and expressive type-directed programming. However, proper static weaving of aspects in polymorphic languages with a type-erasure semantics remains a challenge. In this paper, we describe a type-directed static weaving strategy, as well as its implementation, that supports static type inference and static weaving of programs written in an aspect-oriented polymorphically typed functional language, AspectFun. We show examples of type-scoped advice, identify the challenges faced with compile-time weaving in the presence of type-scoped advice, and demonstrate how various advanced aspect features can be handled by our techniques. Lastly, we prove the correctness of the static weaving strategy with respect to the operational semantics of AspectFun

    Quantifying and Comparing Water Transit Time Distributions in Urban Beaver and Stormwater Retention Ponds in the Atlanta, GA Metropolitan Area

    Get PDF
    Best management practices, including stormwater ponds, are implemented to mitigate the effects of urban stormwater. While these structures may effectively modulate local surface runoff, empirical analyses suggest their cumulative effect on watershed-scale streamflow is marginal. Beaver impoundments, by altering the downstream hydrologic flow regime, may offer a natural, complementary means of managing stormwater. This study seeks to determine how the transit times of water traversing urban beaver ponds compares to those occurring within stormwater ponds, by adding a conservative tracer (Br-) near-instantaneously at inflow points to three beaver impoundments and two stormwater ponds in Atlanta, GA in dry (fall) and wet (spring) seasonal conditions. The expected difference in flow due to seasonal conditions was not observed at all sites. Transit times were longer in the stormwater ponds than the beaver ponds in both seasons, and both pond types show altered flow path configurations due to short term weather dynamics

    Classical Mathematics for a Constructive World

    Full text link
    Interactive theorem provers based on dependent type theory have the flexibility to support both constructive and classical reasoning. Constructive reasoning is supported natively by dependent type theory and classical reasoning is typically supported by adding additional non-constructive axioms. However, there is another perspective that views constructive logic as an extension of classical logic. This paper will illustrate how classical reasoning can be supported in a practical manner inside dependent type theory without additional axioms. We will see several examples of how classical results can be applied to constructive mathematics. Finally, we will see how to extend this perspective from logic to mathematics by representing classical function spaces using a weak value monad.Comment: v2: Final copy for publicatio

    README

    Get PDF
    Public Data used in the manuscript: The Effect of Advection on the Three Dimensional Distribution of Turbulent Kinetic Energy and its Generation in Idealized Tropical Cyclone Simulations. The data in this repository is for the four runs analyzed the manuscript: CAT5-WA, CAT5-NA, CAT1-WA, CAT1-NA. CAT5 represents the category-5 simulations and CAT-1 represents the category-1 simulations. -WA represents simulations with TKE advection and -NA represents simulations without TKE advection turned on. All the simulations run for 6 days and an individual NETCDF file of post-processed relevant variables is made for every half day. The first 12 hours per day are noted under the file extension “_P1” and the second 12 hours per day are noted under the file extension “_P2”. That means there are 12 files per simulation for a total of 48 files. Each file is gziped for space. The total space of the uncompressed files is about ~875 GB. Only data from the innermost domain is shown which is solely what the manuscript analyzes. The variables in each file are: heights: interpolated heights for all of the 4-D variables u_east: zonal wind speed v_north: meridional wind speed w_up: vertical wind speed tke: turbulent kinetic energy tke_shear: shear budget term of TKE tke_buoy: buoyancy budget term of TKE tke_diss: dissipation budget term of TKE tke_wt: vertical transport budget term of TKE dtke: change in TKE between time steps the_advect: calculated advection of TKE Psfc: surface pressure Pressure: full pressure field u10: zonal wind speed at 10-m altitude v10: meridional wind speed at 10-m altitude reflectivity: simulated radar reflectivity Temperature: air temperature Theta_e: air equivalent potential temperature (θe) sst: sea surface temperature ocean_temperature: full ocean temperature profile ocean_levels: ocean vertical levels latentHF: latent heat flux sensibleHF: sensible heat flu

    Enhancing Semantic Bidirectionalization via Shape Bidirectionalizer Plug-ins

    Get PDF
    Matsuda et al. (2007) and Voigtlander (2009) have introduced two techniques that given a source-to-view function provide an update propagation function mapping an original source and an updated view back to an updated source, subject to standard consistency conditions. Previously, we developed a synthesis of the two techniques, based on a separation of shape and content aspects (Voigtlander et al. 2010). Here, we carry that idea further, reworking the technique of Voigtlander such that any shape bidirectionalizer (based on the work of Matsuda et al. or not) can be used as a plug-in, to good effect. We also provide a data-type-generic account, enabling wider reuse, including the use of pluggable bidirectionalization itself as a plug-in

    Type-safe pattern combinators

    Get PDF

    Proofs are Programs: 19th Century Logic and 21st Century Computing

    Get PDF
    As the 19th century drew to a close, logicians formalized an ideal notion of proof. They were driven by nothing other than an abiding interest in truth, and their proofs were as ethereal as the mind of God. Yet within decades these mathematical abstractions were realized by the hand of man, in the digital stored-program computer. How it came to be recognized that proofs and programs are the same thing is a story that spans a century, a chase with as many twists and turns as a thriller. At the end of the story is a new principle for designing programming languages that will guide computers into the 21st century. For my money, Gentzen’s natural deduction and Church’s lambda calculus are on a par with Einstein’s relativity and Dirac’s quantum physics for elegance and insight. And the maths are a lot simpler. I want to show you the essence of these ideas. I’ll need a few symbols, but not too many, and I’ll explain as I go along. To simplify, I’ll present the story as we understand it now, with some asides to fill in the history. First, I’ll introduce Gentzen’s natural deduction, a formalism for proofs. Next, I’ll introduce Church’s lambda calculus, a formalism for programs. Then I’ll explain why proofs and programs are really the same thing, and how simplifying a proof corresponds to executing a program. Finally, I’ll conclude with a look at how these principles are being applied to design a new generation of programming languages, particularly mobile code for the Internet

    The Educational Pearls column

    Get PDF

    The call-by-need lambda calculus

    Get PDF
    corecore