Python Initialization Classes
- class polytopewalk.FROutput
Bases:
pybind11_objectOutput for Facial Reduction.
- property Q
Matrix used to go between forms.
- property dense_A
Full-dim form Ax <= b.
- property dense_b
Full-dim form Ax <= b.
- property saved_V
PAVv = Pb decomposition.
- property sparse_A
Constrained form Ax = b, x >=_k 0.
- property sparse_b
Constrained form Ax = b, x >=_k 0.
- property z1
Vector used to go between forms.
- class polytopewalk.FacialReduction(self: polytopewalk.FacialReduction, err_dc: float = 1e-06)
Bases:
pybind11_objectFacial Reduction Implementation.
Initialization for Facial Reduction Class.
- Parameters:
err_dc (double, optional) – Error sensitivity for decomposition calculation (default is 1e-6).
- reduce(self: polytopewalk.FacialReduction, A: scipy.sparse.csc_matrix[numpy.float64], b: numpy.ndarray[numpy.float64[m, 1]], k: int, sparse: bool) FROutput
Completes facial reduction on Ax = b, x >=_k 0.
- Parameters:
A (numpy.ndarray) – Constraint matrix.
b (numpy.ndarray) – Constraint vector.
k (int) – Dimensionality of polytope.
sparse (bool) – Includes only sparse constrained polytope or adds dense full-dimensional polytope.
- Returns:
Facial Reduction results object.
- Return type:
- class polytopewalk.dense.DenseCenter(self: polytopewalk.dense.DenseCenter)
Bases:
pybind11_objectInitialization Algorithm for Dense Polytopes.
Initialization for Center Algorithm.
- getInitialPoint(self: polytopewalk.dense.DenseCenter, A: numpy.ndarray[numpy.float64[m, n]], b: numpy.ndarray[numpy.float64[m, 1]]) numpy.ndarray[numpy.float64[m, 1]]
Finds analytical center for Ax <= b.
- Parameters:
A (numpy.ndarray) – Constraint matrix.
b (numpy.ndarray) – Constraint vector.
- Returns:
Point well within polytope.
- Return type:
numpy.ndarray
- class polytopewalk.sparse.SparseCenter(self: polytopewalk.sparse.SparseCenter)
Bases:
pybind11_objectInitialization Algorithm for Sparse Polytopes.
Initialization for Center Algorithm.
- getInitialPoint(self: polytopewalk.sparse.SparseCenter, A: scipy.sparse.csc_matrix[numpy.float64], b: numpy.ndarray[numpy.float64[m, 1]], k: int) numpy.ndarray[numpy.float64[m, 1]]
Finds analytical center Ax = b, x >=_k 0.
- Parameters:
A (numpy.ndarray) – Constraint matrix.
b (numpy.ndarray) – Constraint vector.
k (int) – Dimensionality of the polytope.
- Returns:
Point well within polytope.
- Return type:
numpy.ndarray