 To begin this video, let's consider and find the derivative of the natural log of x plus one over the square root of x minus two and do this with respect to x. One could calculate the derivative of this function like we've done many times before. You could do some type of chain rule argument where you have the function x plus one over the square root of x minus two, that rational expression inside of the natural log. We could use the chain rule, go from there, but in addition to the chain rule, we also are going to have to use the quotient rule here. But then you also have like x minus one inside of a square root. So there's a lot going on there. Lots of combinations of the chain rule and the quotient rule and play there. What I want to demonstrate in this video is an alternative approach to computing this one that actually can avoid the quotient rule and a lot of the chain rule steps in this situation. We can't avoid all the chain rules, but we can simplify it dramatically. So how we're going to do that is we're going to expand the function using properties of logarithms. So I'll remind you that when you have a quotient inside of a logarithm, this is the same thing as taking a difference of two logs. So if we're trying to compute the natural log of x plus one over the square root of x minus two prime, we could expand the logarithm as the log of x plus one minus the log of the square root of x minus two, like so. So that's a lot. That's one of the laws of logarithms. The quotient inside becomes a different on the outside. This is compatible with differentiation rules because if you take the derivative of a difference, this becomes the derivative of their different. That is the difference of the derivatives. You can take the derivative separately in this calculation. So by doing so, we actually can avoid the use of the quotient rule. The quotient rule is not necessary anymore. Also, look at the second bit, right? This square root of x plus one, we could think of it as square root of x minus two, excuse me. We could think of it as x minus two to the one half power, like so. And so inside of a logarithm, the exponent can actually be brought outside as a coefficient. And that coefficient could then also be factored out of the derivative process. So this looks like we're going to take the derivative of the natural log of x plus one. And then we're going to subtract from that one half the derivative of the natural log of x minus two, like so. For which then when we take the derivative of these natural logs, we will have to use the chain rule there, but the chain rule will be fairly benign. When you take the derivative of the natural log of x plus one, you're going to get x plus one in the denominator. And then numerator, you're going to get the derivative of x plus one, which is actually one itself. Then the next one, you're going to get this one half. And then you're going to times that by, I'll just write it like this, one half times, well, we take the derivative of the natural log of x minus two. So you're going to put the x minus two in the denominator, and then you're going to put its derivative in the numerator, which you get this thing right here. And so the derivative looks like one over x plus one minus one half times one over x minus two. Now this last figure, if you wanted to write it as a common fraction, that's what I was starting to do, but I didn't want to wait. I'm afraid it might be a little bit misleading where that came from, but we could write that as a common fraction right there. And if we want to continue to add these together as one single fraction, we could do that. But this is the derivative, right? No more calculus is necessary. We were able to avoid at least one usage of the chain rule, and we avoided the quotient rule entirely because we employed the properties of logarithms to expand the logarithm. This idea of using the expansion properties of logarithms to simplify derivative calculations is known as logarithmic differentiation. Let me show you what exactly what I mean here. We're going to talk some more about this. So expanding a logarithmic expression to make the derivative easier, this is what we mean by logarithmic differentiation, but it turns out the original function doesn't even have to involve logarithms, right? What if we have some function y equals f of x? And maybe this function involves a bunch of quotients and products and exponents. What we could do is we could take the natural log of both sides. We get the natural log of y equals the natural log of f of x right here. Then we expand this expression, the natural log of f of x, all the way through. And then once we've done that, we then take the derivative. When you take the derivative of the natural log of y, that's going to look like a y prime over y, and this will equal, well, the derivative of the natural log of f of x. Without knowing what f is, it's hard to predict that what it is, but the point is it should be simple. It looks complicated, but it'll be simple. So we get y prime over y equals the derivative of the natural log of f of x. If we times both sides by y, we would end up with y prime equals, well, you're going to get y times the natural log of f of x, which I can't describe what that's going to look like. The natural log, when you take the derivative there, you're going to get f prime of x over f of x. That's what the natural log does when you multiply it by things here. And then, well, given that y is f of x, you see that these things are going to cancel, and we would have the derivative of f like we normally would. But the idea is this should be much simpler than perhaps would otherwise be the case. Now, we should be cautious that when we take the natural log of y, well, what if y was a negative number? What if our function is negative? Wouldn't that be outside the domain of the function? Well, the good news is when we do this, take the natural log of both sides. Really, what we could do is take the natural log of the absolute value of both sides. So we take the natural log of the absolute value of y. We take the natural log of the absolute value of f of x. When you do that, you're not going to change the derivative on this right hand side at all, right? The derivative of the natural log of y is still going to be y prime over y. You just end up with an absolute value in over here. And again, this is mostly going to clean itself up later on. So I guess what I'm saying is introducing the absolute value takes care of some domain issues that you might see when you do this logarithmic differentiation. But if you forget to do them in this situation, you usually can get away with it without much of a problem whatsoever. I think the best way to demonstrate logarithmic differentiation here is to give you an example of exactly what we have in mind. So consider the function y equals x to the 3 fourths power times the square root of x squared plus one over 3x plus two to the fifth power. Imagine that without logarithms, how would we have to calculate this thing? Well, some things to note. We have this fraction in there, so the quotient rule is going to come into play. The numerator has a product. So after you do the quotient rule, you're going to have to use the product rule. But then, you know, the power rule is definitely going to come into play. But then the numerator, we have a square root with an x squared plus one side of it. That gives us another chain rule. We have a 3x plus two to the fifth. We're going to have to use a chain rule there. This thing is going to get very messy very quickly. But if we use logarithms, it turns out we can simplify this dramatically. For example, if we take the natural log of both sides, we take the natural log of y, and we take the natural log of this whole thing, x to the 3 fourths times the square root of x squared plus one all over 3x plus two to the fifth. Now let's try to expand the right hand side. If we do that, again, recognizing first there's a quotient, you're going to get the natural log of x to the 3 fourths times the square root of x squared plus one. Subtract from that the natural log of 3x plus two all raised to the fifth power. And then we can expand those things even faster. The natural log here, we have a product in the first one. So by the first law of logarithms, you can expand that to be the natural log of x to the 3 fourths plus the natural log of the square root of x squared plus one. And then we'll still have the minus the natural log of 3x plus two to the fifth. And then finally we let's pull the exponents out in front. So the first one, the natural log of x to the 3 fourths we can bring out the exponent. So we get three four times the natural log of x with the second one will since you have a square root that's just the one half exponent pull it out in front. You're going to get one half times the natural log of x squared plus one. And then with the last one pull out the exponent of five, you get five times the natural log of 3x plus two. And so this is going to still equal the natural log of y so we expanded the logarithm, which if you have practice expanding logarithms like this, this is actually something we can do very very quickly, you know, with with enough practice we could have gone from here to here immediately so some of that some of these intermediate could they could disappear. Then the next goal here is we're going to take the derivative of all of these things the derivative, like so, in which case on the left hand side, when you do logarithmic differentiation the left hand side will always look the same it always looks like a y prime over a y. Because by properties of the natural log, we take the derivative of function you can get one over that function, but the times by the inner derivative due to the chain rule so you get y prime over y. On the right hand side, because we have a bunch of sums and differences and coefficients, we just have to take the derivative of these logarithms take the derivative of the natural log of x, the natural log of x squared plus one the natural log of 3x plus two. In which case when we do that, we're going to end up with a three force times the derivative of natural log of x that's a one over x. Next, we have to take the derivative of x squared plus one the natural log of x square plus one x square plus one is going to go to the denominator, then the derivative of x squared plus one needs to go to the numerator which is a 2x. And then finally we get this minus five times the derivative of the natural log of 3x plus two. Well by properties of the natural log here you're going to get 3x plus two in the denominator and then the numerator you get the derivative of 3x plus two which is a three. I do notice there is a factor of two I can cancel out there. Not much else to do. You could try to add these things together. I wouldn't bother. It's probably just better off just leaving them together unless you're asked to add the fractions together leave them separated here. But the only thing I have to caution about logarithmic differentiation is that we haven't found y prime yet. Y prime is here but we have right now y prime over y. We need times both sides by y in order to cancel them out on the left hand side over here. So upon doing that we'll get y prime equals y times what we get three over 4x. We're going to get x over x squared plus one and they're going to minus 15 five times three over 3x plus two like so and then it's also best to insert instead of y because we did find the derivative implicitly. We don't need it because we actually did start off with an explicit function. It's best to plug back in the original expression for y. And so we see that the derivative dy over dx is going to equal y which the formula remember was x to the three fourths times the square root of x squared plus one over 3x plus two to the fifth. And then you times that by three over 4x plus x over x squared plus one minus 15 over 3x plus two. Like so like I said we could distribute y through and add things together if we wanted to but I think that's going to be much more than we really want in this one. This gives us our derivative and while that was there was a good amount of work that still had to be done on this exercise. When you compare that to how you would do this without logarithmic differentiation, you can start to see how effective this strategy is. And so in a nutshell, to compute a derivative logarithmically what you do is you take a function, you take the natural log of both sides, you expand the right hand side and then calculate the derivative implicitly. It's a very effective process that many students underestimate how good logarithmic differentiation is. We should want to use it a lot because it's one of the most effective tools for computing derivatives in an effective efficient manner.