I have tried to compute the eigenvalues of random matrices of the GOE ensemble, using MATLAB.
Such matrices of size $n * n $ can be obtained easily, symmetrizing matrices whose elements follow the standard normal distribution: $H = (M + M^T )/ 2 $.
In MATLAB code for instance:
H = randn(n);
M = (H+H')/2;
eigenvalues = eig(M);
This naive approach is the one I found in most documents. However, it looks like a more efficient method was developed some years ago by A. Edelman and others, which makes use of a matrix factorization (Householder factorization) to obtain a tridiagonal matrix whose eigenvalues are following the same distribution than the GOE. A description of this technique can be found here: http://www-math.mit.edu/~edelman/publications/random_matrix.pdf
The form of this tridiagonal matrix is the next one:
\begin{bmatrix} G_n & \chi_{n-1} & & & & \\ \chi_{n-1} & G_{n-1} & \chi_{n-2} & & & & \\ & \chi_{n-2} & G_{n-2} & & & \\ & & & \ddots & \ddots & \chi_{1} \\ & & & & \chi_{1} & G_1 \\ \end{bmatrix}
where G follow a normal distribution and $\chi_i$ follow chi square distributions. Such a matrix in MATLAB can be obtained with the next lines:
a = sqrt(chi2rnd([n:-1:1]))';
H = spdiags(a, 1, n, n) + spdiags(randn(n,1)/sqrt(2), 0, n, n);
M = (H+H')/sqrt(2);
eigenvalues = eig(M);
Eigenvalues from such a matrix should be easier to get than the ones of the initial problem (the author comes up with $O(n^2)$ time vs. $O(n^3)$ time). When I plot some histograms of the eigenvalues obtained with the two methods, I get results in good agreement.
Shall this method be considered the current best practice to compute the eigenvalues of matrices from the GOE ? What do people do in practice ?