I am studying the following integral with parameter $$E^\varepsilon(t) = \int_{-T}^{t - \lambda_\varepsilon(t)^2} \frac{1}{|\ln(T - s)|^2(t - s)}ds, \quad \text{for } t \in [-T/4, T].$$ $T$ and $\varepsilon$ are constants that can be chosen arbitrarily small such that $\varepsilon \ll T$, and $\lambda_\varepsilon$ is defined as $$\lambda_\varepsilon(t) = \sqrt{\left(\frac{T - t}{|\ln(T - t)|^2}\right)^2 + \left(\frac{\varepsilon}{|\ln(\varepsilon)|^2}\right)^2}.$$ I would like to study the behaviour of this function $E^\varepsilon (t).$ To achieve this, I subtracted $E^\varepsilon (T)$ and tried to bound the quantity $|E^\varepsilon (t) - E^\varepsilon (T)|$ by a function I knew. Note that at $t = T$, the integral can be computed such that $$E^\varepsilon (T) = \frac{1}{|\ln(2T)|} - \frac{1}{|\ln\left(\lambda_\varepsilon(T)^2\right)|}.$$ So far I managed to prove the following bound \begin{equation*} |E^\varepsilon (t) - E^\varepsilon(T)| \le C \begin{cases} \frac{\log|\log (T - t)|}{|\log (T - t)|^2} & \text{for } (T -t) > \varepsilon,\\ \frac{1}{|\log \varepsilon|} & \text{for } (T -t) < \varepsilon. \end{cases} \end{equation*} The splitting of the two time regimes comes from the fact that I considered two different cases: the time for which $(T - t)/|\ln(T - t)|^2$ is dominating in $\lambda_\varepsilon(t)$ and the time for which $\varepsilon/|\log \varepsilon|^2$ is dominating.
However, the regime close to $t = T$, i.e. $(T - t) < \varepsilon$, is not really satisfying. Indeed, the "order" of decay is smaller in the sense that away from $t = T$ it behaves roughly like a $\log^{-2}$ and after like a $\log^{-1}$. Moreover, this $|E^\varepsilon (t) - E^\varepsilon(T)|$ vanishes at $t = T$ so it is reasonable to think that this bound can be improve. I tried an insane amount of things to slightly improve this bound close to $t = T$ but I couldn't manage to find anything, I am kind of desperate. Therefore, if any of you has an idea of a beginning of anything, I would be the really grateful. Even a slight improvement like $1/|\ln \varepsilon|^{1 + \delta}$, for some $\delta \ll 1$ would make me happy.
I put the most important results in block quote. Let $f$ be a $\mathcal{C}^1$ function defined on an open neighborhood of some square $[a,b]^2$. Then,
Claim : $\displaystyle A(t) = \int_a^t f(t,s) \, ds$ verifies, $$ A(t) = A(b) + (t - b)\left(\int_a^b \partial_tf(b,s) \, ds + f(b,b)\right) + \mathrm{o}(t - b), $$ when $t \rightarrow b$.
Notice that it is equivalent to saying that $A$ is derivable at $t = b$ and $\displaystyle A'(b) = \int_a^b \partial_tf(b,s) \, ds - f(b,b)$. Indeed, \begin{align*} \frac{A(t) - A(b)}{t - b} & = \frac{1}{t - b}\left(\int_a^t f(t,s) \, ds - \int_a^b f(b,s) \, ds\right)\\ & = \frac{1}{t - b}\int_a^b f(t,s) - f(b,s) \, ds + \frac{1}{t - b}\int_b^t f(t,s) \, ds\\ & = \frac{1}{t - b}\int_a^b f(t,s) - f(b,s) \, ds + \frac{1}{t - b}\int_b^t f(b,s) \, ds\\ & \ \ \ \ + \frac{1}{t - b}\int_b^t f(t,s) - f(b,s) \, ds \end{align*} By the theorem of derivation under the integral, the first term converges toward $\displaystyle \partial_t|_{t = b}\int_a^b f(t,s) \, ds = \int_a^b \partial_tf(b,s) \, ds$, the second term converges, by the fundamental theorem of analysis toward $f(b,b)$ and the third term is bounded in absolute value by $K|t - b|$ where $K$ is a Lipschitz constant for $f$ (like the $\sup$ of the absolute value of its derivative on $[a,b]^2$), thus it converges toward $0$. We deduce the wanted result.
Now, let $g$ be a function defined in a neighborhood of a point $c$ such that $g(c) = b$ and $g$ is derivable at $c$. In particular, for $t$ close to $c$, $g(t)$ is close to $b$ thus $\displaystyle B(t) = \int_a^{g(t)} f(t,s) \, ds$ is well defined in a neighborhood of $c$.
Claim : $B$ verifies, $$ B(t) = B(c) + (t - c)\left(\int_a^b \partial_tf(c,s) \, ds + g'(c)f(c,b)\right) + \mathrm{o}(t - c) $$ Indeed, as $g$ is derivable at $c$, we have $g(t) = g(c) + g'(c)(t - c) + \epsilon(t - c) = b + g'(c)(t - c) + \epsilon(t - c)$ where $\epsilon(x) = \mathrm{o}(x)$ when $x \rightarrow 0$. We deduce that, if $g'(c) \neq 0$, \begin{align*} B(t) & = \int_a^{g(t)} f(t,s) \, ds\\ & = \int_a^{b + g'(c)(t - c) + \epsilon(t - c)} f(t,s) \, ds\\ & = \int_a^{b + g'(c)(t - c)} f(t,s) \, ds + \int_{b + g'(c)(t - c)}^{b + g'(c)(t - c) + \epsilon(t - c)} f(t,s) \, ds. \end{align*} The second integral is bounded in absolute value by $M|\epsilon(t - c)|$ where $M$ is a bound for $f$ (like the $\sup$ of the absolute value of $f$ on $[a,b]^2$), thus it is a $\mathrm{o}(t - c)$. The first integral is, \begin{align*} \int_a^{b + g'(c)(t - c)} f(t,s) \, ds & = \int_{c + \frac{a - b}{g'(c)}}^t f(t,b + g'(c)(x - c)) \, g'(c)dx \textrm{ with } s = b + g'(c)(x - c),\\ & = (t - c)\left(\int_{c + \frac{a - b}{g'(c)}}^c \partial_tf(c,b + g'(c)(x - c))g'(c) \, dx + f(c,b)g'(c)\right)\\ & \ \ \ \ + \int_{c + \frac{a - b}{g'(c)}}^c f(c,b + g'(c)(x - c))g'(c) \, dx + \mathrm{o}(t - c)\textrm{ by the first claim},\\ & = B(c) + (t - c)\left(\int_a^b \partial_tf(c,s) \, ds + g'(c)f(c,b)\right) + \mathrm{o}(t - c) \end{align*} It proves the wanted result. It obviously remains true even if $g'(c) = 0$, the computation is the same but we don't need the change of variables.
Apply the second claim with $a = -T$, $c = T$, $g : t \mapsto t - \lambda_\epsilon(t)^2$, $b = g(c) = T - \lambda_\varepsilon(T)^2 = T - \left(\frac{\varepsilon}{\ln(\varepsilon)^2}\right)^2$ and $f : t,s \mapsto \frac{1}{\ln(T - s)^2(t - s)}$ which is well defined and $\mathcal{C}^1$ when $s \leqslant t - \lambda_\varepsilon(t) \leqslant t - \left(\frac{\varepsilon}{\ln(\varepsilon)^2}\right)^2 \leqslant T - \left(\frac{\varepsilon}{\ln(\varepsilon)^2}\right)^2$. We have, when $t \rightarrow T$, $$ g(t) = t - \left(\frac{T - t}{\ln(T - t)^2}\right)^2 - \left(\frac{\varepsilon}{\ln(\varepsilon)^2}\right)^2 = g(T) + t - T + \mathrm{o}(t - T), $$ thus $g'(T) = 1$ so by the second claim,
where $C(T,\varepsilon) = A + B$ with, $$ A = \int_{-T}^{T - \left(\frac{\varepsilon}{\ln(\varepsilon)^2}\right)^2} \partial_t|_{t = T}\frac{1}{\ln(T - s)^2(t - s)} \, ds $$ and, $$ B = \frac{1}{\ln\left(T - T + \left(\frac{\varepsilon}{\ln(\varepsilon)^2}\right)^2\right)^2\left(T - T + \left(\frac{\varepsilon}{\ln(\varepsilon)^2}\right)^2\right)} = \frac{1}{4\ln\left(\frac{\varepsilon}{\ln(\varepsilon)^2}\right)^2}\left(\frac{\ln(\varepsilon)^2}{\varepsilon}\right)^2. $$ We have, $$ \partial_t|_{t = T}\frac{1}{\ln(T - s)^2(t - s)} = -\frac{1}{\ln(T - s)^2(T - s)^2}, $$ thus, \begin{align*} A & = -\int_{-T}^{T - \left(\frac{\varepsilon}{\ln(\varepsilon)^2}\right)^2} \frac{1}{\ln(T - s)^2(T - s)^2}\, ds\\ & = -\int_{2T}^{\left(\frac{\varepsilon}{\ln(\varepsilon)^2}\right)^2} \frac{1}{\ln(x)^2x^2}\, (-1)dx\\ & = -\int_{\left(\frac{\varepsilon}{\ln(\varepsilon)^2}\right)^2}^{2T} \frac{1}{\ln(x)^2x^2}\, dx\\ & = \left[\mathrm{Ei}(-\ln(x)) + \frac{x}{\ln(x)}\right]_{\left(\frac{\varepsilon}{\ln(\varepsilon)^2}\right)^2}^{2T} \textrm{ obtained with Wolfram alpha},\\ & = \mathrm{Ei}(-\ln(2T)) + \frac{2T}{\ln(2T)} - \mathrm{Ei}\left(-2\ln\left(\frac{\varepsilon}{\ln(\varepsilon)^2}\right)\right) - \frac{1}{2\ln\left(\frac{\varepsilon}{\ln(\varepsilon)^2}\right)}\left(\frac{\varepsilon}{\ln(\varepsilon)^2}\right)^2. \end{align*} Notice that if you assume $\varepsilon$ and $T$ small enough, all the terms in the $\mathrm{Ei}$ are positive. Finally,
If we set $\alpha = 2\ln\left(\frac{\ln(\varepsilon)^2}{\varepsilon}\right)$, we have $\alpha \sim 2\ln\left(\frac{1}{\varepsilon}\right) \rightarrow +\infty$ when $\varepsilon \rightarrow 0$ and we can rewrite,
And when $T$ is fixed and $\varepsilon \rightarrow 0$, \begin{align*} C(T,\varepsilon) & = -\mathrm{Ei}(\alpha) + \frac{e^\alpha}{\alpha^2} + \mathrm{O}(1)\\ & = -\frac{e^\alpha}{\alpha} - \frac{e^\alpha}{\alpha^2} + \mathrm{O}\left(\frac{e^\alpha}{\alpha^3}\right) + \frac{e^\alpha}{\alpha^2} + \mathrm{O}(1)\\ & = -\frac{e^\alpha}{\alpha} + \mathrm{O}\left(\frac{e^\alpha}{\alpha^3}\right)\\ & \sim -\frac{e^{\alpha}}{\alpha}\\ & = -\frac{1}{2\ln\left(\frac{\ln(\varepsilon)^2}{\varepsilon}\right)}\left(\frac{\ln(\varepsilon)^2}{\varepsilon}\right)^2\\ & \sim -\frac{|\ln(\varepsilon)|^3}{2\varepsilon^2}. \end{align*} We have,
The difficulty here is that $E_\varepsilon(t) - E_\varepsilon(T) = C(T,\varepsilon)(t - T) + \mathrm{o}(t - T) \rightarrow 0$ when $t \rightarrow T$, $T$ and $\varepsilon$ fixed. However, when $\varepsilon$ gets close to $0$, $C(T,\varepsilon) \rightarrow -\infty$, $T$ fixed, which makes the task of finding universal bounds hard. By the way, there are a lot of computation and I maight have done mistakes, don't hesitate to verify everything.