Integrand size = 31, antiderivative size = 366 \[ \int \sec ^m(c+d x) (a+b \sec (c+d x))^3 (A+B \sec (c+d x)) \, dx=\frac {b \left (b^2 B (2+m)+3 a A b (3+m)+2 a^2 B (4+m)\right ) \sec ^{1+m}(c+d x) \sin (c+d x)}{d (1+m) (3+m)}+\frac {b^2 (A b (3+m)+a B (5+m)) \sec ^{2+m}(c+d x) \sin (c+d x)}{d (2+m) (3+m)}+\frac {b B \sec ^{1+m}(c+d x) (a+b \sec (c+d x))^2 \sin (c+d x)}{d (3+m)}-\frac {\left (b^3 B m (2+m)+3 a A b^2 m (3+m)+3 a^2 b B m (3+m)+a^3 A \left (3+4 m+m^2\right )\right ) \operatorname {Hypergeometric2F1}\left (\frac {1}{2},\frac {1-m}{2},\frac {3-m}{2},\cos ^2(c+d x)\right ) \sec ^{-1+m}(c+d x) \sin (c+d x)}{d (3+m) \left (1-m^2\right ) \sqrt {\sin ^2(c+d x)}}+\frac {\left (A b^3 (1+m)+3 a b^2 B (1+m)+3 a^2 A b (2+m)+a^3 B (2+m)\right ) \operatorname {Hypergeometric2F1}\left (\frac {1}{2},-\frac {m}{2},\frac {2-m}{2},\cos ^2(c+d x)\right ) \sec ^m(c+d x) \sin (c+d x)}{d m (2+m) \sqrt {\sin ^2(c+d x)}} \] Output:
b*(b^2*B*(2+m)+3*a*A*b*(3+m)+2*a^2*B*(4+m))*sec(d*x+c)^(1+m)*sin(d*x+c)/d/ (1+m)/(3+m)+b^2*(A*b*(3+m)+a*B*(5+m))*sec(d*x+c)^(2+m)*sin(d*x+c)/d/(2+m)/ (3+m)+b*B*sec(d*x+c)^(1+m)*(a+b*sec(d*x+c))^2*sin(d*x+c)/d/(3+m)-(b^3*B*m* (2+m)+3*a*A*b^2*m*(3+m)+3*a^2*b*B*m*(3+m)+a^3*A*(m^2+4*m+3))*hypergeom([1/ 2, 1/2-1/2*m],[3/2-1/2*m],cos(d*x+c)^2)*sec(d*x+c)^(-1+m)*sin(d*x+c)/d/(3+ m)/(-m^2+1)/(sin(d*x+c)^2)^(1/2)+(A*b^3*(1+m)+3*a*b^2*B*(1+m)+3*a^2*A*b*(2 +m)+a^3*B*(2+m))*hypergeom([1/2, -1/2*m],[1-1/2*m],cos(d*x+c)^2)*sec(d*x+c )^m*sin(d*x+c)/d/m/(2+m)/(sin(d*x+c)^2)^(1/2)
Time = 1.50 (sec) , antiderivative size = 307, normalized size of antiderivative = 0.84 \[ \int \sec ^m(c+d x) (a+b \sec (c+d x))^3 (A+B \sec (c+d x)) \, dx=\frac {\csc (c+d x) \left (\frac {a^3 A \cos ^4(c+d x) \operatorname {Hypergeometric2F1}\left (\frac {1}{2},\frac {m}{2},\frac {2+m}{2},\sec ^2(c+d x)\right )}{m}+\frac {a^2 (3 A b+a B) \cos ^3(c+d x) \operatorname {Hypergeometric2F1}\left (\frac {1}{2},\frac {1+m}{2},\frac {3+m}{2},\sec ^2(c+d x)\right )}{1+m}+b \left (\frac {3 a (A b+a B) \cos ^2(c+d x) \operatorname {Hypergeometric2F1}\left (\frac {1}{2},\frac {2+m}{2},\frac {4+m}{2},\sec ^2(c+d x)\right )}{2+m}+b \left (\frac {(A b+3 a B) \cos (c+d x) \operatorname {Hypergeometric2F1}\left (\frac {1}{2},\frac {3+m}{2},\frac {5+m}{2},\sec ^2(c+d x)\right )}{3+m}+\frac {b B \operatorname {Hypergeometric2F1}\left (\frac {1}{2},\frac {4+m}{2},\frac {6+m}{2},\sec ^2(c+d x)\right )}{4+m}\right )\right )\right ) \sec ^{-1+m}(c+d x) (a+b \sec (c+d x))^3 (A+B \sec (c+d x)) \sqrt {-\tan ^2(c+d x)}}{d (b+a \cos (c+d x))^3 (B+A \cos (c+d x))} \] Input:
Integrate[Sec[c + d*x]^m*(a + b*Sec[c + d*x])^3*(A + B*Sec[c + d*x]),x]
Output:
(Csc[c + d*x]*((a^3*A*Cos[c + d*x]^4*Hypergeometric2F1[1/2, m/2, (2 + m)/2 , Sec[c + d*x]^2])/m + (a^2*(3*A*b + a*B)*Cos[c + d*x]^3*Hypergeometric2F1 [1/2, (1 + m)/2, (3 + m)/2, Sec[c + d*x]^2])/(1 + m) + b*((3*a*(A*b + a*B) *Cos[c + d*x]^2*Hypergeometric2F1[1/2, (2 + m)/2, (4 + m)/2, Sec[c + d*x]^ 2])/(2 + m) + b*(((A*b + 3*a*B)*Cos[c + d*x]*Hypergeometric2F1[1/2, (3 + m )/2, (5 + m)/2, Sec[c + d*x]^2])/(3 + m) + (b*B*Hypergeometric2F1[1/2, (4 + m)/2, (6 + m)/2, Sec[c + d*x]^2])/(4 + m))))*Sec[c + d*x]^(-1 + m)*(a + b*Sec[c + d*x])^3*(A + B*Sec[c + d*x])*Sqrt[-Tan[c + d*x]^2])/(d*(b + a*Co s[c + d*x])^3*(B + A*Cos[c + d*x]))
Time = 2.08 (sec) , antiderivative size = 372, normalized size of antiderivative = 1.02, number of steps used = 15, number of rules used = 15, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.484, Rules used = {3042, 4514, 3042, 4564, 3042, 4535, 3042, 4259, 3042, 3122, 4534, 3042, 4259, 3042, 3122}
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 \sec ^m(c+d x) (a+b \sec (c+d x))^3 (A+B \sec (c+d x)) \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \csc \left (c+d x+\frac {\pi }{2}\right )^m \left (a+b \csc \left (c+d x+\frac {\pi }{2}\right )\right )^3 \left (A+B \csc \left (c+d x+\frac {\pi }{2}\right )\right )dx\) |
\(\Big \downarrow \) 4514 |
\(\displaystyle \frac {\int \sec ^m(c+d x) (a+b \sec (c+d x)) \left (b (A b (m+3)+a B (m+5)) \sec ^2(c+d x)+\left (B (m+2) b^2+a (2 A b+a B) (m+3)\right ) \sec (c+d x)+a (b B m+a A (m+3))\right )dx}{m+3}+\frac {b B \sin (c+d x) \sec ^{m+1}(c+d x) (a+b \sec (c+d x))^2}{d (m+3)}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {\int \csc \left (c+d x+\frac {\pi }{2}\right )^m \left (a+b \csc \left (c+d x+\frac {\pi }{2}\right )\right ) \left (b (A b (m+3)+a B (m+5)) \csc \left (c+d x+\frac {\pi }{2}\right )^2+\left (B (m+2) b^2+a (2 A b+a B) (m+3)\right ) \csc \left (c+d x+\frac {\pi }{2}\right )+a (b B m+a A (m+3))\right )dx}{m+3}+\frac {b B \sin (c+d x) \sec ^{m+1}(c+d x) (a+b \sec (c+d x))^2}{d (m+3)}\) |
\(\Big \downarrow \) 4564 |
\(\displaystyle \frac {\frac {\int \sec ^m(c+d x) \left ((m+2) (b B m+a A (m+3)) a^2+b (m+2) \left (2 B (m+4) a^2+3 A b (m+3) a+b^2 B (m+2)\right ) \sec ^2(c+d x)+(m+3) \left (B (m+2) a^3+3 A b (m+2) a^2+3 b^2 B (m+1) a+A b^3 (m+1)\right ) \sec (c+d x)\right )dx}{m+2}+\frac {b^2 \sin (c+d x) (a B (m+5)+A b (m+3)) \sec ^{m+2}(c+d x)}{d (m+2)}}{m+3}+\frac {b B \sin (c+d x) \sec ^{m+1}(c+d x) (a+b \sec (c+d x))^2}{d (m+3)}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {\frac {\int \csc \left (c+d x+\frac {\pi }{2}\right )^m \left ((m+2) (b B m+a A (m+3)) a^2+b (m+2) \left (2 B (m+4) a^2+3 A b (m+3) a+b^2 B (m+2)\right ) \csc \left (c+d x+\frac {\pi }{2}\right )^2+(m+3) \left (B (m+2) a^3+3 A b (m+2) a^2+3 b^2 B (m+1) a+A b^3 (m+1)\right ) \csc \left (c+d x+\frac {\pi }{2}\right )\right )dx}{m+2}+\frac {b^2 \sin (c+d x) (a B (m+5)+A b (m+3)) \sec ^{m+2}(c+d x)}{d (m+2)}}{m+3}+\frac {b B \sin (c+d x) \sec ^{m+1}(c+d x) (a+b \sec (c+d x))^2}{d (m+3)}\) |
\(\Big \downarrow \) 4535 |
\(\displaystyle \frac {\frac {\int \sec ^m(c+d x) \left ((m+2) (b B m+a A (m+3)) a^2+b (m+2) \left (2 B (m+4) a^2+3 A b (m+3) a+b^2 B (m+2)\right ) \sec ^2(c+d x)\right )dx+(m+3) \left (a^3 B (m+2)+3 a^2 A b (m+2)+3 a b^2 B (m+1)+A b^3 (m+1)\right ) \int \sec ^{m+1}(c+d x)dx}{m+2}+\frac {b^2 \sin (c+d x) (a B (m+5)+A b (m+3)) \sec ^{m+2}(c+d x)}{d (m+2)}}{m+3}+\frac {b B \sin (c+d x) \sec ^{m+1}(c+d x) (a+b \sec (c+d x))^2}{d (m+3)}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {\frac {\int \csc \left (c+d x+\frac {\pi }{2}\right )^m \left ((m+2) (b B m+a A (m+3)) a^2+b (m+2) \left (2 B (m+4) a^2+3 A b (m+3) a+b^2 B (m+2)\right ) \csc \left (c+d x+\frac {\pi }{2}\right )^2\right )dx+(m+3) \left (a^3 B (m+2)+3 a^2 A b (m+2)+3 a b^2 B (m+1)+A b^3 (m+1)\right ) \int \csc \left (c+d x+\frac {\pi }{2}\right )^{m+1}dx}{m+2}+\frac {b^2 \sin (c+d x) (a B (m+5)+A b (m+3)) \sec ^{m+2}(c+d x)}{d (m+2)}}{m+3}+\frac {b B \sin (c+d x) \sec ^{m+1}(c+d x) (a+b \sec (c+d x))^2}{d (m+3)}\) |
\(\Big \downarrow \) 4259 |
\(\displaystyle \frac {\frac {\int \csc \left (c+d x+\frac {\pi }{2}\right )^m \left ((m+2) (b B m+a A (m+3)) a^2+b (m+2) \left (2 B (m+4) a^2+3 A b (m+3) a+b^2 B (m+2)\right ) \csc \left (c+d x+\frac {\pi }{2}\right )^2\right )dx+(m+3) \left (a^3 B (m+2)+3 a^2 A b (m+2)+3 a b^2 B (m+1)+A b^3 (m+1)\right ) \cos ^m(c+d x) \sec ^m(c+d x) \int \cos ^{-m-1}(c+d x)dx}{m+2}+\frac {b^2 \sin (c+d x) (a B (m+5)+A b (m+3)) \sec ^{m+2}(c+d x)}{d (m+2)}}{m+3}+\frac {b B \sin (c+d x) \sec ^{m+1}(c+d x) (a+b \sec (c+d x))^2}{d (m+3)}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {\frac {\int \csc \left (c+d x+\frac {\pi }{2}\right )^m \left ((m+2) (b B m+a A (m+3)) a^2+b (m+2) \left (2 B (m+4) a^2+3 A b (m+3) a+b^2 B (m+2)\right ) \csc \left (c+d x+\frac {\pi }{2}\right )^2\right )dx+(m+3) \left (a^3 B (m+2)+3 a^2 A b (m+2)+3 a b^2 B (m+1)+A b^3 (m+1)\right ) \cos ^m(c+d x) \sec ^m(c+d x) \int \sin \left (c+d x+\frac {\pi }{2}\right )^{-m-1}dx}{m+2}+\frac {b^2 \sin (c+d x) (a B (m+5)+A b (m+3)) \sec ^{m+2}(c+d x)}{d (m+2)}}{m+3}+\frac {b B \sin (c+d x) \sec ^{m+1}(c+d x) (a+b \sec (c+d x))^2}{d (m+3)}\) |
\(\Big \downarrow \) 3122 |
\(\displaystyle \frac {\frac {\int \csc \left (c+d x+\frac {\pi }{2}\right )^m \left ((m+2) (b B m+a A (m+3)) a^2+b (m+2) \left (2 B (m+4) a^2+3 A b (m+3) a+b^2 B (m+2)\right ) \csc \left (c+d x+\frac {\pi }{2}\right )^2\right )dx+\frac {(m+3) \sin (c+d x) \left (a^3 B (m+2)+3 a^2 A b (m+2)+3 a b^2 B (m+1)+A b^3 (m+1)\right ) \sec ^m(c+d x) \operatorname {Hypergeometric2F1}\left (\frac {1}{2},-\frac {m}{2},\frac {2-m}{2},\cos ^2(c+d x)\right )}{d m \sqrt {\sin ^2(c+d x)}}}{m+2}+\frac {b^2 \sin (c+d x) (a B (m+5)+A b (m+3)) \sec ^{m+2}(c+d x)}{d (m+2)}}{m+3}+\frac {b B \sin (c+d x) \sec ^{m+1}(c+d x) (a+b \sec (c+d x))^2}{d (m+3)}\) |
\(\Big \downarrow \) 4534 |
\(\displaystyle \frac {\frac {\frac {(m+2) \left (a^3 A \left (m^2+4 m+3\right )+3 a^2 b B m (m+3)+3 a A b^2 m (m+3)+b^3 B m (m+2)\right ) \int \sec ^m(c+d x)dx}{m+1}+\frac {b (m+2) \sin (c+d x) \left (2 a^2 B (m+4)+3 a A b (m+3)+b^2 B (m+2)\right ) \sec ^{m+1}(c+d x)}{d (m+1)}+\frac {(m+3) \sin (c+d x) \left (a^3 B (m+2)+3 a^2 A b (m+2)+3 a b^2 B (m+1)+A b^3 (m+1)\right ) \sec ^m(c+d x) \operatorname {Hypergeometric2F1}\left (\frac {1}{2},-\frac {m}{2},\frac {2-m}{2},\cos ^2(c+d x)\right )}{d m \sqrt {\sin ^2(c+d x)}}}{m+2}+\frac {b^2 \sin (c+d x) (a B (m+5)+A b (m+3)) \sec ^{m+2}(c+d x)}{d (m+2)}}{m+3}+\frac {b B \sin (c+d x) \sec ^{m+1}(c+d x) (a+b \sec (c+d x))^2}{d (m+3)}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {\frac {\frac {(m+2) \left (a^3 A \left (m^2+4 m+3\right )+3 a^2 b B m (m+3)+3 a A b^2 m (m+3)+b^3 B m (m+2)\right ) \int \csc \left (c+d x+\frac {\pi }{2}\right )^mdx}{m+1}+\frac {b (m+2) \sin (c+d x) \left (2 a^2 B (m+4)+3 a A b (m+3)+b^2 B (m+2)\right ) \sec ^{m+1}(c+d x)}{d (m+1)}+\frac {(m+3) \sin (c+d x) \left (a^3 B (m+2)+3 a^2 A b (m+2)+3 a b^2 B (m+1)+A b^3 (m+1)\right ) \sec ^m(c+d x) \operatorname {Hypergeometric2F1}\left (\frac {1}{2},-\frac {m}{2},\frac {2-m}{2},\cos ^2(c+d x)\right )}{d m \sqrt {\sin ^2(c+d x)}}}{m+2}+\frac {b^2 \sin (c+d x) (a B (m+5)+A b (m+3)) \sec ^{m+2}(c+d x)}{d (m+2)}}{m+3}+\frac {b B \sin (c+d x) \sec ^{m+1}(c+d x) (a+b \sec (c+d x))^2}{d (m+3)}\) |
\(\Big \downarrow \) 4259 |
\(\displaystyle \frac {\frac {\frac {(m+2) \left (a^3 A \left (m^2+4 m+3\right )+3 a^2 b B m (m+3)+3 a A b^2 m (m+3)+b^3 B m (m+2)\right ) \cos ^m(c+d x) \sec ^m(c+d x) \int \cos ^{-m}(c+d x)dx}{m+1}+\frac {b (m+2) \sin (c+d x) \left (2 a^2 B (m+4)+3 a A b (m+3)+b^2 B (m+2)\right ) \sec ^{m+1}(c+d x)}{d (m+1)}+\frac {(m+3) \sin (c+d x) \left (a^3 B (m+2)+3 a^2 A b (m+2)+3 a b^2 B (m+1)+A b^3 (m+1)\right ) \sec ^m(c+d x) \operatorname {Hypergeometric2F1}\left (\frac {1}{2},-\frac {m}{2},\frac {2-m}{2},\cos ^2(c+d x)\right )}{d m \sqrt {\sin ^2(c+d x)}}}{m+2}+\frac {b^2 \sin (c+d x) (a B (m+5)+A b (m+3)) \sec ^{m+2}(c+d x)}{d (m+2)}}{m+3}+\frac {b B \sin (c+d x) \sec ^{m+1}(c+d x) (a+b \sec (c+d x))^2}{d (m+3)}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {\frac {\frac {(m+2) \left (a^3 A \left (m^2+4 m+3\right )+3 a^2 b B m (m+3)+3 a A b^2 m (m+3)+b^3 B m (m+2)\right ) \cos ^m(c+d x) \sec ^m(c+d x) \int \sin \left (c+d x+\frac {\pi }{2}\right )^{-m}dx}{m+1}+\frac {b (m+2) \sin (c+d x) \left (2 a^2 B (m+4)+3 a A b (m+3)+b^2 B (m+2)\right ) \sec ^{m+1}(c+d x)}{d (m+1)}+\frac {(m+3) \sin (c+d x) \left (a^3 B (m+2)+3 a^2 A b (m+2)+3 a b^2 B (m+1)+A b^3 (m+1)\right ) \sec ^m(c+d x) \operatorname {Hypergeometric2F1}\left (\frac {1}{2},-\frac {m}{2},\frac {2-m}{2},\cos ^2(c+d x)\right )}{d m \sqrt {\sin ^2(c+d x)}}}{m+2}+\frac {b^2 \sin (c+d x) (a B (m+5)+A b (m+3)) \sec ^{m+2}(c+d x)}{d (m+2)}}{m+3}+\frac {b B \sin (c+d x) \sec ^{m+1}(c+d x) (a+b \sec (c+d x))^2}{d (m+3)}\) |
\(\Big \downarrow \) 3122 |
\(\displaystyle \frac {\frac {\frac {b (m+2) \sin (c+d x) \left (2 a^2 B (m+4)+3 a A b (m+3)+b^2 B (m+2)\right ) \sec ^{m+1}(c+d x)}{d (m+1)}-\frac {(m+2) \sin (c+d x) \left (a^3 A \left (m^2+4 m+3\right )+3 a^2 b B m (m+3)+3 a A b^2 m (m+3)+b^3 B m (m+2)\right ) \sec ^{m-1}(c+d x) \operatorname {Hypergeometric2F1}\left (\frac {1}{2},\frac {1-m}{2},\frac {3-m}{2},\cos ^2(c+d x)\right )}{d (1-m) (m+1) \sqrt {\sin ^2(c+d x)}}+\frac {(m+3) \sin (c+d x) \left (a^3 B (m+2)+3 a^2 A b (m+2)+3 a b^2 B (m+1)+A b^3 (m+1)\right ) \sec ^m(c+d x) \operatorname {Hypergeometric2F1}\left (\frac {1}{2},-\frac {m}{2},\frac {2-m}{2},\cos ^2(c+d x)\right )}{d m \sqrt {\sin ^2(c+d x)}}}{m+2}+\frac {b^2 \sin (c+d x) (a B (m+5)+A b (m+3)) \sec ^{m+2}(c+d x)}{d (m+2)}}{m+3}+\frac {b B \sin (c+d x) \sec ^{m+1}(c+d x) (a+b \sec (c+d x))^2}{d (m+3)}\) |
Input:
Int[Sec[c + d*x]^m*(a + b*Sec[c + d*x])^3*(A + B*Sec[c + d*x]),x]
Output:
(b*B*Sec[c + d*x]^(1 + m)*(a + b*Sec[c + d*x])^2*Sin[c + d*x])/(d*(3 + m)) + ((b^2*(A*b*(3 + m) + a*B*(5 + m))*Sec[c + d*x]^(2 + m)*Sin[c + d*x])/(d *(2 + m)) + ((b*(2 + m)*(b^2*B*(2 + m) + 3*a*A*b*(3 + m) + 2*a^2*B*(4 + m) )*Sec[c + d*x]^(1 + m)*Sin[c + d*x])/(d*(1 + m)) - ((2 + m)*(b^3*B*m*(2 + m) + 3*a*A*b^2*m*(3 + m) + 3*a^2*b*B*m*(3 + m) + a^3*A*(3 + 4*m + m^2))*Hy pergeometric2F1[1/2, (1 - m)/2, (3 - m)/2, Cos[c + d*x]^2]*Sec[c + d*x]^(- 1 + m)*Sin[c + d*x])/(d*(1 - m)*(1 + m)*Sqrt[Sin[c + d*x]^2]) + ((3 + m)*( A*b^3*(1 + m) + 3*a*b^2*B*(1 + m) + 3*a^2*A*b*(2 + m) + a^3*B*(2 + m))*Hyp ergeometric2F1[1/2, -1/2*m, (2 - m)/2, Cos[c + d*x]^2]*Sec[c + d*x]^m*Sin[ c + d*x])/(d*m*Sqrt[Sin[c + d*x]^2]))/(2 + m))/(3 + m)
Int[((b_.)*sin[(c_.) + (d_.)*(x_)])^(n_), x_Symbol] :> Simp[Cos[c + d*x]*(( b*Sin[c + d*x])^(n + 1)/(b*d*(n + 1)*Sqrt[Cos[c + d*x]^2]))*Hypergeometric2 F1[1/2, (n + 1)/2, (n + 3)/2, Sin[c + d*x]^2], x] /; FreeQ[{b, c, d, n}, x] && !IntegerQ[2*n]
Int[(csc[(c_.) + (d_.)*(x_)]*(b_.))^(n_), x_Symbol] :> Simp[(b*Csc[c + d*x] )^(n - 1)*((Sin[c + d*x]/b)^(n - 1) Int[1/(Sin[c + d*x]/b)^n, x]), x] /; FreeQ[{b, c, d, n}, x] && !IntegerQ[n]
Int[(csc[(e_.) + (f_.)*(x_)]*(d_.))^(n_)*(csc[(e_.) + (f_.)*(x_)]*(b_.) + ( a_))^(m_)*(csc[(e_.) + (f_.)*(x_)]*(B_.) + (A_)), x_Symbol] :> Simp[(-b)*B* Cot[e + f*x]*(a + b*Csc[e + f*x])^(m - 1)*((d*Csc[e + f*x])^n/(f*(m + n))), x] + Simp[1/(m + n) Int[(a + b*Csc[e + f*x])^(m - 2)*(d*Csc[e + f*x])^n* Simp[a^2*A*(m + n) + a*b*B*n + (a*(2*A*b + a*B)*(m + n) + b^2*B*(m + n - 1) )*Csc[e + f*x] + b*(A*b*(m + n) + a*B*(2*m + n - 1))*Csc[e + f*x]^2, x], x] , x] /; FreeQ[{a, b, d, e, f, A, B, n}, x] && NeQ[A*b - a*B, 0] && NeQ[a^2 - b^2, 0] && GtQ[m, 1] && !(IGtQ[n, 1] && !IntegerQ[m])
Int[(csc[(e_.) + (f_.)*(x_)]*(b_.))^(m_.)*(csc[(e_.) + (f_.)*(x_)]^2*(C_.) + (A_)), x_Symbol] :> Simp[(-C)*Cot[e + f*x]*((b*Csc[e + f*x])^m/(f*(m + 1) )), x] + Simp[(C*m + A*(m + 1))/(m + 1) Int[(b*Csc[e + f*x])^m, x], x] /; FreeQ[{b, e, f, A, C, m}, x] && NeQ[C*m + A*(m + 1), 0] && !LeQ[m, -1]
Int[(csc[(e_.) + (f_.)*(x_)]*(b_.))^(m_.)*((A_.) + csc[(e_.) + (f_.)*(x_)]* (B_.) + csc[(e_.) + (f_.)*(x_)]^2*(C_.)), x_Symbol] :> Simp[B/b Int[(b*Cs c[e + f*x])^(m + 1), x], x] + Int[(b*Csc[e + f*x])^m*(A + C*Csc[e + f*x]^2) , x] /; FreeQ[{b, e, f, A, B, C, m}, x]
Int[((A_.) + csc[(e_.) + (f_.)*(x_)]*(B_.) + csc[(e_.) + (f_.)*(x_)]^2*(C_. ))*(csc[(e_.) + (f_.)*(x_)]*(d_.))^(n_.)*(csc[(e_.) + (f_.)*(x_)]*(b_.) + ( a_)), x_Symbol] :> Simp[(-b)*C*Csc[e + f*x]*Cot[e + f*x]*((d*Csc[e + f*x])^ n/(f*(n + 2))), x] + Simp[1/(n + 2) Int[(d*Csc[e + f*x])^n*Simp[A*a*(n + 2) + (B*a*(n + 2) + b*(C*(n + 1) + A*(n + 2)))*Csc[e + f*x] + (a*C + B*b)*( n + 2)*Csc[e + f*x]^2, x], x], x] /; FreeQ[{a, b, d, e, f, A, B, C, n}, x] && !LtQ[n, -1]
\[\int \sec \left (d x +c \right )^{m} \left (a +b \sec \left (d x +c \right )\right )^{3} \left (A +B \sec \left (d x +c \right )\right )d x\]
Input:
int(sec(d*x+c)^m*(a+b*sec(d*x+c))^3*(A+B*sec(d*x+c)),x)
Output:
int(sec(d*x+c)^m*(a+b*sec(d*x+c))^3*(A+B*sec(d*x+c)),x)
\[ \int \sec ^m(c+d x) (a+b \sec (c+d x))^3 (A+B \sec (c+d x)) \, dx=\int { {\left (B \sec \left (d x + c\right ) + A\right )} {\left (b \sec \left (d x + c\right ) + a\right )}^{3} \sec \left (d x + c\right )^{m} \,d x } \] Input:
integrate(sec(d*x+c)^m*(a+b*sec(d*x+c))^3*(A+B*sec(d*x+c)),x, algorithm="f ricas")
Output:
integral((B*b^3*sec(d*x + c)^4 + A*a^3 + (3*B*a*b^2 + A*b^3)*sec(d*x + c)^ 3 + 3*(B*a^2*b + A*a*b^2)*sec(d*x + c)^2 + (B*a^3 + 3*A*a^2*b)*sec(d*x + c ))*sec(d*x + c)^m, x)
\[ \int \sec ^m(c+d x) (a+b \sec (c+d x))^3 (A+B \sec (c+d x)) \, dx=\int \left (A + B \sec {\left (c + d x \right )}\right ) \left (a + b \sec {\left (c + d x \right )}\right )^{3} \sec ^{m}{\left (c + d x \right )}\, dx \] Input:
integrate(sec(d*x+c)**m*(a+b*sec(d*x+c))**3*(A+B*sec(d*x+c)),x)
Output:
Integral((A + B*sec(c + d*x))*(a + b*sec(c + d*x))**3*sec(c + d*x)**m, x)
\[ \int \sec ^m(c+d x) (a+b \sec (c+d x))^3 (A+B \sec (c+d x)) \, dx=\int { {\left (B \sec \left (d x + c\right ) + A\right )} {\left (b \sec \left (d x + c\right ) + a\right )}^{3} \sec \left (d x + c\right )^{m} \,d x } \] Input:
integrate(sec(d*x+c)^m*(a+b*sec(d*x+c))^3*(A+B*sec(d*x+c)),x, algorithm="m axima")
Output:
integrate((B*sec(d*x + c) + A)*(b*sec(d*x + c) + a)^3*sec(d*x + c)^m, x)
\[ \int \sec ^m(c+d x) (a+b \sec (c+d x))^3 (A+B \sec (c+d x)) \, dx=\int { {\left (B \sec \left (d x + c\right ) + A\right )} {\left (b \sec \left (d x + c\right ) + a\right )}^{3} \sec \left (d x + c\right )^{m} \,d x } \] Input:
integrate(sec(d*x+c)^m*(a+b*sec(d*x+c))^3*(A+B*sec(d*x+c)),x, algorithm="g iac")
Output:
integrate((B*sec(d*x + c) + A)*(b*sec(d*x + c) + a)^3*sec(d*x + c)^m, x)
Timed out. \[ \int \sec ^m(c+d x) (a+b \sec (c+d x))^3 (A+B \sec (c+d x)) \, dx=\int \left (A+\frac {B}{\cos \left (c+d\,x\right )}\right )\,{\left (a+\frac {b}{\cos \left (c+d\,x\right )}\right )}^3\,{\left (\frac {1}{\cos \left (c+d\,x\right )}\right )}^m \,d x \] Input:
int((A + B/cos(c + d*x))*(a + b/cos(c + d*x))^3*(1/cos(c + d*x))^m,x)
Output:
int((A + B/cos(c + d*x))*(a + b/cos(c + d*x))^3*(1/cos(c + d*x))^m, x)
\[ \int \sec ^m(c+d x) (a+b \sec (c+d x))^3 (A+B \sec (c+d x)) \, dx=\left (\int \sec \left (d x +c \right )^{m}d x \right ) a^{4}+\left (\int \sec \left (d x +c \right )^{m} \sec \left (d x +c \right )^{4}d x \right ) b^{4}+4 \left (\int \sec \left (d x +c \right )^{m} \sec \left (d x +c \right )^{3}d x \right ) a \,b^{3}+6 \left (\int \sec \left (d x +c \right )^{m} \sec \left (d x +c \right )^{2}d x \right ) a^{2} b^{2}+4 \left (\int \sec \left (d x +c \right )^{m} \sec \left (d x +c \right )d x \right ) a^{3} b \] Input:
int(sec(d*x+c)^m*(a+b*sec(d*x+c))^3*(A+B*sec(d*x+c)),x)
Output:
int(sec(c + d*x)**m,x)*a**4 + int(sec(c + d*x)**m*sec(c + d*x)**4,x)*b**4 + 4*int(sec(c + d*x)**m*sec(c + d*x)**3,x)*a*b**3 + 6*int(sec(c + d*x)**m* sec(c + d*x)**2,x)*a**2*b**2 + 4*int(sec(c + d*x)**m*sec(c + d*x),x)*a**3* b