# Asymptotic behavior of $\sum_{k=1}^{\infty} \sqrt{\max\{1 - k^2/x^2,0\}}$ as $x\to\infty$

Let $$f:\mathbb{R}\to\mathbb{R}$$ be the function $$f(x) = \sum_{k=1}^{\infty} \sqrt{\max\left\{1 -\frac{k^2}{x^2},0\right\}}.$$

Numerical experiments suggests that there exists $$n\in\mathbb{N}$$ and a $$1$$-periodic function $$p:[n,\infty)\to\mathbb{R}$$ such that $$f(x) = - \frac{1}{2} + \frac{\pi}{4}x + \frac{p(x)}{\sqrt{x}}$$ for every $$x\geq n$$.

Question: Can this be true?

Edit (26.12.2021) Below is the portion of the graph of $$p$$.

• How do the numerical experiments suggest this and what $n$ do they suggest?
– user44143
Dec 26, 2021 at 5:55
• @MattF. I was just playing with it in Scilab. $n=1$ seems to work. Dec 26, 2021 at 6:09

Use the Euler-MacLaurin formula, $$\sum_{k=1}^\infty F(k)=\int_0^\infty F(k)\,dk+\tfrac{1}{2}[F(\infty)-F(0)]+\int_0^\infty (k-\text{Int}\,[k]-\tfrac{1}{2})F'(k)\,dk.$$

In this case $$F(k)=\sqrt{\max\{1 -k^2/x^2,0\}}$$, hence$$^\ast$$ $$f(x)=\sum_{k=1}^\infty F(k)=\frac{\pi x}{4}-\frac{1}{2}+(3-4\delta x)\frac{\sqrt {2\delta x}}{6\sqrt{x}}-\frac{0.075}{\sqrt{x}}-\frac{1}{12x^2}\,\text{Int}\,[x]+{\cal O}(1/x^{3/2}),$$ where $$\text{Int}\,[x]$$ denotes the integer part of $$x$$ and $$\delta x=x-\text{Int}\,[x]$$. (The coefficient $$0.075$$ is computed numerically -- can it be computed analytically?)

So the equation in the OP, $$f(x) = - \frac{1}{2} + \frac{\pi}{4}x + \frac{p(x)}{\sqrt{x}},$$ with $$p(x+1)=p(x)$$ holds, but only up to corrections of order $$1/x$$.

The plot compares the exact $$p(x)$$ (blue) with expansion formula above (gold).

$$^\ast$$ The integral of $$k-\text{Int}\,[k]-\tfrac{1}{2}F'(k)$$ over an interval $$(n,n+1)$$ contributes $$-\tfrac{1}{12}x^{-2}$$ for large $$x$$, and there are $$\text{Int}\,[x]$$ of these intervals, hence the term of order $$1/x$$ that breaks the periodicity of $$p(x)$$. The interval $$(\text{Int}\,[x],x)$$ contributes the term $$\tfrac{1}{6}(3-4\delta x)\sqrt{2\delta x/x}$$ for large $$x$$. The term $$-0.075x^{-1/2}$$ comes from the intervals $$(n,n+1)$$ with $$n$$ of order $$x$$. This is the contribution which I was not able to computer analytically.
• I'm afraid you're too quick to accept; I can get the first two terms but not the remainder... need further thought... Dec 25, 2021 at 23:08
• Sir, you saw what I couldn't see and provided a clear expansion for $p$, and the derivatives seemed easy to evaluate. This was good enough for me. Thanks again. Dec 25, 2021 at 23:21
• Sir, I appreciate that you spared your time for a detailed reply, especially in this holiday season, perhaps surrounded by friends and family. I hope this small question is a means to pass a pocket of good time, akin to and no less entertaining than family board games & puzzles. Dec 26, 2021 at 10:13
• $k-\text{Int}[k]-1/2$ is the "periodized Bernoulli function" $P_1(k)=B_1(k-\text{Int}[k])$, see the Wikipedia page I linked to. Apr 21, 2022 at 10:21
• that is the first Bernoulli polynomial, $B_1(x)=x-1/2$. Apr 22, 2022 at 6:12

This can not be true: $$p(m+1)=p(m)$$ for an integer $$m$$ yields that $$\pi$$ is Algebraic.

• Can it be the case that $p = p_1 + e$ where $p_1$ is periodic and the ratio $e/p$ is small? Dec 26, 2021 at 7:46
• @OnurOktay -- yes, that is the case with $e/p={\cal O}(1/\sqrt x)$. Dec 26, 2021 at 8:10