\(\int \log (\cos (x)) \sin (x) \, dx\) [188]

   Optimal result
   Rubi [A] (verified)
   Mathematica [A] (verified)
   Maple [A] (verified)
   Fricas [A] (verification not implemented)
   Sympy [A] (verification not implemented)
   Maxima [A] (verification not implemented)
   Giac [A] (verification not implemented)
   Mupad [B] (verification not implemented)

Optimal result

Integrand size = 6, antiderivative size = 10 \[ \int \log (\cos (x)) \sin (x) \, dx=\cos (x)-\cos (x) \log (\cos (x)) \]

[Out]

cos(x)-cos(x)*ln(cos(x))

Rubi [A] (verified)

Time = 0.01 (sec) , antiderivative size = 10, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.333, Rules used = {2718, 2634} \[ \int \log (\cos (x)) \sin (x) \, dx=\cos (x)-\cos (x) \log (\cos (x)) \]

[In]

Int[Log[Cos[x]]*Sin[x],x]

[Out]

Cos[x] - Cos[x]*Log[Cos[x]]

Rule 2634

Int[Log[u_]*(v_), x_Symbol] :> With[{w = IntHide[v, x]}, Dist[Log[u], w, x] - Int[SimplifyIntegrand[w*(D[u, x]
/u), x], x] /; InverseFunctionFreeQ[w, x]] /; InverseFunctionFreeQ[u, x]

Rule 2718

Int[sin[(c_.) + (d_.)*(x_)], x_Symbol] :> Simp[-Cos[c + d*x]/d, x] /; FreeQ[{c, d}, x]

Rubi steps \begin{align*} \text {integral}& = -\cos (x) \log (\cos (x))-\int \sin (x) \, dx \\ & = \cos (x)-\cos (x) \log (\cos (x)) \\ \end{align*}

Mathematica [A] (verified)

Time = 0.01 (sec) , antiderivative size = 10, normalized size of antiderivative = 1.00 \[ \int \log (\cos (x)) \sin (x) \, dx=\cos (x)-\cos (x) \log (\cos (x)) \]

[In]

Integrate[Log[Cos[x]]*Sin[x],x]

[Out]

Cos[x] - Cos[x]*Log[Cos[x]]

Maple [A] (verified)

Time = 0.60 (sec) , antiderivative size = 11, normalized size of antiderivative = 1.10

method result size
derivativedivides \(\cos \left (x \right )-\cos \left (x \right ) \ln \left (\cos \left (x \right )\right )\) \(11\)
default \(\cos \left (x \right )-\cos \left (x \right ) \ln \left (\cos \left (x \right )\right )\) \(11\)
parallelrisch \(-\cos \left (x \right ) \ln \left (\cos \left (x \right )\right )+\cos \left (x \right )+1\) \(12\)
norman \(\frac {\left (\tan ^{2}\left (\frac {x}{2}\right )\right ) \ln \left (\frac {1-\left (\tan ^{2}\left (\frac {x}{2}\right )\right )}{1+\tan ^{2}\left (\frac {x}{2}\right )}\right )-\ln \left (\frac {1-\left (\tan ^{2}\left (\frac {x}{2}\right )\right )}{1+\tan ^{2}\left (\frac {x}{2}\right )}\right )+2}{1+\tan ^{2}\left (\frac {x}{2}\right )}\) \(67\)
risch \(\ln \left ({\mathrm e}^{i x}\right ) \cos \left (x \right )+\frac {i {\mathrm e}^{i x} \operatorname {csgn}\left (i+i {\mathrm e}^{2 i x}\right ) \pi \,\operatorname {csgn}\left (i {\mathrm e}^{-i x}\right ) \operatorname {csgn}\left (i \cos \left (x \right )\right )}{4}-\frac {i {\mathrm e}^{i x} \operatorname {csgn}\left (i+i {\mathrm e}^{2 i x}\right ) \pi \operatorname {csgn}\left (i \cos \left (x \right )\right )^{2}}{4}-\frac {i {\mathrm e}^{i x} \pi \,\operatorname {csgn}\left (i {\mathrm e}^{-i x}\right ) \operatorname {csgn}\left (i \cos \left (x \right )\right )^{2}}{4}+\frac {i {\mathrm e}^{i x} \pi \operatorname {csgn}\left (i \cos \left (x \right )\right )^{3}}{4}+\frac {i \operatorname {csgn}\left (i+i {\mathrm e}^{2 i x}\right ) {\mathrm e}^{-i x} \pi \,\operatorname {csgn}\left (i {\mathrm e}^{-i x}\right ) \operatorname {csgn}\left (i \cos \left (x \right )\right )}{4}-\frac {i \operatorname {csgn}\left (i+i {\mathrm e}^{2 i x}\right ) {\mathrm e}^{-i x} \pi \operatorname {csgn}\left (i \cos \left (x \right )\right )^{2}}{4}-\frac {i {\mathrm e}^{-i x} \pi \,\operatorname {csgn}\left (i {\mathrm e}^{-i x}\right ) \operatorname {csgn}\left (i \cos \left (x \right )\right )^{2}}{4}+\frac {i {\mathrm e}^{-i x} \pi \operatorname {csgn}\left (i \cos \left (x \right )\right )^{3}}{4}-\frac {{\mathrm e}^{i x} \ln \left (1+{\mathrm e}^{2 i x}\right )}{2}+\frac {{\mathrm e}^{i x} \ln \left (2\right )}{2}-\frac {{\mathrm e}^{-i x} \ln \left (1+{\mathrm e}^{2 i x}\right )}{2}+\frac {{\mathrm e}^{-i x} \ln \left (2\right )}{2}+\frac {{\mathrm e}^{i x}}{2}+\frac {{\mathrm e}^{-i x}}{2}\) \(289\)

[In]

int(ln(cos(x))*sin(x),x,method=_RETURNVERBOSE)

[Out]

cos(x)-cos(x)*ln(cos(x))

Fricas [A] (verification not implemented)

none

Time = 0.28 (sec) , antiderivative size = 10, normalized size of antiderivative = 1.00 \[ \int \log (\cos (x)) \sin (x) \, dx=-\cos \left (x\right ) \log \left (\cos \left (x\right )\right ) + \cos \left (x\right ) \]

[In]

integrate(log(cos(x))*sin(x),x, algorithm="fricas")

[Out]

-cos(x)*log(cos(x)) + cos(x)

Sympy [A] (verification not implemented)

Time = 0.19 (sec) , antiderivative size = 10, normalized size of antiderivative = 1.00 \[ \int \log (\cos (x)) \sin (x) \, dx=- \log {\left (\cos {\left (x \right )} \right )} \cos {\left (x \right )} + \cos {\left (x \right )} \]

[In]

integrate(ln(cos(x))*sin(x),x)

[Out]

-log(cos(x))*cos(x) + cos(x)

Maxima [A] (verification not implemented)

none

Time = 0.19 (sec) , antiderivative size = 10, normalized size of antiderivative = 1.00 \[ \int \log (\cos (x)) \sin (x) \, dx=-\cos \left (x\right ) \log \left (\cos \left (x\right )\right ) + \cos \left (x\right ) \]

[In]

integrate(log(cos(x))*sin(x),x, algorithm="maxima")

[Out]

-cos(x)*log(cos(x)) + cos(x)

Giac [A] (verification not implemented)

none

Time = 0.31 (sec) , antiderivative size = 10, normalized size of antiderivative = 1.00 \[ \int \log (\cos (x)) \sin (x) \, dx=-\cos \left (x\right ) \log \left (\cos \left (x\right )\right ) + \cos \left (x\right ) \]

[In]

integrate(log(cos(x))*sin(x),x, algorithm="giac")

[Out]

-cos(x)*log(cos(x)) + cos(x)

Mupad [B] (verification not implemented)

Time = 1.65 (sec) , antiderivative size = 9, normalized size of antiderivative = 0.90 \[ \int \log (\cos (x)) \sin (x) \, dx=-\cos \left (x\right )\,\left (\ln \left (\cos \left (x\right )\right )-1\right ) \]

[In]

int(log(cos(x))*sin(x),x)

[Out]

-cos(x)*(log(cos(x)) - 1)