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.

A309859 Irregular table read by rows where row(n) partitions n into distinct integers with maximal product.

This page as a plain text file.
%I A309859 #31 Dec 23 2024 14:53:45
%S A309859 1,2,3,4,3,2,4,2,4,3,5,3,4,3,2,5,3,2,5,4,2,5,4,3,6,4,3,5,4,3,2,6,4,3,
%T A309859 2,6,5,3,2,6,5,4,2,6,5,4,3,7,5,4,3,6,5,4,3,2,7,5,4,3,2,7,6,4,3,2,7,6,
%U A309859 5,3,2,7,6,5,4,2,7,6,5,4,3,8,6,5,4,3,7,6,5,4,3,2,8,6,5,4,3,2,8,7,5,4,3,2,8,7,6,4,3,2
%N A309859 Irregular table read by rows where row(n) partitions n into distinct integers with maximal product.
%C A309859 All of the inequalities in the proof [of the maximum formula by Doslic] are strict inequalities (> instead of >=). So the partition which is found to be optimal is not just >= any other, it is >. And hence it is unique. - _Franklin T. Adams-Watters_ [Copied from the SeqFan discussion by J.-F. Alcover, Sep 19 2019]
%H A309859 Jean-François Alcover, <a href="/A309859/b309859.txt">Table of n, a(n) for n = 1..27908</a>
%H A309859 Tomislav Doslic, <a href="https://cs.uwaterloo.ca/journals/JIS/VOL8/Doslic/doslic15.html">Maximum product over partitions into distinct parts</a>, J. of Integer Sequences, Vol. 8 (2005), Article 05.5.8.
%H A309859 SeqFan, <a href="https://web.archive.org/web/*/http://list.seqfan.eu/oldermail/seqfan/2019-September/018905.html">Is a partition with distinct parts and maximum product unique ?, Discussion on SeqFan-mailing list</a>, September 2019.
%e A309859 The partitions of 10 into distinct addenda are {{10}, {9, 1}, {8, 2}, {7, 3}, {7, 2, 1}, {6, 4}, {6, 3, 1}, {5, 4, 1}, {5, 3, 2}, {4, 3, 2, 1}}, then the maximal product is attained with 5*3*2 = 30, so row(10) is {5, 3, 2}.
%e A309859 Table begins:
%e A309859 1
%e A309859 2
%e A309859 3
%e A309859 4
%e A309859 3, 2
%e A309859 4, 2
%e A309859 4, 3
%e A309859 5, 3
%e A309859 4, 3, 2
%e A309859 5, 3, 2
%e A309859 ...
%t A309859 $RecursionLimit = 2000;
%t A309859 b[n_, i_] := b[n, i] = If[i (i + 1)/2 < n, 0, If[n == 0, 1, Max[b[n, i - 1], i b[n - i, Min[n - i, i - 1]]]]];
%t A309859 A034893[n_] := b[n, n];
%t A309859 sol[n_, pro_] := Do[If[pro == Product[i, {i, j, m}]/k && n == (m - j + 1)*(j + m)/2 - k , Return[ {j, k, m}]], {j, 2, 3}, {m, Floor[Sqrt[2 n]], Ceiling[Sqrt[2 n]] + 1}, {k, j + 1, m}];
%t A309859 row[1] = {1}; row[4] = {4}; row[n_] := Module[{j, k, m}, {j, k, m} = sol[n, A034893[n]]; DeleteCases[Range[j, m], k] // Reverse];
%t A309859 Array[row, 100] // Flatten (* _Jean-François Alcover_, Sep 14 2019, after _Alois P. Heinz_ in A034893 *)
%Y A309859 Cf. A034893 (row products).
%K A309859 nonn,tabf
%O A309859 1,2
%A A309859 _Jean-François Alcover_, Aug 20 2019
%E A309859 b-file extended to 1000 rows by _Jean-François Alcover_, Sep 14 2019