1/x(x+1)+1/(x+1)(x+2)+1/(x+2)(x+3)+……+1/(x+1998)(x+1999),并求当x=1时,该代数式的值.

来源:学生作业帮助网 编辑:六六作业网 时间:2024/11/16 16:00:20
1/x(x+1)+1/(x+1)(x+2)+1/(x+2)(x+3)+……+1/(x+1998)(x+1999),并求当x=1时,该代数式的值.1/x(x+1)+1/(x+1)(x+2)+1/(x+2

1/x(x+1)+1/(x+1)(x+2)+1/(x+2)(x+3)+……+1/(x+1998)(x+1999),并求当x=1时,该代数式的值.
1/x(x+1)+1/(x+1)(x+2)+1/(x+2)(x+3)+……+1/(x+1998)(x+1999),并求当x=1时,该代数式的值.

1/x(x+1)+1/(x+1)(x+2)+1/(x+2)(x+3)+……+1/(x+1998)(x+1999),并求当x=1时,该代数式的值.
1/x(x+1)=1/x-1/(x+1)
1/(x+1)(x+2)=1/(x+1)-1/(x+2)
1/(x+2)(x+3)-1/(x+2)-1/(x+3)
……
1/(x+1998)(x+1999)=1/(x+1998)-1/(x+1999)
所以,
1/x(x+1)+1/(x+1)(x+2)+1/(x+2)(x+3)+……+1/(x+1998)(x+1999)
=1/x-1/(x+1999)
当x=1时,
1/x(x+1)+1/(x+1)(x+2)+1/(x+2)(x+3)+……+1/(x+1998)(x+1999)
=1/x-1/(x+1999)
=1-1/2000
=1999/2000

#include
#define x 1
void main()
{
int n;
float sum;
for(n=1,sum=0;n<=1999;n++)
{
sum=sum+1.0/((x+n-1)*(x+n));
}
printf("%f",sum);
}