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.

Showing 1-2 of 2 results.

A363434 Total number of blocks containing only elements of the same parity in all partitions of [n].

Original entry on oeis.org

0, 1, 2, 7, 24, 97, 412, 1969, 9898, 54461, 313944, 1947613, 12603100, 86760255, 620559230, 4682462777, 36586620348, 299664171115, 2534306825064, 22355119509231, 203115201624030, 1917124624702475, 18598998656476220, 186822424157036439, 1925326063016510832
Offset: 0

Views

Author

Alois P. Heinz, Jun 01 2023

Keywords

Examples

			a(3) = 7 = 0 + 1 + 2 + 1 + 3 : 123, 12|3, 13|2, 1|23, 1|2|3.
		

Crossrefs

Programs

  • Maple
    b:= proc(n, e, o, m) option remember; `if`(n=0, e+o,
          (e+m)*b(n-1, o, e, m)+b(n-1, o, e+1, m)+
           `if`(o=0, 0, o*b(n-1, o-1, e, m+1)))
        end:
    a:= n-> b(n, 0$3):
    seq(a(n), n=0..24);
  • Mathematica
    b[n_, e_, o_, m_] := b[n, e, o, m] = If[n == 0, e + o, (e + m)*b[n-1, o, e, m] + b[n - 1, o, e + 1, m] + If[o == 0, 0, o*b[n - 1, o - 1, e, m + 1]]];
    a[n_] := b[n, 0, 0, 0];
    Table[a[n], {n, 0, 24}] (* Jean-François Alcover, Sep 10 2023, after Alois P. Heinz *)

Formula

a(n) = Sum_{k=0..n} k * A124424(n,k).
a(n) = A363452(n) + A363453(n).
a(n) mod 2 = A000035(n).

A363452 Total number of blocks containing only odd elements in all partitions of [n].

Original entry on oeis.org

0, 1, 1, 5, 12, 62, 206, 1189, 4949, 31775, 156972, 1110280, 6301550, 48637701, 310279615, 2591820857, 18293310174, 164218811718, 1267153412532, 12152174863961, 101557600812015, 1035203191874931, 9299499328238110, 100314319611860936, 962663031508255416
Offset: 0

Views

Author

Alois P. Heinz, Jun 02 2023

Keywords

Examples

			a(3) = 5 = 0 + 1 + 1 + 1 + 2 : 123, 12|3, 13|2, 1|23, 1|2|3.
		

Crossrefs

Programs

  • Maple
    b:= proc(n, k) local g, u; g:= floor(n/2); u:=ceil(n/2);
          add(Stirling2(i, k)*binomial(u, i)*
          add(Stirling2(g, j)*j^(u-i), j=0..g), i=k..u)
        end:
    a:= n-> add(b(n, k)*k, k=0..ceil(n/2)):
    seq(a(n), n=0..25);
    # second Maple program:
    b:= proc(n, x, y, m) option remember; `if`(n=0, y,
          `if`(x+m>0, b(n-1, y, x, m)*(x+m), 0)+b(n-1, y, x+1, m)+
          `if`(y>0, b(n-1, y-1, x, m+1)*y, 0))
        end:
    a:= n-> b(n, 0$3):
    seq(a(n), n=0..25);
  • Mathematica
    b[n_, x_, y_, m_] := b[n, x, y, m] = If[n == 0, y,
         If[x + m > 0, b[n-1, y, x, m]*(x+m), 0] + b[n-1, y, x+1, m] +
         If[y > 0, b[n-1, y-1, x, m+1]*y, 0]];
    a[n_] := b[n, 0, 0, 0];
    Table[a[n], {n, 0, 25}] (* Jean-François Alcover, Dec 08 2023, after Alois P. Heinz *)

Formula

a(n) = Sum_{k=0..ceiling(n/2)} k * A124420(n,k).
a(n) = A363434(n) - A363453(n).
a(2n) = A363453(2n).
a(2n+1) = A363453(2n+1) + A094577(n).
Showing 1-2 of 2 results.