The chain rule is a formula that expresses the derivative of the composition of two functions. Given two real univariate functions f(t) and g(x), their composition is h(t)=g(f(t))=(g∘f)(t). The derivative of h is
h′(t)=g′(f(t))f′(t)
This can be extended to arbitrary dimensions. Say now that f and g are defined as f:RN→RM and g:RM→RL. The composition is now h:RN→RL. The Differential of h is given by
Dh(t)=D(g∘f)(t)=Dg(f(t))⋅Df(t)
The dot operator "⋅" represents a product of linear operators. If they are given in matrix form (i.e. the Jacobians), it is a matrix multiplication.
For a partial derivative of the a-th component of h in the b-th argument of f, and calling xj the arguments of g, it reads as
∂tb∂ha(t)=j∑∂xj∂gax=f(t)∂tb∂fj(t)
where the vertical bar denotes that the derivative of ga is evaluated in f(t).