16th European Symposium on Computer Aided Process Engineering and 9th International Symposium on Process Systems Engineering W. Marquardt, C. Pantelides (Editors) © 2006 Published by Elsevier B.V.
2123
Refinery Planning under Correlated and Truncated Price and Demand Uncertainties Wenkai Li, I.A. Karimi, * R. Srinivasan Department of chemical and Biomolecular Engineering, National University of Singapore, 4 Engineering Drive 4, Singapore 117576 Abstract Because of the difficulty in computing the bivariate integral originated from the correlated demand and price, most research work on uncertainty assumes that the demand and price are independent. This can cause significant discrepancies in revenue calculation and hence yield sub-optimal planning strategies. This paper presents a novel approach to handle correlated and truncated demand and price uncertainties. A bivariate normal distribution is used to describe demand and price. The double integral for revenue calculation is reduced to several single integrals after detailed derivation. The unintegrable standard normal cumulative distribution fimction in the single integrals is approximated by polynomial ftinctions. Case studies show that, assuming independent price and demand may underestimate the revenue by up to 20%. Since the real world demands or prices vary in limited ranges, integrating over the whole range of a normal distribution, which some research has done, may give incorrect results. This paper uses a bivariate double-truncated normal distribution to describe demand and price. The influence of different degrees of truncation on plant revenue is studied. Keywords: Refinery, Planning, Uncertainty, Correlation, Truncation 1. Revenue calculation in the literature Since Dantzig's seminal work on uncertainty appeared^ research on uncertainty has been attracting the attention of numerous researchers. Most research work^'^ on uncertainty assumes that the demand and price are independent because of the difficulty in computing the bivariate integral originated from the correlated demand and price. However, by regressing real world demand and price data from EIA"^, the correlation coefficient between gasoline (New York Harbor Gasoline Regular) price and its demand is 0.44 for the year 2003 to 2004. For world crude oil in 2003 and 2004, the correlation coefficient is 0.30. These data show that the demand and price are far from independent. The computation of the expectation of plant revenue generates the main difficulty for a planning problem under uncertainty^. As pointed out by Petkov et aP and Li et aP, if the market demand is less than the product amount, only part of the product can be sold; otherwise if the market demand is higher than the product amount, then only part of the demand can be satisfied. The revenue should then be calculated by: Revenue = ^ [ X Z ^ * m i n ( P , x ) ] (1) cX Where c is the product price, P is the production rate of the product and x is the random demand. Different formulae have been developed in the literature^'^ from (1) to compute plant revenue by assuming that the demand and price are independent. ' Author to whom correspondence should be addressed. E-mail:
[email protected]
2124
W.Lietal
2. Revenue calculation for correlated and non-truncated price and demand A two-dimensional normal distribution is used to describe the relationship between correlated demand and price. Its pdf (probability density function), (p{c,x) , is represented by: ^1 (p(c,x) =
.
e ^
Ac-c)2 _2p(c-c)(x-e)
^ ^
(x-0)2.
c
^
(2)
27rac(Txyll-p^ Where, x represents random demand and c represents random price, c and GC are the mean and standard deviation of price, respectively; 0 and c^ are the mean and standard deviation of demand, respectively, p is the correlation coefficient. Combining eqs (1) and (2), the revenue is -j-oo
x*c*(p(c,x)dxdc
if x < P and
TOO
P * c * (p(c, x)dxdc if X > P. Then, eq (1) becomes C=-oo x=P
Revenue =
J
j
xc(p{c,x)dxdc-\-
C=-oo X = - o o
\
\
C=-oo
X=P
Pc(p{c,x)dxdc
After detailed derivations, the two double integrals in the above equation are reduced to several single integrals as following: Revenue = Al + A2 -{- A3 -\- A4 -\- A5 -\- B - CI - C2 (3) Where, the expressions of the single integrals in (3) are listed in Table 1. The term in Table 1, 0(.), represents the standard normal cumulative fianction. 3. Revenue calculation for correlated and truncated price and demand Underlying the formulae for revenue calculation in the literature^'^, the range of demand is assumed to be (-«>, +oo), which is not the case in the real world. Based on the data obtained from EIA"^, the world total oil demand and the crude oil price (Venezuelan Tia Juana Light) in 1970 to 1999 locate in the ranges (|i-2.2*a, |i+2.0*a) and (|i-1.3*a, 11+2.1 *a), respectively (|x and o respectively represent corresponding mean and standard deviation). A planning strategy based on a non-truncated distribution can be far fi-om optimal. This issue is addressed in this paper. Suppose that the range of demand is [XL, XU], where -oo < XL < Xy < +oo and the range of price is [CL, CU], where -00 < CL < Cu < +00. Then the pdf of bivariate bi-truncated normal distribution is: \g>(c,x) x^
\ \(p{c^x)dxdc
Refinery Planning Under Correlated and Truncated Price and Demand Uncertainties Table 1. The expressions of single integrals in (3) (B) = Pc
-yjl-p^cT^a,
Al
^ e ^ dm
2K
A2 =
-V-
p^
P (^X^
e
2n
^e
^ dm
f\ e ^ Q>(U)clm ^{U)dn
C1 = -T=^
+«>
PCTr
C2--
'27r n
A4 =
GcO + pca^
-
°°
A5 = - ^ 427t
m=
[ me ^ ^{U)dn
e~^0(U)dn
^
(U)dm
c-c
p-e
m
{ J
I
w"
me
- pm
U-
^Table 2. The expressions of single integrals in (5) XL-0
27tFjrr
J
me ^ [e ^ -e
^ ]dm
L =-
- pm
V ^ Xjj
-
2nFrjr
Aj^3=
\ e '[e
'
-e
^]dm
~^
- pm
Ujj=-
^
^^'
f m^e ^ [^(U) -
7c
0(L)]difm
Cj7 =
Pc 27UFr,
ffj2
<7c
f„2
yJ27rF,
AT
J —
J
7 =
e~~[^{U)-^{L)\dm
42^F,,
Combing eqs (1) and (4), the plant revenue is then %
P
cu % JBBTN v^>
C=Ci X=Xi
C=Ci X=P
xjaxac
2125
2126
W.Lietal
After detailed derivations, the revenue for truncated and correlated case is: Revenue = A^l + AT2 + A^S + Aj'4 + A^S + Q 7 + Q 2
(5)
Where, the expressions of the single integrals in (5) are listed in Table 2. 4. Approximation of the standard normal cumulative function In the single integrals listed in Tables 1 and 2, there is an unintegrable term, 0(.). There exist some accurate approximations to (.) in the literature^. However, those approximations are still too complicated to integrate the single integrals. In this paper, a polynomial fimction is used to approximate 0(.): 0 ( x ) = a + Z?x + cx^+Jx^+6x^ (6) When X is in the range of [-3, 3], the coefficients in eq (6) are: a, 0.5; b, 0.3942473009; c, -0.058125270; d, 0.0056884266 and e, -0.000228133. Replacing 0(.). with eq (6) in the single integrals, the revenue can be calculated. 5. Derivation of truncated loss function Loss fimction, defined as LF(P) = J (x - P)p(x)dx (for non-truncated and continuous p
distribution), represents the amount of unmet demand (the backorder level) of a plant facing uncertain demand^. It is essential to compute value of loss fimction to apply the Type II service level (fill rate) in a model. For non-truncated and normally distributed demand, loss fimction has been effectively applied and approximated to compute the actual fill rate in the literature^. In this paper, we extend Li et al.'s^ work to suit for truncated normally distributed demand. Assume that the range of demand is [XL, XU], the bi-truncated loss fimction, the bi-truncated density fimction of demand x is:
0(fz^)
PBTN W —
o-j«i>(^^^^)-
Where
—G
)-^{—
X —0
^^^
)] and (|)(x) is the standard normal density
fimction. Then, the bi-truncated loss fimction, LF^j^^ (P) , is derived: ^BTN
Where,Z;^ =—^
^BTN
.^;tp=
•
For non-truncated normal distribution, that is, X^ -^ +oo and X^ ^ -©o , eq (7) is reduced to the formulae used in the literature^'^: LF{P) = <7M2xp)-2xp[l-^i2^)\} (8)
Refinery Planning Under Correlated and Truncated Price and Demand Uncertainties 2127 6. Case studies Case studies are used to illustrate the influences of correlation and truncation of price and demand on plant revenue. The configuration of the case studies is taken from the case 1 of Li et al.^ Cases differ from each other on the standard deviations of 90# and 93# gasoline demand (Table 3). In Table 3, CV (Coefficient of Variation) is defined as CV = — . The means of 90# and 93# gasoline prices are 3215 and 3387, respectively. /^ The standard deviations of 90# and 93# gasoline prices are 600 and 620, respectively. Table 3. Means and standard deviations of product demands Products
Mean
Standard Deviation CV=0.2
CV=0.3
CV-0.5
90# gasoline
50
10
15
25
93# gasoline
70
10
20
35
6.1. Effect of correlation The revenues at different correlation coefficients (p) and CVs are listed in Table 4. It can be seen that, when CV is 0.5, the revenue at p of 0.4 (near the real world data) is 21.1% higher than the revenue when demand and price is independent (p= 0.0). That means, for a large enough CV, assuming independent price and demand may underestimate the revenue by up to 20%. It is found that the revenue difference between the independent and correlated cases increases as the increase of CV. In the above case study, when CV is 0.2 and p is 0.4, the revenue difference is 1.8%). This difference is 4.4%) for CV of 0.3 and p of 0.4. Table 4. Revenues at different correlation coefficients and CVs CV==0.2
CV==0.3
p 0
Revenue 38685.9
Gap*, %
0.1
38851.2
0.4
0.2
39021.0
0.3 0.4
Gap*, %
Revenue 10097.5
Gap*, %
28266.1
1.0
10589.8
4.9
0.9
28562.1
2.1
11096.9
9.9
39202.3
1.3
28878.3
3.2
11638.7
15.3
39398.5
1.8
29220.8
4.4
12225.6
21.1
Revenue at /? >0 - Revenue at
PI—*100%.
* Gan=
Revenue
CV==0.5
27978.6
Revenue at /7=0
6.2. Effect of truncation Integrating over the whole range of a normal distribution may give incorrect results to revenue calculation. The formulae derived for bivariate double-truncated normal distribution are applied in this paper. Some results are shown in Tables 5 and 6 (the product production rates of truncated cases are fixed to those of the non-truncated case for comparison). In Table 5 (CV=0.2), it can be seen that if the degree of truncation is |i±2o, integrating over the whole range will underestimate the revenue by 2 to 3%. If the degree of truncation is |a±a, integrating over the whole range will underestimate the revenue by about 12%). The revenue difference between truncated and non-truncated becomes much more significant for large CV. In Table 6 (CV=0.5), it can be seen that
2128
W. Li et al
the revenue increases by more than 40% for degree of truncation |i±2a. The revenue even increases by more than 100% for degree of truncation a±|X. It is clear that the revenue difference between truncated and non-truncated cases can be very huge in some cases. In Tables 5 and 6, the difference is defined as: Revenue of truncated case - Revenue of non-truncated case Difference^ 100%. Revenue of non-truncated case Table 5. Revenues of truncated and non-truncated cases (CV=0.2) Non-truncated
Truncated, |i±2a
Truncated, a±|i
p
(-oOj +oo)
Revenue
Difference, %
Revenue
Difference, %
0
38685.9
39847.6
3.0
43513.6
12.5
0.1
38851.2
39948.7
2.8
43772.7
12.7
0.2
39021.0
40107.0
2.8
43958.2
12.7
0.3
39202.3
40418.5
3.1
44166.1
12.7
0.4
39398.5
40792.3
3.5
44369.3
12.6
Table 6. Revenues of truncated and non-truncated cases (CV=0.5) Non-truncated
Truncated, \\±1(5
Truncated, a±|>i
p
(-00, +00)
Revenue
Difference, %
Revenue
Difference, %
0
10097.5
14986.6
48.4
23935.1
137.0
0.1
10589.8
15234.4
43.9
24545.5
131.8
0.2
11096.9
15556.8
40.2
25030.0
125.6
0.3
11638.7
16067.2
38.0
25457.7
118.7
0.4
12225.6
16693.6
36.5
25907.6
111.9
7. Conclusion In this paper, the influences of correlation and truncation of product price and demand on plant revenue are studied. Detailed theoretical derivations are performed. Case studies are developed to show the significant revenue difference between the traditional method and the new formulae developed in this paper.
References 1. Dantzig, G. B. Linear programming under uncertainty. Management Science, 1955, 1:197206 2. Petkov, S. B.; Maranas, C D . Multiperiod planning and scheduling of multiproduct batch plants under demand uncertainty, Ind. Eng. Chem. Res., 1997, 36 4864 3. Li Wenkai, Chi-Wai Hui, Pu Li, An-Xue Li, Refinery planning under uncertainty, Ind. Eng. Chem. Res. 43, 6742-6755, 2004 4. The U.S. Energy Information Administration, http://www.eia.doe.gov 5. Kim, K. J.; Diwekar, U. M. Efficient Combinatorial Optimization under Uncertainty. 1. Algorithm Development, Ind. Eng. Chem. Res., 2002,41 1276 6. Abramowitz & Stegun, "Handbook of Mathematical Functions", Dover Publications, 1965 7. Hopp, W. J.; Spearman, M. L. Factory Physics: foundations of manufacturing management, Irwin/McGraw-Hill, 2000