\(\int (a+b \sec ^2(e+f x))^p \tan ^5(e+f x) \, dx\) [442]

Optimal result
Mathematica [A] (verified)
Rubi [A] (verified)
Maple [F]
Fricas [F]
Sympy [F(-1)]
Maxima [F]
Giac [F]
Mupad [F(-1)]
Reduce [F]

Optimal result

Integrand size = 23, antiderivative size = 123 \[ \int \left (a+b \sec ^2(e+f x)\right )^p \tan ^5(e+f x) \, dx=-\frac {(a+2 b) \left (a+b \sec ^2(e+f x)\right )^{1+p}}{2 b^2 f (1+p)}-\frac {\operatorname {Hypergeometric2F1}\left (1,1+p,2+p,\frac {a+b \sec ^2(e+f x)}{a}\right ) \left (a+b \sec ^2(e+f x)\right )^{1+p}}{2 a f (1+p)}+\frac {\left (a+b \sec ^2(e+f x)\right )^{2+p}}{2 b^2 f (2+p)} \] Output:

-1/2*(a+2*b)*(a+b*sec(f*x+e)^2)^(p+1)/b^2/f/(p+1)-1/2*hypergeom([1, p+1],[ 
2+p],(a+b*sec(f*x+e)^2)/a)*(a+b*sec(f*x+e)^2)^(p+1)/a/f/(p+1)+1/2*(a+b*sec 
(f*x+e)^2)^(2+p)/b^2/f/(2+p)
 

Mathematica [A] (verified)

Time = 0.44 (sec) , antiderivative size = 94, normalized size of antiderivative = 0.76 \[ \int \left (a+b \sec ^2(e+f x)\right )^p \tan ^5(e+f x) \, dx=-\frac {\left (a+b \sec ^2(e+f x)\right )^{1+p} \left (b^2 (2+p) \operatorname {Hypergeometric2F1}\left (1,1+p,2+p,1+\frac {b \sec ^2(e+f x)}{a}\right )+a \left (a+2 b (2+p)-b (1+p) \sec ^2(e+f x)\right )\right )}{2 a b^2 f (1+p) (2+p)} \] Input:

Integrate[(a + b*Sec[e + f*x]^2)^p*Tan[e + f*x]^5,x]
 

Output:

-1/2*((a + b*Sec[e + f*x]^2)^(1 + p)*(b^2*(2 + p)*Hypergeometric2F1[1, 1 + 
 p, 2 + p, 1 + (b*Sec[e + f*x]^2)/a] + a*(a + 2*b*(2 + p) - b*(1 + p)*Sec[ 
e + f*x]^2)))/(a*b^2*f*(1 + p)*(2 + p))
 

Rubi [A] (verified)

Time = 0.33 (sec) , antiderivative size = 113, normalized size of antiderivative = 0.92, number of steps used = 6, number of rules used = 5, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.217, Rules used = {3042, 4627, 354, 99, 2009}

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 \tan ^5(e+f x) \left (a+b \sec ^2(e+f x)\right )^p \, dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \int \tan (e+f x)^5 \left (a+b \sec (e+f x)^2\right )^pdx\)

\(\Big \downarrow \) 4627

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

\(\Big \downarrow \) 354

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

\(\Big \downarrow \) 99

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

\(\Big \downarrow \) 2009

\(\displaystyle \frac {-\frac {(a+2 b) \left (a+b \sec ^2(e+f x)\right )^{p+1}}{b^2 (p+1)}+\frac {\left (a+b \sec ^2(e+f x)\right )^{p+2}}{b^2 (p+2)}-\frac {\left (a+b \sec ^2(e+f x)\right )^{p+1} \operatorname {Hypergeometric2F1}\left (1,p+1,p+2,\frac {b \sec ^2(e+f x)}{a}+1\right )}{a (p+1)}}{2 f}\)

Input:

Int[(a + b*Sec[e + f*x]^2)^p*Tan[e + f*x]^5,x]
 

Output:

(-(((a + 2*b)*(a + b*Sec[e + f*x]^2)^(1 + p))/(b^2*(1 + p))) - (Hypergeome 
tric2F1[1, 1 + p, 2 + p, 1 + (b*Sec[e + f*x]^2)/a]*(a + b*Sec[e + f*x]^2)^ 
(1 + p))/(a*(1 + p)) + (a + b*Sec[e + f*x]^2)^(2 + p)/(b^2*(2 + p)))/(2*f)
 

Defintions of rubi rules used

rule 99
Int[((a_.) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_)*((e_.) + (f_.)*(x_) 
)^(p_), x_] :> Int[ExpandIntegrand[(a + b*x)^m*(c + d*x)^n*(e + f*x)^p, x], 
 x] /; FreeQ[{a, b, c, d, e, f, p}, x] && IntegersQ[m, n] && (IntegerQ[p] | 
| (GtQ[m, 0] && GeQ[n, -1]))
 

rule 354
Int[(x_)^(m_.)*((a_) + (b_.)*(x_)^2)^(p_.)*((c_) + (d_.)*(x_)^2)^(q_.), x_S 
ymbol] :> Simp[1/2   Subst[Int[x^((m - 1)/2)*(a + b*x)^p*(c + d*x)^q, x], x 
, x^2], x] /; FreeQ[{a, b, c, d, p, q}, x] && NeQ[b*c - a*d, 0] && IntegerQ 
[(m - 1)/2]
 

rule 2009
Int[u_, x_Symbol] :> Simp[IntSum[u, x], x] /; SumQ[u]
 

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

rule 4627
Int[((a_) + (b_.)*((c_.)*sec[(e_.) + (f_.)*(x_)])^(n_))^(p_.)*tan[(e_.) + ( 
f_.)*(x_)]^(m_.), x_Symbol] :> With[{ff = FreeFactors[Sec[e + f*x], x]}, Si 
mp[1/f   Subst[Int[(-1 + ff^2*x^2)^((m - 1)/2)*((a + b*(c*ff*x)^n)^p/x), x] 
, x, Sec[e + f*x]/ff], x]] /; FreeQ[{a, b, c, e, f, n, p}, x] && IntegerQ[( 
m - 1)/2] && (GtQ[m, 0] || EqQ[n, 2] || EqQ[n, 4] || IGtQ[p, 0] || Integers 
Q[2*n, p])
 
Maple [F]

\[\int \left (a +b \sec \left (f x +e \right )^{2}\right )^{p} \tan \left (f x +e \right )^{5}d x\]

Input:

int((a+b*sec(f*x+e)^2)^p*tan(f*x+e)^5,x)
 

Output:

int((a+b*sec(f*x+e)^2)^p*tan(f*x+e)^5,x)
 

Fricas [F]

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

integrate((a+b*sec(f*x+e)^2)^p*tan(f*x+e)^5,x, algorithm="fricas")
 

Output:

integral((b*sec(f*x + e)^2 + a)^p*tan(f*x + e)^5, x)
 

Sympy [F(-1)]

Timed out. \[ \int \left (a+b \sec ^2(e+f x)\right )^p \tan ^5(e+f x) \, dx=\text {Timed out} \] Input:

integrate((a+b*sec(f*x+e)**2)**p*tan(f*x+e)**5,x)
 

Output:

Timed out
 

Maxima [F]

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

integrate((a+b*sec(f*x+e)^2)^p*tan(f*x+e)^5,x, algorithm="maxima")
 

Output:

integrate((b*sec(f*x + e)^2 + a)^p*tan(f*x + e)^5, x)
 

Giac [F]

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

integrate((a+b*sec(f*x+e)^2)^p*tan(f*x+e)^5,x, algorithm="giac")
 

Output:

integrate((b*sec(f*x + e)^2 + a)^p*tan(f*x + e)^5, x)
 

Mupad [F(-1)]

Timed out. \[ \int \left (a+b \sec ^2(e+f x)\right )^p \tan ^5(e+f x) \, dx=\int {\mathrm {tan}\left (e+f\,x\right )}^5\,{\left (a+\frac {b}{{\cos \left (e+f\,x\right )}^2}\right )}^p \,d x \] Input:

int(tan(e + f*x)^5*(a + b/cos(e + f*x)^2)^p,x)
 

Output:

int(tan(e + f*x)^5*(a + b/cos(e + f*x)^2)^p, x)
 

Reduce [F]

\[ \int \left (a+b \sec ^2(e+f x)\right )^p \tan ^5(e+f x) \, dx =\text {Too large to display} \] Input:

int((a+b*sec(f*x+e)^2)^p*tan(f*x+e)^5,x)
 

Output:

((sec(e + f*x)**2*b + a)**p*tan(e + f*x)**4*p**2 + (sec(e + f*x)**2*b + a) 
**p*tan(e + f*x)**4*p - 2*(sec(e + f*x)**2*b + a)**p*tan(e + f*x)**2*p + 2 
*(sec(e + f*x)**2*b + a)**p + 2*int(((sec(e + f*x)**2*b + a)**p*tan(e + f* 
x)**5)/(sec(e + f*x)**2*b*p**2 + 3*sec(e + f*x)**2*b*p + 2*sec(e + f*x)**2 
*b + a*p**2 + 3*a*p + 2*a),x)*a*f*p**5 + 8*int(((sec(e + f*x)**2*b + a)**p 
*tan(e + f*x)**5)/(sec(e + f*x)**2*b*p**2 + 3*sec(e + f*x)**2*b*p + 2*sec( 
e + f*x)**2*b + a*p**2 + 3*a*p + 2*a),x)*a*f*p**4 + 10*int(((sec(e + f*x)* 
*2*b + a)**p*tan(e + f*x)**5)/(sec(e + f*x)**2*b*p**2 + 3*sec(e + f*x)**2* 
b*p + 2*sec(e + f*x)**2*b + a*p**2 + 3*a*p + 2*a),x)*a*f*p**3 + 4*int(((se 
c(e + f*x)**2*b + a)**p*tan(e + f*x)**5)/(sec(e + f*x)**2*b*p**2 + 3*sec(e 
 + f*x)**2*b*p + 2*sec(e + f*x)**2*b + a*p**2 + 3*a*p + 2*a),x)*a*f*p**2 - 
 4*int(((sec(e + f*x)**2*b + a)**p*tan(e + f*x)**3)/(sec(e + f*x)**2*b*p** 
2 + 3*sec(e + f*x)**2*b*p + 2*sec(e + f*x)**2*b + a*p**2 + 3*a*p + 2*a),x) 
*a*f*p**4 - 12*int(((sec(e + f*x)**2*b + a)**p*tan(e + f*x)**3)/(sec(e + f 
*x)**2*b*p**2 + 3*sec(e + f*x)**2*b*p + 2*sec(e + f*x)**2*b + a*p**2 + 3*a 
*p + 2*a),x)*a*f*p**3 - 8*int(((sec(e + f*x)**2*b + a)**p*tan(e + f*x)**3) 
/(sec(e + f*x)**2*b*p**2 + 3*sec(e + f*x)**2*b*p + 2*sec(e + f*x)**2*b + a 
*p**2 + 3*a*p + 2*a),x)*a*f*p**2 + 4*int(((sec(e + f*x)**2*b + a)**p*tan(e 
 + f*x))/(sec(e + f*x)**2*b*p**2 + 3*sec(e + f*x)**2*b*p + 2*sec(e + f*x)* 
*2*b + a*p**2 + 3*a*p + 2*a),x)*a*f*p**3 + 12*int(((sec(e + f*x)**2*b +...