0% found this document useful (0 votes)
24 views14 pages

CLP Solver LNS

Slide MLDM

Uploaded by

Chu Thanh Thong
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
24 views14 pages

CLP Solver LNS

Slide MLDM

Uploaded by

Chu Thanh Thong
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 14

Computers & Operations Research 154 (2023) 106199

Contents lists available at ScienceDirect

Computers and Operations Research


journal homepage: www.elsevier.com/locate/cor

A Large Neighbourhood Search Algorithm for Solving Container Loading


Problems
Özge Şafak, Güneş Erdoğan ∗
School of Management, University of Bath, BA1 7AY, Bath, UK

ARTICLE INFO ABSTRACT

Keywords: This paper presents a Large Neighbourhood Search (LNS) algorithm that finds an effective packing of a set
Container loading problem of items into containers. The aim of the LNS algorithm is to provide packing solutions that can be adopted
Large neighbourhood search by many logistics companies. The LNS algorithm can handle a set of side constraints such as orientation,
stacking, and separation as well as weight limit, loading priorities, and stability to address the issues arising
for loading the items. The packing solution is also visualised and animated using an Excel workbook to help
the workers for loading of the items. Finally, the authors present a comparison between the performance of
the LNS algorithm and the state-of-the-art algorithms from the literature based on benchmark data sets. The
results demonstrate the quality of the solutions achieved by the LNS algorithm.

1. Introduction In this paper, we present a Large Neighbourhood Search (LNS) algo-


rithm that provides near optimal solutions to multi CLPs in reasonable
Efficient loading of items into containers is central to many ac- computing time, which is crucial for practical applications. We have
tivities in logistical planning. This problem arises in many industrial implemented the LNS algorithm into an Excel workbook named CLP
applications such as loading of container ships and pallets, air cargo Spreadsheet Solver, which stores item and container data, efficiently
management, and warehouse management. Reducing the number of determines the packing of items into the containers, and graphically
containers required and increasing the value of items loaded can result presents the results. CLP Spreadsheet Solver is open-source; it may be
in significant profits, which is crucial for the survival of a company used, modified, and distributed freely, and is available upon request
in a competitive market. According to Bowes (2021) Parcel Shipping from the second author.
Index, global shipping volume exceeded 100 billion parcels in 2020 The main contributions of this paper are:
and is expected to more than double by 2026. Covid-19 crisis also had
a booster effect on the parcel shipment volume due to the significant • To the best of our knowledge, this is the first study which presents
increase in the number of e-commerce shoppers. Based on these trends, a Large Neighbourhood Search (LNS) algorithm that can effi-
optimising the packing of items into containers is evermore crucial to ciently solve variants of multi container loading problems de-
transport more items while simultaneously reducing the costs. pending on the degree of heterogeneity of the items and contain-
The problem considered in this paper is a multi Container Loading ers.
Problem (CLP) which aims to pack a set of given items into containers • Our LNS algorithm can effectively handle a set of side constraints
so that the total value of the items packed is maximised (Junqueira such as orientation, stacking, and separation as well as weight
et al., 2012a). The basic variant of the CLP only contains constraints limit, loading priorities, and stability.
about non-overlap of packed items and the boundaries of the con- • We present an Excel spreadsheet that efficiently determines the
tainers. In many industrial applications, CLP needs to be enriched packing of items into the containers and visualising and animating
with side constraints e.g., load stability, item-container compatibility, the packing solution in 3D.
and orientation constraints. However, these constraints are likely to
increase the complexity of the problem at hand, since the basic CLP The rest of the paper is organised as follows. In Section 2, we
is known to be NP-Hard (Pisinger, 2002). Consequently, finding an review the related literature on the CLP and its variants. In Section 3,
optimal packing of items in the containers while satisfying a variety we define the CLP along with the side constraints that we accommo-
of real world constraints is a non-trivial task. date. We present our LNS algorithm in Section 4. Section 5 provides

∗ Corresponding author.
E-mail addresses: osa33@bath.ac.uk (Ö. Şafak), G.Erdogan@bath.ac.uk (G. Erdoğan).

https://doi.org/10.1016/j.cor.2023.106199
Received 26 May 2022; Received in revised form 18 January 2023; Accepted 20 February 2023
Available online 1 March 2023
0305-0548/© 2023 The Authors. Published by Elsevier Ltd. This is an open access article under the CC BY license (http://creativecommons.org/licenses/by/4.0/).
Ö. Şafak and G. Erdoğan Computers and Operations Research 154 (2023) 106199

computational results showing the quality of our solutions on bench- (2019) ensure that an item placed below other items must have enough
mark instances, comparing them with the results from the literature. resistance to support the pressure that is applied over its top face.
Section 6 concludes the paper along with future research directions. Complete shipment constraints require that if any part of a certain
subset is loaded, then all other items belonging to it must be loaded
2. Literature review (see Bischoff and Ratcliff, 1995; Eley, 2003; Bortfeldt and Wäscher,
2013).
In this section, we provide an analysis of the literature on the CLP
Separation constraints prohibit certain items being loaded into the
based on five features. First, we address the set of side constraints that
same container, e.g. foodstuff and perfumery articles should be trans-
arise in practice. Next, we review some constructive heuristics that
ported separately (Eley, 2003). According to Bortfeldt and Wäscher
provide initial solutions as well as improvement heuristics along with
(2013), separation constraints have not received much attention from
metaheuristics for the CLP. We also review some exact approaches.
Finally, we provide a brief review of the existing studies for the solution researchers.
visualisation of CLP. Positioning constraints restrict the position of items within the
container (Bortfeldt and Wäscher, 2013). In this context, multi-drop
2.1. Constraints in container loading constraints are commonly used in practice in such a way that items
are loaded by taking into account the delivery route of the vehicle.
As pointed out in the survey of Zhao et al. (2016) who review 113 As Zhao et al. (2016) state the aim of the multi-drop constraints is
papers that cover all variants of the CLP, there is a lack of studies to avoid unnecessary unloading and reloading of large items at every
which incorporate a set of real-world constraints. For a comprehensive destinations, see Terno et al. (2000), Gendreau et al. (2006), Fuellerer
review of such constraints, we refer the reader to Bortfeldt and Wäscher et al. (2010), Iori and Martello (2010), Junqueira et al. (2012b),
(2013), wherein the authors categorise them related to the container, Ceschia and Schaerf (2013) and Pollaris et al. (2016).
items, cargo, positioning, and load. Load stability can be distinguished between vertical and horizontal
Weight limit constraint, which is crucial whenever heavy items stability. Vertical stability, which prevents items from falling down,
have to be loaded, requires that the sum of the weights of the loaded
is achieved through supporting the bottom of items by either the
items must be less than or equal to the given weight limit of the
container floor or by the items underneath (Bortfeldt and Wäscher,
container. Terno et al. (2000), Bortfeldt and Gehring (2001), Egeblad
2013). While several papers (e.g. Eley, 2002; Liu et al., 2011; Zhang
et al. (2010), Fuellerer et al. (2010), and Correcher et al. (2017) are
et al., 2012; Junqueira et al., 2012a; Ceschia and Schaerf, 2013; Liu
examples of studies in which the weight constraint for the stowed load
is incorporated into the CLP. et al., 2014) guarantee full support, others (e.g. Gendreau et al., 2006;
Weight distribution constraints ensure that weight is distributed Fuellerer et al., 2010) require partial support, at least as much the pre-
along the container. This is significantly important for handling and specified minimum fraction of the base area. In addition, horizontal
shipping the loaded container, since an unbalanced load may cause stability avoids shifting of items significantly during transport. Full hor-
item shifts, thereby resulting in damaged items (see Bortfeldt and izontal stability ensures that each item is either horizontally adjacent
Wäscher (2013)). Eley (2002) aims to achieve an even weight distri- to another item or a container wall (Bortfeldt and Wäscher, 2013). Liu
bution along the container length since this side defines the longest et al. (2011) only requires that at least one side of the item is to touch
container edge. More recently, Ramos et al. (2018) adopt vehicle the walls of the container or the sides of other items.
specific diagrams that show the admissible cargo weight as a function
of the position of the centre of gravity of the cargo, thus complying with
the regulations. Júnior et al. (2019) desire to have the load’s centre of 2.2. Constructive heuristics
gravity close to the geometric centre of the container.
When all items cannot be loaded due to insufficient capacity, load-
There is a wide range of heuristics to decide how to put items into
ing priorities of items come into play. Some items containing products
the container. In this paper, we only analyse the most commonly used
with a closer due date or expiration date may have greater priority than
heuristics, namely, wall-building and layer-building.
others (Junqueira et al., 2012a). According to Bortfeldt and Wäscher
(2013), although loading priorities are very important, they have not George and Robinson (1980) introduce a wall-building algorithm
been paid enough attention in the design of algorithms. As an exam- by constructing vertical walls that fill the width and height of the
ple, Ren et al. (2011) set the priority of items to maximise volume container. Although the wall-building approach tackles a set of simpler
utilisation. two-dimensional problems instead of a CLP, the main disadvantage of
There are six orientations for an item. As stated by Bortfeldt and this approach is to lose space when items do not fully utilise the depth
Wäscher (2013), it is common practice that the vertical orientation is of the wall they belong to Egeblad et al. (2010). Some examples in
restricted to prevent the items from being damaged or to ensure the which the wall-building heuristic is used are Bortfeldt and Gehring
stability of the load. Chien and Deng (2004), Gendreau et al. (2006), (2001) and Pisinger (2002).
and Fuellerer et al. (2010) allow only one vertical orientation with 90◦ Bischoff and Ratcliff (1995) utilise the layer-building approach that
rotations of the items on the horizontal plane. fills the container in horizontal layers from the bottom of the container
Stacking constraints (also known as load bearing constraints) re- upwards. Their motivation for this approach is to achieve a high degree
strict how items are placed on top of each other (see Bortfeldt and
of stability in contrast to wall-building approach where the height
Wäscher (2013)). In the literature, stacking constraints are introduced
of adjacent walls varies significantly or where gaps exist between
in several ways. Terno et al. (2000) and Sciomachen and Tanfani
them. Terno et al. (2000), Lim et al. (2012), and Júnior et al. (2019)
(2007) prohibit an item of a particular type being placed on top
also use the layer-building approach within their heuristic algorithm.
of another type. Gendreau et al. (2006) and Fuellerer et al. (2010)
require that no nonfragile item can be placed on top of a fragile one, The column-building heuristic aims to stack up as many items as
although fragile items can be stacked on top of each other. On the other possible. The three constructive heuristics differ in terms of the next
hand, Junqueira et al. (2012a) require that items cannot be placed point, where an item can be added, they choose. Wall-building, layer-
above a fragile item. Junqueira et al. (2012a) limit the pressure of the building, and column-building heuristics choose the rightmost, farthest
items placed above an item of a particular type. Similarly, Júnior et al. from the front-side, and the topmost points respectively.

2
Ö. Şafak and G. Erdoğan Computers and Operations Research 154 (2023) 106199

2.3. Improvement heuristics

In the literature, improvement heuristics have been commonly de-


veloped to improve solutions provided by constructive heuristics. Ex-
amples of popular metaheuristics are Genetic Algorithms (e.g. Bortfeldt
and Gehring, 2001; Wu et al., 2010), Tabu Search (e.g. Liu et al. Fig. 1. Default placement on the 𝑥∕𝑧 surface.
(2011)) and Simulated Annealing (e.g. Mack et al. (2004)). In addition
to metaheuristics, a Greedy Randomised Adaptive Search Procedure
(e.g. Moura and Oliveira (2005)) and a Variable Neighbourhood Search
number of different types, and each item type includes a few items.
(e.g. Parreño et al. (2010)) are rarely used and combined with the con-
Containers can be identical, weakly, or strongly heterogeneous.
structive heuristics to find better quality solutions. For a comprehensive
According to Wäscher et al. (2007) topology, for input minimisation
review of the improvement heuristics for the CLP, we refer the reader
type of problems, multiple stock-size cutting stock problem (MSSCSP)
to Zhao et al. (2016).
and multiple bin-size bin packing problem (MBSBPP) depending on the
degree of heterogeneity of the items and containers can be effectively
2.4. Exact approaches
solved by the LNS algorithm. These problems were addressed in only
10% of the papers reviewed in Bortfeldt and Wäscher (2013).
In contrast to heuristic methods, there are a few exact approaches
Li et al. (2014) also classify 3D packing problems into off-line and
in the literature (e.g. Chen et al. (1995), Fasano (2004), Hifi et al.
on-line environments. Characteristics of input items are known before-
(2010), Junqueira et al. (2012a), Tsai et al. (2015), and Paquay et al. hand in off-line problems, while decisions have to be made immediately
(2016)). Silva et al. (2019) compare the exact approaches for CLPs. once items arrive without full knowledge about their characteristics in
Recently, do Nascimento et al. (2021) develop an exact approach that on-line problems (Ali et al., 2022). Solution approaches for both off-line
considers the resolution of integer linear programming and constraint and on-line problems are reviewed in Ali et al. (2022). In this paper,
programming models iteratively to solve the single container loading we apply our approach to solve only off-line problems.
problem. For many industrial applications, solely optimising the objective
function such as maximising the container volume utilisation and min-
2.5. Solution visualisation imising the number of containers used yields a limited practical value.
As do Nascimento et al. (2021) point out the importance of practical
Simultaneously determining the packing patterns and visualising constraints, they should be considered in the CLP. Otherwise, customer
the solution have been rarely developed. Chien and Deng (2004) ad- satisfaction may decrease due to damaged items or incomplete ship-
dress the difficulty of loading items into the containers for the workers. ments. Therefore, as pointed out by Zhao et al. (2016), to benefit
They underline that changing the packing patterns might be needed the research community as well as make this work more likely to be
to load more items, and consequently unloading and reloading oper- adopted by practitioners, we include a set of side constraints in the
ations may take several days. To address this issue, they determine design of our LNS algorithm.
the container packing patterns (i.e., the packing order, the orientation (C1) Weight (capacity) limit: The sum of the weights of the loaded
and location of each item) and visualise the results. Chan et al. (2006) items must be less than or equal to the given weight limit of the
develop another output of loading plan for air-cargo pallets. Dereli container.
and Daş (2010) develop a computational algorithm based on a swarm (C2) Loading priorities: The loading priorities of the items are taken
intelligence algorithm, a graphical user interface, and a simulation into account. Two sets of items are considered; (i) the first set includes
program visualising the actual packing process in 3D. the items that ‘‘must be packed’’, and (ii) the second set includes the
items that ‘‘may be packed’’. Items that ‘‘must be packed’’ have the
3. Problem definition highest priority to be placed within the container.
(C3) Orientation constraints: Fig. 1 demonstrates our naming conven-
The CLP is formally defined as follows: Three-dimensional cuboid tion for the dimensions of the items and the containers, with the default
items are packed into three-dimensional rectangular containers subject placement on the 𝑥∕𝑧 surface. Examples of all orientations for an item
to two constraints: with width(𝑥) = 10 cm, height(𝑦) = 20 cm, and length(𝑧) = 40 cm are
provided in Fig. 2. The first and the third letters of the orientation show
• Each item is stowed entirely within the container so that the edge the surface the item is placed on, hence the default orientation is 𝑥𝑦𝑧.
of each item lies parallel to the edges of the container. Any other order refers to a rotation where the associated letters imply
• No two items overlap. the type of rotation, e.g. 𝑧𝑦𝑥 refers to the case where the item is still
resting on the 𝑥∕𝑧 surface, with the item is rotated so that the width
Container loading is classified as the three-dimensional (3D) rect- became the length.
angular packing problem within the general cutting and packing prob- In this work, it is assumed that item can be placed on the 𝑥∕𝑧
lem (Chen et al., 1995). Classification of the cutting and packing surfaces (see Fig. 2(a) and (b)). The user defines whether an item is
problem is provided by Bortfeldt and Wäscher (2013) as: (1) there are allowed to be placed on 𝑥∕𝑦 surface (see Fig. 2(c) and (d)) and 𝑦∕𝑧
enough containers are available to accommodate all items and (2) only surface (see 2 (e) and (f)). A 90◦ turn around its vertical axis is always
a subset of the items can be packed due to insufficient capacity of possible.
the containers. Different objectives are pursued for problems of these (C4) Stacking constraints: Heavy items are only placed on the floor,
two categories. In the first category the number of containers used is since they may crush the items they are placed on. Moreover, no items
minimised, whereas in the second category container volume utilisation are allowed to be placed on top of a fragile item, since which may be
is maximised. According to the topology proposed by Wäscher et al. damaged by the weight of the item they support. An item can be both
(2007), each category of the problem can be further distinguished with heavy and fragile at the same time.
respect to the assortment of items and the assortment of the containers. (C5) Separation constraints: If an item is not compatible with another
Items can be identical in terms of their shape and dimensions. The as- item, then they cannot be packed into the same container. Furthermore,
sortment of items is considered to be weakly heterogeneous if it consists the LNS algorithm can also handle the case of an item type not being
of relatively few different item types, and each item type contains large compatible with a container type. For example, dairy items should not
number of items. It is called strongly heterogeneous if there are large be loaded into a non-refrigerated container.

3
Ö. Şafak and G. Erdoğan Computers and Operations Research 154 (2023) 106199

Fig. 2. Orientations for an item.

Table 1
Data for Fig. 4.
Width (cm) Height (cm) Length (cm) # of items
Item type 1 10 10 10 10
Item type 2 20 20 20 10
Item type 3 30 30 30 10
Item type 4 40 40 40 10

The secondary objective is to maximise total volume packed in the


containers. The tertiary objective of our problem is minimising the
sum of the moments of the items in the containers along the mid-line
parallel to the 𝑧-axis, if balancing the items in the containers is desired
by the user. Finally, the quaternary objective is to minimise the distance
between the items of same type.
Our LNS algorithm packs items into the container using one of the
wall-building, layer-building, and column-building heuristics which are
Fig. 3. Vertical & front-side supports.
the options of the constructive heuristic. Users can select one of these
options and analyse their performances depending on the input data
they have. Fig. 4 shows the arrangements of 40 items in a container
(C6) Stability: Load stability is achieved through fully supporting
(with dimensions width (𝑥) = 120 cm, height (𝑦) = 120 cm, length
the bottom of items by either the container floor or by other items
(𝑧) = 120 cm) achieved by the LNS algorithm based on the wall-
underneath, called vertical support. In addition, the user may activate
front-side support, requiring every item to be fully supported on its building, layer-building, and column-building heuristics, respectively.
surface facing the front of the container (container’s front-side wall) Table 1 also provides the dimensions of items as well as their required
(see example in Fig. 3). The far walls (front-sides) of items of type 1 quantities. In this numerical example, items can be placed in all ori-
and type 2 are already supported by the container’s front-side wall. The entations. There is no weight limit, no loading priorities for the items,
intersection area of item of type 3 and items of type 1 is equal to the and there are no heavy or fragile items. We assume that all item types
area of the front-side of item of type 3. are compatible with each other and each item type is compatible with
In addition, the weight distribution is taken into account. If users each container type. We ensure full vertical support, but assume that
choose to balance the load, the moment of the item weights with re- front-side support is not required.
spect to the mid-line along 𝑧-axis (length) is minimised in the objective
While wall-building heuristic in Fig. 4(a) packs items by construct-
function.
In this paper, we consider a multi-objective CLP where the multi ing vertical walls from the front of the container to the back, layer-
objectives are achieved by a lexicographical approach. Our primary building heuristic in Fig. 4(b) constructs horizontal layers from the
objective is to maximise the profit of items packed, calculated as the bottom of the container to the top. In Fig. 4(c), column-building
total value of the items packed minus the cost of the containers used. heuristic builds a column with as many items as possible.

4
Ö. Şafak and G. Erdoğan Computers and Operations Research 154 (2023) 106199

Fig. 4. Solutions with different constructive heuristics.

4. Solution algorithm 4.1. Sorting the items

Items are sorted in decreasing order of their priority. Items that


We develop an LNS algorithm to solve the multi CLPs. The algorithm ‘‘must be packed’’ have the highest priority, which are again sorted
gets item and container specific information as well as the compatibility with respect to the sort criterion provided by the user. If ‘‘volume’’
data from the CLP Spreadsheet Solver. The compatibility data includes is selected, items are sorted by decreasing order of their volume. If
both whether item types are compatible with each other and whether items’ volumes are equal, they are sorted in decreasing order of their
an item type is compatible with a container type. The Large Neigh- weight. If ‘‘weight’’ is selected, items are sorted in decreasing order of
their weight and volume, respectively. If sort criterion is ‘‘max { width;
bourhood Search Algorithm first checks the feasibility of the
height; length }’’, items are sorted in decreasing order of their longest
instance. The infeasibility is reported to the user under three conditions;
edge and volume, respectively. Finally, items that ‘‘may be packed’’ are
(1) if the volume (weight) capacity of the containers are not enough to
sorted by decreasing order of the ratio of profit to volume.
pack all mandatory items, (2) if any of the items is too wide, too tall or
too long to fit into any container, (3) if at least one of the items is not 4.2. Constructive heuristic
compatible with any container. Then, the Large Neighbourhood
Search Algorithm sorts the items with respect to their priority, size, Algorithm 2 first invokes Sort Containers to determine the
and profit. Next, Constructive Heuristic (Algorithm 2) finds an order of containers to fill. Containers are ordered in descending order of
initial solution based on one of the wall-building, layer-building, and their priority, volume packed, and their cost. Next, for each container
column-building heuristics selected by the user. This is followed by the and for each item, Constructive Heuristic sorts the orientations
Improvement Heuristic (Algorithm 3) to find different solutions in decreasing order of the area of the wall which can be constructed by
those items of the same type. Let a container’s width (𝑥) and height
in the neighbourhood of the current solution through destructive and
(𝑦) be 5 cm and an item’s width, height and length be 2 cm, 2 cm,
constructive algorithms. To that end, Improvement Heuristic
3 cm, respectively. For the orientation 𝑥𝑦𝑧, the maximum area of the
randomly empties a number of containers and a subset of items from
wall which can be constructed with items of that type will be 4 × 4 =
the rest of the containers. Next, Constructive Heuristic repacks 16 cm2 . For the orientation 𝑧𝑦𝑥, the maximum area of the wall will be
removed items into the containers. Until the time limit is reached, 4 × 3 = 12 cm2 . Therefore, for this item, the orientation 𝑥𝑦𝑧 will have a
Improvement Heuristic repeats the destruction, perturbation, and higher priority than the orientation 𝑧𝑦𝑥.
construction steps to find better solutions. Details of the steps are Algorithm 2 adds items to the containers using the procedure Ad-
provided in the following subsections. dItemToContainer provided in Appendix D. Once items of a certain
type are started to be loaded into a container, all items of the same
type are attempted to be placed. If no more items of that type could be
Algorithm 1: Large Neighbourhood Search Algorithm
placed, then Algorithm 2 starts to add items of next type.
Input: Item, container, and compatibility data For each container 𝑘 ∈ 𝐶, after all items are attempted to be packed
Step 1. Feasibility Check: Check the feasibility of the instance
into the container 𝑘 ∈ 𝐶, if there is at least one item that ‘‘must be
regarding the size and weight of items, container capacities, and
packed’’ but could not be placed, Algorithm 2 sets the feasibility of the
compatibility data
Step 2. Sort Items: Sort the set of items 𝐼 with respect to their incumbent solution to FALSE.
priority, size, and profit. Next, dispersion and utilisation of the containers in the incumbent
Step 3. Constructive Heuristic: Add items to containers using solution are calculated to better place the items in the improvement
the AddItemToContainer procedure based on the selection of later. Dispersion is calculated as follows:
wall-building, layer-building and column-building heuristics. ∑
Step 4. Improvement Heuristic: While the time limit is not 𝑑𝑖𝑠𝑝𝑒𝑟𝑠𝑖𝑜𝑛 = 𝑐𝑖2 , (1)
𝑖∈𝐼
exceeded;
Step 4.a. Destroy Solution: randomly empty a number of containers, where 𝑐𝑖 is the number of containers which include the item of type 𝑖,
and remove a subset of items from the rest of the containers, 𝑖 ∈ 𝐼. For container 𝑘 ∈ 𝐶, utilisation is calculated as follows:
Step 4.b. Perturb Solution: randomly change the order of rotation (
∑ 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑣𝑜𝑙𝑢𝑚𝑒 𝑝𝑎𝑐𝑘𝑒𝑑 (𝑘)
for the items to be packed, and the order of containers to be used. 𝑢𝑡𝑖𝑙𝑖𝑠𝑎𝑡𝑖𝑜𝑛 = max ,
Step 4.c. Reconstruct Solution: repack the removed items into the 𝑘∈𝐶
𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑣𝑜𝑙𝑢𝑚𝑒 𝑐𝑎𝑝𝑎𝑐𝑖𝑡𝑦 (𝑘)
)
containers using Constructive Heuristic. 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑤𝑒𝑖𝑔ℎ𝑡 𝑝𝑎𝑐𝑘𝑒𝑑 (𝑘)
Output: Solution worksheet with item coordinates in the containers , (2)
𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑤𝑒𝑖𝑔ℎ𝑡 𝑐𝑎𝑝𝑎𝑐𝑖𝑡𝑦 (𝑘)

5
Ö. Şafak and G. Erdoğan Computers and Operations Research 154 (2023) 106199

Algorithm 2: Constructive Heuristic best_known solution. The secondary objective is to maximise the
Input: Item, container, and compatibility data total volume of containers utilised. Therefore, when both incumbent
𝐼𝑠𝐼𝑡𝑒𝑚𝐴𝑑𝑑𝑒𝑑 ← FALSE and best_known solutions are feasible and the profits of the in-
Sort Containers (Algorithm 5) cumbent and best_known solutions are the same, the best_known
𝐶 ← set of containers solution is updated only if the total volume packed in the incumbent
𝐼 ← set of item types solution is bigger than the total volume packed in the best_known
for 𝑘 ∈ 𝐶 do solution.
for 𝑖 ∈ 𝐼 do If users select the option of balancing items in the containers,
Sort the rotation order of the item of type 𝑖 for the container
𝑘∈𝐶
Algorithm 2 calculates the moment for each container 𝑚 with respect to
end the mid-point of the container floor (see Appendix C for the formula).
for 𝑖 ∈ 𝐼 do In addition, Algorithm 2 calculates the distances between the items of
𝐼𝑠𝐼𝑡𝑒𝑚𝐴𝑑𝑑𝑒𝑑 ← TRUE same type in each container 𝑚 ∈ 𝐶 as in (5) in Appendix C. Total
while (There exists at least one item of type 𝑖 ∈ 𝐼 to be packed) distance for the incumbent solution is the sum of distances for all the
and (𝐼𝑠𝐼𝑡𝑒𝑚𝐴𝑑𝑑𝑒𝑑 = TRUE) do
containers. The LNS algorithm attempts to minimise the total distance,
𝐼𝑠𝐼𝑡𝑒𝑚𝐴𝑑𝑑𝑒𝑑 ← AddItemToContainer(item of type
𝑖, container 𝑘) (Algorithm 6) in other words, items are located in such a way that the items with
end the same type are close to each other as possible and at the same time
end outermost point of the items is minimised.
𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑓 𝑒𝑎𝑠𝑖𝑏𝑙𝑒 ← TRUE It is important to note that the solution of the Constructive
for 𝑖 ∈ 𝐼 do Heuristic may not be feasible because all the items that are manda-
if (There exists at least one item of type 𝑖 ∈ 𝐼 to be packed) and tory may not be packed. In this case, the solution is still passed to the
(𝑚𝑎𝑛𝑑𝑎𝑡𝑜𝑟𝑦 (𝑖) = TRUE) then Improvement Heuristic since an infeasible solution may turn into
𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑓 𝑒𝑎𝑠𝑖𝑏𝑙𝑒 ← FALSE
exit for a feasible solution by reorganising the containers in the Improvement
end Heuristic.
end
Calculate 𝑑𝑖𝑠𝑝𝑒𝑟𝑠𝑖𝑜𝑛 for the incumbent solution 4.2.1. Packing an item to a container
Calculate 𝑢𝑡𝑖𝑙𝑖𝑠𝑎𝑡𝑖𝑜𝑛 of containers for the incumbent solution Packing starts with checking the feasibility of possible solution
if incumbent solution is better than the best known solution then when an item with type 𝑖 ∈ 𝐼 is added to the container 𝑘 ∈ 𝐶:
best_known ← incumbent
for 𝑚 ∈ 𝐶 do
1. if the item with type 𝑖 ∈ 𝐼 is compatible with the type of the
if optimise balance = TRUE then
Calculate 𝑚𝑜𝑚𝑒𝑛𝑡 (𝑚) using equation (4) container 𝑘 ∈ 𝐶.
end 2. if the volume capacity of the container 𝑘 ∈ 𝐶 is still enough to
Calculate 𝑑𝑖𝑠𝑡𝑎𝑛𝑐𝑒(𝑚) using equation (5) pack the item of type 𝑖 ∈ 𝐼.
end 3. if the weight capacity of the container 𝑘 ∈ 𝐶 is still enough to

𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑚𝑜𝑚𝑒𝑛𝑡 ∶= 𝑚∈𝐶 𝑚𝑜𝑚𝑒𝑛𝑡 (𝑚) pack the item of type 𝑖 ∈ 𝐼.

𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑑𝑖𝑠𝑡𝑎𝑛𝑐𝑒 ∶= 𝑚∈𝐶 𝑑𝑖𝑠𝑡𝑎𝑛𝑐𝑒(𝑚) 4. if the item of type 𝑖 ∈ 𝐼 is compatible with all the items already
end
packed into the container 𝑘 ∈ 𝐶.
end
Output: incumbent solution If one of the conditions does not hold, item of type 𝑖 ∈ 𝐼 is not added
to the container 𝑘 ∈ 𝐶. Only if all feasibility conditions are satisfied,
we attempt to pack item of type 𝑖 ∈ 𝐼 in its best orientation unless it
is forbidden by the user. If it is forbidden, the next orientation in 𝑂(𝑖),
where 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑣𝑜𝑙𝑢𝑚𝑒 𝑝𝑎𝑐𝑘𝑒𝑑 (𝑘) and 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑤𝑒𝑖𝑔ℎ𝑡 𝑝𝑎𝑐𝑘𝑒𝑑 (𝑘) are
where 𝑂(𝑖) is the orientation order set for the item of type 𝑖, is selected
the total volume and weight of the items packed into the container
to pack the item.
𝑘 ∈ 𝐶 and 𝑣𝑜𝑙𝑢𝑚𝑒 𝑐𝑎𝑝𝑎𝑐𝑖𝑡𝑦 (𝑘) and 𝑤𝑒𝑖𝑔ℎ𝑡 𝑐𝑎𝑝𝑎𝑐𝑖𝑡𝑦 (𝑘) are the volume
and weight limit of the container 𝑘 ∈ 𝐶, respectively. We use the addition point concept to determine the possible positions
If one the following conditions holds: in a container where the items can be placed. Let 𝑃 (𝑘) be the set of
addition points for the container 𝑘 ∈ 𝐶 in the current solution. When
1. 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑓 𝑒𝑎𝑠𝑖𝑏𝑙𝑒 = TRUE and 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑓 𝑒𝑎𝑠𝑖𝑏𝑙𝑒 = FALSE the container 𝑘 is empty, 𝑃 (𝑘) only includes the point with coordinates
2. 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑓 𝑒𝑎𝑠𝑖𝑏𝑙𝑒 = FALSE and 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑓 𝑒𝑎𝑠𝑖𝑏𝑙𝑒 = FALSE (0, 0, 0), meaning that the first item is added to the farthest left lower
and corner. When an item is placed at an addition point, 3 new addition
points are generated (closest left lower corner, farthest right lower
𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑣𝑜𝑙𝑢𝑚𝑒 𝑝𝑎𝑐𝑘𝑒𝑑 > 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑣𝑜𝑙𝑢𝑚𝑒 𝑝𝑎𝑐𝑘𝑒𝑑
corner, farthest left upper corner), at which the next items can be
3. 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑓 𝑒𝑎𝑠𝑖𝑏𝑙𝑒 = TRUE and 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑓 𝑒𝑎𝑠𝑖𝑏𝑙𝑒 = TRUE and placed (see Fig. 5).
We set the origins (𝑜𝑟𝑖𝑔𝑖𝑛 𝑥, 𝑜𝑟𝑖𝑔𝑖𝑛 𝑦, 𝑜𝑟𝑖𝑔𝑖𝑛 𝑧) of the item with type
𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑝𝑟𝑜𝑓 𝑖𝑡 > 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑝𝑟𝑜𝑓 𝑖𝑡 𝑖 ∈ 𝐼 to the coordinates of the addition point 𝑝 ∈ 𝑃 (𝑘). If 𝑜𝑟𝑖𝑔𝑖𝑛 𝑦 > 0
for a heavy item, we look for the next addition point to place the heavy
4. 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑓 𝑒𝑎𝑠𝑖𝑏𝑙𝑒 = TRUE and 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑓 𝑒𝑎𝑠𝑖𝑏𝑙𝑒 = TRUE and
item, since we do not place a heavy item on another item. We also
𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑝𝑟𝑜𝑓 𝑖𝑡 = 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑝𝑟𝑜𝑓 𝑖𝑡 and define the farthest coordinates (𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑥, 𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑦 and 𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑧) of
𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑣𝑜𝑙𝑢𝑚𝑒 𝑝𝑎𝑐𝑘𝑒𝑑 > 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑣𝑜𝑙𝑢𝑚𝑒 𝑝𝑎𝑐𝑘𝑒𝑑 the item with type 𝑖 as follows:
{
then Algorithm 2 updates the best_known with the incumbent 𝑜𝑟𝑖𝑔𝑖𝑛 𝑥 + 𝑤𝑖𝑑𝑡ℎ (𝑖) for orientation xyz,
𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑥 =
one. 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑝𝑟𝑜𝑓 𝑖𝑡 is the profit of items loaded in the incum- 𝑜𝑟𝑖𝑔𝑖𝑛 𝑥 + 𝑙𝑒𝑛𝑔𝑡ℎ (𝑖) for orientation zyx,
{
bent solution. The multi-objective CLP is handled by a lexicographical 𝑜𝑟𝑖𝑔𝑖𝑛 𝑦 + ℎ𝑒𝑖𝑔ℎ𝑡 (𝑖) for orientation xyz,
approach applied through these conditions. Our primary objective is 𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑦 =
𝑜𝑟𝑖𝑔𝑖𝑛 𝑦 + ℎ𝑒𝑖𝑔ℎ𝑡 (𝑖) for orientation zyx,
to maximise the profit. When both incumbent and best_known {
solutions are feasible, the best_known solution is updated only if 𝑜𝑟𝑖𝑔𝑖𝑛 𝑧 + 𝑙𝑒𝑛𝑔𝑡ℎ (𝑖) for orientation xyz,
𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑧 = (3)
the profit of the incumbent solution is bigger than the profit of the 𝑜𝑟𝑖𝑔𝑖𝑛 𝑧 + 𝑤𝑖𝑑𝑡ℎ (𝑖) for orientation zyx.

6
Ö. Şafak and G. Erdoğan Computers and Operations Research 154 (2023) 106199

Table 2
List of papers included in Tables 4–7.
Code Paper Code Paper
I. (1989) Ivancic et al. (1989) B.M. (1990) Bischoff and Marriott
(1990)
N. (1994) Ngoi et al. (1994) B.R. (1995) Bischoff and Ratcliff
(1995)
G.B. (1997) Gehring and Bortfeldt B.G. (1998) Bortfeldt and Gehring
(1997) (1998)
B. (2000) Bortfeldt (2000) B.G. (2001) Bortfeldt and Gehring
(2001)
E. (2002) Eley (2002) E. (2003) Eley (2003)
L. (2005) Lim et al. (2005) L.Z. (2005) Lim and Zhang (2005)
M.O. (2005) Moura and Oliveira (2005) W. (2008) Wang et al. (2008)
T. (2008) Takahara (2008) H.H. (2010) He and Huang (2010)
C. (2011) Che et al. (2011) D.D. (2011) Dereli and Das (2011)
R. (2011) Ren et al. (2011) L. (2012) Lim et al. (2012)
Z. (2012) Zhu et al. (2012) C.S. (2013) Ceschia and Schaerf (2013)
T.E.W.B. (2017) Toffolo et al. (2017) K.S.J.S.C. (2020) Kurpel et al. (2020)

of the container. If the user’s selection is layer-building, the algorithm


searches for the addition point with the minimum height, minimum
length, and minimum width, respectively. Finally, if the user’s selection
is column-building, then the algorithm selects the addition point with
minimum length, minimum width, and minimum height, respectively.
When Algorithm 6 loads item of type 𝑖 ∈ 𝐼 to the best fit addi-
tion point, we add three new addition points to the set of addition
points 𝑃 (𝑘) if added item is not fragile. We set the coordinates of
three new addition points as (𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑥, 𝑜𝑟𝑖𝑔𝑖𝑛 𝑦, 𝑜𝑟𝑖𝑔𝑖𝑛 𝑧), (𝑜𝑟𝑖𝑔𝑖𝑛 𝑥,
𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑦, 𝑜𝑟𝑖𝑔𝑖𝑛 𝑧), and (𝑜𝑟𝑖𝑔𝑖𝑛 𝑥, 𝑜𝑟𝑖𝑔𝑖𝑛 𝑦, 𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑧). Next, we delete
the addition point where the item of type 𝑖 ∈ 𝐼 is placed. For
each container 𝑘 ∈ 𝐶, the solution is also updated by adding the
𝑣𝑜𝑙𝑢𝑚𝑒 (𝑖) and 𝑤𝑒𝑖𝑔ℎ𝑡 (𝑖) of loaded item to 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑣𝑜𝑙𝑢𝑚𝑒 𝑝𝑎𝑐𝑘𝑒𝑑 (𝑘)
and 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑤𝑒𝑖𝑔ℎ𝑡 𝑝𝑎𝑐𝑘𝑒𝑑 (𝑘), respectively. Similarly, total volume
and weight packed for the incumbent solution is also updated by
Fig. 5. Three new addition points on an item. adding the 𝑣𝑜𝑙𝑢𝑚𝑒 (𝑖) and 𝑤𝑒𝑖𝑔ℎ𝑡 (𝑖) of loaded item to
𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑣𝑜𝑙𝑢𝑚𝑒 𝑝𝑎𝑐𝑘𝑒𝑑 and 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑤𝑒𝑖𝑔ℎ𝑡 𝑝𝑎𝑐𝑘𝑒𝑑. The profit of the
incumbent is calculated as follows:
These coordinates can be computed similarly for other orientations.
𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑝𝑟𝑜𝑓 𝑖𝑡
For the addition point 𝑝 ∈ 𝑃 , we check whether the item of {
type 𝑖 ∈ 𝐼 fits inside the container 𝑘 ∈ 𝐶 through the conditions: 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑝𝑟𝑜𝑓 𝑖𝑡 + 𝑝𝑟𝑜𝑓 𝑖𝑡 (𝑖) − 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑐𝑜𝑠𝑡 (𝑘) if |𝐼 (𝑘) | = 1,
=
𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑥 ≤ 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑤𝑖𝑑𝑡ℎ (𝑘), 𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑦 ≤ 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 ℎ𝑒𝑖𝑔ℎ𝑡 (𝑘), and 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑝𝑟𝑜𝑓 𝑖𝑡 + 𝑝𝑟𝑜𝑓 𝑖𝑡 (𝑖) if |𝐼 (𝑘) | > 1,
𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑧 ≤ 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑙𝑒𝑛𝑔𝑡ℎ (𝑘). If at least one of the corners stays
outside of the container, we attempt to put the item of type 𝑖 ∈ 𝐼 to where 𝐼(𝑘) is the set of items placed in the container 𝑘 ∈ 𝐶 so far.
the next addition point. Next, we check the feasibility regarding the
corners of other items in the same container 𝑘 ∈ 𝐶, i.e. they should not 4.2.2. Sorting the containers
overlap with each other. Sort Containers (Algorithm 5) in Appendix B determines the
We guarantee vertical support and optional front-side support for order of containers to fill. If a generated random number is greater
the items. If 𝑜𝑟𝑖𝑔𝑖𝑛 𝑦 = 0, the bottom of the item is already supported than or equal to the threshold value (𝜏), then Algorithm 5 orders the
by the container’s floor. Otherwise, the intersection area of the item of containers randomly. Otherwise, Algorithm 5 first sorts the containers
type 𝑖 ∈ 𝐼 and items directly below it should be equal to the bottom in decreasing order of containers’ priority. For the containers with equal
area of the item of type 𝑖 ∈ 𝐼. Similarly, if 𝑜𝑟𝑖𝑔𝑖𝑛 𝑧 = 0, the front-side priority, Algorithm 5 sorts them in descending order by volume packed
wall of the item is already supported by the container’s front-side wall. of the containers in a given solution. If the containers that ‘‘may be
Otherwise, the intersection area of the item of type 𝑖 and the item which packed’’ share the same amount of volume packed, then Algorithm 5
is in front of the item of type 𝑖 should be equal to the area of the front- sorts them in decreasing order of the ratio of cost to volume capacity
side of the item of type 𝑖, if front-side support option is selected by of the container.
the user. If the conditions for vertical and optional front-side support
cannot be satisfied, we attempt to place the item to the next addition 4.3. Improvement heuristic
point.
Algorithm 6 tries to fit item of type 𝑖 to all addition points 𝑝 ∈ 𝑃 (𝑘) The Improvement Heuristic starts with setting the incum-
by taking into account the feasibility conditions. Then, the algorithm bent solution to best_known solution with a probability of 𝜆 = 0.65.
selects the best fit position among the candidate addition points accord- Next, Improvement Heuristic randomly perturbs the order of
ing to the user’s choice of constructive heuristic. If the wall-building is rotations and the order of items in the incumbent solution to diversify
selected, the algorithm selects the deepest addition point. Among the the search. For each item type and each orientation 𝑜, we generate
addition points at deepest area, the algorithm selects the one at lower a random number. If the random number is less than 0.2, then we
height. If there are more than one addition point with minimum depth swap the order of orientation 𝑜 with the order of another orientation
and minimum height, the algorithm selects the one closer to the origin selected randomly. Similarly, we generate another random number

7
Ö. Şafak and G. Erdoğan Computers and Operations Research 154 (2023) 106199

Table 3 After the destruction and construction steps, to compare the quality
Improvement over constructive heuristic.
of the best_known solution with the quality of incumbent solution,
Instance Constructive heuristic with LNS w. Wall B. Improvement Heuristic calculates the 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑑𝑖𝑠𝑡𝑎𝑛𝑐𝑒 and
Column B. Layer B. Wall B. Min Avg 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑚𝑜𝑚𝑒𝑛𝑡, if the option 𝑜𝑝𝑡𝑖𝑚𝑖𝑠𝑒 𝑏𝑎𝑙𝑎𝑛𝑐𝑒 is set to TRUE.
IMM1 25 25 25 25 25 Next, for each container 𝑘 ∈ 𝐶, Improvement Heuristic
IMM2 10 10 10 10 10 repeats the destruction and construction steps to increase the diversifi-
IMM3 21 21 21 19 19
cation on the incumbent solution until the time limit set by the user
IMM4 28 28 28 26 26
IMM5 52 52 52 51 51 is reached. In other words, the remaining time is used for reorganising
IMM6 10 10 10 10 10 the containers a time, with equal time allocated to each non-empty
IMM7 16 16 16 16 16 container. If one of the following conditions hold:
IMM8 4 4 4 4 4
IMM9 24 21 21 19 19
1. 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑓 𝑒𝑎𝑠𝑖𝑏𝑙𝑒 = TRUE and 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑓 𝑒𝑎𝑠𝑖𝑏𝑙𝑒 = FALSE
IMM10 55 55 55 55 55
IMM11 22 22 22 17 17 2. 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑓 𝑒𝑎𝑠𝑖𝑏𝑙𝑒 = FALSE and 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑓 𝑒𝑎𝑠𝑖𝑏𝑙𝑒 = FALSE
IMM12 53 53 53 53 53 and
IMM13 40 40 40 25 25
IMM14 29 29 29 27 27 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑣𝑜𝑙𝑢𝑚𝑒 𝑝𝑎𝑐𝑘𝑒𝑑 > 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑣𝑜𝑙𝑢𝑚𝑒 𝑝𝑎𝑐𝑘𝑒𝑑
IMM15 12 11 11 11 11
IMM16 29 26 26 26 26 3. 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑓 𝑒𝑎𝑠𝑖𝑏𝑙𝑒 = TRUE and 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑓 𝑒𝑎𝑠𝑖𝑏𝑙𝑒 = TRUE and
IMM17 8 8 8 7 7
IMM18 3 3 3 2 2 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑝𝑟𝑜𝑓 𝑖𝑡 > 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑝𝑟𝑜𝑓 𝑖𝑡
IMM19 3 3 3 3 3
IMM20 6 5 5 5 5 4. 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑓 𝑒𝑎𝑠𝑖𝑏𝑙𝑒 = TRUE and 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑓 𝑒𝑎𝑠𝑖𝑏𝑙𝑒 = TRUE and
IMM21 25 25 25 20 20.03
IMM22 10 10 9 8 8.97 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑝𝑟𝑜𝑓 𝑖𝑡 = 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑝𝑟𝑜𝑓 𝑖𝑡 and
IMM23 23 23 23 20 20.97
𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑣𝑜𝑙𝑢𝑚𝑒 𝑝𝑎𝑐𝑘𝑒𝑑 > 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑣𝑜𝑙𝑢𝑚𝑒 𝑝𝑎𝑐𝑘𝑒𝑑
IMM24 7 7 7 5 5.67
IMM25 5 5 5 5 5
5. 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑓 𝑒𝑎𝑠𝑖𝑏𝑙𝑒 = TRUE and 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑓 𝑒𝑎𝑠𝑖𝑏𝑙𝑒 = TRUE and
IMM26 4 4 4 3 3
IMM27 6 5 5 5 5
IMM28 13 10 10 10 10
𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑝𝑟𝑜𝑓 𝑖𝑡 = 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑝𝑟𝑜𝑓 𝑖𝑡 and
IMM29 20 20 19 17 17 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑣𝑜𝑙𝑢𝑚𝑒 𝑝𝑎𝑐𝑘𝑒𝑑 = 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑣𝑜𝑙𝑢𝑚𝑒 𝑝𝑎𝑐𝑘𝑒𝑑 and
IMM30 28 24 24 22 22 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑚𝑜𝑚𝑒𝑛𝑡 < 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑚𝑜𝑚𝑒𝑛𝑡
IMM31 16 14 14 13 13
IMM32 4 4 4 4 4 6. 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑓 𝑒𝑎𝑠𝑖𝑏𝑙𝑒 = TRUE and 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑓 𝑒𝑎𝑠𝑖𝑏𝑙𝑒 = TRUE and
IMM33 5 5 5 4 4.97
IMM34 9 9 9 8 8 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑝𝑟𝑜𝑓 𝑖𝑡 = 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑝𝑟𝑜𝑓 𝑖𝑡 and
IMM35 3 3 3 2 2
IMM36 14 14 14 14 14 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑣𝑜𝑙𝑢𝑚𝑒 𝑝𝑎𝑐𝑘𝑒𝑑 = 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑣𝑜𝑙𝑢𝑚𝑒 𝑝𝑎𝑐𝑘𝑒𝑑 and
IMM37 23 23 23 23 23 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑚𝑜𝑚𝑒𝑛𝑡 = 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑚𝑜𝑚𝑒𝑛𝑡 and
IMM38 45 45 45 45 45
𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑑𝑖𝑠𝑡𝑎𝑛𝑐𝑒 < 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑑𝑖𝑠𝑡𝑎𝑛𝑐𝑒
IMM39 16 16 16 15 15
IMM40 9 9 9 8 8.94
IMM41 16 16 16 15 15
the Improvement Heuristic 3 sets the best_known solution
IMM42 6 5 5 4 4 to the incumbent solution.
IMM43 4 4 3 3 3
IMM44 4 4 4 4 4
IMM45 3 3 3 3 3
IMM46 2 2 2 2 2 4.4. Solution visualisation
IMM47 4 4 4 3 3
Total 774 755 752 696 700.54 Fig. 6 shows a snapshot of visualisation of a packing solution in 3D.
It contains semi-transparent cuboids depicting the containers and the
items packed into the containers. Users can also animate the loading
plan. Furthermore, users can move the shapes around to see if they
can arrive at a better solution.
for each item type 𝑖 ∈ 𝐼. If this random number is less than 0.1,
we swap the order of item type 𝑖 with the order of another item 5. Computational experiments
type selected randomly. For each container 𝑘 ∈ 𝐶, Improvement
Heuristic destroys the incumbent solution either by emptying We now provide comparisons between our LNS algorithm and var-
the container with a probability of (1- 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑣𝑜𝑙𝑢𝑚𝑒 𝑝𝑎𝑐𝑘𝑒𝑑(𝑘) / ious algorithms from the literature based on their performance on
𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑣𝑜𝑙𝑢𝑚𝑒 𝑐𝑎𝑝𝑎𝑐𝑖𝑡𝑦(𝑘))/ 2 or removing a random subset of items benchmark data sets for both input minimisation and output maximi-
from the container. If the incumbent solution is infeasible and item sation problems. We have implemented LNS algorithm using Visual
of type 𝑖 is not mandatory to be packed, we remove the item of type Basic Application into CLP Spreadsheet Solver. All experiments are
𝑖. Otherwise, we randomly determine the whether to remove the item
performed on a computer with a 1.60 GHz - 1.80 GHz Intel R Core
of type 𝑖. When some items are removed from the container 𝑘 ∈ 𝐶,
TM CPU i5-8265U and 16 GB main memory. We give the list of papers
Algorithm 3 also removes the remaining items from the container 𝑘 ∈ 𝐶
that we compare our results against in Table 2.
since the remaining items might be unstable or vertical and optional
front-side support might not be ensured. To satisfy the feasibility
conditions, remaining items are packed into the container 𝑘 ∈ 𝐶 5.1. Results for input minimisation problem
using the AddItemToContainer(item of type i, container
k). Algorithm 3 also calls Constructive Heuristic to load the We use the data set IMM proposed by Ivancic et al. (1989). The
unpacked items into the containers. The aim of this destruction is to instance set contains 47 instances with homogeneous containers, with
find better solutions by rearranging the items. Half of 𝐶𝑃 𝑈 𝑡𝑖𝑚𝑒 𝑙𝑖𝑚𝑖𝑡 each instance using a different container size. The number of item types
set by the user is spent to repeatedly destruct and construct the solution. ranges from two to five and total number of items ranges from 47 to

8
Ö. Şafak and G. Erdoğan Computers and Operations Research 154 (2023) 106199

Table 4
Best known results for IMM instances.
Instance I. B.R. B. E. L.Z. T. C. L. Z. Z. with C.S. K.S.J.S.C. K.S.J.S.C. with LNS Alg. with VS
(1989) (1995) (2000) (2003) (2005) (2008) (2011) (2012) (2012) VS (2012) (2013) (2020) VS (2020) (min) (avg)
IMM1 26 27 25 25 25 25 25 25 25 25 25 25 25 25 25
IMM2 11 11 10 10 10 10 10 10 10 10 10 9 10 10 10
IMM3 20 21 20 20 19 20 19 19 19 19 19 19 19 19 19
IMM4 27 29 28 26 26 26 26 26 26 26 26 26 26 26 26
IMM5 65 61 51 51 51 51 51 51 51 51 51 51 51 51 51
IMM6 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10
IMM7 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16
IMM8 5 4 4 4 4 4 4 4 4 4 4 4 4 4 4
IMM9 19 19 19 19 19 19 19 19 19 19 19 19 19 19 19
IMM10 55 55 55 55 55 55 55 55 55 55 55 55 55 55 55
IMM11 18 19 18 17 16 16 16 16 16 17 17 16 16 17 17
IMM12 55 55 53 53 53 53 53 53 53 53 53 53 53 53 53
IMM13 27 25 25 25 25 25 25 25 25 25 25 25 25 25 25
IMM14 28 27 28 27 27 27 27 27 27 27 27 27 27 27 27
IMM15 11 11 11 11 11 11 11 11 11 11 11 11 11 11 11
IMM16 34 28 26 26 26 26 26 26 26 26 26 26 26 26 26
IMM17 8 8 7 7 7 7 7 7 7 7 7 7 7 7 7
IMM18 3 3 2 2 2 2 2 2 2 2 2 2 2 2 2
IMM19 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3
IMM20 5 5 5 5 5 5 5 5 5 5 5 5 5 5 5
IMM21 24 24 21 20 20 20 20 20 20 20 20 20 20 20 20.03
IMM22 10 11 9 8 9 9 8 9 8 8 8 8 8 8 8.97
IMM23 21 22 20 20 20 20 19 20 19 20 20 19 21 20 20.97
IMM24 6 6 6 6 5 5 5 5 5 5 6 5 5 5 5.67

Table 5
Best known results for IMM instances.
Instance I. B.R. B. E. L.Z. T. C. L. Z. Z. (2012) C.S. K.S.J.S.C. K.S.J.S.C. (2020) LNS Alg. with VS
(1989) (1995) (2000) (2003) (2005) (2008) (2011) (2012) (2012) with VS (2013) (2020) with VS (min) (avg)
IMM25 6 5 5 5 5 5 5 5 5 5 5 5 5 5 5
IMM26 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3
IMM27 5 5 5 5 5 5 5 5 4 4 5 4 4 5 5
IMM28 10 11 10 10 9 10 10 9 10 10 10 9 9 10 10
IMM29 18 17 17 17 17 17 17 17 17 17 17 16 17 17 17
IMM30 24 24 22 22 22 22 22 22 22 22 22 22 22 22 22
IMM31 13 13 13 13 12 13 12 12 12 12 13 13 13 13 13
IMM32 5 4 4 4 4 4 4 4 4 4 4 4 4 4 4
IMM33 5 5 5 5 4 5 4 4 4 4 4 4 4 4 4.97
IMM34 9 9 8 8 8 8 8 8 8 8 8 8 8 8 8
IMM35 3 3 2 2 2 2 2 2 2 2 2 2 2 2 2
IMM36 18 19 14 14 14 14 14 14 14 14 14 14 14 14 14
IMM37 26 27 23 23 23 23 23 23 23 23 23 23 23 23 23
IMM38 50 56 45 45 45 45 45 45 45 45 45 45 45 45 45
IMM39 16 16 15 15 15 15 15 15 15 15 15 15 15 15 15
IMM40 9 10 9 8 9 9 8 9 8 8 8 8 8 8 8.94
IMM41 16 16 15 15 15 15 15 15 15 15 15 15 15 15 15
IMM42 4 5 4 4 4 4 4 4 4 4 4 4 4 4 4
IMM43 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3
IMM44 4 4 3 4 3 3 3 3 3 3 3 3 3 4 4
IMM45 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3
IMM46 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2
IMM47 4 3 3 3 3 3 3 3 3 3 3 3 3 3 3
Total 763 763 705 699 694 698 692 694 691 693 696 689 693 696 700.54

180. All items ‘‘must be packed’’. The objective of the problem is to need to try them out. On IMM instances, we test the performance
minimise the number of containers used (i.e., cost of each container is of constructive heuristics by turning off the improvement phase of
equal to 1.) IMM covers only a small subset of features of the CLP, since the LNS algorithm. We solve the instances by setting the constructive
there is no weight, rotation, stacking, incompatibility, load balance, or heuristic option to column, layer and wall-building separately, and then
front side support constraint. report their results in Table 3. The results show that Constructive
We report in Tables 3, 4, 5, and 6 the number of containers used Heuristic with wall-building heuristic works better than column and
in the best solution found by Constructive Heuristics (column building, layer-building heuristics. Therefore, we execute our LNS Algorithm by
layer building, and wall building) and the LNS Algorithm, along with setting the option of Constructive Heuristic to wall-building
the results from the literature. We highlight the best known solutions in in the computational experiments. It is evident from Table 3 that
bold. In order to say that there is no significantly randomisation effect Improvement Heuristic of our LNS Algorithm improves the results of
on the performance of our LNS algorithm, we run it 30 times by using the construction phase with wall-building heuristics by 8% on the
different random numbers and report the minimum and average of the average.
results. We also set 𝐶𝑃 𝑈 𝑡𝑖𝑚𝑒 𝑙𝑖𝑚𝑖𝑡 to three minutes for each instance. Our LNS algorithm has been able to obtain better results than many
There is no definitive way of telling which of the constructive of the algorithms in the literature. It is clear that our algorithm 1
heuristics will work better for a given problem instance, users will perform significantly better than the original work Ivancic et al. (1989)

9
Ö. Şafak and G. Erdoğan Computers and Operations Research 154 (2023) 106199

Table 6
Best known results for IMM instances (with separation of items).
Instance E. K.S.J.S.C. K.S.J.S.C. (2020) LNS Alg with vertical support
(2003) (2020) w. vertical support & horizontal support
Min Avg Min Avg
IMM1 27 27 27 27 27 27 27
IMM2 11 10 10 11 11 11 11
IMM3 20 20 20 20 20.83 21 21.97
IMM4 28 28 28 28 28 28 28
IMM5 51 51 51 51 51 53 53
IMM6 10 10 10 10 10 10 10
IMM7 16 16 16 16 16 16 16
IMM8 4 4 4 4 4 4 4
IMM9 19 19 19 19 19 19 19
IMM10 55 55 55 55 55 55 55
IMM11 18 17 18 18 18 19 19
IMM12 56 56 56 56 56 56 56
IMM13 25 25 25 25 25 25 25
IMM14 28 28 28 28 28 28 28
IMM15 12 12 12 12 12 12 12
IMM16 26 26 26 26 26 26 26
IMM17 9 9 9 9 9 9 9
IMM18 2 2 2 2 2 2 2
IMM19 3 3 3 3 3 3 3
IMM20 5 5 5 5 5 5 5
IMM21 21 20 20 20 20.56 21 21.1
IMM22 8 8 8 9 9 9 9.2
IMM23 21 20 21 21 21 21 21
IMM24 6 5 5 5 5.73 6 6
IMM25 5 5 5 5 5 5 5
IMM26 3 3 3 3 3 3 3
IMM27 5 5 5 5 5 5 5
IMM28 10 9 10 10 10 10 10.23
IMM29 17 16 17 17 17 17 17
IMM30 23 22 23 23 23 23 23
IMM31 13 13 13 13 13 13 13
IMM32 4 4 4 4 4 4 4
IMM33 5 5 5 5 5 5 5
IMM34 9 8 8 8 8 9 9
IMM35 3 3 3 3 3 3 3
IMM36 18 18 18 19 19 19 19
IMM37 23 23 23 23 23 23 23
IMM38 45 45 45 45 45 45 45
IMM39 15 15 15 15 15 15 15
IMM40 9 9 9 9 9 9 9
IMM41 16 16 16 16 16 16 16
IMM42 5 4 4 4 4.6 4 4.57
IMM43 4 3 3 3 3 3 3.67
IMM44 4 4 4 4 4 4 4
IMM45 3 3 3 3 3 3 3
IMM46 2 2 2 2 2 2 2
IMM47 3 4 4 4 4 4 4
Sum: 725 715 720 723 725.72 730 732.74

Table 7
Best known results for LN instances.
Instance B.M. N. B.R. G.B. B.G. B.G. E. L. M.O. W. H.H. D.D. R. L. T.E.W.B. LNS
(1990) (1994) (1995) (1997) (1998) (2001) (2002) (2005) (2005) (2008) (2010) (2011) (2011) (2012) (2017) Avg Max
LN1 62.5 62.5 62.5 62.5 62.5 62.5 62.5 62.5 62.5 62.5 62.5 62.5 62.5 62.5 62.5 62.5 62.5
LN2 90 80.7 90 89.5 96.6 89.8 90.8 80.4 92.6 90.7 97.9 86.3 97.9 96.4 93.2 91.8 94.6
LN3 53.4 53.4 53.4 53.4 53.4 53.4 53.4 53.4 53.4 53.4 53.4 53.4 53.4 53.4 53.4 53.4 53.4
LN4 55 55 55 55 55 55 55 55 55 55 55 55 55 55 55 55 55
LN5 77.2 77.2 77.2 77.2 77.2 77.2 77.2 76.7 77.2 77.2 77.2 77.2 77.2 77.2 77.2 77.2 77.2
LN6 83.1 88.7 83.1 91.1 91.2 92.4 87.9 84.8 91.7 92.9 96.7 89.2 96.3 93.5 93 89.8 92.6
LN7 78.7 81.8 78.7 83.3 84.7 84.7 84.7 77 84.7 84.7 84.7 83.2 84.7 84.7 84.7 84.5 84.7
LN8 59.4 59.4 59.4 59.4 59.4 59.4 59.4 59.4 59.4 59.4 59.4 59.4 59.4 59.4 59.4 59.4 59.4
LN9 61.9 61.9 61.9 61.9 61.9 61.9 61.9 61.9 61.9 61.9 61.9 61.9 61.9 61.9 61.9 61.9 61.9
LN10 67.3 67.3 67.3 67.3 67.3 67.3 67.3 67.3 67.3 67.3 67.3 67.3 67.3 67.3 67.3 67.3 67.3
LN11 62.2 62.2 62.2 62.2 62.2 62.2 62.2 62.2 62.2 62.2 62.2 62.2 62.2 62.2 62.2 62.2 62.2
LN12 78.5 78.5 78.5 78.5 78.5 78.5 78.5 69.5 78.5 78.5 78.5 78.5 78.5 78.5 78.5 78.5 78.5
LN13 78.1 84.1 78.1 85.6 84.3 85.6 85.6 73.3 85.6 85.6 85.6 85.6 85.6 84.9 85.6 85.4 85.6
LN14 62.8 62.8 62.8 62.8 62.8 62.8 62.8 62.8 62.8 62.8 62.8 62.8 62.8 62.8 62.8 62.8 62.8
LN15 59.5 59.5 59.5 59.5 59.5 59.5 59.5 59.5 59.5 59.5 59.5 59.5 59.5 59.5 59.5 59.5 59.5
Avg. 68.64 69 68.6 69.9 70.4 70.1 69.91 67 70.3 70.2 71.0 69.55 70.93 70.6 70.4 70.1 70.5

10
Ö. Şafak and G. Erdoğan Computers and Operations Research 154 (2023) 106199

Table 8
Our best found results for BR instances with side constraints.
Instances Output maximisation Input minimisation
Avg vol. util. (%) Max vol. util. (%) Avg # of cont. Min # of cont.
BR1 86.3 92.2 2.00 2
BR2 81.7 88.4 2.00 2
BR3 78.6 88.8 2.11 2
BR4 70.5 87.0 2.30 2
BR5 70.9 84.5 2.50 2
BR6 64.5 78.3 2.93 2
BR7 60.3 72.7 3.05 3
BR8 50.3 62.1 3.81 3
BR9 49.1 61.1 4.00 4
BR10 46.6 56.3 4.11 3
BR11 41.6 53.2 4.25 4
BR12 39.8 53.2 4.42 4
BR13 36.2 45.6 4.81 4
BR14 33.9 44.0 4.97 4
BR15 33.4 44.1 4.95 4

Fig. 6. A snapshot of visualisation worksheet.

and Bischoff and Ratcliff (1995). We also improve upon the later works including the horizontal support constraint together with the separation
by Bortfeldt (2000), Eley (2003) and Takahara (2008). It is important of items and vertical stability. Since we are the first who solves the IMM
to note that our LNS algorithm guarantees full vertical stability by instances with these additional constraints, no benchmark exists, and
supporting the bottom of items by either the container floor or by the we provide our results in the last two columns of Table 6.
items underneath. Our results with vertical stability are quite close to
the more recent works of Zhu et al. (2012), Ceschia and Schaerf (2013) 5.2. Results for output maximisation problem
and Kurpel et al. (2020) in which full vertical stability is ensured.
Although the LNS algorithm requires an additional container for the In the computational experiments, we also take the single container
instances IMM11, IMM27, IMM28, and IMM44 compared to the results problem where the aim of the problem is to maximise the volume
of Kurpel et al. (2020), our LNS algorithm performs better than the utilisation of the container. We adopt our LNS algorithm to this problem
work of Kurpel et al. (2020) for the instance IMM23, thereby difference setting by setting the profit of each item to its volume and the cost of
concerning the total number of containers used is only 3 (0.4%). the container to zero. We also set the priority of each item to ‘‘may be
We also consider the situation with the separation of items as well packed’’.
as with the consideration of vertical stability. As examined in Eley We use the LN1–LN15 instances introduced by Loh and Nee (1992)
(2003), we imposed that items of the first two types must not be stowed to compare the results of our LNS algorithm with the state of the art. In
in the same container. The results in Table 6 indicates that our LNS these instances, rotations around the horizontal axes are not allowed.
algorithm outperforms the procedure of Eley (2003). Compared to the The instance set contains 100 to 250 items with 6 to 10 different types.
work of Kurpel et al. (2020) which considers both separation of items To solve each instance, we execute the LNS algorithm for 10 min. In
and vertical stability, only for IMM2, IMM22, and IMM36, we require order to eliminate the randomisation effect, we run the LNS algorithm
an additional container. Finally, we solve the IMM test instances by 30 times for each instance. We again highlight the best results in bold

11
Ö. Şafak and G. Erdoğan Computers and Operations Research 154 (2023) 106199

Algorithm 3: Improvement Heuristic group as input minimisation problems by setting each item ‘‘must be
Input: Item, container, and compatibility data, incumbent solution, best_known packed’’.
solution, 𝜆, 𝛾 The original instances already include orientation constraints. To
while 𝐶𝑃 𝑈 𝑡𝑖𝑚𝑒 𝑙𝑖𝑚𝑖𝑡/2 is not exceeded do show the ability of LNS algorithm to handle the practical constraints,
𝑅𝑛𝑑 ← U[0,1]
if Rnd < 𝜆 then we include additional side constraints. We minimises the moment of
incumbent ← best_known the item weights along the central 𝑧-axis to achieve an even weight
Randomly perturb rotation and order of items in the incumbent solution
for 𝑘 ∈ 𝐶 do
distribution. We also ensure the vertical and horizontal stability. For the
𝑅𝑛𝑑 ← U[0,1] input minimisation problems, we additionally include the separation
if Rnd < (1- container volume packed(k) / container volume capacity(k) constraints such that the items of the first two types must not be loaded
)/2 then
Empty container 𝑘 into the same container.
else We execute the LNS algorithm for three minutes to solve each
Randomly remove a subset of items from container 𝑘
Repack remaining items in container 𝑘 instance and run the algorithm 30 times by using different random
end numbers. In Table 8, for output maximisation problems, we report the
Call Constructive Heuristic to pack removed items average and maximum volume utilisations of the container in the five
end
Set 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑑𝑖𝑠𝑡𝑎𝑛𝑐𝑒, 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑑𝑖𝑠𝑡𝑎𝑛𝑐𝑒, 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑚𝑜𝑚𝑒𝑛𝑡, 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑚𝑜𝑚𝑒𝑛𝑡 to
instances of each group and for the input minimisation problems, we
0 report the average and minimum number of containers required in the
for 𝑘 ∈ 𝐶 do five instances of each group. Since we do not allow to load the two
Calculate 𝑑𝑖𝑠𝑡𝑎𝑛𝑐𝑒(𝑘) using equation (5)
𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑑𝑖𝑠𝑡𝑎𝑛𝑐𝑒 ∶= 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑑𝑖𝑠𝑡𝑎𝑛𝑐𝑒 + 𝑑𝑖𝑠𝑡𝑎𝑛𝑐𝑒(𝑘) item types into the same container, the number of containers required
if optimise balance = TRUE then to load all items is at least 2 for each instance. As the number of item
Calculate 𝑚𝑜𝑚𝑒𝑛𝑡 (𝑘) using equation (4)
types increases, the volume utilisation of the container decreases for
𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑚𝑜𝑚𝑒𝑛𝑡 ∶= 𝑏𝑒𝑠𝑡 𝑘𝑛𝑜𝑤𝑛 𝑚𝑜𝑚𝑒𝑛𝑡 + 𝑚𝑜𝑚𝑒𝑛𝑡(𝑘)
while 𝐶𝑃 𝑈 𝑡𝑖𝑚𝑒 𝑙𝑖𝑚𝑖𝑡 𝑡𝑜𝑟𝑒𝑜𝑟𝑔𝑎𝑛𝑖𝑠𝑒 is not exceeded do output maximisation problems and the number of containers required
𝑅𝑛𝑑 ← U[0,1] to load all items increases for the input minimisation problems. We
if Rnd < 𝛾 then
incumbent ← best_known believe these generated instances with several side constraints of CLP
Randomly perturb rotation and order of items can be utilised as benchmark instances.
if Rnd < (1- container volume packed(k) / container volume capacity(k)
)/2 then
Empty container 𝑘 6. Conclusion
else
Randomly remove a subset of items from container 𝑘
Repack remaining items in container 𝑘
We have a new LNS algorithm to efficiently determine the packing
Call AddItemToContainer to pack removed items into the container of items into the containers. The main advantage of our LNS algorithm
𝑘∈𝐶 is that it is generally applicable to solve both input minimisation and
𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑓 𝑒𝑎𝑠𝑖𝑏𝑙𝑒 ← True
for 𝑖 ∈ 𝐼 do output maximisation types of CLPs with different degree of hetero-
if (There exists at least one item of type 𝑖 ∈ 𝐼 to be packed) and geneity of the items (likewise containers). Besides, our LNS algorithm
(𝑚𝑎𝑛𝑑𝑎𝑡𝑜𝑟𝑦 (𝑖) = TRUE) then
𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑓 𝑒𝑎𝑠𝑖𝑏𝑙𝑒 ← False
can accommodate many side constraints imposed by the users such as
exit for weight limit, loading priorities, orientation, stacking, separation, and
end
stability. Moreover, our LNS algorithm attempts to achieve an even
Calculate 𝑑𝑖𝑠𝑡𝑎𝑛𝑐𝑒(𝑘) using equation (5)
𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑑𝑖𝑠𝑡𝑎𝑛𝑐𝑒 = 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑑𝑖𝑠𝑡𝑎𝑛𝑐𝑒 + 𝑑𝑖𝑠𝑡𝑎𝑛𝑐𝑒(𝑘) weight distribution through minimising the moment of the item weights
if optimise balance = TRUE then along the central 𝑧-axis. We believe that the VBA implementation of
Calculate 𝑚𝑜𝑚𝑒𝑛𝑡 (𝑘) using equation (4)
𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑚𝑜𝑚𝑒𝑛𝑡 = 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑚𝑜𝑚𝑒𝑛𝑡 + 𝑚𝑜𝑚𝑒𝑛𝑡(𝑘)
our algorithm, CLP Spreadsheet Solver, is suitable be used by small and
if incumbent solution is better than the best_known solution then medium-sized enterprises as well as for teaching purposes.
best_known ← incumbent There are some future research directions arising from this work.
end
The performance of our LNS algorithm depends on a strategy that
end
Output: best_known solution destructs and perturbs the current solution. It is still an open question
how to select the strategy which eventually yields better solutions.
Furthermore, the effectiveness of the proposed algorithm could enable
the researchers to accommodate more practical constraints to meet the
in Table 7. Table 7 indicates that our LNS algorithm is very competitive requirements of other users, e.g., order of unloading must be taken into
with the state of the art for those instances. We obtain the optimality account when a truck with multiple stops is being loaded.
for 13/15 of the instances (all items are loaded in a single container).
For the remaining two instances, our LNS algorithm achieves 94.6% CRediT authorship contribution statement
and 92.6% volume utilisation, where the best known results are 97.9%
and 96.7%, respectively. Özge Şafak: Data curation, Methodology, Visualization,
Roles/Writing – original draft, Writing – review & editing. Güneş Er-
5.3. Results for BR instances doğan: Methodology, Software, Roles/Writing – original draft, Writing
– review & editing.

To test the broader application range of LNS algorithm, we generate


Data availability
a set of instances based on the single container loading instances
(known as BR instances) introduced by Bischoff and Ratcliff (1995)
Data will be made available on request.
and Davies and Bischoff (1999). The original data includes 15 groups
of 100 instances. The first seven groups include instances with weakly
Appendix A. Sorting items
heterogeneous items, i.e. the number of item types varies from 3 to 20,
while, the last eight groups contain instances with strongly heteroge- See Algorithm 4.
neous items, i.e., the number of item types varies from 30 to 100. In the
computational experiments, we only use the first 10 instances in each Appendix B. Sorting containers
group. We organised the first 5 of 10 instances in each group as output
maximisation problems and converted the last 5 of 10 instances in each See Algorithm 5.

12
Ö. Şafak and G. Erdoğan Computers and Operations Research 154 (2023) 106199

Algorithm 4: Sort Items where 𝑚𝑎𝑥 𝑧 = max𝑗∈𝐼(𝑚) 𝑖𝑡𝑒𝑚 𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑧(𝑗).


Input: item data
𝑖𝑡𝑒𝑚 (𝑖) , 𝑖 ∈ 𝐼 ← list of item types
Sort the 𝑖𝑡𝑒𝑚 (𝑖) , 𝑖 ∈ 𝐼 with respect to their priorities
𝑆 ← set of item types with 𝑚𝑎𝑛𝑑𝑎𝑡𝑜𝑟𝑦 (𝑖) = TRUE, 𝑖 ∈ 𝐼 Appendix D. Packing an item to a container
if 𝑖𝑡𝑒𝑚 𝑠𝑜𝑟𝑡 𝑐𝑟𝑖𝑡𝑒𝑟𝑖𝑜𝑛 = ‘‘volume’’ then
Sort the 𝑖𝑡𝑒𝑚 (𝑖) , 𝑖 ∈ 𝑆 in decreasing order of
𝑠𝑜𝑟𝑡 𝑐𝑟𝑖𝑡𝑒𝑟𝑖𝑜𝑛 (𝑖) ∶= 𝑣𝑜𝑙𝑢𝑚𝑒 (𝑖) × 𝑚𝑎𝑥 𝑤𝑒𝑖𝑔ℎ𝑡 + 𝑤𝑒𝑖𝑔ℎ𝑡 (𝑖), 𝑖 ∈ 𝑆,
where 𝑚𝑎𝑥 𝑤𝑒𝑖𝑔ℎ𝑡 ∶= 𝑚𝑎𝑥𝑖∈𝐼 {𝑤𝑒𝑖𝑔ℎ𝑡 (𝑖)} + 1
else if 𝑖𝑡𝑒𝑚 𝑠𝑜𝑟𝑡 𝑐𝑟𝑖𝑡𝑒𝑟𝑖𝑜𝑛 = ‘‘weight’’ then
Sort the 𝑖𝑡𝑒𝑚 (𝑖) , 𝑖 ∈ 𝑆 in decreasing order of Algorithm 6: AddItemToContainer(item of type 𝑖,
𝑠𝑜𝑟𝑡 𝑐𝑟𝑖𝑡𝑒𝑟𝑖𝑜𝑛 (𝑖) ∶= 𝑤𝑒𝑖𝑔ℎ𝑡 (𝑖) × 𝑚𝑎𝑥 𝑣𝑜𝑙𝑢𝑚𝑒 + 𝑣𝑜𝑙𝑢𝑚𝑒 (𝑖), 𝑖 ∈ 𝑆, container 𝑘)
where 𝑚𝑎𝑥 𝑣𝑜𝑙𝑢𝑚𝑒 ∶= 𝑚𝑎𝑥𝑖∈𝐼 {𝑣𝑜𝑙𝑢𝑚𝑒 (𝑖)} + 1
Input: Item, container, and compatibility data
else
𝑖𝑡𝑒𝑚 𝑚𝑎𝑥 (𝑖) ∶= max{𝑤𝑖𝑑𝑡ℎ (𝑖) , ℎ𝑒𝑖𝑔ℎ𝑡 (𝑖) , 𝑙𝑒𝑛𝑔𝑡ℎ (𝑖)}, 𝑖 ∈ 𝑆, Set 𝑚𝑖𝑛 𝑥, 𝑚𝑖𝑛 𝑦, and 𝑚𝑖𝑛 𝑧 to container’s width, height, and length, respectively
Sort the 𝑖𝑡𝑒𝑚 (𝑖) , 𝑖 ∈ 𝑆 in decreasing order of if feasibility checks listed in Section 4.2.1 fails then
Finish AddItemToContainer(item of type 𝑖, container 𝑘)
𝑠𝑜𝑟𝑡 𝑐𝑟𝑖𝑡𝑒𝑟𝑖𝑜𝑛 (𝑖) ∶= 𝑖𝑡𝑒𝑚 𝑚𝑎𝑥(𝑖) × 𝑚𝑎𝑥 𝑣𝑜𝑙𝑢𝑚𝑒 + 𝑣𝑜𝑙𝑢𝑚𝑒 (𝑖), 𝑖 ∈ 𝑆,
end
where 𝑚𝑎𝑥 𝑣𝑜𝑙𝑢𝑚𝑒 ∶= max𝑖∈𝐼 {𝑣𝑜𝑙𝑢𝑚𝑒 (𝑖)} + 1
for 𝑟 ∈ 𝑂(𝑖) do
𝑆̄ ← set of item types with 𝑚𝑎𝑛𝑑𝑎𝑡𝑜𝑟𝑦 (𝑖) = FALSE, 𝑖 ∈ 𝐼
if orientation 𝑟 for the item of type 𝑖 is forbidden by the user then
Sort the 𝑖𝑡𝑒𝑚 (𝑖) , 𝑖 ∈ 𝑆̄ in decreasing order of 𝑟𝑎𝑡𝑖𝑜 (𝑖) ∶= 𝑝𝑟𝑜𝑓 𝑖𝑡 (𝑖) ∕𝑣𝑜𝑙𝑢𝑚𝑒 (𝑖), 𝑖 ∈ 𝑆̄
Go to next 𝑟
Output: 𝑖𝑡𝑒𝑚 (𝑖) , 𝑖 ∈ 𝐼
end
for 𝑝 ∈ 𝑃 do
Set 𝑜𝑟𝑖𝑔𝑖𝑛 𝑥, 𝑜𝑟𝑖𝑔𝑖𝑛 𝑦, 𝑜𝑟𝑖𝑔𝑖𝑛 𝑧 to the coordinates of the addition point 𝑝
if item of type 𝑖 is a heavy item & 𝑜𝑟𝑖𝑔𝑖𝑛 𝑦 > 0 then
Algorithm 5: Sort Containers Go to next 𝑝
Input: container data, solution, 𝜏 end
𝐶 ← set of containers Set 𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑥, 𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑦 and 𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑧 for the orientation 𝑟 as in
′ Equation (3)
𝑆 ← set of containers such that 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑚𝑎𝑛𝑑𝑎𝑡𝑜𝑟𝑦 (𝑘) = TRUE, 𝑘 ∈ 𝐶
′′ if (𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑥 > 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑤𝑖𝑑𝑡ℎ (𝑘)) or (𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑦 > 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 ℎ𝑒𝑖𝑔ℎ𝑡 (𝑘))
𝑆 ← set of containers such that 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑚𝑎𝑛𝑑𝑎𝑡𝑜𝑟𝑦 (𝑘) = FALSE,𝑘 ∈ 𝐶
or (𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑧 > 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑙𝑒𝑛𝑔𝑡ℎ (𝑘)) then
𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 (𝑘) , 𝑘 ∈ 𝐶 ← list of containers in given solution
Go to next 𝑝
𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑣𝑜𝑙𝑢𝑚𝑒 𝑝𝑎𝑐𝑘𝑒𝑑 (𝑘) ← volume packed of the container 𝑘 ∈ 𝐶 in given
end
solution
if feasibility check for all corners w.r.t to the other items fails then
𝑅𝑛𝑑 ← U[0,1] Go to next 𝑝
if 𝑅𝑛𝑑 < 𝜏 then end
Sort 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 (𝑘), 𝑘 ∈ 𝐶 with respect to their priority
′ if 𝑜𝑟𝑖𝑔𝑖𝑛 𝑦 > 0 then
Sort 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 (𝑘) in decreasing order of 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑣𝑜𝑙𝑢𝑚𝑒 𝑝𝑎𝑐𝑘𝑒𝑑 (𝑘) , 𝑘 ∈ 𝑆 if intersection area of the item of type 𝑖 and items directly below it less
′′
Sort 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 (𝑘) in decreasing order of 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑣𝑜𝑙𝑢𝑚𝑒 𝑝𝑎𝑐𝑘𝑒𝑑 (𝑘) , 𝑘 ∈ 𝑆 than the bottom area of the item of type 𝑖 then
′′ Go to next 𝑝
for 𝑚 ∈ 𝑆 do
′′ end
for 𝑘 ∈ 𝑆 , s.t. 𝑚 ≠ 𝑘 do
if 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑣𝑜𝑙𝑢𝑚𝑒 𝑝𝑎𝑐𝑘𝑒𝑑 (𝑚) = 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑣𝑜𝑙𝑢𝑚𝑒 𝑝𝑎𝑐𝑘𝑒𝑑 (𝑘) then end
if 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑐𝑜𝑠𝑡 (𝑚) ∕𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑣𝑜𝑙𝑢𝑚𝑒 𝑐𝑎𝑝𝑎𝑐𝑖𝑡𝑦 (𝑚) ≤ if 𝑓 𝑟𝑜𝑛𝑡 𝑠𝑖𝑑𝑒 𝑠𝑢𝑝𝑝𝑜𝑟𝑡 then
𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑐𝑜𝑠𝑡 (𝑘) ∕𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑣𝑜𝑙𝑢𝑚𝑒 𝑐𝑎𝑝𝑎𝑐𝑖𝑡𝑦 (𝑘) then if 𝑜𝑟𝑖𝑔𝑖𝑛 𝑦 > 0 then
Prioritise 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 (𝑚) above 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 (𝑘) if intersection area of the item of type 𝑖 and items directly below
end it less than the bottom area of the item of type 𝑖 then
end Go to next 𝑝
end
else
Randomly reorder 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 (𝑘) , 𝑘 ∈ 𝐶 end
Output: 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 (𝑘) , 𝑘 ∈ 𝐶 end
if 𝑐𝑜𝑛𝑠𝑡𝑟𝑢𝑐𝑡𝑖𝑣𝑒 ℎ𝑒𝑢𝑟𝑖𝑠𝑡𝑖𝑐 == wall-building then
if 𝑜𝑟𝑖𝑔𝑖𝑛 𝑧 < 𝑚𝑖𝑛 𝑧 OR (𝑜𝑟𝑖𝑔𝑖𝑛 𝑧 = 𝑚𝑖𝑛 𝑧 & 𝑜𝑟𝑖𝑔𝑖𝑛 𝑦 < 𝑚𝑖𝑛 𝑦) OR
(𝑜𝑟𝑖𝑔𝑖𝑛 𝑧 = 𝑚𝑖𝑛 𝑧 & 𝑜𝑟𝑖𝑔𝑖𝑛 𝑦 = 𝑚𝑖𝑛 𝑦 & 𝑜𝑟𝑖𝑔𝑖𝑛 𝑥 < 𝑚𝑖𝑛 𝑥) then
𝑚𝑖𝑛 𝑥 ∶= 𝑜𝑟𝑖𝑔𝑖𝑛 𝑥, 𝑚𝑖𝑛 𝑦 ∶= 𝑜𝑟𝑖𝑔𝑖𝑛 𝑦, 𝑚𝑖𝑛 𝑧 ∶= 𝑜𝑟𝑖𝑔𝑖𝑛 𝑧
𝑐𝑎𝑛𝑑𝑖𝑑𝑎𝑡𝑒 𝑝𝑜𝑠𝑖𝑡𝑖𝑜𝑛 ∶= 𝑝
Appendix C. Formulas
end
else if 𝑐𝑜𝑛𝑠𝑡𝑟𝑢𝑐𝑡𝑖𝑣𝑒 ℎ𝑒𝑢𝑟𝑖𝑠𝑡𝑖𝑐 == layer-building then
The moment (𝑚𝑜𝑚𝑒𝑛𝑡(𝑚)) of the container 𝑚 is calculated as follows: if 𝑜𝑟𝑖𝑔𝑖𝑛 𝑦 < 𝑚𝑖𝑛 𝑦 OR (𝑜𝑟𝑖𝑔𝑖𝑛 𝑦 = 𝑚𝑖𝑛 𝑦 & 𝑜𝑟𝑖𝑔𝑖𝑛 𝑧 < 𝑚𝑖𝑛 𝑧) OR
(𝑜𝑟𝑖𝑔𝑖𝑛 𝑦 = 𝑚𝑖𝑛 𝑦 & 𝑜𝑟𝑖𝑔𝑖𝑛 𝑧 = 𝑚𝑖𝑛 𝑧 & 𝑜𝑟𝑖𝑔𝑖𝑛 𝑥 < 𝑚𝑖𝑛 𝑥) then
𝑚𝑖𝑛 𝑥 ∶= 𝑜𝑟𝑖𝑔𝑖𝑛 𝑥, 𝑚𝑖𝑛 𝑦 ∶= 𝑜𝑟𝑖𝑔𝑖𝑛 𝑦, 𝑚𝑖𝑛 𝑧 ∶= 𝑜𝑟𝑖𝑔𝑖𝑛 𝑧
∑ ( ) 𝑐𝑎𝑛𝑑𝑖𝑑𝑎𝑡𝑒 𝑝𝑜𝑠𝑖𝑡𝑖𝑜𝑛 ∶= 𝑝
| 𝑗∈𝐼(𝑚) 𝑖𝑡𝑒𝑚 𝑜𝑟𝑖𝑔𝑖𝑛 𝑥(𝑗) + 𝑖𝑡𝑒𝑚 𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑥(𝑗) − 𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑤𝑖𝑑𝑡ℎ(𝑚) × 𝑤𝑒𝑖𝑔ℎ𝑡(𝑡(𝑗))|
, end
2
else
(4) if 𝑜𝑟𝑖𝑔𝑖𝑛 𝑧 < 𝑚𝑖𝑛 𝑧 OR (𝑜𝑟𝑖𝑔𝑖𝑛 𝑧 = 𝑚𝑖𝑛 𝑧 & 𝑜𝑟𝑖𝑔𝑖𝑛 𝑥 < 𝑚𝑖𝑛 𝑥) OR
(𝑜𝑟𝑖𝑔𝑖𝑛 𝑧 = 𝑚𝑖𝑛 𝑧 & 𝑜𝑟𝑖𝑔𝑖𝑛 𝑥 = 𝑚𝑖𝑛 𝑥 & 𝑜𝑟𝑖𝑔𝑖𝑛 𝑦 < 𝑚𝑖𝑛 𝑦) then
𝑚𝑖𝑛 𝑥 ∶= 𝑜𝑟𝑖𝑔𝑖𝑛 𝑥, 𝑚𝑖𝑛 𝑦 ∶= 𝑜𝑟𝑖𝑔𝑖𝑛 𝑦, 𝑚𝑖𝑛 𝑧 ∶= 𝑜𝑟𝑖𝑔𝑖𝑛 𝑧
where 𝐼(𝑚) is the set of items packed in the container 𝑚 in the in-
𝑐𝑎𝑛𝑑𝑖𝑑𝑎𝑡𝑒 𝑝𝑜𝑠𝑖𝑡𝑖𝑜𝑛 ∶= 𝑝
cumbent solution and 𝑡(𝑗) is the type of item 𝑗 ∈ 𝐼(𝑚). 𝑖𝑡𝑒𝑚 𝑜𝑟𝑖𝑔𝑖𝑛 𝑥(𝑗) end
and 𝑖𝑡𝑒𝑚 𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑥(𝑗) are the 𝑥 coordinates of corners of item 𝑗. end
𝑐𝑜𝑛𝑡𝑎𝑖𝑛𝑒𝑟 𝑤𝑖𝑑𝑡ℎ(𝑚) and is the width (𝑥) of the container. 𝑤𝑒𝑖𝑔ℎ𝑡(𝑡(𝑗)) end
is the weight of the item of type 𝑡(𝑗). end
if 𝑐𝑎𝑛𝑑𝑖𝑑𝑎𝑡𝑒 𝑝𝑜𝑠𝑖𝑡𝑖𝑜𝑛 is null then
Algorithm 2 calculates the distances between the items of same type 𝐼𝑠𝐼𝑡𝑒𝑚𝐴𝑑𝑑𝑒𝑑 ∶= 𝐹 𝐴𝐿𝑆𝐸
in each container 𝑚 ∈ 𝐶 as follows: end
∑ else
𝑑𝑖𝑠𝑡𝑎𝑛𝑐𝑒(𝑚) = |𝑖𝑡𝑒𝑚 𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑥(𝑗) + 𝑖𝑡𝑒𝑚 𝑜𝑟𝑖𝑔𝑖𝑛 𝑥(𝑗) 𝐼𝑠𝐼𝑡𝑒𝑚𝐴𝑑𝑑𝑒𝑑 ∶= 𝑇 𝑅𝑈 𝐸
if item of type 𝑖 is not fragile then
𝑗,𝑠∈𝐼(𝑚)|𝑡(𝑗)=𝑡(𝑠)
𝑃 (𝑘) ∶= 𝑃 (𝑘) ∪ {(𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑥, 𝑜𝑟𝑖𝑔𝑖𝑛 𝑦, 𝑜𝑟𝑖𝑔𝑖𝑛 𝑧), (𝑜𝑟𝑖𝑔𝑖𝑛 𝑥, 𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑦,
− 𝑖𝑡𝑒𝑚 𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑥(𝑠) − 𝑖𝑡𝑒𝑚 𝑜𝑟𝑖𝑔𝑖𝑛 𝑥(𝑠)| 𝑜𝑟𝑖𝑔𝑖𝑛 𝑧), (𝑜𝑟𝑖𝑔𝑖𝑛 𝑥, 𝑜𝑟𝑖𝑔𝑖𝑛 𝑦, 𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑧)}
end
+ |𝑖𝑡𝑒𝑚 𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑦(𝑗) + 𝑖𝑡𝑒𝑚 𝑜𝑟𝑖𝑔𝑖𝑛 𝑦(𝑗) − 𝑖𝑡𝑒𝑚 𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑦(𝑠) 𝑃 (𝑘) ∶= 𝑃 (𝑘) ⧵ 𝑝
Set the coordinates of added item
− 𝑖𝑡𝑒𝑚 𝑜𝑟𝑖𝑔𝑖𝑛 𝑦(𝑠)|
Update the 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑣𝑜𝑙𝑢𝑚𝑒 𝑝𝑎𝑐𝑘𝑒𝑑, 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑤𝑒𝑖𝑔ℎ𝑡 𝑝𝑎𝑐𝑘𝑒𝑑, and
+ |𝑖𝑡𝑒𝑚 𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑧(𝑗) + 𝑖𝑡𝑒𝑚 𝑜𝑟𝑖𝑔𝑖𝑛 𝑧(𝑗) − 𝑖𝑡𝑒𝑚 𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑧(𝑠) 𝑖𝑛𝑐𝑢𝑚𝑏𝑒𝑛𝑡 𝑝𝑟𝑜𝑓 𝑖𝑡
end
− 𝑖𝑡𝑒𝑚 𝑜𝑟𝑖𝑔𝑖𝑛 𝑧(𝑠)| Return: 𝐼𝑠𝐼𝑡𝑒𝑚𝐴𝑑𝑑𝑒𝑑

+ 𝑖𝑡𝑒𝑚 𝑜𝑝𝑝𝑜𝑠𝑖𝑡𝑒 𝑧(𝑗) + (|𝐼(𝑚)|)2 ⋅ 𝑚𝑎𝑥 𝑧, (5)
𝑗∈𝐼(𝑚)

13
Ö. Şafak and G. Erdoğan Computers and Operations Research 154 (2023) 106199

References Kurpel, D.V., Scarpin, C.T., Junior, J.E.P., Schenekemberg, C.M., Coelho, L.C., 2020.
The exact solutions of several types of container loading problems. European J.
Ali, S., Ramos, A.G., Carravilla, M.A., Oliveira, J.F., 2022. On-line three-dimensional Oper. Res. 284 (1), 87–107.
packing problems: a review of off-line and on-line solution approaches. Comput. Li, Y., Tang, X., Cai, W., 2014. On dynamic bin packing for resource allocation in the
Ind. Eng. 108122. cloud. In: Proceedings of the 26th ACM Symposium on Parallelism in Algorithms
Bischoff, E.E., Marriott, M.D., 1990. A comparative evaluation of heuristics for container and Architectures. pp. 2–11.
loading. European J. Oper. Res. 44 (2), 267–276. Lim, A., Ma, H., Xu, J., Zhang, X., 2012. An iterated construction approach with
Bischoff, E.E., Ratcliff, M.S.W., 1995. Issues in the development of approaches to dynamic prioritization for solving the container loading problems. Expert Syst.
container loading. Omega 23 (4), 377–390. Appl. 39 (4), 4292–4305.
Bortfeldt, A., 2000. Eine heuristik für multiple containerladeprobleme. OR-Spektrum 22 Lim, A., Rodrigues, B., Yang, Y., 2005. 3-D container packing heuristics. Appl. Intell.
(2), 239–261. 22 (2), 125–134.
Bortfeldt, A., Gehring, H., 1998. Applying tabu search to container loading problems. Lim, A., Zhang, X., 2005. The container loading problem. In: Proceedings of the 2005
In: Operations Research Proceedings 1997. Springer, pp. 533–538. ACM Symposium on Applied Computing. pp. 913–917.
Bortfeldt, A., Gehring, H., 2001. A hybrid genetic algorithm for the container loading Liu, S., Tan, W., Xu, Z., Liu, X., 2014. A tree search algorithm for the container loading
problem. European J. Oper. Res. 131 (1), 143–161. problem. Comput. Ind. Eng. 75, 20–30.
Bortfeldt, A., Wäscher, G., 2013. Constraints in container loading–A state-of-the-art Liu, J., Yue, Y., Dong, Z., Maple, C., Keech, M., 2011. A novel hybrid tabu search
review. European J. Oper. Res. 229 (1), 1–20. approach to container loading. Comput. Oper. Res. 38 (4), 797–807.
Bowes, P., 2021. Pitney bowes parcel shipping index. https://www.pitneybowes.com/ Loh, T., Nee, A., 1992. A packing algorithm for hexahedral boxes. In: Proceedings of
us/shipping-index.html, Accessed November 2021. the Conference of Industrial Automation, Singapore. pp. 115–126.
Ceschia, S., Schaerf, A., 2013. Local search for a multi-drop multi-container loading Mack, D., Bortfeldt, A., Gehring, H., 2004. A parallel hybrid local search algorithm for
problem. J. Heuristics 19 (2), 275–294. the container loading problem. Int. Trans. Oper. Res. 11 (5), 511–533.
Chan, F.T., Bhagwat, R., Kumar, N., Tiwari, M., Lam, P., 2006. Development of a Moura, A., Oliveira, J.F., 2005. A GRASP approach to the container-loading problem.
decision support system for air-cargo pallets loading problem: A case study. Expert IEEE Intell. Syst. 20 (4), 50–57.
Syst. Appl. 31 (3), 472–485. do Nascimento, O.X., de Queiroz, T.A., Junqueira, L., 2021. Practical constraints in
Che, C.H., Huang, W., Lim, A., Zhu, W., 2011. The multiple container loading cost the container loading problem: Comprehensive formulations and exact algorithm.
minimization problem. European J. Oper. Res. 214 (3), 501–511. Comput. Oper. Res. 128, 105186.
Chen, C., Lee, S., Shen, Q., 1995. An analytical model for the container loading problem. Ngoi, B., Tay, M., Chua, E., 1994. Applying spatial representation techniques to the
European J. Oper. Res. 80 (1), 68–76. container packing problem. Int. J. Prod. Res. 32 (1), 111–123.
Chien, C., Deng, J., 2004. A container packing support system for determining and Paquay, C., Schyns, M., Limbourg, S., 2016. A mixed integer programming formula-
visualizing container packing patterns. Decis. Support Syst. 37 (1), 23–34. tion for the three-dimensional bin packing problem deriving from an air cargo
Correcher, J.F., Alonso, M.T., Parreño, F., Alvarez-Valdés, R., 2017. Solving a large application. Int. Trans. Oper. Res. 23 (1–2), 187–213.
multicontainer loading problem in the car manufacturing industry. Comput. Oper. Parreño, F., Alvarez-Valdés, R., Oliveira, J.F., Tamarit, J.M., 2010. Neighborhood
Res. 82, 139–152. structures for the container loading problem: a VNS implementation. J. Heuristics
Davies, A.P., Bischoff, E.E., 1999. Weight distribution considerations in container 16 (1), 1–22.
loading. European J. Oper. Res. 114 (3), 509–527. Pisinger, D., 2002. Heuristics for the container loading problem. European J. Oper. Res.
Dereli, T., Daş, G.S., 2010. Development of a decision support system for solving 141 (2), 382–392.
container loading problems. Transport 25 (2), 138–147. Pollaris, H., Braekers, K., Caris, A., Janssens, G.K., Limbourg, S., 2016. Capacitated
Dereli, T., Das, G.S., 2011. A hybrid ‘bee (s) algorithm’for solving container loading vehicle routing problem with sequence-based pallet loading and axle weight
problems. Appl. Soft Comput. 11 (2), 2854–2862. constraints. EURO J. Transp. Logist. 5 (2), 231–255.
Egeblad, J., Garavelli, C., Lisi, S., Pisinger, D., 2010. Heuristics for container loading Ramos, A.G., Silva, E., Oliveira, J.F., 2018. A new load balance methodology for
of furniture. European J. Oper. Res. 200 (3), 881–892. container loading problem in road transportation. European J. Oper. Res. 266 (3),
Eley, M., 2002. Solving container loading problems by block arrangement. European 1140–1152.
J. Oper. Res. 141 (2), 393–409. Ren, J., Tian, Y., Sawaragi, T., 2011. A tree search method for the container loading
Eley, M., 2003. A bottleneck assignment approach to the multiple container loading problem with shipment priority. European J. Oper. Res. 214 (3), 526–535.
problem. OR Spectrum 25 (1), 45–60. Sciomachen, A., Tanfani, E., 2007. A 3D-BPP approach for optimising stowage plans
Fasano, G., 2004. A MIP approach for some practical packing problems: Balancing and terminal productivity. European J. Oper. Res. 183 (3), 1433–1446.
constraints and tetris-like items. Q. J. Belgian French Ital. Oper. Res. Soc. 2 (2), Silva, E.F., Toffolo, T.A.M., Wauters, T., 2019. Exact methods for three-dimensional
161–174. cutting and packing: A comparative study concerning single container problems.
Fuellerer, G., Doerner, K.F., Hartl, R.F., Iori, M., 2010. Metaheuristics for vehicle routing Comput. Oper. Res. 109, 12–27.
problems with three-dimensional loading constraints. European J. Oper. Res. 201 Takahara, S., 2008. A multi-start local search approach to the multiple container
(3), 751–759. loading problem. In: Greedy Algorithms. IntechOpen.
Gehring, H., Bortfeldt, A., 1997. A genetic algorithm for solving the container loading Terno, J., Scheithauer, G., Sommerweiß, U., Riehme, J., 2000. An efficient approach
problem. Int. Trans. Oper. Res. 4 (5–6), 401–418. for the multi-pallet loading problem. European J. Oper. Res. 123 (2), 372–381.
Gendreau, M., Iori, M., Laporte, G., Martello, S., 2006. A tabu search algorithm for a Toffolo, T.A.M., Esprit, E., Wauters, T., Berghe, G.V., 2017. A two-dimensional heuristic
routing and container loading problem. Transp. Sci. 40 (3), 342–350. decomposition approach to a three-dimensional multiple container loading problem.
George, J.A., Robinson, D.F., 1980. A heuristic for packing boxes into a container. European J. Oper. Res. 257 (2), 526–538.
Comput. Oper. Res. 7 (3), 147–156. Tsai, J., Wang, P., Lin, M., 2015. A global optimization approach for solving three-
He, K., Huang, W., 2010. A caving degree based flake arrangement approach for the dimensional open dimension rectangular packing problems. Optimization 64 (12),
container loading problem. Comput. Ind. Eng. 59 (2), 344–351. 2601–2618.
Hifi, M., Kacem, I., Nègre, S., Wu, L., 2010. A linear programming approach for Wang, Z., Li, K.W., Levy, J.K., 2008. A heuristic for the container loading problem: A
the three-dimensional bin-packing problem. Electron. Notes Discrete Math. 36, tertiary-tree-based dynamic space decomposition approach. European J. Oper. Res.
993–1000. 191 (1), 86–99.
Iori, M., Martello, S., 2010. Routing problems with loading constraints. Top 18 (1), Wäscher, G., Haußner, H., Schumann, H., 2007. An improved typology of cutting and
4–27. packing problems. European J. Oper. Res. 183 (3), 1109–1130.
Ivancic, N., Mathur, K., Mohanty, B., 1989. An integer programming based heuristic Wu, Y., Li, W., Goh, M., de Souza, R., 2010. Three-dimensional bin packing problem
approach to the three-dimensional packing problem. J. Manuf. Oper. Manage. 2 with variable bin height. European J. Oper. Res. 202 (2), 347–355.
(4), 268–298. Zhang, D., Peng, Y., Leung, S.C., 2012. A heuristic block-loading algorithm based on
Júnior, R.R., Yanasse, H.H., Morabito, R., Junqueira, L., 2019. A hybrid approach for multi-layer search for the container loading problem. Comput. Oper. Res. 39 (10),
a multi-compartment container loading problem. Expert Syst. Appl. 137, 471–492. 2267–2276.
Junqueira, L., Morabito, R., Yamashita, D.S., 2012a. Three-dimensional container Zhao, X., Bennell, J.A., Bektaş, T., Dowsland, K., 2016. A comparative review of 3D
loading models with cargo stability and load bearing constraints. Comput. Oper. container loading algorithms. Int. Trans. Oper. Res. 23 (1–2), 287–320.
Res. 39 (1), 74–85. Zhu, W., Huang, W., Lim, A., 2012. A prototype column generation strategy for the
Junqueira, L., Morabito, R., Yamashita, D.S., 2012b. MIP-based approaches for the multiple container loading problem. European J. Oper. Res. 223 (1), 27–39.
container loading problem with multi-drop constraints. Ann. Oper. Res. 199 (1),
51–75.

14

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy