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.

A212971 Number of triples (w,x,y) with all terms in {0,...,n} and w < floor((x+y)/3).

Original entry on oeis.org

0, 0, 3, 11, 25, 48, 82, 128, 189, 267, 363, 480, 620, 784, 975, 1195, 1445, 1728, 2046, 2400, 2793, 3227, 3703, 4224, 4792, 5408, 6075, 6795, 7569, 8400, 9290, 10240, 11253, 12331, 13475, 14688, 15972, 17328, 18759, 20267, 21853, 23520
Offset: 0

Views

Author

Clark Kimberling, Jun 03 2012

Keywords

Comments

For a guide to related sequences, see A212959.

Crossrefs

Programs

  • Mathematica
    t = Compile[{{n, _Integer}}, Module[{s = 0},
    (Do[If[w < Floor[(x + y)/3], s = s + 1],
    {w, 0, n}, {x, 0, n}, {y, 0, n}]; s)]];
    m = Map[t[#] &, Range[0, 60]]   (* A212971*)
    LinearRecurrence[{3,-3,2,-3,3,-1},{0,0,3,11,25,48},50] (* Harvey P. Dale, Aug 24 2021 *)

Formula

a(n) = 3*a(n-1) - 3*a(n-2) + 2*a(n-3) - 3*a(n-4) + 3*a(n-5) - a(n-6).
G.f.: (x^2)*(3 + 2*x + x^2)/((1 + x + x^2)*(1-x)^4).
a(n) = (n+1)^3 - A212972(n).
From Ayoub Saber Rguez, Dec 11 2023: (Start)
a(n) = A045991(n+1) - A212974(n).
a(n) = (n^3 + n^2 - n - 1 + (((n+1) mod 3) mod 2))/3. (End)