3.17.15 \(\int \frac {5+10 x+2 x^2-375 x^3-75 x^4+250 x^5+50 x^6-35 x^7-7 x^8}{5 x+x^2} \, dx\)

Optimal. Leaf size=28 \[ -6+2 x-x \left (5 x-x^3\right )^2+\log \left (\frac {2 x}{5+x}\right ) \]

________________________________________________________________________________________

Rubi [A]  time = 0.08, antiderivative size = 27, normalized size of antiderivative = 0.96, number of steps used = 3, number of rules used = 2, integrand size = 50, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.040, Rules used = {1593, 1620} \begin {gather*} -x^7+10 x^5-25 x^3+2 x+\log (x)-\log (x+5) \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(5 + 10*x + 2*x^2 - 375*x^3 - 75*x^4 + 250*x^5 + 50*x^6 - 35*x^7 - 7*x^8)/(5*x + x^2),x]

[Out]

2*x - 25*x^3 + 10*x^5 - x^7 + Log[x] - Log[5 + x]

Rule 1593

Int[(u_.)*((a_.)*(x_)^(p_.) + (b_.)*(x_)^(q_.))^(n_.), x_Symbol] :> Int[u*x^(n*p)*(a + b*x^(q - p))^n, x] /; F
reeQ[{a, b, p, q}, x] && IntegerQ[n] && PosQ[q - p]

Rule 1620

Int[(Px_)*((a_.) + (b_.)*(x_))^(m_.)*((c_.) + (d_.)*(x_))^(n_.), x_Symbol] :> Int[ExpandIntegrand[Px*(a + b*x)
^m*(c + d*x)^n, x], x] /; FreeQ[{a, b, c, d, m, n}, x] && PolyQ[Px, x] && (IntegersQ[m, n] || IGtQ[m, -2]) &&
GtQ[Expon[Px, x], 2]

Rubi steps

\begin {gather*} \begin {aligned} \text {integral} &=\int \frac {5+10 x+2 x^2-375 x^3-75 x^4+250 x^5+50 x^6-35 x^7-7 x^8}{x (5+x)} \, dx\\ &=\int \left (2+\frac {1}{-5-x}+\frac {1}{x}-75 x^2+50 x^4-7 x^6\right ) \, dx\\ &=2 x-25 x^3+10 x^5-x^7+\log (x)-\log (5+x)\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

Mathematica [A]  time = 0.01, size = 27, normalized size = 0.96 \begin {gather*} 2 x-25 x^3+10 x^5-x^7+\log (x)-\log (5+x) \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(5 + 10*x + 2*x^2 - 375*x^3 - 75*x^4 + 250*x^5 + 50*x^6 - 35*x^7 - 7*x^8)/(5*x + x^2),x]

[Out]

2*x - 25*x^3 + 10*x^5 - x^7 + Log[x] - Log[5 + x]

________________________________________________________________________________________

fricas [A]  time = 0.83, size = 27, normalized size = 0.96 \begin {gather*} -x^{7} + 10 \, x^{5} - 25 \, x^{3} + 2 \, x - \log \left (x + 5\right ) + \log \relax (x) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-7*x^8-35*x^7+50*x^6+250*x^5-75*x^4-375*x^3+2*x^2+10*x+5)/(x^2+5*x),x, algorithm="fricas")

[Out]

-x^7 + 10*x^5 - 25*x^3 + 2*x - log(x + 5) + log(x)

________________________________________________________________________________________

giac [A]  time = 0.14, size = 29, normalized size = 1.04 \begin {gather*} -x^{7} + 10 \, x^{5} - 25 \, x^{3} + 2 \, x - \log \left ({\left | x + 5 \right |}\right ) + \log \left ({\left | x \right |}\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-7*x^8-35*x^7+50*x^6+250*x^5-75*x^4-375*x^3+2*x^2+10*x+5)/(x^2+5*x),x, algorithm="giac")

[Out]

-x^7 + 10*x^5 - 25*x^3 + 2*x - log(abs(x + 5)) + log(abs(x))

________________________________________________________________________________________

maple [A]  time = 0.28, size = 28, normalized size = 1.00




method result size



default \(-x^{7}+10 x^{5}-25 x^{3}+2 x +\ln \relax (x )-\ln \left (5+x \right )\) \(28\)
norman \(-x^{7}+10 x^{5}-25 x^{3}+2 x +\ln \relax (x )-\ln \left (5+x \right )\) \(28\)
risch \(-x^{7}+10 x^{5}-25 x^{3}+2 x +\ln \relax (x )-\ln \left (5+x \right )\) \(28\)
meijerg \(-\ln \left (1+\frac {x}{5}\right )+\ln \relax (x )-\ln \relax (5)-\frac {3125 x \left (\frac {24}{3125} x^{6}-\frac {28}{625} x^{5}+\frac {168}{625} x^{4}-\frac {42}{25} x^{3}+\frac {56}{5} x^{2}-84 x +840\right )}{24}+\frac {3125 x \left (-\frac {14}{625} x^{5}+\frac {84}{625} x^{4}-\frac {21}{25} x^{3}+\frac {28}{5} x^{2}-42 x +420\right )}{12}+\frac {3125 x \left (\frac {12}{625} x^{4}-\frac {3}{25} x^{3}+\frac {4}{5} x^{2}-6 x +60\right )}{6}-\frac {3125 x \left (-\frac {3}{25} x^{3}+\frac {4}{5} x^{2}-6 x +60\right )}{6}-\frac {625 x \left (\frac {4}{25} x^{2}-\frac {6}{5} x +12\right )}{4}+\frac {625 x \left (-\frac {3 x}{5}+6\right )}{2}+2 x\) \(142\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

int((-7*x^8-35*x^7+50*x^6+250*x^5-75*x^4-375*x^3+2*x^2+10*x+5)/(x^2+5*x),x,method=_RETURNVERBOSE)

[Out]

-x^7+10*x^5-25*x^3+2*x+ln(x)-ln(5+x)

________________________________________________________________________________________

maxima [A]  time = 0.35, size = 27, normalized size = 0.96 \begin {gather*} -x^{7} + 10 \, x^{5} - 25 \, x^{3} + 2 \, x - \log \left (x + 5\right ) + \log \relax (x) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-7*x^8-35*x^7+50*x^6+250*x^5-75*x^4-375*x^3+2*x^2+10*x+5)/(x^2+5*x),x, algorithm="maxima")

[Out]

-x^7 + 10*x^5 - 25*x^3 + 2*x - log(x + 5) + log(x)

________________________________________________________________________________________

mupad [B]  time = 1.05, size = 30, normalized size = 1.07 \begin {gather*} 2\,x-25\,x^3+10\,x^5-x^7+\mathrm {atan}\left (\frac {x\,2{}\mathrm {i}}{5}+1{}\mathrm {i}\right )\,2{}\mathrm {i} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((10*x + 2*x^2 - 375*x^3 - 75*x^4 + 250*x^5 + 50*x^6 - 35*x^7 - 7*x^8 + 5)/(5*x + x^2),x)

[Out]

2*x + atan((x*2i)/5 + 1i)*2i - 25*x^3 + 10*x^5 - x^7

________________________________________________________________________________________

sympy [A]  time = 0.09, size = 24, normalized size = 0.86 \begin {gather*} - x^{7} + 10 x^{5} - 25 x^{3} + 2 x + \log {\relax (x )} - \log {\left (x + 5 \right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-7*x**8-35*x**7+50*x**6+250*x**5-75*x**4-375*x**3+2*x**2+10*x+5)/(x**2+5*x),x)

[Out]

-x**7 + 10*x**5 - 25*x**3 + 2*x + log(x) - log(x + 5)

________________________________________________________________________________________