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

Commit

Permalink
RelativeInterior.ambient, ambient_vector_space, is_universe: New
Browse files Browse the repository at this point in the history
  • Loading branch information
Matthias Koeppe committed Jun 16, 2021
1 parent 7323b10 commit 94e6858
Showing 1 changed file with 28 additions and 0 deletions.
28 changes: 28 additions & 0 deletions src/sage/geometry/relative_interior.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,34 @@ def __contains__(self, point):
"""
return self._polyhedron.relative_interior_contains(point)

def ambient(self):
r"""
Return the ambient convex set or space.
EXAMPLES::
sage: segment = Polyhedron([[1, 2], [3, 4]])
sage: ri_segment = segment.relative_interior(); ri_segment
Relative interior of
a 1-dimensional polyhedron in ZZ^2 defined as the convex hull of 2 vertices
sage: ri_segment.ambient()
"""
return self._polyhedron.ambient()

def ambient_vector_space(self, base_field=None):
r"""
Return the ambient vector space.
EXAMPLES::
sage: segment = Polyhedron([[1, 2], [3, 4]])
sage: ri_segment = segment.relative_interior(); ri_segment
Relative interior of
a 1-dimensional polyhedron in ZZ^2 defined as the convex hull of 2 vertices
sage: ri_segment.ambient_vector_space()
"""
return self._polyhedron.ambient_vector_space(base_field=base_field)

def ambient_dim(self):
r"""
Return the dimension of the ambient space.
Expand Down

0 comments on commit 94e6858

Please sign in to comment.