Integrand size = 24, antiderivative size = 95 \[ \int \frac {\left (a+b x^2\right ) \left (c+d x^2\right )}{\left (e+f x^2\right )^2} \, dx=\frac {b d x}{f^2}+\frac {(b e-a f) (d e-c f) x}{2 e f^2 \left (e+f x^2\right )}-\frac {(b e (3 d e-c f)-a f (d e+c f)) \arctan \left (\frac {\sqrt {f} x}{\sqrt {e}}\right )}{2 e^{3/2} f^{5/2}} \] Output:
b*d*x/f^2+1/2*(-a*f+b*e)*(-c*f+d*e)*x/e/f^2/(f*x^2+e)-1/2*(b*e*(-c*f+3*d*e )-a*f*(c*f+d*e))*arctan(f^(1/2)*x/e^(1/2))/e^(3/2)/f^(5/2)
Time = 0.06 (sec) , antiderivative size = 95, normalized size of antiderivative = 1.00 \[ \int \frac {\left (a+b x^2\right ) \left (c+d x^2\right )}{\left (e+f x^2\right )^2} \, dx=\frac {b d x}{f^2}+\frac {(b e-a f) (d e-c f) x}{2 e f^2 \left (e+f x^2\right )}-\frac {(b e (3 d e-c f)-a f (d e+c f)) \arctan \left (\frac {\sqrt {f} x}{\sqrt {e}}\right )}{2 e^{3/2} f^{5/2}} \] Input:
Integrate[((a + b*x^2)*(c + d*x^2))/(e + f*x^2)^2,x]
Output:
(b*d*x)/f^2 + ((b*e - a*f)*(d*e - c*f)*x)/(2*e*f^2*(e + f*x^2)) - ((b*e*(3 *d*e - c*f) - a*f*(d*e + c*f))*ArcTan[(Sqrt[f]*x)/Sqrt[e]])/(2*e^(3/2)*f^( 5/2))
Time = 0.23 (sec) , antiderivative size = 111, normalized size of antiderivative = 1.17, number of steps used = 4, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.167, Rules used = {401, 25, 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 {\left (a+b x^2\right ) \left (c+d x^2\right )}{\left (e+f x^2\right )^2} \, dx\) |
\(\Big \downarrow \) 401 |
\(\displaystyle -\frac {\int -\frac {b (3 d e-c f) x^2+a (d e+c f)}{f x^2+e}dx}{2 e f}-\frac {x \left (a+b x^2\right ) (d e-c f)}{2 e f \left (e+f x^2\right )}\) |
\(\Big \downarrow \) 25 |
\(\displaystyle \frac {\int \frac {b (3 d e-c f) x^2+a (d e+c f)}{f x^2+e}dx}{2 e f}-\frac {x \left (a+b x^2\right ) (d e-c f)}{2 e f \left (e+f x^2\right )}\) |
\(\Big \downarrow \) 299 |
\(\displaystyle \frac {\frac {b x (3 d e-c f)}{f}-\frac {(b e (3 d e-c f)-a f (c f+d e)) \int \frac {1}{f x^2+e}dx}{f}}{2 e f}-\frac {x \left (a+b x^2\right ) (d e-c f)}{2 e f \left (e+f x^2\right )}\) |
\(\Big \downarrow \) 218 |
\(\displaystyle \frac {\frac {b x (3 d e-c f)}{f}-\frac {\arctan \left (\frac {\sqrt {f} x}{\sqrt {e}}\right ) (b e (3 d e-c f)-a f (c f+d e))}{\sqrt {e} f^{3/2}}}{2 e f}-\frac {x \left (a+b x^2\right ) (d e-c f)}{2 e f \left (e+f x^2\right )}\) |
Input:
Int[((a + b*x^2)*(c + d*x^2))/(e + f*x^2)^2,x]
Output:
-1/2*((d*e - c*f)*x*(a + b*x^2))/(e*f*(e + f*x^2)) + ((b*(3*d*e - c*f)*x)/ f - ((b*e*(3*d*e - c*f) - a*f*(d*e + c*f))*ArcTan[(Sqrt[f]*x)/Sqrt[e]])/(S qrt[e]*f^(3/2)))/(2*e*f)
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[((a_) + (b_.)*(x_)^2)^(p_)*((c_) + (d_.)*(x_)^2)^(q_.)*((e_) + (f_.)*(x _)^2), x_Symbol] :> Simp[(-(b*e - a*f))*x*(a + b*x^2)^(p + 1)*((c + d*x^2)^ q/(a*b*2*(p + 1))), x] + Simp[1/(a*b*2*(p + 1)) Int[(a + b*x^2)^(p + 1)*( c + d*x^2)^(q - 1)*Simp[c*(b*e*2*(p + 1) + b*e - a*f) + d*(b*e*2*(p + 1) + (b*e - a*f)*(2*q + 1))*x^2, x], x], x] /; FreeQ[{a, b, c, d, e, f}, x] && L tQ[p, -1] && GtQ[q, 0]
Time = 0.58 (sec) , antiderivative size = 97, normalized size of antiderivative = 1.02
method | result | size |
default | \(\frac {b d x}{f^{2}}+\frac {\frac {\left (a c \,f^{2}-a d e f -b c e f +b d \,e^{2}\right ) x}{2 e \left (f \,x^{2}+e \right )}+\frac {\left (a c \,f^{2}+a d e f +b c e f -3 b d \,e^{2}\right ) \arctan \left (\frac {f x}{\sqrt {e f}}\right )}{2 e \sqrt {e f}}}{f^{2}}\) | \(97\) |
risch | \(\frac {b d x}{f^{2}}+\frac {\left (a c \,f^{2}-a d e f -b c e f +b d \,e^{2}\right ) x}{2 e \,f^{2} \left (f \,x^{2}+e \right )}-\frac {\ln \left (f x +\sqrt {-e f}\right ) a c}{4 \sqrt {-e f}\, e}-\frac {\ln \left (f x +\sqrt {-e f}\right ) a d}{4 f \sqrt {-e f}}-\frac {\ln \left (f x +\sqrt {-e f}\right ) b c}{4 f \sqrt {-e f}}+\frac {3 e \ln \left (f x +\sqrt {-e f}\right ) b d}{4 f^{2} \sqrt {-e f}}+\frac {\ln \left (-f x +\sqrt {-e f}\right ) a c}{4 \sqrt {-e f}\, e}+\frac {\ln \left (-f x +\sqrt {-e f}\right ) a d}{4 f \sqrt {-e f}}+\frac {\ln \left (-f x +\sqrt {-e f}\right ) b c}{4 f \sqrt {-e f}}-\frac {3 e \ln \left (-f x +\sqrt {-e f}\right ) b d}{4 f^{2} \sqrt {-e f}}\) | \(250\) |
Input:
int((b*x^2+a)*(d*x^2+c)/(f*x^2+e)^2,x,method=_RETURNVERBOSE)
Output:
b*d*x/f^2+1/f^2*(1/2*(a*c*f^2-a*d*e*f-b*c*e*f+b*d*e^2)/e*x/(f*x^2+e)+1/2*( a*c*f^2+a*d*e*f+b*c*e*f-3*b*d*e^2)/e/(e*f)^(1/2)*arctan(f*x/(e*f)^(1/2)))
Time = 0.09 (sec) , antiderivative size = 318, normalized size of antiderivative = 3.35 \[ \int \frac {\left (a+b x^2\right ) \left (c+d x^2\right )}{\left (e+f x^2\right )^2} \, dx=\left [\frac {4 \, b d e^{2} f^{2} x^{3} + {\left (3 \, b d e^{3} - a c e f^{2} - {\left (b c + a d\right )} e^{2} f + {\left (3 \, b d e^{2} f - a c f^{3} - {\left (b c + a d\right )} e f^{2}\right )} x^{2}\right )} \sqrt {-e f} \log \left (\frac {f x^{2} - 2 \, \sqrt {-e f} x - e}{f x^{2} + e}\right ) + 2 \, {\left (3 \, b d e^{3} f + a c e f^{3} - {\left (b c + a d\right )} e^{2} f^{2}\right )} x}{4 \, {\left (e^{2} f^{4} x^{2} + e^{3} f^{3}\right )}}, \frac {2 \, b d e^{2} f^{2} x^{3} - {\left (3 \, b d e^{3} - a c e f^{2} - {\left (b c + a d\right )} e^{2} f + {\left (3 \, b d e^{2} f - a c f^{3} - {\left (b c + a d\right )} e f^{2}\right )} x^{2}\right )} \sqrt {e f} \arctan \left (\frac {\sqrt {e f} x}{e}\right ) + {\left (3 \, b d e^{3} f + a c e f^{3} - {\left (b c + a d\right )} e^{2} f^{2}\right )} x}{2 \, {\left (e^{2} f^{4} x^{2} + e^{3} f^{3}\right )}}\right ] \] Input:
integrate((b*x^2+a)*(d*x^2+c)/(f*x^2+e)^2,x, algorithm="fricas")
Output:
[1/4*(4*b*d*e^2*f^2*x^3 + (3*b*d*e^3 - a*c*e*f^2 - (b*c + a*d)*e^2*f + (3* b*d*e^2*f - a*c*f^3 - (b*c + a*d)*e*f^2)*x^2)*sqrt(-e*f)*log((f*x^2 - 2*sq rt(-e*f)*x - e)/(f*x^2 + e)) + 2*(3*b*d*e^3*f + a*c*e*f^3 - (b*c + a*d)*e^ 2*f^2)*x)/(e^2*f^4*x^2 + e^3*f^3), 1/2*(2*b*d*e^2*f^2*x^3 - (3*b*d*e^3 - a *c*e*f^2 - (b*c + a*d)*e^2*f + (3*b*d*e^2*f - a*c*f^3 - (b*c + a*d)*e*f^2) *x^2)*sqrt(e*f)*arctan(sqrt(e*f)*x/e) + (3*b*d*e^3*f + a*c*e*f^3 - (b*c + a*d)*e^2*f^2)*x)/(e^2*f^4*x^2 + e^3*f^3)]
Leaf count of result is larger than twice the leaf count of optimal. 190 vs. \(2 (87) = 174\).
Time = 0.60 (sec) , antiderivative size = 190, normalized size of antiderivative = 2.00 \[ \int \frac {\left (a+b x^2\right ) \left (c+d x^2\right )}{\left (e+f x^2\right )^2} \, dx=\frac {b d x}{f^{2}} + \frac {x \left (a c f^{2} - a d e f - b c e f + b d e^{2}\right )}{2 e^{2} f^{2} + 2 e f^{3} x^{2}} - \frac {\sqrt {- \frac {1}{e^{3} f^{5}}} \left (a c f^{2} + a d e f + b c e f - 3 b d e^{2}\right ) \log {\left (- e^{2} f^{2} \sqrt {- \frac {1}{e^{3} f^{5}}} + x \right )}}{4} + \frac {\sqrt {- \frac {1}{e^{3} f^{5}}} \left (a c f^{2} + a d e f + b c e f - 3 b d e^{2}\right ) \log {\left (e^{2} f^{2} \sqrt {- \frac {1}{e^{3} f^{5}}} + x \right )}}{4} \] Input:
integrate((b*x**2+a)*(d*x**2+c)/(f*x**2+e)**2,x)
Output:
b*d*x/f**2 + x*(a*c*f**2 - a*d*e*f - b*c*e*f + b*d*e**2)/(2*e**2*f**2 + 2* e*f**3*x**2) - sqrt(-1/(e**3*f**5))*(a*c*f**2 + a*d*e*f + b*c*e*f - 3*b*d* e**2)*log(-e**2*f**2*sqrt(-1/(e**3*f**5)) + x)/4 + sqrt(-1/(e**3*f**5))*(a *c*f**2 + a*d*e*f + b*c*e*f - 3*b*d*e**2)*log(e**2*f**2*sqrt(-1/(e**3*f**5 )) + x)/4
Exception generated. \[ \int \frac {\left (a+b x^2\right ) \left (c+d x^2\right )}{\left (e+f x^2\right )^2} \, dx=\text {Exception raised: ValueError} \] Input:
integrate((b*x^2+a)*(d*x^2+c)/(f*x^2+e)^2,x, algorithm="maxima")
Output:
Exception raised: ValueError >> Computation failed since Maxima requested additional constraints; using the 'assume' command before evaluation *may* help (example of legal syntax is 'assume(e>0)', see `assume?` for more de tails)Is e
Time = 0.12 (sec) , antiderivative size = 103, normalized size of antiderivative = 1.08 \[ \int \frac {\left (a+b x^2\right ) \left (c+d x^2\right )}{\left (e+f x^2\right )^2} \, dx=\frac {b d x}{f^{2}} - \frac {{\left (3 \, b d e^{2} - b c e f - a d e f - a c f^{2}\right )} \arctan \left (\frac {f x}{\sqrt {e f}}\right )}{2 \, \sqrt {e f} e f^{2}} + \frac {b d e^{2} x - b c e f x - a d e f x + a c f^{2} x}{2 \, {\left (f x^{2} + e\right )} e f^{2}} \] Input:
integrate((b*x^2+a)*(d*x^2+c)/(f*x^2+e)^2,x, algorithm="giac")
Output:
b*d*x/f^2 - 1/2*(3*b*d*e^2 - b*c*e*f - a*d*e*f - a*c*f^2)*arctan(f*x/sqrt( e*f))/(sqrt(e*f)*e*f^2) + 1/2*(b*d*e^2*x - b*c*e*f*x - a*d*e*f*x + a*c*f^2 *x)/((f*x^2 + e)*e*f^2)
Time = 0.17 (sec) , antiderivative size = 95, normalized size of antiderivative = 1.00 \[ \int \frac {\left (a+b x^2\right ) \left (c+d x^2\right )}{\left (e+f x^2\right )^2} \, dx=\frac {b\,d\,x}{f^2}+\frac {\mathrm {atan}\left (\frac {\sqrt {f}\,x}{\sqrt {e}}\right )\,\left (a\,c\,f^2-3\,b\,d\,e^2+a\,d\,e\,f+b\,c\,e\,f\right )}{2\,e^{3/2}\,f^{5/2}}+\frac {x\,\left (a\,c\,f^2+b\,d\,e^2-a\,d\,e\,f-b\,c\,e\,f\right )}{2\,e\,\left (f^3\,x^2+e\,f^2\right )} \] Input:
int(((a + b*x^2)*(c + d*x^2))/(e + f*x^2)^2,x)
Output:
(b*d*x)/f^2 + (atan((f^(1/2)*x)/e^(1/2))*(a*c*f^2 - 3*b*d*e^2 + a*d*e*f + b*c*e*f))/(2*e^(3/2)*f^(5/2)) + (x*(a*c*f^2 + b*d*e^2 - a*d*e*f - b*c*e*f) )/(2*e*(e*f^2 + f^3*x^2))
Time = 0.15 (sec) , antiderivative size = 266, normalized size of antiderivative = 2.80 \[ \int \frac {\left (a+b x^2\right ) \left (c+d x^2\right )}{\left (e+f x^2\right )^2} \, dx=\frac {\sqrt {f}\, \sqrt {e}\, \mathit {atan} \left (\frac {f x}{\sqrt {f}\, \sqrt {e}}\right ) a c e \,f^{2}+\sqrt {f}\, \sqrt {e}\, \mathit {atan} \left (\frac {f x}{\sqrt {f}\, \sqrt {e}}\right ) a c \,f^{3} x^{2}+\sqrt {f}\, \sqrt {e}\, \mathit {atan} \left (\frac {f x}{\sqrt {f}\, \sqrt {e}}\right ) a d \,e^{2} f +\sqrt {f}\, \sqrt {e}\, \mathit {atan} \left (\frac {f x}{\sqrt {f}\, \sqrt {e}}\right ) a d e \,f^{2} x^{2}+\sqrt {f}\, \sqrt {e}\, \mathit {atan} \left (\frac {f x}{\sqrt {f}\, \sqrt {e}}\right ) b c \,e^{2} f +\sqrt {f}\, \sqrt {e}\, \mathit {atan} \left (\frac {f x}{\sqrt {f}\, \sqrt {e}}\right ) b c e \,f^{2} x^{2}-3 \sqrt {f}\, \sqrt {e}\, \mathit {atan} \left (\frac {f x}{\sqrt {f}\, \sqrt {e}}\right ) b d \,e^{3}-3 \sqrt {f}\, \sqrt {e}\, \mathit {atan} \left (\frac {f x}{\sqrt {f}\, \sqrt {e}}\right ) b d \,e^{2} f \,x^{2}+a c e \,f^{3} x -a d \,e^{2} f^{2} x -b c \,e^{2} f^{2} x +3 b d \,e^{3} f x +2 b d \,e^{2} f^{2} x^{3}}{2 e^{2} f^{3} \left (f \,x^{2}+e \right )} \] Input:
int((b*x^2+a)*(d*x^2+c)/(f*x^2+e)^2,x)
Output:
(sqrt(f)*sqrt(e)*atan((f*x)/(sqrt(f)*sqrt(e)))*a*c*e*f**2 + sqrt(f)*sqrt(e )*atan((f*x)/(sqrt(f)*sqrt(e)))*a*c*f**3*x**2 + sqrt(f)*sqrt(e)*atan((f*x) /(sqrt(f)*sqrt(e)))*a*d*e**2*f + sqrt(f)*sqrt(e)*atan((f*x)/(sqrt(f)*sqrt( e)))*a*d*e*f**2*x**2 + sqrt(f)*sqrt(e)*atan((f*x)/(sqrt(f)*sqrt(e)))*b*c*e **2*f + sqrt(f)*sqrt(e)*atan((f*x)/(sqrt(f)*sqrt(e)))*b*c*e*f**2*x**2 - 3* sqrt(f)*sqrt(e)*atan((f*x)/(sqrt(f)*sqrt(e)))*b*d*e**3 - 3*sqrt(f)*sqrt(e) *atan((f*x)/(sqrt(f)*sqrt(e)))*b*d*e**2*f*x**2 + a*c*e*f**3*x - a*d*e**2*f **2*x - b*c*e**2*f**2*x + 3*b*d*e**3*f*x + 2*b*d*e**2*f**2*x**3)/(2*e**2*f **3*(e + f*x**2))