Programming in Martin-Lo¨f's type theory: an introduction
Programming in Martin-Lo¨f's type theory: an introduction
QuickCheck: a lightweight tool for random testing of Haskell programs
ICFP '00 Proceedings of the fifth ACM SIGPLAN international conference on Functional programming
Verifying Haskell Programs by Combining Testing and Proving
QSIC '03 Proceedings of the Third International Conference on Quality Software
Universes for generic programs and proofs in dependent type theory
Nordic Journal of Computing
A logical framework with dependently typed records
TLCA'03 Proceedings of the 6th international conference on Typed lambda calculi and applications
Testing and proving distributed algorithms in constructive type theory
TAP'07 Proceedings of the 1st international conference on Tests and proofs
Hi-index | 0.01 |
We show how to write surjective random generators for several different classes of inductively defined types in dependent type theory. We discuss both non-indexed (simple) types and indexed families of types. In particular we show how to use the relationship between indexed inductive definitions and logic programs: the indexed inductive definition of a type family corresponds to a logic program, and generating an object of a type in the family corresponds to solving a query for the logic program. As an example, we show how to write a surjective random generator for theorems in propositional logic by randomising the Prolog search algorithm.