Skip to content
This repository has been archived by the owner on Jan 30, 2023. It is now read-only.

Commit

Permalink
improved comment
Browse files Browse the repository at this point in the history
  • Loading branch information
Jonathan Kliem committed Aug 27, 2020
1 parent 52b634f commit 92487de
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions src/sage/geometry/polyhedron/face.py
Original file line number Diff line number Diff line change
Expand Up @@ -810,8 +810,15 @@ def combinatorial_face_to_polyhedral_face(polyhedron, combinatorial_face):
raise NotImplementedError("unknown backend")

if polyhedron.dimension() == 0:
# In case of the 0-dimensional polyhedron,
# there is a facets but no inequality.
# Taking care of a special case:
# In this case the face lattice has a coatom,
# but the polyhedron does not have a facet
# (a facet is defined to be non-empty).

# More important, there is no inequality for that coatom.
# So the above would produce an index error.
# Instead, any case of the 0-dimensional polyhedron
# satisfies all of the equations.
H_indices = tuple(range(n_equations))

return PolyhedronFace(polyhedron, V_indices, H_indices)

0 comments on commit 92487de

Please sign in to comment.