Lec3.ppt

advertisement
Lecture 3:
The Critical Path Method
(CPM)
© J. Christopher Beck 2008
1
Outline

ROMAN


Project representation


Project scheduling system
Job-on-node
CPM – forward & backward
© J. Christopher Beck 2008
2
Readings


P Ch 4.0-4.2, 4.7
Some slides
taken from
Twente
University (see
Pinedo CD)
© J. Christopher Beck 2008
3
ROMAN

How do you shut
down a nuclear
power plant for
maintenance?



(Very carefully)
10,000 to 40,000
jobs
$1,000,000 per day
© J. Christopher Beck 2008
4
ROMAN Problem

Given a set of jobs, precedence
constraints & resource requirements,
assign resources to jobs for specific
periods to:



Minimize down-time (the makespan)
Make sure all jobs can be done safely
Jobs: refuelling, repairs, plant
modifications, maintenance
© J. Christopher Beck 2008
5
ROMAN

Complex safety constraints effect state
of the plant (Fig 4-11)



yellow, orange, red
no simple “mathematical” objectives
Constraint-based scheduling


GUI is critical!
Builds on basic algorithms we will study

One of which is the CPM
© J. Christopher Beck 2008
6
Project Planning: Example 1
Job Duration Predecessors
1
2
2
3
1
3
1
1
4
4
2
5
2
3
6
1
4,5
7
3
4,5

1
2
4
6
3
5
7
Rules for “job on node” networks:

network contains no directed cycles

event numbering
© J. Christopher Beck 2008
network contains no redundant arcs 7
Example 2
Job p(j) Predecessors
1 2
2 3
3 1
4 4
1,2
5 2
2,3
6 1
4
© J. Christopher Beck 2008
“job on node”-representation?
8
Example 3
Job p(j) Predecessors
1 2
2 3
3 1
4 4
1,2
5 2
2
6 1
4
Makespan?
Critical Path?
“job on node”-representation:
1
2
3
© J. Christopher Beck 2008
4
6
5
9
Critical Path Method


Find Critical Path and makespan
Two steps:


forward procedure – find min. makespan
backward procedure – find CP
© J. Christopher Beck 2008
10
Forward Procedure
STEP1: For each job that has no predecessors:
'
'
S

max
C
k
STEP2: compute for each job j: j
S 'j  0
C 'j  p j
kj
C
STEP3: C max  max
j
C 'j  S 'j  p j
'
j
C’1 = 2
S’1 = 0
S’6 = 7
1
C’2 = 3
S’2 = 0
S’4 = 3
2
C’4 = 7
4
6
C’3 = 1
© J. Christopher Beck 2008
S’3 = 0 3
S’5 = 3
5
C’6 = 8
C’5 = 5
Cmax = 8
11
Backward Procedure
C ''j  C max
STEP1: For each job that has no successors: S ''j  C max  p j
''
''
STEP2: compute for each job j: C j  min S k
jall k
STEP3: Verify that: 0  min S
j
''
j
S ''j  C ''j  p j
C’’1 = 3
S’’1 = 1
S’’6 = 7
1
C’’2 = 3
S’’2 = 0
S’’4 = 3 C’’4 = 7
2
4
6
C’’3 = 8
© J. Christopher Beck 2008
S’’3 = 7 3
S’’5 = 6
5
C’’6 = 8
C’’5 = 8
Cmax = 8
12
Critical Path

If S’j = S’’j then activity is in the critical
path
Job
S’j
S’’j
1
0
1
2
0
0
3
0
7
4
3
3
5
3
6
6
7
7
© J. Christopher Beck 2008
C’’1 = 3
S’’1 = 1
S’’6 = 7
1
C’’2 = 3
S’’2 = 0
S’’4 = 3 C’’4 = 7
2
4
6
C’’3 = 8
S’’3 = 7 3
S’’5 = 6
5
C’’6 = 8
C’’5 = 8
Cmax = 8
13
Example 4.2.3
Jobs 1 2 3 4
pj
5
6
7
8
9 10 11 12 13 14
5 6 9 12 7 12 10 6 10 9
2
4
7
1
9
3
© J. Christopher Beck 2008
8
7
5
12
14
11
5
8
1) Find makespan
2) Find CP
10
6
7
13
14
Download