ABSTRACT
In this paper, we focus on the multi-objective stochastic multiple knapsack problem, in which the object weights are random. We propose a new approach called the multi-objective memetic algorithm with either Martello and Toth’s heuristic method (MTHM) or the method denoted MTHMn, recently developed and inspired by MTHM. In each iteration of this approach, crossover, mutation, and local search techniques are applied to the current feasible population (parents), initially generated by the greedy algorithm. These operations generate new solutions that form a population of descendants. Next, a selection operator is employed to choose the best elements from the combined population comprising parents and offspring, using the non-domination sorting and the crowding distance calculation algorithms. A comparative analysis of the memetic algorithm using the MTHM and MTHMn heuristics with an exact method is performed, and the experimental results demonstrate the significant efficiency achieved by the memetic algorithm with the MTHMn heuristic.
Keywords:
non-dominated sort algorithm; crowding distance computation algorithm; memetic algorithm; MTHM; MTHMn
1 INTRODUCTION
The knapsack problem (KP), a fundamental NP-hard challenge in combinatorial optimization, has been extensively explored, leading to various exact and heuristic solutions Furini et al. (2017); Gao et al. (2014); Mavrotas et al. (2015). Its practical relevance is reflected in numerous applications across different domains, such as capital budgeting, property maintenance, and resource allocation, among others Bas (2011); Taillandier et al. (2002); Pisinger (2002); Martello & Toth (1990); Reniers & Sorensen (2013); Akbar et al. (2006); Muter & Sezer (2018); Hifi (2004); Chang & Lee (2012); Pfeiffer & Rothlauf (2007); Perboli et al. (2014); der Merwe & Hattingh (2006); Merkle & Hellman (1978); Akbar et al. (2006); Peeta et al. (2010). Recent advancements include optimizing group item transportation and sensor network optimization Simon et al. (2017); Li et al. (2016). KP’s linear nature involves binary decision-making to maximize profit within capacity constraints, emphasizing the balance between item benefits and weights.
In our context, we focus on the multiple knapsack problem (MKP). Given a set of n objects (or items) and a set of S knapsacks, a profit r i and a weight w i are associated with each object i. Each knapsack j has a weight capacity C j . MKP consists of assigning the objects to the knapsacks in such a way as to maximise the total utility of the allocated objects, while ensuring that the sum of the weights of the objects assigned to each knapsack does not exceed its capacity.
Let x ij be a binary decision variable that takes value 1 if item i is assigned to knapsack j and 0 otherwise. MKP can be formulated as follows:
Equation 1a aims to maximize the total profit of all assigned objects. Constraint 1b ensures that the sum of the weights of the objects assigned to each knapsack does not exceed its capacity. Constraint 1c requires that each object is allocated at most to one knapsack.
This paper examines a two-stage optimization problem where item weights are random, independent, and normally distributed. The second stage adjusts the initial decision based on actual weights, either by adding items to address underload or removing them with a penalty for overload.
We explore the multi-objective knapsack problem, significant for its real-world applications in logistics, finance, and resource management, and for addressing complex decisions involving conflicting objectives. It is vital for sustainable resource allocation, engineering, project management, and presents computational challenges that enhance optimization techniques. As a key part of multi-criteria decision analysis, it aids in selecting optimal alternatives based on multiple criteria.
In essence, the multi-objective knapsack problem is a critical tool for complex, multi-faceted decision-making across various sectors, promoting efficient resource use and sustainable practices. The paper further details a mathematical model for this problem and discusses solution methods.
The rest of this paper is developed as follows. In Section 2, we advance a two-stage mathematical formulation for a multi-objective stochastic multiple knapsack problem. We propose in Section 3 resolution methods with detailed descriptions of our different algorithms, which aim to provide a high-quality approximation of the Pareto front. In Section 4, the numerical results are presented and discussed, and Section 5, the last one, is devoted to the conclusion.
2 RELATED WORKS
This research builds upon prior studies of two-stage knapsack problems with random weights, notably Kosuch (2014), and extends to various stochastic models that incorporate probability constraints and allow for post-decision corrections Lisser & Lopez (2010); Klopfenstein & Nace (2008); Kosuch & Lisser (2011); Kosuch et al. (2017); Cohn & Barnhart (1998); Kosuch & Lisser (2009); Range et al. (2018); Tönissen & Schlicher (2021); Blado & Toriello (2021). These works have contributed algorithms and methods, such as branch-and-bound and branchand-price, to solve these complex problems. Our approach also draws from the MTHM procedure Laalaoui & Mhalla (2011): Martello & Toth (1990) and employs hybrid algorithms for the biobjective quadratic multiple knapsack problem Chen & Hao (2016); Chen & Hao (2015); Aïder et al. (2022), addressing the broader context of multi-objective optimization problems (MOOPs) prevalent in real-world scenarios.
Most real-world problems, like scheduling, resource allocation, etc., have many criteria to optimize. These are called multi-objective optimization problems (MOOPs). Given an m-vector function:
In multi-objective optimization, we seek solutions that a decision-maker can endorse, evaluated via objective functions in a decision space. A solution (x ∗) is Pareto optimal if no other solution in the space dominates it, meaning it is not inferior across all objectives and superior in at least one. The collection of these optimal solutions forms the Pareto set (PS), and their corresponding values create the Pareto front (PF). Pareto solutions can often be found by transforming the multi-objective problem into single-objective subproblems. Traditional methods often simplify multi-objective problems to single-objective ones. Inspired by solutions to the multi-objective capacitated arc routing problem (MO-CARP), various algorithms have been proposed, such as the memetic algorithm with extended neighborhood search (MAENS) Tang et al. (2009), and its decomposition-based variant (D-MAENS) Mei et al. (2011). The multi-objective evolutionary algorithm based on decomposition (MOEA/D) Zhang & Li (2007), and the multi-objective memetic algorithm with Pareto local search (MASNPL) Guerrouma & Aïder (2022), integrate these concepts with NSGA-II, a non-dominated sorting-based multi-objective evolutionary algorithm, which includes mechanisms like crowding distance to refine the selection process Deb et al. (2002); Chu & Yu (2018).
3 MATHEMATICAL FORMULATION
The multi-objective stochastic multiple knapsack problem (MO-SMKP) is defined as follows. Given a set of n objects (or items), a set of s knapsacks S = {1,..., s}, each item having a weight that is not known in the first stage but is known before the second stage decision is to take. Therefore, we handle the weights as random variables and assume that the random weight vector χ i of item i is independent and normally distributed with mean µ i > 0 and standard deviation σ i . We denote the respective non-zero probabilities of these L scenarii by p 1 , . . . , p L . All weights are assumed to be strictly positive. Each knapsack j, (j ∈ S) has a weight capacity C j . The stochastic multiple knapsacks problem (SMKP) consists in assigning the objects to the knapsacks in such a way that the total profit of the allocated objects is to be maximized, while the sum of the weights of the objects allocated to each knapsack does not exceed the capacity of the knapsack. Furthermore, each item has a fixed integer m-vector reward per weight unit:
The choice of a reward per unit weight stems from the fact that the value of an item often depends on its weight, and this weight is not known in advance.
The selection of an item is decided by the value of a binary variable x i j , which equals 1 if the item i is allocated to the knapsack j and 0 otherwise.
In the first stage, we place the items in the knapsacks. However, if the outcome of the total weight of these items should exceed the capacity, some of these first-stage items have to be removed in the second stage. Therefore, we restrict the percentage of cases where items lead to an overload in the first stage by introducing a chance constraint in the first stage.
At the beginning of the second stage, the weights of the items are all revealed. Then items from the first stage are removed, and additional items are selected (second-stage items) to meet the capacity constraint and/or to increase the total reward. In the case of overloading, item i must be removed, and a penalty d i , greater than the first-stage reward, must be paid. Therefore, we aim to minimize the total penalty. The removal of item i is modeled by the decision variable , which equals 1 if the item is removed from the knapsack j and 0 otherwise.
If the capacity constraint is respected, the item can be added to knapsacks if and only if this does not lead to an overload (second-stage items). If we decide to add item i to knapsack j, we set .
We assume that the second-stage reward for this item ř i > 0 is strictly smaller than its first-stage reward.
The multi-objective stochastic multiple knapsack problem is formulated as follows:
where P(A) denotes the probability of the event A, E[.] denotes the expectation, denotes the indicator function, and ř i < r i , i=1,..., n, and p ∈ [0.5, 1] is the prescribed probability.
Equation 4a aims to maximize the expected total gain. Constraints 4b are the chance constraints. Constraints 4c ensure that if an item i has been selected in the first stage and has not been deselected after, then it will be considered selected in the second stage. Constraints 4d mean that only an item selected during the first stage can be deselected. Constraints 4e and 4f ensure that items can be added only in the second stage if the selected items in the first stage do not lead to overloading and removed if overloading occurs. Constraints 4g guarantee that, in the second stage, the total weight of the items assigned to each knapsack does not exceed its capacity. Constraints 4h require that each item can be assigned to at most one knapsack. Constraints 4i require that each item added in the second stage can be assigned to at most one knapsack.
3.1 Deterministic Equivalent Problem
3.1.1 Chance constraint
In Andrieu et al. (2007) and Kosuch & Lisser (2009), the authors proposed to rewrite the objective function in a deterministic way by replacing the capacity constraint with a chance constraint that restricts the percentage (1 − ε) of cases where the chosen items lead to an overload.
We assume that the weights χ i are random variables and discretely distributed with L possible outcomes χ 1 ,..., χ L . We denote the respective non-zero probabilities of these L scenarii by p 1 , . . . , p L such that:
Then Problem (4) can be reformulated as follows:
The constraint 6c means that we must choose a subset of {1, ..., L} of scenarii whose sum of probabilities is greater than (1 − ε). Suppose that the random vector H is concentrated i n the finite number of points with l = 1, . . . , L.
We introduce an auxiliary binary variable Q l for each scenario l = 1, . . . , L, defined as follows:
Constraints 6b and 6c of Problem (6) can respectively be reformulated as follows:
where M is an arbitrary number such that:
4 RESOLUTION METHOD
We solve the MO-SMKP problem according to the following scenario. As the weight of each element is not yet known in the first step, we assume that it varies around a mean value. However, we have to decide in advance which items to accept. Typically, subsequent rejection of an item due to overcapacity entails additional costs. We, therefore, have to limit the risk of overload. In case of the capacity being not reached by the total weight of items selected in advance, other items can be added in the second stage. To reduce additional costs (such as the payment of a penalty d i for each item i removed), we may want to avoid removing an item in the second stage in favor of a more profitable one for the same reason that the risk of overloading must be limited.
First, the original MO-SMKP problem is decomposed into several multi-objective stochastic multiple knapsack problem (SO-SMKP) subproblems. Specifically, given the objective vector F(x) = (f 1(x), f 2(x), . . ., f m (x)) and the weight vector Λ = (λ 1 , λ 2 , . . . , λ m ), where the sum of the weight vectors must equal 1, the objective function of a subproblem is defined as follows:
We can write our objective function J k (x, χ) as follows:
The weight vectors are calculated based on the value of the Euclidean norm and parameter ω i as follows:
where:
-
- ωk is given by:
-
- m is the number of the objective functions,
-
- fk (x) is the value of the k th objective function for a solution x,
-
- ∥f(x)∥ is the Euclidean norm, given by:
Once the individual weights are determined for all objectives, they are combined into a single-objective function F defined as follows:
4.1 Population initialization
The initial population is generated using the greedy constructive heuristic, which follows the principle of filling the first knapsack, then the second one, with only the remaining items, and so on. For achieving this, the following procedure is called m times, with the capacity Č j = C j of the current knapsack and the current solution represented as Z i . This process is repeated until no more items can be assigned to any knapsack without violating a capacity constraint, generating our initial population of size N.
The items are assumed to be sorted non-increasingly based on the profit-to-weight ratios:
Additionally, the knapsack capacities are assumed to be sorted in non-decreasing order:
4.1.1 Subpopulation construction
To create a new individual in the population, we need to manipulate the reward of each objective function. To do this, we use a vector called vector_reward V, which represents the ratio of how we want to manipulate and favor the objective functions. For instance, if we want to favor only the first objective function, the vector_reward will be V = (1, 0, . . . , 0), where each value in the vector will be multiplied by the reward. This means that the new rewards for each objective function will be calculated as:
For the first “number_of_objectives” individuals in the population, we want to favor the m th objective function by setting 1 in the m th element of the vector_reward and 0 otherwise. Then, we use this new_rewards to feed into our greedy algorithm to obtain a new individual. For the rest of the population, we first evaluate the previous individuals that are already in our population, and then we search for the maximum value max∗ from all the values evaluated. We define a new vector called vector_max by dividing each element of the vector of evaluation of the i th objective function by max∗ to obtain the normalized maximum. Based on vector_max, we create a new vector_reward:
Using this new vector_reward, we can create new_rewards and send them to our greedy algorithm to obtain a new individual.
This process is repeated until we generate a population of size N.
4.2 Improvement heuristics
To improve the obtained solutions, we use MTHMn Guerrouma & Aïder (2022), the heuristic inspired by MTHM Martello & Toth (1990). The description of these heuristics is given below.
4.2.1 MTHM heuristic
Martello & Toth (1990) proposed MTHM for solving the multiple knapsack problem (MKP) and obtained good solutions in a reasonable amount of time. The MTHM procedure assumes that the knapsacks are sorted in a non-decreasing order of their capacities (i.e. as in Equation (18)), and all items are sorted in a non-increasing order of their profit to weight ratios, (i.e. as in Equation (17)).
Phase 1: Initial solution. The greedy procedure is applied to generate the feasible initial solution of size N.
Phase 2: Rearrangement. The rearrangement procedure consists in rearranging the already found feasible solutions. Firstly, we remove all items in the current solution. Then, the items are reconsidered based on increasing profit per unit weight, where the first item is assigned to the first knapsack, the second item to the second knapsack, and so on, in a cyclic manner. If an item cannot be assigned to the required knapsack, the next knapsack is tried, and so on. Items that cannot be assigned to any knapsack are excluded and are given a value of zero (Z i = 0).
Phase 3: First improvement. The algorithm examines all pairs of items assigned to different knapsacks. If interchanging a pair of items would allow for the inclusion of a new item into the solution, the exchange is performed and would lead to a higher total profit. This process, which utilizes local search techniques, is repeated until no further exchange is possible.
Phase 4: Second improvement. In the last phase, the algorithm attempts to remove each item currently in the solution and replace it with one or more items not currently in the solution that will increase the total profit. This employs local search techniques to identify and implements the most beneficial replacements. The execution of this process stops when no further replacements are possible.
4.2.2 MTHMn heuristic
Our method is inspired by the MTHM heuristic to improve the initial solution of size N and to obtain high-quality solutions in a reasonable time.
The first step of our method involves obtaining an initial solution of size N using the greedy procedure. We assume that the knapsacks are sorted in a non-decreasing order of their capacities (i.e. as in Equation (18)), and all items are sorted in a non-increasing order of their profit to weight ratios, (i.e. as in Equation (17)).
The next step involves rearranging the feasible solutions found. All currently included items in the solution are removed, and then reconsidered according to increasing profit per unit weights, where the first item is assigned to the first knapsack, the second item to the second knapsack, and so on cyclically. If an item i cannot be assigned to the required knapsack, the next knapsack is considered, and so on. Items that cannot be assigned to any knapsack are excluded and assigned a value of zero (Z i = 0).
The third step of our algorithm is the same as the first improvement for the MTHM heuristic. This step aims to interchange all pairs assigned to different knapsacks to increase the profit.
The last step of our algorithm aims to improve the total profit by replacing items that have the minimum ratio and occupy of the capacity of each knapsack with other items that are not currently in the solution. This phase employs local search techniques and implements the most beneficial replacements. The execution stops when no further replacements are possible.
4.3 NSGA-II algorithm
Our memetic algorithm with either MTHM or MTHMn (Algorithm 6) is inspired by the nondominated sorting genetic algorithm II (NSGA-II), one of the most popular multi-objective optimization algorithms that is more efficient than its previous version NSGA. The algorithm tends to spread quickly, and its main advantage is its strategy for preserving the diversity of solutions. The NSGA-II algorithm can be detailed as follows:
Phase 1: Population Initialization. The population is initialized based on the problem range and constraints.
Phase 2: Non-Dominated Sort. The initialized population is sorted based on non-domination.
The fast sort algorithm is described in Subsection 3.4.
Phase 3: Crowding Distance. The value of the crowding distance is assigned to each individual in the initialized population by applying the crowding distance algorithm as described in Subsection 3.5.
Phase 4: Selection. The selection of individuals is accomplished using binary tournament selection with a crowded-comparison operator to select the parents for the next generation.
Phase 5: Genetic Operators. Real-coded GA using simulated binary crossover and polynomial mutation.
Phase 6: Recombination and Selection. The offspring population and the current generation population are combined, and the individuals of the next generation are selected. The new generation is filled by each front subsequently until the population size exceeds the current population size.
4.4 Non-dominated sort algorithm
The non-dominated sort algorithm (Algorithm 4) is primarily designed to categorize each member of a population into distinct non-domination levels.
This process begins by identifying individuals belonging to the first non-dominated front of a population of size N, where each individual in this front is not dominated by other individuals, and its domination count η p is set to zero.
Upon completion of this initial step, two entities are computed for each individual:
-
The first entity is the domination count η p who define the number of solutions which dominate the solution p.
-
The second entity is S p who define a set of solutions that the solution p dominates.
To identify the solutions belonging to the second non-dominated front, we visit each member q in the set S p and decrease its domination count by one. If the domination count of any member q becomes zero, we add it to a separate list Q, which contains the solutions of the second nondominated front and comprises all individuals for which the domination count becomes zero. We repeat the same process for each member of Q to identify the third non-dominated front until all fronts are identified. At this point, every individual in the population of size N is assigned to a non-domination level and will not be visited again.
4.5 Crowding-distance algorithm
The crowding distance is a secondary criterion for discriminating between solutions sharing the same rank. It measures the Euclidean distance between neighboring individuals in an m-dimensional space.
Algorithm 5 below outlines the crowding-distance computation procedure of all solutions in a non-dominated set P.
To compute the crowding distance value for each individual, a set of steps is followed.
Firstly, the population is sorted in ascending order based on the value of each objective function. Then, for each objective function, the boundary solutions with the highest and lowest objective function values are assigned infinite crowding distance values to ensure their inclusion in the solution set. For an intermediate solution indexed by i and the k th objective function, the crowding distance value is computed using the formula:
In Formula (21), P[i] · k denotes the k th objective function value of the i th individual in the set P, and and represent the maximum and minimum values of the k th objective function, respectively. The overall crowding-distance value of a solution is determined by summing up the individual crowding-distance values computed for each objective function.
At this juncture, a distance metric is allocated to each member of the population set P. Solutions with smaller distance values are considered to be relatively more crowded than other solutions. This is precisely what the proposed crowded comparison operator compares.
4.5.1 Crowded-comparison operator
The crowded-comparison operator is utilized throughout the algorithm to guide the selection process and ensure a uniformly distributed Pareto-optimal front. The crowding distance is introduced only when selecting individuals from the same non-domination rank, and in this case, it serves as a criterion for selecting individuals within that rank.
Assuming that each individual in the population has two attributes namely, non-domination rank and crowding distance individuals are selected using a binary tournament selection with the crowded-comparison operator. The following rules govern the selection process:
-
- If both x and y are solutions and are in different ranks, (x rank ) ≠ (y rank ), a solution with lower rank is selected.
-
- If both x and y are solutions and are in the same rank, (x rank ) = (y rank ), a solution, located in a higher crowded region and with a higher crowded space, is selected.
These selection rules ensure a well-spread Pareto-optimal front and contribute to the algorithm’s ability to find diverse and high-quality solutions.
4.5.2 Memetic algorithm with MTHM or MTHMn
In this subsection, we detail our memetic algorithm with MTHM or MTHMn for MO-SMKP, including initialization, crossover, and local search procedures.
First, the initialization phase is composed of two parts: the first one is to generate the feasible solution of size N by applying the greedy procedure, and the second one is an application of MTHMn (or MTHM) procedure with four phases to a feasible solution obtained to find a highquality set of solutions of size N within a reasonable time.
Then, the fitness of every individual is evaluated and non-dominated sorting is applied to attribute non-domination rank (i rank ) equal to its non-domination level and the crowding distance is computed for each individual i of population (i distance ).
These (i rank ) and (i distance ) are two parameters that help in selecting individuals from a greater crowded region and maintain the diversity of solutions across the Pareto front. Then, the binary tournament selection is applied to choose the parents. After that, crossover and mutation operators are conducted to generate new candidate solutions, i.e. the offspring population of size N.
4.5.3 Crossover operator
To select two parent chromosomes, the individuals with the best genes are randomly chosen from the current population. Let and represent the two parent chromosomes. A crossover point is selected randomly, dividing each parent chromosome into two substrings. The genetic information to the left (or right) of the crossover point is exchanged between the parent chromosomes. This results in creating two offspring chromosomes.
-
- The first substring from P 1 is combined with the second substring from P 2 to generate offspring 1.
-
- The first substring from P 2 is combined with the second substring from P 1 to generate offspring 2.
4.5.3.1 Mutation Each new offspring undergoes a modification, known as a mutation, with a small probability p m , determined with respect to the mutation probability.
The next step involves applying the MTHMn procedure to each offspring obtained to improve the quality of solutions generated. Subsequently, we obtain the combined population R t by merging the offspring population Q t and the parent population P t , both of size N. Non-dominated sorting and crowding distance algorithms are applied to R t to sort the individuals by non-domination level and crowding distance operator, respectively. The solutions that belong to the first nondomination front ℱ1 are considered the best solutions in R t . If the number of solutions in ℱ1 equals N, we select all its members to form the new population P t+1 . If the number of solutions in ℱ1 is less than tN, we select the remaining solutions from subsequent non-dominated fronts in the order of their ranking. Solutions from the second non-domination front ℱ2 are selected next, followed by solutions from the third front ℱ3, and so on. This process is repeated until a final set of non-dominated solutions of size N is obtained. We then use the new population P t+1 of size N for selection, crossover, and mutation to create a new population P t+1 of size N. This entire process (lines 11-28 of MAMTHMn) is repeated until the maximum number of generations NG max is reached. Note that the memetic algorithm with MTHM or MTHMn for MO-SMKP involves replacing MTHMn with MTHM.
5 NUMERICAL RESULTS
In this section, we present the results of our numerical experiments. To demonstrate the effectiveness of the proposed method, we compare its performance with that of an exact algorithm. In our experiments, we randomly generate instances with two objective functions, where weights and profits are uniformly distributed in the interval [10, 100] and set the penalty factor d to 1.5.
The knapsack capacities are also randomly and uniformly generated in the interval:
We performed all our experiments on a CPU Intel Core i5-4200U machine with 1.60 Ghz and 4 Go of RAM.
5.1 Performance comparison between MAMTHMn and an exact method
To solve the multi-objective stochastic multiple knapsack problem with an exact method, ILOG’s CPLEX solver is employed to solve the instances generated based on the specified parameters. Note that each algorithm is run 10 times, and for each instance, the optimal results are shown in the figures below.
As a first step, the two objective functions are reformulated into a single objective function as follows:
To present the Pareto front of the BO-SMKP, we vary the value of λ 1 by 0.1.
We discuss below a few numerical examples whose parameters are described in Table 1.
Figures 1a-f show, for Examples 1-6 respectively, comparisons between the sets of non-dominated solutions generated by an exact method and by our proposed algorithm (MAMTHMn).
Table 2 gives, for each example, the CPU times required to obtain the final solutions by an exact method and by the MAMTHMn.
According to all these results, we can conclude that MAMTHMn provides solutions of high quality.
5.2 Performance comparison between MTHMn and MTHM
To assess the performance of our resolution methods, we propose to compare two heuristics, MTHMn and MTHM, by applying the memetic algorithm with each of them to the same set of instances generated according to the parameters presented above. It is worth noting that we implemented all our algorithms using the MATLAB software.
-
- n: number of items.
-
- S: number of knapsacks.
-
- d: penalty.
-
- NG: number of generations.
-
- N: size of the population.
-
- ℱi: level of non-domination.
-
- CPU: time needed to treat all instances for each example (in seconds).
Table 3 shows the numbers of the final solutions of size N for each non-domination level by applying the MAMTHMn algorithm with the MTHMn heuristicd with the MTHM heuristic respectively (the memetic algorithm is generated NG times).
Numbers of solutions generated by MAMTHMn with MTHMn and with MTHM, respectively, for each non-domination level for each set of n items and each set of S knapsacks.
Based on the obtained results presented in Table 3, we can conclude that:
-
- When comparing the total CPU time for the same inputs for each example, we observed that the memetic algorithm with the MTHMn heuristic is faster than its counterpart.
-
- The memetic algorithm with the MTHMn heuristic generates a greater variety and numbers of solutions for each non-domination level.
-
- The memetic algorithm with the MTHMn heuristic maintained a better spread of solutions and converged better than the memetic algorithm with the MTHM heuristic in the obtained non-dominated front.
Therefore, based on the above results, we can conclude that the memetic algorithm with the MTHMn heuristic provides high-quality solutions.
5.3 Example MTHMn Heuristic and MTHM heuristic
We used the following parameters in the numerical experiments.
-
- Number of objective functions: 02.
-
- Number of objects: 50.
-
- Number of knapsacks: 03.
-
- Value of the penalty d: 1.5.
-
- Weights w i: generated uniformly between 100 and 500 under a normal distribution with mean w i and variance 25, for each generation.
-
- Profits : generated uniformly between 1 and 50.
We also used the data given in Table 4.
5.3.1 The initial population
Table 5 represents the initial population of size N = 25 obtained by the greedy algorithm. The values of the first objective f 1 and the second objective f 2 are calculated for each individual of the population as presented on Table 6. The initial population is then ranked into different non-domination levels using the non-dominated sort and the crowding distance algorithms.
Table 6 presents the evaluation of the initial population obtained by the greedy algorithm:
-
▸ f 1: represents the first objective value for each individual in the population;
-
▸ f 2: represents the second objective value for each individual in the population;
-
▸ η p: indicates the count of solutions that dominate solution p;
-
▸ P[i]: denotes the crowding distance value assigned to each individual in the population;
-
▸ N: represents the population size.
-
▸ The non-dominated sort and the crowding distance algorithms are used to assign each individual in the initial population to specific non-domination levels.
Then the generational loop is repeated for the new population, which undergoes a variation process.
In the variation process, each offspring is generated by selecting two parents. Binary tournament selection is used to select each parent. This involves randomly selecting two individuals and choosing the better one based on their rank in the population. The crossover operator is then applied to selected parents to create the offspring, and the resulting individual undergoes mutation. This process creates offspring of size N. The parent and offspring populations are merged into (R t = P t ∪ Q t ).
The selection phase consists of choosing the best individual of size N from a population R t of size 2N, based on a multi-objective ranking. These selected individuals are, then, assigned as the new population P t+1 .
The above procedure is applied to the solution improved with MTHM or MTHMn.
5.3.2 The results
First stage. The first stage is completed, and a population of size 25 is created for each applied heuristic. The results of the first stage are presented as follows:
Second stage The second stage represents a corrective phase that aims to correct the decisions made in the first stage. In the case of underload, items are added, while in the case of overload, items are removed. This process is applied for each heuristic, and the results are as follows:
-
▸ Table 9: presents the results of the items added in the second stage using MTHM.
-
▸ Table 10: presents the results of the items removed in the second stage using MTHM.
-
▸ Table 11: presents the results of the items added in the second stage using MTHMn.
-
▸ Table 12: presents the results of the items removed in the second stage using MTHMn.
5.4 Results of the evaluation
The fitness values of each individual in a population of size 25 are computed and ranked into distinct non-domination levels, while also calculating the corresponding crowding distance values. The results are presented as follows.
-
▸ Table 13 presents the evaluation of the final solution obtained by using the MTHMn and the MTHM heuristics.
-
▸ The total CPU-times needed to obtain our final set of Pareto optimal solutions are 21.7959988000000 seconds with MTHMn heuristic and 23.6844917000000 seconds with MTHM heuristic.
The evaluation of each method can be seen in Figure 2.
Evaluation of the final solution by applying the memetic algorithm and using each heuristic.
When comparing the results obtained by applying the algorithms mentioned above (greedy, nondominated sort, crowding-distance computation, memetic with MTHM or MTHMn), to obtain the Pareto front, a comparison of the total CPU-time reveals that the memetic algorithm with MTHMn is faster. Additionally, the solutions obtained by MTHMn dominate those obtained by MTHM, as illustrated in Figure 2.
6 CONCLUSION
We presented in this paper a model for the multi-objective stochastic multiple knapsack problem (MO-SMKP) with recourse (two-stage knapsack) and random weights (normally distributed). To address this problem, we introduce in the first stage a chance constraint to limit the probability of overloading in the second stage and propose the memetic algorithm to solve this problem.
Firstly, a greedy heuristic is applied to MO-SMKP to obtain an initial population of size N. Then we use, successively, the non-dominated sort algorithm to sort all the individuals of the population into different non-domination levels and the crowding-distance computation algorithm to determine the crowding distance value for each individual.
To improve the quality of these solutions and select parents, two different heuristics, namely MTHM and MTHMn, are applied to the population. Then a series of mutations, crossovers, and local searches are applied to the improved population to generate offspring. Further, these offspring are improved by applying one iteration of MTHMn (respectively MTHM) algorithm. The non-dominated sort algorithm and crowding-distance computation algorithm are then applied to the improved offspring to select the N best individuals of the population.
The numerical experimental results demonstrate that the memetic algorithm using the MTHMn heuristic significantly outperforms the memetic algorithm using the MTHM heuristic in terms of performance and efficiency.
Our study presents novel avenues for further research on the multi-objective stochastic multiple knapsack problem. The methodology we have employed can readily be adapted to one stage (simple recourse) for the multiple knapsack problem where the weight or reward is not known in advance. Additionally, the effectiveness of our approach demonstrates that the memetic algorithm yields benefits in both the quality of solutions obtained and the execution time. Further enhancements to the algorithm can be explored by incorporating additional ideas to improve its performance.
References
- ÄIDER M, GACEM O & HIFI M. 2022. A hybrid population-based algorithm for the bi-objective quadratic multiple knapsack problem. Expert Systems With Applications, 191: 116238.
- AKBAR M, RAHMAN S, KAYKOBAD M, MANNING E & SHOJA G. 2006. Solving the multidimensional multiple-choice knapsack problem by constructing convex hulls. Computers & Operations Research, 33(5): 1259-1273.
- ANDRIEU L, COHEN G & VÁZQUEZ-ABAD F. 2007. Stochastic programming with probability constraints. arXiv, 0708.0281.
- BAS E. 2011. A capital budgeting problem for preventing workplace mobbing by using analytic hierarchy process and fuzzy 0-1 bidimensional Knapsack model. Expert Syst. Appl., 38(10): 12415-12422.
- BLADO D & TORIELLO A. 2021. A column and constraint generation algorithm for the dynamic knapsack problem with stochastic item sizes. Mathematical Programming Computation, 13: 185-223.
- CHANG P & LEE J. 2012. A fuzzy DEA and Knapsack formulation integrated model for project selection. Comput. Oper. Res., 39(1): 112-125.
- CHEN Y & HAO J. 2015. Iterated responsive threshold search for the quadratic multiple knapsack problem. Annals of Operations Research, 226: 101-131.
- CHEN Y & HAO J. 2016. The bi-objective quadratic multiple knapsack problem: Model and heuristics. Knowl.-Based Syst., pp. 89-100.
- CHU X & YU X. 2018. Improved Crowding Distance for NSGA-II. Arxiv, .
- COHN A & BARNHART C. 1998. The stochastic knapsack problem with random weights: A heuristic approach to robust transportation planning. In: Proceedings of the Triennial Symposium on Transportation Analysis (TRISTAN III).
- DEB K, PRATAP A, AGARWAL S & MEYARIVAN T. 2002. A fast and elitist multiobjective genetic algorithm: NSGA-II. IEEE Transactions on Evolutionary Computation, 6(2): 182-197.
- DER MERWE DV & HATTINGH J. 2006. Tree knapsack approaches for local access network design. European Journal of Operational Research, 174(3): 1968-1978.
- FURINI F, LJUBIĆ I & SINNL M. 2017. An effective dynamic programming algorithm for the minimum-cost maximal knapsack packing problem. Eur J Oper Res, 262(2): 438-448.
- GAO J, HE G, LIANG R & FENG Z. 2014. A quantum-inspired artificial immune system for the multiobjective 0-1 knapsack problem. Appl Math Comput, 230: 120-137.
- GUERROUMA A & ÄIDER M. 2022. A hybridized multi-objective memetic algorithm for the multiobjective stochastic quadratic knapsack problem. Pesquisa Operacional, 42: 257386.
- HIFI M. 2004. Exact algorithms for unconstrained three-dimensional cutting problems: a comparative study. Computers & Operations Research , 31(5): 657-674.
- KLOPFENSTEIN O & NACE D. 2008. A robust approach to the chance-constrained knapsack problem. Operations Research Letters, 36(5): 628-632.
- KOSUCH S. 2014. Approximability of the two-stage stochastic knapsack problem with discretely distributed weights. Discrete Applied Mathematics, 165: 192-204.
- KOSUCH S, LETOURNEL M & LISSER A. 2017. Stochastic Knapsack Problem: Application To Transportation Problems. Pesquisa Operacional , 37(3): 597-613.
- KOSUCH S & LISSER A. 2009. Upper bounds for the 0-1 stochastic knapsack problem and a B & B algorithm. Ann. Oper. Res., 176(1): 77-93.
- KOSUCH S & LISSER A. 2011. On two-stage stochastic knapsack problems. Discrete Appl. Math., 159(16): 1827-1841.
- LAALAOUI Y & MHALLA H. 2011. Efficient heuristic for very large 0/1 multiple knapsack problems. International Journal of Computational Systems Engineering, 2(2): 112.
- LI H, YAO T, REN M, RONG J, LIU C & JIA L. 2016. Physical topology optimization of infrastructure health monitoring sensor network for high-speed rail. Measurement, 79: 83-93.
- LISSER A & LOPEZ R. 2010. Stochastic Quadratic Knapsack with Recourse. Electronic Notes in Discrete Mathematics, 36: 97-104.
- MARTELLO S & TOTH P. 1990. Knapsack Problems: Algorithms and Computer Implementations. New York: John Wiley & Sons Ltd.
- MAVROTAS G, FLORIOS K & FIGUEIRA J. 2015. An improved version of a core based algorithm for the multi-objective multi-dimensional knapsack problem: a computational study and comparison with meta-heuristics. Appl Math Comput , 270(2): 25-41.
- MEI Y, TANG K & YAO X. 2011. Decomposition-Based Memetic Algorithm for Multiobjective Capacitated Arc Routing Problem. IEEE Transactions on Evolutionary Computation , 15(2): 151-165.
- MERKLE M & HELLMAN M. 1978. Hiding information and signatures in trapdoor knapsacks. IEEE Transactions on Information Theory, 24(5): 525-530.
- MUTER I & SEZER Z. 2018. Algorithms for the one-dimensional two-stage cutting stock problem. Eur. J. Oper. Res., 271(16): 20-32.
- PEETA S, SALMAN F, GUNNEC D & VISWANATH K. 2010. Pre-disaster investment decisions for strengthening a highway network. Comput. Oper. Res. , 37(10): 1708-1719.
- PERBOLI G, GOBBATO L & PERFETTI F. 2014. Packing problems in transportation and supply chain: new problems and trends. Procedia Social and Behavioral Sciences, 111: 672-681.
- PFEIFFER J & ROTHLAUF F. 2007. Analysis of greedy heuristics and weightcoded eas for multidimensional Knapsack problems and multi-unit combinatorial auctions. In: Proc. Conf. 9th Annu. Genetic Evol. Comput.. p. 1529.
- PISINGER D. 2002. Heuristics for the container loading problem. Eur. J. Oper. Res. , 141(2): 382-392.
- RANGE TM, KOZLOWSKI D & PETERSEN NC. 2018. A shortest-path-based approach for the stochastic knapsack problem with non-decreasing expected overfilling costs. Computers & Operations Research , 97: 111-124.
- RENIERS G & SORENSEN K. 2013. An approach for optimal allocation of safety resources: Using the Knapsack problem to take aggregated cost-efficient preventive measures. Risk Anal., 33(11): 2056-2067.
- SIMON J, APTE A & REGNIER E. 2017. An application of the multiple knapsack problem: the self-sufficient marine. Eur. J. Oper. Res. , 256(3): 868-876.
- TAILLANDIER F, FERNANDEZ C & NDIAYE A. 2002. Real estate property maintenance optimization based on multiobjective multidimensional Knapsack problem. Comput.-Aided Civil Infrastruct. Eng., 141(2): 382-392.
- TANG K, MEI Y & YAO X. 2009. Memetic Algorithm With Extended Neighborhood Search for Capacitated Arc Routing Problems. IEEE Trans Evol Comput, 13(5): 1151-116.
- TÖNISSEN D & SCHLICHER L. 2021. Using 3D-printing in disaster response: The twostage stochastic 3D-printing knapsack problem Author links open overlay panel. Computers & Operations Research , 133: 105356.
- ZHANG Q & LI H. 2007. MOEA/D: A Multiobjective Evolutionary Algorithm Based on Decomposition. IEEE Trans. Evol. Comput., 11: 712-731.
















