Linear algebra is very well developed with a vast literature in numerical methods. This not true for multi-dimensional arrays higher than 2, which correspond to the familiar matrices. In general it is difficult to generalize matrix operations to higher dimensions. One paper that gives an introduction to the topic and treats the problem of diagonalizing higher dimensional arrays is

Tensor Diagonalization

The literature usually refers multi-dimensional arrays as as Tensors, but I prefer to use the term array, because in physics a tensor is more than a multidimensional array.

The following figures correspond to an 9x9x9 array after and before a diagonalization attempt, with the application of orthogonal transformations.