# Why the substitution is not working even though its bijective?

The following integral i was trying to evaluate: $$\int_0^\infty \left( \sin(1/x) - \frac{\sin(\pi/x)}{\pi} \right) \,dx.$$ ,what i did was substituting pi/x = 1/t in the second integral , which converts to first integral which tells integral is zero ,but answer is ln(pi) , whats the fault that i wanted to know .

• "which converts to first integral which tells integral is zero". You can't do that. You need to perform the u-sub on BOTH integrals and not just one and then "combine" the results.Check DESMOS to plot both functions Mar 15 at 0:16

It sounds like what you did was to write $$\int_0^\infty \left( \sin(1/x) - \frac{\sin(\pi/x)}{\pi} \right) \,dx = \int_0^\infty \sin(1/x)\, dx - \int_0^\infty \frac{\sin(\pi/x)}{\pi} \,dx$$ You then made a $$u$$-substitution on the second term $$u = x/\pi$$, in which case the integrals are the same and "should" cancel.

The problem is that both of these improper integrals are divergent. Technically what we have here is $$\lim_{R \to \infty} \left[\int_0^R \sin(1/x)\, dx - \int_0^R \frac{\sin(\pi/x)}{\pi} \,dx \right]$$ but since both integrals approach $$\infty$$, this is a limit of the form $$\infty - \infty$$ and is not necessarily zero.

If we do the $$u$$-substitution for the proper integrals, it becomes instead $$\lim_{R \to \infty} \left[ \int_0^R \sin(1/x)\, dx - \int_0^{R/\pi} \sin(1/u) \,du \right] = \lim_{R \to \infty} \int_{R/\pi}^R \sin(1/x) \, dx$$ which is more amenable to limit-taking. (In particular, you might try substituting $$w = 1/x$$ at this point.)

• I got the pt of infinity - infinity form Sir , but dont we need to consider the R as R tends to 0 , bc thats we dont know in both integrals bc both tends to infinity- infinity ,if R tends to infinity we know its exactly 0-0 isnt ? [ The value at those R , i am referring ] Mar 15 at 0:02
• @WizardMath: I'm not sure I entirely understand what you're asking. But my point in the above is that the proper integrals in Eq. (1) above are not the same, and that both of them tend to infinity individually as $R \to \infty$. Mar 15 at 0:16
• Concerning your question about the lower bounds: I suppose you're right that technically we need to be taking a limit as both the upper bound goes to infinity and the lower bound goes to zero. I'm actually not sure how to argue that the limit of the lower bounds goes to zero; I'll have to think about that further. Concerning how to do the integral once you've substituted with $w$: I would expand the integrand in a Taylor series and integrate it, but I'm a physicist and that technique might not be rigorous enough for a "real" math class. Mar 15 at 2:45
• @WizardMath: $\sin(1/x)$ is different from $1/x$ in a fundamental way. It is bounded near $0$. The improper integrals are used when integrand is unbounded or interval of integration is unbounded. Mar 16 at 5:06
• @WizardMath: I don't want to write a separate answer which is based on this. Consider the last integral at end of this answer and write it as $\int_{r/\pi} ^{r} (\sin(1/x)-(1/x))\,dx+\int_{r/\pi}^r(1/x)\,dx$. The second integral is $\log\pi$ and first one tends to $0$. Why? Because using mean value theorem you can write it as $(r-(r/\pi))(\sin(1/c)-(1/c))$ where $r/\pi<c<r$. When $r\to\infty$ this tends to $0$. Mar 16 at 5:12

Integrate by parts to get $$-x\dfrac{\sin\left(\frac{{\pi}}{x}\right)}{{\pi}}+x\sin\left(\dfrac{1}{x}\right)+\operatorname{Ci}\left(\dfrac{{\pi}}{x}\right)-\operatorname{Ci}\left(\dfrac{1}{x}\right)$$

$$(1).$$ As $$x\to \infty,$$ the first two terms combine to give $$-1+1=0.$$ As $$x\to 0,$$ all four terms tend to $$0$$. Now,

$$\operatorname {Ci} (x)=-\int _x^\infty \frac {\cos t}{t}}dt$$ so $$\operatorname {Ci} (\pi/x)=-\int _{\pi/x}^\infty \frac {\cos t}{t}}dt$$ and $$\displaystyle\operatorname {Ci} (1/x)=-\int _{1/x}^\infty \frac{ \cos t}{t}dt$$

and therefore

$$(2).\ \operatorname{Ci}\left(\dfrac{{\pi}}{x}\right)-\operatorname{Ci}\left(\dfrac{1}{x}\right) = \displaystyle \int _{1/x}^{\pi/x} \frac {\cos t}{t}dt=\int _{1/x}^{\pi/x}\left(\frac{1}{t}-\frac{t}{2}+O(t³)\right)dt=$$

$$\ln(\pi/x)-\ln(1/x)+O(1/x^2)=\ln \pi+O(1/x^2)$$

To finish, let $$x\to \infty$$ in $$(2)$$ and combine the result with $$(1).$$

• Wow this is really nice Sir , one thing i wanna ask how about doing it with feynman techinique , is it possible if we take that pi in the sin term in second integral as a variable a ? @Matematleta Mar 15 at 3:47
• The Feynman teaching method? I am not sure what you mean. If you let a vary, then you get a function $a\to \ln a$ Mar 15 at 18:21
• I meant feynman techinque of differentiation under integral sign ,then integrate it back . Yeah can u share how u got answer as lna @Matematleta Sir Mar 16 at 0:08
• Switching the operations is valid because the McLaurin series for $\cos t/t$ is unifomly convergent on $[1/x, \pi/x]$ Mar 16 at 0:59
• Wym by "switching the operations " Sir , arent we differentiating it ? Mar 16 at 4:25