Ticket #11302 (closed enhancement: fixed)

Opened 2 years ago

Last modified 2 years ago

Make it easier to construct a fan from a triangulation

Reported by: vbraun Owned by: mhampton
Priority: major Milestone: sage-4.7.1
Component: geometry Keywords:
Cc: novoselt Work issues:
Report Upstream: N/A Reviewers: Andrey Novoseltsev
Authors: Volker Braun Merged in: sage-4.7.1.alpha1
Dependencies: Stopgaps:

Description (last modified by vbraun) (diff)

A common step in toric geometry is to construct the fan from some triangulation. This patch adds a fan() method to the triangulation class, so you can write:

sage: pc = PointConfiguration([(0,0), (1,0), (0,1), (-1,-1)], star=0, fine=True)
sage: triangulation = pc.triangulate()
sage: fan = triangulation.fan(); fan
Rational polyhedral fan in 2-d lattice N
sage: fan.is_equivalent( toric_varieties.P2().fan() )
True

Apply:

Attachments

trac_11302_fan_of_a_triangulation.patch Download (6.4 KB) - added by vbraun 2 years ago.
Initial patch
trac_11302_reviewer.patch Download (3.8 KB) - added by novoselt 2 years ago.

Change History

Changed 2 years ago by vbraun

Initial patch

comment:1 Changed 2 years ago by vbraun

  • Cc novoselt added
  • Status changed from new to needs_review

comment:2 Changed 2 years ago by vbraun

  • Type changed from PLEASE CHANGE to enhancement

Changed 2 years ago by novoselt

comment:3 Changed 2 years ago by novoselt

There were some doctest errors, I have fixed them and made fan construction more straightforward. As a pleasant side effect, fan rays should now repeat the order of points ;-)

If everything is OK, please switch to positive review!

comment:4 Changed 2 years ago by novoselt

  • Reviewers set to Andrey Novoseltsev

comment:5 Changed 2 years ago by vbraun

  • Status changed from needs_review to positive_review
  • Description modified (diff)

Oops I added the p.set_engine('internal') to the doctests at the end but then forgot to check that they work. Thanks for catching it :-)

comment:6 Changed 2 years ago by jdemeyer

  • Status changed from positive_review to closed
  • Resolution set to fixed
  • Merged in set to sage-4.7.1.alpha1
Note: See TracTickets for help on using tickets.