European Journal of Operational Research 128 (2001) 34±57 www.elsevier.com/locate/dsw

Theory and Methodology An empirical investigation of meta-heuristic and heuristic algorithms for a 2D packing problem

E. Hopper, B.C.H. Turton * School of Engineering, Cardi€ University, Queens Buildings, The Parade, P.O. Box 689, Cardi€ CF2 3TF, UK Received 7 January 1999; accepted 1 July 1999

Abstract

In this paper we consider the two-dimensional (2D) rectangular packing problem, where a ®xed set of items have to be allocated on a single object. Two heuristics, which belong to the class of packing procedures that preserve bottom- left (BL) stability, are hybridised with three meta-heuristic algorithms (genetic algorithms (GA), (SA), naõve evolution (NE)) and local search heuristic (hill-climbing). This study compares the hybrid algorithms in terms of solution quality and computation time on a number of packing problems of di€erent size. In order to show the e€ectiveness of the design of the di€erent algorithms, their performance is compared to random search (RS) and heuristic packing routines. Ó 2001 Elsevier Science B.V. All rights reserved.

Keywords: Cutting; Packing; Genetic algorithms; Simulated annealing; Optimisation

1. Introduction Packing problems are optimisation problems that are concerned with ®nding a good arrange- Cutting and packing problems are encountered ment of multiple items in larger containing regions in many industries, with di€erent industries in- (objects). The usual objective of the allocation corporating di€erent constraints and objectives. process is to maximise the material utilisation and The wood-, glass- and paper industry are mainly hence to minimise the ``wasted'' area. This is of concerned with the cutting of regular ®gures, particular interest to industries involved with whereas in the ship building, textile and leather mass-production as small improvements in the industry irregular, arbitrary shaped items are to be layout can result in savings of material and a packed. considerable reduction in production costs. Our work is concerned with a 2D rectangular packing problem. The problem consists of packing a collection of items onto a rectangular object while minimising the used object space. The * Corresponding author. Tel.: +44-1222-874425; fax: +44- 1222-874716. packing process has to ensure that there is no E-mail address: [email protected] (B.C.H. Turton). overlap between the items. The speci®c problem

0377-2217/01/$ - see front matter Ó 2001 Elsevier Science B.V. All rights reserved. PII: S 0 3 7 7 - 2 2 1 7 ( 9 9 ) 0 0 357-4 E. Hopper, B.C.H. Turton / European Journal of Operational Research 128 (2001) 34±57 35 that is addressed in this paper has the following rithm is then needed, which describes how this characteristics: sequence is allocated onto the object. One of the · a set of items, which may contain identical ®rst researchers who implemented GAs in the items; domain of packing is Smith (1985). He experi- · one single object of ®xed width and in®nite mented with two heuristic packing routines, one of height; which implements and produces · all pieces are of rectangular shape; denser layouts, however, is computationally more · items can be rotated by 90°; expensive. Comparisons between the two hybrid · non-guillotineable (Dyckho€, 1990). approaches show that the combination with the The 2D stock cutting problem occurs as an more sophisticated heuristic generates better industrial problem where a number of rectangular packing patterns. The packing problem Smith items need to be cut from a roll of material. Since studied is special in that the orientation of the the order (set of items) is small compared to the rectangles is ®xed. stock material, the height of the object can be re- In the hybrid approach by Hwang et al. (1994) garded as in®nite. Processor allocation can also be a GA is combined with a well-known heuristic treated as a 2D packing problem (Hwang, 1997). from bin packing, the so-called First-Fit-Decreas- ing-Height algorithm (FFDH). Although this technique produces guillotineable layouts, this is 2. A review of meta-heuristic packing algorithms not treated as an additional constraint in this work and suggested for the general case of the rectangle Many heuristic packing algorithms have been packing problem. Comparisons with another GA suggested in the literature. Surveys on solution technique, which will be described below, and the methodologies for various types of the 2D rect- FFDH heuristic itself show that this hybrid tech- angle packing problem can be found in Hinxman nique performs best. (1980), Sarin (1983) and Hassler and Sweeney Jakobs (1996) uses a heuristic, which belongs (1991). In comparison to the great quantity of to the class of bottom-left (BL) packing heuris- literature on heuristic algorithms to the packing tics to hybridise an order-based GA. In order to problem, only a few researchers have experimented reduce computational complexity the heuristic with meta-heuristic algorithms. does not necessarily place an item at the lowest available BL position. However, it preserves BL stability in the layout (see Section 3.1). In order 2.1. Packing and genetic algorithms to determine the in¯uence of the heuristic algo- rithm on the solution quality, Hopper and Tur- Genetic algorithms (GA) for packing problems ton (1998) implement two hybrid GAs, which are mainly concentrate on guillotineable layouts as combined with di€erent placement heuristics (see found in the wood, glass and paper industry Section 5.1). (Kroger, 1995; Andras et al., 1996) and 1D bin- Lai and Chan (1997) use an evolutionary al- packing (Falkenauer and Delachambre, 1992). A gorithm, which is combined with a heuristic rou- review of the application of genetic algorithms to tine. This routine is similar to the BL-heuristic and packing problems is given in Hopper and Turton places items in the position that is closest to the (1997). With respect to the speci®c packing prob- lower-left corner of the object. Comparisons with lem described in Section 1 three types of solution a mathematical programming algorithm show that approaches involving GAs can be distinguished. the evolutionary approach is computationally The majority of literature concentrates on hy- more ecient, however, it generates patterns with brid algorithms, where a GA is combined with a slightly higher trim loss. heuristic placement routine. In this two-stage ap- Dagli and Poshyanonda (1997) also used the proach a GA is used to determine the sequence, in GA to generate an input sequence for the place- which the items are to be packed. A second algo- ment algorithm, which is based on a sliding 36 E. Hopper, B.C.H. Turton / European Journal of Operational Research 128 (2001) 34±57 method combined with an arti®cial neural net- 2.2. Packing and simulated annealing work. Every incoming item is placed next to the partial layout and all scrap areas generated are Only few researchers have applied simulated recorded. If there is a match between an incoming annealing (SA) to 2D rectangular packing prob- item and one of the scrap areas, the neural net- lems. Kampke (1988) applies SA to 1D bin pack- work selects the best match. ing. Dowsland (1993) has experimented with SA A second category of solution approaches with on pallet loading problems involving identical as GAs aims at incorporating some of the layout well as non-identical boxes. In the identical case information into the data structure of the GA. the number of feasible positions for the placement However, some additional rules are still needed to of one item is reduced to the co-ordinates, which ®x the position in the layout. are a multiple of its length and width away from The GA by Kroger et al. (1991) is based on a the container edge. The neighbourhood has been directed binary to encode the problem. This de®ned as the set of solutions, which is obtained, representation ®xes one dimension of the position when each item is moved to any other position of an item in the layout. The second dimension is with some restrictions. Since these movements lead determined by the BL condition. Since its perfor- to overlapping patterns, this constraint has been mance is compared to well-known packing heu- dealt with in the objective function. Extending this ristics, a relative comparison with our work is method to non-identical pieces, the condition for possible. the feasible positions is that it has to be at a valid Hwang et al. (1994) also use a directed binary combination of lengths and widths of the other tree, which combines two rectangles to a larger item types from the container edge. rectangle by either placing them horizontally or vertically next to each other. The position within the containing larger rectangle is left justi®ed. As 2.3. Comparison of meta-heuristic methods mentioned before, comparisons with a hybrid GA technique show that this method is less ecient in As can be seen from the literature overview terms of packing height. given above GAs and SA have been successfully The third group of GA solution approaches applied to the 2D rectangle packing problem. attempts to solve the problem in 2D space. Her- However, none of the researchers have compared bert and Dowsland (1996) developed a 2D coding the performance of these meta-heuristic algorithms technique for a pallet-loading problem of identical using the same packing problems. Burke and rectangles. The layout is represented by 2D matrix Kendall (1998) have carried out the only research indicating available positions for vertical and in this area on the clustering of rectangles. Their horizontal placement, whereby the horizontal one ®ndings indicate that and SA outper- has priority. This technique works well for small form GAs for this speci®c problem. problems. In order to improve the outcome for In this paper our main objective is to compare medium sized problems additional repair and en- the performance of GAs, naõve evolution (NE) and hance operators have been introduced. SA with each other for small to large packing The method developed by Ratanapan and Da- problems. For all methods a two-stage approach gli (1997) is di€erent from the other approaches has been chosen, where the meta-heuristic algo- described so far, since it does not make use of a rithm is combined with a heuristic packing policy. data structure to represent the problem. The items As far as we are aware SA has not been imple- are represented as 2D pieces with their true geo- mented in a two-stage approach for packing metric dimensions. After the initialisation process, problems such as GAs (see Section 2.1). which places all items into non-overlapping posi- Two di€erent heuristic routines are used to tions on the object, a series of genetic operators is hybridise the meta-heuristic algorithms. The ®rst applied, which consist of moving, relocation and technique is the BL heuristic, which has been used recombination operations. by Jakobs (1996) in a hybrid GA. The second E. Hopper, B.C.H. Turton / European Journal of Operational Research 128 (2001) 34±57 37 heuristic algorithm also creates BL justi®ed pat- terns. However, it is more sophisticated and hence computationally more expensive (Chazelle, 1983). The outcome of meta-heuristic algorithms is compared with the two packing heuristics as well as with other search techniques such as hill- climbing and random search (RS). In order to show the e€ectiveness of the design of the GAs their performance is compared with an NE algo- rithm. Results indicate that the performance of the Fig. 1. BL routine (Jakobs, 1996). hybrid algorithms is strongly dependent on the nature of the placement routine and the problem which is described by the permutation (2, 6, 4, 3, 0, size. In particular in industrial applications not 1, 5). only the solution quality has to be considered, but The major disadvantage of this routine consists also the computational cost of the various packing of the creation of empty areas in the layout, when methods. larger items block the movement of successive This paper is organised as follows: Section 3 ones. On the other hand its time complexity is only gives a brief introduction into the heuristic and O(N2), when N is the number of items to be meta-heuristic algorithms used in our research. In packed. Due its low complexity this heuristic is Section 4 the experiments and the test problems favourable in a hybrid combination with a meta- are outlined. Sections 5 and 6 contain an overview heuristic, since the decoding routine has to be ex- and a discussion of the results and Section 7 ecuted every time the quality of a solution is summarises the ®ndings of this research. evaluated and hence contributes to a great extent to the run time of the hybrid algorithm.

3. Heuristic placement algorithms 3.2. BLF-algorithm In this paper we turn our attention to the class of BL heuristics (Baker et al., 1980). These packing Since the BL-routine described above tends to procedures preserve BL stability in the layout. An generate layouts with relatively large empty areas, item is allocated in a BL stable position if it cannot a second more sophisticated BL heuristic has been be moved any further to the left or downwards. considered for hybridisation with meta-heuristics. Two implementations of a BL heuristic are com- The strategy here consists of placing a rectangle bined in our study with meta-heuristic algorithms. into the lowest available position of the object and left-justifying it. Fig. 2 demonstrates the placement 3.1. BL algorithm

The BL algorithm described below has been used by Jakobs (1996) in a hybrid GA. Starting from the top-right corner each item is slid as far as possible to the bottom and then as far as possible to the left of the object. These successive vertical and horizontal movement operations are repeated until the item locks in a stable position. A valid position is found when the rectangle collides with the partial layout at its lower and left sides. Fig. 1 shows the placement of a sequence of rectangles, Fig. 2. Bottom-left-®ll heuristic. 38 E. Hopper, B.C.H. Turton / European Journal of Operational Research 128 (2001) 34±57 policy using the same permutation example as in state. This method is known as gradient search or Fig. 1. steepest-ascent hill-climbing. Since the generation of the layout is based on the allocation of the lowest suciently large region in the partial layout rather than on a series of BL 4.2. Meta-heuristic algorithms moves, it is capable of ®lling existing gaps in packing pattern. In order to distinguish it from the In order to overcome the main disadvantage of BL-algorithm described in Section 3.1 it is referred local search algorithms such as hill-climbing, to as the BL-Fill (BLF) heuristic. Compared to the whose weakness lies in the inability to escape from BL-routine this method results in denser packing local minima, more sophisticated heuristic search patterns. The major disadvantage, however, lies in strategies are designed to avoid such a situation. its time complexity, which is O(N3) (Chazelle, This implies the temporary acceptance of a state of 1983). lower quality. Hence meta-heuristic algorithms can be considered to some extent as local search strategies, however, they include a means to escape 4. Heuristic search techniques from local minima.

The quality of the layout which is constructed 4.2.1. Genetic algorithms using the above placement algorithms depends on GAs are search and optimisation procedures the sequence in which the rectangles are presented that operate in a similar way to the evolutionary to the routine. Since the number of combinations processes observed in nature. The search is guided is too large to be explored exhaustively in a rea- towards improvement using the `survival of the sonable amount of time, meta-heuristic algorithms ®ttest principle'. This is achieved by extracting the are used as a more ecient search strategy. In the most desirable features from a generation of so- following hybrid approaches the task of the meta- lutions and combining them to form the next heuristic is to search for a good ordering of the generation. The quality of each solution is evalu- items. A placement routine is then needed to in- ated and the `®tter' individuals are selected for the terpret the permutation and evaluate its quality. reproduction process. Continuation of this process Heuristic search techniques will result in a good, through a number of generations will result in however, not necessarily optimal solution within optimal or near-optimal solutions. The main dif- reasonable computing time. ference between GAs and other meta-heuristic approaches such as SA and tabu search is that they deal with populations of solutions rather than a 4.1. Hill-climbing single solution and therefore explore the neigh- bourhood of the whole population. Operators Hill-climbing is a local search technique, which such as selection, crossover and mutation are used moves from one solution to another one in the to explore the neighbourhood and generate a new neighbourhood. If the quality of the new solution generation. Further theoretical and practical de- is better than the previous one, this move is ac- tails can be found in (Davis, 1991; Goldberg, cepted and the search continues from here. If the 1989). neighbouring state does not result in an improve- ment, the move is rejected and the search contin- 4.2.2. Naõve evolution algorithm ues from the current state. The main disadvantage The basic idea behind NE is the same as for of this method is that the search process might get the GA. However, no crossover operator is ap- trapped in a local minimum, which is not equal to plied to manipulate the search space. Only the the global one. A useful variation on simple hill- mutation operator is used for the generation of climbing considers a series of moves from the the next population. An NE algorithm can current state and selects the best one as the next be used to test the eciency of the crossover E. Hopper, B.C.H. Turton / European Journal of Operational Research 128 (2001) 34±57 39 operator in a GA. Falkenauer (1998) applied this crossover and mutation are applied, the cooling technique in experiments on 1D bin-packing schedule in the case of SA and the population and problems. generation sizes for the GA as well as stopping criteria for the search algorithms. 4.2.3. Simulated annealing In our work the packing problem is tackled Eglese (1990) has investigated the application of with a two-stage approach, where the meta-heu- SA as a tool for Operations Research. SA was ristic search methods (GA and SA) and the local introduced as an optimisation tool in the 1980s search algorithm search the solution space for when the concept of physical annealing ®rst was good permutations. The permutation represents applied in combinatorial optimisation. Transfer- the order, in which the ®nite set of items is packed. ring this model to combinatorial problems the The heuristic placement routine is then used to energy states in a system correspond to the various decode and evaluate the quality of the permutation feasible solutions for a problem and the energy of according to the ®tness function. The quality of a the system to the cost function to be minimised. packing pattern is ®rst of all determined by its SA can be seen as a variant of the hill-climbing height, since the unused rectangular area can be re- method, however, it attempts to avoid getting used. However, this variable is not sucient to trapped in a local minimum. Instead of only ac- express how tightly the items are packed. For the cepting neighbouring solutions that result in an ®tness function a weighted sum has been used so improvement, also solutions, which are worse, the packing height is weighted at 70% and the may be accepted randomly with a certain proba- packing density at 30%. bility. This probability depends on the increase in The search space of this problem is extended by cost and a control parameter, i.e., temperature in the orientation of the items, which can rotate by physical annealing. The smaller the increase in the 90°. In order to allow the meta-heuristic and local cost and the higher the temperature the more likely search algorithms to explore the orientation of the uphill moves will be accepted. During the anneal- items, an operator is used which ¯ips the orienta- ing process the temperature is gradually lowered tion of each rectangle in the sequence with a cer- according to the cooling schedule. This means the tain probability. algorithm becomes more and more selective in accepting new solutions. At the end of the process 5.1.1. only moves, which result in an improvement are Since an order-based encoding is used for this accepted in practice. The search process terminates problem, care has to be taken that valid chromo- when it arrives at a lower bound for temperature somes are generated during the crossover and or cost. mutation operations. Partially matched crossover (PMX) (Goldberg, 1989) and order-based muta- tion (Syswerda, 1991) are suitable for this type of encoding and have been used in this case. Pro- 5. Search techniques and test data portional selection and generational replacement have been applied. The orientation of the rectan- 5.1. Implementation of the search algorithms gles is considered in the GA in the form of muta- tion. In the case of orthogonal packing only two A number of problem-speci®c and generic de- orientations for an item are possible. The rotation cisions have to be made for the implementation of operator is applied to every item in the chromo- the meta-heuristic search algorithms. The prob- some and changes the orientation with a certain lem-speci®c choices concern the objective function, probability. initial solution, representation scheme as well as Further techniques that have been implemented the operators applied to manipulate the search include elitism and seeding (Goldberg, 1989). Since space. Generic decisions include the probabilities heuristic placements with pre-ordered input se- at which the search space manipulators such as quences can yield packing patterns, whose quality 40 E. Hopper, B.C.H. Turton / European Journal of Operational Research 128 (2001) 34±57 can lie above average (Co€man et al., 1984), the moves at each step with N representing the initial population has been seeded with the per- number of items. mutation, which describes the rectangles sorted according to decreasing height. For the seeding the 5.1.4. Hill-climbing best out of 50 evaluations of the placement heu- The neighbourhood structure as well as the ristic using randomly generated but height-sorted manipulators for the search space used in the local input sequences has been taken. The initial popu- search procedure is the same as in SA. The initial lation has been generated randomly and contains solution is generated randomly. The search process the seeded individual. The GAs we implemented is stopped after N unsuccessful moves in the search use a population size of 50 and a generation size of space. 1000. The probability for crossover is 60% and the one for the two types of mutations is 3%. 5.1.5. Random search In order to demonstrate the e€ectiveness of the 5.1.2. Naõve evolution algorithm design the di€erent meta-heuristic search tech- The problem-speci®c and generic decisions for niques are compared to RS. In RS permutations the NE algorithm are the same as for the GA with are generated randomly. The search process is run the di€erence that no crossover operator is used to over the same number of function evaluations as manipulate the solution space. the GA.

5.1.3. Simulated annealing algorithm The packing problem is represented by a per- 5.2. Test problems mutation that is interpreted as the order in which the rectangles are packed. The neighbourhood Performance of the meta-heuristic and heuristic structure of the current solution is de®ned by the algorithms has been tested with seven di€erent set of solutions that can be reached applying the sized packing tasks ranging from 17 to 197 items. following two manipulation operations. The ®rst Three instances have been generated for each one is analogous to the order-based mutation problem category. The dimensions of the rectan- operator used in the GA and swaps two ran- gles are produced randomly with a maximum domly selected items in the permutation. The aspect ratio of 7. The problems have been con- second operator considers only the orientation structed such that the optimal solution is known and ¯ips the rotation variable of one randomly (see Table 1). The ratio of the two dimensions of selected item. In the translation to the next so- the object varies between 1 and 3. Three instances lution only one of the operators is applied with a of each problem have been simulated. Detailed 50% chance. The initial solution is randomly information about the various item sets is given in generated. Appendix A. The generic choices for the implementation of an SA algorithm are summarised in the annealing or cooling schedule. The schedule presented in Table 1 Press et al. (1995) is used in this study with a few Test problems modi®cations. The temperature function is geo- Problem Number of Optimal Object metric and decreased by 10%. The initial value category items height dimensions for the temperature has been determined as 19.23 C1 16 or 17 20 20 ´ 20 C2 25 15 40 ´ 15 applying the method described in Press et al. C3 28 or 29 30 60 ´ 30 (1995). The number of iterations at each tem- C4 49 60 60 ´ 60 perature has been modi®ed in order to reduce the C5 72 or 73 90 60 ´ 90 total simulation time. The temperature is held C6 97 120 80 ´ 120 constant for 50N total moves or 5N successful C7 196 or 197 240 160 ´ 240 E. Hopper, B.C.H. Turton / European Journal of Operational Research 128 (2001) 34±57 41

5.3. Simulation rithm are between 10 and 30% better than the ones obtained with the BL rule. The GA and the NE algorithms have both been Pre-ordering the input sequences according to simulated over 1000 generations using a population decreasing width (DW) or height (DH) of the size of 50. The stopping criterion for the SA and the items improves the outcome of both packing hill-climbing algorithm is based on the number of heuristics by 5±10% compared to the performance unsuccessful moves. Hence both search processes on random input sequences. Comparing the best have been run until termination by this criterion. In solutions achieved with both methods for each order to establish the eciency of the optimisation problem shows that the BLF heuristic outperforms processes RS has been applied over the same the BL routine by up to 25% with the performance amount of iterations as the GA (i.e., 50 000). The gain being higher for the larger problems. results presented below are the average of 10 sim- As already mentioned in Section 3.1 the com- ulations. The outcome of the meta-heuristic putational complexity of the BLF algorithm is methods is compared on the basis of the number of higher than the one of the BL routine. The average iterations. The heuristic methods have been run 50 run time increases exponentially with the problem times using random input sequences as well as se- size. This di€erence is particularly noticeable for quences which have been sorted by decreasing larger packing problems (Fig. 3). The average time height (DH) or width (DW). The simulations have needed to place one item is higher for the BLF been run on a PC with a Pentium Pro 200 MHz algorithm (Table 3). The number of available BL processor and 65MB of RAM under Windows stable positions, which are tested on average, be- NT4.0. The algorithms have been implemented in fore a suitable position is found, is higher than the C++ using LEDA (Library of Ecient Data types number of movements carried out using the sliding and Algorithms), version 3.7.1 (Mehlhorn et al., method of the BL algorithm. The number of free 1998), to generate the graphic output.

6. Results

6.1. Comparison between the heuristic algorithms BL and BLF

The comparison of the two heuristic packing algorithms shows that the more sophisticated placement routine (BLF) achieves better layouts. Table 2. summarises the relative distances between the lowest packing height found and the height of the optimal solution. Using random input se- quences the layouts generated by the BLF algo- Fig. 3. Average elapsed time per 100 iterations for heuristics.

Table 2 Relative distance of best solution to optimum height (%) for heuristic methods with and without pre-ordered input sequences C1 C2 C3 C4 C5 C6 C7 BL 25 39 33 33 31 34 41 BL±DH 17 68 27 21 18 19 31 BL±DW 18 31 24 18 22 21 29 BLF 14 20 17 15 11 12 10 BLF±DH 11 42 12 6 5 5 4 BLF±DW 11 12 12 5 5 5 5 42 E. Hopper, B.C.H. Turton / European Journal of Operational Research 128 (2001) 34±57

Table 3 Average elapsed time per placement of one item for heuristic methods (ls) Problem C1 C2 C3 C4 C5 C6 C7 Size 17 25 29 49 73 97 197 BL 46 61 56 95 119 158 324 BLF 72 87 114 252 470 794 3234

BL-positions in the layout increases exponentially erations. The outcomes of the two evolutionary with the problem size. methods (GA and NE) are very similar with the NE algorithm performing slightly better for some problems (up to 2%). Hill-climbing performs bet- 6.2. Comparison between the heuristic algorithms ter than RS for most problems or at least equally BL and BLF well and outperforms the simple BL heuristic by up to 5%. For all techniques, heuristics as well as In the following the performance of the meta- meta-heuristics, the di€erence between the packing heuristic algorithms is investigated. First of all, heights achieved and the optimal height becomes the meta-heuristics methods, which use the BL larger with increasing problem size. decoder, are compared. Then the same comparison The best layouts for the hybrids with the BL is made for the meta-heuristic algorithms, which decoder have been obtained with SA in all prob- are hybridised with the more sophisticated BLF lem categories. The di€erence between SA and the routine. Finally, the performance of the two types two evolutionary techniques (GA and NE) lies of hybrid combinations is analysed. In order to between 1% and 8% and is higher for the larger study the eciency of the meta-heuristic methods problems. However, the number of iterations over the simple heuristics their outcomes have needed by the SA is up to 5 times higher on av- been compared to RS, which evaluates the packing erage. Fig. 4 shows that the SA converges very routines over the same number of iterations as the slowly, whereas the GA reaches the ®nal packing GA (i.e., 50 000) using random input sequences. height earlier. The meta-heuristic search methods using the The results obtained by the methods using the BL decoder achieve layouts of higher quality than sophisticated packing heuristic, i.e., BLF, show a the simple packing heuristic (BL). The packing similar ranking of the various methods (Table 5). heights achieved by the hybrid are up to 24% For problems up to category C3 RS and hill- better than the ones by the BL (Table 4). The climbing perform better than the simple heuristic. performance of the RS lies between the one of the Hill-climbing, however, is outperformed by RS, meta-heuristics and the packing heuristic. Hence especially for the smaller problems. The packing some of the performance gain achieved by the heights achieved by the evolutionary algorithms, meta-heuristics is due to the higher number of it- GA and NE, are very similar and outperform RS

Table 4 Relative distance of best solution to optimal height (%) for heuristic and meta-heuristic methods combined with BL routine C1 C2 C3 C4 C5 C6 C7 GA + BL 6 10 8 9 11 15 21 NE+BL6888111319 SA+BL47766713 HC + BL 9 18 11 14 14 20 25 RS + BL 6 14 14 16 18 20 28 BL 17 31 24 18 18 21 29 E. Hopper, B.C.H. Turton / European Journal of Operational Research 128 (2001) 34±57 43

Fig. 4. GA and SA+BL for large problem.

Table 5 Relative distance of best solution to optimum height [%] for heuristic and meta-heuristic methods combined with BLF decoder C1 C2 C3 C4 C5 C6 C7 GA + BLF 4 7 5 3 4 4 5 NE + BLF 5 7 4 4 4 4 5 SA + BLF 4 6 5 3 3 3 4 HC + BLF 7 10 7 7 6 7 7 RS + BLF 5 8 7 7 6 7 7 BLF 11 16 12 5 5 5 5 and hill-climbing. SA yields the best results in each timal height does not increase with the problem problem category. size as is the case with the BL decoder (see Tables Summarising Table 5, the meta-heuristic 4 and 5). The solution quality remains at the methods, which use the BLF decoder, achieve same level for each problem category (up to 7% packing heights, which are very close to the op- from the optimum). timum height (between 3% and 7%). Even the The comparison of the hybrid algorithms shows BLF heuristic on its own leads to very low that the combinations with the BLF placement packing heights. Especially, for larger problems routine produce better layouts than the combina- (C2±C7) the di€erence to the meta-heuristics is tions with the BL routine. The hybrids with the maximally 2%. This ®nding is di€erent from the BLF routine generate layouts that are up to 16% BL case, where the solution qualities obtained by better. The di€erence is especially high for the the simple heuristic and the meta-heuristic di€er large problems. The same is true for the NE hy- particularly for the larger problems (Table 4). brids. In Table 6 the results obtained with the two Using the BLF decoder the di€erence to the op- di€erent decoding algorithms are compared. The 44 E. Hopper, B.C.H. Turton / European Journal of Operational Research 128 (2001) 34±57

Table 6 Di€erence between the best solutions of the hybrids with the BLF routine and the ones with the BL routine (%) C1 C2 C3 C4 C5 C6 C7 GA2 33671116 NE1 1447914 SA0 123339 HC2 84781318 RS 1 6 7 9 12 13 21 Heuristic 6 15 12 13 13 16 24

Fig. 5. Comparison of the two GAs combined with BL and BLF routines. di€erence between the best solutions found using further adjustments to the annealing schedule will the meta-heuristic with the BL and the BLF de- most likely reduce the run time of this meta-heu- coder are stated. ristic. Fig. 5. demonstrates the performance of the two GAs. Both algorithms achieve the highest perfor- mance gain within the ®rst 10 000 iterations, i.e., 7. Discussion 2000 generations. Although the meta-heuristics perform better in 7.1. Packing heuristics terms of solution quality, the combinations with the BLF decoder have longer run times (Table 7). The BLF packing algorithm achieves better Run times become extremely long for large prob- packing patterns than the BL heuristic for our lems (C5±C7) due to its higher computational example problems. Since the BLF routine ®rst at- complexity. The BL algorithm o€ers an advantage tempts to ®ll the gaps in the layout, the majority of in that respect. Especially, SA, which achieves the the small items will be `absorbed' within the ex- best layouts, has high execution times. However, isting partial layout and does not contribute E. Hopper, B.C.H. Turton / European Journal of Operational Research 128 (2001) 34±57 45

Table 7 Average elapsed time for heuristics and meta-heuristics per run in (min); for BL and BLF in (ms) C1 C2 C3 C4 C5 C6 C7 GA + BL 0.5 0.8 0.9 2.4 4.0 6.7 23 NE + BL 0.4 0.6 0.7 1.6 2.6 4.1 30 SA + BL 0.4 1.4 1.8 7.5 17 31 117 GA + BLF 1.0 2.0 3.0 13 36 86 777 NE + BLF 0.7 1.3 2.1 8.3 23 55 483 SA + BLF 0.7 2.4 4.0 33 115 382 4181 BL (ms) 0.8 1.3 1.6 4.7 8.7 15.3 63.7 BLF (ms) 1.2 2.2 3.3 12 34 77.0 636 further to the packing height, which is mainly de- tine. In a combination with a meta-heuristic, termined by the larger items (Fig. 6). With the BL- however, the time complexity plays a more im- rule, however, unused regions in layout cannot be portant role. accessed and smaller rectangles also contribute to the height. The results in Section 6.1 show that the di€erence to optimum solution gets smaller with 7.2. Meta-heuristics and local search increasing problem size. This is due to the fact that larger problems contain a larger number of small Looking at the results stated in Section 6.2 it items, which are allocated in the empty areas can be seen that the meta-heuristic methods out- contained in the partial layout. In particular pre- perform the hill-climbing algorithm due to their ordered input sequences (height or width) achieve ability to escape from local minima. Hence meta- dense layouts (Fig. 6). Although the execution heuristics o€er a clear advantage over the local time for the BLF algorithm is considerably larger, search algorithm in that respect. Since the hill- the performance gain especially for large packing climbing algorithm terminates in a local mini- problem justi®es the application of the BLF rou- mum its run time is shorter than that of SA. The

Fig. 6. Best layouts for a large problem (C6) with BL (left) and BLF (right); height-sorted sequence. 46 E. Hopper, B.C.H. Turton / European Journal of Operational Research 128 (2001) 34±57

Fig. 7. Comparison between local search and meta-heuristic methods (+BL). hill-climbing technique only allows exploration of over the number of evaluations and only get out- a limited area of the search space and is outper- performed by the SA towards the end of the search formed by the meta-heuristic algorithms from the (Fig. 4). Hence the technique which GAs use to beginning of the search process (Fig. 7). Although explore the space is more successful than the one the ®nal outcome of hill-climbing is slightly better used by SA. One of the di€erences between the than the RS method, a random walk through the algorithms is that a crossover operator is used in search space results in better solutions during most the GA to manipulate the current best solutions. of the search process. Whereas hill-climbing only This obviously creates larger changes in the se- explores the search space locally, SA can exploit quences than with the mutation operator used in the space more e€ectively and concentrate on SA and hence could explain the rapid progress the promising areas. GA makes in the beginning. Due to the manipulation technique used in SA, Comparisons with an NE algorithm, which is which either only changes the rotation of one ele- only based on mutation and has no crossover, ment at a time or the position of two elements in show, however, that both strategies are equally the permutation, the search process with the SA is successful (Fig. 8). Hence the crossover operator slow at the beginning and even RS results in better used in this implementation is not the reason for layouts. RS, however, is quickly outperformed, the better exploration of the search space in the when the SA algorithm starts exploiting promising beginning of the search process. If crossover was areas in the solution space and ®nds solutions the main contributor, then the di€erence between which would not have been found on a random GA and NE would be higher. However, the mu- basis. tation operator implemented is obviously sucient Looking at Fig. 7 the most successful search for this task. Di€erent from the SA method the strategy in the beginning of the search process are evolutionary techniques work on a population of GAs. Solutions found by the GA improve rapidly solutions, which they explore simultaneously. E. Hopper, B.C.H. Turton / European Journal of Operational Research 128 (2001) 34±57 47

Fig. 8. Evolutionary algorithms (GA and NE) and random search for BL for C3.

While the SA operates only on one solution at a the ®ve di€erent methods have achieved over the time, the recombination method in evolutionary best solution obtained with the BLF algorithm. algorithms guarantees that the most successful so- For problems consisting of a higher number of lutions are utilised in the following generation. items (C4±C7) only meta-heuristic methods are Hence, they allow exploration of the solution space successful and result in better layouts than the in parallel. The GA, however, is outperformed by BLF heuristic. RS and hill-climbing cannot the SA technique towards the end of the search explore the enormous search space suciently and process, when the population has converged. Only are easily outperformed by the simple BLF heu- the SA technique, where solutions of minor quality ristic. Unlike RS the simple BLF method used in can be accepted over a series of moves, can then this comparison also includes pre-sorted sequenc- lead the search into promising regions. es, where the items are sorted according to their In order to establish how well the meta-heu- height or width. As it can be seen in Table 2 ristic algorithms explore the search space, an RS sorting almost always is better than random input. process has been applied to the packing problems. Since RS only stands a theoretical chance of Whereas the RS only `explores' the solution ®nding a sorted sequence it can be outperformed space, the in-built search mechanisms allow the by the simple BLF method as indicated in Fig. 10. meta-heuristic strategies to `exploit' good regions. All meta-heuristic methods manage to improve the The di€erence between the GA and RS for the heuristic solution, however, only by a few percent. BLF case is smaller, which indicates that the The most successful method on large problems is `exploitation' of the solution space is limited SA. (Fig. 9). The comparison between the meta-heuristics, hill-climbing and RS shows that the improvement 7.3. Hybrid methods over the BLF heuristic is largest for smaller packing problems, i.e., problems with less than 50 The results summarised in Tables 4 and 5 show items (C1±C3). Fig. 10 indicates the improvement that the combination between the meta-heuristics 48 E. Hopper, B.C.H. Turton / European Journal of Operational Research 128 (2001) 34±57

Fig. 9. Random search and GAs for both decoders (BL and BLF).

Fig. 10. Improvement of the meta-heuristics + BLF in comparison to the best of the heuristic solutions (BLF including sorted se- quences) for each problem category. and the BLF packing routine achieve better out- Fig. 6 shows the performance of the two heu- comes compared to the combinations with the BL ristics in combination with a GA. Since the pack- routine. The di€erence is higher for the larger ing heights achieved with the BLF on its own are problems (Table 6). already very close to the optimum height (less than E. Hopper, B.C.H. Turton / European Journal of Operational Research 128 (2001) 34±57 49

8% from the optimum on average), the meta- whereas applying the better BLF-heuristic good heuristic cannot improve the performance of the layouts are achieved in a smaller number of iter- heuristic as much as in the BL case. In other words ations. Figs. 11 and 12 show initial and best lay- by using the `poorer' BL-decoder, the meta-heu- outs obtained by both GAs for the largest ristic is needed to ®nd a good input sequence, problem.

Fig. 11. Initial and best layout for GA + BL.

Fig. 12. Initial and best layout for GA + BLF. 50 E. Hopper, B.C.H. Turton / European Journal of Operational Research 128 (2001) 34±57

This questions the use of a hybrid combina- In order to reduce the computation time the BL tion between a meta-heuristic and a `poor' de- heuristic could be considered in connection with coder for this type of packing problem. In order the meta-heuristic. In spite of the reduction of the to achieve high quality layouts it may often be execution time the solution qualities achieved with sucient to apply the BLF routine over a small this approach for large packing tasks are up to number of iterations. This is especially true for 15% worse than those obtained with the simple larger problems (>30 items, C4±C7), where the BLF heuristic (Fig. 13). For smaller problems hybrid methods only manage to improve the where combination with the BLF routine achieves heuristic solution by less than 2% (Fig. 10), better layouts, the computation time is low any- however, at a very high computational cost (Ta- way. Summarising the hybrid approach with the ble 7). For smaller problems on the other hand, poorer decoder, which is more ecient in terms of where the execution times are acceptable, the computation time, cannot be justi®ed, since it is meta-heuristic with the BLF rule outperforms the easily outperformed by the BLF-heuristic on large simple heuristic by about 7%. In this case the problems. application of a meta-heuristic algorithm o€ers An implementation of the BLF algorithm, advantages. which has a lower computational complexity, is of

Fig. 13. Improvement of the meta-heuristics + BL in comparison to the best heuristic solution (BLF) for each problem category.

Table 8 Method for best results within speci®ed time limit (hybrids are with BLF decoder) <1 min <10 min <1 h <10 h <24 h C1 GA, SA GA, SA GA, SA GA, SA GA, SA C2 BLF SA SA SA SA C3 BLF NE NE NE NE C4 BLF NE SA SA SA C5 BLF GA, NE GA, NE SA SA C6 BLF BLF NE SA SA C7 BLF BLF BLF NE NE E. Hopper, B.C.H. Turton / European Journal of Operational Research 128 (2001) 34±57 51

Table 9 Table 11 Category 1: 16 or 17 items; object: 20 ´ 20 Category 3: 28 or 29 items; object: 60 ´ 30 P1 P2 P3 P1 P2 P3 wh wh wh wh wh wh 2124 1 414 75186249 7124 5 5 2 14512289 869422 14 8 7 10 11 9 363597 48234179 353955 21 13 1 4 24 4 551425 7117784 3125 3 7 7 14 11 4 11 6 1 374135 1455651 575565 4572174 267232 18311663 329362 21 3 19 10 5 3 4231346 17 11 5 11 5 12 342863 4112 41312 44154103 74571414 925463 5424142 11 2 10 6 10 3 6712722 72 18513738 356398 7 3 10 6 14 12 53169212 1844136 3410496 Table 10 12224652 Category 2: 25 items; object: 40 ´ 15 6299132 P1 P2 P3 18 5 1 2 18 3 21 5 5 8 14 3 wh wh wh 17 3 5 3 16 3 11 3 11 2 12 7 43257123 1332377 21 5 9 2 10 7 7 1 72 84 51 93 95 32 73 72 62 1124172 great bene®t for the hybrid approach using the 1326152 1144531 BLF rule. Chazelle (1983) developed an imple- 1348361 mentation of this algorithm that has a complexity 35 13 126 of O(N2). Using a more time ecient implemen- 1125596 tation the execution times of both heuristic pack- 22 31 122 ing rules become comparable, and will only di€er 11 3 12 4 7 2 23 62 103 by a factor rather than an order of magnitude. 54 24 41 This means the hybrid algorithms with the BL rule 6 4 11 4 5 1 lose their major advantage over the ones using the 12 2 10 2 16 3 BLF decoder. 12 32 53 Hybrid combinations between meta-heuristics 3 5 11 2 4 2 1353452 and a heuristic packing rule as investigated in this 12 4 26 4 10 3 study not only achieve high quality layouts. Their 14 84 93 main advantage lies in simplicity of the imple- 52 32 163 mentation. The meta-heuristic search is hybridised 62 62 53 with a heuristic and acts as tuner of the packing 52 E. Hopper, B.C.H. Turton / European Journal of Operational Research 128 (2001) 34±57 routine. The representation as a sequencing technique for two medium-sized problems (21 and problem allows the use of well-known manipula- 31 items) are about 92%. Using the same data sets tion techniques for the search space, e.g., order- all of the hybrid meta-heuristic techniques (SA, based crossover operators, rather than developing GA and NE) in combination with either of the problem-speci®c operators that only can be used in packing routines were able to outperform this re- one speci®c context. sult. The achieved packing densities range between On the other side it can be argued that the 92% and 98%, with the SA obtaining the best geometric information concerning the layout is outcomes. For the smaller problem the SA even hidden in the heuristic decoder. Hence it cannot be found the optimum solution in 3 runs out of 10. exploited by meta-heuristic search processes to the Unfortunately, Ratanapan and Dagli do not state same extent as if a representation was used that the computational e€ort of the rearrangements in includes more geometric information in the de®- the layout after application of the mutation oper- nition of the neighbourhood structure and chro- ators. mosomes, respectively. Dagli and Poshyanonda (1997) developed an Comparisons with the approach by Ratanapan approach involving a hybrid between GAs and a and Dagli (1997), where the items have been rep- neural network, which achieves packing densities resented as true geometric objects in an evolu- between 95% and 97%. Applying the meta-heu- tionary search algorithm show that this does not ristics in combination with the BLF routine necessarily generate better layouts. The packing densities between 95% and 96% are obtained. densities achieved by Ratanapan and Dagli's However, the test problem Dagli and Poshyan-

Table 12 Category 4: 49 items; object: 60 ´ 60 P1 P2 P3 wh wh wh wh wh wh 2 7 3 3 10 14 2 4 10 4 12 7 24 7 8 3 3 13 2 7 12 4 9 4 16 4 5 20 28 5 3 4 13 5 4 4 18 4 3 17 5 8 5 30 3 5 9 9 167371495372225 18 7 5 7 12 14 10 26 6 22 20 5 2 4 3 7 13 10 6 5 9 23 9 5 24 4 4 7 3 17 4 9 10 19 4 5 428421151431542 61810194192513122 14 12 4 17 18 4 4 17 2 10 3 15 2 12 8 17 1 1 5 2 2 10 21 11 18 19 3 10 2 6 4 4 13 18 11 3 9 8 5104146 2 3183 3 7876318410231123 9118641424231123 711151281731252118 146312115654238 2 6 11 10 9 12 3 9 3 4 21 4 6 10 5 10 4 7 7 18 9 4 14 4 1610422586671313 358275187613513 4 5 10 2 24 9 13 9 2 4 11 5 812122 914257204115 318 1219 4 7 E. Hopper, B.C.H. Turton / European Journal of Operational Research 128 (2001) 34±57 53 onda use is very special in the sense that the `improvement' operators Herbert and Dowsland ratio between the width and the height of the manage to improve the performance for larger object is very large. Even simple heuristics as the problems. height and width sorted BLF routines achieve a The GA approach developed by Kroger et al. packing density of 94%. Hence, the higher e€ort (1991) is based on a graph structure, which allows of the implementation in Dagli and Poshyan- including some geometric information in the data onda's approach is not re¯ected in a much better structure. Since the data sets used in the experi- outcome. ments are not published only an indirect compar- The 2D matrix representation Herbert and ison is possible. The packing heights achieved with Dowsland (1996) developed for a GA for the this technique are 1% and 7% better than those pallet loading problem of identical boxes does not obtained by the BLF heuristic and lie in the same achieve better outcomes as the 1D binary en- region as our ®ndings. coding as the authors conclude. Applying the hybrid meta heuristics combined with BL and BLF routines to the same problems shows, that they ®nd optimal solutions more often than 8. Conclusions Herbert and Dowsland's approach for the small problems ( 6 16 items). For the larger problems Two types of hybrid algorithms for the rect- only near-optimal solutions have been found. angle packing problem have been implemented Only with the implementation of `enhance' and consisting of a combination of a meta-heuristic

Table 13 Category 5: 72 or 73 items; object: 60 ´ 90 P1 P2 P3 whwhwhwhwhwhwhwhwh 634102233512301063751142 313669614351141910154535 513569692711426475545 121071416624333312713424 12 10 6 14 2 6 21 7 5 20 5 23 4 18 6 3 15 12 7 6 3 16 7 5 7 10 6 23 5 20 10 8 1 4 13 12 15 6 5 16 18 5 1 2 7 2 15 4 5 8 6 4 19 7 7 25 6 14 9 3 13 19 11 21 10 6 4 25 4 2 9 7 15255149341787635255254 12 21 13 14 18 9 4 13 6 15 5 2 4 8 19 25 2 4 7162356173214212859125 51673262410131431101049922 3212111225 4314235103651 521711922 25261433 43621 7 576386 1914927 46131512 5 566981191037871020131312 1 4 14 33 9 10 4 26 4 13 32 6 2 10 3 18 2 5 104412532 1136271531855 13 6 3 12 2 3 4 7 14 11 26 5 4 18 5 16 12 17 13 12 18 16 18 3 7 38 7 10 1 2 15 18 4 16 2 12 912312733 2141265318611512 6 23 18 12 3 2 3 1 18 3 13 3 7 18 13 4 4 5 3 744924 2741037574285 5734 4627 25137 1213 21728 41132 54

Table 14 .Hpe,BCH utn/Erpa ora fOeainlRsac 2 20)34±57 (2001) 128 Research Operational of Journal European / Turton B.C.H. Hopper, E. Category 6: 97 items; object: 80 ´ 120 P1 2 P3 wh wh wh wh wh wh wh wh wh wh wh wh 3019116374267391033655263556942620 859303147268331151344169214257 13510817739764441482664215237 15231087721953331689113413523425315 945457113135442393210752362582 34543793139636268511237866672 21141466628111316716791715626419 972144631934641526243067851810619 3742242188226242521110621051124525 81481462385215384510810335494813 116 314961181153030511509 213337 2174 713 261022683112111195102722627958 11842058101826111041255311415649538 28620522645265204226817417585 12122742969262341369248726435 21213252821210292981553367622468 3010924289124326526718247586828 211013562939559174265154744208712 15695320122827312691330794742107 14617112120922441993121063468814377 2971110391272273662365817178181464 22961841397292863217510174663424 61648713 2262011 8165659 5228622 5120723 15164887 5257522 91511232 564477 Table 15 Category 7: 196 or 197 items; object: 160 ´ 240 P1 P2 P3 w h wh wh wh w h wh wh whw hwh wh wh Items No. 1±100 19 21 33 10 12 23 2 4 15 75 14 5 11 10 1 1 19 15 19 11 17 12 14 23 6 21169994412805252521415335151623 6 18 3 9 16 9 11 11 27 6 7 2 7 26 11 56 8 5 3 3 10 6 6 31

41 18 8 4 6 18 29 11 3 13 12 9 10 44 10 39 26 5 5 5 15 6 21 34±57 22 (2001) 128 Research Operational of Journal European / Turton B.C.H. Hopper, E. 22 14 17 4 20 13 10 54 10 3 2 1 19 4 5 5 21 10 35 5 8 50 4 22 13 14 20 9 21 13 13 54 9 21 12 8 8 31 3 20 5 24 6 17 30 16 4 17 8 13199 52513708 11528336 2 1 3 713176162217 14 13 8 15 6 25 7 13 6 13 8 6 11 73 2 7 32 7 24 8 15 10 14 8 31 20 6 6 19 25 3 13 2 9 35 7 8 27 7 6 26 92 31 8 6 10 16 8 8 756716725511071462131216925810994 147365162126610452917348 535815964 225456994121112419259164626524568204 13 54 17 23 16 9 11 32 2 10 13 17 9 39 1 1 3 17 31 5 5 8 22 4 6 23 5 28 20 12 22 9 8 12 62 9 9 17 6 13 32 17 5 5 12 40 5 29 8 13 6 28 21 12 7 9 13 47 36 11 12 7 3 12 10 5 35 5 9 33 38 7 33 13 11 53 23 10 7 12 14 37 38 18 21 101 6 10 24 5 11 44 6 33 33 7 6 22 20 6 12 10 3 12 3 11 4 2 3 10 9 15 2 8 12 44 6 37 7 32 5 22 19 6 7 9 16 33 3 6 9 5 3 7 6 24 19 8 38 17 5 35 5 32 11 28 3 17 5 9 8 33 1 4 8 3 4 10 1 1 3 7 57 17 21 13 30 49 19 56 5 17 25 7 14 21 1 6 30 20 8 22 5 7 3 7 13 5 4 13 5 22 12 56 39 12 6 7 7 21 27 5 6 7 5 3 4 1 13 10 17 5 4 17 9 22 16 11 8 12 16 47 6 27 14 3 36 10 2 1 2 13 4 27 8 17 22 17 6 37 3 11 31 8 16 14 6 10 10 4 27 7 1 2 11 9 10 14 36 20 16 34 6 31 6 20418 81416105 2017322591 6241421206321631 8 10232321167233 116 4 1 2 3162 1113125322 7 Items No. 101±197 10 45 29 11 4 9 3 10 7 11 30 8 4 2 6 32 25 7 3 8 4 10 2 4 7 4592622146108 15267 6 7 1 51112126547102511 2 10426974246101632133125332255311834 4 1017359 7 5216 217125295 7332 516512117 7 16 13 12 6 17 4 21 21 3 9 12 25 2 2 2 8 25 5 6 9 14 7 2 7 14 6 12 6 3 4 19 21 1 4 22 20 8 15 6 11 27 10 3 9 12 7 10 29 7 6 4 4 19 17 8 21 10 7 9 55 5 28 9 9 11 10 41 9 3 18 2 10 2 3 10 4 8 17 19 17 3 3 13 27 8 42 4 27 5 15 17 3 5 18 5 10 4 3 8 10 8 11 21 17 5 15 65 16 4 27 10 11 9 15 13 3 12 10 59 19 13 13 13 2 5 11 9 15 2 4 1 3 3 2 38 9 5 30 6 8 9 10 9 23 14 13 6 2 7 10 5 6 33 8 5 2 18 4 5 7 11 13 8 8 9 49 22 15 7 810122010136165165717562301317657315 33831297191491221283630211363729 16 34 22 16 9 7 4 14 10 11 3 3 2 11 6 2 7 17 5 11 26 11 4 7 122818161920596 3321232551716114817 12 28 7 20 4 20 4 7 10 11 25 11 3 18 12 4 6 24 6 2 47 8 4 2 7 3017164109739811817101636221023712 4 19 3 16 26 10 5 3 17 113 6 4 7 5 72 15 10 22 6 7 12 7 7 10 29 19 13 8 19 11 21 3 13 36 10 9 3 10 14 14 3 2 3 7 12 39 59 10 10 51 6 8 21 11 4 2 28 8 25 8 5 31 2 6 3 2 8 10 9 39 22 8 13518103392177106199398101435438 13 25 19 10 6 3 42 9 12 15 7 8 12 3 6 18 12 3 3 4 4 21 10 8 18 13 22 57 6 19 10 3 11 8 3 3 51 8

10 21 3 8 8 27 2 1 2 4 11 37 30 8 5 3 15 8 55 4 1199527 1594714 3 8102674 56 E. Hopper, B.C.H. Turton / European Journal of Operational Research 128 (2001) 34±57 algorithm (GA, NE and SA) and heuristic is incorporated in the meta-heuristic rather than packing routine to allocate the items on the the decoder. However, representation schemes object. The heuristic packing routine generates studied by other researchers that use more layout the layouts in a BL justi®ed manner. Whereas information did not necessarily achieve higher one of the techniques (BL) is a time-ecient packing densities than hybrid techniques for the implementation based on a sliding principle, the problems tested. second one (BLF) is able to ®ll enclosures in the Concerning the methodology, hybrid algo- layouts, however, at higher computational cost. rithms are well suited for industrial demands. The The meta-heuristic hybrid algorithms have been layouts achieved are of similar quality as other tested on a number of packing problems and techniques. The implementation of the hybrid al- compared with heuristic and local search meth- gorithm is easier, since it is based on well-known ods and also with approaches used by other re- techniques and does not require development of searchers. problem-speci®c algorithms. With heuristics In terms of solution quality the meta-heuristic already being applied in industry, the acceptance algorithms outperform the heuristic packing rou- of research methods such as meta-heuristics cer- tines and the hill-climbing approach with SA tainly will be higher. performing best. The combinations with the more sophisticated heuristic (BLF) achieve better lay- outs than the ones using the BL decoder. For industrial problems the question, which technique Appendix A in combination with the BLF routing to choose, is a trade-o€ between material cost and simulation The packing tasks are classi®ed by the problem cost. In our study SA has achieved the best layout size, i.e., the number of items. For each category quality over all problem categories. Its execution three problem instances have been constructed. time, however, becomes larger with increasing The dimensions of the items are given in Tables 9± problem size. The evolutionary algorithms, GA 15. The optimum solution for each problem is and NE, are better in terms of execution time and known and is achieved by packing the rectangles in yield results, which are slightly worse than ones the order they are stated in the tables using the obtained by the SA. Hence if the time for solving BLF routine. a packing task is limited, GA and NE are ap- propriate. For very small time margins, only heuristic packing algorithms will be able to meet References this criterion. Table 8 summarises which methods are appropriate for di€erent sized packing tasks Andras, P., Andras, A., Zsuzsa, S., 1996. A genetic solution for under limited execution time. The information in the cutting stock problem. In: Chawdry, P.K., Roy, R., Table 8 has to be seen in connection with the Kant, R.K. (Eds.), Proceedings of the First On-line Work- shop on Soft Computing. Springer, Berlin, pp. 87±92. computational power of the simulation equipment Baker, B.S., Co€man Jr., E.G., Rivest, R.L., 1980. Orthogonal used. With the processing power constantly in- packing in two dimensions. SIAM Journal of Computing 9, creasing, it will be possible to apply meta-heuris- 846±855. tics eciently even in larger problems in the Burke, E., Kendall, G., 1998. Comparison of meta-heuristic future. algorithms for clustering rectangles. In: Proceedings of the 24th International Conference on Computers and Industrial Since the performance di€erence between the Engineering. Uxbridge, UK, to appear. hybrid methods using the BL decoder and the one Chazelle, B., 1983. The bottom-left bin-packing heuristic: An using the BLF decoder is only due to the improved ecient implementation. IEEE Transactions on Computers heuristic, the decoder has a larger e€ect on the c32/8, 697±707. outcome of the hybrid technique than the meta- Co€man, E.G., Garey, M.R., Johnson, D.S., 1984. Approxi- mation algorithms for bin-packing ± an updated survey. In: heuristic technique itself. This seems to suggest Ausiello, (Ed.), Algorithms Design for Computer Systems approaches, where more layout speci®c knowledge Design. Springer, Vienna, pp. 49±106. E. Hopper, B.C.H. Turton / European Journal of Operational Research 128 (2001) 34±57 57

Dagli, C.H., Poshyanonda, P., 1997. New approaches to Hwang, S.M., Cheng, Y.K., Horng, J.T., 1994. On solving nesting rectangular patterns. Journal of Intelligent Manu- rectangle bin packing problems using genetic algorithms. In: facturing 8, 177±190. Proceedings of the 1994 IEEE International Conference on Davis, L, 1991. Handbook of Genetic Algorithms. Van Systems, Man and Cybernetics. IEEE, Piscataway, NJ, Nostrand Reinhold, New York. USA, pp. 1583±1590. Dowsland, K.A., 1993. Some experiments with simulated Jakobs, S., 1996. On genetic algorithms for the packing of annealing techniques for packing problems. European polygons. European Journal of Operational Research 88, Journal of Operational Research 68, 389±399. 165±181. Dyckho€, H., 1990. Typology of cutting and packing problems. Kampke, T., 1988. Simulated annealing: Use of a new tool in European Journal of Operational Research 44, 145±159. bin-packing. Annals of Operations Research 16, 327±332. Eglese, R.W., 1990. Simulated annealing. A tool for operational Kroger, B., Schwenderling, P., Vornberger, O., 1991. Parallel research. European Journal of Operational Research 46, genetic packing of rectangles. In: Schwefel, H.P., Manner, 271±281. R. (Eds.), Parallel Problem Solving from Nature First Falkenauer, E., 1998. Genetic algorithms and grouping prob- Workshop. Springer, Berlin, pp. 160±164. lems. Wiley, Chichester. Kroger, B, 1995. Guillontineable bin-packing: A genetic Falkenauer, E., Delchambre, A., 1992. A genetic algorithm for approach. European Journal of Operational Research 84, bin-packing and line balancing. In: Proceedings of the 1992 645±661. IEEE International Conference on Robotics and Automa- Lai, K.K., Chan, W.M., 1997. An for tion, vol. 2. IEEE, Piscataway, IEEE Service Center, NJ, the rectangular cutting stock problem. International Journal USA, pp.1186±1192. of Industrial Engineering 4, 130±139. Goldberg, D.E., 1989. Genetic Algorithms in Search, Optimi- Mehlhorn, K., Naher, S., Uhrig, C., 1998. LEDA ± Library of sation and Machine Learning. Addison-Wesley, Reading, Ecient Data types and Algorithms. Max-Planck-Institut MA. fur Informatik, Saarbrucken, http://www.mpi-sb.mpg.de/ Hassler, R.W., Sweeney, P.E., 1991. Cutting stock problems LEDA/. and solution procedures. European Journal of Operational Press, W.H., Teuckolsky, S.A., Vetterling, W.T., Flannery, Research 54, 141±150. B.P., 1995. Numerical Recipes in C, The Art Scienti®c Herbert, E.A., Dowsland, K.A., 1996. A family of genetic Computing, second edition. Cambridge University Press, algorithms for the pallet loading problem. Annals of Cambridge. Operations Research 63, 415±436. Ratanapan, K., Dagli, C.H., 1997. An object-based evolution- Hinxman, A.I., 1980. The trim loss and assortment problems. ary algorithm for solving rectangular piece nesting prob- European Journal of Operational Research 88 (1), 8±18. lems. In: Proceedings of the IEEE Conference on Hopper, E., Turton, B.C.H., 1997. Application of genetic Evolutionary Computation. ICEC, IEEE, Piscataway, NJ, algorithms to packing problems ± a review. In: Chawdry, USA, pp. 989±994. P.K., Roy, R., Kant, R.K. (Eds.), Proceedings of the Sarin, S.C., 1983. Two-dimensional stock cutting problems and Second On-line World Conference on Soft Computing in solution methodologies. ASME Transactions Journal of Engineering Design and Manufacturing. Springer, London, Engineering for Industry 104, 155±160. pp. 279±288. Smith, D., 1985. Bin-packing with adaptive search. In: Gre- Hopper, E., Turton, B.C.H., 1998. A genetic algorithm for a 2D fenstette, J. (Ed.), Proceedings of an International Confer- industrial packing problem. In: Proceedings of the 24th ence on Genetic Algorithms and their Applications. International Conference on Computers and Industrial Lawrence Erlbaum, London, pp. 202±206. Engineering. Uxbridge, UK, to appear. Syswerda, D., 1991. Schedule optimisation using genetic Hwang, I., 1997. An ecient processor allocation algorithm algorithms. In: Davis, L. (Ed.), Handbook of Genetic using two-dimensional packing. Journal of Parallel and Algorithms. Van Nostrand Reinhold, New York, pp. 332± Distributed Computing 42, 75±81. 349.