The Matrix_generic_sparse class derives from
Matrix_sparse, and defines functionality
for sparse matrices over any base ring. A generic sparse matrix is
represented using a dictionary whose keys are pairs of integers \((i,j)\) and
values in the base ring. The values of the dictionary must never be zero.

The datastructure can potentially be optimized. Firstly, as noticed in
trac ticket #17663, we lose time in using 2-tuples to store indices.
Secondly, there is no fast way to access non-zero elements in a given
row/column.