#  copyright (c) 1997-2015
#  Ewgenij Gawrilow, Michael Joswig (Technische Universitaet Berlin, Germany)
#  http://www.polymake.org
#
#  This program is free software; you can redistribute it and/or modify it
#  under the terms of the GNU General Public License as published by the
#  Free Software Foundation; either version 2, or (at your option) any
#  later version: http://www.gnu.org/licenses/gpl.txt.
#
#  This program is distributed in the hope that it will be useful,
#  but WITHOUT ANY WARRANTY; without even the implied warranty of
#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
#  GNU General Public License for more details.
#-------------------------------------------------------------------------------

# We implement this in cdd, so we can access it's convex hull algorithms directly
# (otherwise, we'll have to use it via perl, which takes too long)

object PolyhedralFan {

   rule FACET_NORMALS, MAXIMAL_CONES_FACETS, LINEAR_SPAN_NORMALS, MAXIMAL_CONES_LINEAR_SPAN_NORMALS : \
        RAYS, MAXIMAL_CONES, FAN_AMBIENT_DIM, LINEALITY_SPACE | INPUT_LINEALITY {
      raysToFacetNormals($this);
   }
   weight 4.10;

   rule RAYS, MAXIMAL_CONES, LINEALITY_SPACE : FACET_NORMALS, MAXIMAL_CONES_FACETS, FAN_AMBIENT_DIM {
      facetsToRays($this);
   }
   weight 4.10;
   permutation : RaysPerm;
}

# Local Variables:
# mode: perl
# cperl-indent-level: 3
# indent-tabs-mode:nil
# End:
