Polynomial Invariants by Linear Algebra

  • Steven de OliveiraEmail author
  • Saddek Bensalem
  • Virgile Prevosto
Conference paper
Part of the Lecture Notes in Computer Science book series (LNCS, volume 9938)


We present in this paper a new technique for generating polynomial invariants, divided in two independent parts: a procedure that reduces polynomial assignments composed loops analysis to linear loops under certain hypotheses and a procedure for generating inductive invariants for linear loops. Both of these techniques have a polynomial complexity for a bounded number of variables and we guarantee the completeness of the technique for a bounded degree which we successfully implemented for C programs verification.


Affine Transformation Rational Matrix Invariant Generation Polynomial Invariant Program Verification 
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.


  1. 1.
    Alur, R., Etessami, K., Madhusudan, P.: A temporal logic of nested calls and returns. In: Jensen, K., Podelski, A. (eds.) TACAS 2004. LNCS, vol. 2988, pp. 467–481. Springer, Heidelberg (2004)CrossRefGoogle Scholar
  2. 2.
    Basu, S.K., Misra, J.: Proving loop programs. IEEE Trans. Softw. Eng. 1(1), 76–86 (1975)MathSciNetCrossRefGoogle Scholar
  3. 3.
    Beyer, D., Henzinger, T.A., Majumdar, R., Rybalchenko, A.: Path invariants. In: ACM SIGPLAN Conference on Programming Language Design and Implementation, pp. 300–309 (2007)Google Scholar
  4. 4.
    Botella, B., Delahaye, M., Ha, S.H.T., Kosmatov, N., Mouy, P., Roger, M., Williams, N.: Automating structural testing of C programs: experience with PathCrawler. In: 4th International Workshop on Automation of Software Test, AST, pp. 70–78 (2009)Google Scholar
  5. 5.
    Cachera, D., Jensen, T.P., Jobin, A., Kirchner, F.: Inference of polynomial invariants for imperative programs: a farewell to Gröbner bases. Sci. Comput. Program. 93, 89–109 (2014)CrossRefGoogle Scholar
  6. 6.
    Carbonell, E.: Polynomial invariant generation.
  7. 7.
    Clarke, E.M., Grumberg, O., Jha, S., Lu, Y., Veith, H.: Counterexample-guided abstraction refinement. CAV 2000, 154–169 (2000)zbMATHGoogle Scholar
  8. 8.
    Cooper, K.D., Simpson, L.T., Vick, C.A.: Operator strength reduction. ACM Trans. Program. Lang. Syst. 23(5), 603–625 (2001)CrossRefGoogle Scholar
  9. 9.
    de Oliveira, S., Bensalem, S., Prevosto, V.: Polynomial invariants by linear algebra. Technical report 16–0065/SDO, CEA (2016).
  10. 10.
    Hoare, C.A.R.: An axiomatic basis for computer programming. Commun. ACM 12(10), 576–580 (1969)CrossRefzbMATHGoogle Scholar
  11. 11.
    Hoare, C.A.R.: The verifying compiler: a grand challenge for computing research. J. ACM 50(1), 63–69 (2003)CrossRefzbMATHGoogle Scholar
  12. 12.
    Hojjat, H., Iosif, R., Konečný, F., Kuncak, V., Rümmer, P.: Accelerating interpolants. In: Chakraborty, S., Mukund, M. (eds.) ATVA 2012. LNCS, vol. 7561, pp. 187–202. Springer, Heidelberg (2012)CrossRefGoogle Scholar
  13. 13.
    Johnson, D.B.: Finding all the elementary circuits of a directed graph. SIAM J. Comput. 4(1), 77–84 (1975)MathSciNetCrossRefzbMATHGoogle Scholar
  14. 14.
    Kauers, M., Zimmermann, B.: Computing the algebraic relations of C-finite sequences and multisequences. J. Symb. Comput. 43(11), 787–803 (2008)MathSciNetCrossRefzbMATHGoogle Scholar
  15. 15.
    Kirchner, F., Kosmatov, N., Prevosto, V., Signoles, J., Yakobowski, B.: Frama-C: a software analysis perspective. Formal Aspects Comput. 27(3), 573–609 (2015)MathSciNetCrossRefGoogle Scholar
  16. 16.
    Kovács, L.: Aligator: a mathematica package for invariant generation (system description). In: Armando, A., Baumgartner, P., Dowek, G. (eds.) IJCAR 2008. LNCS (LNAI), vol. 5195, pp. 275–282. Springer, Heidelberg (2008)CrossRefGoogle Scholar
  17. 17.
    Kovács, L.: A complete invariant generation approach for P-solvable loops. In: Pnueli, A., Virbitskaite, I., Voronkov, A. (eds.) PSI 2009. LNCS, vol. 5947, pp. 242–256. Springer, Heidelberg (2010)CrossRefGoogle Scholar
  18. 18.
    Mayr, E.: Membership in polynomial ideals over Q is exponential space complete. In: Monien, B., Cori, R. (eds.) STACS 1989. LNCS, vol. 349, pp. 400–406. Springer, Heidelberg (1989)Google Scholar
  19. 19.
    Müller-Olm, M., Seidl, H.: Polynomial constants are decidable. In: Hermenegildo, M.V., Puebla, G. (eds.) SAS 2002. LNCS, vol. 2477, pp. 4–19. Springer, Heidelberg (2002)CrossRefGoogle Scholar
  20. 20.
    Müller-Olm, M., Seidl, H.: Precise interprocedural analysis through linear algebra. POPL 2004, 330–341 (2004)zbMATHGoogle Scholar
  21. 21.
    Pan, V.Y., Chen, Z.Q.: The complexity of the matrix eigenproblem. In: Proceedings of the Thirty-First Annual ACM Symposium on Theory of Computing, May 1–4, Atlanta, Georgia, USA, pp. 507–516 (1999)Google Scholar
  22. 22.
    Rodríguez-Carbonell, E., Kapur, D.: Generating all polynomial invariants in simple loops. J. Symbolic Comput. 42(4), 443–476 (2007)MathSciNetCrossRefzbMATHGoogle Scholar
  23. 23.
    Tarjan, R.E.: Depth-first search and linear graph algorithms. SIAM J. Comput. 1(2), 146–160 (1972)MathSciNetCrossRefzbMATHGoogle Scholar

Copyright information

© Springer International Publishing AG 2016

Authors and Affiliations

  • Steven de Oliveira
    • 1
    Email author
  • Saddek Bensalem
    • 2
  • Virgile Prevosto
    • 1
  1. 1.CEA, LIST, Software Reliability and Security LabGif Sur Yvette CedexFrance
  2. 2.Université Grenoble AlpesSaint-martin-d’hàresFrance

Personalised recommendations