# How to find $\lim_{n \to \infty} \int_0^1 \cdots \int_0^1 \sqrt{x_1+\sqrt{x_2+\sqrt{\dots+\sqrt{x_n}}}}dx_1 dx_2\dots dx_n$

Here I mean the limit of the following sequence:

$$p_1=\int_0^1 \sqrt{x} ~dx=\frac{2}{3}$$

$$p_2=\int_0^1 \int_0^1 \sqrt{x+\sqrt{y}} ~dxdy=\frac{8}{35}(4 \sqrt{2}-1) = 1.06442\dots$$

$$p_3=\int_0^1 \int_0^1 \int_0^1 \sqrt{x+\sqrt{y+\sqrt{z}}} ~dxdydz = 1.242896586866\dots$$

$$p_4 \approx 1.314437693607766$$

$$p_5 \approx 1.34186271753784$$

Here the approximate values are computed by Mathematica. In principle every one of these integrals can be evaluated in closed form, but it becomes very complicated (see $p_3$ at the bottom of the post).

How can we find the limit at $n \to \infty$? It should be finite because of the range of variables chosen.

$$\lim_{n \to \infty}p_n=\lim_{n \to \infty} \int_0^1 \cdots \int_0^1 \sqrt{x_1+\sqrt{x_2+\sqrt{\dots+\sqrt{x_n}}}}dx_1 dx_2\dots dx_n=?$$

I find it very likely that $\lim_{n \to \infty}p_n=\phi$ (the Golden Ratio), but I'm not sure (this is not correct, see the comments).

Edit: With the help of Wolfram Alpha I tackled $p_3$ (see the updated numerical value above):

$$p_3=\frac{64}{135135} (2 \sqrt{3244081+2294881 \sqrt{2}}-664\sqrt{2}-1092\cdot 2^{3/4}+305)$$

This confirms my suspicions that there is no hope for apparent pattern in the first few $p_k$. Now an interesting challenge is to see how many $p_k$ can be realistically computed in closed form.

• Just link another integral limit question here (it's much easier though, since it's symmetic in all the variables) math.stackexchange.com/q/728173/269624 – Yuriy S Jun 12 '16 at 19:46
• Note that $p_n=E(X_n)$ where $(X_n)$ is the Markov chain such that $X_0=0$ and $X_n=\sqrt{X_{n-1}+U_n}$, for $(U_n)$ i.i.d. uniform on $(0,1)$. For every $n\geqslant1$, $P(0<X_n<x^*)=1$ where $x^*$ solves $x=\sqrt{1+x}$. One can guess that $(X_n)$ converges in distribution to some distribution $\pi$, then the limit of $(p_n)$ (easily seen to exist) is $p_\infty=\int_0^{x^*}xd\pi(x)$. On a more constructive side, note that, by convexity, $E(X_n)<\sqrt{E(X_{n-1})+E(U_n)}$, that is, $p_n<\sqrt{p_{n-1}+\frac12}$ for every $n$, hence $p_\infty<\frac12(1+\sqrt3)$. – Did Jun 12 '16 at 19:48
• @Did, thank you. If the upper limit was $2$, would $p_{\infty} < \phi$? – Yuriy S Jun 12 '16 at 19:50
• For anybody who wants to play with Mathematica: f[x_] := Sqrt[Fold[#2 + Sqrt[#1] &, x]]; h[n_] := With[{v = Table[{Subscript[x, i], 0, 1}, {i, 1, n}]}, Apply[NIntegrate, Prepend[v, f[Map[First, v]]]]]; DiscretePlot[h[n], {n, 1, 25}, PlotRange -> Full] This seems to support a limiting value of 1.35-1.36. – Jason Jun 12 '16 at 19:51
• The limit value (infered using Monte-Carlo integration) is numerically found to be $$p_\infty = 1.35836 \pm 10^{-5}$$ where the error is a $1\sigma$ error estimate from the MC integration + extrapolation from finite $n$ to $\infty$ (this last part is estimated to be much smaller than the statistical error here as I computed it up to $n = 200$ for which it has practically converged). – Winther Sep 7 '16 at 21:08

Let us define: $$I_3(a) := \int\limits_{[0,1]^3} \sqrt{x+\sqrt{y+\sqrt{z+a}}} dx dy dz$$ Then by using elementary integration we have the following result: \begin{eqnarray} I_3(a) &=& \frac{32}{31} \left( \sum\limits_{k=0}^3 |[\begin{array}{r} 3 \\ k \end{array}]|(-1)^{3-k} \frac{(u^+)^{\frac{9}{2}+k} - (u^-)^{\frac{9}{2}+k}}{\frac{9}{2}+k} \right)+\\ &-& \frac{32}{15}\left( \sum\limits_{k=0}^3 \binom{3}{k}(-1)^{3-k} \frac{(u_1^+)^{\frac{7}{2}+k} - (u_1^-)^{\frac{7}{2}+k}}{\frac{7}{2}+k} \right)+\\ &-&\frac{16}{21}\left( \frac{(u^+_2)^{\frac{15}{4}} - (u^-_2)^{\frac{15}{4}}}{\frac{15}{4}}-\frac{(u^+_2)^{\frac{11}{4}} - (u^-_2)^{\frac{11}{4}}}{\frac{11}{4}}-\frac{(u^+_3)^{\frac{15}{4}} - (u^-_3)^{\frac{15}{4}}}{\frac{15}{4}} \right) \end{eqnarray} where \begin{eqnarray} (u^+, u^-) &:=& (\sqrt{1+\sqrt{1+a}}+1,\sqrt{1+\sqrt{0+a}}+1) \\ (u_1^+,u_1^-) &:=& (\sqrt{0+\sqrt{1+a}}+1,\sqrt{0+\sqrt{0+a}}+1)\\ (u_2^+,u_2^-)&:=&(\sqrt{1+a}+1,\sqrt{0+a}+1)\\ (u_3^+,u_3^-)&:=&(\sqrt{1+a}+0,\sqrt{0+a}+0) \end{eqnarray} Now, clearly the next integral we need to compute is $I_4(a) := \int\limits_0^1 I_3(\sqrt{\xi+a}) d\xi$. All the integrals are can be expressed through elementary functions by substituting for the respective $u_j^{\pm}$ for $j=0,\cdots,3$ and integrating power functions. Therefore with some effort it is easy to compute higher elements of this sequence. Yet it is unclear for me at this stage if I might be able to find a neat expression for arbitrary elements.

• Thank you for your contribution. Let's hope some closed form answer for the limit will come up eventually. I don't believe there is a 'simple' form for arbitrary elements though, sicne even $p_3$ looks very complicated. – Yuriy S Aug 28 '16 at 19:21

## Just as a try:

Let

\begin{aligned} {P_0} &= P\\ {P_{i + 1}} &= \int_0^1 {{P_i}/.P \to \sqrt {x + P} {\text{d}}x}\\ {p_i} &= {P_i}/.P \to 0 \end{aligned}

Now,we can written the process as:

\begin{aligned} {P_1} &= \int_0^1 {{P_0}/.P \to \sqrt {x + P} {\text{d}}x} \\ &= \int_0^1 {\sqrt {x + P} {\text{d}}x} \\ &= - \frac{2}{3}\left( {{P^{3/2}} - {{\left( {1 + P} \right)}^{3/2}}} \right)\\ {p_1} &= {P_1}/.P \to 0 = \frac{2}{3} \end{aligned}

And then:

\begin{aligned} {P_2} &= \int_0^1 {{P_1}/.P \to \sqrt {x + P} {\text{d}}x} \\ &= \frac{2}{3}\int_0^1 {\left( {{{\sqrt {x + P} }^{3/2}} - {{\left( {1 + \sqrt {x + P} } \right)}^{3/2}}} \right){\text{d}}x} \\ &= \frac{{ - 2}}{3} \times \frac{{ - 4}}{7}\left( {\left( {{P^{7/4}} - {{\left( {1 + P} \right)}^{7/4}}} \right) + \frac{1}{5}{\text{Madness}}(\frac{3}{2},1)} \right)\\ {\text{Madness}}(\frac{3}{2},1) &= 5\int_0^1 {{{\left( {1 + P} \right)}^{3/2}}/.P \to \sqrt {x + P} {\text{d}}x} \\ &= {\left( {1 + \sqrt {1 + P} } \right)^{5/2}}\left( { - 2 + 5\sqrt {1 + P} } \right) - {\left( {1 + \sqrt P } \right)^{5/2}}\left( { - 2 + 5\sqrt P } \right)\\ p2 &= {P_2}/.P \to 0\\ &= \frac{{ - 2}}{3} \times \frac{{ - 4}}{7}\left( { - 1 + \frac{1}{5}(2 + 12\sqrt 2 )} \right)\\ &= \frac{8}{{35}}\left( {4\sqrt 2 - 1} \right) \end{aligned}

Also:

\begin{aligned} {P_3} &= {\color{Red} {\frac{{ - 2}}{3}\left( {\frac{{ - 4}}{7}\left( {\frac{{ - 8}}{{15}}\left( {{P^{15/8}} - {{\left( {1 + P} \right)}^{15/8}} + \frac{1}{{11}}{\text{Mad}}(\frac{{11}}{4},1)} \right) + \frac{1}{5}{\text{Mad}}(\frac{3}{2},2)} \right)} \right)}}\\ &= {a_1}\left( {{a_2}\left( {{a_3}\left( {{P^{15/8}} - {{\left( {1 + P} \right)}^{15/8}} + {b_3}{\text{Mad}}(11/4,1)} \right) + {b_2}{\text{Mad}}(3/2,2)} \right)} \right)\\ {P_n} &= {a_1}\left( { \cdots \left( {{a_n}\left( {{P^{{2^{n + 1}} - 1/{2^n}}} - {{\left( {1 + P} \right)}^{{2^{n + 1}} - 1/{2^n}}} + {b_n}{\text{Mad}}\left( {\left( {3 \times {2^n} - 1} \right)/{2^{n - 1}},1} \right)} \right) + \cdots } \right)} \right)\\ \end{aligned}

Where:

\left\{ \begin{aligned} {a_n} &= \frac{{{2^n}}}{{1 - {2^{1 + n}}}} \hfill \\ {b_n} &= \frac{{{2^n}}}{{3 \times {2^{n - 1}} - 1}} \hfill \\ \end{aligned} \right.

Let $P=0$ and expand $p_n$ :

\begin{aligned} {p_\infty } &= {a_1}\left( { \cdots \left( {{a_n}\left( { - 1 + {b_n}{\text{Mad}}\left( {\left( {3 \times {2^n} - 1} \right)/{2^{n - 1}},1} \right)} \right) + \cdots } \right)} \right)\\ &= 0 + \sum\limits_{j = 1}^\infty {b(j)\left( {\prod\limits_{i = 1}^j a (i)} \right){\text{Mad}}\left( {\left( {3 \times {2^j} - 1} \right)/{2^{j - 1}},\infty } \right)} \\ &= \sum\limits_{j = 1}^\infty {\frac{{3{{( - 1)}^{ - j}}{2^{\frac{1}{2}j(j + 3)}}}}{{\left( {1 - 3 \times {2^j}} \right){{(4;2)}_{j + 1}}}}{\text{Mad}}\left( {\frac{{3 \times {2^j} - 1}}{{{2^{j - 1}}}},\infty } \right)} \end{aligned}

${(4;2)_{n + 1}} = QPochhammer\left[ {4,2,1 + n} \right]$

Well...I failed...It is harder to calculate...

$${\text{Madness}}(s,\infty ){\text{ }} = C\int \cdots \int_0^1 {{{\left( {1 + P} \right)}^s}/.P \to \sqrt {x + P} {\text{d}}x}$$