add row class for sparse representation of A