Integrand size = 23, antiderivative size = 52 \[ \int \frac {\sec ^4(c+d x)}{a+b \tan ^2(c+d x)} \, dx=-\frac {(a-b) \arctan \left (\frac {\sqrt {b} \tan (c+d x)}{\sqrt {a}}\right )}{\sqrt {a} b^{3/2} d}+\frac {\tan (c+d x)}{b d} \] Output:
-(a-b)*arctan(b^(1/2)*tan(d*x+c)/a^(1/2))/a^(1/2)/b^(3/2)/d+tan(d*x+c)/b/d
Time = 0.30 (sec) , antiderivative size = 52, normalized size of antiderivative = 1.00 \[ \int \frac {\sec ^4(c+d x)}{a+b \tan ^2(c+d x)} \, dx=-\frac {(a-b) \arctan \left (\frac {\sqrt {b} \tan (c+d x)}{\sqrt {a}}\right )}{\sqrt {a} b^{3/2} d}+\frac {\tan (c+d x)}{b d} \] Input:
Integrate[Sec[c + d*x]^4/(a + b*Tan[c + d*x]^2),x]
Output:
-(((a - b)*ArcTan[(Sqrt[b]*Tan[c + d*x])/Sqrt[a]])/(Sqrt[a]*b^(3/2)*d)) + Tan[c + d*x]/(b*d)
Time = 0.24 (sec) , antiderivative size = 50, normalized size of antiderivative = 0.96, number of steps used = 5, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.174, Rules used = {3042, 4158, 299, 218}
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 ^4(c+d x)}{a+b \tan ^2(c+d x)} \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {\sec (c+d x)^4}{a+b \tan (c+d x)^2}dx\) |
\(\Big \downarrow \) 4158 |
\(\displaystyle \frac {\int \frac {\tan ^2(c+d x)+1}{b \tan ^2(c+d x)+a}d\tan (c+d x)}{d}\) |
\(\Big \downarrow \) 299 |
\(\displaystyle \frac {\frac {\tan (c+d x)}{b}-\frac {(a-b) \int \frac {1}{b \tan ^2(c+d x)+a}d\tan (c+d x)}{b}}{d}\) |
\(\Big \downarrow \) 218 |
\(\displaystyle \frac {\frac {\tan (c+d x)}{b}-\frac {(a-b) \arctan \left (\frac {\sqrt {b} \tan (c+d x)}{\sqrt {a}}\right )}{\sqrt {a} b^{3/2}}}{d}\) |
Input:
Int[Sec[c + d*x]^4/(a + b*Tan[c + d*x]^2),x]
Output:
(-(((a - b)*ArcTan[(Sqrt[b]*Tan[c + d*x])/Sqrt[a]])/(Sqrt[a]*b^(3/2))) + T an[c + d*x]/b)/d
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(Rt[a/b, 2]/a)*ArcTan[x/R t[a/b, 2]], x] /; FreeQ[{a, b}, x] && PosQ[a/b]
Int[((a_) + (b_.)*(x_)^2)^(p_)*((c_) + (d_.)*(x_)^2), x_Symbol] :> Simp[d*x *((a + b*x^2)^(p + 1)/(b*(2*p + 3))), x] - Simp[(a*d - b*c*(2*p + 3))/(b*(2 *p + 3)) Int[(a + b*x^2)^p, x], x] /; FreeQ[{a, b, c, d}, x] && NeQ[b*c - a*d, 0] && NeQ[2*p + 3, 0]
Int[sec[(e_.) + (f_.)*(x_)]^(m_)*((a_) + (b_.)*((c_.)*tan[(e_.) + (f_.)*(x_ )])^(n_))^(p_.), x_Symbol] :> With[{ff = FreeFactors[Tan[e + f*x], x]}, Sim p[ff/(c^(m - 1)*f) Subst[Int[(c^2 + ff^2*x^2)^(m/2 - 1)*(a + b*(ff*x)^n)^ p, x], x, c*(Tan[e + f*x]/ff)], x]] /; FreeQ[{a, b, c, e, f, n, p}, x] && I ntegerQ[m/2] && (IntegersQ[n, p] || IGtQ[m, 0] || IGtQ[p, 0] || EqQ[n^2, 4] || EqQ[n^2, 16])
Time = 6.93 (sec) , antiderivative size = 44, normalized size of antiderivative = 0.85
method | result | size |
derivativedivides | \(\frac {\frac {\tan \left (d x +c \right )}{b}+\frac {\left (-a +b \right ) \arctan \left (\frac {b \tan \left (d x +c \right )}{\sqrt {a b}}\right )}{b \sqrt {a b}}}{d}\) | \(44\) |
default | \(\frac {\frac {\tan \left (d x +c \right )}{b}+\frac {\left (-a +b \right ) \arctan \left (\frac {b \tan \left (d x +c \right )}{\sqrt {a b}}\right )}{b \sqrt {a b}}}{d}\) | \(44\) |
risch | \(\frac {2 i}{d b \left ({\mathrm e}^{2 i \left (d x +c \right )}+1\right )}-\frac {\ln \left ({\mathrm e}^{2 i \left (d x +c \right )}+\frac {-2 i a b +\sqrt {-a b}\, a +\sqrt {-a b}\, b}{\left (a -b \right ) \sqrt {-a b}}\right ) a}{2 \sqrt {-a b}\, d b}+\frac {\ln \left ({\mathrm e}^{2 i \left (d x +c \right )}+\frac {-2 i a b +\sqrt {-a b}\, a +\sqrt {-a b}\, b}{\left (a -b \right ) \sqrt {-a b}}\right )}{2 \sqrt {-a b}\, d}+\frac {\ln \left ({\mathrm e}^{2 i \left (d x +c \right )}+\frac {2 i a b +\sqrt {-a b}\, a +\sqrt {-a b}\, b}{\left (a -b \right ) \sqrt {-a b}}\right ) a}{2 \sqrt {-a b}\, d b}-\frac {\ln \left ({\mathrm e}^{2 i \left (d x +c \right )}+\frac {2 i a b +\sqrt {-a b}\, a +\sqrt {-a b}\, b}{\left (a -b \right ) \sqrt {-a b}}\right )}{2 \sqrt {-a b}\, d}\) | \(264\) |
Input:
int(sec(d*x+c)^4/(a+b*tan(d*x+c)^2),x,method=_RETURNVERBOSE)
Output:
1/d*(tan(d*x+c)/b+(-a+b)/b/(a*b)^(1/2)*arctan(b*tan(d*x+c)/(a*b)^(1/2)))
Leaf count of result is larger than twice the leaf count of optimal. 93 vs. \(2 (44) = 88\).
Time = 0.12 (sec) , antiderivative size = 267, normalized size of antiderivative = 5.13 \[ \int \frac {\sec ^4(c+d x)}{a+b \tan ^2(c+d x)} \, dx=\left [\frac {\sqrt {-a b} {\left (a - b\right )} \cos \left (d x + c\right ) \log \left (\frac {{\left (a^{2} + 6 \, a b + b^{2}\right )} \cos \left (d x + c\right )^{4} - 2 \, {\left (3 \, a b + b^{2}\right )} \cos \left (d x + c\right )^{2} + 4 \, {\left ({\left (a + b\right )} \cos \left (d x + c\right )^{3} - b \cos \left (d x + c\right )\right )} \sqrt {-a b} \sin \left (d x + c\right ) + b^{2}}{{\left (a^{2} - 2 \, a b + b^{2}\right )} \cos \left (d x + c\right )^{4} + 2 \, {\left (a b - b^{2}\right )} \cos \left (d x + c\right )^{2} + b^{2}}\right ) + 4 \, a b \sin \left (d x + c\right )}{4 \, a b^{2} d \cos \left (d x + c\right )}, \frac {\sqrt {a b} {\left (a - b\right )} \arctan \left (\frac {{\left ({\left (a + b\right )} \cos \left (d x + c\right )^{2} - b\right )} \sqrt {a b}}{2 \, a b \cos \left (d x + c\right ) \sin \left (d x + c\right )}\right ) \cos \left (d x + c\right ) + 2 \, a b \sin \left (d x + c\right )}{2 \, a b^{2} d \cos \left (d x + c\right )}\right ] \] Input:
integrate(sec(d*x+c)^4/(a+b*tan(d*x+c)^2),x, algorithm="fricas")
Output:
[1/4*(sqrt(-a*b)*(a - b)*cos(d*x + c)*log(((a^2 + 6*a*b + b^2)*cos(d*x + c )^4 - 2*(3*a*b + b^2)*cos(d*x + c)^2 + 4*((a + b)*cos(d*x + c)^3 - b*cos(d *x + c))*sqrt(-a*b)*sin(d*x + c) + b^2)/((a^2 - 2*a*b + b^2)*cos(d*x + c)^ 4 + 2*(a*b - b^2)*cos(d*x + c)^2 + b^2)) + 4*a*b*sin(d*x + c))/(a*b^2*d*co s(d*x + c)), 1/2*(sqrt(a*b)*(a - b)*arctan(1/2*((a + b)*cos(d*x + c)^2 - b )*sqrt(a*b)/(a*b*cos(d*x + c)*sin(d*x + c)))*cos(d*x + c) + 2*a*b*sin(d*x + c))/(a*b^2*d*cos(d*x + c))]
\[ \int \frac {\sec ^4(c+d x)}{a+b \tan ^2(c+d x)} \, dx=\int \frac {\sec ^{4}{\left (c + d x \right )}}{a + b \tan ^{2}{\left (c + d x \right )}}\, dx \] Input:
integrate(sec(d*x+c)**4/(a+b*tan(d*x+c)**2),x)
Output:
Integral(sec(c + d*x)**4/(a + b*tan(c + d*x)**2), x)
Time = 0.11 (sec) , antiderivative size = 45, normalized size of antiderivative = 0.87 \[ \int \frac {\sec ^4(c+d x)}{a+b \tan ^2(c+d x)} \, dx=-\frac {\frac {{\left (a - b\right )} \arctan \left (\frac {b \tan \left (d x + c\right )}{\sqrt {a b}}\right )}{\sqrt {a b} b} - \frac {\tan \left (d x + c\right )}{b}}{d} \] Input:
integrate(sec(d*x+c)^4/(a+b*tan(d*x+c)^2),x, algorithm="maxima")
Output:
-((a - b)*arctan(b*tan(d*x + c)/sqrt(a*b))/(sqrt(a*b)*b) - tan(d*x + c)/b) /d
Time = 0.63 (sec) , antiderivative size = 46, normalized size of antiderivative = 0.88 \[ \int \frac {\sec ^4(c+d x)}{a+b \tan ^2(c+d x)} \, dx=-\frac {{\left (a - b\right )} \arctan \left (\frac {b \tan \left (d x + c\right )}{\sqrt {a b}}\right )}{\sqrt {a b} b d} + \frac {\tan \left (d x + c\right )}{b d} \] Input:
integrate(sec(d*x+c)^4/(a+b*tan(d*x+c)^2),x, algorithm="giac")
Output:
-(a - b)*arctan(b*tan(d*x + c)/sqrt(a*b))/(sqrt(a*b)*b*d) + tan(d*x + c)/( b*d)
Time = 7.83 (sec) , antiderivative size = 44, normalized size of antiderivative = 0.85 \[ \int \frac {\sec ^4(c+d x)}{a+b \tan ^2(c+d x)} \, dx=\frac {\mathrm {tan}\left (c+d\,x\right )}{b\,d}-\frac {\mathrm {atan}\left (\frac {\sqrt {b}\,\mathrm {tan}\left (c+d\,x\right )}{\sqrt {a}}\right )\,\left (a-b\right )}{\sqrt {a}\,b^{3/2}\,d} \] Input:
int(1/(cos(c + d*x)^4*(a + b*tan(c + d*x)^2)),x)
Output:
tan(c + d*x)/(b*d) - (atan((b^(1/2)*tan(c + d*x))/a^(1/2))*(a - b))/(a^(1/ 2)*b^(3/2)*d)
Time = 0.29 (sec) , antiderivative size = 180, normalized size of antiderivative = 3.46 \[ \int \frac {\sec ^4(c+d x)}{a+b \tan ^2(c+d x)} \, dx=\frac {\sqrt {b}\, \sqrt {a}\, \mathit {atan} \left (\frac {\sqrt {a -b}-\sqrt {a}\, \tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{\sqrt {b}}\right ) \cos \left (d x +c \right ) a -\sqrt {b}\, \sqrt {a}\, \mathit {atan} \left (\frac {\sqrt {a -b}-\sqrt {a}\, \tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{\sqrt {b}}\right ) \cos \left (d x +c \right ) b -\sqrt {b}\, \sqrt {a}\, \mathit {atan} \left (\frac {\sqrt {a -b}+\sqrt {a}\, \tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{\sqrt {b}}\right ) \cos \left (d x +c \right ) a +\sqrt {b}\, \sqrt {a}\, \mathit {atan} \left (\frac {\sqrt {a -b}+\sqrt {a}\, \tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{\sqrt {b}}\right ) \cos \left (d x +c \right ) b +\sin \left (d x +c \right ) a b}{\cos \left (d x +c \right ) a \,b^{2} d} \] Input:
int(sec(d*x+c)^4/(a+b*tan(d*x+c)^2),x)
Output:
(sqrt(b)*sqrt(a)*atan((sqrt(a - b) - sqrt(a)*tan((c + d*x)/2))/sqrt(b))*co s(c + d*x)*a - sqrt(b)*sqrt(a)*atan((sqrt(a - b) - sqrt(a)*tan((c + d*x)/2 ))/sqrt(b))*cos(c + d*x)*b - sqrt(b)*sqrt(a)*atan((sqrt(a - b) + sqrt(a)*t an((c + d*x)/2))/sqrt(b))*cos(c + d*x)*a + sqrt(b)*sqrt(a)*atan((sqrt(a - b) + sqrt(a)*tan((c + d*x)/2))/sqrt(b))*cos(c + d*x)*b + sin(c + d*x)*a*b) /(cos(c + d*x)*a*b**2*d)