Calculus · real student question

Find the indefinite integral of x e^(-x^2) with respect to x.

Question

Evaluate

xex2dx\int x\,e^{-x^{2}}\,dx

Step-by-step solution

  1. Notice why this one is doable at all. The closely related ex2dx\int e^{-x^2}dx has no elementary antiderivative. The extra factor of xx changes everything: it is (up to a constant) the derivative of the exponent, so the integral is a pure substitution. Recognising that distinction is the entire insight.

  2. Choose the substitution. Let

    u=x2du=2xdxxdx=12duu=-x^{2}\quad\Longrightarrow\quad du=-2x\,dx\quad\Longrightarrow\quad x\,dx=-\tfrac12\,du

  3. Rewrite the integral entirely in uu. The xdxx\,dx in the original is replaced wholesale, leaving nothing in xx behind:

    xex2dx=eu(12du)=12eudu\int x\,e^{-x^{2}}\,dx=\int e^{u}\left(-\tfrac12\,du\right)=-\tfrac12\int e^{u}\,du

  4. Integrate and substitute back.

    12eu+C=12ex2+C-\tfrac12 e^{u}+C=-\tfrac12 e^{-x^{2}}+C

  5. Differentiate to check. By the chain rule,

    ddx(12ex2)=12ex2(2x)=xex2\frac{d}{dx}\left(-\tfrac12 e^{-x^{2}}\right)=-\tfrac12 e^{-x^{2}}\cdot(-2x)=x\,e^{-x^{2}}

    which is the original integrand ✓. A numerical spot check at x=1.3x=1.3: the symmetric difference quotient of 12ex2-\tfrac12 e^{-x^2} gives 0.23987540.2398754, and xex2=0.2398754x e^{-x^2}=0.2398754 ✓.

  6. Note what a definite version would give. With limits aa to bb the answer is 12(ea2eb2)\tfrac12\left(e^{-a^2}-e^{-b^2}\right); in particular 0xex2dx=12\int_0^{\infty}x e^{-x^2}dx=\tfrac12.

Answer

xex2dx=12ex2+C\int x\,e^{-x^{2}}\,dx=-\frac{1}{2}e^{-x^{2}}+C

Need to solve a different problem like this? Open the solver →