Márcio Manháes G. de Almeida, Andrea P. Kotchetkoff Neto, Adilson S. Mendonça, Ricardo R. Alvarez, and Marcello P. Castro, Petrobras-Transpetro, Rio de Janeiro, Brazil

The São Paulo–Brasília Pipeline (OSBRA) pipeline is a 964-kilometer system which supplies over 6,000,000 cubic meters per year of gasoline, diesel oil and LPG to Brazil’s midwest region. Products on the pipeline are pumped 24 hours a day and 365 days a year on a scheduled basis from the Planalto Paulista Refinary (REPLAN) to five medium-sized cities through six remote operated pumping stations located along the pipeline. OSBRA pipeline operations include pumping, valve operation and tank farm monitoring, and these tasks are performed remotely from the Petrobras Transporte S/A–Transpetro national pipeline control center (CNCO) in Rio de Janeiro.

A real time leak detection system (LDS) was supplied and installed at this pipeline control center. The LDS is based on measurements of flow, pressure and density as well as pump and valve status along the pipeline. A SCADA system was implemented and field instrumentation measurements were observed in order to provide good quality data for the pipeline operation and its LDS. Assembling of some field instruments was improved in order to correct measurement failures. On-desk simulations were performed in order to verify theoretical system performance, and the operations team was trained to use the leak detection tool.

Lastly, a field-controlled leak simulation test was performed in order to validate and verify the system performance. The goal here is to describe how the OSBRA LDS test was planned, programmed, commissioned and performed.

Pipeline system description

The OSBRA system was placed in service in December 1996, when diesel oil was received at Senador Canedo tank farm. OSBRA consists of two piping systems. The initial piping transports liquid hydrocarbon from REPLAN Refinery to Senador Canedo tank farm in a 786-km, 20-in. pipeline system. The second piping transports liquid hydrocarbon from Senador Canedo tank farm to Brasília tank farm on a 178-km, 12-in. pipeline system.

Both systems can operate independently, but 90% of the (operations) time, they are interconnected. There are three tank farms connected to the pipeline between REPLAN and Senador Canedo; they are the Ribeirão Preto, Uberaba and Uberlândia tank farms and pumping stations. There are also two unattended pump stations on OSBRA initial piping systems: Pirassununga, between REPLAN and Ribeirão Preto, and Buriti Alegre, between Uberlândia and Senador Canedo (Figure 1). Batches of diesel oil and gasoline produced at REPLAN refinery are pumped on a regular basis. The amount of each batch is defined in order to allow pipeline liquid hydrocarbon take off at Ribeirão Preto, Uberaba and Uberlândia intermediary tank farms, leaving some amount to supply the Senador Canedo and Brasília region.

As noted, the OSBRA system currently moves around 6,000,000 cubic meters/year of diesel oil and gasoline to Brazil’s midwest region. LPG is not transported on a regular basis due to the high amount of unspecified of LPG/ gasoline interface generated during transportation. Projects are being developed in order to improve efficiency of the interface treatment unit at Senador Canedo tank farm, so that LPG transportation through OSBRA can be re-established on a regular basis.

OSBRA SCADA system

The OSBRA SCADA system acquires field information (including possible threats to integrity), and displays and registers that information to the appropriate operations personnel. The system also enables control room operators to command valves, pumps and other equipment on field installations. Field data and commands include:

  • Tank and vessel level, temperature, density and flow
  • Pressure, flow, density and temperature on internal lines and pipelines
  • Control and block valve position, including set up of PID control parameters
  • Pump and compressors status and commands
  • Equipment protection devices status, like pressure, temperature and vibration
  • Liquid hydrocarbons interface and pig detection
  • Electrical measurements
  • Communication status.

The OSBRA SCADA system is designed to function on two hierarchical operation levels. The basic operation level is implemented at the so-called mini-master operation stations which are located at the local control room of each OSBRA tank farm. The mini-master operation stations are mainly designed to allow operation of tank farm facilities, truck loading and unloading, pipeline transfer from OSBRA tank farm to tank farms of distribution companies, liquid hydrocarbon quality control, electrical substation, tank draining, effluents and fire system.

The higher operation level is implemented at the CNCO, which is responsible for the operation of Transpetro’s pipelines. The remote operation includes pump alignment, start and stop, flow and pressure control at main pipeline and to intermediate tank farm take off, batch tracking, tank alignment and level monitoring. The OSBRA LDS is installed at the CNCO operator console. Whenever is necessary, it is possible to operate from the mini-master station the local OSBRA pipeline pump station. Normally, this task is performed from CNCO, but it can be delegated to the mini-master station in case of data communication failure.

Leak detection system

The OSBRA LDS is a real-time transient model which compares the model directly against measured field data. This system was modeled and parameterized according to OSBRA characteristics, and considered in operational condition by Transpetro after being tested to alarm state with simulated commodity removal. This test was done upon edition of the LDS configuration parameters to simulate commodity loss (software simulations) as stated in API 1130, item 6.2.1. CNCO Operators were trained in order to use this special tool on a routine basis. Briefly, a leak alarm is indicated if over the averaging period the diagnostic flows indicate a sufficiently large outflow from the system.

The OSBRA LDS is a transient hydraulic modeling service that simulates dynamic flow of batched fluids of a single phase through a pipeline. It reads text files containing detailed data that represents the pipeline (including pipes, pumps and valves). Using these text files, the system constructs a mathematically sophisticated model. The LDS performs its simulations by calculating flow, pressure, density and temperature at six locations along the OSBRA pipeline model over time, and reports these values in the form screen reports and graphs. The field instrument data comes from the following locations shown in Figure 1: REPLAN refinery, and the Ribeirão Preto, Uberaba, Uberlândia, Senador Canedo and Brasilia tank farms and pump stations. The software compares the measured data for the five segments of pipeline, defined by the field instrument as mentioned with its corresponding modeled conditions. The system simulates the behavior of a pipeline using real data from a SCADA system. When a leak is detected, the system raises an alarm that shows the leak location, the onset time, the leak rate, and the total volume released, associated to an assigned confidence level to the leak.

LDS field commissioning

Prior to test planning, all installations and resources necessary to proper function of the LDS were verified and checked in detail. Field instrumentation associated to OSBRA LDS was listed, checked and calibrated at each pump station and tank farm. SCADA parameters, like instrument range set up, related to each field instrument were checked, both at the PLC and supervisory system, in order to guarantee that the LDS was acquiring true field measurements. Communication parameters were also verified in order to assure that data from PLC on tank farm control room was being sent on time to the CNCO supervisory system, and from there to the LDS. This apparently simple task, which began in April 2001, proved to be quite complex, and took about three years to reach to an acceptable condition.

At field instrumentation level, although remote operation of OSBRA pipeline was being performed a satisfactory level, a long punch list was issued after field check up. These action items included:

  • Install a missing densitometer at Senador Canedo tank station
  • Repair two densitometers in Senador Canedo and Uberaba tank farm (the Uberaba tank farm densitometer had a failure on its temperature meter)
  • Repair Brasília tank farm temperature transmitter
  • Change electrical-hydraulic actuators of control valves, which had intermittent failures
  • Tuning control valves of all pump stations and tank farm inlet lines, so it can operate in automatic mode
  • Modify pipeline installation of ultrasonic flow transmitters at Brasília and Ribeirão Preto inlet lines in order to guarantee reliable measurements at any operational condition
  • Make set up adjustments on the Uberlândia tank farm inlet ultrasonic flow transmitter
  • Repair and change several pump station and tank farm block ball valves.

After commissioning of field instruments and integration of the leak detection and SCADA systems, personnel started to gather the process data in order to allow satisfactory parameterization and tuning of the OSBRA LDS.

Field test planning

Although editing of the LDS configuration parameters to simulate commodity loss helped verify the model designed and parameterized for the OSBRA pipeline, a real field test was still needed. This test would be based on actual removal of test quantities of the commodity from the line. It would also validate the system, and give Transpetro’s managers and operators the confidence to use this specialized tool. This method has also been applied on other Transpetro’s OPASC, ORSUB and ORSOL pipelines. API 1130 states on item 6.2 that “prior to testing, careful planning should be considered.” The following items detail every operational step that was done during both the planning and test phases. We expect that this level of detail will be useful to help others to implement the field activities that are necessary to perform an LDS test with actual commodity removal.

Kick-off planning meeting

The kick off planning meeting occurred at Transpetro’s head office in September 2004. The Buriti Alegre pump station was selected as the appropriate place to conduct the first field test. The main reasons for this choice were:

  • The distance between the Uberlândia and Senador Canedo tank farms comprises the largest pipe segment among OSBRA’s tank farms and pipeline flow meters.
  • The Buriti Alegre pump station is located in the middle distance between Uberlândia and Senador Canedo tank farms.
  • The process conditions of this pipeline segment were considered as the most important for the OSBRA LDS model.

It was assumed that should the LDS perform properly on Uberlândia to Senador Canedo tank farm segment, it would also do so for the total length of OSBRA pipeline. Other main definitions agreed on the kick off planning meeting were:

  • The test should verify system performance for leaks equivalent to 10% and 5% of the typical flow condition of this pipeline segment (550 m3/hr).
  • Tests should be performed with diesel oil, which is considered safer to handle comparing to gasoline and LPG.
  • Internal prior experience on performing tests of LDS should be gathered prior to the next test in other to avoid prior mistakes.

Second planning meeting

A test planning for the OSBRA pipeline based on documentation of previous similar tests was issued in December 2004. This document was used as a baseline for the second planning meeting held in January 2005. Representatives of each area that should take part or contribute to the field test were invited for this meeting, which included the following teams: engineering and technical support, CNCO personnel, tank farm operators, maintenance, pipeline inspectors, safety and environment technicians, reliability, logistics and other individuals with previous experience in these matters. The following topics were discussed on the second planning meeting:

  • A brief review of OSBRA Pipeline, its installations, operational conditions and LDS.
  • A detailed history of a previous LDS test performed at OPASC pipeline.
  • A detailed description of the Buriti Alegre station, including safety, environment and emergency considerations.
  • The test plan was read and commented upon during the meeting in order to provide to the representatives of the whole team a full understanding of the test and its importance.
  • Design and assembling of piping, instruments, control and block valves to allow controlled take- off of liquid hydrocarbons.
  • Explanation of field test conditions, expected pipeline flows and leak detection alarm time, considering leaks equivalent to 15 and 10% of line flow.
  • Participants of the field test team, including quantities and personnel qualification.
  • Punch list revision.
  • Personnel transportation, meals and accommodation.
  • Preliminary safety task analysis for installation assembling, field test performance and disassembling.

Test conditions were established based on actual normal pipeline operational conditions for the Uberlândia–Senador Canedo segment like flow rate and pipe pressure at segment ends. Expected leak detection volume and alarm time for the field test were defined upon results obtained from the edition of OSBRA LDS configuration parameters to simulate commodity loss at Buriti Alegre pump station. The obtained values from software simulations were analyzed and validated by engineering personnel as acceptable values to be used as criteria for field test with actual removal of hydrocarbon liquids, as far as there is not a specific national regulatory requirement for such system (Figure 3).

Final planning meeting

A field inspection was performed on August 23rd at Buriti Alegre pump station in order to verify the take off piping assembling conformance, to review the punch list and check for safety conditions. The third and final planning meeting was held August 31, 2005, after all requirements agreed previously were completed and the main field installation was assembled and ready for the leak detection test.

The following topics were discussed on this meeting:

  • Documentation review, including planning, operational procedures, on desk simulations and safety analysis.
  • Punch list review.
  • Presentation of piping, instruments and valves assembled in Buriti Alegre station.
  • Field and CNCO communication.
  • Emergency phone list.
  • Tank truck requirements and quantities.
  • Field and CNCO teams.
  • Test performance dates.

Communication

Communication was considered an important requirement to allow test performance on a safety basis. Buriti Alegre is an unassisted remote operated pump station that, due to OSBRA operational requirements, was not yet commissioned to operate. The CNCO had no real time process variables available from this site on its SCADA system. A communication procedure was agreed in order to offer the CNCO operator an adequate monitoring of the leak simulations that should be performed at the Buriti Alegre station. The field operator was required to inform the CNCO operator of every event, including valve operations, leak flow and pipeline pressure. A CCTV system was proposed to provide the CNCO operator and the technical support team a real time view of the field activities. The telecommunications department offered to install and give permanent field support on local radios, wireless phones, cell phones and the video monitoring system.

LDS test procedure

In accordance with the test plan, a test procedure was issued to coordinate the CCO and field activities. The test procedure included the following orientations:

  • Leak detection should be performed by a controlled take-off of liquid hydrocarbon from the OSBRA pipeline, so that LDS performance could be verified.
  • CNCO and field operators should communicate by Petrobras internal telephone or public cell phones, as needed.
  • Test conditions should represent normal OSBRA operational steady-state conditions. Pipeline pressure and flow should be representatives of OSBRA daily operational conditions.
  • Test date should be defined after assembling and testing of the take off piping upon field and pipeline programming teams’ agreement.
  • The LDS test should verify simultaneously the performance of two installed licenses: one parameterized by the supplier and the other by Petrobras.
  • Test program should verify system performance for leaks of gasoline and diesel oil.
  • CNCO should register on its SCADA system the flow, pressures and batch volumes in each OSBRA pipe segment.
  • Field operators should record on a prepared table the following variables: initial and final test time, local pipeline pressure, control valve position, pipeline take off flow and volume.
  • The leak detection expected time and volume should be informed to CNCO and field operators prior to field test by means of on-desk real time simulation. The maximum test time and volume will be three times the expected values.
  • The LDS test should conform to the following program:
    • 1st Day – Flow meter pre-test during a controlled hydrocarbon liquid take off from OSBRA pipeline to a tank truck.
    • 2nd Day – Gasoline leak test by controlled take off equivalent to 5% and 10% of actual pipeline flow.
    • 3rd Day – Waiting time until the next diesel oil batch approaches the Buriti Alegre pump station.
    • 4th Day – Diesel oil leak test by controlled take off equivalent to 5% and 10% of actual pipeline flow.

LDS test implementation

The pipe conditioning and system test was conducted from September 27th to September 30th, 2005.

First day. The main field activities on the first day were: piping blind removal, piping leak test, assembling and parameterization of ultrasonic flow meter (Figure 3).

Second day. The following activities were executed on the second day:

  • On-site meeting for introduction of field personnel and its tasks, work planning, safety preliminary analysis and test procedure reading and punch list review.
  • Flow meter set up.
  • Sump tank drainage.
  • Emergency wagon kit positioning (Figure 4).
  • Vacuum truck positioning.
  • Radio, cell phones, wireless phones and video monitoring testing.
  • Chemical restroom assembling.
  • Tank truck positioning.

Third day. The following activities were executed on the third day:

  • Notebook and flow meter communication set up.
  • Drainage of take off line to sump tank in order to avoid product contamination.
  • Tank truck hose and grounding coupling.
  • Pipeline flow stabilization at 630 m3/hr. Editing of LDS configuration parameter to simulate hydrocarbon leak equivalent to 10% of pipeline flow rate in order to establish the expected time and volume for the actual removal field test.
  • A waiting time is always necessary to reset the LDS before a new test can be done.
  • OSBRA 10% LDS actual removal field test for gasoline at the following condition:
    • Pipeline flow rate: 630 m3/hr.
    • Take off flow rate: 66 m3/hr.
  • Pipeline flow stabilization at 440 m3/hr. Editing of LDS configuration parameter to simulate hydrocarbon leak equivalent to 5% of pipeline flow rate in order to establish the expected time and volume for the actual removal field test.
  • OSBRA 5% LDS actual removal field test trial. Test was aborted after 36 minutes due to tank truck hose coupling leak observed when the second tank truck was aligned to test system (Figure 5).
  • New OSBRA 5% LDS test for gasoline succeeded trial. Test was performed with the following operational condition:
    • Pipeline flow rate: 440 m3/hr.
    • Take off flow rate: 24.6 m3/hr.

Fourth day. On the fourth day, an OSBRA 5% LDS test trial for diesel fuel was performed at the lowest operational flow condition for the Uberlândia–Senador Canedo pipeline segment, which flows at 360 m3/hr. Such trial was not implemented due to simultaneous pigging operations performed at the REPLAN–Ribeirão Preto pipeline segment, intermittent pump failures at REPLAN, and communication failures at the Pirassununga pump station. All these events inhibited the stabilization of OSBRA pipeline operational conditions, and a shutdown was necessary for equipment maintenance.

As a result of this shutdown, an unpredictable LDS test was agreed between the field personnel and the CNCO operators. The LDS was to be tested during pipeline shut-in and tank truck loading up operation (Figure 6). This test was performed with a 44 m3/hr pipeline take off flow. The test plan was then considered complete, and the piping system was re-commissioned to leave Buriti Alegre pump station in a safe condition. This included the following tasks: line drainage, sump tank emptying and blind reinstallation at the pump station main inlet block valve.

LDS test results

The test take off flow rate measurements were accomplished by a clamp-on ultrasonic flow meter installed at the Buriti Alegre pump station take off line. This flow meter was connected by serial cable to a notebook which registered the take off flow rate and accumulated removed volume. During test performance, data was acquired and registered on field every 30 seconds.

The clamp-on ultrasonic flow meter was used only to control the take off flow rate and calculate the actual removed hydrocarbon liquid volume from pipeline. Automatic synchronization was not implemented between the clamp on ultrasonic flow meter and the SCADA systems, but time delay (around 30 seconds) between both was observed during verbal communication of field and CNCO personnel.

Registered start and end test time is based on the SCADA clock. SCADA screens with operational variables were hard copied at test start up and leak detection alarm moments. The expected values listed in Tables 1 and 2 are based on software simulations for the same field test condition obtained upon edition of the LDS parameters, to simulate the hydrocarbon loss at Buriti Alegre. On-desk calculations showed that a 65 m3/hr leak flow rate from a 18 Kgf/cm2 internal pressure pipeline to open atmosphere should be achieved from a 4.7 cm2 hole at the pipeline surface. On-desk calculations also showed that a 25 m3/hr leak flow rate from a 15 Kgf/cm2 internal pressure pipeline to open atmosphere should be achieved from a 1.9 cm2 hole at the pipeline surface.

Conclusion

The OSBRA LDS test demonstrated that both parameterized licenses (from the supplier and Petrobras) reached the on-desk simulated expected values relating to leak alarming time and leak volume. On the other hand, there were some problems with the leak detection tool. Location errors varied from 38 to 287 km. On some occasions, the leak location exceeded the pipeline limits. This type of problem was also observed on the ORSUB, OPASC and ORSOL pipelines already tested by Petrobras.

Detailed planning was considered by the whole team as a successful factor for good test performance. Applying previous internal company experience helped prevent failures and reduce risk for this non-routine task. The planning meetings were an important part of this process, especially since they helped disseminate information as well as motivate members of the project team. A written and detailed test plan includes test scope, installation description, task responsibilities, punch list and procedures. The on-site meeting held prior to test performance was useful to provide field personnel a wide understanding of the activities to be performed as well as their task limits, turning coordination an easy task.

The clamp-on ultrasonic flow meter associated to a notebook was useful for field test monitoring, and to determine the pipeline take-off volume. However, it is important to say that its measures should always be compared to a known volume in order avoid substantial errors due to uncertainties on pipe dimensions, sensors distance and parameterization errors. A 10% measurement error was observed when measured values were compared to the known volume value of the tank truck. Such error was used to calculate a correction factor used over the registered values.

The installation of CCTV cameras at Buriti Alegre pump station and a monitoring system at the CCO provided its operators and office team with a good visualization of field activities and conditions. It also worked as a motivating tool to remind field personnel about continuous care on safety aspects, since they knew the field team was being constantly observed by office personnel. The wireless phone system gave the field team good mobility to perform their tasks and keep in touch with the CNCO operators.

Recommendations

Planning and programming are key factors where non-routine tasks are carried out. A successful LDS test requires previous knowledge of process conditions which will be simulated in order to determine tank truck volume requirements as well as expected alarming time. Several on-desk simulations considering different leak conditions were performed a few months during the planning test period, before the real leak detection test. These on-desk simulations proved to be useful for test planning and programming. However, to get a more precise expected alarming time and leak volume, on-desk simulation were required before the real leak test, so that the on-desk simulation would be performed with actual process conditions. Such decision resulted in two to three-hour waiting period before each leak test. This procedure limited the number of leak tests that can be performed during daylight, usually to two tests per day. On the other hand, simulations done during the planning test period did not result in values significantly different from those obtained during the real leak detection test. In order to improve time efficiency, the field team recommended that the on-desk simulation should be performed previously considering different pipeline process conditions. This can help reduce the waiting time needed before implementing the real leak detection test.

The leak detection test requires special attention of CNCO operator to set pipeline process conditions at expected values. Side tasks such as valve, pump and instrument pipeline maintenance, pig operation, meetings and trainings should be avoided during leak detection test. Pipeline instrument calibration should be always verified prior to a leak detection test, and CNCO operators should report any nonconformance variable readings verified at SCADA system. In addition, the flow meter used to control pipeline liquid hydrocarbon take off should be checked and compared to a known volume tank prior to real leak detection test.

Acknowledgment

Based on a paper presented at the ASME’s 6th International Pipeline Conference, held in Calgary, Alberta, Canada.