added allRowSums method and fixed columnSum method