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

Commit

Permalink
use abs tol flag
Browse files Browse the repository at this point in the history
  • Loading branch information
Jonathan Kliem committed Jun 22, 2020
1 parent 23ed583 commit 5283dc4
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions src/sage/geometry/hyperbolic_space/hyperbolic_geodesic.py
Original file line number Diff line number Diff line change
Expand Up @@ -909,8 +909,8 @@ def perpendicular_bisector(self):
sage: g = HyperbolicPlane().PD().random_geodesic()
sage: h = g.perpendicular_bisector()
sage: bool(h.intersection(g)[0].coordinates() - g.midpoint().coordinates() < 10**-9)
True
sage: abs(h.intersection(g)[0].coordinates() - g.midpoint().coordinates()) # abs tol 1e-9
0
"""

Expand Down Expand Up @@ -1148,7 +1148,7 @@ def plot(self, boundary=True, **options):
Graphics object consisting of 2 graphics primitives
Plotting a line with ``boundary=False``. ::
sage: g = HyperbolicPlane().UHP().get_geodesic(0, I)
sage: g.plot(boundary=False)
Graphics object consisting of 1 graphics primitive
Expand Down Expand Up @@ -1373,8 +1373,8 @@ def perpendicular_bisector(self): # UHP
sage: g = UHP.random_geodesic()
sage: h = g.perpendicular_bisector()
sage: c = lambda x: x.coordinates()
sage: bool(c(g.intersection(h)[0]) - c(g.midpoint()) < 10**-9)
True
sage: abs(c(g.intersection(h)[0]) - c(g.midpoint())) # abs tol 1e-9
0
::
Expand Down Expand Up @@ -1663,7 +1663,7 @@ def angle(self, other): # UHP
arccos(7/8)
sage: h.angle(g)
arccos(7/8)
Angle between circle and line. Note that ``1/2*sqrt(2)`` equals
``1/4*pi``. ::
Expand Down Expand Up @@ -1911,10 +1911,10 @@ def _crossratio_matrix(p0, p1, p2): # UHP
sage: (p1, p2, p3) = [UHP.random_point().coordinates()
....: for k in range(3)]
sage: A = HyperbolicGeodesicUHP._crossratio_matrix(p1, p2, p3)
sage: bool(abs(moebius_transform(A, p1)) < 10**-9)
True
sage: bool(abs(moebius_transform(A, p2) - 1) < 10**-9)
True
sage: abs(moebius_transform(A, p1)) # abs tol 1e-9
0
sage: abs(moebius_transform(A, p2) - 1) # abs tol 1e-9
0
sage: bool(moebius_transform(A, p3) == infinity)
True
sage: (x,y,z) = var('x,y,z')
Expand Down

0 comments on commit 5283dc4

Please sign in to comment.