2
$\begingroup$

Recently I've tried to find the difference between partial differentiation and total differentiation. I've heard the total derivative is defined on single value functions, while the partial derivative by contrast is defined on multivariate functions. My problem is, that total differentiation is used on multivariate functions all the time.

Every time I come up with a rigorous definition I arrive at a contradiction. I will share what I have defined so far, and hopefully you can enlighten me.

Let

$$f: (x_1, ... , x_n) \rightarrow f(x_1, ..., x_n)$$

and it's partial derivative by the difference quotient

$$\frac{\partial f}{\partial x_i} = \lim_{h \to 0} \frac{f(x_1,..,x_i+h,...x_n)- f(x_1,..., x_n)}{h}$$

the total derivative must by contrast account for interdependence between $x_k$ in the domain of f.

$$\frac{df}{dx_i}\stackrel{?}{=} \sum_k{\frac{\partial f}{\partial x_k} \frac{\partial x_k}{\partial x_i}}$$

This seemed sensible to me, until I realized it simplified to

$$n \frac{\partial f}{\partial x_i}$$

which definitely isn't right.

Can someone tell me where I've made an error? Or provide better definition? This issue really annoys me, since all my research so far didn't answer this question at all.

Edit: Ok thank you for all the responses! I'm just writing out the final formula for total derivatives for quick lookup now: $\frac{d}{d x_i}$ is defined recursively as $$\frac{df}{dx_i}\stackrel{!}{=} \sum_k{\frac{\partial f}{\partial x_k} \frac{d x_k}{d x_i}}$$

until $x_k$ has a domain without interdependence, in which case $\frac{\partial x_j}{\partial x_i}$ = $\frac{d x_j}{d x_i}$ and the entire expression can be calculated by limits.

$\endgroup$
0
3
$\begingroup$

The difficulty comes from the fact that with function of several variables, there can be dependencies between the variables (which is not possible in the univariate case).

Consider the function $f(x,y):=x+y$.

The partial derivative on $x$ is what you get by varying $x$ and freezing the other variables, i.e.

$$\frac{\partial f(x,y)}{\partial x}=f_x(x,y)=\frac{d(x+y)}{dx}=1.$$

Now consider the dependency $y=x^2$.

We still have the partial derivative on $x$

$$\frac{\partial f(x,x^2)}{\partial x}=f_x(x,x^2)=1$$ but this is no more

$$\frac{d(x+y)}{dx}=\frac{d(x+x^2)}{dx}=1+2x.$$

The latter is the total derivative as it accounts for the indirect variations of $f$ due to the variations of the other arguments induced by $x$.

The rule is now

$$\frac{df(x,y)}{dx}=\frac{\partial f(x,y)}{\partial x}+\frac{\partial f(x,y)}{\partial y}\frac{dy}{dx}=f_x(x,x^2)+f_y(x,x^2)\frac{d(x^2)}{dx}.$$

$\endgroup$
1
  • $\begingroup$ thanks! this helped. I kind of didn't expect 'd' to be defined recursively, but it makes sense now! $\endgroup$
    – Hans Meier
    Jul 1 '20 at 15:53
3
$\begingroup$

In linear algebra you learn about linear transformations $A:\>{\mathbb R}^n\to{\mathbb R}^m$. This $A$ is a single letter, but the full information content of $A$ is encased in an $m\times n$ matrix $\bigl[A_{ik}\bigr]$ of real numbers. I hope you don't say "I never know when to speak of $A$, and when of $A_{21}$". In the cases $m=1$, $n=1$, $m=n=1$ the matrix $\bigl[A_{ik}\bigr]$ is a row vector, a column vector, a single number.

If you now have a function $f:\>{\mathbb R}^n\to{\mathbb R}^m$ then its derivative $df(p)$ at a certain point $p$ in the domain of $f$ is a linear map $A$ as described above. This map can be used to approximate $f$ in the neighborhood of $p$, and for other things, as explained in Calculus 102. The map $A$ has its matrix $\bigl[A_{ik}\bigr]$, and it turns out that $$A_{ik}={\partial f_i\over\partial x_k}(p)\ ,$$ whereby the partial derivatives ${\partial f_i\over\partial x_k}(p)$ can be calculated as limits. In particular, when $m=1$ then $f$ is real valued, and $\bigl[A_{ik}\bigr]$ is a row vector $$\bigl[A_1 \ A_2\ \ldots\ A_n\bigr]=\left({\partial f\over\partial x_1},{\partial f\over\partial x_2},\ \ldots,\ {\partial f\over\partial x_n}\right)_p=:\nabla f(p)\ .$$ Expressions of the form $$\phi(x):=f\bigl(x,y(x)\bigr)$$ are a sad story, and should be avoided. Here the letter $x$ is used for two different things, namely as coordinate variable for the outer function $f$ and also as single variable of the composed function $\phi$. When studying rules of differentiation you should say: I have a vector valued inner function $t\mapsto {\bf r}(t)=\bigl(x(t),y(t)\bigr)$ and an outer function $f$ in the $(x,y)$ plane. "By coincidence" we have $x(t)=t$, so that $\phi:=f\circ {\bf r}$ appears as $\phi(t)=f\bigl(t,y(t)\bigr)$. The chain rule then gives $$\phi'(t)={\partial f\over\partial x}\biggr|_{{\bf r}(t)}\cdot 1+{\partial f\over\partial y}\biggr|_{{\bf r}(t)}\cdot y'(t)\ .$$

$\endgroup$
1
$\begingroup$

In order to make sense of a total derivative of a function of multiple variables, you need to make some additional assumptions.

Suppose $x_1,x_2,\ldots,x_n$ are all single-variable functions of some variable $t$ (using the word "function" in its 17th-century sense rather than in the sense of a mapping that is applied to an input parameter), so that it is possible to define $\frac{d}{dt}x_1, \frac{d}{dt}x_2, \ldots, \frac{d}{dt}x_n$.

Then any choice of value of $t$ leads to a unique value of $f(x_1,x_2,\ldots,x_n).$ That is, the value of $f(x_1,x_2,\ldots,x_n)$ can be expressed as a single-variable function of $t$, $$ f(x_1,x_2,\ldots,x_n) = f_t(t). $$

Then we can write $$ \frac{d}{dt} f(x_1,x_2,\ldots,x_n) = \frac{d}{dt} f_t(t) = \frac{\partial f}{\partial x_1} \frac{dx_1}{dt} + \frac{\partial f}{\partial x_2} \frac{dx_2}{dt} + \cdots + \frac{\partial f}{\partial x_n} \frac{dx_n}{dt}. $$

Note the total derivatives on the right-hand side. It is technically possible to write these as partial derivatives, but only if you strictly regard each of the $x_i$ as a single-variable function of $t$ and never as a function of anything else.

You are considering the case in which $t = x_i$, that is, $t$ is itself one of the input parameters of $f(x_1,x_2,\ldots,x_n).$ Then $$ \frac{dx_i}{dx_i} = \frac{dt}{dt} = 1. $$

But it is not true in general that $$ \frac{dx_k}{dx_i} \stackrel?= 1 $$ for any other of the variables $x_k,$ $k \neq i.$ If $x_k$ is a constant function of $x_i,$ then $$ \frac{dx_k}{dx_i} = 0. $$

If $x_k$ is a non-constant function of $x_i,$ then $$ \frac{dx_k}{dx_i} = g(x_i) $$ for some other function $g$.

And if $x_k$ cannot be defined as a function of $x_i$ at all, then it doesn't make sense to write $\frac{df}{dx_i}.$

For answers to your more general question, see What is the difference between partial and normal derivatives?

$\endgroup$
0
$\begingroup$

It simplifies to $\frac{\partial f}{\partial x_i}$, because $\frac{\partial x_k}{\partial x_i}=0$ if $i\neq k$.

$\endgroup$
1
  • $\begingroup$ well, that doesn't solve my problem though. For independent parameters, both definitions are equivalent, yes. But what is the difference between total and partial derivative exactly? and what prevents me from canceling $\partial x_k$ and $\partial x_k$? $\endgroup$
    – Hans Meier
    Jul 1 '20 at 10:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.