Document

advertisement
Dynamic Programming and
Applications
Water Allocation - II
Water Resources Planning and Management: M4L3
D Nagesh Kumar, IISc
Objectives
To demonstrate the water allocation problem through
a numerical example using
Backward approach
Forward approach
2
Water Resources Planning and Management: M4L3
D Nagesh Kumar, IISc
Numerical Problem
 Consider a canal supplying water for three different crops
 Maximum capacity of the canal is 4 units of water.
Field 3
x3
x1
Field 1
x2
Field 2
 Optimization Problem: Determine the optimal allocations xi to each crop that
maximizes the total net benefits from all the three crops
3
Water Resources Planning and Management: M4L3
D Nagesh Kumar, IISc
Numerical Problem…
Net benefits from producing the crops can be expressed as a function of the
water allotted.
NB1 ( x1 ) = 5 x1 − 0.5 x1
2
NB2 ( x2 ) = 8 x2 − 1.5 x2
NB3 ( x3 ) = 7 x3 − x3
2
2
The net benefit values are
calculated for each crop
and are as shown
4
Water Resources Planning and Management: M4L3
D Nagesh Kumar, IISc
Numerical Problem…

Representation of the problem as a set of nodes and links
x2
x1
4
0
x3
4
0
1
0
2
3
4
1
2
3
3
1
4
2
2
2
2
1
1
1
3
4
1
0
Crop 1
5
0
Crop 2
Water Resources Planning and Management: M4L3
1
0
0
0
Crop 3
D Nagesh Kumar, IISc
Numerical Problem…
 The values inside the node show the value of state variable at each
stage
 Number of nodes for any stage corresponds to the number of discrete
states possible for each stage.
 The values over the links show the different values taken by decision
variables corresponding to the value taken by state variables
6
Water Resources Planning and Management: M4L3
D Nagesh Kumar, IISc
Numerical Problem: Solution by
Backward recursion
Sub-optimization function for the 3rd crop:
f 3 ( S3 ) = max NB3 ( x3 ) with the range of S 3
from 0 to 4.
x3
0≤ x3 ≤ S 3
7
Water Resources Planning and Management: M4L3
D Nagesh Kumar, IISc
Solution by Backward recursion…
Next, by considering last two stages together, the sub-optimization function is
f 2 ( S 2 ) = max[NB2 ( x2 ) + f1 ( S 2 − x2 )]
x2
x2 ≤ S 2
The calculations are shown below
Table 3
8
Water Resources Planning and Management: M4L3
D Nagesh Kumar, IISc
Solution by Backward recursion…
9
Water Resources Planning and Management: M4L3
D Nagesh Kumar, IISc
Solution by Backward recursion…
Considering all the three stages together
f1 (Q) = max [NB1 ( x1 ) + f 2 (Q − x1 )] with S1 = Q = 4
x
1
0≤ x1 ≤Q
10
Water Resources Planning and Management: M4L3
D Nagesh Kumar, IISc
Solution by Backward recursion…
Backtrack through each table,
∗
Optimal allocation for crop 1, x1 = 1 and S1 = 4
Thus,
S 2 = S1 − x1 = 3
From 2nd stage, the optimal allocation for crop 2, x2 = 1.
Now, S3 = S 2 − x2 = 2
From 3rd stage calculations, x3 * = 2
Maximum total net benefit from all the crops = 21
11
Water Resources Planning and Management: M4L3
D Nagesh Kumar, IISc
Numerical Problem: Solution by
Forward recursion
Start from the first stage and proceed towards the final stage
Suboptimization function for the first stage
f1 ( S1 ) = max NB1 ( x1 )
x1
x1 ≤ S1
Range of values for S1 is from 0 to 4
The calculations are shown in the table
12
Water Resources Planning and Management: M4L3
D Nagesh Kumar, IISc
Solution by Forward recursion…
13
Water Resources Planning and Management: M4L3
D Nagesh Kumar, IISc
Solution by Forward recursion…
f 2 ( S2 ) = max[NB2 ( x2 ) + f1( S2 − x2 )]
x
2
x2 ≤ S2
14
Water Resources Planning and Management: M4L3
D Nagesh Kumar, IISc
Solution by Forward recursion…
f 3 ( S3 ) = max [NB3 ( x3 ) + f 2 ( S3 − x3 )] with S3 = 4
x
3
x3 ≤ S 3 =Q
15
Water Resources Planning and Management: M4L3
D Nagesh Kumar, IISc
Solution by Forward recursion…
Backtrack through each table,
Optimal allocation for crop 3, x3 * = 2 and S 3 = 4
Then,
S 2 = S3 − x3 = 2
∗
The optimal allocation for crop 2, x2 = 1
Now, S1 = S 2 − x2 = 1
∗
From 1st stage calculations, x1 = 1
Maximum total net benefit from all the crops = 21
These solutions are the same as those we got from backward recursion method.
16
Water Resources Planning and Management: M4L3
D Nagesh Kumar, IISc
Thank You
Water Resources Planning and Management: M4L3
D Nagesh Kumar, IISc
Download