I wrote several matlab programs to help with the solution to this problem:
>> n=100;
>> a=randn(100);
>> tridi;
>> [Q,D]=eig(c);
>> countbig
count =
4150
The entries in Q were printed on a semilog scale, after zeroing out any
smaller than 10e-10, giving
this plot.
The MATLAB command spy can be used to give a plot of the nonzero
structure of Q; again after zeroing out small components, we get
this plot.
There are some dense columns, but there are also some sparse columns.
>> semilogy(max(abs(Q),10^(-10))) % saved as hw5q5f1.eps >> eps=1e-10 eps = 1.0000e-10 >> spy(max(abs(Q)-eps,0)) % saved as hw5q5spy1.epsIt is possible to experiment with other choices for what we consider "small" values. The program countbigeps.m was used to count. Here are the corresponding semilog plot and spy plot.
>> semilogy(max(abs(Q),10^(-3))) % saved as hw5q5f3.eps
>> eps=1.e-3;
>> spy(max(abs(Q)-eps,0)) % saved as hw5q5spy3.eps
>> eps=1.e-3
eps =
1.0000e-03
>> countbigeps
count =
1287
>> laplace;
>> [Q,D]=eig(T);
>> countbig
count =
10000
>> semilogy(max(abs(Q),10^(-10))) % saved as hw5q5laplace.eps
>> eps=1.e-3
eps =
1.0000e-03
>> countbigeps
count =
10000