Partial derivatives
A partial derivative is a method we use to find the derivative of a function that depends on more than one variable, with respect to one of its variables, while keeping the others constant. This allows us to understand how a function is affected by a single variable instead of by all of them. Suppose we are modeling the price of a stock item, and the price depends on a number of different factors. We can vary one variable at a time to determine how much this change will affect the price of the stock item. This is different from taking a total derivative, where all the variables vary.
A multivariate function can have as many variables as you would look like, but to keep things simple, we will look at a function with two variables, as follows:
This function looks a lot more complicated than the ones we have previously dealt with. Let's break it down. When we take the partial derivative of a function with respect to x, we find the rate of change of z as x varies, while keeping y constant. The same applies when we differentiate with respect to any other variable.
Let's visually imagine the xy-plane (a flat surface) as being the set of acceptable points that can be used as input to our function. The output, z, can be thought of as how much we are elevated (or the height) from the xy-plane.
Let's start by first differentiating the function with respect to , as follows:
This gives us the following:
Now, we will differentiate with respect to y, as follows:
This gives us the following:
As we saw earlier, in single variable differentiation, we can take second derivatives of functions (within reason, of course), but in multivariable calculus, we can also take mixed partial derivatives, as illustrated here:
You may have noticed that when we take a mixed partial derivative, the order of the variables does not matter, and we get the same result whether we first differentiate with respect to x and then with respect to y, or vice versa.
We can also write this in another form that is often more convenient, and this is what we will be using in this book, going forward. The function is illustrated here: