Using a sparse matrix versus numpy array

The scipy sparse matrix package, and similar ones in MATLAB, was based on ideas developed from linear algebra problems, such as solving large sparse linear equations (e.g. finite difference and finite element implementations). So things like matrix product (the dot product for numpy arrays) and equation solvers are well developed. My rough experience is that … Read more

whats the fastest way to find eigenvalues/vectors in python?

**if your matrix is sparse, then instantiate your matrix using a constructor from scipy.sparse then use the analogous eigenvector/eigenvalue methods in spicy.sparse.linalg. From a performance point of view, this has two advantages: your matrix, built from the spicy.sparse constructor, will be smaller in proportion to how sparse it is. the eigenvalue/eigenvector methods for sparse matrices … Read more