Integrand size = 24, antiderivative size = 209 \[ \int \frac {\cos ^4(c+d x)}{(a+i a \tan (c+d x))^3} \, dx=\frac {21 x}{128 a^3}+\frac {i a^2}{40 d (a+i a \tan (c+d x))^5}+\frac {i}{16 d (a+i a \tan (c+d x))^3}+\frac {3 i a^5}{64 d \left (a^2+i a^2 \tan (c+d x)\right )^4}-\frac {3 i}{64 d \left (a^3-i a^3 \tan (c+d x)\right )}+\frac {15 i}{128 d \left (a^3+i a^3 \tan (c+d x)\right )}-\frac {i a^5}{128 d \left (a^4-i a^4 \tan (c+d x)\right )^2}+\frac {5 i a^5}{64 d \left (a^4+i a^4 \tan (c+d x)\right )^2} \] Output:
21/128*x/a^3+1/40*I*a^2/d/(a+I*a*tan(d*x+c))^5+1/16*I/d/(a+I*a*tan(d*x+c)) ^3+3/64*I*a^5/d/(a^2+I*a^2*tan(d*x+c))^4-3/64*I/d/(a^3-I*a^3*tan(d*x+c))+1 5/128*I/d/(a^3+I*a^3*tan(d*x+c))-1/128*I*a^5/d/(a^4-I*a^4*tan(d*x+c))^2+5/ 64*I*a^5/d/(a^4+I*a^4*tan(d*x+c))^2
Time = 0.33 (sec) , antiderivative size = 159, normalized size of antiderivative = 0.76 \[ \int \frac {\cos ^4(c+d x)}{(a+i a \tan (c+d x))^3} \, dx=\frac {\sec ^7(c+d x) (-1050 \cos (c+d x)-469 \cos (3 (c+d x))+105 \cos (5 (c+d x))+6 \cos (7 (c+d x))-350 i \sin (c+d x)+840 i \arctan (\tan (c+d x)) (\cos (3 (c+d x))+i \sin (3 (c+d x)))-189 i \sin (3 (c+d x))+175 i \sin (5 (c+d x))+14 i \sin (7 (c+d x)))}{5120 a^3 d (-i+\tan (c+d x))^5 (i+\tan (c+d x))^2} \] Input:
Integrate[Cos[c + d*x]^4/(a + I*a*Tan[c + d*x])^3,x]
Output:
(Sec[c + d*x]^7*(-1050*Cos[c + d*x] - 469*Cos[3*(c + d*x)] + 105*Cos[5*(c + d*x)] + 6*Cos[7*(c + d*x)] - (350*I)*Sin[c + d*x] + (840*I)*ArcTan[Tan[c + d*x]]*(Cos[3*(c + d*x)] + I*Sin[3*(c + d*x)]) - (189*I)*Sin[3*(c + d*x) ] + (175*I)*Sin[5*(c + d*x)] + (14*I)*Sin[7*(c + d*x)]))/(5120*a^3*d*(-I + Tan[c + d*x])^5*(I + Tan[c + d*x])^2)
Time = 0.35 (sec) , antiderivative size = 181, normalized size of antiderivative = 0.87, number of steps used = 5, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.167, Rules used = {3042, 3968, 54, 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 \frac {\cos ^4(c+d x)}{(a+i a \tan (c+d x))^3} \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {1}{\sec (c+d x)^4 (a+i a \tan (c+d x))^3}dx\) |
\(\Big \downarrow \) 3968 |
\(\displaystyle -\frac {i a^5 \int \frac {1}{(a-i a \tan (c+d x))^3 (i \tan (c+d x) a+a)^6}d(i a \tan (c+d x))}{d}\) |
\(\Big \downarrow \) 54 |
\(\displaystyle -\frac {i a^5 \int \left (\frac {3}{64 a^7 (a-i a \tan (c+d x))^2}+\frac {15}{128 a^7 (i \tan (c+d x) a+a)^2}+\frac {1}{64 a^6 (a-i a \tan (c+d x))^3}+\frac {5}{32 a^6 (i \tan (c+d x) a+a)^3}+\frac {3}{16 a^5 (i \tan (c+d x) a+a)^4}+\frac {3}{16 a^4 (i \tan (c+d x) a+a)^5}+\frac {1}{8 a^3 (i \tan (c+d x) a+a)^6}+\frac {21}{128 a^7 \left (\tan ^2(c+d x) a^2+a^2\right )}\right )d(i a \tan (c+d x))}{d}\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle -\frac {i a^5 \left (\frac {21 i \arctan (\tan (c+d x))}{128 a^8}+\frac {3}{64 a^7 (a-i a \tan (c+d x))}-\frac {15}{128 a^7 (a+i a \tan (c+d x))}+\frac {1}{128 a^6 (a-i a \tan (c+d x))^2}-\frac {5}{64 a^6 (a+i a \tan (c+d x))^2}-\frac {1}{16 a^5 (a+i a \tan (c+d x))^3}-\frac {3}{64 a^4 (a+i a \tan (c+d x))^4}-\frac {1}{40 a^3 (a+i a \tan (c+d x))^5}\right )}{d}\) |
Input:
Int[Cos[c + d*x]^4/(a + I*a*Tan[c + d*x])^3,x]
Output:
((-I)*a^5*((((21*I)/128)*ArcTan[Tan[c + d*x]])/a^8 + 1/(128*a^6*(a - I*a*T an[c + d*x])^2) + 3/(64*a^7*(a - I*a*Tan[c + d*x])) - 1/(40*a^3*(a + I*a*T an[c + d*x])^5) - 3/(64*a^4*(a + I*a*Tan[c + d*x])^4) - 1/(16*a^5*(a + I*a *Tan[c + d*x])^3) - 5/(64*a^6*(a + I*a*Tan[c + d*x])^2) - 15/(128*a^7*(a + I*a*Tan[c + d*x]))))/d
Int[((a_) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_.), x_Symbol] :> Int[E xpandIntegrand[(a + b*x)^m*(c + d*x)^n, x], x] /; FreeQ[{a, b, c, d}, x] && ILtQ[m, 0] && IntegerQ[n] && !(IGtQ[n, 0] && LtQ[m + n + 2, 0])
Int[sec[(e_.) + (f_.)*(x_)]^(m_)*((a_) + (b_.)*tan[(e_.) + (f_.)*(x_)])^(n_ ), x_Symbol] :> Simp[1/(a^(m - 2)*b*f) Subst[Int[(a - x)^(m/2 - 1)*(a + x )^(n + m/2 - 1), x], x, b*Tan[e + f*x]], x] /; FreeQ[{a, b, e, f, n}, x] && EqQ[a^2 + b^2, 0] && IntegerQ[m/2]
Time = 1.13 (sec) , antiderivative size = 129, normalized size of antiderivative = 0.62
method | result | size |
derivativedivides | \(\frac {-\frac {21 i \ln \left (-i+\tan \left (d x +c \right )\right )}{256}+\frac {3 i}{64 \left (-i+\tan \left (d x +c \right )\right )^{4}}-\frac {5 i}{64 \left (-i+\tan \left (d x +c \right )\right )^{2}}+\frac {1}{40 \left (-i+\tan \left (d x +c \right )\right )^{5}}-\frac {1}{16 \left (-i+\tan \left (d x +c \right )\right )^{3}}+\frac {15}{128 \left (-i+\tan \left (d x +c \right )\right )}+\frac {i}{128 \left (\tan \left (d x +c \right )+i\right )^{2}}+\frac {21 i \ln \left (\tan \left (d x +c \right )+i\right )}{256}+\frac {3}{64 \left (\tan \left (d x +c \right )+i\right )}}{d \,a^{3}}\) | \(129\) |
default | \(\frac {-\frac {21 i \ln \left (-i+\tan \left (d x +c \right )\right )}{256}+\frac {3 i}{64 \left (-i+\tan \left (d x +c \right )\right )^{4}}-\frac {5 i}{64 \left (-i+\tan \left (d x +c \right )\right )^{2}}+\frac {1}{40 \left (-i+\tan \left (d x +c \right )\right )^{5}}-\frac {1}{16 \left (-i+\tan \left (d x +c \right )\right )^{3}}+\frac {15}{128 \left (-i+\tan \left (d x +c \right )\right )}+\frac {i}{128 \left (\tan \left (d x +c \right )+i\right )^{2}}+\frac {21 i \ln \left (\tan \left (d x +c \right )+i\right )}{256}+\frac {3}{64 \left (\tan \left (d x +c \right )+i\right )}}{d \,a^{3}}\) | \(129\) |
risch | \(\frac {21 x}{128 a^{3}}+\frac {7 i {\mathrm e}^{-6 i \left (d x +c \right )}}{256 a^{3} d}+\frac {7 i {\mathrm e}^{-8 i \left (d x +c \right )}}{1024 a^{3} d}+\frac {i {\mathrm e}^{-10 i \left (d x +c \right )}}{1280 a^{3} d}+\frac {17 i \cos \left (4 d x +4 c \right )}{256 a^{3} d}+\frac {9 \sin \left (4 d x +4 c \right )}{128 a^{3} d}+\frac {7 i \cos \left (2 d x +2 c \right )}{64 a^{3} d}+\frac {21 \sin \left (2 d x +2 c \right )}{128 a^{3} d}\) | \(132\) |
Input:
int(cos(d*x+c)^4/(a+I*a*tan(d*x+c))^3,x,method=_RETURNVERBOSE)
Output:
1/d/a^3*(-21/256*I*ln(-I+tan(d*x+c))+3/64*I/(-I+tan(d*x+c))^4-5/64*I/(-I+t an(d*x+c))^2+1/40/(-I+tan(d*x+c))^5-1/16/(-I+tan(d*x+c))^3+15/128/(-I+tan( d*x+c))+1/128*I/(tan(d*x+c)+I)^2+21/256*I*ln(tan(d*x+c)+I)+3/64/(tan(d*x+c )+I))
Time = 0.08 (sec) , antiderivative size = 98, normalized size of antiderivative = 0.47 \[ \int \frac {\cos ^4(c+d x)}{(a+i a \tan (c+d x))^3} \, dx=\frac {{\left (840 \, d x e^{\left (10 i \, d x + 10 i \, c\right )} - 10 i \, e^{\left (14 i \, d x + 14 i \, c\right )} - 140 i \, e^{\left (12 i \, d x + 12 i \, c\right )} + 700 i \, e^{\left (8 i \, d x + 8 i \, c\right )} + 350 i \, e^{\left (6 i \, d x + 6 i \, c\right )} + 140 i \, e^{\left (4 i \, d x + 4 i \, c\right )} + 35 i \, e^{\left (2 i \, d x + 2 i \, c\right )} + 4 i\right )} e^{\left (-10 i \, d x - 10 i \, c\right )}}{5120 \, a^{3} d} \] Input:
integrate(cos(d*x+c)^4/(a+I*a*tan(d*x+c))^3,x, algorithm="fricas")
Output:
1/5120*(840*d*x*e^(10*I*d*x + 10*I*c) - 10*I*e^(14*I*d*x + 14*I*c) - 140*I *e^(12*I*d*x + 12*I*c) + 700*I*e^(8*I*d*x + 8*I*c) + 350*I*e^(6*I*d*x + 6* I*c) + 140*I*e^(4*I*d*x + 4*I*c) + 35*I*e^(2*I*d*x + 2*I*c) + 4*I)*e^(-10* I*d*x - 10*I*c)/(a^3*d)
Time = 0.31 (sec) , antiderivative size = 292, normalized size of antiderivative = 1.40 \[ \int \frac {\cos ^4(c+d x)}{(a+i a \tan (c+d x))^3} \, dx=\begin {cases} \frac {\left (- 11258999068426240 i a^{18} d^{6} e^{34 i c} e^{4 i d x} - 157625986957967360 i a^{18} d^{6} e^{32 i c} e^{2 i d x} + 788129934789836800 i a^{18} d^{6} e^{28 i c} e^{- 2 i d x} + 394064967394918400 i a^{18} d^{6} e^{26 i c} e^{- 4 i d x} + 157625986957967360 i a^{18} d^{6} e^{24 i c} e^{- 6 i d x} + 39406496739491840 i a^{18} d^{6} e^{22 i c} e^{- 8 i d x} + 4503599627370496 i a^{18} d^{6} e^{20 i c} e^{- 10 i d x}\right ) e^{- 30 i c}}{5764607523034234880 a^{21} d^{7}} & \text {for}\: a^{21} d^{7} e^{30 i c} \neq 0 \\x \left (\frac {\left (e^{14 i c} + 7 e^{12 i c} + 21 e^{10 i c} + 35 e^{8 i c} + 35 e^{6 i c} + 21 e^{4 i c} + 7 e^{2 i c} + 1\right ) e^{- 10 i c}}{128 a^{3}} - \frac {21}{128 a^{3}}\right ) & \text {otherwise} \end {cases} + \frac {21 x}{128 a^{3}} \] Input:
integrate(cos(d*x+c)**4/(a+I*a*tan(d*x+c))**3,x)
Output:
Piecewise(((-11258999068426240*I*a**18*d**6*exp(34*I*c)*exp(4*I*d*x) - 157 625986957967360*I*a**18*d**6*exp(32*I*c)*exp(2*I*d*x) + 788129934789836800 *I*a**18*d**6*exp(28*I*c)*exp(-2*I*d*x) + 394064967394918400*I*a**18*d**6* exp(26*I*c)*exp(-4*I*d*x) + 157625986957967360*I*a**18*d**6*exp(24*I*c)*ex p(-6*I*d*x) + 39406496739491840*I*a**18*d**6*exp(22*I*c)*exp(-8*I*d*x) + 4 503599627370496*I*a**18*d**6*exp(20*I*c)*exp(-10*I*d*x))*exp(-30*I*c)/(576 4607523034234880*a**21*d**7), Ne(a**21*d**7*exp(30*I*c), 0)), (x*((exp(14* I*c) + 7*exp(12*I*c) + 21*exp(10*I*c) + 35*exp(8*I*c) + 35*exp(6*I*c) + 21 *exp(4*I*c) + 7*exp(2*I*c) + 1)*exp(-10*I*c)/(128*a**3) - 21/(128*a**3)), True)) + 21*x/(128*a**3)
Exception generated. \[ \int \frac {\cos ^4(c+d x)}{(a+i a \tan (c+d x))^3} \, dx=\text {Exception raised: RuntimeError} \] Input:
integrate(cos(d*x+c)^4/(a+I*a*tan(d*x+c))^3,x, algorithm="maxima")
Output:
Exception raised: RuntimeError >> ECL says: expt: undefined: 0 to a negati ve exponent.
Time = 0.22 (sec) , antiderivative size = 123, normalized size of antiderivative = 0.59 \[ \int \frac {\cos ^4(c+d x)}{(a+i a \tan (c+d x))^3} \, dx=\frac {21 i \, \log \left (\tan \left (d x + c\right ) + i\right )}{256 \, a^{3} d} - \frac {21 i \, \log \left (\tan \left (d x + c\right ) - i\right )}{256 \, a^{3} d} - \frac {i \, {\left (105 i \, \tan \left (d x + c\right )^{6} + 315 \, \tan \left (d x + c\right )^{5} - 140 i \, \tan \left (d x + c\right )^{4} + 420 \, \tan \left (d x + c\right )^{3} - 469 i \, \tan \left (d x + c\right )^{2} - 7 \, \tan \left (d x + c\right ) - 176 i\right )}}{640 \, a^{3} d {\left (\tan \left (d x + c\right ) + i\right )}^{2} {\left (\tan \left (d x + c\right ) - i\right )}^{5}} \] Input:
integrate(cos(d*x+c)^4/(a+I*a*tan(d*x+c))^3,x, algorithm="giac")
Output:
21/256*I*log(tan(d*x + c) + I)/(a^3*d) - 21/256*I*log(tan(d*x + c) - I)/(a ^3*d) - 1/640*I*(105*I*tan(d*x + c)^6 + 315*tan(d*x + c)^5 - 140*I*tan(d*x + c)^4 + 420*tan(d*x + c)^3 - 469*I*tan(d*x + c)^2 - 7*tan(d*x + c) - 176 *I)/(a^3*d*(tan(d*x + c) + I)^2*(tan(d*x + c) - I)^5)
Time = 2.20 (sec) , antiderivative size = 173, normalized size of antiderivative = 0.83 \[ \int \frac {\cos ^4(c+d x)}{(a+i a \tan (c+d x))^3} \, dx=\frac {21\,x}{128\,a^3}+\frac {\frac {7\,\mathrm {tan}\left (c+d\,x\right )}{640\,a^3}+\frac {11{}\mathrm {i}}{40\,a^3}+\frac {{\mathrm {tan}\left (c+d\,x\right )}^2\,469{}\mathrm {i}}{640\,a^3}-\frac {21\,{\mathrm {tan}\left (c+d\,x\right )}^3}{32\,a^3}+\frac {{\mathrm {tan}\left (c+d\,x\right )}^4\,7{}\mathrm {i}}{32\,a^3}-\frac {63\,{\mathrm {tan}\left (c+d\,x\right )}^5}{128\,a^3}-\frac {{\mathrm {tan}\left (c+d\,x\right )}^6\,21{}\mathrm {i}}{128\,a^3}}{d\,\left (-{\mathrm {tan}\left (c+d\,x\right )}^7\,1{}\mathrm {i}-3\,{\mathrm {tan}\left (c+d\,x\right )}^6+{\mathrm {tan}\left (c+d\,x\right )}^5\,1{}\mathrm {i}-5\,{\mathrm {tan}\left (c+d\,x\right )}^4+{\mathrm {tan}\left (c+d\,x\right )}^3\,5{}\mathrm {i}-{\mathrm {tan}\left (c+d\,x\right )}^2+\mathrm {tan}\left (c+d\,x\right )\,3{}\mathrm {i}+1\right )} \] Input:
int(cos(c + d*x)^4/(a + a*tan(c + d*x)*1i)^3,x)
Output:
(21*x)/(128*a^3) + ((7*tan(c + d*x))/(640*a^3) + 11i/(40*a^3) + (tan(c + d *x)^2*469i)/(640*a^3) - (21*tan(c + d*x)^3)/(32*a^3) + (tan(c + d*x)^4*7i) /(32*a^3) - (63*tan(c + d*x)^5)/(128*a^3) - (tan(c + d*x)^6*21i)/(128*a^3) )/(d*(tan(c + d*x)*3i - tan(c + d*x)^2 + tan(c + d*x)^3*5i - 5*tan(c + d*x )^4 + tan(c + d*x)^5*1i - 3*tan(c + d*x)^6 - tan(c + d*x)^7*1i + 1))
\[ \int \frac {\cos ^4(c+d x)}{(a+i a \tan (c+d x))^3} \, dx=-\frac {\int \frac {\cos \left (d x +c \right )^{4}}{\tan \left (d x +c \right )^{3} i +3 \tan \left (d x +c \right )^{2}-3 \tan \left (d x +c \right ) i -1}d x}{a^{3}} \] Input:
int(cos(d*x+c)^4/(a+I*a*tan(d*x+c))^3,x)
Output:
( - int(cos(c + d*x)**4/(tan(c + d*x)**3*i + 3*tan(c + d*x)**2 - 3*tan(c + d*x)*i - 1),x))/a**3