login
A023868
a(n) = 1*t(n) + 2*t(n-1) + ... + k*t(n+1-k), where k=floor((n+1)/2) and t is A023533.
1
1, 0, 0, 1, 2, 3, 4, 0, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 17, 19, 21, 23, 25, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 23, 25, 27, 29, 31, 33, 35, 37, 39, 41, 43, 45, 47, 49, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 30, 32
OFFSET
1,5
LINKS
FORMULA
a(n) = Sum_{j=1..floor((n+1)/2)} j * A023533(n-j+1).
MATHEMATICA
A023533[n_]:= A023533[n]= If[Binomial[Floor[Surd[6*n-1, 3]] +2, 3]!= n, 0, 1];
A023868[n_]:= A023868[n]= Sum[j*A023533[n-j+1], {j, Floor[(n+1)/2]}];
Table[A023868[n], {n, 100}] (* G. C. Greubel, Jul 21 2022 *)
PROG
(Magma)
A023533:= func< n | Binomial(Floor((6*n-1)^(1/3)) +2, 3) ne n select 0 else 1 >;
[(&+[k*A023533(n+1-k): k in [1..Floor((n+1)/2)]]): n in [1..100]]; // G. C. Greubel, Jul 18 2022
(SageMath)
def A023533(n): return 0 if (binomial(floor((6*n-1)^(1/3)) +2, 3)!= n) else 1
def A023868(n): return sum(j*A023533(n-j+1) for j in (1..((n+1)//2)))
[A023868(n) for n in (1..100)] # G. C. Greubel, Jul 21 2022
CROSSREFS
Cf. A023533.
Sequence in context: A037883 A350775 A330267 * A122275 A197024 A031235
KEYWORD
nonn
EXTENSIONS
Title simplified by Sean A. Irvine, Jun 12 2019
STATUS
approved