Solving Packing Problems by a Distributed Global Optimization Algorithm

Packing optimization problems aim to seek the best way of placing a given set of rectangular boxes within a minimum volume rectangular box. Current packing optimization methods either find it difficult to obtain an optimal solution or require too many extra 0-1 variables in the solution process. This study develops a novel method to convert the nonlinear objective function in a packing program into an increasing function with single variable and two fixed parameters. The original packing program then becomes a linear program promising to obtain a global optimum. Such a linear program is decomposed into several subproblems by specifying various parameter values, which is solvable simultaneously by a distributed computation algorithm. A reference solution obtained by applying a genetic algorithm is used as an upper bound of the optimal solution, used to reduce the entire search region.


Introduction
A packing optimization problem is to seek a minimal container, which can hold a given number of smaller rectangular boxes.This problem is also referred to as a container loading problem.Packing cartons into a container is concerning material handling in the manufacturing and distribution industries.For instance, workers in the harbor have to pack more than one type of cartons into a container, and they often deal with this problem by the rule of thumb but a systematic approach.Therefore, the utilization of the container is low , which will cause additional costs.2 all of n boxes are within the range of x, y, and z.
x, y, z, x, y, z are constants .

2.1
According to Chen et al. 10 , the current packing model adopts the terminologies as follows.
p i , q i , r i : Dimension of box i, p i is the length, q i is the width, and r i is the height, and p i , q i , and r i are integral constants.i ∈ J, J {1, 2, 3, . . ., n} is the set of the given boxes.
x, y, z : Variables indicating the length, width, and height of the container.
x i , y i , z i : Variables indicating the coordinates of the front-left-bottom corner of box i. l xi , l yi , l zi : Binary variables indicating whether the length of box i is parallel to the X-axis, Y -axis, or Z-axis.The value of l xi is equal to 1 if the length of box i is parallel to the X-axis; otherwise, it is equal to 0. It is clear that l xi l yi l zi 1.
w xi , w yi , w zi : Binary variables indicating whether the width of box i is parallel to the X-axis, Y -axis, or Z-axis.The value of w xi is equal to 1 if the width of box i is parallel to the X-axis; otherwise, it is equal to 0. It is clear that w xi w yi w zi 1.
h xi , h yi , h zi : Binary variables indicating whether the width of box i is parallel to the X-, Y -, or Z-axis.The value of h xi is equal to 1 if the height of box i is parallel to the X-axis; otherwise, it is equal to 0. It is clear that h xi h yi h zi 1.
For a pair of boxes i, k , where i < k, there is a set of 0-1 vector a ik , b ik , c ik , d ik , e ik , f ik defined as The front-left-bottom corner of the container is fixed at the origin.The interpretation of these variables is illustrated in Figure 1. Figure 1 contains two boxes i and k, where box i is located with its length along the X-axis and the width parallel to the Z-axis, and box k is located with its length along the Z-axis and the width parallel to the X-axis.We then have l xi , w zi , h yi , l zk , w xk , and h yk equal to 1.In addition, since box i is located on the left-hand side of and in front of box k, it is clear that a ik d ik 1 and b ik c ik e ik f ik 0.
According to Chen et al. 10 and Tsai and Li 20 , the packing problem can be formulated as follows.

Mathematical Problems in Engineering
x i p i l xi q i w xi r i h xi ≤ x, ∀i ∈ J, 2.10 y i p i l yi q i w yi r i h yi ≤ y, ∀i ∈ J, 2.11 x, y, z, x, y, z are constants,

2.20
x, y, z are positive variables.

2.21
The objective of this model is to minimize the volume of the container.The constraints 2.3 -2.9 are nonoverlapping conditions used to ensure that none of these n boxes overlaps with each other.Constraints 2.10 -2.12 ensure that all boxes are within the enveloping container.Constraints 2.13 -2.18 describe the allocation restrictions among logic variables.For instance, 2.13 implies that the length of box i is parallel to one of the axes.2.16 implies that only one of the length, the width, and the height of box i is parallel to X-axis.
Since the objective function of Problem 1 is a product term, Problem 1 is a nonlinear mixed 0-1 program, which is difficult to be solved by current optimization methods.Chen et al. 10 can only solve linear objective function.Tsai and Li's method 20 can solve Problem 1 at the price of adding many extra 0-1 variables.

Proposed Method
Consider the objective function Obj xyz in 2.2 , where Proof.Since ∂Obj /∂x 6x 2 − 2x r 3s rs s 2 xy yz 2xz > 0, it is clear that Obj is an increasing function.
Proposition 3.2.The optimal solution of Problem 1 is integral.
Proof.Since dimensions of box i, p i , q i , r i , are integral constants for i 1, 2, . . ., n and all of n boxes are nonoverlapping, therefore, x * , y * , and z * that indicate the optimal solution of the container must be integral.Proposition 3.3. 3n i 1 p i q i r i ≤ x y z /3, where p i is the length, q i is the width, and r i is the height of the given box i. [19,20] Proof.Since n i 1 p i q i r i ≤ xyz and 3 √ xyz ≤ x y z /3, then we can have 3 n i 1 p i q i r i ≤ x y z /3.According to the above propositions and given values of r and s denoted as r and s , consider the following program.Adding the constraint x ≤ x Δ to Problem 2 for reducing the search region of the optimal solution, we can have the following two programs.
r and s are fixed values.

Minimize x
subject to all the constraints in Problem 3.According to the above propositions, a packing optimization problem, which is a nonlinear 0-1 programming problem, can be transformed into a linear 0-1 program by introducing two parameters r and s.Then we can guarantee to obtain the global optimum of a packing problem by solving the transformed linear 0-1 programs.The distributed computation scheme is also proposed to enhance the computational efficiency.

Distributed Algorithm
The solution procedure for solving Problem 1 to obtain a global optimum is presented in the following with a flow chart shown in Figure 2.
Step 1. Find an initial solution by GA .From Proposition 3.4, the obtained solution is x Δ , y Δ , z Δ and the constraint x ≤ x Δ can be utilized to reduce the searching space of the global solution.
Step 2. Denote s m and s 1 as the upper and lower bounds of s, respectively.Find the bounds of s x − z by solving the following linear programs:

4.1
Let x − z s i , i m, and go to Step 3.
Step 3. Denote r n and r 1 as the upper and lower bounds of r, respectively.Find the bounds of r x − y z by solving the following linear programs: Let r r j , j 1, and go to Step 4.
Step 4. Decompose main problem and perform distributed packing algorithm.According to verity of r and s, the main problem can be decomposed into several subproblems.The transformed subproblem of each iterative process is listed as follows.Solve problem P ij with x − z = s(i) and x − y + z = r(j).Let (x ij , y ij , z ij ) be the solution and x ij y ij z ij be the objective value Problem P ij .

4.3
Every sub-problem can be submitted to client computer and solved independently.Server computer controls the whole process and compares the solutions The structure of distributed packing algorithm is developed based on star schema.Owing to reduce the network loading and improve the computational performance of each client computer, all results found on all clients are directly sent to host computer.
Step 5. Let j j 1.If j > n, then go to Step 6.Otherwise, go to Step 4.
Step 6.Let i i − 1.If i < 1, then go to Step 3. Otherwise, go to Step 7.
Step 7. The whole process is finished and the host computer obtains the optimal solution x * , y * , z * with the objective value x * y * z * .

Numerical Examples
To validate the proposed method, several examples with different number of boxes are solved by LINGO 11.0 26 with the distributed algorithm.Two of the test problems denoted as Problems 1 and 2 are taken from Chen et al. 10 .The other examples are arbitrarily generated.Solving these problems by the proposed method, the obtained globally optimal solutions are listed in Tables 1 and 3. Comparison results between GA and the proposed method are shown in Table 2, and the associated graphs are presented in Figures 3 and 4.
Packing problems often arise in logistic application.The following example Problem 5 demonstrates how to apply the proposed algorithm in transportation problem and compare the result with traditional genetic algorithm.Problem 5. Several kinds of goods are packed into a container so as to deliver to 6 different stores on a trip.The dimensions of width and height of the container are 5 and 4. All goods are packed in cubic boxes, which have three different sizes.In order to take less time during unloading, boxes sent to the same store must be packed together.Different groups of boxes cannot overlap each other.Moreover, the packing order to each group must be ordered of the arriving time to each store.The boxes required to be sent to each store are listed in Table 4.The objective is to determine the smallest dimensions of the container.Solution 1.The arrangement of boxes can be treated as level assortment.The boxes packed in the same level will be delivered to the same store.After performing the proposed method, list of the optimal solutions are shown in Table 5, and illustrated graph is presented in Figure 5.

Conclusions
This paper proposes a new method to solve a packing optimization problem.The proposed method reformulates the nonlinear objective function of the original packing problem into a linear function with two given parameters.The proposed method then solves the reformulated linear 0-1 programs by specifying the parameters sequentially to reach the globally optimal solution.Furthermore, this study adopts a distributed genetic algorithm and distributed  packing algorithm to enhance the computational efficiency.Numerical examples demonstrate that the proposed method can be applied to practical problems and solve the problems to obtain the global optimum.

Proposition 3 . 1 .
and x, y, z are positive variables.Denote r and s as two variables defined as r x − y z, s x − z.Replace y by 2x − s − r and replace z by x − s. xyz then becomes Obj as follows.Obj x 2x 2 − r 3s x rs s 2 .3.1We then have the following propositions.Suppose r and s in 3.1 are fixed values, then Obj is an increasing function.

2 Proposition 3 . 4 .
21 , r and s are fixed values.3.If x Δ , y Δ , z Δ is the solution of Problem 2 found by a genetic algorithm and x * , y * , z * is the globally optimal solution of Problem 2, then x * ≤ x Δ .Proof.Since Obj is an increasing function with single variable x following Proposition 3.1 and 2 x * 3 − r 3 s x * 2 r s s 2 x * ≤ 2 x Δ 3 − r 3 s x Δ 2 r s s 2 x Δ .Hence, x * ≤ x Δ .

3 . 4 Proposition 3 . 5 .
Let (x * , y * , z * ) be the global optimum of Problem 3, then x * , y * , z * is also the global optimum of Problem 4. Proof.Since Obj x is an increasing function with single variable x following Proposition 3.1 , Problems 2 and 3 have the same global optimum x * , y * , z * .
(x ∆ , y ∆ , z ∆ ) by GA.Let x * = x ∆ Find lower bound s(1) and upper bound s(m) of s = x − z, let s = s(i), i = m Find lower bound r(1) and upper bound r(n) of x − y + z, let r = r(j), j = 1

Table 2 :
Solution comparison of the proposed algorithm and genetic algorithm GA .

Table 3 :
Computational results for all boxes are cubic.

Table 5 :
List of optimal arrangement of the boxes.is 37, 5, 4 , and the minimal volume of the container is 740.