\(\int \frac {(b d+2 c d x)^2}{(a+b x+c x^2)^3} \, dx\) [77]

Optimal result
Mathematica [A] (verified)
Rubi [A] (verified)
Maple [A] (verified)
Fricas [B] (verification not implemented)
Sympy [B] (verification not implemented)
Maxima [F(-2)]
Giac [A] (verification not implemented)
Mupad [B] (verification not implemented)
Reduce [B] (verification not implemented)

Optimal result

Integrand size = 24, antiderivative size = 100 \[ \int \frac {(b d+2 c d x)^2}{\left (a+b x+c x^2\right )^3} \, dx=-\frac {d^2 (b+2 c x)}{2 \left (a+b x+c x^2\right )^2}-\frac {c d^2 (b+2 c x)}{\left (b^2-4 a c\right ) \left (a+b x+c x^2\right )}+\frac {4 c^2 d^2 \text {arctanh}\left (\frac {b+2 c x}{\sqrt {b^2-4 a c}}\right )}{\left (b^2-4 a c\right )^{3/2}} \] Output:

-1/2*d^2*(2*c*x+b)/(c*x^2+b*x+a)^2-c*d^2*(2*c*x+b)/(-4*a*c+b^2)/(c*x^2+b*x 
+a)+4*c^2*d^2*arctanh((2*c*x+b)/(-4*a*c+b^2)^(1/2))/(-4*a*c+b^2)^(3/2)
 

Mathematica [A] (verified)

Time = 0.06 (sec) , antiderivative size = 98, normalized size of antiderivative = 0.98 \[ \int \frac {(b d+2 c d x)^2}{\left (a+b x+c x^2\right )^3} \, dx=d^2 \left (-\frac {(b+2 c x) \left (b^2+2 b c x+2 c \left (-a+c x^2\right )\right )}{2 \left (b^2-4 a c\right ) (a+x (b+c x))^2}+\frac {4 c^2 \arctan \left (\frac {b+2 c x}{\sqrt {-b^2+4 a c}}\right )}{\left (-b^2+4 a c\right )^{3/2}}\right ) \] Input:

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

Output:

d^2*(-1/2*((b + 2*c*x)*(b^2 + 2*b*c*x + 2*c*(-a + c*x^2)))/((b^2 - 4*a*c)* 
(a + x*(b + c*x))^2) + (4*c^2*ArcTan[(b + 2*c*x)/Sqrt[-b^2 + 4*a*c]])/(-b^ 
2 + 4*a*c)^(3/2))
 

Rubi [A] (verified)

Time = 0.25 (sec) , antiderivative size = 97, normalized size of antiderivative = 0.97, number of steps used = 5, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.167, Rules used = {1110, 1086, 1083, 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 \frac {(b d+2 c d x)^2}{\left (a+b x+c x^2\right )^3} \, dx\)

\(\Big \downarrow \) 1110

\(\displaystyle c d^2 \int \frac {1}{\left (c x^2+b x+a\right )^2}dx-\frac {d^2 (b+2 c x)}{2 \left (a+b x+c x^2\right )^2}\)

\(\Big \downarrow \) 1086

\(\displaystyle c d^2 \left (-\frac {2 c \int \frac {1}{c x^2+b x+a}dx}{b^2-4 a c}-\frac {b+2 c x}{\left (b^2-4 a c\right ) \left (a+b x+c x^2\right )}\right )-\frac {d^2 (b+2 c x)}{2 \left (a+b x+c x^2\right )^2}\)

\(\Big \downarrow \) 1083

\(\displaystyle c d^2 \left (\frac {4 c \int \frac {1}{b^2-(b+2 c x)^2-4 a c}d(b+2 c x)}{b^2-4 a c}-\frac {b+2 c x}{\left (b^2-4 a c\right ) \left (a+b x+c x^2\right )}\right )-\frac {d^2 (b+2 c x)}{2 \left (a+b x+c x^2\right )^2}\)

\(\Big \downarrow \) 219

\(\displaystyle c d^2 \left (\frac {4 c \text {arctanh}\left (\frac {b+2 c x}{\sqrt {b^2-4 a c}}\right )}{\left (b^2-4 a c\right )^{3/2}}-\frac {b+2 c x}{\left (b^2-4 a c\right ) \left (a+b x+c x^2\right )}\right )-\frac {d^2 (b+2 c x)}{2 \left (a+b x+c x^2\right )^2}\)

Input:

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

Output:

-1/2*(d^2*(b + 2*c*x))/(a + b*x + c*x^2)^2 + c*d^2*(-((b + 2*c*x)/((b^2 - 
4*a*c)*(a + b*x + c*x^2))) + (4*c*ArcTanh[(b + 2*c*x)/Sqrt[b^2 - 4*a*c]])/ 
(b^2 - 4*a*c)^(3/2))
 

Defintions of rubi rules used

rule 219
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])
 

rule 1083
Int[((a_) + (b_.)*(x_) + (c_.)*(x_)^2)^(-1), x_Symbol] :> Simp[-2   Subst[I 
nt[1/Simp[b^2 - 4*a*c - x^2, x], x], x, b + 2*c*x], x] /; FreeQ[{a, b, c}, 
x]
 

rule 1086
Int[((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_), x_Symbol] :> Simp[(b + 2*c*x) 
*((a + b*x + c*x^2)^(p + 1)/((p + 1)*(b^2 - 4*a*c))), x] - Simp[2*c*((2*p + 
 3)/((p + 1)*(b^2 - 4*a*c)))   Int[(a + b*x + c*x^2)^(p + 1), x], x] /; Fre 
eQ[{a, b, c}, x] && ILtQ[p, -1]
 

rule 1110
Int[((d_) + (e_.)*(x_))^(m_)*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_), x_Sy 
mbol] :> Simp[d*(d + e*x)^(m - 1)*((a + b*x + c*x^2)^(p + 1)/(b*(p + 1))), 
x] - Simp[d*e*((m - 1)/(b*(p + 1)))   Int[(d + e*x)^(m - 2)*(a + b*x + c*x^ 
2)^(p + 1), x], x] /; FreeQ[{a, b, c, d, e}, x] && EqQ[2*c*d - b*e, 0] && N 
eQ[m + 2*p + 3, 0] && LtQ[p, -1] && GtQ[m, 1] && IntegerQ[2*p]
 
Maple [A] (verified)

Time = 0.89 (sec) , antiderivative size = 148, normalized size of antiderivative = 1.48

method result size
default \(d^{2} \left (\frac {\frac {2 c^{3} x^{3}}{4 a c -b^{2}}+\frac {3 b \,c^{2} x^{2}}{4 a c -b^{2}}-\frac {2 c \left (a c -b^{2}\right ) x}{4 a c -b^{2}}-\frac {\left (2 a c -b^{2}\right ) b}{2 \left (4 a c -b^{2}\right )}}{\left (c \,x^{2}+b x +a \right )^{2}}+\frac {4 c^{2} \arctan \left (\frac {2 c x +b}{\sqrt {4 a c -b^{2}}}\right )}{\left (4 a c -b^{2}\right )^{\frac {3}{2}}}\right )\) \(148\)
risch \(\frac {\frac {2 c^{3} d^{2} x^{3}}{4 a c -b^{2}}+\frac {3 b \,c^{2} d^{2} x^{2}}{4 a c -b^{2}}-\frac {2 c \,d^{2} \left (a c -b^{2}\right ) x}{4 a c -b^{2}}-\frac {b \,d^{2} \left (2 a c -b^{2}\right )}{2 \left (4 a c -b^{2}\right )}}{\left (c \,x^{2}+b x +a \right )^{2}}+\frac {2 d^{2} c^{2} \ln \left (\left (-8 a \,c^{2}+2 b^{2} c \right ) x +\left (-4 a c +b^{2}\right )^{\frac {3}{2}}-4 a b c +b^{3}\right )}{\left (-4 a c +b^{2}\right )^{\frac {3}{2}}}-\frac {2 d^{2} c^{2} \ln \left (\left (8 a \,c^{2}-2 b^{2} c \right ) x +\left (-4 a c +b^{2}\right )^{\frac {3}{2}}+4 a b c -b^{3}\right )}{\left (-4 a c +b^{2}\right )^{\frac {3}{2}}}\) \(227\)

Input:

int((2*c*d*x+b*d)^2/(c*x^2+b*x+a)^3,x,method=_RETURNVERBOSE)
 

Output:

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

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 346 vs. \(2 (94) = 188\).

Time = 0.09 (sec) , antiderivative size = 713, normalized size of antiderivative = 7.13 \[ \int \frac {(b d+2 c d x)^2}{\left (a+b x+c x^2\right )^3} \, dx=\left [-\frac {4 \, {\left (b^{2} c^{3} - 4 \, a c^{4}\right )} d^{2} x^{3} + 6 \, {\left (b^{3} c^{2} - 4 \, a b c^{3}\right )} d^{2} x^{2} + 4 \, {\left (b^{4} c - 5 \, a b^{2} c^{2} + 4 \, a^{2} c^{3}\right )} d^{2} x + {\left (b^{5} - 6 \, a b^{3} c + 8 \, a^{2} b c^{2}\right )} d^{2} + 4 \, {\left (c^{4} d^{2} x^{4} + 2 \, b c^{3} d^{2} x^{3} + 2 \, a b c^{2} d^{2} x + a^{2} c^{2} d^{2} + {\left (b^{2} c^{2} + 2 \, a c^{3}\right )} d^{2} x^{2}\right )} \sqrt {b^{2} - 4 \, a c} \log \left (\frac {2 \, c^{2} x^{2} + 2 \, b c x + b^{2} - 2 \, a c - \sqrt {b^{2} - 4 \, a c} {\left (2 \, c x + b\right )}}{c x^{2} + b x + a}\right )}{2 \, {\left (a^{2} b^{4} - 8 \, a^{3} b^{2} c + 16 \, a^{4} c^{2} + {\left (b^{4} c^{2} - 8 \, a b^{2} c^{3} + 16 \, a^{2} c^{4}\right )} x^{4} + 2 \, {\left (b^{5} c - 8 \, a b^{3} c^{2} + 16 \, a^{2} b c^{3}\right )} x^{3} + {\left (b^{6} - 6 \, a b^{4} c + 32 \, a^{3} c^{3}\right )} x^{2} + 2 \, {\left (a b^{5} - 8 \, a^{2} b^{3} c + 16 \, a^{3} b c^{2}\right )} x\right )}}, -\frac {4 \, {\left (b^{2} c^{3} - 4 \, a c^{4}\right )} d^{2} x^{3} + 6 \, {\left (b^{3} c^{2} - 4 \, a b c^{3}\right )} d^{2} x^{2} + 4 \, {\left (b^{4} c - 5 \, a b^{2} c^{2} + 4 \, a^{2} c^{3}\right )} d^{2} x + {\left (b^{5} - 6 \, a b^{3} c + 8 \, a^{2} b c^{2}\right )} d^{2} - 8 \, {\left (c^{4} d^{2} x^{4} + 2 \, b c^{3} d^{2} x^{3} + 2 \, a b c^{2} d^{2} x + a^{2} c^{2} d^{2} + {\left (b^{2} c^{2} + 2 \, a c^{3}\right )} d^{2} x^{2}\right )} \sqrt {-b^{2} + 4 \, a c} \arctan \left (-\frac {\sqrt {-b^{2} + 4 \, a c} {\left (2 \, c x + b\right )}}{b^{2} - 4 \, a c}\right )}{2 \, {\left (a^{2} b^{4} - 8 \, a^{3} b^{2} c + 16 \, a^{4} c^{2} + {\left (b^{4} c^{2} - 8 \, a b^{2} c^{3} + 16 \, a^{2} c^{4}\right )} x^{4} + 2 \, {\left (b^{5} c - 8 \, a b^{3} c^{2} + 16 \, a^{2} b c^{3}\right )} x^{3} + {\left (b^{6} - 6 \, a b^{4} c + 32 \, a^{3} c^{3}\right )} x^{2} + 2 \, {\left (a b^{5} - 8 \, a^{2} b^{3} c + 16 \, a^{3} b c^{2}\right )} x\right )}}\right ] \] Input:

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

Output:

[-1/2*(4*(b^2*c^3 - 4*a*c^4)*d^2*x^3 + 6*(b^3*c^2 - 4*a*b*c^3)*d^2*x^2 + 4 
*(b^4*c - 5*a*b^2*c^2 + 4*a^2*c^3)*d^2*x + (b^5 - 6*a*b^3*c + 8*a^2*b*c^2) 
*d^2 + 4*(c^4*d^2*x^4 + 2*b*c^3*d^2*x^3 + 2*a*b*c^2*d^2*x + a^2*c^2*d^2 + 
(b^2*c^2 + 2*a*c^3)*d^2*x^2)*sqrt(b^2 - 4*a*c)*log((2*c^2*x^2 + 2*b*c*x + 
b^2 - 2*a*c - sqrt(b^2 - 4*a*c)*(2*c*x + b))/(c*x^2 + b*x + a)))/(a^2*b^4 
- 8*a^3*b^2*c + 16*a^4*c^2 + (b^4*c^2 - 8*a*b^2*c^3 + 16*a^2*c^4)*x^4 + 2* 
(b^5*c - 8*a*b^3*c^2 + 16*a^2*b*c^3)*x^3 + (b^6 - 6*a*b^4*c + 32*a^3*c^3)* 
x^2 + 2*(a*b^5 - 8*a^2*b^3*c + 16*a^3*b*c^2)*x), -1/2*(4*(b^2*c^3 - 4*a*c^ 
4)*d^2*x^3 + 6*(b^3*c^2 - 4*a*b*c^3)*d^2*x^2 + 4*(b^4*c - 5*a*b^2*c^2 + 4* 
a^2*c^3)*d^2*x + (b^5 - 6*a*b^3*c + 8*a^2*b*c^2)*d^2 - 8*(c^4*d^2*x^4 + 2* 
b*c^3*d^2*x^3 + 2*a*b*c^2*d^2*x + a^2*c^2*d^2 + (b^2*c^2 + 2*a*c^3)*d^2*x^ 
2)*sqrt(-b^2 + 4*a*c)*arctan(-sqrt(-b^2 + 4*a*c)*(2*c*x + b)/(b^2 - 4*a*c) 
))/(a^2*b^4 - 8*a^3*b^2*c + 16*a^4*c^2 + (b^4*c^2 - 8*a*b^2*c^3 + 16*a^2*c 
^4)*x^4 + 2*(b^5*c - 8*a*b^3*c^2 + 16*a^2*b*c^3)*x^3 + (b^6 - 6*a*b^4*c + 
32*a^3*c^3)*x^2 + 2*(a*b^5 - 8*a^2*b^3*c + 16*a^3*b*c^2)*x)]
 

Sympy [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 430 vs. \(2 (94) = 188\).

Time = 0.67 (sec) , antiderivative size = 430, normalized size of antiderivative = 4.30 \[ \int \frac {(b d+2 c d x)^2}{\left (a+b x+c x^2\right )^3} \, dx=- 2 c^{2} d^{2} \sqrt {- \frac {1}{\left (4 a c - b^{2}\right )^{3}}} \log {\left (x + \frac {- 32 a^{2} c^{4} d^{2} \sqrt {- \frac {1}{\left (4 a c - b^{2}\right )^{3}}} + 16 a b^{2} c^{3} d^{2} \sqrt {- \frac {1}{\left (4 a c - b^{2}\right )^{3}}} - 2 b^{4} c^{2} d^{2} \sqrt {- \frac {1}{\left (4 a c - b^{2}\right )^{3}}} + 2 b c^{2} d^{2}}{4 c^{3} d^{2}} \right )} + 2 c^{2} d^{2} \sqrt {- \frac {1}{\left (4 a c - b^{2}\right )^{3}}} \log {\left (x + \frac {32 a^{2} c^{4} d^{2} \sqrt {- \frac {1}{\left (4 a c - b^{2}\right )^{3}}} - 16 a b^{2} c^{3} d^{2} \sqrt {- \frac {1}{\left (4 a c - b^{2}\right )^{3}}} + 2 b^{4} c^{2} d^{2} \sqrt {- \frac {1}{\left (4 a c - b^{2}\right )^{3}}} + 2 b c^{2} d^{2}}{4 c^{3} d^{2}} \right )} + \frac {- 2 a b c d^{2} + b^{3} d^{2} + 6 b c^{2} d^{2} x^{2} + 4 c^{3} d^{2} x^{3} + x \left (- 4 a c^{2} d^{2} + 4 b^{2} c d^{2}\right )}{8 a^{3} c - 2 a^{2} b^{2} + x^{4} \cdot \left (8 a c^{3} - 2 b^{2} c^{2}\right ) + x^{3} \cdot \left (16 a b c^{2} - 4 b^{3} c\right ) + x^{2} \cdot \left (16 a^{2} c^{2} + 4 a b^{2} c - 2 b^{4}\right ) + x \left (16 a^{2} b c - 4 a b^{3}\right )} \] Input:

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

Output:

-2*c**2*d**2*sqrt(-1/(4*a*c - b**2)**3)*log(x + (-32*a**2*c**4*d**2*sqrt(- 
1/(4*a*c - b**2)**3) + 16*a*b**2*c**3*d**2*sqrt(-1/(4*a*c - b**2)**3) - 2* 
b**4*c**2*d**2*sqrt(-1/(4*a*c - b**2)**3) + 2*b*c**2*d**2)/(4*c**3*d**2)) 
+ 2*c**2*d**2*sqrt(-1/(4*a*c - b**2)**3)*log(x + (32*a**2*c**4*d**2*sqrt(- 
1/(4*a*c - b**2)**3) - 16*a*b**2*c**3*d**2*sqrt(-1/(4*a*c - b**2)**3) + 2* 
b**4*c**2*d**2*sqrt(-1/(4*a*c - b**2)**3) + 2*b*c**2*d**2)/(4*c**3*d**2)) 
+ (-2*a*b*c*d**2 + b**3*d**2 + 6*b*c**2*d**2*x**2 + 4*c**3*d**2*x**3 + x*( 
-4*a*c**2*d**2 + 4*b**2*c*d**2))/(8*a**3*c - 2*a**2*b**2 + x**4*(8*a*c**3 
- 2*b**2*c**2) + x**3*(16*a*b*c**2 - 4*b**3*c) + x**2*(16*a**2*c**2 + 4*a* 
b**2*c - 2*b**4) + x*(16*a**2*b*c - 4*a*b**3))
 

Maxima [F(-2)]

Exception generated. \[ \int \frac {(b d+2 c d x)^2}{\left (a+b x+c x^2\right )^3} \, dx=\text {Exception raised: ValueError} \] Input:

integrate((2*c*d*x+b*d)^2/(c*x^2+b*x+a)^3,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(4*a*c-b^2>0)', see `assume?` for 
 more deta
 

Giac [A] (verification not implemented)

Time = 0.12 (sec) , antiderivative size = 134, normalized size of antiderivative = 1.34 \[ \int \frac {(b d+2 c d x)^2}{\left (a+b x+c x^2\right )^3} \, dx=-\frac {4 \, c^{2} d^{2} \arctan \left (\frac {2 \, c x + b}{\sqrt {-b^{2} + 4 \, a c}}\right )}{{\left (b^{2} - 4 \, a c\right )} \sqrt {-b^{2} + 4 \, a c}} - \frac {4 \, c^{3} d^{2} x^{3} + 6 \, b c^{2} d^{2} x^{2} + 4 \, b^{2} c d^{2} x - 4 \, a c^{2} d^{2} x + b^{3} d^{2} - 2 \, a b c d^{2}}{2 \, {\left (c x^{2} + b x + a\right )}^{2} {\left (b^{2} - 4 \, a c\right )}} \] Input:

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

Output:

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

Mupad [B] (verification not implemented)

Time = 0.12 (sec) , antiderivative size = 233, normalized size of antiderivative = 2.33 \[ \int \frac {(b d+2 c d x)^2}{\left (a+b x+c x^2\right )^3} \, dx=\frac {4\,c^2\,d^2\,\mathrm {atan}\left (\frac {\left (\frac {4\,c^3\,d^2\,x}{{\left (4\,a\,c-b^2\right )}^{3/2}}-\frac {2\,c^2\,d^2\,\left (b^3-4\,a\,b\,c\right )}{{\left (4\,a\,c-b^2\right )}^{5/2}}\right )\,\left (4\,a\,c-b^2\right )}{2\,c^2\,d^2}\right )}{{\left (4\,a\,c-b^2\right )}^{3/2}}-\frac {\frac {b\,d^2\,\left (2\,a\,c-b^2\right )}{2\,\left (4\,a\,c-b^2\right )}-\frac {2\,c^3\,d^2\,x^3}{4\,a\,c-b^2}-\frac {3\,b\,c^2\,d^2\,x^2}{4\,a\,c-b^2}+\frac {2\,c\,d^2\,x\,\left (a\,c-b^2\right )}{4\,a\,c-b^2}}{x^2\,\left (b^2+2\,a\,c\right )+a^2+c^2\,x^4+2\,a\,b\,x+2\,b\,c\,x^3} \] Input:

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

Output:

(4*c^2*d^2*atan((((4*c^3*d^2*x)/(4*a*c - b^2)^(3/2) - (2*c^2*d^2*(b^3 - 4* 
a*b*c))/(4*a*c - b^2)^(5/2))*(4*a*c - b^2))/(2*c^2*d^2)))/(4*a*c - b^2)^(3 
/2) - ((b*d^2*(2*a*c - b^2))/(2*(4*a*c - b^2)) - (2*c^3*d^2*x^3)/(4*a*c - 
b^2) - (3*b*c^2*d^2*x^2)/(4*a*c - b^2) + (2*c*d^2*x*(a*c - b^2))/(4*a*c - 
b^2))/(x^2*(2*a*c + b^2) + a^2 + c^2*x^4 + 2*a*b*x + 2*b*c*x^3)
 

Reduce [B] (verification not implemented)

Time = 0.20 (sec) , antiderivative size = 521, normalized size of antiderivative = 5.21 \[ \int \frac {(b d+2 c d x)^2}{\left (a+b x+c x^2\right )^3} \, dx=\frac {d^{2} \left (8 \sqrt {4 a c -b^{2}}\, \mathit {atan} \left (\frac {2 c x +b}{\sqrt {4 a c -b^{2}}}\right ) a^{2} b \,c^{2}+16 \sqrt {4 a c -b^{2}}\, \mathit {atan} \left (\frac {2 c x +b}{\sqrt {4 a c -b^{2}}}\right ) a \,b^{2} c^{2} x +16 \sqrt {4 a c -b^{2}}\, \mathit {atan} \left (\frac {2 c x +b}{\sqrt {4 a c -b^{2}}}\right ) a b \,c^{3} x^{2}+8 \sqrt {4 a c -b^{2}}\, \mathit {atan} \left (\frac {2 c x +b}{\sqrt {4 a c -b^{2}}}\right ) b^{3} c^{2} x^{2}+16 \sqrt {4 a c -b^{2}}\, \mathit {atan} \left (\frac {2 c x +b}{\sqrt {4 a c -b^{2}}}\right ) b^{2} c^{3} x^{3}+8 \sqrt {4 a c -b^{2}}\, \mathit {atan} \left (\frac {2 c x +b}{\sqrt {4 a c -b^{2}}}\right ) b \,c^{4} x^{4}-8 a^{3} c^{3}-6 a^{2} b^{2} c^{2}-32 a^{2} b \,c^{3} x -16 a^{2} c^{4} x^{2}+6 a \,b^{4} c +24 a \,b^{3} c^{2} x +20 a \,b^{2} c^{3} x^{2}-8 a \,c^{5} x^{4}-b^{6}-4 b^{5} c x -4 b^{4} c^{2} x^{2}+2 b^{2} c^{4} x^{4}\right )}{2 b \left (16 a^{2} c^{4} x^{4}-8 a \,b^{2} c^{3} x^{4}+b^{4} c^{2} x^{4}+32 a^{2} b \,c^{3} x^{3}-16 a \,b^{3} c^{2} x^{3}+2 b^{5} c \,x^{3}+32 a^{3} c^{3} x^{2}-6 a \,b^{4} c \,x^{2}+b^{6} x^{2}+32 a^{3} b \,c^{2} x -16 a^{2} b^{3} c x +2 a \,b^{5} x +16 a^{4} c^{2}-8 a^{3} b^{2} c +a^{2} b^{4}\right )} \] Input:

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

Output:

(d**2*(8*sqrt(4*a*c - b**2)*atan((b + 2*c*x)/sqrt(4*a*c - b**2))*a**2*b*c* 
*2 + 16*sqrt(4*a*c - b**2)*atan((b + 2*c*x)/sqrt(4*a*c - b**2))*a*b**2*c** 
2*x + 16*sqrt(4*a*c - b**2)*atan((b + 2*c*x)/sqrt(4*a*c - b**2))*a*b*c**3* 
x**2 + 8*sqrt(4*a*c - b**2)*atan((b + 2*c*x)/sqrt(4*a*c - b**2))*b**3*c**2 
*x**2 + 16*sqrt(4*a*c - b**2)*atan((b + 2*c*x)/sqrt(4*a*c - b**2))*b**2*c* 
*3*x**3 + 8*sqrt(4*a*c - b**2)*atan((b + 2*c*x)/sqrt(4*a*c - b**2))*b*c**4 
*x**4 - 8*a**3*c**3 - 6*a**2*b**2*c**2 - 32*a**2*b*c**3*x - 16*a**2*c**4*x 
**2 + 6*a*b**4*c + 24*a*b**3*c**2*x + 20*a*b**2*c**3*x**2 - 8*a*c**5*x**4 
- b**6 - 4*b**5*c*x - 4*b**4*c**2*x**2 + 2*b**2*c**4*x**4))/(2*b*(16*a**4* 
c**2 - 8*a**3*b**2*c + 32*a**3*b*c**2*x + 32*a**3*c**3*x**2 + a**2*b**4 - 
16*a**2*b**3*c*x + 32*a**2*b*c**3*x**3 + 16*a**2*c**4*x**4 + 2*a*b**5*x - 
6*a*b**4*c*x**2 - 16*a*b**3*c**2*x**3 - 8*a*b**2*c**3*x**4 + b**6*x**2 + 2 
*b**5*c*x**3 + b**4*c**2*x**4))