A366461 a(n) = number of partitions of n that have the maximum number of neighbors; see Comments.
1, 2, 1, 2, 1, 1, 2, 1, 6, 1, 2, 1, 6, 2, 1, 2, 1, 6, 2, 8, 1, 2, 1, 6, 2, 8, 1, 1, 2, 1, 6, 2, 8, 1, 6, 1, 2, 1, 6, 2, 8, 1, 6, 22, 1, 2, 1, 6, 2, 8, 1, 6, 22, 2, 1, 2, 1, 6, 2, 8, 1, 6, 22, 2, 8, 1, 2, 1, 6, 2, 8, 1, 6, 22, 2, 8, 30, 1, 2, 1, 6, 2, 8, 1, 6, 22
Offset: 1
Keywords
Examples
Refer to the Example in A366429 to see that a(5) = 1.
Programs
-
Mathematica
c[n_] := PartitionsP[n]; q[n_, k_] := q[n, k] = IntegerPartitions[n][[k]]; r[n_, k_] := r[n, k] = Join[q[n, k], ConstantArray[0, n - Length[q[n, k]]]]; d[u_, v_] := d[u, v] = Total[Abs[u - v]]; s[n_, k_] := s[n, k] = Select[Range[c[n]], d[r[n, k], r[n, #]] == 2 &] t[n_] := t[n] = Table[s[n, k], {k, 1, c[n]}] a[n_] := Max[Map[Length, t[n]]] b[n_] := b[n] = Select[t[n], Length[#] == a[n] &] e[n_] := Length[b[n]] Table[e[n], {n, 1, 24}]
Extensions
More terms from Pontus von Brömssen, Oct 24 2023
Comments