Best way to store a sparse matrix in .NET

后端 未结 6 933
眼角桃花
眼角桃花 2021-02-05 22:07

We have an application that stores a sparse matrix. This matrix has entries that mostly exist around the main diagonal of the matrix. I was wondering if there were any efficie

6条回答
  •  梦如初夏
    2021-02-05 22:22

    Here's a list of general data structure schemas. Each has its advantages and disadvantages, and are suitable for slightly different kinds of problems where sparse matrices arise. You'd probably want to implement them on top of existing data structures, such as List<> and Dictionary<>.

提交回复
热议问题