[Numpy-discussion] Special matrices with structure?
Thu Feb 23 07:50:36 CST 2012
I was wondering whether it would be easy/possible/reasonable to have
classes for arrays that have special structure in order to use less
memory and speed up some computations?
- symmetric matrix could be stored in almost half the memory required by
a non-symmetric matrix
- diagonal matrix only needs to store the diagonal vector
- Toeplitz matrix only needs to store one or two vectors
- sparse matrix only needs to store non-zero elements (some
implementations in scipy.sparse)
- and so on
If such classes were implemented, it would be nice if they worked with
numpy functions (dot, diag, ...) and operations (+, *, +=, ...) easily.
I believe this has been discussed before but google didn't help a lot..
More information about the NumPy-Discussion