GL(s,R)

March 22, 2011

The title of this post was already taken

Filed under: Uncategorized — Adam Glesser @ 12:10 am

Tricks of the Trade

(with Professor Glesser)

My all-time favorite differentiation technique is logarithmic differentiation. The implementation is right there in the name: take a logarithm and then differentiate. If you are a pro with your log rules, you will understand why this would be useful.
There are two canonical types of functions where this technique is often used in standard calculus courses. The first is where you have a product and/or quotient of functions, potentially raised to a rational power. For example:
y = \sqrt[3]{\dfrac{(3x-2)^2\sqrt{2x^3+1}}{x^4(x-1)}}
If you apply the natural log to both sides—we choose base e so as to avoid unnecessary constants when differentiating (recall that when u is a function of x that \log_a(u)' = \dfrac{u'}{u \ln(a)}—then we can deconstruct the right hand side using the log rules to get:
\ln(y) = \dfrac{1}{3}\left[2\ln(3x-2) + \frac{1}{2}\ln(2x^3 + 1) - 4\ln(x) - \ln(x-1)\right].
Differentiating both sides is now a snap:
\dfrac{1}{y}\dfrac{dy}{dx} = \dfrac{1}{3}\left[\dfrac{2\cdot 3}{3x-2} + \dfrac{6x^2}{2(2x^3+1)} - \dfrac{4}{x} - \dfrac{1}{x-1}\right].
Multiplying both sides by y—which is the orignal function—gives us the derivative.
The second example is one that gives students no trouble at all, but gives teachers fits. The simplest such example is
y = x^x.
Three-quarters of the class knows that you use the power rule to get
\dfrac{dy}{dx} = x\cdot x^{x-1} = x^x.
The remaining group of students will point out that the power rule only works with a constant exponent, so instead you need to use the exponential rule which gives
\dfrac{dy}{dx} = x^x \ln(x).
Of course, the teacher is squirming right now because they know the exponential rule only works you have a constant base. In fact, neither rule is correct! However, in a way, they are both half-right. Applying the natural log to our orginal equation gives
\ln(y) = \ln(x^x) = x\ln(x).
Differentiating—using the product rule on the right—gives
\dfrac{1}{y}\dfrac{dy}{dx} = x \cdot \dfrac{1}{x} + \ln(x) = 1 + \ln(x).
Multiplying both sides by y now gives
\dfrac{dy}{dx} = y(1 + \ln(x)) = x^x + x^x\ln(x), the sum of the two incorrect answers.
SWEET
Using logarithmic differentiation on functions of the form f(x)^{g(x)}, we can get a general rule which is not particularly well-known:

SPEC (Super Power Exponential Chain) Rule

If y = f(x)^{g(x)} is differentiable, then \dfrac{dy}{dx} = g(x)\cdot f(x)^{g(x) -1} \cdot f'(x) + f(x)^{g(x)}\ln(f(x))\cdot g'(x), i.e., evaluate the derivative using the power and chain rules, then with the exponential and chain rules, and finally add the two incorrect answers together.
In short,
\begin{array}{cl} variable^{constant} & \longrightarrow \text{ Power rule (+ Chain rule)} \\ constant^{variable} & \longrightarrow \text{ Exponential rule (+ Chain rule)}\\ variable^{variable} & \longrightarrow \text{ SPEC rule: Add power rule and exponential rule answers together} \end{array}
An Example
On my midterm, I asked the students to compute the derivative of y = [\sin(x)]^x. The SPEC rule makes this a piece of cake: the power rule gives x \sin(x)^{x-1}\cos(x) and the exponential rule gives \sin(x)^x\ln(\sin(x)). Adding them together gives:
\dfrac{dy}{dx} = x\sin(x)^{x-1}\cos(x) + \sin(x)^x\ln(\sin(x)).
The title
When coming up with this, I thought that the perfect title would be “Two Wrongs Make a Right.” Unfortunately, this was already taken by the authors of the paper of nearly the same name (which has to be the most obvious title for a paper—ever).  They don’t give a name to this rule, so in honor of my anime loving friends, I stick with SPEC rule for the moniker.
What about logarithmic differentiation?
One of the faculty asked me if students will avoid logarithmic differentiation now. For the first type of problem: absolutely not—the SPEC rule doesn’t really apply. For the second type: I hope so—logarithmic differentiation is useful because it simplifies calculations; why not use a trick to simplify it even more?
About these ads

3 Comments »

  1. Beautiful. I think I didn’t understand this when I first learned it, and never learned it again after that. Now… it’s so elegant!

    Comment by Riley — March 23, 2011 @ 9:48 am | Reply

  2. [...] readers derided these tricks or mnemonics surprised me. For instance, my post on a shortcut for logarithmic differentiation ended up being the topic of a Facebook debate on sound pedagogy. One of the participants claimed [...]

    Pingback by In Defense of Shrtcts « GL(s,R) — July 6, 2012 @ 10:41 pm | Reply

  3. [...] Professor Glesser) As I mentioned in this much-maligned post, “my all-time favorite differentiation technique is logarithmic differentiation.” In [...]

    Pingback by The Usual Way Is Just Fine, Man. « GL(s,R) — July 7, 2012 @ 11:29 pm | Reply


RSS feed for comments on this post. TrackBack URI

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

The Rubric Theme. Create a free website or blog at WordPress.com.

Follow

Get every new post delivered to your Inbox.

%d bloggers like this: