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.

A023565 Convolution of A023531 and A023533.

Original entry on oeis.org

0, 1, 0, 0, 2, 0, 0, 1, 1, 0, 1, 1, 0, 2, 0, 0, 1, 1, 0, 1, 1, 0, 2, 1, 0, 0, 1, 1, 1, 1, 0, 0, 1, 0, 1, 2, 0, 1, 2, 0, 0, 0, 1, 2, 0, 1, 1, 1, 0, 0, 0, 0, 1, 3, 0, 0, 2, 0, 0, 1, 1, 0, 2, 1, 1, 0, 0, 1, 2, 0, 0, 0, 1, 1, 1, 0, 1, 1, 0, 1, 0, 1, 0, 1, 1, 1, 0, 2, 0, 2
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Magma
    A023531:= func< n | IsIntegral((Sqrt(8*n+9) - 3)/2) select 1 else 0 >;
    A023533:= func< n | Binomial(Floor((6*n-1)^(1/3)) +2, 3) ne n select 0 else 1 >;
    [(&+[A023533(k)*A023531(n+1-k): k in [1..n]]): n in [1..100]]; // G. C. Greubel, Jul 16 2022
    
  • Mathematica
    A023531[n_]:= If[IntegerQ[(Sqrt[8*n+9] -3)/2], 1, 0];
    A023533[n_]:= If[Binomial[Floor[Surd[6*n-1, 3]] +2, 3] != n, 0, 1];
    A023565[n_]:= A023565[n]= Sum[A023533[k]*A023531[n-k+1], {k,n}];
    Table[A023565[n], {n,100}] (* G. C. Greubel, Jul 16 2022 *)
  • SageMath
    @CachedFunction
    def A023531(n): return 1 if ((sqrt(8*n+9) -3)/2).is_integer()  else 0
    @CachedFunction
    def A023533(n): return 0 if binomial( floor((6*n-1)^(1/3)) +2, 3)!=n else 1
    [sum(A023533(k)*A023531(n-k+1) for k in (1..n)) for n in (1..100)] # G. C. Greubel, Jul 16 2022

Formula

a(n) = Sum_{j=1..n} A023533(j) * A023531(n-j+1). - G. C. Greubel, Jul 16 2022