libpoly a library for reasoning about polynomials
play

LIBPOLY: A LIBRARY FOR REASONING ABOUT POLYNOMIALS Dejan Jovanovi - PowerPoint PPT Presentation

LIBPOLY: A LIBRARY FOR REASONING ABOUT POLYNOMIALS Dejan Jovanovi Bruno Dutertre SRI International SMT Workshop 2017 OUTLINE INTRODUCTION LIBPOLY Working with Polynomials Constructing a Sign Table Cylindrical Algebraic Decomposition


  1. LIBPOLY: A LIBRARY FOR REASONING ABOUT POLYNOMIALS Dejan Jovanović Bruno Dutertre SRI International SMT Workshop 2017

  2. OUTLINE INTRODUCTION LIBPOLY Working with Polynomials Constructing a Sign Table Cylindrical Algebraic Decomposition CONCLUSION

  3. OUTLINE INTRODUCTION LIBPOLY Working with Polynomials Constructing a Sign Table Cylindrical Algebraic Decomposition CONCLUSION

  4. NON-LINEAR REASONING T x 20 1 T z T y MANY APPLICATIONS T x T z T y Example from Narkawicz, Muõz, Formal Verification of Conflict Detection Algorithms for Arbitrary Trajectories, 2012 1 ( t ) = 3 . 2484 + 270 . 7t + 433 . 12t 2 − 324 . 83999t 3 20 1 ( t ) = 15 . 1592 + 108 . 28t + 121 . 2736t 2 − 649 . 67999t 3 0 � 20 1 ( t ) = 38980 . 8 + 5414t − 21656t 2 + 32484t 3 2 ( t ) = 1 . 0828 − 135 . 35t + 234 . 9676t 2 2 + 3248 . 4t 3 40 000 2 ( t ) = 18 . 40759 − 230 . 6364t − 121 . 2736t 2 − 649 . 67999t 3 2 ( t ) = 40280 . 15999 − 10828t + 24061 . 9816t 2 − 32484t 3 39 500 39 000 0 D = 5 H = 1000 0 ≤ t ≤ 20 40 2 ( t )) 2 + ( T y 2 ( t )) 2 ≤ D 2 | T z 1 ( t ) − T z 2 ( t ) | ≤ H ( T x 1 ( t ) − T x 1 ( t ) − T y 60

  5. NON-LINEAR REASONING 1 T x T z T y T x MANY APPLICATIONS T z Example from Narkawicz, Muõz, Formal Verification of Conflict Detection Algorithms for Arbitrary Trajectories, 2012 20 RUN SMT SOLVER 319 T y 1 ( t ) = 3 . 2484 + 270 . 7t + 433 . 12t 2 − 324 . 83999t 3 20 1 ( t ) = 15 . 1592 + 108 . 28t + 121 . 2736t 2 − 649 . 67999t 3 0 � 20 1 ( t ) = 38980 . 8 + 5414t − 21656t 2 + 32484t 3 2 ( t ) = 1 . 0828 − 135 . 35t + 234 . 9676t 2 2 + 3248 . 4t 3 40 000 2 ( t ) = 18 . 40759 − 230 . 6364t − 121 . 2736t 2 − 649 . 67999t 3 t �→ 16384 ≈ 0 . 019470215 2 ( t ) = 40280 . 15999 − 10828t + 24061 . 9816t 2 − 32484t 3 39 500 39 000 0 D = 5 H = 1000 0 ≤ t ≤ 20 40 2 ( t )) 2 + ( T y 2 ( t )) 2 ≤ D 2 | T z 1 ( t ) − T z 2 ( t ) | ≤ H ( T x 1 ( t ) − T x 1 ( t ) − T y 60

  6. NON-LINEAR REASONING SMT TECHNIQUES Popular techniques in SMT (QF_NRA): Cylindrical Algebraic Decomposition (CAD): complete method, currently state-of-the-art; requires advanced polynomial operations. ◮ Interval reasoning: RASAT ◮ Linear reasoning + model-based refinement: CVC4 ◮ DPLL(T) + VTS: VERIT ◮ DPLL(T) + CAD: SMTRAT, VERIT ◮ MCSAT + CAD: Z3, YICES2

  7. NON-LINEAR REASONING SMT TECHNIQUES Popular techniques in SMT (QF_NRA): Cylindrical Algebraic Decomposition (CAD): ◮ Interval reasoning: RASAT ◮ Linear reasoning + model-based refinement: CVC4 ◮ DPLL(T) + VTS: VERIT ◮ DPLL(T) + CAD: SMTRAT, VERIT ◮ MCSAT + CAD: Z3, YICES2 ◮ complete method, currently state-of-the-art; ◮ requires advanced polynomial operations.

  8. NON-LINEAR REASONING SMT SOLVERS (2016) 1e+06 100000 10000 cumulative time (s) 1000 100 10 1 z3 yices2 0.1 smtrat rasat-0.4 0.01 rasat-0.3 cvc4 0.001 0 2000 4000 6000 8000 10000 benchmarks solved

  9. SMT SOLVERS (2017) NON-LINEAR REASONING 1e+06 100000 10000 cumulative time (s) 1000 100 10 1 yices2 0.1 z3 verit+rasat+redlog 0.01 cvc4 smtrat 0.001 0 2000 4000 6000 8000 10000 benchmarks solved

  10. NON-LINEAR REASONING CAD-BASED REASONING 2. Basic operations: 3. Solving and model representation: 4. Projection and symbolic explanations: 1. Representation of polynomials. ◮ variables, variable ordering; ◮ arithmetic (addition, multiplication, …); ◮ GCD computation; ◮ some factorization. ◮ Sturm sequences; ◮ interval reasoning; ◮ root isolation (multivariate); ◮ resultants; ◮ computation with algebraic numbers. ◮ principal subresultant coefgicients.

  11. NON-LINEAR REASONING CAD-BASED REASONING Use LIBPOLY Implement yourself Borrow and adapt code Use a computer algebra system Use an existing library HOW TO GET THESE? 4. Projection and symbolic explanations: . 2. Basic operations: 3. Solving and model representation: 1. Representation of polynomials. ◮ variables, variable ordering; ◮ arithmetic (addition, multiplication, …); ◮ GCD computation; ◮ some factorization. ◮ Sturm sequences; ◮ interval reasoning; ◮ root isolation (multivariate); ◮ resultants; ◮ computation with algebraic numbers. ◮ principal subresultant coefgicients.

  12. NON-LINEAR REASONING CAD-BASED REASONING Use LIBPOLY Implement yourself Borrow and adapt code Use a computer algebra system HOW TO GET THESE? 4. Projection and symbolic explanations: . 3. Solving and model representation: 2. Basic operations: 1. Representation of polynomials. ◮ variables, variable ordering; ◮ arithmetic (addition, multiplication, …); ◮ GCD computation; ◮ some factorization. ◮ Use an existing library ◮ Sturm sequences; ◮ interval reasoning; ◮ root isolation (multivariate); ◮ resultants; ◮ computation with algebraic numbers. ◮ principal subresultant coefgicients.

  13. NON-LINEAR REASONING CAD-BASED REASONING Use LIBPOLY Implement yourself Borrow and adapt code Use a computer algebra system HOW TO GET THESE? 4. Projection and symbolic explanations: . 3. Solving and model representation: 2. Basic operations: 1. Representation of polynomials. ◮ variables, variable ordering; ◮ arithmetic (addition, multiplication, …); ◮ GCD computation; ◮ some factorization. ◮ Use an existing library � ◮ Sturm sequences; ◮ interval reasoning; ◮ root isolation (multivariate); ◮ resultants; ◮ computation with algebraic numbers. ◮ principal subresultant coefgicients.

  14. NON-LINEAR REASONING CAD-BASED REASONING Use LIBPOLY Implement yourself Borrow and adapt code HOW TO GET THESE? 4. Projection and symbolic explanations: . 2. Basic operations: 3. Solving and model representation: 1. Representation of polynomials. ◮ variables, variable ordering; ◮ arithmetic (addition, multiplication, …); ◮ GCD computation; ◮ some factorization. ◮ Use an existing library � ◮ Sturm sequences; ◮ Use a computer algebra system ◮ interval reasoning; ◮ root isolation (multivariate); ◮ resultants; ◮ computation with algebraic numbers. ◮ principal subresultant coefgicients.

  15. NON-LINEAR REASONING CAD-BASED REASONING Use LIBPOLY Implement yourself Borrow and adapt code HOW TO GET THESE? 4. Projection and symbolic explanations: . 2. Basic operations: 3. Solving and model representation: 1. Representation of polynomials. ◮ variables, variable ordering; ◮ arithmetic (addition, multiplication, …); ◮ GCD computation; ◮ some factorization. ◮ Use an existing library � ◮ Use a computer algebra system � ◮ Sturm sequences; ◮ interval reasoning; ◮ root isolation (multivariate); ◮ resultants; ◮ computation with algebraic numbers. ◮ principal subresultant coefgicients.

  16. NON-LINEAR REASONING 3. Solving and model representation: Use LIBPOLY Implement yourself HOW TO GET THESE? 4. Projection and symbolic explanations: CAD-BASED REASONING . 2. Basic operations: 1. Representation of polynomials. ◮ variables, variable ordering; ◮ arithmetic (addition, multiplication, …); ◮ GCD computation; ◮ some factorization. ◮ Use an existing library � ◮ Use a computer algebra system � ◮ Sturm sequences; ◮ interval reasoning; ◮ Borrow and adapt code ◮ root isolation (multivariate); ◮ resultants; ◮ computation with algebraic numbers. ◮ principal subresultant coefgicients.

  17. NON-LINEAR REASONING 3. Solving and model representation: Use LIBPOLY Implement yourself HOW TO GET THESE? 4. Projection and symbolic explanations: CAD-BASED REASONING . 2. Basic operations: 1. Representation of polynomials. ◮ variables, variable ordering; ◮ arithmetic (addition, multiplication, …); ◮ GCD computation; ◮ some factorization. ◮ Use an existing library � ◮ Use a computer algebra system � ◮ Sturm sequences; ◮ interval reasoning; ◮ Borrow and adapt code � ◮ root isolation (multivariate); ◮ resultants; ◮ computation with algebraic numbers. ◮ principal subresultant coefgicients.

  18. NON-LINEAR REASONING 3. Solving and model representation: Use LIBPOLY HOW TO GET THESE? 4. Projection and symbolic explanations: CAD-BASED REASONING . 2. Basic operations: 1. Representation of polynomials. ◮ variables, variable ordering; ◮ arithmetic (addition, multiplication, …); ◮ GCD computation; ◮ some factorization. ◮ Use an existing library � ◮ Use a computer algebra system � ◮ Sturm sequences; ◮ interval reasoning; ◮ Borrow and adapt code � ◮ root isolation (multivariate); ◮ Implement yourself � ◮ resultants; ◮ computation with algebraic numbers. ◮ principal subresultant coefgicients.

  19. NON-LINEAR REASONING HOW TO GET THESE? 2. Basic operations: 3. Solving and model representation: CAD-BASED REASONING 4. Projection and symbolic explanations: 1. Representation of polynomials. ◮ variables, variable ordering; ◮ arithmetic (addition, multiplication, …); ◮ GCD computation; ◮ some factorization. ◮ Use an existing library � ◮ Use a computer algebra system � ◮ Sturm sequences; ◮ interval reasoning; ◮ Borrow and adapt code � ◮ root isolation (multivariate); ◮ Implement yourself � ◮ resultants; ◮ computation with algebraic numbers. ◮ Use LIBPOLY � . ◮ principal subresultant coefgicients.

  20. OUTLINE INTRODUCTION LIBPOLY Working with Polynomials Constructing a Sign Table Cylindrical Algebraic Decomposition CONCLUSION

  21. LIBPOLY ◮ Open source: https://github.com/SRI-CSL/libpoly . ◮ Permissive License: LGLP ◮ Lightweight: Implemented in C, 15KLOC. ◮ Only depends on GMP. ◮ Basis for non-linear reasoning in YICES2.

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend