Integrand size = 32, antiderivative size = 121 \[ \int \frac {\sec (e+f x) (a+a \sec (e+f x))^2}{(c-c \sec (e+f x))^5} \, dx=-\frac {(a+a \sec (e+f x))^2 \tan (e+f x)}{9 f (c-c \sec (e+f x))^5}-\frac {2 (a+a \sec (e+f x))^2 \tan (e+f x)}{63 c f (c-c \sec (e+f x))^4}-\frac {2 (a+a \sec (e+f x))^2 \tan (e+f x)}{315 c^2 f (c-c \sec (e+f x))^3} \] Output:
-1/9*(a+a*sec(f*x+e))^2*tan(f*x+e)/f/(c-c*sec(f*x+e))^5-2/63*(a+a*sec(f*x+ e))^2*tan(f*x+e)/c/f/(c-c*sec(f*x+e))^4-2/315*(a+a*sec(f*x+e))^2*tan(f*x+e )/c^2/f/(c-c*sec(f*x+e))^3
Time = 0.46 (sec) , antiderivative size = 59, normalized size of antiderivative = 0.49 \[ \int \frac {\sec (e+f x) (a+a \sec (e+f x))^2}{(c-c \sec (e+f x))^5} \, dx=\frac {a^2 (1+\sec (e+f x))^2 \left (47-14 \sec (e+f x)+2 \sec ^2(e+f x)\right ) \tan (e+f x)}{315 c^5 f (-1+\sec (e+f x))^5} \] Input:
Integrate[(Sec[e + f*x]*(a + a*Sec[e + f*x])^2)/(c - c*Sec[e + f*x])^5,x]
Output:
(a^2*(1 + Sec[e + f*x])^2*(47 - 14*Sec[e + f*x] + 2*Sec[e + f*x]^2)*Tan[e + f*x])/(315*c^5*f*(-1 + Sec[e + f*x])^5)
Time = 0.62 (sec) , antiderivative size = 126, normalized size of antiderivative = 1.04, number of steps used = 6, number of rules used = 6, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.188, Rules used = {3042, 4439, 3042, 4439, 3042, 4438}
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 (e+f x) (a \sec (e+f x)+a)^2}{(c-c \sec (e+f x))^5} \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {\csc \left (e+f x+\frac {\pi }{2}\right ) \left (a \csc \left (e+f x+\frac {\pi }{2}\right )+a\right )^2}{\left (c-c \csc \left (e+f x+\frac {\pi }{2}\right )\right )^5}dx\) |
\(\Big \downarrow \) 4439 |
\(\displaystyle \frac {2 \int \frac {\sec (e+f x) (\sec (e+f x) a+a)^2}{(c-c \sec (e+f x))^4}dx}{9 c}-\frac {\tan (e+f x) (a \sec (e+f x)+a)^2}{9 f (c-c \sec (e+f x))^5}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {2 \int \frac {\csc \left (e+f x+\frac {\pi }{2}\right ) \left (\csc \left (e+f x+\frac {\pi }{2}\right ) a+a\right )^2}{\left (c-c \csc \left (e+f x+\frac {\pi }{2}\right )\right )^4}dx}{9 c}-\frac {\tan (e+f x) (a \sec (e+f x)+a)^2}{9 f (c-c \sec (e+f x))^5}\) |
\(\Big \downarrow \) 4439 |
\(\displaystyle \frac {2 \left (\frac {\int \frac {\sec (e+f x) (\sec (e+f x) a+a)^2}{(c-c \sec (e+f x))^3}dx}{7 c}-\frac {\tan (e+f x) (a \sec (e+f x)+a)^2}{7 f (c-c \sec (e+f x))^4}\right )}{9 c}-\frac {\tan (e+f x) (a \sec (e+f x)+a)^2}{9 f (c-c \sec (e+f x))^5}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {2 \left (\frac {\int \frac {\csc \left (e+f x+\frac {\pi }{2}\right ) \left (\csc \left (e+f x+\frac {\pi }{2}\right ) a+a\right )^2}{\left (c-c \csc \left (e+f x+\frac {\pi }{2}\right )\right )^3}dx}{7 c}-\frac {\tan (e+f x) (a \sec (e+f x)+a)^2}{7 f (c-c \sec (e+f x))^4}\right )}{9 c}-\frac {\tan (e+f x) (a \sec (e+f x)+a)^2}{9 f (c-c \sec (e+f x))^5}\) |
\(\Big \downarrow \) 4438 |
\(\displaystyle \frac {2 \left (-\frac {\tan (e+f x) (a \sec (e+f x)+a)^2}{35 c f (c-c \sec (e+f x))^3}-\frac {\tan (e+f x) (a \sec (e+f x)+a)^2}{7 f (c-c \sec (e+f x))^4}\right )}{9 c}-\frac {\tan (e+f x) (a \sec (e+f x)+a)^2}{9 f (c-c \sec (e+f x))^5}\) |
Input:
Int[(Sec[e + f*x]*(a + a*Sec[e + f*x])^2)/(c - c*Sec[e + f*x])^5,x]
Output:
-1/9*((a + a*Sec[e + f*x])^2*Tan[e + f*x])/(f*(c - c*Sec[e + f*x])^5) + (2 *(-1/7*((a + a*Sec[e + f*x])^2*Tan[e + f*x])/(f*(c - c*Sec[e + f*x])^4) - ((a + a*Sec[e + f*x])^2*Tan[e + f*x])/(35*c*f*(c - c*Sec[e + f*x])^3)))/(9 *c)
Int[csc[(e_.) + (f_.)*(x_)]*(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_))^(m_)*(cs c[(e_.) + (f_.)*(x_)]*(d_.) + (c_))^(n_.), x_Symbol] :> Simp[b*Cot[e + f*x] *(a + b*Csc[e + f*x])^m*((c + d*Csc[e + f*x])^n/(a*f*(2*m + 1))), x] /; Fre eQ[{a, b, c, d, e, f, m, n}, x] && EqQ[b*c + a*d, 0] && EqQ[a^2 - b^2, 0] & & EqQ[m + n + 1, 0] && NeQ[2*m + 1, 0]
Int[csc[(e_.) + (f_.)*(x_)]*(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_))^(m_)*(cs c[(e_.) + (f_.)*(x_)]*(d_.) + (c_))^(n_.), x_Symbol] :> Simp[b*Cot[e + f*x] *(a + b*Csc[e + f*x])^m*((c + d*Csc[e + f*x])^n/(a*f*(2*m + 1))), x] + Simp [(m + n + 1)/(a*(2*m + 1)) Int[Csc[e + f*x]*(a + b*Csc[e + f*x])^(m + 1)* (c + d*Csc[e + f*x])^n, x], x] /; FreeQ[{a, b, c, d, e, f, m, n}, x] && EqQ [b*c + a*d, 0] && EqQ[a^2 - b^2, 0] && ILtQ[m + n + 1, 0] && NeQ[2*m + 1, 0 ] && !LtQ[n, 0] && !(IGtQ[n + 1/2, 0] && LtQ[n + 1/2, -(m + n)])
Time = 0.20 (sec) , antiderivative size = 51, normalized size of antiderivative = 0.42
method | result | size |
parallelrisch | \(\frac {a^{2} \cot \left (\frac {f x}{2}+\frac {e}{2}\right )^{5} \left (35 \cot \left (\frac {f x}{2}+\frac {e}{2}\right )^{4}-90 \cot \left (\frac {f x}{2}+\frac {e}{2}\right )^{2}+63\right )}{1260 c^{5} f}\) | \(51\) |
derivativedivides | \(\frac {a^{2} \left (-\frac {2}{7 \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{7}}+\frac {1}{9 \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{9}}+\frac {1}{5 \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{5}}\right )}{4 f \,c^{5}}\) | \(52\) |
default | \(\frac {a^{2} \left (-\frac {2}{7 \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{7}}+\frac {1}{9 \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{9}}+\frac {1}{5 \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{5}}\right )}{4 f \,c^{5}}\) | \(52\) |
risch | \(\frac {2 i a^{2} \left (315 \,{\mathrm e}^{8 i \left (f x +e \right )}-630 \,{\mathrm e}^{7 i \left (f x +e \right )}+2310 \,{\mathrm e}^{6 i \left (f x +e \right )}-2520 \,{\mathrm e}^{5 i \left (f x +e \right )}+3402 \,{\mathrm e}^{4 i \left (f x +e \right )}-1638 \,{\mathrm e}^{3 i \left (f x +e \right )}+1062 \,{\mathrm e}^{2 i \left (f x +e \right )}-108 \,{\mathrm e}^{i \left (f x +e \right )}+47\right )}{315 f \,c^{5} \left ({\mathrm e}^{i \left (f x +e \right )}-1\right )^{9}}\) | \(116\) |
norman | \(\frac {\frac {a^{2}}{36 c f}-\frac {8 a^{2} \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{2}}{63 c f}+\frac {139 a^{2} \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{4}}{630 c f}-\frac {6 a^{2} \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{6}}{35 c f}+\frac {a^{2} \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{8}}{20 c f}}{\left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{2}-1\right )^{2} c^{4} \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{9}}\) | \(131\) |
Input:
int(sec(f*x+e)*(a+a*sec(f*x+e))^2/(c-c*sec(f*x+e))^5,x,method=_RETURNVERBO SE)
Output:
1/1260*a^2*cot(1/2*f*x+1/2*e)^5*(35*cot(1/2*f*x+1/2*e)^4-90*cot(1/2*f*x+1/ 2*e)^2+63)/c^5/f
Time = 0.10 (sec) , antiderivative size = 140, normalized size of antiderivative = 1.16 \[ \int \frac {\sec (e+f x) (a+a \sec (e+f x))^2}{(c-c \sec (e+f x))^5} \, dx=\frac {47 \, a^{2} \cos \left (f x + e\right )^{5} + 127 \, a^{2} \cos \left (f x + e\right )^{4} + 101 \, a^{2} \cos \left (f x + e\right )^{3} + 11 \, a^{2} \cos \left (f x + e\right )^{2} - 8 \, a^{2} \cos \left (f x + e\right ) + 2 \, a^{2}}{315 \, {\left (c^{5} f \cos \left (f x + e\right )^{4} - 4 \, c^{5} f \cos \left (f x + e\right )^{3} + 6 \, c^{5} f \cos \left (f x + e\right )^{2} - 4 \, c^{5} f \cos \left (f x + e\right ) + c^{5} f\right )} \sin \left (f x + e\right )} \] Input:
integrate(sec(f*x+e)*(a+a*sec(f*x+e))^2/(c-c*sec(f*x+e))^5,x, algorithm="f ricas")
Output:
1/315*(47*a^2*cos(f*x + e)^5 + 127*a^2*cos(f*x + e)^4 + 101*a^2*cos(f*x + e)^3 + 11*a^2*cos(f*x + e)^2 - 8*a^2*cos(f*x + e) + 2*a^2)/((c^5*f*cos(f*x + e)^4 - 4*c^5*f*cos(f*x + e)^3 + 6*c^5*f*cos(f*x + e)^2 - 4*c^5*f*cos(f* x + e) + c^5*f)*sin(f*x + e))
\[ \int \frac {\sec (e+f x) (a+a \sec (e+f x))^2}{(c-c \sec (e+f x))^5} \, dx=- \frac {a^{2} \left (\int \frac {\sec {\left (e + f x \right )}}{\sec ^{5}{\left (e + f x \right )} - 5 \sec ^{4}{\left (e + f x \right )} + 10 \sec ^{3}{\left (e + f x \right )} - 10 \sec ^{2}{\left (e + f x \right )} + 5 \sec {\left (e + f x \right )} - 1}\, dx + \int \frac {2 \sec ^{2}{\left (e + f x \right )}}{\sec ^{5}{\left (e + f x \right )} - 5 \sec ^{4}{\left (e + f x \right )} + 10 \sec ^{3}{\left (e + f x \right )} - 10 \sec ^{2}{\left (e + f x \right )} + 5 \sec {\left (e + f x \right )} - 1}\, dx + \int \frac {\sec ^{3}{\left (e + f x \right )}}{\sec ^{5}{\left (e + f x \right )} - 5 \sec ^{4}{\left (e + f x \right )} + 10 \sec ^{3}{\left (e + f x \right )} - 10 \sec ^{2}{\left (e + f x \right )} + 5 \sec {\left (e + f x \right )} - 1}\, dx\right )}{c^{5}} \] Input:
integrate(sec(f*x+e)*(a+a*sec(f*x+e))**2/(c-c*sec(f*x+e))**5,x)
Output:
-a**2*(Integral(sec(e + f*x)/(sec(e + f*x)**5 - 5*sec(e + f*x)**4 + 10*sec (e + f*x)**3 - 10*sec(e + f*x)**2 + 5*sec(e + f*x) - 1), x) + Integral(2*s ec(e + f*x)**2/(sec(e + f*x)**5 - 5*sec(e + f*x)**4 + 10*sec(e + f*x)**3 - 10*sec(e + f*x)**2 + 5*sec(e + f*x) - 1), x) + Integral(sec(e + f*x)**3/( sec(e + f*x)**5 - 5*sec(e + f*x)**4 + 10*sec(e + f*x)**3 - 10*sec(e + f*x) **2 + 5*sec(e + f*x) - 1), x))/c**5
Leaf count of result is larger than twice the leaf count of optimal. 269 vs. \(2 (118) = 236\).
Time = 0.08 (sec) , antiderivative size = 269, normalized size of antiderivative = 2.22 \[ \int \frac {\sec (e+f x) (a+a \sec (e+f x))^2}{(c-c \sec (e+f x))^5} \, dx=-\frac {\frac {a^{2} {\left (\frac {180 \, \sin \left (f x + e\right )^{2}}{{\left (\cos \left (f x + e\right ) + 1\right )}^{2}} - \frac {378 \, \sin \left (f x + e\right )^{4}}{{\left (\cos \left (f x + e\right ) + 1\right )}^{4}} + \frac {420 \, \sin \left (f x + e\right )^{6}}{{\left (\cos \left (f x + e\right ) + 1\right )}^{6}} - \frac {315 \, \sin \left (f x + e\right )^{8}}{{\left (\cos \left (f x + e\right ) + 1\right )}^{8}} - 35\right )} {\left (\cos \left (f x + e\right ) + 1\right )}^{9}}{c^{5} \sin \left (f x + e\right )^{9}} + \frac {10 \, a^{2} {\left (\frac {18 \, \sin \left (f x + e\right )^{2}}{{\left (\cos \left (f x + e\right ) + 1\right )}^{2}} - \frac {42 \, \sin \left (f x + e\right )^{6}}{{\left (\cos \left (f x + e\right ) + 1\right )}^{6}} + \frac {63 \, \sin \left (f x + e\right )^{8}}{{\left (\cos \left (f x + e\right ) + 1\right )}^{8}} - 7\right )} {\left (\cos \left (f x + e\right ) + 1\right )}^{9}}{c^{5} \sin \left (f x + e\right )^{9}} + \frac {7 \, a^{2} {\left (\frac {18 \, \sin \left (f x + e\right )^{4}}{{\left (\cos \left (f x + e\right ) + 1\right )}^{4}} - \frac {45 \, \sin \left (f x + e\right )^{8}}{{\left (\cos \left (f x + e\right ) + 1\right )}^{8}} - 5\right )} {\left (\cos \left (f x + e\right ) + 1\right )}^{9}}{c^{5} \sin \left (f x + e\right )^{9}}}{5040 \, f} \] Input:
integrate(sec(f*x+e)*(a+a*sec(f*x+e))^2/(c-c*sec(f*x+e))^5,x, algorithm="m axima")
Output:
-1/5040*(a^2*(180*sin(f*x + e)^2/(cos(f*x + e) + 1)^2 - 378*sin(f*x + e)^4 /(cos(f*x + e) + 1)^4 + 420*sin(f*x + e)^6/(cos(f*x + e) + 1)^6 - 315*sin( f*x + e)^8/(cos(f*x + e) + 1)^8 - 35)*(cos(f*x + e) + 1)^9/(c^5*sin(f*x + e)^9) + 10*a^2*(18*sin(f*x + e)^2/(cos(f*x + e) + 1)^2 - 42*sin(f*x + e)^6 /(cos(f*x + e) + 1)^6 + 63*sin(f*x + e)^8/(cos(f*x + e) + 1)^8 - 7)*(cos(f *x + e) + 1)^9/(c^5*sin(f*x + e)^9) + 7*a^2*(18*sin(f*x + e)^4/(cos(f*x + e) + 1)^4 - 45*sin(f*x + e)^8/(cos(f*x + e) + 1)^8 - 5)*(cos(f*x + e) + 1) ^9/(c^5*sin(f*x + e)^9))/f
Time = 0.22 (sec) , antiderivative size = 57, normalized size of antiderivative = 0.47 \[ \int \frac {\sec (e+f x) (a+a \sec (e+f x))^2}{(c-c \sec (e+f x))^5} \, dx=\frac {63 \, a^{2} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{4} - 90 \, a^{2} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{2} + 35 \, a^{2}}{1260 \, c^{5} f \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{9}} \] Input:
integrate(sec(f*x+e)*(a+a*sec(f*x+e))^2/(c-c*sec(f*x+e))^5,x, algorithm="g iac")
Output:
1/1260*(63*a^2*tan(1/2*f*x + 1/2*e)^4 - 90*a^2*tan(1/2*f*x + 1/2*e)^2 + 35 *a^2)/(c^5*f*tan(1/2*f*x + 1/2*e)^9)
Time = 10.78 (sec) , antiderivative size = 67, normalized size of antiderivative = 0.55 \[ \int \frac {\sec (e+f x) (a+a \sec (e+f x))^2}{(c-c \sec (e+f x))^5} \, dx=\frac {a^2\,{\mathrm {cot}\left (\frac {e}{2}+\frac {f\,x}{2}\right )}^5}{20\,c^5\,f}-\frac {a^2\,{\mathrm {cot}\left (\frac {e}{2}+\frac {f\,x}{2}\right )}^7}{14\,c^5\,f}+\frac {a^2\,{\mathrm {cot}\left (\frac {e}{2}+\frac {f\,x}{2}\right )}^9}{36\,c^5\,f} \] Input:
int((a + a/cos(e + f*x))^2/(cos(e + f*x)*(c - c/cos(e + f*x))^5),x)
Output:
(a^2*cot(e/2 + (f*x)/2)^5)/(20*c^5*f) - (a^2*cot(e/2 + (f*x)/2)^7)/(14*c^5 *f) + (a^2*cot(e/2 + (f*x)/2)^9)/(36*c^5*f)
Time = 0.17 (sec) , antiderivative size = 50, normalized size of antiderivative = 0.41 \[ \int \frac {\sec (e+f x) (a+a \sec (e+f x))^2}{(c-c \sec (e+f x))^5} \, dx=\frac {a^{2} \left (63 \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{4}-90 \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{2}+35\right )}{1260 \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{9} c^{5} f} \] Input:
int(sec(f*x+e)*(a+a*sec(f*x+e))^2/(c-c*sec(f*x+e))^5,x)
Output:
(a**2*(63*tan((e + f*x)/2)**4 - 90*tan((e + f*x)/2)**2 + 35))/(1260*tan((e + f*x)/2)**9*c**5*f)