### 3.503 $$\int \frac{1}{(d+e x)^2 (a+c x^2)} \, dx$$

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

[Out]

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

________________________________________________________________________________________

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

Antiderivative was successfully veriﬁed.

[In]

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

[Out]

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

Rule 710

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

Rule 801

Int[(((d_.) + (e_.)*(x_))^(m_)*((f_.) + (g_.)*(x_)))/((a_) + (c_.)*(x_)^2), x_Symbol] :> Int[ExpandIntegrand[(
(d + e*x)^m*(f + g*x))/(a + c*x^2), x], x] /; FreeQ[{a, c, d, e, f, g}, x] && NeQ[c*d^2 + a*e^2, 0] && Integer
Q[m]

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{1}{(d+e x)^2 \left (a+c x^2\right )} \, dx &=-\frac{e}{\left (c d^2+a e^2\right ) (d+e x)}+\frac{c \int \frac{d-e x}{(d+e x) \left (a+c x^2\right )} \, dx}{c d^2+a e^2}\\ &=-\frac{e}{\left (c d^2+a e^2\right ) (d+e x)}+\frac{c \int \left (\frac{2 d e^2}{\left (c d^2+a e^2\right ) (d+e x)}+\frac{c d^2-a e^2-2 c d e x}{\left (c d^2+a e^2\right ) \left (a+c x^2\right )}\right ) \, dx}{c d^2+a e^2}\\ &=-\frac{e}{\left (c d^2+a e^2\right ) (d+e x)}+\frac{2 c d e \log (d+e x)}{\left (c d^2+a e^2\right )^2}+\frac{c \int \frac{c d^2-a e^2-2 c d e x}{a+c x^2} \, dx}{\left (c d^2+a e^2\right )^2}\\ &=-\frac{e}{\left (c d^2+a e^2\right ) (d+e x)}+\frac{2 c d e \log (d+e x)}{\left (c d^2+a e^2\right )^2}-\frac{\left (2 c^2 d e\right ) \int \frac{x}{a+c x^2} \, dx}{\left (c d^2+a e^2\right )^2}+\frac{\left (c \left (c d^2-a e^2\right )\right ) \int \frac{1}{a+c x^2} \, dx}{\left (c d^2+a e^2\right )^2}\\ &=-\frac{e}{\left (c d^2+a e^2\right ) (d+e x)}+\frac{\sqrt{c} \left (c d^2-a e^2\right ) \tan ^{-1}\left (\frac{\sqrt{c} x}{\sqrt{a}}\right )}{\sqrt{a} \left (c d^2+a e^2\right )^2}+\frac{2 c d e \log (d+e x)}{\left (c d^2+a e^2\right )^2}-\frac{c d e \log \left (a+c x^2\right )}{\left (c d^2+a e^2\right )^2}\\ \end{align*}

Mathematica [A]  time = 0.088362, size = 113, normalized size = 0.92 $\frac{\sqrt{c} (d+e x) \left (c d^2-a e^2\right ) \tan ^{-1}\left (\frac{\sqrt{c} x}{\sqrt{a}}\right )-\sqrt{a} e \left (c d (d+e x) \log \left (a+c x^2\right )+a e^2+c d^2-2 c d (d+e x) \log (d+e x)\right )}{\sqrt{a} (d+e x) \left (a e^2+c d^2\right )^2}$

Antiderivative was successfully veriﬁed.

[In]

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

[Out]

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

________________________________________________________________________________________

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

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

[In]

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

[Out]

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

________________________________________________________________________________________

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(1/(e*x+d)^2/(c*x^2+a),x, algorithm="maxima")

[Out]

Exception raised: ValueError

________________________________________________________________________________________

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

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

[In]

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

[Out]

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

________________________________________________________________________________________

Sympy [B]  time = 22.0573, size = 2508, normalized size = 20.39 \begin{align*} \text{result too large to display} \end{align*}

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

[In]

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

[Out]

2*c*d*e*log(x + (112*a**6*c**2*d**3*e**12/(a*e**2 + c*d**2)**4 + 432*a**5*c**3*d**5*e**10/(a*e**2 + c*d**2)**4
- 4*a**5*c*d*e**10/(a*e**2 + c*d**2)**2 + 608*a**4*c**4*d**7*e**8/(a*e**2 + c*d**2)**4 - 32*a**4*c**2*d**3*e*
*8/(a*e**2 + c*d**2)**2 + 352*a**3*c**5*d**9*e**6/(a*e**2 + c*d**2)**4 - 72*a**3*c**3*d**5*e**6/(a*e**2 + c*d*
*2)**2 + 5*a**3*c*d*e**6 + 48*a**2*c**6*d**11*e**4/(a*e**2 + c*d**2)**4 - 64*a**2*c**4*d**7*e**4/(a*e**2 + c*d
**2)**2 - 55*a**2*c**2*d**3*e**4 - 16*a*c**7*d**13*e**2/(a*e**2 + c*d**2)**4 - 20*a*c**5*d**9*e**2/(a*e**2 + c
*d**2)**2 + 3*a*c**3*d**5*e**2 - c**4*d**7)/(a**3*c*e**7 + 33*a**2*c**2*d**2*e**5 - 33*a*c**3*d**4*e**3 - c**4
*d**6*e))/(a*e**2 + c*d**2)**2 - e/(a*d*e**2 + c*d**3 + x*(a*e**3 + c*d**2*e)) + (-c*d*e/(a*e**2 + c*d**2)**2
- sqrt(-a*c)*(a*e**2 - c*d**2)/(2*a*(a**2*e**4 + 2*a*c*d**2*e**2 + c**2*d**4)))*log(x + (28*a**6*d*e**10*(-c*d
*e/(a*e**2 + c*d**2)**2 - sqrt(-a*c)*(a*e**2 - c*d**2)/(2*a*(a**2*e**4 + 2*a*c*d**2*e**2 + c**2*d**4)))**2 + 1
08*a**5*c*d**3*e**8*(-c*d*e/(a*e**2 + c*d**2)**2 - sqrt(-a*c)*(a*e**2 - c*d**2)/(2*a*(a**2*e**4 + 2*a*c*d**2*e
**2 + c**2*d**4)))**2 - 2*a**5*e**9*(-c*d*e/(a*e**2 + c*d**2)**2 - sqrt(-a*c)*(a*e**2 - c*d**2)/(2*a*(a**2*e**
4 + 2*a*c*d**2*e**2 + c**2*d**4))) + 152*a**4*c**2*d**5*e**6*(-c*d*e/(a*e**2 + c*d**2)**2 - sqrt(-a*c)*(a*e**2
- c*d**2)/(2*a*(a**2*e**4 + 2*a*c*d**2*e**2 + c**2*d**4)))**2 - 16*a**4*c*d**2*e**7*(-c*d*e/(a*e**2 + c*d**2)
**2 - sqrt(-a*c)*(a*e**2 - c*d**2)/(2*a*(a**2*e**4 + 2*a*c*d**2*e**2 + c**2*d**4))) + 88*a**3*c**3*d**7*e**4*(
-c*d*e/(a*e**2 + c*d**2)**2 - sqrt(-a*c)*(a*e**2 - c*d**2)/(2*a*(a**2*e**4 + 2*a*c*d**2*e**2 + c**2*d**4)))**2
- 36*a**3*c**2*d**4*e**5*(-c*d*e/(a*e**2 + c*d**2)**2 - sqrt(-a*c)*(a*e**2 - c*d**2)/(2*a*(a**2*e**4 + 2*a*c*
d**2*e**2 + c**2*d**4))) + 5*a**3*c*d*e**6 + 12*a**2*c**4*d**9*e**2*(-c*d*e/(a*e**2 + c*d**2)**2 - sqrt(-a*c)*
(a*e**2 - c*d**2)/(2*a*(a**2*e**4 + 2*a*c*d**2*e**2 + c**2*d**4)))**2 - 32*a**2*c**3*d**6*e**3*(-c*d*e/(a*e**2
+ c*d**2)**2 - sqrt(-a*c)*(a*e**2 - c*d**2)/(2*a*(a**2*e**4 + 2*a*c*d**2*e**2 + c**2*d**4))) - 55*a**2*c**2*d
**3*e**4 - 4*a*c**5*d**11*(-c*d*e/(a*e**2 + c*d**2)**2 - sqrt(-a*c)*(a*e**2 - c*d**2)/(2*a*(a**2*e**4 + 2*a*c*
d**2*e**2 + c**2*d**4)))**2 - 10*a*c**4*d**8*e*(-c*d*e/(a*e**2 + c*d**2)**2 - sqrt(-a*c)*(a*e**2 - c*d**2)/(2*
a*(a**2*e**4 + 2*a*c*d**2*e**2 + c**2*d**4))) + 3*a*c**3*d**5*e**2 - c**4*d**7)/(a**3*c*e**7 + 33*a**2*c**2*d*
*2*e**5 - 33*a*c**3*d**4*e**3 - c**4*d**6*e)) + (-c*d*e/(a*e**2 + c*d**2)**2 + sqrt(-a*c)*(a*e**2 - c*d**2)/(2
*a*(a**2*e**4 + 2*a*c*d**2*e**2 + c**2*d**4)))*log(x + (28*a**6*d*e**10*(-c*d*e/(a*e**2 + c*d**2)**2 + sqrt(-a
*c)*(a*e**2 - c*d**2)/(2*a*(a**2*e**4 + 2*a*c*d**2*e**2 + c**2*d**4)))**2 + 108*a**5*c*d**3*e**8*(-c*d*e/(a*e*
*2 + c*d**2)**2 + sqrt(-a*c)*(a*e**2 - c*d**2)/(2*a*(a**2*e**4 + 2*a*c*d**2*e**2 + c**2*d**4)))**2 - 2*a**5*e*
*9*(-c*d*e/(a*e**2 + c*d**2)**2 + sqrt(-a*c)*(a*e**2 - c*d**2)/(2*a*(a**2*e**4 + 2*a*c*d**2*e**2 + c**2*d**4))
) + 152*a**4*c**2*d**5*e**6*(-c*d*e/(a*e**2 + c*d**2)**2 + sqrt(-a*c)*(a*e**2 - c*d**2)/(2*a*(a**2*e**4 + 2*a*
c*d**2*e**2 + c**2*d**4)))**2 - 16*a**4*c*d**2*e**7*(-c*d*e/(a*e**2 + c*d**2)**2 + sqrt(-a*c)*(a*e**2 - c*d**2
)/(2*a*(a**2*e**4 + 2*a*c*d**2*e**2 + c**2*d**4))) + 88*a**3*c**3*d**7*e**4*(-c*d*e/(a*e**2 + c*d**2)**2 + sqr
t(-a*c)*(a*e**2 - c*d**2)/(2*a*(a**2*e**4 + 2*a*c*d**2*e**2 + c**2*d**4)))**2 - 36*a**3*c**2*d**4*e**5*(-c*d*e
/(a*e**2 + c*d**2)**2 + sqrt(-a*c)*(a*e**2 - c*d**2)/(2*a*(a**2*e**4 + 2*a*c*d**2*e**2 + c**2*d**4))) + 5*a**3
*c*d*e**6 + 12*a**2*c**4*d**9*e**2*(-c*d*e/(a*e**2 + c*d**2)**2 + sqrt(-a*c)*(a*e**2 - c*d**2)/(2*a*(a**2*e**4
+ 2*a*c*d**2*e**2 + c**2*d**4)))**2 - 32*a**2*c**3*d**6*e**3*(-c*d*e/(a*e**2 + c*d**2)**2 + sqrt(-a*c)*(a*e**
2 - c*d**2)/(2*a*(a**2*e**4 + 2*a*c*d**2*e**2 + c**2*d**4))) - 55*a**2*c**2*d**3*e**4 - 4*a*c**5*d**11*(-c*d*e
/(a*e**2 + c*d**2)**2 + sqrt(-a*c)*(a*e**2 - c*d**2)/(2*a*(a**2*e**4 + 2*a*c*d**2*e**2 + c**2*d**4)))**2 - 10*
a*c**4*d**8*e*(-c*d*e/(a*e**2 + c*d**2)**2 + sqrt(-a*c)*(a*e**2 - c*d**2)/(2*a*(a**2*e**4 + 2*a*c*d**2*e**2 +
c**2*d**4))) + 3*a*c**3*d**5*e**2 - c**4*d**7)/(a**3*c*e**7 + 33*a**2*c**2*d**2*e**5 - 33*a*c**3*d**4*e**3 - c
**4*d**6*e))

________________________________________________________________________________________

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

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

[In]

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

[Out]

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