Changeset 14649 for branches/OptimizationNetworks/HeuristicLab.Networks.IntegratedOptimization.LocationRouting/3.3/LrpOrchestratorNode1.cs
- Timestamp:
- 02/07/17 10:43:13 (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/OptimizationNetworks/HeuristicLab.Networks.IntegratedOptimization.LocationRouting/3.3/LrpOrchestratorNode1.cs
r14628 r14649 97 97 var vrp = (VehicleRoutingProblem)VrpParameter.Value.Clone(); 98 98 var vrpInstance = (CVRPProblemInstance)vrp.ProblemInstance; 99 var coordinates = LrpUtils.GetVrpCoordinates(depotCoordinates, customerCoordinates, depotIdx, customers);99 var coordinates = LrpUtils.GetVrpCoordinates(depotCoordinates, customerCoordinates, new[] { depotIdx }, customers); 100 100 var distances = LrpUtils.GetVrpDistances(coordinates, distanceType); 101 101 vrpInstance.Coordinates = new DoubleMatrix(coordinates); … … 111 111 112 112 var vrpResults = (ResultCollection)vrpMsg["Results"]; 113 var bestVrpSolution = (VRPSolution)vrpResults["Best valid VRP Solution"].Value.Clone(); 113 IResult bestVrpSolutionResult; 114 if (!vrpResults.TryGetValue("Best valid VRP Solution", out bestVrpSolutionResult) 115 && !vrpResults.TryGetValue("Best VRP Solution", out bestVrpSolutionResult)) { 116 // no best solution found ... throw? 117 } 118 var bestVrpSolution = (VRPSolution)bestVrpSolutionResult.Value.Clone(); 114 119 vrpSolutions.Add(new Result("Depot " + depot.Key, bestVrpSolution)); 115 120 }
Note: See TracChangeset
for help on using the changeset viewer.