shunting

sorting railway vehicles into complete trains (or the reverse)