<s>[INST] Divergence of $\lim_{N\to +\infty}[ \int_{1}^{N+1} f(x) dx -\sum_{n=1}^{N}f(n)] $ Divergence of  $\lim_{N\to +\infty}[ \int_{1}^{N+1} f(x) dx -\sum_{n=1}^{N}f(n)] $ where $f(x)= sin(log_e x)(\frac{1}{x^{a}}-\frac{1}{x^{1-a}})$,$ 0<a<1/2$
My try -
$\lim_{N\to +\infty}[ \int_{1}^{N+1} sin(log_e x)(\frac{1}{x^{a}}-\frac{1}{x^{1-a}})dx - \sum_{n=1}^{N} sin ( log _en) (\frac{1}{n^{a}}-\frac{1}{n^{1-a}})]  $ where $0<a<1/2$
Define S=$\lim_{N\to +\infty}[ \int_{1}^{N+1} sin(log_e x)(\frac{1}{x^{a}}-\frac{1}{x^{1-a}})dx - \sum_{n=1}^{N} sin ( log _en) (\frac{1}{n^{a}}-\frac{1}{n^{1-a}})]  $
If $a=1/2$ then S is convergent to 0.
If $a<1/2$ then, $(\frac{1}{x^{a}}-\frac{1}{x^{1-a}})>0$ $ \forall x\geq 1$
and $(\frac{1}{n^{a}}-\frac{1}{n^{1-a}})>0$ $ \forall n\geq 1$.
Please prove that S is divergent when $0<a<1/2$
 [/INST] *

*Integral $I(a)=\int_{1}^{N+1} \sin(\ln x)(\frac{1}{x^{a}}-\frac{1}{x^{1-a}})dx$  can be evaluated - just make a change $x=e^t$:
$I(a)=\int_{0}^{\ln(N+1)} \sin(t)(e^{-ta}-e^{(a-1)t})e^tdt=\int_{0}^{\ln(N+1)} \sin(t)(e^{t(1-a)}-e^{at})dt$  and $\sin(t)=\frac{e^{it}-e^{-it}}{2i}= \Im({e}^{it})$
Integral with exponents can be easily taken.


*Consider the integral as a sum:  $\sum_{k=1}^{N}\int_{\ln(k)}^{\ln(k+1)} \sin(t)(e^{t(1-a)}-e^{at})dt$
So, you get a series with N term as $a_N=\left(\int_{\ln(N)}^{\ln(N+1)} \sin(t)(e^{t(1-a)}-e^{at})dt-\sin(\ln{N})(\frac{1}{N^{a}}-\frac{1}{N^{1-a}})\right)$ and you can investigate its behaviour at $N\to\infty$.
Let's consider $a_N$:
After evaluating the integral we get:
$a_N=\frac{1-a}{1+(1-a)^2}[(N+1)^{1-a}\sin(\ln(N+1))-N^{1-a}\sin(\ln(N))]-\frac{1}{1+(1-a)^2}[(N+1)^{1-a}\cos(\ln(N+1))-N^{1-a}\cos(\ln(N))]-\frac{a}{1+a^2}[(N+1)^{a}\sin(\ln(N+1))-N^{a}\sin(\ln(N))]+\frac{1}{1+a^2}[(N+1)^{a}\cos(\ln(N+1))-N^{a}\cos(\ln(N))]-[\sin(\ln{N})\frac{1}{N^{a}}]+[\sin(\ln{N})\frac{1}{N^{1-a}}]$
Now, let's consider, for example
$\frac{a}{1+a^2}[(N+1)^{a}\sin(\ln(N+1))-N^{a}\sin(\ln(N))]=\frac{a}{1+a^2}[N^a(1+\frac{1}{N})^{a}\sin(\ln{N}+\ln(1+\frac{1}{N}))-N^{a}\sin(\ln(N))]$
Expanding the sine of the sum, as well as using Taylor series expansion for large N we get
$\frac{aN^a}{1+a^2}[(1+\frac{a}{N}+O(\frac{1}{N^2}))\left(\sin(\ln{N})\cos((\frac{1}{N})+O(\frac{1}{N^2}))+\cos(\ln{N})\sin((\frac{1}{N})+O(\frac{1}{N^2}))\right)-\sin(\ln(N))]=\frac{aN^a}{1+a^2}[(1+\frac{a}{N}+O(\frac{1}{N^2}))\left(\sin(\ln{N})\cos(\frac{1}{N})+O(\frac{1}{N^2})+\cos(\ln{N})\sin(\frac{1}{N})+O(\frac{1}{N^2})\right)-\sin(\ln(N))]=\frac{a}{1+a^2}N^a\left(\frac{a\sin(\ln{N})}{N}+\frac{\cos(\ln{N})}{N}+O(\frac{1}{N^2})\right)$
Finally, evaluating all terms we get
$a_N=N^{-a}\left(\frac{(1-a)^2\sin(\ln{N})}{1+(1-a)^2}+\frac{(1-a)\cos(\ln{N})}{1+(1-a)^2}-\frac{(1-a)\cos(\ln{N})}{1+(1-a)^2}+\frac{\sin(\ln{N})}{1+(1-a)^2}+O(\frac{1}{N^2})\right)+N^{a-1}\left(-\frac{a^2\sin(\ln{N})}{1+a^2}-\frac{a\cos(\ln{N})}{1+a^2}+\frac{a\cos(\ln{N})}{1+a^2}-\frac{\sin(\ln{N})}{1+a^2}+O(\frac{1}{N^2})\right)-$$-\sin(\ln{N})\frac{1}{N^{a}}+\sin(\ln{N})\frac{1}{N^{1-a}}$
After grouping all terms we see that they cancel each other, so we get
$a_N=N^{a}O(\frac{1}{N^2})+N^{1-a}O(\frac{1}{N^2})=O(\frac{1}{N^{2-a}})+O(\frac{1}{N^{1+a}})$
But these series converges absolutely $\Rightarrow$ $a_N$ converges.
Please check my calculations.
</s>