Bigfun

From Esolang
Jump to navigation Jump to search

Bigfun is a total esolang created by User:Pro465 in 2024 to represent fast-growing functions and large numbers. It is based on minsky machines and the fast growing hierarchy.

Description

Since this esolang relies heavily on functions, the following part contains some maths, so beware.

Let be the set of all possible register states with being the number of registers required, then a Bigfun program is just a function

Let and , then is defined as the th entry of (0-based).

There is only one type of primitive function, represented by +n where and , which just takes the register state and returns it but with incremented by 1.

There are two operations on functions:

1. concatenation is composition - Let there be two programs p and q with corresponding functions
Then the function representing p q is given by .
2. the bigify operator - Let there be a program p with corresponding function
then the function corresponding to (m|n|p) where and is
where defines a new family of functions, ,
such that:
1.
2. , where is the th iterate of .
and diagonalizes over it:

Execution

The function corresponding to the whole program is evaluated with its argument being a -tuple with every element being 0, and the resulting state is outputted and the program halted.

Examples

just some random large number

  +0+0+0(0|0|+0)

exits with in register 0.

a number much greater than Graham's number

+0+0+0+0
+1+1+1+1
(1|1|+0(0|0|+0+0))

exits with a number much greater than graham's number on register 0. In fact, it's much larger than

Explanation

Let be defined by:

(We'll use instead of for Graham's numbers to avoid conflict with our function.)

Then,

And more generally,

where is Knuth's up-arrow notation.

And thus, for any

so the corresponding program,

   +0(0|0|+0+0)

implements a function that always results in a number that's at least given an input

now we just need to repeat this 256 times, which is what +1+1+1+1(1|1|p) does for any program p, provided that register 1 doesn't get incremented in p.

So our almost finished code is:

   +1+1+1+1(1|1|+0(0|0|+0+0))

we need to initialize register 0 with 4 though, because the first number () is supposed to be and we are currently starting off with So we add a +0+0+0+0 to the beginning of the program:

   +0+0+0+0+1+1+1+1(1|1|+0(0|0|+0+0))

and that's it!