This classic integral is solved using the symmetry property of definite integrals. By substituting x→2π−x and adding the two forms, we transform the product sinxcosx into 21sin2x, leading to a simple equation whose solution is ∫0π/2logsinxdx=−2πlog2.
The integral I=∫0π/2logsinxdx is a famous one — it appears in many contexts, from probability to number theory. The trick is not to integrate directly (the antiderivative involves the dilogarithm), but to exploit symmetry.
Why symmetry works: The interval [0,π/2] is symmetric about π/4. The function logsinx is not symmetric itself, but if we replace x by 2π−x, we get logcosx. Adding the two forms gives log(sinxcosx)=log(21sin2x), which splits into a constant term and a scaled version of the original integral. This creates an equation we can solve for I.
Let’s walk through it step by step.
- Define the integral and apply the substitution x→2π−x.
Let I=∫0π/2logsinxdx.
Substitute x=2π−t. Then dx=−dt, and when x=0, t=π/2; when x=π/2, t=0. So:
I=∫π/20logsin(2π−t)(−dt)=∫0π/2logcostdt.
Renaming the dummy variable back to x, we have:
I=∫0π/2logcosxdx.
So the integral of logsinx equals the integral of logcosx over the same interval.
- Add the two expressions for I.
2I=∫0π/2logsinxdx+∫0π/2logcosxdx=∫0π/2log(sinxcosx)dx.
Using the identity sinxcosx=21sin2x, we get:
2I=∫0π/2log(21sin2x)dx=∫0π/2(log21+logsin2x)dx.
The constant log(1/2)=−log2 factors out:
2I=−log2∫0π/21dx+∫0π/2logsin2xdx=−2πlog2+∫0π/2logsin2xdx.
- Handle the integral ∫0π/2logsin2xdx with another substitution.
Let u=2x. Then dx=du/2, and when x=0, u=0; when x=π/2, u=π. So:
∫0π/2logsin2xdx=21∫0πlogsinudu.
Now, the integral from 0 to π of logsinu can be split at π/2:
∫0πlogsinudu=∫0π/2logsinudu+∫π/2πlogsinudu. …