1 Introduction

The dynamic development of the Internet and information technology (IT) in the last several years has caused a transition to the next stage of society computerization. Many IT systems are used in the daily lives of inhabitants and the functioning of companies and institutions. Currently, the rapid development of mobile application breakthroughs in the functioning of household devices, data collection, processing devices, and various sensors and controllers has been observed. This phenomenon is referred to as the Internet of Things (IoT) (Vermesan and Friess 2013). The main idea behind the IoT is the automation of various processes and activities to improve the handling of devices and facilities used by inhabitants working remotely in network structures.

Contemporary IT systems supporting the functioning of communities consist of a complex IT infrastructure and various automation elements.

The achievements of contemporary techniques play a particular role in supply chain management. These techniques apply artificial intelligence (AI) systems to optimize routes, shorten transport time, determine vehicle and semi-trailer loads. These techniques are currently widely used in the execution of deliveries by delivery companies and in dynamically developing passenger transportation services. This is particularly significant when ordering a taxi or vehicle, after indicating the location and searching for a vehicle to access services by selecting the fastest access for the customer. Moreover, IT systems supported by AI algorithms are a crucial element for improving the quality of transportation, logistics, and communication services. The improvement of the functioning of companies is achieved by decreasing activity costs while improving natural environment protection. The optimum design of transport routes results in decreasing exhaust emissions.

We recently observed the increased interest of companies responsible for the collection and disposal of waste in IT systems (Song et al. 2015; Medvedev et al. 2015). New concepts support waste collection [e.g., the use of waste containers equipped with sensors indicating the fullness level of the container (http://www.enevo.com/)] and the planning of waste-collection vehicle routes that consider the sequence of emptying the containers. Other proposals support waste collection, including waste collection on demand (Król et al. 2016). This method can be applied, for instance, to construction waste, large-size household waste, and waste electrical and electronic equipment (WEEE), which is also called e-waste.

The sequence of waste-collection calls from residents creates a set of location points, which can be represented as a graph where the vertices are the waste-collection points and the edges are roads connecting nodes. Inhabitants can use communication channels (i.e., mobile applications, websites, or phones) when they request waste equipment for collection, and a waste-collection company receives the calls. Then, a collection company prepares a waste-collection plan. The decision of WEEE disposal depends on the individual. When the equipment is considered waste or nonfunctional, it should be disposed of. The operating time for each category of electrical or electronic equipment varies and should be considered random.

The time of operation varies, which must be considered for WEEE. A decision regarding when to dispose of waste equipment from a household depends on many factors and is random. As a result, after receiving applications for equipment collection by the waste-collection company, a collection plan must be prepared, which is the route sequence of the collection vehicles (Moura and Oliveira 2009; Nowakowski et al. 2017).

WEEE collection is characterized not only by a particular significance for the environment, but also by specific restrictions and assumptions that should be taken into account when planning the route. The decision-making process regarding municipal waste collection usually does not take into consideration the customer’s requirements (e.g. preferred time windows) and does not allow for a precise determination of the profitability of the collection. However, when planning mobile WEEE collection, it is necessary to take into account the indicated factors. Depending on the adopted company’s policy, two extreme approaches can be distinguished—one assuming only generating the highest possible profit and the other pro-consumer, which ensures the best level of customer service. In economic practice, a mixed approach is dominant, forcing the planner to adopt further assumptions, requiring the determination of a solution for an instance of the classic Vehicle Routing Problem with Time Windows (VRPTW) or the extended version of the Team Orienteering Problem (TOP), depending on the adapted customer service policy (TOP assumes no need to visit all customers and is used when the company does not want to generate losses). Also, the diversification of the collected equipment, as well as the associated loading time and its size, may lead to the need to use heuristic algorithms when planning a collection (in highly urbanized areas it may be necessary to handle a large number of collection points by a fleet consisting of a dozen vehicles—the collection points can be households, commercial or business facilities as well as additional placements of containers, bins, etc.).

To ensure timely and cost-efficient waste collection, AI algorithms should be used to solve the VRPTW and TOP issues. Prototype systems for on-demand waste collection have been discussed by Nowakowski et al. (2018). The following algorithms were used in applied solutions: Simulated Annealing (SA), Tabu Search (TS), Greedy Algorithm (GrA) and improved Bee Colony Optimization (BCOi).

Among the new and popular approaches to solving VRPTW instances, special attention can be paid to the use of metaheuristics. As an example of their use, we can distinguish e.g. Modified Artificial Bee Colony (Alzaqebah et al. 2016), a hybrid of Ant Colony and Firefly Algorithm (Goel and Maini 2018), Multi-Adaptive Particle Swarm Optimization (Marinakis et al. 2019) and Parallel Hybrid Genetic Algorithm (Berger and Barkaoui 2004). In order to solve the special cases of VRTPW adapted to the classic waste collection, researchers used e.g. Adaptive Large Neighbourhood Search (Buhrkal et al. 2012), Multi-Objective Genetic Algorithms (Ombuki-Berman et al. 2007) and Memetic Algorithm (MA) (Minh et al. 2013). The optimization problem that is the canvas for our WEEE collection model (TOP) can be solved e.g. by the Guided Local Search (Vansteenwegen et al. 2009), MA (Bouly et al. 2010) or the Similarity Hybrid Harmony Search (Tsakirakis et al. 2019).

The primary aim of the improvement of household waste-collection efficiency should focus on the preparation of a communication platform and IT system for inhabitants, administered by a waste-collection company. Using a mobile application, website, or phone, inhabitants can define the kind of equipment to collect, the number of items, and the cubage or weight of the WEEE for pick up from a household. It is necessary to assign the volume, the weight of each piece of waste for the collection, and a convenient time for a resident for waste pick up. This action is supported by a database with common volumes and the weights of equipment from producer datasheets. After registering the data, waste-collection companies can prepare a waste-collection plan, choose the number of vehicles required for collection, and determine the length of routes and personnel costs. This can be solved only using AI systems, provided that the routes are determined in a short time and the inhabitants are notified within the declared collection time.

An additional advantage of systems supporting e-waste collection is the convenience for inhabitants in removing the waste from the household. Xue et al. (2019) suggested that a new collection model is required to utilize ICTs (Information and Communication Technologies) in waste management. The concept of intelligent waste collection proposes that waste items are collected with the assistance of ICT and the IOT.This collection model includes benefits for the collection companies (Xue et al. 2019). In China, Zhang et al. (2019) found the key drivers and barriers regarding the residents’ choice of e-commerce for recycling. They indicated a positive correlation with the intention to use e-commerce for e-waste recycling. Internet-based waste-collection services were investigated in India (Agrawal and Mittal 2017) and China (Gu et al. 2017) with a proposal to create a framework for implementing the IoT and big data technology. Park et al. investigated the development of door-to-door services for collecting waste (Park et al. 2019). A recent study by Sun et al. (2020) discussed different variants of WEEE collection as business models with possible opportunities for recycling companies. This indicates the growing interest of the possible use of ICT, IoT, and website-based platforms for broad application in society. Acquiring data on the type, number, and volume of waste, including the location of the collection point and access time windows, creates new opportunities and challenges for waste-collection companies.

This article is a development of previous research (Król et al. 2016; Nowakowski et al. 2017, 2018) as an attempt to test the application of other algorithms and to assess their efficiency during the execution of transportation tasks in designing vehicle routes for on-demand waste collection from inhabitants within a defined time window. Due to the great popularity of Evolutionary Algorithms (EA), although basic evolutionary techniques were formulated several decades ago, they are still used to solve many optimization problems. For example, Rahmani Hosseinabadi et al. (2018) used Extended Genetic Algorithm to solve open-shop scheduling problem, and Kadri and Boctor (2018) used Genetic Algorithm for the resource-constrained project scheduling problem with transfer times. Considering the results of the research presented by Nowakowski et al. (2018), indicating the efficiency of local search algorithms for solving the problem of planning mobile WEEE collection, we assume the opportunity to further improve the process of e-waste mobile collection by using the synergic effect occurring in the MA, which is formed as a result of a combination of the local search and the EA. The MA has been successfully used in solving classic VRPTW (e.g. Labadi et al. 2008; Nagata et al. 2010; Nalepa and Blocho 2016), indicating the possibility of obtaining good results for a model adapted to the e-waste mobile collection.

The results of these tests should provide an answer to the question of how the EA and MA might support \(\mathcal {NP}\)-hard planning and execution of WEEE collection. The support system may include various groups and categories of waste, and its assumptions perfectly fit the assumptions of the circular economy model as well as of the IoT concept.

The work was organized in the following manner. The introduction to the subject matter is followed by a description of the analyzed algorithms, and the problem of mobile WEEE collection is formulated. Next, the method of adjustment of metaheuristics to electro-waste-collection route planning is described. The methodology of the research work is presented, and the achieved results are interpreted.

2 Principles of the memetic algorithm

The notion of the MA was first proposed by Moscato (1989), who proposed the method to imitate cultural evolution. The technique assumes the connection of the EA and the heuristics of the local search applied by particular individuals, the aim of which is to model the process of learning population representatives.

The EA refers to various evolutionary techniques, which include Genetic Algorithms, Evolutionary Strategies, and Evolutionary and Genetic Programming. The structure of the EA is based on generating the initial population (by creating genotypes of individuals and calculating their fitness) and processing it into a loop (referred to as a generation), in which the selection, genetic operations, assessment, and succession take place in turn.

In terms of this article, tournament selection is the most relevant. It is based on making a selection of population \(Q \subset P^t\) containing q individuals from \(P^t\), from which the best-fitted member is determined and copied to \(T^t\). The procedure is repeated until the desired number of individuals is generated.

Succession is responsible for the method of generational change execution, which may be based on the total replacement of the initial population by \(O^t\) or making a selection of some individuals from \(P^t\) and \(O^t\). With regard to the method based on partial replacement \(P^t\) the applied approaches assume e.g. the removal of the worst fitted individuals, elimination of population elements most similar to descendants and ensuring that the best-fitted individuals from \(P^{t+1}\) appear in \(P^t\) (generational replacement with elitism).

The general structure of the MA was described by Moscato (1989) in the following way: the procedure starts with the random creation of initial population or with the use of any heuristic. Subsequently, to determine the local optimum or improve the solution, individuals perform a local search and initiate interaction with other members of the population, which could be of a competitive or cooperative nature. Competition is compared to the process of selection, whereas cooperation is compared to crossover or other methods of creating new members of the population. Both local searches and interactions between individuals are performed until the predetermined stop criterion is reached. In summary, the MA completes EA with a mechanism that improves the flow of exploitation of the solution space, eliminating the imperfection of classic evolutionary techniques that focus on exploration (Wang and Kusiak 2000).

The above-mentioned idea of Pablo Moscato was broadened, indicating generally three possible places of occurrence of hybridization: after generating the initial population, in the evolutionary loop (e.g. before selection or after the crossover and mutation operation Szwarc and Boryczka 2017) and after the execution of evolutionary phase (Le et al. 2015). The pseudocode of the method, considering the analyzed time places of hybridization, was presented in Algorithm 1.

The performance of the local search, which is presented in Algorithm 1, causes the assessment of other created individuals. After improving the given solution, under Lamarckian evolution, it may replace the entire result or leave the original genotype and modify the fitness value (the Baldwin effect), which avoids premature convergence.

figure a

3 Characteristic features of selected MA supporting algorithms

3.1 Simple methods of the local search

The simplest methods of the local search include two heuristics that differ due to the selection rule: Greedy Local Search (GLS) and Hill Climbing (HC). These are characterized by expressing the improvement of the existing solution at the cost of quickly reaching convergence, and as a result, falling into a local optimum.

The GLS assumes an iterative search of the neighborhood of the current result and its modification when designating a solution characterized by a more beneficial value of the objective function The procedure terminates when the neighboring solutions are described by the value of the objective function not better than currently examined.

The HC approach is based on mechanisms corresponding to the greedy variation; however, replacement of the current solution occurs during the termination of the search of an entire neighborhood (the best of the determined results becomes a new result, which is subject to further improvement).

3.2 Tabu search

The TS algorithm developed the HC concept by implementing a mechanism that allows leaving the local optimum by proceeding to the solution described by a worse value of the objective function. The algorithm also uses the structure storing—for the period sometimes referred to as the Tabu period – of the most recently performed moves in order to disable the return to visited places, as a result increasing the exploration of the solution space. Despite marking the given transformation as inaccessible, it is possible to perform the desired route again if it fulfills so-called aspiration criterion (the most commonly applied solution is permission to make a move if it leads to improvement of the best-known result Gendreau 2003).

3.3 Simulated annealing

Similarly to TS, SA allows leaving the local optimum by accepting the result described by a worse value of the objective function. This mechanism is executed by the parameter t, which is the temperature. The probability \(P_{t}\) of accepting solution \(X^{'}\) (belonging to the neighborhood of the solution X), at temperature t, is expressed by the equation:

$$\begin{aligned} P_{t}= \left\{ \begin{array}{ll} 1 &{}\quad \text {if }f(X^{'})\le f(X),\\ e^{\left( \frac{f(X)-f(X^{'})}{t}\right) } &{}\quad \text {otherwise}. \end{array} \right. \end{aligned}$$
(1)

The value of parameter t can be determined in such a way as to initially accept solutions worse with the given probability \(P_0\). The discussed approach is expressed by the following equation:

$$\begin{aligned} t=\frac{-\overline{\varDelta f}}{\text {ln}(P_0)}, \end{aligned}$$
(2)

whereas \(\overline{\varDelta f}\) is the average value of deterioration of solutions.

The temperature in the j circuit of the algorithm loop can be lowered by applying the cooling coefficient \(\alpha \) (satisfying the equation \(\alpha <1\)) in accordance with the equation:

$$\begin{aligned} t_{j+1}=\alpha t_j, \quad j=1,2,\ldots . \end{aligned}$$
(3)

While executing one algorithm loop, L (Epoch length) neighborhood solutions are generated at a given temperature.

In this article we use the SA with the leader, which, in contrast to the original method, assumes storing the best-determined solution \(X_b\), increasing the efficiency of the method.

4 Formulating the problem of mobile WEEE collection

This article is based on the developed model of a mobile collection of WEEE proposed by Nowakowski et al. (2018) and derived from the TOP with additional restrictions. It assumes that some company has a heterogenic fleet of vehicles that vary in terms of usage (maintenance) costs, categories of waste equipment for the collection, maximum capacity of the cargo compartment of the vehicles, and the maximum load of a vehicle. In a typical delivery of goods, a vehicle starts a route fully loaded. In the mobile collection of WEEE, this is inverted. A number of residents request waste pick up within convenient time windows. Each resident declares a category of WEEE and the size of the waste item to be collected. After a vehicle is fully loaded or another piece of waste cannot be loaded, the vehicle must return to a collection company base and unload WEEE. A difference between the analyzed model of the mobile WEEE collection and the classic VRPTW is the possibility to reject waste pick up from a household (forcing the use of the model derived from TOP). It happens when a piece of waste is small or represents low recycling value. In such case, the collection costs can exceed a potential income of secondary raw materials value. The quality of service, timely waste pick up from a household, could be followed by a recommendation of this collection method to other individuals. Consequently, the number of collected WEEE is likely to increase (Helgesen 2006).

The objective function can be presented universally, enabling its adjustment to an implemented policy of the waste-collection company, using the following equation:

$$\begin{aligned} \begin{aligned} F_c&=\left( p_p\cdot \left( \frac{\sum \nolimits _{i=1}^{v}\sum \nolimits _{j=1}^{n}sb_{ij}\cdot b_{j}}{\sum \nolimits _{i=1}^{v}\sum \nolimits _{j=1}^{n}sn_{ij}\cdot b_{j}}\right. \right. \\&\quad \left. \left. +\,\frac{\sum \nolimits _{i=1}^{v} \left( un_{i} \cdot \left( c_i + \sum \nolimits _{j=2}^{rn_{i}}(d_{{i}{(j-1)},{i}{j}}\cdot ct_i)\right) \right) }{\sum \nolimits _{i=1}^{v} \left( ub_{i} \cdot \left( c_i + \sum \nolimits _{j=2}^{rb_{i}}(d_{{i}{(j-1)},{i}{j}}\cdot ct_i)\right) \right) }\right) \right. \\&\quad \left. +\,p_t \cdot \frac{\sum \nolimits _{i=1}^{v} un_{i} \cdot \sum \nolimits _{j=2}^{rn_{i}}t_{{i}{(j-1)},{i}{j}}}{\sum \nolimits _{i=1}^{v} ub_{i} \cdot \sum \nolimits _{j=2}^{rb_{i}}t_{{i}{(j-1)},{i}{j}}}\right. \\&\quad \left. +\,p_g \cdot \frac{\sum \nolimits _{i=1}^{v}\sum \nolimits _{j=1}^{n}sb_{ij}}{\sum \nolimits _{i=1}^{v}\sum \nolimits _{j=1}^{n}sn_{ij}}\right) \rightarrow \text {min} \\ \end{aligned}, \end{aligned}$$
(4)

where we distinguish the following parameters:

  • n is a number of waste collection points,

  • v is the number of vehicles which may participate in the collection,

  • \(p_p\) is the parameter of profit (the difference between the cost of collection and the value of secondary raw material obtained from the collected equipment) relevance,

  • \(p_t\) is the parameter of time relevance,

  • \(p_g\) is the parameter of relevance of the number of served collection points (households),

  • \(rb_i\)/\(rn_i\) is the number of points to visit (including the base node) in the plan of vehicle i in the base/new solution,

  • \(c_i\) is the initial cost of a vehicle i use,

  • \(ct_i\) is the cost of the travel per one kilometre for the vehicle i,

  • \(b_{j}\) is a potential secondary raw material value in the point j,

  • \(d_{{i}{(k-1)},{i}{k}}\) is the distance between the node \((k-1)\) and k the route of the vehicle i (km),

  • \(t_{{i}{(k-1)},{i}{k}}\) is the time of travel between the node \((k-1)\) and k the route of the vehicle i (s),

and the following decision variables:

  • \(ub_{i}\)/\(un_{i}\) is the decision variable representing the use of a vehicle i in the base/new solution,

  • \(sb_{ij}\)/\(sn_{ij}\) is the decision variable representing the fact that the vehicle i serve the point j in the base/new solution,

Additionally \(n,v,rb_i,rn_i\in {\mathbb {N}}\) and \(p_p, p_t, p_g,c_i,ct_i,b_j\), \(d_{{i}{(k-1)},{i}{k}},t_{{i}{(k-1)},{i}{k}} \in {\mathbb {R}}\).

Decision variables \(ub_{i}\)/\(un_{i}\) have been defined in the following way:

$$\begin{aligned} \begin{aligned} ub_{i}/un_{i}&= \left\{ \begin{array}{ll} 1 &{}\quad \text {if the vehicle }i\text { was used},\\ 0 &{}\quad \text {otherwise}, \end{array} \right. \end{aligned} \end{aligned}$$
(5)

Decision variables \(sb_{ij}\) and \(sn_{ij}\) have been defined in the following way:

$$\begin{aligned} \begin{aligned} sb_{ij}/sn_{ij}&= \left\{ \begin{array}{ll} 1 &{}\quad \text {if vehicle }i\text { serve the point }j,\\ 0 &{}\quad \text {otherwise}, \end{array} \right. \end{aligned} \end{aligned}$$
(6)

The base solution is the reference solution that is compared to the solution constructed by the given algorithm (new solution). In this paper, the base solution was constructed by the GrA.

Additionally, limiting conditions were implemented, forcing the occurrence of the aggregate value of the weights equal to 1:

$$\begin{aligned} \begin{gathered} p_p+p_t+p_g=1, \quad 0 \le p_p, p_t, p_g \le 1. \end{gathered} \end{aligned}$$
(7)

The following limiting conditions have been implemented to ensure that vehicle limitations are not violated in the new solution (maximum capacity in Eq. (8), maximum cargo mass in Eq. (9) and accepted equipments in Eq. (10)):

$$\begin{aligned}&\sum _{j=2}^{rn_i-1}pv_{ij} \le vc_i, \quad \forall i=1,\dots , v, \end{aligned}$$
(8)
$$\begin{aligned}&\sum _{j=2}^{rn_i-1}pw_{ij} \le vm_i, \quad \forall i=1,\dots , v, \end{aligned}$$
(9)
$$\begin{aligned}&pe_{ijk} \in E_i \quad \forall i=1,\dots , v, \forall j=2,\dots ,rn_i-1, \nonumber \\&\quad \forall k=1,\dots ,ne_{ij}, \end{aligned}$$
(10)

where:

  • \(pv_{ij}\) is the total volume of equipments at the collection point, served by the vehicle i in the order j in the new plan,

  • \(vc_i\) is the maximum capacity of vehicle i,

  • \(pw_{ij}\) is the total weight of equipments at the collection point, served by the vehicle i in the order j in the new plan,

  • \(vm_i\) is the maximum cargo mass of vehicle i,

  • \(pe_{ijk}\) is a category of k equipment available at the collection point, served by the vehicle i in the order j in the new plan,

  • \(ne_{ij}\) is the number of equipments available at the collection point, served by the vehicle i in the order j in the new plan,

  • \(E_i\) is a set of categories of waste equipment, accepted by the vehicle i.

Additionally, at the time of unloading (handling the point representing the return to the base for unloading) a negative value is assigned to \(pv_{ij}/pw_{ij}\) (equal to the current sum value) in the Eqs. (8) and (9). Moreover, we assume that \(pv_{ij}, vc_i, pw_{ij}, vm_i \in {\mathbb {R}}\) and \(pe_{ijk}, ne_{ij} \in {\mathbb {N}}\).

To ensure that each point will be served maximum once in the new plan, the following limiting condition has been introduced:

$$\begin{aligned} \sum _{i=1}^v sn_{ij} \le 1, \quad \forall j=1,\dots ,n. \end{aligned}$$
(11)

The customer time windows cannot be affected by introducing the following limiting condition:

$$\begin{aligned} \begin{aligned}&\left\lfloor \frac{s_i+t_{i(j-1),ij}+\sum _{k=1}^{j-1}(t_{i(k-1),ik}+l_{ik})}{3600}\right\rfloor \in TW_{ij}, \\&\quad \forall i=1,\dots , v, \quad \forall j=2,\dots ,rn_i-1, \end{aligned} \end{aligned}$$
(12)

where:

  • \(TW_{ij}\) is the set of the accepted time windows by the customer at the point served by the vehicle i in the order j in the new solution (each element of the set represents the starting hour of the time window),

  • \(l_{ij}\) is the vehicle loading time in seconds at the point served by the vehicle i in the order j in the new solution (it is equal to the vehicle i unload time for the point representing the return to the base for unloading; \(l_{ij} \in {\mathbb {N}}\)),

  • \(s_i\) is the starting time of collection for the vehicle i in seconds in the new solution (the departure time from the base; \(s_{i} \in {\mathbb {N}}\)).

The analyzed model assumes the possibility of congestion, which decreases the vehicle speed, which is represented by the safety coefficient \(s_f\) in the equation below:

$$\begin{aligned} t_{{(j-1)},{j}} = s_f \cdot rt_{{(j-1)},{j}}, \end{aligned}$$
(13)

whereas \(t_{{(j-1)},{j}}\) is the assumed time of travel between node \((j-1)\) and j, and \(rt_{{(j-1)},{j}}\) is a theoretical time of travel between node \((j-1)\) and j. The parameter \(s_f\) was additionally described by the occurrence of limiting conditions, which make it impossible to determine the negative time of vehicle travel:

$$\begin{aligned} \begin{aligned} s_f \ge 0, \quad s_f \in {\mathbb {R}}. \\ \end{aligned} \end{aligned}$$
(14)

5 Adjustment of metaheuristics to WEEE mobile collection route planning

5.1 Generating the base solution: greedy algorithm

To create a base solution, which was applied during the determination of the value of the objective function of the result; of the value of the objective function equal to 1, the GrA proposed by Nowakowski et al. (2018) was applied. It assumes the iterative construction of route plans for subsequent vehicles. Its pseudocode is presented in Algorithm 2.

figure b

5.2 Accepted neighborhood of solutions

Based on the approach by Nowakowski et al. (2018), the neighborhood of the current solution was assumed to be the results achieved by removing and reconstructing the route for a single vehicle or two vehicles. Selection of collection locations, to the new route, takes place using the roulette method, where the probability of affirmation of the given point depends on the inverse distance between them, and the most recently visited node. In other words, the route for the selected vehicle or two vehicles is removed and the procedure of creating a new route for the available points is launched, selecting the next points in the same way as in GrA (Algorithm 2); however, instead of selecting the closest point, the roulette wheel method is used, thereby allowing diversifying the solution space. The size of the neighborhood is equal to \((v^2+v)/2\).

5.3 Adjustment of EA and MA to the problem of mobile WEEE collection

Individuals describing the solution of the given problem are coded in the path representation, containing route sequences for each vehicle. The set of points included in the given route is separated from other nodes incorporated in the chromosome of the population member. Figure 1 presents an example of coding an individual for two vehicles—the first vehicle (marked as \(v_1\)) involves visiting point number 2 first, and then number 1, while the second vehicle (\(v_2\)) has to visit point 3 first, then return to the base for unloading (conventionally marked as point 0) and at the end, handling point 4. Due to the fact that vehicles always start and end their journey in the base, it is not necessary to add these points at the beginning and end of the route, while coding an individual.

Fig. 1
figure 1

An example of coding an individual

To adjust EA and MA to the analyzed optimization problem, it was proposed to implement the mutation operator, the operation mechanism of which is based on the random choice of solution from the neighborhood (in this way, only the part of the genotype that is responsible for the selected route constructed for one or two vehicles is modified (according to the definition of neighborhood proposed in the Sect. 5.2) and a correct solution is created, not requiring repairing action). For the example from Fig. 1 as the neighborhood solution we can choose the route for vehicle \(v_1\), \(v_2\) or both of them. Assuming that the route of the \(v_1\) has been selected as the neighborhood solution that is subject to mutation, all the collection points belonging to the \(v_1\) (1 and 2) are marked as not served. Then a new random correct path (not violating the limitations) for the \(v_1\) vehicle is generated from all collection points marked as not served (1, 2 and any other points that have not been assigned to any vehicle).

Assuming the inefficiency of classic crossover operators—for the developed problem of routing, introducing many limitations, which may result in the creation of an incorrect solution (violating e.g. the maximum vehicle capacity), requiring further repair procedures—it was decided to modify the BRBAX operator proposed by Graglia et al. (2010), based on sorting all the m routes recorded in the first parent and choosing from them m/2 of the best route plans (for the needs of the analyzed problem it was assumed that the choice will be made on the basis of profit expressed as the difference between the value of collected equipment and the cost of its acquisition), and subsequently placing them in the chromosome of the offspring. Other items are completed on the basis of the second parent, in accordance with the order of occurrence. Due to the existence of time windows and other limitations, the method was modified, assuming iterative constructing of routes (with the use of GrA) from locations assigned to the given vehicle in the plan of the second parent and other non-managed—as a result of moving the nodes of the first parent to the chromosome of the offspring - points. To illustrate how the crossover works, we will use the parents shown in Fig. 2. We assume that the collection made by \(v_1\) in the parent 1 will generate a profit of 2, and \(v_2\) will provide a profit of 1. Vehicle \(v_1\) in the parent 2 will generate a profit of 3, while \(v_2\) will generate a profit of 4. To generate the first offspring, we select one (\(\lceil m/2 \rceil \)) vehicle with the highest profit from the parent 1, i.e. \(v_1\), and we copy its route to the offspring. Then we assign to the pool of not served points pool all points of the parent 2 that were originally served by the \(v_1\), but they do not exist in the new offspring (\(\{0,1,2\} {\setminus } \{1,2\}=\{0\}\)). Then we iteratively analyze all remaining vehicles and generate their routes using GrA. To construct the routes for the i vehicle we use the points from the pool (\(\{0\}\)) and the points that were at the same time served by the i vehicle in the parent 2 and are not yet added to the offspring (\(\{3,4\}\)). As a result, the route for \(v_2\) in the offspring will be produced by GrA on the basis of the points from set \(\{0,3,4\}\). The second offspring is created in the same way with one difference—the parents swap places and from the parent 2, \(\lceil m/2 \rceil \) routes are copied (\(v_2\) will be selected, because its profit is greater than that of \(v_1\) in the parent 2).

Fig. 2
figure 2

An example of the parents during the crossover operation

5.4 Intensification of the process of exploration of the solution space

Constructing the new route begins with managing locations occurring in the earliest possible collection hour. Due to the possibility of vehicle unloading, an approach assuming creating the plan forward and backward starting with randomly chosen time window may cause inefficiency of the first loading. To diversify the solution space, the parameter \(\zeta \)—proposed by Nowakowski et al. (2018)—was applied to determine the probability of removing the time window. After the operation, it is assumed that at least one available collection hour must remain. Hence, nondeterminism is introduced in the route planning. Moreover, GrA is devoid of the described mechanism.

6 Methods of tests

6.1 Characteristics of test assignments

It was assumed that the analyzed algorithms are adjusted to the enterprise needs, for which the most important factor is the customer care level, consequently selecting the following values of parameters from Eq. (7): \(p_p=0.2\), \(p_t=0.1\), \(p_g=0.7\).

To determine the recommended adjusted algorithm to solve the problem of route planning for the mobile WEEE collection, 20 instances were generated pseudorandomly. Due to the existence of many limitations characterizing the problem of e-waste mobile collection, it is inadvisable to use classical TOP benchmark tests. The instances are described by the values presented in Table 1. The values were established based on conversations with employees of enterprises and the work by Nowakowski (2017) and Nowakowski et al. (2017). The existence of the asymmetrical weights of edges connecting the same points was assumed, and the time of route was made directly dependent on the distance (distance \(\cdot \) 60 s). Additionally, the lack of the possibility of congestion was introduced [\(s_f\) from the Eq. (13) equals 1].

Each instance of the problem can be solved using another fleet created pseudorandomly in accordance with the values presented in Table 2. The presented cost of use is interpreted as the salary for the drivers and other costs related to the operation of the vehicles.

Table 1 Values of parameters of test assignments
Table 2 Values of parameters of used fleet

6.2 Assessment of the efficiency of the researched methods

The assessment of results determined using the particular techniques was conducted using the following equation:

$$\begin{aligned} q = i_o \cdot o_n + i_t \cdot t_n, \end{aligned}$$
(15)

whereas q is the coefficient of the quality of values determined by the tested algorithm, \(i_o\) is the parameter of relevance of the value of the objective function, \(o_n\) is a normalized average percentage excess of the value of the objective function, \(i_t\) is the parameter of relevance of time of achieving convergence, and \(t_n\) is a normalized average value of the time of achieving convergence. Tto ensure the occurrence of aggregate value of parameters equal to 1, the following limiting conditions were introduced: \(i_o + i_t=1, \quad i_o, i_t \in {\mathbb {R}}, \quad 0 \le i_o, i_t \le 1.\)

As a result of conversations with the representatives of enterprises dealing with the mobile WEEE collection, it was assumed that the obtained value of the objective function is three times more relevant than the time of performing the method, hence \(i_o=0.75\) and \(i_t=0.25\). Due to the minimization criterion of both parameters, the algorithms described by the lower value of the q ratio are characterized by a more beneficial value of determined results.

Two methods were applied to perform the normalization: min–max [Eq. (16)] and the percentage value positions in the dataset, within the range from 0 to 1 inclusive [Eq. (17)]. The second ensures the reduction of differences between the values from the researched set (assuming an acceptable performance time in practical terms for all methods, it is recommended to assess the usefulness of the algorithm designed for utilitarian purposes). Subject to the applied normalization method, the algorithm quality ratio was designated as \(q_m\) (for min–max normalization) and \(q_p\) (for percentage value positions in the dataset).

$$\begin{aligned} \begin{aligned} n = \frac{X-\text {min}}{\text {max}-\text {min}}, \end{aligned} \end{aligned}$$
(16)

whereas n is a normalised value (min–max), X is the analyzed value, min is a minimal value occurring in the dataset, and max is the maximum value occurring in the dataset.

$$\begin{aligned} \begin{aligned} p = \frac{s}{s+l}, \end{aligned} \end{aligned}$$
(17)

whereas p is the percentage value position in the analyzed data set, s is the number of values smaller than the researched in the analyzed dataset, and l is the number of values larger than the researched in the analyzed dataset.

6.3 Tests of the algorithms

The study was performed in two steps. In the first step, the influence of the parameter \(\zeta \) value upon the quality of achieved results was assessed. To do this, all tasks from the generated test set were solved 10 times by each analyzed method, using the following values: \(\zeta =\{0,5,10,25,50\}\). Based on the results, the arithmetic means of the objective function values of the solutions for each of the parameter \(\zeta \) values were determined.

The second part of the study included an analysis of the quality of the results determined using particular methods. To do that, the 30 repetition measurement was performed, determining each time the value of the objective function o (the mean value was designated as \({\overline{o}}\) and the standard deviation of the sample was \(s_o\)) and the time for achieving convergence t, expressed in seconds (the mean value was designated as \({\overline{t}}\) and the standard deviation of the sample was \(s_t\)). Based on this, the values \(q_m\) and \(q_p\) were determined, which were used in the determination of the recommended techniques for utilitarian and scientific applications (assuming that each method runs within the time acceptable in practical applications, \(q_p\) is recommended for determining the usefulness of the algorithm in utilitarian applications as it eliminates significant differences between the results. For scientific use, \(q_m\) is better because it accounts for the large differences between the methods). Additionally, the number of iterations after which the given method achieved convergence it was recorded to determine the optimum stop condition for each algorithm. The mean value was determined as \({\overline{it}}\) and the standard deviation of the sample as \(s_{it}\).

In the process of the local search occurring in the MA, the following methods were used: GLS, HC, TS, and SA with the leader. According to research presented by Nowakowski et al. (2018), it determined better results than TS and BCOi. Additionally, the effect of the local search on the quality of solutions determined by MA was tested, considering the applied method and place of hybridization.

The selected algorithms were implemented in \(C\#\), and the tests were performed on the server with the following parameter values: Intel Xeon E3-1231v3, 32 GB RAM, two SSDs, 480 GB each. Due to the significant calculation complexity, all algorithms were executed concurrently, making it possible to slightly interfere with the measured time for achieving convergence.

To simplify the registration of results, the coding of algorithm names was applied, as presented in Table 3.

Table 3 Coding of algorithm names

The values of the objective function from 30 repetitions were subjected to the Wilcoxon Signed-Rank Test with the application of the R package. The process was applied to the pairs of methods, designated as T1 and T2. The value 0.05 was assumed as the level of test relevance. The p-values characterized by a lower result confirm the acceptance of the alternative hypothesis in accordance with which T1 obtained lower results than T2.

6.4 Configuration of metaheuristics

Based on the paper by Nowakowski et al. (2018) and the empirical studies, the algorithms were described by the parameter values presented in Tables 4, 5, 6, and 7 for TS, SA, EA, and MA, respectively.

Table 4 TS parameters applied in the studies
Table 5 SA parameters applied in the studies
Table 6 EA parameters applied in the studies
Table 7 MA parameters applied in the studies

The selection of individuals for modification in the MA assumes the selection of the best-fit individuals created in the previous generation with a different objective function value until a specified number of individuals is chosen. In the variants with hybridization after genetic operations, the order of creating the offspring was decisive in order to search through more diverse areas of the solution space.

7 Results of the tests and discussion

7.1 Choice of parameter \(\zeta \) values

Figure 3 presents the breakdown of the mean value of the objective function for various values of the parameter \(\zeta \) obtained using all the methods. Based on the findings, it is recommended to use a relatively small value equal to \(5\%\). This was applied in further tests. The observation justifies using the insignificant value \(\zeta \) presented by Nowakowski et al. (2018). However, based on the analysis, the value should be decreased from 10 to 5%. For major values of the described parameter, the operation of the algorithms is noticeably worse, which is caused by too big limitation of the solution space (eliminating too many time windows causes the decrease of the exploration possibilities), proving the parameter \(\zeta \) has a significant impact on the quality of constructed route plans.

Fig. 3
figure 3

Breakdown of the objective function and the parameter \(\zeta \) values

7.2 Assessment of the quality of the algorithm results

The aggregate results of the performed tests for 26 combinations of different methods are presented in Tables 8 and 9. They summarize the technique analysis and breakdown, describing route plan parameters, indicating the differences between algorithms regarding the utilitarian function. Building on the findings, in practical and scientific terms, the MA with TS and hybridization before selection obtained the most profitable value of parameter q. It determined the results of the lowest values of the objective function, which were characterized by significant recurrence. The standard deviation of the sample amounted to as little as 0.0133.

In addition, the relatively quick time to achieve convergence (on average \(< 15\) min) allows the application of the technique in many enterprises dealing with WEEE collection. Nowakowski et al. (2018) was also confirmed that SA obtained the most beneficial results among the analyzed local search techniques (regarding the value of the objective function). Particular attention should be paid to the observation, according to which GLS, HC, and TS, based on the base solution generated by GrA determined better solutions, in a shorter time than their variants based on the random initial solution. However, SA obtained better results (at the cost of increasing the calculation time) for random initial solutions (due to the relatively small differences of values of the objective function and a small number of repetitions, the dependency cannot occur, as it could emerge as a result of nondeterminism of methods).

The observation presented by Wang and Kusiak (2000) was confirmed by recording the increase of EA efficiency, which was enriched by the incidence of local search techniques that improved the mechanism of algorithm exploitation. As a result, most variants of the developed MA have created better routes than the local search algorithm recommended in the article by Nowakowski et al. (2018). In addition, they outperformed the analyzed EA, which is similar to the method proposed by Król et al. (2016), demonstrating the possibility of applying them in business practice (the utilitarian application of the method is important due to the fact that WEEE is a global problem with potential environmental pollution and human health risk (Zeng et al. 2017)).

Figure 4 presents the results of Wilcoxon Signed-Rank Test for the value of the objective function obtained by particular techniques. According to them, there are no grounds to undermine the hypothesis, in accordance with which MA with TS and hybridization occurring before selection obtained better results than any of the analyzed algorithms.

Table 8 Algorithmic breakdown of aggregated results
Table 9 Utilitarian breakdown of aggregated results
Fig. 4
figure 4

Breakdown of obtained results of Wilcoxon Signed-Rank Test

The results determined by MA were further analyzed by calculating the mean value of the parameters considering the applied local search algorithm (Table 10). Based on the results, TS is recommended as a method for completing the MA, which balances both the time of achieving convergence and the obtained value of the objective function of solutions. However, the MA with SA were characterized by the best mean value of the objective function, as they required definitely shorter operation time to achieve convergence. Convergence was achieved most quickly by versions of MA with GLS (in terms of time—the value of \({\overline{it}}\) is slightly larger than the value for HC, but the execution time of local search operation was higher for HC). The MA with HC achieved the worst average value of the objective function.

Table 10 Aggregate, algorithmic breakdown of MA results, taking into account the local search algorithm

The development of new methods of WEEE collection is expected to be applied in future solutions by waste-collection companies. This is a key issue in highly populated countries, such as India and China. The results of the study conducted by Madya Pradesh (Agrawal and Mittal 2017) indicate that the problems and concerns regarding e-waste collection from households can be solved by an online e-waste market. The authors of another study from China proposed an innovative network platform collection model including the assessment of economic issues and the creation of an internet-based application (Cao et al. 2018).

Other research by Gao et al. (2015) focused on the emerging channel of disposing of e-waste online and the potential attitude of residents regarding using the new online collection method. Creating a new kind of coordination of a reverse supply chain using an online recycling channel was proposed by Feng et al. (2017), indicating consumer preference for an online recycling channel. Wang et al. (2018) discussed a new approach ‘Internet +’ as a new recycling program combining collection companies and recycling sites with the proposal of building a connection between online and offline systems and presenting emerging online solutions of online waste collection. The increasing popularity of the integration of residents, waste-collection companies, and recycling plants through online platforms directly influences the development of efficient systems that are capable of minimizing transportation and waste-collection costs. The results presented in this article contribute to the selection of the best algorithm for solving e-waste collection on demand.

8 Conclusions and future work

This article proposed an efficient approach to designing EA and MA, adjusted to solve the problem of planning the mobile WEEE collection. Analyzing various methods of implementation of MA the efficiency was demonstrated of the discussed modification of the recombination operator BRBAX and accepted approach to performing the mutations (variants with hybridization occurring after generating the starting population achieved convergence later than in the first iteration). Both for practical and scientific applications, it is recommended to use MA and TS which is initiated before the selection (performed statistical tests did not allow denying the hypothesis, in accordance with which it obtained the best results in terms of the obtained value of the objective function). On the basis of performed tests, it is also recommended to apply the parameter \(\zeta \) with the value of \(5\%\).

Performed analyses enabled also to confirm the results presented in the previous article by Nowakowski et al. (2018) and allowed a statement that recommended MA configuration should include the application of TS and locating hybridization before selection, while simultaneously avoiding the use of HC and locating the local search after generating the initial population.

Further research regarding the application of the evolutionary approach to solving the problem of planning the mobile WEEE collection may include the preparation of new operators of crossover and mutation and checking the efficiency of MA using other local search techniques. Additionally, it is important to determine the recommended parameter values for EA and individual MA variants, e.g. using the irace package (described by López-Ibáñez et al. 2016).