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

Commit

Permalink
{Topological,Differentiable,PseudoRiemannianSubmanifold}._repr_: Prin…
Browse files Browse the repository at this point in the history
…t subsets as subsets
  • Loading branch information
Matthias Koeppe committed Apr 15, 2021
1 parent 3fc1922 commit 006fd02
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -208,6 +208,8 @@ def _repr_(self):
3-dimensional differentiable manifold M
"""
if self is not self._manifold:
return "Open subset {} of the {}".format(self._name, self._manifold)
if self._ambient is None:
return super(DifferentiableManifold, self).__repr__()
if self._embedded:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -382,6 +382,8 @@ def _repr_(self):
3-dimensional Lorentzian manifold M
"""
if self is not self._manifold:
return "Open subset {} of the {}".format(self._name, self._manifold)
if self._ambient is None:
return super(PseudoRiemannianManifold, self).__repr__()
if self._embedded:
Expand Down
2 changes: 2 additions & 0 deletions src/sage/manifolds/topological_submanifold.py
Original file line number Diff line number Diff line change
Expand Up @@ -246,6 +246,8 @@ def _repr_(self):
3-dimensional topological manifold M
"""
if self is not self._manifold:
return "Open subset {} of the {}".format(self._name, self._manifold)
if self._ambient is self:
return super(TopologicalManifold, self).__repr__()
if self._embedded:
Expand Down

0 comments on commit 006fd02

Please sign in to comment.