Chapter Contents
Chapter Contents
Previous
Previous
Next
Next
The CPM Procedure

RESOURCE Statement

RESOURCE variables / resource options ;
RES variables / resource options ;

The RESOURCE statement identifies the variables in the Activity data set that contain the levels of the various resources required by the different activities. This statement is necessary if the procedure is required to summarize resource utilization for various resources.

This statement is also required when the activities in the network use limited resources and a schedule is to be determined subject to resource constraints in addition to precedence constraints. The levels of the various resources available are obtained from the RESOURCEIN= data set (the Resource data set.) This data set need not contain all of the variables listed in the RESOURCE statement. If any resource variable specified in the RESOURCE statement is not also found in the Resource data set, it is assumed to be available in unlimited quantity and is not used in determining the constrained schedule. The following options are available with the RESOURCE statement to help control scheduling the activities subject to resource constraints. Some control the scheduling heuristics, some control the amount of information to be output to the RESOURCEOUT= data set (the Usage data set), and so on.

ACTDELAY=variable
specifies the name of a variable in the Activity data set that specifies a value for the maximum amount of delay allowed for each activity. The values of this variable should be greater than or equal to 0. If a value is missing, the value of the DELAY= option is used instead.

ACTIVITYPRTY=variable
ACTPRTY=variable
identifies the variable in the Activity data set that contains the priority of each activity. This option is required if resource-constrained scheduling is to be performed and the scheduling rule specified is ACTPRTY. If the value of the SCHEDRULE= option is specified as the keyword ACTPRTY, then all activities waiting for resources are ordered by increasing values of the ACTPRTY= variable. Missing values of the activity priority variable are treated as +INFINITY. See the "Scheduling Method" section for a description of the various scheduling rules used during resource constrained scheduling.

ALL
is equivalent to specifying the ESPROFILE and LSPROFILE options when an unconstrained schedule is obtained and is equivalent to specifying all four options, AVPROFILE (AVP), ESPROFILE (ESP), LSPROFILE (LSP), and RCPROFILE (RCP), when a resource-constrained schedule is obtained. If none of these four options are specified and a Usage data set is specified, by default the ALL option is assumed to be in effect.

ALTBEFORESUP
indicates that all alternate resources are to be checked first before using supplementary resources. By default, if supplementary levels of resources are available, the procedure uses supplementary levels first and uses alternate resources only if the supplementary levels are not sufficient.

APPEND
APPENDINTXRATE
APPENDRATEXINT
APPENDUSAGE
indicates that the Usage data set is to contain two sets of observations: the first set indicates the rate of usage for each resource at the beginning of the current time period, and the second set contains the total usage of each resource for the current time period. In other words, the Usage data set appends observations indicating the total usage of each resource to the default set of observations. If the APPEND option is specified, the procedure adds a variable named OBS_TYPE to the Usage data set. This variable contains the value RES_RATE for the observations that indicate rate of usage and the value RES_USED for the observations that indicate the total usage.

AROUTCAL=calname
specifies the name of the calendar to be used for incrementing the _TIME_ variable in the Usage data set.

AVPROFILE
AVP
AVL
creates one variable in the Usage data set corresponding to each variable in the RESOURCE statement. These new variables denote the amount of resources remaining after resource allocation. This option is ignored if resource allocation is not performed.

AWAITDELAY
forces PROC CPM to wait until L_START+delay, where delay is the maximum delay allowed for the activity (which is the value of the ACTDELAY= variable or the DELAY= option), before an activity is scheduled using supplementary levels of resources. By default, even if an activity has a nonzero value specified for the ACTDELAY= variable (or the DELAY= option), it may be scheduled using supplementary resources before L_START+delay. This happens if the procedure does not see any increase in the resource availability in the future. Thus, if it appears that the activity will require supplementary resources anyway, the procedure may schedule it before L_START+delay. The AWAITDELAY option prohibits this behavior; it will not use supplementary resources to schedule an activity before L_START+delay. This option can be used to force activities with insufficient resources to start at L_START by setting DELAY=0.

CUMUSAGE
specifies that the Usage data set should indicate the cumulative usage of consumable resources. Note that by default, for consumable resources, each observation in the Usage data set contains the rate of usage for each resource at the start of the given time interval. See the "RESOURCEOUT= Usage Data Set" section for a definition of the variables in the resource usage output data set. In some applications, it may be useful to obtain the cumulative usage of these resources. The CUMUSAGE option can be used to obtain the cumulative usage of consumable resources up to the time specified in the _TIME_ variable.

DELAY=delay
specifies the maximum amount by which an activity can be delayed due to lack of resources. If E_START of an activity is 1JUN92 and L_START is 5JUN92 and delay is specified as 2, PROC CPM first tries to schedule the activity to start on 1JUN92. If there are not enough resources to schedule the activity, the CPM procedure postpones the activity's start time. However, it does not postpone the activity beyond 7JUN92 (because delay=2 and L_START=5JUN92).

If the activity cannot be scheduled even on 7JUN92, then PROC CPM tries to schedule it by using supplementary levels of resources, if available, or by using alternate resources, if possible. If resources are still not sufficient, the procedure stops with an error message. The default value of the DELAY= option is assumed to be +INFINITY.

DELAYANALYSIS
SLIPINF
causes the addition of three new variables to the Schedule data set. The variables are R_DELAY, DELAY_R and SUPPL_R. The R_DELAY variable indicates the number of units (in interval units) by which the activity's schedule has slipped due to resource unavailability, and the DELAY_R variable contains the name of the resource, the delaying resource, that has caused the slippage.

The R_DELAY variable is calculated as follows: it is the difference between S_START and the time when an activity first enters the list of activities that are available to be scheduled. (See the "Scheduling Method" section for a definition of this waiting list of activities.) Note that R_DELAY is not necessarily the same as S_START - E_START.

If several resources are insufficient, causing a delay in the activity, DELAY_R is the name of the resource that first causes an activity to be postponed.

The variable SUPPL_R contains the name of the first resource that is used above the primary level in order for an activity to be scheduled at S_START.

ESPROFILE
ESP
ESS
creates one variable in the Usage data set corresponding to each variable in the RESOURCE statement. Each new variable denotes the resource usage based on the early start schedule for the corresponding resource variable.

E_START
requests that the E_START and E_FINISH variables, namely the variables specifying the early start schedule, be included in the Schedule data set in addition to the S_START and S_FINISH variables. This option is the default and can be turned off using the NOE_START option.

EXCLUNSCHED
excludes the resource consumption corresponding to unscheduled activities from the daily resource usage reported for each time period in the Usage data set. Note that the Usage data set contains a variable named Rresname for each resource variable resname. For each observation in this data set, each such variable contains the total amount of resource (rate of usage for a consumable resource) used by all the activities that are active at the time period corresponding to that observation. By default, this calculation includes even activities that are still unscheduled when resource constrained scheduling is stopped either by the STOPDATE= option or due to resource infeasibilities. The EXCLUNSCHED option allows the exclusion of activities that are still unscheduled. Note that the unscheduled activites are assumed to start as per the early start schedule (unless the UPDTUNSCHED option is specified).

FILLUNSCHED
FILLMISSING
fills in S_START and S_FINISH values for activities that are still unscheduled when resource constrained scheduling is stopped either by the STOPDATE= option or due to resource infeasibilities. By default, the Schedule data set contains missing values for S_START and S_FINISH corresponding to unscheduled activities. If the FILLUNSCHED option is on, the procedure uses the original E_START and E_FINISH times for these activities. If the UPDTUNSCHED option is also specified, the procedure uses updated values.

F_FLOAT
requests that the Schedule data set include the F_FLOAT variable computed using the unconstrained early and late start schedules. Note that if resource allocation is not performed, this variable is always included in the output data set.

INCLUNSCHED
allows the inclusion of activities that are still unscheduled in the computation of daily (or cumulative) resource usage in the Usage data set when resource-constrained scheduling is stopped either by the STOPDATE= option or due to resource infeasibilities. This option is the default and can be turned off by the EXCLUNSCHED option.

INDEPENDENTALLOC
INDEPALLOC
allows each resource to be scheduled independently for each activity during resource-constrained scheduling. Consider the basic resource scheduling algorithm described in the "Scheduling Method" section. When all the precedence requirements of an activity are satisfied, the activity is inserted into the list of activities that are waiting for resources using the appropriate scheduling rule. An activity in this list is scheduled to start at a particular time only if all the resources required by it are available in sufficient quantity. Even if the resources are required by the activity for different lengths of time, or if the resources have different calendars, all resources must be available to start at that particular time (or at the beginning of the next work period for the resource's calendar).

If you specify the INDEPENDENTALLOC option, however, each resource is scheduled independently of the others. This may cause an activity's schedule to be extended if its resources cannot all start at the same time.

INFEASDIAGNOSTIC
INFEASDIAG
requests PROC CPM to continue scheduling even when resources are insufficient. When PROC CPM schedules the project subject to resource constraints, the scheduling process is stopped when the procedure cannot find sufficient resources for an activity before the activity's latest possible start time (accounting for the DELAY= or ACTDELAY= options and using supplementary or alternate resources if necessary and if allowed). The INFEASDIAGNOSTIC option can be used to override this default action. (Sometimes, you may want to know the level of resources needed to schedule a project to completion even if resources are insufficient.) This option is equivalent to specifying infinite supplementary levels for all the resources under consideration; the DELAY= value is assumed to equal the default value of +INFINITY, unless otherwise specified.

LSPROFILE
LSP
LSS
creates one variable in the Usage data set corresponding to each variable in the RESOURCE statement. Each new variable denotes the resource usage based on the late start schedule for the corresponding resource variable.

L_START
requests that the L_START and L_FINISH variables, namely the variables specifying the late start schedule, be included in the Schedule data set in addition to the S_START and S_FINISH variables. This option is the default and can be turned off using the NOL_START option.

MAXDATE=maxdate
specifies the maximum value of the _TIME_ variable in the Usage data set. The default value of maxdate is the maximum finish time for all of the schedules for which a usage profile was requested.

MAXNSEGMT=variable
MAXNSEG=variable
specifies a variable in the Activity data set that indicates the maximum number of segments that the current activity can be split into. A missing value for this variable is set to a default value that depends on the duration of the activity and the value of the MINSEGMTDUR variable. A value of 1 indicates that the activity cannot be split. By default, PROC CPM assumes that any activity, once started, cannot be stopped until it is completed (except for breaks due to holidays or weekends). Thus, even during resource-constrained scheduling, an activity is scheduled only if enough resources can be found for it throughout its entire duration. Sometimes, you may want to allow preemption of activities already in progress; thus, a more critical activity could cause another activity to be split into two or more segments. However, you may not want a particular activity to be split into too many segments, or to be split too many times. The MAXNSEGMT= and MINSEGMTDUR= options enable you to control the number of splits and the length of each segment.

MAXOBS=max
specifies an upper limit on the number of observations that the Usage data set can contain. If the values specified for the ROUTINTERVAL= and ROUTINTPER= options are such that the data set will contain more than max observations, then PROC CPM does not create the output data set and stops with an error message.

The MAXOBS= option is useful as a check to ensure that a very large data set (with several thousands of observations) is not created due to a wrong specification of the ROUTINTERVAL= option. For example, if interval is DTYEAR and routinterval is DTHOUR and the project extends over 2 years, the number of observations would exceed 15,000. The default value of the MAXOBS= option is 1000.

MINDATE=mindate
specifies the minimum value of the _TIME_ variable in the Usage data set. The default value of mindate is the minimum start time for all of the schedules for which a usage profile is requested. Thus, the Usage data set has observations containing the resource usage and availability information from mindate through maxdate .

MINSEGMTDUR=variable
MINSEGD=variable
specifies a variable in the Activity data set that indicates the minimum duration of any segment of the current activity. A missing value for this variable is set to a value equal to one fifth of the activity's duration.

NOE_START
requests that the E_START and E_FINISH variables, namely the variables specifying the early start schedule, be dropped from the Schedule data set. Note that the default is E_START. Also, if resource allocation is not performed, the NOE_START option is ignored.

NOF_FLOAT
requests that the F_FLOAT variable be dropped from the Schedule data set when resource-constrained scheduling is requested. This is the default behaviour. To include the F_FLOAT variable in addition to the resource-constrained schedule, use the F_FLOAT option. Note that if resource allocation is not performed, F_FLOAT is always included in the Schedule data set.

NOL_START
requests that the Schedule data set does not include the late start schedule, namely, the L_START and L_FINISH variables. Note that the default is L_START. Also, if resource allocation is not performed, the NOL_START option is ignored.

NORESOURCEVARS
NORESVARSOUT
NORESVARS
requests that the variables specified in the RESOURCE statement be dropped from the Schedule data set. By default, all of the resource variables specified on the RESOURCE statement are also included in the Schedule data set.

NOT_FLOAT
requests that the T_FLOAT variable be dropped from the Schedule data set when resource-constrained scheduling is requested. This is the default behavior. To include the T_FLOAT variable in addition to the resource-constrained schedule, use the T_FLOAT option. Note that if resource allocation is not performed, T_FLOAT is always included in the Schedule data set.

NROUTCAL=calnum
specifies the number of the calendar to be used for incrementing the _TIME_ variable in the Usage data set.

OBSTYPE=variable
specifies a character variable in the Resource data set that contains the type identifier for each observation. Valid values for this variable are RESLEVEL, RESTYPE, RESPRTY, SUPLEVEL, ALTRATE, ALTPRTY, RESRCDUR, and CALENDAR. If OBSTYPE= is not specified, then all observations in the data set are assumed to denote the levels of the resources, and all resources are assumed to be replenishable and constraining.

PERIOD=variable
PER=variable
identifies the variable in the RESOURCEIN= data set that specifies the date from which a specified level of the resource is available for each observation with the OBSTYPE variable equal to RESLEVEL. It is an error if the PERIOD= variable has a missing value for any observation specifying the levels of the resources or if the Resource data set is not sorted in increasing order of the PERIOD= variable.

RCPROFILE
RCP
RCPS
creates one variable in the Usage data set corresponding to each variable in the RESOURCE statement. Each new variable denotes the resource usage based on the resource-constrained schedule for the corresponding resource variable. This option is ignored if resource allocation is not performed.

RESCALINTERSECT
RESCALINT
RCI
specifies that an activity can be scheduled only during periods that are common working times for all resource calendars (corresponding to the resources used by that activity) and the activity's calendar. This option is valid only if multiple calendars are in use and if calendars are associated with individual resources. Use this option with caution; if an activity uses resources that have mutually disjoint calendars, that activity can never be scheduled. For example, if one resource works a night shift while another resource works a day shift, the two calendars do not have any common working time.

If you do not specify the RESCALINTERSECT option, and resources have independent calendars, then the procedure schedules each resource using its own calendar. Thus, an activity can have one resource working on a five-day calendar, while another resource is working on a seven-day calendar.

RESID=variable
specifies a variable in the RESOURCEIN= data set that indicates the name of the resource variable for which alternate resource information is being specified in that observation. Such observations are identified by the values ALTRATE and ALTPRTY for the OBSTYPE variable. These values indicate whether the observation specifies a rate of substitution or a priority for substitution; the value of the RESID variable in such an observation indicates the particular resource for which alternate resource information is specified in that observation. Note that the specification of the RESID= option triggers the use of alternate resources. See the "Specifying Alternate Resources" section for further information.

RESOURCEVARS
RESVARSOUT
requests that the variables specified in the RESOURCE statement be included in the Schedule data set. These include the RESOURCE variables identifying the resource requirements, the activity priority variable, the activity delay variable, and any variables specifying activity splitting information. This option is the default and can be turned off by the NORESVARSOUT option.

ROUTINTERVAL=routinterval
STEPINT=routinterval
specifies the units to be used to determine the time interval between two successive values of the _TIME_ variable in the Usage data set. It can be used in conjunction with the ROUTINTPER= option to control the amount of information to be included in the data set. Valid values for routinterval are DAY, WORKDAY, WEEK, MONTH, WEEKDAY, QTR, YEAR, DTDAY, DTWRKDAY, DTWEEK, DTMONTH, DTQTR, DTYEAR, DTSECOND, DTMINUTE, DTHOUR, SECOND, MINUTE, or HOUR. The value of this parameter must be chosen carefully; a massive amount of data could be generated by a bad choice. If this parameter is not specified, a default value is chosen depending on the format of the schedule variables.

ROUTINTPER=routintper
STEPSIZE=routintper
STEP=routintper
specifies the number of routinterval units between successive observations in the Usage data set where routinterval is the value of the ROUTINTERVAL= option. For example, if routinterval is MONTH and routintper is 2, the time interval between each pair of observations in the Usage data set is two months. The default value of routintper is 1. If routinterval is blank (' '), then routintper can be used to specify the exact numeric interval between two successive values of the _TIME_ variable in the Usage data set. Note that routintper is only allowed to have integer values when routinterval is specified as one of the following: WEEK, MONTH, QTR, YEAR, DTWEEK, DTMONTH, DTQTR, or DTYEAR.

ROUTNOBREAK
ROUTCONT
specifies that the _TIME_ variable is to be incremented using a calendar with no breaks or holidays. Thus, the Usage data set contains one observation per unit routinterval from mindate to maxdate, without any breaks for holidays or weekends. Note that, by default, the _TIME_ variable is incremented using the default calendar; thus, if the default calendar follows a five-day work week, the Usage data set skips weekends.

RSCHEDID=(variables)
RSID=(variables)
identifies variables not specified in the TAILNODE, HEADNODE, or ACTIVITY statements that are to be included in the Resource Schedule data set. This option is useful for carrying any relevant information about each activity from the Activity data set to the Resource Schedule data set.

SCHEDRULE=schedrule
RULE=schedrule
specifies the rule to be used to order the list of activities whose predecessor activities have been completed while scheduling activities subject to resource constraints. Valid values for schedrule are LST, LFT, SHORTDUR, ACTPRTY, RESPRTY, and DELAYLST. (See the "Scheduling Rules" section for more information.) The default value of SCHEDRULE is LST. If an invalid specification is given for the SCHEDRULE= option, the default value is used, and a warning message is displayed in the log.

SCHEDRULE2=schedrule2
RULE2=schedrule2
specifies the rule to be used to break ties caused by the SCHEDRULE= option. Valid values for schedrule2 are LST, LFT, SHORTDUR, ACTPRTY, RESPRTY, and DELAYLST. Note that ACTPRTY and RESPRTY cannot be specified at the same time for the two scheduling rules; in other words, if schedrule is ACTPRTY, schedrule2 cannot be RESPRTY and vice versa.

SPLITFLAG
indicates that activities are allowed to be split into segments during resource allocation. This option can be used instead of specifying either the MAXNSEGMT= or the MINSEGMTDUR= variable; PROC CPM assumes that the activity can be split into no more than five segments.

STOPDATE=stdate
specifies the cutoff date for resource-constrained scheduling. When such a date is specified, S_START and S_FINISH are set to missing beyond the cutoff date. Options are available to set these missing values to the original E_START and E_FINISH times (FILLUNSCHED) or to updated values based on the scheduled activities (UPDTUNSCHED).

T_FLOAT
requests that the Schedule data set include the T_FLOAT variable computed using the unconstrained early and late start schedules. Note that if resource allocation is not performed, this variable is always included in the Schedule data set.

TOTUSAGE
INTXRATE
INTUSAGE
RATEXINT
specifies that the Usage data set is to indicate the total usage of the resource for the current time period. The current time period is the time interval from the time specified in the _TIME_ variable for the current observation to the time specified in the _TIME_ variable for the next observation. The total usage is computed taking into account the relevant activity and resource calendars. Note that, by default, the observations in the Usage data set specify the rate of usage for each resource at the beginning of the current time period. The TOTUSAGE option specifies the product of the rate and the time interval between two succesive observations. To get both the rate and the product, use the APPEND option.

UNSCHEDMISS
sets the S_START and S_FINISH values to missing for activities that are still unscheduled when resource constrained scheduling is stopped either by the STOPDATE= option or due to resource infeasibilities. This is the default and can be turned off by specifying the FILLUNSCHED option.

UPDTUNSCHED
causes the procedure to use the S_START and S_FINISH times of scheduled activities to update the projected start and finish times for the activities that are still unscheduled when resource constrained scheduling is stopped either by the STOPDATE= option or due to resource infeasibilities. These updated dates are used as the S_START and S_FINISH times.

WORK=variable
identifies a variable in the Activity data set that specifies the total amount of work required by one unit of a resource. This work is represented in units of the INTERVAL parameter. The procedure uses the rate specified for the resource variable to compute the duration of the activity for that resource. Thus, if the value of the WORK variable is 10, and the value of the resource variable R1 is 2, then the activity requires 5 interval units for the resource R1. For details, see the "Resource-Driven Durations and Resource Calendars" section.

Chapter Contents
Chapter Contents
Previous
Previous
Next
Next
Top
Top

Copyright © 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.