application: fan
This application deals with polyhedral fans. You can define a fan, e.g. via its RAYS and MAXIMAL_CONES and compute several properties like HASSE_DIAGRAM and F_VECTOR.
uses: group, ideal, topaz
Objects
- derived from: PolyhedralFan
A polyhedral complex. The derivation from PolyhedralFan works like the derivation of Polytope from Cone.
Properties of PolyhedralComplex
These properties capture combinatorial information of the object. Combinatorial properties only depend on combinatorial data of the object like, e.g., the face lattice.
- MAXIMAL_CELLS: common::IncidenceMatrix<NonSymmetric>
Maximal cells of the polyhedral complex. Indices refer to POINTS. Points do not have to be vertices of the cells.
- MAXIMAL_POLYTOPES_COMBINATORIAL_DIMS: common::Array<Int>
Alias for property MAXIMAL_CONES_COMBINATORIAL_DIMS.
- MAXIMAL_POLYTOPES_INCIDENCES: common::Array<IncidenceMatrix<NonSymmetric>>
Array of incidence matrices of all maximal polytopes. Alias for property MAXIMAL_CONES_INCIDENCES.
These properties capture geometric information of the object. Geometric properties depend on geometric information of the object, like, e.g., vertices or facets.
- CONVEX: common::Bool
True if POINTS are in convex position. In this case POINTS and RAYS, and MAXIMAL_CELLS and MAXIMAL_POLYTOPES are equal. FIXME: This should possibly either go or be duplicated in application polytope. Keep an eye on it!
- MAXIMAL_POLYTOPES_FACETS: common::SparseMatrix<Int, NonSymmetric>
Alias for property MAXIMAL_CONES_FACETS.
These properties are for input only. They allow redundant information.
These properties are for visualization.
User Methods of PolyhedralComplex
These methods capture geometric information of the object. Geometric properties depend on geometric information of the object, like, e.g., vertices or facets.
- AMBIENT_DIM () → Int
These methods are for visualization.
- VISUAL () → Visual::PolyhedralComplex
Visualizes the polyhedral complex. The cells of the complex may have interior points.
Options
option list: Visual::Polygons::decorations Returns
Visual::PolyhedralComplex - VISUAL () → Visual::PolyhedralComplex
Visualizes the polyhedral complex.
Options
option list: Visual::Polygons::decorations Returns
Visual::PolyhedralComplex
A polyhedral fan. The current restriction is that each cone in the fan has to be pointed. This will be relaxed later. If a fan is specified via INPUT_RAYS and INPUT_CONES each input cone must list all the input rays incident.
Once non-trivial linealities are allowed the following will apply: The RAYS always lie in a linear subspace which is complementary to the LINEALITY_SPACE.
Specializations of PolyhedralFan
Properties of PolyhedralFan
These properties capture combinatorial information of the object. Combinatorial properties only depend on combinatorial data of the object like, e.g., the face lattice.
- COMPLETE: common::Bool
The polyhedral fan is complete if its suport is the whole space.
Due to undecidability issues this is checked heuristically only. See the remarks on SPHERE for details.
- CONES: common::Array<IncidenceMatrix<NonSymmetric>>
List of all cones of the fan of each dimension. Indices refer to RAYS.
- DUAL_GRAPH: graph::Graph<Undirected>
The graph whose nodes are the maximal cones which are connected if they share a common facet.
- F2_VECTOR: common::Matrix<Integer, NonSymmetric>
fik is the number of incident pairs of i-dimensional cones and k-dimensional cones; the main diagonal contains the F_VECTOR.
- F_VECTOR: common::Vector<Integer>
fk is the number of k-dimensional cones starting from dimension k=1.
- GRAPH: graph::Graph<Undirected>
The graph of the fan intersected with a sphere, that is, the vertices are the rays which are connected if they are contained in a common two-dimensional cone.
- HASSE_DIAGRAM: graph::FaceLattice
The poset of subcones of the polyhedral fan organized as a directed graph. Each node corresponds to some proper subcone of the fan. The nodes corresponding to the rays and maximal cones appear in the same order as the elements of RAYS and MAXIMAL_CONES properties.
One special node represents the origin.
- MAXIMAL_CONES: common::IncidenceMatrix<NonSymmetric>
Non redundant list of maximal cones. Indices refer to RAYS. Cones which do not have any rays correspond to the trivial cone (contains only the origin). An empty fan does not have any cones.
- MAXIMAL_CONES_COMBINATORIAL_DIMS: common::Array<Int>
The combinatorial dimensions of the maximal cones.
- MAXIMAL_CONES_INCIDENCES: common::Array<IncidenceMatrix<NonSymmetric>>
Array of incidence matrices of all maximal cones.
These properties capture geometric information of the object. Geometric properties depend on geometric information of the object, like, e.g., vertices or facets.
- LINEALITY_SPACE: common::Matrix
Since we do not require our cones to be pointed: a basis of the lineality space of the fan. Co-exists with RAYS.
- MAXIMAL_CONES_FACETS: common::SparseMatrix<Int, NonSymmetric>
Tells for each maximal cone what are its facets. A negative number means that the corresponding row of FACET_NORMALS has to be negated.
- MAXIMAL_CONES_LINEAR_SPAN_NORMALS: common::IncidenceMatrix<NonSymmetric>
Tells for each maximal cone what is its linear span. Indices refer to LINEAR_SPAN_NORMALS. Rows correspond to MAXIMAL_CONES_FACETS.
- RAYS: common::Matrix
Rays from which the cones are formed. Non-redundant. Co-exists with LINEALITY_SPACE.
These properties are for input only. They allow redundant information.
- INPUT_CONES: common::Array<Set<Int>>
Maybe redundant list of not necessarily maximal cones. Indices refer to INPUT_RAYS. Each cone must list all rays of INPUT_RAYS it contains. The cones are allowed to contain lineality. Cones which do not have any rays correspond to the trivial cone (contains only the origin). An empty fan does not have any cones.
Input section only. Ask for MAXIMAL_CONES if you want to know the maximal cones (indexed by RAYS).
- INPUT_LINEALITY: common::Matrix
Vectors whose linear span defines a subset of the lineality space of the fan; redundancies are allowed.
Input section only. Ask for LINEALITY_SPACE if you want to know the lineality space.
- INPUT_RAYS: common::Matrix
Rays from which the cones are formed. May be redundant. All vectors in the input must be non-zero. You also need to provide INPUT_CONES to define a fan completely.
Input section only. Ask for RAYS if you want a list of non-redundant rays.
The following properties are topological invariants.
- HOMOLOGY: common::Array<HomologyGroup<Integer>>
The homology of the intersection of the fan with the unit sphere.
- INTERSECTION_COMPLEX: topaz::SimplicialComplex
If the fan is SIMPLICIAL the simplicial complex obtained by intersection the fan with the unit sphere. If the fan is not SIMPLICIAL the crosscut complex of the intersection.
Properties coming from associated toric varieties
- GORENSTEIN: common::BoolOnly defined for PolyhedralFan<Rational>
A fan is Gorenstein if it is Q_GORENSTEIN with Q_GORENSTEIN_INDEX equal to one.
- Q_GORENSTEIN: common::BoolOnly defined for PolyhedralFan<Rational>
A fan is Q-GORENSTEIN if each maximal cone is Q_Gorenstein.
- Q_GORENSTEIN_INDEX: common::IntOnly defined for PolyhedralFan<Rational>
If a fan is Q_GORENSTEIN, then its Q-Gorenstein index is the least common multiple of the Q-Gorenstein indices of its maximal cones. Otherwise Q_GORENSTEIN_INDEX is undefined.
- SMOOTH_FAN: common::BoolOnly defined for PolyhedralFan<Rational>
A fan is smooth if all cones of the fan are smooth.
These properties are for visualization.
- INPUT_RAY_LABELS: common::Array<String>
Unique names assigned to the INPUT_RAYS. Similar to RAY_LABELS for RAYS.
- RAY_LABELS: common::Array<String>
Unique names assigned to the RAYS. If specified, they are shown by visualization tools instead of vertex indices.
For a polyhedral fan built from scratch, you should create this property by yourself, either manually in a text editor, or with a client program.
User Methods of PolyhedralFan
These methods capture combinatorial information of the object. Combinatorial properties only depend on combinatorial data of the object like, e.g., the face lattice.
- MAXIMAL_CONES_DIMS () → Array<Int>
These methods capture geometric information of the object. Geometric properties depend on geometric information of the object, like, e.g., vertices or facets.
- AMBIENT_DIM () → Int
These methods are for visualization.
- VISUAL () → Visual::PolyhedralFan
Visualizes the fan, intersected with the unit ball.
Options
option list: Visual::Polygons::decorations Returns
Visual::PolyhedralFan FIXME: use combinatorics via MAXIMAL_CONES_FACETS
Permutations of PolyhedralFan
- derived from: PolyhedralFan
A PolyhedralFan with a symmetry group acting on the coordinates.
Properties of SymmetricFan
These properties are for input only. They allow redundant information.
- INPUT_CONES_REPS: common::Array<Set<Int>>
Maybe redundant list of not necessarily maximal cones, one from each orbit. All vectors in the input must be non-zero. Indices refer to INPUT_RAYS.
These properties capture information of the object that is concerned with the action of permutation groups.
- CONES_REPS: common::Array<Array<Set<Int>>>
List of all cones of all dimensions of the fan, one from each orbit. Indices refer to RAYS.
- MAXIMAL_CONES_IN_ORBITS: common::Array<Set<Int>>
Tells which maximal cone is in the orbit of which representative, indices refers to rows of MAXIMAL_CONES.
- MAXIMAL_CONES_REPS: common::Array<Set<Int>>
Non redundant list of maximal cones, one from each orbit. Indices refer to RAYS.
- MAXIMAL_CONES_REPS_FACETS: common::SparseMatrix<Int, NonSymmetric>
Tells for each maximal cone representative what are its facets. A negative number means that the corresponding row of REPS_FACET_NORMALS has to be negated.
- MAXIMAL_CONES_REPS_LINEAR_SPAN_NORMALS: common::IncidenceMatrix<NonSymmetric>
Tells for each maximal cone representative what is its linear span. Indices refer to REPS_LINEAR_SPAN_NORMALS. Rows correspond to MAXIMAL_CONES_REPS_FACETS
- RAYS_IMAGES: common::Array<Array<Int>>
Each row contains the image of all RAYS under one element of the symmetry group.
- RAYS_IN_ORBITS: common::Array<Set<Int>>
Tells which ray is in the orbit of which representative, indices refers to rows of RAYS.
- REPS_LINEAR_SPAN_NORMALS: common::Matrix
The possible linear span normals of all maximal cone representatives.
- SYMMETRY_GENERATORS: common::Array<Array<Int>>
Each element of the array is a generator of the subgroup of the symmetric group acting on the coordintates. Each generator is represented by an Array whose ith entry is the image of ith coordinate.
- SYMMETRY_GROUP: common::Array<Array<Int>>
Each element of the array is an element of the symmetry group.
User Methods of SymmetricFan
- cone_representative (i) → Cone
- derived from: PolyhedralFan
The tropical variety defined by a fan.
Type Parameters
Scalar default: RationalProperties of TropicalVariety
User Functions
These clients provide consistency checks, e.g. whether a given list of rays and cones defines a polyhedral fan.
- check_fan (rays, cones) → PolyhedralFan
Checks whether a given set of rays together with a list cones defines a polyhedral fan. If this is the case, the ouput is the PolyhedralFan defined by rays as INPUT_RAYS, cones as INPUT_CONES, lineality_space as LINEALITY_SPACE if this option is given.
Parameters
Matrix rays Array< Set<int> > cones Options
Matrix lineality_space Common lineality space for the cones.Bool verbose prints information about the check.Returns
PolyhedralFan - check_fan_objects <Coord> (cones) → PolyhedralFan
Checks whether the polytope::Cone objects form a polyhedral fan. If this is the case, returns that PolyhedralFan.
Type Parameters
Coord Parameters
Array<Cone> cones Options
Bool verbose prints information about the check.Returns
PolyhedralFan
These clients provide standard constructions for PolyhedralFan objects, e.g. from polytopes (face_fan or normal_fan) or from other fans (via projection, refinement or product).
- common_refinement (f1, f2) → PolyhedralFan
Computes the common refinement of two fans.
- face_fan <Coord> (p, v) → PolyhedralFan
Computes the face fan of p.
Type Parameters
Coord Parameters
Polytope p Vector v a relative interior point of the polytopeReturns
PolyhedralFan - face_fan <Coord> (p) → PolyhedralFan
Computes the face fan of p. the polytope has to be CENTERED
- groebner_fan (I)
- hyperplane_arrangement (H) → PolyhedralFan
- normal_fan <Coord> (p) → PolyhedralFan
- product (F1, F2) → PolyhedralFan
Construct a new polyhedral fan as the product of two given polyhedral fans F1 and F2.
Parameters
PolyhedralFan F1 PolyhedralFan F2 Options
Bool noc only combinatorial information is handledReturns
PolyhedralFan - projection (P, indices) → PolyhedralFan
Orthogonally project a pointed fan to a coordinate subspace.
The subspace the fan P is projected on is given by indices in the set indices. The option revert inverts the coordinate list.
Parameters
PolyhedralFan P Array<Int> indices Options
Bool revert inverts the coordinate listReturns
PolyhedralFan - projection_full (P) → PolyhedralFan
Orthogonally project a fan to a coordinate subspace such that redundant columns are omitted, i.e., the projection becomes full-dimensional without changing the combinatorial type.
- secondary_fan (M)
Call wiki:external_software#gfan to compute the secondary cone of a vector configuration.
Parameters
Matrix M whose rows are the vectors in the configuration
These clients provide constructions for PolyhedralComplex objects.
- mixed_subdivision (P_0, P_1, VIF, t_0, t_1) → PolyhedralComplex
Create a weighted mixed subdivision of the Minkowski sum of two polytopes, using the Cayley trick. The polytopes must have the same dimension, at least one of them must be pointed. The vertices of the first polytope P_0 are weighted with t_0, and the vertices of the second polytope P_1 with t_1.
Default values are t_0=t_1=1.
The option relabel creates an additional section VERTEX_LABELS.
Parameters
Polytope P_0 the first polytopePolytope P_1 the second polytopeArray<Set> VIF the indices of the vertices of the mixed cellsScalar t_0 the weight for the vertices of P_0; default 1Scalar t_1 the weight for the vertices of P_1; default 1Options
Bool relabel Returns
PolyhedralComplex - mixed_subdivision (m, C, a) → PolyhedralComplex
Create a weighted mixed subdivision of a Cayley embedding of a sequence of polytopes. Each vertex v of the i-th polytope is weighted with t_i, the i-th entry of the optional array t.
The option relabel creates an additional section VERTEX_LABELS.
Parameters
Int m the number of polytopes giving rise to the Cayley embeddingPolytope C the Cayley embedding of the input polytopesArray<Set> a triangulation of COptions
Vector<Scalar> t scaling for the Cayley embedding; defaults to the all-1 vectorBool relabel Returns
PolyhedralComplex - mixed_subdivision (A) → PolyhedralComplex
Create a weighted mixed subdivision of a sequence (P1,...,Pm) of polytopes, using the Cayley trick. All polytopes must have the same dimension, at least one of them must be pointed. Each vertex v of the i-th polytope is weighted with t_i, the i-th entry of the optional array t.
The option relabel creates an additional section VERTEX_LABELS.
Parameters
Array<Polytope> A the input polytopesOptions
Vector<Scalar> t scaling for the Cayley embedding; defaults to the all-1 vectorBool relabel Returns
PolyhedralComplex - tiling_quotient <Coord> (P, Q) → PolyhedralComplex
Calculates the quotient of P by Q+L, where Q+L is a lattice tiling. The result is a polytopal complex inside Q.
Type Parameters
Coord Parameters
Polytope P a polytopePolytope Q a polytope that tiles spaceReturns
PolyhedralComplex