A270103 Array read by antidiagonals: T(n, k) is the sum of the integer part of the n-th roots of natural numbers less than k.
1, 3, 1, 6, 2, 1, 10, 3, 2, 1, 15, 5, 3, 2, 1, 21, 7, 4, 3, 2, 1, 28, 9, 5, 4, 3, 2, 1, 36, 11, 6, 5, 4, 3, 2, 1, 45, 13, 7, 6, 5, 4, 3, 2, 1, 55, 16, 9, 7, 6, 5, 4, 3, 2, 1, 66, 19, 11, 8, 7, 6, 5, 4, 3, 2, 1
Offset: 1
Examples
The fifth entry in the second row of this array is 7, since 7 = floor(sqrt(1)) + floor(sqrt(2)) + floor(sqrt(3)) + floor(sqrt(4)) + floor(sqrt(5)). The table array begins: 1, 3, 6, 10, 15, 21, 28, 36, 45, 55, ... 1, 2, 3, 5, 7, 9, 11, 13, 16, 19, ... 1, 2, 3, 4, 5, 6, 7, 9, 11, 13, ... 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, ... ...
References
- R. L. Graham, D. E. Knuth, and O. Patashnik, Concrete Mathematics, 2nd Edition, Addison-Wesley, 1994, Eq. 3.27 on page 87.
- D. E. Knuth, The Art of Computer Programming, Vol. 1, 3rd Edition, Addison-Wesley, 1997, Ex. 43 of section 1.2.4.
Links
- M. Griffiths, More Sums Involving the Floor Function, Math. Gaz., 86 (2002), 285-287.
- Maths StackExchange, Find a formula for Sum_{k=1..n} floor(sqrt(k)), see achille hui formula.
- Wikipedia, Faulhaber's formula
Crossrefs
Programs
-
Mathematica
T[n_, k_] := (1 + k) Floor[k^(1/n)] - HarmonicNumber[Floor[k^(1/n)], -n] (* Daniel Hoying, Jun 11 2020 *)
-
PARI
T(n, k) = sum(j=0, k, sqrtnint(j, n)); \\ Michel Marcus, Mar 12 2016
Formula
T(n,k) = Sum_{j=0..k} floor(j^(1/n)).
T(n,k) = (1+k)*floor(k^(1/n)) - (1/(n+1))*Sum_{j=1..n+1} (1 + floor(k^(1/n)))^j*binomial(n+1, j)*Bernoulli(n+1-j).
T(n,k) = (1+k)*floor(k^(1/n)) - Sum_{j=1..floor(k^(1/n))} j^n. - Daniel Hoying, Jun 11 2020