Finished sparse_matrix_factory