cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A024326 a(n) = s(1)*t(n) + s(2)*t(n-1) + ... + s(k)*t(n+1-k), where k = floor((n+1)/2), s = A023531, t = A023533.

This page as a plain text file.
%I A024326 #13 Feb 06 2022 02:15:59
%S A024326 0,0,0,0,1,0,0,0,0,0,1,0,0,1,0,0,0,1,0,0,1,0,0,1,0,0,0,1,0,0,0,0,1,0,
%T A024326 0,1,0,0,2,0,0,0,1,0,0,0,0,1,0,0,0,0,0,1,0,0,1,0,0,1,1,0,0,1,0,0,0,0,
%U A024326 2,0,0,0,0,0,1,0,0,0,0,0,0,1,0,0,1,0,0,1,0,1
%N A024326 a(n) = s(1)*t(n) + s(2)*t(n-1) + ... + s(k)*t(n+1-k), where k = floor((n+1)/2), s = A023531, t = A023533.
%H A024326 G. C. Greubel, <a href="/A024326/b024326.txt">Table of n, a(n) for n = 1..1000</a>
%F A024326 a(n) = Sum_{j=1..floor((n+1)/2)} A023531(j)*A023533(n-j+1).
%t A024326 nmax = 120;
%t A024326 A023533:= A023533 = With[{ms= Table[m(m+1)(m+2)/6, {m, 0, nmax+5}]}, Table[If[MemberQ[ms, n], 1, 0], {n, 0, nmax+5}]];
%t A024326 AbsoluteTiming[Table[t=0; m=3; p=BitShiftRight[n]; n--; While[n>p, t += A023533[[n + 1]]; n -= m++]; t, {n, nmax}]] (* _G. C. Greubel_, Jan 29 2022  *)
%o A024326 (Sage)
%o A024326 nmax=120
%o A024326 @CachedFunction
%o A024326 def A023531(n):
%o A024326     if ((sqrt(8*n+9) -3)/2).is_integer(): return 1
%o A024326     else: return 0
%o A024326 @CachedFunction
%o A024326 def B_list(N):
%o A024326     A = []
%o A024326     for m in range(ceil((6*N)^(1/3))):
%o A024326         A.extend([0]*(binomial(m+2, 3) -len(A)) +[1])
%o A024326     return A
%o A024326 A023533 = B_list(nmax+5)
%o A024326 @CachedFunction
%o A024326 def A023324(n): return sum( A023531(j)*A023533[n-j+1] for j in (1..((n+1)//2)) )
%o A024326 [A023324(n) for n in (1..nmax)] # _G. C. Greubel_, Jan 29 2022
%Y A024326 Cf. A024312, A024313, A024314, A024315, A024316, A024317, A024318, A024319, A024320, A024321, A024322, A024323, A024324, A024325, A024327.
%Y A024326 Cf. A023531, A023533.
%K A024326 nonn
%O A024326 1,39
%A A024326 _Clark Kimberling_