Integrand size = 31, antiderivative size = 95 \[ \int \frac {(a+i a \tan (e+f x))^4}{c-i c \tan (e+f x)} \, dx=-\frac {12 a^4 x}{c}+\frac {12 i a^4 \log (\cos (e+f x))}{c f}+\frac {5 a^4 \tan (e+f x)}{c f}+\frac {i a^4 \tan ^2(e+f x)}{2 c f}-\frac {8 i a^4}{f (c-i c \tan (e+f x))} \] Output:
-12*a^4*x/c+12*I*a^4*ln(cos(f*x+e))/c/f+5*a^4*tan(f*x+e)/c/f+1/2*I*a^4*tan (f*x+e)^2/c/f-8*I*a^4/f/(c-I*c*tan(f*x+e))
Time = 2.56 (sec) , antiderivative size = 63, normalized size of antiderivative = 0.66 \[ \int \frac {(a+i a \tan (e+f x))^4}{c-i c \tan (e+f x)} \, dx=\frac {i a^4 \left (-24 \log (i+\tan (e+f x))-10 i \tan (e+f x)+\tan ^2(e+f x)-\frac {16 i}{i+\tan (e+f x)}\right )}{2 c f} \] Input:
Integrate[(a + I*a*Tan[e + f*x])^4/(c - I*c*Tan[e + f*x]),x]
Output:
((I/2)*a^4*(-24*Log[I + Tan[e + f*x]] - (10*I)*Tan[e + f*x] + Tan[e + f*x] ^2 - (16*I)/(I + Tan[e + f*x])))/(c*f)
Time = 0.37 (sec) , antiderivative size = 81, normalized size of antiderivative = 0.85, number of steps used = 7, number of rules used = 6, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.194, Rules used = {3042, 4005, 3042, 3968, 49, 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 {(a+i a \tan (e+f x))^4}{c-i c \tan (e+f x)} \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {(a+i a \tan (e+f x))^4}{c-i c \tan (e+f x)}dx\) |
\(\Big \downarrow \) 4005 |
\(\displaystyle a^4 c^4 \int \frac {\sec ^8(e+f x)}{(c-i c \tan (e+f x))^5}dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle a^4 c^4 \int \frac {\sec (e+f x)^8}{(c-i c \tan (e+f x))^5}dx\) |
\(\Big \downarrow \) 3968 |
\(\displaystyle \frac {i a^4 \int \frac {(i \tan (e+f x) c+c)^3}{(c-i c \tan (e+f x))^2}d(-i c \tan (e+f x))}{c^3 f}\) |
\(\Big \downarrow \) 49 |
\(\displaystyle \frac {i a^4 \int \left (\frac {8 c^3}{(c-i c \tan (e+f x))^2}-\frac {12 c^2}{c-i c \tan (e+f x)}+i \tan (e+f x) c+5 c\right )d(-i c \tan (e+f x))}{c^3 f}\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle \frac {i a^4 \left (-\frac {8 c^3}{c-i c \tan (e+f x)}+\frac {1}{2} c^2 \tan ^2(e+f x)-5 i c^2 \tan (e+f x)-12 c^2 \log (c-i c \tan (e+f x))\right )}{c^3 f}\) |
Input:
Int[(a + I*a*Tan[e + f*x])^4/(c - I*c*Tan[e + f*x]),x]
Output:
(I*a^4*(-12*c^2*Log[c - I*c*Tan[e + f*x]] - (5*I)*c^2*Tan[e + f*x] + (c^2* Tan[e + f*x]^2)/2 - (8*c^3)/(c - I*c*Tan[e + f*x])))/(c^3*f)
Int[((a_.) + (b_.)*(x_))^(m_.)*((c_.) + (d_.)*(x_))^(n_.), x_Symbol] :> Int [ExpandIntegrand[(a + b*x)^m*(c + d*x)^n, x], x] /; FreeQ[{a, b, c, d}, x] && IGtQ[m, 0] && IGtQ[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]
Int[((a_) + (b_.)*tan[(e_.) + (f_.)*(x_)])^(m_.)*((c_) + (d_.)*tan[(e_.) + (f_.)*(x_)])^(n_.), x_Symbol] :> Simp[a^m*c^m Int[Sec[e + f*x]^(2*m)*(c + d*Tan[e + f*x])^(n - m), x], x] /; FreeQ[{a, b, c, d, e, f, n}, x] && EqQ[ b*c + a*d, 0] && EqQ[a^2 + b^2, 0] && IntegerQ[m] && !(IGtQ[n, 0] && (LtQ[ m, 0] || GtQ[m, n]))
Time = 0.15 (sec) , antiderivative size = 97, normalized size of antiderivative = 1.02
method | result | size |
risch | \(-\frac {4 i a^{4} {\mathrm e}^{2 i \left (f x +e \right )}}{c f}+\frac {24 a^{4} e}{c f}+\frac {2 i a^{4} \left (6 \,{\mathrm e}^{2 i \left (f x +e \right )}+5\right )}{f c \left ({\mathrm e}^{2 i \left (f x +e \right )}+1\right )^{2}}+\frac {12 i a^{4} \ln \left ({\mathrm e}^{2 i \left (f x +e \right )}+1\right )}{f c}\) | \(97\) |
derivativedivides | \(\frac {5 a^{4} \tan \left (f x +e \right )}{c f}+\frac {i a^{4} \tan \left (f x +e \right )^{2}}{2 c f}-\frac {12 a^{4} \arctan \left (\tan \left (f x +e \right )\right )}{f c}-\frac {6 i a^{4} \ln \left (1+\tan \left (f x +e \right )^{2}\right )}{f c}+\frac {8 a^{4}}{f c \left (i+\tan \left (f x +e \right )\right )}\) | \(102\) |
default | \(\frac {5 a^{4} \tan \left (f x +e \right )}{c f}+\frac {i a^{4} \tan \left (f x +e \right )^{2}}{2 c f}-\frac {12 a^{4} \arctan \left (\tan \left (f x +e \right )\right )}{f c}-\frac {6 i a^{4} \ln \left (1+\tan \left (f x +e \right )^{2}\right )}{f c}+\frac {8 a^{4}}{f c \left (i+\tan \left (f x +e \right )\right )}\) | \(102\) |
norman | \(\frac {-\frac {12 a^{4} x}{c}-\frac {17 i a^{4}}{2 c f}-\frac {12 a^{4} x \tan \left (f x +e \right )^{2}}{c}+\frac {13 a^{4} \tan \left (f x +e \right )}{c f}+\frac {5 a^{4} \tan \left (f x +e \right )^{3}}{c f}+\frac {i a^{4} \tan \left (f x +e \right )^{4}}{2 c f}}{1+\tan \left (f x +e \right )^{2}}-\frac {6 i a^{4} \ln \left (1+\tan \left (f x +e \right )^{2}\right )}{f c}\) | \(133\) |
Input:
int((a+I*a*tan(f*x+e))^4/(c-I*c*tan(f*x+e)),x,method=_RETURNVERBOSE)
Output:
-4*I/c/f*a^4*exp(2*I*(f*x+e))+24/c/f*a^4*e+2*I*a^4*(6*exp(2*I*(f*x+e))+5)/ f/c/(exp(2*I*(f*x+e))+1)^2+12*I/f*a^4/c*ln(exp(2*I*(f*x+e))+1)
Time = 0.10 (sec) , antiderivative size = 129, normalized size of antiderivative = 1.36 \[ \int \frac {(a+i a \tan (e+f x))^4}{c-i c \tan (e+f x)} \, dx=-\frac {2 \, {\left (2 i \, a^{4} e^{\left (6 i \, f x + 6 i \, e\right )} + 4 i \, a^{4} e^{\left (4 i \, f x + 4 i \, e\right )} - 4 i \, a^{4} e^{\left (2 i \, f x + 2 i \, e\right )} - 5 i \, a^{4} + 6 \, {\left (-i \, a^{4} e^{\left (4 i \, f x + 4 i \, e\right )} - 2 i \, a^{4} e^{\left (2 i \, f x + 2 i \, e\right )} - i \, a^{4}\right )} \log \left (e^{\left (2 i \, f x + 2 i \, e\right )} + 1\right )\right )}}{c f e^{\left (4 i \, f x + 4 i \, e\right )} + 2 \, c f e^{\left (2 i \, f x + 2 i \, e\right )} + c f} \] Input:
integrate((a+I*a*tan(f*x+e))^4/(c-I*c*tan(f*x+e)),x, algorithm="fricas")
Output:
-2*(2*I*a^4*e^(6*I*f*x + 6*I*e) + 4*I*a^4*e^(4*I*f*x + 4*I*e) - 4*I*a^4*e^ (2*I*f*x + 2*I*e) - 5*I*a^4 + 6*(-I*a^4*e^(4*I*f*x + 4*I*e) - 2*I*a^4*e^(2 *I*f*x + 2*I*e) - I*a^4)*log(e^(2*I*f*x + 2*I*e) + 1))/(c*f*e^(4*I*f*x + 4 *I*e) + 2*c*f*e^(2*I*f*x + 2*I*e) + c*f)
Time = 0.38 (sec) , antiderivative size = 143, normalized size of antiderivative = 1.51 \[ \int \frac {(a+i a \tan (e+f x))^4}{c-i c \tan (e+f x)} \, dx=\frac {12 i a^{4} \log {\left (e^{2 i f x} + e^{- 2 i e} \right )}}{c f} + \frac {12 i a^{4} e^{2 i e} e^{2 i f x} + 10 i a^{4}}{c f e^{4 i e} e^{4 i f x} + 2 c f e^{2 i e} e^{2 i f x} + c f} + \begin {cases} - \frac {4 i a^{4} e^{2 i e} e^{2 i f x}}{c f} & \text {for}\: c f \neq 0 \\\frac {8 a^{4} x e^{2 i e}}{c} & \text {otherwise} \end {cases} \] Input:
integrate((a+I*a*tan(f*x+e))**4/(c-I*c*tan(f*x+e)),x)
Output:
12*I*a**4*log(exp(2*I*f*x) + exp(-2*I*e))/(c*f) + (12*I*a**4*exp(2*I*e)*ex p(2*I*f*x) + 10*I*a**4)/(c*f*exp(4*I*e)*exp(4*I*f*x) + 2*c*f*exp(2*I*e)*ex p(2*I*f*x) + c*f) + Piecewise((-4*I*a**4*exp(2*I*e)*exp(2*I*f*x)/(c*f), Ne (c*f, 0)), (8*a**4*x*exp(2*I*e)/c, True))
Exception generated. \[ \int \frac {(a+i a \tan (e+f x))^4}{c-i c \tan (e+f x)} \, dx=\text {Exception raised: RuntimeError} \] Input:
integrate((a+I*a*tan(f*x+e))^4/(c-I*c*tan(f*x+e)),x, algorithm="maxima")
Output:
Exception raised: RuntimeError >> ECL says: expt: undefined: 0 to a negati ve exponent.
Time = 0.58 (sec) , antiderivative size = 79, normalized size of antiderivative = 0.83 \[ \int \frac {(a+i a \tan (e+f x))^4}{c-i c \tan (e+f x)} \, dx=-\frac {12 i \, a^{4} \log \left (\tan \left (f x + e\right ) + i\right )}{c f} + \frac {8 \, a^{4}}{c f {\left (\tan \left (f x + e\right ) + i\right )}} - \frac {-i \, a^{4} c f \tan \left (f x + e\right )^{2} - 10 \, a^{4} c f \tan \left (f x + e\right )}{2 \, c^{2} f^{2}} \] Input:
integrate((a+I*a*tan(f*x+e))^4/(c-I*c*tan(f*x+e)),x, algorithm="giac")
Output:
-12*I*a^4*log(tan(f*x + e) + I)/(c*f) + 8*a^4/(c*f*(tan(f*x + e) + I)) - 1 /2*(-I*a^4*c*f*tan(f*x + e)^2 - 10*a^4*c*f*tan(f*x + e))/(c^2*f^2)
Time = 1.85 (sec) , antiderivative size = 82, normalized size of antiderivative = 0.86 \[ \int \frac {(a+i a \tan (e+f x))^4}{c-i c \tan (e+f x)} \, dx=\frac {5\,a^4\,\mathrm {tan}\left (e+f\,x\right )}{c\,f}+\frac {a^4\,{\mathrm {tan}\left (e+f\,x\right )}^2\,1{}\mathrm {i}}{2\,c\,f}+\frac {8\,a^4}{c\,f\,\left (\mathrm {tan}\left (e+f\,x\right )+1{}\mathrm {i}\right )}-\frac {a^4\,\ln \left (\mathrm {tan}\left (e+f\,x\right )+1{}\mathrm {i}\right )\,12{}\mathrm {i}}{c\,f} \] Input:
int((a + a*tan(e + f*x)*1i)^4/(c - c*tan(e + f*x)*1i),x)
Output:
(5*a^4*tan(e + f*x))/(c*f) + (a^4*tan(e + f*x)^2*1i)/(2*c*f) + (8*a^4)/(c* f*(tan(e + f*x) + 1i)) - (a^4*log(tan(e + f*x) + 1i)*12i)/(c*f)
\[ \int \frac {(a+i a \tan (e+f x))^4}{c-i c \tan (e+f x)} \, dx=\frac {a^{4} \left (-32 \left (\int \frac {1}{\tan \left (f x +e \right ) i -1}d x \right ) f -12 \,\mathrm {log}\left (\tan \left (f x +e \right )^{2}+1\right ) i +\tan \left (f x +e \right )^{2} i +10 \tan \left (f x +e \right )-40 f x \right )}{2 c f} \] Input:
int((a+I*a*tan(f*x+e))^4/(c-I*c*tan(f*x+e)),x)
Output:
(a**4*( - 32*int(1/(tan(e + f*x)*i - 1),x)*f - 12*log(tan(e + f*x)**2 + 1) *i + tan(e + f*x)**2*i + 10*tan(e + f*x) - 40*f*x))/(2*c*f)