Skip to content

Commit

Permalink
Moving code to compute cusp areas from cusp area matrix from verify t…
Browse files Browse the repository at this point in the history
…o cusps since it works for both floats and intervals.
  • Loading branch information
unhyperbolic committed Jul 19, 2024
1 parent dbeddad commit 35e07fb
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 8 deletions.
7 changes: 3 additions & 4 deletions python/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ def canonical_retriangulation(
Manifold.cusp_area_matrix = cusp_area_matrix
ManifoldHP.cusp_area_matrix = cusp_area_matrix

from .verify import cusp_areas as verify_cusp_areas
from .cusps import cusp_areas_from_matrix


def cusp_areas(manifold, policy='unbiased',
Expand Down Expand Up @@ -321,10 +321,9 @@ def cusp_areas(manifold, policy='unbiased',
method=method, verified=verified, bits_prec=bits_prec)

if policy == 'unbiased':
return verify_cusp_areas.unbiased_cusp_areas_from_cusp_area_matrix(m)
return cusp_areas_from_matrix.unbiased_cusp_areas_from_cusp_area_matrix(m)
else:
return verify_cusp_areas.greedy_cusp_areas_from_cusp_area_matrix(m, first_cusps=first_cusps)

return cusp_areas_from_matrix.greedy_cusp_areas_from_cusp_area_matrix(m, first_cusps=first_cusps)

Manifold.cusp_areas = cusp_areas
ManifoldHP.cusp_areas = cusp_areas
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion python/len_spec/geometric_structure.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
from ..geometric_structure.cusp_neighborhood.vertices import scale_vertices_from_horotriangles

from ..cusps.trig_cusp_area_matrix import triangulation_dependent_cusp_area_matrix_from_cusp_cross_section
from ..verify.cusp_areas import unbiased_cusp_areas_from_cusp_area_matrix
from ..cusps.cusp_areas_from_matrix import unbiased_cusp_areas_from_cusp_area_matrix
from ..tiling.triangle import add_triangles_to_tetrahedra
from ..math_basics import correct_min
from ..matrix import make_matrix
Expand Down
2 changes: 2 additions & 0 deletions python/test.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
import snappy.tiling.canonical_key_dict
import snappy.tiling.dict_based_set
import snappy.cusps.maximal_cusp_area_matrix
import snappy.cusps.cusp_areas_from_matrix
import snappy.raytracing.cohomology_fractal
import snappy.raytracing.geodesic_tube_info
import snappy.raytracing.geodesics
Expand Down Expand Up @@ -117,6 +118,7 @@ def ptolemy_doctester(verbose):
snappy.tiling.canonical_key_dict,
snappy.tiling.dict_based_set,
snappy.cusps.maximal_cusp_area_matrix,
snappy.cusps.cusp_areas_from_matrix,
snappy.raytracing.cohomology_fractal,
snappy.raytracing.geodesic_tube_info,
snappy.raytracing.geodesics,
Expand Down
4 changes: 1 addition & 3 deletions python/verify/test.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from snappy import verify, Manifold
from snappy.geometric_structure import cusp_neighborhood
from snappy.verify import upper_halfspace, cusp_shapes, cusp_areas, volume
from snappy.verify import upper_halfspace, volume
from snappy.sage_helper import _within_sage, doctest_modules
import sys
import getopt
Expand Down Expand Up @@ -64,8 +64,6 @@ def run_doctests(verbose=False, print_info=True):
verify.canonical,
verify.interval_tree,
volume,
cusp_areas,
cusp_shapes,
upper_halfspace.ideal_point,
upper_halfspace.finite_point,
upper_halfspace.extended_matrix,
Expand Down

0 comments on commit 35e07fb

Please sign in to comment.