You are now following this Submission
- You will see updates in your followed content feed
- You may receive emails, depending on your communication preferences
This utility can be useful when you need to update a sparse matrix values
without changing its sparsity pattern.
Since MATLAB uses CSC (Compressed Sparse Column) format for sparse matries, the non-zeroes are stored in an array, which can be safely overwritten in order to update the matrix, while preserving the sparsity pattern.
This can be done much faster than re-allocating the whole sparse matrix again, when only its values change.
The source code can be found at GitHub:
https://github.com/romanz/thesis/tree/master/utils/spinit
Cite As
Roman (2026). SPINIT (https://www.mathworks.com/matlabcentral/fileexchange/30293-spinit), MATLAB Central File Exchange. Retrieved .
General Information
- Version 1.3.0.0 (3.69 KB)
MATLAB Release Compatibility
- Compatible with any release
Platform Compatibility
- Windows
- macOS
- Linux
