Hi, Sparse matrices store only the nonzero elements and their position indices. Using sparse matrices can significantly reduce the amount of memory required for data storage. But surprisingly I noticed that my computer runs out of memory when I try something like >>sparse(zeros(80000)) or a matrix having more elements.In zeros(), as there is no non-zero element, the sparse matrix should not have used any memory in this case at all! I would really appreciate if anyone can elucidate this issue… thanks.
MATLAB: Memory usage in sparse matrix
memorysparse
Related Question
- Squaring a sparse upper-triangular matrix results in more non-zero elements than its original self?
- If I am trying to write a “while” loop for while the bottom row of a matrix has only one non-zero value, what would I write after the “while” to specify only that condition
- How large can a sparse matrix be
Best Answer