updates the grain size