How Do You Solve the Integral of ln|a+b*sin(x)| from 0 to 2π?

  • Context: MHB 
  • Thread starter Thread starter Saitama
  • Start date Start date
  • Tags Tags
    Integral
Click For Summary
SUMMARY

The integral $$\int_0^{2\pi} \ln|a+b\sin x|\,dx$$ for the case where $0 PREREQUISITES

  • Understanding of definite integrals and properties of logarithms
  • Familiarity with trigonometric functions and their integrals
  • Knowledge of calculus techniques, including differentiation under the integral sign
  • Experience with handling discontinuities in integrals
NEXT STEPS
  • Study the properties of logarithmic integrals, particularly in trigonometric contexts
  • Learn about the implications of discontinuities in definite integrals
  • Explore differentiation under the integral sign and its applications
  • Investigate the integral of sine and its transformations over different intervals
USEFUL FOR

Mathematicians, calculus students, and anyone interested in advanced integral evaluation techniques, particularly those involving logarithmic and trigonometric functions.

Saitama
Messages
4,244
Reaction score
93
I am trying to evaluate the following integral:
$$\int_0^{2\pi} \ln|a+b\sin x|\,dx$$
where $0<a<b$.

Source: homework - Find the value of the integral $\int_0^{2\pi}\ln|a+b\sin x|dx$ where $0\lt a\lt b$ - Mathematics Stack Exchange

Attempt:
Consider
$$I(a)=\int_0^{2\pi} \ln|a+b\sin x|\,dx$$
It can be shown that:
$$I(a)=2\int_0^{\pi/2} \ln|a^2-b^2\sin^2x|\,dx$$
Differentiate both sides wrt $a$ to get:
$$\frac{dI}{da}=4a\int_0^{\pi/2}\frac{dx}{a^2-b^2\sin^2x}$$
Next, I rewrite the denominator as:
$$a^2-b^2\sin^2x=\frac{a^2+(a^2-b^2)\tan^2x}{\sec^2x}$$
Using the substitution $\tan x=t$, I obtain the following definite integral:
$$\frac{dI}{da}=4a\int_0^{\infty} \frac{dt}{a^2+(a^2-b^2)t^2}$$
$$\Rightarrow \frac{dI}{da}=\frac{2\pi}{\sqrt{a^2-b^2}}$$
This is where I am stuck. I don't find the result correct because as per the question, $b>a$ due to which $\sqrt{a^2-b^2}$ doesn't make sense. :confused:

Any help is appreciated. Thanks!

EDIT: I thought about it some more and I think I see the error. I found an error at this step:
$$I(a)=2\int_0^{\pi/2} \ln|a^2-b^2\sin^2x|\,dx$$
I cannot simply differentiate the above because of the modulus symbol. $|a^2-b^2\sin^2x|=a^2-b^2\sin^2x$ only if $sin(x)<=a/b$, hence,
$$I(a)=2\left(\int_0^{a/b}\ln(a^2-b^2\sin^2x)\,dx+\int_{a/b}^{\pi/2} \ln(b^2\sin^2x-a^2)\,dx\right)$$
If I differentiate the above, I get:
$$\frac{dI}{da}=2\left(\int_0^{a/b}\frac{2a}{a^2-b^2\sin^2x}\,dx+\int_{a/b}^{\pi/2} \frac{-2a}{b^2\sin^2x-a^2}\,dx\right)$$
which is the same integral as before. :confused:
 
Last edited:
Physics news on Phys.org
We are given

[math] I= \int_0^{2 \pi} \ln \left \vert a+b \sin x \right \vert dx [/math].

The reason your evaluation of the integral was incorrect is because there are two discontinuities on [math] [0, 2 \pi] [/math], at [math] x= \pi + \arcsin(a/b) [/math] and [math] 2 \pi - \arcsin(a/b) [/math]. Therefore, we must split the integral at these points. Also, the absolute value of [math] a+b \sin x [/math] on [math] [0, \pi + \arcsin(a/b)] [/math] and [math] [2 \pi - \arcsin(a/b), 2 \pi] [/math] is just [math] a+b \sin x [/math], while on [math] [\pi + \arcsin(a/b), 2 \pi - \arcsin(a/b)] [/math], it is [math] -a-b \sin x [/math].
Putting these together and setting [math] \pi + \arcsin(a/b)=c [/math] and [math] 2 \pi - \arcsin(a/b)=d [/math], we have

[math] I= \int_0^{c} \ln (a+b \sin x) dx + \int_c^{d} \ln (-a-b \sin x) dx +\int_d^{2 \pi} \ln (a+b \sin x) dx [/math].

Considering I to be a function of a and differentiating under the integral sign, we have

[math] \frac{dI}{da} = \int_0^{c} \frac{1}{a+b \sin x} dx +\int_c^{d} \frac{-1}{-a- b \sin x} dx +\int_d^{2 \pi} \frac{1}{a+b \sin x} dx [/math].

Using the substitution [math] z=\tan \frac{x}{2} [/math] and completing the square, the integrand becomes

[math] \frac{2}{a} \frac{1}{(z+\frac{b}{a})^2+(1-\frac{b^2}{a^2})} [/math].

Integrating (without bounds for the moment), we have

[math] \frac{2}{\sqrt{a^2-b^2}} \arctan \frac{a \tan \frac{x}{2} +b}{\sqrt{a^2-b^2}} +C[/math].

But since [math] a < b [/math], this quantity is imaginary! All is not lost, however. We have

[math] \operatorname{arctanh} z = \frac{1}{i} \arctan iz [/math].

Using this relation, the integral becomes

[math] \frac{2}{\sqrt{b^2-a^2}} \operatorname{arctanh} \frac{a \tan \frac{x}{2} +b}{\sqrt{b^2-a^2}} +C[/math],

which is real.
Evaluating between the three sets of bounds, we have

[math] \frac{dI}{da} = \frac{2}{\sqrt{b^2-a^2}} \left ( \operatorname{arctanh} \frac{b}{\sqrt{b^2-a^2}} -\operatorname{arctanh} \frac{b}{\sqrt{b^2-a^2}} \right ) =0 [/math].

We would appear to be stuck. However, all this implies is that I is not a function of a, as we had previously assumed. Therefore, letting a approach 0 in the original integral gives

[math] I= \int_0^{2 \pi} \ln \left \vert b \sin x \right \vert dx [/math].

Splitting up the argument of the ln, and using the fact that the integral of sine on [math] [0, 2 \pi] [/math] is four times the integral on [math] [0, \frac{\pi}{2}] [/math], we have

[math] I= 2 \pi \ln b + 4 \int_0^{\frac{\pi}{2}} \ln \sin x dx [/math].

Taking [math] \sin x = 2 \sin \frac{x}{2} \cos \frac{x}{2} [/math] and splitting up the logarithmic terms, the second term becomes

[math] 2 \pi \ln 2 + 4 \int_0^{\frac{\pi}{2}} \ln \sin \frac{x}{2} dx + 4 \int_0^{\frac{\pi}{2}} \ln \cos \frac{x}{2} dx [/math].

Substituting [math] u= \frac{x}{2} [/math], the integrals become

[math] 8 \int_0^{\frac{\pi}{4}} \ln \sin u \ du + 8 \int_0^{\frac{\pi}{4}} \ln \cos u \ du [/math].

Substituting [math] u= \frac{\pi}{2} –t [/math] into the cosine integral, it becomes

[math] \int_{\frac{\pi}{4}}^{\frac{\pi}{2}} \ln \sin t \ dt [/math].

Therefore,

[math] 4 \int_0^{\frac{\pi}{2}} \ln \sin x dx= 2\pi \ln 2 + 8 \int_0^{\frac{\pi}{2}} \ln \sin x dx [/math].

Cancelling, and remembering the fact that the integral of sine over a period is equal to four times its integral over a quarter-period, we have

[math] 4 \int_0^{\frac{\pi}{2}} \ln \sin x dx=\int_0^{2 \pi} \ln \sin x dx = -2 \pi \ln 2 [/math].

Substituting into the equation for I and combining logarithmic terms, we obtain (finally)

[math] I= 2 \pi \ln \frac{b}{2} [/math].
 
Last edited:

Similar threads

  • · Replies 5 ·
Replies
5
Views
2K
  • · Replies 19 ·
Replies
19
Views
4K
  • · Replies 4 ·
Replies
4
Views
4K
  • · Replies 2 ·
Replies
2
Views
3K
  • · Replies 1 ·
Replies
1
Views
3K
  • · Replies 6 ·
Replies
6
Views
2K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 3 ·
Replies
3
Views
3K
  • · Replies 6 ·
Replies
6
Views
3K