Three grouping modes of battery cells