The CLP Procedure |
Activity Data Set |
You can use an Activity data set in lieu of, or in combination with, an ACTIVITY statement to define activities and constraints that relate to the activities. The Activity data set is similar to the Activity data set of the CPM procedure in SAS/OR software and is specified by using the ACTDATA= option in the PROC CLP statement.
The Activity data set enables you to define an activity, its domain, temporal constraints, and resource constraints. The temporal constraints can be either time-alignment-type or precedence-type constraints. The Activity data set requires at least two variables: one to determine the activity, and another to determine its duration. The procedure terminates if it cannot find the required variables. The activity is determined with the _ACTIVITY_ variable, which must be character, and the duration is determined with the _DURATION_ variable, which must be numeric. You can define temporal constraints and resource constraints by including additional variables.
The _ALIGNDATE_ and _ALIGNTYPE_ variables enable you to define time-alignment-type constraints. The _ALIGNTYPE_ variable defines the type of the alignment constraint for the activity that is named in the _ACTIVITY_ variable with respect to the _ALIGNDATE_ variable. If the _ALIGNDATE_ variable is not present in the Activity data set, the _ALIGNTYPE_ variable is ignored. Similarly, _ALIGNDATE_ is ignored when _ALIGNTYPE_ is not present. The _ALIGNDATE_ variable can take nonnegative integer values. The _ALIGNTYPE_ variable can take the values shown in Table 3.3.
Value |
Type of Alignment |
---|---|
SEQ |
Start equal to |
SGE |
Start greater than or equal to |
SLE |
Start less than or equal to |
FEQ |
Finish equal to |
FGE |
Finish greater than or equal to |
FLE |
Finish less than or equal to |
The _SUCCESSOR_ variable enables you to define precedence-type relationships between activities by using AON (activity-on-node) format. The _SUCCESSOR_ variable is a character variable. The _LAG_ variable defines the lag type of the relationship. By default, all precedence relationships are considered to be finish-to-start (FS). An FS type of precedence relationship is also referred to as a standard precedence constraint. All other types of precedence relationships are considered to be nonstandard precedence constraints. The _LAGDUR_ variable specifies the lag duration. By default, the lag duration is zero.
For each (activity, successor) pair, you can define a lag type and a lag duration. Consider a pair of activities (A, B) with a lag duration given by lagdur. The interpretation of each of the different lag types is given in Table 3.4.
Lag Type |
Interpretation |
---|---|
FS |
Finish A + lagdur Start B |
SS |
Start A + lagdur Start B |
FF |
Finish A + lagdur Finish B |
SF |
Start A + lagdur Finish B |
FSE |
Finish A + lagdur = Start B |
SSE |
Start A + lagdur = Start B |
FFE |
Finish A + lagdur = Finish B |
SFE |
Start A + lagdur = Finish B |
The first four lag types (FS, SS, FF, and SF) are also referred to as finish-to-start, start-to-start, finish-to-finish, and start-to-finish, respectively. The next four types (FSE, SSE, FFE, and SFE) are stricter versions of FS, SS, FF, and SF, respectively. The first four types impose a lower bound on the start and finish times of B, while the last four types force the start and finish times to be set equal to the lower bound of the domain. The last four types enable you to force an activity to begin when its predecessor is finished. It is relatively easy to generate infeasible scenarios with the stricter versions, so you should use the stricter versions only if the weaker versions are not adequate for your problem.
The _RESOURCE_ and _QTY_ variables enable you to define resource constraints for activities. The _RESOURCE_ variable is a character variable that identifies the resource or resource pool. The _QTY_ variable is a numeric variable that identifies the number of units required. If the requirement is for a resource pool, you need to use the Resource data set to identify the pool members. See the section Resource Data Set for more information.
For example, the following observations specify that activity A1 needs one unit of resource R1 and two units of resource R2:
_ACTIVITY_ _RESOURCE_ _QTY_ A1 R1 1 A1 R2 2
Table 3.5 lists all the variables that are associated with the ACTDATA= data set and their interpretations by the CLP procedure. For each variable, the table also lists its type (C for character, N for numeric), its possible values, and its default value.
Name |
Type |
Description |
Allowed Values |
Default |
---|---|---|---|---|
_ACTIVITY_ |
C |
Activity name |
||
_DURATION_ |
N |
Duration |
Nonnegative integers |
0 |
_SUCCESSOR_ |
C |
Successor name |
||
_LAG_ |
C |
Lag type |
FS, SS, FF, SF, FSE, SSE, FFE, SFE |
FS |
_LAGDUR_ |
N |
Lag duration |
0 |
|
_ALIGNDATE_ |
N |
Alignment date |
||
_ALIGNTYPE_ |
C |
Alignment type |
SGE, SLE, SEQ, FGE, FLE, FEQ |
|
_RESOURCE_ |
C |
Resource name |
||
_QTY_ |
N |
Resource quantity |
Nonnegative integers |
1 |
Copyright © SAS Institute, Inc. All Rights Reserved.