37

I need to solve $$ \int_0^{\Large\frac\pi2}\frac{\ln{(\sin x)}\ \ln{(\cos x})}{\tan x}\ dx $$

I tried to use symmetric properties of the trigonometric functions as is commonly used to compute $$ \int_0^{\Large\frac\pi2}\ln\sin x\ dx = -\frac{\pi}{2}\ln2 $$ but never succeeded. (see this for example)

Glorfindel
  • 3,955
M. M.
  • 945

5 Answers5

35

Let's start out with the substitution $ \displaystyle \ln(\sin x) = u $ and get: $$\ln(\cos x)=\frac{\ln(1-e^{2u})}{2}$$ $$\displaystyle\frac{1}{\tan x} \ dx =du$$ that further yields $$\int_0^{\pi/2}\frac{(\ln{\sin x})(\ln{\cos x})}{\tan x}dx= \frac{1}{2} \int_{-\infty}^{0} \ln(1-e^{2u}) u \ du$$

According to Taylor expansion we have $$\ln(1-e^{2u})= \sum_{k=1}^{\infty} (-1)^{2k+1} \frac{e^{2 k u}}{k}$$ then $$\frac{1}{2} \int_{-\infty}^{0} \ln(1-e^{2u}) u \ du=$$ $$\frac{1}{2} \sum_{k=1}^{\infty} \frac{(-1)^{2k+1}}{k} \int_{-\infty}^{0} u e^{2ku} \ du =$$ $$\frac{1}{2} \sum_{k=1}^{\infty} \frac{(-1)^{2k+1}}{k} \frac{-1}{4k^2} = \frac{1}{8} \sum_{k=1}^{\infty} \frac{1}{k^3}=\frac{1}{8} \zeta(3).$$

Remark: the value of $\zeta(3)\approx1.2020569$ is called Apéry's Constant - see here.

Q.E.D. (Chris)

dot dot
  • 1,582
  • 1
  • 12
  • 22
user 1591719
  • 44,216
  • 12
  • 105
  • 255
24

Let $u = \sin^2(x)$. Then $\frac{\mathrm{d}x}{\tan(x)} = \frac{\cos(x)}{\sin(x)} \mathrm{d}x = \frac{d\sin(x)}{\sin(x)} = \frac{1}{2}\frac{\mathrm{d}u}{u}$, $\ln(\sin(x)) = \frac{1}{2}\ln(u)$ and $\ln(\cos(x)) = \frac{1}{2} \ln(1-u)$: $$ \int_0^{\pi/2} \frac{\ln(\sin(x)) \ln(\cos(x))}{\tan(x)} \mathrm{d} x = \frac{1}{8} \int_0^{1} \frac{\ln u}{u} \cdot \ln(1-u) \mathrm{d} u = \left.\frac{1}{8} \frac{\mathrm{d}^2}{\mathrm{d} s \mathrm{d} t} \int_0^1 u^{s-1} (1-u)^{t-1} \mathrm{d}u \right|_{s\to 0^+,t=1} = \left.\frac{1}{8} \frac{\mathrm{d}^2}{\mathrm{d} s \mathrm{d} t} \frac{\Gamma(s) \Gamma(t)}{\Gamma(s+t)} \right|_{s\to 0^+,t=1} $$ First differentiate with respect to $t$ and substitute $t=1$: $$ \left.\frac{1}{8} \frac{\mathrm{d}}{\mathrm{d} s} \frac{\Gamma(s)}{\Gamma(s+1)}\left( \psi(1) - \psi(s+1)\right) \right|_{s\to 0^+} = \left.\frac{1}{8} \frac{\mathrm{d}}{\mathrm{d} s} \frac{\left( \psi(1) - \psi(s+1)\right) }{s} \right|_{s\to 0^+} $$ Using Taylor series expansion for the digamma function $\psi(s)$ we have: $$ \frac{\left( \psi(1) - \psi(s+1)\right) }{s} = -\zeta(2) + \zeta(3) s + \mathcal{o}(s) $$ Hence the value of the integral is: $$ \int_0^{\pi/2} \frac{\ln(\sin(x)) \ln(\cos(x))}{\tan(x)} \mathrm{d} x = \frac{1}{8} \zeta(3) $$


Alternatively you could use $$\frac{\ln(1-u)}{u} = -\sum_{k=0}^\infty \frac{u^k}{k+1}$$ and integrate term-wise: $$\int_0^1 u^k \ln(u) \mathrm{d} u \stackrel{u=\exp(-t)}{=} \int_0^\infty t \exp(-t(k+1)) \mathrm{d} t = -\frac{1}{(k+1)^2}$$ which yields the result immediately.

Sasha
  • 70,631
10

Rewrite the integral as $$ \int_0^{\Large\frac\pi2}\frac{\ln{(\sin x)}\ \ln{(\cos x})}{\tan x}\ dx=\int_0^{\Large\frac\pi2}\frac{\ln{(\sin x)}\ \ln{\sqrt{1-\sin^2 x}}}{\sin x}\cdot\cos x\ dx. $$ Set $t=\sin x\ \color{red}{\Rightarrow}\ dt=\cos x\ dx$, then we obtain \begin{align} \int_0^{\Large\frac\pi2}\frac{\ln{(\sin x)}\ \ln{(\cos x})}{\tan x}\ dx&=\frac12\int_0^1\frac{\ln t\ \ln(1-t^2)}{t}\ dt\\ &=-\frac12\int_0^1\ln t\sum_{n=1}^\infty\frac{t^{2n}}{nt}\ dt\tag1\\ &=-\frac12\sum_{n=1}^\infty\frac{1}{n}\int_0^1t^{2n-1}\ln t\ dt\\ &=\frac12\sum_{n=1}^\infty\frac{1}{n}\cdot\frac{1}{(2n)^2}\tag2\\ &=\large\color{blue}{\frac{\zeta(3)}{8}}. \end{align}


Notes :

$[1]\ \ $Use Maclaurin series for natural logarithm: $\displaystyle\ln(1-x)=-\sum_{n=1}^\infty\frac{x^n}{n}\ $ for $|x|<1$.

$[2]\ \ $$\displaystyle\int_0^1 x^\alpha \ln^n x\ dx=\frac{(-1)^n n!}{(\alpha+1)^{n+1}}\ $ for $ n=0,1,2,\cdots$

Tunk-Fey
  • 24,849
8

$\newcommand{\+}{^{\dagger}} \newcommand{\angles}[1]{\left\langle\, #1 \,\right\rangle} \newcommand{\braces}[1]{\left\lbrace\, #1 \,\right\rbrace} \newcommand{\bracks}[1]{\left\lbrack\, #1 \,\right\rbrack} \newcommand{\ceil}[1]{\,\left\lceil\, #1 \,\right\rceil\,} \newcommand{\dd}{{\rm d}} \newcommand{\down}{\downarrow} \newcommand{\ds}[1]{\displaystyle{#1}} \newcommand{\expo}[1]{\,{\rm e}^{#1}\,} \newcommand{\fermi}{\,{\rm f}} \newcommand{\floor}[1]{\,\left\lfloor #1 \right\rfloor\,} \newcommand{\half}{{1 \over 2}} \newcommand{\ic}{{\rm i}} \newcommand{\iff}{\Longleftrightarrow} \newcommand{\imp}{\Longrightarrow} \newcommand{\isdiv}{\,\left.\right\vert\,} \newcommand{\ket}[1]{\left\vert #1\right\rangle} \newcommand{\ol}[1]{\overline{#1}} \newcommand{\pars}[1]{\left(\, #1 \,\right)} \newcommand{\partiald}[3][]{\frac{\partial^{#1} #2}{\partial #3^{#1}}} \newcommand{\pp}{{\cal P}} \newcommand{\root}[2][]{\,\sqrt[#1]{\vphantom{\large A}\,#2\,}\,} \newcommand{\sech}{\,{\rm sech}} \newcommand{\sgn}{\,{\rm sgn}} \newcommand{\totald}[3][]{\frac{{\rm d}^{#1} #2}{{\rm d} #3^{#1}}} \newcommand{\ul}[1]{\underline{#1}} \newcommand{\verts}[1]{\left\vert\, #1 \,\right\vert} \newcommand{\wt}[1]{\widetilde{#1}}$

$\ds{\int_{0}^{\pi/2}{\ln\pars{\sin\pars{x}}\ln\pars{\cos\pars{x}} \over \tan\pars{x}}\,\dd x:\ {\large ?}}$

\begin{align} &\int_{0}^{\pi/2}{\ln\pars{\sin\pars{x}}\ln\pars{\cos\pars{x}}\over \tan\pars{x}}\,\dd x \,\,\,\stackrel{x\ =\ \arcsin\pars{t}}{=}\,\,\, \int_{0}^{1}{\ln\pars{t}\ln\pars{\root{1 - t^{2}}} \over t\,/\root{1 - t^{2}}}\, {\dd t \over \root{1 - t^{2}}} \\[5mm]= &\ \half\int_{0}^{1}{\ln\pars{t}\ln\pars{1 - t^{2}} \over t}\,\dd t = \half\int_{0}^{1}{\ln\pars{t^{1/2}}\ln\pars{1 - t}\over t^{1/2}}\,\half\,t^{-1/2}\,\dd t \\[5mm] = &\ {1 \over 8}\int_{0}^{1}{\ln\pars{t}\ln\pars{1 - t} \over t}\,\dd t =-\,{1 \over 8}\int_{0}^{1}{{\rm Li}_{1}\pars{t} \over t}\,\ln\pars{t}\,\dd t =-\,{1 \over 8}\int_{0}^{1}{\rm Li}_{2}'\pars{t}\ln\pars{t}\,\dd t \\[5mm]&={1 \over 8}\int_{0}^{1}{{\rm Li}_{2}\pars{t} \over t}\,\dd t ={1 \over 8}\int_{0}^{1}{\rm Li}_{3}'\pars{t}\,\dd t ={1 \over 8}\,{\rm Li}_{3}\pars{1} = \bbox[10px,border:1px dotted navy]{\ds{\zeta\pars{3}}} \approx 0.1503 \end{align}

$\ds{{\rm Li}_{\rm s}\pars{z}}$ is a PolyLogarithm Function: I used some properties of them as reported in the cited link. $\ds{\zeta\pars{s}}$ is the Riemann Zeta Function.

Felix Marin
  • 89,464
1

$$\begin{align*} I &= \int_0^{\frac\pi2} \frac{\log(\cos(x)) \log(\sin(x))}{\tan(x)} \, dx \\[1ex] &= \int_0^\infty \frac{\log\left(\frac1{\sqrt{x^2+1}}\right) \log\left(\frac x{\sqrt{x^2+1}}\right)}{x} \, \frac{dx}{1+x^2} \tag{1} \\[1ex] &= \frac14 \int_0^\infty \frac{\log^2(x^2+1)-\log(x^2)\log(x^2+1)}{x} \, \frac{dx}{1+x^2} \\[1ex] &= \frac18 \int_0^\infty \frac{\log^2(x+1)-\log(x)\log(x+1)}{x(1+x)} \, dx \tag{2} \\[1ex] &= \frac18 \int_0^1 \left(\frac{\log^2(x+1)}{x} - \frac{\log(x)\log(x+1)}x\right) \, dx \tag{3} \\[1ex] &= \frac14 \int_0^1 \frac{\log(x)\log(x+1)}x \, dx - \frac12 \int_0^1 \frac{\log(x+1)\log(x)}{x+1} \, dx \tag{4} \\[1ex] &= -\frac14 \sum_{n=1}^\infty \frac{(-1)^n}n \int_0^1 x^{n-1} \log(x) \, dx + \frac12 \sum_{n=1}^\infty (-1)^n H_n \int_0^1 x^n \log(x) \, dx \tag{5} \\[1ex] &= -\frac14 \sum_{n=1}^\infty \frac{(-1)^n}{n^3} + \frac12 \sum_{n=1}^\infty \frac{(-1)^n H_n}{(n+1)^2} \tag{4} \\[1ex] &= \boxed{\frac{\zeta(3)}8} \tag{6} \end{align*}$$


  • $(1)$ : substitute $x\mapsto\arctan(x)$
  • $(2)$ : substitute $x\mapsto\sqrt x$
  • $(3)$ : split up the integral at $x=1$; substitute $x\mapsto\frac1x$ in the integral over $[1,\infty)$; partial fractions
  • $(4)$ : integrate by parts
  • $(5)$ : recall the power series $-\log(1-x)=\sum\limits_{n\ge1}\frac{x^n}n$ and $-\frac{\log(1-x)}{1-x}=\sum\limits_{n\ge1} H_n x^n$, where $H_n$ is the $n^{\rm th}$ harmonic number
  • $(6)$ : see e.g. section $7$ for a contour-integration method to evaluating the Euler sum; I'm sure there are more efficient means
user170231
  • 19,334