Nov 13, 2014 at 7:00 PM
Edited Nov 13, 2014 at 7:59 PM

Hallo all,
I looked into Math.NET for usage in my Research. More specific I am looking for a library that can compute the Eigenvectors and Values of medium (500+) matrices. I need this for graph matching and graph drawing. My background is Architecture with a little bit
of knowledge in programming and math but unfortunatly not enough to understand all the problems of the implementation of algorithms calculating eigenvalues/eigenvectors. The aim is to use graphMatching within the field of Architecture for the generation of
layouts.
I have had a quick look into the .evd() function and it works better than other libraries I have looked at. But a few questions have poped up about the outputs:
 Laplacian Matrix
All publications read so far on Laplacian matrices asure me that the resulting eigenvalues should be equal or larger than 0 for a symetric matrix. (e.g.
http://en.wikipedia.org/wiki/Laplacian_matrix)
However with a spares matrix of 553*553 enteries the smallest Eigenvalues is given with 1.
 Different outputs for the same Matrix
If have checked the outputs for the following laplacianMatrix with different libraries (MATH.net and Wolfram Alpha):
[ {4,1,1,1,1},{1,4,1,1,1},{1,1,4,1,1},{1,1,1,4,1},{1,1,1,1,4}]
This is the Laplacian Matrix of the K5 Graph.
This will output the Eigenvalues of 0, 5, 5, 5, 5.
The Eigenvector for the Eigenvalue 0 will be the same in both cases but the other Eigenvalues do not match at all.
What did I miss? + as fare as I understand Eigenvalues / Eigenvectors are aproximated in some cases how can I handle the error.
Thx for any help,
Best Richard
Edit: I don't know what is happening exactly but it seams that the Eigenvalues of 1 of the Laplacian should actually be 0 beacaus when imputing a distjoined graph (two connected components, undirected graph) than I get two 1 values. However two 0 values should
be outputed, so what to do?


Coordinator
Nov 14, 2014 at 9:19 AM

Thanks, I'll have to look into this in more detail. Are you using the managed or the MKL provider in Math.NET?
Thanks,
Christoph


Nov 14, 2014 at 7:25 PM
Edited Nov 14, 2014 at 7:45 PM

Hallo Christoph,
How can I tell? I have downloaded the "RECOMMENDED DOWNLOAD" and used the .net 3.5 Version and used the MathNet.Numerics.dll wih the following code:
M = M.Build.Dense(tmpG.dimension, tmpg.dimension)
' this is just parsing from another Matrix class I have been using into the MATh.NEt matrix class
For i As Integer = 0 To tmpG.dimension  1
M.SetRow(i, tmpG.Matrix.Row(i).ToArray)
Next
tmpEVD = M.Evd(Symmetricity.Symmetric)
print(M.toString())
print(tmpEVD.Eigenvectors.toString())
print(tmpEVD.D.ToString())
I can also post the matrix as *.csv if that helps.
However can you tell me which Algorithmen is used within Math.net to compute the eigenvalues to get a better understanding of which problems or errors might occure, since I came to understand that especially if the Eigenvalues of the matrix are not unique the
resulting eigenvectors might be wrong as well...
To add to my EDIT:
It seams that the Eigenvectors associated with the Eigenvalues of 1 (which schould be 0) are correct.
thanks
Richard
EDIT: I have to appologice Issue two I have resoved there was an error in my matrix. However the other questions are still there.

