# Bounding an intriguing integral from above

I would like to show that the following function of the positive integers k and N does not grow to infinity with k, at least for some values of N. $$F(k,N) = \int_1^{k^2} e^{\log (N/k) \sqrt x } e^{ x/k } \textrm{d}x$$ In other words, my goal is to find $$N \in \mathbb{N}_{>0}$$ and $$M < \infty$$ such that $$f(k,N) < M$$ for every $$k$$. How could I upper bound the integral efficiently? In the ideal case such a finite upper bound on $$F(k,N)$$ (uniform in $$k$$) will not grow faster than linearly with $$N$$...

• Is $\log$ specifically the natural logarithm $\ln$ or any arbitrary logarithm of any base? Jul 29, 2021 at 9:59
• Natural logarithm. However it does not make much difference... Jul 29, 2021 at 12:03
• What have you tried for deriving an upper bound? What's the context of this integral? Please take a look at Enforcement of Quality Standards.
– Ѕааԁ
Jul 29, 2021 at 13:42

This is more of a supplement to Gary's answer, with the goal of avoiding the use of special functions.

There are two distinct behaviours depending on the size of $$\log(N/k)$$. Setting $$m = \log(N/k)$$, we have an integral of the form $$\int_1^{k^2} e^{\frac{x +mk \sqrt{x}}{k}}.$$ Now notice that $$(x +mk\sqrt{x}) < 0 \iff \sqrt{x} < -mk \iff x < m^2 k^2.$$ So, in particular, if $$m <- 1,$$ then the integrand is upper bounded by $$\int_1^{k^2} e^{(m+1)\sqrt{x} }\mathrm{d}x \le \int_0^\infty e^{(m+1)\sqrt{x}} \mathrm{d}x = \int_0^\infty \frac{2t}{(m+1)^2} e^{-t} \mathrm{d}t = \frac{2}{(m+1)^2},$$ where I've used that $$\int _0^\infty te^{-t} = 1.$$

If, on the other hand, $$m > -1,$$ then notice that the integrand is maximised near $$k^2$$, and grows quite large around there. This sets up the calculation $$\int_1^{k^2} e^{\frac{x + mk\sqrt{x}}{k}} = \int_{1/k}^1 2k^2 t e^{k(t^2 +mt)} \le \int_0^1 2k^2 t e^{k(t^2 + mt)} \le e^{k(1+m)} \int_0^12k^2t = k^2 e^{k(1+m)}.$$

I'll note that for fixed $$N/k$$, the growth rate $$k^2 e^{k(1+m)}$$ is correct up to a factor of $$k$$. For a lower bound (for $$k\ge 4$$), observe that the slope of $$t^2 + mt$$ over $$(0,1)$$ is at most $$2 + m$$, and thus in $$(1-1/k, 1),$$ $$t^2 + mt \ge 1 - (2+m)/k,$$ giving $$\int_{1/k}^1 2k^2 t e^{k(t^2 + mt)} \ge \int_{1 - 1/k}^1 2k^2 te^{k(t^2 + mt)} \ge \frac{2}{4e^{2}} ke^{-m} e^{k(1+m)} = \frac{k}{2e^2 (N/k)} e^{k(1+m)}$$

This quite clearly shows that $$f(k,N)$$ has a phase transition around the line $$N/k = 1/e$$ as $$k$$ grows large.

• This is a much simpler approach! (+1)
– Gary
Jul 30, 2021 at 11:25

Let $$m=\log(N/k)$$ and assume $$k \gg N$$. Then \begin{align*} 0 & < \int_1^{k^2 } {\exp \left( {x/k + \sqrt x \log (N/k)} \right)dx} \\ & = 2k^2 \int_{1/k}^1 {\exp \left( {k\left[ {t^2 + tm} \right]} \right)tdt} \\ & \le 2k^2 \int_0^1 {\exp \left( {k\left[ {t^2 + tm} \right]} \right)tdt} \\ & = \frac{{\sqrt \pi }}{2}\left| m \right|e^{ - km^2 /4} k^{3/2} \left( {\operatorname{erfi}\left( {\frac{{\left| m \right|}}{2}\sqrt k } \right) - \operatorname{erfi}\left( {\frac{{\left| m \right| - 2}}{2}\sqrt k } \right)} \right) - k + ke^{ - k(\left| m \right| - 1)} \\ & < \frac{{\sqrt \pi }}{2}\left| m \right|e^{ - km^2 /4} k^{3/2} \operatorname{erfi}\left( {\sqrt k \frac{{\left| m \right|}}{2}} \right) - k + ke^{ - k(\left| m \right| - 1)} \\ & \sim \frac{2}{{m^2 }} + ke^{ - k(\left| m \right| - 1)} \sim \frac{2}{{m^2 }} \end{align*} for large $$k$$. Here I used the following two-term asymptotics of the imaginary error function: $$\operatorname{erfi}(z) \sim \frac{{e^{z^2 } }}{{\sqrt \pi }}\left( {\frac{1}{z} + \frac{1}{{2z^3 }}} \right),\quad z\to +\infty.$$ For small values of $$k$$ the integral is clearly bounded and for large values of $$k$$ it even tends to zero.

From an algebraic point of view.

We have the antiderivative $$I=\int e^{a \sqrt{x}+\frac{x}{k}}\,dx$$ $$I=k e^{a+\frac{1}{k}} \left(a \sqrt{k} F\left(\frac{a k+2}{2 \sqrt{k}}\right)-1\right)-k e^{(a+1) k} \left(a \sqrt{k} F\left(\frac{(a+2) \sqrt{k}}{2} \right)-1\right)$$ where appears Dawson integral function.

Then, the analytical expression of $$f(n,k)$$is

$$\color{blue}{f(n,k)=e^{\frac{1}{k}} n \left(\sqrt{k} \log \left(\frac{n}{k}\right) F\left(\frac{k \log \left(\frac{n}{k}\right)+2}{2 \sqrt{k}}\right)-1\right)-}$$ $$\color{blue}{e^k k \left(\frac{n}{k}\right)^k \left(\sqrt{k} \log \left(\frac{n}{k}\right) F\left(\frac{1}{2} \sqrt{k} \left(\log \left(\frac{n}{k}\right)+2\right)\right)-1\right)}$$ Considering $$k$$ as a continuous variable, the maximum of $$f(n,k)$$ is attained at $$k\sim n+\frac32$$ which makes that we can compute exactly the maximum value of the function. The only problem is that the formulae are quite nasty.

What is pleasant is that $$f(n,n)=\left(e^n-e^{\frac{1}{n}}\right) n$$ and, numerically, $$\frac{f\left(n,n+\frac{3}{2}\right)}{f(n,n)} \sim 1+\frac 1{n}$$

If $$k$$ is an integer, it has been verified that the maximum value of the function happens for $$k=n+1$$ as soon as $$n \geq 3$$.

So, the maximum value of the function is $$f(n,n+1)$$ and a rather good approximation is, for $$n \geq 10$$, $$f(n,n+1)\sim e^{n+1}\, n^{n+1} \,(n+1)^{-n}$$