Nothing should be submitted for the following exercise, and it should be considered only for interest's sake.
Feel free to ignore it if you wish.
We will try to gain some insight into the following question: what do the eigenvalues of a matrix chosen at random look like?
You should use matlab or another tool of your choice for the following.
It turns out that any matrix with real entries which is equal to its own transpose is diagonalizable, i.e., similar to a diagonal matrix, and therefore there is a basis of $\R^n$ consisting of eigenvectors for the matrix.
We will make use of that in what follows.
- Construct a $25\times25$ upper triangular matrix in matlab with entries chosen independantly at random from a Gaussian distribution of variance one; you may find the matlab functions triu and randn useful for this.
- Use this to construct a symmetric $25\times25$ matrix (one which is equal to its own transpose) whose upper triangular entries are independent random Gaussian variables. Arrange so that the diagonal entries have either variance 1 or $\sqrt2$, whichever you prefer.
- Multiply the matrix above by the constant $\frac1{\sqrt5}$ (this causes the rows of the matrix to have, on average, a length of $1$).
- Compute the eigenvalues of the above matrix, and plot them on a histogram. You may find the matlab commands eig and histogram useful for this; you may want something like the command histogram(e, -2:.1:2); this post on stackoverflow may also be helpful.
- Repeat the above a few times and see if you can divine a pattern.
- Now do the same for a much larger matrix, normalizing by $\frac1{\sqrt{N}}$ instead of $\frac1{\sqrt5}$; what do the data look like? Keep trying larger and larger matrices until your computer has a hard time handling it, but try to get at least to $10000\times10000$ matrices (you may need to wait a minute or two between commands for matrices of this size, but not too long).
- Now do the same, except use a symmetric matrix whose entries are $\pm1$ chosen at random instead of Gaussian. You may find the matlab function randn helpful.
It turns out that there is actually a lot of structure lurking within the eigenvalues of a random matrix.