The chain rule for functions of several variables is as follows. For f : Rm → Rn and g : Rn → Rp, and g o f differentiable at p, then the Jacobian is given by
Again, we have matrix multiplication, so one must preserve this exact order.
Compositions in one order may be defined, but not necessarily in the other way.