Modelling dynamic group limits to reduce grid congestion