Optimal. Leaf size=72 \[ \frac {\log \left (\tan ^2(a+b x)-\sqrt {2} \tan (a+b x)+1\right )}{2 \sqrt {2} b}-\frac {\log \left (\tan ^2(a+b x)+\sqrt {2} \tan (a+b x)+1\right )}{2 \sqrt {2} b} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 1.40, antiderivative size = 72, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 2, integrand size = 39, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.051, Rules used = {1165, 628} \[ \frac {\log \left (\tan ^2(a+b x)-\sqrt {2} \tan (a+b x)+1\right )}{2 \sqrt {2} b}-\frac {\log \left (\tan ^2(a+b x)+\sqrt {2} \tan (a+b x)+1\right )}{2 \sqrt {2} b} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 628
Rule 1165
Rubi steps
\begin {align*} \int \frac {-\csc ^4(a+b x)+\sec ^4(a+b x)}{\csc ^4(a+b x)+\sec ^4(a+b x)} \, dx &=\frac {\operatorname {Subst}\left (\int \frac {-1+x^2}{1+x^4} \, dx,x,\tan (a+b x)\right )}{b}\\ &=\frac {\operatorname {Subst}\left (\int \frac {\sqrt {2}+2 x}{-1-\sqrt {2} x-x^2} \, dx,x,\tan (a+b x)\right )}{2 \sqrt {2} b}+\frac {\operatorname {Subst}\left (\int \frac {\sqrt {2}-2 x}{-1+\sqrt {2} x-x^2} \, dx,x,\tan (a+b x)\right )}{2 \sqrt {2} b}\\ &=\frac {\log \left (1-\sqrt {2} \tan (a+b x)+\tan ^2(a+b x)\right )}{2 \sqrt {2} b}-\frac {\log \left (1+\sqrt {2} \tan (a+b x)+\tan ^2(a+b x)\right )}{2 \sqrt {2} b}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 0.02, size = 26, normalized size = 0.36 \[ -\frac {\tanh ^{-1}\left (\frac {\sin (2 a+2 b x)}{\sqrt {2}}\right )}{\sqrt {2} b} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 1.15, size = 74, normalized size = 1.03 \[ \frac {\sqrt {2} \log \left (-\frac {2 \, \cos \left (b x + a\right )^{4} + 2 \, \sqrt {2} \cos \left (b x + a\right ) \sin \left (b x + a\right ) - 2 \, \cos \left (b x + a\right )^{2} - 1}{2 \, \cos \left (b x + a\right )^{4} - 2 \, \cos \left (b x + a\right )^{2} + 1}\right )}{4 \, b} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 0.39, size = 48, normalized size = 0.67 \[ \frac {\sqrt {2} \log \left (\frac {{\left | -2 \, \sqrt {2} + 2 \, \sin \left (2 \, b x + 2 \, a\right ) \right |}}{{\left | 2 \, \sqrt {2} + 2 \, \sin \left (2 \, b x + 2 \, a\right ) \right |}}\right )}{4 \, b} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.51, size = 108, normalized size = 1.50 \[ -\frac {\sqrt {2}\, \ln \left (\frac {1+\sqrt {2}\, \tan \left (b x +a \right )+\tan ^{2}\left (b x +a \right )}{1-\sqrt {2}\, \tan \left (b x +a \right )+\tan ^{2}\left (b x +a \right )}\right )}{8 b}+\frac {\sqrt {2}\, \ln \left (\frac {1-\sqrt {2}\, \tan \left (b x +a \right )+\tan ^{2}\left (b x +a \right )}{1+\sqrt {2}\, \tan \left (b x +a \right )+\tan ^{2}\left (b x +a \right )}\right )}{8 b} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 0.43, size = 58, normalized size = 0.81 \[ -\frac {\sqrt {2} \log \left (\tan \left (b x + a\right )^{2} + \sqrt {2} \tan \left (b x + a\right ) + 1\right ) - \sqrt {2} \log \left (\tan \left (b x + a\right )^{2} - \sqrt {2} \tan \left (b x + a\right ) + 1\right )}{4 \, b} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 3.09, size = 23, normalized size = 0.32 \[ -\frac {\sqrt {2}\,\mathrm {atanh}\left (\frac {\sqrt {2}\,\sin \left (2\,a+2\,b\,x\right )}{2}\right )}{2\,b} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [F(-1)] time = 0.00, size = 0, normalized size = 0.00 \[ \text {Timed out} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________