Академический Документы
Профессиональный Документы
Культура Документы
Henry Charlesworth
January 26, 2015
however as I was just about able to get adequate results for the problem were looking at without having to modify
my code to account for this I decided it was easier to just not use shifting at all, and let the code run overnight!
Results
The eigenvalues calculated between 0 and 40 (fewer than 1000 out of the 100 million were higher than this, and
these were ignored) are then placed in to bins of length = 0.001. Because the resulting histogram has sharp
peaks at integer values of it is important that the bins are centred on the integer values, i.e. instead of having
for example the two bins 19.999-20.000 and 20.000-20.001 you need to have a bin covering 19.9995-20.0005. This
is because otherwise eigenvalues which mathematically are exactly 20 can be placed in two different bins due to
the finite accuracy of the eigenvalues obtained making some just below 20 and some just above. The histogram
is then normalized by calculating the area using the trapz function in MATLAB, and the results are attached
as a Mathematica notebook. There the histogram is compared with the function given on the assignment sheet
and we see that the peaks in the histogram are well approximated by the function as stated. As the nodes are
placed independently around the unit circle by symmetry the average degree of each node must be the same, and
we can calculate the average degree of a particular node by noting that the average fraction of nodes to which it
2
5
= 51 . This means that < k >= 20 as stated. Looking at the histogram we see that
is connected is given by 2
the highest peak is at 21 =< k > +1. A zoomed in plot of the histogram is also shown. The next part of the
Mathematica notebook has a comparison of the results I obtained from my code with the results I obtained in
MATLAB using the eig function (code for both is attached).