Expansion

Expansion refers to the function \(a \{\{1\}\} b = a \{a \{\cdots \{a\} \cdots\}a\}a\), where there are b a 's from the center out. It is {a,b,1,2} in BEAF. The notation a{c}b means {a,b,c}, which is a "c + 2"-ated to c.

It grows faster than any hyper-operator, such as tetration or pentation. In the fast-growing hierarchy, \(f_{\omega+1}(n)\) corresponds to expandal growth rate.

Graham's number is defined using a very close variant of expansion. It is \(3 \{\{1\}\} 65\) with the central 3 replaced with a 4.

Examples
\(2\ \{\{1\}\}\ 2\) = 4 \(2\ \{\{1\}\}\ 3\) = 2{2{2}2}2 = 2{4}2 = 2{3}2 = 2{2}2 = 2{1}2 = 4, in fact if the base is equal to 2 and prime is ≥ 2, then the result will always be 4.

\(3\ \{\{1\}\}\ 2 = \{3,2,1,2\} = 3 \{3\} 3 = 3\uparrow\uparrow\uparrow 3\) (tritri)

\(a\ \{\{1\}\}\ 2 = \{a,2,1,2\} = \{a,a,a\} = a\underbrace{\uparrow\uparrow\cdots\uparrow\uparrow}_{a}a\)

\(3\ \{\{1\}\}\ 3 = \{3,3,1,2\} = 3 \{3 \{3\} 3\} 3 = 3\{\text{tritri}\}3 = 3\underbrace{\uparrow\uparrow\cdots\uparrow\uparrow}_{\text{tritri}}3\)

\(4\ \{\{1\}\}\ 3 = \{4,3,1,2\} = 4 \{4 \{4 \} 4 \}4 = 4 \{\)\(\} 4 = 4\underbrace{\uparrow\uparrow\cdots\uparrow\uparrow}_{\text{tritet}}4\)

\(3\ \{\{1\}\}\ 4 = \{3,4,1,2\} = 3 \{3 \{3 \{3\} 3\} 3 \}3 = 3 \{3 \{tritri\} 3\} 3 = 3\{\ \{3,3,1,2\}\ \}3 = 3\underbrace{\uparrow\uparrow\cdots\uparrow\uparrow}_{\{3,3,1,2\} }3\) = 3{3{3{3}3}3}3 = 3^^^^^^^^^^^^^...........3^^^^^^^^^^^^^ ...........3^^^3 ^'s...........^^^^^^^^^^^^^3 ^'s........... ^^^^^^^^^^^^^3

\(10 \{\{1 \}\} 100 = \{10,100,1,2\} = \{10,10,\{10,99,1,2 \}\} = 10 \underbrace{\uparrow\uparrow\cdots\uparrow\uparrow}_{\{10,99,1,2 \} }10\) (corporal)

\(a \{\{1 \}\} b = \{a,b,1,2\} = \{a,a,\{a,b-1,1,2 \}\} = a \underbrace{\uparrow\uparrow\cdots\uparrow\uparrow}_{\{a,b-1,1,2\} }a\)

Steps
How to use expansion:


 * 1) Take a = 8 and b = 5, so is {8,5,1,2}.
 * 2) 8 { 8 { 8 { 8 { 8 }8}8}8}8, w/5 8's (including the center 8.)
 * 3) To reduce one of the center out, do 8{8}8 (8 decated to 8) first.
 * 4) Now it becomes 8{8{8{8↑88}8}8}8, lets take the 8{r}8 as results, (result 1).
 * 5) 8{8{8{result 1}8}8}8, now we have done one center out 8.
 * 6) Now, do 8 (result 1)+2-ated to 8 = result 2
 * 7) Then we get 8{8{result 2}8}8.
 * 8) Repeat 8{'result'}8 till all the center out are no more {}'s = result 4, in {8,5,1,2}.

Note: Result r is 8 (result r-1)+2-ated to 8. (in this example, 'a' is 8.)

Pseudocode
Below is an example of pseudocode for expansion.

function expansion(a, b): result := a repeat b - 1 times: result := hyper(a, a, result + 2) return result function hyper(a, b, n): if n = 1: return a + b result := a repeat b - 1 times: result := hyper(a, result, n - 1) return result