Pepe,
That's a great trick--thanks. Maybe now I'll remember to append 'box' to my toolbox.
My actual problem was that I wanted to incorporate the term s^2-1 into the two terms in the numerator in (an integral representation for an
Appell function after a fractional linear transformation). It's easy enough to do by hand, but box works great:
(%i105) integrate(((1-s)^(c-a)*(s+1)^a*(2*A+s-1)^(-c+b2+b1))/((s^2-1)*(-((s+1)*x-2)*A+s-1)^b1*(-((s+1)*y-2)*A+s-1)^b2),s,-1,1)$
(%i106) scanmap('factor,%)$
(%i107) subst(-box(1-s),s-1,%);
(%o107) -integrate(((1-s)^(c-a-1)*(s+1)^(a-1))/((2*A+s-1)^(c-b2-b1)*(-(s*x*A+x*A-2*A-s+1))^b1*(-(s*y*A+y*A-2*A-s+1))^b2),s,-1,1)
--Barton
________________________________
From: Pepe Sanchez
Using box does the job
aux: (1-x)^a/(x-1);
aux: ratsubst(box(1-x),1-x,aux);