Verified Quadratic Virtual Substitution for Real Arithmetic

This paper presents a formally verified quantifier elimination (QE) algorithm for first-order real arithmetic by linear and quadratic virtual substitution (VS) in Isabelle/HOL. The Tarski-Seidenberg theorem established that the first-order logic of real arithmetic is decidable by QE. However, in practice, QE algorithms are highly complicated and often combine multiple methods for performance. VS is a practically successful method for QE that targets formulas with low-degree polynomials. To our knowledge, this is the first work to formalize VS for quadratic real arithmetic including inequalities. The proofs necessitate various contributions to the existing multivariate polynomial libraries in Isabelle/HOL. Our framework is modularized and easily expandable (to facilitate integrating future optimizations), and could serve as a basis for developing practical general-purpose QE algorithms. Further, as our formalization is designed with practicality in mind, we export our development to SML and test the resulting code on 378 benchmarks from the literature, comparing to Redlog, Z3, Wolfram Engine, and SMT-RAT. This identified inconsistencies in some tools, underscoring the significance of a verified approach for the intricacies of real arithmetic.

[1]  Matthew England,et al.  Algorithmically Generating New Algebraic Features of Polynomial Systems for Machine Learning , 2019, SC-square@SIAM AG.

[2]  Thomas Sturm,et al.  REDLOG: computer algebra meets computer logic , 1997, SIGS.

[3]  André Platzer,et al.  Logical Analysis of Hybrid Systems - Proving Theorems for Complex Dynamics , 2010 .

[4]  André Platzer,et al.  Logical Foundations of Cyber-Physical Systems , 2018, Springer International Publishing.

[5]  Edmund M. Clarke,et al.  dReal: An SMT Solver for Nonlinear Theories over the Reals , 2013, CADE.

[6]  George E. Collins,et al.  Hauptvortrag: Quantifier elimination for real closed fields by cylindrical algebraic decomposition , 1975, Automata Theory and Formal Languages.

[7]  Volker Weispfenning,et al.  Quantifier elimination for real algebra—the cubic case , 1994, ISSAC '94.

[8]  Matthew England,et al.  Quantifier Elimination for Reasoning in Economics , 2018, ArXiv.

[9]  Dejan Jovanović,et al.  Solving Non-linear Arithmetic , 2012, IJCAR.

[10]  Thomas Sturm,et al.  A Survey of Some Methods for Real Quantifier Elimination, Decision, and Satisfiability and Their Applications , 2017, Math. Comput. Sci..

[11]  Grant Olney Passmore,et al.  Combined decision procedures for nonlinear arithmetics, real and complex , 2011 .

[12]  Sebastian Junges,et al.  SMT-RAT: An Open Source C++ Toolbox for Strategic and Parallel SMT Solving , 2015, SAT.

[13]  Nathan Fulton,et al.  KeYmaera X: An Axiomatic Tactical Theorem Prover for Hybrid Systems , 2015, CADE.

[14]  Amine Chaieb,et al.  Automated methods for formal proofs in simple arithmetics and algebra (Automatische Methoden für formale Beweise in einfachen Arithmetiken und Algebren) , 2008 .

[15]  A. Seidenberg A NEW DECISION METHOD FOR ELEMENTARY ALGEBRA , 1954 .

[16]  Tobias Nipkow,et al.  Linear Quantifier Elimination , 2008, Journal of Automated Reasoning.

[17]  Marek Kosta,et al.  New concepts for real quantifier elimination by virtual substitution , 2016 .

[18]  John Harrison,et al.  A Proof-Producing Decision Procedure for Real Arithmetic , 2005, CADE.

[19]  Tobias Nipkow,et al.  A Verified Compiler from Isabelle/HOL to CakeML , 2018, ESOP.

[20]  Antonio José Durán Guardeño,et al.  The Misfortunes of a Trio of Mathematicians Using Computer Algebra Systems. Can We Trust in Them , 2014 .

[21]  Thomas Sturm,et al.  Thirty Years of Virtual Substitution: Foundations, Techniques, Applications , 2018, ISSAC.

[22]  René Thiemann,et al.  Executable Multivariate Polynomials , 2010, Arch. Formal Proofs.

[23]  George E. Collins,et al.  Quantifier elimination for real closed fields by cylindrical algebraic decomposition , 1975 .

[24]  Volker Weispfenning,et al.  Quantifier Elimination for Real Algebra — the Quadratic Case and Beyond , 1997, Applicable Algebra in Engineering, Communication and Computing.

[25]  André Platzer,et al.  Real World Verification , 2009, CADE.

[26]  Assia Mahboubi,et al.  Formal proofs in real algebraic geometry: from ordered fields to quantifier elimination , 2012, Log. Methods Comput. Sci..

[27]  Stefan Ratschan,et al.  Verification-Integrated Falsification of non-Deterministic Hybrid Systems , 2006, ADHS.

[28]  Nikolaj Bjørner,et al.  Z3: An Efficient SMT Solver , 2008, TACAS.

[29]  Volker Weispfenning,et al.  The Complexity of Linear Problems in Fields , 1988, Journal of symbolic computation.

[30]  A. Tarski A Decision Method for Elementary Algebra and Geometry , 2023 .

[31]  André Platzer,et al.  Formally verified differential dynamic logic , 2017, CPP.