(For the sake of this proposal, it is better to consider the
language non-profane.)
'Brainfuck' is an esoteric programming language based on a
minimal Turing machine: it has a data tape and a code array,
the instructions in the code modify the data in cells on the
tape. Despite the presence of only a few simple instructions
in the language it is theoretically possible to compute
everything that can be computed within the Church/Turing
model of computation; further an even more minimal
derivative of Brainfuck, 'Boolfuck', restricts the data on
the tape to consist only of single bits (either 0 or 1).
Now, consider changing the structure of the data 'tape', in
particular extending it into a 2D hyperbolic plane.
Hyperbolic geometry allows many parallel lines to a given
line through a given point not on the line, with the
consequence that the hyperbolic plane has exponentially more
space than the common flat Euclidean plane.
Now, it is possible to tile the hyperbolic plane with
congruent shapes, in many more ways than flat space can be
tiled. For example, with one particularly shaped pentagonal
tile, one can tile the hyperbolic plane in uncountably
infinitely many ways. To navigate in this new arrangement
of cells in this hyperbolic pentagonal tape, one adds three
new instructions to the language: in addition to moving the
cursor in the data tape East and West, new instructions
allow moving North, South-East and South-West.
This best visualised in the PoincarĂ© half-plane model of
hyperbolic geometry, in which shapes are distorted to give a
horizon at infinity to the South (compare with the PoincarĂ©
disk model in which there is a circular horizon at infinity,
most popularized by M C Escher's 'Circle Limit I-IV'
prints).
This 2D hyperbolic modification of 'Boolfuck' I call
'Hyperfuck', for fairly obvious reasons.
Now, the pentagonal tiling described above has a kind of
tree-like memory property: if you proceed from a starting
location and head North, you might enter the pentagon above
from either its South-East edge or its South-West edge: this
allows information to be encoded in the geometry of the
initial 'Garden Of Eden' configuration of the system. By
modifying data in the cells and moving suitably, comparing
the results of the movements with what you expect allows you
to recover the stored bitstream. Further, this information
need have no bound, for example one could encode an infinite
library of every book ever written and that ever will be
written (compare with Borges, the Shakespeare Typing
Monkeys, and the text entry software 'Dasher').
However, a suitable source of information if a programmer
is to be able to write useful programs more easily needs to
be widely known and predictable: thus I propose the ASCII
bitstream of a certain authorized version of the Christian
Bible.
This liturgical modification of Hyperfuck I call 'King James
Hyperfuck', for fairly obvious reasons.
Now that the theoretical background to the project is
explained, I can proceed to the concrete proposal: to
implement a graphical King James Hyperfuck interpreter that
will run in a web browser, using Javascript and either SVG
or Canvas (to be decided). There will be a facility to
choose from a library of simple example programs, and in
addition the visitor can write their own code to execute.
The interpreter will provide a visualisation of the
hyperbolic data tape and its mutation by the running code;
the code tape will also be displayed. The output of the
program will be displayed as it is generated.
The first example program will reconstruct the text of the
King James Bible; its source code:
+[^/+;^+]
The web installation will also present the visitor with the
theoretical background to the project, to enlighten and
inform.
Current state of the project: I have an unpublished
interpreter implemented in the C programming language
(though its algorithms need some minor tweaks to cope with
pathological bitstreams), and I have worked out the required
geometric shape of the pentagonal tiling when embedded in
the PoincarĂ© half-plane model of hyperbolic geometry. I
have prior experience of Javascript/SVG/Canvas programming
and modelling hyperbolic geometry, so I am confident I can
fully implement this proposal.
References:
http://en.wikipedia.org/wiki/Brainfuck
http://web.archive.org/web/20070403131306/http://www.rpi.edu/~hughes/boof/
http://en.wikipedia.org/wiki/Uniform_tilings_in_hyperbolic_plane
http://en.wikipedia.org/wiki/Poincar%C3%A9_half-plane_model
http://en.wikipedia.org/wiki/The_Library_of_Babel
http://en.wikipedia.org/wiki/Infinite_monkey_theorem
http://en.wikipedia.org/wiki/Dasher
http://www.gutenberg.org/etext/10