3-manifolds / SnapPy

SnapPy is a package for studying the topology and geometry of 3-manifolds, with a focus on hyperbolic structures. It is based on the SnapPea kernel written by Jeff Weeks.
https://snappy.computop.org/
87 stars 41 forks source link

Choose maximal cusp inflation order in `Manifold.cusp_areas` #31

Closed bobbycyiii closed 3 years ago

bobbycyiii commented 3 years ago

In order to calculate the length of a curve on a maximal cusp, you need to have that cusp be maximal. As Manifold.cusp_area stands, one can only ensure that the initial cusp is maximal. This pull request enables one to choose the order in which to make cusps maximal.

NathanDunfield commented 3 years ago

Thanks for this. It looks like the CI checks on Windows are failing, see above, due to numerical answers differing in the last digit. You can add

# doctest: +NUMERIC9

or +NUMERIC12 so that it only compares the specified number of digits. See line 361 of __init__.py right above your changes for an example.

unhyperbolic commented 3 years ago

Thanks. I think the change looks good but I am a bit confused by the diffs. Would you mind doing a rebase crushing it to a single commit?

unhyperbolic commented 3 years ago

Two thoughts: Should first_cusps be preferred_cusps? And should there be some sanity checks about it, e.g., number of given list is not longer than the number of cusps, no duplicates, ...?