Optimal. Leaf size=27 \[ \log \left (e^{-2 e^{-\frac {3-x}{e^2-x}}+2 x}\right ) \]
________________________________________________________________________________________
Rubi [A] time = 1.20, antiderivative size = 28, normalized size of antiderivative = 1.04, number of steps used = 8, number of rules used = 7, integrand size = 76, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.092, Rules used = {27, 6741, 6688, 12, 6742, 2230, 2209} \begin {gather*} 2 x-2 e^{-\frac {3-e^2}{e^2-x}-1} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 12
Rule 27
Rule 2209
Rule 2230
Rule 6688
Rule 6741
Rule 6742
Rubi steps
\begin {gather*} \begin {aligned} \text {integral} &=\int \frac {e^{-\frac {3-x}{e^2-x}} \left (6-2 e^2+e^{\frac {3-x}{e^2-x}} \left (2 e^4-4 e^2 x+2 x^2\right )\right )}{\left (-e^2+x\right )^2} \, dx\\ &=\int \frac {e^{-\frac {3-x}{e^2-x}} \left (6 \left (1-\frac {e^2}{3}\right )+e^{\frac {3-x}{e^2-x}} \left (2 e^4-4 e^2 x+2 x^2\right )\right )}{\left (e^2-x\right )^2} \, dx\\ &=\int \frac {2 \left (e^4+e^{\frac {-3+x}{e^2-x}} \left (3-e^2\right )-2 e^2 x+x^2\right )}{\left (e^2-x\right )^2} \, dx\\ &=2 \int \frac {e^4+e^{\frac {-3+x}{e^2-x}} \left (3-e^2\right )-2 e^2 x+x^2}{\left (e^2-x\right )^2} \, dx\\ &=2 \int \left (1+\frac {e^{\frac {-3+x}{e^2-x}} \left (3-e^2\right )}{\left (e^2-x\right )^2}\right ) \, dx\\ &=2 x+\left (2 \left (3-e^2\right )\right ) \int \frac {e^{\frac {-3+x}{e^2-x}}}{\left (e^2-x\right )^2} \, dx\\ &=2 x+\left (2 \left (3-e^2\right )\right ) \int \frac {e^{-1-\frac {-3+e^2}{-e^2+x}}}{\left (e^2-x\right )^2} \, dx\\ &=-2 e^{-1-\frac {3-e^2}{e^2-x}}+2 x\\ \end {aligned} \end {gather*}
________________________________________________________________________________________
Mathematica [A] time = 0.38, size = 21, normalized size = 0.78 \begin {gather*} -2 e^{\frac {-3+x}{e^2-x}}+2 x \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.90, size = 20, normalized size = 0.74 \begin {gather*} 2 \, x - 2 \, e^{\left (-\frac {x - 3}{x - e^{2}}\right )} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [B] time = 8.87, size = 81, normalized size = 3.00 \begin {gather*} -2 \, {\left (\frac {2 \, e^{2} - 3}{{\left (e^{2} - 3\right )}^{2}} - \frac {e^{2}}{{\left (e^{2} - 3\right )}^{2}}\right )} e^{\left (\frac {x - 2 \, e^{2} + 3}{x - e^{2}}\right )} + 6 \, {\left (\frac {e^{2}}{{\left (e^{2} - 3\right )}^{2}} - \frac {3}{{\left (e^{2} - 3\right )}^{2}}\right )} e^{\left (-\frac {x - 3}{x - e^{2}}\right )} + 2 \, x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.16, size = 20, normalized size = 0.74
method | result | size |
risch | \(2 x -2 \,{\mathrm e}^{\frac {x -3}{{\mathrm e}^{2}-x}}\) | \(20\) |
norman | \(\frac {\left (2 \,{\mathrm e}^{4} {\mathrm e}^{\frac {3-x}{{\mathrm e}^{2}-x}}+2 x -2 x^{2} {\mathrm e}^{\frac {3-x}{{\mathrm e}^{2}-x}}-2 \,{\mathrm e}^{2}\right ) {\mathrm e}^{-\frac {3-x}{{\mathrm e}^{2}-x}}}{{\mathrm e}^{2}-x}\) | \(76\) |
derivativedivides | \(-\left ({\mathrm e}^{2}-3\right ) \left (-\frac {18 \left (x -{\mathrm e}^{2}\right )}{\left ({\mathrm e}^{4}-6 \,{\mathrm e}^{2}+9\right ) \left ({\mathrm e}^{2}-3\right )}+\frac {12 \,{\mathrm e}^{2} \left (x -{\mathrm e}^{2}\right )}{\left ({\mathrm e}^{4}-6 \,{\mathrm e}^{2}+9\right ) \left ({\mathrm e}^{2}-3\right )}-\frac {2 \,{\mathrm e}^{4} \left (x -{\mathrm e}^{2}\right )}{\left ({\mathrm e}^{4}-6 \,{\mathrm e}^{2}+9\right ) \left ({\mathrm e}^{2}-3\right )}-\frac {6 \,{\mathrm e}^{-1-\frac {{\mathrm e}^{2}-3}{x -{\mathrm e}^{2}}}}{{\mathrm e}^{4}-6 \,{\mathrm e}^{2}+9}+\frac {2 \,{\mathrm e}^{2} {\mathrm e}^{-1-\frac {{\mathrm e}^{2}-3}{x -{\mathrm e}^{2}}}}{{\mathrm e}^{4}-6 \,{\mathrm e}^{2}+9}\right )\) | \(158\) |
default | \(-\left ({\mathrm e}^{2}-3\right ) \left (-\frac {18 \left (x -{\mathrm e}^{2}\right )}{\left ({\mathrm e}^{4}-6 \,{\mathrm e}^{2}+9\right ) \left ({\mathrm e}^{2}-3\right )}+\frac {12 \,{\mathrm e}^{2} \left (x -{\mathrm e}^{2}\right )}{\left ({\mathrm e}^{4}-6 \,{\mathrm e}^{2}+9\right ) \left ({\mathrm e}^{2}-3\right )}-\frac {2 \,{\mathrm e}^{4} \left (x -{\mathrm e}^{2}\right )}{\left ({\mathrm e}^{4}-6 \,{\mathrm e}^{2}+9\right ) \left ({\mathrm e}^{2}-3\right )}-\frac {6 \,{\mathrm e}^{-1-\frac {{\mathrm e}^{2}-3}{x -{\mathrm e}^{2}}}}{{\mathrm e}^{4}-6 \,{\mathrm e}^{2}+9}+\frac {2 \,{\mathrm e}^{2} {\mathrm e}^{-1-\frac {{\mathrm e}^{2}-3}{x -{\mathrm e}^{2}}}}{{\mathrm e}^{4}-6 \,{\mathrm e}^{2}+9}\right )\) | \(158\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [B] time = 0.59, size = 120, normalized size = 4.44 \begin {gather*} 4 \, {\left (\frac {e^{2}}{x - e^{2}} - \log \left (x - e^{2}\right )\right )} e^{2} + 4 \, e^{2} \log \left (x - e^{2}\right ) + 2 \, x - \frac {4 \, e^{4}}{x - e^{2}} - \frac {2 \, e^{\left (-\frac {e^{2}}{x - e^{2}} + \frac {3}{x - e^{2}} + 1\right )}}{e^{2} - 3} + \frac {6 \, e^{\left (-\frac {e^{2}}{x - e^{2}} + \frac {3}{x - e^{2}}\right )}}{e^{3} - 3 \, e} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 2.53, size = 29, normalized size = 1.07 \begin {gather*} 2\,x-2\,{\mathrm {e}}^{-\frac {x}{x-{\mathrm {e}}^2}}\,{\mathrm {e}}^{\frac {3}{x-{\mathrm {e}}^2}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [A] time = 0.22, size = 14, normalized size = 0.52 \begin {gather*} 2 x - 2 e^{- \frac {3 - x}{- x + e^{2}}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________