Re: [sympy] Problems in the documentation of the rising factorial

2016-04-29 Thread Peter Luschny
> Double check that > import sympy > sympy.__version__ > gives '1.0'. Yes, this was the issue. Solved and thanks. Peter -- You received this message because you are subscribed to the Google Groups "sympy" group. To unsubscribe from this group and stop receiving emails from it, send an email t

Re: [sympy] Problems in the documentation of the rising factorial

2016-04-29 Thread Peter Luschny
> I'm not sure why this definition is made. It seems like a bad one, > since there are two different ways to interpret rf(a, b) if a is a > polynomial. > For the other two, I get the same thing as the docstring in SymPy 1.0 > These seem mathematically correct. Thank you very much. I agree with yo

Re: [sympy] Problems in the documentation of the rising factorial

2016-04-28 Thread Peter Luschny
> > We still haven't updated SymPy Live to SymPy 1.0, so the output of > some examples may be different. > Thanks! Maybe I expressed myself misleading. Also the output in my yupyter notebook did not correspond to what is in the documentation. I have difficulty to understand the output of the

[sympy] Problems in the documentation of the rising factorial

2016-04-28 Thread Peter Luschny
http://docs.sympy.org/latest/modules/functions/combinatorial.html#risingfactorial I executed the examples in SymPy-Live but got different outputs from what the docs say. For example for >>> rf(x, k).rewrite(ff) gives nothing instead of: FallingFactorial(k + x - 1, k) >>> rf(x, k).rewrite(bino

[sympy] Re: Generating functions in Sympy

2016-01-16 Thread Peter Luschny
> > are consistent with the definitions from the previous link. For instance, > I have the feeling that I don't understand l.g.f. (logarithmic generating > function) exactly the same way as some contributors in the OEIS > The definitive guide for these definitions is Bruno Salvy's gefun packag

Re: [sympy] Two integration test suites

2013-09-16 Thread Peter Luschny
>> In fact they developed around the discussion of >> Albert Rich's Rubi (RUle-Based Integration). It is worth to look this up: >> http://www.apmaths.uwo.ca/~arich/ > if their claim to outperform Wolfram > Mathematica is correct, that could become the strongest integrator ever. It was one of the

Re: [sympy] Two integration test suites

2013-09-13 Thread Peter Luschny
AM> Yes, the fallback algorithm in SymPy, heurisch, is very slow. What's AM> the longest time an integral took that still gave an answer from your AM> tests? Most of the time I used a time-out of one minute, so I cannot tell. But see this comment by Waldek Hebisch: https://groups.google.com/d/msg/

[sympy] Two integration test suites

2013-09-12 Thread Peter Luschny
Two integration test suites For some history of the two integration test suites see [1]. An implementation for SymPy can be found at github [2]. The results are listed at [3]. Running the test suites I found some examples which seem to need special attention by the developers: [161] Timofeev i

[sympy] A possible bug in integrate

2013-09-11 Thread Peter Luschny
Consider (F1) sqrt(1+x^3)/x (F2) sqrt(1+1/x^3)*sqrt(x) According to Mathematica's online integrator (I1) integral F1 dx = (2/3)*(sqrt(x^3+1)-arctanh(sqrt(x^3+1))) (I2) integral F2 dx = (2*sqrt(1/x^3+1)*x^(3/2)*(sqrt(x^3+1)-arctanh(sqrt(x^3+1/(3*sqrt(x^3+1)) SymPy Live computes (I1) as (

Re: [sympy] Possible improvement of the factorial function.

2013-08-20 Thread Peter Luschny
> Are there improvements that can be made to SymPy's > factorial or not? It depends how you explain the difference between the behaviour in Sage and SymPy. If my speculation is right the basic product prod_i=0^n a[i] is implemented suboptimal in SymPy. Otherwise this product would (for large n) b

Re: [sympy] Possible improvement of the factorial function.

2013-08-20 Thread Peter Luschny
I looked today another time into the factorial function. Unfortunately the observed gain only works with the Sage implementation of 'prime_range' (which I used) but not with the SymPy implementation. First of all Sage's 'prime_range' returns a list whereas SymPy's 'primerange' is an iterator. T

[sympy] Possible improvement of the factorial function.

2013-08-19 Thread Peter Luschny
Hi all, looking yesterday at some SymPy code I observed that the factorial function can be tuned by a simple in place substitution of the function "swing". timeit("sympy_factorial(100)", number=10) timeit("factorialPS(100)", number=10) 10 loops, best of 3: 2.02 s per loop 10 loops, best