# How to compute the indefinite integrate of n-th tetration of x?

How can the following indefinite integral be computed ?

$$\int{x↑↑n} dx$$

where $$n$$ = {$$x$$ $$\in$$ $$N^+$$ : $${x > 2}$$}

Here $${x↑↑n}$$ refers to $$n$$th tetration of $$x$$. I tried searching over the internet to find a general formulae for calculating it when the value of $$n$$ varies and came across a single paper which had an application of W-Lambart function.

Is there any other method to compute it ?

• Here ${x↑↑n}$ = $xn$ – user 493905 May 23 at 17:29
• Chances of a closed-form solution are negative, I am afraid. – Yves Daoust May 23 at 17:29
• Can you do even $\int x^x\;dx$ in closed form? I can't. There is no reason to think $x^{x^x}$ or $x^{x^{x^x}}$ are any easier. – GEdgar May 23 at 17:52
• @GEdgar: $\int x^x dx$ = $$\sum_{i=0}^{\infty}{(-1)^{i+1}}\frac{Γ(i+1, ln(x^{-i}))}{i!\cdot i^i}$$ – user 493905 May 24 at 7:42
• I forgot to mention $+C$ – user 493905 May 24 at 7:55

The solution expressed on the form of series isn't generally accepted as a closed form. However, the choice of what to call closed-form and what not is rather arbitrary. In common sens, a closed form is a combination of a $$\underline{\text{finite}}$$ number of $$\underline{\text{standard}}$$ functions.

Then the question is what is a standard function ? When a function (defined by an infinite series or by an integral or by other means) becomes a standard function ?

For an example related to $$\int{x↑↑n} dx$$ in the paper : https://fr.scribd.com/doc/34977341/Sophomore-s-Dream-Function the function named Sphd covers a lot of cases. $$\text{Sphd}(\alpha,x)=\int_0^x t^{\alpha t}dt$$ generalized with : $$\int_0^x{x↑↑n} \: dx = \text{Sphd}_{n}(1,...;x)\qquad \text{Eq.}(12:5)$$

And from Eq.$$(12:6)$$ $$\int_a^b{x↑↑\infty} \: dx =\text{Sphd}_{\infty}(1,...;b)-\text{Sphd}_{\infty}(1,...;a)=-\int_a^b\frac{\text{W}(-\ln(t))}{\ln(t)}dt$$ W is the Lambert W function.

Of course, all this is purely formal since Sphd isn't a standardized special function. Creating symbols for new functions may appear as vicious circle. A discussion about the definition of new special functions, standardization of such functions and further use can be found in : https://fr.scribd.com/doc/14623310/Safari-on-the-country-of-the-Special-Functions-Safari-au-pays-des-fonctions-speciales .

There are easy taylor series for $$(x+1)$$, $$(x+1)^{(x+1)}$$, $$(x+1)^{(x+1)^{(x+1)}}$$, and so on. For them you can do formal integration by integrating the series-terms. (Whether this gives series with nonzero convergence-radius or not, and something else, I don't know at the moment). A general formula for the generating of the coefficients, which would be simpler than the explicite computation by the taylor-series expansion for some given tetration-height, I don't see at the moment. But the remarkable pattern of the coefficients when iterating to higher $$n$$ has been discussed many times.

added: you might be interested in this essay on "tetrating the pascal-matrix" which gives in chap 2 possibly helpful discussion of concept and pattern, although it may as well be some overkill for your question...

Example: first few taylor-coefficients for $$1$$, $$x+1$$, $$(x+1)^{(x+1)}$$ , ...

  1  x  x^2 x^3  x^4   x^5    x^6     x^7
---------------------------------------------------------------
1  0  0    0    0     0       0         0      for f0(x)=1
1  1  0    0    0     0       0         0      for f1(x)=(x+1)^f0(x)
1  1  1  1/2  1/3  1/12    3/40    -1/120      for f2(x)=(x+1)^f1(x)
1  1  1  3/2  4/3   3/2   53/40   233/180
1  1  1  3/2  7/3     3  163/40  1861/360
1  1  1  3/2  7/3     4  243/40  3421/360
1  1  1  3/2  7/3     4  283/40  4321/360
1  1  1  3/2  7/3     4  283/40  4681/360
1  1  1  3/2  7/3     4  283/40  4681/360


The columnwise progressions may be illustrated by the moving differences:

  1  x  x^2 x^3  x^4   x^5    x^6     x^7    for
---------------------------------------------------------------
1  0  0    0    0      0     0        0
.  1  0    0    0      0     0        0    (x+1)-1
.  .  1  1/2  1/3   1/12  3/40   -1/120    (x+1)^(x+1)-(x+1)
.  .  .    1    1  17/12   5/4  469/360    (x+1)^(x+1)^(x+1)-(x+1)^(x+1)
.  .  .    .    1    3/2  11/4     31/8
.  .  .    .    .      1     2     13/3
.  .  .    .    .      .     1      5/2
.  .  .    .    .      .     .        1
.  .  .    .    .      .     .        0


If we scale the coefficients by factorials (columnwise) we find the limit of the sequence of rows in the OEIS and they can also be found when having the expansion of the LambertW-function for power series at hand:

      exp(-lambertw(-log(1+x)))-1    \\ Pari/GP gives the limiting set of
\\ coefficients for the infinite iteration height
%20 = x + x^2 + 3/2*x^3 + 7/3*x^4 + 4*x^5 + 283/40*x^6 + 4681/360*x^7 + O(x^8)


After that, you can write your integrals by the formal integration-rule for coefficients of the taylor-series.

• That means the final result can be obtained by observing the pattern ? – user 493905 May 25 at 6:12
• Yes, I think so. But I've never found out a "simple" pattern-formula with a meaningful/obvious option to interpolate to fractional iteration-heights. – Gottfried Helms May 25 at 6:21
• Does a solution to this indefinite integral exists or has someone ever tried to compute it ? – user 493905 May 28 at 5:45
• @AdityaRaj - what do you mean "solution"? You only need adapt the coefficients and exponents of the $x$ in the series for getting the series for integrals. You can do it yourself, no further big plan is needed...Perhaps Wolfram alpha gives even the integral for the $\exp(...)$-expression, just type it into it.... – Gottfried Helms May 28 at 5:57
• Well Wolframe Alpha fails to provide the indefinite integral of nth tetration of x. Even i have tried every online integral calculator over the internet. – user 493905 May 28 at 6:23

Your can try to compute it approximately. As an example. If you have the integral. $$I_2(a)=\int_1^a x^{x^x} dx\,,$$ with $$a\gg1$$. In fact this faction grows very rapidly, it will be works for a=3, with enough good accuracy. We can represent this integral in the following form $$I_2(a)=\int_1^a e^{S(x)} dx$$ and do the integration by parts $$I(a)=\int_1^a e^{S(x)} dx=\int_1^a \frac{de^{S(x)}}{S'(x)} dx=\frac{S(a)}{S'(a)}-\frac{S(1)}{S'(1)}-\int_1^a dxe^{S(x)} \frac{d}{dx} \frac{1}{S'(x)}.$$ The main contribution is given by the term $$\frac{S(a)}{S'(a)}$$, the integral term is a the next correction. You can continue to do the integration by part to improve your accuracy. In such case $$I_2(a)=\dfrac{a^{a^a}}{a^a(1/a+\ln a(\ln a+1 ))}$$ The I_2(3)=$$1,07 *10^{11}$$, the result by numerical integration is $$1,11*10^{11}$$.

In fact this asymptotics depends only on upper limit of integration.

In the general case, using the notation presented above we have $$I_n(a)=\int_0^a{x↑↑n} dx=\frac{x↑↑n}{d/dx({x↑↑(n-1)} \ln(x))}|_{x=a}$$