(D8) Implicit Differentiation#
By the end of the lesson you will be able to:
compute derivatives of implicitly defined functions.
find the slope of the tangent line to an implicit curve.
Lecture Videos#
Implicitly Defined Functions#
For this discussion, we’re going to consider equations involving two variables (normally \(x\) and \(y\)).
There are two ways such an equation can be used to define \(y\) as a function of \(x\): explicit and implicit.
Variable y: This is where our 2-variable equation has \(y\) explicitly written as a function of \(x\).
Here, we see this equation is literally written in the form \(y=\cdots\)
\(y\) is written as a function in terms of \(x\) and we know what the formula for the function is.
Variable y: This is where our 2-variable equation is not telling us an explicit formula for what the \(y\) function is. So we still view \(y\) as a function of \(x\), we just don’t know what the formula is.
This equation is not written in the form \(y=\cdots\).
We could potentially solve for \(y\), but that is not what is given to us here. The \(x\) and \(y\) terms are all mixed together and we do not immediately know the formula for the \(y\) function.
Implicit Differentiation#
So the question becomes, how do we calculate the derivative for a function we do not have the formula for? The answer is implicit differentiation. Starting with our 2-variable equation, we:
Apply the derivative to the equation.
Differentiate each term (which gives us some \(y'\) terms).
Move all terms containing \(y'\) to the left side of the equation.
Factor and solve for \(y'\).
How we do the differentiation in our work, depends on the variables present:
If a term contains only \(x\)’s we:
Differentiate like usual. That’s it!
This is because we are viewing \(x\) only as a variable.
If a term contains only \(y\)’s we:
Differentiate like usual.
Multiply the result by \(y'\)
The reason why we do this extra step of multiplying by \(y'\) is because we are viewing \(y\) both as a variable in our equation and as a function of \(x\).
So when we see something like \(y^3\), we really have a composition of two functions which requires chain rule (derivative of the outer function times the derivative of the inner function).
The outer function is \((\cdot)^3\) which we can differentiate with our usual power rule
The inner function is \(y\)
If a term contains both \(x\) and \(y\) terms then we might need to use some of our more advanced derivative rules:
Product Rule
Quotient Rule
Chain Rule
Example 1#
Consider the following equation: \(x^2+y^2=4\)
Use implicit differentiation to compute \(\dfrac{dy}{dx}\).
Find the slope of the graph at the point \((1,\sqrt{3})\).
Click through the tabs to see the steps of our solution.
Note that since we want to calculate the derivative of \(y\) with respect to \(x\), this means, we are treating:
each \(x\) as a variable term only.
each \(y\) as both a variable and an implicit function of \(x\).
The first step is to apply the derivative to each term on both sides of the equation:
Here, we are using the prime notation to indicate differentiation with respect to \(x\). This means, in our equation, we are treating:
each \(x\) as a variable term only.
each \(y\) as both a variable and an implicit function of \(x\).
Next, differentiate each of the terms in the brackets:
Remember that when we calculate:
\(\big[x^2\big]'=2x\quad\) we only differentiate like usual, since this term only involves an \(x\).
\(\big[y^2\big]'= 2y\cdot y'\quad\) we differentiate like usual but then also multiply the result by \(y'\) since \(y\) is being treated as both a variable and a function.
At this point we’re done differentiating, so the only thing we need to do is solve for the derivative, \(y'\). We start this process by moving terms around:
Left Side: Move all terms with \(y'\) to the left.
Right Side: Move all terms without \(y'\) to the right.
Finally, we factor out \(y'\), and then divide both sides by the leftover pieces.
There is our desired derivative. Notice that since we used implicit differentiation, this version of the derivative involves both \(x\) and \(y\) terms - and this is okay.
Note that we can simplify this answer down a little bit by canceling the \(2\)’s to get:
We’re also interested in finding the slope \((m)\) of the tangent line at the point \((1,\sqrt{3})\). To do this, we evaluate the derivative with the \(x\) and \(y\) coordinates of our point.
And so we find that the slope of the tangent line at point \((1,\sqrt{3})\) is given by \(m=-\dfrac{\sqrt{3}}{3}\).
Example 2#
Consider the equation: \(x^2y^6=1\).
Use implicit differentiation to calculate \(\dfrac{dy}{dx}\).
Click through the tabs to see the steps of our solution.
Note that since we want to calculate the derivative of \(y\) with respect to \(x\), this means, we are treating:
each \(x\) as a variable term only.
each \(y\) as both a variable and an implicit function of \(x\).
The first step is to apply the derivative to both sides of the equation:
Here, we are using the prime notation to indicate differentiation with respect to \(x\). This means, in our equation, we are treating:
each \(x\) as a variable term only.
each \(y\) as both a variable and an implicit function of \(x\).
Next, we actually differentiate each of the terms.
Right Side: On the right we have a term involving only a constant. We know that the derivative of a constant all by itself is \(0\).
Left Side: On the left we have a term involving both \(x\) and \(y\), so we need to use one of our more advanced differentiation rules. In this case the product rule, since we have a product: \(x^2\) times \(y^6\).
Applying the product rule we get:
And then from here we continue differentiating each of the remaining terms.
Remember that when we calculate:
\(\big[x^2\big]'=2x\quad\) we only differentiate like usual, since this term only involves an \(x\).
\(\big[y^6\big]'= 6y^5\cdot y'\quad\) we differentiate like usual but then also multiply the result by \(y'\) since \(y\) is being treated as both a variable and a function.
At this point we’re done differentiating, so the only thing we need to do is solve for the derivative, \(y'\). Let’s rewrite our equation first, just to make it a little easier to read.
Now we’re ready to start moving terms around:
Left Side: Move all terms with \(y'\) to the left.
Right Side: Move all terms without \(y'\) to the right.
Finally, we factor out \(y'\), and then divide both sides by the leftover pieces.
There is our desired derivative. Notice that since we used implicit differentiation, this version of the derivative involves both \(x\) and \(y\) terms - and this is okay.
Actually, if we needed to, we could simplify this derivative down a little bit:
Example 3#
Consider the following equation: \(x^2y+xy^3-2x=4\)
Use implicit differentiation to compute \(y'\).
Find the equation of the tangent line at the point \((3,1)\).
Click through the tabs to see the steps of our solution.
Note that since we want to calculate the derivative of \(y\) with respect to \(x\), this means, we are treating:
each \(x\) as a variable term only.
each \(y\) as both a variable and an implicit function of \(x\).
The first step is to apply the derivative to each term on both sides of the equation:
Here, we are using the prime notation to indicate differentiation with respect to \(x\). This means, in our equation, we are treating:
each \(x\) as a variable term only.
each \(y\) as both a variable and an implicit function of \(x\).
Next, we actually differentiate each of the terms.
Left Side: On the left side of this equation we have two parts that are a product of \(x\) and \(y\) terms. This means we are going to use product rule twice:
We need to keep differentiating.
But now we’re at a point where each of the remaining derivatives consist of either only an \(x\) term or only a \(y\) term and can be done without our more advanced derivative rules.
Remember that when we calculate:
\(\big[x^2\big]'=2x\quad\) we only differentiate like usual, since this term only involves an \(x\).
\(\big[y^3\big]'= 3y^2\cdot y'\quad\) we differentiate like usual but then also multiply the result by \(y'\) since \(y\) is being treated as both a variable and a function.
We’re now done differentiating, so the only thing we need to do is solve for the derivative, \(y'\). Let’s rewrite our equation first, just to make it a little easier to read.
Now we’re ready to start moving terms around:
Left Side: Move all terms with \(y'\) to the left.
Right Side: Move all terms without \(y'\) to the right.
Finally, we factor out \(y'\), and then divide both sides by the leftover pieces.
There is our desired derivative. Notice that since we used implicit differentiation, this version of the derivative involves both \(x\) and \(y\) terms - and this is perfectly fine.
We’re also interested in finding the equation of the tangent line at the point \((3,1)\).
Since we now know the derivative, we can use this to find the slope of the tangent \((m)\):
And then using the point-slope formula for the equation of the line, we get our tangent line equation:
Example 4#
Consider the equation: \(\sin(x+y)=y^2\cos x\).
Use implicit differentiation to calculate \(\dfrac{dy}{dx}\).
Click through the tabs to see the steps of our solution.
Note that since we want to calculate the derivative of \(y\) with respect to \(x\), this means, we are treating:
each \(x\) as a variable term only.
each \(y\) as both a variable and an implicit function of \(x\).
The first step is to apply the derivative to each term on both sides of the equation:
Here, we are using the prime notation to indicate differentiation with respect to \(x\). This means, in our equation, we are treating:
each \(x\) as a variable term only.
each \(y\) as both a variable and an implicit function of \(x\).
Next, we need to differentiate each of the terms. To do this we’re going to need to use some of our more advanced derivative rules.
Right Side - The term on the right side \(\; y^2\cdot \cos x \;\) is actually a product of two functions. So we need to use product rule:
Left Side - The term on the left side \(\; \sin\big(x+y\big) \;\) is actually a composition of functions where the:
Outer Function is \(\sin\big(\cdot \big)\)
Inner Function is \((x+y)\)
Whenever we differentiate the composition of two functions, we need to use Chain Rule. Which is done by multiplying the derivative of the outer function with the derivative of the inner function:
Putting this altogether, we can keep differentiating:
We’re done differentiating, so now we need to actually answer the question by solving for the derivative, \(y'\).
We usually do this by factoring out a \(y'\) wherever it occurs. However, as currently written, we’re not able to factor a \(y'\) from the \(\; \cos(x+y) \cdot \big(1+y'\big)\;\) piece on the left. We need to first multiply this out so that we can split off the \(y'\) term from the non-\(y'\) term.
Now we’re ready to start moving terms around:
Left Side: Move all terms with \(y'\) to the left.
Right Side: Move all terms without \(y'\) to the right.
Finally, we factor out \(y'\), and then divide both sides by the leftover pieces.
There is our desired derivative. Notice that since we used implicit differentiation, this version of the derivative involves both \(x\) and \(y\) terms - and this is perfectly fine.
Example 5#
Find the second derivative \(y''\) given the equation \(x^4+y^4=16\).
Click through the tabs to see the steps of our solution.
Note that since we want to calculate the second derivative of \(y\) with respect to \(x\), this means, we are treating:
each \(x\) as a variable term only.
each \(y\) as both a variable and an implicit function of \(x\).
We start by using implicit differentiation to find the first derivative \(y'\).
Now we’re ready to calculate the second derivative by differentiating the first derivative. We need to use implicit differentiation again, since our formula for \(y'\) involves both \(x\) and \(y\) terms.
Now at this point, it might feel like we’re done, but not quite. For these implicitly defined functions, we normally want a derivative written in terms of only \(x\) and \(y\). This means we need to do something with that \(y'\) term.
Well, we already determined a nice formula for \(y'\) when we calculated the first derivatve. So we plug this in and get our answer:
For practice, try using the original equation, \(x^4+y^4=16\), to simplify this answer for the second derivative down to: