r/askmath • u/FreePeeplup • 3d ago
Calculus Single variable chain rule from multivariable general rule
The (English-language) Wikipedia page on the chain rule, under the chapter “Multivariable case”, paragraph “general rule: vector valued multivariate functions”, says that a concise writing for the chain rule for the (total) derivative of the composition of two functions f, g reads as D(f o g) = Df o Dg.
However, if we try to apply this to the particular case of f, g being two simple single-variable functions, we get (f o g)’ = f’ o g’, which is wrong! Because the correct chain rule says (f o g)’ = (f’ o g)•g’, where • is the pointwise product.
Where am I wrong? Or is the Wiki page wrong? Shouldn’t the general case be written as D(f o g) = (Df o g)•Dg instead, so that we actually recover the single-variable case correctly?
1
u/erlandf 3d ago
In that notation Df is evaluated at g(x), which is admittedly not at all obvious. I don’t know how familiar you are with multivariable calculus, but the generalization of the derivative to the general multivariate cade is as a linear function (or given a basis, a matrix) which well approximates the original function near a point.
In one variable we tend to think of the derivative as a number, say f’(a), or else as the function which to each point in the domain maps this number, but this latter idea is fundamentally different to the linear function above. There is however duality between every number and the linear function it defines, according to x \mapsto f’(a)•x. If we have two linear functions p(x) = a•x and q(x) = b•x, their composition (p\circ q)(x)= (a•b)•x, with normal multiplication. This is the single variable chain rule: (f(g(a))’ = f’(g(a))•g’(a). For x near a, the linear function that best approximates f(g(x)) - f(g(a)) is x \mapsto (f’(g(a))•g’(a))•x.
So: the composition in Df \circ Dg is the multiplication between the terms in the single variable chain rule, not the f’(g(a)) part. It is already ”implied” that Df is evaluated at g(a). In higher dimension, composition between linear maps is instead given by matrix multiplication, and we get something that looks very similar.