You are on page 1of 13

The Wagner-Whitin Model

Change is not made without inconvenience,


even from worse to better.
Robert Hooker

Wallace J. Hopp, Mark L. Spearman, 1996, 2000

http://www.factory-physics.com

Dynamic Lot Sizing Notation


t

a period (e.g., day, week, month); we will consider t = 1, ,T,


where T represents the planning horizon

Dt demand in period t (in units)


ct unit production cost (in dollars per unit), not counting setup or
inventory costs in period t
At fixed setup cost (in dollars) to place an order in period t
ht holding cost (in dollars) to carry a unit of inventory from period t to
period t +1
Qt the unknown size of the http://www.factory-physics.com
order or lot size in period t
Wallace J. Hopp, Mark L. Spearman, 1996, 2000

decision
variables2

Wagner-Whitin Example
Data

t
Dt
ct
At
ht

1
2
3
4
5
6
7
8
9
10
20 50 10 50 50 10 20 40 20 30
10 10 10 10 10 10 10 10 10 10
100 100 100 100 100 100 100 100 100 100
1
1
1
1
1
1
1
1
1
1

Lot-for-Lot Solution
t
Dt
Qt
It
Setup cost
Holding cost
Total cost

1
20
20
0
100
0
100

2
50
50
0
100
0
100

Wallace J. Hopp, Mark L. Spearman, 1996, 2000

3
10
10
0
100
0
100

4
50
50
0
100
0
100

5
50
50
0
100
0
100

6
10
10
0
100
0
100

7
20
20
0
100
0
100

http://www.factory-physics.com

8
40
40
0
100
0
100

9
20
20
0
100
0
100

10
30
30
0
100
0
100

Total
300
300
0
1000
0
1000
3

Wagner-Whitin Example (cont.)

Fixed Order Quantity Solution


t
Dt
Qt
It
Setup cost
Holding cost
Total cost

1
20
100
80
100
80
180

2
50
0
30
0
30
30

Wallace J. Hopp, Mark L. Spearman, 1996, 2000

3
4
5
10 50 50
0 100 0
20 70 20
0 100 0
20 70 20
20 170 20

6
7
8
10 20 40
0 100 0
10 90 50
0 100 0
10 90 50
10 190 50

http://www.factory-physics.com

9
20
0
30
0
30
30

10 Total
30 300
0 300
0
0
0 300
0 400
0 700

Wagner-Whitin Property

Under an optimal lot-sizing policy


either the inventory carried to period t
from a previous period will be zero
or the production quantity in period t
will be zero.

Wallace J. Hopp, Mark L. Spearman, 1996, 2000

http://www.factory-physics.com

Basic Idea of Wagner-Whitin Algorithm


By WW Property I, either Qt=0 or Qt=Dt++Dk for some k t.
If jk* = last period of production in a k-period problem
then we will produce exactly Djk*++Dk in period jk*.
We can then consider periods 1, , jk*1
as if they form an independent problem with jk*1 periods.

Wallace J. Hopp, Mark L. Spearman, 1996, 2000

http://www.factory-physics.com

Wagner-Whitin Example
Step 1: Obviously, just satisfy D1 (note we are neglecting
production cost, since it is fixed).
Z1* A1 100

j1* 1
Step 2: Two choices, either j2* = 1 or j2* = 2.
A1 h1 D2 , produce in 1
Z min *
Z1 A2 , produce in 2
100 1(50) 150
min
100 100 200
*
2

150
j2* 1
Wallace J. Hopp, Mark L. Spearman, 1996, 2000

http://www.factory-physics.com

Wagner-Whitin Example (cont.)

Step 3: Three choices, j3* = 1, 2, 3.

A1 h1 D2 (h1 h2 ) D3 , produce in 1
*
*
Z 3 min Z1 A2 h2 D3 ,
produce in 2
Z*2 A3 ,
produce in 3
100 1(50) (1 1)10 170

min 100 100 (1)10


210
150 100
250
170
j3* 1
Wallace J. Hopp, Mark L. Spearman, 1996, 2000

http://www.factory-physics.com

Wagner-Whitin Example (cont.)


Step 4: Four choices, j4* = 1, 2, 3, 4.

A1 h1 D2 (h1 h2 ) D3 (h1 h2 h3 ) D4 , produce in 1


Z* A h D (h h ) D ,
produce in 2
1
2
2 3
2
3
4
*
Z 4 min *
produce in 3
Z 2 A3 h3 D4 ,
Z*3 A4 ,
produce in 4
100 1(50) (1 1)10 (1 1 1)50 320
100 100 (1)10 (1 1)50
310

min
300
150 100 (1)50
170 100
270
270
j4* 4
Wallace J. Hopp, Mark L. Spearman, 1996, 2000

http://www.factory-physics.com

Planning Horizon Property


If jt*= k, then the last period in which production occurs in an
optimal t+1 period policy must be in the set k, k+1,t+1.
In the Example:
We produce in period 4 for period 4 of a 4-period
problem.
Thus, we would never produce in period 3 for period 5
in a 5-period problem.

Wallace J. Hopp, Mark L. Spearman, 1996, 2000

http://www.factory-physics.com

10

Wagner-Whitin Example (cont.)


Step 5: Only two choices, j5* = 4, 5.
*

Z
*
3 A4 h4 D5 , produce in 4
Z 5 min *
produce in 5
Z 4 A5 ,
170 100 1(50) 320
min
370
270 100

320
j5* 4
Step 6: Three choices, j6* = 4, 5, 6.

And so on.
Wallace J. Hopp, Mark L. Spearman, 1996, 2000

http://www.factory-physics.com

11

Wagner-Whitin Example Solution


Last Period
with Production
1
2
3
4
5
6
7
8
9
10
Zt
jt

Planning Horizon (t)


1
2
3
4
5
6
7
8
100 150 170 320
200 210 310
250 300
270 320 340 400 560
370 380 420 540
420 440 520
440 480
500

100 150 170 270 320 340 400 480


1

Produce in period Produce in period


1 for 1, 2, 3
4 for 4, 5, 6, 7
(20 + 50 + 10
(50 + 50 + 10 + 20
http://www.factory-physics.com
= 80 units)
= 130 units)

Wallace J. Hopp, Mark L. Spearman, 1996, 2000

10

520
520
580
520

610
580
610
620
580

7 or 8

Produce in period
8 for 8, 9, 10
(40 + 20 + 30
= 90 units) 12

Wagner-Whitin Example Solution (cont.)


Optimal Policy:
Produce in period 8 for 8, 9, 10 (40 + 20 + 30 = 90 units)
Produce in period 4 for 4, 5, 6, 7 (50 + 50 + 10 + 20 = 130 units)
Produce in period 1 for 1, 2, 3 (20 + 50 + 10 = 80 units)
t
Dt
Qt
It
Setup cost
Holding cost
Total cost

1
20
80
60
100
60
160

2
50
0
10
0
10
10

3
4
5
10 50 50
0 130 0
0 80 30
0 100 0
0 80 30
0 180 30

6
10
0
20
0
20
20

7
8
9
20 40 20
0 90 0
0 50 30
0 100 0
0 50 30
0 150 30

10 Total
30 300
0 300
0
0
0 300
0 280
0 580

Note: we produce in 7 for an 8-period problem, but this


never comes into play in optimal solution.
Wallace J. Hopp, Mark L. Spearman, 1996, 2000

http://www.factory-physics.com

13

You might also like