Today, we'll be computing the most efficient binary function. More specifically, we'll be computing the function which, when an equationexpression is created from applying the function to the constant input 0 or its own output, can represent all positive integers with the shortest possible expressions, placing higher priority on the smaller integers.
For each integer, starting at 1 and going upwards, choose the shortest expression which we have not yet assigned an output to, and make that integer the output of that equationexpression. Ties in equationexpression length will be broken by smaller left argument, and then by smaller right argument. Here's how it works:
Initially, 1 is unassigned. The shortest unassigned equationexpression is
f(0, 0)
, so we'll set that to 1.Now, 2 is unassigned. The shortest unassigned equationsexpressions are
f(f(0, 0), 0)
=f(1, 0)
andf(0, f(0, 0))
=f(0, 1)
. Ties are broken towards smaller left argument, sof(0, 1) = 2
.The shortest unassigned expression remaining is
f(f(0, 0), 0)
=f(1, 0)
, sof(1, 0) = 3
.Now, we're out of expressions with only 2
f
s and 30
s, so we'll have to add one more of each. Breaking ties by left argument, then right argument, we getf(0, 2) = 4
, sincef(0, f(0, f(0, 0))) = f(0, f(0, 1)) = f(0, 2)
.Continuing, we have
f(0, 3) = 5
,f(1, 1) = 6
,f(2, 0) = 7
,f(3, 0) = 8
,f(0, 4) = 9
, ...