Professional Documents
Culture Documents
Project Report
On
Submitted by
Sunil Pillai
May-June 2010
Refinery Revenue Optimization
Project Report
On
Project Guide:
Dharmendra Mehta
DGM
Economic Planning & Scheduling
Submitted by
Sunil Pillai
May-June 2010
2 Sunil S Pillai
Refinery Revenue Optimization
CERTIFICATE
Project Guide
Dharmendra Mehta
DGM
Economic Planning & Scheduling
3 Sunil S Pillai
Refinery Revenue Optimization
Acknowledgements
Before we get into the thick of the thing, let me pen down a few words for all those who
made this possible.
Above everything, am grateful to GOD for leading the way at all steps and enabling me to
complete this Project well in time and with desired quality.
I would like to begin with Mr. C Manoharan, HOR-Vadinar Refinery for providing me an
opportunity to do my internship at Essar and add value to its operations. I am thankful
to Mr. Milind Hiwale, JGM-HR for facilitating the process. It was truly a learning
experience.
I am grateful to Mr. Dhaval Doshi, head-EPS for assigning challenging tasks and setting
the bar high. Sincere Regards to Mr. Dharmendra Mehta, my Project Guide for the
quality time he devoted to the project. His in-depth analysis has played an important role
in the improvement of the project.
Kudos to Karishma Mam, our SIP Coordinator for skillfully managing the entire
Internship process and being a guide at most crucial stages.
Bhargav Chandarana deserves mention for explaining the diesel blending process and
laying the foundation for development of models. His analysis of the model went a long
way in making the model bug-free.
Next in line would be Ms. Muthulaxmi Balasubramanium for let’s say ‘the infrastructure
support’, for being always available to queries, for encouraging experimenting. Her
insights have been very useful in making the report
Mohit sir’s contribution in the MS Model cannot go unmentioned. Right from explaining
the process to finally obtaining feasible solution, his significant presence was
everywhere. I am thankful to him for all the help extended to this project.
Last but not the least; I would like to express my gratitude to Mr. Anand Pachouri and
Mr. Vikrant of Nalanda Knowledge Center and all the members of Essar family who
directly or indirectly made my stay at Essar, a smooth and pleasant experience.
4 Sunil S Pillai
Refinery Revenue Optimization
Table of Contents
Acknowledgements ........................................................................................................................................... 4
Executive Summary ........................................................................................................................................... 7
1. About ESSAR .............................................................................................................................................. 8
1.1. ENERGY BUSINESS ............................................................................................................................... 9
2. Objective .................................................................................................................................................. 12
2.1. Refinery Economics ........................................................................................................................... 12
2.2. Optimisation ...................................................................................................................................... 12
2.3. Product Optimization Models ........................................................................................................... 13
2.4. Solver ................................................................................................................................................. 14
2.5. Model Overview ................................................................................................................................ 15
3. Literature Survey ..................................................................................................................................... 16
3.1. Refinery Economics ........................................................................................................................... 16
3.2. Linear Programming .......................................................................................................................... 17
3.3. What’s Best ........................................................................................................................................ 18
3.4. Excel 2010 Solver ............................................................................................................................... 19
3.5. Microsoft Solver Foundation ............................................................................................................. 19
4. HSD Blending Model ................................................................................................................................ 22
4.1. Objective ............................................................................................................................................ 22
4.2. Units ................................................................................................................................................... 22
4.3. Products ............................................................................................................................................. 26
Other Products ........................................................................................................................................ 28
4.4. Inputs ................................................................................................................................................. 29
4.5. Outputs .............................................................................................................................................. 29
Revenue ................................................................................................................................................... 29
5 Sunil S Pillai
Refinery Revenue Optimization
5. MS Blending Model ................................................................................................................................. 30
5.1. Objective ............................................................................................................................................ 30
5.2. Units ................................................................................................................................................... 30
5.3. Products ............................................................................................................................................. 32
Other Products ........................................................................................................................................ 33
5.4. Inventory ........................................................................................................................................... 34
5.5. Inputs ................................................................................................................................................. 34
5.6. Outputs .............................................................................................................................................. 34
6. Integrated HSD MS Blending ................................................................................................................... 35
6.1. Material Balance ................................................................................................................................ 35
6.2. Hydrogen Accounting ........................................................................................................................ 35
7. Tank Correction Model ............................................................................................................................ 37
8. Applications ............................................................................................................................................. 38
8.1. Monthly Plan ..................................................................................................................................... 38
8.2. Quality Targets .................................................................................................................................. 38
8.3. Stream Deviation and Quality Giveaway Reports & Targets ............................................................. 38
9. Analysis .................................................................................................................................................... 39
9.1. Intermediate Properties .................................................................................................................... 39
9.2. Final Product Properties .................................................................................................................... 39
10. Assumptions ........................................................................................................................................ 40
10.1. Prices ................................................................................................................................................. 40
10.2. Yields .................................................................................................................................................. 40
10.3. Intermediate Properties .................................................................................................................... 40
11. Limitations ........................................................................................................................................... 41
12. GLOSSARY ............................................................................................................................................ 42
13. Bibilography ......................................................................................................................................... 43
6 Sunil S Pillai
Refinery Revenue Optimization
Executive Summary
Accordingly the refinery planning problem can also be decomposed into three sub
problems. Given the scale of situation, we focus on the product blending area. This whole
process is usually described by massive amount of operational data and decision-making
processes. These situations call for detailed planning over a specific period of time -
typically one year. Often the production plans are further broken down into feasible
operations throughout time with detailed schedule of each activity and event in the
refining operations. The scheduling horizons span from a few days to weeks, depending
on information availability and uncertainty, and decisions are taken on hourly basis.
The problem being addressed here in is the monthly planning of product blending.
The objective is to obtain optimum production slate while maximizing the revenue. The
crude selection is treated as an independent optimization area and hence the input costs
are considered to be optimized & locally constant. The operating cost of the refinery is an
insignificant fraction of the total costs. Hence revenue from product sales can be
considered as a basis for optimizing production.
This project envisages the development and implementation of four models viz the
HSD Model, MS Model, Integrated HSD-MS Model and the Tank Correction Model. The
first two models are centered on HSD blending & MS Blending process and their fallouts.
The Integrated model takes care of Hydrogen Accounting while providing an optimization
over both the process. The tank correction model comes as a handy tool when some of
the target parameters are not met and the failed tank has to be corrected.
The solver required for solving the models is an equally important part of the
project. Due analysis has been done for the solver capability required and currently
available. The model can readily utilize the services of what’s Best & Excel Solver. In
addition Microsoft Solver Foundation can be called upon to aid in transferring the model
to other optimization modeling languages which can then by accessed by a large number
of solver suites.
The models with over 130 variables and 220 constraints span over six units, 20+
intermediates and ten products. The models are logically arranged in a most user-
friendly layout equipped with multi solver support. Fully documented and worked out in
to understand way, the models will facilitate the work flow at EPS.
a easy
7 Sunil S Pillai
Refinery Revenue Optimization
1. About ESSAR
The Essar Group is a multinational conglomerate and a leading player in the
sectors of Steel, Energy, Power, Communications, Shipping Ports & Logistics,
Construction, and Mining & Minerals. With operations in more than 20 countries
across five continents, the Group employs 60,000 people, with revenues of about USD
15 billion in FY08-09.
Today, the Group continues to expand its global footprint, focusing on markets in
Asia, Africa, Europe, the Americas and Australia. Essar invests significantly in the
latest technology to drive forward and backward integration in its businesses, and on
leveraging synergies between these businesses. It also focuses on in-house research
and innovation to be a low-cost manufacturer with high quality products and
innovative customer offerings.
Alongside its ambitious business pursuits, Essar has been committed to its social
responsibility. The Group runs community outreach initiatives in all its plant
locations, with a focus on education, healthcare, environmental and agricultural
development, and self-employment. Essar is committed to sustainable business
practices. Our Health, Safety and Environment (HSE) management system is on par
with global standards. We are also taking climate change initiatives to reduce our
carbon footprint. This includes several CDM (Clean Development Mechanism) projects
that can earn the company Certified Emission Reduction (CER) credits. A growing
number of our businesses—with new businesses joining the list every year—are
certified to international environment standards, like ISO 9001 / 14001, and health
and safety standards, like OHSAS 18001.
8 Sunil S Pillai
Refinery Revenue Optimization
¾ Steel Business
¾ Energy Business
¾ Power Business
¾ Communication Business
¾ Shipping, Ports & Logistics Business
¾ Projects Business
¾ Mining, Metals & Minerals Business
1.1.ENERGY BUSINESS
• A fully integrated oil & gas company of international scale with strong presence
across the hydrocarbon value chain from exploration & production to oil retail.
• Global portfolio of onshore and offshore oil & gas blocks, with about 70,000 sq km
available for exploration.
• Over 280,000 bpd (barrels per day) of crude refining capacity that is being expanded
to 680,000 bpd, with a goal to reach a global refining capacity of 1 million bpd.
• Over 1,200 Essar branded oil retail outlets in various parts of India, with plans to
open over 3,000 outlets countrywide
CURRENT OPERATIONS
¾ Asia, Africa & Australia: Diverse portfolio of offshore and onshore Oil & Gas
blocks as well as Coal Bed Methane blocks
• Ratna and R-series fields, with reserves of 161 million barrels of oil equivalent,
near the Mumbai High field in the Mumbai offshore basin
9 Sunil S Pillai
Refinery Revenue Optimization
Refining:
Major units:
¾ Crude Distillation Unit: Current potential capacity of 14 million tons.
¾ Vacuum Distillation Unit: Current potential capacity of 7.2 million tons.
¾ Vis Breaker Unit: Current potential capacity of 2.3 million tons (Axens,
France).
¾ Continuous Catalytic Regenerator: Current potential capacity of 1 million
tons (Axens, France)
¾ Fluid Catalytic Cracking Unit: Current potential capacity of 3.5 million tons
(Stone & Webster)
¾ Diesel Hydro Desulphurisation unit: Current potential capacity of 4.5
million tons (Axens, France)
10 Sunil S Pillai
Refinery Revenue Optimization
¾ Mombassa, Kenya: 50 percent stake in a 80,000 bpd refinery run by the Kenya
Petroleum Refineries Ltd (KPRL); the remaining 50 percent is owned by the Kenyan
government
Retailing
Across India:
• Marketing network of over 1,200 operational retail outlets, with plans to reach
3,000 outlets countrywide
• Tie-ups with other oil marketing companies that gives Essar Oil access to product
and right to use their terminals and facilities for placing and marketing our products.
This gives the company pan-India presence with more than 30 supply locations.
UNDER EXECUTION
11 Sunil S Pillai
Refinery Revenue Optimization
2. Objective
2.1. Refinery Economics
Modeling the activities of petroleum refineries with regard to altering the mix of refined
petroleum product output has proven to be a most elusive proposition. The structural
and data problems inherent in such analysis are difficult to resolve. It is imperative,
however, that a framework be developed to enable such modeling efforts because of the
overall importance of petroleum in a balanced energy network.
It should be observed that the design of any specific refinery will depend upon, among
other things, the specific characteristics of the crude oil to be processed and the output
mix desired, within limits. There are different grades of crude oil and, as a result, there
will be differences in the yield obtained from them.
2.2.Optimisation
The use of mathematical programming (MP) in detailed planning in the petroleum
refining industry spans well over half a century. However, usage prior to the invention of
the electronic digital computer was limited to small problems that could be solved by
hand. Dantzig’s invention and development of the simplex algorithm in 1947 really
created the area of linear programming (LP) and blending of gasoline turned out to be the
most popular application in the petroleum industry. Later, usage of LP was extended to a
grassroots design and configuration selection, capital investment analysis, long-range
operations planning, supply and distribution planning. The limitations to progress are
the matrix size capacity of the computer or the time required to get a solution or both
and the accuracy of LP results which depend on the validity of input data. Refinery
planners have therefore solved complex refinery-planning problems by decomposing into
sub problems and, to date, this is reflected in the way some refineries operate its
planning, central engineering, upstream operations, refining, supply and transportation.
In most cases, the refinery-planning problem is decomposed into three sub problems -
crude supply, refining and blending, and product distribution.
The primary goal of SCM is to maximize profit by integrated management of material and
transactional flows within a business and to customer and partner companies. The
supply chain of a typical petroleum refining company involves a wide spectrum of
12 Sunil S Pillai
Refinery Revenue Optimization
activities, starting from crude purchase and crude transportation to refineries, refining
operations, product transportation and finally delivering the product to the end user. The
nature of the value chain is such that its economics are extremely complex and heavily
linked.
For example, the process of selecting the right crude oil is linked not only to the
transportation costs involved in delivering it to the refinery, but it must take into
consideration the need to balance the dynamic behavior of the whole refinery network in
different scenarios, the capabilities and constraints in converting the crude into
products, stochastic nature of prices, increasingly restrictive environmental legislation as
well as the product volume.
This whole process is usually described by massive amount of operational data and
decision-making processes. These situations call for detailed planning over a specific
period of time - typically one year. Often the production plans are further broken down
into feasible operations throughout time with detailed schedule of each activity and event
in the refining operations. The scheduling horizons span from a few days to weeks,
depending on information availability and uncertainty, and decisions are taken on hourly
basis.
2.3.Product Optimization Models
The objective of this exercise is to determine optimum Refinery Production scenario so as
to maximize revenue.
Given
Determine
13 Sunil S Pillai
Refinery Revenue Optimization
In order to
Subject to
The development of four models was undertaken to meet the specific requirements of the
department
• HSD Blending
• MS Blending
• Combined HSD-MS Model
• Tank Correction Model
These models employ the concepts of Linear Programming, Non-Linear Programming and
Quadratic Programming
2.4.Solver
The Models were originally designed using Excel 2010’s solver. The HSD model has been
completely linearized. Hence it can use the simplex algorithm of Excel 2010’s solver. The
other 3 models have non-linearities present hence need the services of a non-linear
solver. The models can be run on Excel 2007’s solver without any modifications. In
addition the services of WHAT’s BEST, a solver from LINDO systems is available. All the
models have been modified to run on both the solvers- WB & Excel.
Study of Microsoft Solver Foundation has also been undertaken. The models can be
transported to MSF, if and when required. MSF allows the model to be transported to
other mathematical programming languages like MPS, QPS & OML. The model can also
be deployed using C#. Once the model is available in these languages, it can be accessed
& solved
by all the solvers that understand these languages.
14 Sunil S Pillai
Refinery Revenue Optimization
2.5.Model Overview
All the models operate in Microsoft Excel. They basically have two sheets: Processing &
Interface.
The Interface sheet is to be used to supply data values to the model. It also displays all
the outputs generated by the model. The processing sheet fetches values from the
Interface sheet. It does all the calculations. The solvers are binded to this sheet. After
processing, the processing sheet passes on all the required values to Interface sheet to be
displayed in an easy to visualize manner. The processing sheet can be referred to drill
down into the model.
Fully Documented
Almost all the cells have relevant meaningful cell names. All formulas use Cell names
instead of cell addresses. This makes the model self-explanatory & aids easy
understanding without having to refer to voluminous documentation.
User Friendly
The Model has been arranged in most effective manner. All the objectives are highlighted
at the top of the sheet effectively summarizing the model. The Model has been
represented in a graphical way providing easy visualization of the situation. The model
also makes optimum utilization of sheet space. Laid out in a compact format, the model
envisages minimum scrolling effort. The units & products have been separated and
displayed apart to provide clarity.
ActiveX Controls
The model solving part has also been automated. The model uses ActiveX controls to do
all the excel solver jobs. Clicking on optimize button will set up the solver, load the
constraints, solve the problem & come back to active sheet.
Multiple solver support
The same file can be used with both what’s best & Excel Solver. All the necessary
modifications have been built into the model. The original file though made with Excel
2010 can be used with any version of Excel or other spreadsheet programs with minimal
changes.
15 Sunil S Pillai
Refinery Revenue Optimization
3. Literature Survey
3.1.Refinery Economics
Using more expensive crude oil (lighter, sweeter) requires less refinery upgrading
but supplies of light, sweet crude oil are decreasing and the differential between
heavier and sourer crudes is increasing. Using cheaper heavier crude oil means more
investment in upgrading processes. Costs and payback periods for refinery processing
units must be weighed against anticipated crude oil costs and the projected
differential between light and heavy crude oil prices.
Crude slates and refinery configurations must take into account the type of
products that will ultimately be needed in the marketplace. The quality specifications
of the final products are also increasingly important as environmental requirements
become more stringent.
Product Slates
Refinery configuration is also influenced by the product demand in each region.
Refineries produce a wide range of products including: propane, butane,
petrochemical feedstock, gasolines (naphtha specialties, aviation gasoline, motor
gasoline), distillates (jet fuels, diesel, stove oil, kerosene, furnace oil), heavy fuel oil,
lubricating oils, waxes, asphalt and still gas.
Light crude, for example, will yield a high percentage of useful products by
distillation, whereas heavy crude will produce significant amounts of crude-oil
material that must be sold as heavy fuel oil or else processed further. As a result,
there
is some flexibility in switching a refinery to alternative crude streams, although
this
is limited [4].
16 Sunil S Pillai
Refinery Revenue Optimization
In the refining process, some of the available crudes must be refined because of
long-term minimum volume commitments or because of requirements for specialty
products. These crudes are considered fixed, and yield constant motor gasoline and
distillate fuel oil volumes. From the remaining crudes, and from those crudes which
are available in volumes greater than their minimum volume commitment, are
selected those which can supply the required refined products most economically.
These are nominally referred to as the incremental crudes.
3.2.Linear Programming
Considerable research work has been done in the modelling of each of sub-
system. In the upstream and crude supply operations, Iyer et. al. (1998) develop a
multi-period mixed integer linear programming (MILP) problem for planning and
scheduling of offshore oil field infrastructure investments and operations. Van der
Heever and Grossmann (2000) present a nonlinear model for oil field infrastructure
that involves design and planning decisions while, in another study, the same
authors and others focus on business rules (Van der Heever, 2000). Meister, Clark
and Shah (1996) develop a model which allows the optimal selection of information-
gathering processes during the oil exploration phase and, at the same time, permits
the calculation of optimal operating policies. In other studies, Lee et. al. (1996) report
a detailed MILP formulation comprising of oil tankers, berths, storage tanks,
substations and refineries whereas Maglh˜aes and Shah (2003) focus on the crude oil
supply scheduling. Pinto et al. (2002) address the problem of crude oil supply and
unloading, transfer to storage tanks, charging schedules for each CDU and inventory
management of the tanks while M´as and Pinto (2003) go further to decompose
supply subsystem into subproblems.
Park et. al. (2002) reports a MILP formulation of actual refinery scheduling
consisting of crude oil purchase, shipping by oil tankers, unloading to storage tanks,
CDU and product tank operations with due consideration to environmental pollution.
Recently, Kosmidis et. al. (2005) present a novel mixed integer nonlinear (MINLP)
model for the daily well scheduling in the petroleum fields, the applicability of which
gave up to 10% increase in oil production compared to heuristic rules widely applied
in practice.
In the area of refining and blending sub-system, Moro, Zanin and Pinto (1998)
develop a real-world application for the planning of diesel production in Sao Paulo
which represents an increase in profitability of about $6,000,000/year. Pinto, Joly
and
Moro (2002) focus on production scheduling for several specific areas in a
refinery
such as crude oil, fuel oil, asphalt and LPG. Okeke and Osakwe-Akofe (2003)
17 Sunil S Pillai
Refinery Revenue Optimization
model a group of CDUs as nonlinear programming problem (NLP) with the aim of
obtaining increased gasoline yield in the context of reducing energy requirement.
Ponnambalam, Vannelli, and Woo (1992) develop an approach that combines simplex
method for LP with an interior point method (IPM) for solving a linear multi-period
planning model in an oil refinery. Jia and Ierapetritou (2003) propose a realistic large-
scale continuous-time formulation for the short-term scheduling of gasoline blending
and distribution system.
In the distribution sub-system, Van der Bruggen et. al. (1995) present a hierarchal
approach for the operations related to the delivery of gasoline and diesel oil between
depots and clients while Persson and Gothe-Lundgren (2005) suggest an optimisation
model and a solution method for a shipment planning problem. In his thesis, Kogal
(2002) presents two different approaches for pipeline models one of which was a
general MILP formulation. In a more recent report, Rejowski and Pinto (2003) present
a model composed of petroleum refinery, one multi-product pipeline and several
depots that are connected to local consumer markets.
3.3.What’s Best
What’s Best is an add-in to Excel that allows you to build large scale optimization
models in a free form layout within a spreadsheet. What’s Best combines the power of
Linear, Non-Linear, Quadratic, Stochastic & Integer Optimization with Microsoft
Excel.
Key Benefits
¾ Extensive documentation & Help
18 Sunil S Pillai
Refinery Revenue Optimization
User manual fully describes the commands & features of the program. Also
included in the manual is discussion of major classes of linear, integer and nonlinear
optimization problems along with over two dozen real world based examples that you
can modify and expand.
3.4.Excel 2010 Solver
Excel 2010 includes a new version of the Solver add-in, which you can use to find
optimal solutions in what-if analysis. Solver has an improved user interface, a new
Evolutionary Solver, based on genetic algorithms, that handles models with any Excel
functions, new global optimization options, better linear programming and nonlinear
optimization methods, and new linearity and feasibility reports. In addition, the
Solver add-in is now available in a 64-bit version
Excel 2010 Solver ships with three solvers. Select Simplex Solver for solving linear
problems. The GRG Solver can be used with smooth Non-linear problems. The
Evolutionary solver can manage the non-smooth problems.
If Simplex Solver is used, it will result in a global solution. The GRG solver
ensures that the result is at least locally optimal.
3.5.Microsoft Solver Foundation
Solver Foundation is a pure, managed code runtime for mathematical
programming, modeling, and optimization. This .NET/CLR based framework provides
a rich set of tools, services, and engines to aid companies in their continuous quest
for operational efficiency, profit maximization, and risk management. Solver
Foundation is designed to help businesses make strategic decisions. It affords its
users the advantage of easy to use tools, numerically stable solver technologies and
deep integration with ubiquitous information worker systems like Microsoft Office.
19 Sunil S Pillai
Refinery Revenue Optimization
Solver Foundation consists of a series of layered services that efficiently divide the
work of modeling and solving. The following system diagram describes the extensible
architecture.
• Solver Foundation Services (SFS). Essentially a runtime API that augments the
capabilities of individual solvers with framework-level model analysis and meta-
heuristics. In short, we abstract the complexities of optimization so users can focus
on modeling and solving their decision problems. Key features in this area:
o Easy data binding. SFS allows easy LINQ data binding of model parameters and
delivery of results in multiple formats.
o Solver/Capability Selection. SFS will automatically analyze models and
determine which solver is most appropriate. Advanced Modelers can optionally
choose specific solvers, and solver attributes.
o
20 Sunil S Pillai
Refinery Revenue Optimization
o Solver Plug-in Capability. Solver Foundation allows new or existing 3rd party
solvers to plug into the SFS directly, avoiding the need to learn a new modeling
language or the significant overhead in managing solver specific solutions. We
included a collection of reference and certified partner wrappers, and included the
Gurobi MIP solver to handle all default MILP problems.
o Model/Solver Reports and Analysis. SFS can report information about solver
behavior and results, and provide additional information about solutions,
including sensitivity.
o Type safe version of the Optimization Modeling Language (OML). The SFS
interface provides the same facilities as OML, but adds type checking and higher-
level constructs.
Solver Foundation supports all of the common domains that a business modeler and
planner would require – including working with models that involve:
• (Mixed and Binary) Integer Programming (From Branch and Bound to Cutting Plane
Techniques)
21 Sunil S Pillai
Refinery Revenue Optimization
4. HSD Blending Model
4.1.Objective
• To maximize Product Revenue
• Optimum Production Slates of HSD, FO, IFO, Bitumen
• Optimum Unit Throughputs
Now to maximize the revenue, all the alternative uses of feed components have to be
considered.
The single input of raw material to the model is at Crude Input to CDU. The model is
divided into two sections: Units & Products.
4.2.Units
Crude Distillation Unit (CDU)
The main input to the refinery is Crude Oil. The Crude Oil is sent to Crude Distillation
Unit (CDU). The CDU gives different products by fractional Distillation process. Some of
the CDU products are used to drive the Vis-Breaker Unit (VBU). Some of the products of
VBU & CDU are used as feed stock to Fluid Catalytic Cracker (FCC).
22 Sunil S Pillai
Refinery Revenue Optimization
The Detailed possible Allocations for each of the CDU streams are shown below in the
form of table:
As To To
To VBU To FCC To FO
Product DHDS Blending
LPG
HN
LK
Crude Oil
Thruput HK
LGO
CDU
HGO
VD
LVGO
HVGO
HHVGO
VR
The output stream SN (Stabilized Naphtha) is involved in the MS Blending Model & is
detailed there. In addition to these, CDU also emits Gas in small quantities. This gas
is sent to Utility & Power plant for generating steam & electricity
23 Sunil S Pillai
Refinery Revenue Optimization
Vis Breaker Unit (VBU)
The inputs to the VBU are the CDU streams HHVGO & VR. The VBU outputs the
following Products
• VBVR
• VBVGO
• VBAGO
• VB Naptha
• VB LPG
• VB H2S
• VB GAS
The Detailed possible Allocations for each of the VBU streams are shown below in the
form of table
VBVR
VBVGO
VBAGO
VBNap
VB LPG
VB Gas is send to utility for generating steam and electricity. VB H2S is sent to
Sulphur Recovery unit for recovering Sulphur.
24 Sunil S Pillai
Refinery Revenue Optimization
Fluid Catalytic Cracker (FCC)
The inputs to the FCC are the CDU streams LVGO and HVGO & VBU stream VBVGO.
The VBU outputs the following Products
• Gas
• LPG
• Coke
• LG
• MG
• HG
• LCO
• Slurry Oil
The Detailed possible Allocations for each of the FCC streams are shown below in the
form of table
As To To
To DHDS To FO
Product Blending Bitumen
Gas
LPG
Coke
LG
MG
HG
LCO
Slurry Oil
LG & MG are used for MS Blending & are detailed in the MS Blending Model. Coke is
fed as fuel to FCC.
25 Sunil S Pillai
Refinery Revenue Optimization
Diesel Hydro Desulphurisation (DHDS)
DHDS removes the sulphur content out of the feed products by adding H2 and
extracting H2S. The output pool has sulphur of 40ppm, Flash of 60°C and KV reduced
by 0.2.
LK
HK
LGO Diesel
DHDS
HGO Naptha
VD H2S
HG Gas
LCO
VBAGO
H2
The DHDS produces following Product streams::
• Diesel
• Naphtha.
• H2S
• Gas
The Diesel output from DHDS is used for Diesel Blending. Naphtha is directly sold as
a product. GAS is sent to CDU for recovering LPG. H2S is routed to Sulphur Recovery
Unit.
4.3.Products
Diesel Blending
So finally the Components that can be used to blend Diesel are as Follows
DHDS Diesel
HSD
LK
HK
HG
HN
26 Sunil S Pillai
Refinery Revenue Optimization
• KV min : 2.2CST
• Sulphur min : 300 ppm, max : 320ppm
• Flash min : 38°C, max : 45°C
The values for these parameters are known for the feed Components. The product
parameters can be calculated by taking sum product of the component parameter
values with the volume used of respective components. The Model determines the
optimum volume of each of the feed Components in such a way that the product key
parameters are in the desired range.
FO Blending
The Following components are used for Fuel Oil Blending
LK
HK
LGO
Fuel Oil
LCO
LVGO
HHVGO
Slurry Oil
VBVR
VBVGO
VBAGO
IFO Blending
Internal Fuel Oil is blended from the following components
27 Sunil S Pillai
Refinery Revenue Optimization
• VBVR
• Slurry Oil
The Key parameter for IFO is KV which should be equal to 40,800 CST.
Bitumen Blending
Bitumen is blended from
• HHVGO (40%)
• VR (60%)
Other Products
Naptha
Naptha is sourced from three units:
Liquified Petroluem Gas (LPG)
LPG is sourced from three units:
LPG is directly sold as a Final Product. It appears directly in the Revenue Calculation
of model.
Superior Kerosene Oil
The part of LK which optimizer allocates for selling as a product is directly sold as
SKO. Usually there is a cap on maximum quantity of SKO.
28 Sunil S Pillai
Refinery Revenue Optimization
4.4.Inputs
As far as the model is considered, crude oil is the only raw material used.
The model can be run for any time period- monthly, weekly, daily. The only changes
to be made are in the capacity constraints which have to be scaled up or scaled down
as per the required period.
4.5.Outputs
The Model outputs the following data
Revenue
The prices of the products have to be entered into the model as an input. For revenue
calculation the output quantities have been converted into the units in which they are
actually traded viz bbls & tons. The total revenue is the sum of revenue from all
product sales including LPG & SKO. The objective of the model is maximizing this
revenue.
29 Sunil S Pillai
Refinery Revenue Optimization
5. MS Blending Model
5.1.Objective
• To maximize Revenue
• Optimum Throughputs for NHT & CCR
• Optimum production slates for MS BS3, MS BS 92, MS Exp
• SN (CDU Stream)
• LG (FCC Stream)
• MG (FCC Stream)
5.2.Units
Crude Distillation Unit
The only stream of CDU that is involved in the MS Blending Process is SN (Stabilised
Naptha). The possible allocation for SN is as follows::
• As Product
• To Blend MS BS3
• To Blend MS BS92
• To Blend MS Exp
• As Feed to NHT
Naptha Hydro Treater (NHT)
The Feed for NHT is obtained from the CDU stream SN. The outputs from NHT are as
below:
• Gas
• LN
• HN
• As Product
• To Blend MS BS3
30 Sunil S Pillai
Refinery Revenue Optimization
• To Blend MS BS92
• To Blend MS EXP
• Stored in Inventory
• As Feed to CCR
The detailed possible allocations for each of the FCC Streams are shown below:
Continuous Cracking Regenerator (CCR)
CCR can be run in two modes:
• Domestic
• Export
• H2
• Gas
• LPG
• Domestic Reformate (in Domestic Mode)
• Export Reformate (in Export Mode)
To model this we have two CCR units, one for Domestic Operation & other for Export
Mode Operation.
• To Blend MS BS3
• To Blend MS BS92
• To Blend MS EXP
• Stored in Inventory
31 Sunil S Pillai
Refinery Revenue Optimization
Fluid Catalytic Cracker (FCC)
As mentioned in the HSD Blending Model two output streams of the FCC are used in
MS Blending. They are:
• LG
• MG
• To Blend MS BS3
• To Blend MS BS92
• To Blend MS EXP
• Stored in Inventory
5.3.Products
The main products of the MS Blending Model are:
• MS BS3
• MS BS92
• MS EXP
• FRN
• LN
• NHT HN
• Domestic Reformate
• Export Reformate
• LG
• MG
• Density
• Research Octane Number (RON)
• Motor Octane Number MON
• Reid Vapor Pressure RVP
• Sulphur
32 Sunil S Pillai
Refinery Revenue Optimization
• Benzene
• Olefin
• Aromatics
• Recovery @ 70°C
• Recovery @ 100°C
• Mercapatan
• Vapour Lock Index VLI
• Anti-knocking Index AKI
• Reid Vapor Index (RVI)
Other Products
The other products involved in the MS Model are:
Naptha
The Naptha is sourced from two sources:
Naptha is directly sold as a product in Tons & reflects in the Revenue calculation of
the model.
GAS
Gas is obtained from the CCR unit. The total gas in the model is from
The gas is directly sold in Tons. It gets reflected in the Revenue calculation part of the
model.
LPG
LPG occurs as a product of CCR. Hence it has two sources in the model
• LPG (CCR- D)
• LPG (CCR- E)
33 Sunil S Pillai
Refinery Revenue Optimization
The LPG is directly sold in tons. It appears in the Revenue calculation part of the
model.
5.4.Inventory
MS is produced in batches. This is because the MS parameters RON & MON are
non-linear in nature. They change with the feed composition. So MS cannot be
blended online. Hence batch blending is done for MS. For this, Inventory of the
components has to be made. The MS Blending Model also provides for the
Inventory. The opening Stock can be entered into the model. This is added to the
produced quantity of Components to obtain the net availability of the components.
The Minimum & Maximum Quantities to be maintained in the Inventory can also
be specified. The optimizer will output the optimum inventory level for each of the
component streams. Usually the inventory limits remains constant throughout the
year.
5.5.Inputs
The Input to the model comes from the CDU & FCC.
5.6.Outputs
• Total Revenue
• Optimum allocation of the Unit Products
• Optimum Unit Throughputs
• Optimum Inventory Level for Each of the Components
34 Sunil S Pillai
Refinery Revenue Optimization
6. Integrated HSD MS Blending
The HSD Blending Model & MS Blending Model is combined to provide a higher level
of optimization. All the elements of the both the models are present in the Integrated
Model. In addition it incorporates two new features:
• Material Balance
• Hydrogen Back Calculation
6.1.Material Balance
Mass is neither destroyed nor created. So what goes in should come out in one
form or another. Material balance helps us account for the total raw material
utilized by the refinery.
6.2.Hydrogen Accounting
Hydrogen is an important Raw Material for Refinery. All over the world, there is
a shift towards low sulphur products. Hydrogen is important for these low sulphur
products. Production cost of hydrogen is very high so it has to be used optimally.
1) Fixing CCR according to H2 would mean more / less CCR product availability
to MS blending.
35 Sunil S Pillai
Refinery Revenue Optimization
Earlier attempts to solve the problem in micro mode involved use of iterations &
loops leading to a less than perfect solution. We directly provide the hydrogen
situation as a constraint to the optimizer. To meet our objective of maximizing the
revenue, we provide an alternative route to H2 of being flared. Since this flaring
does not fetch any revenue, the optimizer minimizes the H2 flared while not
adversely impacting other units.
Objective
The main objective of the integrated model is to optimize the combined Revenue
from both the Models. It also incorporates all other objectives of both the models.
36 Sunil S Pillai
Refinery Revenue Optimization
7. Tank Correction Model
The operations execute the plan with utmost adherence. However in practical situation
the planned results are not fully achieved. The variance of +-1% is expected. Hence the
final product parameters achieved in the tank may not meet the desired specifications.
When such a case is verified by the lab results, the tank has to be corrected. Content
from the available tanks are transferred to the correction tank in such a way that the
final content of correction tank meets the product specification.
Objective
Given
• A tank to be corrected
• A set of Available tanks with products
• A set of Parameters of products in the tank
• A set of desired parameters
Determine
• The volume to be transferred from the available tanks to the correction tank so
as to correct it.
In order to
Subject to
The model requires the user to input the available volumes in the tanks along with the
parameters of its content. The tank to be corrected is also included with the input
tanks. The desired final parameters required in the correction tank are to be specified.
With this data, the model will determine the minimum volume of products that are to
be transferred from the input tanks to the correction tank.
37 Sunil S Pillai
Refinery Revenue Optimization
8. Applications
8.1.Monthly Plan
Refinery Operations are guided by the Rolling Plan. The Rolling plan is a 4
monthly operational plan generated using PIMS software. The PIMS model utilizes
13000 variables & 12000 Constraints to set directions for Refinery Operations.
Simultaneously, a monthly plan is developed for product optimization. The monthly
plan sees to it the overall objectives of the rolling plan are achieved. The monthly
plan sets directions for the daily plans. The daily plans are implemented by the
operations as per the inputs from EPS. The HSD Blending & MS Blending model
developed as a part of this Exercise are meant to replace the current monthly
models.
The daily plan derives the direction from monthly plan. The daily plan takes
into account the actual situation of the plant, the changes in the crude blends, the
performance of units & any other unexpected deviations. Due to these
considerations the daily plan may not strictly resemble the monthly plan but
overall direction is guided by the monthly plan. Both monthly & daily plan set the
blend ratios for the products albeit for different time periods.
8.2.Quality Targets
The model can also be used to back calculate intermediate properties. This
helps to set quality targets for the units. Now we shift the focus from the final
product quality to the intermediate’s properties. Instead of trying to hit the product
parameters with the available intermediates, we try to fix the product parameter &
develop intermediate’s properties so as to meet the set product specifications.
These Intermediate Quality targets are revised weekly.
8.3.Stream Deviation and Quality Giveaway Reports & Targets
The model can also be used as a basis for setting unit throughputs. These
targets are set daily and are reflected in the Stream Deviation & Quality giveaway
Target reports. The daily report also tracks the performance over the last 24 hours.
The quality giveaway results in loss of revenue to the refinery.
38 Sunil S Pillai
Refinery Revenue Optimization
9. Analysis
The economics decide which component to be routed to which product. However these
are limited by the product specifications. The model helps us take several such calls.
Some of the possible decisions are detailed here.
9.1.Intermediate Properties
RVP: Based on daily LPG-MS Price Differential
A particular high sulphur component is used for HSD Blending. It can also be
diverted to MS Blending. However such a move’s feasibility depends on the HSD-
MS price differential. Again this component can be dumped into MS only till its
sulphur is hit. Beyond this no more addition is possible although MS fetches more
revenue.
9.2.Final Product Properties
The final product parameters have been given a desired range in which they can
lie. Now whether to hit the extreme ends of the range depends on economics. The
Naphtha –MS price differential determines the RON value realized by the model. If
the differential is positive the n Minimum RON is achieved. If the price differential
turns positive more of naphtha is backed out from MS till the Max value of RON is
hit
39 Sunil S Pillai
Refinery Revenue Optimization
10. Assumptions
10.1. Prices
Refinery Revenue is calculated on the basis of the final product prices. The
product price used by the plan is not the price at which it is sold. The price
scenario for MS & HSD is highly volatile. As a result the price fetched by the
product may not be same as the one used in plan. This difference is reflected in
Plan vs Actual Delta. The product is usually sold at a price in 5days from the BOL.
This reduces the plan prices to a best approximation of the prevailing prices. So for
revenue optimization the model assumes that the product is sold at plan prices.
10.2. Yields
10.3. Intermediate Properties
40 Sunil S Pillai
Refinery Revenue Optimization
11. Limitations
Processing Speed
The speed of system used to solve the model would determine the time required to
arrive at a solution. With some typical data sets, the amount of computation required
would be huge. Most solvers have inbuilt max solving time limits. If a solution is not
found in the given time limit, it aborts the attempt. This is to ensure that the system
resources are not tied up with the solver.
Solver
The Solver used will determine the accuracy of the results. The ability of a solver to
find global solutions to non-linear problems will limit the applicability & extent of
usefulness of the model.
Dummy Prices.
The HSD model uses dummy prices for products which are not directly linked to the
HSD Blending model viz Coke, LG & MG. This will impact the value realized for the
FCC products and hence the FCC throughput. It also doesnot account for SN
revenues, however it will not impact the results as it is a direct output of CDU. But the
Integrated model takes care of that.
Scope
The model is limited in its scope in the sense it does not attend to all the variables.
The Aspen PIMS model utilizes more than 13000 variables & 12000 Constraints
41 Sunil S Pillai
Refinery Revenue Optimization
12. GLOSSARY
42 Sunil S Pillai
Refinery Revenue Optimization
13. Bibilography
43 Sunil S Pillai