3.8.22 \(\int \frac {-8-33 x+17 x^2+e^x (-15+5 x+5 x^2)+(28+14 x-14 x^2+e^x (10+5 x-5 x^2)) \log (-2-x+x^2)+(-10-5 x+5 x^2) \log ^2(-2-x+x^2)}{-10-5 x+5 x^2+(20+10 x-10 x^2) \log (-2-x+x^2)+(-10-5 x+5 x^2) \log ^2(-2-x+x^2)} \, dx\)

Optimal. Leaf size=27 \[ x-\frac {-2+e^x+\frac {4 x}{5}}{-1+\log \left (-2-x+x^2\right )} \]

________________________________________________________________________________________

Rubi [F]  time = 4.11, antiderivative size = 0, normalized size of antiderivative = 0.00, number of steps used = 0, number of rules used = 0, integrand size = 0, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.000, Rules used = {} \begin {gather*} \int \frac {-8-33 x+17 x^2+e^x \left (-15+5 x+5 x^2\right )+\left (28+14 x-14 x^2+e^x \left (10+5 x-5 x^2\right )\right ) \log \left (-2-x+x^2\right )+\left (-10-5 x+5 x^2\right ) \log ^2\left (-2-x+x^2\right )}{-10-5 x+5 x^2+\left (20+10 x-10 x^2\right ) \log \left (-2-x+x^2\right )+\left (-10-5 x+5 x^2\right ) \log ^2\left (-2-x+x^2\right )} \, dx \end {gather*}

Verification is not applicable to the result.

[In]

Int[(-8 - 33*x + 17*x^2 + E^x*(-15 + 5*x + 5*x^2) + (28 + 14*x - 14*x^2 + E^x*(10 + 5*x - 5*x^2))*Log[-2 - x +
 x^2] + (-10 - 5*x + 5*x^2)*Log[-2 - x + x^2]^2)/(-10 - 5*x + 5*x^2 + (20 + 10*x - 10*x^2)*Log[-2 - x + x^2] +
 (-10 - 5*x + 5*x^2)*Log[-2 - x + x^2]^2),x]

[Out]

x + (8*Defer[Int][(-1 + Log[-2 - x + x^2])^(-2), x])/5 - (2*Defer[Int][1/((-2 + x)*(-1 + Log[-2 - x + x^2])^2)
, x])/5 + Defer[Int][E^x/((-2 + x)*(-1 + Log[-2 - x + x^2])^2), x] - (14*Defer[Int][1/((1 + x)*(-1 + Log[-2 -
x + x^2])^2), x])/5 + Defer[Int][E^x/((1 + x)*(-1 + Log[-2 - x + x^2])^2), x] - (4*Defer[Int][(-1 + Log[-2 - x
 + x^2])^(-1), x])/5 - Defer[Int][E^x/(-1 + Log[-2 - x + x^2]), x]

Rubi steps

\begin {gather*} \begin {aligned} \text {integral} &=\int \frac {8+33 x-17 x^2-5 e^x \left (-3+x+x^2\right )+\left (14+5 e^x\right ) \left (-2-x+x^2\right ) \log \left (-2-x+x^2\right )-5 \left (-2-x+x^2\right ) \log ^2\left (-2-x+x^2\right )}{5 \left (2+x-x^2\right ) \left (1-\log \left (-2-x+x^2\right )\right )^2} \, dx\\ &=\frac {1}{5} \int \frac {8+33 x-17 x^2-5 e^x \left (-3+x+x^2\right )+\left (14+5 e^x\right ) \left (-2-x+x^2\right ) \log \left (-2-x+x^2\right )-5 \left (-2-x+x^2\right ) \log ^2\left (-2-x+x^2\right )}{\left (2+x-x^2\right ) \left (1-\log \left (-2-x+x^2\right )\right )^2} \, dx\\ &=\frac {1}{5} \int \left (-\frac {8}{(-2+x) (1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2}-\frac {33 x}{(-2+x) (1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2}+\frac {17 x^2}{(-2+x) (1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2}-\frac {14 \log \left (-2-x+x^2\right )}{\left (-1+\log \left (-2-x+x^2\right )\right )^2}+\frac {5 \log ^2\left (-2-x+x^2\right )}{\left (-1+\log \left (-2-x+x^2\right )\right )^2}-\frac {5 e^x \left (3-x-x^2-2 \log \left (-2-x+x^2\right )-x \log \left (-2-x+x^2\right )+x^2 \log \left (-2-x+x^2\right )\right )}{(-2+x) (1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2}\right ) \, dx\\ &=-\left (\frac {8}{5} \int \frac {1}{(-2+x) (1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx\right )-\frac {14}{5} \int \frac {\log \left (-2-x+x^2\right )}{\left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx+\frac {17}{5} \int \frac {x^2}{(-2+x) (1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx-\frac {33}{5} \int \frac {x}{(-2+x) (1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx+\int \frac {\log ^2\left (-2-x+x^2\right )}{\left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx-\int \frac {e^x \left (3-x-x^2-2 \log \left (-2-x+x^2\right )-x \log \left (-2-x+x^2\right )+x^2 \log \left (-2-x+x^2\right )\right )}{(-2+x) (1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx\\ &=-\left (\frac {8}{5} \int \left (\frac {1}{3 (-2+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2}-\frac {1}{3 (1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2}\right ) \, dx\right )-\frac {14}{5} \int \left (\frac {1}{\left (-1+\log \left (-2-x+x^2\right )\right )^2}+\frac {1}{-1+\log \left (-2-x+x^2\right )}\right ) \, dx+\frac {17}{5} \int \left (\frac {1}{\left (-1+\log \left (-2-x+x^2\right )\right )^2}+\frac {4}{3 (-2+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2}-\frac {1}{3 (1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2}\right ) \, dx-\frac {33}{5} \int \left (\frac {2}{3 (-2+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2}+\frac {1}{3 (1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2}\right ) \, dx+\int \left (1+\frac {1}{\left (-1+\log \left (-2-x+x^2\right )\right )^2}+\frac {2}{-1+\log \left (-2-x+x^2\right )}\right ) \, dx-\int \frac {e^x \left (-3+x+x^2-\left (-2-x+x^2\right ) \log \left (-2-x+x^2\right )\right )}{(2-x) (1+x) \left (1-\log \left (-2-x+x^2\right )\right )^2} \, dx\\ &=x-\frac {8}{15} \int \frac {1}{(-2+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx+\frac {8}{15} \int \frac {1}{(1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx-\frac {17}{15} \int \frac {1}{(1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx+2 \int \frac {1}{-1+\log \left (-2-x+x^2\right )} \, dx-\frac {11}{5} \int \frac {1}{(1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx-\frac {14}{5} \int \frac {1}{\left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx-\frac {14}{5} \int \frac {1}{-1+\log \left (-2-x+x^2\right )} \, dx+\frac {17}{5} \int \frac {1}{\left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx-\frac {22}{5} \int \frac {1}{(-2+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx+\frac {68}{15} \int \frac {1}{(-2+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx-\int \left (\frac {e^x (1-2 x)}{(-2+x) (1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2}+\frac {e^x}{-1+\log \left (-2-x+x^2\right )}\right ) \, dx+\int \frac {1}{\left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx\\ &=x-\frac {8}{15} \int \frac {1}{(-2+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx+\frac {8}{15} \int \frac {1}{(1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx-\frac {17}{15} \int \frac {1}{(1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx+2 \int \frac {1}{-1+\log \left (-2-x+x^2\right )} \, dx-\frac {11}{5} \int \frac {1}{(1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx-\frac {14}{5} \int \frac {1}{\left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx-\frac {14}{5} \int \frac {1}{-1+\log \left (-2-x+x^2\right )} \, dx+\frac {17}{5} \int \frac {1}{\left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx-\frac {22}{5} \int \frac {1}{(-2+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx+\frac {68}{15} \int \frac {1}{(-2+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx+\int \frac {1}{\left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx-\int \frac {e^x (1-2 x)}{(-2+x) (1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx-\int \frac {e^x}{-1+\log \left (-2-x+x^2\right )} \, dx\\ &=x-\frac {8}{15} \int \frac {1}{(-2+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx+\frac {8}{15} \int \frac {1}{(1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx-\frac {17}{15} \int \frac {1}{(1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx+2 \int \frac {1}{-1+\log \left (-2-x+x^2\right )} \, dx-\frac {11}{5} \int \frac {1}{(1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx-\frac {14}{5} \int \frac {1}{\left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx-\frac {14}{5} \int \frac {1}{-1+\log \left (-2-x+x^2\right )} \, dx+\frac {17}{5} \int \frac {1}{\left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx-\frac {22}{5} \int \frac {1}{(-2+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx+\frac {68}{15} \int \frac {1}{(-2+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx-\int \left (-\frac {e^x}{(-2+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2}-\frac {e^x}{(1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2}\right ) \, dx+\int \frac {1}{\left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx-\int \frac {e^x}{-1+\log \left (-2-x+x^2\right )} \, dx\\ &=x-\frac {8}{15} \int \frac {1}{(-2+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx+\frac {8}{15} \int \frac {1}{(1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx-\frac {17}{15} \int \frac {1}{(1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx+2 \int \frac {1}{-1+\log \left (-2-x+x^2\right )} \, dx-\frac {11}{5} \int \frac {1}{(1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx-\frac {14}{5} \int \frac {1}{\left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx-\frac {14}{5} \int \frac {1}{-1+\log \left (-2-x+x^2\right )} \, dx+\frac {17}{5} \int \frac {1}{\left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx-\frac {22}{5} \int \frac {1}{(-2+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx+\frac {68}{15} \int \frac {1}{(-2+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx+\int \frac {1}{\left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx+\int \frac {e^x}{(-2+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx+\int \frac {e^x}{(1+x) \left (-1+\log \left (-2-x+x^2\right )\right )^2} \, dx-\int \frac {e^x}{-1+\log \left (-2-x+x^2\right )} \, dx\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

Mathematica [A]  time = 0.08, size = 33, normalized size = 1.22 \begin {gather*} \frac {1}{5} \left (5 x-\frac {-10+5 e^x+4 x}{-1+\log \left (-2-x+x^2\right )}\right ) \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(-8 - 33*x + 17*x^2 + E^x*(-15 + 5*x + 5*x^2) + (28 + 14*x - 14*x^2 + E^x*(10 + 5*x - 5*x^2))*Log[-2
 - x + x^2] + (-10 - 5*x + 5*x^2)*Log[-2 - x + x^2]^2)/(-10 - 5*x + 5*x^2 + (20 + 10*x - 10*x^2)*Log[-2 - x +
x^2] + (-10 - 5*x + 5*x^2)*Log[-2 - x + x^2]^2),x]

[Out]

(5*x - (-10 + 5*E^x + 4*x)/(-1 + Log[-2 - x + x^2]))/5

________________________________________________________________________________________

fricas [A]  time = 1.04, size = 36, normalized size = 1.33 \begin {gather*} \frac {5 \, x \log \left (x^{2} - x - 2\right ) - 9 \, x - 5 \, e^{x} + 10}{5 \, {\left (\log \left (x^{2} - x - 2\right ) - 1\right )}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((5*x^2-5*x-10)*log(x^2-x-2)^2+((-5*x^2+5*x+10)*exp(x)-14*x^2+14*x+28)*log(x^2-x-2)+(5*x^2+5*x-15)*e
xp(x)+17*x^2-33*x-8)/((5*x^2-5*x-10)*log(x^2-x-2)^2+(-10*x^2+10*x+20)*log(x^2-x-2)+5*x^2-5*x-10),x, algorithm=
"fricas")

[Out]

1/5*(5*x*log(x^2 - x - 2) - 9*x - 5*e^x + 10)/(log(x^2 - x - 2) - 1)

________________________________________________________________________________________

giac [A]  time = 0.43, size = 36, normalized size = 1.33 \begin {gather*} \frac {5 \, x \log \left (x^{2} - x - 2\right ) - 9 \, x - 5 \, e^{x} + 10}{5 \, {\left (\log \left (x^{2} - x - 2\right ) - 1\right )}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((5*x^2-5*x-10)*log(x^2-x-2)^2+((-5*x^2+5*x+10)*exp(x)-14*x^2+14*x+28)*log(x^2-x-2)+(5*x^2+5*x-15)*e
xp(x)+17*x^2-33*x-8)/((5*x^2-5*x-10)*log(x^2-x-2)^2+(-10*x^2+10*x+20)*log(x^2-x-2)+5*x^2-5*x-10),x, algorithm=
"giac")

[Out]

1/5*(5*x*log(x^2 - x - 2) - 9*x - 5*e^x + 10)/(log(x^2 - x - 2) - 1)

________________________________________________________________________________________

maple [A]  time = 0.22, size = 27, normalized size = 1.00




method result size



risch \(x -\frac {4 x +5 \,{\mathrm e}^{x}-10}{5 \left (\ln \left (x^{2}-x -2\right )-1\right )}\) \(27\)
norman \(\frac {2 \ln \left (x^{2}-x -2\right )+\ln \left (x^{2}-x -2\right ) x -\frac {9 x}{5}-{\mathrm e}^{x}}{\ln \left (x^{2}-x -2\right )-1}\) \(45\)
default \(\frac {2 \ln \left (x^{2}-x -2\right )^{2}+\ln \left (x^{2}-x -2\right ) x -\frac {9 x}{5}}{\ln \left (x^{2}-x -2\right )-1}-2 \ln \left (x -2\right )-2 \ln \left (x +1\right )-\frac {{\mathrm e}^{x}}{\ln \left (x^{2}-x -2\right )-1}\) \(73\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

int(((5*x^2-5*x-10)*ln(x^2-x-2)^2+((-5*x^2+5*x+10)*exp(x)-14*x^2+14*x+28)*ln(x^2-x-2)+(5*x^2+5*x-15)*exp(x)+17
*x^2-33*x-8)/((5*x^2-5*x-10)*ln(x^2-x-2)^2+(-10*x^2+10*x+20)*ln(x^2-x-2)+5*x^2-5*x-10),x,method=_RETURNVERBOSE
)

[Out]

x-1/5*(4*x+5*exp(x)-10)/(ln(x^2-x-2)-1)

________________________________________________________________________________________

maxima [A]  time = 0.81, size = 37, normalized size = 1.37 \begin {gather*} \frac {5 \, x \log \left (x + 1\right ) + 5 \, x \log \left (x - 2\right ) - 9 \, x - 5 \, e^{x} + 10}{5 \, {\left (\log \left (x + 1\right ) + \log \left (x - 2\right ) - 1\right )}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((5*x^2-5*x-10)*log(x^2-x-2)^2+((-5*x^2+5*x+10)*exp(x)-14*x^2+14*x+28)*log(x^2-x-2)+(5*x^2+5*x-15)*e
xp(x)+17*x^2-33*x-8)/((5*x^2-5*x-10)*log(x^2-x-2)^2+(-10*x^2+10*x+20)*log(x^2-x-2)+5*x^2-5*x-10),x, algorithm=
"maxima")

[Out]

1/5*(5*x*log(x + 1) + 5*x*log(x - 2) - 9*x - 5*e^x + 10)/(log(x + 1) + log(x - 2) - 1)

________________________________________________________________________________________

mupad [B]  time = 0.90, size = 112, normalized size = 4.15 \begin {gather*} \frac {3\,x}{5}+\frac {9}{10\,\left (x-\frac {1}{2}\right )}-\frac {\frac {5\,x^2\,{\mathrm {e}}^x-15\,{\mathrm {e}}^x-28\,x+5\,x\,{\mathrm {e}}^x+12\,x^2+2}{5\,\left (2\,x-1\right )}+\frac {\ln \left (x^2-x-2\right )\,\left (5\,{\mathrm {e}}^x+4\right )\,\left (-x^2+x+2\right )}{5\,\left (2\,x-1\right )}}{\ln \left (x^2-x-2\right )-1}+\frac {{\mathrm {e}}^x\,\left (-\frac {x^2}{2}+\frac {x}{2}+1\right )}{x-\frac {1}{2}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((33*x + log(x^2 - x - 2)^2*(5*x - 5*x^2 + 10) - exp(x)*(5*x + 5*x^2 - 15) - 17*x^2 - log(x^2 - x - 2)*(14*
x + exp(x)*(5*x - 5*x^2 + 10) - 14*x^2 + 28) + 8)/(5*x - log(x^2 - x - 2)*(10*x - 10*x^2 + 20) + log(x^2 - x -
 2)^2*(5*x - 5*x^2 + 10) - 5*x^2 + 10),x)

[Out]

(3*x)/5 + 9/(10*(x - 1/2)) - ((5*x^2*exp(x) - 15*exp(x) - 28*x + 5*x*exp(x) + 12*x^2 + 2)/(5*(2*x - 1)) + (log
(x^2 - x - 2)*(5*exp(x) + 4)*(x - x^2 + 2))/(5*(2*x - 1)))/(log(x^2 - x - 2) - 1) + (exp(x)*(x/2 - x^2/2 + 1))
/(x - 1/2)

________________________________________________________________________________________

sympy [A]  time = 0.47, size = 31, normalized size = 1.15 \begin {gather*} x + \frac {10 - 4 x}{5 \log {\left (x^{2} - x - 2 \right )} - 5} - \frac {e^{x}}{\log {\left (x^{2} - x - 2 \right )} - 1} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((5*x**2-5*x-10)*ln(x**2-x-2)**2+((-5*x**2+5*x+10)*exp(x)-14*x**2+14*x+28)*ln(x**2-x-2)+(5*x**2+5*x-
15)*exp(x)+17*x**2-33*x-8)/((5*x**2-5*x-10)*ln(x**2-x-2)**2+(-10*x**2+10*x+20)*ln(x**2-x-2)+5*x**2-5*x-10),x)

[Out]

x + (10 - 4*x)/(5*log(x**2 - x - 2) - 5) - exp(x)/(log(x**2 - x - 2) - 1)

________________________________________________________________________________________