Is there such a thing as a matrix of functions?

Solution 1:

You can define a matrix with elements in any commutative ring, since the only requirement is to be able to perform addition and multiplication with the usual properties.

You even may consider the following $2\times 2$ matrices, with elements that do not belong to the same sets. Such matrices describe the endomorphisms of the direct sum $\;E=U\oplus V$ of two vector spaces $U$ and $V$ $$M=\begin{bmatrix} f_1&f_2\\g_1&g_2\end{bmatrix},\quad\text{where}\quad\begin{array}{|ll} f_1\in \mathcal L(U,U),& f_2\in \mathcal L(U,V),\\ g_1\in \mathcal L(V,U),& g_2\in \mathcal L(V,V). \end{array}$$ You can check one can multiply two such matrices, multiplication of elements being composition of linear maps.

Solution 2:

One common use of functions in a matrix is the Hessian matrix in multivariable calculus. This is a matrix of second derivatives with respect to $x_1, x_2, \ldots$.

$$ M = \pmatrix{ \frac{\partial^2 f}{\partial^2 x_1} & \frac{\partial^2 f}{\partial x_1 \partial x_2} & \cdots \\ \frac{\partial^2 f}{\partial x_2 \partial x_1} & \frac{\partial^2 f}{\partial^2 x_2} & \cdots \\ \vdots & \vdots & \ddots }$$

The eigenvalues of this matrix says a lot about the nature of the function (minimum, maximum, saddle point) and other properties such as stability.