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.

A171634 Number of compositions of n such that the number of parts is divisible by the greatest part.

Original entry on oeis.org

1, 1, 3, 2, 8, 13, 21, 38, 89, 173, 302, 545, 1109, 2309, 4564, 8601, 16188, 31365, 62518, 125813, 251119, 493123, 956437, 1854281, 3633938, 7218166, 14444539, 28868203, 57300450, 112921744, 221760513, 436117749, 861764899, 1711773936
Offset: 1

Views

Author

Vladeta Jovovic, Dec 13 2009

Keywords

Crossrefs

Programs

  • Maple
    b:= proc(n,t,g) option remember; `if`(n=0, `if`(irem(t, g)=0, 1, 0), add(b(n-i, t+1, max(i, g)), i=1..n)) end: a:= n-> b(n,0,0): seq(a(n), n=1..40); # Alois P. Heinz, Dec 15 2009
  • Mathematica
    b[n_, t_, g_] := b[n, t, g] = If[n == 0, If [Mod[t, g] == 0, 1, 0], Sum[b[n - i, t + 1, Max[i, g]], {i, 1, n}]];
    a[n_] := b[n, 0, 0];
    Array[a, 40] (* Jean-François Alcover, Nov 11 2020, after Alois P. Heinz *)

Formula

G.f.: Sum_{n>=0} Sum_{d|n} ((x^(d+1)-x)^n-(x^d-x)^n)/(x-1)^n.

Extensions

More terms from Alois P. Heinz, Dec 15 2009