A pattern hard to recognize?



-----giovanni gherdovich wrote: -----


>My goal is to make this simplification:
>
>-(k+1)*binomial(n,k+1)/(2*(n-k)*2^n)    --->
>     -binomial(n,k)/2^(n+1)

(%i1) binomial_id : 'binomial = lambda([n,k], (n-k + 1) *
binomial(n,k-1)/k);
(%o1) binomial=lambda([n,k],((n-k+1)*binomial(n,k-1))/k)
(%i2) subst(binomial_id, -(k+1) * binomial(n,k+1)/(2 * (n-k)*2^k));
(%o2) ((-k-1)*binomial(n,k))/(2*(k+1)*2^k)
(%i3) ratsimp(%);
(%o3) -binomial(n,k)/(2*2^k)

Barton