exact_vol: Compute the exact volume of (a) a zonotope (b) an arbitrary...

Description Usage Arguments Value References Examples

View source: R/RcppExports.R

Description

Given a zonotope (as an object of class Zonotope), this function computes the sum of the absolute values of the determinants of all the d \times d submatrices of the m\times d matrix G that contains row-wise the m d-dimensional segments that define the zonotope. For an arbitrary simplex that is given in V-representation this function computes the absolute value of the determinant formed by the simplex's points assuming it is shifted to the origin.

Usage

1

Arguments

P

A polytope

Value

The exact volume of the input polytope, for zonotopes, simplices in V-representation and polytopes with known exact volume

References

E. Gover and N. Krikorian, “Determinants and the Volumes of Parallelotopes and Zonotopes,” Linear Algebra and its Applications, 433(1), 28 - 40, 2010.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
# compute the exact volume of a 5-dimensional zonotope defined by the Minkowski sum of 10 segments
Z = gen_rand_zonotope(2, 5)
vol = exact_vol(Z)

# compute the exact volume of a 2-d arbitrary simplex
V = matrix(c(2,3,-1,7,0,0),ncol = 2, nrow = 3, byrow = TRUE)
P = Vpolytope(V = V)
vol = exact_vol(P)


# compute the exact volume the 10-dimensional cross polytope
P = gen_cross(10,'V')
vol = exact_vol(P)

volesti documentation built on July 14, 2021, 5:11 p.m.