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!)
A339416 Number of compositions (ordered partitions) of n into an even number of triangular numbers. 3
1, 0, 1, 0, 3, 0, 6, 2, 13, 6, 28, 20, 61, 56, 135, 148, 308, 380, 707, 950, 1654, 2340, 3897, 5714, 9252, 13858, 22055, 33492, 52735, 80744, 126313, 194376, 302906, 467506, 726862, 1123830, 1744947, 2700682, 4190016, 6488824, 10062649, 15588714, 24168232, 37447884 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,5
LINKS
FORMULA
G.f.: (1/2) * (1 / (1 - Sum_{k>=1} x^(k*(k + 1)/2)) + 1 / Sum_{k>=0} x^(k*(k + 1)/2)).
a(n) = (A023361(n) + A106507(n)) / 2.
a(n) = Sum_{k=0..n} A023361(k) * A106507(n-k).
EXAMPLE
a(9) = 6 because we have [6, 3], [3, 6], [6, 1, 1, 1], [1, 6, 1, 1], [1, 1, 6, 1] and [1, 1, 1, 6].
MAPLE
b:= proc(n, t) option remember; local r, f, g;
if n=0 then t else r, f, g:=$0..2; while f<=n
do r, f, g:= r+b(n-f, 1-t), f+g, g+1 od; r fi
end:
a:= n-> b(n, 1):
seq(a(n), n=0..50); # Alois P. Heinz, Dec 03 2020
MATHEMATICA
nmax = 43; CoefficientList[Series[(1/2) (1/(1 - Sum[x^(k (k + 1)/2), {k, 1, nmax}]) + 1/Sum[x^(k (k + 1)/2), {k, 0, nmax}]), {x, 0, nmax}], x]
CROSSREFS
Sequence in context: A011079 A334874 A343903 * A226535 A005928 A113062
KEYWORD
nonn
AUTHOR
Ilya Gutkovskiy, Dec 03 2020
STATUS
approved

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 April 18 22:18 EDT 2024. Contains 371782 sequences. (Running on oeis4.)