Faculty Working Paper 91-0171 A Fixed Interval Due-Date Scheduling Problem with Earliness and Due-Date Costs i 2 » Dilip Chhajed Department of Business Administration Bureau of Economic and Business Research College of Commerce and Business Administration University of Illinois at Urbana-Champaign BEBR FACULTY WORKING PAPER NO. 91-0171 College of Commerce and Business Administration University of Illinois at Urbana-Champaign October 1991 A Fixed Interval Due- Date Scheduling Problem with Earliness and Due- Date Costs Dilip Chhajed Department of Business Administration Digitized by the Internet Archive in 2011 with funding from University of Illinois Urbana-Champaign http://www.archive.org/details/fixedintervaldue91171chha A Fixed Interval Due-Date Scheduling Problem with Earliness and Due-Date Costs Dilip Chhajed* April 1991 Abstract In this paper we consider a problem where N jobs are to be scheduled on a single machine and assigned to one of the two due-dates which are given at equal intervals. Tardy jobs are not allowed, thus the due-dates are deadlines. There is a linear due-date penalty and linear earliness penalty, and the sum of these penalties is to be minimized. This problem is shown to be NP-hard. One case of the problem (the unrestricted case) is shown to be solvable in linear time. For the restricted case, lower and upper bounds are developed. Computational experience is reported which suggests that the bounds are quite effective. * University of Illinois, Department of Business Administration, 350 Commerce West, Champaign, IL 61820. 1. Introduction To motive the problem in this paper, consider a shop with a single machine and N jobs available at time that need to be assigned a due-date and sequenced on the machine. The time required by each job on the machine is known and deterministic. Finished jobs are supplied to the customer by a truck that is dispatched at a fixed time interval, for example, at the end of each week. Since all jobs finished during the week will be shipped at the end of the week, the due-date assigned to a job will be the end of the week in which the job is scheduled to be completed. Since customers prefer their jobs to shipped as early as possible, there is a penalty for assigning jobs to a due -date that is praportional to the length of the due-date. A finished job incurs a holding cost until it is shipped. The shop has the policy of delivering on the promised due-date, thus tardy jobs are not allowed. The measure of customer service level is through due-date cost. The problem is to find an assignment of due-dates (the week in which the job will be completed) and sequence such that the sum of earliness penalty and due-date penalty is minimized, subject to no tardy job. The problem of scheduling a given number of jobs to minimize the sum of earliness, tardiness, and due-date costs where the due-date cost of an order is praportional to its assigned due-date is well studied. Panwalkar, Smith, and Seidmann (1982) consider the case of single due-date and Chand and Chhajed (1990) consider the case of multiple due-dates. Models in which there a single fixed due-date and a schedule of minimum total earliness and tardiness costs are also considered (Hall, Kubiak, and Sethi, 1989; Kanet, 1981; Bagachi, Sullivan, and Chang, 1986). The interest in studying problems with earliness and tardiness costs (E/T Cost) supports the growing success and popularity of Just-In-Time (Baker and Scudder, 1990). Typically in a schedule obtained for a problem with E/T costs, some jobs will be finished on time, some will be early and others will be tardy. An early job incurs a penalty for each time unit it has to wait after completion until shipped to the customer, whereas a tardy job is shipped as soon as it is completed. In the literature, the cost associated with shipping each tardy job separately is not considered. A comprehensive review of the literature on scheduling problems with E/T costs is given in Baker and Scudder (1990). Note that in an JIT environment a tardy job may force a customer to shut down operations, the cost of which may be very high. In the problem we consider, the due-dates cannot be violated and so they are deadlines as considered in Ahmadi and Bagchi (1986) and Chand and Schneeberger (1988). Matsuo (1988) considers the problem with fixed shipping times (similar to ours) and minimizes the sum of overtime and tardiness costs. Our focus in this paper is on a restricted version of the above problem where only two due-dates are considered. We concentrate on this restricted version because even this case is computationally difficult (Appendix A). However this simple case provides us insights and results which can be useful in solving the general case. This paper also provides a framework for developing a solution scheme for many other useful and interesting variations of the problem, some of these are outlined in the concluding section. The rest of the paper is organized as follows. In section 2, we introduce the notation and formulate the problem for the two due-dates case. In section 3, we show that certain special case of the problem is easy to solve. In section 4, we provide a method to obtain lower and upper bounds. Our computational study, reported in section 5, indicates that these bounds are very effective. Concluding remarks are in section 6. In Appendix A, we show the complexity of the problem and proofs of several results are in Appendix B. 2. Preliminaries The statement of the problem we consider is: Assign N jobs to one of two due- dates and schedule them such that there is no tardy job and the sum of due-date penalty and earliness penalty is minimum. The two due-dates are given and are at equal intervals. We assume that pre-emption is not allowed and only one job can be processed at a time. All cost functions are assumed to be linear. We call this problem the 2-Due-Date Scheduling Problem (2DSP). We now introduce the notation. Notation : N: number of jobs t\: processing time of job i 8: due-date penalty per time unit (the earliness penalty per time unit is assumed to be one) X: time period (interval between two successive due-dates) Ji: job i. Occasionally we will refer to a job by its index, i.e. job i Dj: due-date of job i Q: Completion time of job i N T: sum of the processing times of all jobs = £ ti i=l (a, b): Set of integers a,a+l,...,b In our development, due-date j mean that the due-date is jx, j=l,2. We assume that T < 2x so that the problem is feasible. Jobs are indexed such that ti Q Die {x,2x}. Note that there may be idle time before the starting time of the first jobs assigned to due-dates 1 and 2. Thus a permutation schedule may not be optimal. However, there will be no idle time between jobs assigned to the same due-date. This can be shown by using a simple interchange argument. Also the completion time of the last job assigned to the first due-date may not coincide with the due-date. It is optimal to schedule jobs assigned to the same due-date in non-decreasing order of their processing time. Figure 1 shows the nature of different kinds of schedules that may occur. We will denote the optimal value of function Z by Z*. Given a schedule, the job at position i, denoted as Jgj, refers to the job which is preceded by (i-1) jobs. Since there may be idle time, the completion time of of J[i] may not i be equal to £ t[j]- Let ni denote the number of jobs (a decision variable) assigned to the j=l first due-date and let C[0] = 0. With these notation (Pi) can be rewritten as: (Pi) min Z = I (x - C[i]) + I (2x- C m ) + (m + 2(N-ni))x8 (1) i=l i=ni+l S. T. Cp] > C[i_i] + tp] , i=l,...N (2) C [ni ] < X. nie (1,N) (3) (4) Any optimal solution to 2DSP will satisfy one of the following cases (Figure 1): Case I: C[ ni ] - x Case II: C[ ni ] < x. [ v////xm^/M t^m^ d t=0 t=x t=2x V//\ Due-date 1 KS^i Due-date 2 (a) I l^^g^ii^^^y^^^^^^t^^^^l^^^^tr^ y t=0 t=x t=2x V7X Due-date 1 CSSS3 Due-date 2 (b) Figure 1. Two Kinds of Schedules We now give an example which has an optimal solution corresponding to Case H Example: Let N=6, x=5.5, ti = {1,1,1,1,3,3}, 5=1. The optimal solution for this case is: t=0 t=5.5 d t=5.5 ZTTA Due-date 1 t=ll ^^^ Due-date 2 which is a Case II solution. The two cases are now analyzed separately. Case I: C[ n i] = x. In this case, the following property is satisfied by all optimal solutions: Property 1: If an optimal solution to (Pi) satisfies C[ ni ] = x, then idle time can be only before the first job that is processed in due-date 1 and the first job (position ni+1) in due- date 2. For this case Q ni ] = x and C[N] = 2x and the objective function of (Pi) can be rewritten as: I (x - C[i]) + I (2x- C[ii) + (2N-ni)x5 i=l i=ni+l ni N = I (C [ni ] - C[i]) + I (C[N]- Ch) + (2N-ni)x5 i=l i=ni+l ni ni N N = S Itrj]+ I £ tm + (2N-n0x8 i=l j=i+l i=ni+lj=i+l = I(i-l)t[i]+ I(i-l-ni)t [i] + (2N-ni)x5 (5) i=l i=ni+l Therefore (Pi), with the additional constraint that C[ ni ] = X, can be formulated as, ni N (P 2 )minZi= I(i-l)t[i]+ I(i-l-m)t[i] + (2N-ni)T5 i=l i=ni+l S. T. Ql]^t[l] C[i] = C[i-i] + t[i], i=2,...,ni C [ni ] > t+t[ ni ] c [i] = c [i-l] + tffl* i=ni+2,...,N C[ ni ] = x , and (4). We will refer to the number multiplied to the processing time of the job assigned to position i as the positional weight of position i. In (P2), for example, the positional weight of position i (i t f i] C[i] = C[i-i] + t[i], i=2,...,N C [ni ] < x, and (4). In order to solve (Pi), we could solve (P2) and (P3). Then the optimal value of (Pi) will be given by Z* = min {Zi*, Z 2 *}. (7) In Appendix A we show that (Pi) is NP-hard. If T N/2. Since sorting takes O(NlogN) time and there are O(N) possible values of hi, this suggests an CXN^logN) algorithm. However, as we show, this procedure can be reduced to O(N) time. We first note that Wini. Thus, the wj's can be sorted in O(N) time. In the first iteration, with ni=mo, the solution can be obtained in O(N) time. We now show that, given a solution to any value of ni=n°, the solution for n=n°+l can be obtained in constant time. To show this, consider an example with 10 jobs and processing times ti < t2 <...< tio- When ni=6, the positional weights and the assignment of jobs is as follows: Due Date 1 Due Date 2 Position 1 2 3 4 5 6 7 8 9 10 Wi 1 2 3 4 5 1 2 3 Job# 10 8 6 4 2 1 9 7 5 3 Thus, jobs { 10,8,6,4,2,1 } are assigned to due-date 1 and the remaining jobs are assigned to due-date 2. Note that jobs assigned to a due-date are processed in LPT order. When ni = 7, the new weights and the corresponding assignments will be: Due Date 1 Due Date 2 Position 1 2 3 4 5 6 7 8 9 10 Wi 1 2 3 4 5 6 1 2 Job# 10 8 6 4 3 2 1 9 7 5 In going from a solution with ni=6 to ni=7, the smallest job (here job 3) assigned to the second due-date is reassigned to due-date 1. All the other jobs remain assigned to their earlier due-dates. The relative positions of some jobs in due-date 1 are increased by 1, and the relative position of all jobs assigned to due-date 2 increases by 1. Note that the cost resulting from these changes can be computed in constant time, once the optimal cost and the solution for ni=6 is given. Thus, after the initial computation of the solution for ni=mo, each subsequent optimal cost to (5) as a function of ni can be computed in constant time resulting in a total complexity of O(N). 4. Sharp Lower and Upper Bounds In this section we provide a method to obtain lower and upper bounds to 2DSP when 2t >T>t. Suppose we know that ni jobs are assigned to due-date 1 and the remaining N-ni jobs are assigned to due-date 2, i.e. constraint (4) is no longer present. Let the optimal objective function value with ni jobs assigned to due-date 1 be Z*(ni). As the number of jobs assigned to the first due-date can vary from 1 to N (more on this later), the optimal value of (Pi) is be given by, Z* = min ni e (^nj Z*(ni). With ni jobs assigned to due-date 1, we find Z*(ni) by considering the two cases as before. We now analyze these two cases separately in order to obtain a lower bound to Z*(ni). Case I: C[ ni ] = x, ni fixed. In order for the completion time of the last job assigned to due-date 1 (the job in position ni) to be x, it is necessary and sufficient to have the sum of the processing time of jobs assigned to each of the two due-dates to be less than or equal to x. This is written as, It[i]x. (16) i=ni+l Constraint (15) restricts the total processing times of jobs assigned to due-date 1 to less than the period and constraint (16) is required because the total processing time of jobs N ni ni assigned to due-date 2 must exceed x. With £t[i] = T- £ t[g f (16) becomes T- £ t[i] i=ni+l i=l i=l ni >xor T - x > X t[i] . Since T - x < x, constraint (16) implies (15). (P3) with ni fixed can i=l be rewritten as: N min Z2(ni) = £ (i-l)t[i] + (2N-ni)x5 - nix i=l S. T. It[i] min ( min ni {Z*i(ni)}, min ni {Z*2(ni)}), = min (min ni {maxx lf x 2 Z*\(niMXl)}, min ni {maxx Z*2(ni,X)}) = Z*. «» The dual problems (14) and (19) can be solved by any of the methods given in Fisher (1981). We now develop several results that reduce the computational time required to obtain Z* and present an algorithm that uses these results to obtain Z*. Lemma 1 : There exists an optimal solution to (14) with at least one ofXj and X2 equal to 0. Proof: We prove this by contradiction. Suppose for fixed ni, we have multipliers X*\ > and \*2 > for which Z*\(n\,X*\,X*2) is an optimal solution to (14). Case A: X*\ > \*2- If we use new multipliers X.'i = X*\-X*2 and V2 - ^*2-^-*2=0> tne relative ranking of the positional weights does not change and so the given sequence is still optimal with these new values of the multipliers. The new objective function value in (13) is, Z*i(ni,ViA2) = I (k\ -V 2 + i-l)t[i] + xVl) t [i+ni ] + (2N-ni)x8 - V x x - X'j{% - T) i=l i=l = Z*i(ni,X*iA* 2 ) + ^*2(2l-T). As 2t >T, Z*i(ni,X'i,V2) > Z*i(ni^,*i,X*2) and thus we have found a solution which is at least as good as the given optimal solution to (14) and satisfies the Lemma. 12 Case B : X*\ < X*2. The proof of this case is similar to the proof of Case A. Now we set X f \ = A.*i-A,*i and X'2 = ^*2 -^*i- «» Lemma 2: It is sufficient to consider only integer values of the multipliers in (13) and (18). Proof: Consider (13). Only one X[ (i=l,2) is positive. Suppose Xi >0 and k < ^4 < k+1 for some integer k. For any value of X\, Z*i(ni,A,i,0) is obtained by arranging the sequence [(X\ + i-l):i=l...ni)u{( i-l-ni):i=ni+l...N) in decreasing order and multiplying it with ti's. If we vary X\ between k and k+1, the ordering of the sequence does not change and so the first two terms in (13) are linear functions of X\. Thus (13), with k < X\ < k+1 has an optimal solution at an extreme point, i.e., Xi=k or A.i=k+1. The proof of X2 > in (13) and X > in (18) is similar. «» By the virtue of the above two Lemmas, we only have to consider integer values of the multipliers. Furthermore, while computing Z*i(ni,A.i,A,2), at most one of the two multipliers will be non-zero. We need the following definitions for the next Theorem. Let, mo = minimum integer > N/2, mi =max {j: £ ti T- t}, i=l 1113 = max {j: £ ti < T-x}. i=l Note that in defining mi and 1113 we add the smallest jobs, whereas in defining 1113 we are adding the largest jobs. Theorem 2 provides values of ni and the multipliers (X.i, X2,X) that are sufficient to evaluate Z*. Theorem 2: The lower bound Z* in (20) can be computed by restricting the range of search 13 to,a)ForZi(ni,XiM): al) max{m2,mo} ^nj } for ni € . Step 5. Set Z* = min (min ni {Z*i(ni)}, min ni {Z*2(ni)}). To obtain the time complexity, we note that functions Z*i(ni,A.i,0), Z*i(ni,0,^2)> and Z*2(ni,>.) are piece- wise concave function in the multipliers (Nemhauser and Wolsey, 1988). Thus for a given value of ni, max{ Z*i(ni,A.i,0) : ^i e < 0, N-ni)} can be computed by performing a binary search over the feasible range of X\. This will require O(logN) computations of Z*i(). Computation of Z*i() requires finding the weights ( w i=^l + i-l:i=l...ni}u{vi=i-l-ni:i=ni+l...N}and sorting them. Since wi < wj+i and vj< vj + i finding a sorted list of these two can be done in O(N) time and hence Z*i() can be 14 computed in O(N) time. Consequently, maxx 2 { Z*i(ni,0,X2)} can be computed in O(NlogN) time. A similar argument shows that max{ Z*i(ni,0,A,2)}and max{ Z*2(n\,X)} can also be computed in O(NlogN) time. Since ni < N, the total complexity is 0(N 2 logN). Upper Bound: While solving each problem in steps 1,2, and 4, an upper bound is computed as follows. Given the assignment of jobs, if the assignment is feasible (the sum of the processing times of the ni jobs assigned to the first due-date is less than or equal to x) then the cost of the schedule is computed using (5) or (6). Finally, the lowest cost feasible assignment gives an upper bound. 5. Empirical Analysis To investigate the effectiveness of the proposed lower and upper bounds we coded the heuristic algorithm in the Pascal programming language on a personal computer (Macintosh Hex). A 3 4 experimental design was used involving number of jobs (N); processing times of jobs; tightness of due-date; and the due-date penalty. The values of N were (20,30,40). The processing times (integer) of the jobs were generated from a uniform distribution between (l,tmax) with tmax being (10,20,30). The tightness of the due-date refers to the relative amount of idle time. We set the time period x =ocZti/2 where a is a parameter with values (1.1,1.3,1.4). Here a=l.l implies 10% idle time in the data. The earliness penalty was set to 1 and (0.1, .75, 1.25) were the values used for the due-date penalty per job per time period. . Thus 81 different problems were studied. For each problem five replications were done. Lower bounds were computed using the algorithm DDLB and upper bounds were obtained as per the method outlined earlier. Table 1 summarizes the average and the maximum values of the relative gap, measured as 100*(upper bound - lower bound)/lower bound. As Table 1 indicates, the lower and the upper bounds are very close. The maximum gap for the 405 problems we solved was 0.24%. For over 65% of the problems, optimal solution was found. The average time for the 40 job problems was approximately 14 seconds. 15 6. Conclusion This paper introduces a new scheduling problem with due-date and earliness costs that has applications in JIT environments. The problem with two due-dates was shown to be NP-hard. A linear time algorithm for a special case and a lower bound for the general case were provided. Computational experience suggests that these bounds are quite tight. There are several possible extensions, some of which are subject of our on-going research. (i) The extension of this methodology to more than two due-dates and the identification of special cases that are solvable in polynomial time. (ii) Variable delivery intervals and the possibility of dispatching additional trucks with extra cost or perhaps not making a trip in some time periods. (iii) Truck capacity constraints, job dependent earliness penalties, and different release times of jobs. 16 Appendix A Problem Complexity We show that 2DSP is NP-hard by reducing the NP-hard even-odd partitioning problem (Garey, Tarjan, and Wilfong, 1988) to 2DSP in polynomial time. Even-Odd Partitioning Problem fEOPP): Given 2n numbers, x\ does there exists a partition Xj andXi of these numbers such that Z X eXj *i = ExseX? x i an d exactly one of {x2i-iPC2iJ is in Xj (and so in X2) for i=l,. . ,,n. Given an instance of EOPP, we define an instance of 2DSP with 2n jobs. The 2n processing time of the jobs are, ti = Xi + |i, for i = 1,. . .,2n with ji = £ x i and the time ! 2n j M period x= ~ £ti = (n-Hy)|i. Observe that ti X. As J£ l i < x, the optimal schedule will have n jobs assigned to each of i=l i=l two due-dates. We now analyze the two cases considered in section 2 with the value of ni fixed to n. Case I: The completion time of the n* job coincides with x. The total penalty of such a schedule is given by (5), which in this case, is: n 2n n Zi(n)= X(i-l)t[i]+ X(i-l-n)t [i] + 3nx8= I 0, X 2 = 0. By Lemma 2 we restrict A,i to non-negative integers. Consider (13) and let the positional weights be, wj = A,i +i-l i=l,...,ni vj = i- 1 i=l...,N-ni. Note that wi < w 2 <... N-ni, V]sf. ni ^wi and thus the smallest ni jobs are assigned to the first due-date to get Zi*(ni,>.i,0). This optimal value is equal to, ni N-ni Zi*(ni,Xi,0) = X wit ni+ i- i + I vi tN+i-i + (2N-ni)x5 - X x x i=l i=l ni = ^l( S ti - x) + Constant i=l 19 ni Since ni satisfies (al), X U ^ T, and so Zi*(ni,A.i,0) > Zi*(ni,A.i+l,0) for X\ > N-n\. i=l Therefore max^j Zi*(ni,A.i,0) = max^N-i^ Zi*(ni,A.i,0). (a3) Again by Lemma 2, when X2 > 0, it is sufficient to set ^i = and by Lemma 2, integer values of X2 are sufficient. Consider (18) and let Wi = -A.2+i-l i=l,...,ni vi = i- 1 i=ni+l...,N. Note that wi < W2 <... T- x when ni satisfies (al), Z2*(ni,0,A.2) ^ Z2*(ni, O.A.2+1) f° r ^2 ^ ni-1. i=l Therefore max\ 2 Z2*(ni,0,X.2) = maxx 2 < ni -i Z2*(ni,0,A.2)- (bl) The argument for the upperbound on ni is similar to the corresponding case in (al). To show that N-mi-1