[sympy] documentation for Sum?

2009-07-29 Thread Phillip M. Feldman
I'd like to be able to calculate symbolic Sums (finite and infinite). >From searches of this discussion group, it's clear that this can be done, but I can't find any relevant documentation. Any pointers will be appreciated. --~--~-~--~~~---~--~~ You received this

[sympy] Re: documentation for Sum?

2009-07-30 Thread Phillip M. Feldman
Something must be missing from that URL (I've tried various prefixes, but couldn't make any of them work). Phillip > We are missing good documentation for this, but look here for tons of > examples how to evaluate sums symbolically and numerically: > > sympy/concrete/tests/test_sums_products.py

[sympy] Re: documentation for Sum?

2009-07-30 Thread Phillip M. Feldman
I hate underscores, but Sum with a capital S seems reasonable. When doing the import, one could choose to import SymPy.sum as Sum, but it would be more convenient to be able to do 'from SymPy import *' and get everything at one shot. > > BTW: What about using sum_ or Sum instead of overwriting Py

[sympy] problem with sum: bug or user error?

2009-07-30 Thread Phillip M. Feldman
I tried to construct a simple sum based on the examples in test_sums_products.py; here's my code: from sympy import * n= Symbol('n', integer=True) print Rational(1,2)+Rational(1,3)+Rational(1,4) print sum(Rational(1,n), (n, 2, 4)) The first print statement gives the correct result, 13/12. The s

[sympy] support for divergent sums?

2009-07-30 Thread Phillip M. Feldman
When I type something like the following, I would expect to get a result of oo, indicating that the sum diverges to infinity: sum(1/n, (n, 2, oo)) Instead, I get the same thing back (actually not quite-- the 's' changes to a capital 'S'). Any idea why this doesn't work? --~--~-~--~~

[sympy] Re: problem with sum: bug or user error?

2009-07-30 Thread Phillip M. Feldman
Actually, n was declared to be an integer. Consider the following four sums: #1: sum(1/3,(n,1,3)) #2: sum(Rational(1,3),(n,1,3)) #3: sum(1/n,(n,1,3)) #4: sum(Rational(1,n),(n,1,3)) #s 2 and 3 work, while #s 1 and 4 don't. This seems strange. I understand that #1 gives a result of zero because

[sympy] Re: support for divergent sums?

2009-07-31 Thread Phillip M. Feldman
That would be much nicer! Phillip > Maybe the sum could return oo immediately. > > Ondrej --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "sympy" group. To post to this group, send email to sympy@googlegroups.com To

[sympy] documentation of polynomials module is out-of-date

2016-05-23 Thread Phillip M. Feldman
Documentation at http://docs.sympy.org/0.6.7/modules/polynomials.html gives the following example: from sympy import * x, y, z = symbols('xyz') This doesn't work. I believe that the syntax has changed. -- You received this message because you are subscribed to the Google Groups "sympy

[sympy] polynomials over GF(2)

2016-05-23 Thread Phillip M. Feldman
I would like to perform operations on polynomials over GF(2), i.e., polynomials with binary coefficients. Is there a way to do this with SymPy? There is a sympy.polys.galoistools module, but I haven't found any user documentation for it -- You received this message because you are subscribed