login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A224326 Number of partitions of n into 3 distinct triangular numbers. 2

%I #24 Feb 07 2022 20:18:31

%S 0,0,0,0,1,0,0,1,0,1,1,1,0,1,1,0,2,1,1,2,0,1,2,0,2,2,1,1,2,1,1,3,2,0,

%T 2,1,1,4,1,3,1,1,2,2,2,1,4,1,1,4,1,2,4,1,2,2,2,2,3,2,2,4,1,2,3,2,3,4,

%U 1,2,4,2,3,3,2,1,5,2,0,5,1,4,5,2,4,2,2

%N Number of partitions of n into 3 distinct triangular numbers.

%C Indices of zeros: 0 followed by A002243.

%H T. D. Noe, <a href="/A224326/b224326.txt">Table of n, a(n) for n = 0..10000</a>

%H Jon Maiga, <a href="http://sequencedb.net/s/A224326">Computer-generated formulas for A224326</a>, Sequence Machine.

%t nn = 150; tri = Table[n*(n + 1)/2, {n, 0, nn}]; t = Table[0, {tri[[-1]]}]; Do[s = tri[[i]] + tri[[j]] + tri[[k]]; If[s <= tri[[-1]], t[[s]]++], {i, nn}, {j, i + 1, nn}, {k, j + 1, nn}]; t = Join[{0}, t] (* _T. D. Noe_, Apr 05 2013 *)

%o (Python)

%o TOP = 777

%o for n in range(TOP):

%o k = 0

%o for x in range(TOP):

%o s = x*(x+1)//2

%o if s>n: break

%o for y in range(x+1,TOP):

%o sy = s + y*(y+1)//2

%o if sy>n: break

%o for z in range(y+1,TOP):

%o sz = sy + z*(z+1)//2

%o if sz>n: break

%o if sz==n: k+=1

%o print(str(k), end=',')

%Y Cf. A000217, A002243, A033761.

%Y Cf. A025436 (number of partitions of n into 3 distinct squares).

%Y Cf. A002636 (allows nondistinct triangular numbers).

%K nonn

%O 0,17

%A _Alex Ratushnyak_, Apr 03 2013

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified May 7 21:53 EDT 2024. Contains 372317 sequences. (Running on oeis4.)