kill(all)$

sumtest , version 1.0
peter.vlasschaert@gmail.com,30/10/2018.

load(lrats)$

p1:powerseries(log(1+x),x,0);

p2:intosum(p1);

p3:niceindices(p2);

p4:subst([i=2],part(p3,0));

p5:subst([inf=m],p3);

p6:intosum(p5);

p8:subst([m=5],p6);

p9:ev(p8,sum);

p10:unsum(p9,x);

p10a:ratsimp(p10);

p11:intosum(p8);

p12:factorsum(p9);

p12a:ratsimp(p12);

p13:ev(p9,unsum);

p13a:part(p8,1,2)=j;

p14:subst([p13a],p8);

p15:part(p14,1,0);

f(x,a,b):=-sum(((-1)^j*x^j)/j,j,a,b)$

p15a:f(x,1,5);

p15b:args(p11);

p15c:args(p2);

p15d:ev(p15b[2],integer);

p16:sum(p15b[1],i,p15b[3],p15b[4]);

p17:sum(p15c[1],i1,p15c[3],p15c[4]);

p17a:p15c;

p17b:p17a[2] = a;

p17c:subst([i1=rhs(p17b)],p17a);

p17d:sum(p17c[1],a,p17c[3],p17c[4]);

assume(abs(x)-1 <0);

p17e:f(x1,b,c):=sum(x1,a,b,c);

p17f:f(x^a,1,inf) =ev(f(x^a,p17c[3],p17c[4]) ,simpsum);

p17g:f(x^a,0,inf)-1 =ev(f(x^a,0,p17c[4]) ,simpsum)-1;

p17h:ratsimp(p17g);

p17h1:sumcontract(lhs(p17h))=rhs(p17h);

f(x^a,0,n) =ev(f(x^a,0,n) ,simpsum);

''sum(x^k, k, 1, inf) = ev(sum(x^k, k, 1, inf), simpsum);

''sum(x^k, k, 1, n)  =ev( sum(x^k, k, 1, n), simpsum);