Why the Inner Derivative Matters
Exponential functions are straightforward to differentiate when their input is \(x\). For an exponent that is itself a function of \(x\), the chain rule adds a factor: differentiating \(e^{g(x)}\) gives \(e^{g(x)}g'(x)\). This tutorial uses that relationship in reverse to recognize and evaluate a family of integrals.
The important question is not just whether an integrand contains an exponential. It is whether it also contains the derivative of the expression in the exponent. When those factors match, the integral can be evaluated directly. When the match is scaled by a constant, that constant must be accounted for in the answer.
The Basic Exponential Patterns
Let \(g\) be differentiable on an interval. Since the derivative of \(e^u\) with respect to \(u\) is \(e^u\), the chain rule gives \(\frac{d}{dx}e^{g(x)}=e^{g(x)}g'(x)\). Therefore, when the integrand contains both \(e^{g(x)}\) and \(g'(x)\), the integrand is exactly the derivative of \(e^{g(x)}\).
For a general positive base \(a\), the derivative of \(a^u\) with respect to \(u\) is \((\ln a)a^u\). Here \(\ln a\) is the natural logarithm of \(a\). Applying the chain rule introduces both the factor \(\ln a\) and the factor \(g'(x)\).
The conditions on \(a\) matter. A positive base is needed for the real-valued exponential function \(a^u\) to be defined for every real exponent \(u\). The case \(a=1\) is excluded from the formula because \(\ln 1=0\); in that case \(1^{g(x)}=1\), so \(\int 1^{g(x)}g'(x)\,dx=g(x)+C\).
Deriving the Rules
The rules follow directly from differentiation. Recall that if a function \(F\) satisfies \(F'(x)=f(x)\) throughout an interval, then \(F\) is an antiderivative of \(f\) there. Thus, to justify an indefinite integral formula, it is enough to differentiate the proposed antiderivative and recover the integrand.
The chain rule gives \(\frac{d}{dx}e^{g(x)}=e^{g(x)}g'(x)\). This is the integrand in the first rule, so \(e^{g(x)}\) is an antiderivative.
Adding a constant does not change a derivative. Therefore all the antiderivatives in this pattern are \(e^{g(x)}+C\).
The chain rule gives \(\frac{d}{dx}a^{g(x)}=(\ln a)a^{g(x)}g'(x)\). Dividing by the nonzero constant \(\ln a\) leaves derivative \(a^{g(x)}g'(x)\).
This argument also explains why the formulas work: they are not separate tricks for particular exponents. They are consequences of the chain rule, with the exponential function's derivative supplying the outer factor and \(g'(x)\) supplying the inner factor.
Worked Example: A Polynomial Exponent with Base \(e\)
Worked Example: A Polynomial Exponent with Base \(e\)
Evaluate \(\int 6x e^{3x^2-4}\,dx\).
First identify the exponent as the inner function: \(g(x)=3x^2-4\).
Differentiate it: \(g'(x)=6x\).
The integrand contains exactly \(g'(x)e^{g(x)}\), because \(6x e^{3x^2-4}=g'(x)e^{g(x)}\).
Apply the base-\(e\) rule: \(\int 6x e^{3x^2-4}\,dx=e^{3x^2-4}+C\).
Check by differentiation: \(\frac{d}{dx}\left(e^{3x^2-4}+C\right)=e^{3x^2-4}\cdot\frac{d}{dx}(3x^2-4)=e^{3x^2-4}\cdot6x=6x e^{3x^2-4}\).
The derivative matches the original integrand.
When the Derivative Match Has a Constant Scale
The factor beside the exponential does not have to equal \(g'(x)\) exactly. It may be a constant multiple of it. If the integrand is \(k e^{g(x)}g'(x)\), where \(k\) is a constant, then its antiderivative is \(k e^{g(x)}+C\), because the constant can be taken outside the integral. Equivalently, if the integrand contains \(e^{g(x)}g'(x)\) divided by a constant, that division remains in the answer.
For base \(a\), the same scaling principle applies, but the derivative of the outer exponential contributes the additional factor \(\ln a\). In particular, if the integrand is \(k a^{g(x)}g'(x)\), an antiderivative is \(\frac{k}{\ln a}a^{g(x)}+C\), provided \(a>0\) and \(a\ne1\).
Worked Example: The Inner Derivative Is Scaled
Worked Example: The Inner Derivative Is Scaled
Evaluate \(\int x e^{x^2+1}\,dx\).
Set \(g(x)=x^2+1\). Then \(g'(x)=2x\), but the integrand contains \(x\), not \(2x\).
Express the factor \(x\) using the derivative: \(x=\frac{1}{2}(2x)=\frac{1}{2}g'(x)\).
Rewrite the integral: \(\int x e^{x^2+1}\,dx=\frac{1}{2}\int e^{g(x)}g'(x)\,dx\).
Use the basic rule and substitute back: \(\frac{1}{2}\int e^{g(x)}g'(x)\,dx=\frac{1}{2}e^{g(x)}+C=\frac{1}{2}e^{x^2+1}+C\).
Check by differentiation: \(\frac{d}{dx}\left(\frac{1}{2}e^{x^2+1}+C\right)=\frac{1}{2}e^{x^2+1}(2x)=x e^{x^2+1}\).
The factor \(\frac{1}{2}\) in the answer is necessary to recover the original integrand.
Worked Example: An Exponential with Another Positive Base
Worked Example: An Exponential with Another Positive Base
Evaluate \(\int 5^{2x-3}\,dx\).
Let \(g(x)=2x-3\). Its derivative is \(g'(x)=2\). The integral as written does not include that factor of \(2\), so first supply it and compensate outside: \(\int 5^{2x-3}\,dx=\frac{1}{2}\int 5^{2x-3}\cdot2\,dx\).
Apply the rule for base \(a\), with \(a=5\): \(\frac{1}{2}\int 5^{g(x)}g'(x)\,dx=\frac{1}{2}\cdot\frac{5^{g(x)}}{\ln 5}+C\).
Substitute the inner function: \(\int 5^{2x-3}\,dx=\frac{5^{2x-3}}{2\ln 5}+C\).
Check by differentiation: \(\frac{d}{dx}\left(\frac{5^{2x-3}}{2\ln 5}+C\right)=\frac{1}{2\ln 5}\cdot(\ln 5)5^{2x-3}\cdot2=5^{2x-3}\).
Both the factor \(2\) from the inner derivative and the factor \(\ln 5\) from differentiating the outer exponential are accounted for.
Worked Example: A Scaled Derivative with Base \(a\)
Worked Example: A Scaled Derivative with Base \(a\)
Evaluate \(\int 3x\,2^{x^2+4}\,dx\).
Choose \(g(x)=x^2+4\), so \(g'(x)=2x\). The factor \(3x\) is \(\frac{3}{2}g'(x)\), since \(\frac{3}{2}(2x)=3x\).
Rewrite the integral to make the derivative match explicit: \(\int 3x\,2^{x^2+4}\,dx=\frac{3}{2}\int 2^{g(x)}g'(x)\,dx\).
Use the rule with \(a=2\): \(\frac{3}{2}\int 2^{g(x)}g'(x)\,dx=\frac{3}{2}\cdot\frac{2^{g(x)}}{\ln 2}+C\).
Therefore, \(\int 3x\,2^{x^2+4}\,dx=\frac{3}{2\ln 2}2^{x^2+4}+C\).
Check by differentiation: \(\frac{d}{dx}\left(\frac{3}{2\ln 2}2^{x^2+4}+C\right)=\frac{3}{2\ln 2}(\ln 2)2^{x^2+4}(2x)=3x\,2^{x^2+4}\).
The result differentiates to the original integrand.
A Common Mistake: Losing a Constant Factor
A frequent error is to recognize the correct inner function but overlook the difference between its derivative and the factor actually present. For example, consider \(\int x e^{x^2}\,dx\). A wrong calculation might say, “The exponent is \(x^2\), so the answer is \(e^{x^2}+C\).” That answer is incorrect: the derivative of \(x^2\) is \(2x\), not \(x\).
Indeed, differentiating the proposed wrong answer gives \(\frac{d}{dx}(e^{x^2}+C)=2x e^{x^2}\), which is twice the required integrand. The correction is to write \(x=\frac12(2x)\), giving \(\int x e^{x^2}\,dx=\frac12 e^{x^2}+C\). Its derivative is \(\frac12 e^{x^2}(2x)=x e^{x^2}\), as required.
For a base other than \(e\), there is a second factor to track. Omitting \(\ln a\) is an error even when the inner derivative matches exactly. Differentiating \(a^{g(x)}\) produces \((\ln a)a^{g(x)}g'(x)\), so the antiderivative formula must divide by \(\ln a\).
When the Pattern Is Not Present
These rules apply when the needed derivative factor is present, up to a constant multiple. For example, \(\int (2x+1)e^{x^2+x}\,dx\) matches because the derivative of \(x^2+x\) is \(2x+1\). By contrast, \(\int e^{x^2}\,dx\) does not match this pattern: the derivative of the exponent is \(2x\), and the integrand has no factor \(2x\).
This does not by itself prove that an integral without a visible match has no antiderivative. It means only that the direct exponential-composition rule cannot be applied as written. Do not insert a variable factor that is not present. First check the actual derivative of the exponent, then decide whether the integrand contains that derivative, perhaps multiplied by a constant.
Summary
The chain rule gives a direct way to integrate exponential functions of inner expressions when the integrand supplies the derivative of the exponent. For base \(e\), the matching factors integrate to \(e^{g(x)}+C\). For a positive base \(a\ne1\), the corresponding antiderivative is \(a^{g(x)}/\ln a+C\). If the factor in the integrand is a constant multiple of \(g'(x)\), retain that constant multiple in the answer. Differentiation provides a direct check of every result.
Check Your Understanding
For each integral, identify the inner function and its derivative before choosing a rule. Then check your result by differentiation.
- Evaluate \(\int 4x e^{2x^2-1}\,dx\).
- Evaluate \(\int (3x^2) e^{x^3+2}\,dx\).
- Evaluate \(\int 2^{3x+1}\,dx\), accounting for the derivative of the inner function and the factor \(\ln 2\).
- Evaluate \(\int 8x\,7^{4x^2}\,dx\), and state which constant factors appear in the antiderivative.
- Does \(\int e^{x^2+1}\,dx\) match the direct rule in this tutorial as written? Explain by comparing the derivative of the exponent with the factor multiplying the exponential.