A partitioning algorithm for the multicommodity network flow problem