Information and Computation - Semantics of Data Types
How to make ad-hoc polymorphism less ad hoc
POPL '89 Proceedings of the 16th ACM SIGPLAN-SIGACT symposium on Principles of programming languages
Theoretical Computer Science
IEEE Transactions on Computers
Testing monadic code with QuickCheck
ACM SIGPLAN Notices
Isomorphisms, hylomorphisms and hereditarily finite data types in Haskell
Proceedings of the 2009 ACM symposium on Applied Computing
An embedded declarative data transformation language
PPDP '09 Proceedings of the 11th ACM SIGPLAN conference on Principles and practice of declarative programming
Pure, declarative, and constructive arithmetic relations (declarative pearl)
FLOPS'08 Proceedings of the 9th international conference on Functional and logic programming
Emulating primality with multiset representations of natural numbers
ICTAC'11 Proceedings of the 8th international conference on Theoretical aspects of computing
Proceedings of the 27th Annual ACM Symposium on Applied Computing
Binary trees as a computational framework
Computer Languages, Systems and Structures
Hi-index | 0.00 |
A common foundation of finite arithmetic, hereditarily finite sets and sequences, binary trees and graphs is described as a progressive refinement of Haskell type classes. We derive as instances symbolic implementations of arithmetic operations in terms of rooted ordered trees representing hereditarily finite sets and sequences. Conversely, arithmetic implementations of pairs, powersets, von Neumann ordinals shade new light on the bi-interpretability between Peano arithmetic and a theory of hereditarily finite sets. As another instance, rooted ordered binary trees representing a simplified form of the type language of Goedel's System T are shown as directly emulating arithmetic and finite set operations. The main contribution of the paper is a fully constructive unification of paradigms - a chain of type classes does it all: Peano arithmetic, sets, sequences, binary trees, bitstrings. Another contribution is that we do it "efficiently" (i.e. in time and space asymptotically comparable with standard binary representations). The Haskell code in the paper is available at http://logic.cse.unt.edu/tarau/research/2010/shared.hs.