login
Floor of sum of the first n^2 square roots.
0

%I #8 Dec 29 2014 03:27:40

%S 0,1,6,19,44,85,146,231,345,490,671,892,1157,1470,1836,2257,2738,3283,

%T 3896,4581,5343,6184,7109,8122,9227,10428,11730,13135,14648,16273,

%U 18014,19875,21861,23974,26219,28600,31121,33786,36600,39565,42686,45967

%N Floor of sum of the first n^2 square roots.

%C a(n)-A005900(n)={0,0,0,0,0,0,0,1,1,1,1,1,1,2,2,2,2,2,2,3,3,3,3,3,3,4,4,4,4,4,4,5,5,5,5,5,5,6,6,6,...}

%t A[n_]:=Floor[HarmonicNumber[n^2,-1/2]] (* or *) A[n_]:=Floor[(2/3)n^3+n/2+1/(24n)+Zeta[ -1/2]]

%t nn=50;With[{c=Sqrt[Range[nn^2]]},Table[Floor[Total[Take[c,n^2]]],{n,0,nn}]] (* _Harvey P. Dale_, Apr 21 2012 *)

%o (PARI) a(n)=floor(sum(x=0,n^2,sqrt(x)))

%Y Cf. A005900 (Octahedral numbers:(2n^3+n)/3).

%K nonn

%O 0,3

%A _Zak Seidov_, Mar 16 2008