\(\int \frac {\sec ^3(e+f x)}{(a+b \sec ^2(e+f x))^2} \, dx\) [194]

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

Optimal result

Integrand size = 23, antiderivative size = 74 \[ \int \frac {\sec ^3(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^2} \, dx=\frac {\text {arctanh}\left (\frac {\sqrt {a} \sin (e+f x)}{\sqrt {a+b}}\right )}{2 \sqrt {a} (a+b)^{3/2} f}+\frac {\sin (e+f x)}{2 (a+b) f \left (a+b-a \sin ^2(e+f x)\right )} \] Output:

1/2*arctanh(a^(1/2)*sin(f*x+e)/(a+b)^(1/2))/a^(1/2)/(a+b)^(3/2)/f+1/2*sin( 
f*x+e)/(a+b)/f/(a+b-a*sin(f*x+e)^2)
 

Mathematica [A] (verified)

Time = 0.27 (sec) , antiderivative size = 71, normalized size of antiderivative = 0.96 \[ \int \frac {\sec ^3(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^2} \, dx=\frac {\frac {\text {arctanh}\left (\frac {\sqrt {a} \sin (e+f x)}{\sqrt {a+b}}\right )}{\sqrt {a} (a+b)^{3/2}}+\frac {2 \sin (e+f x)}{(a+b) (a+2 b+a \cos (2 (e+f x)))}}{2 f} \] Input:

Integrate[Sec[e + f*x]^3/(a + b*Sec[e + f*x]^2)^2,x]
 

Output:

(ArcTanh[(Sqrt[a]*Sin[e + f*x])/Sqrt[a + b]]/(Sqrt[a]*(a + b)^(3/2)) + (2* 
Sin[e + f*x])/((a + b)*(a + 2*b + a*Cos[2*(e + f*x)])))/(2*f)
 

Rubi [A] (verified)

Time = 0.25 (sec) , antiderivative size = 72, normalized size of antiderivative = 0.97, number of steps used = 5, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.174, Rules used = {3042, 4635, 215, 221}

Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.

\(\displaystyle \int \frac {\sec ^3(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^2} \, dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \int \frac {\sec (e+f x)^3}{\left (a+b \sec (e+f x)^2\right )^2}dx\)

\(\Big \downarrow \) 4635

\(\displaystyle \frac {\int \frac {1}{\left (-a \sin ^2(e+f x)+a+b\right )^2}d\sin (e+f x)}{f}\)

\(\Big \downarrow \) 215

\(\displaystyle \frac {\frac {\int \frac {1}{-a \sin ^2(e+f x)+a+b}d\sin (e+f x)}{2 (a+b)}+\frac {\sin (e+f x)}{2 (a+b) \left (-a \sin ^2(e+f x)+a+b\right )}}{f}\)

\(\Big \downarrow \) 221

\(\displaystyle \frac {\frac {\text {arctanh}\left (\frac {\sqrt {a} \sin (e+f x)}{\sqrt {a+b}}\right )}{2 \sqrt {a} (a+b)^{3/2}}+\frac {\sin (e+f x)}{2 (a+b) \left (-a \sin ^2(e+f x)+a+b\right )}}{f}\)

Input:

Int[Sec[e + f*x]^3/(a + b*Sec[e + f*x]^2)^2,x]
 

Output:

(ArcTanh[(Sqrt[a]*Sin[e + f*x])/Sqrt[a + b]]/(2*Sqrt[a]*(a + b)^(3/2)) + S 
in[e + f*x]/(2*(a + b)*(a + b - a*Sin[e + f*x]^2)))/f
 

Defintions of rubi rules used

rule 215
Int[((a_) + (b_.)*(x_)^2)^(p_), x_Symbol] :> Simp[(-x)*((a + b*x^2)^(p + 1) 
/(2*a*(p + 1))), x] + Simp[(2*p + 3)/(2*a*(p + 1))   Int[(a + b*x^2)^(p + 1 
), x], x] /; FreeQ[{a, b}, x] && LtQ[p, -1] && (IntegerQ[4*p] || IntegerQ[6 
*p])
 

rule 221
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(Rt[-a/b, 2]/a)*ArcTanh[x 
/Rt[-a/b, 2]], x] /; FreeQ[{a, b}, x] && NegQ[a/b]
 

rule 3042
Int[u_, x_Symbol] :> Int[DeactivateTrig[u, x], x] /; FunctionOfTrigOfLinear 
Q[u, x]
 

rule 4635
Int[sec[(e_.) + (f_.)*(x_)]^(m_.)*((a_) + (b_.)*sec[(e_.) + (f_.)*(x_)]^(n_ 
))^(p_), x_Symbol] :> With[{ff = FreeFactors[Sin[e + f*x], x]}, Simp[ff/f 
 Subst[Int[ExpandToSum[b + a*(1 - ff^2*x^2)^(n/2), x]^p/(1 - ff^2*x^2)^((m 
+ n*p + 1)/2), x], x, Sin[e + f*x]/ff], x]] /; FreeQ[{a, b, e, f}, x] && In 
tegerQ[(m - 1)/2] && IntegerQ[n/2] && IntegerQ[p]
 
Maple [A] (verified)

Time = 0.55 (sec) , antiderivative size = 68, normalized size of antiderivative = 0.92

method result size
derivativedivides \(\frac {-\frac {\sin \left (f x +e \right )}{2 \left (a +b \right ) \left (-a -b +a \sin \left (f x +e \right )^{2}\right )}+\frac {\operatorname {arctanh}\left (\frac {a \sin \left (f x +e \right )}{\sqrt {a \left (a +b \right )}}\right )}{2 \left (a +b \right ) \sqrt {a \left (a +b \right )}}}{f}\) \(68\)
default \(\frac {-\frac {\sin \left (f x +e \right )}{2 \left (a +b \right ) \left (-a -b +a \sin \left (f x +e \right )^{2}\right )}+\frac {\operatorname {arctanh}\left (\frac {a \sin \left (f x +e \right )}{\sqrt {a \left (a +b \right )}}\right )}{2 \left (a +b \right ) \sqrt {a \left (a +b \right )}}}{f}\) \(68\)
risch \(-\frac {i \left ({\mathrm e}^{3 i \left (f x +e \right )}-{\mathrm e}^{i \left (f x +e \right )}\right )}{f \left (a +b \right ) \left (a \,{\mathrm e}^{4 i \left (f x +e \right )}+2 a \,{\mathrm e}^{2 i \left (f x +e \right )}+4 b \,{\mathrm e}^{2 i \left (f x +e \right )}+a \right )}+\frac {\ln \left ({\mathrm e}^{2 i \left (f x +e \right )}+\frac {2 i \left (a +b \right ) {\mathrm e}^{i \left (f x +e \right )}}{\sqrt {a^{2}+a b}}-1\right )}{4 \sqrt {a^{2}+a b}\, \left (a +b \right ) f}-\frac {\ln \left ({\mathrm e}^{2 i \left (f x +e \right )}-\frac {2 i \left (a +b \right ) {\mathrm e}^{i \left (f x +e \right )}}{\sqrt {a^{2}+a b}}-1\right )}{4 \sqrt {a^{2}+a b}\, \left (a +b \right ) f}\) \(183\)

Input:

int(sec(f*x+e)^3/(a+b*sec(f*x+e)^2)^2,x,method=_RETURNVERBOSE)
 

Output:

1/f*(-1/2*sin(f*x+e)/(a+b)/(-a-b+a*sin(f*x+e)^2)+1/2/(a+b)/(a*(a+b))^(1/2) 
*arctanh(a*sin(f*x+e)/(a*(a+b))^(1/2)))
 

Fricas [A] (verification not implemented)

Time = 0.09 (sec) , antiderivative size = 262, normalized size of antiderivative = 3.54 \[ \int \frac {\sec ^3(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^2} \, dx=\left [\frac {{\left (a \cos \left (f x + e\right )^{2} + b\right )} \sqrt {a^{2} + a b} \log \left (-\frac {a \cos \left (f x + e\right )^{2} - 2 \, \sqrt {a^{2} + a b} \sin \left (f x + e\right ) - 2 \, a - b}{a \cos \left (f x + e\right )^{2} + b}\right ) + 2 \, {\left (a^{2} + a b\right )} \sin \left (f x + e\right )}{4 \, {\left ({\left (a^{4} + 2 \, a^{3} b + a^{2} b^{2}\right )} f \cos \left (f x + e\right )^{2} + {\left (a^{3} b + 2 \, a^{2} b^{2} + a b^{3}\right )} f\right )}}, -\frac {{\left (a \cos \left (f x + e\right )^{2} + b\right )} \sqrt {-a^{2} - a b} \arctan \left (\frac {\sqrt {-a^{2} - a b} \sin \left (f x + e\right )}{a + b}\right ) - {\left (a^{2} + a b\right )} \sin \left (f x + e\right )}{2 \, {\left ({\left (a^{4} + 2 \, a^{3} b + a^{2} b^{2}\right )} f \cos \left (f x + e\right )^{2} + {\left (a^{3} b + 2 \, a^{2} b^{2} + a b^{3}\right )} f\right )}}\right ] \] Input:

integrate(sec(f*x+e)^3/(a+b*sec(f*x+e)^2)^2,x, algorithm="fricas")
 

Output:

[1/4*((a*cos(f*x + e)^2 + b)*sqrt(a^2 + a*b)*log(-(a*cos(f*x + e)^2 - 2*sq 
rt(a^2 + a*b)*sin(f*x + e) - 2*a - b)/(a*cos(f*x + e)^2 + b)) + 2*(a^2 + a 
*b)*sin(f*x + e))/((a^4 + 2*a^3*b + a^2*b^2)*f*cos(f*x + e)^2 + (a^3*b + 2 
*a^2*b^2 + a*b^3)*f), -1/2*((a*cos(f*x + e)^2 + b)*sqrt(-a^2 - a*b)*arctan 
(sqrt(-a^2 - a*b)*sin(f*x + e)/(a + b)) - (a^2 + a*b)*sin(f*x + e))/((a^4 
+ 2*a^3*b + a^2*b^2)*f*cos(f*x + e)^2 + (a^3*b + 2*a^2*b^2 + a*b^3)*f)]
 

Sympy [F]

\[ \int \frac {\sec ^3(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^2} \, dx=\int \frac {\sec ^{3}{\left (e + f x \right )}}{\left (a + b \sec ^{2}{\left (e + f x \right )}\right )^{2}}\, dx \] Input:

integrate(sec(f*x+e)**3/(a+b*sec(f*x+e)**2)**2,x)
 

Output:

Integral(sec(e + f*x)**3/(a + b*sec(e + f*x)**2)**2, x)
 

Maxima [A] (verification not implemented)

Time = 0.11 (sec) , antiderivative size = 98, normalized size of antiderivative = 1.32 \[ \int \frac {\sec ^3(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^2} \, dx=-\frac {\frac {2 \, \sin \left (f x + e\right )}{{\left (a^{2} + a b\right )} \sin \left (f x + e\right )^{2} - a^{2} - 2 \, a b - b^{2}} + \frac {\log \left (\frac {a \sin \left (f x + e\right ) - \sqrt {{\left (a + b\right )} a}}{a \sin \left (f x + e\right ) + \sqrt {{\left (a + b\right )} a}}\right )}{\sqrt {{\left (a + b\right )} a} {\left (a + b\right )}}}{4 \, f} \] Input:

integrate(sec(f*x+e)^3/(a+b*sec(f*x+e)^2)^2,x, algorithm="maxima")
 

Output:

-1/4*(2*sin(f*x + e)/((a^2 + a*b)*sin(f*x + e)^2 - a^2 - 2*a*b - b^2) + lo 
g((a*sin(f*x + e) - sqrt((a + b)*a))/(a*sin(f*x + e) + sqrt((a + b)*a)))/( 
sqrt((a + b)*a)*(a + b)))/f
 

Giac [A] (verification not implemented)

Time = 0.15 (sec) , antiderivative size = 76, normalized size of antiderivative = 1.03 \[ \int \frac {\sec ^3(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^2} \, dx=-\frac {\frac {\arctan \left (\frac {a \sin \left (f x + e\right )}{\sqrt {-a^{2} - a b}}\right )}{\sqrt {-a^{2} - a b} {\left (a + b\right )}} + \frac {\sin \left (f x + e\right )}{{\left (a \sin \left (f x + e\right )^{2} - a - b\right )} {\left (a + b\right )}}}{2 \, f} \] Input:

integrate(sec(f*x+e)^3/(a+b*sec(f*x+e)^2)^2,x, algorithm="giac")
 

Output:

-1/2*(arctan(a*sin(f*x + e)/sqrt(-a^2 - a*b))/(sqrt(-a^2 - a*b)*(a + b)) + 
 sin(f*x + e)/((a*sin(f*x + e)^2 - a - b)*(a + b)))/f
 

Mupad [B] (verification not implemented)

Time = 0.14 (sec) , antiderivative size = 62, normalized size of antiderivative = 0.84 \[ \int \frac {\sec ^3(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^2} \, dx=\frac {\sin \left (e+f\,x\right )}{2\,f\,\left (a+b\right )\,\left (-a\,{\sin \left (e+f\,x\right )}^2+a+b\right )}+\frac {\mathrm {atanh}\left (\frac {\sqrt {a}\,\sin \left (e+f\,x\right )}{\sqrt {a+b}}\right )}{2\,\sqrt {a}\,f\,{\left (a+b\right )}^{3/2}} \] Input:

int(1/(cos(e + f*x)^3*(a + b/cos(e + f*x)^2)^2),x)
 

Output:

sin(e + f*x)/(2*f*(a + b)*(a + b - a*sin(e + f*x)^2)) + atanh((a^(1/2)*sin 
(e + f*x))/(a + b)^(1/2))/(2*a^(1/2)*f*(a + b)^(3/2))
 

Reduce [B] (verification not implemented)

Time = 0.17 (sec) , antiderivative size = 371, normalized size of antiderivative = 5.01 \[ \int \frac {\sec ^3(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^2} \, dx=\frac {-\sqrt {a}\, \sqrt {a +b}\, \mathrm {log}\left (\sqrt {a +b}\, \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{2}+\sqrt {a +b}-2 \sqrt {a}\, \tan \left (\frac {f x}{2}+\frac {e}{2}\right )\right ) \sin \left (f x +e \right )^{2} a +\sqrt {a}\, \sqrt {a +b}\, \mathrm {log}\left (\sqrt {a +b}\, \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{2}+\sqrt {a +b}-2 \sqrt {a}\, \tan \left (\frac {f x}{2}+\frac {e}{2}\right )\right ) a +\sqrt {a}\, \sqrt {a +b}\, \mathrm {log}\left (\sqrt {a +b}\, \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{2}+\sqrt {a +b}-2 \sqrt {a}\, \tan \left (\frac {f x}{2}+\frac {e}{2}\right )\right ) b +\sqrt {a}\, \sqrt {a +b}\, \mathrm {log}\left (\sqrt {a +b}\, \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{2}+\sqrt {a +b}+2 \sqrt {a}\, \tan \left (\frac {f x}{2}+\frac {e}{2}\right )\right ) \sin \left (f x +e \right )^{2} a -\sqrt {a}\, \sqrt {a +b}\, \mathrm {log}\left (\sqrt {a +b}\, \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{2}+\sqrt {a +b}+2 \sqrt {a}\, \tan \left (\frac {f x}{2}+\frac {e}{2}\right )\right ) a -\sqrt {a}\, \sqrt {a +b}\, \mathrm {log}\left (\sqrt {a +b}\, \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{2}+\sqrt {a +b}+2 \sqrt {a}\, \tan \left (\frac {f x}{2}+\frac {e}{2}\right )\right ) b -2 \sin \left (f x +e \right ) a^{2}-2 \sin \left (f x +e \right ) a b}{4 a f \left (\sin \left (f x +e \right )^{2} a^{3}+2 \sin \left (f x +e \right )^{2} a^{2} b +\sin \left (f x +e \right )^{2} a \,b^{2}-a^{3}-3 a^{2} b -3 a \,b^{2}-b^{3}\right )} \] Input:

int(sec(f*x+e)^3/(a+b*sec(f*x+e)^2)^2,x)
 

Output:

( - sqrt(a)*sqrt(a + b)*log(sqrt(a + b)*tan((e + f*x)/2)**2 + sqrt(a + b) 
- 2*sqrt(a)*tan((e + f*x)/2))*sin(e + f*x)**2*a + sqrt(a)*sqrt(a + b)*log( 
sqrt(a + b)*tan((e + f*x)/2)**2 + sqrt(a + b) - 2*sqrt(a)*tan((e + f*x)/2) 
)*a + sqrt(a)*sqrt(a + b)*log(sqrt(a + b)*tan((e + f*x)/2)**2 + sqrt(a + b 
) - 2*sqrt(a)*tan((e + f*x)/2))*b + sqrt(a)*sqrt(a + b)*log(sqrt(a + b)*ta 
n((e + f*x)/2)**2 + sqrt(a + b) + 2*sqrt(a)*tan((e + f*x)/2))*sin(e + f*x) 
**2*a - sqrt(a)*sqrt(a + b)*log(sqrt(a + b)*tan((e + f*x)/2)**2 + sqrt(a + 
 b) + 2*sqrt(a)*tan((e + f*x)/2))*a - sqrt(a)*sqrt(a + b)*log(sqrt(a + b)* 
tan((e + f*x)/2)**2 + sqrt(a + b) + 2*sqrt(a)*tan((e + f*x)/2))*b - 2*sin( 
e + f*x)*a**2 - 2*sin(e + f*x)*a*b)/(4*a*f*(sin(e + f*x)**2*a**3 + 2*sin(e 
 + f*x)**2*a**2*b + sin(e + f*x)**2*a*b**2 - a**3 - 3*a**2*b - 3*a*b**2 - 
b**3))