Optimal. Leaf size=9 \[ \log (\cos (x))-\log (\sin (x)) \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.028245, antiderivative size = 9, normalized size of antiderivative = 1., number of steps used = 5, number of rules used = 5, integrand size = 14, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.357, Rules used = {4334, 266, 36, 31, 29} \[ \log (\cos (x))-\log (\sin (x)) \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 4334
Rule 266
Rule 36
Rule 31
Rule 29
Rubi steps
\begin{align*} \int \frac{\cos (x)}{-\sin (x)+\sin ^3(x)} \, dx &=\operatorname{Subst}\left (\int \frac{1}{x \left (-1+x^2\right )} \, dx,x,\sin (x)\right )\\ &=\frac{1}{2} \operatorname{Subst}\left (\int \frac{1}{(-1+x) x} \, dx,x,\sin ^2(x)\right )\\ &=\frac{1}{2} \operatorname{Subst}\left (\int \frac{1}{-1+x} \, dx,x,\sin ^2(x)\right )-\frac{1}{2} \operatorname{Subst}\left (\int \frac{1}{x} \, dx,x,\sin ^2(x)\right )\\ &=\log (\cos (x))-\log (\sin (x))\\ \end{align*}
Mathematica [A] time = 0.0049069, size = 9, normalized size = 1. \[ \log (\cos (x))-\log (\sin (x)) \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] time = 0.02, size = 21, normalized size = 2.3 \begin{align*} -\ln \left ( \sin \left ( x \right ) \right ) +{\frac{\ln \left ( 1+\sin \left ( x \right ) \right ) }{2}}+{\frac{\ln \left ( \sin \left ( x \right ) -1 \right ) }{2}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [B] time = 0.969199, size = 27, normalized size = 3. \begin{align*} \frac{1}{2} \, \log \left (\sin \left (x\right ) + 1\right ) + \frac{1}{2} \, \log \left (\sin \left (x\right ) - 1\right ) - \log \left (\sin \left (x\right )\right ) \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] time = 2.12816, size = 68, normalized size = 7.56 \begin{align*} \frac{1}{2} \, \log \left (\cos \left (x\right )^{2}\right ) - \frac{1}{2} \, \log \left (-\frac{1}{4} \, \cos \left (x\right )^{2} + \frac{1}{4}\right ) \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [B] time = 0.360291, size = 20, normalized size = 2.22 \begin{align*} \frac{\log{\left (\sin{\left (x \right )} - 1 \right )}}{2} + \frac{\log{\left (\sin{\left (x \right )} + 1 \right )}}{2} - \log{\left (\sin{\left (x \right )} \right )} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [B] time = 1.09292, size = 26, normalized size = 2.89 \begin{align*} -\frac{1}{2} \, \log \left (\sin \left (x\right )^{2}\right ) + \frac{1}{2} \, \log \left (-\sin \left (x\right )^{2} + 1\right ) \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]