Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

You cannot compute a sum with variable bounds. But if you fix N=4 or any other integer, this works.

sage: j,a,t = var('j,a,t')
sage: cj_t = (-1)**(j-1)/factorial(j-1)*(-j+a)**(j-1/2)*exp(-j)*(t+j)**(-1)
sage: N = 2
sage: add(cj_t(j=j) for j in range(1,N+1))
-(a - 2)^(3/2)*e^(-2)/(t + 2) + sqrt(a - 1)*e^(-1)/(t + 1)