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 A352813 #28 Jun 18 2022 17:59:40 %S A352813 0,1,2,6,18,30,576,840,24480,93696,800640,7983360,65318400,2286926400, %T A352813 13680979200,797369149440,16753029012720,10176199188480, %U A352813 159943859712000,26453863460044800,470500040794291200,20720967220237197312,61690805562507264000 %N A352813 Minimum difference |product(A) - product(B)| where A and B are a partition of {1,2,3,...,2*n} and |A| = |B| = n. %C A352813 a(n) >= A038667(2*n). %C A352813 Conjecture: a(n) = A038667(2*n) for all n. It is verified for n<=70. - _Max Alekseyev_, Jun 18 2022 %C A352813 Bernardo Recamán Santos proposes that this should be called Luciana's sequence for the student whose question prompted its investigation. (See MathOverflow link below.) %H A352813 Max Alekseyev, <a href="/A352813/b352813.txt">Table of n, a(n) for n = 0..70</a> %H A352813 Gordon Hamilton, <a href="https://mathpickle.com/project/thirsty-fractions/">Thirsty Fractions</a>, MathPickle, 2013, for elementary and middle school teachers. %H A352813 MathOverflow discussion <a href="https://mathoverflow.net/q/419319">Splitting the integers from 1 to 2n into two sets with products as close as possible</a>. %e A352813 For n = 4, the partition A = {1,5,6,7} and B = {2,3,4,8} is optimal, giving difference 1*5*6*7 - 2*3*4*8 = 18. %e A352813 _Rob Pratt_ computed the optimal solutions for n <= 10: %e A352813 [ n] a(n) partitions of 2n %e A352813 ------------------------------------------------------------------ %e A352813 [ 1] 1 2 | 1 %e A352813 [ 2] 2 2,3 | 1,4 %e A352813 [ 3] 6 1,5,6 | 2,3,4 %e A352813 [ 4] 18 1,5,6,7 | 2,3,4,8 %e A352813 [ 5] 30 2,3,4,8,10 | 1,5,6,7,9 %e A352813 [ 6] 576 1,4,7,8,9,11 | 2,3,5,6,10,12 %e A352813 [ 7] 840 2,4,5,6,8,11,14 | 1,3,7,9,10,12,13 %e A352813 [ 8] 24480 1,5,6,7,8,13,14,15 | 2,3,4,9,10,11,12,16 %e A352813 [ 9] 93696 2,3,6,8,9,11,12,13,18 | 1,4,5,7,10,14,15,16,17 %e A352813 [10] 800640 2,3,4,8,9,11,12,18,19,20 | 1,5,6,7,10,13,14,15,16,17 %o A352813 (Sage) %o A352813 def A352813(n): %o A352813 return min(abs(prod(A)-prod(B)) for (A,B) in SetPartitions((1..2*n), [n,n])) %o A352813 [A352813(n) for n in (1..10)] # _Freddy Barrera_, Apr 05 2022 %o A352813 (Python) %o A352813 from math import prod, factorial %o A352813 from itertools import combinations %o A352813 def A352813(n): %o A352813 m = factorial(2*n) %o A352813 return 0 if n == 0 else min(abs((p:=prod(d))-m//p) for d in combinations(range(2,2*n+1),n-1)) # _Chai Wah Wu_, Apr 06 2022 %Y A352813 Cf. A061057, A038667. %K A352813 nonn %O A352813 0,3 %A A352813 _Peter J. Taylor_, Apr 04 2022