Skip to main content

Advertisement

Log in

Analysis of Linear Definite Iterative Loops

  • SOFTWARE–HARDWARE SYSTEMS
  • Published:
Cybernetics and Systems Analysis Aims and scope

Abstract

The paper presents a new method to prove the invariance of the system of linear inequalities and completability of linear definite iterative loops for imperative programs. Loop body is a linear operator that transforms the vector of program variables. The method takes into account loop precondition, as well as the condition of loop repetition in the form of a set of systems of linear inequalities. The method is based on the construction and analysis of the spectrum of linear operator and calculation of the number of loop iterations after which the invariance is either provided or disproved. The theory is illustrated by examples.

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Similar content being viewed by others

References

  1. R. W. Floyd, “Assigning meanings to programs,” in: J. T. Schwartz (ed.), Proc. Symp. on Applied Mathematics, 19, American Math. Society, Providence (1967), pp. 19–32.

  2. C. A. R. Hoare, “An axiomatic basis for computer programming,” Communications of the ACM, 12, No. 10, 576–580 (1969).

  3. A. B. Godlevskii, Yu. V. Kapitonova, S. L. Krivoy, and A. A. Letichevskii, “Iterative methods of program analysis,” Cybernetics, 25, No. 2, 139–152 (1989).

    Article  MathSciNet  Google Scholar 

  4. M. S. L’vov, “Invariant equalities of small degrees in programs defined over a field,” Kibernetika, No. 1, 108–110 (1988).

  5. A. Letichevsky and M. Lvov, “Discovery of invariant equalities in programs over data fields,” Applicable Algebra in Engineering, Communication and Computing, No. 4, 21–29 (1993).

  6. M. Lvov, “About one algorithm of program polynomial invariants generation,” in: M. Giese and T. Jebelean (eds.), Proc. Workshop on Invariant Generation, WING 2007, Technical Report No. 07-07 in RISC Report Series, University of Linz, Austria, June 2007, Workshop Proc. (2007), pp. 85–99.

  7. M. Muller-Olm and H. Seidl, “Computing polynomial program invariants,” Inf. Process. Lett., 91, No. 5, 233–244 (2004).

    Article  MathSciNet  MATH  Google Scholar 

  8. M. Muller-Olm and H. Seidl, “Precise interprocedural analysis through linear algebra,” in: Proc. 31st ACM SIGPLAN-SIGACT Symp. on Principles of Programming Languages, SIGPLAN Notices, POPL ‘04, 39, No. 1, (2004), pp. 330–341.

  9. S. Sankaranarayanan, H. Sipma, and Z. Manna, “Non-linear loop invariant generation using Grobner bases,” in: Proc. Symp. on Principles of Programming Languages, Venice, Italy, January 14–16, 2004, ACM, New York (2004), pp. 318–329.

  10. E. Rodríguez-Carbonell and D. Kapur, “Automatic generation of polynomial loop invariants: algebraic foundations,” in: Proc. Intern. Symp. on Symbolic and Algebraic Computation, Santander, Spain, July 4–7, 2004, ACM, New York (2004), pp. 266–273.

  11. L. I. Kovács and T. Jebelean, “An algorithm for automated generation of invariants for loops with conditionals,” in: Proc. Intern. Symp. on Symbolic and Numeric Algorithms for Scientific Computing, Timisoara, Romania, Sept. 25–29, 2005, IEEE Computer Society (2005), pp. 245–249.

  12. M. S. Lvov, “Polynomial invariants for linear loops,” Cybern. Syst. Analysis, 46, No. 4, 660–668 (2010).

    Article  MathSciNet  MATH  Google Scholar 

  13. M. S. Lvov and V. A. Kreknin, “Nonlinear invariants for linear loops and eigenpolynomials of linear operators,” Cybern. Syst. Analysis, 48, No. 2, 268–281 (2012).

    Article  MathSciNet  MATH  Google Scholar 

  14. P. Cousot and N. Halbwachs, “Automatic discovery of linear restraints among variables of a program,” in: Conf. Record of the 5th Annual ACM SIGPLAN-SIGACT Symp. on Principles of Programming Languages, Tucson, Arizona, ACM Press, New York (1978), pp. 84–97.

  15. S. L. Krivoi and S. G. Raksha, “Search for invariant linear relationships in programs,” Cybernetics, 20, No. 6, 796–803 (1984).

    Article  MathSciNet  MATH  Google Scholar 

  16. A. B. Godlevskii, Yu. V. Kapitonova, S. L. Krivoi, and A. A. Letichevskii, “Iterative methods of program analysis. Equalities and inequalities,” Cybernetics, 26, No. 3, 307–318 (1990).

    Article  MathSciNet  Google Scholar 

  17. M. S. L’vov, “Invariant inequalities in programs interpreted over an ordered field,” Cybernetics, 22, No. 5, 560–567 (1986).

    Article  MathSciNet  MATH  Google Scholar 

  18. M. S. Lvov, “On invariant inequalities for states of schemes of programs interpreted over a vector space,” Kibernetika, 21, No. 2, 111–112 (1985).

    Google Scholar 

  19. M. S. Lvov, “A method of proving the invariance of linear inequalities for linear loops,” Cybern. Syst. Analysis, 50, No. 4, 643–648 (2014).

    Article  MathSciNet  MATH  Google Scholar 

  20. A. V. Robinson, An Introduction to the Models Theory and Algebra Metamathematics [Russian translation], Nauka, GRFML, Moscow (1967).

  21. B. L. van der Waerden, Algebra, Springer (2003).

  22. W. V. D. Hodge and D. Pedoe, Methods of Algebraic Geometry, Vol. 1, Cambridge Univ. Press (1994).

  23. B. Buchberger, G. E. Collins, R. Loos, and R. Albrecht (eds.), Computer Algebra: Symbolic and Algebraic Computation, Springer (1983).

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to M. S. Lvov.

Additional information

Translated from Kibernetika i Sistemnyi Analiz, No. 1, January–February, 2016, pp. 122–136.

Rights and permissions

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Lvov, M.S. Analysis of Linear Definite Iterative Loops. Cybern Syst Anal 52, 113–126 (2016). https://doi.org/10.1007/s10559-016-9806-5

Download citation

  • Received:

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s10559-016-9806-5

Keywords

Navigation