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.
%I A257990 #19 Feb 14 2020 16:31:13 %S A257990 0,1,1,1,1,1,1,1,2,1,1,1,1,1,2,1,1,2,1,1,2,1,1,1,2,1,2,1,1,2,1,1,2,1, %T A257990 2,2,1,1,2,1,1,2,1,1,2,1,1,1,2,2,2,1,1,2,2,1,2,1,1,2,1,1,2,1,2,2,1,1, %U A257990 2,2,1,2,1,1,2,1,2,2,1,1,2,1,1,2,2,1,2,1,1,2,2,1,2,1,2,1,1,2,2,2,1,2,1,1 %N A257990 The side-length of the Durfee square of the partition having Heinz number n. %C A257990 The Durfee square of a partition is the largest square that fits inside the Ferrers board of the partition. %C A257990 We define the Heinz number of a partition p = [p_1, p_2, ..., p_r] as Product(p_j-th prime, j=1...r) (concept used by _Alois P. Heinz_ in A215366 as an "encoding" of a partition). For example, for the partition [1, 1, 2, 4, 10] we get 2*2*3*7*29 = 2436. %C A257990 In the Maple program the subprogram B yields the partition with Heinz number n. %C A257990 First appearance of k is a(prime(k)^k) = k. - _Gus Wiseman_, Apr 12 2019 %D A257990 G. E. Andrews, The Theory of Partitions, Addison-Wesley, Reading, Mass. 1976. %D A257990 G. E. Andrews, K. Eriksson, Integer Partitions, Cambridge Univ. Press, 2004, Cambridge. %D A257990 M. Bona, A Walk Through Combinatorics, World Scientific Publishing Co., 2002. %H A257990 Alois P. Heinz, <a href="/A257990/b257990.txt">Table of n, a(n) for n = 1..20000</a> %H A257990 Findstat, <a href="http://www.findstat.org/StatisticsDatabase/St000183/">St000183: The side length of the Durfee square of an integer partition</a> %F A257990 For a partition (p_1 >= p_2 >= ... > = p_r) the side-length of its Durfee square is the largest i such that p_i >=i. %e A257990 a(9)=2; indeed, 9 = 3*3 is the Heinz number of the partition [2,2] and, clearly its Durfee square has side-length =2. %p A257990 with(numtheory): a := proc (p) local B, S, i: B := proc (n) local nn, j, m: nn := op(2, ifactors(n)): for j to nops(nn) do m[j] := op(j, nn) end do: [seq(seq(pi(op(1, m[i])), q = 1 .. op(2, m[i])), i = 1 .. nops(nn))] end proc: S := {}: for i to nops(B(p)) do if i <= B(p)[nops(B(p))+1-i] then S := `union`(S, {i}) else end if end do: max(S) end proc: seq(a(n), n = 2 .. 146); %p A257990 # second Maple program: %p A257990 a:= proc(n) local l, t; %p A257990 l:= sort(map(i-> numtheory[pi](i[1])$i[2], ifactors(n)[2]), `>`); %p A257990 for t from nops(l) to 1 by -1 do if l[t]>=t then break fi od; t %p A257990 end: %p A257990 seq(a(n), n=1..120); # _Alois P. Heinz_, May 10 2016 %t A257990 a[n_] := a[n] = Module[{l, t}, l = Reverse[Sort[Flatten[Table[PrimePi[ f[[1]] ], {f, FactorInteger[n]}, {f[[2]]}]]]]; For[t = Length[l], t >= 1, t--, If[l[[t]] >= t, Break[]]]; t]; Table[a[n], {n, 1, 120}] (* _Jean-François Alcover_, Feb 17 2017, after _Alois P. Heinz_ *) %Y A257990 Positions of 1's are A093641. Positions of 2's are A325164. Positions of 3's are A307386. %Y A257990 Cf. A006918, A056239, A062457, A065770, A112798, A115720, A117485, A215366, A252464, A325163, A325169. %K A257990 nonn %O A257990 1,9 %A A257990 _Emeric Deutsch_, May 18 2015 %E A257990 a(1)=0 prepended by _Alois P. Heinz_, May 10 2016