Chain rule in matrix form. Since matrix multiplication does not commute, the. order of the derivatives matters in the chain rule. For instance, given y = b. T (X. T a). Let h = X. T a. and k = Xb. Then, ∂y. ∂a = ∂h. ∂a. ∂y. ∂h = Xb, ∂y. ∂X = ∂y. ∂k (∂k. ∂X) T = ab. T . The order the derivatives might vary, but it can be