Научная статья на тему 'Constructive heuristics for capacitated vehicle routing problem: a comparative study'

Constructive heuristics for capacitated vehicle routing problem: a comparative study Текст научной статьи по специальности «Математика»

CC BY
171
87
i Надоели баннеры? Вы всегда можете отключить рекламу.
Ключевые слова
ЗАДАЧА МАРШРУТИЗАЦИИ С ОГРАНИЧЕНИЕМ ПО ГРУЗОПОДЪЕМНОСТИ / ЭВРИСТИЧЕСКИЕ МЕТОДЫ КОНСТРУИРОВАНИЯ МАРШРУТА / CAPACITATED VEHICLE ROUTING PROBLEM / CLASSICAL HEURISTICS / CONSTRUCTIVE HEURISTICS

Аннотация научной статьи по математике, автор научной работы — Avdoshin Sergey Mikhailovitch, Beresneva Ekaterina Nikolaevna

Vehicle Routing Problem (VRP) is concerned with the optimal design of routes to be used by a fleet of vehicles to serve a set of customers. In this study we analyze constructive heuristics for a subcase of VRP, where the vehicles have a limited capacity Capacitated Vehicle Routing Problem (CVRP). The problem is NP-hard, therefore heuristic algorithms which provide near-optimal polynomial-time solutions are still actual. The aim of this work is to make a comparison of constructive heuristics as there were not found any such classification. Finally, the leader by a criterion of quality is admitted being a Clarke and Wright Savings heuristic; however, this algorithm cannot find the solution for all used instances. This fact and other ones are discussed in the paper. Our future goal is to make an experimental comparison of the most common and state-of-the-art metaheuristics using well suited constructive heuristic to build a suboptimal solution.

i Надоели баннеры? Вы всегда можете отключить рекламу.
iНе можете найти то, что вам нужно? Попробуйте сервис подбора литературы.
i Надоели баннеры? Вы всегда можете отключить рекламу.

Эвристические методы конструирования маршрута для решения задачи маршрутизации с ограничением по грузоподъемности

Задача маршрутизации одна из широко известных задач комбинаторной оптимизации. Она состоит в отыскании оптимального множества маршрутов для транспортных средств с целью однократного обслуживания определенного множества клиентов. В данной работе исследуется подвид задачи маршрутизации задача маршрутизации с ограничением по грузоподъемности, в которой каждое транспортное средство имеет свою грузоподъемность. Задача является NP-трудной, поэтому вместо точных алгоритмов решения исследуются только эвристические алгоритмы, позволяющие получить приближенные решения за полиномиальное время. Задача работы провести экспериментальное исследование точности решения различных конструктивных эвристик, так как в других источниках не было найдено подобных сравнений. В большинстве случаев, лидером можно признать эвристику «Clarke and Wright Savings», однако существуют отдельные наборы данных, описанные в тексте, на которых лучше работают другие алгоритмы. Также в статье рассмотрены и другие интересные факты. В целом работа проделана с целью дальнейшего использования полученных знаний в экспериментальном исследовании наиболее известных и современных метаэвристических алгоритмов решения задачи маршрутизации с ограничением по грузоподъемности, для которых будут получены предварительные решения на основе выявленных лучших эвристических методов конструирования маршрута.

Текст научной работы на тему «Constructive heuristics for capacitated vehicle routing problem: a comparative study»

DOI: 10.15514/ISPRAS-2019-31(3)-12

Constructive heuristics for Capacitated Vehicle Routing Problem: a comparative study

S.M. Avdoshin, ORCID: 0000-0001-8473-8077 <savdoshin@hse.ru> E.N. Beresneva, ORCID: 0000-0001-6710-2843 <eberesneva@hse.ru> Department of Software Engineering, National Research University Higher School of Economics, 20, Myasnitskaya st., Moscow, 101000 Russia

Abstract. Vehicle Routing Problem (VRP) is concerned with the optimal design of routes to be used by a fleet of vehicles to serve a set of customers. In this study we analyze constructive heuristics for a subcase of VRP, where the vehicles have a limited capacity - Capacitated Vehicle Routing Problem (CVRP). The problem is NP-hard, therefore heuristic algorithms which provide near-optimal polynomial-time solutions are still actual. The aim of this work is to make a comparison of constructive heuristics as there were not found any such classification. Finally, the leader by a criterion of quality is admitted being a Clarke and Wright Savings heuristic; however, this algorithm cannot find the solution for all used instances. This fact and other ones are discussed in the paper. Our future goal is to make an experimental comparison of the most common and state-of-the-art metaheuristics using well suited constructive heuristic to build a suboptimal solution.

Keywords: capacitated vehicle routing problem; classical heuristics; constructive heuristics

For citation: Avdoshin S.M., Beresneva E.N. Constructive heuristics for Capacitated Vehicle Routing Problem: a comparative study. Trudy ISP RAN/Proc. ISP RAS, vol. 31, issue 3, 2019. pp. 145-156. DOI: 10.15514/ISPRAS-2019-31(3)-12

Эвристические методы конструирования маршрута для решения задачи маршрутизации с ограничением по грузоподъемности

СМ. Авдошин, ORCID: 0000-0001-8473-8077 <savdoshin@hse.ru> Е.Н. Береснева, ORCID: 0000-0001-6710-2843 <eberesneva@hse.ru> Департамент программной инженерии, Национальный исследовательский университет "Высшая школа экономики ", 101000, Россия, г. Москва, ул. Мясницкая, д. 20

Аннотация. Задача маршрутизации - одна из широко известных задач комбинаторной оптимизации. Она состоит в отыскании оптимального множества маршрутов для транспортных средств с целью однократного обслуживания определенного множества клиентов. В данной работе исследуется подвид задачи маршрутизации - задача маршрутизации с ограничением по грузоподъемности, в которой каждое транспортное средство имеет свою грузоподъемность. Задача является NP-трудной, поэтому вместо точных алгоритмов решения исследуются только эвристические алгоритмы, позволяющие получить приближенные решения за полиномиальное время. Задача работы - провести экспериментальное исследование точности решения различных конструктивных эвристик, так как в других источниках не было найдено подобных сравнений. В большинстве случаев, лидером можно признать эвристику «Clarke and Wright Savings», однако существуют отдельные наборы данных, описанные в тексте, на которых лучше работают другие алгоритмы. Также в статье рассмотрены и другие интересные факты. В целом работа проделана с целью дальнейшего использования полученных знаний в экспериментальном исследовании наиболее известных и современных

метаэвристических алгоритмов решения задачи маршрутизации с ограничением по грузоподъемности, для которых будут получены предварительные решения на основе выявленных лучших эвристических методов конструирования маршрута.

Ключевые слова: задача маршрутизации с ограничением по грузоподъемности; эвристические методы конструирования маршрута

Для цитирования: Авдошин С.М., Береснева Е.Н. Эвристические методы конструирования маршрута для решения задачи маршрутизации с ограничением по грузоподъемности. Труды ИСП РАН, том 31, вып. 3, 2019 г., стр. 145-156 (на английском языке). DOI: 10.15514/ISPRAS-2019-31(3)-12

1. Introduction

The Vehicle Routing Problem (VRP) is one of the most widely known questions in a class of combinatorial optimization problems. VRP is directly related to Logistics transportation problem and it is meant to be a generalization of the Travelling Salesman Problem (TSP). In contrast to TSP, VRP produces solutions containing some (usually, more than one) looped cycles, which are started and finished at the same point called «depot». The objective is to minimize the cost (time or distance) for all tours. For the identical type of input data, VRP has higher solving complexity than TSP. Both problems belong to the class of NP-hard tasks.

This work is aimed at analysis of VRP subcase, which is called Capacitated Vehicle Routing Problem (Capacitated VRP, CVRP), where the vehicles have a limited capacity. It means that there is a physical restriction on transportation more than determined amount of weight for each machine. Capacitated vehicle routing problems form the core of logistics planning and are hence of great practical and theoretical interest.

There are three types of algorithms that are used to solve any subcase of CVRP.

• Exact algorithms. These algorithms find an optimal solution but take a great time for solving large instances. Such methods include Branch-and-Bound, Branch-and-Cut, cutting plane, column generation, cut and solve, Branch-and-Cut-and-Price, Branch-and-Price, and dynamic programming techniques. It was shown in (Toth & Vigo, Branch-and-Bound algorithms for the capacitated VRP, 2002) that Branch-and-Bound algorithm was able to solve random CVRP instances with up to 300 customers and four vehicles within 1000 CPU seconds in 2002. However, according to the same source some real-world CVRP instances with up to 47 vertices only were successfully solved within 1000 CPU seconds. Current situation does not differ a lot. State-of-the-art exact methods can provide optimal solution for some SCVRP instances with up to 100 nodes, but it takes 30-40 minutes at average (Braekers, Ramaekers, & Nieuwenhuyse, 2016). Due to these restrictions, researchers all over the world concentrate on heuristic methods.

• Classical heuristics. These algorithms build an approximate solution iteratively, but they do not include further improvement stage. Different scientific works reveal that, in comparison to exact methods, classical heuristics work much faster. For example, an instance of 100-150 nodes can be solved up to a few (1-2) seconds (Braekers, Ramaekers, & Nieuwenhuyse, 2016). Heuristics are divided into two groups that include constructive heuristics and improvement heuristics.

• Metaheuristics. Such type of algorithms is also called a framework for building heuristics. According to (Golden, Raghavan, & Wasil, The vehicle routing problem: latest advances and new challenges, 2008), metaheuristics either explore the solution space by moving at each iteration from a solution to another solution in its neighbourhood (metaheuristics based on local search) or evolve a population of solutions which may be combined together in the hope of generating better ones (metaheuristics based on population, natural inspired).

Actuality of research and development of heuristics algorithms for solving VRP is on its top, because such approximate algorithms can produce near-optimal solutions in a polynomial time. It

is especially important in real-world tasks when there are more than one hundred clients in a delivery net. Among the best-known algorithms for CVRP there are metaheuristic proposed by Pisinger and Ropke (Pisinger & Ropke, 2007), Nagata and Braysy (Nagata & Braysy, 2009), and Vidal et al (Vidal, Crainic, Gendreau, Lahrichi, & Rei, 2012).

There are a lot of articles related to CVRP heuristics, but no works were found which compare solution quality, or gap, of classical heuristics using the same data bases. Solution quality is calculated as the percentage of difference in the obtained value of the solution with the optimal (or best-known) solution for the problem.

It is important to analyze classical heuristics since constructive heuristics are usually used in order to provide an initial (suboptimal) solution to improvement methods and to metaheuristics that allow to iteratively get near optimal solutions. So, we will discuss only algorithms from the first group.

The paper is structured as follows. In the second part a mathematical formulation of CVRP is given. In the third section, some notes on a classification of most popular constructive heuristics are provided, including description of chosen algorithms. The fourth part consists of design of experiments and their results. And, finally, in the fifth part conclusions and future goals are given.

2. Classical CVRP mathematical model

In the paper we will use CVRP abbreviation having in mind the mathematical formulation that was described in a previous work of authors (Beresneva & Avdoshin, 2018).

Let a complete weighted oriented graph G=<V,VxV> is given. Let I = {0,1,... ,N}, where N + 1 = | V|. Graph vertices are indexed as ind = V^I, (Vv E V)(Vw EV) v Ф w ^ ind(v) Ф ind(w). Thus, V = {v0,v1, ...,vn] is the set of vertices, here i = ind(vi), i E I. Let v0 be the depot, where vehicles are located, and Vi be the destination points of a delivery, i Ф 0.

The distance between two vertices Vi and Vj is calculated using a distance function c(Vi, Vj). Here a real-valued function c(y) on V xV satisfies Vi,j, g El (Reed & Simon, 1972):

• c(vi,vj) > 0 (non-negativity axiom);

• c(vi,vj) = 0 if and only if vi = Vj (identity axiom);

• c(vi,vj) = c(vj,vi) (symmetry axiom);

• c(vi,vg) < c(vi, Vj) + c(vj, Vg) (triangle inequality axiom).

Each destination point Vi, Vi E I, is associated with a known nonnegative demand, di, to be delivered, and the depot has a fictitious demand d0 = 0. The total demand of the set V с V is

calculated as d(V') = dc.

Let К be a number of available vehicles at the depot v0. Each vehicle has the same capacity - С. Let us assume that every vehicle may perform at most one route and К > Kmin, where Kmin is a minimal number of vehicles needed to serve all the customers due to restriction on С. Clearly, next condition must be fulfilled - (VVi EV) di < С, Vi E I, which prohibits goods transportation that exceed maximum vehicle capacity.

Let introduce V0 = {v0}, where v0 e V. Let us divide V in К +1 sets: S = {V0, V1,..., V^}, each subset, except for V0, represent a set of customers to be served for one vehicle. Sal1 = {S} is a set of all possible partitions of V. Let J = {0,1,..., K} be a set that keeps indexes. Then (Vj E j) \Vjl > 1. There should be no duplicates in any of subsets from S: (Vg E J)(Vj Ej)(g Ф] ^Vg П Vj = 0). Also, all subsets from S must form set V. Thus, V = Uf=0 Vj. In this notation, V0k = V0 U Vk, Vk E J\{0}. It is obvious that d(Vok) < С.

Let introduce Mk = {1,N1 ...,Nk}, Nk = \Vk\, E%=1Nk = N. Then let M0k = {0}uMk. Let Ik = Ufc=1{i \ i = ind(v),Vv e Vk] be a set of vertex indices from Vk. Then I0k = {0} u Ik, Vk e J\{0}.

Let Hk = {pk: M0k ^ I0k\pk(0) = 0 & (Vx e M0k)(Vy e M0k) x^y ^ pk(x) ± pk(y)} be a

set of codes of all possible permutations hk = (vp^yvp^y...,vpk^Nk^) of V0k. These

permutations represent all possible Hamiltonian cycles of graph G0k < y(0k),y(0k) x V(0ky >, Vkej\{0}.

Weight of hk e Hk can be found according to the formula 1:

Nk-1

f(hk) = C (vpk(0),Vpk(Nk)) + ^ C(Vpk(q),Vpk(q+1)) (1)

q=0

Let S' be a set of {V01,V02, ...,V0K}. In this notation the weight of S' is calculated as F(S') =

'Lk=Tj(f(hk), Vkej\{0}.

Overall, the formulation of CVRP is to find:

S0:F(S0)= minF(S) (2)

se sal1 v '

3. Constructive heuristics

In this section the most popular constructive heuristics are described.

3.1 Sequential Insertion algorithm (SI)

Sequential Insertion algorithm (Laporte & Demet, Classical heuristics for the Capacitated VRP, 2002) constructs routes subsequently, one after another.

In the first step, a new tour tourk, k < K, is initialized with a random unrouted node v^i ^ 0, and the depot v0. Thus, a tour (v0, vh v0) is obtained.

In the second step, another unrouted vertex Vj,j ^ 0, is chosen, such that its incorporation in the current tour gives the least increase in a tour length and demand of a potential node Vj does not exceed vehicle capacity. So, the next two formulae must be hold:

• argmin Va e tourk, c(va, Vj) + c(vj, va+1) - c(va, v^y,

va+1 e tourk, Vj g tourk

• Dtourk + dj <C, where Dtourk is a total demand of current tourk.

If all conditions hold then this unrouted vertex Vj,j ± 0 is inserted in a tour tourk between va and

Va+1.

The second step is repeated until no more unrouted vertex Vj,j ^ 0, can be feasibly inserted. In this case a new tour tourk, k < K, is initialized, and the procedure starts from the first step.

3.2 Improved Parallel Insertion algorithm

Parallel Insertion Improved algorithm (Laporte, Nobert, & Desrochers, Optimal routing under capacity and distance restrictions, 1985) builds routes simultaneously. This method is a modification of Sequential Insertion algorithm.

In the first step, the minimum number Kmin of feasible routes is defined as Kmin = dt /C. All these routes tourk e Tours are initialized with Kmin different closest to v0 unrouted nodes Vi, i ^ 0. Thus, Kmin tours (v0, v0 v0) are obtained.

In the second step, a random unrouted node Vj,j ^ 0, is inserted in some route tourk at its best insertion position. The next two conditions must be hold - incorporation of Vj in this tour gives the

least increase in a tour length among all other tours and demand of a potential node Vj does not exceed vehicle capacity. So:

• argmin vaEtourk, c(Va, Vj) + c(Vj, Va + 1) - C(Va, Va-цУ;

va+1Etourk, Vj&tourk

• Dtourk + dj < С, where Dtourk is a total demand of current tourk.

If all conditions hold then this unrouted vertex Vj,j Ф 0 is inserted in a tour tourk between Va and

Va+1.

The second step is repeated until no more unrouted vertex Vj,j Ф 0, can be feasibly inserted in some route tourk. In this case a new tour tourk, k < K, is initialized as (v0, Vj, v0) and adds to set of all tours Tours, and the procedure continues.

3.3 Nearest Neighbor heuristic (NN)

Nearest Neighbor heuristic constructs routes subsequently, one after another, in a greedy way. In the first step, an unrouted node Vi, i Ф 0, which is closest to the depot v0, is chosen. A new open tour tourk, k < K, is initialized with Vi and v0. Thus, a tour (v0, Vi) is obtained. In the second step, another unrouted vertex Vj,j Ф 0, is chosen, which is the nearest to the last added vertex and a demand of a potential node Vj does not exceed vehicle capacity. So, the next two formulae must be hold:

• argminv. E tourk, Vj g tourk c(.Vi, Vj);

• Dtourk + dj < С, where Dtourk is a total demand of current tourk.

If all conditions hold then this unrouted vertex Vj is added in the end of tourk after Vi, and since that time it turns to be the last added vertex.

The second step is repeated until no more unrouted vertex Vj,j Ф 0, can be feasibly inserted. In this case a new tour tourk, k < K, is initialized, and the procedure starts from the first step.

3.4 Clarke and Wright Savings heuristic (CWS)

In the first step, all vertices ViEV,i^0, must form IV - 11 routes. Thus, IV - 11 tours (v0, Vi, v0) are obtained.

In the second step, VVi E V,VVj E V,i Ф 0,j Ф 0,i Ф j, saving s(Vi,Vj) is calculated as s(Vi, Vj) = c(Vi,V0) + c(v0, Vj) - с(Vi, Vj). All savings are put in a list of S, S must be sorted in a non-increasing order.

In the third step, the first unused saving in a list is taken. Then, existence of two routes tourx and toury, x Ф y, having the next conditions, is checked:

• there is an edge (Vi, v0) in route x and edge (v0, Vj) in tour toury;

• Dtourx + Dtoury < С.

If there are such routes then tourx and toury are combined by removing edges (Vi, v0), (v0, Vj) and introducing edge (Vi,Vj). After that, despite of ability or absence these routes, the current saving is skipped and the next one in the list is checked. The last step works until K tours are left.

3.5 Variant of Clarke and Wright Savings heuristic (CWS_2)

Classical variant of Clarke and Wright Savings algorithm forms good tours in the first part of its work mostly. However, it was noticed that it tends to produce less competitive tours towards the

end because of periphery nodes addition. Thus, Yellow (Yellow, 1970) and Gaskell (Gaskell, 1967) suggested improved form of savings calculation. It is s(yi,Vj) = c(vi,v0) + c(v0,vj) -Xc(v0 Vj). Here X is a parameter which responds for measuring the distance between the vertices to be joint. In one report (Golden, Magnanti, & Nguyen, Implementing vehicle routing algorithms, 1977) it was mentioned that the best value of X is 0.4.

3.6 Subgroup of Cluster-First-Route-Second heuristics

Subgroup of Cluster-First-Route-Second heuristics belongs to two-phase methods, which are based on the decomposition of the CVRP solution process into two separate stages - clustering and routing. In the clustering stage, a partition of the customers into routes is made, and in the routing stage, the sequence of the customers on each subset is obtained.

In Cluster-First-Route-Second methods, nodes are first partitioned into different subsets called clusters and then routes are determined by sequencing the customers within each subset.

3.6.1 Sweep

This Cluster-First-Route-Second method can be applied only for planar instances (Laporte & Demet, Classical heuristics for the Capacitated VRP, 2002).

Clustering stage

Let us define vt eV as vt = (xt; yt), where xt and yt are the Cartesian coordinates of point vt. In the first step, new normalized vertices v[ = (x'-y^) = (xi - x0;yi -y0) are introduced, where the depot v0' has new Cartesian coordinates (0; 0), Vi e \7\.

Let vL' = (9i,ri) be a vertex with polar coordinate of vt', where rt = x'2 + y'2 and 9t is calculated using formula 3:

arctg (—),xt > 0,yt > 0

9, =

arctg (—) + 2n,Xi > 0,yi < 0

arctg (—) + n,Xi < 0 (3)

n

iНе можете найти то, что вам нужно? Попробуйте сервис подбора литературы.

-,Xi = 0,Vi > 0 3n

^ = 0,yi < 0

In the second step, a list V of all vL' = (9i,rt),Vi e \V\,i ^ 0, is calculated and is sorted in increasing order by parameter fy.

In the next step, a new cluster is initialized with {v0} and maximum number of first L vertices from V, such that YJi-0> d-i < C. Parameter L is not a constant, it can be other for different clusters depending on weights of demands and total capacity. Then these used vertices are removed from V, and the procedure is repeated until 7 = 0.

Routing stage

At this stage for each cluster TSP Cheapest Insertion heuristic is applied which forms a cycle. 3.6.2 Fisher and Jaikumar algorithm

In contrast to Sweep algorithm, this Cluster-First-Route-Second method can be applied not only for planar instances. Instead of using a geometric method to form the clusters, it solves a Generalized Assignment Problem (GAP).

Clustering stage

In the first step Vk = 1..K a vertex vseed(k) £ V\{vo} is chosen. These K vertices form K clusters. In the second step the cost cos of allocating each node vi £ V,i ^ 0, to each cluster k is calculated as cos= c(v0, vd + c(vh Vseed(k)) - c(Vseed(k), Vo).

In the third step the algorithm solves GAP with costf., di and C, which determines a minimum cost assignment of items to a given set of bins of capacity C. The GAP can be solved using either exact or heuristic techniques.

Routing stage

The final routes are determined by solving a TSP on each defined cluster.

According to this work (Sultana, Akhand, & Rahman, 2017), this algorithm gives way to the algorithms described above and provides solutions with more solution quality. That is why it will not be considered in later comparison study as it was already done.

3.7 Subgroup of Route-First-Cluster-Second heuristics

Subgroup of Route-First-Cluster-Second heuristics also belongs to two-phase methods. However, in contrast to Cluster-First-Route-Second methods, these constructive heuristics at first solve TSP for all nodes and only then break built cycle to K routes. Unfortunately, many studies showed than these heuristics are applicable only if there is no constraint on the number of vehicles. In addition, they are not competitive with other constructive heuristics in general (Laporte & Demet, Classical heuristics for the Capacitated VRP, 2002).

4. Experiments and results

All algorithms are implemented as sequential algorithms in C++. The computational testing of the solution methods for CVRP has been carried out by considering eight sets of test instances from the next well-known database (Xavier). Total number of instances in sets A, B, E, F, G, M, P, X is 211. All instances inside one set have its own characteristics and a way of generation: cluster-based / uniform / geometric distribution of clients, real-world / imitative cases etc. The integer Euclidean metric is used for all instances. The naming scheme and data format for each instance is described here (Heidelberg University). Shortly, the first letter in names shows the name of used set, the figure after letter 'n' shows the number of nodes and the figure which stands after letter 'k' presents the number of vehicles.

Experiment starts with the choice of a constructive heuristic H from the set {SI, FI, NN, CWS, CWS_2, Sweep}. After that one dataset D is selected from the list of all benchmark datasets. Then an instance file F from the chosen dataset D is taken as input for the algorithm H and the heuristic is executed (only 1 time because all these algorithms do not use random generations, so all obtained solutions are the same). After that we report solution quality e(H, F) found for the algorithm H on the test F. Solution quality (or percent above best-known, or gap) is calculated using formula 4 (Toth & Vigo, An overview of vehicle routing problems, 2002):

F(S0) - Fopt(S)

100%, (4)

FoPt(S)

where F(S0) is a length of obtained solution and Fopt(S) is a length of optimal solution or best-known one. And finally, among all e(H, F) from one dataset sample mean X£(H, D) = EifJi e(H, F) is calculated which shows average gap for the algorithm H on the dataset D, where \ D \ is a number of input files in dataset D.

The plan of experiments on constructive heuristics described in Fig. 1. Input: constructive heuristics, datasets

1: foreach constructive heuristic H

2: foreach dataset D from datasets

3: foreach instance file F from D

4: solution = run H on F

5: calculate s(H, F)

6: calculate XE(H, D) // average gap on dataset

Fig.1. Plan of experiment on constructive heuristics

It should be mentioned that each algorithm is subsequently launched on all 211 instances from 8 datasets, so no input file is missed.

A criterion of running time was not considered because all instances were solved in a time which does not exceed 1 second. It is thought to be insignificant in comparison with time-consuming metaheuristic work.

Fig. 2, 3 and 4 represent the results of experiments conducted over algorithms using sets B, P and G of widely different types. The horizontal axis represents the name of instance data. The vertical axis shows the solution quality.

Solution quality of constructive heuristics (set B), %

140% 120% 100% 80% 60% 40% 20%

J? J? J? J3 J> ^ J? Jfr. J> J> 3 J* .?> a,v ^ #

<b <b v 'b <b % % V <t> V <y v ^ <b' « ^ ^

—Sequential Insertion—Parallel insertion —Nearest Neighbour —CWS_2 —CWS —Sweep

Fig. 2. Solution quality of constructive heuristics, set B

Solution quality of constructive heuristics (set P), %

120% 100% 80% 60% 40% 20% 0%

^ ^ ^ Л ^ Л ф Л ^ A ^ Л А Л Л ^ ^ ^

Ч Ч "Ч Ч Ч Ч Ч Ч Ч ^ S Ч ^ Ч Ч Ч (¡-^

—Sequential Insertion—Parallel insertion —Nearest Neighbour —CWS_2 CWS —Sweep

Fig. 3. Solution quality of constructive heuristics, set P

Solution quality of constructive heuristics (set G), %

200% s^ \ \

150% \

100% \

50%

—Sequential Insertion —Parallel insertion —Nearest Neighbour —CWS_2 CWS —Sweep

Fig. 4. Solution quality of constructive heuristics, set G.

Average gaps X£(H, D) of each algorithm on different data sets are presented in Table 1 and fig. 5. These general figures can show an approximate overall effectiveness of algorithms. On the basis of Table 1, all fig. 2, 3, 4, 5 and other results which cannot be shown here because of their large volume, it can be easily seen that CWS algorithm (its column is made bold in the table) is a leader for all input files, except some instances from dataset G. Its average gap varies from 3,4% till 11,0%. The closest competitor is its variant CWS_2, which has average solution quality in a range [9,8%; 20,6%]. CWS_2 algorithm is able to construct the best solutions only for some instances in set B. In all other cases this algorithm nearly always takes second place and goes behind classical CWS.

Table 1. Average gaps of all heuristics for every set, %.

Average gap X£ (H, D) in the dataset Constructive heuristic

SI PI NN CWS CWS 2 Sweep

Set (its size) A (26) 68,7% 33,2% 39,7% 5,0% 12,7% 40,2%

B (23) 82,3% 34,0% 41,2% 4,3% 9,8% 31,7%

E (11) 70,4% 30,0% 41,5% 6,4% 17,5% 36,4%

F (3) 42,5% 48,5% 74,6% 4,4% 20,6% 71,9%

G (20) 24,8% 15,6% 16,3% 11,0% 18,4% 142,4%

M (4) 83,0% 35,5% 44,6% 3,4% 12,0% 89,2%

P (24) 66,0% 25,6% 32,2% 6,9% 11,3% 31,4%

X (100) 99,7% 23,3% 27,4% 5,9% 11,9% 82,9%

Table 2. Percentage of unsolved instances for every set, %.

Percentage of unsolved Constructive heuristic

instances in the set SI PI NN CWS CWS 2 Sweep

A (26) 0% 0% 0% 0% 0% 69,0%

B (23) 0% 0% 0% 0% 0% 50,0%

и N E (11) 0% 0% 0% 0% 0% 43,5%

F (3) 0% 0% 0% 0% 0% 63,6%

G (20) 0% 0% 0% 0% 0% 66,7%

m M (4) 0% 0% 0% 0% 0% 90,0%

P (24) 0% 0% 0% 0% 0% 50,0%

X (100) 0% 0% 0% 0% 0% 58,3%

There is only one algorithm that have a problem with finding an answer to the given problems - it is Sweep. This heuristic is not able to construct a set of routes without exceeding the number of vehicles for some input files. All the others coped with the task - they are NN, SI, PI, CWS and CWS_2. Table 2 shows the percentage and the number of unsolved instances for all sets. In average, Sweep algorithm cannot solve the instance without over limit in more than 50% cases. It can be explained by the fact that the next vertex to be added is chosen by criteria of distance (polar angle, for real) but not the capacity.

Average gap of constructive heuristics in the datasets, %

160% 140% 120% 100% 80% 60% 40%

set A (26) set B (23) set E (11) set F (3) set G (20) set M (4) set P (24) set X (100) —Sequential Insertion—Parallel insertion —Nearest Neighbour —CWS_2 —CWS —Sweep

Fig. 5. Average gap of constructive heuristics in the datasets

Golden_5 (П=200, Q=90Q)

—•— Route 1

-9- Route 2

--»- Route 3

-*- Route 4

—•— Route 5

-300

-150

0

150

300

Fig. 6. Solution for instance G-n200-k5

It was mentioned earlier that CWS is not a leader for some instances from dataset G. There are 8 instances when NN finds the best solutions but not CWS (fig. 4). This interesting change of the leader is connected with the type of customers' distribution - these instances have a form of rays going from the center. If we look at fig. 6, where a solution for the instance is presented, we can see that the idea of nearest neighbor works here the best way.

5. Conclusions

Overall, the next recommendation should be given to the problem which has described variant of mathematical model of CVRP. In general, for all types of clients' distribution the best algorithm to be applied is Clarke and Wright Savings, however, in case of having input data in form of concentric rays (like in fig. 6) it is better to use Nearest Neighbor algorithm. Also, a few instances were solved best of all by Clarke and Wright Savings 2 algorithm, so it is important to have this algorithm in mind, however the difference between it and CWS is not very significant (no more than 1%). One more conclusion is that it is unreasonable to use Sweep heuristic as it is not able to construct a set of routes without exceeding the number of vehicles for more than 50% of input files. Finally, for our research it means that for all instances, except those 8 from set G, CWS heuristic will be used as initial algorithm for metaheuristic, otherwise - we will apply NN.

References

[1] P. Toth and D. Vigo, "Branch-and-Bound algorithms for the capacitated VRP," in The Vehicle Routing Problem, Philadelphia, SIAM, 2002, pp. 29-51.

[2] K. Braekers, K. Ramaekers, and I. Nieuwenhuyse. The vehicle routing problem: State of the art classification and review. Computers & Industrial Engineering, vol. 99, 2016, pp. 300-313.

[3] B. Golden, S. Raghavan and E. Wasil. The vehicle routing problem: latest advances and new challenges. New York: Springer, 2008.

[4] P. Pisinger and S. Ropke. A general heuristic for vehicle routing problems. Computers & Operations Research, vol. 34, no. 8, 2007, pp. 2403-2435.

iНе можете найти то, что вам нужно? Попробуйте сервис подбора литературы.

[5] Y. Nagata and O. Braysy. Edge assembly-based memetic algorithm for the capacitated vehicle routing problem. Networks, vol. 54, no. 4, 2009, pp. 205-215.

[6] T. Vidal, T. Crainic, M. Gendreau, N. Lahrichi, and W. Rei. A hybrid genetic algorithm for multi-depot and periodic vehicle routing problems. Operations Research, vol. 60, no. 3, 2012, pp. 611-624.

[7] E. Beresneva and S. Avdoshin. Analysis of mathematical formulations of Capacitated Vehicle Routing Problem and methods for their solution. Trudy ISP RAN/Proc. ISP RAS, vol. 30, no. 3, 2018, pp. 233250. DOI: 10.15514/ISPRAS-2018-30(3)-17.

[8] M. Reed and B. Simon. Methods of modern mathematical physics. London: Academic Press, 1972.

[9] G. Laporte and F. Demet. Classical heuristics for the Capacitated VRP. In The Vehicle Routing Problem, SIAM, 2002, pp. 109-128.

[10] G. Laporte, Y. Nobert, and M. Desrochers. Optimal routing under capacity and distance restrictions. Operations Research, vol. 33, no. 5, 1985, pp. 1050-1073.

[11] P. Yellow. A computational modification to the savings method of vehicle scheduling, Operational Research Quarterly, no. 21, 1970, pp. 281-283.

[12] T. Gaskell. Bases for vehicle fleet scheduling. Operational Research Quarterly, no. 18, 1967, pp. 281295.

[13] B. Golden, T. Magnanti, and H. Nguyen. Implementing vehicle routing algorithms. Networks, no. 7, 1977, pp. 113-148.

[14] M. L. Fisher and R. Jaikumar. A generalized assignment heuristic for vehicle routing. Networks, vol. 11, no. 3, 1981, pp. 109-124.

[15] T. Sultana, M. Akhand and M. Rahman. A variant Fisher and Jaikuamr algorithm to solve capacitated vehicle routing problem. In Proc. of the 8th International Conference on Information Technology (ICIT), 2017, pp. 710-716.

[16] I. Xavier. CVRPLIB. [Online]. Available: http://vrp.atd-lab.inf.puc-rio.br/index.php/en/. [Accessed 09 07 2019].

[17] Heidelberg University. TSPLIB. [Online]. Available: https://www.iwr.uni-heidelberg.de/groups/comopt/software/TSPLIB95/. [Accessed 09 07 2019].

[18] P. Toth and D. Vigo. An overview of vehicle routing problems. In The Vehicle Routing Problem, SIAM, 2002.

Информация об авторах / Information about authors

Екатерина Николаевна БЕРЕСНЕВА - с 2017 года преподаватель департамента программной инженерии НИУ ВШЭ, с 2019 года - аспирант НИУ ВШЭ. Профессиональные интересы - дискретная математика, задача маршрутизации транспорта, задача коммивояжера.

Ekaterina BERESNEVA - lecturer at School of Software Engineering, Faculty of Computer Science, National Research University Higher School of Economics since 2017. Her research interests include discrete mathematics, the vehicle routing problem and the travelling salesman problem.

Сергей Михайлович АВДОШИН - профессор, руководитель департамента программной инженерии факультета компьютерных наук НИУ ВШЭ с 2005 года. Сфера научных интересов: разработка и анализ компьютерных алгоритмов, имитация и моделирование, параллельные и распределенные процессы, теневой интернет, технология блокчейн.

Sergey AVDOSHIN - Professor, Head of School of Software Engineering in National Research University Higher School of Economics since 2005. Research interests are design and analysis of computer algorithms, simulation and modeling, parallel and distributed processing, deep Web, blockchain technology.

i Надоели баннеры? Вы всегда можете отключить рекламу.