Skip to main content
Springer Nature - PMC COVID-19 Collection logoLink to Springer Nature - PMC COVID-19 Collection
. 2020 Jun 6;12097:212–221. doi: 10.1007/978-3-030-52200-1_21

Practical Volume Estimation of Zonotopes by a New Annealing Schedule for Cooling Convex Bodies

Apostolos Chalkis 13,, Ioannis Z Emiris 13,14, Vissarion Fisikopoulos 13
Editors: Anna Maria Bigatti8, Jacques Carette9, James H Davenport10, Michael Joswig11, Timo de Wolff12
PMCID: PMC7340933

Abstract

We study the problem of estimating the volume of convex polytopes, focusing on zonotopes. Although a lot of effort is devoted to practical algorithms for polytopes given as an intersection of halfspaces, there is no such method for zonotopes. Our algorithm is based on Multiphase Monte Carlo (MMC) methods, and our main contributions include: (i) a new uniform sampler employing Billiard Walk for the first time in volume computation, (ii) a new simulated annealing generalizing existing MMC by making use of adaptive convex bodies which fit to the input, thus drastically reducing the number of phases. Extensive experiments on zonotopes show our algorithm requires sub-linear number of oracle calls in the dimension, while the best theoretical bound is cubic. Moreover, our algorithm can be easily generalized to any convex body. We offer an open-source, optimized C++ implementation, and analyze its performance. Our code tackles problems intractable so far, offering the first efficient algorithm for zonotopes which scales to high dimensions (e.g. one hundred dimensions in less than 1 h).

Keywords: Volume approximation, Zonotope, Simulated annealing, Billiard Walk, Mathematical software

Introduction

Volume computation is a fundamental problem with many applications. It is Inline graphicP-hard for explicit polytopes [7, 11], and APX-hard [9] for convex bodies in the oracle model. Therefore, a significant effort has been devoted to randomized approximation algorithms, starting with the celebrated result in [8] with complexity Inline graphic oracle calls, where Inline graphic suppresses polylog factors and dependence on error parameters, and d is the dimension. Improved algorithms reduced the exponent to 5 [13] and further results [5, 14] reduced the exponent to 3. Current theoretical results consider either the general oracle model or polytopes given as an intersection of halfspaces (i.e. H-polytopes). Regarding implementations, the approach of [13] led to the first practical implementation in [10] for high dimensions, followed by another practical implementation [6] based on [5, 14]. However, both implementations can handle only H-polytopes.

An important class of convex polytopes are zonotopes [15]. A zonotope is the Minkowski sum of k d-dimensional segments. Equivalently, given a matrix Inline graphic a zonotope can be seen as the affine projection of the hypercube Inline graphic to Inline graphic using the matrix G, while the columns of G are the corresponding segments (or generators). Zonotopes are centrally symmetric and each of their faces are again zonotopes. We call the order of a zonotope P the ratio between the number of generators of P over the dimension. For a nice introduction to zonotopes we refer to [20].

Volume approximation for zonotopes is of special interest in several applications in smart grids [1], in autonomous driving [2] or human-robot collaboration [16]. The complexity of algorithms that work on zonotopes strongly depends on their order. Thus, to achieve efficient computations, a solution that is common in practice is to over-approximate P, as tight as possible, with a second zonotope Inline graphic of smaller order, while Inline graphic is given by, an easy to compute, closed formula. A good measure for the quality of the approximation is the ratio of fitness, Inline graphic, which involves a volume computation problem [3]. Existing work (e.g. in [12]) uses exact - deterministic volume computation [11], and thus Inline graphic can not be computed for Inline graphic in certain applications.

A typical randomized algorithm uses a Multiphase Monte Carlo (MMC) technique, which reduces volume approximation of convex P to computing a telescoping product of ratios of integrals. Then each ratio is estimated by means of random walks sampling from a proper multivariate distribution. In this paper we rely on MMC of [13] which specifies a sequence of convex bodies Inline graphic, assuming P is well-rounded, i.e. Inline graphic, where C is constant and Inline graphic is the unit ball. We define a sequence of scaled copies of Inline graphic, and let Inline graphic. One computes Inline graphic and applies:

graphic file with name M18.gif 1

There is a closed-form expression to compute Inline graphic . Each ratio Inline graphic in Eq. (1) can be estimated within arbitrary small error Inline graphic by sampling uniformly distributed points in Inline graphic and accept/reject points in Inline graphic so Inline graphic can be derived after m multiplications. The estimation of Inline graphic shows how sampling comes into the picture. In [10], assuming Inline graphic for Inline graphic, they get Inline graphic. The issue is to minimize m while each ratio remains bounded by a constant, and to use a random walk that converges, after a minimum number of steps, to the uniform distribution. The first would permit a larger approximation error per ratio without compromising overall error, while it would require a smaller uniform sample to estimate each ratio. The second would reduce the cost per sample point. Total complexity is determined by the number of ratios, or phases, multiplied by the number of points, or steps, to estimate each ratio, multiplied by the cost to generate a point. The first two factors are determined by the MMC and the third by the random walk.

Previous Work. Exact volume computation for zonotopes can be reduced to a sum of absolute values of determinants, with an exponential number of summands in d [11]. Practical algorithms for volume computation of zonotopes are limited to low dimensions (typically Inline graphic in [6]). This is due to two main reasons: current algorithms create a long sequence of phases in MMC for zonotopes, and the boundary and membership oracles are costlier than for H-polytope, as they both reduce to Linear Programs (LP). In [6], they consider low dimensional zonotopes: in Inline graphic with Inline graphic generators, the algorithm performs Inline graphic Boundary Oracle Calls (BOC), whereas our algorithm requires only Inline graphic BOCs, and for Inline graphic it performs Inline graphic BOCs (see Table 1). In [19] they present an implementation of an efficient algorithm that computes Minkowski sums of polytopes (generalization of zonotopes). In [18] they propose a randomized algorithm for enumerating the vertices of a zonotope.

Table 1.

Volume estimation for zonotopes. For each Z-d-k we approximate its volume using ball and the P-approx in MMC. Body stands for the type of body in MMC; Inline graphic, Vol the average of volumes over 10 runs; m the average number of bodies in MMC; OracleCalls is the average number of BOCs; time is average time in seconds. We set the error parameter Inline graphic in all cases.

Z-d-k Body order Vol m OralceCalls time
Inline graphic-20-2000 Ball 100 3.69e+83 1 3.52e+03 1 442
Inline graphic-20-2000 P-approx 100 3.54e+83 1 4.10e+03 1 647
Inline graphic-30-600 Ball 20 3.93e+104 1 5.26e+03 451
Inline graphic-30-600 P-approx 20 3.84e+104 1 5.34e+03 554
Inline graphic-60-120 Ball 2 4.31e+139 6 7.94e+04 694
Inline graphic-60-120 P-approx 2 4.18e+139 2 3.39e+04 361
Inline graphic-80-160 Ball 2 1.68e+187 9 1.67e+05 3 045
Inline graphic-80-160 P-approx 2 1.82e+187 2 4.22e+04 950
Inline graphic-100-200 Ball 2 9.77e+233 12 2.81e+05 12 223
Inline graphic-100-200 P-approx 2 1.03e+234 3 6.51e+04 2 815

Our Contribution. We focus on zonotopes and introduce crucial algorithmic innovations to overcome the existing barriers, by reducing significantly the number of oracle calls. Thus, our method scales to high dimensions (Inline graphic in Inline graphic h), performing computations which were intractable till now.

We use a new simulated annealing method in order to define a sequence of appropriate convex bodies, instead of balls, in MMC, and we exploit the fast convergence of Billiard Walk (BW) [17] to the uniform distribution. We experimentally analyze complexity by counting the number of BOCs, since BW uses boundary reflections.

The new simulated annealing specifies the Inline graphic’s by exploiting the statistical properties of the telescoping ratios to drastically reduce the number of phases. In particular, we bound each ratio Inline graphic to a given interval Inline graphic with high probability, for some real r. Moreover, our MMC generalizes balls, used in [13] and previous papers, by taking as input any convex body C and constructing the sequence by only scaling C. It does not need an enclosing body of P nor an inscribed ball (or body), unlike [10, 13].

Most of the previous algorithms use a rounding step before volume computation, as preprocessing, to reduce the number of phases in MMC. However, rounding requires uniform sampling from P which makes it costly for zonotopes because of the expensive oracle calls. Our approach is to exploit the fact that the schedule uses any body C and skip rounding by letting C be an H-polytope that fits well to P. The idea is to construct C fast and reduce the number of phases and the total runtime more than a rounding preprocessing would do in practice.

We prove that the number of bodies defined in MMC is, with high probability, Inline graphic, where Inline graphic, for some Inline graphic, is the body with minimum volume, and Inline graphic. The bound on m is not surprising, as it does not improve worst-case complexity [5], if C is a ball, but offers crucial advantages in practice. First, the hidden constant is small. More importantly, if C is a good fit to P, Inline graphic increases and m decreases (Fig. 1).

Fig. 1.

Fig. 1.

Different selection of body in our algorithm’s MMC; Inline graphic and Inline graphic. Body C: left is the unit ball; right is the centrally symmetric H-polytope of Sect. 2.3.

We also show that, for constant d, and k (number of generators) increasing, m decreases to 1, when we use ball in MMC, since the schedule constructs an enclosing ball of P. Intuitively, while order increases for constant d, a random zonotope approximates the hypersphere. The latter can be approximated up to Inline graphic in the Hausdorff metric by a zonotope with Inline graphic, c(d) being a constant [4]. This does not directly prove our claim on m but strengthens it intuitively. So, in our experiments, the number of phases is Inline graphic for any order, without rounding for Inline graphic.

Considering uniform sampling, BW defines a linear trajectory starting at the current point, using boundary reflections [17]. No theoretical mixing time exists. We show that with the right selection of parameters, BW behaves like an almost perfect uniform sampler even if the walk length is 1. In particular, for this walk length, it generates just Inline graphic points per phase, with sub-linear number of reflections per point, and provides the desired accuracy. To stop sampling when estimating ratio Inline graphic we modify the binomial proportion confidence interval. We use the standard deviation of a sliding window of the last l ratios, thus defining a new empirical convergence criterion; Inline graphic suffices with BW.

Our software contributions build upon and enhance volesti1 a C++ open source library for high dimensional sampling and volume computation with an R interface. We experimentally show that the total number of oracle calls grows as Inline graphic for random zonotopes; the best available theoretical bound is Inline graphic [5].

Volume Algorithm

The algorithm first constructs a sequence of convex bodies Inline graphic intersecting the zonotope P; the Inline graphic’s are determined by simulated annealing. A typical choice of Inline graphic’s in this paper is co-centric balls, or centrally symmetric H-polytopes. Inline graphic is chosen for its volume to be computed faster than Inline graphic and easily sampled. Then,

graphic file with name M62.gif

where Inline graphic. Let Inline graphic, Inline graphic.

Uniform Sampling and Oracles for Zonotopes

We use BW to sample approximately uniform points in Inline graphic at each phase i. BW picks a uniformly distributed line Inline graphic through the current point. It walks on a linear trajectory of length Inline graphic, reflecting at the boundary. BW can be used to sample only uniform points; in [17] they experimentally show that BW converges fast to the uniform distribution when Inline graphic diam(P).

The membership oracle is a feasibility problem. A point Inline graphic iff the following region is feasible: Inline graphic, where Inline graphic are the generators of P. Let the uniformly distributed vector on the boundary of the unit ball v define the line Inline graphic through the current point. The boundary oracle for the intersection Inline graphic is expressed as a LP. One extreme point of the segment can be computed as follows: Inline graphic. The second extreme point which corresponds to a negative value of Inline graphic is not used by BW. For the BW we need the normal of the facet that intersects Inline graphic to compute the reflection of the trajectory if needed. We keep the generators that corresponds to Inline graphic and then the normal vector is computed straightforwardly.

Annealing Schedule for Convex Bodies

Given P, the annealing schedule generates the sequence of convex bodies Inline graphic defining Inline graphic and Inline graphic. The main goal is to restrict each ratio Inline graphic in the interval Inline graphic with high probability. We define the following two statistical tests, which can be reduced to t-tests:graphic file with name 495991_1_En_21_Figa_HTML.jpg

The U-test and L-test are successful iff null hypothesis Inline graphic is rejected, namely Inline graphic is upper bounded by Inline graphic or lower bounded by r, with high probability, respectively. If we sample N uniform points from Inline graphic then r.v. X that counts points in Inline graphic, follows Inline graphic, the binomial distribution, and Inline graphic. Then each sample proportion that counts successes in Inline graphic over N is an unbiased estimator for the mean of Y, which is Inline graphic.graphic file with name 495991_1_En_21_Figb_HTML.jpg

Let us now describe the annealing schedule: Each Inline graphic in Inline graphic is a scalar multiple of a given body C. Since our algorithm does not use an inscribed body, initialization computes the body with minimum volume, denoted by Inline graphic or Inline graphic. This is the last body in the sequence. The algorithm sets Inline graphic and employs Inline graphic to decide stopping at the i-th phase.

Initialization. Given C, and interval Inline graphic, one employs binary search to compute Inline graphic s.t. both U-test(Inline graphic) and L-test(Inline graphic) are successful. Let Inline graphic. If U-test(Inline graphic) succeeds and L-test(Inline graphic) fails, we continue to the left-half of the interval. With inverse outcomes, we continue to the right-half of the interval. If both succeed, stop and set Inline graphic. The output is Inline graphic, denoted by Inline graphic at termination.

Regular Iteration. At iteration i, the algorithm determines Inline graphic s.t. volume ratio Inline graphic with high probability. The schedule samples Inline graphic points from Inline graphic and binary searches for a Inline graphic in an updated interval Inline graphic s.t. both U-test(Inline graphic) and L-test(Inline graphic) are successful. Then set Inline graphic.

Stopping and Termination. The algorithm uses Inline graphic in the i-th iteration for checking whether Inline graphic with high probability, using only L-test, and then stops if L-test(Inline graphic) holds. Then, set Inline graphic, and Inline graphic.

In the t-tests, errors of different types may occur, thus, binary search may enter intervals that do not contain ratios in Inline graphic. Hence, there is a probability that annealing schedule fails to terminate. Let Inline graphic capture the power of a t-test: Inline graphic.

Theorem 1

Let J be the minimum number of steps by annealing schedule, corresponding to no errors occurring in the t-tests. Let the algorithm perform Inline graphic iterations. Let Inline graphic, Inline graphic be the maximum and minimum among all Inline graphic’s in the M pairs of t-tests in the U-test and L-test, respectively. Then, annealing schedule terminates with constant probability, namely:

graphic file with name 495991_1_En_21_Equ3_HTML.gif

Rounding and Convex Bodies in MMC

The annealing schedule allows as to use any C which must (a) be a good fit to P, (b) allow for more efficient sampling than in P, and (c) for faster volume calculation than of Inline graphic. For low order ones C shall be an enclosing H-polytope that fits well to P. Indeed it is possible that with certain choices for C rounding is not needed. We define a centrally symmetric H-polytope with Inline graphic facets:graphic file with name 495991_1_En_21_Figc_HTML.jpg

Experimental Complexity

We perform extended experiments analyzing practical complexity. We use eigen2 for linear algebra and lpSolve3 for LPs. All experiments were performed on a PC with Intel® Inline graphic i7-6700 3.40 GHz 8 CPU and 32 GB RAM. We use three zonotope generators. All of them pick uniformly a direction for each one of the k segments. Then, (a) Inline graphic-d-k: the length of each segment is uniformly sampled from [0, 100], (b) Inline graphic-d-k: the length of each segment is random from Inline graphic truncated to [0, 100], (c) Inline graphic-d-k: the length of each segment is random from Exp(1/30) truncated to [0, 100]. Total number of boundary oracle calls of our algorithm:graphic file with name 495991_1_En_21_Figd_HTML.jpg

Figure 2 denotes the best choice between ball and P-approx in MMC. It moreover shows that for order Inline graphic, the number of phases Inline graphic for Inline graphic. In particular, when we use P-approx, m is smaller for order Inline graphic compared to using balls without rounding. For order equal to 5 the number of balls in MMC is smaller compared to the number of bodies when the choice is the P-approx. Notice than when we use balls in MMC, m decreases for constant d as k increases. Table 1 shows that, for high-order zonotopes, Inline graphic, which implies one or two rejection steps, while the run-time is smaller when we use ball in MMC. It also reports the difference in the run-time for random zonotopes of order = 2 between the cases of using ball and the P-approx in MMC. In all our experiments, BW performs only Inline graphic steps per phase with just a factor of Inline graphic hidden in the complexity. The plot that counts the BW reflections per point in Fig. 3 imply this number grows sub-linearly in d. Hence, the total number of BOCs grows sub-linearly in d.

Fig. 2.

Fig. 2.

Number of bodies in MMC. For each dimension we generate 10 random zonotopes and we compute the number of bodies, m, in MMC when C is ball. We keep the zonotope with the larger m and then, for that one, we compute m when C is the P-approx.

Fig. 3.

Fig. 3.

Experimental complexity for order Inline graphic. Total number of oracle calls is given by the Inline graphicphases (bodies) Inline graphic Inline graphicsteps (points) per phase Inline graphic Inline graphicreflections per step.

Footnotes

Contributor Information

Anna Maria Bigatti, Email: bigatti@dima.unige.it.

Jacques Carette, Email: carette@mcmaster.ca.

James H. Davenport, Email: j.h.davenport@bath.ac.uk

Michael Joswig, Email: joswig@math.tu-berlin.de.

Timo de Wolff, Email: t.de-wolff@tu-braunschweig.de.

Apostolos Chalkis, Email: achalkis@di.uoa.gr.

Ioannis Z. Emiris, Email: emiris@di.uoa.gr

Vissarion Fisikopoulos, Email: vfisikop@di.uoa.gr.

References

  • 1.Althoff M. Formal and compositional analysis of power systems using reachable sets. IEEE Trans. Power Syst. 2014;29(5):2270–2280. doi: 10.1109/TPWRS.2014.2306731. [DOI] [Google Scholar]
  • 2.Althoff M, Dolan JM. Online verification of automated road vehicles using reachability analysis. IEEE Trans. Robotics. 2014;30(4):903–918. doi: 10.1109/TRO.2014.2312453. [DOI] [Google Scholar]
  • 3.Althoff, M.: Reachability Analysis and Its Application to the Safety Assessment of Autonomous Cars (2010). Google-Books-ID: ndN3vgAACAAJ
  • 4.Bourgain J, Lindenstrauss J. Approximating the ball by a Minkowski sum of segments with equal length. Discrete Comput. Geom. 1993;9(2):131–144. doi: 10.1007/BF02189313. [DOI] [Google Scholar]
  • 5.Cousins, B., Vempala, S.: Bypassing KLS: Gaussian cooling and an Inline graphic volume algorithm. In: Proceedings of the ACM STOC, pp. 539–548 (2015)
  • 6.Cousins B, Vempala S. A practical volume algorithm. Math. Prog. Comp. 2015;8(2):133–160. doi: 10.1007/s12532-015-0097-z. [DOI] [Google Scholar]
  • 7.Dyer M, Frieze A. On the complexity of computing the volume of a polyhedron. SIAM J. Comput. 1988;17(5):967–974. doi: 10.1137/0217060. [DOI] [Google Scholar]
  • 8.Dyer M, Frieze A, Kannan R. A random polynomial-time algorithm for approximating the volume of convex bodies. J. ACM. 1991;38(1):1–17. doi: 10.1145/102782.102783. [DOI] [Google Scholar]
  • 9.Elekes G. A geometric inequality and the complexity of computing volume. Discrete Comput. Geom. 1986;1(4):289–292. doi: 10.1007/BF02187701. [DOI] [Google Scholar]
  • 10.Emiris I, Fisikopoulos V. Practical polytope volume approximation. ACM Trans. Math. Soft. 2018;44(4):38:1–38:21. doi: 10.1145/3194656. [DOI] [Google Scholar]
  • 11.Gover E, Krikorian N. Determinants and the volumes of parallelotopes and zonotopes. Linear Algebra Appl. 2010;413:28–40. doi: 10.1016/j.laa.2010.01.031. [DOI] [Google Scholar]
  • 12.Kopetzki, A., Schürmann, B., Althoff, M.: Methods for order reduction of zonotopes. In: Proceedings of the IEEE Annual Conference on Decision & Control (CDC), pp. 5626–5633 (2017). 10.1109/CDC.2017.8264508
  • 13.Lovász L, Kannan R, Simonovits M. Random walks and an Inline graphic volume algorithm for convex bodies. Random Struct. Algor. 1997;11:1–50. doi: 10.1002/(SICI)1098-2418(199708)11:1<1::AID-RSA1>3.0.CO;2-X. [DOI] [Google Scholar]
  • 14.Lovász L, Vempala S. Simulated annealing in convex bodies and an OInline graphic volume algorithms. J. Comput. Syst. Sci. 2006;72:392–417. doi: 10.1016/j.jcss.2005.08.004. [DOI] [Google Scholar]
  • 15.McMullen P. On zonotopes. Trans. Am. Math. Soc. 1971;159:91–109. doi: 10.1090/S0002-9947-1971-0279689-2. [DOI] [Google Scholar]
  • 16.Pereira, A., Althoff, M.: Safety control of robots under computed torque control using reachable sets. In: Proceedings of the IEEE International Conference on Robotics Automation (ICRA), pp. 331–338 (2015). 10.1109/ICRA.2015.7139020
  • 17.Polyak B, Gryazina E. Billiard walk - a new sampling algorithm for control and optimization. IFAC Proc. Vol. 2014;47(3):6123–6128. doi: 10.3182/20140824-6-ZA-1003.02312. [DOI] [Google Scholar]
  • 18.Stinson, K., Gleich, D.F., Constantine, P.G.: A randomized algorithm for enumerating zonotope vertices. CoRR abs/1602.06620 (2016). http://arxiv.org/abs/1602.06620
  • 19.Weibel, C.: Implementation and parallelization of a reverse-search algorithm for Minkowski sums. In: ALENEX (2010)
  • 20.Ziegler G. Lectures on Polytopes. New York: Springer; 1995. [Google Scholar]

Articles from Mathematical Software – ICMS 2020 are provided here courtesy of Nature Publishing Group

RESOURCES