Integrand size = 36, antiderivative size = 246 \[ \int \tan ^2(c+d x) (a+i a \tan (c+d x))^{5/2} (A+B \tan (c+d x)) \, dx=\frac {4 \sqrt {2} a^{5/2} (i A+B) \text {arctanh}\left (\frac {\sqrt {a+i a \tan (c+d x)}}{\sqrt {2} \sqrt {a}}\right )}{d}-\frac {8 a^2 (45 i A+46 B) \sqrt {a+i a \tan (c+d x)}}{105 d}+\frac {2 a^2 (45 i A+46 B) \tan ^2(c+d x) \sqrt {a+i a \tan (c+d x)}}{105 d}-\frac {2 a^2 (3 A-4 i B) \tan ^3(c+d x) \sqrt {a+i a \tan (c+d x)}}{21 d}-\frac {8 a (60 i A+59 B) (a+i a \tan (c+d x))^{3/2}}{315 d}+\frac {2 i a B \tan ^3(c+d x) (a+i a \tan (c+d x))^{3/2}}{9 d} \] Output:
4*2^(1/2)*a^(5/2)*(I*A+B)*arctanh(1/2*(a+I*a*tan(d*x+c))^(1/2)*2^(1/2)/a^( 1/2))/d-8/105*a^2*(45*I*A+46*B)*(a+I*a*tan(d*x+c))^(1/2)/d+2/105*a^2*(45*I *A+46*B)*tan(d*x+c)^2*(a+I*a*tan(d*x+c))^(1/2)/d-2/21*a^2*(3*A-4*I*B)*tan( d*x+c)^3*(a+I*a*tan(d*x+c))^(1/2)/d-8/315*a*(60*I*A+59*B)*(a+I*a*tan(d*x+c ))^(3/2)/d+2/9*I*a*B*tan(d*x+c)^3*(a+I*a*tan(d*x+c))^(3/2)/d
Time = 2.24 (sec) , antiderivative size = 151, normalized size of antiderivative = 0.61 \[ \int \tan ^2(c+d x) (a+i a \tan (c+d x))^{5/2} (A+B \tan (c+d x)) \, dx=\frac {2 a^2 \left (630 \sqrt {2} \sqrt {a} (i A+B) \text {arctanh}\left (\frac {\sqrt {a+i a \tan (c+d x)}}{\sqrt {2} \sqrt {a}}\right )+\sqrt {a+i a \tan (c+d x)} \left (-780 i A-788 B+4 (60 A-59 i B) \tan (c+d x)+3 (45 i A+46 B) \tan ^2(c+d x)+(-45 A+95 i B) \tan ^3(c+d x)-35 B \tan ^4(c+d x)\right )\right )}{315 d} \] Input:
Integrate[Tan[c + d*x]^2*(a + I*a*Tan[c + d*x])^(5/2)*(A + B*Tan[c + d*x]) ,x]
Output:
(2*a^2*(630*Sqrt[2]*Sqrt[a]*(I*A + B)*ArcTanh[Sqrt[a + I*a*Tan[c + d*x]]/( Sqrt[2]*Sqrt[a])] + Sqrt[a + I*a*Tan[c + d*x]]*((-780*I)*A - 788*B + 4*(60 *A - (59*I)*B)*Tan[c + d*x] + 3*((45*I)*A + 46*B)*Tan[c + d*x]^2 + (-45*A + (95*I)*B)*Tan[c + d*x]^3 - 35*B*Tan[c + d*x]^4)))/(315*d)
Time = 1.46 (sec) , antiderivative size = 266, normalized size of antiderivative = 1.08, number of steps used = 17, number of rules used = 16, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.444, Rules used = {3042, 4077, 27, 3042, 4077, 27, 3042, 4080, 27, 3042, 4075, 3042, 4010, 3042, 3961, 219}
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 ^2(c+d x) (a+i a \tan (c+d x))^{5/2} (A+B \tan (c+d x)) \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \tan (c+d x)^2 (a+i a \tan (c+d x))^{5/2} (A+B \tan (c+d x))dx\) |
\(\Big \downarrow \) 4077 |
\(\displaystyle \frac {2}{9} \int \frac {3}{2} \tan ^2(c+d x) (i \tan (c+d x) a+a)^{3/2} (a (3 A-2 i B)+a (3 i A+4 B) \tan (c+d x))dx+\frac {2 i a B \tan ^3(c+d x) (a+i a \tan (c+d x))^{3/2}}{9 d}\) |
\(\Big \downarrow \) 27 |
\(\displaystyle \frac {1}{3} \int \tan ^2(c+d x) (i \tan (c+d x) a+a)^{3/2} (a (3 A-2 i B)+a (3 i A+4 B) \tan (c+d x))dx+\frac {2 i a B \tan ^3(c+d x) (a+i a \tan (c+d x))^{3/2}}{9 d}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {1}{3} \int \tan (c+d x)^2 (i \tan (c+d x) a+a)^{3/2} (a (3 A-2 i B)+a (3 i A+4 B) \tan (c+d x))dx+\frac {2 i a B \tan ^3(c+d x) (a+i a \tan (c+d x))^{3/2}}{9 d}\) |
\(\Big \downarrow \) 4077 |
\(\displaystyle \frac {1}{3} \left (\frac {2}{7} \int \frac {1}{2} \tan ^2(c+d x) \sqrt {i \tan (c+d x) a+a} \left ((39 A-38 i B) a^2+(45 i A+46 B) \tan (c+d x) a^2\right )dx-\frac {2 a^2 (3 A-4 i B) \tan ^3(c+d x) \sqrt {a+i a \tan (c+d x)}}{7 d}\right )+\frac {2 i a B \tan ^3(c+d x) (a+i a \tan (c+d x))^{3/2}}{9 d}\) |
\(\Big \downarrow \) 27 |
\(\displaystyle \frac {1}{3} \left (\frac {1}{7} \int \tan ^2(c+d x) \sqrt {i \tan (c+d x) a+a} \left ((39 A-38 i B) a^2+(45 i A+46 B) \tan (c+d x) a^2\right )dx-\frac {2 a^2 (3 A-4 i B) \tan ^3(c+d x) \sqrt {a+i a \tan (c+d x)}}{7 d}\right )+\frac {2 i a B \tan ^3(c+d x) (a+i a \tan (c+d x))^{3/2}}{9 d}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {1}{3} \left (\frac {1}{7} \int \tan (c+d x)^2 \sqrt {i \tan (c+d x) a+a} \left ((39 A-38 i B) a^2+(45 i A+46 B) \tan (c+d x) a^2\right )dx-\frac {2 a^2 (3 A-4 i B) \tan ^3(c+d x) \sqrt {a+i a \tan (c+d x)}}{7 d}\right )+\frac {2 i a B \tan ^3(c+d x) (a+i a \tan (c+d x))^{3/2}}{9 d}\) |
\(\Big \downarrow \) 4080 |
\(\displaystyle \frac {1}{3} \left (\frac {1}{7} \left (\frac {2 \int -2 \tan (c+d x) \sqrt {i \tan (c+d x) a+a} \left (a^3 (45 i A+46 B)-a^3 (60 A-59 i B) \tan (c+d x)\right )dx}{5 a}+\frac {2 a^2 (46 B+45 i A) \tan ^2(c+d x) \sqrt {a+i a \tan (c+d x)}}{5 d}\right )-\frac {2 a^2 (3 A-4 i B) \tan ^3(c+d x) \sqrt {a+i a \tan (c+d x)}}{7 d}\right )+\frac {2 i a B \tan ^3(c+d x) (a+i a \tan (c+d x))^{3/2}}{9 d}\) |
\(\Big \downarrow \) 27 |
\(\displaystyle \frac {1}{3} \left (\frac {1}{7} \left (\frac {2 a^2 (46 B+45 i A) \tan ^2(c+d x) \sqrt {a+i a \tan (c+d x)}}{5 d}-\frac {4 \int \tan (c+d x) \sqrt {i \tan (c+d x) a+a} \left (a^3 (45 i A+46 B)-a^3 (60 A-59 i B) \tan (c+d x)\right )dx}{5 a}\right )-\frac {2 a^2 (3 A-4 i B) \tan ^3(c+d x) \sqrt {a+i a \tan (c+d x)}}{7 d}\right )+\frac {2 i a B \tan ^3(c+d x) (a+i a \tan (c+d x))^{3/2}}{9 d}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {1}{3} \left (\frac {1}{7} \left (\frac {2 a^2 (46 B+45 i A) \tan ^2(c+d x) \sqrt {a+i a \tan (c+d x)}}{5 d}-\frac {4 \int \tan (c+d x) \sqrt {i \tan (c+d x) a+a} \left (a^3 (45 i A+46 B)-a^3 (60 A-59 i B) \tan (c+d x)\right )dx}{5 a}\right )-\frac {2 a^2 (3 A-4 i B) \tan ^3(c+d x) \sqrt {a+i a \tan (c+d x)}}{7 d}\right )+\frac {2 i a B \tan ^3(c+d x) (a+i a \tan (c+d x))^{3/2}}{9 d}\) |
\(\Big \downarrow \) 4075 |
\(\displaystyle \frac {1}{3} \left (\frac {1}{7} \left (\frac {2 a^2 (46 B+45 i A) \tan ^2(c+d x) \sqrt {a+i a \tan (c+d x)}}{5 d}-\frac {4 \left (\int \sqrt {i \tan (c+d x) a+a} \left ((60 A-59 i B) a^3+(45 i A+46 B) \tan (c+d x) a^3\right )dx+\frac {2 a^2 (59 B+60 i A) (a+i a \tan (c+d x))^{3/2}}{3 d}\right )}{5 a}\right )-\frac {2 a^2 (3 A-4 i B) \tan ^3(c+d x) \sqrt {a+i a \tan (c+d x)}}{7 d}\right )+\frac {2 i a B \tan ^3(c+d x) (a+i a \tan (c+d x))^{3/2}}{9 d}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {1}{3} \left (\frac {1}{7} \left (\frac {2 a^2 (46 B+45 i A) \tan ^2(c+d x) \sqrt {a+i a \tan (c+d x)}}{5 d}-\frac {4 \left (\int \sqrt {i \tan (c+d x) a+a} \left ((60 A-59 i B) a^3+(45 i A+46 B) \tan (c+d x) a^3\right )dx+\frac {2 a^2 (59 B+60 i A) (a+i a \tan (c+d x))^{3/2}}{3 d}\right )}{5 a}\right )-\frac {2 a^2 (3 A-4 i B) \tan ^3(c+d x) \sqrt {a+i a \tan (c+d x)}}{7 d}\right )+\frac {2 i a B \tan ^3(c+d x) (a+i a \tan (c+d x))^{3/2}}{9 d}\) |
\(\Big \downarrow \) 4010 |
\(\displaystyle \frac {1}{3} \left (\frac {1}{7} \left (\frac {2 a^2 (46 B+45 i A) \tan ^2(c+d x) \sqrt {a+i a \tan (c+d x)}}{5 d}-\frac {4 \left (105 a^3 (A-i B) \int \sqrt {i \tan (c+d x) a+a}dx+\frac {2 a^3 (46 B+45 i A) \sqrt {a+i a \tan (c+d x)}}{d}+\frac {2 a^2 (59 B+60 i A) (a+i a \tan (c+d x))^{3/2}}{3 d}\right )}{5 a}\right )-\frac {2 a^2 (3 A-4 i B) \tan ^3(c+d x) \sqrt {a+i a \tan (c+d x)}}{7 d}\right )+\frac {2 i a B \tan ^3(c+d x) (a+i a \tan (c+d x))^{3/2}}{9 d}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {1}{3} \left (\frac {1}{7} \left (\frac {2 a^2 (46 B+45 i A) \tan ^2(c+d x) \sqrt {a+i a \tan (c+d x)}}{5 d}-\frac {4 \left (105 a^3 (A-i B) \int \sqrt {i \tan (c+d x) a+a}dx+\frac {2 a^3 (46 B+45 i A) \sqrt {a+i a \tan (c+d x)}}{d}+\frac {2 a^2 (59 B+60 i A) (a+i a \tan (c+d x))^{3/2}}{3 d}\right )}{5 a}\right )-\frac {2 a^2 (3 A-4 i B) \tan ^3(c+d x) \sqrt {a+i a \tan (c+d x)}}{7 d}\right )+\frac {2 i a B \tan ^3(c+d x) (a+i a \tan (c+d x))^{3/2}}{9 d}\) |
\(\Big \downarrow \) 3961 |
\(\displaystyle \frac {1}{3} \left (\frac {1}{7} \left (\frac {2 a^2 (46 B+45 i A) \tan ^2(c+d x) \sqrt {a+i a \tan (c+d x)}}{5 d}-\frac {4 \left (-\frac {210 i a^4 (A-i B) \int \frac {1}{a-i a \tan (c+d x)}d\sqrt {i \tan (c+d x) a+a}}{d}+\frac {2 a^3 (46 B+45 i A) \sqrt {a+i a \tan (c+d x)}}{d}+\frac {2 a^2 (59 B+60 i A) (a+i a \tan (c+d x))^{3/2}}{3 d}\right )}{5 a}\right )-\frac {2 a^2 (3 A-4 i B) \tan ^3(c+d x) \sqrt {a+i a \tan (c+d x)}}{7 d}\right )+\frac {2 i a B \tan ^3(c+d x) (a+i a \tan (c+d x))^{3/2}}{9 d}\) |
\(\Big \downarrow \) 219 |
\(\displaystyle \frac {1}{3} \left (\frac {1}{7} \left (\frac {2 a^2 (46 B+45 i A) \tan ^2(c+d x) \sqrt {a+i a \tan (c+d x)}}{5 d}-\frac {4 \left (-\frac {105 i \sqrt {2} a^{7/2} (A-i B) \text {arctanh}\left (\frac {\sqrt {a+i a \tan (c+d x)}}{\sqrt {2} \sqrt {a}}\right )}{d}+\frac {2 a^3 (46 B+45 i A) \sqrt {a+i a \tan (c+d x)}}{d}+\frac {2 a^2 (59 B+60 i A) (a+i a \tan (c+d x))^{3/2}}{3 d}\right )}{5 a}\right )-\frac {2 a^2 (3 A-4 i B) \tan ^3(c+d x) \sqrt {a+i a \tan (c+d x)}}{7 d}\right )+\frac {2 i a B \tan ^3(c+d x) (a+i a \tan (c+d x))^{3/2}}{9 d}\) |
Input:
Int[Tan[c + d*x]^2*(a + I*a*Tan[c + d*x])^(5/2)*(A + B*Tan[c + d*x]),x]
Output:
(((2*I)/9)*a*B*Tan[c + d*x]^3*(a + I*a*Tan[c + d*x])^(3/2))/d + ((-2*a^2*( 3*A - (4*I)*B)*Tan[c + d*x]^3*Sqrt[a + I*a*Tan[c + d*x]])/(7*d) + ((2*a^2* ((45*I)*A + 46*B)*Tan[c + d*x]^2*Sqrt[a + I*a*Tan[c + d*x]])/(5*d) - (4*(( (-105*I)*Sqrt[2]*a^(7/2)*(A - I*B)*ArcTanh[Sqrt[a + I*a*Tan[c + d*x]]/(Sqr t[2]*Sqrt[a])])/d + (2*a^3*((45*I)*A + 46*B)*Sqrt[a + I*a*Tan[c + d*x]])/d + (2*a^2*((60*I)*A + 59*B)*(a + I*a*Tan[c + d*x])^(3/2))/(3*d)))/(5*a))/7 )/3
Int[(a_)*(Fx_), x_Symbol] :> Simp[a Int[Fx, x], x] /; FreeQ[a, x] && !Ma tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1/(Rt[a, 2]*Rt[-b, 2]))* ArcTanh[Rt[-b, 2]*(x/Rt[a, 2])], x] /; FreeQ[{a, b}, x] && NegQ[a/b] && (Gt Q[a, 0] || LtQ[b, 0])
Int[Sqrt[(a_) + (b_.)*tan[(c_.) + (d_.)*(x_)]], x_Symbol] :> Simp[-2*(b/d) Subst[Int[1/(2*a - x^2), x], x, Sqrt[a + b*Tan[c + d*x]]], x] /; FreeQ[{a , b, c, d}, x] && EqQ[a^2 + b^2, 0]
Int[((a_) + (b_.)*tan[(e_.) + (f_.)*(x_)])^(m_)*((c_.) + (d_.)*tan[(e_.) + (f_.)*(x_)]), x_Symbol] :> Simp[d*((a + b*Tan[e + f*x])^m/(f*m)), x] + Simp [(b*c + a*d)/b Int[(a + b*Tan[e + f*x])^m, x], x] /; FreeQ[{a, b, c, d, e , f, m}, x] && NeQ[b*c - a*d, 0] && EqQ[a^2 + b^2, 0] && !LtQ[m, 0]
Int[((a_.) + (b_.)*tan[(e_.) + (f_.)*(x_)])^(m_.)*((A_.) + (B_.)*tan[(e_.) + (f_.)*(x_)])*((c_.) + (d_.)*tan[(e_.) + (f_.)*(x_)]), x_Symbol] :> Simp[B *d*((a + b*Tan[e + f*x])^(m + 1)/(b*f*(m + 1))), x] + Int[(a + b*Tan[e + f* x])^m*Simp[A*c - B*d + (B*c + A*d)*Tan[e + f*x], x], x] /; FreeQ[{a, b, c, d, e, f, A, B, m}, x] && NeQ[b*c - a*d, 0] && !LeQ[m, -1]
Int[((a_) + (b_.)*tan[(e_.) + (f_.)*(x_)])^(m_)*((A_.) + (B_.)*tan[(e_.) + (f_.)*(x_)])*((c_.) + (d_.)*tan[(e_.) + (f_.)*(x_)])^(n_), x_Symbol] :> Sim p[b*B*(a + b*Tan[e + f*x])^(m - 1)*((c + d*Tan[e + f*x])^(n + 1)/(d*f*(m + n))), x] + Simp[1/(d*(m + n)) Int[(a + b*Tan[e + f*x])^(m - 1)*(c + d*Tan [e + f*x])^n*Simp[a*A*d*(m + n) + B*(a*c*(m - 1) - b*d*(n + 1)) - (B*(b*c - a*d)*(m - 1) - d*(A*b + a*B)*(m + n))*Tan[e + f*x], x], x], x] /; FreeQ[{a , b, c, d, e, f, A, B, n}, x] && NeQ[b*c - a*d, 0] && EqQ[a^2 + b^2, 0] && GtQ[m, 1] && !LtQ[n, -1]
Int[((a_) + (b_.)*tan[(e_.) + (f_.)*(x_)])^(m_)*((A_.) + (B_.)*tan[(e_.) + (f_.)*(x_)])*((c_.) + (d_.)*tan[(e_.) + (f_.)*(x_)])^(n_), x_Symbol] :> Sim p[B*(a + b*Tan[e + f*x])^m*((c + d*Tan[e + f*x])^n/(f*(m + n))), x] + Simp[ 1/(a*(m + n)) Int[(a + b*Tan[e + f*x])^m*(c + d*Tan[e + f*x])^(n - 1)*Sim p[a*A*c*(m + n) - B*(b*c*m + a*d*n) + (a*A*d*(m + n) - B*(b*d*m - a*c*n))*T an[e + f*x], x], x], x] /; FreeQ[{a, b, c, d, e, f, A, B, m}, x] && NeQ[b*c - a*d, 0] && EqQ[a^2 + b^2, 0] && GtQ[n, 0]
Time = 0.31 (sec) , antiderivative size = 206, normalized size of antiderivative = 0.84
method | result | size |
derivativedivides | \(\frac {2 i \left (\frac {i B \left (a +i a \tan \left (d x +c \right )\right )^{\frac {9}{2}}}{9}-\frac {i B a \left (a +i a \tan \left (d x +c \right )\right )^{\frac {7}{2}}}{7}-\frac {A a \left (a +i a \tan \left (d x +c \right )\right )^{\frac {7}{2}}}{7}+\frac {i a^{2} B \left (a +i a \tan \left (d x +c \right )\right )^{\frac {5}{2}}}{5}+\frac {i B \,a^{3} \left (a +i a \tan \left (d x +c \right )\right )^{\frac {3}{2}}}{3}-\frac {A \,a^{3} \left (a +i a \tan \left (d x +c \right )\right )^{\frac {3}{2}}}{3}+2 i B \,a^{4} \sqrt {a +i a \tan \left (d x +c \right )}-2 A \,a^{4} \sqrt {a +i a \tan \left (d x +c \right )}+2 a^{\frac {9}{2}} \left (-i B +A \right ) \sqrt {2}\, \operatorname {arctanh}\left (\frac {\sqrt {a +i a \tan \left (d x +c \right )}\, \sqrt {2}}{2 \sqrt {a}}\right )\right )}{d \,a^{2}}\) | \(206\) |
default | \(\frac {2 i \left (\frac {i B \left (a +i a \tan \left (d x +c \right )\right )^{\frac {9}{2}}}{9}-\frac {i B a \left (a +i a \tan \left (d x +c \right )\right )^{\frac {7}{2}}}{7}-\frac {A a \left (a +i a \tan \left (d x +c \right )\right )^{\frac {7}{2}}}{7}+\frac {i a^{2} B \left (a +i a \tan \left (d x +c \right )\right )^{\frac {5}{2}}}{5}+\frac {i B \,a^{3} \left (a +i a \tan \left (d x +c \right )\right )^{\frac {3}{2}}}{3}-\frac {A \,a^{3} \left (a +i a \tan \left (d x +c \right )\right )^{\frac {3}{2}}}{3}+2 i B \,a^{4} \sqrt {a +i a \tan \left (d x +c \right )}-2 A \,a^{4} \sqrt {a +i a \tan \left (d x +c \right )}+2 a^{\frac {9}{2}} \left (-i B +A \right ) \sqrt {2}\, \operatorname {arctanh}\left (\frac {\sqrt {a +i a \tan \left (d x +c \right )}\, \sqrt {2}}{2 \sqrt {a}}\right )\right )}{d \,a^{2}}\) | \(206\) |
parts | \(\frac {2 i A \left (-\frac {\left (a +i a \tan \left (d x +c \right )\right )^{\frac {7}{2}}}{7}-\frac {\left (a +i a \tan \left (d x +c \right )\right )^{\frac {3}{2}} a^{2}}{3}-2 a^{3} \sqrt {a +i a \tan \left (d x +c \right )}+2 a^{\frac {7}{2}} \sqrt {2}\, \operatorname {arctanh}\left (\frac {\sqrt {a +i a \tan \left (d x +c \right )}\, \sqrt {2}}{2 \sqrt {a}}\right )\right )}{d a}+\frac {2 B \left (-\frac {\left (a +i a \tan \left (d x +c \right )\right )^{\frac {9}{2}}}{9}+\frac {a \left (a +i a \tan \left (d x +c \right )\right )^{\frac {7}{2}}}{7}-\frac {a^{2} \left (a +i a \tan \left (d x +c \right )\right )^{\frac {5}{2}}}{5}-\frac {a^{3} \left (a +i a \tan \left (d x +c \right )\right )^{\frac {3}{2}}}{3}-2 a^{4} \sqrt {a +i a \tan \left (d x +c \right )}+2 a^{\frac {9}{2}} \sqrt {2}\, \operatorname {arctanh}\left (\frac {\sqrt {a +i a \tan \left (d x +c \right )}\, \sqrt {2}}{2 \sqrt {a}}\right )\right )}{d \,a^{2}}\) | \(229\) |
Input:
int(tan(d*x+c)^2*(a+I*a*tan(d*x+c))^(5/2)*(A+B*tan(d*x+c)),x,method=_RETUR NVERBOSE)
Output:
2*I/d/a^2*(1/9*I*B*(a+I*a*tan(d*x+c))^(9/2)-1/7*I*B*a*(a+I*a*tan(d*x+c))^( 7/2)-1/7*A*a*(a+I*a*tan(d*x+c))^(7/2)+1/5*I*a^2*B*(a+I*a*tan(d*x+c))^(5/2) +1/3*I*B*a^3*(a+I*a*tan(d*x+c))^(3/2)-1/3*A*a^3*(a+I*a*tan(d*x+c))^(3/2)+2 *I*B*a^4*(a+I*a*tan(d*x+c))^(1/2)-2*A*a^4*(a+I*a*tan(d*x+c))^(1/2)+2*a^(9/ 2)*(A-I*B)*2^(1/2)*arctanh(1/2*(a+I*a*tan(d*x+c))^(1/2)*2^(1/2)/a^(1/2)))
Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 531 vs. \(2 (193) = 386\).
Time = 0.12 (sec) , antiderivative size = 531, normalized size of antiderivative = 2.16 \[ \int \tan ^2(c+d x) (a+i a \tan (c+d x))^{5/2} (A+B \tan (c+d x)) \, dx =\text {Too large to display} \] Input:
integrate(tan(d*x+c)^2*(a+I*a*tan(d*x+c))^(5/2)*(A+B*tan(d*x+c)),x, algori thm="fricas")
Output:
-2/315*(315*sqrt(2)*sqrt(-(A^2 - 2*I*A*B - B^2)*a^5/d^2)*(d*e^(8*I*d*x + 8 *I*c) + 4*d*e^(6*I*d*x + 6*I*c) + 6*d*e^(4*I*d*x + 4*I*c) + 4*d*e^(2*I*d*x + 2*I*c) + d)*log(4*((-I*A - B)*a^3*e^(I*d*x + I*c) + sqrt(-(A^2 - 2*I*A* B - B^2)*a^5/d^2)*(d*e^(2*I*d*x + 2*I*c) + d)*sqrt(a/(e^(2*I*d*x + 2*I*c) + 1)))*e^(-I*d*x - I*c)/((-I*A - B)*a^2)) - 315*sqrt(2)*sqrt(-(A^2 - 2*I*A *B - B^2)*a^5/d^2)*(d*e^(8*I*d*x + 8*I*c) + 4*d*e^(6*I*d*x + 6*I*c) + 6*d* e^(4*I*d*x + 4*I*c) + 4*d*e^(2*I*d*x + 2*I*c) + d)*log(4*((-I*A - B)*a^3*e ^(I*d*x + I*c) - sqrt(-(A^2 - 2*I*A*B - B^2)*a^5/d^2)*(d*e^(2*I*d*x + 2*I* c) + d)*sqrt(a/(e^(2*I*d*x + 2*I*c) + 1)))*e^(-I*d*x - I*c)/((-I*A - B)*a^ 2)) + 2*sqrt(2)*(2*(300*I*A + 323*B)*a^2*e^(9*I*d*x + 9*I*c) + 27*(65*I*A + 61*B)*a^2*e^(7*I*d*x + 7*I*c) + 63*(35*I*A + 37*B)*a^2*e^(5*I*d*x + 5*I* c) + 1365*(I*A + B)*a^2*e^(3*I*d*x + 3*I*c) + 315*(I*A + B)*a^2*e^(I*d*x + I*c))*sqrt(a/(e^(2*I*d*x + 2*I*c) + 1)))/(d*e^(8*I*d*x + 8*I*c) + 4*d*e^( 6*I*d*x + 6*I*c) + 6*d*e^(4*I*d*x + 4*I*c) + 4*d*e^(2*I*d*x + 2*I*c) + d)
\[ \int \tan ^2(c+d x) (a+i a \tan (c+d x))^{5/2} (A+B \tan (c+d x)) \, dx=\int \left (i a \left (\tan {\left (c + d x \right )} - i\right )\right )^{\frac {5}{2}} \left (A + B \tan {\left (c + d x \right )}\right ) \tan ^{2}{\left (c + d x \right )}\, dx \] Input:
integrate(tan(d*x+c)**2*(a+I*a*tan(d*x+c))**(5/2)*(A+B*tan(d*x+c)),x)
Output:
Integral((I*a*(tan(c + d*x) - I))**(5/2)*(A + B*tan(c + d*x))*tan(c + d*x) **2, x)
Time = 0.13 (sec) , antiderivative size = 176, normalized size of antiderivative = 0.72 \[ \int \tan ^2(c+d x) (a+i a \tan (c+d x))^{5/2} (A+B \tan (c+d x)) \, dx=-\frac {2 i \, {\left (315 \, \sqrt {2} {\left (A - i \, B\right )} a^{\frac {11}{2}} \log \left (-\frac {\sqrt {2} \sqrt {a} - \sqrt {i \, a \tan \left (d x + c\right ) + a}}{\sqrt {2} \sqrt {a} + \sqrt {i \, a \tan \left (d x + c\right ) + a}}\right ) - 35 i \, {\left (i \, a \tan \left (d x + c\right ) + a\right )}^{\frac {9}{2}} B a + 45 \, {\left (i \, a \tan \left (d x + c\right ) + a\right )}^{\frac {7}{2}} {\left (A + i \, B\right )} a^{2} - 63 i \, {\left (i \, a \tan \left (d x + c\right ) + a\right )}^{\frac {5}{2}} B a^{3} + 105 \, {\left (i \, a \tan \left (d x + c\right ) + a\right )}^{\frac {3}{2}} {\left (A - i \, B\right )} a^{4} + 630 \, \sqrt {i \, a \tan \left (d x + c\right ) + a} {\left (A - i \, B\right )} a^{5}\right )}}{315 \, a^{3} d} \] Input:
integrate(tan(d*x+c)^2*(a+I*a*tan(d*x+c))^(5/2)*(A+B*tan(d*x+c)),x, algori thm="maxima")
Output:
-2/315*I*(315*sqrt(2)*(A - I*B)*a^(11/2)*log(-(sqrt(2)*sqrt(a) - sqrt(I*a* tan(d*x + c) + a))/(sqrt(2)*sqrt(a) + sqrt(I*a*tan(d*x + c) + a))) - 35*I* (I*a*tan(d*x + c) + a)^(9/2)*B*a + 45*(I*a*tan(d*x + c) + a)^(7/2)*(A + I* B)*a^2 - 63*I*(I*a*tan(d*x + c) + a)^(5/2)*B*a^3 + 105*(I*a*tan(d*x + c) + a)^(3/2)*(A - I*B)*a^4 + 630*sqrt(I*a*tan(d*x + c) + a)*(A - I*B)*a^5)/(a ^3*d)
Exception generated. \[ \int \tan ^2(c+d x) (a+i a \tan (c+d x))^{5/2} (A+B \tan (c+d x)) \, dx=\text {Exception raised: TypeError} \] Input:
integrate(tan(d*x+c)^2*(a+I*a*tan(d*x+c))^(5/2)*(A+B*tan(d*x+c)),x, algori thm="giac")
Output:
Exception raised: TypeError >> an error occurred running a Giac command:IN PUT:sage2:=int(sage0,sageVARx):;OUTPUT:Error: Bad Argument TypeError: Bad Argument TypeError: Bad Argument TypeError: Bad Argument TypeError: Bad Ar gument Ty
Time = 5.07 (sec) , antiderivative size = 258, normalized size of antiderivative = 1.05 \[ \int \tan ^2(c+d x) (a+i a \tan (c+d x))^{5/2} (A+B \tan (c+d x)) \, dx=-\frac {2\,B\,{\left (a+a\,\mathrm {tan}\left (c+d\,x\right )\,1{}\mathrm {i}\right )}^{5/2}}{5\,d}-\frac {A\,a\,{\left (a+a\,\mathrm {tan}\left (c+d\,x\right )\,1{}\mathrm {i}\right )}^{3/2}\,2{}\mathrm {i}}{3\,d}-\frac {2\,B\,a\,{\left (a+a\,\mathrm {tan}\left (c+d\,x\right )\,1{}\mathrm {i}\right )}^{3/2}}{3\,d}-\frac {A\,a^2\,\sqrt {a+a\,\mathrm {tan}\left (c+d\,x\right )\,1{}\mathrm {i}}\,4{}\mathrm {i}}{d}-\frac {A\,{\left (a+a\,\mathrm {tan}\left (c+d\,x\right )\,1{}\mathrm {i}\right )}^{7/2}\,2{}\mathrm {i}}{7\,a\,d}-\frac {4\,B\,a^2\,\sqrt {a+a\,\mathrm {tan}\left (c+d\,x\right )\,1{}\mathrm {i}}}{d}+\frac {2\,B\,{\left (a+a\,\mathrm {tan}\left (c+d\,x\right )\,1{}\mathrm {i}\right )}^{7/2}}{7\,a\,d}-\frac {2\,B\,{\left (a+a\,\mathrm {tan}\left (c+d\,x\right )\,1{}\mathrm {i}\right )}^{9/2}}{9\,a^2\,d}+\frac {\sqrt {2}\,A\,{\left (-a\right )}^{5/2}\,\mathrm {atan}\left (\frac {\sqrt {2}\,\sqrt {a+a\,\mathrm {tan}\left (c+d\,x\right )\,1{}\mathrm {i}}}{2\,\sqrt {-a}}\right )\,4{}\mathrm {i}}{d}-\frac {\sqrt {2}\,B\,a^{5/2}\,\mathrm {atan}\left (\frac {\sqrt {2}\,\sqrt {a+a\,\mathrm {tan}\left (c+d\,x\right )\,1{}\mathrm {i}}\,1{}\mathrm {i}}{2\,\sqrt {a}}\right )\,4{}\mathrm {i}}{d} \] Input:
int(tan(c + d*x)^2*(A + B*tan(c + d*x))*(a + a*tan(c + d*x)*1i)^(5/2),x)
Output:
(2*B*(a + a*tan(c + d*x)*1i)^(7/2))/(7*a*d) - (A*a*(a + a*tan(c + d*x)*1i) ^(3/2)*2i)/(3*d) - (2*B*a*(a + a*tan(c + d*x)*1i)^(3/2))/(3*d) - (A*a^2*(a + a*tan(c + d*x)*1i)^(1/2)*4i)/d - (A*(a + a*tan(c + d*x)*1i)^(7/2)*2i)/( 7*a*d) - (4*B*a^2*(a + a*tan(c + d*x)*1i)^(1/2))/d - (2*B*(a + a*tan(c + d *x)*1i)^(5/2))/(5*d) - (2*B*(a + a*tan(c + d*x)*1i)^(9/2))/(9*a^2*d) + (2^ (1/2)*A*(-a)^(5/2)*atan((2^(1/2)*(a + a*tan(c + d*x)*1i)^(1/2))/(2*(-a)^(1 /2)))*4i)/d - (2^(1/2)*B*a^(5/2)*atan((2^(1/2)*(a + a*tan(c + d*x)*1i)^(1/ 2)*1i)/(2*a^(1/2)))*4i)/d
\[ \int \tan ^2(c+d x) (a+i a \tan (c+d x))^{5/2} (A+B \tan (c+d x)) \, dx=\sqrt {a}\, a^{2} \left (-\left (\int \sqrt {\tan \left (d x +c \right ) i +1}\, \tan \left (d x +c \right )^{5}d x \right ) b -\left (\int \sqrt {\tan \left (d x +c \right ) i +1}\, \tan \left (d x +c \right )^{4}d x \right ) a +2 \left (\int \sqrt {\tan \left (d x +c \right ) i +1}\, \tan \left (d x +c \right )^{4}d x \right ) b i +2 \left (\int \sqrt {\tan \left (d x +c \right ) i +1}\, \tan \left (d x +c \right )^{3}d x \right ) a i +\left (\int \sqrt {\tan \left (d x +c \right ) i +1}\, \tan \left (d x +c \right )^{3}d x \right ) b +\left (\int \sqrt {\tan \left (d x +c \right ) i +1}\, \tan \left (d x +c \right )^{2}d x \right ) a \right ) \] Input:
int(tan(d*x+c)^2*(a+I*a*tan(d*x+c))^(5/2)*(A+B*tan(d*x+c)),x)
Output:
sqrt(a)*a**2*( - int(sqrt(tan(c + d*x)*i + 1)*tan(c + d*x)**5,x)*b - int(s qrt(tan(c + d*x)*i + 1)*tan(c + d*x)**4,x)*a + 2*int(sqrt(tan(c + d*x)*i + 1)*tan(c + d*x)**4,x)*b*i + 2*int(sqrt(tan(c + d*x)*i + 1)*tan(c + d*x)** 3,x)*a*i + int(sqrt(tan(c + d*x)*i + 1)*tan(c + d*x)**3,x)*b + int(sqrt(ta n(c + d*x)*i + 1)*tan(c + d*x)**2,x)*a)