Trig Substitution Calculator

Type an integrand with a square root of a quadratic to substitute for x.

Use x. Type powers with ^, and functions with brackets: sin(x), e^(2x), ln(x), sqrt(x).

Try

Result

You entered∫1x2+1 dx\int \frac{1}{\sqrt{x^{2} + 1}}\,dx

∫1x2+1 dx=ln⁡(x+x2+1)+C\displaystyle \int \frac{1}{\sqrt{x^{2} + 1}}\,dx = \ln\left(x + \sqrt{x^{2} + 1}\right) + C
Show the work
  1. Trigonometric substitution

    The integrand contains an a2+x2a^2 + x^2 form, so let x=atan⁡θx = a\tan\theta: then a2+x2=a2sec⁡2θa^2 + x^2 = a^2\sec^2\theta.

    x=tan⁡θdx=sec⁡2θ dθx2+1=sec⁡2θ\begin{gathered} x = \tan\theta \\ dx = \sec^{2} \theta\,d\theta \\ x^{2} + 1 = \sec^{2} \theta \end{gathered}
  2. Rewrite in theta

    Replace every x, the root and dx, then simplify.

    ∫1x2+1 dx=∫1cos⁡θ dθ\int \frac{1}{\sqrt{x^{2} + 1}}\,dx = \int \frac{1}{\cos \theta}\,d\theta
  3. Integral of secant

    The antiderivative of secant is found by multiplying top and bottom by sec x + tan x.

    Using ∫sec⁡x dx=ln⁡∣sec⁡x+tan⁡x∣+C\int \sec x\,dx = \ln\left|\sec x + \tan x\right| + C

    ∫sec⁡θ dθ=ln⁡∣tan⁡θ+sec⁡θ∣\int \sec \theta\,d\theta = \ln\left|\tan \theta + \sec \theta\right|
  4. Back-substitute with the triangle

    Draw a right triangle with opposite side xx, adjacent side 11 and hypotenuse x2+1\sqrt{x^{2} + 1}.

    ln⁡∣tan⁡θ+sec⁡θ∣  →  ln⁡∣x+x2+1∣\ln\left|\tan \theta + \sec \theta\right| \;\to\; \ln\left|x + \sqrt{x^{2} + 1}\right|
  5. Result

    An antiderivative is only defined up to a constant, so the constant of integration CC is added.

    ∫1x2+1 dx=ln⁡(x+x2+1)+C\int \frac{1}{\sqrt{x^{2} + 1}}\,dx = \ln\left(x + \sqrt{x^{2} + 1}\right) + C

Worked examples