# Does $\lim\limits_{n\to\infty}\int\limits_{0}^{1}\{x+\frac{1}{2}\{x+\frac{1}{3}\{x+...\frac{1}{n}\}\}\}dx$ converge?

Where $$\{x\}$$ is the fractional part of $$x$$.

According to Desmos, with $$I_n=\int\limits_{0}^{1}\{x+\frac{1}{2}\{x+\frac{1}{3}\{x+...\frac{1}{n}\}\}\}dx$$

$$\begin{array}{c|c} n & I_n \\ \hline 2 & \frac{1}{2} \\ \hline 3 & \frac{19}{36} \\ \hline 4 & \frac{107}{240} \\ \hline 5 & \frac{395473}{836400} \\ \hline 6 & \approx0.459451666657 \\ \hline 7 & \approx0.445305522347 \end{array}$$

It seems to be bounded by $$0.44. I do not even know to how to go about proving the convergence of this because I have not found a pattern in $$\frac{1}{2},\frac{19}{36},\frac{107}{240},\frac{395473}{836400}$$.

Edit: I came up with this problem while messing around on Desmos. Here is the link to the graph: https://www.desmos.com/calculator/fgikxrptj2

• If there were no $\{\;\}$ inside the first integral part, the limit of the inside expression would be $xe$, and $\int^1_0\{e x\}\,dx\approx 0.4627786...$ more or less in accordance to your bounds. I think the trick is to show that $f_n(x)=f_{n-1}(x+\frac1n\{x\})$, where $f_1(x)=\{x\}$ converges to $\frac\{ex\}$ or something like that. Feb 6 at 0:03
• IIf the OP can also post the provenance of this problem (a compendium of problems, a statement in a paper, an old academic or contest exam) to give credit to the authors of the problem, that would be appreciated. Feb 6 at 0:13
• @Mittens I came up with it myself. I don't suppose I was the first person to think of this but, as you can probably tell by a lot of other questions I ask on this site, I mess around a lot on desmos with the fractional part function. Feb 6 at 0:17
• @Mittens I find Dylan's questions interesting. I don't think a lot of people need a provenance to answer his question.
– Sam
Feb 6 at 0:21
• @Sam: Bexacuse there are other places such as the artofproblemsolving.com where the solution might have been posted and also because is good practice to give credit. Feb 6 at 0:26

Let $$f_j(x) =\left\{x + \frac{1}{2} \left\{x + \cdots + \frac{1}{j}\left\{x + \frac{1}{j+1}\right\}\cdots\right\}\right\}$$ for $$j > 0$$. Define $$g_0 = 0; \quad g_j(x) = \left\{x + \frac{1}{2} \left\{x + \cdots + \frac{1}{j}\left\{x\right\}\cdots\right\}\right\} \text{ for } j > 0.$$ Finally, define the sequence $$r_k = \frac{1}{(k+1)!\sum_{n=k+1}^{\infty} \frac{1}{n!}}$$ for $$k \geq 0$$, and write $$\alpha = e - 1$$ for convenience. Note $$r_k$$ is increasing and that $$\lim_{k \to \infty} r_k = 1$$.

Lemma. $$f_j \to \alpha(x - r_m) + g_n(r_m)$$ pointwise on $$(r_m, r_{m+1})$$.

Proof. Denote the domain of continuity of a function $$a \colon \mathbb{R} \to \mathbb{R}$$ by $$\mathcal{C}(a) = \{x \in [0,1] \mid a \text{ is continuous at } x \}.$$ Note that

• $$\mathcal{C}(a \circ b) = \mathcal{C}(b) \cap b^{-1}[\mathcal{C}(a)]$$ for $$a,b \colon \mathbb{R} \to \mathbb{R}$$, and
• $$\mathcal{C}(a + b) = \mathcal{C}(a)$$, if $$b$$ is continuous.

Of interest to us is the fact that $$\mathcal{C}(x \mapsto \{x\}) = \mathbb{R} - \mathbb{Z}$$. Now, given a function $$a \colon \mathbb{R} \to \mathbb{R}$$, define the $$\lambda$$-crease of $$a$$ to be the map $$T_\lambda[a]$$ taking $$x \mapsto \frac{1}{\lambda}\{x + a(x)\}$$. Then we may compute $$\mathcal{C}(T_{\lambda}[a]) = \mathcal{C}(a) \cap \{x \mid x + a(x) \not\in \mathbb{Z}\}.$$ Observe that $$f_j$$ is actually the result of performing multiple creases on $$a \equiv \frac{1}{j+1}$$. Specifically, $$f_j = T_1 T_{2} \cdots T_{j} \left[\frac{1}{j+1}\right]$$. Then it follows that $$\mathcal{C}(f_j) = \left\{ x \bigm| x + T_{k} \cdots T_{j}\left[\tfrac{1}{j+1}\right] < 1 \text{ for all } 1 \leq k \leq j \right\}.$$

Now, we can determine all the points of discontinuity from solutions to the equations $$f_{j, k}(x) \overset{\text{def}}{=} x + T_{k} \cdots T_{j}\left[\tfrac{1}{j+1}\right] = 1; \quad f_{j, j+1} \overset{\text{def}}{=} x + \tfrac{1}{j+1} = 1.$$ I claim that $$f_{j,k}(x) < 1$$ for all $$x \in (0, r_{k-3})$$. To see this, write $$f_{j,k}(x) = x + \frac{1}{k}\{f_{j, k-1}(x)\}$$, and note that for $$x < r_{k-3}$$, we have $$f_{j,k}(x) < r_{k-3} + \tfrac{1}{k} < 1,$$ since $$\frac{1}{r_{k-3}} = \frac{1}{k-1}\left(k + \frac{1}{k} + \frac{1}{k(k+1)} + \frac{1}{k(k+1)(k+2)}+\cdots\right) > \frac{k}{k-1}.$$

As $$(r_k)_{k \in \mathbb{N}}$$ is increasing, it follows that for any integer $$k' \in \{k, \ldots, j\}$$, one also has that $$f_{j, k'}(x) < 1$$ for all $$x \in (0, r_{k-3})$$. Then if $$m(k, x)$$ is the greatest integer such that $$f_{j, m}(x) = 1$$, we must have $$m(k,x) < k \leq j$$ whenever $$x \in (0, r_{k-3})$$. In that case, we have \begin{align*} f_{j,j+1}(x) &= x + \tfrac{1}{j+1} \\ f_{j,j}(x) &= x + \tfrac{1}{j}\{f_{j, j}(x)\} = x + \tfrac{1}{j}\left( x + \tfrac{1}{j+1} \right) \\ &{\hspace{6pt}\vdots} \\ f_{j, m}(x) &= x + \tfrac{1}{m}\left(x + \tfrac{1}{m+1}\left(x + \cdots + \tfrac{1}{j} \left(x + \tfrac{1}{j+1}\right) \cdots \right) \right) = 1. \end{align*} This is a linear equation with a unique solution $$s_{j, m}$$, which may or may not be in the desired interval. Therefore, there are at most $$k$$ points of discontinuity of $$f_j$$ in the interval $$(0, r_{k-3})$$. However, by explicitly calculating these solutions for large $$j$$, we can determine that exactly $$k - 2$$ points of discontinuity lie in this interval. In particular, we have that for $$m < k$$, $$s_{j,m} = \frac{\frac{1}{(m-1)!} - \frac{1}{(j+1)!}}{\frac{1}{(m-1)!} + \frac{1}{m!} + \cdots + \frac{1}{j!}} \to r_{m-2},$$ and moreover, that $$s_{j,m}$$ is increasing in $$j$$, since $$\frac{c}{d} > \frac{a}{b}$$ implies $$\frac{a+c}{b+d} > \frac{a}{b}$$ and $$\frac{\frac{1}{(j+1)!} - \frac{1}{(j+2)!}}{\frac{1}{(j+1)!}} = 1 - \frac{1}{j+2} > 1-\frac{1}{m+3} > s_{j,m}.$$ Therefore, for large $$j$$, the only points of discontinuity of $$f_j$$ in the interval $$(0, r_{k-3})$$ are the roots $$s_{j,2}, \ldots, s_{j,k-1}$$. By a similar argument, we may determine the points of discontinuity of $$g_j$$, and realize that they do not include any $$r_{k}$$. This can be done through wrangling several inequalities, but the quickest way to see this is that the points of discontinuity of $$g_j$$ will all be rational, whereas each $$r_k$$ is irrational.

We can now compute the pointwise limit of $$f_j$$. Suppose that $$x_0 \in (r_m, r_{m+1})$$ Then there exists some integer $$J \geq m + 3$$ such that for all $$j \geq J$$, we have $$x_0 \in (s_{j, m+2}, s_{j, m+3})$$. Since $$f_j$$ is right-continuous and linear on $$[s_{j, m+2}, s_{j, m+3})$$, we may write $$f_j(x) = \alpha_j (x - s_{j, m+2}) + f_j(s_{j, m+2}) = \alpha_j (x - s_{j, m+2}) + g_{m}(s_{j, m+2}),$$ where $$\alpha_j = \sum_{n=1}^{j} \frac{1}{n!}$$ is the slope of $$f_j$$. Since $$g_m$$ is continuous at $$r_m$$, we may take the limit to obtain

$$\lim_{j \to \infty} f_j(x) = \alpha (x - r_m) + g_m(r_m),$$ as desired.

The bounded convergence theorem implies that the limit of $$I_j = \int_{0}^{1} f_j(x) \, \mathrm{d}x$$ exists, and is equal to $$\int_{0}^{1} f(x) \, \mathrm{d}x$$. By the previous lemma, we may integrate $$f$$ over each interval $$(r_m, r_{m+1})$$, yielding $$\lim I_j = \int_{0}^{1} f(x) \, \mathrm{d}x = \frac{1}{2\alpha} + \sum_{n=0}^{\infty} \left[g_n(r_{n})\left(r_{n+1} - r_n\right) + \frac{\alpha}{2}(r_{n+1}-r_n)^2\right].$$

This is not a complete answer, but it will help you get started. Define $$I_n = \int_0^{1} g_n(x) dx$$ and $$f(x) = \{x\}$$ be the fractional part function. Since $$f(x) = x - \lfloor x \rfloor$$ (Subtracting an integer from $$x$$), the function $$g_n$$ can be simplified as $$g_n(x) = x\left( \sum_{k=1}^{n-1} \frac{1}{k!}\right) + \frac{1}{n!} - \sum_{i=1}^{N(n)} c_i\chi_{[a_{i-1},a_i)}(x)$$ where $$\{a_i\}_{i=0}^{N}$$ is a partition of $$[0,1]$$, $$0 = a_0 < a_1 < \cdots < a_N = 1$$, $$\chi_{[a_{i-1},a_i)} = 1$$ if $$x \in [a_{i-1},a_i)$$ and $$0$$ otherwise (these are called indicator functions), and coefficients $$0\le c_i < e-1$$ .We also know that $$a_1 = \frac{1}{\sum_{k=1}^{n-1}k!}\left(1-\frac{1}{n!}\right)$$, $$a_2 = \frac{1}{\sum_{k=2}^{n-1}\frac{1}{k!}}\left(\frac{1}{2}-\frac{1}{n!}\right)$$ (unless $$n=2$$, in which case $$a_2=1$$) and $$c_1 =0, c_2 = 1, c_3= \frac{1}{2}$$. This implies that $$g_n(x) =\begin{cases} x\left( \sum_{k=1}^{n-1} \frac{1}{k!}\right) + \frac{1}{n!},& \quad 0 \le x < \frac{1}{\sum_{k=1}^{n-1}k!}\left(1-\frac{1}{n!}\right) \\ x\left(\sum_{k=1}^{n-1}\frac{1}{k!}\right)+\frac{1}{n!}-1,& \frac{1}{\sum_{k=1}^{n-1}k!}\left(1-\frac{1}{n!}\right)\le x<\frac{1}{\sum_{k=2}^{n-1}\frac{1}{k!}}\left(\frac{1}{2}-\frac{1}{n!}\right)\end{cases}$$ and $$I_n$$ can be simplified as: $$I_n =\frac{1}{2}\left( \sum_{k=1}^{n-1} \frac{1}{k!}\right) + \frac{1}{n!} - \sum_{i=2}^{N(n)} c_i|a_i-a_{i-1}|$$ If something can be said about the sequence $$c_i$$ then the limiting value can be determined. In the limiting case $$I_{\infty} = \frac{e-1}{2}-\left(\frac{1}{2}\frac{1}{e-2}-\frac{1}{e-1}\right)-\sum_{i=3}^{\infty} c_i|a_i-a_{i-1}|.$$