# Methods for choosing $u$ and $dv$ when integrating by parts?

When doing integration by parts, how do you know which part should be $u$ ?

For example,

For the following: $$\int x^2e^xdx$$

$u = x^2$?

However for: $$\int \sqrt{x}\ln xdx$$

$u = \ln x$?

Is there a rule for which part should be $u$ ? As this is confusing.

• While not exactly part of the question, both integrals may be evaluated without integration by parts:$$f(t)=\int e^{tx}\ dx\implies f''(1)=\int x^2e^x\ dx$$and the second one becomes the first one through the u-substitution $x=e^{2x}$. Commented Feb 1, 2017 at 1:58

My general principle is "Which bit gets nicer to work with when differentiated than when integrated?", which roughly lines up with the LIATE approach:

• The derivative of $$\ln x$$ is $$\frac{1}{x}$$, which will interact nicely with polynomial terms, whereas the integral is some weird rubbish on the order of $$x \ln x$$ which looks terrible.
• The derivatives of the inverse trigonometric functions tend to be rational functions or square roots of rational functions, which again tend to interact with polynomial terms decently, whereas the integrals are horrible things with logarithms in them.
• Algebraic stuff (polynomials) differentiates into other algebraic stuff, and if you're lucky it will get simpler as it goes (but not always).
• Trig and exponential functions tend to sit at about the same complexity no matter how much you differentiate or integrate them. So if you're left picking them as your $$u$$ it probably means you're going to be setting up a recurrence relation of some kind.
• +1 This is the one I would have chosen as the answer. I always prefer "understand what you are trying to do" to "remember some arbitrary-sounding rule". Commented Feb 1, 2017 at 3:08

Forget cute (or weird) acronyms or tables. You are focusing on the wrong thing: differentiation is easy, while integration is hard, so you should ask not what to pick as $u$, but what to pick as $dv$. The answer is: choose as $dv$ the most complicated expression in the integrand that you currently know how to integrate.

For example, you asked about integrating $x^2e^x$. Between $x^2$ and $e^x$ the factor $e^x$ is more sophisticated and you can integrate it, so let $dv = e^x dx$ and then $u = x^2$. You also asked about integrating $\sqrt{x}\ln x$. For students the antiderivative of $\sqrt{x}$ is known but the antiderivative of $\ln x$ is not, so let $dv = \sqrt{x} dx$ and then $u = \ln x$.

When this tip of how to pick $dv$ rather than $u$ was passed on to me, I never had a problem applying integration by parts afterwards. This method requires no memorization of rules, but just experience integrating to recognize one factor as being more complicated than another.

• Well, this sorta works. Except it really only works with a small subset of functions. Complexity is really hard to define in general. Do you integrate the Dilogarithm or the Logarithm of the Gamma function given the choice? I would probably do $\log(\Gamma(x))$ because the derivative of the Dilogarithm is elementary, but your answer doesn't clearly define complexity. I think @ConMan's answer is the evolution of your idea, but I actually like your post a bit more, it is just lacking a lot imo Commented Feb 1, 2017 at 4:47
• @BrevanEllefsen, the OP is asking a question about elementary calculus (reread it), and that is the level at which my reply is pitched. It is a practical answer. A rigorous definition of complexity is far above the level of the original question. When I teach freshman calculus the students grasp what my advice about integration by parts means without anyone ever objecting that I did not offer a careful definition of complexity.
– KCd
Commented Feb 1, 2017 at 6:27

There is an acronym called "LIATE":

Set $u$ to be the first function you see on this list (ordered):

1. logarithm
2. inverse trigonometric function
3. algebraic function
4. trigonometric function
5. exponential

Doesn't always work perfectly, but it's your best bet.

In your first integral, the algebraic function $x^2$ takes precedence.

In the second, the logarithm $\ln x$ takes precedence.

• Okay thanks I understand now (:
– Dan
Commented Feb 1, 2017 at 0:49
• Oh, I use GAHYL. Guess-and-hope-you're-lucky Commented Feb 1, 2017 at 2:00
• @SakethMalyala To tell you the truth, I don't use LIATE myself. In fact I never learned it when I learned about I by P (only came across it much later). When I actually do it, I'm rapidly mentally differentiating one term (constant coefficients don't matter), multiplying it by the other term and "seeing" (mentally) whether that has an easier antiderivative. If this doesn't work, try the other way. Doesn't take more than a few seconds of thought. It improves with experience. Commented Feb 1, 2017 at 3:01
• On the other hand, I never learned things like SAHCAHTOA etc. either. They just stuck without any memory aids. Commented Feb 1, 2017 at 3:02
• The one algorithm (pertaining to I by P) I learned about late, but actually find very useful is the method of tabular integration for repeated integration by parts. I love the way it's presented in the movie "Stand And Deliver", very neat and useful. Of course, we're more likely to rely on Wolfram or other computer algebra systems now, but it's still a nice technique to learn. Commented Feb 1, 2017 at 3:05

I prefer the converse of the more common LIATE approach:

• dv is the first of
• exponential function
• trigonometric function
• algebraic function
• inverse trigonometric function
• logarithm function

I find DETAIL to be easier to remember. The reason this order works well is that integrating the $dv$ tends to not mess things up as much higher up in the list.

In your first integral, you have an algebraic $x^2$ and an exponential $e^x$, so that $dv$ should be the exponential. In your second integral, you have an algebraic $\sqrt x$ and a logarithm, so that $dv$ should be the $\sqrt x$.

I think ILATE rule is more accurate as it works well in most cases.Through this rule in most cases the problem becomes small and quite easy.ILATE stands for Inverse,Logarithmic,Algebraic,Trigonometric and last one exponential..