From 2ee7b99e0270f80cf03b80418372f45274f46051 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Samuel=20Leli=C3=A8vre?= Date: Sat, 20 Nov 2021 13:34:16 +0100 Subject: 32905: abs tol for some CBF and RBF doctests --- src/sage/functions/gamma.py | 2 +- src/sage/rings/complex_arb.pyx | 6 +++--- src/sage/rings/real_arb.pyx | 24 ++++++++++++------------ src/sage/symbolic/function.pyx | 2 +- 4 files changed, 17 insertions(+), 17 deletions(-) diff --git a/src/sage/functions/gamma.py b/src/sage/functions/gamma.py index 3a4deef..307deb1 100644 --- a/src/sage/functions/gamma.py +++ b/src/sage/functions/gamma.py @@ -1049,7 +1049,7 @@ class Function_beta(GinacFunction): r""" TESTS:: - sage: RBF(beta(sin(3),sqrt(RBF(2).add_error(1e-8)/3))) + sage: RBF(beta(sin(3),sqrt(RBF(2).add_error(1e-8)/3))) # abs tol 6e-7 [7.407662 +/- 6.17e-7] """ return [x, y] diff --git a/src/sage/rings/complex_arb.pyx b/src/sage/rings/complex_arb.pyx index ce9b1b1..7e10ec9 100644 --- a/src/sage/rings/complex_arb.pyx +++ b/src/sage/rings/complex_arb.pyx @@ -4189,7 +4189,7 @@ cdef class ComplexBall(RingElement): TESTS: - sage: CBF(Ei(I)) + sage: CBF(Ei(I)) # abs tol 1e-16 [0.337403922900968 +/- 3.76e-16] + [2.51687939716208 +/- 2.01e-15]*I """ cdef ComplexBall result = self._new() @@ -4239,7 +4239,7 @@ cdef class ComplexBall(RingElement): TESTS: - sage: CBF(Ci(I)) + sage: CBF(Ci(I)) # abs tol 1e-17 [0.837866940980208 +/- 4.72e-16] + [1.570796326794897 +/- 5.54e-16]*I """ cdef ComplexBall result = self._new() @@ -4291,7 +4291,7 @@ cdef class ComplexBall(RingElement): TESTS: - sage: CBF(Chi(I)) + sage: CBF(Chi(I)) # abs tol 1e-16 [0.337403922900968 +/- 3.25e-16] + [1.570796326794897 +/- 5.54e-16]*I """ cdef ComplexBall result = self._new() diff --git a/src/sage/rings/real_arb.pyx b/src/sage/rings/real_arb.pyx index 80a840e..49caa63 100644 --- a/src/sage/rings/real_arb.pyx +++ b/src/sage/rings/real_arb.pyx @@ -3489,12 +3489,12 @@ cdef class RealBall(RingElement): EXAMPLES:: - sage: RBF(1).Ei() + sage: RBF(1).Ei() # abs tol 5e-16 [1.89511781635594 +/- 4.94e-15] TESTS:: - sage: RBF(Ei(1)) + sage: RBF(Ei(1)) # abs tol 5e-16 [1.89511781635594 +/- 4.94e-15] """ cdef RealBall res = self._new() @@ -3531,12 +3531,12 @@ cdef class RealBall(RingElement): EXAMPLES:: - sage: RBF(1).Ci() + sage: RBF(1).Ci() # abs tol 1e-16 [0.337403922900968 +/- 3.25e-16] TESTS:: - sage: RBF(Ci(1)) + sage: RBF(Ci(1)) # abs tol 1e-16 [0.337403922900968 +/- 3.25e-16] """ cdef RealBall res = self._new() @@ -3575,12 +3575,12 @@ cdef class RealBall(RingElement): EXAMPLES:: - sage: RBF(1).Chi() + sage: RBF(1).Chi() # abs tol 1e-17 [0.837866940980208 +/- 4.72e-16] TESTS:: - sage: RBF(Chi(1)) + sage: RBF(Chi(1)) # abs tol 1e-17 [0.837866940980208 +/- 4.72e-16] """ cdef RealBall res = self._new() @@ -3597,7 +3597,7 @@ cdef class RealBall(RingElement): EXAMPLES:: - sage: RBF(3).li() + sage: RBF(3).li() # abs tol 1e-15 [2.16358859466719 +/- 4.72e-15] TESTS:: @@ -3621,7 +3621,7 @@ cdef class RealBall(RingElement): EXAMPLES:: - sage: RBF(3).Li() + sage: RBF(3).Li() # abs tol 1e-15 [1.11842481454970 +/- 7.61e-15] """ cdef RealBall res = self._new() @@ -3648,9 +3648,9 @@ cdef class RealBall(RingElement): EXAMPLES:: - sage: RBF(sin(3)).beta(RBF(2/3).sqrt()) + sage: RBF(sin(3)).beta(RBF(2/3).sqrt()) # abs tol 1e-13 [7.407661629415 +/- 1.07e-13] - sage: RealBallField(100)(7/2).beta(1) + sage: RealBallField(100)(7/2).beta(1) # abs tol 1e-30 [0.28571428571428571428571428571 +/- 5.23e-30] sage: RealBallField(100)(7/2).beta(1, 1/2) [0.025253813613805268728601584361 +/- 2.53e-31] @@ -3685,9 +3685,9 @@ cdef class RealBall(RingElement): sage: RBF(1/2).gamma() [1.772453850905516 +/- ...e-16] - sage: RBF(gamma(3/2, RBF(2).sqrt())) + sage: RBF(gamma(3/2, RBF(2).sqrt())) # abs tol 2e-17 [0.37118875695353 +/- 3.00e-15] - sage: RBF(3/2).gamma_inc(RBF(2).sqrt()) + sage: RBF(3/2).gamma_inc(RBF(2).sqrt()) # abs tol 2e-17 [0.37118875695353 +/- 3.00e-15] .. SEEALSO:: diff --git a/src/sage/symbolic/function.pyx b/src/sage/symbolic/function.pyx index 89cdce5..480a601 100644 --- a/src/sage/symbolic/function.pyx +++ b/src/sage/symbolic/function.pyx @@ -626,7 +626,7 @@ cdef class Function(SageObject): sage: b = RBF(3/2, 1e-10) sage: airy_ai(b) airy_ai([1.500000000 +/- 1.01e-10]) - sage: gamma(b, 1) + sage: gamma(b, 1) # abs tol 4.5e-9 [0.50728223 +/- 4.67e-9] sage: hurwitz_zeta(b, b) hurwitz_zeta([1.500000000 +/- 1.01e-10], [1.500000000 +/- 1.01e-10]) -- cgit v1.0-1-gd88e