Home > Teaching > A Surprising Integral

## A Surprising Integral

I had a fun encounter with an innocuous looking integral.

It all started with a simple directive:  evaluate $\int{cos(\sqrt{x}) \thinspace dx}$.

Integration is often tricky business.  Although there is a large collection of integration techniques, there isn’t really one guaranteed procedure for evaluating an integral.  If you see what the answer is, you write it down; if you don’t, you try a technique in the hope that it makes you see what the answer is.  If that technique doesn’t work, you try another.

This particular problem is interesting in that it highlights a strange phenomenon that occasionally pops up in problem-solving:  sometimes making a problem look more complicated actually makes it easier to solve.

Let $u = \sqrt{x}$.  Thus, $du = \frac{1}{2\sqrt{x}} dx$, and so $dx = 2 \sqrt{x} du$.  But since $u = \sqrt{x}$, we have $dx = 2 \thinspace u \thinspace du$.

This gives us $\int{cos(\sqrt{x}) \thinspace dx} = \int{2 \thinspace u \thinspace cos(u) \thinspace du}$.

This actually looks a bit more difficult than the original problem, but now we can easily integrate this using Integration by Parts!

After applying this technique, we’ll get $\int{2 \thinspace u \thinspace cos(u) \thinspace du} = 2 \thinspace u \thinspace cos(u) + sin(u) + C$.  And so, after un-substituting, we get

$\int{cos(\sqrt{x})} = 2\sqrt{x} \thinspace sin(\sqrt{x}) + 2 \thinspace cos(\sqrt{x}) + C.$

I was surprised that this technique worked, so I actually differentiated to make sure I got the correct answer.  You can take my word for it, or you can verify with WolframAlpha.

One of the best parts of being a teacher is learning (or re-learning) something new every day!