Energy Syst (2010) 1: 393–416 DOI 10.1007/s12667-010-0016-3 O R I G I N A L PA P E R
An MILP-based formulation for minimizing pumping energy costs of oil pipelines: beneficial to both the environment and pipeline companies Ehsan Abbasi · Vahid Garousi
Received: 5 March 2010 / Accepted: 2 June 2010 / Published online: 16 June 2010 © Springer-Verlag 2010
Abstract Optimal scheduling of pumps operation in fluid distribution networks (e.g., oil or water) is an important optimization problem. This is due to the fact that the dollar cost and also global carbon footprints of such a major transportation are in mega scales. For example, one of our industrial partners, a Canadian oil pipeline operator, spent more than $18.11 million dollars in 2008 for pumping costs. According to our calculations, this would lead to up to 182,460 tons of CO2 emissions annually. Therefore, even slight improvements in operation of a pipeline system can lead to considerable savings in costs and also reducing carbon footprints emitted to the environment (by introducing air pollutions needed to generate those huge amounts of electricity). In this paper, a methodology for determining optimal pump operation schedule for a fluid distribution pipeline system with multi-tariff electricity supply is presented. The optimization problem at hand is a complex task as it includes the extended period hydraulic model represented by algebraic equations as well as mixed-integer decision variables. Obtaining a strictly optimal solution involves excessive computational effort; however, a near optimal solution can be found at significantly reduced effort using heuristic simplifications. The problem is efficiently formulated in this paper based on Mixed-Integer Linear Programming. The proposed model is evaluated on a typical oil pipeline network. The numerical results indicate the effectiveness and computationally efficient performance of the proposed formulation. Keywords Pump scheduling · Mixed-integer linear programming · Oil pipeline networks · Power optimization E. Abbasi () · V. Garousi Software Quality Engineering Research Group, Department of Electrical and Computer Engineering, Schulich School of Engineering, University of Calgary, Calgary, Alberta, Canada e-mail:
[email protected] url: www.softqual.ucalgary.ca V. Garousi e-mail:
[email protected]
394
E. Abbasi, V. Garousi
Nomenclature Maximum efficiency of pump j ηj∗ t Efficiency of the pump j at time t ηj Binary variable that indicates the status of the pump on segment j at BPtj time t The constant term of the Darcy-Weisbach equation for segment j CLj Contracted volume of fluid that should be transported in the time frame Coni to the delivery point located on node i Operation cost associated with pump j at time t Costtj Minimum down time of the pump j DT j First electricity rate for pump j at time t FRatetj Average pressure head associated with node i at time t Hit min Hi Minimum acceptable head of node i Maximum acceptable head of node i HiMax Power charged by second rate for pump j at time t HPtj Incidencei,j The (i, j ) entry of the network incidence matrix Power limit that the rate of electricity is changed for pump j at time t Limtj Power charged by the first rate for pump j at time t LPtj t Binary variable which is equal to zero in case the system is shut down Op at time t and one otherwise Power consumed by pump j at time t Pjt PjMax The power that pump j consumes to add the maximum possible head to a fluid with maximum flow rate Head added to the network by pump j at time t PH tj t Pressure loss of segment j at time t PLj Average flow rate associated with pipeline segment j at time t Qtj The flow rate associated with the maximum efficiency of pump j Q∗j ˜j The flow rate associated with zero efficiency point for pump j Q QMax j Qmin j QSinkti QSourceti Sjt SH i SRatetj UT j IU j IDj Vjt Gj HLj
Maximum acceptable flow rate of segment j Minimum acceptable flow rate of segment j Discharge flow rate from node i at time t Flow rate of fluid incoming to node i at time t Ratio of the speed of the pump on segment j at time t to its nominal speed Static head associated with node i Second electricity rate for pump j at time t Minimum up time of the pump j The time pump unit j has to be On at the beginning of the period The time pump unit j has to be Off at the beginning of the period Valve pressure drop of segment j at time t The slope of the head loss versus flow rate linearized equation for segment j The Y-intercept of head loss versus flow rate linearized equation for segment j
An MILP-based formulation for minimizing pumping energy costs
Aj Bj CSi Ci Di Ej Fj
395
The slope of the pump head versus speed linearized equation for pump j The Y-intercept of the pump head versus speed linearized equation for pump j Constant coefficient in head versus discharging flow rate equation for node i The slope of the pump head versus discharging flow rate linearized equation for node i The Y-intercept of the pump head versus discharging flow rate linearized equation for node i The slope of the pump power versus speed linearized equation for pump j The Y-intercept of the pump power versus speed linearized equation for pump j
1 Introduction The energy required to operate pump stations in oil pipeline networks accounts for enormous energy consumption (either electrical or fossil fuels). Expenses due to electricity usage surpass 50% of operating cost in case of many fluid distributors. Furthermore, more than 95% of the electricity consumed in those systems is associated with pumping [1]. Consequently, optimizing pump operations is seen as a major source of significant savings which may be in the range of hundreds of thousands of dollars annually depending on the size of the pipeline [1, 2]. Oil distribution systems consist of components such as reservoirs, pipes, pump stations, and valves. Pipes carry the fluid(s) from reservoirs to the designated delivery points, e.g., refineries, ports. Pumps provide pressure needed to overcome gravity and pipe friction. Valves control flows and pressures. The entire operation is expensive, due to the fact that usually large masses of fluid are to be pumped. However, significant savings can be achieved through efficient energy management, by matching pumping schedules with time and shifting heavy pumping to periods with cheap tariff rates (e.g., night time) [2]. The objective of a pumping optimization problem is to provide the operator with the least-cost operation policy for all pump stations in the pipeline distribution system while maintaining the desired delivery schedule. The operation policy for a set of pumps is simply a set of rules or a schedule that indicates when a particular pump or group of pumps should be turned on or off over a specified period of time, and gives the operating speed in case of variable speed pumps. The optimal policy should result in the lowest total operating cost subject to a given set of boundary conditions and system physical and operational constraints [3]. Pipeline operation problem initially deals with binary variables (e.g., for turning pumps on or off) and comes up with non-linear terms in mathematical relationship between variables due to non-linear nature of the hydraulic models (i.e., pressure versus flow relationship of the pumps or head loss versus flow relationship of the pipeline). Hence, optimization of such a system calls for a dynamic, mixed-integer nonlinear
396
E. Abbasi, V. Garousi
solution technique. Since solving nonlinear problems is challenging in general, we can explore a way to carefully convert the current nonlinear problem to a linear one. As we discuss in this paper, the problem lends itself quite well to various simplifying assumptions to have it converted to a linear problem, and then to calculate its suboptimal solutions. The two most common approaches rely on approximating the original problem by assuming integer variables as continuous and/or by applying linearization techniques to the non-linear functions in the problem. The main objective of this paper is to develop an efficient mixed-integer linear formulation for finding optimal pump operation schedule. The nonlinear equations have been linearized in small operational flow rate ranges so that the linearization errors are as marginal as possible. The proposed formulation is capable of identifying the most cost-effective solution to the linearized format of the problem by giving the operation regime with the lowest-cost energy consumption that satisfies the mandatory operational and physical constraints given a set of time-varying and quantity-varying electricity tariffs. Although electric pumps are assumed in this study, but the proposed approach and formulation are generic and could be adjusted to pumps with other sources of energy supply (e.g., fossil fuels) with slight changes. The optimization method that we have developed enables a win-win situation for both the environment and pipeline companies in that, it firstly reduces the carbon footprint due to enormous electricity usage of pumping operations. Secondly, our method enables pipeline companies to reduce their pumping costs. Data from one of our industrial partners, Pembina Pipelines (www.pembina.com), an oil pipeline operator in Western Canada, can provide a perspective on how enormous the above measures can be. In year 2008, Pembina Pipelines spent about 18.11 Million Canadian dollars on electricity costs, almost all of which were spent on pumping [4]. To reversely calculate the amount of energy which has led to the above pumping cost, and using the average regional energy prices for electricity in Alberta (7.99¢/kWh) [5], one would get about 226.5 MWh for our industrial partner. We can then calculate the carbon footprint (emissions) produced to generate the above amount of electricity. Assuming that only coal is used for electricity generation, using an example benchmark for calculation of carbon footprint in electricity generation [6], this would lead to up to 182,460 tons of CO2 emissions annually. Albeit other types of electricity generation emit less CO2 into atmosphere, over 40% of world’s electricity is provided by coal power plants [7] and hence, the aforementioned carbon footprint could be assumed as a reasonable upper bound. The remainder of this article is outlined as follows. A review of the related works is presented in the next section. The Mixed-Integer Linear Programming (MILP) formulation of the problem is then provided, which includes the definition of the objective function and constraints. To evaluate our optimization approach, a test problem is then described along with the results of the optimization engine. Sensitivity analysis is then performed to assess the results of the optimization engine and finally the paper is concluded. The data used in the test problem are provided in the Appendix.
An MILP-based formulation for minimizing pumping energy costs
397
2 Related literature The problem of pipeline operation optimization has been a subject of study for three major types of products to be transported: water, natural gas, and oil. Although the transportation problems of these three product types are somewhat similar in concept, there are fundamental differences in formulating the optimization transportation problems for each one which stems from the domain logic and the physical nature of those products. For example, the compressibility of natural gas can lead to much sophistication in the optimization of the transportation problem. In the case of (citywide) water networks, the network is much smaller and has different structure (compared to cross-province oil pipelines) and also the notion of delivery amounts is not directly applicable, i.e., there is no contract between the residential water consumers and the provider to transfer a fixed volume of water in this case. In [8, 9], dynamic programming is used to evaluate the optimal pumps operation scenario. However, for practical distribution networks comprising reasonably large number of pump units, application of dynamic programming needs extensive computational resources due to the “curse of dimensionality” [10]. Non-Linear Programming (NLP) approaches are used in [11–14]. The NLP approaches do not guarantee finding the global optimal solution. The linearized or pseudo-linearized models were used in [15, 16]. A dynamic optimization technique is introduced in [17]. Recent efforts have also been conducted to implement the problem using the heuristic or meta-heuristic optimization techniques such as ant colony [18], particle swarm [19], and evolutionary algorithms [20]. While the heuristic-based methods provide flexibility to modeling of the problem and are often more scalable than deterministic optimization techniques, however; they do not guarantee finding a global optimum. In contrast, Mixed-Integer Linear Programming (MILP) guarantees convergence to global optimum in a finite number of steps [21] while providing a flexible and accurate modeling framework. In addition, during the search of the problem tree, information on the proximity to the optimal solution is available. Efficient MILP techniques, such as the branch-and-cut (a.k.a., branch-and-bound) algorithms have been developed, and commercial solvers with large-scale capabilities are currently available [22–25]. As a consequence, a great deal of attention has been paid to MILPbased approaches [26–28]. The execution time for MILP models grows dramatically with the number of integer variables included in the model. Hence, in order for having acceptable execution time for practically large systems, the integer variables should be avoided to the extent possible in the formulation. The novelty of the current work is proposing a novel and efficient MILP formulation for the single-product pipeline scheduling problem. Various practical types of electricity rates have been considered in the formulation. Furthermore, the model is capable of optimizing the operation schedule of a set of pumps consisting of both types of fixed speed and variable speed. The method is generic and systemindependent and could be applied to any generic structured network. The efficiency and applicability of the formulation is revealed by low execution time of the test results.
398
E. Abbasi, V. Garousi
Fig. 1 The numbering format of nodes and segments
3 Mixed-Integer Linear Programming (MILP) formulation As stated so far, optimal control of oil distribution systems involves selecting control schedules that provide the least operational cost, while satisfying the system constraints over a given finite time horizon. The key components of the pump scheduling problem are network hydraulics model, operational constraints, and the objective function. The assumptions and approaches used in representing these components can affect the quality of the solution achieved and are discussed below. 3.1 Network hydraulics model In order to validate a particular pump-operating policy, a mathematical model of the distribution system is required to assess the operational status of the network from a hydraulic point of view [29]. Potential modeling approaches include mass balance [30], regression [11], and full hydraulic simulation [17]. Since the full hydraulic model deals with more complex equations including transient states, this can be considered only by means of a commercial hydraulics modeling software and could not be used in linear models. Hence, a simplified hydraulic model is used here [16] which simplifies the hydraulic constraints while yielding the acceptable accuracy for the optimization problem. However, we acknowledge that a more realistic approach would be to integrate the optimization engine with hydraulic solver tools, and due to its complex nature, we leave it as a future work. An incidence matrix based on the graph theory is used to represent the interconnection status of the pipeline segments and nodes of the system. Incidence matrix has coefficients equal to −1, 0 or 1, and it maps pipeline segments and nodes into a single data structure. A unique incidence matrix exists for a specific network. If the fluid is due to pass the segment j of the pipeline network from node i towards node i + 1, as shown in Fig. 1, then the (i, j ) component of the incidence matrix will be equal to one and accordingly the (i + 1, j ) component is going to be minus one. If there is no connection between a node and a segment the according component will be zero. Mass balance of flow for each node is maintained by applying a set of flow equations on the incidence matrix that represents the pipeline configuration. By making use of the incidence matrix concept, the mass balance equation for each node of the system can be formulated as follows. Qtj × Incidencei,j + QSourceti − QSinkti = 0 ∀i, t (1) j
On the other hand, the following equation should be satisfied for each segment based on the concept of energy conservation. Hit − SH ti × Incidencei,j − PLtj − Vjt − PH tj = 0 ∀j, t (2) i
An MILP-based formulation for minimizing pumping energy costs
399
Fig. 2 Linearization method of the pipeline pressure loss due to friction versus flow rate pattern
The reader is referred to the nomenclature section for details on all mathematical formalizations used in this paper. Equation (2) states that the difference in heads of the two adjacent nodes is equal to the sum of pressures added to the system by pumps minus the friction and valves loss on the segment connecting the two nodes plus the difference in static heads of the nodes. The term PLtj is the pressure loss that occurs in pipeline segment j as a result of friction which depends on the fluid type, pipeline material and it’s cross section, and the flow rate of fluid. The aforementioned factors have been related to each other in Darcy-Weisbach equation [31] in which, the amount of loss is proportional to the flow rate squared as shown in (3). 2 PLtj = CLj × Qtj
∀j, t
(3)
The term CLj remains constant for a specific fluid and specific pipeline and depends on the pipeline material, cross section area, fluid viscosity and density. The flow rate associated with oil distribution networks is limited to a small range due to operational constraints. It is empirically observed that the relation between head loss and flow rate is very close to linear in the mentioned practical flow rate ranges. Hence, it is possible to approximate the head-loss relationship as shown in Fig. 2. The following equation represents the linear format. PLtj = Gj × Qtj + HLj × Opt
∀j, t
(4)
400
E. Abbasi, V. Garousi
The binary variable Opt determines whether the system is off at the time t, and is verified by the following equation: Opt ≥ BPtj
∀j, t
(5)
If at least one of the pumps is On at time t (BPtj = 1), then the variable Opt is forced to be one which indicates that the system is in operational mode. On the other hand, if all the pumps are determined to be off, the variable Opt is forced to be zero as well so that the operational constraints of the system are met. This issue will be discussed further in the section dealing with the operational constraints. Since valves are used to attenuate the pressure to avoid over-stressed condition to the pipeline, they appear in (2) accompanied by negative sign. The last term of (2) PH tj represents the pressure head added to the system by the pump located on segment j at time t. The pumps head is a function of the flow rate and also the speed of the pump in case of variable speed pumps. The head-flow characteristic curve of a variable speed pump provided by the manufacturer for a specific speed is similar to what is presented in Fig. 3 and is often approximated by a quadratic polynomial as: 2
PH tj = APj × Qtj + BPj × Qtj × Sjt + CPj × Sjt
2
∀j, t
(6)
In which, APj , BPj and CPj are the coefficients of the pump which determine the head, flow-rate and speed relation of the pump and is provided by the manufacturer. For a typical pump mentioned in [32], the values of APj , BPj and CPj are −1.09 × 10−4 , 5.15 × 10−4 and 223.32 respectively. On the other hand, the speed of a pump can vary from half of the nominal speed to twice the value (about 100% variation range) but the amount of flow rate on a typical pipeline varies 120–150 cubic meters per hour (20% variation range). Due to the above small range of variation and the fact that, in real-world pipeline networks that we have analyzed (e.g., the one for the Pembina Pipeline Corporation), parameters APj and BPj of (6) are considerably lower than the parameter CPj , practically, speed is the dominant determining variable which actually controls the pressure being added to the pipeline system by the pump. This phenomenon can also be visually assessed on a variable speed pump set of curves in the typical range of operation [33]. Therefore, it is reasonable to replace Qtj in (6) with the average flow rate of the pipeline and linearize the equation with respect to Sjt . This relationship, if linearized, could be stated in the following form: PH tj = Aj × Sjt + Bj × BPtj
∀j, t
(7)
The final part of the model governs the head-flow relationship at the delivery nodes. There exists a quadratic relationship between the variables as follows: Hit = CSi × QSinkti
2
∀i, t
(8)
In real-world pipeline networks that we have assessed, the discharging flow rates at the nodes do not vary much from the flow rates of the main line. In other words, the range of variation of QSinkti is limited in practice. Hence, it is possible to linearize
An MILP-based formulation for minimizing pumping energy costs
401
Fig. 3 Typical head and efficiency versus flow rate curves according to a centrifugal pump
(8) with respect to variable QSinkti while having marginal approximation error. As an example of the amount of such linearization errors, if (8) is linearized in the range of flow rate of 100–200 for a specific oil product with density of 850 kg per cubic meter, the corresponding r-square regression error value is 0.99. The close proximity of this r-square error value to unity denotes that (8) could be linearized with respect to QSinkti with a very reasonable precision as follows: Hit = Ci × QSinkti + Di × Opt
∀i, t
(9)
3.2 Operational constraints The operational constraints on the optimization problem represent system performance criteria and demand contracts which may include constraints on junction node pressure, flow rate, pumps’ available speed range, contracts with consumers, and pump switching limits. The pressure of the fluid in the pipeline should not pass a specified limit due to the fact that high pressures may cause the pipelines to leak which may eventually end up in catastrophic failures. On the other hand, if the pressure falls below a certain limit, an unacceptable amount of vapor will be formed, causing cavitations, and consequent damage to the pipeline segments and the centrifugal pump impellers. For each operational time interval, the pressure at any junction node i must be between a maximum value and a minimum value. This can be expressed as: Himin × Opt ≤ Hit ≤ HiMax × Opt
∀i, t
(10)
Furthermore, the flow rate corresponding to the distribution network should be limited to the pipeline designed criteria at all time intervals. This can be stated as follows. t t Max Qmin × Op t j × Op ≤ Qj ≤ Qj
∀j, t
(11)
402
E. Abbasi, V. Garousi
The speed of rotation of the pump units are bounded by an upper and lower limit which is defined by the following equation: Sjmin × BPtj ≤ Sjt ≤ SjMax × BPtj
∀j, t
(12)
It has to be noted that when a specific pump j is Off at time t the according variable BPtj equals to zero, and hence, the speed of the pump is forced to be zero at that time interval. However, at any time the pump is On, which means that the according variable BPtj equals to one, the variable speed is imposed by the (12) to be in the range of Sjmin and SjMax . The most important objective is to transport products from sources to designated destinations within appropriate delivery timeframes determined by contracts. Hence the next constraint associated with the optimization problem is to meet this requirement for the sink nodes which can be stated as follows. T
QSinkti ≥ Coni
∀i
(13)
t=1
Another important cost issue that deserves consideration is pump maintenance. An operation schedule in which pumps are turned on and off many times may reduce energy consumption; however, this schedule may increase the wear on the pumps and increase the resulting pump maintenance costs. It would also complicate the operation of the system from the operator’s point of view. This cost has not been quantified, but it is empirically found that it is proportional to the number of pump switches. Therefore, the number of pump switches is used as a surrogate measure for the intangible wear-and-tear cost. The switching is not an easily quantifiable cost. This fact propels the problem towards two independent objectives that do not have common units. Therefore, either a multi-objective optimization method should be adopted or the switching objective should be introduced into the model as a constraint. The operator can then evaluate the trade-off of increasing cost to reduce the number of switches by reviewing the model results. This issue is recognized by considering minimum continuous operation time and minimum continuous off time for the pump units. These two constraints can be stated mathematically in MILP structure as follows. The set of the following equations assures that when a pump is turned on, it is to be operated continuously for at least a given minimum on-time limit of UT j (an input setting for each pump). IU j 1 − BPnj = 0 ∀j
(14)
n=1 t+UT j −1
BPnj ≥ UT j × [BPtj − BPt−1 j ]
∀j, ∀t ∈ {IU j + 1, . . . , T − UT j + 1} (15)
n=t T {BPnj − [BPtj − BPt−1 j ]} ≥ 0 ∀j, ∀t ∈ {T − UT j + 2, . . . , T } n=t
(16)
An MILP-based formulation for minimizing pumping energy costs
403
Conversely, the following equations ascertain that the pumps that are turned off, will not change state for a given minimum down-time period of DT j . IDj
BPnj = 0
∀j
(17)
n=1 t+DT j −1
[1 − BPnj ] ≥ DT j × [BPt−1 − BPtj ] j
n=1
∀j, ∀t ∈ {IDj + 1, . . . , T − DT j + 1} T {1 − BPnj − [BPt−1 − BPtj ]} ≥ 0 j
(18)
∀j, ∀t ∈ {T − DT j + 2, . . . , T } (19)
n=1
3.3 Objective function The operating cost for a pumping system is typically comprised of energy consumption based on the kilowatt-hours of electric energy consumed during the billing period. In general, energy-consumption charges may be reduced by decreasing the fluid quantity pumped, decreasing the total system head, increasing the overall efficiency of the pump station by proper pump selection, or maintaining uniform highly efficient pump operations. In most instances, efficiency can be improved by using an optimal control algorithm to select the most efficient combination of pumps to meet a given demand. Additional cost savings may be achieved by increasing flow rates during offpeak hours, e.g., from midnight to early morning. Off-peak pumping is particularly beneficial for systems operating under a variable-electricity-rate schedule. The individual pump efficiency η is a function of the pump flow and the pump speed and is approximated here by a cubic polynomial. It is assumed that the available information includes the peak efficiency point (Q∗ , η∗ ). The cubic approximation of the efficiency ensures that the curve goes through the three specified points (0, 0), ˜ 0) and also attains its maximum value for the peak efficiency flow (Q∗ , η∗ ), and (Q, (i.e. dη/dQ = 0 at Q = Q∗ ) As illustrated in Fig. 3. Consequently, the efficiency flow relationship of a centrifugal pump as reported by [32] will be, ηj = aj Q3j + bj Q2j + cj Qj + dj
(20)
In which, ˜ j )/[−(Q∗j )2 (Q ˜ j − Q∗j )2 ] aj = ηj∗ (2Q∗j − Q
(21)
bj = −ηj∗ (3(Q∗j )2 − (Q˜ j )2 )/[−(Q∗j )2 (Q˜ j − Q∗j )2 ]
(22)
˜ j )/[−(Q∗j )2 (Q ˜ j − Q∗j )2 ] ˜ j (3Q∗j − 2Q bj = ηj∗ Q∗j Q
(23)
and dj is zero for all pumps. ˜ are provided by the pumps manufacturers. TypiThe parameters Q∗ , η∗ and Q ∗ ˜ [32]. cally, the peak efficiency flow Q is close to 0.5Q
404
E. Abbasi, V. Garousi
For a single pump running at speed Sj , the formula for electrical power consumption can be evaluated from the hydraulic power of fluid and the pump efficiency, as: Pjt = Const × Qtj × PH tj /ηjt
∀j, t
(24)
In which, Const is a constant parameter and its value depends on the fluid type. Since PH tj is a function of flow-rate and pump speed, the power consumed by a pump could be assumed as a function of flow-rate and pump speed as well. Considering the fact that the flow-rate of oil going through the pipeline is in limited range, the dominant variable which sets the power is speed of the pump. Hence, (24) is linearized with respect to speed in the allowed range of the flow rate, which gives (25). Pjt = Ej × Sjt + Fj × BPtj
∀j, t
(25)
Finally, the cost of operating the pump is evaluated as the product of the amount of power consumed and the electricity rate. Since the pipeline networks are usually expanded over a reasonably vast geographical area, more than a single electrical company are to supply their electricity. In this context, fluid distributors face various electricity purchasing contracts. As per our meetings with our industrial partners in Alberta and also by seeing examples of existing power contracts, we have seen two cases in this context: (1) Some electricity suppliers offer incentive rates for electricity usage to sell more electricity as shown in Fig. 4 (Type II). (2) On the other hand, others encourage their customers to consume less electricity (Type I). We were not able to find public information (e.g., papers) on this topic exactly, but governmental documents such as this one [34] reflect the idea behind this pricing scheme. Furthermore, electricity suppliers usually offer rates based on time of use to encourage the customers to shift their consumption to off-peak times, e.g., midnight to early morning. In fact, a comprehensive optimization algorithm should consider all the above electricity charging patterns as this can be a major opportunity for lowering the pump operation costs. The following equations recognize the multi-tariff electricity charges: Costtj = FRatetj × LPtj + SRatetj × HPtj
∀j, t
(26)
For which, LPtj + HPtj = Pjt
∀j, t
0 ≤ LPtj ≤ Tetj × Limtj
(27) ∀t, j
(1 − Tetj ) × Limtj ≤ HPtj ≤ (1 − Tetj ) × PjMax
(28) ∀t, j
(29)
Tetj is a binary variable that assures what rate is in correspondence with the power consumption. If the power of the pump i is in the first cost region (e.g., less than Limtj ), the binary variable Tetj will get a value of 1 so that the limit on variable LPtj is Limtj and the variable HPtj is forced to 0, therefore, the cost of unit i is calculated based on the first region’s rate. Similar condition exists for the case if the pump i’s power falls in the second cost region.
An MILP-based formulation for minimizing pumping energy costs
405
Fig. 4 Various types of electricity tariffs
Finally, the objective function is the sum of the total unit’s costs as follows. T J
min
Costtj
(30)
t=1 j =1
3.4 Summary of the MILP formulation Based on the formulations presented above the final optimization model is summarized as follows: Decision variables:
Continuous
Costtj
LPtj
HPtj
Binary
Tetj
Opt
BPtj
Pjt
Sjt
Qtj
QSourceti
QSinkti
Hjt
PLtj
Vjt
PH tj
Objective function: min
T J t=1 j =1
Constraints:
Costtj
(31)
406
E. Abbasi, V. Garousi
Constraints determining cost Costtj = FRatetj × LPtj + SRatetj × HPtj LPtj
+ HPtj
= Pjt
∀j, t
∀j, t
0 ≤ LPtj ≤ Tetj × Limtj
(27) ∀t, j
(1 − Tetj ) × Limtj ≤ HPtj ≤ (1 − Tetj ) × PjMax Pjt
= Ej × Sjt
(26)
+ Fj × BPtj
(28) ∀t, j
∀j, t
(29) (25)
Hydraulics model constraints
Qtj × Incidencei,j + QSourceti − QSinkti = 0 ∀i, t
(1)
j
(Hit − SH ti ) × Incidencei,j − PLtj − Vjt − PH tj = 0 ∀j, t
(2)
i
PLtj = Gj × Qtj + HLj Opt Opt ≥ BPtj
∀j, t
∀j, t
(5)
PH tj = Aj × Sjt + Bj × BPtj Hit
= Ci × QSinkti
(4)
∀j, t
+ Di × Op
t
∀i, t
(7) (9)
Operational constraints Himin × Opt ≤ Hit ≤ HiMax × Opt
∀i, t
(10)
t t Max Qmin × Opt j × Op ≤ Qj ≤ Qj
∀j, t
(11)
Sjmin × BPtj ≤ Sjt ≤ SjMax × BPtj T
QSinkti ≥ Coni
∀j, t
∀i
(12) (13)
t=1 IU j [1 − BPnj ] = 0 ∀j
(14)
n=1 t+UT j −1
BPnj ≥ UT j × [BPtj − BPt−1 j ]
n=t
∀j, ∀t ∈ {IU j + 1, . . . , T − UT j + 1} T {BPnj − [BPtj − BPt−1 j ]} ≥ 0 ∀j, ∀t ∈ {T − UT j + 2, . . . , T } n=t
(15) (16)
An MILP-based formulation for minimizing pumping energy costs
407
Fig. 5 The test case network configuration
IDj
BPnj = 0 ∀j
(17)
n=1 t+DT j −1
[1 − BPnj ] ≥ DT j × [BPt−1 − BPtj ] j
n=1
∀j, ∀t ∈ {IDj + 1, . . . , T − DT j + 1} T {1 − BPnj − [BPt−1 − BPtj ]} ≥ 0 ∀j, ∀t ∈ {T − DT j + 2, . . . , T } j
(18) (19)
n=1
4 Case study To evaluate our optimization technique, we are working with a Western Canadian oil pipeline operator to apply our optimization technique to its pipeline network. However, as of this writing, extraction of actual parameters to be able to execute the algorithm has not been completed yet. In the mean-time, we evaluate the proposed approach on a hypothetical oil distribution system comprising of 11 pipeline segments which connect 10 nodes. The system is designed to feed two delivery nodes from a single source on a dendritic structure. All of the segments are equipped with pump units and valves. Structure of the network is shown in Fig. 5. The system parameters are presented in the Appendix. To solve the optimization problem for the above test-case pipeline network, we coded the formulation in the GAMS (General Algebraic Modeling System) environment and used GAMS’s MILP solver (CPLEX 11.0). By executing the optimization program, the total optimum cost of $5,850.50 for a 24 hours time frame is obtained. Table 1 presents the optimum pump operation schedule. The solver could find the optimal solution in 1,743 (MILP) iterations which took 0.172 seconds. To provide a baseline for execution times reported in this article, we should note that all the results reported in this paper were gathered by executing our
408
E. Abbasi, V. Garousi
Table 1 The optimal ratio of operating speed to nominal speed corresponding to each pump in 24 hours period (hour 1 is 1 AM) Pumps
Hours
1
2
3
4
5
6
7
8
9
10
11
0
0
0
0
0
0
0
0
0
0
0
1
1.038
1.025
0
0
1.3
1
0
0
1
1
1–4 Hour 5–24
Table 2 The optimal flow rate of pipeline segments (Barrels/Hour) in 24 hours period Pipeline segments 1 Hour 1–4 Hour 5–24
2
3
4
5
6
7
8
9
10
11
0
0
0
0
0
0
0
0
0
0
0
1800
1800
800
400
400
800
1000
500
500
1000
1000
optimization GAMS models on a PC with the Windows XP operating system having a CPU with the speed of 2.3 GHz and 2 Giga Bytes of RAM. The optimal operation schedule of pumps is in a way that there is no need to use the pressure reducing valves. This is reasonable as the valves reduce the pressure added to the system by pumps which is a waste of energy and spare of expense. The according optimal segments’ flow rate values for every hour are presented in Table 2. As it can be seen from Table 1, although the electricity rate is lower in the after midnight time, but the optimization model has decided to turn the system off at night time. This fact is a side effect of the minimum operation time constraint considered for the model. If the system had been started to operate at midnight (hour 1) to make use of the low rate electricity tariff, it had to be turned off during day to avoid overdelivery of the product and extra cost. In this case, the minimum down time and up time constraints bounds it to be off for 5 hours in a row. However, with the current system parameters, it is not possible to meet the delivery volume contract constraint in 18 hours. Hence, the model finds it feasible and more cost effective to set the operation schedule started from hour 5. If the two constraints of minimum up time and down time are relaxed, then the optimal solution of $4,226.00 is achieved. As it was expected, the total cost in this case is less due to the fact that the model pushes the pumps to operate at the times that electricity rate is assumed lower. The pumps operating schedule which is found in this case is presented in Table 3. It is notable that the four pumps of 4, 5, 8 and 9 remain off at all the hours. The reason is that they are located on the two pair of parallel segments of 4–5 and 8–9. The friction loss factor of these parallel segments is equal to the other series segments as segment 2 or 7 while the flow rate of the oil passing through them is half of those segments. Consequently, the total friction loss of the pair is much lower than the other series segments. Hence, the pressure added to the system by the preceding pumps is sufficient to overcome the friction loss according to these segments and keep the node pressures over the minimum limit.
An MILP-based formulation for minimizing pumping energy costs
409
Table 3 The optimal ratio of operating speed to nominal speed corresponding to each pump in 24 hrs period after relaxing minimum up and down time constraints Pumps 1
2
3
4
5
6
7
8
9
10
11
1
1.038
1.025
0
0
1.3
1
0
0
1
1
0
0
0
0
0
0
0
0
0
0
0
1
1.038
1.025
0
0
1.3
1
0
0
1
1
Hour 16
0
0
0
0
0
0
0
0
0
0
0
Hour
1
1.038
1.025
0
0
1.3
1
0
0
1
1
Hour 21
0
0
0
0
0
0
0
0
0
0
0
Hour
1
1.038
1.025
0
0
1.3
1
0
0
1
1
Hour 1–11 Hour 12, 13 Hour 14, 15
17, 20
22–24
Table 4 Optimization results for different time spans Time span (hours)
Optimum operation cost with the set of minimum up time and down time constraints ($) Included
Relaxed
24
5,850.50
4,226.00
48
11,308.57
10,469.53
72
15,837.82
15,704.29
96
21,668.37
20,939.05
120
26,372.89
26,173.81
144
31,790.96
31,408.58
∗ The delivery contract is increased proportional to the length of time for each case
If all the pumps are considered as fixed speed, then the cost of system increases to $5,909.00 which is, as expected, higher than the test case total cost. In this case, all of the pumps except the ones located at segments 8 and 9 operate from hour 5 to hour 24. In order to assess the effect of the set of constraints of minimum up time and minimum down time of the pump units in longer time spans, the system is executed once from a 24-hour period up to 144-hour period considering the up-time/down-time constraints and, in another execution, the constraints are relaxed (i.e., not considered). The results of this analysis are presented in Table 4. It can be seen, from the results, that the effect of minimum up time and down time constraints is more significant in the 24 hours time span. This difference is due to the flexibility of model in making use of the low tariff hours in longer time spans.
410
E. Abbasi, V. Garousi
Fig. 6 Sensitivity analysis by increasing the contracted delivery volumes
5 Sensitivity analysis In order to evaluate the accuracy and behavior of the model, several sensitivity analyses have been performed on the model. Some essential parameters that their variations reflect the due behavior of the model have been considered for this purpose. 5.1 Sensitivity analysis on delivery volume contract A sensitivity analysis is conducted on the delivery contract. The delivery contract is increased from 0 to 130% of the test case value. Figure 6 presents the results of the sensitivity analysis. As expected, the total number of pump-hour operation is increased as a result. It should be noted that for the values greater or equal 130% of the test case value, the constraints of the model could not be met by the system and would indeed be infeasible (i.e. the system reaches its transportation limit in 130% and cannot deliver any more without violating the operational constraints e.g. maximum pressure at nodes.) The sudden variations observed in the slope of the pump-hours operation grow in Fig. 6 are due to the changes in number of pumps necessary to provide the pressure required for maintaining the optimum flow rate. The consistent slope on Fig. 6 corresponds to the condition that a specific number of pumps in operation give the necessary pressure to the system to deliver the assigned volume in subsequent cases, but as the contracted volume is increased the identical set of pumps is operated for another more hour to meet the contract limit which causes a constant addition of pump hours operation versus contracted volume increment that forms the constant slope.
An MILP-based formulation for minimizing pumping energy costs
411
Fig. 7 Sensitivity analysis of the total pumps operation hours versus increase in the friction factor
Fig. 8 Sensitivity analysis of total system cost versus increase in the friction factor
5.2 Sensitivity analysis on the pipe friction factor As another sensitivity analysis, the pipe friction factor is varied and it’s impact on the total pump-hours operation is studied. As the friction factor is increased, the number of pump hours needed to overcome this pressure loss is increased as shown in Fig. 7. Furthermore, the cost of system operation is increased as well (Fig. 8). As it could be seen in Fig. 8, the slope of the cost variation increases as the ratio of friction factor to
412
E. Abbasi, V. Garousi
Fig. 9 Sensitivity analysis for total cost versus change in flow rate
the original test case value passes the threshold of 1.11. At this specific point, more pumps are needed to operate to overcome the friction loss of the pipeline. This fact is even more realizable if the two of Figs. 7 and 8 are considered simultaneously. 5.3 Sensitivity analysis on the system flow rate A sensitivity analysis is done on the value of the flow rate versus the total cost. Since the incoming flow rate of oil to the first segment determines the other segments flows accordingly, the sensitivity analysis is performed on this specific variable. This has been done by adding the following constraint to the model, which bounds the flow rate to the specific value. QSourcet1 = FB × Optt
(31)
In which the parameter FB refers to a specific flow rate. The curve in Fig. 9 is achieved by varying FB in the range of 1,700 to 1,900 (Barrels/Hour) and measuring the total cost. Figure 9 reveals the fact that the minimum value of the cost in this range is 1,800 (Barrels/Hour) which was found by the MILP model (Table 2). If one moves on the graph from the optimal value of 1,800 to the left, sudden increases in total cost are detected which are due to the inability of the preceding pump schedule to meet the delivery volume contracts and hence the system should be operated for another more hour. Before reaching such points, the cost is in decreasing direction as the friction loss of the system is decreasing and pumps are in charge of adding less pressure to the pipeline system.
An MILP-based formulation for minimizing pumping energy costs
413
Table 5 Model and execution parameters associated with each time horizons Time horizon
Number of
Number of discrete
Number of
Number of
Execution
(hours)
decision variables
decision variables
equations
iterations
time (s)
24
3,169
552
4,474
2,624
0.063
48
6,337
1,104
8,938
7,280
0.094
50
6,601
1,150
9,310
10,499
0.094
55
7,261
1,265
10,240
10,742
0.093
60
7,921
1,380
11,170
9,262
0.14
65
8,581
1,495
12,100
16,993
0.14
70
9,241
1,610
13,030
16,094
0.141
75
9,901
1,725
13,960
20,080
0.172
Fig. 10 Sensitivity analysis for execution time versus change in time horizon
5.4 Sensitivity analysis on the size of the model Another sensitivity analysis has been conducted on the size of the model by increasing the time horizon during which the system is operated. This type of analysis is sometimes called scalability sensitivity. Table 5 indicates variation in number of variables and the number of equations (forming the model) as the time horizon is increased. The execution time and number of iterations it takes to give the final solution are also presented in Table 5. The GAMS output .lst file provides all the metrics reported in this table. Figure 10 depicts the variation of the execution time versus the time horizon considered. The trend of execution time indicates the potential scalability of the model for solving large-scale problems.
414
E. Abbasi, V. Garousi
6 Conclusion and future works Optimal scheduling of oil distribution systems is a dynamic mixed-integer problem and its solution is hindered by the difficulties faced in dealing with the large number of discrete and continuous variables, and the nonlinearity of the system equations. Model simplification and the use of surrogate decision variables have been used in the past to solve such a scheduling problem. However, the optimal scheduling of truly large scale distribution systems is still a big challenge. The aim of this paper was to implement the single-product fluid pipeline operation scheduling with MILP formulation. It is found that MILP can find the global optimum in finite number of steps. The sensitivity analysis results reveal the accuracy of the proposed method. Considering the low execution time and accuracy of the model, the proposed approach is viable for practical purposes as well as online control systems. The simulation test results followed by the sensitivity analysis presented reveal the viability and applicability of the proposed method. Oil pipelines operation is a challenging task in fluid distribution industry and slight improvements in operation costs can bring huge financial savings for the distributors. On the other hand, many novel optimization methods are being proposed lately, this research work could be built up on by modeling the problem utilizing the nascent optimization techniques and comparing the results. Modeling multi-product oil pipeline systems is another area in which the current work might be expanded. The latter case is very challenging, for the fluid-dependent parameters which were assumed constant in the proposed formulation of this paper, are change prone due to movement of fluids in the pipeline. Therefore, more constraints are going to be imposed to the model to track the movement of fluids which must be duly accounted for in the model thereof. As an ongoing/future work, the proposed model is now being tested on a Western Canadian Oil Pipeline with 800 km in length and 6 pump stations. Currently, we are in the process of extracting the parameters needed for optimization modeling. We also plan to conduct analysis of energy-savings (in dollars) for our industrial partners and also reduction in carbon footprints if the pumping regimes generated by our method are used (similar to the numerical calculations of the introduction section). Acknowledgements This work was supported by the Alberta Ingenuity New Faculty grant number 200600673. We would like to thank Dr. Nesa Ilich from Optimal Solutions Ltd., Ognjen Sobajic and the engineers from Pembina Pipeline Corporation for their inputs and collaborations in this project.
Appendix
Table 6 Input data used in Case study APj j = 1, 2
−0.3 × 104
Himin i = 1, . . . , 10
APj j = 3, . . . , 11
−1.0941 × 104
HiMax i = 1, . . . , 10
450
BPj j = 1, 2
2.5 × 102
CLj j = 1, 2
0.020941
BPj j = 3, . . . , 11
5.1516 × 102
CLj j = 3, . . . , 11
0.05941
60
An MILP-based formulation for minimizing pumping energy costs
415
Table 6 (Continued) Q∗j j = 1, 2
CPj j = 1, 2
110
CPj j = 3, . . . , 11
223.32
CSi i = 6, 10
0.06
ηj∗ j = 1, . . . , 11
83.5%
SH i i = 1
120
Coni i = 6
12000
SH i i = 2, . . . , 10
0
Coni i = 10
20000
j = 1, 2 QMax j
2000
SjMax j = 2, 3, 6, 9
1.3
j = 3, . . . , 11 QMax j
1000
Sjmin j = 2, 3, 6, 9
0.7
Qmin j j = 1, 2 Qmin j j = 3, 6, 7, 10, 11 Qmin j j = 4, 5, 8, 9 FRatetj j = 1, 3, 5, 6, 9, 11
1500
SjMin j = 1, 4, 5, 7, 8, 10, 11
1
800
Sjmin j = 1, 4, 5, 7, 8, 10, 11
1
400
DT j j = 1, . . . , 11
5
0.035
SRatetj j = 1, 3, 5, 6, 9, 11
400
t = 1, 2, 3, 4, 23, 24 SRatetj j = 1, 3, 5, 6, 9, 11
0.065
FRatetj j = 2, 4, 7, 8, 10
0.07
SRatetj j = 2, 4, 7, 8, 10
0.025
FRatetj j = 1, 3, 5, 6, 9, 11
0.07
t = 5, . . . , 22 500
SRatetj j = 1, 3, 5, 6, 9, 11
2.0941 × 10−2
UT j j = 1, . . . , 11
5
IU j j = 1, . . . , 11
0
t = 1, . . . , 24 CLj j = 1, 2
0.05
t = 5, . . . , 22
t = 1, 2, 3, 4, 23, 24 Limtj j = 2, 4, 7, 8, 10
0.14
t = 5, . . . , 22
t = 1, 2, 3, 4, 23, 24 SRatetj j = 2, 4, 7, 8, 10
1700 914
t = 1, . . . , 24
t = 1, 2, 3, 4, 23, 24 FRatetj j = 2, 4, 7, 8, 10
Q∗j j = 3, . . . , 11
0.13
t = 5, . . . , 22
CLj j = 3, . . . , 11
5.941 × 10−2
I Lj j = 1, . . . , 11
5
References 1. Pezeshk, S., Helweg, O.J.: Adaptive search optimization in reducing pump operation costs. J. Water Resour. Plan. Manag. 122, 7 (1996) 2. Webb, K.: Non-chronological pipeline analysis for batched operations. In: PSIG Annual Meeting Calgary, Alberta (2007) 3. Lindell, E., Ormsbee, K., Lansey, E.: Optimal control of water supply pumping systems. J. Water Resour. Plan. Manag. 120, 237–252 (1994) 4. Pembina Pipeline Corporation: 2008 Annual Report (public information). http://www.pembina.com/ webcms.nsf/AllDoc/0A7E6DFB88C344B387257570007A5C3B/$File/2008AnnualReport.pdf. Last accessed: March 2010 5. ENERGYSHOP CORP: Deregulated electricity offers. http://www.energyshop.com/es/prices/ab/ eleab.cfm?ldc_id=357. Last accessed: March 2010 6. British Parliamentary Office of Science and Technology: Carbon footprint of electricity generation. http://www.parliament.uk/documents/upload/postpn268.pdf (2006) 7. U.S. Energy Information Administration: International Energy Outlook 2009. http://www.eia. doe.gov/oiaf/ieo/coal.html. Last accessed: March 2010 8. Coulbeck, B.: Optimization of water networks. Trans. Inst. Meas. Control 6, 271–279 (1984) 9. Zessler, U., Shamir, U.: Optimal operation of water distribution systems. J. Water Resour. Plan. Manag. 115, 18 (1989) 10. Bellman, R.: Dynamic Programming. Princeton University Press, Princeton (1957) 11. Ormsbee, L.E., Walsky, T., Chase, D., Sharp, W.: Methodology for improving pump operation efficiency. J. Water Resour. Plan. Manag. 115, 148–164 (1989)
416
E. Abbasi, V. Garousi
12. Yu, G., Powell, R.S., Sterling, M.J.H.: Optimized pump scheduling in water distribution systems. J. Optim. Theory Appl. 83, 463–488 (1994) 13. Lansey, K.E., Awumah, K.: Optimal pump operations considering pump switches. J. Water Resour. Plan. Manag. 120, 19 (1994) 14. Bounds, P.L.M., Ulanicka, K., Ulanicki, B., Dacre, B., Cummings, G.: Optimal scheduling of SouthStaffordshire water supply system using the FINESSE package. In: Water Supply Management, Balkema, Rotterdam, The Netherlands (2003) 15. Ulanicki, B., Orr, C.H.: Unified approach for the optimization of nonlinear hydraulic systems. J. Optim. Theory Appl. 68, 161–179 (1991) 16. Jowitt, P.W., Germanopoulos, G.: Optimal pump scheduling in water supply networks. J. Water Resour. Plan. Manag. 118, 17 (1992) 17. Ulanicki, B., Kahler, J., See, H.: Dynamic optimization approach for solving an optimal scheduling problem in water distribution systems. J. Water Resour. Plan. Manag. 133, 10 (2007) 18. Ostfeld, A., Tubaltzev, A.: Ant colony optimization for least-cost design and operation of pumping water distribution systems. J. Water Resour. Plan. Manag. 134, 107–118 (2008) 19. Wegley, C., Eusuff, M., Lansey, K.: Determining pump operations using particle swarm optimization. In: Joint Conference on Water Resource Engineering and Water Resources Planning and Management, Minneapolis, Minnesota, USA (2000) 20. Ilich, N., Simonovic, S.P.: Evolutionary algorithm for minimization of pumping cost. J. Comput. Civil Eng. 12, 9 (1998) 21. Nemhauser, G.L., Wolsey, L.A.: Integer and Combinatorial Optimization. Wiley-Interscience, New York (1999) 22. Bixby, R.E., Fenelon, M., Gu, Z., Rothberg, E., Wunderling, R.: MIP: theory and practice closing the gap. In: System Modeling and Optimization: Methods, Theory and Applications, Norwell, MA, 2000, pp. 19–50 23. The ILOG CPLEX Website, http://www.ilog.com/products/cplex/ (2009) 24. The Dash XPRESS Website, http://www.dashoptimization.com/home/products/products_optimizer. html (2009) 25. Schrage, L.: Optimization Modeling with LINGO. LINDO Systems Inc., Chicago (2006) 26. Abiri-Jahromi, A., Fotuhi-Firuzabad, M., Abbasi, E.: An efficient mixed integer linear formulation for long term overhead lines maintenance scheduling in power distribution systems. J. IEEE Trans. Power Deliv. 22, 2043–2053 (2009) 27. Carrion, M., Arroyo, J.M.: A computationally efficient mixed-integer linear formulation for the thermal unit commitment problem. IEEE Trans. Power Syst. 21, 1371–1378 (2006) 28. Venkatesh, B., Yu, P., Gooi, H.B., Choling, D.: Fuzzy MILP unit commitment incorporating wind generators. IEEE Trans. Power Syst. 23, 1738–1746 (2008) 29. Boulos, P.F., Lansey, K.E., Karney, B.W.: Comprehensive Water Distribution Systems Analysis Handbook for Engineers and Planners. MWH Soft, Pasadena (2006) 30. Fallside, F., Perry, P.: Hierarchical optimization of a water supply network. Proc. Inst. Electr. Eng. 122, 202–208 (1975) 31. Mennon, E.S.: Piping Calculation Manual. McGraw-Hill, New York (2005) 32. Ulanicki, B., Kahler, J., Coulbeck, B.: Modeling the efficiency and power characteristics of a pump group. J. Water Resour. Plan. Manag. 134, 88–93 (2008) 33. http://www.gouldspumps.com/download_files/3910/35482.pdf. Last Accessed: March 2010 34. Prindle, W.: Customer incentives for energy efficiency through electric and natural gas rate design. In: National Action Plan for Energy Efficiency (2009). http://www.epa.gov/rdee/documents/ rate_design.pdf. Last Viewed: April 2010