3.507 $$\int \frac{(d+e x)^3}{(a+c x^2)^2} \, dx$$

Optimal. Leaf size=109 $\frac{d \left (3 a e^2+c d^2\right ) \tan ^{-1}\left (\frac{\sqrt{c} x}{\sqrt{a}}\right )}{2 a^{3/2} c^{3/2}}+\frac{e^3 \log \left (a+c x^2\right )}{2 c^2}-\frac{d e^2 x}{2 a c}-\frac{(d+e x)^2 (a e-c d x)}{2 a c \left (a+c x^2\right )}$

[Out]

-(d*e^2*x)/(2*a*c) - ((a*e - c*d*x)*(d + e*x)^2)/(2*a*c*(a + c*x^2)) + (d*(c*d^2 + 3*a*e^2)*ArcTan[(Sqrt[c]*x)
/Sqrt[a]])/(2*a^(3/2)*c^(3/2)) + (e^3*Log[a + c*x^2])/(2*c^2)

________________________________________________________________________________________

Rubi [A]  time = 0.080895, antiderivative size = 109, normalized size of antiderivative = 1., number of steps used = 5, number of rules used = 5, integrand size = 17, $$\frac{\text{number of rules}}{\text{integrand size}}$$ = 0.294, Rules used = {739, 774, 635, 205, 260} $\frac{d \left (3 a e^2+c d^2\right ) \tan ^{-1}\left (\frac{\sqrt{c} x}{\sqrt{a}}\right )}{2 a^{3/2} c^{3/2}}+\frac{e^3 \log \left (a+c x^2\right )}{2 c^2}-\frac{d e^2 x}{2 a c}-\frac{(d+e x)^2 (a e-c d x)}{2 a c \left (a+c x^2\right )}$

Antiderivative was successfully veriﬁed.

[In]

Int[(d + e*x)^3/(a + c*x^2)^2,x]

[Out]

-(d*e^2*x)/(2*a*c) - ((a*e - c*d*x)*(d + e*x)^2)/(2*a*c*(a + c*x^2)) + (d*(c*d^2 + 3*a*e^2)*ArcTan[(Sqrt[c]*x)
/Sqrt[a]])/(2*a^(3/2)*c^(3/2)) + (e^3*Log[a + c*x^2])/(2*c^2)

Rule 739

Int[((d_) + (e_.)*(x_))^(m_)*((a_) + (c_.)*(x_)^2)^(p_), x_Symbol] :> Simp[((d + e*x)^(m - 1)*(a*e - c*d*x)*(a
+ c*x^2)^(p + 1))/(2*a*c*(p + 1)), x] + Dist[1/((p + 1)*(-2*a*c)), Int[(d + e*x)^(m - 2)*Simp[a*e^2*(m - 1) -
c*d^2*(2*p + 3) - d*c*e*(m + 2*p + 2)*x, x]*(a + c*x^2)^(p + 1), x], x] /; FreeQ[{a, c, d, e}, x] && NeQ[c*d^
2 + a*e^2, 0] && LtQ[p, -1] && GtQ[m, 1] && IntQuadraticQ[a, 0, c, d, e, m, p, x]

Rule 774

Int[(((d_.) + (e_.)*(x_))*((f_) + (g_.)*(x_)))/((a_) + (c_.)*(x_)^2), x_Symbol] :> Simp[(e*g*x)/c, x] + Dist[1
/c, Int[(c*d*f - a*e*g + c*(e*f + d*g)*x)/(a + c*x^2), x], x] /; FreeQ[{a, c, d, e, f, g}, x]

Rule 635

Int[((d_) + (e_.)*(x_))/((a_) + (c_.)*(x_)^2), x_Symbol] :> Dist[d, Int[1/(a + c*x^2), x], x] + Dist[e, Int[x/
(a + c*x^2), x], x] /; FreeQ[{a, c, d, e}, x] &&  !NiceSqrtQ[-(a*c)]

Rule 205

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(Rt[a/b, 2]*ArcTan[x/Rt[a/b, 2]])/a, x] /; FreeQ[{a, b}, x]
&& PosQ[a/b]

Rule 260

Int[(x_)^(m_.)/((a_) + (b_.)*(x_)^(n_)), x_Symbol] :> Simp[Log[RemoveContent[a + b*x^n, x]]/(b*n), x] /; FreeQ
[{a, b, m, n}, x] && EqQ[m, n - 1]

Rubi steps

\begin{align*} \int \frac{(d+e x)^3}{\left (a+c x^2\right )^2} \, dx &=-\frac{(a e-c d x) (d+e x)^2}{2 a c \left (a+c x^2\right )}+\frac{\int \frac{(d+e x) \left (c d^2+2 a e^2-c d e x\right )}{a+c x^2} \, dx}{2 a c}\\ &=-\frac{d e^2 x}{2 a c}-\frac{(a e-c d x) (d+e x)^2}{2 a c \left (a+c x^2\right )}+\frac{\int \frac{a c d e^2+c d \left (c d^2+2 a e^2\right )+c \left (-c d^2 e+e \left (c d^2+2 a e^2\right )\right ) x}{a+c x^2} \, dx}{2 a c^2}\\ &=-\frac{d e^2 x}{2 a c}-\frac{(a e-c d x) (d+e x)^2}{2 a c \left (a+c x^2\right )}+\frac{e^3 \int \frac{x}{a+c x^2} \, dx}{c}+\frac{\left (d \left (c d^2+3 a e^2\right )\right ) \int \frac{1}{a+c x^2} \, dx}{2 a c}\\ &=-\frac{d e^2 x}{2 a c}-\frac{(a e-c d x) (d+e x)^2}{2 a c \left (a+c x^2\right )}+\frac{d \left (c d^2+3 a e^2\right ) \tan ^{-1}\left (\frac{\sqrt{c} x}{\sqrt{a}}\right )}{2 a^{3/2} c^{3/2}}+\frac{e^3 \log \left (a+c x^2\right )}{2 c^2}\\ \end{align*}

Mathematica [A]  time = 0.0785699, size = 107, normalized size = 0.98 $\frac{\frac{\sqrt{a} \left (a^2 e^3-3 a c d e (d+e x)+a e^3 \left (a+c x^2\right ) \log \left (a+c x^2\right )+c^2 d^3 x\right )}{a+c x^2}+\sqrt{c} d \left (3 a e^2+c d^2\right ) \tan ^{-1}\left (\frac{\sqrt{c} x}{\sqrt{a}}\right )}{2 a^{3/2} c^2}$

Antiderivative was successfully veriﬁed.

[In]

Integrate[(d + e*x)^3/(a + c*x^2)^2,x]

[Out]

(Sqrt[c]*d*(c*d^2 + 3*a*e^2)*ArcTan[(Sqrt[c]*x)/Sqrt[a]] + (Sqrt[a]*(a^2*e^3 + c^2*d^3*x - 3*a*c*d*e*(d + e*x)
+ a*e^3*(a + c*x^2)*Log[a + c*x^2]))/(a + c*x^2))/(2*a^(3/2)*c^2)

________________________________________________________________________________________

Maple [A]  time = 0.049, size = 115, normalized size = 1.1 \begin{align*}{\frac{1}{c{x}^{2}+a} \left ( -{\frac{d \left ( 3\,a{e}^{2}-c{d}^{2} \right ) x}{2\,ac}}+{\frac{e \left ( a{e}^{2}-3\,c{d}^{2} \right ) }{2\,{c}^{2}}} \right ) }+{\frac{{e}^{3}\ln \left ( c{x}^{2}+a \right ) }{2\,{c}^{2}}}+{\frac{3\,d{e}^{2}}{2\,c}\arctan \left ({cx{\frac{1}{\sqrt{ac}}}} \right ){\frac{1}{\sqrt{ac}}}}+{\frac{{d}^{3}}{2\,a}\arctan \left ({cx{\frac{1}{\sqrt{ac}}}} \right ){\frac{1}{\sqrt{ac}}}} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

int((e*x+d)^3/(c*x^2+a)^2,x)

[Out]

(-1/2*d*(3*a*e^2-c*d^2)/a/c*x+1/2*e*(a*e^2-3*c*d^2)/c^2)/(c*x^2+a)+1/2*e^3*ln(c*x^2+a)/c^2+3/2/c/(a*c)^(1/2)*a
rctan(x*c/(a*c)^(1/2))*d*e^2+1/2/a/(a*c)^(1/2)*arctan(x*c/(a*c)^(1/2))*d^3

________________________________________________________________________________________

Maxima [F(-2)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Exception raised: ValueError} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

integrate((e*x+d)^3/(c*x^2+a)^2,x, algorithm="maxima")

[Out]

Exception raised: ValueError

________________________________________________________________________________________

Fricas [A]  time = 1.92571, size = 639, normalized size = 5.86 \begin{align*} \left [-\frac{6 \, a^{2} c d^{2} e - 2 \, a^{3} e^{3} +{\left (a c d^{3} + 3 \, a^{2} d e^{2} +{\left (c^{2} d^{3} + 3 \, a c d e^{2}\right )} x^{2}\right )} \sqrt{-a c} \log \left (\frac{c x^{2} - 2 \, \sqrt{-a c} x - a}{c x^{2} + a}\right ) - 2 \,{\left (a c^{2} d^{3} - 3 \, a^{2} c d e^{2}\right )} x - 2 \,{\left (a^{2} c e^{3} x^{2} + a^{3} e^{3}\right )} \log \left (c x^{2} + a\right )}{4 \,{\left (a^{2} c^{3} x^{2} + a^{3} c^{2}\right )}}, -\frac{3 \, a^{2} c d^{2} e - a^{3} e^{3} -{\left (a c d^{3} + 3 \, a^{2} d e^{2} +{\left (c^{2} d^{3} + 3 \, a c d e^{2}\right )} x^{2}\right )} \sqrt{a c} \arctan \left (\frac{\sqrt{a c} x}{a}\right ) -{\left (a c^{2} d^{3} - 3 \, a^{2} c d e^{2}\right )} x -{\left (a^{2} c e^{3} x^{2} + a^{3} e^{3}\right )} \log \left (c x^{2} + a\right )}{2 \,{\left (a^{2} c^{3} x^{2} + a^{3} c^{2}\right )}}\right ] \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

integrate((e*x+d)^3/(c*x^2+a)^2,x, algorithm="fricas")

[Out]

[-1/4*(6*a^2*c*d^2*e - 2*a^3*e^3 + (a*c*d^3 + 3*a^2*d*e^2 + (c^2*d^3 + 3*a*c*d*e^2)*x^2)*sqrt(-a*c)*log((c*x^2
- 2*sqrt(-a*c)*x - a)/(c*x^2 + a)) - 2*(a*c^2*d^3 - 3*a^2*c*d*e^2)*x - 2*(a^2*c*e^3*x^2 + a^3*e^3)*log(c*x^2
+ a))/(a^2*c^3*x^2 + a^3*c^2), -1/2*(3*a^2*c*d^2*e - a^3*e^3 - (a*c*d^3 + 3*a^2*d*e^2 + (c^2*d^3 + 3*a*c*d*e^2
)*x^2)*sqrt(a*c)*arctan(sqrt(a*c)*x/a) - (a*c^2*d^3 - 3*a^2*c*d*e^2)*x - (a^2*c*e^3*x^2 + a^3*e^3)*log(c*x^2 +
a))/(a^2*c^3*x^2 + a^3*c^2)]

________________________________________________________________________________________

Sympy [B]  time = 1.40224, size = 298, normalized size = 2.73 \begin{align*} \left (\frac{e^{3}}{2 c^{2}} - \frac{d \sqrt{- a^{3} c^{5}} \left (3 a e^{2} + c d^{2}\right )}{4 a^{3} c^{4}}\right ) \log{\left (x + \frac{4 a^{2} c^{2} \left (\frac{e^{3}}{2 c^{2}} - \frac{d \sqrt{- a^{3} c^{5}} \left (3 a e^{2} + c d^{2}\right )}{4 a^{3} c^{4}}\right ) - 2 a^{2} e^{3}}{3 a c d e^{2} + c^{2} d^{3}} \right )} + \left (\frac{e^{3}}{2 c^{2}} + \frac{d \sqrt{- a^{3} c^{5}} \left (3 a e^{2} + c d^{2}\right )}{4 a^{3} c^{4}}\right ) \log{\left (x + \frac{4 a^{2} c^{2} \left (\frac{e^{3}}{2 c^{2}} + \frac{d \sqrt{- a^{3} c^{5}} \left (3 a e^{2} + c d^{2}\right )}{4 a^{3} c^{4}}\right ) - 2 a^{2} e^{3}}{3 a c d e^{2} + c^{2} d^{3}} \right )} - \frac{- a^{2} e^{3} + 3 a c d^{2} e + x \left (3 a c d e^{2} - c^{2} d^{3}\right )}{2 a^{2} c^{2} + 2 a c^{3} x^{2}} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

integrate((e*x+d)**3/(c*x**2+a)**2,x)

[Out]

(e**3/(2*c**2) - d*sqrt(-a**3*c**5)*(3*a*e**2 + c*d**2)/(4*a**3*c**4))*log(x + (4*a**2*c**2*(e**3/(2*c**2) - d
*sqrt(-a**3*c**5)*(3*a*e**2 + c*d**2)/(4*a**3*c**4)) - 2*a**2*e**3)/(3*a*c*d*e**2 + c**2*d**3)) + (e**3/(2*c**
2) + d*sqrt(-a**3*c**5)*(3*a*e**2 + c*d**2)/(4*a**3*c**4))*log(x + (4*a**2*c**2*(e**3/(2*c**2) + d*sqrt(-a**3*
c**5)*(3*a*e**2 + c*d**2)/(4*a**3*c**4)) - 2*a**2*e**3)/(3*a*c*d*e**2 + c**2*d**3)) - (-a**2*e**3 + 3*a*c*d**2
*e + x*(3*a*c*d*e**2 - c**2*d**3))/(2*a**2*c**2 + 2*a*c**3*x**2)

________________________________________________________________________________________

Giac [A]  time = 1.30426, size = 140, normalized size = 1.28 \begin{align*} \frac{e^{3} \log \left (c x^{2} + a\right )}{2 \, c^{2}} + \frac{{\left (c d^{3} + 3 \, a d e^{2}\right )} \arctan \left (\frac{c x}{\sqrt{a c}}\right )}{2 \, \sqrt{a c} a c} + \frac{{\left (c d^{3} - 3 \, a d e^{2}\right )} x - \frac{3 \, a c d^{2} e - a^{2} e^{3}}{c}}{2 \,{\left (c x^{2} + a\right )} a c} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

integrate((e*x+d)^3/(c*x^2+a)^2,x, algorithm="giac")

[Out]

1/2*e^3*log(c*x^2 + a)/c^2 + 1/2*(c*d^3 + 3*a*d*e^2)*arctan(c*x/sqrt(a*c))/(sqrt(a*c)*a*c) + 1/2*((c*d^3 - 3*a
*d*e^2)*x - (3*a*c*d^2*e - a^2*e^3)/c)/((c*x^2 + a)*a*c)