How to graph Tupper’s self-referential formula
This page looks into how to graph or plot the formula and if you just landed on this page then this article is a continuation of a multi-page article. In the previous sections, I have already shown in detail how to derive the decoding block from first principles.
Mr Tupper describes in his paper that the grid is a 1696 × 272 "pixmap" over [0, 106] × [k, k + 1 7], which is based on his earlier definition of the following Cartesian plane.
[L, R] × [B, T.
However, it all made sense when I read the following.
"The graphing area is partitioned into a regular grid of rectangles, pixel (x, y) corresponds to the region [L + x(R − L)W−1, L + (x + 1 )(R − L)W−1] × [B + y(T − B)H−1,B + (y + 1 )(T − B)H−1], where pixel (0, 0) is the bottom-left pixel and pixel (W −1, H − 1) is the top-right pixel."
So, if (0, 0) is the bottom-left corner pixel then many people would start the plot from this point and move up the column one pixel at a time to the 17th pixel. However, there is no reason why you cannot start from (W −1, H − 1). In fact, this was the whole point of the paper to break away from the convention of always starting plots from (0, 0).
Ever "just", know something?
I decided to follow the mundane Cartesian convention of starting the plot from the bottom-left (0, 0), and scanning the raster in columns and ending on the top-right corner pixel, knowing fully well that the image would be upside down and mirror reversed. I figured that since the universe was deterministic, why do things any other way and risk a causality paradox. As Einstein once said that a paradox cannot physically exist within a universe, and if it did, then the Universe would have to disappear.
I read the paper again in case I missed something, and I concluded that Mr Tupper must have made a mistake since the universe still exists, but the paper does not specifically mention where to start the plot from either...
Is this a big deal? I do not think so; he probably encoded the image the wrong way round without realising, and did not have time to recheck by pushing it through the decoder again. It is always a rush when you want to get a paper published. Hey, happens to the best of us sometimes!
Tupper’s constant K
These are the numbers for the constant K from Mr Tupper's published paper. At a glance there seems to be 181 in groups of three digits. I wonder why he arranged them in this way. Digits as long as these are usually manipulated as strings, so he might have had a special processing function that ignored the spaces as it parsed the string. Obviously if you plan to use these numbers then you should remove the spaces.
"k = 960 939 379 918 958 884 971 672 962 127 852 754 715 004 339 660 129 306 651 505 519 271 702 802 395 266 424 689 642 842 174 350 718 121 267 153 782 770 623 355 993 237 280 874 144 307 891 325 963 941 337 723 487 857 735 749 823 926 629 715 517 173 716 995 165 232 890 538 221 612 403 238 855 866 184 013 235 585 136 048 828 693 337 902 491 454 229 288 667 081 096 184 496 091 705 183 454 067 827 731 551 705 405 381 627 380 967 602 565 625 016 981 482 083 418 783 163 849 115 590 225 610 003 652 351 370 343 874 461 848 378 737 238 198 224 849 863 465 033 159 410 054 974 700 593 138 339 226 497 249 461 751 545 728 366 702 369 745 461 014 655 997 933 798 537 483 143 786 841 806 593 422 227 898 388 722 980 000 748 404 719"Why plot Tupper’s formula using JavaScript?
I just wanted to see if it was possible to use it for something like this. Initially my thoughts were that JavaScript could never plot Tupper’s formula. It is impossible, because JavaScript handles all variables as floating point, and it most certainly cannot handle digits as large as Tupper’s constant k. Therefore, I thought that this was a good challenge. Also because it would be nice if my visitors could see the plot on their browsers and there was nothing like this on the Internet.
I also wanted to keep this article in the same spirit as the published paper of making available better and affordable software for students. JavaScript is a good choice because, 1. It is widely available all over the world. If your computer has a browser then you already have the tools! All you need is a text editor to write the code and a browser to run it in. 2. JavaScript is very much like C, which is familiar to many university students.
Large Integer Support for JavaScript
JavaScript has a very "nice" native math library that supports floor and mod functions, however it cannot handle large integers and will give up when presented with Tupper’s constant. It will treat the number as infinity. It is OK for basic math operations but not ideally suited for large numbers.
The architect in the Matrix would have said, "The first algorithm I designed was quite naturally perfect; it was a work of art, flawless, sublime. A triumph equaled only by its monumental failure. The inevitability of its doom is apparent to me now as a consequence of the imperfection inherent in every browser..."
This limitation of JavaScript obviously poses a problem, however I managed to find a library of math functions that can handle large integers, and could be used with JavaScript. The math library consists of two files called biginteger.js and schemeNumber.js, which are loaded in that sequence. Hence, it saved some time having to rewrite the math functions. The sites matthewcrumley.com and john-edwin-tobey.org, manage these files and I would highly recommend you support their projects.
This Article Continues...
Tupper’s Self-Referential Formula ExplainedSimplification of Tupper’s Formula for Graphing
How to graph Tupper’s self-referential formula
Graphing Raster Used for Tupper’s Formula
Plot Tupper’s Self-Referential Formula
How to Convert Binary (Base 2) to Decimal (Base 10)
Self-Referential Formula Plot 1
Self-Referential Formula Plot 2