# Can someone find the flaw in an argument that $\int_0^{\infty}\sin x dx=1$?

Consinder the following indefinite integrals,
$$I=\int e^{-sx}\sin x dx$$ $$\displaystyle J=\int e^{-sx}\cos x dx$$ Using integration by parts on the first and second integrals we get, $$I=-e^{-sx}\cos x-sJ$$ $$J=e^{-sx}\sin x+sI$$ \begin{align*}\implies I&=-e^{-sx}\cos x-s(e^{-sx}\sin x+sI) \\\\\implies (1+s^2)I&=-e^{-sx}(\cos x+s\sin x) \\\\\implies I&=\frac{-e^{-sx}(\cos x+s\sin x)}{1+s^2}\end{align*} Therefore, \begin{align*}\int_0^{\infty} e^{-sx}\sin x dx&=\bigg[\frac{-e^{-sx}(\cos x+s\sin x)}{1+s^2}\bigg]_0^{\infty}\\&=0-\frac{-1}{1+s^2}\\&=\frac1{1+s^2}\end{align*} Substituting $$s=0$$ we get that, $$\int_0^{\infty} \sin x dx=1$$ Obviously this is not true because $$\displaystyle\int_0^{n} \sin x dx$$ oscillates between $$0$$ and $$2$$ when we increase the value of $$n$$. Can someone tell me the flaw in the above argument. Thanks in advance.

• $$\lim_{s\to0}\int_0^\infty f(s,x)dx\neq \int_0^\infty\lim_{s\to0}f(s,x)dx$$ Jul 25, 2021 at 8:57
• I agree with @NinadMunshi ... $$\int_0^{\infty} e^{-sx}\sin x dx=\frac1{1+s^2}$$ is true for $s>0$, but $\int_0^\infty \sin x dx = 1$ is false. Jul 25, 2021 at 11:57
• Next time that you post a question, please don't use titles that consists of mathematical expressions or equations only. These are discouraged for technical reasons - see the second item from Guidelines for good use of $\rm\LaTeX$ in question titles. Jul 25, 2021 at 15:33

I believe the part before evaluating $$\frac{-e^{-sx}(\cos x+s\sin x)}{1+s^2}$$ at $$\infty$$ is correct. The thing is, when $$s=0$$ this is $$-\cos x$$ which does not have a limit at $$\infty$$.
• Yeah, I double checked whether OP divided by $s$ when I saw your answer. Jul 25, 2021 at 9:00
• You mean $-\cos x$. Jul 25, 2021 at 9:38