So there we have it, the chain rule that we are using on a function of a function.
We have spoken of its formal definition and also proved it
and we've looked at the faster method that we just do by observation.
So let me just quickly go over what we've just discussed.
This is the formal definition, so we're saying that if you have a function f, g of x,
so we have g of x which is within a function f, so it's two different functions, one within another.
You can separate it into two functions, you can let the inside function be u,
whatever it is which we look at numerically. In our case we're calling it g of x
and you can let the outside function then become the function of u so f of u.
We then differentiate them separately as two separate functions,
we use du/dx and we use dy/du, depending on what the variables and the function are
and then lastly to get your final answer, we just multiply the two together.
So remember that this was our formal definition and this is what we proved.
Let's look at an another example and this is also a function of a function,
let's write it out to see why it's a function of a function and then apply the chain rule.
We'll try and do it the faster way this time. So we have a function, y equals to 5x squared
plus 2x minus 1 to the power of 3. First of all, look at it and observe.
This isn't a normal function that we've been looking at previously,
this is a function and then we have an outside function,
it's almost like you have a container, so you have something on the outside and something in the inside
and you have to try and spot that there are two different functions.
Now, the chain rule definition we have already defined,
so we said dy/dx is dy/du multiplied by du/dx, but we also spoke at the faster method
which is what we recommend which makes things a lot easier.
So this question will be a lot easier if we just did this by observation or the faster way
and remember what we said dy/dx, you can do the whole of the outside function
so just that whole thing as one and you can just ignore anything on the inside so you just,
this could be anything and it doesn't bother us, so you just take the outside function
or the container function and differentiate it.
So I bring the power to the front here so that brings me 3,
the inside stays as it is nothing changes because I'm just imagining it's not there
and I decrease the power by 1, so I've differentiated the outside function.
Next step, I differentiate or I times it with the differential of the inside
so now I just look at the function on the inside.
We're going to have to differentiate each term separately.
So 5x squared, bring the power down, decrease the power by 1, gives me 10x.
And then 2x will just go to 2 and then the minus 1 disappears because it's a constant.
So that is the differential of the inside. So once again let's just repeat the faster way of doing the chain rule,
you differentiate the outside function, so this function first
and then you multiply it with the inside function which is this.
The easiest way to do this is to not look at questions in a complicated way
just spot that you have two functions and then just do the outside function,
ignoring anything that's in the inside and then just doing inside function,
ignoring anything that's on the outside. So I'm just gonna tidy this up,
I'm not going to expand out because that's just going to make things more complicated,
so I just leave this factorized so it stays in bracket.
This is my gradient and you can see that it's a fairly complicated gradient
so we're not dealing with straight forward gradients anymore.
We're looking at functions that are complicated, we're looking at a function of a function
and this is our gradient. And again just to remind you we can do a lot with this gradient now,
so we can find the gradient at specific points,
we can find equations of tangents and normals, which will move on to, in the later questions.