Chain rule
Function Composition
Before we move on to Chain rule, we discuss function composition. Suppose we have two functions and ; the composition of and , denoted by , is evaluated by plugging the second function in the first function, as follows
Definition
Suppose is differentiable at and is differentiable at . It follows that the composition of and , i.e. is differentiable at and that
Letting and , then
where is evaluated at .
Proof of chain rule
From first principles, is
The answer involves the derivative of the outer function, and of the inner function, . Assuming exists ( is differentiable at ), using the definition of the derivative, we have
as . We introduce a new variable to define this quantity as follows,
where as .
We rearrange to give:
Next, we assume that is differentiable at and define a new variable (similar to above) giving
note that this is a result of the limit definition of and as .
We rearrange to give:
Now, substituting the first rearranged eqn in gives
Comparing the RHS of this eqn and the LHS of the second rearranged eqn, we have that and, of course, . It follows that, as and so as (we will make use of these in the last step of the proof). Using the above expressions for and in the second rearranged eqn, we have
Subsituting these eqns back into one another, we get:
which simplifies to
Using the sum and product limit properties, we finally have
since as .
Applications of the chain rule
The chain rule is therefore used to differentiate composite functions. For example consider and . Then, and its derivative is
Another application of the chain rule is implicit differentiation. For example, compute the slope of the tangent to the unit circle . To differentiate explicitly, we first need to express as follows
whose derivative is
To differentiate implicitly, we differentiate wrt , treating as a function of and as a composite function of so that
Therefore by implicit differentiation we have
This is equivalent to the result obtained with explicit differentiation. It is not always easy (or possible) to express as an explicit function of in order to use explicit differentiation. With implicit differentiation, we can still obtain an expression for the derivative and evaluate slopes at given coordinates .
For another example, if we wanted to compute the derivatives of the curve using implicit differentiation and evaluate the slope at .
Differentiating implicitly we have
or
At , the slope is
Further, implicit differentiation is used for logarithmic differentiation. Keeping in mind that and are inverse functions , consider a function or, equivalently, . Now, we have
which we can show is true by taking the natural logarithm on both sides. Then,
which gives
Solving for , we have
but also, yielding the relationship,
From Eq. (3.17), we can differentiate logarithms with any base: