title: Matrix Library for .NET
body: <p>I'm looking for a good (well-tested, fully-featured, and ideally with a nice interface) matrix library for .NET/C#. My main requirements here are only that it should be free (I don't particularly care whether it's open-source in this case) and preferably support <a href="http://en.wikipedia.org/wiki/Sparse_matrix" rel="noreferrer">sparse matrix</a> operations. The obligatory requirements are all the basic operations (e.g. multiplication, transposition, inversion) as well as finding eigenvalues &amp; eigenvectors. Implementation of a numerical rather than/as well as analytical methods for discovery of eigenvalues, particularly the <a href="http://en.wikipedia.org/wiki/Lanczos_algorithm" rel="noreferrer">Lanczos algorithm</a> for sparse matrices, would be highly preferable since the matrices I'm going to be dealing with are very large (lengths of 10,000 upwards) as well as square, and also reasonably sparse. Saying that, I could be asking for a bit much there, so any suggestions for a reasonably complete matrix library would be great.</p>
  
  <p>Now I'm aware that Python has one or two useful libraries for such tasks (namely <a href="http://numpy.scipy.org/" rel="noreferrer">NumPy</a>/<a href="http://www.scipy.org/" rel="noreferrer">SciPy</a>), but .NET unfortunately seems to be lacking in the area.</p>
  
  <p>A bit of searching turned up the following libraries for .NET, which I could potentially used:</p>
  
  <ul>
  <li>Lutz Roeder's <a href="https://github.com/lutzroeder/Mapack" rel="noreferrer">Mapack</a></li>
  <li><a href="http://www.codeproject.com/KB/recipes/psdotnetmatrix.aspx" rel="noreferrer">DotNetMatrix</a> (CodeProject)</li>
  <li><a href="http://www.codeproject.com/KB/cs/CSML.aspx" rel="noreferrer">C# Matrix Library</a> (CodeProject)</li>
  </ul>
  
  <p>However, since I have had no experience whatsoever using any of these libraries or others (and not exactly enough time to check each of them out properly in any case), I would very much appreciate if anyone here could discuss their recommendations regarding the various libraries, their pros/cons particularly with regards to suitability for my uses, and their general experiences with them.</p>
  
  <p>Resorting to MatLab is always an option, but not a preferred one, as it would be much more convenient if I could integrate the matrix math directly with my program.</p>