[x+(1/y)]+[x^2+(1/y^2)]+...+[x^n+(1/y^n)]
=(x+x^2+……+x^n)+(1/y+1/y^2+……+1/y^n)
x+x^2+……+x^n是以x为首项,x为公比的等比数列,有x项
所以和=x(x^n-1)/(x-1)
1/y+1/y^2+……+1/y^n是以1/y为首项,1/y为公比的等比数列,有x项
所以和=(1/y)[(1/y)^n-1]/(1/y-1)
=(1-y)[(1/y)^n-1]
所以[x+(1/y)]+[x^2+(1/y^2)]+...+[x^n+(1/y^n)]
=x(x^n-1)/(x-1)+(1-y)[(1/y)^n-1]