# Symmetry of second derivatives

In

mathematics, the

**symmetry of second derivatives** refers to the possibility of interchanging the order of taking

partial derivatives of a function

*f*(*x*_{1}, *x*_{2}, ... , *x*_{n})

of

*n* variables. If the partial derivative with respect to

*x*_{i} is denoted with a subscript

*i*, then the symmetry is the assertion that

*f*_{ij}

is an

*n*×

*n* symmetric matrix. This matrix is called the

**Hessian matrix** of

*f*. In most normal circumstances it is indeed symmetric; but from the point of view of

mathematical analysis this isn't a safe statement, without some hypothesis on

*f* that goes further than simply stating the existence of the second derivatives at a particular point.

From the symmetry one derives the algebraic statement

*D*_{i}.*D*_{j} = *D*_{j}. *D*_{i}

where

*D*_{i} denotes partial differential with respect to

*x*_{i}, as

differential operator. From that relation it follows that the

ring of differential operators with constant coefficients, generated by the

*D*_{i}, is

commutative. But one should naturally specify some domain for these operators. It is easy to check the symmetry as applied to monomials, so that one can take polynomials in the

*x*_{i} as a domain. In fact smooth functions is possible.

One can also apply the theory of distributions to get round any analytic problems with the symmetry. Firstly the derivative of any function can be defined (provided it is integrable), as a distribution. Secondly the use of integration by parts throws the symmetry question back onto the test functions, which are smooth and certainly satisfy the symmetry. One concludes that, in the sense of distributions, the symmetry always holds. (Another approach, where the Fourier transform of a function is defined, is to note that on transforms the partial derivatives become multiplication operators that commute much more obviously).

The fact remains that in the worst case there are counterexamples. In the case of two variables, near (0,0) one can consider two limiting processes on

*f*(*h*,*k*) − *f*(*h*,0) − *f*(0,*k*) + *f*(0,0)

corresponding to making

*h* -> 0 first, and to making

*k* -> 0 first. These processes need not

*commute*: it can matter, looking at the first-order terms, which is applied first. This leads to the construction of

pathological examples in which the symmetry of second derivatives isn't true.