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

Optimal. Leaf size=55 $-\frac{a e^2-b d e+c d^2}{e^3 (d+e x)}-\frac{(2 c d-b e) \log (d+e x)}{e^3}+\frac{c x}{e^2}$

[Out]

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

________________________________________________________________________________________

Rubi [A]  time = 0.0454211, antiderivative size = 55, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 1, integrand size = 18, $$\frac{\text{number of rules}}{\text{integrand size}}$$ = 0.056, Rules used = {698} $-\frac{a e^2-b d e+c d^2}{e^3 (d+e x)}-\frac{(2 c d-b e) \log (d+e x)}{e^3}+\frac{c x}{e^2}$

Antiderivative was successfully veriﬁed.

[In]

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

[Out]

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

Rule 698

Int[((d_.) + (e_.)*(x_))^(m_)*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Int[ExpandIntegrand[(d +
e*x)^m*(a + b*x + c*x^2)^p, x], x] /; FreeQ[{a, b, c, d, e, m}, x] && NeQ[b^2 - 4*a*c, 0] && NeQ[c*d^2 - b*d*
e + a*e^2, 0] && NeQ[2*c*d - b*e, 0] && IntegerQ[p] && (GtQ[p, 0] || (EqQ[a, 0] && IntegerQ[m]))

Rubi steps

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

Mathematica [A]  time = 0.0273447, size = 49, normalized size = 0.89 $\frac{-\frac{a e^2-b d e+c d^2}{d+e x}+(b e-2 c d) \log (d+e x)+c e x}{e^3}$

Antiderivative was successfully veriﬁed.

[In]

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

[Out]

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

________________________________________________________________________________________

Maple [A]  time = 0.049, size = 74, normalized size = 1.4 \begin{align*}{\frac{cx}{{e}^{2}}}+{\frac{\ln \left ( ex+d \right ) b}{{e}^{2}}}-2\,{\frac{cd\ln \left ( ex+d \right ) }{{e}^{3}}}-{\frac{a}{e \left ( ex+d \right ) }}+{\frac{bd}{{e}^{2} \left ( ex+d \right ) }}-{\frac{c{d}^{2}}{{e}^{3} \left ( ex+d \right ) }} \end{align*}

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

[In]

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

[Out]

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

________________________________________________________________________________________

Maxima [A]  time = 0.994857, size = 78, normalized size = 1.42 \begin{align*} -\frac{c d^{2} - b d e + a e^{2}}{e^{4} x + d e^{3}} + \frac{c x}{e^{2}} - \frac{{\left (2 \, c d - b e\right )} \log \left (e x + d\right )}{e^{3}} \end{align*}

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

[In]

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

[Out]

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

________________________________________________________________________________________

Fricas [A]  time = 1.96706, size = 159, normalized size = 2.89 \begin{align*} \frac{c e^{2} x^{2} + c d e x - c d^{2} + b d e - a e^{2} -{\left (2 \, c d^{2} - b d e +{\left (2 \, c d e - b e^{2}\right )} x\right )} \log \left (e x + d\right )}{e^{4} x + d e^{3}} \end{align*}

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

[In]

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

[Out]

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

________________________________________________________________________________________

Sympy [A]  time = 0.509098, size = 49, normalized size = 0.89 \begin{align*} \frac{c x}{e^{2}} - \frac{a e^{2} - b d e + c d^{2}}{d e^{3} + e^{4} x} + \frac{\left (b e - 2 c d\right ) \log{\left (d + e x \right )}}{e^{3}} \end{align*}

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

[In]

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

[Out]

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

________________________________________________________________________________________

Giac [A]  time = 1.10336, size = 143, normalized size = 2.6 \begin{align*} -{\left (e^{\left (-1\right )} \log \left (\frac{{\left | x e + d \right |} e^{\left (-1\right )}}{{\left (x e + d\right )}^{2}}\right ) - \frac{d e^{\left (-1\right )}}{x e + d}\right )} b e^{\left (-1\right )} +{\left (2 \, d e^{\left (-3\right )} \log \left (\frac{{\left | x e + d \right |} e^{\left (-1\right )}}{{\left (x e + d\right )}^{2}}\right ) +{\left (x e + d\right )} e^{\left (-3\right )} - \frac{d^{2} e^{\left (-3\right )}}{x e + d}\right )} c - \frac{a e^{\left (-1\right )}}{x e + d} \end{align*}

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

[In]

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

[Out]

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