Thanks Riccardo, this is a great patch, great description, nice job!

I was just about to push it in, but I noticed that doctests are broken:

$ ./setup.py test_doc
running test_doc
Testing docstrings.
....F.............................................................................................................................................................F.........F.......................
======================================================================
FAIL: Doctest: sympy.core.evalf.N
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib/python2.5/doctest.py", line 2128, in runTest
    raise self.failureException(self.format_failure(new.getvalue()))
AssertionError: Failed doctest test for sympy.core.evalf.N
  File "/home/ondra/repos/sympy.hg/sympy/core/evalf.py", line 998, in N

----------------------------------------------------------------------
File "/home/ondra/repos/sympy.hg/sympy/core/evalf.py", line 1007, in
sympy.core.evalf.N
Failed example:
    Sum(1/k**k, (k, 1, oo))
Expected:
    Sum(k**(-k), (k, 1, oo))
Got:
    Sum(1/(k**k), (k, 1, oo))


======================================================================
FAIL: Doctest: sympy.series.acceleration.shanks
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib/python2.5/doctest.py", line 2128, in runTest
    raise self.failureException(self.format_failure(new.getvalue()))
AssertionError: Failed doctest test for sympy.series.acceleration.shanks
  File "/home/ondra/repos/sympy.hg/sympy/series/acceleration.py", line
62, in shanks

----------------------------------------------------------------------
File "/home/ondra/repos/sympy.hg/sympy/series/acceleration.py", line
74, in sympy.series.acceleration.shanks
Failed example:
    print round(A.subs(n, 100).evalf(), 10)
Expected:
    0.6881721793
Got:
    1.6349839002
----------------------------------------------------------------------
File "/home/ondra/repos/sympy.hg/sympy/series/acceleration.py", line
76, in sympy.series.acceleration.shanks
Failed example:
    print round(shanks(A, n, 25).evalf(), 10)
Expected:
    0.6931396564
Got:
    1.6253312467
----------------------------------------------------------------------
File "/home/ondra/repos/sympy.hg/sympy/series/acceleration.py", line
78, in sympy.series.acceleration.shanks
Failed example:
    print round(shanks(A, n, 25, 5).evalf(), 10)
Expected:
    0.6931471806
Got:
    1.6437139714


======================================================================
FAIL: Doctest: sympy.simplify.simplify.together
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib/python2.5/doctest.py", line 2128, in runTest
    raise self.failureException(self.format_failure(new.getvalue()))
AssertionError: Failed doctest test for sympy.simplify.simplify.together
  File "/home/ondra/repos/sympy.hg/sympy/simplify/simplify.py", line
185, in together

----------------------------------------------------------------------
File "/home/ondra/repos/sympy.hg/sympy/simplify/simplify.py", line
223, in sympy.simplify.simplify.together
Failed example:
    together(1/x**y + 1/x**(y-1))
Expected:
    x**(-y)*(1 + x)
Got:
    (x**y + x**(-1 + y))/x**(-1 + 2*y)


----------------------------------------------------------------------
Ran 196 tests in 9.677s

FAILED (failures=3)



Two of them are broken by:

http://code.google.com/p/sympy/issues/detail?id=1147

however this one is broken by your patch:

======================================================================
FAIL: Doctest: sympy.series.acceleration.shanks
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib/python2.5/doctest.py", line 2128, in runTest
    raise self.failureException(self.format_failure(new.getvalue()))
AssertionError: Failed doctest test for sympy.series.acceleration.shanks
  File "/home/ondra/repos/sympy.hg/sympy/series/acceleration.py", line
62, in shanks

----------------------------------------------------------------------
File "/home/ondra/repos/sympy.hg/sympy/series/acceleration.py", line
74, in sympy.series.acceleration.shanks
Failed example:
    print round(A.subs(n, 100).evalf(), 10)
Expected:
    0.6881721793
Got:
    1.6349839002
----------------------------------------------------------------------
File "/home/ondra/repos/sympy.hg/sympy/series/acceleration.py", line
76, in sympy.series.acceleration.shanks
Failed example:
    print round(shanks(A, n, 25).evalf(), 10)
Expected:
    0.6931396564
Got:
    1.6253312467
----------------------------------------------------------------------
File "/home/ondra/repos/sympy.hg/sympy/series/acceleration.py", line
78, in sympy.series.acceleration.shanks
Failed example:
    print round(shanks(A, n, 25, 5).evalf(), 10)
Expected:
    0.6931471806
Got:
    1.6437139714



Could you please look into that what went wrong?

Thanks,
Ondrej

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"sympy-patches" group.
To post to this group, send email to sympy-patches@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sympy-patches?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to