```Date: Feb 17, 2013 2:50 AM
Author: David Bernier
Subject: Re: Bernoulli numbers and sqrt(1)+sqrt(2)+sqrt(3) + ... sqrt(1000)

On 02/17/2013 02:38 AM, David Bernier wrote:> On 02/16/2013 01:42 AM, David Bernier wrote:>> The Bernoulli numbers can be used to compute for example>> 1^10 + 2^10 + ... + 1000^10 .>>>> Jakob Bernoulli wrote around 1700-1713 that he had computed>> the sum of the 10th powers of the integers 1 through 1000,>> with the result:>> 91409924241424243424241924242500>>>> in less than "one half of a quarter hour" ...>>>> Suppose we change the exponent from 10 to 1/2, so the sum>> is then:>> sqrt(1) + sqrt(2) + ... sqrt(1000).>>>> Or, more generally,>> sqrt(1) + sqrt(2) + ... sqrt(N) , N some largish positive>> integer.>>>> Can Bernoulli numbers or some generalization be used>> to compute that efficiently and accurately?>>>> My first thought would be that the Euler-MacLaurin>> summation method might be applicable.>>>> Above, if k^a is the k'th term, a = 1/2 .> [...]>> Numerical experiments suggest a pattern of> excellent approximations.>> There's a series involving N^(3/2), N^(1/2),> N^(-5/2), N^(-9/2) and a constant term C.oops. There's also an N^(-1/2) term.> To get rid of the unkwown C, I take the difference> of the sum of square roots of integers up to N and> a smaller number N' .>> For example, N = 2000, N' = 1000:>> Below, A is in fact sum_{k=1001 ... 2000} sqrt(k) :>> A = (sum(X=1,2000,sqrt(X)) - sum(X=1,1000,sqrt(X)));>> Below, B is the approximation broken over 5 lines:>> B= (2/3)*(2000^( 1.5)-1000^( 1.5))\> +(1/2)*(2000^( 0.5)-1000^( 0.5))\> +(1/24)*(2000^(-0.5)-1000^(-0.5))\> +(-1/1920)*(2000^(-2.5)-1000^(-2.5))\> +(1/9216)*(2000^(-4.5)-1000^(-4.5));>>> ? A - B> %280 = 2.09965132898428157559493347219264943224 E-24>> So, | A - B | < 1/(10^23) .>> David Bernier>-- dracut:/# lvm vgcfgrestoreFile descriptor 9 (/.console_lock) leaked on lvm invocation. Parent PID 993: sh   Please specify a *single* volume group to restore.
```