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

Commit

Permalink
ConvexSet_base._some_elements_: Provide a default implementation
Browse files Browse the repository at this point in the history
  • Loading branch information
Matthias Koeppe committed Aug 9, 2022
1 parent f0708e7 commit 5f3a8ed
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/sage/geometry/convex_set.py
Original file line number Diff line number Diff line change
Expand Up @@ -764,7 +764,6 @@ def some_elements(self):
raise NotImplementedError
return list(self._some_elements_())

@abstract_method(optional=True)
def _some_elements_(self):
r"""
Generate some points of ``self``.
Expand All @@ -775,11 +774,12 @@ def _some_elements_(self):
sage: from sage.geometry.convex_set import ConvexSet_base
sage: C = ConvexSet_base()
sage: C._some_elements_(C)
sage: list(C._some_elements_())
Traceback (most recent call last):
...
TypeError: 'NotImplementedType' object is not callable
"""
yield self.representative_point()

@abstract_method(optional=True)
def cartesian_product(self, other):
Expand Down

0 comments on commit 5f3a8ed

Please sign in to comment.