Reactive schedule modification in multipurpose ... - ACS Publications

Reactive schedule modification in multipurpose batch chemical plants ... Cite This:Ind. Eng. Chem. Res.199433177-90. Publication Date (Print):January ...
0 downloads 0 Views 2MB Size
Ind. Eng. Chem. Res. 1994,33, 77-90

77

Reactive Schedule Modification in Multipurpose Batch Chemical Plants Kishore B. Kanakamedala? Gintaras V. Rek1aitis;J and Venkat Venkatasubramanian.98 School of Chemical Engineering, Purdue University, West Lafayette, Indiana 47907

A new scheme is described for reactive schedule modification in the face of unexpected deviations in processing times and unit availabilities of a multipurpose batch plant (MBP). Schedule modification is done using a least impact heuristic beam search which proceeds in two levels: creation of a decision tree which makes use of possible reroutings of the product that is causing a conflict, and heuristic pruning of the search space to contain the combinatorial complexity. The heuristic chooses a path among all possible reroutings for a product such that the impact of each decision on the rest of the schedule is kept as small as possible. This approach has been implemented and tested on a number of simulated deviations in a MBP case study with three products. The proposed least impact heuristic was found to perform better than the earliest finishing unit heuristic in all the cases considered. 1. Introduction

The interest in the batch mode of chemical processing has recently been substantial, both in industry and in academia. A batch production facility typically consists of a collection of equipment items which have a certain degree of flexibility in both functionality and connectivity. That flexibility facilitates the production of a wide range of products in a single plant. The increased flexibility of batch processingcomes at the price of increased complexity of operation. The operation of a batch plant consists of production planning at the highest level, scheduling of various products at the intermediate level, and the unit level process control at the lowest level (Cott and Macchietto, 1988). There has been a considerable amount of attention paid to developing good strategies to automate all the stages of batch plant operation. Almost all the work reported so far on scheduling systems for batch chemical plants has been aimed at developing either a priori schedules, which take all the orders for a planning period and schedule them on the plant equipment, or reactive scheduling systems, which schedule each order as it arrives at the plant. Developing a priori schedules assumes that the plant and the production requirements are static throughout the scheduling period; hence it does not consider the possibility of plant parameters being dynamic in nature. The ability to react to unexpected events during the execution of a schedule is an important part of a batch plant operating strategy as real plants do exist in a dynamic environment where parameters like processing times and unit availabilities change as the schedule is being executed. A schedule developed beforehand may become inefficient, or even infeasible, when there are unexpected deviations in plant parameters during the execution of the schedule. This problem is traditionally handled by a combination of ad hoc decision making by a human operator and repeated use of the static scheduling system. Resorting to full-scale rescheduling of the remaining orders can be quite expensive,time consuming,and disruptive to smooth operation of the plant. Hence, it is not desirable to do full rescheduling for every deviation. It is also important to be able to estimate projected product delivery dates in the face of changes in plant parameters. Hence, there is

* Authors to whom correspondence should be addressed. t

E-mail: [email protected].

t

E-mail: [email protected].

8

E-mail: [email protected].

0SSS-5SS5/94/2633-0077$04.50/0

a need for systems which can do reactive production schedule maintenance in the face of deviations, without resorting to full-scale rescheduling every time some deviation occurs. The decision levels in reactive schedule maintenance of a batch plant are shown in Figure 1. The bottommost level deals with the process and schedule execution monitoring. This will typically be performed by a human operator, but could be performed with the assistance of an automated plant monitoring and diagnostic methodology. The middle level deals with schedule modification when an unexpected event is detected at the lower level. This is concerned with adaptive tracking of the original schedule in the face of dynamic changes in plant parameters. The highest level is the rescheduling level. This can be invoked when the deviations in the plant parameters are sufficiently large. This level can make use, in part, of the scheduling strategies used to develop the static schedule beforehand. There has been very little work reported for the intermediate level of reactive schedule modification for multiproduct plants, and none for multipurpose plants. 1.1. Problem Definition. The general problem of reactive schedule modification can be defined as follows: Given the plant parameters along with product information, the original production schedule information and information about the deviation in the plant parameters, modify the original schedule so as to take the deviation into account. This modification has to be done such that the impact of the deviation on the rest of the schedule is the minimum possible. In other words, the aim is to develop a new schedule which can track the old schedule well. 1.2. Literature Review. In a batch chemical plant, it is sometimes difficult to estimate the processing times exactly beforehand. Typically the processing times used in a plant may be rough estimates based on the values obtained from previous runs along with approximate process modeling calculations. The variability of batch process parameters and their effects have been discussed by many researchers (Karimi and Reklaitis, 1985a,b;Smith and Rudd, 1964). Karimi and Reklaitis suggest that batch process variability is largely due to changes in operator response times, fluctuations in utility availability, equipment malfunction, recipe inaccuracies, and changes in raw material quality. As a result of these deviations, when running a plant using a fixed off-line schedule, delays are forced into the production operation as intermediates have 0 1994 American Chemical Society

78 Ind. Eng. Chem. Res., Vol. 33, No. 1, 1994 (Re)scheduler

h

i Reactive Schedule Modifier

+ Execution 4

Monitor

.

m Batch Plant

Figure 1. Reactive schedule maintenance.

to wait because the subsequent processing steps cannot commence as scheduled. One approach to minimizing the impact of batch process variability is to design storage between processing units and to maintain a reserve of material in storage for the downstream processors (Karimi and Reklaitis, 1985a,b). This procedure decouples the operation of the plant sections, hence allowing the original schedule to be used without modification. However, it requires that separate storage facilities be provided and that extra material be produced to be kept in reserve. Furthermore, this strategy is not suitable in the case of unstable intermediates as the subsequent operation must be performed without delay, and hence intermediate storage cannot be used. Another approach to minimizing the impact of process variability is to modify the process conditions in order to change the processing times so as to return the operation to the original schedule (Onogi et al., 1986). The main drawback of this approach is that tight dependence of product quality on the operation conditions does not leave much room for modification of these conditions. It also makes controlling the process operating conditions more difficult. These two approaches really do not address the problem as an adaptation of the original schedule. The first approach essentially amounts to design retrofitting rather than refitting the schedule. I t is done at the design or retrofitting stage and, hence, lacks the often needed reactfvity to deviations. The second approach takes a local view of the particular processingunit and does not consider the impact of the deviation on the rest of the schedule. The only approach to have dealt with the impact of a deviation on rest of the schedule was proposed by Cott and Macchietto (1989). This work deals with the schedule modification problem as a part of a larger computer aided production management system. The essence of the approach used is to shift the remaining batches in the schedule in time, using a shifting algorithm called the Projected Operation Modification Algorithm (POMA). POMA uses the information about the original schedule of a batch and modifies the starting times of all the processing steps of that batch by the maximum difference between the expected and actual completion times of each of the processing steps. This approach can be likened to

a modified completion time calculation. The main advantage of this approach is that very little information is needed, and hence it is suitable for on-line production schedule monitoring and control. The major drawback of this approach is that it minimizesthe makesapn and, hence, lacks good representation of plant's profitability as it does not account for customer priorities. Another problem that has not been addressed so far is the possible changes in the unit functionality either due to changes in its availability or due to some secondary reason to which the usage of the particular unit depends. Normally, the unit availability is assumed to be constant during the original schedule development. However, in a plant it is not uncommon to encounter unit breakdowns for relatively short durations. Unit availabilities can also change due to other unexpected reasons. For example, a particular unit cannot be used due to some utility failure, and hence the production may have to be either delayed or routed through another unit which does not make use of that utility. This is clearly a complex problem as the rerouting of a batch may delay production of another batch that was originally scheduled on the second unit. The advances in computer graphics hardware and software, and the need to make use of a human's abilities to make certain decisionswhich cannot be quantified, have recently renewed the interest in "interactive scheduling". Interactive scheduling systems have a combination of schedule generation and modification capability. Wiede (1984)developed an interactive graphic scheduling system for multiproduct plants under mixed intermediate storage policy. His system uses heuristic search techniques for suboptimal schedule generation and allows user intervention at selected points. Musier and Evans (1990) give details of features that should be incorporated in an interactive scheduling system. They report on an interactive scheduling system, ScheduleAid, with user intervention and graphical display capability. Both these systems are developed for multiproduct plants. They do rescheduling of the remaining orders whenever a user intervention occurs. All of the work done on schedule modification in multiproduct plants either resorts to simple time shifting with the objective of minimizing makespan or to full rescheduling of the remaining orders when the objective is a more complex function of plant and customer parameters. None of the work considers the possibility of changes in unit availabilities during schedule execution. Moreover, there has been no reported work on schedule modification in multipurpose plants. In the rest of this paper, we describe a least impact heuristic search scheme for reactive schedule modification in batch chemicalplants. 2. Solution Approach 2.1. Representation Scheme. The data items in a batch plant scheduling scenario naturally lend themselves to a hierarchical structure as shown in Figure 2. A schedule can be represented as a list of production campaigns, where each campaign contains a list of products that are scheduled in that campaign. Each product structure has a product priority value, a list of batches, and a recipe which is a list of tasks to which each of those batches must be subjected. Each task of a product recipe has pointers to all the units that are allowed to be used for that task. Each batch structure has a list of processing-step structures. Each processing-step structure corresponds to the physical processing of the batch in a task of the product recipe, and has the data items about the timing of the operation. The plant is represented as an array of all the

.

Ind. Eng. Chem. Res., Vol. 33, No. 1, 1994 79 Input data

schedule A

I

I

.).

campaigns

'i, /product

batches

J

tasks

I

i

7

7.

I

steps

umts Figure 2. Hierarchical representation of schedule and plant.

available processing units. Each unit structure has a list of processing-step structures on that unit. The schedule at the bottommost level is a two-dimensional network of processing-step structures with processing unit structures on one dimension and batch structures on the other. All of the connections between various data items are bidirectional, facilitating easy access of all the data. During the schedule modification procedure, new attributes are needed in unit and processing-step structures. An array of linked lists of availability intervals is added to each unit structure. A list of feasibility intervals is added to each processing-stepstructure. This representation scheme is flexible enough for representing both multiproduct and the more complex multipurpose plants. 2.2. Assumptions. The main characteristic of a multipurpose plant that distinguishes it from a multiproduct plant is the parallel production of multiple products following different flow directions in the plant. To deal with this complex nonlinear problem, it is traditionally assumed that the parallel production lines within a campaign are noninteracting. Such an assumption restricts a given unit from being used for the processing of two different products and may make the schedule modification process inefficient. The assumption of noninteracting production lines is relaxed in the present approach so that the flexibility available in a MBP can be exploited. Due to this relaxation, the original schedule need not necessarily be divided into multiple campaigns. Hence, the system is developed for a single campaign with multiple products being produced in parallel. In case of multiple campaigns, once the schedule is modified for a campaign, if the new assignments for the present campaign are such that it extends into the next campaign, the deviation can be propagated either by modifying the schedule for the next campaign with the impact of changes made in the present campaign take into account, or by scheduling the next campaign as it was in the original schedule and scheduling the part of the p resent campaign that disturbs the next campaign after that campaign. Only permutation schedules are considered in this work. It is assumed that production of a batch is noncyclic in nature; Le., two different steps of a batch are not allowed to be processed in the same unit. Moreover, splitting and merging of products is not allowed. Consequently, a batch maintains its identity throughout its processing sequence. It is assumed that each task of a product recipe is processed by a single unit. Parallel in-phase processing in multiple units is not allowed. This assumption can be relaxed by treating all the units operating in phase at a step as a

I

Decision Tree Construction

Pruning at Lower Level

!

Pruning at Higher Level

t New schedule Figure 3. Outline of the solution scheme.

single combined entity for decision making purposes. Although cleaning and transfer times are not considered in this scheme for simplicity of development, they can be readily incorporated. Storage is considered only as holding in a processing unit after a particular processing step is completed. 2.3. Outline of the Solution Strategy. Once information about the original schedule and the deviation is given to the system, all the batches are ordered by increasing order of their starting times in the original schedule. As shown inFigure 3, the search procedure starts from the batch with the deviation and proceeds sequentially batch by batch. A decision made at a batch may not be revoked at a later batch. In other words, all the decisions made at a batch are imposed on decision making for further batches. With each batch, the search proceeds processing step by processing step. On the basis of whether or not there is a possible conflict resulting from a decision made at a processing step, the conflict is resolved using a hierarchical beam search strategy. Beam search is a solution mechanism in which the consequences of a decision at each node of the search tree are ranked in a sequential depth-first manner. The beam width, also referred to as the branching factor, is the number of consequences that are considered at each decision node. The beam search makes use of the flexibility available in the plant structure to construct a decision tree. Heuristic pruning of the decision tree using the information about the original schedule is employed to contain the search complexity. The whole search proceeds in a conservative manner so as to minimize the impact of each decision on the rest of the schedule, while reexecuting the unit assignment and timing calculations for each processing step. The decision tree is constructed either by shifting in time the processing step that is causing the conflict, or by replacing the processing unit in demand at the point of conflict with another unit. Replacements are sought only if simple shifting does not absorb the deviation within the

80 Ind. Eng. Chem. Res., Vol. 33, No. 1, 1994 sl

WHrn s2

a \ \

0 ul

12

s3

WMB

0 u3

I3

t4

t4cT

time __c

Figure 4. (a, top) Soft timing constraint. (b, bottom) Hard timing constraint.

batch. The decision tree is pruned heuristically in two levels. At the lower processing-step level, the pruning is based on the local static properties of the schedule at that processing step. At the higher batch level, it is based on the impact of all of the decisions made in the previous batch. Unit replacement may potentially disturb another batch and delay it. Pruning at the batch level accounts for the possible absorption of the impact of a replacement decision in the second batch that is being disturbed. The reactive schedule modification scheme can be described as reexecuting the assignment and timing calculations for each batch under two types of timing constraints: 1. Soft constraints: These are the constraints that have to be satisfied if the remainder of the old schedule is not to be disturbed. For example, suppose that the step s l in Figure 4a has to be scheduled on the unit ul, and the step which is assigned to this unit just after s l in the original schedule is 92. Suppose s2 starts at t 2 according to the original schedule. In this case, t 2 is a soft constraint (soft upper bound) on the timing of product transfer of s l from ul; Le., s l should be processed and the product material transferred from u l before t2. Otherwise, the soft timing constraint may have to be relaxed. 2. Hard constraints: These are the constraints that are imposed due to the decisionsmade during the modification process for the previous batches. For example, suppose that the assignment calculations have been completed up to a certain batch of a product which is scheduled to finish on unit u3 at time t3 as shown in Figure 4b. Suppose a step s3 has to be scheduled on this unit at this time. Due to a replacement decision made at an earlier batch, u3 will be occupied from t4 to t4 + T. The fact that u3 is not available from t4 to t4 + T i s a hard timing constraint on the decision making at this step. During the search, hard constraints are strictly followed and soft constraints are relaxed with each batch in such a manner that the impact of this relaxation on the rest of the original schedule is minimized. At the completion of rescheduling of a batch, both soft and hard constraints are updated and the search proceeds with the next batch. When assignment calculations are reexecuted, the feasibility intervals for each processing step, i.e., the time intervals during which a particular step can be processed on a particular unit, and the availability intervals for each unit have to be maintained. This is different from maintaining a single time point (as done in some scheduling systems for multiproduct plants) or from the critical path method which maintains a single feasibility interval for a step on a given unit. During reactive modification, multiple intervals may have to be maintained due to replacement decisions made with the previous batches

which might have reassigned a unit for another processing step. For example, unit u3 in Figure 4b has two different availability intervals into which the processing step s3 of the next batch may be inserted. This requires the maintenance of multiple availability intervals for the unit and multiple feasibility intervals for the processing steps. For the purpose of maintaining the feasibility intervals of processing steps, we use the “multiple interval propagation” technique proposed recently by Zentner and Reklaitis (1991). 2.4. Initial Conditions. Initial conditions differ for the two types of deviations considered. For deviations in processing time, the decision making is performed only when the deviation is complete (Le., at the new finishing time). All the processing steps that started before the new finishing time have to be scheduled as they were in the original schedule. This does not really cause much loss in efficiencyif processing time deviations are not large. This decision can be improved if a projected finishing time of the process can be obtained by using a mathematical model. This is generally not worth the effort as the processing time deviations are typically small. It has to be noted that the proposed framework has a provision for specificationof a new finishing time as soon as the deviation starts if an estimate of the new finishing time can be obtained. In the case of unit unavailabilities, we assume that unavailabilities are detected and conveyed to the system at the end of a processing step. This assumption, in effect, says that the batch to which the step with deviation belongs can proceed as per the old schedule, whereas the later batches may have to be rescheduled. Unit unavailabilities, when they occur, are typically of longer duration than processing time variations. In such cases, the schedule becomes inefficient if the decision making is postponed until the tims the unit actually becomes available again. Therefore, we assume that the system is provided with an availability t i k e estimate of a unit as soon as it becomes unavailable. This improves the efficiency of the schedule as the operations that were scheduled to start between the unit unavailability time and the next unit availability time can be reassigned to different units if needed. If the estimated availability time changes at a later time, a new estimate can be used and the schedule modification procedure can again be invoked. 3. Heuristic Search

The search is done in two levels with a decision tree construction at the lower level and heuristic pruning at both the lower and the higher level. The decision tree construction proceeds in a two-step process of detecting a possible conflict at each step and then making the decision based on that conflict. A step is defined to be in a conflict if the unit that is being used for the present step will not be available for the next scheduled step on that unit as required by the original schedule. This definition of conflict accounts for both of the types of deviations considered. Any holding time in the original schedule is accounted for at this stage itself; i.e., if the deviation can be absorbed through changes in the holding time, then there is no conflict at this step. This definition of conflict associates the conflict with the batch that is causing the conflict rather than with the batch that is being disturbed by the conflict. Once a conflict is detected, the options available for conflict resolution are either to simply shift that step of the batch in time, or to replace the unit that is in demand at the conflict so that the disturbance

Ind. Eng. Chem. Res., Vol. 33, No. 1, 1994 81 b2 ul

I

step2

u2

.‘-LLs2

step3

bl

u3 u4

s2

SJ

n:

bl ul

b2

sl I

I

u2

s2

+A

bl u3 u4

.

:

s2

b2

”=JJs2 s2

ul u2 u3 u4

0

product1

product2

processing time deviation

conflict

Figure 6. Conflict resolution: (a) original schedule; (b) simple shifting; (c) replacement.

propagation is minimized. By replacing a unit, the deviation (or part of it) is essentially transferred to another batch. Before further discussion, a few frequently used terms need to be defined. At any processing step, by “simple shifting” is meant that the same unit used for the corresponding step in the original schedule,is assigned for this step and the disturbance is either absorbed at this step or propagated by time shifting. By “replacement” is meant that a unit other than the unit used for the corresponding step in the original schedule is assigned for this step. For example, a partial schedule for two noninteracting schedules without any deviation is shown in Figure 5a. u l and u2 are the units assigned for steps s l and s2 respectively of batches b l and b2 of product pl. Similarly u3 and u4 are the units assigned for steps s l and 52 respectivelyof batches b l and b2 of product p2. Suppose s l in b l of p l finishes later than expected. Figure 5b shows the propagation of this deviation by simple shifting within that batch. Note that simple shifting disturbs the step 5 2 in b2 of pl, hence causing a conflict. Figure 5c shows a replacement of unit u2 with unit u3 for the step s2 in b l of pl. This allows 92 in b2 of p l to be processed as scheduled originally. In this example, for the sake of simplicity, the replacement decision does not disturb product p2. However, it is possible that it may disturb a step of p2, in which case the deviation will be propagated to p2 from pl. “Unit a t this step” means the unit that was used for this particular step in the original schedule. “Beam width” is defined as the number of children nodes left at each node

s

simple time shifting

m

replacement n

Figure 6. Decision tree at lower level (for a given batch).

after pruning. A “stage” in the search refers to all the calculations associated with a batch in the original schedule. This term encompasses all of the various processes such as decision tree construction and pruning at both levels for schedule modification of each batch of the original schedule. In each stage, multiple batches corresponding to a single batch in the original schedule are handled. 3.1. Decision Tree Construction. At the lower processingstep level, the decision tree is constructed in a depth-first manner with conservative node expansion. First, feasibility intervals for simple shifting of all the steps of the batch are calculated, generating a full branch (from starting node to a leaf node) of the decision tree in the process. Next, timing assignments for each step in this branch are calculated. Timing calculations are done in the opposite direction to that of the processing order (i-e.,from the last step to first step as opposed to first step to last step of a batch) to avoid infeasible timing assignments. All the processing steps that had already started at the time of deviation are scheduled at the same times as in the original schedule. Each step that has started after the time of deviation is assigned such that it finishes at the closest feasible moment to the finishing time of that step according to the original schedule. As the timing assignments are calculated, a check for conflict is performed at each step. If there is a conflict at the present step or at any step downstream in this batch, a list of possible replacements for the unit at this step is developed. A t each node, a prespecified number (=beam width - 1) of replacements are chosen from the list, and are used in creating the rest of the children nodes. It should be noted that the node generated by simple shifting is one of the children nodes if simple shifting is feasible at this step. Next, each of the children nodes are expanded in a recursive manner. At the end of the tree construction in a batch, there are potentially NMpossiblealternative paths for the batch, where N is the number of the processing steps for that batch and M is the beam width. The decision tree at the lower level is illustrated in Figure 6, and the algorithm for node expansion in the decision tree is presented in Figure 7. 3.2. P r u n i n g at the Lower Level. At the lower level, when the tree is constructed, the replacements at each step are chosen on the basis of whether or not they satisfy the following criteria: 1. Only the units that have the functionality to process the particular processing step are considered. 2. From those units that have the required functionality, any unit that is assigned to a step in the present batch is

82 Ind. Eng. Chem. Res., Vol. 33, No. 1, 1994 Expand-ncde (node) [

Caldate feasibilitykt~valsof next ste? for 'simple shiidng' (fmt child node). If cdculations for!!a &e steps in the batch are not comp1e:ed Expand-ncb ( h t child).

Do assignment caldtons for first child. Check for conflict ckhc at the present step or ac any SXCF downsream in the batch. If conflict is found &u at the present step or downsoem [

Find rep1ac:~ents for the unit at the presenr ste?. Calculate ferlbiiity intervals for the next step on each of the chosen re?lacement units (other children nodes).

I If calculations for dl the steps in the batch are not completed Expandpod:(cc'nild)for each of the other children nodes.

I

of the reassigned unit and the product priority of the disturbed batch are local properties associated with this step. These properties are also static in nature in the sense that the heuristic index does not vary directly based on the deviation characteristics. It does depend on the deviation indirectly through the feasibility interval calculation. The index at a step that disturbs a batch i due to reassignment of unit j is given by Pi hi = 1 + rj

where pi is the priority of the product in batch i and rj is the replaceability of the unit j . The index hi accounts for the product priority and, partially, the possibility of transferring the deviation to another batch from the disturbed batch at a later stage in the search by replaceability. The larger the number of units that can replace a particular unit that is being used as a replacement, the greater the possibility of transferring the deviation from the disturbed batch to another batch. If there are no possible replacements, hi is equal topi. The average index for unit j is given by

Figure7. Algorithm for node expansion in decisiontree construction at the lower level. 1

eliminated. For the steps for which assignment decisions have already been made, the new assignments are used whereas old assignments are used for the rest of the steps. This procedure maintains the noncyclic nature of a batch. 3. The capacity of the unit for this particular processing step should be equal to or greater than the capacity of the unit that had been assigned to this step according to the old schedule. 4. From all the units that satisfy the above three criteria, only those units that are used in batches starting after the present batch and in steps that start after the time of deviation are considered. A list is made of all the units that satisfy the above four criteria. For each unit in this list, a list of feasibility intervals of the processing step is calculated. 5. From the above unit list, only those units that can finish this step earlier than would be the case under simple shifting are considered. Feasibility intervals for each replacement decision are reduced to satisfy this constraint. For each of the units remaining in the list, a heuristic index is calculated on the basis of all of the batches that may be disturbed if the unit is used as a replacement. The new step can start at many points in the list of feasibility intervals on a given unit. On the basis of where the new step starts, different numbers of batches may be disturbed. All of these batches need not be of the same product. Ideally, we would like to start the new step at the latest feasible moment in these intervals so that the disturbance is shifted to a batch that starts latest. It is not possible to decide at this stage about the exact timing of the processing steps of the disturbed batch as other decisions made for the batch that is causing the disturbance may affect this batch at other points. Hence, a heuristic index is calculated for each of the batches that may be disturbed (i.e., the ones that are scheduled on the given unit during the feasibility intervals for the new step) and the average of all these indices is calculated as the overall index at this node. The heuristic index at each node is based on the replaceability of the unit that is being reassigned and the product priority of the batch that is being disturbed. In this context, "replaceability" of a unit is defined as the number of units that can replace it. Both replaceability

(hj)= nb

where nb is number of the batches that may be disturbed by this replacement. This average index is calculated for all the units that satisfy the above mentioned five criteria. A prespecified number of units with the least index values are chosen as possible replacements for the tree construction at this node. 3.3. Pruning at the Higher Level. The trees that have been generated at the lower level are pruned once again at the higher level, and a maximum of 2M batches are created from all the pruned trees. The pruning is done on the basis of a heuristic index which accounts for the cumulative effect of all of the decisions made for that batch. First, assignment calculations are completed for each possible batch that may be generated from the decision tree. The complete timing calculations for these batches are performed at this stage. Each step is assigned such that it finishes at the closest feasible moment to the finishing time of that step according to the original schedule. The unit availabilities are updated at this stage. The 2M batches chosen at this stage are passed on to the next stage where 2M trees are constructed at the lower level again. This procedure is repeated until the calculations for all the batches are completed. At the end of the campaign, the weighted deviation from the original makespan of each of the products is calculated for each of the 2M solutions, and the one with the least value is chosen. For each batch generated in a stage, a heuristic index which accounts for the product priority and the possibility of absorbing the impact of the deviation within the steps of a disturbed batch is calculated at each step undergoing a replacement decision. The index Hi is given by

Hi = pi6i (3) where pi is the product priority of the batch that is being disturbed due to a replacement decision and 6i is the difference between the new completion time of the disturbed batch with all the decisions at this batch taken into account and the completion time of the distubed batch according to the original schedule. The impact of the replacement decision on the batch which is disturbed due

Ind. Eng. Chem. Res., Vol. 33, No. 1, 1994 83 batchl

batch2

0

stepl

barch3

h

step4

step5

step6

\

8

batchl

p2

P3

pn : primary batch n

@

nrh processing nep in a batch

s

simpledmeshifdng

r

replacement

d,: dominant node

Figure 8. Unit replacements.

to the replacement is accounted for by calculating the new finishing time of the disturbed batch with all the decisions in the present batch taken into account. This index does not consider the possibility of replacements at the disturbed batch. Hence, it can be conceptually likened to a "first-order approximation". The overall index for the present batch is calculated by

pn : primary batch n un : unit n

(4)

Figure 9. (a, top) Dominance of a node. (b, bottom) Determination of dominant node.

where the summation is over all the disturbed batches instead of all the replacement decisions. Figure 8 illustrates the replacement choices for a specific example. Batch1 is the batch for which the decision tree is constructed presently. Suppose that the second, third, and fifth steps have a replacement decision as shown. Replacement at step2 disturbs step3 in batch2, whereas replacement at step3 disturbs stepl in batch2 and replacement at step5 disturbs step3 in batch3. When the cumulative index is calculated, only two local indices are added-one for the disturbance in batch3 and one for two disturbances in batch2. Once the overall index H values are calculated for all the possible batches of the tree, M batches with the least H values are chosen. The above pruning scheme may encounter difficulties in cases where a particular choice dominates the rest of the choices at a node, and hence all the batches that come out of a stage may be dominated by this decision. For example, in Figure 9a, suppose that three batches p l , p2, and p3 are chosen based on H values. All of these three batches are said to be dominated by the node dn. To explain more clearly, suppose the node dn (which corresponds to the fourth step) is a replacement decision of unit u l by unit u2 for a given batch. Suppose the finishing time of the step4 on u2 is far less than it could be as the result of any other decision at that node. This may cause the batches that use u2 for step4 to have a low H value compared to rest of the batches in the decision tree, making the node d, a dominant node. The presence of a dominant node in the initial stages of the search can have a significant impact on the quality of the solution. This impact can be lessened by a more informed pruning via the dominance properties of the nodes in the initial stages. Hence, the previously described scheme is extended such that the

dominance properties in the initial stages of the search are taken into account. Once the first M batches (henceforth referred to as "primary batches") are chosen based on index H values, another M batches (henceforth referred to as "secondary batches") are chosen from the rest of the possible batches generated from each tree at a stage, with the dominance properties taken into account. It has to be noted that a tree is generated for each of the batches entering a stage. In the initial stages of the search, the number of batches that go from a stage to the next stage may not be the maximum allowed (2M-M primary and M secondary) as the number of possible choices may be limited. As the search continues, the number of batches that go from stage to stage can reach the limit of 2M. The stage at which this happens varies from problem to problem. The generation of both primary and secondary batches is controlled such that there are not more than M primary and M secondary batches at any stage. The secondary batches are generated until the number of batches passed from a stage to the next stage becomes 2M as the decisions made at the initial stages impact the rest of the search heavily. When the number of batches passed from stage to stage become equal to 2M, the distinction between the primary and the secondary batches no longer exists. From the stage when the number of batches reach 2M onward, a tree is generated for each of the 2M batches. A single batch is chosen from each such tree based on index H value and is passed on to the next stage. The rest of this section explains the procedure for calculating the secondary batches in the initial stages. Once M primary batches are chosen using the heuristic index H, the node (decision) that dominates all these M batches is determined. For example, the node dn in Figure 9a is

H= I

84 Ind. Eng. Chem. Res., Vol. 33, No. 1, 1994

the dominant node in the decision tree shown. All of the three primary batches in Figure 9b are represented as lists of steps with the identification of corresponding units written along with the step. The dominant node is determined by comparing each batch to every other batch in the list for the latest step with a common unit assignment. In the example shown, unit4 at the third step is the dominant node among the three primary batches. Once the dominant node is determined, the rest of the batches which are not dominated by this node are ordered according to a new index which is based on their distances from the dominant node and their respective index H values. The new index value is given by

D = Hld (5) where d is the distance of a batch from the dominant node. The distance of a batch (path) from the dominant node is equal to number of arcs that have to be traced to go from the dominant node to a batch. For example, batch1 in Figure 9a has a distance of 2 from the dominant node. I t is important to note the significance of the distance d because the node designated as the dominant node may not be the node that is actually causing the dominance in the first M batches. It is possible that one of the parent nodes of d, in Figure 9a may be the actual reason for dominance; Le., the dominance may be happening due to a decision at a previous step of the same batch, such as step3, whereas the calculated dominant node is at step4. The heuristic index D achieves a balance between the impact that a batch has on the rest of the schedule and not being dominated by a single decision. The M batches that have the least value of D are chosen as the secondary batches. 3.4. Unstable Intermediates. In case of unstable intermediates, the scheme presented above needs modifications in two places. (1)At the assignment calculation stage, for a stable intermediate, a processing step is started such that it finishes at the closest feasible moment to the finishing time of that step according to the original schedule. For a step with an unstable product, the timing assignment is changed such that the step finishes at the same time as the next step in that batch starts. This maintains the zero wait (ZW) transfer policy needed for unstable intermediates. It has to be noted that it is not possible to maintain the ZW policy in situations where a particular processing step has already started at the time of deviation detection and its finishing time is less that earliest feasible starting time for the next step. (2) At the stage of choosing replacements, a unit is not allowed to be used as replacement if the feed entering the unit is unstable to avoid any infeasibilities at a later stage of the search. 4. Results

In the previous sections, a heuristic approach to reactive schedule modification in batch chemical plants of intermediate campaign length was presented. The search is driven by a “least impact” (LI) heuristic which, in two levels, accounts partially for the impact on rest of the schedule when choosing among the various possible routings of a product. In this section, the problems used to test the efficiency of the heuristic procedure are presented. The performance is compared with the results obtained by using an “earliest finishing unit” (EFU) heuristic to order and choose among the different choices at each step. 4.1. Base Test Problem. As mentioned earlier, the scheme is developed assuming a single campaign. For test purposes, a multipurpose plant which has 26 equipment

Table 1. Equipment Units in the Test Plant unit type reactor 1 reactor2 reactor3 reactor4 reactor5 filter1 filter2 dryer1 dryer2

no. of units 2 3 3 3 4 3 3 3 2

names of unite unitl, unit2 unit3 to unit5 unit6 to unit8 unit9 to unit11 unit12 to unit15 unit16 to unit18 unit19 to unit21 unit22 to unit24 unit25, unit26

items grouped into 7 equipment groups is used. A base schedule with a single campaign is generated for three products produced in parallel. For simplicity in generating the base schedule, the assumption of noninteracting production lines is made. It is important to note that this assumption is relaxed during the testing of the reactive modification procedure. Table 1lists the various equipment types in the plant. The first product has four processing tasks in its recipe, the second one five, and the third one six. Each task in a product recipe can be processed in multiple units. Each product can be produced in different paths; i.e., two different batches of the same product need not go through the same unit sequence. In the base schedule, productl and product2 have two different processing sequenceseach, whereas product3 has six. Appendix A summarizes the rest of the plant and initial schedule data. The makespan (defined as the time taken from the start of the first batch until the completion of the last batch of a product) is equal to 51.0, 51.5, and 51.5 for productl, product2, and product3, respectively. 4.2. Test Results: Overall Summary. For this plant, 34 different deviations of various magnitudes and at various positions in the base schedule are simulated. In each case, the details of the deviation are enteredmanually, and the schedule modification procedure is run separately with the LI and the EFU heuristics. Each of the deviations is introduced in one of the first three batches of a product. As the processing time deviations are typically small, only 8 out of the 34 cases involve processing time deviations. The remaining 26 cases involve unit unavailabilities (one case for each of the 26 units). The processing time deviations are introduced at randomly chosen points distributed evenly among the products. Product1 uses 6 processing units whereas product2 and product3 use 7 and 13 processing units, respectively. Hence, two of the processing time deviation test cases are with productl, two are with product2, and four are with product3. The unit unavailabilities are of randomly generated durations between 4 and 10 time units while the processing time deviations are of randomly generated durations between 1 and 5 time units. I t has to be noted that all of the durations are discrete in nature; i.e., only multiples of 0.5 time units are allowed for simplicity. Two sets of product priorities are used for this study-(I) 1.2,1.4,1.6 and (11) 1.0,2.0,1.5for productl, product2, product3, respectively. All of the problems tested are run with a beam width of 3. All of the intermediates are assumed to be stable. The performance measure is the cumulative weighted difference between the new and old makespans of all the products. Tables 2 and 3 show the results obtained for the two sets of product priorities. In both of these tables, the first 26 test cases are unit unavailabilities and the remaining are processing time deviations. In Tables 2 and 3, the items in the column “deviation and product parameters” are represented using the following coded sequence:

Ind. Eng. Chem. Res., Vol. 33, No. 1, 1994 85 I

30

C

n

n

I -

100

80

80

40 10

20

0

0

Figure 10. Performance measure for product priorities set I.

Figure 11. Number of replacementa for product priorities set I.

Table 2. Results of t h e Test Cases with Product Priorities

Table 3. Results of the Test Cases with Product Priorities

I

I1

test case no. 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34

devand product params

perforperformance no.of mance no.of mea8 reassignta meas reaasignta withLI withLI withEFU withEFU 19.6 89 5.4 3 13.2 56 3 3.2 84 22.0 4 4.9 19.8 62 4 8.7 8.8 60 0 4.2 11.0 59 6.0 0 13.6 87 5 6.4 22.9 77 7 5.3 26.9 92 0 7.0 16.6 72 0 4.2 16.1 79 0 4.2 15.6 61 0 5.6 11.6 51 0 5.6 26.8 106 3 4.0 18.4 94 3 3.7 21.7 70 4 17.7 18.2 70 4 11.4 23.8 78 4 15.2 22.9 70 2 14.0 20.7 71 1 9.8 25.0 64 15.8 1 80 19.6 12.8 4 11.7 82 1 4.8 17.7 59 8.8 1 14.0 64 1 9.6 14.0 67 7.0 1 30.1 91 8.7 9 16.7 30 0 6.0 28.8 71 0 2.8 21.8 59 0 2.8 25.2 94 8.0 13 30.1 79 4.6 3 28.9 78 0 2.4 12.7 54 3 2.2

al blcl Tlun where a is the number of the step at the end of which the deviation is observed, b is the product number with the deviation, c is the batch number with the deviation, T is length of the deviation, and un is the unit with the deviation. It can be seen from Tables 2 and 3 that the LI heuristic performed better than the EFU heuristic in all of the cases tested. The performance measure and number of replacements from Table 2 are illustrated in Figures 10 and 11,respectively. The results reflect the conservativenature of the LI heuristic which, at least, partially accounts for the impact on the other batches. The EFU heuristic chooses the units based on their ability to finish a step earliest without any consideration of the impact of this

test case no. 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34

devand product params

perforperformance no.of mance no.of meaa reassignts meas reaasignta withLI withLI withEFU withEFU 4.5 3.5 6.0 8.0 3.5 5.0 10.0 2.5 8.25 5.25 5.75 7.0 8.0 6.5 7.5 17.25 11.75 13.25 13.0 11.25 8.25 12.75 5.5 8.25 10.5 5.25 12.75 5.25 4.0 4.0 7.75 3.75 2.25 4.5

2 3 0 0 1 0 4 3 2 1 4 4 0 1 4 2 9 6 1 1 0

0 1 0 0 0 7 6 0 0 2 0 0 3

18.75 13.75 21.75 19.5 7.5 11.0 14.25 23.5 26.25 17.5 15.25 15.25 10.0 27.75 19.5 26.5 18.5 23.0 23.5 22.5 25.0 19.6 11.5 18.25 13.75 15.25 31.5 17.5 24.75 23.5 26.75 33.5 18.25 13.0

89 56 84

62 60 59 87 77 92 72 79 78 51 106 95 88 71 78 99 71 64 80 82 59 75 67 91 39 68 59 68 64 79 54

choice on the rest of the schedule. The LI heuristic also does very few reassignments of units while improving the objective function in all the cases tested. This is in line with the idea of disrupting the original schedule as little as possible. The computation of all the test cases reported in Tables 2 and 3 took an average of 45 s of CPU time on a SUN SPARCl workstation. The longest run took 2.5 min while the shortest run took 15 s on the same machine. 4.3. Detailed Tracing of Cases 3 and 34. Next, two of the test cases from Table 2 (one for unit unavailability and one for processing time deviation) are explained in a more detailed fashion to illustrate the difference between the LI and the EFU heuristics. For this purpose, test cases 3 and 34 from Table 2 are selected.

86 Ind. Eng. Chem. Res., Vol. 33, No. 1, 1994 processing step a of product b s batch c processing step a of product b‘s batch cd holding time unit unavailability

Figure 12. Legend for Figures 13, 14, 16, and 17. unit14

131

133

21 4

135 A

unit1

111

113

I12

I

131 1 I

114

117

unit12

unit3

I 1 I

L

unit17

I

21 1

21 3

I 1 3 4 I136

unitl 5

I

I

U

I

I137

I 1 3 8 11310~13121

unit9 unit2

5

6

Ib

IS

Figure 13. New schedule for case 3 (LI). unit9

unit18 331

unit6 unit5

323

unit4 unitl 9 unit7 unitl 6

I

unitl 1 unitl 0

Figure 14. New schedule for case 3 (EFU).

Test case 3 has an unavailability of unit9 at the end of step2 of productl’s batch2 for a duration of 7 time units. Figure 13 shows part of the new schedule after the LI heuristic is applied. Figure 14 shows part of the new schedule after the EFU heuristic is applied. For the full schedules, the reader is referred to Kanakamedala (1991). An arrow in Figures 13 and 14 shows a reassignment of a processing step from the unit at the tail of the arrow to

the unit at the head of the arrow. The three- or four-digit number in the boxes in these figures characterizes a processing step. Each step has a unique number. The first digit is the processing step number, and the second digit is the product number. The third (if fourth digit is not present) or the third and fourth digits (if fourth digit is present) show the batch number. For example, 235 in a box shows that it is step2 of product3’s batch5. 4211 shows that it is step4 of product2’s batchll. Figure 12 shows the legend for various items in Figures 13 and 14. As the beam width is equal to 3, six different possible routings for each batch are generated at each stage of the search after the initial expansion. To explain the idea of “staying close to the original schedule”, the differences between the new completion time and the original completion time of each batch for the routing with least cumulative weighted makespan value for LI and EFU heuristics are plotted against batch number for all three products in Figure 15. The way in which the completion times of batches change as the search proceeds from batch to batch can be noticed from Figure 15. The EFU heuristic does not follow the original schedule well as it does not have any provision for assessing the impact of a reassignment decision on the disturbed batch. The LI heuristic is able to track the original schedule in a better manner by a conservative approach accounting for the impact of a decision in a partial way. For this test case, the LI heuristic makes only 3 reassignments whereas EFU makes 84. The first three batches of productl, the first four batches of product2, and the first six batches of product3 arenot affected by the unit unavailability as these batches started before the unit unavailability time. Figure 13 shows the three reassignments made by LI. Due to the breakdown of units, step2 of productl’s batch4 is reassigned to unitl4. (In othe words, unit9 is replaced by unit14 for step2 of productl’s batch4). Due to this reassignment decision, stepl of product3’s batch7 and stepl of product3’s batch9 are disturbed. This is the only reassignment decision made by LI at this batch. Due to the impact of this decision, when the search reaches product3’s batch7, its first step is reassigned to unit15 disturbing stepl of product3’s batch8. Similarly, stepl of product3’s batch9 is reassigned to unit12 disturbing the stepl of product2’s batch5. LI does not make further reassignments. Instead it keeps the original assignments for the remaining batches. The EFU heuristic makes 84 reassignments in total for this test case. It makes two reassignments in productl’s batch4. Figure 14 shows these reassignments. Step2 is rerouted through unit10 disturbing step3 of product2’s batch4. Step3is rerouted through unit18 disturbing step2 of product3’s batchlo. As the search proceeds to further batches, more reassignments are executed. From Figure 15a, it may be noticed that the completion time of the first batch affected by the unit unavailability (productl’s batch4) is more for EFU than for LI. This may look like an anomaly as EFU is supposed to pick the routing such that the batch is finished earliest. This happens because a routing that is good in the initial stages may turn out to be worse in the long run. For comparison, an attempt was made to reschedule the plant at the point of the disturbance using the mathematical programming strategy outlined by Elkamel et al. (1993a,b). The resulting mixed integer linear program contained over 30 000 binary variables, 245 OOO continuous variables, and 100 000 constraints. Using a branch-and-bound based heuristic, a solution could not

Ind. Eng. Chem. Res., Vol. 33, No. 1, 1994 87 unit2 unitl 8 unit9 unit6

unit5 unitl 9 unit4 I

i

4

0

12

16

unitl 1

4

EFU 3-

1-

---

I 1 I I

'\

/ \

I I

4315

I

4317

I

11

4319

432b

I

4323

I

unit20

I \

I \V/

unit8

I

unit25 unit21

0-

-2

3 24

unitl 0

1-

-1

3321

unit16

Batch number

2-

3318

unit7

1

I

30

-

I

I

35

40

45

Figure 16. New schedule for case 34 (LI).

!

I

2

unit19

I

8

6

4

10

unit4

'Batch number

unit7 unit! 6

,

I

unitl 1 unit10 unit20 unit8 unit25 unit21 0

4

6

12

16

20

24

5

lb

I

15

Figure 17. New schedule for case 34 (EFU). Batch Number Figure 16. (a, top) Differences in completion times of product1 (case3)VB batchnumber. (b,middle)Differences in completion times of product2 (case 3) vs batch number. (c, bottom) Differences in completion times of product3 (case 3) vs batch number.

be found after 3156 s of computation time on an IBM RS6000 machine. Test case 34 is a processing time deviation at step6 of products's batch2 for a duration of 3 time units. Figure

16 shows part of the new schedule after the LI heuristic is applied. Figure 17 shows part of the new schedule after the EFU heuristic is applied. For the full schedules, the reader is referred to Kanakamedala (1991). Again, an arrow in Figures 15 and 16 shows a reassignment of a processing step from the unit at the tail of the arrow to the unit at the head of the arrow. The three- or four-digit numbers in the boxes uniquely signify the step similar to Figures 12 and 13. Figure 12 shows the legend for various items in Figures 16 and 17. The differences between the

88 Ind. Eng. Chem. Res., Vol. 33, No. 1, 1994 Table 4. Comparison with Simple Time Shifting dev tvDe unit down processing time

Batch Number

-1 2

6

10

Batch Number

EFU

4

8

12

16

20

24

Batch number Figure 18. (a, top) Differences in completion times of product1 (case 34) vs batch number. (b, middle) Differences in completion times of product2 (case34) vs batch number. (c,bottom)Differences in completion times of product3 (case 34) vs batch number.

new completion time and the original completion time of each batch for the best routings are shown in Figure 18 for LI and EFU heuristics. For this test case, the LI heuristic makes 3 replacements whereas the EFU heuristic makes 54 replacements. Figure 16shows the three reassignments made by LI. All of these

total no. of cases tested 52 52

no. of good caaes 48 43

three reassignments are made at product3's batch20. Step3 is reassigned to unit2 disturbing step3 of product2's batchll. Step4 is reassigned to unit4 disturbing the step3 of product2's batchll. Step5 is reassigned to unit19 disturbing step3 of productl's batchl5. All of the remaining assignment decisions in the original schedule are unchanged. The EFU heuristic makes 54 reassignments for this case. The first of these is made at step5 of products's batch7. This reassignment is shown in Figure 16. Step5 of product3's batch7 is rerouted through unit19 disturbing step3 of productl's batch7. As the search proceeds to further batches, more reassignments are made. The proposed algorithm can also handle unstable intermediates. To illustrate this, a single test problem is used. Aunit unavailability at the end of stepl of product3's batch2 is simulated. This particular task can be processed in all reactors of types 4 and 5. The intermediates that come out of stepl of productl, step2 of product2, and step3 of product3 are designated as unstable, warranting a ZW storage policy at these steps. This effectively reduces the number of choices available for reassignments during reactive schedule modification. The program is run with a unit breakdown of 6 time units. The objective function value obtained with the LI heuristic is 5.2 with four replacements. The objective function value obtained with EFU heuristic is 28.7 with 99 replacements. Though the objective function value may be expected to increase due to unstable intermediates compared to the case with all stable intermediates, it has to be noted that it may not be the case every time due to the nature of the beam search. 4.4. Effect of Beam Width Parameter. Next, astudy of the effectiveness of the beam search is conducted. For this purpose, randomly generated deviations are introduced in the original schedule and the LI heuristic beam search with beam widths of 1 (simple shifting), 2, and 3 is applied to each case. Fifty-two cases of unit unavailabilities of randomly generated durations between 4 and 10 time units and 52 cases of processing time deviations of randomly generated durations between 1 and 4 time units are used in this test. Table 4 shows the number of cases (designated as "good" cases in Table 4) in which the search scheme with beam widths of 2 and 3 has performed better than or as well as simple shifting, with improvement with a beam width of 3 over a beam width of 2. From Table 4, it is seen that the search has performed as well or better than simple time shifting in 87 % of the cases tested. In the rest of the cases, the failure to find a better solution can be attributed to the fact that the beam search can prune off some paths which are not promising at an earlier stage of the search, but may turn out to be good in the long run. Beam width is a key algorithm parameter in this study with its value having an effect on the computational requirements. Hence, eight test cases are simulated and the proposed LI heuristic search algorithm is run with beam widths of 1, 2, 3, and 4. Of these eight cases, two are with productl, two with product2 and four with product4. All the cases are run with product priorities I (1.2,1.4,1.6). Half of these cases are unit unavailabilities, and the other half are processing time deviations. It has to be noted that any other cases could have been chosen for this test. These eight cases are chosen as a represen-

Ind. Eng. Chem. Res., Vol. 33, No. 1, 1994 89 Table 11. Capacities for Product3

Table 5. Computational Requirements for Various Beam Widths

task

beam width testcaseparams

tmeofdev

1

2

3

4

2.5 2.2 2.6 2.4 2.6 3.0 2.5 2.2

5.6 5.0 9.1 5.8 16.6 9.2 8.8 4.7

17.2 16.7 47.5 15.8 79.0 53.4 37.0 32.6

45.4 45.0 123.2 44.6 197.0 143.6 92.8 83.7

1 2 3 4 5 6

R1

R2

X

X

X X X 600 450 600 700

unit type assigned

feasible types

1 2

reactorl reactor2 reactor4 filter2 filterl dryer2

all reactors1 and -2 all reactors all reactors all filters all filters all dryers

3 4

X

X

X

X

X

X

X

unit type assigned reactor5 reactor5 reactorl reactor2 reactor4 filter2 dryerl

product product1 product2 product3

R1 700 500

x

x

R2 650 600

R3

R4

R5

X

X

X

400

750

x

x

x

x

x

x

x

4

R1

1

x

2 3 4 5

1000 900 X

x

x

x

x

F1

4

X

X

0

X

X X

950

X X X

X

700

750

X X

X

X

x

R4

R5

F1

F2

D1

D2

x

x

x

x

x

x

3.5

5.5

X

X

X

X

x x

x x

3.54.5

x

x

x x

2.0

x

F2

D1

D2

X

X

X

800

x

x

x

1000 x

X

X

650

D1

D2

X X

1025

x

x X X X

X

X

R5

F1

F2

D1

D2

X

X

4.0

6.0

x

X X

X X

X X

X X

3 . 5 4 . 5 x

X

X

X

x

X

X

x 2.5

5. Summary and Conclusions

700

F2 x

X

R4

for the type of deviation column is as follows: u is unit unavailability and p is processing time deviation.

x

x

x

R1 R2 R3 1 3 . 0 3 . 0 X 2 5.5 5.5 5.0 3 x x x

x

x

x

task

X X

R2 R3 R4 R5 F1 x x x 9 5 O x 850 700 750 1100 X 850 750 900 900 X X X X X 975

D2

Table 14. Processing Times for Productl Path2 feasible types all reactors5 all reactors5 all reactors all reactors all reactors all filters all dryers

x

Table 10. Capacities for Product2

task

X

0

D1

batch sizes 600,650 850,900 500,450

R1 R2 R3 1 2 . 0 2 . 0 x 2 5.0 5.0 6.0 3 x x x

Table 9. Capacities for Productl 1 2 3 4

F2

Table 12. Batch Sizes

task

Table 8. Unit Assignments for Product3 task no. unit type assigned feasible types 1 reactor5 all reactors4 and -5 all reactors4 and -5 reactor5 all filters 2 filterl filterl all filters all reactors 3 reactor3 all reactors reactor2 all reactors reactor3 all reactors 4 reactor4 all reactors reactor3 5 filter2 all filters all dryers 6 dryerl all dryers dryer2 all dryers dryerl

task

R5 F1 650X 0 0 7 500 X 550 X X 1250 X X

Table 13. Processing Times for Productl Path1

Table 7. Unit Assignments for Product2

task no.

R4 X 550 X X 6 500 550 650 650

X

Table 6. Unit Assignments for Productl

task no.

R3

X X X X

11oox

tative sample of all the cases. Table 5 shows the CPU times taken for various beam widths in each case. As expected, there is a clear increase in the computation time as the beam width increases. It can also be seen that one of the aims of the reactive modification scheme, Le., to obtain a quick response, is achieved. For the test case parameters the same legend as in Tables 2 and 3 applies. All the test cases are run on a SPARCl workstation. All the time values in Table 5 are in seconds, and the legend

The reactive schedule modification of multipurpose plant schedules within a single campaign is studied. The assumption of noninteracting production lines is relaxed. Since full scale rescheduling heuristics are often highly disruptive with respect to prior task-unit assignments and can be computationally intractable, a heuristic search scheme is developed which is conservative in the sense that it bases its selection among alternatives on the principle of causing minimum impact on the rest of the schedule. The search makes use of the possible reroutings of various batches to create alternatives and prunes the choices to a prespecified number at each stage in order to contain the combinatorial complexity. The search proceeds in two different levels. At the lower level, it accounts for the local impact of decision around a processing step, while at the higher level it accounts for the impact of all the decisions made for a batch. The focus of this work has been on the development of an efficient heuristic for choosing among the alternatives that accounts for the impact of a rerouting choice on the rest of the schedule. Toward this end, a heuristic which is based on the static properties of the schedule at the lower level of the search and the dynamic impact of a decision in a one-batch look-ahead manner at the higher level of the search is developed. It has been shown that the proposed heuristic scheme performs better than a earliest finishing unit heuristic for choosing among the alternatives in all the tested cases. The search scheme has been able to strike a balance between achieving a good solution and doing so with a reasonable computational effort in most of the cases tested. However, since the method is purely heuristic, a theoretically based algorithm could produce better solutions. The LI heuristic has been developed rigorously around the plant structure in the examples and may not be as suitable to other configurations. It also tends to be

90 Ind. Eng. Chem. Res., Vol. 33, No. 1, 1994 Table 15. Processing Times for Product2 P a t h l R1

task l 2 3 4 5

X

R2 X

X

F1

D1

R3

R4

R5

. O X X X 3.0 X X X 3.0 X X X X 2 . 5 2 . 0 X X X X 3.0

2.0 3.0

2.0 3.5

X 2.5 3.5

5 2.5 3.5

X X

X X

X X

X X

F2

D2 X X X X X

Table 16. Processing Times for Product2 Path2

task 1 2 3 4 5

R1

R3

R4

R5

x x x x 2.5 2.5 3.5 4.0 4.0 4.0

5 3.5 4.0

. 3.5 4.5

R2

X

X

X

X

X

x

x

x

x

x

F1 5

D1

F2 x

X X

x X X

D2

x

x X X X

X X

4 . 0 3 . 5 X x x 3.5

x

Table 17. Processing Times for Product3 P a t h l task

R1

R2

R3

X X

X X

X X

3.0

3.5 3.0

4.0 3.0

4.0 3.0

4.0 3.0

X X

X X

X X

X X

R%4

R5

F1

F2 ~

1 2 3. 4 5 6

X

3 . 0 X X 2 . 5 4.5 X 3.5 X X 1 . 5 X

X

X

D1 ~

X

3 . 0 X X X

X X

D2 ~~~

X X X X X

1 . 0 X X 3.53.5

Table 18. Processing Times for Product3 Path2 task 1 2 3 4

5 6

R1

R2

x X

F1

R3

R4

x

x

X

X

3.5 3.0

4.0 3.0

4.0 3.0

X X

X X

X X

2 . 0 2 . 0 x X X 1 . 5 4.0 4.5 X 3.0 3.5 X X X 1 . 5 X

R5

X

X

F2

D1

x

x

2 . 0 X X X

X X

number of vessel types. Tables 9-11 show the capacity values for three producta. A "X" in a box indicates that particular unit cannot process the corresponding task. The processing time of a step is a function of the vessel type used and the batch size. Since changes in batch size are not considered in this methodology, it suffices to know the values of processing times based on the initial batch sizes for the base case. There are two different batch sizes for the first and second products as there are two different processing paths for each of them. Although there are six different processing paths for the third product, it is assumed that the batch sizes and the processing times repeat in a cycle of two batches for simplicity in generating the original schedule. The batch sizes for the three producta are given in Table 12. The processing times are given in Tables 13-18. A "X" in a box indicates that particular unit cannot process the corresponding task.

D2 x X X X X

1 . 0 X X 4.04.0

somewhat myopic since it is a one-batch look-ahead algorithm. At present though, it is among the best heuristics for most disturbance cases involving the plant structure presented, as rigorous mathematical techniques for scheduling and reactive scheduling are yet being developed. This work is a first step in filling a gap that exists in the research on multipurpose batch plant operating policies. The proposed scheme is general enough to be applied to both multiproduct and multipurpose plants and complements the more rigorous optimization schemes used for a priori schedule development.

Appendix A. Plant and Initial Schedule Data Tables 6-8 show the initial feasible assignments and all the feasible assignments for the three products. The size of a batch that each unit can process (referred to as the "capacity" of the unit hereafter) in a step is a function of the vessel type and the step itself. For each product, the capacity data is expressed as a two-dimensional array of number of steps in the recipe and the total

Literature Cited Cott, B. J.; Macchietto, S. An integrated approach to computeraided operation of batch chemical plants. Proceedings Third International Symposium on Process Systems Engineering, Sydney, Australia; Institution of Engineers, Australia: 1988; Publication No. 88/17, pp 243-249. Cott, B. J.; Macchietto, S. Minimizing the effects of batch process variability using online schedule modification. Comput. Chem. Eng. 1989, 13 (1/2), 105-113. Elkamel, A. Scheduling of process operations using mathematical programming techniques: Towards a prototype decision support system. Ph.D. Dissertation, Purdue University, 1993. Elkamel, A.; Zentner, M. G.; Pekny, J. F.; Reklaitis, G. V. A decomposition heuristic for scheduling the general batch plant. Presented at ORSA/TIMS National Meeting, Chicago, IL, 1993. Kanakamedala, K. B. Reactiveschedulemodificationin multipurpose batch chemical plants. M.S. Thesis, Purdue University, 1991. Karimi, I. A.; Reklaitis, G. V. Deterministic variability analysis for intermediate storage in noncontinuous processes, Part I Allowability conditions. AIChE J. 1985a, 31 (9), 1516-1527. Karimi, I. A.; Reklaitis, G. V. Deterministic variability analysis for intermediate storage in noncontinuous processes,Part I1 Storage sizing for serial systems. AIChE J . 1985b,31 (9), 1528-1537. Musier, R. F. H.; Evans, L. B. Batch Process Management. Chem. Eng. Prog. 1990, 86 (6), 66-77. Onogi, K.; Nishimura,Y.; Nakata, Y.; Inomata, T. An on-lineoperating control system for a class of combined batch/semicontinuous processes. J. Chem. Eng. Jpn. 1986,19 (6), 542-548. Smith, N. F.; Rudd, D. F. On the effects of batch time variations on process performance. Chem. Eng. Sci. 1964,19, 403-411. Wiede, W., Jr. An interactive scheduling system for the operation of multiproduct plants. Ph.D. Dissertation, Purdue University,1984. Zentner, M. G.; Reklaitis, G. V. An interval based approach for resource constrained batch process scheduling. Process Technology Proceedings, 1 0 Proceedings of COPE-91; Puigjainer, L., Espufia, A., Eds.; Elsevier: Amsterdam, 1991; pp 151-157. Received for review July 12, 1993 Accepted September 22, 1993' ~~

e

Abstract published in Advance ACS Abstracts, December

1, 1993.