Opened 4 months ago

Closed 3 months ago

#31990 closed enhancement (fixed)

ConvexSet_base: Add methods an_element, some_elements

Reported by: mkoeppe Owned by:
Priority: major Milestone: sage-9.4
Component: geometry Keywords:
Cc: gh-kliem, tscrim, yzh Merged in:
Authors: Matthias Koeppe Reviewers: Travis Scrimshaw
Report Upstream: N/A Work issues:
Branch: 1744ffa (Commits, GitHub, GitLab) Commit: 1744ffadb775f6a9f975f07f858a22f19c5efc8b
Dependencies: #31959 Stopgaps:

Status badges

Description

Although subclasses of ConvexSet_base are not necessarily Parents, it will be useful for them to provide an_element and some_elements methods.

Change History (14)

comment:1 Changed 4 months ago by mkoeppe

  • Dependencies set to #31959

comment:2 Changed 4 months ago by mkoeppe

  • Branch set to u/mkoeppe/convexset_base__add_methods_an_element__some_elements

comment:3 Changed 4 months ago by mkoeppe

  • Authors set to Matthias Koeppe
  • Commit set to a8845171bcb84207ef8b56a139067f809ad7a675
  • Status changed from new to needs_review

Last 10 new commits:

6ab5677RelativeInterior.is_universe: New
c085d30Polyhedron_base.interior: Handle the empty polyhedron correctly
686d0afPolyhedron_base.product: Add doctest for alias 'cartesian_product'
2b1d108Merge #31919
7323b10ConvexSet_base._test_contains: Only test extension to AA for exact base rings
94e6858RelativeInterior.ambient, ambient_vector_space, is_universe: New
0c9bc94ConvexSet_base: Add default implementations of ambient, ambient_dim; add doctests
7d3ae5cMerge #31959
2b1040cConvexSet_base.{an_element,some_elements}, Polyhedron.some_elements, RelativeInterior.some_elements: New
a884517PolyhedronFace.some_elements: New

comment:4 Changed 4 months ago by git

  • Commit changed from a8845171bcb84207ef8b56a139067f809ad7a675 to b19b3cc61cb8f0aed9a1f80accca1f5025da06f4

Branch pushed to git repo; I updated commit sha1. New commits:

ce91e44src/sage/geometry/relative_interior.py: Fix doctest output
b19b3ccMerge #31959

comment:5 Changed 4 months ago by tscrim

  • Reviewers set to Travis Scrimshaw

The only little quip I have is that generally in Sage some_elements() returns a list rather than an iterable. It might be good to be consistent about this.

comment:6 Changed 4 months ago by git

  • Commit changed from b19b3cc61cb8f0aed9a1f80accca1f5025da06f4 to ed898e6b23488a2912cb510ef1d7d59a798d51a7

Branch pushed to git repo; I updated commit sha1. New commits:

f0e7c58ambient_vector_space docstring: Fix bad blocks
200d967ConvexSet_base.ambient doctest: Actually test the method
1c2bef5Merge #31959
ed898e6ConvexSet_base.an_element, some_elements: Go through generator method _some_elements_, make some_elements return a list

comment:7 Changed 4 months ago by mkoeppe

  • Status changed from needs_review to needs_work

comment:8 Changed 4 months ago by git

  • Commit changed from ed898e6b23488a2912cb510ef1d7d59a798d51a7 to 7152e1fdcdf6de646218a459870e1bbb885337af

Branch pushed to git repo; I updated commit sha1. New commits:

b3ac0f3ConvexSet_base.an_element, some_elements: Raise NotImplementedError if _some_elements_ is NotImplemented
7152e1fConvexSet_base._test_contains: Test some_elements too

comment:9 Changed 4 months ago by mkoeppe

  • Status changed from needs_work to needs_review

comment:10 Changed 4 months ago by tscrim

Thanks. Green bot => positive review.

comment:11 Changed 4 months ago by git

  • Commit changed from 7152e1fdcdf6de646218a459870e1bbb885337af to 1744ffadb775f6a9f975f07f858a22f19c5efc8b

Branch pushed to git repo; I updated commit sha1. New commits:

f02ca28src/sage/geometry/polyhedron/face.py: Remove unused import
1744ffaMerge #31959

comment:12 Changed 4 months ago by mkoeppe

  • Status changed from needs_review to positive_review

Patchbot is green modulo the unrelated sage.misc.package test failure. Merged latest #31959 to get rid of pyflakes' report on an unused import.

comment:13 Changed 4 months ago by mkoeppe

Thanks for reviewing!

comment:14 Changed 3 months ago by vbraun

  • Branch changed from u/mkoeppe/convexset_base__add_methods_an_element__some_elements to 1744ffadb775f6a9f975f07f858a22f19c5efc8b
  • Resolution set to fixed
  • Status changed from positive_review to closed
Note: See TracTickets for help on using tickets.