%I #21 Dec 11 2024 15:42:29
%S 0,1,2,3,2,3,4,4,5,6,3,4,5,5,6,7,6,7,8,9,4,5,6,6,7,8,7,8,9,10,8,9,10,
%T 11,12,5,6,7,7,8,9,8,9,10,11,9,10,11,12,13,10,11,12,13,14,15,6,7,8,8,
%U 9,10,9,10,11,12,10,11,12,13,14,11,12,13,14,15,16,12,13,14,15,16,17,18,7
%N b + c + d where b >= c >= d >= 0 ordered by b then c then d.
%H Robert Israel, <a href="/A070770/b070770.txt">Table of n, a(n) for n = 0..10000</a>
%F a(n) = A056556(n) + A056557(n) + A056558(n).
%e Triangle begins:
%e 0,
%e ;
%e 1;
%e 2, 3;
%e ;
%e 2;
%e 3, 4;
%e 4, 5, 6;
%e ;
%e 3;
%e 4, 5,
%e 5, 6, 7;
%e 6, 7, 8, 9;
%e ;
%e 4;
%e 5, 6;
%e 6, 7, 8;
%e 7, 8, 9, 10;
%e 8, 9, 10, 11, 12;
%e ;
%e ...
%p seq(seq(seq(b+c+d,d=0..c),c=0..b),b=0..10); # _Robert Israel_, Jun 21 2018
%o (PARI) for(x=0,5,for(y=0,x,for(z=0,y,print1(x+y+z", ")))) \\ _Charles R Greathouse IV_, Sep 17 2015
%o (Python)
%o from math import isqrt, comb
%o from sympy import integer_nthroot
%o def A070770(n): return (m:=integer_nthroot(6*(n+1),3)[0])+(a:=n>=comb(m+2,3))+(k:=isqrt(b:=(c:=n+1-comb(m+a+1,3))<<1))-((b<<2)<=(k<<2)*(k+1)+1)+c-2-comb(k+(b>k*(k+1)),2) # _Chai Wah Wu_, Dec 11 2024
%Y Cf. A001477, A051162, A070771, A070772 for similar sequences with different numbers of terms summed.
%K nonn,look,tabf
%O 0,3
%A _Henry Bottomley_, May 06 2002