An Exact Bidirectional Approach to the Resource Constrained Project Scheduling Problem Razek E. Karnoub and Salah E. Elmaghraby Operations Research Program, North Carolina State University, Raleigh, North Carolina, USA.
[email protected],
[email protected] Abstract A new bidirectional shortest path approach to the Resource Constrained Project Scheduling Problem is discussed. The approach is based on Dijkstra’s Shortest Path algorithm and consists of iteratively generating reduced forward and reverse state networks until an optimal termination criterion is reached. The general principles that make the approach workable are examined.
1.
Problem definition, known exact methodologies and motivation for a new approach
The Resource Constrained Project Scheduling Problem, RCPSP for short, is the problem of scheduling a set of activities subject to given precedence relationships and the availability of limited resources required for their completion. The precedence relationships assumed for this problem are of the so-called ‘zero time lag finish-to-start’ variety where an activity is said to precede another if starting the second merely requires the completion of the first. For convenience, this set of activities is presumed to contain a start activity, preceding all others, and end activity, succeeding all others. Such a set of activities is said to determine a project instance. The objective of the problem is to minimize the makespan of an arbitrary project instance, i.e. the completion time of its end activity, under three further assumptions: Activity durations are discrete. The time horizon is subdivided into equal periods with • activities starting at their beginning. The activities' resource consumption levels are given discrete constants over their • durations. The resource availability limits are constant throughout the duration of the project. • The decision version of this problem is known to be strongly NP-complete [1]. For the most part, the exact methodologies investigated to solve it can be grouped into two categories. The first involves integer programming approaches that aim to derive models for the problem which can be efficiently solved to optimality. Unfortunately, this aim has been elusive for the more than four decades that this problem has been studied. Such models have been used mostly to derive lower bounds for the problem instead. Examples of this methodology have been the approaches of Pritsker et al. [2], Alvarez-Valdes and Tamarit [3], Mohring et al. [4] and Sankaran et al. [5], to name a few. The second category of exact methods studied consists of various Branch and Bound approaches, (BaB). These have generally proven to be the more successful approaches in computational terms. They include the approaches of Demeulemeester and Herroelen, [6] and [7], Mingozzi et al. [8], Brucker et al. [9], Klein [10] and Sprecher [11]. Though significantly more successful the BaB approaches have been, we find that they are limited in at least two aspects. First, RCPSP has both a start and an end activity. While it is quite intuitive to conceive that the root node of a BaB procedure should be the start activity, it is no less conceivable that it be the end activity. Actually, one might venture to think that a procedure could start from both ends and meet somewhere in the middle. To the best of our knowledge, no one has ever attempted such an exact procedure, and for good reason. Unfortunately, BaB is not amenable to deriving a termination criterion for such a procedure that guarantees optimality. This is true of Breath First BaB strategies but even more so of their Depth First counterparts which, conventional wisdom says, are the more efficient computationally. Moreover, it is conceivable that, due to an
1
instance's structure, a unidirectional algorithm solving the instance is very much time consuming in one direction but quite efficient in its opposite. Not knowing which direction to choose might be disadvantageous at best. A bidirectional algorithm could actually mitigate the disadvantage. Second, in most BaB procedures it is possible to compute the time required for a project to move from one state, represented by a node in the search tree, to a descendent state in a relatively easy way as the smallest time required for the completion of an ongoing or just starting activity at the parent state. We feel that this easily obtained information, which has no parallel in BaB procedures for other types of problem such as Integer Programming for example, is not taken advantage of in most existing BaB procedures for the RCPSP problem. The research undertaken for this communication is an attempt to design an exact procedure that takes these two concerns into account and investigates the tradeoffs that inevitably need to be made, vis-a-vis unidirectional methods, in order to implement them.
2.
Principles of a bidirectional procedure
Consider an RCPSP instance and an arbitrary feasible schedule to it. At any time period during its execution, the state of this project can be characterized by: (1) the activities that are completed, (2) those that are currently “active” with their remaining times and (3) those activities that have yet to start. Using the precedence relationships of the project, this characterization of the state can be rendered more concise by eliminating from it the activities that precede the active ones and those that succeed them; as the disposition of those activities is inferable from the active ones. What remains, besides the ongoing activities with their residual times, are the activities that are neither predecessors nor successors of the ongoing ones. The characterization of a project's state can now be rendered even more concise by eliminating from these latter activities the ones that possess uncompleted predecessors; as, again, their disposition could be inferred from these same uncompleted predecessors. Thus, the state of the project at any time period t can be characterized by the activities that are active at time t, with their residual times, and the precedence feasible but not yet started activities as of time t. With this concept of state, it is not hard to imagine that a schedule for a project instance is actually a sequence of states, one corresponding to each time period of the schedule, which starts with the state solely containing the start activity and ends with the state solely containing the end activity. Assuming every possible state of an instance is represented as a node and that arcs between two nodes indicate that the nodes correspond to consecutive states in some schedule of the instance, it is not hard to see that the objective of minimizing the makespan of the instance is equivalent to that of finding the chain of states, starting with the ‘start’ state and ending with the ‘end’ state, containing the least number of states. It is not hard to see also that sometimes we do not need to explicitly express many of these states as they contain the same activities as their predecessor states with only the remaining times of the ongoing activities decreased by one time unit. This observation allows for the coalescing of many such states into a single state corresponding to the completion of some activity in the preceding state. Clearly, a state may have more than one predecessor and the time elapsed between successive states can be indicated on the arc connecting the states. This gives rise to the concept of a state network as opposed to a BaB search tree. Now the problem can be seen as that of finding the shortest path between a ‘start’ node and an ‘end’ node in a directed acyclic network of positive arc lengths. a i (d i , r i1 , r i2 ) r ik : activ ity a i req uirem ent of re so urce k d i : du ratio n of activity a i R k : pe r p erio d availability of re so urce k
R 1 = 3, R 2 = 3
a 1 (3 ,2 ,0 )
2 1
a 2 (1 ,1 ,0 )
2
a 4 (7 ,2 ,2 )
3
a 5 (3 ,1 ,0 )
a 3 (3 ,0 ,2 ) F igure 1 - A p roject in stance to illustrate th e redu ced state n etw ork con cept (A oA rep resen tation ).
4
Two questions immediately arise in this setting. First, are we to generate the state network first and then find the shortest path? Note that if this were the case then this approach might require generating a huge network, even for a relatively small instance. Second, do we really need to generate all the states of such a network before we can look for the shortest path? Fortunately, the answer to both concerns is negative, as a shortest path procedure that can be implemented on a developing network is readily available, namely Dijkstra’s Shortest Path Algorithm with a slight modification, and as bounding rules can be used at will to limit the size of the network. Two easily implementable bounding rules we propose are variants of the well-known “local left shift” and “global left shift” rules used in many BaB procedures. We point out that given any state of the state network, descendent states satisfying the first, and even the second, rules can be generated using a recursive BaB procedure that runs in time linear in the number of such descendents. We call a state network resulting from the implementation of those two rules the reduced state network of an instance. Obviously, such a network may possibly be further reduced by use of lower bounds, upper bounds and several other known rules such as the “Cutset Dominance Rule” used in [6]. To illustrate these concepts, Figure 1 presents a simple project instance whose reduced state network is developed in Figure 2. a 1; a 3; a 4 1 3
a 1/2 ; a 3; a 4
a5
7
3 7 1
3
a 1; a 3; a 5
start
en d
1
a4 a 1; a 1/2 ; a 3 2
1
a 1 / 2 ;a 2 / 2 ; a 4 F igure 2 - T he reduced forw ard state netw ork of the instance in F igure 1.
So far the implicit assumption in our presentation is that the project instance, its state and reduced state networks are considered in the forward direction as an instance is usually given. But those concepts apply just as well if we reverse the given precedence relationships. The only difference to which we need to pay close attention is that the reduced reverse state network is not necessarily the same as the reduced forward state network. In fact, it is likely to be totally different. This means that the reduced reverse state network can be significantly more complicated or significantly less complicated than its forward counterpart; which happens to be the case of the
start
1
a2
7
a4
3
3
Figure 3 - the reduced reverse state network of the instance in Figure 1.
end
reduced reverse network (Figure 3) of the same instance previously considered. The same holds true, of course, when using further bounding rules to limit the size of the reduced networks. Nevertheless, therein lies the advantage of working with the two networks simultaneously. As progress in one network may be slow in one direction, progress in the opposite direction may be fast enough to ‘catch up with it’ at some later stage. The issue that arises, naturally, is to know when the ‘catching up’ is realized so as to terminate, as soon as possible, an algorithm proceeding simultaneously in both directions. This involves establishing (1) a suitable criterion whereby two paths, one in each network, are determined to have proceeded long enough for every activity of the instance to be completed, and (2) enacting another efficient criterion to make possible the assertion that a pair of such paths at hand does in fact yield an optimal schedule. These ideas can indeed be made mathematically precise in order to achieve a workable bidirectional algorithm. An algorithm along those lines is currently undergoing extensive testing to fine tune it and make it suitable as a tool to draw meaningful insights into the problem.
References [1] Blazewicz, J.; J.K. Lenstra and A.H.G. Rinnooy Kan (1983): Scheduling Subject to Resource Constraints: Classification and Complexity. Discrete Applied Mathematics 5, 11-24. [2] Pritsker, A.A.B.; L.J. Watters and P.M. Wolfe (1969): Multiproject Scheduling with Limited Resources: A Zero-One Programming Approach. Management Science 16, 93-108. [3] Alvarez-Valdes, R. and J.M. Tamarit (1993): Project Scheduling Polyhedron: Dimension, Facets and Lifting Theorems. European Journal of Operational Research 67, 202-220. [4] Mohring, R.H.; A.S. Schultz; F. Stork and M. Uetz (1999): Resource-Constrained Project Scheduling: Computing Lower Bounds by Solving Minimum Cut Problems. In: Nesetril, J. (Ed.): Algorithms - ESA 1999: Proceedings of the 7th Annual European Symposium, Prague, Czech Republic, July 16-18, 1999. Lecture Notes in Computer Science 1643. [5] Sankaran, J.K.; D.L. Bricker and S.H. Jyang (1999): A Strong Fractional Cutting-Plane Algorithm for Resource-Constrained Project Scheduling. International Journal of Industrial Engineering 6, 99-111. [6] Demeulemeester E.L. and W.S. Herroelen (1992): A Branch and Bound Procedure for the Multiple Resource Constrained Project Scheduling Problems. Management Science 38, 18031818. [7] Demeulemeester E.L. and W.S. Herroelen (1997): New Benchmark Results for the Resource Constrained Project Scheduling Problem. Management Science 43, 1485-1492. [8] Mingozzi, A; V. Maniezzo; S. Ricciardelli and L. Bianco (1998): An Exact Algorithm for the Resource-Constrained Project Scheduling Problem Based on a New Mathematical Formulation. Management Science 44, 714-729. [9] Brucker, P.; S. Knust; A. Schoo and O. Thiel (1998): A Branch and Bound Algorithm for the Resource-Constrained Project Scheduling Problem. European Journal of Operational Research 107, 272-288. [10] Klein, R. (2000): Scheduling of Resource Constrained Projects. Kluwer Academic Publishers, Boston, Massachusetts. [11] Sprecher, A. (2000): Scheduling Resource-Constrained Projects Competitively at Modest Memory Requirements. Management Science 46, 710-723.
4