### Video Transcript

Let me share with you something I found particularly weird when I was a student first
learning calculus. Letโs say that you have a circle with radius five centered at the origin of the
๐ฅ๐ฆ-plane. This is something defined with the equation ๐ฅ squared plus ๐ฆ squared equals five
squared. That is, all of the points on this circle are a distance five from the origin, as
encapsulated by the Pythagorean theorem. Where the sum of the squares of the two legs on this triangle equal the square of the
hypotenuse, five squared. And suppose that you wanna find the slope of a tangent line to this circle, maybe at
the point ๐ฅ, ๐ฆ equals three, four.

Now, if youโre savvy with geometry, you might already know that this tangent line is
perpendicular to the radius touching it at that point. But letโs say you donโt already know that, or maybe you want a technique that
generalizes to curves other than just circles. As with other problems about the slopes of tangent lines to curves, the key thought
here is to zoom in close enough that the curve basically looks just like its own
tangent line. And then ask about a tiny step along that curve. The ๐ฆ-component of that little step is what you might call d๐ฆ. And the ๐ฅ-component is a little d๐ฅ. So the slope that we want is the rise over run, d๐ฆ divided by d๐ฅ.

But unlike other tangent-slope problems in calculus, this curve is not the graph of a
function. So we canโt just take a simple derivative, asking about the size of some tiny nudge
to the output of a function caused by some tiny nudge to the input. ๐ฅ is not an input and ๐ฆ is not an output. Theyโre both just interdependent values related by some equation.

This is whatโs called an implicit curve. Itโs just the set of all points ๐ฅ, ๐ฆ that satisfy some property written in terms of
the two variables ๐ฅ and ๐ฆ. The procedure for how you actually find d๐ฆ d๐ฅ for curves like this is the thing
that I found very weird as a calculus student. You take the derivative of both sides, like this. For ๐ฅ squared, you write two ๐ฅ times d๐ฅ. And similarly, ๐ฆ squared becomes two ๐ฆ times d๐ฆ. And then, the derivative of that constant, five squared, on the right is just
zero. Now, you can see why this feels a little strange, right? What does it mean to take the derivative of an expression that has multiple variables
in it? And why is it that weโre tacking on the little d๐ฆ and the little d๐ฅ in this
way?

But, if you just blindly move forward with what you get, you can rearrange this
equation and find an expression for d๐ฆ divided by d๐ฅ. Which, in this case, comes out to be negative ๐ฅ divided by ๐ฆ. So at the point with coordinates ๐ฅ, ๐ฆ equals three, four, that slope would be
negative three divided by four, evidently. This strange process is called implicit differentiation. And donโt worry, I have an explanation for how you can interpret taking a derivative
of an expression with two variables like this. But first, I wanna set aside this particular problem and show how itโs connected to a
different type of calculus problem, something called a related-rates problem.

Imagine a five-meter-long ladder held up against a wall. Where the top of the ladder starts four meters above the ground, which, by the
Pythagorean theorem, means that the bottom is three meters away from the wall. And letโs say itโs slipping down in such a way that the top of the ladder is dropping
at a rate of one meter per second. The question is, in that initial moment, whatโs the rate at which the bottom of the
ladder is moving away from the wall? Itโs interesting, right? That distance from the bottom of the ladder to the wall is 100 percent determined by
the distance from the top of the ladder to the floor. So we should have enough information to figure out how the rates of change for each
of those values actually depend on each other. But it might not be entirely clear how exactly you relate those two.

First things first, itโs always nice to give names to the quantities that we care
about. So letโs label that distance from the top of the ladder to the ground ๐ฆ of ๐ก,
written as a function of time cause itโs changing. Likewise, label the distance between the bottom of the ladder and the wall ๐ฅ of
๐ก. The key equation that relates these terms is the Pythagorean theorem, ๐ฅ of ๐ก
squared plus ๐ฆ of ๐ก squared equals five squared. What makes that a powerful equation to use is that itโs true at all points of
time. Now, one way that you could solve this would be to isolate ๐ฅ of ๐ก. And then you figure out what ๐ฆ of ๐ก has to be based on that one-meter-per-second
drop rate. And you could take the derivative of the resulting function, d๐ฅ d๐ก, the rate at
which ๐ฅ is changing with respect to time.

And thatโs fine; it involves a couple layers of using the chain rule. And itโll definitely work for you. But I wanna show a different way that you can think about the same problem. This left-hand side of the equation is a function of time, right? It just so happens to equal a constant, meaning the value evidently doesnโt change
while time passes. But itโs still written as an expression dependent on time, which means we can
manipulate it like any other function that has ๐ก as an input. In particular, we can take a derivative of this left-hand side. Which is a way of saying, โIf I let a little bit of time pass, some small d๐ก, which
causes ๐ฆ to slightly decrease and ๐ฅ to slightly increase, how much does this
expression change?โ

On the one hand, we know that that derivative should be zero, since the expression is
a constant. And constants donโt care about your tiny nudges in time. They just remain unchanged. But on the other hand, what do you get when you compute this derivative? Well, the derivative of ๐ฅ of ๐ก squared is two times ๐ฅ of ๐ก times the derivative
of ๐ฅ. Thatโs the chain rule that I talked about last video. Two ๐ฅ d๐ฅ represents the size of a change to ๐ฅ squared caused by some change to ๐ฅ,
and then weโre dividing out by d๐ก. Likewise, the rate at which ๐ฆ of ๐ก squared is changing is two times ๐ฆ of ๐ก times
the derivative of ๐ฆ.

Now evidently, this whole expression must be zero. And thatโs an equivalent way of saying that ๐ฅ squared plus ๐ฆ squared must not
change while the ladder moves. At the very start, time ๐ก equals zero, the height, ๐ฆ of ๐ก, is four meters, and
that distance, ๐ฅ of ๐ก, is three meters. And since the top of the ladder is dropping at a rate of one meter per second, that
derivative, d๐ฆ d๐ก, is negative one meters per second. Now this gives us enough information to isolate the derivative, d๐ฅ d๐ก. And when you work it out, it comes out to be four-thirds meters per second.

The reason I bring up this ladder problem is that I want you to compare it to the
problem of finding the slope of a tangent line to the circle. In both cases, we had the equation ๐ฅ squared plus ๐ฆ squared equals five
squared. And in both cases, we ended up taking the derivative of each side of this
expression. But for the ladder question, these expressions were functions of time. So taking the derivative has a clear meaning. Itโs the rate at which the expression changes as time changes. But what makes the circle situation strange is that rather than saying that small
amount of time, d๐ก, has passed, which causes ๐ฅ and ๐ฆ to change. The derivative just has these tiny nudges, d๐ฅ and d๐ฆ, just floating free, not tied
to some other common variable, like time. Let me show you a nice way to think about this.

Letโs give this expression, ๐ฅ squared plus ๐ฆ squared, a name, maybe ๐. ๐ is essentially a function of two variables. It takes every point ๐ฅ, ๐ฆ on the plane and associates it with a number. For points on this circle, that number happens to be 25. If you step off the circle away from the center, that value would be bigger. For other points ๐ฅ, ๐ฆ closer to the origin, that value would be smaller. Now what it means to take a derivative of this expression, a derivative of ๐, is to
consider a tiny change to both of these variables. Some tiny change, d๐ฅ, to ๐ฅ and some tiny change, d๐ฆ, to ๐ฆ. And not necessarily one that keeps you on the circle, by the way. Itโs just any tiny step in any direction of the ๐ฅ๐ฆ-plane. And from there you ask, how much does the value of ๐ change? And that difference, the difference in the value of ๐ before the nudge and after the
nudge, is what Iโm writing as d๐.

For example, in this picture, weโre starting off at a point where ๐ฅ equals three and
where ๐ฆ equals four. And letโs just say that that step I drew has d๐ฅ at negative 0.02 and d๐ฆ at negative
0.01. Then the decrease in ๐, the amount that ๐ฅ squared plus ๐ฆ squared changes over that
step, would be about two times three times negative 0.02 plus two times four times
negative 0.01. Thatโs what this derivative expression, two ๐ฅ d๐ฅ plus two ๐ฆ d๐ฆ, actually
means. Itโs a recipe for telling you how much the value ๐ฅ squared plus ๐ฆ squared changes
as determined by the point ๐ฅ, ๐ฆ where you start and the tiny step d๐ฅ, d๐ฆ that
you take. And as with all things derivative, this is only an approximation. But itโs one that gets truer and truer for smaller and smaller choices of d๐ฅ and
d๐ฆ. The key point here is that when you restrict yourself to steps along the circle,
youโre essentially saying you want to ensure that this value of ๐ doesnโt
change. It starts at a value of 25, and you wanna keep it at a value of 25. That is, d๐ should be zero.

So setting this expression two ๐ฅ d๐ฅ plus two ๐ฆ d๐ฆ equal to zero is the condition
under which one of these tiny steps actually stays on the circle. Again, this is only an approximation. Speaking more precisely, that condition is what keeps you on the tangent line of the
circle, not the circle itself. But for tiny enough steps, those are essentially the same thing. Of course, thereโs nothing special about the expression ๐ฅ squared plus ๐ฆ squared
equals five squared. Itโs always nice to think through more examples. So letโs consider this expression sin of ๐ฅ times ๐ฆ squared equals ๐ฅ. This corresponds to a whole bunch of U-shaped curves on the plane. And those curves, remember, represent all of the points ๐ฅ, ๐ฆ where the value of sin
of ๐ฅ times ๐ฆ squared happens to equal the value of ๐ฅ.

Now, imagine taking some tiny step with components d๐ฅ, d๐ฆ and not necessarily one
that keeps you on the curve. Taking the derivative of each side of this equation is gonna tell us how much the
value of that side changes during the step. On the left side, the product rule that we talked through last video tells us that
this should be left d right plus right d left. That is, sin of ๐ฅ times the change to ๐ฆ squared, which is two ๐ฆ times d๐ฆ, plus ๐ฆ
squared times the change to sin of ๐ฅ, which is cos of ๐ฅ times d๐ฅ. The right side is simply ๐ฅ, so the size of a change to that value is exactly d๐ฅ,
right? Now setting these two sides equal to each other is a way of saying, โWhatever your
tiny step with coordinates d๐ฅ and d๐ฆ is, if itโs gonna keep us on the curve, the
values of both the left-hand side and the right-hand side must change by the same
amount.โ Thatโs the only way that this top equation can remain true.

From there, depending on what problem youโre trying to solve, you have something to
work with algebraically. And maybe the most common goal is to try to figure out what d๐ฆ divided by d๐ฅ
is. As a final example here, I wanna show how you can actually use this technique of
implicit differentiation to figure out new derivative formulas. Iโve mentioned that the derivative of ๐ to the ๐ฅ is itself. But what about the derivative of its inverse function, the natural log of ๐ฅ? Well, the graph of the natural log of ๐ฅ can be thought of as an implicit curve. Itโs all of the points ๐ฅ, ๐ฆ on the plane where ๐ฆ happens to equal ln of ๐ฅ. It just happens to be the case that the ๐ฅs and ๐ฆs of this equation arenโt as
intermingled as they were in our other examples. The slope of this graph, d๐ฆ divided by d๐ฅ, should be the derivative of ln of ๐ฅ,
right? Well, to find that, first rearrange this equation, ๐ฆ equals ln of ๐ฅ, to be ๐ to
the ๐ฆ equals ๐ฅ. This is exactly what the natural log of ๐ฅ means. Itโs saying ๐ to the what equals ๐ฅ.

Since we know the derivative of ๐ to the ๐ฆ, we can take the derivative of both
sides here. Effectively asking how a tiny step with components d๐ฅ, d๐ฆ changes the value of each
one of these sides. To ensure that a step stays on the curve, the change to this left side of the
equation, which is ๐ to the ๐ฆ times ๐๐ฆ, must equal the change to the right side,
which in this case is just d๐ฅ. Rearranging, that means that d๐ฆ divided by d๐ฅ, the slope of our graph, equals one
divided by ๐ to the ๐ฆ. And when weโre on the curve, ๐ to the ๐ฆ is by definition the same thing as ๐ฅ. So evidently, the slope is one divided by ๐ฅ. And of course, an expression for the slope of a graph of a function written in terms
of ๐ฅ like this is the derivative of that function. So evidently, the derivative of ln of ๐ฅ is one divided by ๐ฅ.

By the way, all of this is a little sneak peek into multivariable calculus. Where you consider functions that have multiple inputs and how they change as you
tweak those multiple inputs. The key, as always, is to have a clear image in your head of what tiny nudges are at
play and how exactly they depend on each other.