simplified code of GetListOfHomalgMatrixAsString etc.