SA_VRP: To find near optimal solutions using Simmulated Annealing.

Description Usage Arguments Examples

Description

To find near optimal solutions using Simmulated Annealing.

Usage

1
2
SA_VRP(fitness, vc, demand, locations, method = "euclidean", popSize = NULL,
  nrun = 25)

Arguments

fitness

Fitness function

vc

Vehicle capacity

demand

Demand at each node

method

– Metric to calculate distnace between nodes. Feasible methods for X-Y co-ordinates c("euclidean", "maximum", "manhattan", "canberra", "binary" or "minkowski"); Feasible methods for Long-Lat c(distCosine, distHaversine). Default: "euclidean". Note: Please make sure that, method should be character for X-Y co-ordinates and not for Long-Lat.

popSize

Population Size

nrun

Number of runs

location

Location of each node

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
popSize <- 100
num_nodes <- 31
fitness <- fitness
vc <- 100
Demand <- An32k5demand
Locations <- An32k5locations
DMat <- DistMat(locations)
row.names(DMat) <- c(0, 1:(nrow(demand)-1))
colnames(DMat) <- c(0, 1:(nrow(demand)-1))
SA_VRP(fitness, vc, demand, locations, popSize = 100)
SA_VRP(fitness, vc, demand, locations)

kavetinaveen/HeuristicsVRP documentation built on May 20, 2019, 7:53 a.m.