You are on page 1of 18

Computers and Chemical Engineering 24 (2000) 2259 2276

www.elsevier.com/locate/compchemeng

Planning and scheduling models for refinery operations


J.M. Pinto a,*, M. Joly a, L.F.L. Moro a,b
a
Department of Chemical Engineering, Uni6ersity of Sao Paulo, Sao Paulo SP, 05508 -900, Brazil
b
PETROBRAS, Petroleo Brasileiro S/A, Brazil

Abstract

The main objective of this work is to discuss planning and scheduling applications for refinery operations. Firstly, the
development of a nonlinear planning model for refinery production is presented. The model is able to represent a general refinery
topology and allows the implementation of nonlinear process models as well as blending relations. Considering the market
limitations for each oil derivative usually supplied by the refinery, the optimization model is able to define new operating points,
thus increasing the production of more valuable products, while satisfying all specification constraints. Real-world applications are
developed for the planning of diesel production in the RPBC refinery in Cubatao (SP, Brazil) among others. The optimization
results were compared to the current situation, where no computer algorithm is used and the stream allocation is made based on
experience, with the aid of manual calculations. The new operating point represents an increase of several million dollars in annual
profitability. The second part of the work addresses scheduling problems in oil refineries that are formulated as mixed integer
optimization models and rely on both continuous and discrete time representations. The problem of crude oil inventory
management that involves the optimal operation of crude oil unloading from pipelines, transfer to storage tanks and the charging
schedule for each crude oil distillation unit will be discussed. Furthermore, the paper will consider the development and solution
of optimization models for short-term scheduling of a set of operations that includes: product receiving from processing units,
storage and inventory management in intermediate tanks, blending in order to attend oil specifications and demands, and
transport sequencing in oil pipelines. Important real-world examples on refinery production and distribution are reported: the
diesel distribution problem at RPBC refinery and the production problems related to the fuel oil/asphalt and LPG areas of the
REVAP refinery in Sao Jose dos Campos (SP, Brazil), which produces approximately 80% of the national consumption. 2000
Elsevier Science Ltd. All rights reserved.

Keywords: Refinery operations; Scheduling applications; Oil refinery

1. Introduction variables but simply consider current operational


conditions.
The 1980s were characterized by the emergence of The optimization of the production units does not
international markets and the development of global achieve the global economic optimization of the plant.
competition. The chemical processing industry had to Usually the objectives of the individual units are confl-
go through severe restructuring in order to compete icting and thus contribute to a sub-optimal and many
successfully in this new scenario. Better economic per- times infeasible overall operation. The lack of computa-
formance has been achieved with a more efficient plant tional technology for production scheduling is the main
operation. obstacle for the integration of production objectives
The implementation of advanced control systems in and process operations. A more efficient approach
oil refineries has allowed significant productivity gains would have to incorporate current and future con-
in the plant units. The resulting savings have created straints in the synthesis of production schedules, trans-
interest for more complex automation systems that late short term production objectives in operating
explicitly take into account production objectives. Unit conditions to the processing units, supply an analysis
optimizers determine optimal values of the process tool for the effect of economical disturbances in the
performance of the production system within a horizon,
* Corresponding author. and provide mechanisms to account for commercial as
E-mail address: jompinto@usp.br (J.M. Pinto). well as technological uncertainties.

0098-1354/00/$ - see front matter 2000 Elsevier Science Ltd. All rights reserved.
PII: S0098-1354(00)00571-8
2260 J.M. Pinto et al. / Computers and Chemical Engineering 24 (2000) 22592276

According to SIPP (1997) that identified the major term schedules that consider time-dependent conditions
needs for tools in production planning and scheduling integrated to the global refining scheme.
in oil refineries, the traditional approach for operations This paper is organized as follows: first, an overview
planning makes use of linear models for generating a of planning and scheduling activities in oil refineries is
feasible plan in a monthly horizon and relies on man- introduced. Developments of representations for non-
ual/spreadsheet calculations. This process, despite re- linear planning models are discussed, followed by the
quiring time and effort from the scheduler, simply optimization work in refinery scheduling with applica-
generates a feasible solution that does not fully exploit tions in crude oil management and scheduling, produc-
solutions which are economically more attractive, not tion and distribution of oil products, such as diesel, fuel
even for sub-areas of the refinery where gains would oil/asphalt and LPG. In particular, the mathematical
clearly improve the operation. The main objective of model for production and distribution of oil dervatives
SIPP (Integrated System for Production Planning), is presented. Finally, conclusions are drawn and current
which is now in the final stage of development, is to as well as future developments are presented.
make the solution generated by a Linear Programming
planning model practicable. Since the operational con-
straints are not present in the LP model, the main goal 2. Overview of planning and scheduling in oil refineries
is to implement a solution, which violates as little as
possible and it is still similar to the LP solution. Ac- The potential benefits of optimization for process
cording to Magalhaes, Moro, Smania, Hassimotto, operations in oil refineries have long been observed,
Pinto and Abadia (1998) important results were already with applications of linear programming in crude
achieved, which are as follows: blending and product pooling (Symonds, 1955). Oil
Centralized information. SIPP is the single platform refineries are increasingly concerned with improving the
that is required for the production scheduler. It is no planning of their operations. The major factor, among
longer necessary to connect to several computers to others, is the dynamic nature of the economic environ-
get a complete view of the current status both of the ment. Companies must assess the potential impact of
refinery and in all the remaining refining plants in important changes such as demands for final product
order to develop a new schedule. specifications, prices, and crude oil compositions or
Increase of the scheduling horizon. Since the system even be capable to explore immediate market opportu-
allows access to future projections (demands, oil nities (Magalhaes et al., 1998). Coxhead (1994) iden-
extraction, tanker arrivals, etc.), the scheduler has tifies several applications of planning models in the
the opportunity of working with longer horizons. refining and oil industry, including: crude selection,
This horizon was normally restricted to three days crude allocation for multi-refinery situations, partner-
and currently has been raised to 7 days. ship models for negotiating raw material supply and
What-if analysis. With the implementation of the operations planning.
system it will be possible to react more quickly to The availability of LP-based commercial software for
unexpected situations through cause and effect refinery production planning, such as RPMS (Refinery
analysis. and Petrochemical Modeling System Bonner &
Knowledge preser6ation. This may be considered the Moore, 1979) and PIMS (Process Industry Modeling
most important aspect brought by the system that System Bechtel, 1993) has allowed the development
resulted in a better understanding of the scheduling of general production plans of the whole refinery,
problem. which can interpreted as general trends. As pointed out
The main benefits of the system will be perceived by Pelham and Pharris (1996), the planning technology
from the implementation of models and algorithms that can be considered well developed and relevant progress
will support the production scheduler. Among these, should not be expected. The major advances in this
the goal is to develop and implement mathematical area will be based on model refinement, notably
programming models based on mixed integer optimiza- through the use of nonlinear programming, as recently
tion algorithms. in Picaseno-Gamiz (1989) and Moro, Zanin and Pinto
The objective of this paper is to describe the ap- (1998).
proach taken in the development of optimization mod- Bodington (1992) also mentions the lack of system-
els for production planning and scheduling for oil atic methodologies for handling nonlinear blending re-
refineries. The plant is divided into sub-systems, which lations. Despite that, progress in nonlinear
although coupled, allow the development of representa- programming in the nineties (Viswanathan & Gross-
tion of the main scheduling activities within relevant mann, 1990; Porn, Harjunkoski & Westerlund, 1999)
time horizons. The final objective is to develop strate- allowed that many authors, such as Ramage (1998),
gies for incorporating these models in an automated refer to nonlinear programming (NLP, MINLP) as a
planning and scheduling system that generates short necessary tool for the refineries of the 21st-century. The
J.M. Pinto et al. / Computers and Chemical Engineering 24 (2000) 22592276 2261

pooling problem is studied by Fieldhouse (1993), who management and planning and distribution (Bodington,
solves simultaneously the mass balance equations and 1995). The importance of on-line integration of plan-
quality relations with successive linear approximation. ning, scheduling and control is pointed out by Boding-
On the other hand, commercial tools for production ton and Shobrys (1996) and Steinschorn and Hofferl
scheduling are few and these do not allow a rigorous (1997). Mansfield, Maphet, Bain, Bosler and Kennedy
representation of plant particularities (Rigby, Lasdon & (1993) discuss the issue of integration of process con-
Waren, 1995; Moro et al., 1998). For that reason, trol, optimization and planning activities in gasoline
refineries are developing in-house tools strongly based blending.
on simulation (Steinschorn & Hofferl, 1997; Magalhaes
et al., 1998) in order to obtain essential information for
a given system (Moro & Pinto, 1998). In the literature 3. Planning models
there are specific applications based on mathematical
programming, such as crude oil unloading and gasoline The work focus on the development of nonlinear
blending (Bodington, 1992; Rigby et al., 1995; Lee, planning models for refinery production. Planning ac-
Pinto, Grossmann & Park, 1996; Shah, 1996). The lack tivities involve optimization of raw material supply,
of rigorous models for refinery scheduling is also dis- processing and subsequent commercialization of final
cussed by Ballintjin (1993), who compares continuous products over one or several time periods.
and mixed-integer linear formulations and points out to Moro et al. (1998) developed a nonlinear planning
the low applicability of models based only on continu- model for refinery production that is able to represent a
ous variables. general refinery topology. The model relies on a general
More generally, the scheduling literature presents representation for refinery process units in which non-
very few optimization based formulations for the linear equations are considered. The unit models are
scheduling of continuous multiproduct plants, as op- composed of blending relations and process equations.
posed to the large amount of work in batch plants Also, the unit variables must satisfy bound constraints,
(Reklaitis, 1992; Pinto & Grossmann, 1998). Nowa- which consist of product specifications, maximum and
days, due to need for moving towards flexible plants, minimum unit feed flowrates and limits on operating
which must promptly respond to market requirements, variables. Fig. 1 shows the representation of a typical
continuous processing has received more attention (Ier- unit. The model of a typical unit u is represented by the
following equations:
apetritou & Floudas, 1998). Examples of planning and
Feed flowrate:
scheduling of continuous multiproduct plants are pre-
sented for the single stage (Sahinidis & Grossmann,
Qu,F = % % Qu%,s,u (1)
1991) and multistage case (Pinto & Grossmann, 1994). u%  Uu s  Su %,u
It has also been recognized that the integration of
Feed properties:
new technologies for process operations is an essential
profitability factor and that it can only be achieved Pu,F, j = fj (Qu%,s,u, Pu%,s, j ) u% Uu, sSu%,u, jJs (2)
through appropriate planning (Cutler & Ayala, 1993;
Total flowrate of each product stream:
Macchietto, 1993). According to a recent survey of
hydrocarbon processing companies, it is pointed out by Qu,s = f(Qu,F, Pu,F, j, Vu ) jJF, sSU (3)
management that among the main areas for integration
Unit product stream properties:
there are: sales and planning, planning and operations
Pu,s, j = fj (Pu,F, j, Vu ) jJs, sSU (4)
Product stream flowrates (splitter):

Qu,s = % Qu,s,u% sSU (5)


u%  Us,u

Eqs. (1) and (2) represent the mixing of the feed


streams. These are defined by the sets Uu and Su%,u
which denote the units u% whose destination is u and the
streams leaving unit u whose destination is unit u,
respectively. The properties of the resulting feed stream
are nonlinear functions of the entering feed streams as
well as each property jJs, where Js is the set of
properties relevant to stream s.
The process model is defined in Eqs. (3) and (4),
Fig. 1. Typical process unit. which relate the product flowrate and properties to the
2262 J.M. Pinto et al. / Computers and Chemical Engineering 24 (2000) 22592276

Fig. 2. Schematic representation of the RPBC diesel production plant.

flowrate and properties of the feed stream as well as to operation cost of each unit, yielding:
the operating variables. In general, the process model
may be a simple yield relation or a complex system of
Pr= % CpuQu,p % CFuQu,F


equations based on conservation principles and consti- u  Up u  UF
tutive relations.
Usually, mass balances and yield expressions are used % Cru + % C6u,oVu,o Qu,F
n (6)
uU o  Vu
to determine product flow rates; energy balances are
not included in the model. The mass balance in a unit The revenue from products is defined over all prod-
may not satisfied due to material losses and to the ucts generated in the units in Up, which is the set of
possible existence of streams that are not modeled, in units that generate finished products. The feed costs are
the event that they are irrelevant to the model in also defined over the set of units that are fed by
question. Yield expressions are based on a standard external streams, Uf. The cost of operation per unit feed
value, which is determined over average values ob- stream in each processing unit depends (linearly) on the
tained from plant data. The effect of the feed properties operating variables of all units (U).
as well as those of the operating variables is applied A real-world application was developed for the plan-
over the standard yield, in the form of gains, also ning of diesel production in the RPBC refinery in
determined experimentally. Most of the physical prop- Cubatao (SP, Brazil), as illustrated in Fig. 2. The
erties are calculated from mixing indexes, which are refinery has as main objective the production of diesel
based on correlations. Likewise, the effect of the feed fuel with different specifications and demands shown in
and operating variables in the properties of the product
streams is computed through gains. Table 1
Note that the operating variables are defined as Diesel specifications
continuous. Nevertheless, if a given unit runs under
Property Diesel
different operating modes (campaigns), these could be
represented by discrete variables. An additional Regular Metropolitan Maritime
difficulty in this case is that the resulting planning
model would be a (nonconvex) MINLP. Density 0.82/0.88 0.82/0.88 0.82/0.88
In (5), since each product streams may have multiple (min/max)
Flash point (min) 60.0
destinations, a simple balance is imposed in each of
(C)
these streams. These are either sent to the final product ASTM 50% 245.0/310.0 245.0/310.0 245.0/310.0
pool or sent to another processing unit. Additionally, (min/max) (C)
operational bound constraints are imposed on the ASTM 85% 370.0 360.0 370.0
flowrates due to market limitations as well as on the (max) (C)
Cetane number 40.0 42.0 40.0
properties because of product specifications.
(min)
The objective is to maximize the profit (Pr) of the Sulfur content 0.5 0.3 1.0
refinery, defined as the sales revenue, the sum of feed (max) (% wt.)
costs and the total operating cost, which is the sum of
J.M. Pinto et al. / Computers and Chemical Engineering 24 (2000) 22592276 2263

Table 2
Main results for the diesel production problem

Diesel Current operation Optimal

Regular Metropolitan Maritime Regular Metropolitan Maritime

Total flow rate (m3/d) 4878 5500 3500 3877 7000 2999
Properties
Density 0.880 0.880 0.860 0.871 0.880 0.869
Flash Point (oC) 66.8 61.8 79.5 88.0 60.5 70.0
ASTM 50% (oC) 291.0 282.2 270.3 292.9 283.0 267.0
ASTM 85% (oC) 369.7 357.0 354.1 370.0 360.0 350.2
Cetane number 41.9 42.0 40.5 41.9 42.0 40.3
Sulfur content (% wt.) 0.29 0.20 0.38 0.45 0.20 0.21

Table 1. These are as follows: Metropolitan diesel (low 4. Scheduling in oil refineries
sulphur levels), regular diesel and maritime diesel (high
flashing point). The process includes crude distillation As previously mentioned, the work has focused on
units, vacuum distillation units, fluid catalytic cracking the development of optimization models and solution
unit, coking unit, hydrotreating unit and diesel pools. methods for refinery sub-systems. This is mainly due to
The processing units operate in steady state and pro- the complexity of scheduling operations, which are
duce a variety of intermediate streams, with different translated into large-scale combinatorial problems (NP-
properties, that can be blended to generate the desired Complete, at least), and limitations in computing tech-
kinds of diesel fuel. nology. One of the major issues has been on time
The modeling system GAMS (Brooke, Kendrick & representation. Parallel research has been conducted on
Meeraus, 1992) was used to implement the optimization both discrete and continuous time models. Another
model, which contains 233 variables, 199 equations and important aspect that is under investigation concerns
620 non-linear non-zeroes and was solved with compatibility between planning and scheduling models.
CONOPT, based on a feasible path generalized reduced We address scheduling problems in oil refineries,
gradient method. The optimization results were com- which are formulated as mixed integer optimization
pared to the current situation, where no computer models and rely on both continuous and discrete time
algorithm is used and the stream allocation is made representations. Although in general continuous time
based on experience, with the aid of manual calcula- formulations provide substantial reductions on the
tions. Considering the market limitations for each kind combinatorial feature of a model, the use of a discrete
of diesel oil usually supplied by the refinery, the opti-
time representation may still be attractive since:
mization algorithm was able to define a new point of
Resource constraints under discrete time representa-
operation, increasing the production of more valuable
tion are much easier to handle. For instance, inven-
oil, while satisfying all specification limits. A summary
tory constraints in continuous time are inherently
of the main results in shown in Table 2. For example,
nonlinear (and nonconvex) due to the bilinear terms
the refinery produces approximately 5500 m3/d of
involving flowrates and time intervals. In order to
metropolitan diesel, while the market could absorb up
to 7000 m3/d. Since this is the most valuable diesel, it is avoid the solution of non-convex models, lineariza-
clear that there is room to increase the refinery profit. tion techniques are frequently used. Consequently,
The refinery also produces 3500 m3/d of maritime the performance of the solution method may deterio-
diesel, a low-valued product, while the minimum rate rate due to a significant increase in the integrality
due to commercial agreements is 3000 m3/d. This situa- gap of the linearized models. This fact (observed in
tion arises because this kind of diesel is relatively easy Section 4.1, for instance) is undesirable, mainly in
to produce, since it has less restrictive specifications. the case of complex industrial processes where a
This new operating point represents an increase in feasible schedule is often imperative.
profitability of approximately US$ 6 000 000 per year. If the execution times involved in the problem are of
Currently an application is under development for the same order of magnitude, the size of the resulting
the overall production planning at the REVAP refinery discrete model is less dependent on the scheduling
based on the generalized model representation. Several horizon and can be solved in reasonable time.
processing units are modeled, such as atmospheric dis- Discrete time models provide in general tight formu-
tillation, vacuum distillation, fluid catalytic cracking, lations, which means that they present a relatively
hydrotreating and deasphalting. low integrality gap (Xueya & Sargent, 1996).
2264 J.M. Pinto et al. / Computers and Chemical Engineering 24 (2000) 22592276

Therefore, in light of the above arguments, Sections 4.2 where oil tankers unload. The unloading schedule of
and 4.3 will be founded in discrete representation. these oil tankers is usually defined at corporate level
The problem of crude oil inventory management and cannot be easily changed. Thus, for a given
(Section 4.1) involves the optimal operation of crude oil scheduling horizon, the number, type, start and end
unloading from pipelines, transfer to storage tanks and times of the oil parcels are known a priori. In the
the charging schedule for each crude oil distillation unit pipeline, adjacent crude oil types share an interface,
is formulated and solved with a continuous time repre- which has to be properly handled. If these adjacent
sentation. Furthermore, the paper will consider the batches of oil (known as parcels) present significantly
development and solution of optimization models for different properties, it becomes necessary to take into
short-term scheduling of a set of operations that in- account this mixing that always occur within the
cludes: product receiving from processing units, storage pipeline, which causes the degradation of part of the
and inventory management in intermediate tanks, higher quality oil. Therefore it is necessary to send this
blending in order to attend oil specifications and de- mixed oil either to storage together with the oil of lower
mands, and transport sequencing in oil pipelines. The quality or to a tank assigned to receive such mixtures.
mathematical formulation for such a problem is pre- This operation is called interface separation and the
sented. Important real-world examples on refinery pro- volume of this interface is defined based on prior
duction and distribution are reported. The diesel experience.
pooling and distribution problem at the RPBC refinery In the refinery the crude oil is stored in cylindrical
is solved (Section 4.2). Production problems related to floating-roof tanks, with a total capacity in the range of
the fuel oil/asphalt (Section 4.3) and LPG (Section 4.4) tens of thousands cubic meters, which is usually suffi-
areas of the REVAP refinery in Sao Jose dos Campos cient for a few days of refinery operation. Floating roof
(SP, Brazil), which produces approximately 80% of all tanks provide much smaller loss of volatile petroleum
fuel oil consumed in Brazil, are also reported. In the components than the usual fixed roof tanks; on the
LPG problem, an optimization model that is an exten- other hand they demand a minimum product volume of
sion of the generalized planning model is proposed. about 20% of total capacity so to avoid damaging the
floating device. The crude oil must be stored in these
tanks for a certain amount of time until it can be
4.1. Crude oil scheduling
processed in the distillation units. There is a minimum
amount of time to allow the separation of the brine that
This work addresses the problem of crude oil inven-
forms an emulsion with the oil. Thus it is not possible
tory management of a real world refinery that receives
to feed the distillation units directly from the pipeline,
several types of crude oil, which are delivered by an oil
even if an intermediate tank is used. It is possible to
pipeline (Moro & Pinto, 1998). The system consists of a
transfer oil among tanks, although such operations are
crude oil pipeline, a series of storage tanks and distilla-
seldom performed, since they are lengthy and it is
tion units. As in Lee et al. (1996) and Shah (1996), the
usually simpler to blend two or more tanks while
problem involves transfers from the pipeline to the
feeding the distillation units.
crude tanks, internal transfers among tanks and charges
If the oil quality in a given tank and the distillation
to the crude distillation units. The processing time of
unit operating conditions are not compatible, it is nec-
the tasks involved may vary from few minutes to
essary to process it simultaneously with the oil from
several hours.
another tank. This situation may arise if a certain crude
Typically, an oil refinery receives its crude oil
oil is too heavy, in which case there will not be enough
through a pipeline, which is linked to a docking station,
product in the distillation tower top section to produce
a proper amount of internal reflux, or if the crude is too
light, which may cause difficulties in pressure control.
As a rule, these properties are known a priori by the
refiner and can be correlated to the petroleum origin.
On the other hand, it is mandatory that the distillation
units be fed with an oil flow rate as close as possible to
a target value, defined at the corporate planning level,
to maximize production and, consequently, profit. It is
imperative that oil feeds such units continuously, be-
cause a shutdown is a very costly and undesirable
operation.
In this work we analyze the problem of generating an
optimal schedule for crude oil operations for a refinery
Fig. 3. Refinery crude system. petroleum system described in Fig. 3, which includes
J.M. Pinto et al. / Computers and Chemical Engineering 24 (2000) 22592276 2265

Fig. 4. Oil parcel scheduling.

receiving oil from pipeline, transferring oil among of ten different types of crude oil in seven crude storage
tanks, waiting for the brine to be separated, and feeding tanks and a distillation capacity of 200 000 barrels per
the distillation units. These decisions are taken with the day. We study an example derived from the actual
objective of maximizing the operating profit by maxi- refinery situation. The total time horizon spans 112 h,
mizing production while minimizing the number of during which four completely defined oil parcels have
tanks used. to be received from pipeline. Six oil tanks are available,
Firstly, a discrete time mixed integer optimization all of them with the same capacity, but with different
model is proposed for the generation of a plan for amounts and qualities of oil in the beginning of the
refinery crude oil management. However, this model time horizon. We consider three different kinds of oil,
has computational limitations since it results in an Bonito, Marlin and RGN. The distillation unit has a
unnecessary increase of the number of 0 1 variables, as target feed flow rate of 1500 m3/h during the entire time
in Kondili, Pantelides and Sargent (1993). This fact horizon.
makes the model solution unattainable for a relevant The distribution of the oil parcels during the time
scheduling horizon, which is at least of 3 4 days. horizon is shown in Fig. 4, which also shows the
To circumvent this difficulty, we develop an alternate sub-periods and the number of time slots defined for
model with variable length time slots, which represent each one of them. More detailed information on the oil
crude oil receiving operations as well as periods be- parcels can be found in Table 3.
tween two receiving tasks (Moro & Pinto, 1998). The Table 4 describes the oil tank initial conditions. All
system generated by this model is capable of creating a tanks are considered to be adequately prepared to feed
short-term schedule, with a horizon of approximately 1 the distillation unit, i.e. settling has already taken place.
week that takes into account volume and quality con- The tanks have the same dimensions and their capacity
straints as well as operational rules. These rules involve,
among others, minimum time for crude utilization, due Table 3
to brine settling. There are also operational constraints Oil parcel scheduling
such as the one that imposes that just one tank receives
at the same time but several can feed the columns Oil parcel Volume of Start time End time Composition
oil (m3) (h) (h)
simultaneously and the requirement that a tank cannot
receive and send oil at the same time. Inputs to the 1 60 000 8 20 100%
problem are the crude arrival schedule, which describes Bonito
the volumes and qualities of the crude oils to be re- 2 50 000 48 58 100%
ceived in the refinery within the desired horizon; the Marlin
3 1000 58 58.2 100%
crude demands and the current levels and qualities of Marlin
crude oil in the storage tanks. A critical decision con- 4 60 000 100 112 100% RGN
cerns the calculation of crude properties for blended
streams. These properties are normally represented by
indexes, which are linear on a volumetric basis. Never- Table 4
theless, indexes are nonlinear functions of the proper- Initial conditions of oil tanks
ties. Based on this information, a schedule is generated, Tank Volume (m3) Composition
which describes the main decisions such as: feed strat-
egy from the storage tanks to the distillation units as 01 40 000 50% Bonito, 50% Marlin
well as internal transfers among tanks along the 02 50 000 100% Marlin
scheduling horizon. 03 15 000 70% Bonito, 30% RGN
04 50 000 100% Marlin
A real-world application is developed for the 05 20 000 60% Bonito, 40% RGN
scheduling of crude oil in the REVAP refinery in Sao 06 15 000 60% Bonito, 30% Marlin, 10%RGN
Jose dos Campos (SP, Brazil) that receives in the order
2266 J.M. Pinto et al. / Computers and Chemical Engineering 24 (2000) 22592276

Fig. 5. Receiving and sending operations during time horizon.

is 80 000 m3 while the minimum operating volume is includes charging pipelines from U crude distillation
13 000 m3. The minimum settling time is defined as 24 h units (CDUs) to storage area, I storage tanks (where
and this is the minimum time necessary for brine sepa- I= 2U) and J oil pipelines that may transport P grades
ration after a tank receives oil from pipeline. of products, as well as all their interconnections. The
The problem so defined, with 19 time slots, four oil processing in the CDUs, which operate continuously
parcels, six tanks and three kinds of oil, generates an during the scheduling horizon, is sent by charging
MILP problem with 912 discrete variables and 5599 pipelines in such mode that each pipeline transports
equations, which was solved using OSL (IBM, 1991), only one kind of product, denoted primary product, to
embedded in the GAMS software (Brooke et al., 1992). the storage area where there are two dedicated tanks.
The problem solution can be seen in Fig. 5. It is clear Each tank stores only one kind of product and due to
that the constraints of minimum settling time and the operational reasons it is not allowed that storage tanks
demand that the distillation unit always be fed are load and unload simultaneously; therefore, when one
honored. tank unloads the stream from CDU must be directed to
If the fixed time slot duration approach were used in the other one.
this same problem, we would be forced to define a slot All properties of the stored hydrocarbon are the
duration of 15 min, which would generate a MILP same as those obtained in the CDU, and thus known.
problem with 21504 binary variables. The solution of The distribution of the primary products is done by J
such a problem is far beyond the capabilities of current oil pipelines that transport these pure products or their
mixed integer optimization technology. blends, both denoted final products, in order to achieve
the specification relative to the composition of key-
components. Mixed-integer constraints are proposed
4.2. Production and distribution
that take into account transitions among products in oil
pipelines. Each oil pipeline supplies only one consumer
A typical oil refinery produces several streams, whose
market where there is a demand known a priori, along
major specifications are based on their physical and/or
the scheduling horizon, for different grades of final
chemical properties such as flash point, composition of
key components, density and/or viscosity, among oth-
ers. These streams are usually blended in order to
satisfy final product specifications and further sent to
consumer markets, in agreement with the foreseen ne-
cessities throughout the scheduling horizon. The refin-
ery model addressed in this work assumes the existence
of several processing units, which generate several
streams that are differentiated only by the composition
of their key elements, (e.g. sulfur and lead content).
After processing, these streams are stored in intermedi-
ate tanks and further sent through oil pipelines as final
product or mixed with others aiming to produce a
desired blend. The system is shown in Fig. 6, which Fig. 6. General scheme of scheduling problem.
J.M. Pinto et al. / Computers and Chemical Engineering 24 (2000) 22592276 2267

Table 5 6. all products have the same (constant) density and


Nomenclature
their blends constitute an ideal solution;
Indices and sets 7. changeover times are neglected.
i =1, , I tanks; j =1, ..., J pipelines; p (or n)= 1 ,..., P A remark should be made on assumption (4), whose
products; k= 1, ..., K key-comp.; t= 1, , T time; u= 1,...,U main objective is to reduce computational time. Al-
CDUs though this assumption could be in principle relaxed,
Binary 6ariables since transition costs would tend to penalize solutions
XWi,t : denotes if tank i is loading at time t; DDi,j,t : denotes if with many changeovers, it would incur in a much larger
tank i feeds oil pipeline j at time t; XDIj,p,t /XDFj,p,t : denotes if combinatorial problem. Nevertheless, it is recognized
there was the start/end of transport of product p by oil
pipeline j at time t; DOj,p,t : denotes if oil pipeline j transports
that the global optimal solution may be affected in
product p at time t; TRANj,p,n : denotes if there was transition cases that inventory levels are high (it would be neces-
from product p to n in oil pipeline j during the horizon; sary to unload more than once along the horizon)
TRANSj,p,n : auxiliary variable for transition modeling and/or storage is expensive (higher operating costs).
Continuous 6ariables Note that the values of flowrate bounds in Table 5
FVSi,t : volumetric flowrate from CDU to tank i at time t; VSi,t : should be specified in agreement with the time span
volume of tank i at time t; FSBi,j,t : volumetric flowrate from adopted.
tank i to oil pipeline j at time t; FOj,p,t : volumetric flowrate of
product p in oil pipeline j at time t; TDIj,p /TDFj,p : initial/final
transport time of product p in oil pipeline j
Maximize:
Profit= sales revenue raw material cost pumping
Parameters
costinventory cost transition cost.
PRp : revenue per unit volume of final product p; CRMi : cost per
unit volume of raw material in tank i; CPi : pumping cost from J P T
tank i to any oil pipeline j per flow unit; CINVi : inventory cost Profit= % % % (PRp FOj,p,t )
of tank i per unit volume and time; CHANGEp,n : transition j=1 p=1 t=1
cost between final products p and n (p to n); I J T
FVSMAXi /FVSMINi : max/min volumetric flowrate from CDU % % % [(CRMi + CPi ) FSBi, j,t ]
to tank i; VSMAXi /VSMINi : capacity bounds of tank i; i=1 j=1 t=1
VSZEROi : initial volume of tank i; DMj,p : volumetric demand I T
of product p by oil pipeline j; FSBMAXi,j /FSBMINi,j : % % (CINVi VSi,t )
max/min volumetric flowrate from tank i to oil pipeline j; i=1 t=1
FOMAXj /FOMINj : max/min volumetric flowrate in oil pipeline J P N
j; ESi,k : composition of key-element k in tank i; Cp,k : % % % (TRANj,p,n CHANGEp,n ) (7)
specification of product p in key-element k; NTRANj : total j=1 p=1 n=1
number of transitions in oil pipeline j; NTj,p : 01 parameter
that denotes the existence of demand for p in oil pipeline j Subject to:
1. Material balance constraints
Volumetric balances are developed in (8a) and vol-
products that are discerned only by the composition of umes of all storage tanks are bounded in (8b).
the key-elements.
t

VSi,t = VSZEROi + % FVSi,t % (FSBi, j,t )
J
n
t=1 j=1
4.2.1. Mathematical formulation i= 1,, I t= 1, , T (8a)
The model is based on a uniform discretization of
time and relies on the following assumptions: VSMINi 5 VSi,t 5 VSMAXi
1. each oil pipeline j can be simultaneously fed by one
or more storage tanks, aiming to generate on line i= 1, , I; t= 1, , T (8b)
the oil blends with correct key-composition;
Constraint (9a) enforces the global balance for the
2. each storage tank i feeds at most NCi oil pipelines
blending streams, while in (9b) the key-component bal-
simultaneously and connects with any oil pipeline j;
ances are done, whose specifications are exactly im-
3. the oil mixing properties are calculated by a
posed or may also be stated as lower/upper bounds.
weighted relation based on the properties of the
original streams; P I

4. the expedition of final products by any oil pipeline % (FOj,p,t )= % (FSBi, j,t )
p=1 i=1
occurs only once throughout the scheduling horizon
(i.e. in a single batch); j =1, , J; t= 1, , T (9a)
5. material losses due to undesirable mixing that oc- p I
curs within the oil pipeline when there is a transport % (Cp,k FOj,p,t )= % (FSBi, j,t ESi,k )
P=1 i=1
changeover of two final products incurs on a transi-
tion cost, which is sequence dependent; j= 1, , J; k= 1, , K; t= 1, , T (9b)
2268 J.M. Pinto et al. / Computers and Chemical Engineering 24 (2000) 22592276

2. Demand constraints pipelines) must satisfy upper and lower flow bounds
The plant must also satisfy the foreseen demands in due to pumping limitations, as stated by constraints
each market. In (10), demand must be exactly met, but (12a2c).
may also be enforced as a lower/upper bound.
FVSMINi XWi,t 5 FVSi,t 5 FVSMAXi XWi,t
T
DMj,p = % (FOj,p,t ) j = 1, , J; p = 1, , P i= 1, , I; t= 1, , T (12a)
t=1
(10) FSBMINi, j DDi, j,t 5 FSBi, j,t 5 FSBMAXi, j DDi, j,t
3. Operating rules i= 1, , I; j= 1, , J; t= 1, , T (12b)
Constraints (11a b) state that it is not allowed that
storage tanks load and unload simultaneously and im- FOMINj DOj,p,t 5 FOj,p,t 5 FOMAXj DOj,p,t
pose that tank i feeds at most NCi oil pipelines at every j= 1, , J; p= 1, , P; t=1, , T (12c)
time.
5. Transition relations
XWi,t + XWi + 1,t = 1 i =1,3,5, ; t =1,, T
Constraint (13a) imposes that if oil pipeline j trans-
(11a)
ports product n later than product p, it is possible that
J
there is a transition from product p to n (denoted by
NCi XWi,t + % (DDi, j,t ) 5 NCi
j=1
TRANSj,p,n = 1). This is a necessary, but not sufficient
condition. Otherwise, constraint (13c) sets TRANSj,p,n
i = 1, , I; t= 1, , T (11b)
to zero if product n is transported earlier than product
Expedition of final product p by oil pipeline j occurs at p. Note that TRANSj,p,n indicates only the potential
most once during the scheduling horizon (i.e. a single transition from p to n, but this transition may not take
batch). If this process begins, it must finish before the place even when TRANSj,p,n = 1. Consider the case that
end of the period, as in (11c). Moreover, in (11d) the oil pipeline j transports products A, B and C in this
start time must precede its end. order. From (13a): TRANSj,A,B = TRANSj,A,C =
T T TRANSj,B,C = 1. However, it is clear that are only
% (XDIj,p,t )5 1 and % (XDIj,p,t XDFj,p,t ) =0 transitions from A to B and from B to C.
t=1 t=1
TRANSj,p,n ] (TDIj,n TDIj,p )/(T)
j= 1, J; p=1, , P (11c)
T T n" p; p=1, , P; j =1, , J (13a)
% (t XDIj,p,t )= TDIj,p 5TDFj,p = % (t XDFj,p,t )
t=1 t=1 TRANSj,p,n = 0 n= p; j= 1, , J (13b)
j= 1, J; p=1, , P (11d) T (TRANSj,p,n )5 (TDIj,n TDIj,p )
Product p is sent by oil pipeline j only between TDIj,p j= 1, , J; p= 1, , P; n= 1, , N (13c)
and TDFj,p as in (11e).
t Note that P= N. Constraints (13df) impose that a
DOj,p,t = % (XDIj,p,t XDFj,p,t ) transition from product p to n (n, n" p) and vice-
t=1 versa occurs at most once. The sum of all binary
j =1, , J; p=1, , P; t = 1, , T (11e) variables TRANj,p,n, which truly denote the occurrence
of transition from product p to n in oil pipeline j, must
It is not allowed that storage tank i(i ) unloads to oil match the total number of transitions, NTRANj, as in
pipeline j at time t if this oil pipeline must not transport (13h).
products in this moment as stated by constraint (11f).
P ! P
NTRANj = max 0, % (NTj,p ) 1
"
DDi, j,t 5 % (DOj,p,t ) p=1
p=1

i = 1, , I; j =1, , J; t =1, , T (11f) where the first argument of the max operator accounts
for the case that no product is sent through oil pipeline
Additionally, in (11g) each oil pipeline at each time t j during the scheduling horizon and the second argu-
can transport at most one final product. ment denotes that the number of transitions depends on
P the number of products sent. In the previous case of A,
% (DOj,p,t )51 j =1, , J; t =1,, T (11g) B and C sent through pipeline j, we have p (NTj,p )=3
p=1
and therefore NTRANj = 2, i.e. two transitions occur.
4. Flowrate constraints NTj,p is a 01 parameter that is activated by the
All streams (from CDUs to storage tanks, from modeling if there is demand of product p in market fed
storage tanks to oil pipelines and those within the oil by j.
J.M. Pinto et al. / Computers and Chemical Engineering 24 (2000) 22592276 2269

TRANj,p,n 5TRANSj,p,n should be obtained by proper dilution since no rigorous


control related to the composition of key-elements is
j = 1, , J; p=1,, P; n= 1, , N (13d)
done in CDU2. The metropolitan diesel storage tanks
N
may feed at most two oil pipelines simultaneously and
% (TRANj,p,n )51 j= 1, , J; p =1, , P
n=1 the remaining ones only one pipeline.
(13e) The modeling system GAMS (Brooke et al., 1992)
P was used in order to implement the optimization model
% (TRANj,p,n )51 j= 1, , J; n =1, , N and its solution method. The branch and bound code
p=1
OSL (IBM, 1991) was utilized to solve this MILP
(13f )
model, which contains 2252 continuous variables, 1278
P N
01 variables and 3065 constraints. In order to reduce
% % (TRANj,p,n )= NTRANj j= 1, , J (13g)
p=1 n=1 the computational expense, the relative optimality crite-
rion was set to a non-zero value and valid constraints
4.2.2. Real-world application were included in the model to reduce the size of the
A real-world example is presented that is based on search tree providing significant timesaving. The model
Moro et al. (1998) (see Section 3), who studied the solution provides, at each time of the scheduling hori-
diesel production planning problem at the PETRO- zon, flowrates of all streams as well as the schedule for
BRAS RPBC refinery in Cubatao (SP, Brazil). The tank loading and unloading, all information for the
system includes three CDUs, six storage tanks and mixing process, volumes in all tanks and operation
three oil pipelines and was solved for a scheduling schedule for oil pipelines. The optimal schedule for this
horizon of one day, at every hour. The plant produces real-world distribution problem is shown in Fig. 7.
three diesel grades: metropolitan (p = 1), regular (p= 2)
and maritime diesel (p =3) as shown in Table 6. It is 4.3. Fuel oil/asphalt production
assumed that the relevant properties are the sulfur
content (k= 1) and the cetane number (k = 2). The Although some authors such as Rigby et al. (1995)
remaining properties are not changed when different mention that in general the optimization of fuel oil area
oils are mixed. Since metropolitan is the most valuable does not provide fruitful gains in terms of refinery
diesel and adding the fact that its demand can be profitability, this may not always be the case. For
accepted as unlimited, its distribution must be maxi- instance, for the REVAP refinery this area is singular
mized in order to increase the refinery profitability. This since (Magalhaes et al., 1998):
problem works with lower and upper limits for the there are significant storage limitations in the fuel oil
specification of two key-components in question and area;
also allows flexibility to determine the metropolitan the Brazilian oil sector is under a gradual end of 43
diesel demand, which has a lower bound of 5000 m3/d. year-old monopoly of the PETROBRAS (started in
It is also assumed that regular diesel specification 1992), fact mentioned by Hartveld (1996) as respon-

Fig. 7. Optimal operation schedule for the diesel example.


2270

Table 6
System information for the diesel example

Storage tank Key-cp.1 S (% weight) Kep-cp.2 cetane n. Storage limits Unload limits (m3/h) Invent cost ($/vol.t) Pump cost ($/vol.t)
(m3)
i = 1/i= 2 0.3/0.3 42.0/42.0 200030 000 30500 0.10/0.10 0.20/0.20
i = 3/i= 4 $ 0.6/0.4 $ 40.3/39.0 200030 000 40500 0.12/0.12 0.18/0.18
i= 5/i=6 1.0/1.0 40.0/40.0 200030 000 40500 0.11/0.11 0.16/0.16
Primary products Key-comp.1 S Key.comp.2 (cetane Prod. Rate Vol. cost ($/vol.) Oil pipeline Flowrate bounds
(% weight) n.) (m3/h) (m3/h)
a=1 (from 0.3/0.3 42.0/42.0 250300 0.60 j =1 50400
u=1)
a=2 (from $0.6/0.4 $ 40.3/39.0 220250 0.40 j=2 50400
u=2)
a=3 (from 1.0/1.0 40.0/40.0 180200 0.05 j =3 50250
u=3)
Diesel Sulfur (% wt.) Cetane number Sale pr. ($/vol.) Demand (103 m3) in Transition cost between final products p/n
specifications j =1/2/3 (p to n) ($)
p= 1 50.30 ]42 0.90 ]5.0/1.0/0.0
p= 2 50.50 ]40 0.50 4.0/1.0/1.0 1/2 1/3 2/1 2/3 3/1 3/2
p=3 51.00 ]40 0.10 0.0/1.5/2.0 1.1 1.0 1.3 1.2 1.9 1.9
J.M. Pinto et al. / Computers and Chemical Engineering 24 (2000) 22592276
J.M. Pinto et al. / Computers and Chemical Engineering 24 (2000) 22592276 2271

Fig. 8. Schematic representation of the plant.

sible for the new extraordinary business opportuni- pure LCO from UFCC as diluent. The UDASF pro-
ties in Brazil. More specifically, fuel oil monopoly duction must also satisfy a minimal demand of pure
was recently broken (May, 1999); RASF to the refinery oil-header (roh). The major spe-
a substantial amount of the plant production is cification of all final products is the viscosity range,
dispatched by oil pipelines, which operate intense which has to be adjusted by proper dilution with avail-
flux among refineries of the state of Sao Paulo; able diluents. The OCC and the HG streams are totally
the plant is responsible for approximately 80% of all utilized to supply the plant necessities; the HG stream is
fuel oil consumed in Brazil. directed to storage in tank TK-42221 and the OCC
In this context, the present work considers the short- stream from UFCC is directly utilized for RASF dilu-
term scheduling of fuel oil and asphalt production with tion or directed to storage in TK-42208 (which contains
operations management, which include mixing, storage LCO and OCC mixed) once is not permitted that two
and distribution. A set of final products is diluted and operations occurs simultaneously. Unlike the above
sent to intermediate storage tanks, and may undergo described, the LCO stream must be directed to the
further eventual corrections in dilution rates previous to plant only when necessary, i.e. when is desired to
its distribution to the consumer market, whose demand charge the storage tank TK-42208 or when UVO1 (or
is determined from refinery planning. The objective is UVO2) must be produced. In this case, to assert that
the development of an optimization model which is able pure LCO is being utilized to dilute RASF, the TK-
to define the production schedule of a real world prob- 42208 level must increase at a proper rate while pure
lem at the PETROBRAS REVAP Refinery, located in LCO flows in the dilution line (see Fig. 8). A priori, the
Sao Jose dos Campos (SP, Brazil). The resulting model last procedure may be also used to produce fuel oil, but
produces an optimal policy of production and inven- it is not employed indeed.
tory control throughout the scheduling horizon regard- There is no pre-assignment of final products to tanks,
ing the foreseen product demands under operational with the exception of asphalt and UVO although this
restrictions, with the objective of minimizing the costs should occur whenever possible, in agreement with Fig.
involved in this portion of the plant. 7. Sometimes it is necessary, in order to meet demand,
Fig. 8 illustrates the system configuration which in- to temporarily store products in tanks originally dedi-
cludes one deasphalting unit (UDASF), one cracking cated to other oil grades, due to storage limitation.
unit (UFCC), two storage tanks for diluents, 15 storage The presence of residual product in the tank, prior to
tanks for final products, four charging terminals and the transfer, requires viscosity adjustment by addition
two oil pipelines as well as all their interconnections. of diluents or pure RASF directly to the tank and
During the scheduling horizon, asphaltic residue homogenization steps. This strategy of allocating the
(RASF) is produced in the UDASF, as bottom production temporarily in a tank is often applied to
product, and further diluted on-line with at least one of optimize the tank farm utilization as a function of the
the following diluents: decanted oil (OCC) and light foreseen demand and existing inventory, however it is
cycle oil (LCO), with the purpose of producing four undesirable once it implies on additional process steps,
grades of fuel oil (FO1, FO2, FO3 and FO4), or with such as homogenization and viscosity analysis. The
another diluent, heavy gasoil (HG) aiming to produce storage tanks cannot be charged and discharged simul-
two asphalt specifications (CAP 07 and CAP 20). taneously, with the exception of HG storage tank,
Moreover, the plant produces two grades of ultra-vis- which is continually charged. The distribution of a
cous oil (UVO1 and UVO2) which must contain only given product, by oil pipeline or trucks, requires that
2272 J.M. Pinto et al. / Computers and Chemical Engineering 24 (2000) 22592276

relations to compute material loss generated by the


undesirable mixing among products transported in the
oil pipelines. Although the number of 01 variables
remains unchanged, the linearization causes an increase
in the model size; nevertheless it has the advantage of
Fig. 9. Plant production throughout the scheduling horizon (06:00 h providing a lower bound to the objective function.
start time).
The most important operating variables of the prob-
lem are the order of plant production, flowrate values
two tanks that contain it are connected to the same
of all streams, as well as the distribution schedule. The
line, with exception of tanks TK-44108 and TK-43307,
solvers DICOPT+ + (Viswanathan & Grossmann,
which operate individually. Hence, there is the option
1990) and OSL (IBM, 1991) embedded in the modeling
of replacing the supplier tank in case of problems
system GAMS (Brooke et al., 1992) were used to
during the discharge operation, as for example the
implement the MIP optimization models for a schedul-
urgent necessity of receiving material in one of tanks.
ing horizon of 3 days discretized in 2 h intervals. In
The distribution of UVO/Asphalt is only performed by
order to reduce the CPU time, the relative optimality
trucks, from 06:00 to 18:00 h and the distribution of all
criterion was set to a non-zero value and valid con-
FOs is only done by oil pipelines; one is utilized essen-
straints were tested to reduce the size of the search tree
tially to the transport of FO1 and FO4 to Sao Paulo
providing significant timesaving. The computational
and another is utilized to transport FO1, FO2 and FO3
performances of the both MIP models are evaluated
to nearby cities. Set-up times can be neglected.
and compared according to algorithmic structures and
The problem is first modeled as a non-convex mixed-
modeling features. The smaller model (MINLP) has
integer non-linear programming (MINLP), which has
2629 continuous variables, 1584 01 variables and 4630
the inconvenience that no global solution is guaranteed
constraints and its computational results are graphi-
by conventional MINLP algorithms, although this
cally presented in Figs. 911.
difficulty is partially circumvented by the augmented
penalty version of the outer-approximation method. A
rigorous mixed-integer linear (MILP) model derived 4.4. LPG scheduling
from the previous non-linear one is obtained, which
may theoretically be solved to global optimality (Pinto Liquefied petroleum gas (LPG) is basically a mix of
& Joly, 2000). The MILP also incorporates transition hydrocarbons with three and four carbon atoms. This

Fig. 10. Flowrates in oil pipelines (m3/h).

Fig. 11. Volume ( 10 3 m3) of several tanks as function of time (06:00 h start time).
J.M. Pinto et al. / Computers and Chemical Engineering 24 (2000) 22592276 2273

Fig. 12. Refinery LPG system.

product may be used as domestic fuel for cooking and shipped from the refinery through a pipeline. Due to
heating and it is also an important source of petro- that, large quantities of each product must be available
chemical intermediate products, such as propene and when pipeline pumping starts, since small amounts
iso-butane. cannot be shipped in this way. In general the refinery
In a typical refinery, the catalytic cracking process is operates by almost reaching its storage capacity and
the major producer of LPG and approximately a quar- then ships most of the product, ending up with a very
ter of its load is transformed in three and four carbon- small amount. On the other hand, the local market
atom hydrocarbons. Additional amounts are produced demands LPG more or less continuously.
by crude distillation, delayed coking, etc. The fact that The problem is how to make use of the processing
LPG can be liquefied at low pressures allows the stor- resources, raw material and storage room so that the
age of large amounts in spherical tanks, known simply product delivery schedules and quantities are honored.
as spheres. The objective function asks for the maximization of
In the refinery studied, the LPG raw material stream product deliveries and the available inventory of inter-
is fed to a distillation column, which separates it into a mediate propane while the number of spheres used is
stream rich in hydrocarbons with three carbon atoms minimized.
and another rich in four carbon atom hydrocarbons. The optimization model relies on a mixed integer
This column can operate in two different modes: nor-
linear programming (MILP) formulation (Pinto &
mal mode that produces propane for use as domestic
Moro, 2000). Two main decisions concerning this for-
fuel (bottled gas or LPG), and special mode, which
mulation are the representation of the time domain and
employs a high internal reflux ratio, that produces
the model structure itself, which involves the definition
propane for petrochemical purposes. This petrochemi-
of continuous and discrete variables as well as their
cal propane is a very profitable product and its produc-
relationships.
tion is usually maximized. When in this high-purity
mode of operation, the column capacity is limited and In the MILP formulation, time horizon is divided in
cannot process the entire LPG stream, which implies a fixed number of time slots of unknown duration. For
that part of it must be bypassed straight to storage. some of these time slots the initial or final time instant
The storage farm comprises eight spheres capable of is previously known due to decisions that must happen
handling LPG or propane (high pressure and low den- at that time instant. The other time slots are entirely
sity) and four spheres suitable for butane storage (low free but for the fact that they must be subsequent and
pressure and higher density). The butane produced can there must not be overlaps among them. These last are
also be marketed as bottled gas, or injected in the known as soft time slots, whose duration is defined by
gasoline pool or, more frequently, fed to the MTBE the optimization algorithm. The first ones are known as
unit. This unit produces the methyl-terc-butyl-ether, a hard time slots. The schedule of the inputs must be
gasoline additive. It is also possible to feed stored LPG taken into account when defining the time slots to be
or propane to the separation column, an operation used. Any operation whose precise time is known in
known as reprocessing. The overall scheme of the LPG advance defines a hard time slot. On the other hand,
processing area is shown in Fig. 12. the time between two hard time slots may be divided
The main scheduling difficulties in this system arise into a number of soft time slots, whose duration will
from the fact that most LPG and LPG by-products are be set by the optimization algorithm.
2274 J.M. Pinto et al. / Computers and Chemical Engineering 24 (2000) 22592276

The model assumes the existence of several process- The desired product delivery schedule is an input to the
ing units, producing a variety of intermediate streams, optimization algorithm and the LPG production flow
with different properties, that can be blended to consti- rate is also known in advance. During the total time
tute the desired products. The basic aspects of this horizon propane, LPG and butane must be produced,
formulation were described by Moro et al. (1998) for sampled, analyzed and delivered. Furthermore the tank
the planning problem, in which the time domain is not farm must be adequately managed, so that the maxi-
taken into account. In this work we extend that formu- mum and minimum volumes are honored.
lation for the scheduling problem, where decisions must We built an example closely related to the actual
be sequenced and time is an important issue. On the refinery situation. The total time horizon spans 58 h,
other hand, in the present formulation aspects related during which propane, LPG and butane ought to be
to product qualities were not investigated (the problem produced, sampled, analyzed and delivered to cus-
remains linear). tomers. Furthermore the tank farm, comprising eight
We define a unit as a processing element that trans- LPG and propane spheres as well as four butane
forms a feed into several products. The distribution and spheres must be adequately managed. The objective is
properties of these products are related to the feed flow to maximize product delivery as well as the inventory of
rate and properties and the unit operating variables. A petrochemical propane.
product can be the feed of another unit and the feed of The LPG production pattern and the desired product
any unit is the mix of every stream sent to it. deliveries are known in advance as well as the desired
There are two classes of units in the formulation: the feed rate to MTBE unit. In this case, total amount of
processing units and the storage units. The processing 3550 m3 of LPG must be delivered between 26 and 34
units continuously transform the feed into one or more h. Also, a total volume of 1100 m3 of petrochemical
products, so that the steady-state material balance propane must be delivered between 54 and 58 h, while
around them is always satisfied. On the other hand, the 2000 m3 of butane must be sent to customers between
storage units merely store products for later usage. In 50 and 54 h. The LPG production flowrate is 137 m3/h
this case, the material balance must include the non-sta-
and remains the same along the horizon. Moreover,
tionary accumulation term. The processing units
MTBE desired flowrate must be reduced from 14 to 13
defined for the LPG scheduling problem are as follows:
m3/h at time 31 h.
Feed unit: it is used simply to mix all the external
According to these definitions, a total of ten variable-
streams and distribute the resulting mixture to down-
size time slots were defined, most of which were consid-
stream units. It produces only one stream, a mix of
ered hard time-slots, i.e. with known duration. The
C3 and C4 (C3C4) that can be distributed between
modeling system GAMS version 2.50 (Brooke et al.,
the distillation column and the bypass unit.
Distillation column: since the column can operate in
1992) was used to implement the optimization model,
two different modes we created two units to repre- which contains 774 discrete variables and 3807 equa-
sent it and added constraints to assure that only one tions and was solved with OSL solver. The results
may operate during a given time slot. The unit used clearly show that the presented optimization system is
to represent the high-purity propane operation mode capable of deriving an adequate schedule for the LPG
produces special propane (C3i) and butane (C4). The production decisions. The optimal schedule is shown in
other unit produces standard grade propane (C3n) Fig. 13.
and butane. In both cases the C3 stream can be sent
to the spheres or to the bypass unit, while the C4
stream can be directed only to storage.
MTBE unit: process a C4 stream producing MTBE 5. Conclusions
and raffinate. The MTBE stream is directed to the
corresponding product pool unit, while raffinate Applications in planning and scheduling for refinery
must be stored in a LPG or butane sphere. operations have been addressed in this paper. It has
Spheres: these units have the capability to store been shown that these problems can be efficiently for-
product and so are considered storage units. The mulated as large-scale MIP optimization models. Dis-
LPG spheres can send streams to LPG and C3 crete and continuous time representation approaches
product pools and to the distillation column to be for handling the highly combinatorial issues of these
reprocessed. The butane spheres can feed the LPG representations were tested. Continuous time models
and butane product pools and the MTBE unit. were found to avoid the difficulty originated by the
Product Pools: these units represent the product relevant differences in processing time of the several
consumers and are modeled simply as a sink. operations involved, as in the case of crude receipt-
Bypass: represents the pipe that is used to bypass the scheduling problem. Nevertheless, optimal results were
distillation column and send product direct to the obtained in reasonable time through discretization of
LPG spheres. scheduling horizon for important areas of the refinery.
J.M. Pinto et al. / Computers and Chemical Engineering 24 (2000) 22592276 2275

Fig. 13. Optimal LPG schedule.

Real-world refinery problems were presented and Industry requires continuous work in order to allow the
solved. The MILP models can be solved with the LP necessary enhancements related to the computer aided
based branch and bound method while the generalized scheduling tools.
reduced gradient method was satisfactory for NLP Other important areas of the refinery are currently
ones. The solution of the MINLP non-convex model under investigation, such as the distillation units and
presented for the fuel oil production problem can in the FCC area, which operate under different cam-
principle be accomplished with the augmented penalty paigns. The problems of crude oil distribution among
version of the outer-approximation method imple- the refineries as well as the management of common oil
mented in DICOPT + +. The computational require- pipelines are also fundamental for the efficient opera-
ments of all solution methods proposed are reasonable. tion of an oil company. More generally, important
However, it is computationally infeasible to obtain issues remain to be investigated, such as integration of
global optimal solutions due to the highly combinato- logistics, planning and scheduling, as well as more
rial features of the MIP formulations. efficient modeling and solution techniques.
In fact, the understanding of these real-world plan-
ning/scheduling problems constitute the most difficult
step for obtaining optimal solutions, since several oper- References
ational features of the plant are closely related to the
process experts, a fact that represents an additional Ballintjin, K. (1993). Optimization in refinery scheduling: modeling
and solution. In T. A. Ciriani, & R. C. Leachman, Optimization in
difficulty to the modeler task. Many times, this is industry, vol. 3 (pp. 191 199). New York: Wiley.
responsible for divergences between the modeler and Bechtel (1993). PIMS (Process Industry Modeling System) Users
the user. Suri, Diehl, Treville and Tomsicek (1995) manual. Version 6.0. Houston, TX: Bechtel Corp.
mention this fact as one of the major challenges in Bodington, C. E. (1992). Inventory management in blending opti-
Operations Research in the last 15 years since the mization: use of nonlinear optimization for gasoline blend plan-
ning and scheduling. In ORSA/TIMS National Meeting, San
scientific community frequently see the industrial prob- Francisco (CA).
lems as solved as soon as a paper is published. On the Bodington, C. E. (1995). Planning, scheduling, and control integration
other hand, the dynamic nature of the Petrochemical in the process industries. New York: McGraw Hill.
2276 J.M. Pinto et al. / Computers and Chemical Engineering 24 (2000) 22592276

Bodington, C. E, & Shobrys, D. E. (1996). Optimize the supply chain. Picaseno-Gamiz, J. (1989). A systematic approach for scheduling pro-
Hydrocarbon Processing, 75 (9), 5560. duction in continuous processing systems. Ph.D. Thesis, University
Bonner & Moore (1979). RPMS (Refinery and Petrochemical Model- of Waterloo, Waterloo, Canada.
ing System): a system description. Houston, NY: Bonner and Pinto, J. M., & Grossmann, I. E. (1994). Optimal cyclic scheduling of
Moore Management Science. multistage continuous multiproduct plants. Computers & Chemi-
Brooke, A., Kendrick, D., & Meeraus, A. (1992). GAMS a users cal Engineering, 18 (9), 797 816.
guide (release 2.25). San Francisco, CA: The Scientific Press. Pinto, J. M., & Grossmann, I. E. (1998). Assignment and sequencing
Coxhead, R. E. (1994). Integrated planning and scheduling systems models for the scheduling of chemical processes. Annals of Opera-
for the refining industry. In T. A. Ciriani, & R. C. Leachman, tions Research, 81, 433 466.
Optimization in industry, vol. 2 (pp. 185199). New York: Wiley. Pinto, J. M., & Moro, L. F. L. (2000). A mixed-integer model for
Cutler, C. R., & Ayala, J. S. (1993). Integrating off-line schedulers LPG scheduling. Accepted at the European Symposium on Com-
with real time optimizers. In AIChE National Spring Meeting, puter Aided Process Engineering-ESCAPE-10, Florence, Italy.
paper 40a, Houston, TX. Pinto, J. M., & Joly, M. (2000). Mixed-integer programming tech-
Fieldhouse, M. (1993). The pooling problem. In T. A. Ciriani, & R. niques for the scheduling of fuel oil and asphalt production. Ac-
C. Leachman, Optimization in industry, vol. 3 (pp. 223230). New cepted at the European Symposium on Computer Aided Process
York: Wiley. Engineering-ESCAPE-10, Florence, Italy.
Hartveld, M. (1996). The chemical industry, by country Brazil. Porn, R., Harjunkoski, I., & Westerlund, T. (1999). Convexification
Hydrocarbon Processing, 75 (9), 118118. of different classes of non-convex MINLP problems. Computers &
IBM (1991). IBM-OSL guide and reference (release 2). Kingston, NY. Chemical Engineering, 23, 439 448.
Ierapetritou, M. G., & Floudas, C. A. (1998). Effective continuous- Ramage, M. P. (1998) The petroleum industry of the 21st Century. In
time formulation for short-term scheduling. 2. Continuous and Foundations of computer aided process operations-FOCAPO 98,
semicontinuous processes. Industrial & Engineering Chemistry Re- Snowmass, CO.
search, 37, 4360 4374. Reklaitis, G.V. (1992). O6er6iew of scheduling and planning of batch
Kondili, E., Pantelides, C. C., & Sargent, R. W. H. (1993). A general process operations. NATO Advanced Study Institute Batch
algorithm for scheduling batch operations. Computers & Chemical Process Systems Engineering, Antalya, Turkey.
Engineering, 17, 211 227. Rigby, B., Lasdon, L. S., & Waren, A. D. (1995). The evolution of
Lee, H., Pinto, J. M., Grossmann, I. E., & Park, S. (1996). Mixed-in- Texacos blending systems: from OMEGA to StarBlend. Inter-
teger linear programming model for refinery short-term schedul- faces, 25 (5), 64 83.
ing of crude oil unloading with inventory management. Industrial Sahinidis, N. V., & Grossmann, I. E. (1991). MINLP model for cyclic
& Engineering Chemistry Research, 35, 16301641. multiproduct scheduling on continuous parallel lines. Computers
Macchietto, S. (1993). Bridging the gap integration of design, & Chemical Engineering, 15, 85 103.
operations scheduling and control. In D. W. T. Rippin, J. C. Shah, N. (1996). Mathematical programming techniques for crude oil
Hale, & J. F. Davis, Foundations of computer aided process scheduling. Computers & Chemical Engineering, 20 (Suppl.),
operations (pp. 207 230). Austin, TX: CACHE. S1227 S1232.
Magalhaes, M. V. O., Moro, L. F. L., Smania, P., Hassimotto, M. SIPP (1997). Scheduling REVAP Production scheduling system.
K., Pinto, J. M., & Abadia, G. J. (1998). SIPP A solution for System specification. V. 3.0, Petrobras Petroleo Brasileiro S/A,
refinery scheduling. 1998 NPRA Computer Conference, National Rio de Janeiro, Brazil.
Petroleum Refiners Association, November 1618, San Antonio, Steinschorn, D., & Hofferl, F. (1997). Refinery scheduling using
TX. mixed integer LP and dynamic recursion. In NPRA Computer
Mansfield, K. W., Maphet, J. G., Bain, M. L., Bosler, W. H., & conference, New Orleans, LA.
Kennedy, J. P. (1993). Gasoline blending with an integrated on line Suri, R., Diehl, G. W. W., Treville, S., & Tomsicek, M. J. (1995).
optimization, scheduling and control system. Paper 40b. AIChE From CAN-Q to MPX: evolution of queuing software for manu-
National Spring Meeting, Houston, TX. facturing. Interfaces, 25 (5), 128 150.
Moro, L. F. L, Zanin, A. C., & Pinto, J. M. (1998). A planning Symonds, G. H. (1955). Linear programming: the solution of refinery
model for refinery diesel production. Computers & Chemical Engi- problems. New York: Esso Standard Oil Company.
neering, 22 (Suppl), S1039S1042. Viswanathan, J., & Grossmann, I. E. (1990). A combined penalty
Moro, L. F. L., & Pinto, J. M. (1998). A mixed-integer model for function and outer approximation method for MINLP optimiza-
short-term crude oil scheduling. In AIChE Annual National Meet- tion. Computers & Chemical Engineering, 14 (7), 769 782.
ing, paper 241c. Miami Beach, FL. Xueya, Z., & Sargent, R. W. H. (1996). The optimal operation of
Pelham, R., & Pharris, C. (1996). Refinery operation and control: a mixed production facilities. Computers & Chemical Engineering,
future vision. Hydrocarbon Processing, 75 (7), 8994. 20 (6/7), 897 904.

You might also like