| IBM ILOG Dispatcher User's Manual > The Basics > Multiple Tours per Vehicle > Model > Declare the RoutingModel class |
Declare the RoutingModel class |
INDEX
PREVIOUS
NEXT
|
The code for the declaration of the class RoutingModel is provided for you:
There are only a few differences between the RoutingModel class used in a standard VRP and the RoutingModel class used in this problem.
The dimensions in this problem are weight and distance. As in Chapter 4, Minimizing the Number of Vehicles, you use an instance of the class IloDispatcherGraph to compute the shortest paths between nodes for each vehicle. It is this shortest path that is used to create the dimension _distance in this model. See "Define the addDimensions function".
You create _unorderedVisitArray, an instance of IloVisitArray that will be used in the submodel to generate a first solution.
The function getGraph is used to access the road network graph in the submodel. The member function getUnorderedVisitArray is used in the submodel to access the array of unordered visits.
| © Copyright IBM Corp. 1987, 2009. Legal terms. | PREVIOUS NEXT |