\(\int (a+b (c \sec (e+f x))^n)^p \tan (e+f x) \, dx\) [465]

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

Optimal result

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

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

Mathematica [A] (verified)

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

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

Output:

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

Rubi [A] (verified)

Time = 0.27 (sec) , antiderivative size = 59, normalized size of antiderivative = 0.98, number of steps used = 7, number of rules used = 6, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.261, Rules used = {3042, 4627, 891, 27, 798, 75}

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

\(\Big \downarrow \) 3042

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

\(\Big \downarrow \) 4627

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

\(\Big \downarrow \) 891

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

\(\Big \downarrow \) 27

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

\(\Big \downarrow \) 798

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

\(\Big \downarrow \) 75

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

Input:

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

Output:

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

Defintions of rubi rules used

rule 27
Int[(a_)*(Fx_), x_Symbol] :> Simp[a   Int[Fx, x], x] /; FreeQ[a, x] &&  !Ma 
tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
 

rule 75
Int[((b_.)*(x_))^(m_)*((c_) + (d_.)*(x_))^(n_), x_Symbol] :> Simp[((c + d*x 
)^(n + 1)/(d*(n + 1)*(-d/(b*c))^m))*Hypergeometric2F1[-m, n + 1, n + 2, 1 + 
 d*(x/c)], x] /; FreeQ[{b, c, d, m, n}, x] &&  !IntegerQ[n] && (IntegerQ[m] 
 || GtQ[-d/(b*c), 0])
 

rule 798
Int[(x_)^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> Simp[1/n   Subst 
[Int[x^(Simplify[(m + 1)/n] - 1)*(a + b*x)^p, x], x, x^n], x] /; FreeQ[{a, 
b, m, n, p}, x] && IntegerQ[Simplify[(m + 1)/n]]
 

rule 891
Int[((d_.)*(x_))^(m_.)*((a_) + (b_.)*((c_)*(x_))^(n_))^(p_.), x_Symbol] :> 
Simp[1/c   Subst[Int[(d*(x/c))^m*(a + b*x^n)^p, x], x, c*x], x] /; FreeQ[{a 
, b, c, d, m, n, p}, x]
 

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 \left (c \sec \left (f x +e \right )\right )^{n}\right )^{p} \tan \left (f x +e \right )d x\]

Input:

int((a+b*(c*sec(f*x+e))^n)^p*tan(f*x+e),x)
 

Output:

int((a+b*(c*sec(f*x+e))^n)^p*tan(f*x+e),x)
 

Fricas [F]

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

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

Output:

integral(((c*sec(f*x + e))^n*b + a)^p*tan(f*x + e), x)
 

Sympy [F]

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

integrate((a+b*(c*sec(f*x+e))**n)**p*tan(f*x+e),x)
 

Output:

Integral((a + b*(c*sec(e + f*x))**n)**p*tan(e + f*x), x)
 

Maxima [F]

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

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

Output:

integrate(((c*sec(f*x + e))^n*b + a)^p*tan(f*x + e), x)
 

Giac [F]

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

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

Output:

integrate(((c*sec(f*x + e))^n*b + a)^p*tan(f*x + e), x)
 

Mupad [F(-1)]

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

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

Output:

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

Reduce [F]

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

int((a+b*(c*sec(f*x+e))^n)^p*tan(f*x+e),x)
                                                                                    
                                                                                    
 

Output:

((c**n*sec(e + f*x)**n*b + a)**p + int(((c**n*sec(e + f*x)**n*b + a)**p*ta 
n(e + f*x))/(c**n*sec(e + f*x)**n*b + a),x)*a*f*n*p)/(f*n*p)