Showing posts with label tetration. Show all posts
Showing posts with label tetration. Show all posts

Thursday, 23 April 2026

Power Towers

The number associated with my diurnal age today, \( \textbf{28144}\), has the property that its power tower of digits is equal to its product of digits. That is to say:

2 ^ 8 ^ 1 ^ 4 ^ 4 = 2 x 8 x 1 x 4 x 4 = 36

Such numbers are relatively rare. In the range beyond 28144 up to 40000, there are only the following numbers that satisfy: 28182, 31111, 33113 and 33131.

Meanwhile, I thought it was time to clarify the reasons behind the right associativity of power towers and so I consulated Gemini. Here was the response:

Let's break down the mechanics of power towers, tetration, and the crucial role of associativity in how we evaluate these operations.

Associativity: The Order of Operations

In mathematics, associativity dictates how we group numbers when an expression contains multiple instances of the same operator.

  • Left-Associative: Operations are evaluated from left to right. Subtraction and division are left-associative by convention.
    For example, 10 − 5 − 2 is evaluated as (10 − 5) − 2 = 3.
  • Right-Associative: Operations are evaluated from right to left.

Exponentiation is mathematically defined as right-associative. When you see a sequence of exponents, you evaluate them from the top down.

Here is why this convention exists: if exponentiation were left-associative, it would be mathematically redundant. Let's look at 232.

  • If it were left-associative: (23)2 = 82 = 64.
    By the rules of exponents, (ab)c = ab × c. Therefore, a left-associative power tower is just a disguised way of multiplying exponents together (23 × 2 = 26 = 64). We already have multiplication, so we don't need a new convention for this.
  • Because it is right-associative: 2(32) = 29 = 512.
    Evaluating from the top-down creates a fundamentally new, uniquely powerful operation that cannot be simplified by basic multiplication.

Power Towers

A power tower is simply a visual stack of exponents, written as abcd.

Because of the right-associative rule, you always start at the highest point of the tower and work your way down to the base.

For example, to evaluate 2322:

  1. Start at the top: 22 = 4
  2. Move down one level: 34 = 81
  3. Calculate the final base: 281

The result is 2,417,851,639,229,258,349,412,352.

Tetration: Iterated Exponentiation

Tetration is a specific type of power tower where the base number is identical throughout the entire stack.

Just as multiplication is repeated addition, and exponentiation is repeated multiplication, tetration is repeated exponentiation. It is the fourth fundamental hyperoperation in mathematics (following addition, multiplication, and exponentiation).

Because standard exponentiation notation becomes visually cumbersome when stacked high, mathematicians use specific notations for tetration:

  • Knuth's Up-Arrow Notation: a ↑↑ n
  • Rudy Rucker's Superscript Prefix: na

In both notations, a is the base and n is the height of the tower.

Examples of Tetration:

  • 23 (or 3 ↑↑ 2) = 33 = 27
  • 33 (or 3 ↑↑ 3) = 333 = 327 = 7,625,597,484,987

The Computational Horizon

Tetration generates exponential growth at a scale that rapidly breaks the limits of standard computation.

If we take just one more step up the tower to 43 (or 3 ↑↑ 4), the expression becomes 3333, which evaluates to 37,625,597,484,987.

This number has over 3.6 trillion decimal digits. While theoretical mathematics can easily define and manipulate the expression 43, calculating the exact integer quickly leaves the realm of standard datatypes. Numbers at this scale become highly unrenderable in their full decimal form; storing just the digits of 43 as a standard text file would require terabytes of disk space. When computational number theory investigates numbers at or beyond this threshold, it relies on custom algorithms, modulo arithmetic, or symbolic representation frameworks to analyze the properties of the digits without attempting to hold the entire integer in memory.

Saturday, 8 January 2022

Mathematical Quiz: 1

This post is just a first attempt at creating a mathematical quiz. I'm still thinking about the best way to present such a quiz from the wide variety of online resources available. The target audience is an important consideration. The first seven questions of this particular quiz is accessible to those you have completed a course in high school mathematics. The last three questions however, would not be but would serve to stimulate interest and get them to follow the suggested links. This whole quiz concept is a work in progress so I'll keep experimenting with quiz content and design.

Here is a set of ten mathematical questions that will test your understanding of Mathematics and perhaps help you to learn things of interest in the process. You should not use a calculator (except for Question 6) or reference material to answer these questions. Just rely on your own resources.

Questions:
  1. Evaluate \(2^{3^2}\)

  2. \(\pi\) represents the ratio of a circle's diameter to its circumference while \(e\) is the base of the natural logarithms. What is the product of these two numbers?

  3. Evaluate \( \dfrac{1}{0!}\)

  4. Evaluate \(4 + 8 \div 4 \times 2\)

  5. Will \(2100\) be a leap year?

  6. In a random group of people, how many are needed so that the probability of two people sharing the same birthday is about 50%? You can use a calculator for this problem.

  7. Can you find the smallest integer that can be written as \(x^2+xy+y^2 \) in two different ways with \(x \geq 0\) and \(y \geq 0\)? Hint: it's smaller than 50.

  8. A happy number is one that reduces to 1 with repeated sums of squares of digits. For example, \(13 \rightarrow 1^2+3^2 = 10 \rightarrow 1^2+0^2 = 1\). What happens to numbers that aren't happy?

  9. \(5=2^2+1^2\) but \(7\) can't be written as a sum of two squares. Using this information, try to decide whether the prime number \(1009\) can or cannot be written as a sum of two squares. Hint: use modular arithmetic. 

  10. Who is this German mathematician depicted below? Hint: his first name is Georg. He was born in 1845 and died in 1918.

Answers:

  1.  The rule is that the calculation proceeds from the top downwards and so we calculate \(3^2=9 \) first, then \(2^9=512\). Proceeding from the bottom up, we would evaluate \(2^3=8\) and then \(8^2=64\) but this is incorrect. Thus the answer is 512.

    Comment: I've written about this in a blog post titled Power Towers and Tetration. This is a simple but important principle to understand and is a sort of extension of the BOMDAS rule (Brackets, Of, Multiplication, Division, Addition, Subtraction).

  2. This is definitely a trick question. The answer is \(pie\).

    Comment: there's always room for humour in mathematics, provided it's not overdone. 

  3. It needs to be remembered that \(0!=1\) and thus the answer is 1.

    Comment: many former high school students would remember that zero factorial is 1 so this is not as difficult as it looks.

  4. To prevent mistakes put a bracket around division and multiplication before proceeding from left to right. This gives:

    \(4 + ((8 \div 4 )\times 2)=4 + (2 \times 2)=4+4=8\)

    Comment: this will trick a lot of people but it's still an elementary problem that even an upper level primary student should be able to handle.

  5. End of century years must be divisible by \(4\) and \(100\). While \(2100\) is divisible by \(100\), it is not divisible by \(4\) and thus it is not a leap year.

    Comment: this is not widely known but it should be and so this problem will inform those who weren't familiar with the rule.

  6. This is the famous birthday problem and the answer is 23 people. I've written about this is a blog post titled 23.

    Comment: the number is somewhat counter-intuitive in that it's much smaller than one might expect. It's an interesting problem that doesn't require any high level mathematics but will require a calculator (hence the exemption).

    Here is a brief explanation taken from my previously mentioned blog post:
    • With 23 people we have 253 pairs: \(\dfrac{23 \times 22}{2}=253\)
    • The chance of two people having different birthdays is \(1−\dfrac{1}{365}=\dfrac{364}{365}=0.997260\)
    • Makes sense, right? When comparing one person's birthday to another, in 364 out of 365 scenarios they won't match. Fine. But making 253 comparisons and having them all be different is like getting heads 253 times in a row - you had to dodge "tails" each time. Let's get an approximate solution by pretending birthday comparisons are like coin flips.We use exponents to find the probability:
      • \( \left (\dfrac{364}{365} \right )^{253}=0.4995 \approx 50 \%\)
    • Our chance of getting a single miss is pretty high (99.7260%), but when you take that chance hundreds of times, the odds of keeping up that streak drop. Fast.

  7. The smallest integer is \(49=0^2+0 \times 7+7^2=3^2+3 \times 5+5^2\). Such numbers are called Loeschian numbers and I've written about them in this post.

    Comment: this is easy to work out with a little trial and error.

  8. It shouldn't take too long for someone to realise that numbers that aren't happy end up in the loop {4,16,37,58,89,145,42,20}. I've written about these in a post titled Happy Numbers.

    Comment: the discovery takes just a little trial and error.

  9. All primes of the form \(4k+1\) where \(k \geq 1\) can be written as a sum of two squares. Now \(1009 \div 4\) leaves a remainder of \(1\) so it is of the form \(4k+1\) and can be written as a sum of two squares (\(15^2+28^2\)). I've written about these in a post titled Sum of Two Squares

    Comment: this is a little difficult but the hint to use modular arithmetic should nudge people in the right direction.

  10. His name is Georg Cantor and he is the "father" of set theory. You can read more about him by following this link.

    Comment: the first name is "Georg" and other hints will eliminate the well-known mathematics so some people may guess this because "Cantor" is reasonably well-known.
Since creating this quiz I've modified and improved the questions in various ways, so it's been a useful exercise. I still have to decide on the best way to present them. I may experiment with various formats and report back on this post as I'll use this quiz as the content.

ADDENDUM:

I've made use of QUIZIZZ to create a multiple choice quiz using 9 out of the 10 questions. Question 2 wasn't suitable for multiple choice so I've replaced it with another one involving identification of primes. A negative is that the site requires the setting up of a class and the addition of the quiz to that class as homework. Anyone wanting to take the test needs to set up an account by visiting https://quizizz.com/join/class and then use the class code which is M214707.


There are other negatives. As far as I can tell there is no support for LaTeX and so any mathematical expressions have to be included as images. However, the images are easily imported and display well so it's not a major issue. Any revisions mean that the image must be deleted and a new one imported.

Sunday, 12 March 2017

Power Towers and Tetration

How is an expression like \(2^{{{2}^{2}}^{0}}\) evaluated? Such an expression is often termed a power tower and the convention is that the evaluation takes place from the top down so we have:

\(2^{{2}^{1}}=2^2=4\)

I saw this question posed in Quora and it evoked hundreds of responses.

The term used in this context is tetration which Wikipedia explains as follows:
In mathematics, tetration (or hyper-4) is the next hyper-operation after exponentiation, and is defined as iterated exponentiation. The word was coined by Reuben Louis Goodstein, from tetra-(four) and iteration. Tetration is used for the notation of very large numbers.  
The notation \({^{n}a}\) means \({a^{a^{\cdot^{\cdot^{a}}}}}\), the application of exponentiation \(n-1\) times.
Shown below are the first four hyperoperations, with tetration as the fourth:

Addition
\(a + n = a + \underbrace{1 + 1 + \cdots + 1}_n\)
\(n\) copies of 1 added to \(a\).

Multiplication
\(a \times n = \underbrace{a + a + \cdots + a}_n\)
\(n\) copies of \(a\) combined by addition.

Exponentiation
\(a^n = \underbrace{a \times a \times \cdots \times a}_n\)
\(n\) copies of \(a\) combined by multiplication.

Tetration
\({^{n}a} = \underbrace{a^{a^{\cdot^{\cdot^{a}}}}}_n\)
\(n\) copies of \(a\) combined by exponentiation, right-to-left.

Here is a proper definition:

For any positive real number \(a>0\) and non-negative integer \(n \ge 0 \), we define \(\,\! {^{n}a} \) by:$${^{n}a} := \begin{cases} 1 &\text{if }n=0 \\ a^{\left[^{(n-1)}a\right]} &\text{if }n>0 \end{cases} $$As we can see from the definition, when evaluating tetration expressed as an "exponentiation tower", the exponentiation is done at the deepest level first (in the notation, at the highest level). For example:$$\,\!\ ^{4}2 = 2^{2^{2^2}} = 2^{\left[2^{\left(2^2\right)}\right]} = 2^{\left(2^4\right)} = 2^{16} = 65,\!536$$Note that exponentiation is not associative, so evaluating the expression in the other order will lead to a different answer:$$\,\! 2^{2^{2^2}} \ne \left[{\left(2^2\right)}^2\right]^2 = 2^{2 \cdot 2 \cdot2} = 256$$Exponential towers must be evaluated from top to bottom (or right to left). Computer programmers refer to this choice as right-associative.

Source: https://en.wikipedia.org/wiki/Tetration 

Note: there's nothing very original about this post. I've copied the rather involved LaTeX code from the Wikipedia editing page, modified it by getting rid of the maths arrow brackets and replaced them with \( signs. I was mainly interested to see how the LaTeX would convert and as it turned out the transfer from Wikipedia to Blogger was quite straightforward.