3.76.2 \(\int \frac {e^{-\log ^2(x^2)} (-x+e^{\log ^2(x^2)} (3 x-x^2+e^{21+x} (-3 x+x^2))+(-12+4 x) \log (-3+x) \log (x^2))}{-3 x+x^2} \, dx\)

Optimal. Leaf size=25 \[ e^{21+x}-x-e^{-\log ^2\left (x^2\right )} \log (-3+x) \]

________________________________________________________________________________________

Rubi [B]  time = 0.91, antiderivative size = 56, normalized size of antiderivative = 2.24, number of steps used = 5, number of rules used = 4, integrand size = 69, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.058, Rules used = {1593, 6742, 2194, 2288} \begin {gather*} -\frac {e^{-\log ^2\left (x^2\right )} \left (3 \log (x-3) \log \left (x^2\right )-x \log (x-3) \log \left (x^2\right )\right )}{(3-x) \log \left (x^2\right )}-x+e^{x+21} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(-x + E^Log[x^2]^2*(3*x - x^2 + E^(21 + x)*(-3*x + x^2)) + (-12 + 4*x)*Log[-3 + x]*Log[x^2])/(E^Log[x^2]^2
*(-3*x + x^2)),x]

[Out]

E^(21 + x) - x - (3*Log[-3 + x]*Log[x^2] - x*Log[-3 + x]*Log[x^2])/(E^Log[x^2]^2*(3 - x)*Log[x^2])

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 2194

Int[((F_)^((c_.)*((a_.) + (b_.)*(x_))))^(n_.), x_Symbol] :> Simp[(F^(c*(a + b*x)))^n/(b*c*n*Log[F]), x] /; Fre
eQ[{F, a, b, c, n}, x]

Rule 2288

Int[(y_.)*(F_)^(u_)*((v_) + (w_)), x_Symbol] :> With[{z = (v*y)/(Log[F]*D[u, x])}, Simp[F^u*z, x] /; EqQ[D[z,
x], w*y]] /; FreeQ[F, x]

Rule 6742

Int[u_, x_Symbol] :> With[{v = ExpandIntegrand[u, x]}, Int[v, x] /; SumQ[v]]

Rubi steps

\begin {gather*} \begin {aligned} \text {integral} &=\int \frac {e^{-\log ^2\left (x^2\right )} \left (-x+e^{\log ^2\left (x^2\right )} \left (3 x-x^2+e^{21+x} \left (-3 x+x^2\right )\right )+(-12+4 x) \log (-3+x) \log \left (x^2\right )\right )}{(-3+x) x} \, dx\\ &=\int \left (-1+e^{21+x}+\frac {e^{-\log ^2\left (x^2\right )} \left (-x-12 \log (-3+x) \log \left (x^2\right )+4 x \log (-3+x) \log \left (x^2\right )\right )}{(-3+x) x}\right ) \, dx\\ &=-x+\int e^{21+x} \, dx+\int \frac {e^{-\log ^2\left (x^2\right )} \left (-x-12 \log (-3+x) \log \left (x^2\right )+4 x \log (-3+x) \log \left (x^2\right )\right )}{(-3+x) x} \, dx\\ &=e^{21+x}-x-\frac {e^{-\log ^2\left (x^2\right )} \left (3 \log (-3+x) \log \left (x^2\right )-x \log (-3+x) \log \left (x^2\right )\right )}{(3-x) \log \left (x^2\right )}\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

Mathematica [A]  time = 0.76, size = 25, normalized size = 1.00 \begin {gather*} e^{21+x}-x-e^{-\log ^2\left (x^2\right )} \log (-3+x) \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(-x + E^Log[x^2]^2*(3*x - x^2 + E^(21 + x)*(-3*x + x^2)) + (-12 + 4*x)*Log[-3 + x]*Log[x^2])/(E^Log[
x^2]^2*(-3*x + x^2)),x]

[Out]

E^(21 + x) - x - Log[-3 + x]/E^Log[x^2]^2

________________________________________________________________________________________

fricas [A]  time = 0.87, size = 32, normalized size = 1.28 \begin {gather*} -{\left ({\left (x - e^{\left (x + 21\right )}\right )} e^{\left (\log \left (x^{2}\right )^{2}\right )} + \log \left (x - 3\right )\right )} e^{\left (-\log \left (x^{2}\right )^{2}\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((((x^2-3*x)*exp(x+21)-x^2+3*x)*exp(log(x^2)^2)+(4*x-12)*log(x-3)*log(x^2)-x)/(x^2-3*x)/exp(log(x^2)^
2),x, algorithm="fricas")

[Out]

-((x - e^(x + 21))*e^(log(x^2)^2) + log(x - 3))*e^(-log(x^2)^2)

________________________________________________________________________________________

giac [A]  time = 0.22, size = 23, normalized size = 0.92 \begin {gather*} -e^{\left (-\log \left (x^{2}\right )^{2}\right )} \log \left (x - 3\right ) - x + e^{\left (x + 21\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((((x^2-3*x)*exp(x+21)-x^2+3*x)*exp(log(x^2)^2)+(4*x-12)*log(x-3)*log(x^2)-x)/(x^2-3*x)/exp(log(x^2)^
2),x, algorithm="giac")

[Out]

-e^(-log(x^2)^2)*log(x - 3) - x + e^(x + 21)

________________________________________________________________________________________

maple [C]  time = 0.24, size = 74, normalized size = 2.96




method result size



risch \({\mathrm e}^{x +21}-x -\ln \left (x -3\right ) {\mathrm e}^{-\frac {\left (-i \pi \mathrm {csgn}\left (i x \right )^{2} \mathrm {csgn}\left (i x^{2}\right )+2 i \pi \,\mathrm {csgn}\left (i x \right ) \mathrm {csgn}\left (i x^{2}\right )^{2}-i \pi \mathrm {csgn}\left (i x^{2}\right )^{3}+4 \ln \relax (x )\right )^{2}}{4}}\) \(74\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

int((((x^2-3*x)*exp(x+21)-x^2+3*x)*exp(ln(x^2)^2)+(4*x-12)*ln(x-3)*ln(x^2)-x)/(x^2-3*x)/exp(ln(x^2)^2),x,metho
d=_RETURNVERBOSE)

[Out]

exp(x+21)-x-ln(x-3)*exp(-1/4*(-I*Pi*csgn(I*x)^2*csgn(I*x^2)+2*I*Pi*csgn(I*x)*csgn(I*x^2)^2-I*Pi*csgn(I*x^2)^3+
4*ln(x))^2)

________________________________________________________________________________________

maxima [A]  time = 0.40, size = 21, normalized size = 0.84 \begin {gather*} -e^{\left (-4 \, \log \relax (x)^{2}\right )} \log \left (x - 3\right ) - x + e^{\left (x + 21\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((((x^2-3*x)*exp(x+21)-x^2+3*x)*exp(log(x^2)^2)+(4*x-12)*log(x-3)*log(x^2)-x)/(x^2-3*x)/exp(log(x^2)^
2),x, algorithm="maxima")

[Out]

-e^(-4*log(x)^2)*log(x - 3) - x + e^(x + 21)

________________________________________________________________________________________

mupad [B]  time = 4.70, size = 23, normalized size = 0.92 \begin {gather*} {\mathrm {e}}^{x+21}-x-\ln \left (x-3\right )\,{\mathrm {e}}^{-{\ln \left (x^2\right )}^2} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((exp(-log(x^2)^2)*(x + exp(log(x^2)^2)*(exp(x + 21)*(3*x - x^2) - 3*x + x^2) - log(x - 3)*log(x^2)*(4*x -
12)))/(3*x - x^2),x)

[Out]

exp(x + 21) - x - log(x - 3)*exp(-log(x^2)^2)

________________________________________________________________________________________

sympy [A]  time = 2.09, size = 19, normalized size = 0.76 \begin {gather*} - x + e^{x + 21} - e^{- \log {\left (x^{2} \right )}^{2}} \log {\left (x - 3 \right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((((x**2-3*x)*exp(x+21)-x**2+3*x)*exp(ln(x**2)**2)+(4*x-12)*ln(x-3)*ln(x**2)-x)/(x**2-3*x)/exp(ln(x**
2)**2),x)

[Out]

-x + exp(x + 21) - exp(-log(x**2)**2)*log(x - 3)

________________________________________________________________________________________