ICFP '97 Proceedings of the second ACM SIGPLAN international conference on Functional programming
Functional reactive programming, continued
Proceedings of the 2002 ACM SIGPLAN workshop on Haskell
A foundation for embedded languages
ACM Transactions on Programming Languages and Systems (TOPLAS)
PADL '03 Proceedings of the 5th International Symposium on Practical Aspects of Declarative Languages
SAIG '00 Proceedings of the International Workshop on Semantics, Applications, and Implementation of Program Generation
Modular Domain Specific Languages and Tools
ICSR '98 Proceedings of the 5th International Conference on Software Reuse
SUNDIALS: Suite of nonlinear and differential/algebraic equation solvers
ACM Transactions on Mathematical Software (TOMS) - Special issue on the Advanced CompuTational Software (ACTS) Collection
Why it's nice to be quoted: quasiquoting for haskell
Haskell '07 Proceedings of the ACM SIGPLAN workshop on Haskell workshop
A type-preserving compiler in Haskell
Proceedings of the 13th ACM SIGPLAN international conference on Functional programming
Paradise: a two-stage DSL embedded in Haskell
Proceedings of the 13th ACM SIGPLAN international conference on Functional programming
Flask: staged functional programming for sensor networks
Proceedings of the 13th ACM SIGPLAN international conference on Functional programming
Embedding a functional hybrid modelling language in Haskell
IFL'08 Proceedings of the 20th international conference on Implementation and application of functional languages
Mathematical equations as executable models of mechanical systems
Proceedings of the 1st ACM/IEEE International Conference on Cyber-Physical Systems
Haskell boards the ferry: database-supported program execution for Haskell
IFL'10 Proceedings of the 22nd international conference on Implementation and application of functional languages
Keeping calm in the face of change
Higher-Order and Symbolic Computation
Towards a formal semantics for a structurally dynamic noncausal modelling language
TLDI '12 Proceedings of the 8th ACM SIGPLAN workshop on Types in language design and implementation
Hi-index | 0.00 |
This paper explores how to implement an iteratively staged domain-specific language (DSL) by embedding into a functional language. The domain is modelling and simulation of physical systems where models are expressed in terms of non-causal differential-algebraic equations; i.e., sets of constraints solved through numerical simulation. What distinguishes our language is that the equational constraints are first class entities allowing for an evolving model structure characterised by repeated generation of updated constraints. Hence iteratively staged. Our DSL can thus be seen as a combined functional and constraint programming language, albeit a two-level one, with the functional language chiefly serving as a meta language. However, the two levels do interact throughout the simulation. The embedding strategy we pursue is a mixture of deep and shallow, with the deep embedding enabling justin-time (JIT) compilation of the constraints as they are generated for efficiency, while the shallow embedding is used for the remainder for maximum leverage of the host language. The paper is organised around a specific DSL, but our implementation strategy should be applicable for iteratively staged languages in general. Our DSL itself is further a novel variation of a declarative constraint programming language.