Verification of the Redecoration Algorithm for Triangular Matrices

  • Ralph Matthes
  • Martin Strecker
Conference paper
Part of the Lecture Notes in Computer Science book series (LNCS, volume 4941)


Triangular matrices with a dedicated type for the diagonal elements can be profitably represented by a nested datatype, i.e., a heterogeneous family of inductive datatypes. These families are fully supported since the version 8.1 of the Coq theorem proving environment, released in 2007. Redecoration of triangular matrices has a succinct implementation in this representation, thus giving the challenge of proving it correct. This has been achieved within Coq, using also induction with measures. An axiomatic approach allowed a verification in the Isabelle theorem prover, giving insights about the differences of both systems.


Triangular Matrix List Length Recursive Call Triangular Matrice Proof Assistant 
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.
    Abel, A., Matthes, R.: Fixed points of type constructors and primitive recursion. In: Marcinkowski, J., Tarlecki, A. (eds.) CSL 2004. LNCS, vol. 3210, pp. 190–204. Springer, Heidelberg (2004)Google Scholar
  2. 2.
    Abel, A., Matthes, R., Uustalu, T.: Generalized iteration and coiteration for higher-order nested datatypes. In: Gordon, A.D. (ed.) FOSSACS 2003. LNCS, vol. 2620, pp. 54–68. Springer, Heidelberg (2003)CrossRefGoogle Scholar
  3. 3.
    Abel, A., Matthes, R., Uustalu, T.: Iteration and coiteration schemes for higher-order and nested datatypes. Theoretical Computer Science 333, 3–66 (2005)zbMATHCrossRefMathSciNetGoogle Scholar
  4. 4.
    Balaa, A., Bertot, Y.: Fix-point equations for well-founded recursion in type theory. In: Aagaard, M.D., Harrison, J. (eds.) TPHOLs 2000. LNCS, vol. 1869, pp. 1–16. Springer, Heidelberg (2000)CrossRefGoogle Scholar
  5. 5.
    Barthe, G., Courtieu, P.: Efficient reasoning about executable specifications in Coq. In: Carreño, V.A., Muñoz, C.A., Tahar, S. (eds.) TPHOLs 2002. LNCS, vol. 2410, pp. 31–46. Springer, Heidelberg (2002)CrossRefGoogle Scholar
  6. 6.
    Barthe, G., Forest, J., Pichardie, D., Rusu, V.: Defining and reasoning about recursive functions: A practical tool for the Coq proof assistant. In: Hagiya, M., Wadler, P. (eds.) FLOPS 2006. LNCS, vol. 3945, pp. 114–129. Springer, Heidelberg (2006)CrossRefGoogle Scholar
  7. 7.
    Berghofer, S., Wenzel, M.: Inductive datatypes in HOL - lessons learned in formal-logic engineering. In: Bertot, Y., Dowek, G., Hirschowitz, A., Paulin, C., Théry, L. (eds.) TPHOLs 1999. LNCS, vol. 1690, pp. 19–36. Springer, Heidelberg (1999)CrossRefGoogle Scholar
  8. 8.
    Bertot, Y., Castéran, P.: Interactive Theorem Proving and Program Development. Coq’Art: The Calculus of Inductive Constructions. Texts in Theoretical Computer Science. Springer, Heidelberg (2004)zbMATHGoogle Scholar
  9. 9.
    Bird, R., Meertens, L.: Nested datatypes. In: Jeuring, J. (ed.) MPC 1998. LNCS, vol. 1422, pp. 52–67. Springer, Heidelberg (1998)CrossRefGoogle Scholar
  10. 10.
    Coq Development Team: The Coq Proof Assistant Reference Manual Version 8.1. Project LogiCal, INRIA (2006), System available at:
  11. 11.
    Hinze, R.: Manufacturing datatypes. Journal of Functional Programming 11, 493–524 (2001)zbMATHCrossRefMathSciNetGoogle Scholar
  12. 12.
    Matthes, R., Strecker, M.: Coq and Isabelle development for Verification of the Redecoration Algorithm for Triangular Matrices (2007),
  13. 13.
    Nipkow, T., Paulson, L.C., Wenzel, M.T.: Isabelle/HOL. LNCS, vol. 2283. Springer, Heidelberg (2002)zbMATHGoogle Scholar
  14. 14.
    Slind, K.: Wellfounded schematic definitions. In: McAllester, D. (ed.) CADE 2000. LNCS, vol. 1831, pp. 45–63. Springer, Heidelberg (2000)CrossRefGoogle Scholar
  15. 15.
    Uustalu, T., Vene, V.: The dual of substitution is redecoration. In: Hammond, K., Curtis, S. (eds.) Trends in Functional Programming 3, Intellect, Bristol / Portland, OR, pp. 99–110 (2002)Google Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 2008

Authors and Affiliations

  • Ralph Matthes
    • 1
  • Martin Strecker
    • 1
  1. 1.Institut de Recherche en Informatique de Toulouse (IRIT)C.,N.,R.,S. et Université Paul Sabatier (Toulouse III)Toulouse Cedex 9

Personalised recommendations