Bug in Sum?
- To: mathgroup at smc.vnet.net
- Subject: [mg109109] Bug in Sum?
- From: gopher <gophergoon at gmail.com>
- Date: Mon, 12 Apr 2010 23:03:35 -0400 (EDT)
In the following, A and Expand[A] give different answers after when summed (a finite geometric series.) The result of summing A is clearly wrong, since it is independent of the parameters r and s. Abhishek In[44]:= A = x^(i - n) (x^(i - n) (1 - r x^n) - s); A == Expand[A] // Simplify Out[45]= True In[46]:= Sum[A, {i, 0, n - 1}] Out[46]= (x^(-2 n) (-1 + x^(2 n)))/(-1 + x^2) In[47]:= Sum[Expand[A], {i, 0, n - 1}] // FullSimplify Out[47]= -(( x^(-2 n) (-1 + x^n) (-1 + x^n (-1 + r + s + s x + r x^n)))/(-1 + x^2) )