Volume Computation for Boolean Combination of Linear Arithmetic Constraints
There are many works on the satisfiability problem for various logics and constraint languages, such as SAT and Satisfiability Modulo Theories (SMT). On the other hand, the counting version of decision problems is also quite important in automated reasoning. In this paper, we study a counting version of SMT, i.e., how to compute the volume of the solution space, given a set of Boolean combinations of linear constraints. The problem generalizes the model counting problem and the volume computation problem for convex polytopes. It has potential applications to program analysis and verification, as well as approximate reasoning, yet it has received little attention. We first give a straightforward method, and then propose an improved algorithm. We also describe two ways of incorporating theory-level lemma learning technique into the algorithm. They have been implemented, and some experimental results are given. Through an example program, we show that our tool can be used to compute how often a given program path is executed.
Unable to display preview. Download preview PDF.
- 2.Bacchus, F., Dalmao, S., Pitassi, T.: Algorithms and complexity results for #SAT and Bayesian inference. In: Proceedings of the 44th Symposium on Foundations of Computer Science (FOCS 2003), pp. 340–351 (2003)Google Scholar
- 4.Behle, M., Eisenbrand, F.: 0/1 vertex and facet enumeration with BDDs. In: Proceedings of the Workshop on Algorithm Engineering and Experiments (ALENEX 2007) (2007), http://www.mpi-inf.mpg.de/~behle/azove.html
- 5.Berkelaar, M., Eikland, K., Notebaert, P.: The lp_solve Page, http://lpsolve.sourceforge.net/
- 6.Büeler, B., Enge, A., Fukuda, K.: Exact volume computation for polytopes: a practical study. Polytopes–combinatorics and computation (1998), http://www.lix.polytechnique.fr/Labo/Andreas.Enge/Vinci.html
- 7.Buse, R.P.L., Weimer, W.R.: The road not taken: Estimating path execution frequency statically. In: Proceedings of the 31st International Conference on Software Engineering (ICSE 2009) (2009)Google Scholar
- 8.Davies, J., Bacchus, F.: Using more reasoning to improve #SAT solving. In: Proceedings of the 22nd AAAI Conference on Artificial Intelligence (AAAI 2007), pp. 185–190 (2007)Google Scholar
- 11.Eén, N., Sorensson, N.: The MiniSat Page, http://www.cs.chalmers.se/Cs/Research/FormalMethods/MiniSat/
- 13.Gomes, C.P., Hoffmann, J., Sabharwal, A., Selman, B.: From sampling to model counting. In: Proceedings of the 20th International Joint Conference on Artificial Intelligence (IJCAI 2007), pp. 2293–2299 (2007)Google Scholar
- 14.Bayardo Jr., R.J., Pehoushek, J.D.: Counting models using connected components. In: Proceedings of the 17th National Conference on Artificial Intelligence and 12th Conference on on Innovative Applications of Artificial Intelligence (AAAI/IAAI 2000), pp. 157–162 (2000)Google Scholar
- 18.Moura, L., Bjørner, N.: Z3: An efficient SMT solver. In: Ramakrishnan, C.R., Rehof, J. (eds.) TACAS 2008. LNCS, vol. 4963, pp. 337–340. Springer, Heidelberg (2008), http://research.microsoft.com/projects/z3/index.html CrossRefGoogle Scholar
- 24.Zhang, J.: Specification analysis and test data generation by solving boolean combinations of numeric constraints. In: Proceedings of the 1st Asia-Pacific Conference on Quality Software (APAQS 2000), pp. 267–274 (2000)Google Scholar
- 25.Zhang, J.: Quantitative analysis of symbolic execution. Presented at the 28th International Computer Software and Applications Conference (COMPSAC 2004) (2004)Google Scholar