There are doctests of the form 

    sage: x = random_value()
    sage: abs(floating_point_computation(x) - exact_value(x)) < tolerance
    True 

but every floating point computation has SOME values where it is 
ill-conditioned. I'm finding a steady trickle of test failures due to the 
(now) random seeds for each run. Whats the plan for that?

A) mark them all as # random

B) identify all such tests and pick a fixed seed for those

C) identify all such tests and do the error analysis to find a tolerance(x) 
that takes the numerical instabilities into account

D) ignore issue and pick a fixed seed for the buildbot, will still randomly 
fail for users


PS: Here is one to illustrate the issue:

sage -t --long --warn-long 50.7 
--random-seed=269711721119345330713403621242624346446 
src/sage/functions/exp_integral.py
**********************************************************************
File "src/sage/functions/exp_integral.py", line 1493, in 
sage.functions.exp_integral.exponential_integral_1
Failed example:
    for prec in [20..128]:  # long time (15s on sage.math, 2013)
        R = RealField(prec)
        S = RealField(prec+64)
        a = R.random_element(-15,10).exp()
        n = 2^ZZ.random_element(14)
        x = exponential_integral_1(a, n)
        y = exponential_integral_1(S(a), n)
        c = RDF(4 * max(1.0, y[0]))
        for i in range(n):
            e = float(abs(S(x[i]) - y[i]) << prec)
            if e >= c:
                print("exponential_integral_1(%s, %s)[%s] with precision %s 
has error of %s >= %s"%(a, n, i, prec, e, c))
Expected nothing
Got:
    exponential_integral_1(57.77854062056109797473161078505723378, 1)[0] 
with precision 127 has error of 4.75102130393081 >= 4.0
**********************************************************************
1 item had failures:
   1 of  11 in sage.functions.exp_integral.exponential_integral_1
    [275 tests, 1 failure, 7.23 s]
----------------------------------------------------------------------
sage -t --long --warn-long 50.7 
--random-seed=269711721119345330713403621242624346446 
src/sage/functions/exp_integral.py  # 1 doctest failed
----------------------------------------------------------------------

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-devel/6a08eaf8-227a-4340-8e33-a8c96a4ced32n%40googlegroups.com.

Reply via email to