In particular, I'm trying to find out how to define a polytope via halfspaces.
The documentation tells me what command to use:
Code: Select all
$inequalities=new Matrix<Rational>([[1,1,0],[1,0,1],[1,-1,0],[1,0,-1],[17,1,1]]);
$p=new Polytope<Rational>(INEQUALITIES=>$inequalities);
Perhaps a simple example: here is a trivial polytope
x+y >= 1
x >= 0
y >= 0
What matrix of inequalities would yield this?
I'd appreciate knowing just this one fact, but even more, I'd appreciate knowing how to find out the precise semantics of a command from the documentation!
Thanks
Gordon
PS In case it matters, all the polytopes I need to work with are specified as follows:
- lots of 0/1 linear combination of the variables >= 1
- all variables >= 0