12 Comments
Jul 21, 2023Liked by Zach Wissner-Gross

I will admit to being a little bit frustrated that my solutions for N > 2 were overlooked somehow. I will roughly rewrite what I submitted, and, of course, remove embarrassing errors and false paths that I submitted privately. I worked collaboratively with another user named SeerSkye, and much of this work was found by him while I was still messing around with slow computer code.

N=3 => 13 * 12 * (11 + 4) * (1/(10 + 5))/(6 + 9)/(8 - (2 - 3 - 7)) = 8,424,000

N=4 => 17 * 16 * 15 * (11 + 9) * (12 + 8)/((1/(13+7) /(14+6)/(10 - (2 - 5 - 4 - 3)) = 13,056,000,000

N=5 => 21 * 20 * 19 * 18 * (17 + 7) * (16 + 9) / ((1 / (15 + 10))/(14 + 11)/(13 + 12)/(8 - (2 - 6 - 5 - 4 - 3)) = 32,319,000,000,000

The general strategy is to recognize that all /s can become *s after the first one, and all -s can become +s after the first one. If we sacrifice the 1 to the /, and the 2 to the -, we can then try to even out all of the products as much as possible. In general, it seems like the best that we can do is:

product(3N+3..4N+1) * ceil(S/(N+1))^(S mod N+1) * floor(S/(N+1))^(N+1-S mod N+1)

where S = sum(3..3N+2) - 2

Which is an upper bound, actually satisfying this upper bound is probably impossible for all N.

However, we have a little bit of tug of war going on here, because the more digits we use in a single expression the worse the expression gets, and this assumes we use all of the minuses in a single term. If instead we allow ourselves to consider also sacrificing the 3, 4, 5, and so on for larger and larger N, we can begin to do better. The first N where this becomes absolutely desirable to do is N=21. So we have to create larger upper bounds.

N=21 (sacrifice 2 only) => 1858561114113223590154513972642442186649575491096420050912878442728057261260800000

N=21 (sacrifice both 2 and 3) => 1861170011681117541222317931520613643629245091916594782109445096734720000000000000

This more general expression is:

```

def poc(upper, lower):

return prod(range(lower, upper+1))

def sac(n, j):

s = sum(range(j+1, 3*n + j+1)) - sum(range(2, j+1))

return poc(4*n + 1, 3*n + j+1) * ceil(s/(n + j - 1))**(s % (n + j - 1)) * floor(s / (n + j - 1))**((n + j - 1) - (s % (n + j - 1)))

```

Where `sac(21, 2)` considers just the 2 case, `sac(21, 3)` also considers the 3 case. Our upper bound then is the maximum over j = 2..n of `sac(n, j)`

Unfortunately, actually finding explicit expressions for N=21 that correspond to this upper bound is not something I was able to do by hand, and I was unable to write a computer program to do so by the time submissions closed.

Expand full comment
author
Jul 21, 2023·edited Jul 21, 2023Author

Nice! Glad you were able to include your findings here.

I missed these results because they were in "Show Your Work" rather than in "Your Answer" on the Google Form. Granted, it's a little ambiguous where to put things when I pose more than one question.

Expand full comment
Jul 21, 2023Liked by Zach Wissner-Gross

My bad then, I'll keep that in mind :)

Expand full comment
Jul 21, 2023Liked by Zach Wissner-Gross

That's the path I was taking as well, Michael. (I think I made the same Google Form mistake you did.) I tried to generalize for N, and ended up with (4N+1)! / (3N+2)! * (4N+4)^N * (0.5N^2 + 4.5N - 6). For N = 5, that yields 33,168,788,029,440.

Expand full comment
Jul 21, 2023Liked by Zach Wissner-Gross

I think there might be an error lurking in there. I'll play around with it.

Expand full comment

I guess it was too much to hope that someone had devised a general algorithm for finding the best combo of operations for any n

Expand full comment
Jul 21, 2023Liked by Zach Wissner-Gross

I tried, below, but I'm open to learning why I was wrong!

Expand full comment

A general solution seems highly unlikely. Numbers are, sadly, not well-behaved like that.

Expand full comment
Aug 7, 2023Liked by Zach Wissner-Gross

If you miss Digits, you will enjoy Krypto. It is a card-based game that has a similar concept: https://en.wikipedia.org/wiki/Krypto_(game)

Expand full comment

The general solution, the approximation, and the example that I submitted are written below.

Most of these were submitted to also "Show Your Work" and I do not think they could have been submitted to "Your Answer" due to format and length.

-- Summary of my submission

[1], [2], and so on represent the numbers used.

For large N, consider the following expression.

([N+2]−([2]−[?]−[?]−...−[?]))

×([N+3]−([3]−[?]−[?]−...−[?]))

×...

×([N+k+1]−([k+1]−[?]−[?]−...−[?]))

×([N+k+2]+[3N+k+1])

×([N+k+3]+[3N+k])

×...

×([2N+2]+[2N+2k+1])

÷(

[1]

÷([2N+3]+[2N+2k])

÷([2N+4]+[2N+2k-1])

÷...

÷([2N+k+1]+[2N+k+2])

÷[3N+k+2]

÷[3N+k+3]

÷...

÷[4N+1]

),

where,

• ([N+2]−([2]−[?]−[?]−...−[?])), ..., ([N+k+1]−([k+1]−[?]−[?]−...−[?])) are equal to floor(N + ((N - k) (N + k + 3))/(2 k)) or floor(N + ((N - k) (N + k + 3))/(2 k)) + 1, and

• k is such that the value is maximized, which is approximately 0.143453 N.

(0.143453 is a solution to the equation:

2 e^((-((α + 3) α^2) + α - 1)/(α^3 - 5 α - 2)) (α + 3) + α = 1/α + 2.

)

The value of the expression is approximately,

(8 N^(2 N) (exp((3 (α + 1))/((α - 2) α - 1) + 3/(2 (α + 2)) + 3) (2^(9 - α) e^(α - 1) (-α + 1/α + 2)^α (α + 2) (α + 3)^(-α - 3))^N))/(α + 3)^(3/2)

≈ 3.86654×15.7512^N N^(2 N).

For example, N = 100, then k = 14, and the expression is

([102]−([2]−[57]−[59]−[70]−[76]−[98]))

×([103]−([3]−[25]−[36]−[53]−[71]−[79]−[96]))

×([104]−([4]−[28]−[32]−[42]−[48]−[55]−[64]−[91]))

×([105]−([5]−[47]−[69]−[78]−[82]−[84]))

×([106]−([6]−[29]−[31]−[39]−[44]−[50]−[67]−[100]))

×([107]−([7]−[49]−[61]−[72]−[87]−[90]))

×([108]−([8]−[19]−[27]−[56]−[66]−[94]−[97]))

×([109]−([9]−[22]−[74]−[80]−[88]−[95]))

×([110]−([10]−[26]−[35]−[46]−[68]−[85]−[99]))

×([111]−([11]−[33]−[40]−[41]−[75]−[77]−[93]))

×([112]−([12]−[16]−[30]−[62]−[73]−[86]−[92]))

×([113]−([13]−[43]−[63]−[81]−[83]−[89]))

×([114]−([14]−[20]−[21]−[23]−[24]−[34]−[37]−[38]−[45]−[52]−[65]))

×([115]−([15]−[17]−[18]−[51]−[54]−[58]−[60]−[101]))

×([116]+[315])

×([117]+[314])

×...

×([202]+[229])

÷(

[1]

÷([203]+[228])

÷([204]+[227])

÷...

÷([215]+[216])

÷[316]

÷[317]

÷...

÷[401]

)

≈ 2.060469293246929×10^520

Expand full comment

Amazing work. Good to see that I was on the right track. How did you arrive at the maximizing equation for alpha: 2 e^((-((α + 3) α^2) + α - 1)/(α^3 - 5 α - 2)) (α + 3) + α = 1/α + 2 ?

Expand full comment

Thanks for the comment.

I am glad to read your praise.

I got there using Mathematica.

The outline is at

https://i.imgur.com/bP0ES1g.png

Expand full comment