OFFSET
0,2
COMMENTS
Row sums of the irregular triangle A255250. - Wolfdieter Lang, Mar 15 2015
FORMULA
a(n) = sum(floor(sqrt(n^2 - m^2)) - (m-1), m = 0.. floor(n/sqrt(2))), n >= 0. See A255250. - Wolfdieter Lang, Mar 15 2015
MAPLE
A036702 := proc(n)
local a, x, y ;
a := 0 ;
for x from 0 do
if x^2 > n^2 then
return a;
fi ;
for y from 0 to x do
if y^2+x^2 <= n^2 then
a := a+1 ;
end if;
end do;
end do:
end proc: # R. J. Mathar, Oct 29 2011
MATHEMATICA
a[n_] := Module[{a, b}, If[n == 0, 1, Reduce[a^2 + b^2 <= n^2 && a >= 0 && 0 <= b <= a, {a, b}, Integers] // Length]];
a /@ Range[0, 49] (* Jean-François Alcover, Oct 17 2019 *)
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
STATUS
approved