@Override public NetPlan readDemandSetFromFile(File file) { DoubleMatrix2D trafficMatrix = DoubleUtils.read2DMatrixFromFile(file); NetPlan netPlan = new NetPlan(); netPlan.setTrafficMatrix(trafficMatrix , RoutingType.SOURCE_ROUTING); return netPlan; }
netPlan.setTrafficMatrix(trafficMatrix , RoutingType.SOURCE_ROUTING);
setTrafficMatrix(TrafficMatrixGenerationModels.normalizationPattern_totalTraffic(getTrafficMatrix(matrixId), totalTraffic), matrixId); setTrafficMatrix(option == 2 ? TrafficMatrixGenerationModels.normalizationPattern_outgoingTraffic(getTrafficMatrix(matrixId), newValue) : TrafficMatrixGenerationModels.normalizationPattern_incomingTraffic(getTrafficMatrix(matrixId), newValue), matrixId); aux.setTrafficMatrix(trafficMatrix , RoutingType.SOURCE_ROUTING); setTrafficMatrix(aux.getMatrixNode2NodeOfferedTraffic(), matrixId);
netPlan.setTrafficMatrix(trafficMatrices[tmId] , RoutingType.SOURCE_ROUTING); netPlan.setVectorDemandOfferedTraffic(TrafficMatrixGenerationModels.normalizeTraffic_networkCapacity(netPlan)); trafficMatrices[tmId] = netPlan.getMatrixNode2NodeOfferedTraffic(); netPlan.setTrafficMatrix(trafficMatrices[tmId] , RoutingType.SOURCE_ROUTING); netPlan.setVectorDemandOfferedTraffic(TrafficMatrixGenerationModels.normalizeTraffic_linkCapacity_xde(netPlan, solverName, solverLibraryName)); trafficMatrices[tmId] = netPlan.getMatrixNode2NodeOfferedTraffic(); NetPlan aux = new NetPlan(); aux.setTrafficMatrix(trafficMatrices[tmId] , RoutingType.SOURCE_ROUTING); outputDemandSets.add(aux);
netPlan.setTrafficMatrix(DoubleFactory2D.dense.make (N,N,1.0) , RoutingType.SOURCE_ROUTING); // just to create the demands
netPlan.setTrafficMatrix(DoubleFactory2D.dense.make (N,N,1.0) , RoutingType.SOURCE_ROUTING); // just to create the demands
netPlan.setTrafficMatrix(DoubleFactory2D.dense.make (N,N,1.0) , RoutingType.SOURCE_ROUTING); // just to create the demands