Visiting all Sparse Matrix entries in org.apache.commons.math.linear

I see 2 sparse matrix implementations in this package.

  • OpenMapRealMatrix
  • SparseFieldMatrix

Both documents are documented as “Implementing a Sparse Matrix Based on an Open Address Card”.

Do you know what are the differences between them? also, that the best way to quickly iterate over all records (which means iterating over nonzero elements).

Thank!

+3
source share
1 answer

SparseFieldMatrix is ​​just an interface implemented by the OpenMapRealMatrix class.

. walkInOptimizedOrder , , . , . . , .

, , , . , , , .

+1

Source: https://habr.com/ru/post/1759995/


All Articles