need to calculte the sum of SIGMA(-1)^n*(1/(2n+1)) from n=0 to n=N
how to do the trick for + - + - + ........ ?
TNX .......
Code:
for (i=0; i<N; i++)
{
X1=(-1)*(1/(1+2*i));
X=X-X1;
}
printf("%lf", X);
how to do the trick for + - + - + ........ ?
TNX .......
Comment