Copyright | 2014 Tomáš Musil |
---|---|
License | BSD-3 |
Stability | experimental |
Portability | portable |
Safe Haskell | Safe |
Language | Haskell2010 |
VRP
Description
Vehicle Routing Problem.
- type Size = Int
- type Vertex = Int
- type Path = [Vertex]
- type Distance = Double
- type Coordinate = Double
- type Capacity = Demand
- type Demand = Int
- type Solution = (Score, (State, [Path]))
- type State = Map Int Vertex
- type Score = Double
- type DistF = (Vertex, Vertex) -> Distance
- type DemF = Vertex -> Demand
- type DArray = UArray Vertex Demand
- readProblemF :: FilePath -> IO (Size, Size, Capacity, DistF, DemF)
- readProblemM :: FilePath -> IO (Size, Size, DistArray, PenaltyF)
- neighbour :: (State -> (Score, [Path])) -> (Size, Size) -> Solution -> Rand StdGen Solution
- solve :: DistF -> DemF -> Capacity -> State -> (Score, [Path])
- allNeigh :: (State -> (Score, [Path])) -> Solution -> [Solution]