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.

A364808 a(n) = sum of minimal runlengths of all the partitions of n.

Original entry on oeis.org

1, 3, 5, 9, 11, 20, 22, 36, 44, 63, 74, 114, 128, 180, 224, 298, 355, 485, 573, 760, 922, 1174, 1419, 1836, 2189, 2756, 3341, 4160, 4988, 6217, 7412, 9131, 10941, 13326, 15916, 19379, 22988, 27770, 33017, 39662, 46919, 56223, 66308, 79047, 93187, 110512
Offset: 1

Views

Author

Clark Kimberling, Sep 10 2023

Keywords

Examples

			The partitions of 4 are [4], [3,1], [2,2], [2,1,1], [1,1,1,1], with runlengths {1}, {1,1}, {2}, {1,2}, {4} having minima 1, 1, 2, 1, 4, with sum 9, so that a(4) = 9.
		

Crossrefs

Cf. A000041, A264397 (sum of maximal runlengths).

Programs

  • Maple
    b:= proc(n, i, m) option remember; `if`(n=0, m, `if`(i=1, min(m, n),
          add(b(n-i*j, i-1, `if`(j=0, m, min(m, j))), j=0..n/i)))
        end:
    a:= n-> b(n$3):
    seq(a(n), n=1..50);  # Alois P. Heinz, Sep 17 2023
  • Mathematica
    m[n_] := m[n] = Map[Split, IntegerPartitions[n]]
    t[n_] := t[n] = Table[Map[Length, m[n][[k]]], {k, 1, PartitionsP[n]}]
    Table[Total[Map[Min, t[n]]], {n, 1, 47}]
  • Python
    from sympy.utilities.iterables import partitions
    def A364808(n): return sum(min(p.values()) for p in partitions(n)) # Chai Wah Wu, Sep 17 2023