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.

A036890 Number of partitions of 5n such that cn(1,5) = cn(4,5) < cn(0,5) <= cn(2,5) = cn(3,5).

Original entry on oeis.org

0, 1, 4, 11, 27, 63, 142, 312, 665, 1382, 2795, 5524, 10674, 20228, 37634, 68886, 124179, 220779, 387458, 671883, 1152027, 1954614, 3283494, 5464437, 9013558, 14743397, 23923577, 38526121, 61593796, 97795238, 154251217, 241765892, 376643803, 583370176
Offset: 1

Views

Author

Keywords

Comments

Alternatively, number of partitions of 5n such that cn(2,5) = cn(3,5) < cn(0,5) <= cn(1,5) = cn(4,5).
For a given partition, cn(i,n) means the number of its parts equal to i modulo n.

Programs

  • Maple
    mkl:= proc(i,l) local ll, mn, x; ll:= applyop(x->x+1, irem (i,5)+1, l); mn:= min(ll[]); `if`(mn=0, ll, map(x->x-mn, ll)) end:
    g:= proc (n,i,t) if n<0 then 0 elif n=0 then `if`(t[2]=t[5] and t[3]=t[4] and t[5]t[4], 0, g(n-2*(t[4]-t[3]), 1, [t[1], t[2], t[4], t[4], t[5]])) else g(n,i,t):= g(n, i-1, t) + g(n-i, i, mkl(i,t)) fi end:
    a:= n-> g(5*n, 5*n, [0,0,0,0,0]):
    seq(a(n), n=1..15);  # Alois P. Heinz, Jul 02 2009
  • Mathematica
    mkl[i_, l_List] := Module[{ll, mn, x}, ll = MapAt[#+1&, l, Mod[i, 5]+1]; mn = Min[ll]; If[mn == 0, ll, ll-mn]]; g[n_, i_, t_List] := g[n, i, t] = Which[n<0, 0, n == 0, If[t[[2]] == t[[5]] && t[[3]] == t[[4]] && t[[5]] < t[[1]] && t[[1]] <= t[[3]], 1, 0], True, Which[i == 0, 0, i == 1, g[0, 0, {t[[1]], t[[2]]+n, t[[3]], t[[4]], t[[5]]}], i == 2, If[t[[3]] > t[[4]], 0, g[n-2*(t[[4]] - t[[3]]), 1, t[[{1, 2, 4, 4, 5}]]]], True, g[n, i, t] = g [n, i-1, t] + g[n-i, i, mkl[i, t]]]]; a[n_] := a[n] = g[5*n, 5*n, {0, 0, 0, 0, 0}]; Table[Print["a(", n, ") = ", a[n]]; a[n], {n, 1, 32}] (* Jean-François Alcover, Dec 23 2015, after Alois P. Heinz *)

Formula

a(n) = A036892(n) + A036894(n).
a(n) = A036881(n) - A036884(n).

Extensions

a(10)-a(32) from Alois P. Heinz, Jul 02 2009
a(33)-a(34) from Max Alekseyev, Dec 11 2011