Higher-order unification with dependent function types

  • Conal M. Elliott
Regular Papers
Part of the Lecture Notes in Computer Science book series (LNCS, volume 355)


Roughly fifteen years ago, Huet developed a complete semidecision algorithm for unification in the simply typed λ-calculus (λ→). In spite of the undecidability of this problem, his algorithm is quite usable in practice. Since then, many important applications have come about in such areas as theorem proving, type inference, program transformation, and machine learning.

Another development is the discovery that by enriching λ to include dependent function types, the resulting calculus (λ) forms the basis of a very elegant and expressive Logical Framework, encompassing the syntax, rules, and proofs for a wide class of logics.

This paper presents an algorithm in the spirit of Huet's, for unification in λ. This algorithm gives us the best of both worlds: the automation previously possible in λ, and the greatly enriched expressive power of λ. It can be used to considerable advantage in many of the current applications of Huet's algorithm, and has important new applications as well. These include automated and semi-automated theorem proving in encoded logics, and automatic type inference in a variety of encoded languages.


Logical Framework Typing Rule Type Inference Disagreement Pair Type Check 
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.


Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.


  1. [1]
    Peter B. Andrews, Dale Miller, Eve Cohen, and Frank Pfenning. Automating higher-order logic. Contemporary Mathematics, 29:169–192, August 1984.Google Scholar
  2. [2]
    R. M. Burstall, D. B. MacQueen, and D. T. Sanella. HOPE: an Experimental Applicative Language. Technical Report CSR-62-80, Department of Computer Science, University of Edinburgh, Edinburgh, U.K., 1981.Google Scholar
  3. [3]
    Michael R. Donat and Lincoln A. Wallen. Learning and applying generalised solutions using higher order resolution. In Ewing Lusk and Ross Overbeek, editors, 9th International Conference on Automated Deduction, Argonne, Illinois, pages 41–60, Springer-Verlag LNCS 310, Berlin, May 1988.Google Scholar
  4. [4]
    Conal Elliott. Some Extensions and Applications of Higher-order Unification: A Thesis Proposal. Ergo Report 88-061, Carnegie Mellon University, Pittsburgh, June 1988. Thesis to appear June 1989.Google Scholar
  5. [5]
    Amy Felty and Dale A. Miller. Specifying theorem provers in a higher-order logic programming language. In Ewing Lusk and Ross Overbeek, editors, 9th International Conference on Automated Deduction, Argonne, Illinois, pages 61–80, Springer-Verlag LNCS 310, Berlin, May 1988.Google Scholar
  6. [6]
    Jean-Yves Girard. Une extensions de l'interpretation de Gödel a l'analyse, et son application a l'elimination des coupures dans l'analyse et la theorie des types. In J. E. Fenstad, editor, Proceedings of the Second Scandinavian Logic Symposium, pages 63–92, North-Holland Publishing Co., Amsterdam, London, 1971.Google Scholar
  7. [7]
    Warren D. Goldfarb. The undecidability of the second-order unification problem. Theoretical Computer Science, 13:225–230, 1981.Google Scholar
  8. [8]
    John Hannan and Dale Miller. Uses of higher-order unification for implementing program transformers. In Robert A. Kowalski and Kenneth A. Bowen, editors, Logic Programming: Proceedings of the Fifth International Conference and Symposium, Volume 2, pages 942–959, MIT Press, Cambridge, Massachusetts, August 1988.Google Scholar
  9. [9]
    Robert Harper. Standard ML. Technical Report ECS-LFCS-86-2, Laboratory for the Foundations of Computer Science, Edinburgh University, March 1986.Google Scholar
  10. [10]
    Robert Harper, Furio Honsell, and Gordon Plotkin. A framework for defining logics. In Symposium on Logic in Computer Science, pages 194–204, IEEE, June 1987.Google Scholar
  11. [11]
    J. Roger Hindley and Jonathan P. Seldin. Introduction to Combinators and λ-calculus. Cambridge University Press, 1986.Google Scholar
  12. [12]
    Gérard Huet. Résolution d'équations dans des langages d'ordre 1, 2, ..., ω. PhD thesis, Université Paris VII, September 1976.Google Scholar
  13. [13]
    Gérard Huet. A unification algorithm for typed λ-calculus. Theoretical Computer Science, 1:27–57, 1975.Google Scholar
  14. [14]
    Gérard Huet and Bernard Lang. Proving and applying program transformations expressed with second-order patterns. Acta Informatica, 11:31–55, 1978.Google Scholar
  15. [15]
    Dale Miller, Gopalan Nadathur, Frank Pfenning, and Andre Scedrov. Uniform proofs as a foundation for logic programming. Journal of Pure and Applied Logic, 1988. Submitted.Google Scholar
  16. [16]
    Dale A. Miller. Unification under mixed prefixes. 1987. Unpublished manuscript.Google Scholar
  17. [17]
    Robin Milner. A theory of type polymorphism in programming. Journal of Computer and System Sciences, 17:348–375, August 1978.Google Scholar
  18. [18]
    Gopalan Nadathur and Dale Miller. An overview of λProlog. In Robert A. Kowalski and Kenneth A. Bowen, editors, Logic Programming: Proceedings of the Fifth International Conference and Symposium, Volume 1, pages 810–827, MIT Press, Cambridge, Massachusetts, August 1988.Google Scholar
  19. [19]
    Lawrence C. Paulson. The Representation of Logics in Higher-Order Logic. Technical Report 113, University of Cambridge, Cambridge, England, August 1987.Google Scholar
  20. [20]
    Frank Pfenning. Elf: A Language for Logic Definition and Verified Meta-Programming. Ergo Report 88-067, Carnegie Mellon University, Pittsburgh, Pennsylvania, October 1988.Google Scholar
  21. [21]
    Frank Pfenning. Partial polymorphic type inference and higher-order unification. In Proceedings of the 1988 ACM Conference on Lisp and Functional Programming, ACM Press, July 1988.Google Scholar
  22. [22]
    Frank Pfenning and Conal Elliott. Higher-order abstract syntax. In Proceedings of the SIGPLAN '88 Symposium on Language Design and Implementation, pages 199–208, ACM Press, June 1988. Available as Ergo Report 88-036.Google Scholar
  23. [23]
    Garrel Pottinger. Proof of the normalization and Church-Rosser theorems for the typed λ-calculus. Notre Dame Journal of Formal Logic, 19(3):445–451, July 1978.Google Scholar
  24. [24]
    David Pym. A unification algorithm for the logical framework. November 1988. Laboratory for Foundations of Computer Science, University of Edinburgh. To appear as LFCS report.Google Scholar
  25. [25]
    John Reynolds. Towards a theory of type structure. In Proc. Colloque sur la Programmation, pages 408–425, Springer-Verlag LNCS 19, New York, 1974.Google Scholar
  26. [26]
    Wayne Snyder. Complete Sets of Transformations for General Unification. PhD thesis, University of Pennsylvania, 1988.Google Scholar
  27. [27]
    Wayne Snyder and Jean H. Gallier. Higher-order unification revisited: complete sets of transformations. Journal of Symbolic Computation, 1988. To appear in the special issue on unification.Google Scholar
  28. [28]
    David A. Turner. Miranda: a non-strict functional lanugage with polymorphic types. In Functional Programming Languages and Computer Architecture, Springer-Verlag, Berlin, September 1985.Google Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 1989

Authors and Affiliations

  • Conal M. Elliott
    • 1
  1. 1.Department of Computer ScienceCarnegie Mellon UniversityPittsburgh

Personalised recommendations