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 A332105 #22 Nov 23 2020 14:26:30 %S A332105 16,144,80,96,160,208,256,304,384,432,544,608,720,816,832,1040,1168, %T A332105 1264,1360,1568,1664,1808,1984,2080,2256,2480,2704,2800,3104,3248, %U A332105 3520,3744,3968,4112,4464,4688,4880,5200,5472,5744,6016,6336,6608,6800,7248,7568,7888,8080,8528 %N A332105 a(n) is the smallest number k that can be partitioned into a set of n distinct positive even integers {e(1), e(2), ..., e(n)} where the sum of e(i)*(e(i)-1) for i = 1 to n equals k*(k-1)/2. %C A332105 These numbers solve the problem of what is the required minimum even number of socks of n colors such that a random drawing of two socks has a 50% chance of matching. %e A332105 For n = 3, {6, 48, 90} is the set of even numbers with the smallest sum that has this property. With 6 socks of one color, 48 socks of another color, and 90 socks of a third color, there is exactly a 50% chance that a random draw of two socks will produce a matching pair. (6*5 + 48*47 + 90*89) = (144*143) / 2. %e A332105 n = 2, sum = 16, set = {6, 10} %e A332105 n = 3, sum = 144, set = {6, 48, 90} %e A332105 n = 4, sum = 80, set = {2, 8, 16, 54} %e A332105 n = 5, sum = 96, set = {2, 6, 8, 14, 66} %e A332105 n = 6, sum = 160, set = {2, 6, 8, 10, 24, 110} %o A332105 (PARI) \\ See Links in A246750 for a faster program. %o A332105 a(n)={for(k=n*(n+1)/2, oo, my(t=k*(4*k-1)); forpart(p=2*k-n*(n-1)/2, if(sum(i=1, n, (p[i]+i-1)*(2*(p[i]+i-1)-1))==t, return(4*k)), ,[n,n]))} \\ _Andrew Howroyd_, Nov 21 2020 %Y A332105 Cf. A246750. %K A332105 nonn %O A332105 2,1 %A A332105 _Dean D. Ballard_, Nov 20 2020 %E A332105 a(16)-a(50) from _Andrew Howroyd_, Nov 22 2020