‣ PolytopeByInequalities ( L ) | ( operation ) |
Returns: a Polytope Object
The operation takes a list L of lists [L_1, L_2, ...] where each L_j represents an inequality and returns the polytope defined by them (if they define a polytope). For example the j'th entry L_j = [c_j,a_{j1},a_{j2},...,a_{jn}] corresponds to the inequality c_j+\sum_{i=1}^n a_{ji}x_i \geq 0.
‣ Polytope ( L ) | ( operation ) |
Returns: a Polytope Object
The operation takes the list of the vertices and returns the polytope defined by them.
‣ ExternalCddPolytope ( P ) | ( attribute ) |
Returns: a CddPolyhedron
Converts the polytope to a CddPolyhedron. The operations of CddInterface can then be applied on this polyhedron.
‣ LatticePoints ( P ) | ( attribute ) |
Returns: a List
The operation returns the list of integer points inside the polytope.
‣ RelativeInteriorLatticePoints ( P ) | ( attribute ) |
Returns: a List
The operation returns the interior lattice points inside the polytope.
‣ VerticesOfPolytope ( P ) | ( attribute ) |
Returns: a list of lists
The operation returns the vertices of the polytope
‣ Vertices ( P ) | ( operation ) |
Returns: a list of lists
The same output as VerticesOfPolytope
.
‣ DefiningInequalities ( P ) | ( attribute ) |
Returns: a list of lists
The operation returns the defining inequalities of the polytope. I.e., a list of lists [L_1, L_2, ...] where each L_j=[c_j,a_{j1},a_{j2},...,a_{jn}] represents the inequality c_j+\sum_{i=1}^n a_{ji}x_i \geq 0. If L and -L occur in the output then L is called a defining-equality of the polytope.
‣ EqualitiesOfPolytope ( P ) | ( attribute ) |
Returns: a list of lists
The operation returns the defining-equalities of the polytope.
‣ FacetInequalities ( P ) | ( attribute ) |
Returns: a list of lists
The operation returns the list of the inequalities of the facets. Each defining inequality that is not defining-equality of the polytope is a facet inequality.
‣ VerticesInFacets ( P ) | ( attribute ) |
Returns: a list of lists
The operation returns list of lists L. The entries of each L_j in L consists of 0's or 1's. For instance, if L_j=[1,0,0,1,0,1], then The polytope has 6 vertices and the vertices of the j'th facet are \{V_1,V_4,V_6\}.
‣ NormalFan ( P ) | ( attribute ) |
Returns: a fan
The operation returns the normal fan of the given polytope.
‣ FaceFan ( P ) | ( attribute ) |
Returns: a fan
The operation returns the face fan of the given polytope. Remember that the face fan of a polytope is isomorphic to the normal fan of its polar polytope.
‣ AffineCone ( P ) | ( attribute ) |
Returns: a cone
If the ambient space of the polytope is \mathrm{R}^n, then the output is a cone in \mathrm{R}^{n+1}. The defining rays of the cone are {[a_{j1},a_{j2},...,a_{jn},1]}_j such that V_j=[a_{j1},a_{j2},...,a_{jn}] is a vertex in the polytope.
‣ PolarPolytope ( P ) | ( attribute ) |
Returns: a Polytope
The operation returns the polar polytope of the given polytope.
‣ DualPolytope ( P ) | ( attribute ) |
Returns: a Polytope
The operation returns the dual polytope of the given polytope.
‣ IsEmpty ( P ) | ( property ) |
Returns: a true or false
Returns whether the polytope empty or not
‣ IsLatticePolytope ( P ) | ( property ) |
Returns: a true or false
Returns whether the polytope is lattice polytope or not.
‣ IsVeryAmple ( P ) | ( property ) |
Returns: a true or false
Returns whether the polytope is very ample or not.
‣ IsNormalPolytope ( P ) | ( property ) |
Returns: a true or false
Returns whether the polytope is normal or not.
‣ IsSimplicial ( P ) | ( property ) |
Returns: a true or false
Returns whether the polytope is simplicial or not.
‣ IsSimplexPolytope ( P ) | ( property ) |
Returns: a true or false
Returns whether the polytope is simplex polytope or not.
‣ IsSimplePolytope ( P ) | ( property ) |
Returns: a true or false
Returns whether the polytope is simple or not.
‣ IsReflexive ( P ) | ( property ) |
Returns: a true or false
Returns whether the polytope is reflexive or not, i.e., if its dual polytope is lattice polytope.
‣ IsFanoPolytope ( P ) | ( property ) |
Returns: a true or false
returns whether the polytope is Fano or not. Fano polytope is a full dimensional lattice polytope whose vertices are primitive elements in the containing lattice, i.e., each vertex is not a positive integer multiple of any other lattice element.
‣ IsCanonicalFanoPolytope ( P ) | ( property ) |
Returns: a true or false
returns whether the polytope is canonical Fano or not. A canonical Fano polytope is a full dimensional lattice polytope whose relative interior contains only one lattice point, namely the origin.
‣ IsTerminalFanoPolytope ( P ) | ( property ) |
Returns: a true or false
returns whether the polytope is terminal Fano or not. A terminal Fano polytope is a full dimensional lattice polytope whose lattice points are its vertices and the origin.
‣ IsSmoothFanoPolytope ( P ) | ( property ) |
Returns: a true or false
Returns whether the polytope is smooth fano polytope or not, i.e, if the vertices in each facet form a basis for the containing lattice or not. polytope.
7.4-1 \+
‣ \+ ( P1, P2 ) | ( operation ) |
Returns: a polytope
The output is Minkowski sum of the input polytopes.
7.4-2 \*
‣ \* ( n, P ) | ( operation ) |
Returns: a polytope
The output is Minkowski sum of the input polytope with itself n times.
‣ IntersectionOfPolytopes ( P1, P2 ) | ( operation ) |
Returns: a polytope
The output is the intersection of the input polytopes.
‣ RandomInteriorPoint ( P ) | ( operation ) |
Returns: a list
Returns a random interior point in the polytope.
‣ IsInteriorPoint ( M, P ) | ( operation ) |
Returns: true or false
Checks if the given point is interior point of the polytope.
gap> P:= Polytope( [ [ 0, 0, 0 ], [ 1, 0, 0 ], [ 0, 1, 0 ], [ 1, 1, 2 ] ] ); <A polytope in |R^3> gap> IsNormalPolytope( P ); false gap> IsVeryAmple( P ); false gap> Q:= Polytope( [ [ 0, 0, 0 ], [ 1, 0, 0 ], [ 0, 1, 0 ], [ 1, 1, 1 ] ] ); <A polytope in |R^3> gap> IsNormalPolytope( Q ); true gap> IsVeryAmple( Q ); true gap> Q; <A normal very ample polytope in |R^3 with 4 vertices> gap> T:= Polytope( [ [ 0, 0, 0 ], [ 1, 0, 0 ], [ 0, 1, 0 ], [ 1, 1, 4 ] ] ); <A polytope in |R^3> gap> I:= Polytope( [ [ 0, 0, 0 ], [ 0, 0, 1 ] ] ); <A polytope in |R^3> gap> J:= T + I; <A polytope in |R^3> gap> IsVeryAmple( J ); true gap> IsNormalPolytope( J ); false gap> J; <A very ample polytope in |R^3 with 8 vertices> gap> # Example 2.2.20 Cox, Toric Varieties > A:= [ [1,1,1,0,0,0], [1,1,0,1,0,0], [1,0,1,0,1,0], [ 1,0,0,1,0,1], > [ 1,0,0,0,1,1], [ 0,1,1,0,0,1], [0,1,0,1,1,0], [0,1,0,0,1,1], > [0,0,1,1,1,0], [0,0,1,1,0,1] ]; [ [ 1, 1, 1, 0, 0, 0 ], [ 1, 1, 0, 1, 0, 0 ], [ 1, 0, 1, 0, 1, 0 ], [ 1, 0, 0, 1, 0, 1 ], [ 1, 0, 0, 0, 1, 1 ], [ 0, 1, 1, 0, 0, 1 ], [ 0, 1, 0, 1, 1, 0 ], [ 0, 1, 0, 0, 1, 1 ], [ 0, 0, 1, 1, 1, 0 ], [ 0, 0, 1, 1, 0, 1 ] ] gap> H:= Polytope( A ); <A polytope in |R^6> gap> IsVeryAmple( H ); true gap> IsNormalPolytope( H ); false gap> H; <A very ample polytope in |R^6 with 10 vertices> gap> l:= [ [ 0, 0, 1 ], [ 0, 0, 0 ], [ 1, 0, 0 ], [ 1, 0, 1 ], [ 0, 1, 0 ], > [ 0, 1, 1 ], [ 1, 1, 4 ], [ 1, 1, 5 ] ];; gap> P:= Polytope( l ); <A polytope in |R^3> gap> IsNormalPolytope( P ); false gap> lattic_points:= LatticePoints( P ); [ [ 0, 0, 0 ], [ 0, 0, 1 ], [ 0, 1, 0 ], [ 0, 1, 1 ], [ 1, 0, 0 ], [ 1, 0, 1 ], [ 1, 1, 4 ], [ 1, 1, 5 ] ] gap> u:= Cartesian( lattic_points, lattic_points );; gap> k:= Set( List( u, u-> u[1]+u[2] ) ); [ [ 0, 0, 0 ], [ 0, 0, 1 ], [ 0, 0, 2 ], [ 0, 1, 0 ], [ 0, 1, 1 ], [ 0, 1, 2 ], [ 0, 2, 0 ], [ 0, 2, 1 ], [ 0, 2, 2 ], [ 1, 0, 0 ], [ 1, 0, 1 ], [ 1, 0, 2 ], [ 1, 1, 0 ], [ 1, 1, 1 ], [ 1, 1, 2 ], [ 1, 1, 4 ], [ 1, 1, 5 ], [ 1, 1, 6 ], [ 1, 2, 4 ], [ 1, 2, 5 ], [ 1, 2, 6 ], [ 2, 0, 0 ], [ 2, 0, 1 ], [ 2, 0, 2 ], [ 2, 1, 4 ], [ 2, 1, 5 ], [ 2, 1, 6 ], [ 2, 2, 8 ], [ 2, 2, 9 ], [ 2, 2, 10 ] ] gap> Q:= 2*P; <A polytope in |R^3 with 8 vertices> gap> LatticePoints( Q ); [ [ 0, 0, 0 ], [ 0, 0, 1 ], [ 0, 0, 2 ], [ 0, 1, 0 ], [ 0, 1, 1 ], [ 0, 1, 2 ], [ 0, 2, 0 ], [ 0, 2, 1 ], [ 0, 2, 2 ], [ 1, 0, 0 ], [ 1, 0, 1 ], [ 1, 0, 2 ], [ 1, 1, 0 ], [ 1, 1, 1 ], [ 1, 1, 2 ], [ 1, 1, 3 ], [ 1, 1, 4 ], [ 1, 1, 5 ], [ 1, 1, 6 ], [ 1, 2, 4 ], [ 1, 2, 5 ], [ 1, 2, 6 ], [ 2, 0, 0 ], [ 2, 0, 1 ], [ 2, 0, 2 ], [ 2, 1, 4 ], [ 2, 1, 5 ], [ 2, 1, 6 ], [ 2, 2, 8 ], [ 2, 2, 9 ], [ 2, 2, 10 ] ] gap> P:= Polytope( [ [ 1, 1 ], [ 1, -1 ], [ -1, 1 ], [ -1, -1 ] ] ); <A polytope in |R^2> gap> Q:= PolarPolytope( P ); <A polytope in |R^2> gap> Vertices( Q ); [ [ -1, 0 ], [ 0, -1 ], [ 0, 1 ], [ 1, 0 ] ] gap> T := PolarPolytope( Q ); <A polytope in |R^2> gap> Vertices( T ); [ [ -1, -1 ], [ -1, 1 ], [ 1, -1 ], [ 1, 1 ] ] gap> P:= Polytope( [ [ 0, 0 ], [ 1, -1], [ -1, 1 ], [ -1, -1 ] ] ); <A polytope in |R^2> gap> # PolarPolytope( P );;
gap> P := PolytopeByInequalities( [ [ 0, 0, 1 ], [ 1, -1, -1 ], [ 1, 1, -1 ] ] ); <A polytope in |R^2> gap> Vertices( P ); [ [ -1, 0 ], [ 0, 1 ], [ 1, 0 ] ]
generated by GAPDoc2HTML