Machine Learning and Flow Assurance in Oil and Gas Production 3031242300, 9783031242304

This book is useful to flow assurance engineers, students, and industries who wish to be flow assurance authorities in t

427 60 4MB

English Pages 178 [179] Year 2023

Report DMCA / Copyright

DOWNLOAD PDF FILE

Table of contents :
Preface
Contents
1 Machine Learning and Flow Assurance Issues
1.1 Introduction
1.2 Flow Assurances Challenges
1.2.1 Wax Deposition
1.2.2 Corrosion
1.2.3 Asphaltene
1.2.4 Scales
1.2.5 Hydrates
1.3 Machine Learning Vocabulary
References
2 Machine Learning in Oil and Gas Industry
2.1 Introduction
2.2 Machine Learning in Upstream
2.2.1 Exploration
2.2.2 Reservoir Engineering
2.2.3 Drilling Engineering
2.2.4 Production Engineering
2.3 Machine Learning Advancements in the Oil and Gas Industry
2.3.1 Total S.A. With Google Cloud–Optimize Subsurface Data Analysis
2.3.2 ExxonMobil and MIT Collaborate to Detect Oil Seeps with AI-Powered Robots
2.3.3 Shell—Machine Learning Algorithms for Precision Drilling
2.3.4 Aker BP and Spark Cognition—Predictive Maintenance Increases Productivity
2.4 Challenges
2.4.1 Manpower
2.4.2 Data Availability
2.4.3 Opportunities and Facilities for Collaboration
2.5 COVID-19's Impact on the Oil and Gas Industry, and AI as a Solution Companies
2.6 Summary
References
3 Multiphase Flow Systems and Potential of Machine Learning Approaches in Cutting Transport and Liquid Loading Scenarios
3.1 Introduction to Multiphase
3.1.1 Gas–Liquid Flow Systems
3.1.2 Liquid–Liquid Flow Systems
3.1.3 Solid–Liquid Flow Systems
3.1.4 Solid–Liquid–Gas Three-Phase Flow Systems
3.2 Flow Assurance Issues in Drilling Applications (Cutting Transport)
3.3 Introduction of Cutting Transport Issues
3.4 Evolution of Various Cutting Transport Models
3.4.1 Layer Model
3.4.2 Layer Model
3.5 Empirical Model
3.6 Transient Model
3.7 Machine Learning Approaches for Cutting Transport
3.8 Flow Assurance issues in Liquid Loading Applications
3.8.1 Introduction of Liquid Loading Issue
3.8.2 Flow Pattern Analysis for Liquid Loading System
3.8.3 Prediction Models for Liquid Loading
3.8.4 Machine Learning Approaches for Liquid Loading or Gas/liquid Flow
3.9 Case Studies in Multiphase Flow Assurance
3.9.1 Conclusion
References
4 Machine Learning in Corrosion
4.1 Introduction
4.2 Corrosion in Oil and Gas Industry
4.2.1 Corrosion Mechanism
4.2.2 Corrosion Factors
4.2.3 Types of Corrosion
4.2.4 Corrosion Control
4.3 Mitigation Procedures
4.3.1 Pigging
4.3.2 Corrosion Inhibitor
4.3.3 Internal Coating
4.3.4 External Coating
4.3.5 Cathodic Protection
4.3.6 Process Optimization
4.4 Corrosion Prediction Models
4.4.1 Hydrocor
4.4.2 Cassandra
4.4.3 De Waard
4.4.4 NORSOK
4.4.5 Lipucor
4.4.6 ECE
4.4.7 KSC
4.5 Machine Learning in Corrosion
4.5.1 Weight Loss Method
4.5.2 Tafel Extrapolation Method
4.5.3 Machine Learning
4.6 Case Study
References
5 Machine Learning in Asphaltenes Mitigation
5.1 Introduction
5.2 Asphaltene Precipitation and Deposition in Oil and Gas Industry
5.3 Asphaltene Mitigation Procedures
5.3.1 Mechanical Method
5.3.2 Ultrasonic Treatment
5.3.3 Thermal Treatment
5.3.4 Bacterial Treatment
5.3.5 Chemical Treatment
5.4 Asphaltene Prediction Models
5.4.1 Thermodynamic Solubility Technique
5.4.2 Colloidal Technique
5.4.3 Asphaltene Deposition Modelling
5.5 Machine Learning Application in Asphaltenes Precipitation and Deposition Control
5.5.1 Case Study
5.6 Conclusion
References
6 Machine Learning for Scale Deposition in Oil and Gas Industry
6.1 Introduction
6.2 Source of Scaling in Oil and Gas Industry
6.3 Mechanism of Scale Deposition
6.3.1 Types of Scales
6.3.2 Influence of Impurities on Scale Formation
6.3.3 Scale Control Methods
6.4 Effect of Scaling to Equipment Pipelines
6.5 Scale Inhibition Placement
6.5.1 Scale Inhibition Placement by the Squeeze Technique
6.5.2 Pumping the Inhibitor with the Stimulation
6.5.3 Pumping the Inhibitor with Fracturing Fluid
6.5.4 Inhibitor Impregnated into Proppant
6.6 Prediction Models Available for Scale Formation Detection
6.6.1 Saturation Index
6.6.2 Inhibitor Impregnated into Proppant
6.6.3 Ion Association Theory
6.7 Machine Learning for Scale Deposition
6.7.1 K-Nearest Neighbor
6.7.2 Gradient Boosting Classifier
6.7.3 Decision Tree
6.7.4 Support Vector Machines (SVM)
6.7.5 Gradient Boosting
6.8 Applications of Artificial Intelligence in Oil Desalination Systems
6.8.1 FN Tool to Develop Scale-Formation Correlation
6.8.2 Least Square Support Vector Machine (LSSVM)
6.8.3 Scale Thickness Measurement Using Gamma-Ray Densitometer
6.8.4 Prediction of CaCO3 Scaling Using MLP and PNN
6.8.5 Prediction of BaSO4/CaSO4 Oilfield Scale Using ANN and SNN
6.9 Case Studies on Scaling Measurement Using Machine Learning
6.9.1 Effective Control of Deposition of Scale Using AI in Vacuum Pump
6.9.2 Conclusion
References
7 Machine Learning in CO2 Sequestration
7.1 Introduction
7.2 Conventional CO2 Sequestration Techniques
7.2.1 Enhanced Oil Recovery
7.2.2 Depleted Reservoirs
7.2.3 Deep Saline Aquifers
7.2.4 Unmineable Coal Seams
7.2.5 Conventional/Prediction Models for CO2 Sequestration
7.3 Machine Learning in CO2 Sequestration
7.3.1 Machine Learning in Enhanced Oil Recovery (EOR)
7.3.2 Machine Learning in Saline Aquifers
7.3.3 Machine Learning in Depleted Reservoirs
7.4 Conclusion
References
8 Machine Learning in Wax Deposition
8.1 Introduction
8.1.1 Wax Deposition in Oil and Gas Industry
8.2 Wax Deposition Mitigation Techniques
8.2.1 Mechanical Techniques
8.2.2 Heating
8.2.3 Chemical Inhibitors
8.2.4 Microbiological techniques
8.3 Prediction’s Models in Wax Deposition
8.4 Machine Learning in Wax Deposition
8.5 Wax Deposition Case Studies
8.6 Conclusion
References
9 Machine Learning Application in Gas Hydrates
9.1 Introduction to Gas Hydrates
9.2 Introduction to Gas Hydrates
9.2.1 Methane Recovery
9.2.2 Energy Storage
9.2.3 Desalination
9.2.4 Greenhouse Gas Capture
9.3 Conventional Gas Hydrate Mitigation Method
9.4 Chemical Inhibition of Gas Hydrates
9.4.1 Thermodynamic Hydrate Inhibitors (THIs)
9.4.2 Low Dosage Hydrate Inhibitors (LDHIs)
9.5 Flow Assurance Challenge
9.6 Machine Learning in Gas Hydrates
9.7 Case Study
9.8 Conclusion
References
10 Machine Learning Application Guidelines in Flow Assurance
10.1 Introduction
10.2 Data Selection
10.3 Data Representation
10.4 Model Development
References
Recommend Papers

Machine Learning and Flow Assurance in Oil and Gas Production
 3031242300, 9783031242304

  • 0 0 0
  • Like this paper and download? You can publish your own PDF file online for free in a few minutes! Sign Up
File loading please wait...
Citation preview

Bhajan Lal Cornelius Borecho Bavoh Jai Krishna Sahith Sayani   Editors

Machine Learning and Flow Assurance in Oil and Gas Production

Machine Learning and Flow Assurance in Oil and Gas Production

Bhajan Lal · Cornelius Borecho Bavoh · Jai Krishna Sahith Sayani Editors

Machine Learning and Flow Assurance in Oil and Gas Production

Editors Bhajan Lal Chemical Engineering Department Universiti Teknologi Petronas Seri Iskandar, Perak, Malaysia

Cornelius Borecho Bavoh Chemical Engineering Department Universiti Teknologi PETRONAS Bandar Seri Iskandar, Malaysia

Jai Krishna Sahith Sayani Department of Chemical and Bioprocess Engineering University College Dublin Belfield, Ireland

ISBN 978-3-031-24230-4 ISBN 978-3-031-24231-1 (eBook) https://doi.org/10.1007/978-3-031-24231-1 © The Editor(s) (if applicable) and The Author(s), under exclusive license to Springer Nature Switzerland AG 2023 This work is subject to copyright. All rights are solely and exclusively licensed by the Publisher, whether the whole or part of the material is concerned, specifically the rights of translation, reprinting, reuse of illustrations, recitation, broadcasting, reproduction on microfilms or in any other physical way, and transmission or information storage and retrieval, electronic adaptation, computer software, or by similar or dissimilar methodology now known or hereafter developed. The use of general descriptive names, registered names, trademarks, service marks, etc. in this publication does not imply, even in the absence of a specific statement, that such names are exempt from the relevant protective laws and regulations and therefore free for general use. The publisher, the authors, and the editors are safe to assume that the advice and information in this book are believed to be true and accurate at the date of publication. Neither the publisher nor the authors or the editors give a warranty, expressed or implied, with respect to the material contained herein or for any errors or omissions that may have been made. The publisher remains neutral with regard to jurisdictional claims in published maps and institutional affiliations. This Springer imprint is published by the registered company Springer Nature Switzerland AG The registered company address is: Gewerbestrasse 11, 6330 Cham, Switzerland

Preface

The use of digital or artificial intelligence methods in flow assurance has increased recently to effectively achieve fast results without any thorough training. Generally, flow assurance covers all risks associated with maintaining the flow of oil and gas during any stage in the petroleum industry. Flow assurance in the oil and gas industry covers the anticipation, limitation, and/or prevention of hydrates, wax, asphaltenes, scale, and corrosion during operation. The occurrence of flow assurance challenges mostly leads to stoppage of production or plugs, damage of pipelines or production facilities, economic losses, and in severe cases blowouts and loss of human lives. A combination of several chemical and non-chemical techniques is mostly used to prevent flow assurance issues in the industry. However, the use of models to anticipate, limit, and/or prevent flow assurance problems is recommended as the best and suitable practice. The existing proposed flow assurance models on hydrates, wax, asphaltenes, scale, and corrosion management are challenged with accuracy and precision. They are not also limited by several parametric assumptions. Recently, machine learning methods have gained much attention as the best practice for predicting flow assurance issues. Examples of these machine learning models include conventional approaches such as Artificial Neural Network, Support Vector Machine (SVM), Least Squares Support Vector Machine (LSSVM), Random Forest (RF), and hybrid models. The use of machine learning in flow assurance is growing, and thus relevant knowledge and guidelines on their application methods and effectiveness are needed for academic, industrial, and research purposes. In this book, we focused on the use and abilities of various machine learning methods in flow assurance. Initially, basic definitions and use of machine learning in flow assurance are discussed in a broader scope within the oil and gas industry. The rest of the chapters discuss the use of machine learning in various flow assurance areas such as hydrates, wax, asphaltenes, scale, and corrosion. Also, the use of machine learning in practical field applications is discussed to understand the practical use of

v

vi

Preface

machine learning in flow assurance. This book is useful to flow assurance engineers, students, and industries who wish to be flow assurance authorities in the twenty-firstcentury smart oil and gas industry. Seri Iskandar, Malaysia Bandar Seri Iskandar, Malaysia Belfield, Ireland

Bhajan Lal Cornelius Borecho Bavoh Jai Krishna Sahith Sayani

Contents

1

Machine Learning and Flow Assurance Issues . . . . . . . . . . . . . . . . . . . Cornelius Borecho Bavoh and Bhajan Lal

1

2

Machine Learning in Oil and Gas Industry . . . . . . . . . . . . . . . . . . . . . . Jai Krishna Sahith Sayani and Bhajan Lal

7

3

Multiphase Flow Systems and Potential of Machine Learning Approaches in Cutting Transport and Liquid Loading Scenarios . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Muhammad Saad Khan, Abinash Barooah, Bhajan Lal, and Mohammad Azizur Rahman

27

4

Machine Learning in Corrosion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Jai Krishna Sahith Sayani and Bhajan Lal

59

5

Machine Learning in Asphaltenes Mitigation . . . . . . . . . . . . . . . . . . . . Ali Qasim and Bhajan Lal

81

6

Machine Learning for Scale Deposition in Oil and Gas Industry . . . 105 Sirisha Nallakukkala and Bhajan Lal

7

Machine Learning in CO2 Sequestration . . . . . . . . . . . . . . . . . . . . . . . . 119 Amirun Nissa Rehman and Bhajan Lal

8

Machine Learning in Wax Deposition . . . . . . . . . . . . . . . . . . . . . . . . . . . 141 Ihtisham Ul Haq and Bhajan Lal

9

Machine Learning Application in Gas Hydrates . . . . . . . . . . . . . . . . . . 155 Ali Qasim and Bhajan Lal

10 Machine Learning Application Guidelines in Flow Assurance . . . . . 175 Cornelius Borecho Bavoh and Bhajan Lal

vii

Chapter 1

Machine Learning and Flow Assurance Issues Cornelius Borecho Bavoh and Bhajan Lal

Abstract This chapter briefly discusses the main challenges facing the flow assurance related areas in the oil and gas industry. It also provide simple fundamental definitions to machine learning vocabulary to introduce to machine learning terms. Keywords Machine learning vocabularies · Flow assurance · Hydrates · Scales · Corrosion

1.1 Introduction Flow assurance issues has increased recently owing to the recent increase in the production of oil and gas in harsh environments [1]. Most of such issue arise from the production and transportation pipelines in the oil and gas industry. The term flow assurance is the process of successfully ensuring the economic flow of hydrocarbon stream from the reservoir to the point of sale. The major oil and gas flow assurance issues include wax, hydrates, asphaltenes, scales, and corrosion, etc. [2]. The knowledge of multiple discipline studies with a combination of chemistry, multiphase hydrodynamics, thermodynamics, kinetics, and materials science. The main flow assurance issues are briefly discussed in this section for the better understanding of the entire book [2, 3].

C. B. Bavoh Chemical Engineering Department, Universiti Teknologi PETRONAS, 32610 Bandar Seri Iskandar, Perak Darul Ridzuan, Malaysia B. Lal (B) Research Centre for CO2 Capture (RCCO2C), Universiti Teknologi PETRONAS, 32610 Bandar Seri Iskandar Perak, Malaysia e-mail: [email protected] © The Author(s), under exclusive license to Springer Nature Switzerland AG 2023 B. Lal et al. (eds.), Machine Learning and Flow Assurance in Oil and Gas Production, https://doi.org/10.1007/978-3-031-24231-1_1

1

2

C. B. Bavoh and B. Lal

1.2 Flow Assurances Challenges 1.2.1 Wax Deposition The deposition of wax is a very common flow assurance issue in the petroleum industry. The deposition of wax occurs because of the precipitation of paraffin constituents in crude oil. The paraffins are mostly alkanes with carbon numbers greater than 20 [4, 5]. The precipitation of wax in crude oil flow is controlled by the operating pressure and temperature, the crude oil compositions, the flow rate, shear stress, and the crude viscosity. Wax precipitation occurance in pipelines can lead to stoppage in crude flow, leading to pipeline blockage and stoppage in production. Usually, the use of pigging, and chemical additives is preferable for wax precipitation prevention and/or removal [5].

1.2.2 Corrosion The deteriorating of metals due to chemical reactions between the metal and its surrounding is known as corrosion. The rate and form of corrosion is controlled by the type of environment (especially the presence of gaseous systems) and metals under consideration. Pipeline corrosion is one of the main causes of subsea pipeline failure. Therefore, it is very necessary to regulate and control pipeline condition to effectively predict likely failures during operations [6].

1.2.3 Asphaltene Asphaltenes are basically compounds that are polar and soluble in nature and are present in heavy crude oil fractions. Just like hydrates, asphaltene has the tendency of plugging pipelines and reservoir pores. Mostly asphaltene precipitation occurs as a result of thermodynamic conditions variations, crude viscosity, and the constituent of the crude oil. Asphaltene that contains chemical components such as carbon, hydrogen, nitrogen, oxygen and sulfide, and has aromatic cyclic structures are chemical asphaltene. Similar to hydrates, asphaltene precipitation is more likely to occur in an undersaturated, light reservoir fluid than a heavy hydrocarbon system. When asphaltenes form in pipelines and reservoirs, they mostly lead to oil production declines, higher viscosity and water–oil emulsion [7].

1 Machine Learning and Flow Assurance Issues

3

1.2.4 Scales Scales are water forming deposits formed during oil and gas transportation. This water forming deposits are formed as crystals from insoluble salt or oxides trapped in the water molecules. The precipitation of scales is a result of the incompatibility of salts molecules in owing to water their individual solubility in exceeded in water [8, 9]. These molecules become difficult to travel out, hence they precipitate and in severe cases lead to plugging. Similar to other flow assurance issues, scales formation is thermodynamically driven. Other factors such as scales forming species concentration, water quality, hydrodynamic conditions, and pH also influence scale formation. There are several existing techniques used to reduce scale formation. These are mechanical means, chemical dissolution and the use of scale inhibitors. The formation and deposition of scales can lead to formation damage and production equipment failure during the development of a reservoir. In case of waterflooding, complex geochemical processes between the injection water, formation water, formation rock, and the concentration of ions can cause operational challenges. Major contribution of scale control concentrates on understanding the conditions for scale formation and its inhibition [8, 9].

1.2.5 Hydrates Hydrates are solid inclusion crystalline substance that are icelike in nature and are formed at high pressure and low temperature conditions. Hydrate is formed in the presences of high pressure, low temperature, the presence of water, and the presence of hydrate forming molecules (gas or liquid, but most hydrate formers are gaseous) [10–12]. Common gas hydrate formers are light hydrocarbons (e.g. methane, ethane, propane, isobutane) and inorganic molecules such as CO2 and H2 S. Despite some interesting potential of gas hydrates in sea water desalination, carbon capture and storage, gas transformation and future energy source, their formation in flow assurance systems or operations are strictly prohibited and unwanted. Aside gas dominated systems, Oil dominated flowlines are proven to be prone to hydrate formation at subsea low temperatures and high-pressure conditions, thereby leading to hydraterelated flow assurance issues. The formation of hydrates in pipelines leads to production stoppage, pipeline blockage, and in very serious scenarios lead to loss of lives [13]. Therefore, for a smother flow assurance process, all these floe assurance related issues need to be avoided.

4

C. B. Bavoh and B. Lal

1.3 Machine Learning Vocabulary Since this book focuses of the use of machines learning algorithms in flow assurance, it is proper to first understand some few machine learning vocabularies. This will set a bases for readers to effectively follow the discussed in the rest of the book [14]. Some important machine learning vocabularies used in this book are explained as follows. • Algorithm: an algorithm consists of a set of commands issued to an AI, neural network to conduct a task specific job. The part of a system or neural network that engage in problem solving is the algorithm. • Artificial Intelligence: It is the capability of a system to imitate human behavior. • Artificial Neural Network: This consist of several models that learn like the human brain in systems for solving complex problems. • Big Data: Extremely large data sets that are analyzed to reveal patterns, trends, and associations related to human interaction. • Classification: This is basically algorithms used to assign categorical data set in a software. • Deep Learning: A subset of machine learning that uses specialized algorithms to model, understand and mimic complex behavior structures and relationships in data. • Genetic algorithm: An algorithm based on principles of genetics used to efficiently and quickly find solutions. • Machine Intelligence: The overall concept of machine learning, deep learning, and classical learning algorithms. • Machine Learning: An application of AI that provides systems the ability to learn and improve from experience without any specific instructions being programmed into it. • Machine Translation: Applying NLP to translate language whether via text or voice. • Pattern Recognition: Recognizing regularities in data and using them efficiently. • Recurrent Neural Network: A type of neural network that identifies sequential patterns and makes sense of sequential information. • Supervised Learning: Output datasets provide machines with information on producing a desirable result/ algorithm. • Transfer Learning: A system that uses previously learned data to do a new set of tasks. • Unsupervised Learning: A machine learning technique where the model works independently to discover information. As the name suggests, no supervision is required. The most common supervised learning method is cluster analysis.

1 Machine Learning and Flow Assurance Issues

5

References 1. Bavoh CB, Lal B, Keong LK (2020) Introduction to gas hydrates. Chem Addit Gas Hydrates. https://doi.org/10.1007/978-3-030-30750-9_1 2. Theyab M, Theyab MA, Petroleum SJ, Muhammad *, Theyab A (2018) Fluid flow assurance issues: literature review fluid flow assurance issues: literature review view project scifed journal of petroleum fluid flow assurance issues: literature review. SciFed J Pet 3. Gao H (2022) Flow assurance overview and challenges in oil and gas production 4. Wang J, Zhou F, Zhang L, Huang Y, Yao E, Zhang L, Wang F, Fan F (2019) Experimental study of wax deposition pattern concerning deep condensate gas in Bozi block of Tarim oilfield and its application. Thermochim Acta 671:1–9 5. Yang J, Lu Y, Daraboina N, Sarica C (2020) Wax deposition mechanisms: is the current description sufficient? Fuel. https://doi.org/10.1016/j.fuel.2020.117937 6. Theyab MA (2018) Fluid flow assurance issues : literature review. SciFed J Pet 2:1–11 7. Mohammed I, Mahmoud M, Al Shehri D, El-Husseiny A, Alade O (2021) Asphaltene precipitation and deposition: a critical review. J Pet Sci Eng 197:107956 8. Olajire AA (2015) A review of oilfield scale management technology for oil and gas production. J Pet Sci Eng 135:723–737 9. Jamaluddin AKM, Kabir CS (2012) Flow assurance: managing flow dynamics and production chemistry. J Pet Sci Eng 100:106–116 10. B. Bavoh C, Ntow Ofei T, Lal B, (2020) investigating the potential cuttings transport behavior of ionic liquids in drilling mud in the presence of sII hydrates. Energy Fuels 34:2903–2915 11. Bavoh C, Nashed O, Rehman A, Othaman NA, Lal B, Sabil khalik Ionic liquids as gas hydrate thermodynamic inhibitors. Ind Eng Chem Res 60:15835–15873 12. Nissa Rehman A, B. Bavoh C, Pendyala R, Lal B, (2021) Research advances, maturation, and challenges of hydrate-based CO2 sequestration in porous media. ACS Sustain Chem Eng 9:15075–15108 13. Bavoh CB, Lal B, Osei H, Sabil KM, Mukhtar H (2019) A review on the role of amino acids in gas hydrate inhibition, CO2 capture and sequestration, and natural gas storage. J Nat Gas Sci Eng 64:52–71 14. Mohri M, Rostamizadeh A, Talwalkar A (2018) Foundations of machine learnin. MIT Press. https://doi.org/10.1007/s00362-019-01124-9

Chapter 2

Machine Learning in Oil and Gas Industry Jai Krishna Sahith Sayani and Bhajan Lal

Abstract In the chapter, the use of machine learning in the oil and gas industry is briefly presented with emphases on the current trends in the oil and gas models. Also, the use of machine learning in the oil and gas upstream is discussed with highlights on the recent advancement on the use of AI in the oil and gas industry. The challenges facing the application of machine learning in the oil and gas industry is also presented. Keywords Machine learning · Artificial intelligence · Oil and gas industry · Upstream

2.1 Introduction The oil and gas industry is a massive business that includes upstream, midstream, and downstream sectors (Fig. 2.1). It is a difficult yet vital industry all over the world. It has a direct or indirect influence on our everyday lives by enabling services such as transportation, heating, and electricity, as well as various petrochemical products ranging from household items to clothing. It’s no surprise that petroleum is sometimes referred to as “black gold” because of its worth and value in human existence and the global economy [1]. At the moment, OGI organisations are looking at new methods to reduce operating costs, improve efficiency, and increase output. The challenges and dangers connected with activities and operations across the supply chain must be thoroughly handled, which necessitates the evolution of technology J. K. S. Sayani Department of Chemical and Bioprocess Engineering, University College Dublin (UCD), Dublin, Ireland B. Lal (B) Chemical Engineering Department, Universiti Teknologi PETRONAS, 32610 Bandar Seri Iskandar, Perak Darul Ridzuan, Malaysia e-mail: [email protected] Research Centre for CO2 Capture (RCCO2C), Universiti Teknologi PETRONAS, 32610 Bandar Seri Iskandar Perak, Malaysia © The Author(s), under exclusive license to Springer Nature Switzerland AG 2023 B. Lal et al. (eds.), Machine Learning and Flow Assurance in Oil and Gas Production, https://doi.org/10.1007/978-3-031-24231-1_2

7

8

J. K. S. Sayani and B. Lal

inside the OGI, particularly for data processing and administration. Digitalization of oil fields, real-time optimization of drilling operations, the use of nanotechnology, wireless sensor networks to improve gauging, reservoir modelling, and diagnostics are some examples of such technologies. According to industry research, there are enough resources available to sustain present oil production levels for at least another 50 years. Thus, the key problems that the OGI has are increasing productivity and delivering products to end customers at the lowest feasible cost. Given its worldwide character and the complexities of contracting with governments, joint ventures, and other stakeholders, the OGI also requires technology solutions for more effective data management [2]. Systems for oil field exploration, reservoir engineering, drilling, and production engineering are all part of the petroleum business. Other chemicals, such as prescription medications, solvents, fertilisers, insecticides, and polymers, are also powered by oil and gas [3]. If fossil fuel costs continue to climb, fossil fuel businesses will need to create new technologies and enhance operations in order to boost efficiency and build on current capabilities. However, as the oil fields age, they are now producing more water than oil due to waterfront arrival at shore, channeling, coning, or water breakthrough. This makes economically producing petroleum from the formation difficult.

Fig. 2.1 Breakdown of oil and gas industry

2 Machine Learning in Oil and Gas Industry

9

Furthermore, because the price of oil has not yet stabilised, fairly expensive engineering or equipment is of little interest to any oil and gas corporation. The simplest way to conserve efficiency and productivity is to optimise cumulative extraction with effective and smart technology, such as Inflow Control Devices (ICD) or Inflow Control Valves (ICV) as well as downhole sensor systems. Improved control in huge oilfields necessitates quick decision-making while keeping continuing difficulties in mind. The Smart Oilfield will do this by constructing a comprehensive oilfield technological infrastructure through the digitization of instrumentation equipment and the creation of a network-based information exchange in order to improve the production process [4]. It has become abundantly evident that digital technology has a major impact on business and society. With the passage of time, it has become clear that digital transformation is now regarded as the “fourth industrial revolution,” characterised by the convergence of technologies that blur the boundaries between the physical, digital, and biological realms, such as artificial intelligence, robotics, and selfdriving vehicles. Artificial intelligence (AI) technologies are gaining popularity due to their quick response times and powerful potential for generalization [5]. Machine learning has shown promising results in helping and improving traditional reservoir engineering techniques in a wide spectrum of reservoir engineering difficulties [6]. Various research use advanced machine-learning methods for classification and regression issues, such as Fuzzy Logic (FL), Artificial Neural Networks (ANN), Supporting Vector Machines (SVM), and Response Surface Model (RSM) [7]. Several machine-learning methods utilised in reservoir engineering are within the supervised learning category. The majority of reservoir engineering implementations include evolutionary optimization approaches such as Genetic Algorithm (GA) and Particle Swarm Optimization (PSO). The goal of the study should be to construct analytical processes by merging forward and reverse-looking AI models in order to predict the accurate solution of an inverse problem. Rana et al., for example, used forward-looking Gaussian proxy designs, Bayesian optimization, and numerical models of high-fidelity procedures to structure AI-assisted common platform workflows [8]. The new method is being used to address a problem with a coal seam degasification effort from the past. Bayesian optimization It may discover a variety of reservoir characteristic distribution solutions that suit the provided field data [9]. The authors also created a specialty approach based on ANN that uses field data from a part of the Marcellus shale gas field to help the history-matching method. It evaluated several hydraulic fracturing designs. Costa et al. employed ANN models and optimization programming to tackle a contextappropriate oilfield problem [10]. Throughout this method, forward-thinking ANN expertise systems are outfitted to replicate quantitative high-fidelity simulations in order to anticipate output data throughout the historical field period. Indeed, machine learning is employed in the petroleum business to investigate data-related issues. The educational programme was created to teach petroleum engineers via the use of machine learning algorithms and artificial intelligence tools. This gives suggestions for increasing productivity while lowering costs [3].

10

J. K. S. Sayani and B. Lal

The Gulf of Mexico oil and gas sectors have explored the impact of technology transition in oil and natural gas inspection using a specific collection of data types in a microstructured grid. The findings indicate that the technical shift with adaption of this technology has played a significant role in the offshore oil and gas business during the previous 50 years, with increased deposits and decreasing costs. Even while saturation impact remained important in the first two decades, its influence on technical advancement was adequate to compensate for the capital loss of more than 50 years of research [11]. Improving knowledge for future technological improvements through testing and innovation may result in improved predicting strategies for delivering oil and gas. Despite the fact that significant advances are possible, developers are testing field as well as regional-level systems to understand the consequences of changes in exploration technology. The progress of technology effects the discovery of new deposits, which are economically feasible sections of existing deposits, as well as the rental of capital; our research is critical for estimating mineral resources across the government revenue accounts [12]. Aside from technological advancements, certain circumstances may have a significant impact on the cost efficiency of the Clean Electricity Production from Offshore Natural Gas (CEPONG) framework [13]. Sami and Ibrahim investigated three different machine learning algorithms in order to anticipate multiphase flowing bottom hole pressure [14]. The model is constructed and tested using real-world data from an open literature collection. To evaluate the procedure accurately of the BHPs obtained using ML models and verify the work’s usefulness, a range of datasets were employed to check the correctness of the recommended models. Hazbeh et al. examined the precision and computational performance of machine learning techniques for rate of penetration in directional well drilling [15]. Hassanvand et al. estimated the rock uniaxial strength characteristics for an Iranina carbonate oil deposit using an artificial neural network [16]. Priyanka et al. did a review study on cloud computing-based smart grid technologies in the oil pipeline sensor network system [17]. The understanding of block chain technology in the oil and gas industry answers the opportunities, obstacles, risks, and developments that are analysed in this area. Block chain technology will provide several benefits to the whole oil and gas industry, including reduced payments and increased accountability and performance. The evolution of block chain technology in the oil and gas sector would then move to a modified block chain network, cross-chain, and modified smart contracts, as well as more interdisciplinary expertise [18, 19]. Casing drilling technology; modern innovations, enhanced oil recovery; synthetic, thermic, physical, and chemical techniques Microbial Enhanced Oil Recovery (MOER) and water alternating gas (WAG) processes are examples of technical changes brought about by the implementation of the block chain method in this sector. This Chapter describes cutting-edge research on the application of Machine Learning and AI approaches in the oil and gas upstream business. The primary goal of this article is to demonstrate the benefits of AI and machine learning approaches in various upstream areas. The study describes procedures that use machine learning and AI for effective computation and decision making based on a thorough understanding of this industry. This research examines how a handshake between the

2 Machine Learning in Oil and Gas Industry

11

petroleum industry and a numerical simulator with an intelligent system facilitates work and increases production.

2.2 Machine Learning in Upstream The term “upstream” refers to the production of crude oil and natural gas. It entails locating possible underground or underwater crude oil and natural gas deposits, drilling exploratory wells, and then drilling and operating the wells utilised to bring the crude oil or raw natural gas to the surface. The upstream segment is of special significance since it is the most capital-intensive and crucial of the three segments in the oil and gas industry. The increase in data processing capacities improves the performance of electronic gadgets. Computing power should be used for production and exploration in the oil and gas sectors [20]. Companies in this industry deal with large uncertainties that are managed manually and rely on specialist knowledge rather than real facts. The adage “one rock, two geologists, three viewpoints” encapsulates the enormous uncertainties and hazards that oil and gas firms face. When making multibillion-dollar decisions on where and how to spend over the next 5–20 years, the uncertainties must be addressed. Nonetheless, despite the sector’s complex and unpredictable management difficulties, single-criterion techniques have historically dominated decision-making [21]. To account for uncertainties associated with practitioners’ subjective perception and decision-making based on experience, the initial steps in employing artificial intelligence and machine learning, which are becoming increasingly popular, are made in the upstream. The report draws on findings from hundreds of AI initiatives completed with the authors’ assistance for top oil and gas upstream firms throughout the world over the previous three years. The programmes encompassed AI solutions for the whole spectrum of upstream activities, including reservoir geological evaluation, drilling optimization, reservoir engineering/field development, and production optimization. More information may be found in Table 2.1. The domination of “difficult-to-recover” oil and gas reserves during the last ten years necessitates new operational approaches and economic models in hydrocarbon exploration and production, aimed at assuring acceptable oil and gas production profitability. Both well-developed (brownfields) and recently discovered (greenfields) subterranean hydrocarbon reserves fall within this category. Despite the fact that the vast majority of brownfields are reasonably large geometrically and have adequate transport and storage qualities (porosity and permeability), the volume of oil and gas recoverable with cheap waterflooding is fairly little. All traditional brownfields, in theory, produce more water than oil. To maintain production levels, operators must spend enough money on one of the following operations: additional drilling, well treatment (e.g., hydraulic fracturing), or field-scale enhanced oil recovery procedures (e.g., increasing the mobility of remaining oil in the reservoir with chemical cocktails

12

J. K. S. Sayani and B. Lal

Table 2.1 Non-confidential overview of projects completed with the authors’ direct involvement Upstream activity

Developed tool

Geological assessment

A tool for automatically mapping reservoir rock parameters over an oil area

AI approach Non gradient optimization + interpolation techniques

Main effect Acceleration

De-risking

Speeded up the manual mapping procedure from several weeks to several seconds

Removing human mistakes that cause incorrect mapping Means a more precise determination of the proper hydrocarbon targets

Geological Gradient information may boosting be extracted from well records using this tool

100 + times speedup

Rock typing software based on photographs of rock samples taken from wells

~1.000.000 + times speedup

Deep neural networks

Drilling

Detects the kind Combination of of drilled rock machine learning and likely failure algorithms using real-time drilling telemetry

Up to 20% time saving and up to 15% money savings at well construction

Reservoir engineering

A tool for speeding up traditional reservoir simulations

Deep neural networks

Accelerating by a Making it feasible factor of 200–2000 to filter through a significantly larger number of field development scenarios in order to find the best one

Production optimization

Data-driven technique for predicting the efficacy of well treatment initiatives objectively

Gradient boosting + expert-based feature selection

100 + times faster estimation of the well treatment effect

Increasing the amount of contact between the wellbore and the pay zone

Up to a 20% increase in the marginality of campaign investments

injection). In many situations, the money spent on these activities does not pay off, allowing brownfields to die slowly. The situation isn’t much better in terms of new discoveries. Almost all of the recently discovered hydrocarbon sources are difficult to access. It’s possible they’re [22]: • In harsh environments (e.g., the Arctic shelf) • Complex in geometry (e.g., thin and winding layers of oil-saturated rocks with many cracks)

2 Machine Learning in Oil and Gas Industry

13

• Under a thick layer of seawater and salt minerals (e.g., offshore Brazil) • Poor in permeability (so that the hydrocarbon is nearly immobile within the reservoir rock). The development of these greenfields necessitates costly technologies, putting the profitability of future oil production in jeopardy. Decision-makers manually and based on specialist knowledge, not actual data, handle uncertainties associated to long-term and high-value investments in the oil and gas upstream. In this situation, they must respond to two major questions. First and foremost, is this a unique asset perspective? Will we spend money on geophysical research to evaluate the asset’s potential? This topic is often answered through a geological modelling and reservoir modelling workflow, which can take anywhere from a few months to several years, depending on the need for further geophysical surveys and the complexity of in-house techniques. The second question is whether I should invest in increasing oil output at my asset. If that’s the case, which technologies are worth investing in? Experts are mostly in charge of this issue, and they are backed up by evidence. By using traditional reservoir modelling tools, we can get a good idea of how much water is in the reservoir. A strong reliance on professional opinion, as well as a lack of suitable input data for the traditional modelling techniques produce skewed and ambiguous results. AI systems that have been trained with the appropriate field data can help with both questions by speeding up the asset assessment process and making it more objective or expert independent. The next part discusses the first steps in this direction as well as future potential.

2.2.1 Exploration Exploration for hydrocarbons is fraught with danger. Explorationists must accurately identify subsurface potential in order to drill and utilise hydrocarbons. Limited 2D seismic data were used in the early twenty-first century to pinpoint drilling locations based on subsurface mapping. Because it is fraught with danger, the odds of success were 1:7. With the passage of time, new data was collected in each of the leases that were curved out for investigation. With advances in seismic and well data gathering, processing, and interpretation, this vast volume of data was dubbed “big data,” and it was stored in Terabytes of memory space. The machine learning idea was used to analyse the vast data. The goal of using big data and applying machine learning during collecting and processing is to enhance the signal to noise ratio. Using several robust methods, the clean data was used to interpret 2D, 3D, and 4D seismic. By combining well logging with accurate mapping of multiple subsurface horizons, an interpreter was able to prepare subsurface volume maps and turn them into amplitude, porosity, and saturation maps. To interpret the data parameters from the subsurface models, inversion techniques were used [22].

14

J. K. S. Sayani and B. Lal

Machine learning techniques assisted in the construction of horizon and window based features in order to grasp the sweet spots over time. Machine learning has produced new qualities such as coherency, edge map, spectral decomposition, and relief map. Understanding fault polygons, mapping complex fault structures, and facies mapping utilising striatal slicing increased subsurface prospect understanding. Prospects were converted into drillable prospects using machine learning algorithms, increasing the possibility of success to 1:3. The use of 4D seismic or repeat seismic assisted an interpreter in determining the hydrocarbon transport following drilling [23]. Artificial neural networks and heuristic methods are increasingly widely used to refine target prospects, their size, and hydrocarbon volume. Monte Carlo simulation and Evolutionary programming techniques are used to calculate a stochastic range of hydrocarbon in the subsurface and how much can be extracted and brought to the surface. In short, machine learning has ushered in a paradigm shift in India’s and the world’s exploration and production regimes. The use of AI in the oil and gas business is fast evolving, as the concept of AI pervades several stages of the industry, including intelligent drilling, intelligent development, intelligent pipelines, intelligent processing, and so on, and it will become a promising research path. Using artificial intelligence algorithms, developers have built a spectrum of realistic application technologies in research and production. Using artificial intelligence algorithms, developers have built a spectrum of realistic application technologies in research and production. The adoption of the ANN technique has already generated significant results in terms of minimising exploration risks and raising exploration well success rates in the field of exploration. Drilling quality has substantially increased and expenses have decreased because to new drilling equipment such as an automated drilling rig and an intelligent drill pipe. The most common use of AI technology in oilfield development is to refine the development plan based on past production data [24, 25]. A regression model can be used to investigate field planning and well site planning. Unsupervised learning can be used to understand data characteristics. Kumar et al., proposed a framework that was shown to be beneficial for shales due to its ability to manage massive amounts of data. The linearized rock physics inversion method can be used to tackle the problem of rock physics. Although this model can yield correct physical parameters, it is ineffective for highly nonlinearized rock physics. The suggested machine learning approach can generate accurate and cost-effective well logs, it can be concluded. When compared to the Long Short Term Memory Method, the Shift Window method can provide better pressure prediction (LSTM) [26, 27]. Diersen et al. employed artificial intelligence to reduce human effort in seismic whole wave tomography processing and analysis. This is accomplished through the use of artificial intelligence and the Complex Wavelet Transform (CWT). CWT is a wavelet-based transformation that aids in the understanding of waveforms’ time and frequency domains. Inside the full-wave tomography technique, an Artificial Neural Network and a Knowledge based Artificial Neural Network can be employed to pick suitable seismic window pieces [28].

2 Machine Learning in Oil and Gas Industry

15

2.2.2 Reservoir Engineering Fluid flow through porous medium, production forecasts, and field optimization are all aspects of reservoir engineering. Preparing subsurface property maps and PVT analysis necessitates numerical simulations, modelling, and experiments. To prepare static and dynamic models, modelling is done on large amounts of data. For appraisal planning and stochastic field development plans, data from seismic, well log, core analysis, and past reservoir performance are combined using machine learning algorithms. Artificial Neural Network, Genetic Algorithm, Response Surface Model (RSM), and other algorithms are used to perform complex pressure transient analysis and deconvolution of pressure data. These GA models are highly useful for matching reservoir histories and preparing P90, P50, and P10 production profiles following Project Resource Management Systems principles (PRMS). Large amounts of data are used to create reservoir maps, which are refined repeatedly as new data is added to the database. For many years, ANN has been used to estimate reservoir parameters such as permeability and porosity. To forecast reservoir fluid properties, many machine learning approaches such as K Nearest Neighbours (KNN), Support Vector Regression (SVR), Kernel Ridge Regression (KRR), Adaptive Boosting, and Collaborative Filtering can be used. Onwuchekwa discovered that collaborative filtering, which was originally built for a consumer product recommendation system, worked well in their reservoir study [29]. The synthetic reservoir model can be used to simulate reservoir oil numerically. Teixeira and Secchi employed an optimization technique to find the best control for increasing total oil production [30]. The parametric study compares different machine learning algorithms for predicting permeability, seismic characteristics, and wireline data. In terms of permeability prediction, the Superior Vector Mechanism (SVM) outperformed other approaches. Anifowose et al., developed an intelligent model based on injector wells that used the Extreme Gradient Boosting method to forecast reservoir response. In a heterogeneous reservoir with complex topography, Nwachukwu et al. chose five cases: homogeneous reservoir water flood, channelized reservoir water flood, 20-model ensemble water flood, and CO2 flood [31].

2.2.3 Drilling Engineering Drilling has a number of issues, including stick sleep vibrations, loss of circulation, bit wear, excessive torque, borehole instability, and so on. Machine learning has the ability to solve these issues [32]. Aliouane and Ouadfeul suggested a machine learning approach for generating a poisson’s ratio map, which is beneficial for determining drilling direction and rock features [33]. Castineria et al. used the machine learning method to verify the quality of huge drilling data, retrieve critical information, and anticipate non-productive time [34]. This strategy saved money by reducing

16

J. K. S. Sayani and B. Lal

the amount of time it took to assess the quality of vast amounts of drilling data. The Byesian network (BN) can be used for Managed Pressure Drilling (MPD) and Under Balanced Drilling (UBD) operations in deep sea drilling. According to Bhandari et al., the BN may be utilised efficiently for risk analysis and failure prediction in the offshore business [35]. Automation was used to control drilling parameters such as the Weight of Bit (WOB), Rotary Speed (RPM), and Rate of Penetration (ROP). A machine learning method can collect information such as alternative bit or rig equipment upgrades, estimated abrasive wear, and predicted bit wear [36].

2.2.4 Production Engineering The use of advanced machine learning technologies results in a revolutionary workflow that relieves the burden on engineers. In the oil and gas industry, machine learning has a variety of applications in production engineering. One of the most difficult tasks is analyzing massive amounts of data in a short amount of time in order to make decisions. Machine learning technologies can be used to recognize production patterns in data. With active learning, Subrahmanya et al. were able to obtain the data point with the maximum information value. With semi-supervised learning, data from wells was integrated from labelled and unlabeled sources. Algorithms were used to check, verify, and recover the data. The study looked at well logging data rectification, quality control of physical and chemical fluid parameters, and separation between base production and well interventions [37, 38]. With the help of data patterns, the ANN model can forecast closure pressure. To reduce mistake, the output data is usually compared to the real outcomes. According to Nande, an ANN model is capable of accurately predicting closure pressure [39]. Shen et al. employed the Support Vector Regression Model to forecast wrinkling in mechanically lined pipelines [40]. The importance of edge analytics for the oil and gas industries was explained by Saghir et al. For electric submersible pump driven wells, edge analytics was used to detect anomalies in real time [41]. Another key use in the oil and gas business is the Continuous Integration/Continuous Deployment (CICD) methods in machine learning. An advanced CICD should contain a precise and repeatable Machine Learning (ML) workflow with tracking, model lineage, and version control systems. This is especially useful in recognizing conceptual drift, which occurs when the performance of a statistical model degrades over time due to changes in data and previously modelled input– output relationships [42]. Another key use in the oil and gas business is the Continuous Integration/Continuous Deployment (CICD) methods in machine learning. An advanced CICD should contain a precise and repeatable Machine Learning (ML) workflow with tracking, model lineage, and version control systems. This is especially useful in recognizing conceptual drift, which occurs when the performance of a statistical model degrades over time due to changes in data and previously modelled input–output relationships. By employing LiDAR to create 3D point clouds and

2 Machine Learning in Oil and Gas Industry

17

analytics for plant building, experts can predict the behavior of a structure and calculate its maintenance needs, considerably prolonging its lifetime. These simulations, on the other hand, are fairly “static,” in the sense that they don’t account for all of the changes in an asset’s actual, real-world physical variables that can affect its performance over time. To combine data from IIoT sensors concerning actual environmental loads with a virtual duplicate of the asset, new control methods have been developed.

2.3 Machine Learning Advancements in the Oil and Gas Industry Companies are actively pursuing creative techniques to be more efficient through simplifying production, cutting costs, and enhancing worker safety, among other things, as the oil and gas business grows more competitive and unpredictable. Many CEOs are turning to digitization to protect businesses from market shocks, stay profitable at reduced oil prices, and gain a competitive edge during the rebound. Artificial intelligence (AI) and machine learning-based technologies, which are rapidly maturing and being deployed across the value chain, are the way forward. Numerous sectors have recognised the advantages of these new technologies, and we will continue to see more AI applications created in the future. Let’s look at some real-life AI applications in the oil and gas sector.

2.3.1 Total S.A. With Google Cloud–Optimize Subsurface Data Analysis Before and after drilling into the Earth, oil and gas companies must collect and analyse a large amount of data. They need to be able to solve complicated exploration and production challenges before they waste money drilling into an unproductive well to increase efficiency in day-to-day operations. In 2018, Total S.A., a French oil and gas firm, teamed up with Google Cloud to create AI solutions that improve subsurface data processing for exploration and production. If you go back a few decades, you’ll see that Total is no stranger to AI implementation. In the 1990s, the business began using AI and machine learning algorithms to describe oil and gas areas. In 2013, they deployed predictive maintenance technologies for turbines, pumps, and compressors, which resulted in hundreds of millions of dollars in savings. With Google Cloud, they’re taking it to the next level. Their combined technologies will make it possible to use computer vision to understand subsurface images from seismic studies. Furthermore, their AI solutions will use natural language processing to automate the study of technical texts. Total will be able to explore and analyse oil and gas areas significantly faster and more effectively as a result of these solutions.

18

J. K. S. Sayani and B. Lal

2.3.2 ExxonMobil and MIT Collaborate to Detect Oil Seeps with AI-Powered Robots ExxonMobil is one of the most well-known oil and gas companies in the world. They also put their money into some interesting AI projects. The industry behemoth partnered up with the Massachusetts Institute of Technology (MIT) in 2016 to develop artificial intelligence (AI) robots for ocean research. One of the major members of this deep-sea endeavour is Brian Williams, an MIT professor and a core designer of the software for NASA’s Mars Curiosity Rover, adding to the cool factor. ExxonMobil intends to employ this deep-sea AI robot to improve its natural seep detection capabilities. Natural oil seeps from the bottom are the most common source of oil into the world’s oceans, accounting for over half of all oil discharged each year, according to the National Oceanic and Atmospheric Administration. ExxonMobil’s AI-powered robots will be able to detect these oil seeps, reducing the risk of exploration and minimising the impact on marine life. Researchers and engineers from ExxonMobil are partnering with MIT’s Computer Science and Artificial Intelligence Laboratory (CSAIL) to build self-learning, submersible artificial intelligence robots for ocean subsurface exploration. The robots’ programming, or “intelligence,” will allow them to perform independently in severe environments like those encountered on Mars, as well as modify mission parameters on their own to examine unforeseen anomalies. Observing the waters, charting deep areas, researching how they evolve over time, and assessing their state would be a promising application for the new technology.

2.3.3 Shell—Machine Learning Algorithms for Precision Drilling Shell is another corporate behemoth that is experimenting with AI applications. Shell is utilising reinforcement learning to operate its drilling equipment this time around, effectively implementing a reward system based on the AI’s decisions. For example, to drive the drill into the subsurface, a machine learning model is trained on historical data from Shell’s comprehensive drilling records, as well as simulations. It also considers data from seismic surveys, as well as temperature, pressure, and other drill bit data points. The geosteerer, or the person running the drilling machine, can then provide feedback via reward or punishment functions, allowing the machinery to adjust to changing subsurface conditions. This allows the geosteerer to have a greater understanding of the area in which they are working, resulting in faster, more precise results and fewer machinery damage. However, innovation does not end there. Shell is continuously on the lookout for major ideas that will push the oil and gas industry’s boundaries. Shell conducts regular calls for AI proposals centred on machine learning from people and startups all across the world through their Shell Game Changer project. Shell is leading

2 Machine Learning in Oil and Gas Industry

19

the way in helping to tackle some of the industry’s biggest difficulties, whether it’s investing in these ideas or simply partnering on a project. However, innovation does not end there. Shell is continuously on the lookout for major ideas that will push the oil and gas industry’s boundaries. Shell conducts regular calls for AI proposals centred on machine learning from people and startups all across the world through their Shell Game Changer project. Shell is leading the way in helping to tackle some of the industry’s biggest difficulties, whether it’s investing in these ideas or simply partnering on a project. Algorithms for guiding drills through the subsurface are being created utilising data from Shell’s drilling history as well as data from simulated investigations. Mechanical data from the drill bit, such as pressures and temperatures, are included, as well as data from subsurface seismic research. As a result, a Shell geosteerer, the drilling machine’s human programmer, is capable of comprehending the circumstances in which they are working, resulting in faster results and less wear and tear on machinery.

2.3.4 Aker BP and Spark Cognition—Predictive Maintenance Increases Productivity Unplanned downtime can be a costly nightmare for offshore oil and gas platforms, with catastrophic asset breakdowns costing as much as $2e3 million in a single day. Too many businesses still rely on antiquated ways, causing some to place a greater emphasis on data and analytics when making maintenance choices. Aker BP, a Norwegian independent upstream oil and gas firm, teamed with Spark Cognition to implement an AI-powered predictive maintenance solution to their unmanned Tambar platform, where problems with a crucial multi-phase pump cause a large amount of unplanned downtime. Spark Cognition built and integrated a multi-phase pump normal behaviour model into its AI-powered predictive maintenance software, which subsequently flagged deviations from normal subsystem behaviour. The AI programme notified Aker BP operators and SMEs to a probable multi-phase pump trip caused by a deteriorating seal over the course of six months, with previous failures costing over $10 million in lost production. Aker BP and Spark Cognition were able to avert pump failure, resulting in hundreds of thousands of dollars in additional production for each day of downtime avoided. Spark Cognition built and integrated a multi-phase pump normal behaviour model into its AI-powered predictive maintenance software, which subsequently flagged deviations from normal subsystem behaviour. The AI programme notified Aker BP operators and SMEs to a probable multi-phase pump trip caused by a deteriorating seal over the course of six months, with previous failures costing over $10 million in lost production. Aker BP and Spark Cognition were able to avert pump failure, resulting in hundreds of thousands of dollars in additional production for each day of downtime avoided. SparkPredict uses machine learning techniques to analyse

20

J. K. S. Sayani and B. Lal

sensor data in order to detect inefficient processes and impending issues before they occur. Installing SparkPredict on Aker BP’s offshore production platforms will boost productivity and efficiency, furthering the company’s goal of providing unrivalled value to its clients around the world.

2.4 Challenges Companies To reduce uncertainty, the first step is to develop a system that can handle multiple hypotheses in order to arrive at an optimal solution. Anifowose et al. developed an effective AI and machine learning technique to tackle this challenge. Hybrid Intelligent System (HIS) was created to address this issue in machine learning. It had been demonstrated that the HIS has enormous potential for improving oil field reserve estimates, resulting in better finding, considerably more efficient extraction, wider development, and highly productive use of energy supplies [43]. Given the current state of the oil industry, machine learning appears to have become more widely used in the previous five years, particularly in the alleviation of drilling issues in real time, as well as in oil drilling automation and technology. Machine learning has also shown promise in achieving higher rates of penetration (ROP) and lower CPF levels, as well as many other performance metrics like drilling 10,000 m per day [32]. Hawedi et al. proposed a data-driven framework for evaluating well performance in two scenarios: predicting only current well performance and forecasting future well performance [44]. The entire method is much more detailed than the step-by-step regression evaluation in that it includes additional data sources such as geological map details, output restrictions such as tube head pressure, and positions that represent dynamic reservoir characterisation of non-traditional wells without requiring a current model [45]. Machine learning (ML) will significantly improve oil exploration and interpretation of seismic data, as well as develop extraction strategies to make it more efficient. The biggest issue confronting the oil industry today is the environmental risk associated with both oil extraction and production. However, the goal is that other systems will be constructed using modern technical approaches that are considerably more environmentally sustainable. Although the Artificial Neuro Fuzzy Inference System (ANFIS) improves performance slightly, the prediction is not necessarily changed when ANN is used because the neural network is already capable of providing a genuine working formula [46]. While certain oil and gas firms, such as ONGC, OIL, Reliance, and Shell, are accelerating their AI activities by investing heavily in startups and R&D, many obstacles are keeping them from implementing AI in the exploration and production of oil and gas on a large scale and quickly. This isn’t a problem exclusive to the oil and gas industry; it’s a regular occurrence in the early stages of AI’s development. The main problems, according to studies, are related to the type of people the sector requires, the value of data, and the necessity for open communication. These three difficulties will be explained further down.

2 Machine Learning in Oil and Gas Industry

21

2.4.1 Manpower Artificial intelligence’s success is inextricably linked to human intelligence. AI solutions aren’t general, and they can’t be purchased off the shelf. Even when produced by third parties, AI solutions must be tailored to a company’s business context and database. Companies must build in-house teams of data and AI specialists to actively use AI in processes and products. These groups should be able to assist in the development of AI infrastructure (algorithms and datasets) and, at the very least, customise tools that businesses will use in the future. That means that, in the next ten years, oil and gas companies will become (partially) data-driven, and AI specialists will become indispensable in supporting practically all innovation efforts in the industry. Finding and keeping AI talent, on the other hand, is a difficult undertaking. There is a severe scarcity of AI talent on the employment market, and with more corporations investing in AI and developing their own AI departments, the outlook for the next decade is bleak. This is particularly true for oil and gas firms. Next, in order to compete with tech giants like Google, Yandex, IBM, and Amazon for the same talent, oil and gas businesses must combat negative opinions regarding fossil fuel industries by partnering with great institutions and cool startups throughout the world. That is neither a simple nor a cheap task. Despite the fact that AI’s entry into the oil and gas business heralds “the end of petroleum engineering as we know it,” petroleum engineers will not vanish. The only thing that will change is their function and the ability that will be needed of them. To succeed in the AI era, oil and gas firms will need petroleum engineers with a good understanding of data science and the capacity to identify and design jobs that can be addressed by AI, in addition to data scientists. Their job will be to make sure that the relevant challenges for AI are recognised, that the right data is collected, and that solutions are tailored to the physical and process realities. This will become increasingly important over time, as otherwise, the wrong questions may be asked, and existing human errors may be compounded, as was the case with Google’s mammogram-based breast cancer screening system. As a result of the use of AI, it is not simply data science and AI skills that are in need, but a new way of thinking about the difficulties that oil and gas firms face, anchored in a thorough grasp of the processes and the underlying logic of activities. As a result, petroleum engineers’ new job will become increasingly important. Some universities, such as Russia’s Skolkovo Institute of Science and Technology and the United States’ West Virginia University, have already begun to implement specific educational programmes that combine data science with petroleum studies to prepare the future generation of petroleum engineers. Petroleum engineers will need to learn how to interact with AI assistants, which are akin to Alexa and Siri but focused on industry applications, in addition to working with data and data scientists. The goal in these new partnerships will be to combine the best of both sides’ capabilities: AI’s capacity to deal with large amounts of data, detect patterns and relationships, and petroleum engineers’ deep industrial domain knowledge. Although AI is projected to mostly be utilised by humans to supplement

22

J. K. S. Sayani and B. Lal

rather than replace their decision-making abilities, this will be a difficult undertaking because numerous questions about trust and the fear of losing jobs may arise. There is also an unresolved issue with people’s legal perspectives on AI’s recommendations. There may be instances where an AI tool proposes a course of action that results in a loss of money, output, or even serious health or environmental problems. In this instance, there is no clear understanding of who is responsible for what: the AI algorithm, the AI algorithm user, or the AI algorithm developer. With the advancement of AI capabilities, this subject will become increasingly relevant. As a result, the legal foundation will be established in simultaneously. According to the practise, the algorithms and their developers are not liable, but the decisionmakers who receive advise from AI and AI users bear accountability. As a result, in order to take advantage of the chance to greatly expand decision-making capabilities, businesses will need to develop not just AI strategies, but AI strategies as well.

2.4.2 Data Availability To be taught and subsequently perform successfully in the operational mode, AI systems require high-quality data in a sufficient volume. While smarter algorithms may aid in obtaining better results from datasets of restricted size, there is no way to improve faulty data. As a result, access to large amounts of high-quality data is both an advantage and a barrier to the development of AI applications. Large volumes of raw data are generated in oil and gas sectors. Even said, there are acknowledged challenges with the quality and accuracy of field data, as well as a general shortage of huge volumes of labelled data in the oil and gas business, so it is not a guarantee of success. Training datasets must be properly acquired over the course of a multiyear procedure that follows a well-planned methodology and is situation-specific. Oil and gas firms will have to adapt and adjust their organisational structures and procedures to increase the value of the data they have or can access. Technical efforts in enhancing AI systems and their subsequent practical use in oil and gas exploration and production are driven by data difficulties (across industries, not only in the oil and gas industry).

2.4.3 Opportunities and Facilities for Collaboration Artificial intelligence emerges in an open and collaborative environment as a result of academia’s decades of leadership in AI research, almost free of commercial influences. This spawned a culture of open sharing and publishing, which businesses from all industries (and all corners of the globe) were forced to adopt as a standard in order to compete in the AI era. While open innovation is becoming the norm in the digital industry, oil and gas corporations aren’t known for their collaborative industry projects, especially between competitors and especially in crucial fields like

2 Machine Learning in Oil and Gas Industry

23

artificial intelligence. Despite the fact that many organisations have announced the open-source of some of their data and assert the importance of cross-company and cross-border data exchange, the reality is currently negative. The oil and gas industry in the United Kingdom One of the first significant open data releases in the oil and gas industry was the National Data Repository. It holds 130 gigabytes of geophysical, infrastructure, field, and well data, with approximately 12,500 wellbores, 5000 seismic surveys, and 3000 pipelines represented (Oil and Gas Authority, 2019). On the basis of accessible data, potential for machine learning and artificial intelligence applications are outlined. Oil and gas firms should reconsider their methods for partnering and interacting with universities because university labs are another significant source of novel AI technology and AI skills.

2.5 COVID-19’s Impact on the Oil and Gas Industry, and AI as a Solution Companies Lower crude prices and geopolitical difficulties are resulting in excess supply and some major industry advances as the oil and gas sector enters a new normal of pandemic condition. Despite the fact that consumption is likely to rise as the world recovers from the epidemic and normalises its relations and output quotas, industry participants must be flexible enough to adjust to the new reality. They need to focus on strengthening their supply chain and activities in order to reduce manufacturing, distribution, and transportation expenses. Artificial intelligence (AI) has the potential to transform the value chain in the oil and gas industry. Artificial intelligence (AI) models are frequently used as isolated point solutions with little overall benefit. As benefits begin to plateau fast, dissatisfaction with performance has an impact on future plans. As it incorporates crossdomain data, the industry continues to focus on different aspects of reservoir, geology, geophysics, engineering, and drilling. With a single staff in charge of all geotechnical needs, these divisions were developed to boost productivity across the organisation. This operational division, which was established in the past to meet cost-cutting requirements, precludes the oil and gas industry from implementing broader cross-functional AI applications.

2.6 Summary This chapter presents examples of machine learning applications in exploration, reservoir, drilling, and production. The oil and gas business, according to the literature analysis, is well-positioned to gain from machine learning because of its ability

24

J. K. S. Sayani and B. Lal

to process large amounts of data quickly. Throughout this work, a variety of monitored learning approaches have been defined and described. Machine learning has the ability to fundamentally alter the myriad vital decisions made by administrators and engineers in the oil and gas industry on a daily basis. If proper approaches are employed to incorporate diverse data kinds or structures and convert them into valuable information that leads to intelligent judgments, the future benefits of information can be realised. Many of these methods, which use ANN, ALM, supervised learning, fuzzy logic, linear regression, and PCA, may be implemented to address numerous challenges in the oil and gas industry and aid in the development of successful strategies. Machine learning’s use is expected to grow fast in the future years, and its worth will be widely recognised in the oil and gas industries.

References 1. Lalude G (2015) Importance of oil to the global community. Glob J Human-Soc Sci F Polit Sci 15 2. Fjellheim RA (2020) Autonomous systems - opportunities and challenges for the oil & gas industry a white paper authored by the autonomy working group of norsk forening for automatisering (Norwegian Society of Automatic Control ) 3. Anderson RN (2017) “Petroleum analytics learning machine” for optimizing the Internet of Things of today’s digital oil field-to-refinery petroleum system. In: Proceedings of the - 2017 IEEE International Conference Big Data, Big Data 2017 2018, pp 4542–4545 4. Temizel C, Canbaz CH, Palabiyik Y, Putra D, Asena A, Ranjith R, Jongkittinarukorn K (2019) A comprehensive review of smart/intelligent oilfield technologies and applications in the oil and gas industry. SPE Middle East Oil Gas Show Conf. https://doi.org/10.2118/195095-MS 5. Evans SJ (2019) How digital engineering and cross-industry knowledge transfer is reducing project execution risks in oil and gas. Offshore Technol Conf. https://doi.org/10.4043/294 58-MS 6. Anifowose FA, Labadin J, Abdulraheem A (2017) Ensemble machine learning: an untapped modeling paradigm for petroleum reservoir characterization. J Pet Sci Eng 151:480–487 7. Ani M, Oluyemi G, Petrovski A, Rezaei-Gomari S (2016) Reservoir uncertainty analysis: the trends from probability to algorithms and machine learning. SPE Intell Energy Int Conf Exhib. https://doi.org/10.2118/181049-MS 8. Rana S, Ertekin T, King GR (2018) An efficient probabilistic assisted history matching tool using Gaussian processes proxy models: application to coalbed methane reservoir. SPE Annu Tech Conf Exhib. https://doi.org/10.2118/191655-MS 9. Esmaili S, Mohaghegh SD (2016) Full field reservoir modeling of shale assets using advanced data-driven analytics. Geosci Front 7:11–20 10. Costa LAN, Maschio C, José Schiozer D (2014) Application of artificial neural networks in a history matching process. J Pet Sci Eng 123:30–45 11. Managi S, Opaluch JJ, Jin D, Grigalunas TA (2005) Technological change and petroleum exploration in the Gulf of Mexico. Energy Policy 33:619–632 12. Adelman MA (1991) User cost in oil production. Resour Energy 13:217–240 13. Roussanaly S, Aasen A, Anantharaman R et al (2019) Offshore power generation with carbon capture and storage to decarbonise mainland electricity and offshore oil and gas installations: A techno-economic analysis. Appl Energy 233–234:478–494 14. Sami N, Aziz A (2021) Machine learning and big data: an approach toward better healthcare services. Comput Intell Healthc Inform 1–13

2 Machine Learning in Oil and Gas Industry

25

15. Hazbeh O, Aghdam SK, ye, Ghorbani H, Mohamadian N, Ahmadi Alvar M, Moghadasi J, (2021) Comparison of accuracy and computational performance between the machine learning algorithms for rate of penetration in directional drilling well. Pet Res 6:271–282 16. Hassanvand M, Moradi S, Fattahi M, Zargar G, Kamari M (2018) Estimation of rock uniaxial compressive strength for an Iranian carbonate oil reservoir: modeling versus artificial neural network application. Pet Res 3:336–345 17. Priyanka EB, Thangavel S, Gao X-Z (2021) Review analysis on cloud computing based smart grid technology in the oil pipeline sensor network system. Pet Res 6:77–90 18. Zheng L, Wei P, Zhang Z, Nie S, Lou X, Cui K, Fu Y (2017) Joint exploration and development: A self-salvation road to sustainable development of unconventional oil and gas resources. Nat Gas Ind B 4:477–490 19. Lu H, Huang K, Azimi M, Guo L (2019) Blockchain technology in the oil and gas industry: a review of applications, opportunities, challenges, and risks. IEEE Access 7:41426–41444 20. Shafiee M, Animah I, Alkali B, Baglee D (2019) Decision support methods and applications in the upstream oil and gas sector. J Pet Sci Eng 173:1173–1186 21. Strantzali E, Aravossis K (2016) Decision making in renewable energy investments: a review. Renew Sustain Energy Rev 55:885–898 22. Zhang J, Yin X, Zhang G, Gu Y, FAN X, (2020) Prediction method of physical parameters based on linearized rock physics inversion. Pet Explor Dev 47:59–67 23. Kumar A (2019) A machine learning application for field planning. Offshore Technol Conf. https://doi.org/10.4043/29224-MS 24. Holditch SA (2013) Unconventional oil and gas resource development–let’s do it right. J Unconv Oil Gas Resour 1–2:2–8 25. Pandey RK, Kakati H, Mandal A (2017) Thermodynamic modeling of equilibrium conditions of CH4/CO2/N2 clathrate hydrate in presence of aqueous solution of sodium chloride inhibitor. Pet Sci Technol 35:947–954 26. Zhang D, Chen Y, MENG J, (2018) Synthetic well logs generation via recurrent neural networks. Pet Explor Dev 45:629–639 27. Heghedus C, Shchipanov A, Rong C (2019) Advancing deep learning to improve upstream petroleum monitoring. IEEE Access 7:106248–106259 28. Diersen S, Lee EJ, Spears D, Chen P, Wang L (2011) Classification of seismic windows using artificial neural networks. Proc Comput Sci 4:1572–1581 29. Onwuchekwa C (2018) Application of machine learning ideas to reservoir fluid properties estimation. SPE Niger Annu Int Conf Exhib. https://doi.org/10.2118/193461-MS 30. Teixeira AF, Secchi AR (2019) Machine learning models to support reservoir production optimization. IFAC-PapersOnLine 52:498–501 31. Nwachukwu A, Jeong H, Pyrcz M, Lake LW (2018) Fast evaluation of well placements in heterogeneous reservoir models using machine learning. J Pet Sci Eng 163:463–475 32. Noshi CI, Schubert JJ (2018) The role of machine learning in drilling operations; a review. SPE/AAPG East Reg Meet. https://doi.org/10.2118/191823-18ERM-MS 33. Aliouane L, Ouadfeul S-A (2014) Sweet spots discrimination in shale gas reservoirs using seismic and well-logs data. A case study from the worth basin in the Barnett shale. Energy Procedia 59:22–27 34. Castiñeira D, Toronyi R, Saleri N (2018) Machine learning and natural language processing for automated analysis of drilling and completion data. SPE Kingdom Saudi Arab Annu Tech Symp Exhib. https://doi.org/10.2118/192280-MS 35. Bhandari J, Abbassi R, Garaniya V, Khan F (2015) Risk analysis of deepwater drilling operations using Bayesian network. J Loss Prev Process Ind 38:11–23 36. Dunlop J, Isangulov R, Aldred WD, Sanchez HA, Flores JL, Herdoiza JA, Belaskie J, Luppens JC (2011) Increased rate of penetration through automation. SPE/IADC Drill Conf Exhib. https://doi.org/10.2118/139897-MS 37. Subrahmanya N, Xu P, El-Bakry A, Reynolds C (2014) Advanced machine learning methods for production data pattern recognition. SPE Intell Energy Conf Exhib. https://doi.org/10.2118/ 167839-MS

26

J. K. S. Sayani and B. Lal

38. Andrianova A, Simonov M, Perets D, Margarit A, Serebryakova D, Bogdanov Y, Budennyy S, Volkov N, Tsanda A, Bukharev A (2018) Application of machine learning for oilfield data quality improvement. SPE Russ Pet Technol Conf. https://doi.org/10.2118/191601-18R PTC-MS 39. Nande S (2018) Application of machine learning for closure pressure determination. SPE Annu Tech Conf Exhib. https://doi.org/10.2118/194042-STU 40. Shen C, Fournier B, Giry E, Cocault-Duverger V (2019) Lined pipe reeling mechanics design of experiment and; machine learning model. 29th Int. Ocean Polar Eng. Conf. 41. Saghir F, Gilabert H, Boujonnier M (2018) Edge analytics and future of upstream automation. SPE Asia Pacific Oil Gas Conf Exhib. https://doi.org/10.2118/192019-MS 42. Žliobait˙e I, Pechenizkiy M, Gama J (2016) An overview of concept drift applications BT - big data analysis: new algorithms for a new society. In: Stefanowski J (ed) Japkowicz N. Springer International Publishing, Cham, pp 91–114 43. Anifowose FA, Labadin J, Abdulraheem A (2017) Hybrid intelligent systems in petroleum reservoir characterization and modeling: the journey so far and the challenges ahead. J Pet Explor Prod Technol 7:251–263 44. Hawedi HS, Haron H, Nordin A, Ahmed AA (2011) Current challenges and future perspective: the influence of organizational intelligence on libyan oil and gas industry. IJCSNS Int J Comput Sci Netw Secur 11(1):145–147 45. Cao Q, Banerjee R, Gupta S, Li J, Zhou W, Jeyachandra B (2016) Data driven production forecasting using machine learning. SPE Argentina Explor Prod Unconv Resour Symp. https:// doi.org/10.2118/180984-MS 46. Khan MA, Al-Oufi M, Toseef A, Nadeem MA, Idriss H (2018) Comparing the reaction rates of plasmonic (Gold) and non-plasmonic (Palladium) metal particles in photocatalytic hydrogen production. Catal Lett 148:1–10

Chapter 3

Multiphase Flow Systems and Potential of Machine Learning Approaches in Cutting Transport and Liquid Loading Scenarios Muhammad Saad Khan, Abinash Barooah, Bhajan Lal, and Mohammad Azizur Rahman Abstract Multiphase flow is a primary concern in flow assurance applications, mainly dealing with cutting transport, hydrate formation, and liquid loading issues. The conventional prediction model includes empirical equations and complex physics-based models; however, they are limited within the experimental ranges. Due to complex physics and the limitations of numerical methods, new techniques of collecting and evaluating multiphase behavior in these pipelines is essential, which is reviewed in this chapter. The review covers the overview of different multiphase systems, followed by cutting transport and existing models for accurate prediction of cutting transport. Also, the available literature on machine learning applications in cutting transport is included in it. Moreover, the chapter also demonstrates a liquid loading issue and their available prediction methods. The available literature on machine learning in liquid loading applications is also part of this chapter. The final part of the chapter includes the case studies of machine learning in multiphase flow systems to provide the field applicability of this modern prediction technique which can provide an avenue for future applications. Keywords Cutting transport · Flow regime maps · Liquid loading · Machine learning · Multiphase flow

M. S. Khan · B. Lal (B) Chemical Engineering Department, Universiti Teknologi PETRONAS, 32610 Bandar Seri Iskandar, Perak Darul Ridzuan, Malaysia e-mail: [email protected] Research Centre for CO2 Capture (RCCO2C), Universiti Teknologi PETRONAS, 32610 Bandar Seri Iskandar, Perak, Malaysia A. Barooah Petroleum Engineering Department, Texas A&M University, College Station, USA M. A. Rahman Petroleum Engineering Department, Texas A&M University at Qatar, Ar-Rayyan, Qatar © The Author(s), under exclusive license to Springer Nature Switzerland AG 2023 B. Lal et al. (eds.), Machine Learning and Flow Assurance in Oil and Gas Production, https://doi.org/10.1007/978-3-031-24231-1_3

27

28

M. S. Khan et al.

3.1 Introduction to Multiphase Two-phase flow is the interaction of two distinct phases in a channel that share common interfaces, with each phase representing a mass or volume of matter. Both phases are capable of coexisting as solids, gases, or liquids. Although three-phase multiphase flow occurs, the bulk of multiphase engineering applications uses a twophase flow. Planning, development, and optimization are required for flow in any channel. Based on the interfaces generated between the phases, predicting the flow phases and flow regimes is critical, i.e., typical flow patterns. Based on the flow rate, channel size, and operating conditions, this knowledge allows for predicting pressure drop and heat transfer characteristics. The appropriate flow parameters can be determined based on the pressure drop data to reduce the occurrence of corrosion, erosion, or scale development, all of which can lead to excessive friction. Predicting flow regimes, such as oil and gas flow in pipelines or chemical process industries, allows avoiding excessive gas pressure buildup, meltdowns, and potentially hazardous explosions. The results of heat transfer analysis can be utilized to design flow channels and operating conditions and forecast and avoid flow instabilities. The heat transfer community and practicing engineers are predominantly interested in two-phase flow, which involves phase transition between a single substance’s liquid and vapor phases. Two-phase flow refers to the fluid flow of a two-phase mixture, which can be (1) liquid–vapor flow, (2) liquid–liquid, (3) liquid–solid particles, or (4) gas–solid particles. This category includes forced convective condensation and boiling. Solving two-phase flow and heat transfer problems is extremely difficult because each phase has its own properties, velocity, and temperature. The conveyance of multiphase well fluids is extremely prevalent in the oil industry. When the fluid from an oil and gas well reaches the wellhead, it forms a three-phase (oil, water, and gas) or two-phase (oil and gas) mixture. A single-phase liquid or gas flow at the wellhead is an extreme example. The multiphase fluid flow analysis is used to mimic the behavior and interactions of two fluid phases. The study uses the Volume of Fluid (VoF) method, a typical multiphase system computing method. Because of the variety in flow regimes, multiphase flow is substantially more difficult than single-phase flow (or flow patterns). Fluid distribution varies dramatically throughout flow regimes, influencing pressure gradients inside and outside the drill string.

3.1.1 Gas–Liquid Flow Systems Gas–liquid systems are often encountered in gas wells where produced water increases with increased production, causing serious production threats like hydrate formations [1–9] and liquid loading [10–13]. Flow Regime maps are handy tools for understanding the flow behavior that might be expected for a given set of input data. Each map, however, is not broad enough to apply to other data sets. It describes the

3 Multiphase Flow Systems and Potential of Machine Learning …

29

geometrical distribution of a multiphase fluid passing through a pipe. This distribution is described using various flow regimes, distinguishing between qualitative and somewhat arbitrary. The flow mapping or flow analysis indicates the onsite visualization of fluid flow behavior encountered mainly in production lines is gas–liquid, which is depicted in Fig. 3.1. The significant gas–liquid flow regimes in a horizontal annulus can be described as the bubbly flow, plug flow, slug flow, wavy flow, and annular flow with the increased flow rates of gases phase (see Fig. 3.1).

Fig. 3.1 Gas–liquid flow regimes orientation in the horizontal annulus: a Schematic b pictorial

30

M. S. Khan et al.

3.1.2 Liquid–Liquid Flow Systems Many engineering applications accurately predict oil–water flow properties such as flow pattern, water holdup, and pressure gradient. Flows of two immiscible liquids occur in a wide variety of processes and equipment. Oil and water combinations are delivered through pipes across great distances via pipelines [14–16]. Despite their importance, liquid–liquid fluxes have not been studied as thoroughly as gas–liquid flows. In fact, gas–liquid systems are a subset of two-fluid systems distinguished by a low density to viscosity ratio. The density difference between the phases in liquid–liquid systems is quite small (Fig. 3.2).

3.1.3 Solid–Liquid Flow Systems Solid–liquid flows, which are generally encountered during the drilling operation, require effective cutting transport for effective hole cleaning [2, 17–19]. Different types of flow behaviors like stationary bed, slowly moving bed, rolling bed, and dispersed moving beds are generally encountered based on the increased flow rate of liquid flow, as presented in Fig. 3.3.

3.1.4 Solid–Liquid–Gas Three-Phase Flow Systems Figure 3.4 shows the schematic and actual flow representation of multiphase flow (Solid–liquid–gas) systems in cutting transportation perspectives [2, 17]. Like the solid–liquid system, the three-phase system also possesses a similar flow pattern, and solid transport increases with a rise in liquid flow rates. The stationary solid bed breaks up in a different pattern of moving dunes. Some solid particles roll on the, while the other solid accumulates in the lower part of the dunes. This mechanism pushes the solids in the flow direction (Fig. 3.5).

3.2 Flow Assurance Issues in Drilling Applications (Cutting Transport) Solid particles (cuttings) are produced in petroleum drilling by the drill bit when it is forced downhole at a specific penetration rate (ROP). The cuttings are then conveyed to the surface by the often shear-thinning drilling fluid through the annular gap (formed by the drill pipe1 in a wellbore).

3 Multiphase Flow Systems and Potential of Machine Learning …

31

Fig. 3.2 Liquid–liquid flow regimes orientation in the horizontal annulus: a pictorial b Schematic

3.3 Introduction of Cutting Transport Issues Among the many roles of drilling fluid, hole cleaning, or the movement of cuttings from the bit to the surface, is a critical function that impacts the drilling process’s efficiency. Hole cleaning removes drill cuttings from a borehole and transports them to the surface. Across the last 30 years, cutting transportation has gotten much attention, and experts worldwide have researched it. It is mostly determined by the drilling mud’s viscosity and gel strength. If the drilling mud lacks viscosity, it will be unable to

32

M. S. Khan et al.

Fig. 3.3 Solid–liquid flow regimes orientation in the horizontal annulus: a Schematic b pictorial

pull the cuttings from the bottom of the borehole to the top. Again, if the drilling mud has sufficient gel strength, it will be unable to suspend the cuttings once the mud pump is turned off. However, the effect of viscosity in horizontal wells is different compared to vertical wells [2, 20]. It has been observed that cutting transport or hole cleaning is more difficult in horizontal and direction wells than in vertical wells. Cutting transport becomes significantly more difficult as wellbore angles exceed 30°. The cause of the hampered transportation is the formation of stagnant beds, which dramatically increase friction and, as a result, restrict the annular area of the cutting to move or carry. These drill cuttings can cause various issues, including drill pipe sticking, increased torque, drag, fluid circulation loss, loss of control over mud density. On top of that, it significantly increases the cost of drilling operations, resulting in the waste of hundreds of millions of dollars worldwide. An assessment conducted by

3 Multiphase Flow Systems and Potential of Machine Learning …

33

Fig. 3.4 Gas–solid-liquid flow regimes orientation in the horizontal annulus: a Schematic b pictorial

Amoco experts that focused on 70% of its lost time due to unexpected events revealed that clogged pipe problems were the primary source of wasted time. Even though extensive research has been undertaken to identify how different parameters affect the cutting transport process in directional and horizontal wells. Adequate cuttings transport is essential for appropriate hole cleaning, i.e., the absence of a critical cuttings bed to avoid costly drilling downtimes due to clogged pipes. Many parameters influence the quality of solids transport [21, 22], two of which are drill pipe rotation and eccentricity. Several experimental research studies have been conducted because of the importance of cuttings transport in the drilling sector [23].

34

M. S. Khan et al.

Fig. 3.5 Classification of existing cutting transport models

Understanding the mechanism of cutting transport in the annulus is critical. There is no accumulation of drill cuttings when the annular velocity (flow rate) is high enough. The critical transport velocity is the speed at which there is no accumulation of bed height, and all cuttings can efficiently transfer to the surface [24]. The bed height increases during sub-critical transport velocity as the annular flow area decrease, resulting in a steady increase in cuts’ local velocity. Mud continues to accumulate until the local velocity reaches a threshold number. Then, an equilibrium bed height is reached at that particular sub-critical flow transport velocity or flow rate. As a result, equilibrium bed height depends on critical velocity [24]. The constant buildup of cut depositions results in various bed formations, such as moving beds and stationary beds. When stationary bed formation occurs, two potential mechanisms can cause solid transport: saltation behavior. The lift force induced by the fluid overcomes the gravitational force and sliding phenomenon, in which viscous force is more dominant than friction between the solid cuttings and pipe wall. Figure 3.5 depicts a generic classification of several sorts of models. Since its inception, the development of various cutting transport models has been centered on three distinct directions: empirical models, mechanical models, and, more recently, numerical models. Empirical correlations are generated using various experimental data, whereas mechanical models consider the physical mechanics of cutting transit. On the other hand, numerical models rely on mesh generation and accurate analysis of individual mesh sizes. Empirical models are rarely utilized because they require many variables, some of which are difficult to simulate at the lab scale, limiting their application [25]. Again, mechanical models are classified as 1D (one dimension), 2D (two dimensions), and 3D (three dimensions). In 1D models, velocity is only considered in the Z direction (along with the wellbore axis).

3 Multiphase Flow Systems and Potential of Machine Learning …

35

Two-dimensional and three-dimensional models are rarely employed since solving a three-dimensional (unsteady-state equation); on fast workstations, the timedependent problem would take hours to solve and are practically useless in field applications [26]. In contrast, in 2D and 3D models, velocity is considered in the Z, X, and Y directions, respectively (velocity gradient both along and across the wellbore). These are further subdivided based on the number of annulus layers, i.e., two-layer and three-layer models. The next section offers a complete summary of the many models in historical sequence.

3.4 Evolution of Various Cutting Transport Models 3.4.1 Layer Model Wicks [26] created one of the first two-layer cutting transport models. Wicks’ idea was based on saltation and backed by experiments. His paper focused on lift force in the X direction (across the wellbore) instead of the Z direction (along the wellbore). Tomren and coworkers [27] discovered the following observations during their experimental investigation of cutting transfer: (1) When the vertical variation is less than 10°, cuttings transport is very comparable. (2) A cuttings bedforms at low flow rates. (3) The bed thickness grows with deviation until it is independent of the deviation angle. (4) Drill pipe eccentricity affects bed thickness but not fluid viscosity, depending on deviation and flow rate. To salt, a particle from the bed, drag, and lift must overcome gravity to rock it over its contact sites. As the particle falls through the fluid, its settling velocity reflects the balance of gravity and drag. The fluid velocity near the particle must be larger than the settling velocity to move a particle. So the liquid layer’s average fluid velocity must be several times the particle’s settling velocity. This model only applies to fine solids. Especially for coarse particles, high fluid velocities can cause bed sliding [28]. Gavignet and Sobéy [29] proposed a two-layer model with a stationary layer at the annulus’ bottom and a heterogeneous layer above. One of the first models that work for both fine and coarse particles. The diffusivity equation was used to calculate the solid composition of the heterogeneous layer [30]. Brown et al. [31] experimentally compared Gavignet’s model utilizing Dodge and Metzner’s Reynolds number for turbulent non-Newtonian flow [32]. This allowed them to calculate a cutting wall friction factor of 0.2 empirically. Instead of clear mud, Martins and Santana offered a two-layer model with a heterogeneous layer. It permitted particles to be suspended in the upper layer, unlike Gavignet and Sobey’s concept. Iyoho and Takahashi [33] observed spatial changes in cuttings bed height along the wellbore using a similar approach. All previous models assumed that the bed height remains constant along the wellbore. In this case, a two-layer model with triangular dunes was adopted. The model requires knowledge of pressure fluctuations: sliding and heterogeneous layer model by Clark [24] to forecast bed heights. The wellbore angle determines the primary mechanism. This is one of

36

M. S. Khan et al.

the first devices to recognize that high angles require a rotating cutting bed. A lifting device transfers clippings at a churning, moving cuttings bed. Particle settling determines almost vertical transport. Based on various wellbore angles. Also, Kamp [34] used mass balance and momentum models to predict cutting transport behavior. In terms of closure terms, the model looks to be similar to Doron et al. Quantitatively, two-layered models outperform correlation-based models. At a given mud flow rate, the model overestimates cuttings transfer.

3.4.2 Layer Model Doron and Barnea [35] proposed a three-layer concept with a fixed bed, a moving bed, and a mixed layer in 1993. It was an extension of Doron’s two-layer model [30] proposed in 1987. The two-layer model’s fundamental flaw is its inability to reliably forecast the presence of a stationary bed at low flow rates. The three-layer model outperformed the two-layer model for low flow rates. According to Nguyen and Rahman [36], three layers of cuts with a uniform concentration and velocity. On top of that layer is a distributed cuttings layer with a Wilson-like velocity gradient [37]. The top layer is clear mud. Ramadan et al. [38] proposed a threelayer model for inclined channel flows. Experiments did not validate this model. Although the three-layer cutting transport model has been developed, it is still limited to Newtonian fluid flows in horizontal and nearly horizontal channels [37]. The prior modeling studies’ flaw of no-slip between particles and fluid was also eliminated. However, the no-slip assumption restricts the model to horizontal and near-horizontal situations [39].

3.5 Empirical Model Research Centre Sunbury, comparing the effects of major parameters such as hole angle, penetration rate, mud characteristics, and flow regime. On the other hand, Zamora and Hanson [40] proposed an empirical model based on experimental and field observations to improve hole cleaning efficiency for high angle wellbore. Luo and Bern [41] proposed a model for determining the minimum flow rate required to clear or prevent stationary cuttings beds on the low-side of a deviated wellbore. The model was validated using experimental data from an 8” wellbore simulator at BP. Larsen et al. [40] created a model for strongly inclined wellbores (50–90°). The model forecasts the critical velocity and cuttings-bed thickness when the flow rate is below the critical flow. Based on empirical correlations from a 35 ft long 5-inch diameter flow loop. Valid for holes 500° or more or where cutting beds may occur. Hopkins [41] discovered that increasing drilling fluid density reduced bit cutting slip velocity and quantified this effect using a novel equation with modifications. The density of drilling fluid can only be increased so far. If the Equivalent mud density

3 Multiphase Flow Systems and Potential of Machine Learning …

37

exceeds the formation pressure, the formation may fracture. To estimate the critical or minimal velocity to lift the cutting from the wellbore, Rudi [42] established a new model with equations. This model develops Moore’s slip velocity of a vertical well for usage in inclined and horizontal wells with Larsen’s slip velocity method modifications for rotating speed and mud weight. The minimal mud rate of Larsen’s approach, Larsen’s experiment data, and Peden’s experiment data do not differ much from this new equation in the publication. However, at an inclination angle of 45°, the new equation produces a larger mud minimum rate than the previous techniques. Tobenna [43] used Bern-approach Lou’s and a correction factor in computing the critical flow rate for deviated wells. In 2017, Mohamad Ishaq et al. [44] examined the Rudi-Shindu [42], Hopkins [41], and Tobenna [43] models. Hopkins’ model [41] is modified by cutting size and RPM (RPM). The Tobenna [43] model’s minimum flow rate is only affected by well inclination, drilling fluid weight, and rheological characteristics. Rudi’s model is restricted to inclinations exceeding 45°. The explored models are not suited for horizontal wells because they do not contain lateral section effects [44]. Several writers have developed other empirical models optimized using experimental data sets [22, 45–48]. They were designed for a limited range of drilling settings and are dependent on the experimental setup. Extending the range affects its accuracy [48]. Recently, Khaled and colleagues [17] created a generalized dimensionless model for accurate prediction of cuttings concentration in deviated wells using data from many sources, including experimental work, computational fluid dynamics (CFD) simulation, and experimental data acquired from the literature. The model can predict the cutting transport behavior with a resounding accuracy of 90% for various hydrodynamic conditions.

3.6 Transient Model During the drill operations, the cuttings bed distribution changes in real-time. The conventional models can only calculate the unchanging height of the cuttings bed at the end of the formation, but not the changing cuttings bed distribution during the process. The annulus pressure drop is uncertain if the cuttings bed distribution is unknown. Similarly, removing the cuttings bed from the borehole takes time. The steady models can’t characterize the process and calculate the hydraulics. Iyoho et al. [49] introduced transient models for cutting removal in 1987. Subsequently, Martins et al. [52] developed a two-layer transient model for horizontal wells based on mass and momentum conservation equations. Shigemi Naganawa [50] devised a modified two-layer model to simulate cuttings transport along an extended-reach well’s complete trajectory in wellbore drilling. Other factors as cuttings concentration and bed height were also predicted in nonstationary flow [39]. Most of them are made up of nonlinear equations that are difficult to solve. So, real-time calculation in fields is difficult [51].

38

M. S. Khan et al.

We can conclude from the evolution of the different types of cutting transport models presented in chronological order and classified form in terms of their underlying mechanisms. It was observed that although the 2D and 3D models provide a better representation of actual cutting transport, 1D models are more comfortable to develop, solve, and take less time. However, there is still a need for improvement in the existing models. The Empirical models are not used for field application as many variables involved impose restrictions. Therefore, applying the latest predictive technique like machine learning is very important in this perspective.

3.7 Machine Learning Approaches for Cutting Transport Accurate cutting transport or hole cleaning is imperative for a successful drilling operation. It has been seen that although it is easier in the case of vertical wells, however, it is more difficult in the case of horizontal and extended reach well due to the accumulation of cuttings at the lower side of the borehole due to gravity. Over the years, several different techniques such as empirical, Dimensional analysis, mechanical and numerical models have been used for predicting cutting transport phenomenon. However, Artificial Intelligence (AI), especially the machine learning (ML) technique, is still very limited in this field [52]. Artificial neural networks (ANNs) are mathematical models inspired by studies on brain systems, consisting of highly interconnected processing nodes or elements (artificial neurons) under a pre-specified topology (sequence of layers or slabs with full or random connections between the layers). Ozbayoglu and coauthors [55] were one of the first who used Back Propagation Neural Network (BPNN) in Artificial Neural Network (ANN) for Horizontal and Inclined wells. They developed three nondimensional parameters, i.e., Reynold number, Froude number, and cutting concentration at the bit, to predict the cuttings bed height of the stationary bed. Experimental data was used for developing the model using the traditional least-square fit and BPNN method. They revealed that ANN showed higher accuracy than the least square fit method. Rooki and coauthors [53] compared the BPNN and Multi Linear Regression (MLR) methods for predicting the cutting concentration during foam drilling for a Horizontal Well. Like Ozbayoglu [54], they revealed that BPNN showed a lower Average Absolute Percentage (AAPE) than the MLR Method, highlighting ANN technology’s effectiveness. Later on, Rookie and Rakhshkhorshid [55] used the Radial Basis Function Network (RBFN) method to predict the cutting concentration in a horizontal well. They [55] recommended that RBFN is a better prediction tool than the BPNN method, which showed higher accuracy, faster training, and simpler network architecture. Al-Azane and coauthors [56] used the Support Vector Machine (SVM) network for predicting the cutting concentration for horizontal wells. Aliouane and Ouadfeul [57] proposed a machine-learning algorithm to generate a poisson’s ratio map, which can be used to predict drilling direction and rock properties. Castineria et al. [58] used machine learning to assess the quality of large amounts

3 Multiphase Flow Systems and Potential of Machine Learning …

39

of drilling data, obtain critical information, and forecast non-productive time. This method helped reduce labor costs when checking the quality of large amounts of drilling data. Deepwater drilling can use the Bayesian network (BN) for Managed Pressure Drilling (MPD) and Under Balanced Drilling (UBD) operations. According to Bhandari et al. (2015), the BN can be used effectively for offshore industry risk analysis and failure prediction. Automation was used to control drilling parameters such as Weight of Bit (WOB), Rotary Speed (RPM), and Rate of Penetration (ROP). A machine learning algorithm can collect information on potential bit or rig equipment upgrades and estimate abrasive and anticipated bit wear [59]. Two-phase flow is the interaction of two distinct phases in a channel that share common interfaces, with each phase representing a mass or volume of matter. Both phases are capable of coexisting as solids, gases, or liquids. Although three-phase multiphase flow occurs, the bulk of multiphase engineering applications uses a twophase flow. Planning, development, and optimization are required for flow in any channel. Based on the interfaces generated between the phases, predicting the flow phases and flow regimes is critical, i.e., typical flow patterns. Based on the flow rate, channel size, and operating conditions, this knowledge allows for predicting pressure drop and heat transfer characteristics. The appropriate flow parameters can be determined based on the pressure drop data to reduce the occurrence of corrosion, erosion, or scale development, all of which can lead to excessive friction. Predicting flow regimes, such as oil and gas flow in pipelines or chemical process industries, allows avoiding excessive gas pressure buildup, meltdowns, and potentially hazardous explosions. The results of heat transfer analysis can be utilized to design flow channels and operating conditions and forecast and avoid flow instabilities. The heat transfer community and practicing engineers are predominantly interested in two-phase flow, which involves phase transition between a single substance’s liquid and vapor phases. Two-phase flow refers to the fluid flow of a two-phase mixture, which can be (1) liquid–vapor flow, (2) liquid–liquid, (3) liquid–solid particles, or (4) gas–solid particles. This category includes forced convective condensation and boiling. Solving two-phase flow and heat transfer problems is extremely difficult because each phase has its own properties, velocity, and temperature. The conveyance of multiphase well fluids is extremely prevalent in the oil industry. When the fluid from an oil and gas well reaches the wellhead, it forms a three-phase (oil, water, and gas) or two-phase (oil and gas) mixture. A single-phase liquid or gas flow at the wellhead is an extreme example. The multiphase fluid flow analysis is used to mimic the behavior and interactions of two fluid phases. The study uses the Volume of Fluid (VoF) method, a typical multiphase system computing method. Because of the variety in flow regimes, multiphase flow is substantially more difficult than single-phase flow (or flow patterns). Fluid distribution varies dramatically throughout flow regimes, influencing pressure gradients inside and outside the drill string.

40

M. S. Khan et al.

3.8 Flow Assurance issues in Liquid Loading Applications 3.8.1 Introduction of Liquid Loading Issue Most natural gas wells have enough reservoir pressure when they are first completed to flow formation fluids (liquid hydrocarbons and water) to the surface and the produced gas. As production continues, reservoir pressure falls, and the flowing fluid’s velocity in the well tubing begins to fall. Eventually, the gas velocity up to the production tubing is insufficient to lift liquid droplets to the surface. This phenomenon occurs when the upward gas velocity in the well falls below a critical value, known as critical velocity [66, 67]. The critical velocity is when the produced liquids, primarily flowing upwards, begin to drop back, causing liquid loading problems. This downhole liquid accumulation affects hydrostatic back-pressure on the reservoir, lowering production rates, disrupting the multiphase flow in the gas well (due to flow regime changes), and, in extreme cases, destroying natural gas wells presented in Fig. 3.6. Aside from dry natural gas wells, liquid loading concerns in the wellbore for volatile gases like condensates gas wells might be seen. When the pressure falls below the dew point pressure, gas condensates in the form of liquid form, imposing liquid loading. The typical liquid loading behavior in vertical and horizontal gas wells is depicted in Fig. 3.7.

3.8.2 Flow Pattern Analysis for Liquid Loading System Different flow patterns can occur when two phases (gas–liquid) pass through a wellbore/pipeline. Common flow distributions are bubbly, stratified, slug, annular, and Fig. 3.6 Evolution of the liquid loading in a natural gas well

3 Multiphase Flow Systems and Potential of Machine Learning …

41

Fig. 3.7 The characteristic liquid loading behavior in vertical and horizontal gas wells [11]

separated flows. Small bubbles are dispersed with a liquid phase in bubbly flow, whereas more oversized liquid slugs or larger gas pockets can form in slug flow. In stratified flow, the liquid and gas phases are separated, and the gas flows on top because it is lighter than liquid; and annular flow, where liquid flows as a film on the inner surface of the tubing. Mandhane et al. [68] offered a typical flow pattern map in the literature. The flow map attempts to anticipate the many sorts of flow zones. The flow map developed by Mandhane et al. [68] has been the most commonly used flow map for gas/Newtonian flow. They generated this flow map for horizontal two-phase flow using around 1400 experimental data from the AGA-API two-phase flow data bank. The most important flow pattern transitions in the prediction of liquid loading are linked with patterns of slug-to-churn and churn-to-annular flow. Even with the advent of modern instrumentation, it is now possible to obtain high-frequency measurements of critical flow parameters (e.g., phase fraction, pressure, temperature, velocity). The observed regime’s interpretation remains highly subjective [69]. The minimum gas flow rate model developed by Nosseir et al. [69] was based on the impact of flow regimes and variations in flow circumstances in natural gas wells. Moreover, Guo et al. [70] developed a closed-form analytical solution for determining the minimum gas flow rate for continuous liquid removal from a gas well. The following are the typical symptoms of liquid loading: • • • •

Unanticipated production losses The production of slugs or plugs in the fluid stream. Unanticipated variance in pressure gradients. Low-temperature spikes in the temperature profiles at the wellhead.

It is difficult to determine the beginning liquid loading point because it is not always obvious [71, 72]. A comprehensive well diagnostic data analysis must be performed to discover the origin of the liquid loading problem [73]. The most subjective liquid loading symptom is identified using flow mapping [74, 75]. Another critical criterion is to monitor changes in the gas wells’ pressure gradient or pressure

42

M. S. Khan et al.

profile. Understanding the components that influence liquid loading is critical for overcoming it. The superficial gas velocities (Vg,s) and superficial liquid velocities (Vl,s) have the greatest influence on creating different flow regimes in a natural gas well. Figures 3.8 and 3.9 represent the liquid holdup with a typical flow pattern in a horizontal and vertical gas well.

Fig. 3.8 A schematic representation of liquid holdup in horizontal gas wells with a typical flow pattern [76]

Fig. 3.9 A schematic representation of liquid holdup in vertical gas wells with a typical flow pattern [77]

3 Multiphase Flow Systems and Potential of Machine Learning …

43

3.8.3 Prediction Models for Liquid Loading Although several established techniques are used to alleviate the effects of liquid loading, the industry still lacks reliable predictive models to help select the best remedial option for a particular loading occurrence. Gas wells must operate at or above a predetermined minimum rate to avoid liquid loading. “The critical gas rate” is defined as the minimum stable gas rate (MSGR) required to produce condensate liquid or water to the surface without the accumulation of liquids below the surface. There are various correlations for estimating the critical gas rate, the majority of which are based on Turner’s [78] pioneering work conducted in 1969, with improvements presented by Coleman et al. [79], Li et al. [80], and many others. Most generalized critical gas velocity correlations include the following correlating parameters: bottom-hole flowing pressure “Pwf ,” psi, tubing radius “rw,” in inches, gas density “g,” lb/ft3 , liquid density “L,” lb/ft3 , surface tension “g–L,” dyne/cm, bottom-hole temperature “T,” °R. The fundamental force balance acting on liquid droplets’ balance includes the drag force of gas flowing upward and the downward force of the droplet’s weight. The drag force should be consistently higher than the gravity force. Fd = Fg

(3.1)

with Fd =

π d2 1 ρG C D VC2 2gc 4

(3.2)

Fg =

g π d3 (ρ L − ρG ) gc 6

(3.3)

after substitution / VC =

4g (ρ L − ρG ) d 3 ρG CD

(3.4)

The variables in the expression to evaluate the critical velocity include the drag coefficient (Cd), which depends on the Reynolds number, the diameter of the droplet, gas, and liquid densities in hydrocarbon condensate systems change significantly offshore flowlines due to immense pressure and temperature gradients. Though significant efforts have been made to predict the flowing conditions at which the well remains out of the liquid loading region using the so-called “Turner’s criteria,” these do not capture the dynamics of the loading sequence. Operators frequently use Turner’s criteria to design a production system to remove all liquids from the well at gas rates high enough to do so. It’s impossible to tell how much of a problem the loading is or how quickly it will slow down production with the

44

M. S. Khan et al.

help of these tools. From a flow mechanics perspective, It is critical to comprehend flow patterns and flow pattern transitions. The shape and behavior of the interface between phases in a multiphase mixture determine the “flow regime” or “flow pattern.“ Within the multiphase fluid, competing forces or mechanisms are at work simultaneously, and the balance determines the flow pattern. Additionally, the proportions and properties of the phases coexisting in the well/tubing must be determined to model multiphase flows associated with liquid loading in gas wells. A turbulent gas core with numerous entrained liquid droplets exists in an annular flow at the well’s center, while a brittle liquid layer (m to mm) exists at the tubing’s surface. At the bottom of the well, a turbulent gas core generates frictional pressure drop, while a thin liquid coating imposes hydrostatic pressure load. As a result, boosting gas production to minimize liquid loading may not solve a natural gas well’s liquid loading. Modeling methodologies used to characterize liquid loading in gas wells include empirical, phenomenological, two-fluid, and drift-flux models. Particular emphasis is placed on these approaches’ ability to capture the ephemeral aspect of the loading process. Phenomenological models are flow-pattern-based models that rely on identifying a specific flow regime and the use of adhoc pressure drop computations. Examples of phenomenological models include those based on the unit cell concept for slug flow in vertical pipes, which take into account the actual flow configuration (long Taylor bubbles separated by aerated liquid slugs) in the formulation of ad hoc models for calculating the void fraction, wall shear stress [81–84]. Data for frictional pressure gradient and void fraction are connected to system variables using empirical equations in empirical models. Many trials are required to duplicate a specific situation to develop a reliable empirical model, but this can be costly. The model is only applicable to a limited set of conditions unless the dimensional analysis is performed. There are several advantages to relying on empirical models rather than fundamental physical mechanisms. The two-fluid model does not work well with intermittent flow patterns like slug flow. Liquid flows upward in the Taylor bubble zone but downwards in vertical upward slug flow, making averaging liquid properties difficult. The relative motion between phases in most separated flows is closely proportional to the pressure and velocity gradients in the two phases. A drift flux model cannot account for this. The two-fluid technique also does not adequately capture churn flow. This flow pattern can be considered an annular flow with periodic reversals in the liquid film. Waves have developed, carrying the liquids upwards. A film travels downhill between the waves, replenishing the next upstream wave from which liquid is draining. The result is net upward liquid transfer. The two-fluid model does not account for this flow intermittency. Waltrich et al. [85] collected steady-state and transient two-phase flow experimental data at Texas A&M University’s TowerLAB facility in the United States, using a transparent vertical test Sect. 42 m in length and 0.048 m ID. As working fluids, air and water were used. Comparisons were made between a benchmark algorithm for multiphase flow in pipes, experimental data, and HyTAF, showing the need for additional research in this area. Alves et al. [86] demonstrated a satisfactory agreement between the observed pressure gradients of Waltrich et al. [85] and those predicted by HyTAF for

3 Multiphase Flow Systems and Potential of Machine Learning …

45

an induced transient example, from steady-state annular flow to steady-state churn flow. Most models used to forecast and diagnose liquid loading issues are based on steady-state analysis. As a result, they cannot deal with the transient phenomena associated with liquid loadings, such as the gradual buildup of the static fluid column in the well and the resulting increase in back-pressure on the formation. In business and academia, efforts are being made to link observed well dynamics with the intermittent reservoir response typical of liquid loading in gas wells. Even when transient multiphase wellbore models are used, the problem remains incorrectly described because the reservoir is characterized using a steady-state Inflow Performance Relationship (IPR), resulting in inaccurate boundary conditions between the well and the reservoir. Yang et al. [87] provided a new set of methods for determining the critical velocity for inclined wells that consider the various forces acting on a liquid droplet. They thought that the droplet constantly rises through the tubing’s midsection and is unaffected by the wall. Ming et al. [88] created a model that considers the degree of deviation and the influence of the Reynolds number. Their [88] findings suggested that the Reynolds number had a favorable impact on the critical liquid carrying velocity; however, the degree of variations had a negative impact. The standard pressure profile in the near-wellbore region of a flowing reservoir cannot characterize the transitory phenomena that occur during liquid loading. Because of a combination of inertia and compressibility effects, the reservoir reaction to wellbore phase redistribution effects is not instantaneous. A more reliable technique would be to utilize a transient multiphase flow wellbore model using the transient properties of the reservoir’s near-wellbore region as boundary conditions. Despite the several two-phase flow modeling methodologies available, it is critical to capture the transition from annular flow to churn flow, then to slug flow, and finally to bubble flow, which may result in the well’s demise. More study is needed in this area to develop credible predictive models that can assist in selecting the optimal remedial solution for a given incident of liquid loading. Table 3.1 summarizes the gas/liquid flow investigations on various types of fluxes. As previously stated, liquid loading is a common concern in gas wells, necessitating the development of a modified analytical model for predicting its occurrence and critical gas velocity. Monitoring the pipe’s appearance and position of deviated wells will necessitate greater experimental efforts. As highlighted from the brief literature review, liquid loading in the gas wells is one of the most problematic scenarios encountered during the production stages of the reservoir [13, 69, 71, 73, 89, 90]. The smooth gas production from the gas wells hinders the liquid loading issues. The undesired condensate and water are entrained in the gas phase below the dew point as the liquid phase goes below the bubble point pressure. The problem could even be worsened when solid particles are encountered in the gas wells. Therefore, it is highly desired to adopt the sophisticated and latest computational approach such as machine learning to accurately predict the onset of liquid loading (Tables 3.2 and 3.3).

46

M. S. Khan et al.

Table 3.1 Literature for ML technique applied in hole cleaning Author and Year

Well Type

ML Technique

Parameter Studied Error

Ozbayoglu et al. [54], 2002

Horizontal and highly inclined wells

BPNN

Cuttings bed height

Error < 10%

BPNN and MLR

Cutting concentration during foam drilling

AAPE for ANN < 6%, AAPE for MLR < 9%

Rooki et al. [53], Horizontal annulus 2014

Rooki and Rakhshkhorshid [55], 2017

Horizontal annulus

RBFN

Cutting concentration in underbalanced drilling

AAPE = 5.7%

Al-Azane et al. [56], 2018

Horizontal and Deviated wells

SVM

Cutting concentration

AAE < 5%

Al-Azani et al. [60], 2019

Horizontal and Deviated wells

ANN and SVM

Cutting concentration

AAE < 5%

Sorgun et al. [61], 2015

Horizontal Annulus

Support Vector Regression

Pressure loss

AAE < 6%

Osman [62], (2004)

Deviated well

BPNN

Flow regime Identification and calculate Liquid hold up

AAE < 10%

Sorgun and ulcer Horizontal pipe TrainGdx–Tansig [63], 2016

Pressure drop

AAE < 20%

Ozbayoglu et al. [64], 2009

Horizontal wellbore

Several ANN techniques

Fluid pattern and pressure drop

AAE for fluid patter < 5%, AAE for pressure drop < 20%

Ashena and Moghadasi [65], 2011

Vertical wellbore

BPNN, Ant Colony Optimization (ACO), Genetic Algorithm (GA.)

Bottom hole pressure estimation

ACO and GA performs better as compared to BPNN

3.8.4 Machine Learning Approaches for Liquid Loading or Gas/liquid Flow Determining multiphase flow parameters like flow pattern, pressure drop, and the liquid holdup is a difficult and valuable problem in the chemical, oil, and gas industries, especially during transportation. There are two basic approaches to solving this problem in the literature: data-driven algorithms and mechanistic models. Although data-driven methods are more accurate in forecasting, they do not reveal the twophase characteristics (i.e., pressure gradient, gas and local liquid velocities, liquid holdup, etc.). Machine Learning is the latest prediction technology for efficiently

3 Multiphase Flow Systems and Potential of Machine Learning …

47

Table 3.2 Gas/liquid two-phase flow studies Authors and Year

Type of Fluid

Geometry

Dimension

Studied Parameters

Ansari et al. [91], 1994

Gas wells

Vertical and directional wells

4.57– 17.78 cm ID length, Wellhead pressure

Developed mechanistic model

Vertical

7.62 cm ID/18 m Minimum flow length rate

Coleman et al. Gas wells [79], 1991 D. Barnea [92],1987

Air and water

Vertical-Inclined

5 cm ID, 3.45 bar– 43.13 bar

Hakim et al. [93], 2018

Air and water

Vertical

7.62 cm ID/40 m Pressure gradient length and liquid holdup

Goal and Valkó [94], 2016

Air and water

Vertical

4.8 cm ID/42 m length

Ikpeka and Okolo [95], 2019

Air and water

Vertical and deviated

3.1 cm ID/9.5 m A new model to length, Wellhead predict liquid pressure = loading 40 bar

Guo et al. [96], 2005

Gas wells with oil and water

Vertical wells

Different tubing sizes, Wellhead pressure

Develop a new correlation

Pedro Air and water Cavalcanti De Sousa [97], 2013

Vertical

6.03 cm ID/13.97 cm OD/42 m length

Investigate unexpected periodic release of liquid slugs

Paulo Jose Waltrich [85], 2011

Air and water

Vertical

50 cm ID/42 m length

Visualize two-phase flow regimes and measure pressure and liquid holdup

Riza et al. [98], 2016

Air and water

Vertical

50 cm/42 m length

Study of liquid loading phenomena

Slightly inclined (0.65° and 2.1°)

5 cm ID/26 m length

Flow regime

Andreussi and Air and water Person [99], 1987 Alsaadi et al. [100], 2015

Air and water

Operative equation and dimensionless map

Flow regime and validate a liquid content model

Vertical-Directional 7.62 cm ID/18 m Pressure gradient (60° to 88°) length and liquid holdup (continued)

48

M. S. Khan et al.

Table 3.2 (continued) Authors and Year

Type of Fluid

Geometry

Dimension

Studied Parameters

Guner et al. [101], 2015

Air and water

Vertical-Inclined (90° to 45°)

7.62 cm ID/18 m Pressure gradient, length liquid holdup, and visualization

Skopich et al. [102], 2015

Air and water

Vertical

5.08 cm and 10.16 cm ID/167.1 m length

Pressure gradient and liquid holdup

Dinaryanto et al. [103], 2017

Air and water

horizontal pipe

2.6 cm ID/10 m length at 8 bar pressure

Flow regime map and visualization

Kong and Kim Air and water [75], 2017

horizontal pipe

3.1 cm ID/9.5 m Flow regime length transition and Frictional pressure drop analysis

Kesana et al. [104], 2017

Air and water/air horizontal and Aqueous Carboxymethyl Cellulose (CMC) solution

7.62 cm ID/18 m Flow pattern map length and effect of liquid viscosity on slug flow distributions

Kong et al. [76], 2017

Air and water

3.81 cm ID/9.5 m length

horizontal

Flow regime mapping, the void fraction, bubble velocity analysis was also performed

predicting gas–liquid systems. For instance, Shaban et al. [105] employed an elastic mapping technique to produce a flow pattern map from differential pressure signals. Different flow patterns for air–water two-phase flow in a vertical pipe were examined. The elastic mapping method is a machine learning technology that reduces the number of data dimensions displayed in a two-dimensional map. The produced map displayed well-defined and clustered data of the same types of flow patterns. Al-Naser et al. [106] detected the flow pattern in a horizontal pipe using MATLAB and its built-in neural network technique. The authors generated input for various flow patterns using the unified model simulator. They [106] created a universal 3-D flow pattern map for various dimensions and fluid parameters based on the liquid Reynolds number, gas Reynolds number, and pressure drop multiplier. They showed that the model, based on the natural logarithm of the three dimensions, can correctly predict up to 97 percent of the flow patterns. Deep machine learning was applied by Ezzatabadipour et al. [107] for pipes with diameters of 1 or 2 inches and varying pipe inclinations; to predict annular, bubble, scattered bubble, intermittent, stratified smooth, and stratified wavy flows. They used a feedforward neural network known as a multilayer perceptron (MLP) to train 60

3 Multiphase Flow Systems and Potential of Machine Learning …

49

Table 3.3 Machine learning approaches applied on gas/liquid systems Authors and year

Application

Machine learning technique

Al-Naser et al. [106], 2016

Flow pattern detection in horizontal conduit

ANN technique

Ezzatabadipour et al. [107], 2017

Flow regimes predictions for 2-inch pipelines

Deep learning approach

Amaya-Gómez et al. [108], 2019

Predictions of flow regimes maps

Bayesian supervised method

Alhashem [113], 2019

Forecasted multiphase flow regimes in horizontal pipelines

Decision Tree, Random Forest, Logistic Regression, Support Vector Machine (SVM), and Neural Network Multi-Layer Perceptron were the methods evaluated in the study

Hernandez et al. [109], 2019

Classification of various flow Data-driven methodology for regimes for horizontal pipelines decision tree-based model

Almalkai and Ahmed [110], 2020

Flow pattern analysis from downstream of the orifice

Classification Learner approach in MATLAB

Mask et al. [111], 2019

Flow pattern analysis via dimensionless numbers

XGB tree model (machine learning) approach

Sami and Ibrahim [112], 2021 Flowing bottom-hole pressure Random forest, K-Nearest (FBHP) prediction for gas wells Neighbors (K.N.N.), and artificial neural network (ANN)

percent of a total of 5676 data points, with 20 percent for validation and 20 percent for testing. The outcomes showed that the strategy could predict the flow pattern accurately. Amaya-Gómez et al. [108] suggested a Bayesian supervised method with a novel visualization tool for flow pattern maps. Hernandez and coworkers [109] introduced a machine learning-based data-driven approach for flow pattern classification. A decision tree-based model was developed and then validated for flow pattern prediction using a set of 9224 observations using the data-driven methodology. Over a wide range of two-phase flow conditions, the closure relationship selection model correctly classified flow regimes. The intermittent flow was found to be the most accurate (86.32 percent), while the annular flow was found to be the least accurate (49.11 percent). The results show that less than 10% of global accuracy is lost compared to direct data-based algorithms, which is explained by the poor performance for unusual values and zones close to flowing pattern borders. The local pressure drop has been the focus of much research on two-phase flow via orifices. Despite the topic’s relevance, flow patterns downstream of an orifice have gotten comparatively little research. As the mixture passes through the aperture, the momentum of the phases increases considerably. Almalkai and Ahmed [110] introduced the ML technique for the flow pattern behavior analysis downstream

50

M. S. Khan et al.

of an orifice in a horizontal pipe. Findings revealed that the Classification Learner environment, a Machine Learning Algorithm in MATLAB, provides a total error of 9%, which indicates its prediction ability for flow pattern downstream of the orifice. Fluid characteristics, liquid and gas flow rates, flow conduit shape, and mechanical factors influence the flow pattern. Mask et al. [111] used hydraulic basics and dimensional analysis to reduce the number of freedom dimensions to produce three upscaling numbers. They used machine learning techniques on dimensionless variables to dramatically enhance their predicted accuracy to 90% or more than the usual dimensional model using experimental data, which gave an accuracy of 80%. Oil and gas production wells are evaluated based on the flow of bottom-hole pressure (FBHP). Oil production optimization, oil lifting costs, and workover operation assessment necessitate accurate FBHP predictions in the petroleum sector. Sami and Ibrahim [112] used three machine learning techniques to forecast the multiphase FBHP: random forest, K-Nearest Neighbors (K.N.N.), and artificial neural network (ANN). The results showed that using an artificial neural network model resulted in a 2.5 percent error in estimating the FBHP, which was less than the 3.6 percent and 4 percent errors in the random forest and K-nearest neighbor models. Alhashem [113] forecasted multiphase flow regimes in horizontal air, water, and oil pipelines using supervised machine learning (ML) approaches. The input features used were water cut (the proportion of water), gas superficial velocity, and liquid superficial velocity. The output was projected to be one of six different flow regimes. The methods evaluated in the study were Decision Tree, Random Forest, Logistic Regression, Support Vector Machine (SVM), and Neural Network Multi-Layer Perceptron (MLP). Their findings revealed that the random forest algorithm, with high accuracy of up to 90.8 percent and a short training time (0.13 s), is the best candidate for the dataset to increase the size of the data and features.

3.9 Case Studies in Multiphase Flow Assurance Petroleum companies are actively looking for new ways to become more efficient, such as streamlining production, lowering costs, and improving worker safety, among other things. Several administrators look to digitize to protect their businesses with lower oil prices and a recovering economy. The ML or AI are implemented in various fields within the industry, including production optimization, detecting oil seep, precision drilling, boosting production with predictive maintenance. The following paragraph only focuses on the case study in the cutting transport area. Shell Industry is a leader in exciting AI applications. Shell uses reinforcement learning to control its drilling equipment, essentially rewarding the AI’s choices [52]. A machine learning model, for example, is trained on historical drilling data and simulations to guide the drill into the subsurface. It also takes seismic data, temperature, pressure, and drill bit data into account. The steerer can then use reward and punishment functions to assist the drilling machine in adapting to changing subsurface conditions. This allows the geosteerer to understand the environment

3 Multiphase Flow Systems and Potential of Machine Learning …

51

better, resulting in faster results and less machine damage. In any case, progress is being made. Shell is always looking for big ideas to push the boundaries of the oil and gas industry. Shell game-changer regularly solicits machine learning-focused AI proposals from individuals and start-ups worldwide. Shell is leading to help solve some of the industry’s biggest challenges by investing in these ideas and collaborating on projects. Throughout the process, AI is being implemented or tested. The company recently implemented semi-supervised reinforcement learning to manage its drill rigs. However, machine learning can work with unlabeled data (supervised or unsupervised learning). Reinforcement learning strikes a middle ground by rewarding the AI’s “choices” based on their success. Shell’s drilling history and simulated explorations create algorithms that guide drills through the subsurface. It includes drill bit mechanical data like pressures and temperatures and subsurface seismic data. As a result, a Shell geosteerer is the human programmer of the drilling machinery, resulting in faster results and less wear and tear on machinery.

3.9.1 Conclusion Since This chapter provided a high-level overview of the multiphase system, including cutting transport and liquid loading in the flow assurance domain. The first sections discussed the process and existing prediction methods and their limitations. The research also includes a literature review on machine learning applications in the cutting transport and liquid loading fields. According to the machine learning literature, the application of ML is still in its early stages, especially for multiphase systems. Furthermore, the accuracy of predictive algorithms can be improved by gaining experience, either by increasing the size of the dataset or by adding relevant features. The oil and gas sector is entering a different normal of pandemic situation. Industry players must adapt to the new reality and improve their supply chain and activities. In this perspective, the appropriately trained ML model and logic can be tailored to the industry to provide automated flow control or install prediction and mitigation solutions for pipelines and field operations, potentially changing the oil industry’s value chain.

References 1. Qasim A, Saad Khan M, Lal B, Mohd. Shariff A, Che Ismail M, (2021) Evaluation of tetramethylammonium acetate as corrosion suppressor for flow assurance applications. Mater Today Proc. https://doi.org/10.1016/j.matpr.2021.03.568 2. Khan MS, Barooh A, Rahman MA, Hassan I, Hasan R (2021) Investigation of Flowzan as nonnewtonian cutting transport fluid in directional drilling applications via electrical resistance tomography method. In: ASME 2021 40th international conference on ocean, offshore and arctic engineering

52

M. S. Khan et al.

3. Bavoh CB, Lal B, Nashed O, Khan MS, Keong LK, Bustam MA (2016) COSMO-RS: an ionic liquid prescreening tool for gas hydrate mitigation. Chinese J Chem Eng 11:1619–1624 4. Ahmed I, Saad M, Lal B, Abdullah H, Alsaiari A (2021) Dual-functional gas hydrate inhibition of tetramethylammonium chloride for carbon dioxide-methane mixed gas systems. Fuel 305:121598 5. Khan MS, Bavoh CB, Partoon B, Lal B, Bustam MA, Shariff AM (2017) Thermodynamic effect of ammonium based ionic liquids on CO2 hydrates phase boundary. J Mol Liq 238:533– 539 6. Bavoh CB, Lal B, Ben-Awuah J, Khan MS, Ofori-Sarpong G (2019) Kinetics of mixed amino acid and ionic liquid on CO2 hydrate formation. IOP Conf Ser Mater Sci Eng 495:012073 7. Khan MS, Lal B, Sabil KM, Ahmed I (2019) Desalination of seawater through gas hydrate process: an overview. J Adv Res Fluid Mech Therm Sci 55(55):65–73 8. Qasim A, Heurtas J, Khan MS, Lal B, Mohammad Shariff A, Cezac P, Siak Foo K, Sundramoorthy JD (2021) Thermodynamic modeling of electrolytic solutions of ionic liquids for gas hydrates inhibition applications. J Adv Res Fluid Mech Therm Sci 81:110–123 9. Khan MS, Lal B, Shariff AM, Mukhtar H (2019) Ammonium hydroxide ILs as dual-functional gas hydrate inhibitors for binary mixed gas (carbon dioxide and methane) hydrates. J Mol Liq 274:33–44 10. Bolujo EO, Fadairo AS, Ako CT, Orodu DO, Omodara OJ, Emetere ME (2017) A new model for predicting liquid loading in multiphase gas wells. Int J Appl Eng Res 12:4578–4586 11. Liu T, Zhou X, Chen H, Lu G, Zhao Z, Liu D, Du Y (2019) Popularization and application of the capillary foam deliquification technology in horizontal wells with low pressures and low liquid flow rates: a case study on middle–shallow gas reservoirs in the Western Sichuan depression. Nat Gas Ind B 6:25–33 12. Gonzalez-Miquel M, Massel M, DeSilva A, Palomar J, Rodriguez F, Brennecke JF (2014) Excess enthalpy of monoethanolamine + ionic liquid mixtures: how good are COSMO-RS predictions? J Phys Chem B 118:11512–11522 13. Alsadoun R, Al Momen M, Luo H (2020). Prediction of liquid loading in gas condensate and volatile oil wells for unconventional reservoirs. https://doi.org/10.2523/iptc-19993-abstract 14. Anisa IN, a., Nour H a. (2010) Effect of viscosity and droplet diameter on water-in-oil emulsions: an experimental study. Eng Technol 38:213–216 15. Khan MS, AHmed I, Mutalib I, Bostum A, (2015) Role of oxygenated aditives for diesel fuel blend - a short review. J Appl Sci 15:619–625 16. Yusof ZAM, Ahmed I, Khan MS, Hussain SA, Hussain A, Mutalib I, bin A, Balkhair KS, Albeirutty MH, (2015) Thermal evaluation of diesel/hydrogen peroxide fuel blend. Chem Eng Technol 38:2170–2180 17. Khaled MS, Khan MS, Ferroudji H, Barooah A, Rahman MA, Hassan I, Hasan AR (2021) Dimensionless data-driven model for optimizing hole cleaning efficiency in daily drilling operations. J Nat Gas Sci Eng 104315 18. Khan MS, Barooah A, Rahman MA, Hassan I, Hasan R, Maheshwari P (2021) Application of the electric resistance tomographic technique to investigate its efficacy in cuttings transport in horizontal drilling scenarios. J Nat Gas Sci Eng 104119 19. Morshed M, Khan MS, Rahman MA, Imtiaz S (2020) Flow regime, slug frequency and wavelet analysis of air/Newtonian and air/non-newtonian two- phase flow. Appl Sci 10:3272 20. Barooah A, Khan MS, Rahman MA, Hasan AR, Manikonda K, Abdelrazeq M, Sleiti AK, El-Naas M, Hascakir B (2021) Investigation of gas-liquid flow using electrical resistance tomography and wavelet analysis techniques for early kick detection. In: ASME 2021 40th international conference ocean offshore architectural engineering. https://doi.org/10.1115/ OMAE2021-63725 21. Busch A, Islam A, Martins DW, Iversen FP, Khatibi M, Johansen ST, Time RW, Meese EA (2018) Cuttings-transport modeling-part 1: specification of benchmark parameters with a Norwegian-continental-shelf perspective. SPE Drill Complet 33:130–148 22. Busch A, Werner B, Johansen ST, Industry S (2020) Cuttings transport modeling—part 2: dimensional analysis and scaling. SPE Drill Complet 35:069–087

3 Multiphase Flow Systems and Potential of Machine Learning …

53

23. Qureshi MF, Ali MH, Ferroudji H, Rasul G, Khan MS, Azizur M, Hasan R, Hassan I (2021) Measuring solid cuttings transport in Newtonian fluid across horizontal annulus using electrical resistance tomography (ERT). Flow Meas Instrum 77 24. Clark RK, Bickham KL (1994) Mechanistic model for cuttings transport. In: Proceedings SPE Annual Technology Conference on Exhibitions Delta, pp 139–153 25. Martins AL, Costapinto Santana C (1992) Evaluation of cuttings transport in horizontal and near horizontal wells - a dimensionless approach. In: SPE Latin America and Caribbean petroleum engineering conference, proceedings, pp 155–161 26. Wicks M (1971) Transport of solids at low concentration in horizontal pipes. Adv Solid–Liquid Flow Pipes Its Appl. https://doi.org/10.1016/b978-0-08-015767-2.50010-7 27. Tomren PH, Iyoho AWAJ (1986) Experimental study of cutting transport in directional wells. SPE Drill Eng 01:43–56 28. Nazari T, Hareland G, Azar JJ (2010) Review of cuttings transport in directional well drilling: Systematic approach. In: Society of Petroleum Engineers West North American Registration Meeting 2010 - Collaboration with Jt Meet Pacific Sect AAPG Cordilleran Sect GSA 1, pp 108–122 29. Gavignet AA, Sobey IJ (1989) Model aids cuttings transport prediction. J Pet Technol 41(916– 921):15417 30. Doron P, Granica D, Barnea D (1987) Slurry flow in horizontal pipes-experimental and modeling. Int J Multiph Flow 13:535–547 31. Brown NP, Bern PA, Weaver A (1989) paper SPE/IADC 18636 presented at the, New Orleans, Louisiana (February 28 – March 3 1989) 171. (1989) Cleaning deviated holes: new experimental and theoretical studies. In: SPE/IADC drilling conference 32. Flow T, Systems N turbulent flow of non-newtonian systems. AIChE J 5:189–204 33. Iyoho AW, Takahashi H Modeling cuttings transport in horizontal, eccentric wellbores. unsolicited Pap. In: SPE 27416 34. Kamp A, Rivero M (1999) Layer modeling for cuttings transport in highly inclined wellbores. In: Latin America and Caribbean petroleum engineering conference. https://doi.org/10.2523/ 53942-ms 35. Doron P, Barnea D (1993) A three-layer model for solid-liquid flow in horizontal pipes. Int J Multiph Flow 19:1029–1043 36. Nguyen D, Rahman SS (1996) A three-layer hydraulic program for effective cuttings transport and hole cleaning in highly deviated and horizontal wells. In: SPE/IADC Asia Pacific drilling technology 37. Wilson KC (1987) Analysis of bed-load motion at high shear stress. J Hydraul Eng 113:97–103 38. Ramadan A, Skalle P, Johansen ST (2003) A mechanistic model to determine the critical flow velocity required to initiate the movement of spherical bed particles in inclined channels. Chem Eng Sci 58:2153–2163 39. Zhang H, Li G, Huang Z, Tian S (2013) Mathematical model of critical velocity for cuttings transport in microhole drilling. SOCAR Proc 2013:39–46 40. Larsen TI, Pilehvari AA, Azar JJ (1997) Development of a new cuttings-transport model for high-angle wellbores including horizontal wells. SPE Drill Complet 12:129–134 41. Hopkins CJ, Leicksenring RA (1995) Reducing the risk of stuck pipe in the Netherlands. In: SPE/IADC drilling conference 42. Rubiandini RS (1999) Equation for estimating mud minimum rate for cuttings transport in an inclined-until-horizontal well. In: SPE/IADC middle east drilling technology conference 43. Tobena UC (2010) Hole cleaning and hydraulics. Universitetet i Stavanger 44. Shiddiq AMI, Christiantoro B, Syafri I, Abdurrokhim MBTH, Wattimury P, Resesiyanto H (2017) A comprehensive comparison study of empirical cutting transport models in inclined and horizontal wells. J Eng Technol Sci 49:275–289 45. Rose HE, Duckworth RA (1969) Transport of solid particles in liquid and gases. Engineer 227:478–483 46. Turian RM, Yuan T, Maurl G (1971) Pressure drop correlation for pipeline flow of sol id-Liq u id Suspensions, 17

54

M. S. Khan et al.

47. Mingqin D, Miska SZ, Mengjiao Y et al (2006) Transport of small cuttings in extended reach drilling. In: International oil gas conference exhibition China 2006 - Sustain growth oil gas, vol 2, pp 800–808 48. Thomas AD (1976) Scale-up methods for pipeline transport of slurries. Int J Miner Process 3:51–69 49. Iyoho AW, Horeth JM, Veenkant RL (1987) A computer model for hole-cleaning analysis. In: SPE Annual technical conference and exhibition 50. S. Naganawa TN (2006) Simulating transient behavior of cuttings transport over whole trajectory of extended reach well. In: IADC/SPE Asia Pacific drilling technology conference exhibition 51. Wang Z, Zhai Y, Hao X, Guo X, Sun L (2010) Numerical simulation on three layer dynamic cutting transport model and its application on extended well drilling. In: IADC/SPE Asia Pacific drilling technology conference exhibition 52. Sircar A, Yadav K, Rayavarapu K, Bist N, Oza H (2021) Application of machine learning and artificial intelligence in oil and gas industry. Pet Res. https://doi.org/10.1016/j.ptlrs.2021. 05.009 53. Rooki R, Doulati Ardejani F, Moradzadeh A (2014) Hole cleaning prediction in foam drilling using artificial neural network and multiple linear regression. Geomaterials 04:47–53 54. Ozbayoglu E, Miska S, Reed T, Takach N (2002) Analysis of Bed Height in Horizontal and Highly-Inclined Wellbores by Using Artificial Neuraletworks. In: SPE international thermal operations and heavy oil symposium. International Horiz well technology conference. https:// doi.org/10.2523/78939-ms 55. Rooki R, Rakhshkhorshid M (2017) Cuttings transport modeling in underbalanced oil drilling operation using radial basis neural network. Egypt J Pet 26:541–546 56. Al-Azani K, Elkatatny S, Abdulraheem A, Mahmoud M, Ali A (2018) Prediction of cutting concentration in horizontal and deviated wells using support vector machine. In: Society of Petroleum Engineers - SPE Kingdom Saudi Arab annual technical symposium and exhibition 2018, SATS 2018. https://doi.org/10.2118/192193-ms 57. Aliouane L, Ouadfeul SA (2014) Sweet spots discrimination in shale gas reservoirs using seismic and well-logs data. A case study from the Worth basin in the Barnett shale. Energy Proc 59:22–27 58. Castiñeira D, Toronyi R, Saleri N (2018) Machine learning and natural language processing for automated analysis of drilling and completion data. In: SPE Kingdom Saudi Arab annual technical symposium and exhibition. https://doi.org/10.2118/192280-MS 59. Dunlop J, Isangulov R, Aldred WD, Sanchez HA, Flores JL, Herdoiza JA, Belaskie J, Luppens JC (2011) Increased rate of penetration through automation. In: SPE/IADC drilling conference exhibition. https://doi.org/10.2118/139897-MS 60. Al-Azani K, Elkatatny S, Ali A, Ramadan E, Abdulraheem A (2019) Cutting concentration prediction in horizontal and deviated wells using artificial intelligence techniques. J Pet Explor Prod Technol 9:2769–2779 61. Sorgun M, Ozbayoglu AM, Ozbayoglu ME (2015) Support vector regression and computational fluid dynamics modeling of Newtonian and non-Newtonian fluids in annulus with pipe rotation. J Energy Resour Technol Trans ASME 137:1–5 62. Osman ESA (2001) Artificial neural networks models for identifying flow regimes and predicting liquid holdup in horizontal multiphase flow. Proc Middle East Oil Show 797–804 63. Sorgun M, Ulker E (2016) Modeling and experimental study of solid-liquid two-phase pressure drop in horizontal wellbores with pipe rotation. J Energy Resour Technol Trans ASME 138:1–5 64. Ozbayoglu EM, Ozbayoglu MA (2009) Estimating flow patterns and frictional pressure losses of two-phase fluids in horizontal wellbores using artificial neural networks. Pet Sci Technol 27:135–149 65. Ashena R, Moghadasi J (2011) Bottom hole pressure estimation using evolved neural networks by real coded ant colony optimization and genetic algorithm. J Pet Sci Eng 77:375–385

3 Multiphase Flow Systems and Potential of Machine Learning …

55

66. Ajani A, Kelkar M, Sarica C, Pereyra E (2016) Foam flow in vertical gas wells under liquid loading: critical velocity and pressure drop prediction. Int J Multiph Flow 87:1339–1351 67. El Fadili Y, Shah S (2017) A new model for predicting critical gas rate in horizontal and deviated wells. J Pet Sci Eng 150:154–161 68. Mandhane JM, Gregory GA, Aziz K (1974) A flow pattern map for gas-liquid flow in horizontal pipes. Int J Multiph Flow 1:537–553 69. Falcone G, Barbosa JR (2013) State-of-the-art review of liquid loading in gas wells. DGMK/ÖGEW-Frühjahrstagung 129–150 70. Tao G, He L, Liu W, Xu L, Xiong W, Wang T, Kou Y (2006) Preparation, characterization and application of amino acid-based green ionic liquids. Green Chem 8:639 71. Abdullahi MB, Sulaiman ADI, Abdulkadir U, Salaudeen I, Shehu BU (2019) Production optimization of liquid loading problem in offshore Niger delta gas condensate field. Society of Petroleum Engineers - SPE Niger annual technical symposium and exhibition 2019, NAIC 2019. https://doi.org/10.2118/198873-MS 72. Shekhar S, Kelkar M, Hearn WJ, Hain LL (2017) Improved prediction of liquid loading in gas wells. SPE Prod Oper 32:539–550 73. Okoro EE, Bassey CI, Sanni SE, Ashiq MGB, Mamudu AO (2019) Application of nonuniform film thickness concept in predicting deviated gas wells liquid loading. MethodsX 6:2443–2454 74. Kvandal H, Holm H, Valle A (2007) Liquid holdup in high pressure, low temperature, gascondensate flow with low liquid loading including hydrate inhibitor. In: 13th international conference multiphase production technology, pp 209–223 75. Kong R, Kim S (2017) Characterization of horizontal air–water two-phase flow. Nucl Eng Des 312:266–276 76. Kong R, Kim S, Bajorek S, Tien K, Hoxie C (2017) Experimental investigation of horizontal air–water bubbly-to-plug and bubbly-to-slug transition flows in a 3.81 cm ID pipe. Int J Multiph Flow 94:137–155 77. Du M, De JN, Gao ZK, Wang ZY, Zhai LS (2012) Flow pattern and water holdup measurements of vertical upward oil-water two-phase flow in small diameter pipes. Int J Multiph Flow 41:91–105 78. Turner RG, Hubbard MG, Dukler AE (1969) Analysis and prediction of minimum flow rate for the continuous removal of liquids from gas wells. J Pet Technol 21:1475–1482 79. Graf JF, Coleman MM, Painter PC (1991) 6710–6723 80. Li G, Yao Y, Zhang R (2016) An improved model for the prediction of liquid loading in gas wells. J Nat Gas Sci Eng 32:198–204 81. Fernandes RC, Semiat R, Dukler AE (1983) Hydrodynamic model for Gias-liquid slug flow in vertical tubes. AIChE J 29:981–989 82. Orell A, Rembrand R (1986) A model for gas—liquid slug flow in a vertical tube. Ind Eng Chem Fundam 25:196–206 83. Sylvester ND (1987) A mechanistic model for two-phase vertical slug flow in pipes. Trans Am Soc Mech Eng 109:206–213 84. de Cachard F, Delhaye JM (1996) A slugh-churn flow model for small-diameter airlift pumps. Int J Multiph flow 22:627–649 85. Waltrich PJ, Falcone G, Barbosa JR (2011) Performance of vertical transient two-phase flow models applied to liquid loading in gas wells. In: Proceedings - SPE annual technology conference exhibition, vol 5, pp 3568–3582 86. C.Alves MV, Falcone G, Barbosa JR (2012) Modeling the transient behavior of churn-annular flow in a vertical pipe. 3rd Brazilian Conference Boil Condens Multiph Flow, pp 7–9 87. Yang D, Ding Y, Du T, Mao S, Zhang Z (2018) Buoyant back-layering and the critical condition for preventing back-layering fluid in inclined tunnels under natural ventilation: brine water experiments. Exp Therm Fluid Sci 90:319–329

56

M. S. Khan et al.

88. Ming R, He H (2017) A new approach for accurate prediction of liquid loading of directional gas wells in transition flow or turbulent flow. J Chem. https://doi.org/10.1155/2017/4969765 89. Chen D, Yao Y, Fu G, Meng H, Xie S (2016) A new model for predicting liquid loading in deviated gas wells. J Nat Gas Sci Eng 34:178–184 90. Zhu Q-L, Xu Q (2015) Liquid organic and inorganic chemical hydrides for high-capacity hydrogen storage. Energy Environ Sci 8:478–512 91. Ansari AM, Sylvester ND, Sarica C, Shoham O, Brill JP (1994) A comprehensive mechanistic model for upward two-phase flow in wellbores. SPE Prod Facil 9:143–151 92. Barnea D (1987) A unified model for predicting transitions for the whole pipe inclinations. Int J Multiph Flow 13:1–12 93. Hakim H, Katende A, Sagala F, Ismail I, Nsamba H (2018) Performance of polyethylene and polypropylene beads towards drill cuttings transportation in horizontal wellbore. J Pet Sci Eng 165:962–969 94. Gaol AHL, Valkó PP (2016) Modeling wellbore liquid-content in liquid loading gas wells using the SPE. In: Low Perm Symposium Denver, Color, USA 95. Ikpeka PM, Okolo MO (2018) Title: Li and Turner Modified model for Predicting Liquid Loading in Gas Wells. J Pet Explor Prod Technol 9:1971–1993 96. Guo B, Ghalambor A, Xu C (2005) A systematic approach to predicting liquid loading in gas wells. SPE Prod Oper Symp 9 97. Cavalcanti de Sousa P (2013) Upward gas-liquid flow in concentric and eccentric annular spaces. Texas A&M University 98. Riza MF, Hasan AR, Kabir CS (2016) A pragmatic approach to understanding liquid loading in gas wells. SPE Prod Oper 31:185–196 99. Andreussi P, Persen LN (1987) Stratified gas-liquid flow in downwardly inclined pipes. Int J Multiph Flow 13:565–575 100. Alsaadi Y, Pereyra E, Torres C, Sarica C (2015) Liquid loading of highly deviated gas wells from 60° to 88°. In: SPE annual technical conference and exhibition, 18 101. Guner M, Pereyra E, Sarica C, Torres C (2015) An experimental study of low liquid loading in inclined pipes from 90° to 45°. In: SPE production and operations symposium proceedings 2015, pp 505–525 102. Skopich A, Pereyra E, Sarica C, Kelkar M (2015) Pipe-diameter effect on liquid loading in vertical gas wells. SPE Prod Oper 30:164–176 103. Dinaryanto O, Prayitno YAK, Majid AI, Hudaya AZ, Nusirwan YA, Widyaparaga A, Indarto D (2017) Experimental investigation on the initiation and flow development of gas-liquid slug two-phase flow in a horizontal pipe. Exp Therm Fluid Sci 81:93–108 104. Kesana NR, Parsi M, Vieira RE, Azzopardi B, Schleicher E, McLaury BS, Shirazi SA, Hampel U (2017) Visualization of gas-liquid multiphase pseudo-slug flow using wire-mesh sensor. J Nat Gas Sci Eng 46:477–490 105. Shaban H, Tavoularis S (2014) Identification of flow regime in vertical upward air-water pipe flow using differential pressure signals and elastic maps. Int J Multiph Flow 61:62–72 106. Al-Naser M, Elshafei M, Al-Sarkhi A (2016) Artificial neural network application for multiphase flow patterns detection: a new approach. J Pet Sci Eng 145:548–564 107. Ezzatabadipour M, Singh P, Robinson MD, Guillen-Rondon P, Torres C (2017) Deep learning as a tool to predict flow patterns in two-phase flow 108. Amaya-Gomez R, López J, Pineda H, Urbano-Caguasango D, Pinilla J, Ratkovich N, Muñoz F (2019) Probabilistic approach of a flow pattern map for horizontal, vertical, and inclined pipes. Oil Gas Sci Technol. https://doi.org/10.2516/ogst/2019034 109. Hernandez JS, Valencia C, Ratkovich N, Torres CF, Muñoz F (2019) Data driven methodology for model selection in flow pattern prediction. Heliyon 5:e02718 110. Almalki N, Ahmed WH (2020) Prediction of two-phase flow patterns using machine learning algorithms. In: International conference fluid flow, heat mass transfer, pp 182–1–182–9 111. Mask G, Wu X, Ling K (2019) An improved model for gas-liquid flow pattern prediction based on machine learning. J Pet Sci Eng 183:106370

3 Multiphase Flow Systems and Potential of Machine Learning …

57

112. Sami NA, Ibrahim DS (2021) Forecasting multiphase flowing bottom-hole pressure of vertical oil wells using three machine learning techniques. Pet Res. https://doi.org/10.1016/j.ptlrs. 2021.05.004 113. Alhashem M (2019) Supervised machine learning in predicting multiphase flow regimes in horizontal pipes. In: Society of petroleum engineers - Abu Dhabi international petroleum exhibition and conference. OnePetro, ADIP 2019. https://doi.org/10.2118/197545-ms

Chapter 4

Machine Learning in Corrosion Jai Krishna Sahith Sayani and Bhajan Lal

Abstract This chapter presents the advances and progress on the use of machine learning in corrosion. Specifically, the use of machine learning to predict corrosion rate in pipelines. Keywords Machine learning · Flow assurance · Corrosion · Predictions · Model

4.1 Introduction Corrosion is a common problem that occurs in every industrial sector. Corrosion has become a major crisis in each sector due to its effect that can influence the profit and loss in any production business. This is because when corrosion occurs, it can affect the quality and the quantity of the product produced thus, it requires maintenance to back to its original condition. More critical if corrosion becomes uncontrol, any unpredicted accident can happen that can cause events such as sudden burst, leaking, explosion, and a more serious case can involve a fatality. This chapter will include the corrosion mechanisms, factors that influence corrosion, and types of corrosion that can happen in the oil and gas industry. Besides, it also describes the mitigation procedures that can be done to minimize and control the corrosion as it is quite impossible to completely avoid the corrosion from keep occurring. Next, in implementing all the possible corrosion controls, it is important to determine the corrosion rate of the equipment in order to decide which method

J. K. S. Sayani Department of Chemical and Bioprocess Engineering, University College Dublin (UCD), Dublin, Ireland B. Lal (B) Chemical Engineering Department, Universiti Teknologi PETRONAS, 32610 Bandar Seri Iskandar, Perak Darul Ridzuan, Malaysia e-mail: [email protected] Research Centre for CO2 Capture (RCCO2C), Universiti Teknologi PETRONAS, 32610 Bandar Seri Iskandar, Perak, Malaysia © The Author(s), under exclusive license to Springer Nature Switzerland AG 2023 B. Lal et al. (eds.), Machine Learning and Flow Assurance in Oil and Gas Production, https://doi.org/10.1007/978-3-031-24231-1_4

59

60

J. K. S. Sayani and B. Lal

is the most suitable and the correct amount of corrosion inhibitor requires to minimize the corrosion rate if applicable. The corrosion rate can be determined based on experimental or computer simulation methods. These methods are also described in this chapter. Over the years, corrosion has become the main problem faced by every sector. Alternatives in determining the corrosion rate in terms of simulation have been developed to tackle this problem. Various corrosion prediction models have been developed based on the different operating conditions of the process involved. HYDROCOR, Cassandra, De Waard, NORSOK, Lipucor, ECE, and KSC are examples of the corrosion prediction model includes in this chapter.

4.2 Corrosion in Oil and Gas Industry 4.2.1 Corrosion Mechanism Corrosion has been a major crisis that occurs not only in the oil and gas industry but also in every processing plant. It can occur in every piece of equipment such as storage tank, pipeline, reactor, and distillation column whenever the corrosion factors exist. Some of the main factors of corrosion are oxygen, metal ion, and water vapour. Corrosion is the degradation process of material strength and its critical properties as a result of chemical, electrochemical, and other processes that involve the reaction between the exposed material surface and the surrounding environment. As corrosion can happen easily regardless of its severity level, a large amount of revenue has been allocated only for corrosion as whenever it happened, the recovery cost will include the maintenance, compensation, and installation of a new part of the affected equipment.7/8847 For example, in 2018 around $1.4 billion was spent by US oil and gas exploration and production industry only for corrosion purposes as reported by NACE International also known National Association of Corrosion Engineers. Therefore, this crisis must be overcome by implementing the steps in reducing the corrosion rate to avoid losing a large amount of revenue. It occurs when the reduction–oxidation (redox) reaction takes place as the substance transforms to a more stable form. The selection of which metal to undergo whether oxidation or reduction will be based on the standard electrode potential. For the metal with higher standard electrode potential, it will undergo reduction at the cathode side while the metal with lower standard electrode potential will likely undergo oxidation at the anode site. The anodic metal will likely become thinner throughout the redox reaction as it loses some of its electrons whereas, for the cathodic metal, it will become thicker due to the gaining electron process. 2M → 2M2+ + 4e− O2 + 2H2 O + 4e− → 4OH−

(Anodic reaction) (Cathodic reaction)

(4.1) (4.2)

4 Machine Learning in Corrosion

61

4.2.2 Corrosion Factors Environmental factor has been the main influence of corrosion to occur. Various types of corrosion can take place due to the existence of certain factors such as pH, pressure, temperature, and the presence of sulfides, acid, and carbon dioxide [1]. Increases in temperature can result in increasing corrosion rate since the collision frequency of ions increases. Even so, the corrosion rate increases with temperature, whenever the temperature reaches its peak point, the corrosion rate starts to decrease due to the formation of corrosion product on the metal surface avoiding the reaction between the metal surface with the corrosion agent. Next, an increase in pressure will result in increase flow velocity and directly lead to an increase in corrosion rate. This is because, at this condition, higher speed of the fluid able to remove the protective layer formed on the metal surface causing a more exposed area of metal and allowing corrosion to happen [2]. In addition, the presence of certain elements able to corrosion to happen. For example, an increase in the oxygen concentration is able to increase the corrosion rate since oxygen will likely undergo a cathodic reaction during the electrochemical process. However, for metals such as stainless steel, titanium, and aluminium, the presence of oxygen is able to maintain the protective oxide layer on these metals [3]. Therefore, the presence of oxygen can result in an increase and decrease of corrosion rate depending on the surrounding conditions. Moreover, the presence of carbon dioxide or hydrogen sulfide that dominant an area can classify whether it undergoes sweet corrosion or sour corrosion, respectively. This classification of corrosion can help in determining the suitable corrosion control to be implemented. Besides, the partial pressure of carbon dioxide also can be used to determine the corrosion severity of the equipment. For example, for carbon dioxide partial pressure (PPCO2 ) < 48 kPa, it can be considered as non-corrosive, 48 kPa < PPCO2 < 207 kPa can be considered as medium corrosion, and PPCO2 > 207 kPa can be considered as severe corrosion [4].

4.2.3 Types of Corrosion General corrosion or also known as uniform corrosion or general attack corrosion is a type of corrosion that occurs at the same rate over the entire surface area of the metal that is exposed to the corrosion-causing conditions (Fig. 4.1). This happens due to the presence of acids, salts, and when oxidation and reduction reactions occur uniformly [1]. The uniformly occur electrochemical reaction results in thinning of the wall or surface thickness until failure occurs. However, the corrosion can be well managed by increasing the thickness of the exposed surface. Next, galvanic corrosion is corrosion that happens when the two dissimilar metals are placed together in a corrosive electrolyte (Fig. 4.2). For the metal with high corrosion resistance, it will become the cathode while the other metal will become the anode. This type of corrosion can happen due to the presence of acids, water, and the deposition of salts

62

J. K. S. Sayani and B. Lal

Fig. 4.1 General corrosion on a metal surface [4]

from sulfides and chlorides [1]. In the anode–cathode extend, the further the position of the two metals in the galvanic series, the lower the reactivity between the metals thus minimizing the galvanic corrosion. In addition, another type of corrosion that can happen is pitting corrosion (Fig. 4.3). This corrosion can be observed when there are holes, cavities, or pits formed on the metal surface. It is considered more dangerous than general corrosion due to its difficulty to be traced and predicted. This difficulty is because of the formation of corrosion product that forms on the metal surface that covers the holes and pits resulting in the unnoticeable pits. This type of corrosion involves three stages which are the formation of the surface layer on the metal surface, initiation of pits at localized regions where layer breakdown occurs, and followed by pit propagation and final material penetration. Moreover, intergranular corrosion is corrosion with the localized attack that occurs at grain boundaries or directly next to grain boundaries, leaving the majority of the grains intact. If this corrosion occurs, it may lead to loss of tensile properties and loss of cross-sectional thickness of the materials. This corrosion is likely to occur due to a fabrication process that involves heating or cooling where some of the material content can be reduced when undergoes the process. Lastly, many other types of corrosion can happen in the oil and gas industry such as crevice corrosion, microbial induced corrosion (MIC), erosion corrosion, stress corrosion, and intergranular corrosion.

4 Machine Learning in Corrosion

63

Fig. 4.2 Galvanic corrosion at three lead pipe joints [4]

Fig. 4.3 Pitting corrosion on a metal surface [5]

4.2.4 Corrosion Control The selection of the most suitable corrosion control can be influenced by the chemical involved in the corrosion and the environmental conditions. The first thing that should be considered in the selection of construction material. There is no material that is

64

J. K. S. Sayani and B. Lal

able to fulfill all the requirements. The most common material 0020 used is carbon steel due to its cheapness but the usage of carbon steel, especially in natural gas systems, must come with the application of the coating, cathodic protection, and injection of corrosion inhibitors to minimize the corrosion rate. Other than carbon steel, titanium alloy also can be used in natural gas as it is highly corrosion resistant due to the formation of TiO2 passive layer and also highly resistant to H2 S, CO2, and brine [6]. Besides, for the injection of corrosion inhibitor, it will be adsorbed and covered the metal surface. By increasing the concentration of the corrosion inhibitor, it able to reduce the metal surface exposed to the corrosion agent. There are multiple types of corrosion inhibitors that can be utilized such as anodic inhibitors, cathodic inhibitors, organic and inorganic inhibitors based on the purpose of the usage [3]. Prior to injecting the corrosion inhibitor into the equipment, it recommends doing some chemical cleaning such as pigging. For the reason that the effectiveness of the inhibitors can be reduced when the suspended solids and sand present as it will attract the molecules of the inhibitors. Apart from these two alternatives, there are other ways that can be utilized to minimize the corrosion rate such as cathodic protection and coating. All of these corrosion controls can be done based on the behaviour of the corrosion agents and the internal or external environmental conditions of the equipment involved.

4.3 Mitigation Procedures The severity of corrosion can be influenced by the material of construction. The selection of materials for the construction of the equipment is very vital as it will influence the capital expenditures (CAPEX) and operational expenditure (OPEX). Therefore, it is required to keep both balances by implementing the mitigation activities. Carbon steel is the most commonly used material in construction such as a pipeline. However, this application is only applicable with the implementation of corrosion control such as injection of inhibitors and cathodic protection. Other than carbon steel, materials such as stainless steel, alloy, and PVC have also been used as construction materials depending on the operating conditions of the process and the characteristics of the substances involved.

4.3.1 Pigging Pigging is a process where a device known as ‘pig’ is inserted in a pipeline that used the flowing fluid as the driving force. It can be categorized into three types based on its functionality such as cleaning pigs, sealing pigs, and in-line inspection (ILI). Cleaning pigs are used to remove the solid deposition, debris, wax, asphaltenes, and biofilms from the pipe whereas cleaning pigs are used to seal, sweep liquid (mainly

4 Machine Learning in Corrosion

65

water), apply corrosion inhibitors, coat the pipe, and separate products. Lastly, inline inspection (ILI) pigs are a tool that is utilized to inspect pipelines and are also known as intelligent pigs. It can be done on a variety sizes of pipelines as it will not interrupt and stop the flow of the materials flowing through the pipeline. Besides, pigging can be implemented in both metallic and non-metallic pipelines. Pigging is used to remove accumulated water and sediment in non-metallic pipes. During construction, operation and maintenance, inspection, repair and rehabilitation, and decommissioning, a pigging operation is carried out. Pigs exist in various shapes which used for different applications such as a sphere, cast, and multi-diameter.

4.3.2 Corrosion Inhibitor In addition, the usage of corrosion inhibitors has been one of the commonly used applications for corrosion control. Most construction in the oil and gas industry implement the usage of carbon steel for the equipment that is only possible with the assistance of corrosion inhibitors. This application is the most trusted, time-tested, and proven method that can be used especially in the production, transportation, and refinery sectors in the oil and gas industry. The characteristics of organic corrosion inhibitors that are commonly used in the oil and gas industry are organic, polar, and surface-active molecules. It is made up of mixtures containing active ingredients for inhibitors, hydrate inhibitors, antifoaming agents, and more but rarely made up of pure substance. The application of corrosion inhibitors is by injecting a small concentration of the chemical substance into the corrosive media to decrease or prevent the reaction between the metal and the media. Then, the inhibitors will operate by the adsorption of ions or molecules onto the metal surface. The injection of corrosion inhibitors to the corrosive media is able to reduce the corrosion rate of the media by increasing or decreasing the anodic and/or cathodic reaction, decreasing the diffusion rate for the reactant to the surface of the metal, and decreasing the electrical resistance of the metal surface. In addition, the selection of corrosion inhibitors depends on some factors such as cost, availability, toxicity, and biodegradability. The usage of the natural product as the corrosion inhibitor has been considered previously but the usage has already been banned due to its toxicity towards human beings and the environment. This case same goes for the organic compound that contains nitrogen, oxygen, or sulfur that has significant inhibition efficiency but is not being used due to expensive and toxic to the environment. Therefore, the existence of plant extract as a corrosion inhibitor has been one of the options of corrosion inhibitor. This is because plant extract is a renewable source of inhibitor, readily available, and environment-friendly other than it has very high inhibition efficiency. It is believed that the presence of heterocyclic constituents like alkaloids and flavonoids causes the possibility of plant extract to be a corrosion inhibitor.

66

J. K. S. Sayani and B. Lal

Based on the study done on the effectiveness of non-ionic surfactants as corrosion inhibitors which are aniline and ethoxylated aromatic amine, it is found that by increasing the concentration of corrosion inhibitor, the corrosion rate decreases and the inhibition efficiency also increases [7].

4.3.3 Internal Coating Coating can be one of the options to control the corrosion rate. Some confusion might happen from the words of liner and coating which liner can be referred to as the materials used to protect the internal surface whereas coating can be referred to as the materials used to protect the external surface. In minimizing or preventing the corrosion rate, both protection from the internal coating and external coating can be done. Various types of coating can be used for the internal protection of the surface. For examples are polymeric liners, clad materials, and refractive index. The consideration of polymeric liner as an internal coating is due to its properties such as adhesion, abrasion resistance, ability to withstand rapid changes of pressure without blistering or flickering, elasticity to withstand stresses during construction, and ability to withstand welding temperature. Moreover, properties like electrical resistivity, aging, water and moisture resistance, flexibility, resistance to a salt solution, solvent, hydrocarbon, and wet H2 S gas are other properties that are also taken into account during the selection of polymeric liner. Different types of polymeric liners have different properties that are suitable for only certain functions. The most widely used liners in the oil and gas industry are epoxies and vinyls other than phenolics, furans, neoprenes, and alkyds. Refractive index is another internal coating that can be used for reducing the corrosion rate. This liner typically is used for the surface material that is exposed to high temperatures such as in refineries. This liner typically has a range of thickness between 25 and 100 mm. The performance of this liner can be measured from its installation, materials, process, and fabrication. Some examples of the materials used for refractories are silica, chromium oxide, silicon nitride, and alumina.

4.3.4 External Coating Pipeline corrosion can happen in the external and internal of the pipeline due to exposure to the corrosion factors. As for corrosion that occurs outside the pipeline, the corrosion control can divide whether exposed to the atmosphere or exposed to the underground environment. For the corrosion that happened due to atmospheric exposure, the corrosion can be controlled by implementing the electrically insulated coating. The various coating can be used, for example, polymetric coating, metallic or thermal spray coating, girth weld coating, insulator, and concrete coating.

4 Machine Learning in Corrosion

67

Polymetric coating is an anti-corrosion coating that is applied to the above-ground structure and to buried infrastructures. Some of the usages of this coating are in the 1980s, extruded three-layers coatings were used with an inner fusion bonded epoxy (FBE) layer, an adhesive layer, and an outer polyolefin (polyethylene or polypropylene) layer. In the 1990s, the composite coatings were used, with an inner FBE, a graded layer of FBE, and modified polyethylene, and followed by an outer polyolefin layer. Some examples of the materials used as polymetric coating are coal tar, asphalt, and extruded polyolefins. Next, girth weld coating is used during pipeline construction as a protective fluid coating that is placed to the metal surface of two pipes that have been linked throughout their circumference. It is also known as joint coatings since it is commonly applied to protect weld-joint. Some types of girth-weld coatings that have been used in the oil and gas industry are tape coating, heat shrinkable coating, polyolefin, and powder epoxy. Tape coating can be applied based on the type of application whether it is a hot or cold application with different maximum operating temperatures. Each of the applications has its tape that can be used as each tape has its own characteristics. For example, the bituminous tape is a single and multi-layer tape that can be applied with or without primer whereas petrolatum is a single and multi-layer tape that must be applied with primer. It also has a typical maximum operating temperature of 30 °C. Next, heat shrinkable coating is a protective coating in form of a wraparound or tubular sleeve for the pipeline that consists of an adhesive and an extruded polyolefin outer layer. This coating will shrink in size and adapt to the surface it is surrounded by whenever the heat is applied to it. The shrinking process of the coating is caused by the polyolefin contained in the sleeve which also the uniqueness of this coating. The types of heat-shrinkable coating can be classified into two, whether with primer or without primer. Each of the tapes has its maximum operating temperature as an indicator for the selection of tape during the decision-making process. For example, polyethylene with no primer has a maximum operating temperature of 50 °C. In addition, liquid epoxy, urethane, vinylester, wax, elastomeric, and visco-elastic coatings are the other types of girth weld coating. Besides, metallic coating or also known as thermal spray coating is used for applications such as wear resistance, corrosion resistance, bioactivity, and dielectric properties of light metal [8]. This coating protects the steel from these problems by acting as a barrier coating or sacrificial anode It is also widely used in industrial sectors such as biomedical, automotive, and aerospace as a protective coating due to its suitability to be applied to all types of materials such as pure metals, metal alloys, oxide ceramics, cermets, plastics, and hard metals (carbides). However, materials that can easily decompose irreversibly during melting, not stable during melting, and vaporize excessively in the spray process are not suitable for this coating [9]. Silicon ceramics and magnesia are examples of materials that are not suitable for this type of coating.

68

J. K. S. Sayani and B. Lal

4.3.5 Cathodic Protection Cathodic protection is an electrical method for corrosion control for the metallic structure that is widely used in the underground system. For examples of the system are lead cables, water treatment equipment, steel piling, well casing, and water storage tank. In this method, there is the involvement of current that flows from the more negative potential metal to more positive potential metal through an electrolyte. Some corrosion types that can be related to this protection method are electrolytic corrosion and galvanic corrosion. Electrolytic corrosion occurs due to the existence of current from an external source that enters and leaves a particular metallic structure through an electrolyte. This type of corrosion mechanism is also called stray current corrosion in the underground work. Next, galvanic corrosion occurs due to the differences in the electrolyte such as soil resistivity, oxygen concentration, moisture content, and various ion concentration. The cathodic protection mechanism requires an anode, a cathode, and an electrolyte to occur. For the cathode or the structure to be protected, the commonly used materials are made up of iron, steel, and stainless steel however, there are other metals that also can be used as a cathode such as lead, sheathed cable, copper, and aluminium piping, galvanized steel, and cast iron. Moreover, the widely used electrolyte is soil or water but there are also some unusual electrolytes that can be used successfully which are concrete, calcium chloride, and caustic soda. In conducting the cathodic protection, there are two methods that can be applied which are impressed current cathodic protection and sacrificial anode cathodic protection. Firstly, impressed current cathodic protection requires the anode to be energized by an external direct current (DC) power source which the anode will be then installed in an electrolyte and connected to the positive terminal of the DC power source. For the structure that to be protected, it will be connected to the negative terminal of the power source. This method is also known as a rectifier system. Next, for the anode of this method, it requires the one that has longer life as it will corrode during the process. Examples of the anode are graphite, high silicon cast iron, and precious metal oxide coated titanium. Secondly, the sacrificial anode cathodic protection requires the usage of the galvanic anode with a higher energy level or potential compares to the structure to be protected. In addition, the anode of this method can be whether magnesium or zinc whereas the structure to be protected can be made up of material such as iron or steel. However, the selection of the anode and structure can be done based on the electromotive force series where the lower material in the ranking will be the anode.

4.3.6 Process Optimization Process optimization is another method that can be used for corrosion control. This method is implemented by altering the environment of the equipment or pipeline to

4 Machine Learning in Corrosion

69

make it not corrosion favorable. The operating condition such as pH, temperature, pressure, and flowrate will play the important role in this method. However, this method can be said to be expensive and sometimes impractical environment.

4.4 Corrosion Prediction Models The Corrosion prediction models are used to estimate and predict the corrosion rate of the equipment of the pipeline. This can be done during the designing of the equipment in order to plan or strategize the corrosion control measure that needs to be implemented to minimize the corrosion that might occur. Several corrosion predictions models have been developed with different environmental factors, limitations, and philosophies during the development of the models. The prediction model can be classified as a mechanistic, empirical, or semi-empirical model. For a mechanistic model, it has a strong theoretical background and considers the mechanisms of basic reactions such as chemical, electrochemical, and transport processes. Whereas the empirical model has a very little theoretical background with a foundation of a set of basic empirical correlations. For the semi-empirical model, it is partly based on well-established theoretical hypotheses. They are expanded for practical reasons to regions where there is insufficient theoretical knowledge in such as way that the extra phenomena may be explained empirically [10]. It is observed that for the cases of lack of corrosion or very low corrosion rate, it happened because of the formation of protective films and/or oil wetting factors [11]. Institute for Energy Technology (IFE) has conducted several discussions with corrosion experts from different oil companies such as Saudi Aramco, Shell, Chevron, and BP. The outcome from these meetings is a guideline for the use of a CO2 corrosion prediction tool that can be used to estimate the corrosion rate in the oil and gas industry. Some of the prediction models that have been evaluated from the IFE joint projects are as follows: • • • • • • • • • • • • • •

HYDROCOR CORPLUS KSC MODEL MULTICORP NORSOK model De Waard model Cassandra ECE model PREDICT Corpos SweetCor Tulsa model OLI model ULL model

70

J. K. S. Sayani and B. Lal

4.4.1 Hydrocor HYDROCOR model is a mechanistic model developed by Shell. This model is a combination of corrosion and fluid flow modeling with a few assumptions. The flow considered for this model is extended to slug flow which brought to a mean that it ignores the bubble collapsing in the slug mixing zone [12]. It also assumed that there is no protection film during the presence of water formation and weak protection film for condensed water cases [13]. Oil wetting factor is considered when the water cut is below 40% and liquid velocity is above 1.5 m/s however, this consideration is only valid for crude oil systems but not for gas condensate [14]. For this model, it requires the inlet pressure and temperature, mole percentage of CO2 and H2 S, production rates, bicarbonate, organic acid, glycol content, and pipe diameter as the main input parameters. Some additional information that is also required is oil type (gas condensate or crude oil) and water type (condensed water or formation water). This model considers the small effect of protective films and less sensitivity of the variation of pH.

4.4.2 Cassandra Cassandra is a predictive tool from BP that considered the corrosion in multiphase flow. For this model, it considered a weaker effect of protective layer at high temperature than in the de Waard model but does not specify the effect for the cases whether with or without the water formation [12]. This model requires temperature, total pressure, liquid velocity, water chemistry, and mole percentage of CO2 as the main input parameters. Other information that also can be used if available are glycol concentration, oil type (condensate or crude oil), water type (condensed water or formation water), hydraulic diameter, and presence of acetic acid. This model also considers the relatively little effect of protective films and pH but not the oil wetting effect [14].

4.4.3 De Waard The De Waard model is a semi-empirical model that was originally developed by De Waard and Milliams in 1975. It has been revised several times due to the correction factors added to the original correlation that considered the effect of pH and little consideration on the formation of the protective film [13]. For the first version that developed in 1975, the dependency of the correlation is temperature and CO2 partial pressure. Some correction factors have been introduced in the 1991 version and 1993 version, which respected the effect of pH and corrosion product, and effect of fluid velocity, respectively. For the correlation that was revised in 1995, it takes

4 Machine Learning in Corrosion

71

into consideration the effect of mass transport, fluid velocity, and steel composition. The requirement of main input parameters only takes water cut, temperature, liquid velocity, CO2 partial pressure, and pH. For the information that can be used depending on its availability are hydraulic parameters, oil type (condensate or crude oil), water type (condensed water or formation water), total pressure, and glycol concentration. The consideration of protective films is only when no presence of formation water as it is neglected because of the possibility to break down when with the presence of formation water. It also assumed that for water cut below 30% and liquid velocity above 1 m/s, oil wetting and no corrosion occurs but only for crude oil system, not for condensate [14].

4.4.4 NORSOK NORSOK model is an empirical model developed by the Norwegian oil companies Statoil, Norsk Hydro, and Saga Petroleum. It takes into account the effect of protective layers especially at higher temperatures and higher pH. The range of temperature that can be applied to this correlation has been wider than the original one as it considers temperature from 5 to 150 °C [15]. The major input parameters required by this model are glycol concentration, pH, temperature, total pressure, CO2 content, and wall shear stress. The calculation of pH can be based on three ways; pH will be based on temperature and CO2 partial pressure for the condensed water without corrosion product, pH can be calculated for the pH in condensed water saturated with iron carbonate produced, and pH will be based on specified bicarbonate content and ionic strength from water analysis for pH of formation water [14]. This model does not consider the effect of oil wetting Scales.

4.4.5 Lipucor Lipucor model is an empirical model developed by Total that has two versions. The first version is a point model that the calculation of the flow regime will be at one point in a pipeline or well and a version that is based on fluid flow model which developed by the collaboration of Total, Elf, and Institute Français du Pétrole [14]. The parameters such as mole percentage of CO2 and H2 S, water chemistry, total pressure, pipe diameter, production rates, and temperature are the major input required. For the other information that can be used depending on its availability are steel composition, oil density, and gas molar weight. For this model, the pH has a relatively small effect on the corrosion rate, yet the calculation of pH will be based on the water chemistry, temperature, and CO2 content. The oil wetting factor is considered in this model. By utilizing this model, it is capable to indicate the corrosion type (general or localized) and the severity of the corrosion that might happen.

72

J. K. S. Sayani and B. Lal

4.4.6 ECE Electronic Corrosion Engineer or ECE model is developed by Intetech which inspired by the De Waard 95 model but includes a module for calculating pH from water chemistry and bicarbonate produced by corrosion, as well as an additional correlation for the influence oil wetting. The oil wetting factor is considered in this model which is based on a light crude oil field’s tube corrosion and determined by the density of oil, flow inclination, and liquid flow velocity [14].

4.4.7 KSC KSC model is a mechanistic model that developed at Institute for Energy Technology. Electrochemical reactions at the steel surface, chemical reactions in the liquid phase, species diffusion to and from the bulk phase, diffusion via porous corrosion films, and precipitation of iron carbonate in the corrosion film are all simulated in this model. The corrosion rate that calculated by this model can be with and without protective films but for the calculation without protective film, it will be used for the calculation for risk of mesa attack [14]. The main input parameters required by this model are CO2 partial pressure, pH, total pressure liquid flow velocity, and temperature. This model does not consider the oil wetting factor but the protective layer factors that are considered is sensitive to pH and temperature.

4.5 Machine Learning in Corrosion TIn the oil and gas industry, corrosion can occur in any sector whether upstream, midstream, or downstream. Any area of metal that is exposed to corrosion factors such as oxygen, hydrogen sulfide, and carbon dioxide can lead to a corrosive environment. Since the upstream sector involves the exploration and production process of crude oil and natural gas, corrosion tends to occur during the drilling process when the equipment exposes to any corrosion factors. Moreover, in order to sustain the oil production, the reservoir will be injected with water to increase the internal pressure. Excess exposure towards high water cut, temperature, and pressure can lead to a corrosive environment resulting in corrosion to occur. Next, the midstream sector relates to the transportation of raw materials, products, and transition substances to downstream sectors. This transportation includes crude oil, natural gas liquid (NGL), liquid petroleum products, oilfield steam, condensate, oilfield water, multiphase fluids, gas, and liquid or dense phase CO2 . In the midstream sector, pitting & crevice corrosion have a high chance to occur in the equipment such as pipeline, fittings, flanges, valves, bolting, and gaskets. As the transportation of products involves various types of fluid, the factors that influence corrosion to occur

4 Machine Learning in Corrosion

73

are also different. For example, corrosion factors for oil pipelines are water holdup, solid deposition, bacteria, velocity, CO2 , H2 S, and oxygen ingress whereas corrosion factors for the gas pipelines are solid deposition, methanol, elemental sulfur, water holdup, critical gas velocity, polysulfides, H2 S, CO2 , oxygen ingress, bacteria, and chlorides. Lastly, corrosion factors for water pipelines are microorganisms, scale formation, oxygen ingress, solid accumulation, CO2 (aq), and H2 S (aq). All the raw materials found in upstream will be transported to downstream through midstream. In downstream, all the raw materials will be processed prior to the purpose of the sale. This is the sector where the crude oil refineries, petrochemical plants, and petroleum product distribution take place and if the corrosion is not well controlled, it can affect the production period and cost. A scheduled shutdown or turnaround is a common thing that happens in downstream in order to perform maintenance and repair the equipment however if uncontrol corrosion happens, frequent unscheduled shutdown can lead to an increase in the cost of maintenance and production loss. Moreover, as some equipment requires to be opened during maintenance, it will increase the chances of the internal equipment to be exposed to air and moisture which can influence corrosion and stress corrosion cracking (SCC) to occur [4]. In investigating and determining the corrosion rate can be done by experimental method or computer simulation method. For the experimental method, the corrosion rate can be determined by observing the weight loss experienced by the materials or using the Tafel extrapolation method while for the computer simulation method, a machine learning application can be implemented to predict and determine the corrosion rate.

4.5.1 Weight Loss Method The weight loss method is one of the methods that can be used to determine the corrosion rate experimentally. However, this method is time-consuming as there is no driving force applied during the experiment. The change of weight of the metal specimen after being removed from the environment will be weighed and the corrosion rate will be calculated based on the formula as follows [16]. Corr osion Rate(C R) =

KW ρ At

where K = constant, 534 W = weight loss in milligram (mg). ρ = density of the metal sample in gram per cubic centimetre (g/cm3 ). A = sample area in square inch (in2 ). t = time of immersion (exposure) in hours (h). CR = corrosion rate in milli-inch per year.

(4.3)

74

J. K. S. Sayani and B. Lal

4.5.2 Tafel Extrapolation Method The Tafel extrapolation method is another method to determine the corrosion rate of material by estimating the corrosion current or corrosion potential in an electrochemical cell. This method is faster than the weight loss method is it involves an electric current that can act as the driving force. It is an accurate method as it considers all the reactions that involve in the corrosion. This consideration is made based on the assumption of simple electrochemical kinetics, to represent the mixed potential theory, predict the corrosion rate and potential based on the kinetics and thermodynamics of all the reactions occurring on the electrode surface. In determining the corrosion rate, a Tafel graph is plotted in order to determine the Tafel slope that will be required in the calculation of corrosion rate based on the formula as follow: 1 ) i corr = ( )( c 2.303R p ββaa ×β +βc ) ( i corr × t × M × 10 V = F ×S×d

(4.4)

(4.5)

where i corr = corrosion current density in amperes per square centimetre (A/cm2 ) R p = corrosion resistance in ohms square centimetre (Ω cm2 ). βa and βc = Tafel slopes. V = corrosion rate of polarization in millimetre per year (mm/year). t = immersion time. M = equivalent molar weight in gram per mol (g/mol). F = Faraday constant (96,500 C.mol−1 ). S = surface area of electrode. d = density of iron.

4.5.3 Machine Learning Over the years, various studies have been done related to predicting corrosion rate or corrosion behaviour using the machine learning approach. Both machine learning and experimental approaches have been used however, the machine learning approach has been a hot topic lately due to the world migration into Artificial Intelligence (AI) and more accurate outcomes compared to experiments. Most of the studies done on this corrosion topics majority are using neural network technique for the machine learning part. According to the study of prediction of pipeline internal corrosion profile, it was found that the technique used was feedforward neural networks which was a part of the neural network learning approach. De Masi et al. [17] proposed the usage of the Levenberg–Marquardt back propagation algorithm in predicting the internal corrosion profile of a pipeline and in identifying

4 Machine Learning in Corrosion

75

the pipeline sections that were critically exposed to the corrosion risk. In this study, three types of input variables were alternated with another three output variables in achieving the objectives of the study. The three types of input variables were geometrical pipeline characteristics, fluid dynamic multiphase variables, and deterministic models whereas the three output variables were corrosion rate, metal loss, and area of defects. In this study, the correlations used to estimate the corrosion rates were de Waard and NORSOK model. Next, referring to the study done by Canonaco et al. [18] that observed the behaviour of three types of machine learning on internal corrosion of pipeline, all the input data used which were geometrical variables and fluid dynamical variables were supplied from the Pipeline Inspection Gauge (PIG) and dynamic multiphase flow simulator (OLGA), respectively. For the performance of the learning algorithms which were Support Vector Machine (SVM), Neural Network, and XGBoost, it split the data into two sets with 80% for the training set and 20% for the test set. It also used cross-validation on the training set to maximize the performance of the learning algorithm. In this study, it showed that Support Vector Machine (SVM) was able to capture all of the phenomenon’s components better than XGBoost and Neural Network. In addition, the study of corrosion rate prediction using ANN in a carbonated mixture of MDEA-based solution showed that the ANN model showed a better performance compared to the SVM model [8]. In this study, the Levenberg– Marquardt BP algorithm was also chosen due to its smallest mean square error (MSE) and the lowest training time. From the results obtained, it showed that pH, solution type, and conductivity of the solution showed a higher correlation coefficient compared to the PZ, DEA, and MEA concentrations to corrosion rate. Based on the study on the identification of the crucial factors of corrosion done by De Masi et al. [17], it used an artificial neural network (ANN) as it was the most useful application for the prediction of internal corrosion. The input and out parameters used in this study were based on the historical and current operating data of the pipeline. For the input parameters, it used four categories of data which were hydrocarbon characteristics, geometrical pipeline characteristics, fluid dynamic multiphase variables, and deterministic models whereas the output parameter was corrosion volume loss. For the first category of the input parameters, it only included CO2 partial pressure, the second category includes elevation, inclination, and concavity of each segment, the third category includes flow regime, hold-up, pressure, gas flow, total flow, liquid velocity, and gas velocity, and lastly, the fourth category includes de Waard and NORSOK. For the evaluation of the dependency between the observed corrosion and the variables, Mutual Information (MI) analysis was used. This study concluded that at the finest scale of the region exposed to corrosion that at 10 m, it was found that hold-up, concavity, liquid velocity, and gas velocity had the highest influence on corrosion which were at 0.84, 0.64, 0.60, and 0.50 of the Mutual Information. From the studies, all the findings obtained show that in determining the most suitable and accurate algorithms and the number of hidden neurons, a trial and error method is used as each of the options has its preferable environment to operate with.

76

J. K. S. Sayani and B. Lal

This machine learning method also can be the fastest method to be used in predicting the corrosion rate of equipment depending on the size of the dataset used.

4.6 Case Study Throughout the years, there are many studies done on the prediction of corrosion rate using the machine learning approach. Various studies were done on this corrosion rate prediction using the machine learning approach with different operating conditions and the algorithms utilized in achieving the objectives. For the study done on the prediction of the lifetime of a pipe by Shaik et al. [19], it showed that corrosion played the most important role in the factor that influence the lifetime of the pipeline using the Artificial Neural Network (ANN) approach. In this study, there were two sections which were the machine learning development and sensitivity analysis. For the machine learning part, it was performed based on the corrosion, wall thinning, age, external diameter, pressure, thickness, and product type as the input, and the pipe condition target was the output. The data used in this study was based on the real-time operating data from the risk inspection date. In conducting the machine learning, the data samples were divided into three groups with 70%, 20%, and 10% for the training set, testing set, and validation set purposes. As for the training algorithm implemented in this study, it used the Levenberg–Marquardt algorithm as it was the fastest Back Propagation (BP) algorithm. As ANN consisting of three layers that included input, hidden, and output layers, the machine learning model was developed by implementing 7 neurons in the input layer that represented all the input parameters, 10 hidden neurons in the hidden layer, and 1 neuron in the output layer that represented the pipe condition target as the output of the machine learning model. In addition, the sensitivity analysis was done with the purpose to determine the correlation or the impact of each factor of the machine learning’s input on the pipe life condition which was the output of the machine learning. From this analysis, it found that corrosion was the factor with the highest negative impact on the pipe condition with 44% compared to other factors. It can be explained that increasing corrosion will affect decreasing pipe conditions. This study concluded that the machine learning developed was considered as successful reflecting on the coefficient of determination (R2 ) value obtained from the training, testing, and validation performed which were 0.9927, 0.9953, and 0.9842, respectively. Next, based on the study done by Diao et al. [20] on the influence of the chemical composition of low-alloy steel and environmental factors on the corrosion rate, it was found that both factors affect the corrosion rate of the pipe. In determining the key factors of the corrosion rate, the combination of gradient boosting decision tree (GBDT) and Kendall correlations were used due to its higher coefficient of determination (R2 ) in the training and testing sets compared to the principal component analysis (PCA) method. The R2 values for both training and testing sets of the preferred method were 0.94 and 0.92, respectively. Based on this method, the key factors that

4 Machine Learning in Corrosion

77

had the highest influence on corrosion rate were maximum dissolved oxygen content, maximum seawater salinity, minimum pH value, and mean temperature for the environmental factors whereas Cr, C, Si, P, and S contents for the materials factors. After the determination of key factors, machine learning was developed with all the key factors as the input and corrosion rate as the output. For the machine learning development, it used Phyton and random forest algorithm as the modeling algorithm. This was because the random forest algorithm had the highest coefficient of determination (R2 ) and root-mean-square error (RMSE) compared to the k-nearest neighbor model, multilayer perceptron model, support vector regression model with radial basis function kernel, linear kernel, and polynomial kernel. In the machine learning development, the data samples were divided into training and testing sets. The division of the groups was based on 40%, 50%, 60%, 70%, 80%, and 90% for the training set and the remaining for the testing sets. In this study, the development of machine learning implemented the random forest approach with 80% for the training set and 10% for the testing set. This was due to above 80% of the training set causing the accuracy of the model started to decrease which was believed to be caused by overfitting. Lastly, for the prediction of corrosion rate based on the key factors, the features λ– , V – , EN p– and ΔH f– under method II were selected for the prediction of corrosion rate due to its higher accuracy in terms of RMSE and R2 compared to the method I that utilized the usage of EN s , K, Rm, and Rc features. The R2 of method II for the training and testing sets were 0.91 and 0.90, respectively. Thus, based on the values of R2 and RMSE for the chosen method used, it showed that the machine learning developed was reliable for the corrosion rate prediction. Besides, Pei et al. [21] proposed the usage of the random forest machine learning approach to study the relation of corrosion rate on the environmental factors. Among all the listed environmental factors investigated which were temperature, relative humidity, rainfall, sulfur dioxide, nitrogen dioxide carbon monoxide, ozone, and particulate pollutant, only the first three parameters were considered as the key factors that influence the corrosion rate. This was due to its higher importance index compared to others. The importance index was determined using the random forest method. for the machine learning development, the data samples were split into two groups which were 90% for the training set and the remaining 10% for the testing set. This study also included the results for the Artificial Neural Network (ANN) and support vector regression (SVR) other than the random forest for comparison purposes. By considering the three key factors as the input and atmospheric corrosion monitoring current (IACM ) as the output of the machine learning, the random forest had the highest accuracy in terms of R2 compared to ANN and SVR. The R2 values for the training and testing samples were 0.526 and 0.457, respectively. In addition, another machine learning model was developed known as the corrected model. This corrected model included the formation of rust on the atmospheric corrosion monitoring (ACM) sensor as one of the inputs. This consideration caused the R2 of the random forest to increase from 0.526 to 0.940. For this corrected model, the random forest method still had the highest R2 than ANN and SVR with 0.94 for both training and testing samples. The consideration of rust formation was

78

J. K. S. Sayani and B. Lal

due to when the atmospheric corrosion occurred, the layer of the steel electrode became thicker and the roughness of the surface increased due to the rust formation. This situation led to enhancement ability by the sensor surface to collect moisture and decrease in the critical relative humidity to generate the IACM output. This study concluded that the corrected random forest model was a better machine learning model to be used for the prediction of corrosion rate as the number of the samples correctly predicted and the accuracy rate was higher than the first random forest model developed with 6196/6540 and 94.7%, respectively.

References 1. Fajobi M, Loto RT, Oluwole L, Fajobi MA, Loto RT, Oluwole OO (2019) Corrosion in crude distillation overhead system: a review energy absorption improvement of circular tubes View project Electrochemical analysis of the synergistic effect and corrosion inhibition property of quaternary ammonium surfactants and derivatives. J Bio-and Tribo-Corros 5:67 2. Abbas M (2016) Modelling CO2 corrosion of pipeline steels. Newcastle University 3. Groysman A (2017) Corrosion problems and solutions in oil, gas, refining and petrochemical industry. Koroze a Ochr Mater 61:100–117 4. Al-Janabi YT (2020) An overview of corrosion in oil and gas industry: upstream, midstream, and downstream sectors. Corros Inhib Oil Gas Ind 1–39 5. Tang K, Wilkinson S (2020) Corrosion resistance of electrified railway tunnels made of steel fibre reinforced concrete. Constr Build Mater 230:117006 6. Kane R, Craig S, Venkatesh A (2009) Titanium alloys for oil and gas service: a review. Corros 7. Migahed MA, Abd-El-Raouf M, Al-Sabagh AM, Abd-El-Bary HM (2005) Effectiveness of some non ionic surfactants as corrosion inhibitors for carbon steel pipelines in oil fields. Electrochim Acta 50:4683–4689 8. Li CJ (2010) Thermal spraying of light alloys. In: Surface engineering light alloy. Woodhead Publishing, pp 184–241 9. Petri V (2014) Thermal spray coating processes. In: Comprehensive Materials Processing, 1st ed, pp 229–276 10. Senouci A, Saeed El-Abbasy M, Elwakil E, El-Abbasy MS, Zayed T, Asce M (2014) Fuzzybased model for predicting failure of oil pipelines destructive analysis-based testing for curedin-place pipe view project toward clean water: avoid intrusion of contaminants into water systems. View project fuzzy-based model for predicting failure of oil pipelines. J Infrastruct Syst 20:375–387 11. Olsen S, Halvorsen A, Lunde P, Nyborg R (2005) CO2 Corrosion prediction model-basic principles. Corros 12. Wang H, Cai J-Y, Jepson WP (2002) CO 2 Corrosion mechanistic modeling and prediction in horizontal slug flow. In: Corros. 2002. OnePetro, p 02238 13. Nyborg R (2009) Guidelines for prediction of CO 2 corrosion in oil and gas production systems. Inst energiteknikk 1–16 14. Nyborg R (2002) Overview of CO2 corrosion models for wells and pipelines. Corros 15. Norsork Standard (2005) CO2 Corrosion rate calculation model. Majorstural, Norw Nor Technol Stand Inst Oscarsgt 20 16. Adeyanju O, Oyekunle LO (2009) Experimental investigation of the effects of different environmental conditions on pipelines corrosion rates. In: oSPE Niger annual international conference and exhibition 2009 17. De Masi G, Vichi R, Gentile M, Bruschi R, Gabetta G (2014) A neural network predictive model of pipeline internal corrosion profile. In: 1st International conference on systems informatics, modelling simulations 2014, pp 18–23

4 Machine Learning in Corrosion

79

18. Canonaco G, Roveri M, Alippi C, Podenzani F, Bennardo A, Conti M, Mancini N (2021) A machine-learning approach for the prediction of internal corrosion in pipeline infrastructures. In: IEEE International instrumentation and measurement technology conference 2021, pp 1–6 19. Shaik N, Pedapati S, Dzubir FAB (2022) Remaining useful life prediction of a piping system using artificial neural networks: a case study. Ain Shams Eng J 13:101535 20. Diao Y, Yan L, Gao K (2021) Improvement of the machine learning-based corrosion rate prediction model through the optimization of input features. Mater Des 198:109326 21. Pei Z, Zhang D, Zhi Y, Yang T, Jin L, Fu D, Cheng X, Terryn HA, Mol JM, Li X (2020) Towards understanding and prediction of atmospheric corrosion of an Fe/Cu corrosion sensor via machine learning. Corros Sci 170:108697

Chapter 5

Machine Learning in Asphaltenes Mitigation Ali Qasim and Bhajan Lal

Abstract The issue of Asphaltenes formation inside the pipeline is a major concern in flow assurance industry. These are complex polar molecules with high molecular weights. Asphaltenes mitigation is required as they disrupt the normal operation of the pipeline. Industry employs mechanical, ultrasonic, thermal, bacterial and chemical treatments to mitigate asphaltenes deposition. For asphaltenes prediction, preceding studies have used thermodynamic solubility technique, colloidal based models. Currently researchers have focused on machine learning techniques to predict the conditions of asphaltenes formation. The machine and deep learning methods included Bayesian belief network (BBN), Least-squares support vector machine (LSSVM), Support vector regression (SVR) and Genetic algorithm-support vector regression (GA-SVR). It was found that the use machine learning and deep learning approaches predicted accurately about the onset of asphaltenes precipitation and deposition. In future, the utilisation of machine learning approaches in the field of asphaltenes mitigation can be studied further. Keywords Machine learning · Flow assurance · Asphaltene · AI

5.1 Introduction Asphaltenes are complex molecules with the largest molecular weight known in crude oils, are far more hazardous than typical wax deposition. These are essentially polar molecules [1, 2]. Figure 5.1 depicts a part of asphaltene that originates in the pipeline. In terms of chemical composition, asphaltenes are made up of heteroatoms such as carbon, nitrogen, hydrogen, sulphide, and oxygen. Aromatic structures (cyclic A. Qasim Chemical Engineering Department, Universiti Teknologi PETRONAS, 32610 Bandar Seri Iskandar, Perak Darul Ridzuan, Malaysia B. Lal (B) Research Centre for CO2 Capture (RCCO2C), Universiti Teknologi PETRONAS, 32610 Bandar Seri Iskandar, Perak, Malaysia e-mail: [email protected] © The Author(s), under exclusive license to Springer Nature Switzerland AG 2023 B. Lal et al. (eds.), Machine Learning and Flow Assurance in Oil and Gas Production, https://doi.org/10.1007/978-3-031-24231-1_5

81

82

A. Qasim and B. Lal

Fig. 5.1 Asphaltenes formation inside pipeline

in shape) are also produced. In a variety of solvents, asphaltenes have different solubility ratios. It is highly soluble in some solvents, such as benzene and toluene, but insoluble at room temperature in n-pentane and n-heptane. Asphaltene can form in heavy oil when temperature and pressure conditions, as well as the makeup of the oil’s phases, alter. The compounds in this chemical cause clogging inside oil pipelines and huge reservoir wells, making it dangerous. Because of its proclivity to associate and aggregate, asphaltenes have been termed the “Cholesterol of Petroleum”. They are a viscous substance that boils at a high temperature [3, 4]. Asphaltene content in oils can range from less than a percent to as much as 20% [5, 6]. A range of analytical methodologies have been used to characterise the structure and size of asphaltene aggregates. The structure of the asphaltene molecule, on the other hand, has remained a mystery. Structural characterization includes determining the chemical components, molecular weight and size, and molecule architecture. Heavy metals like Nickel and Vanadium have the potential to change the reactivity of asphaltene molecules [7].

5.2 Asphaltene Precipitation and Deposition in Oil and Gas Industry The point at which asphaltenes begin to separate from oil is known as the commencement of asphaltene precipitation. One of the first stages in preventing asphaltene precipitation is to understand the asphaltenic fluid and its behaviour under various operating conditions from a thermodynamic aspect. Asphaltene precipitation occurs inside the asphaltene precipitation envelope (APE), which is defined by sufficient

5 Machine Learning in Asphaltenes Mitigation

83

temperature and pressure conditions [6, 8]. Figure 5.1 depicts a typical asphaltene phase envelope. APE can provide useful information on the way to adapt production settings to avoid asphaltene precipitation from reservoir fluid under high pressure and temperature. When reservoir pressure falls below the start of asphaltene precipitation pressure, which is lower than reservoir pressure but usually much higher than the saturation pressure of the active reservoir fluid, asphaltenes precipitate as shown in Fig. 5.2. As pressure decreases below the beginning precipitation pressure, the amount of asphaltene precipitation increases, reaching its maximum value as pressure approaches the bubble point pressure. As a result, the presence of gas components effects asphaltene precipitation, and the overall system’s composition and pressure control the stability of these precipitated particles. The operational pressure and temperature are represented by the P–T diagram. When modelling asphaltene precipitation with thermodynamic phase equilibrium, it is necessary to determine the energy associated with molecules as well as the parameters of interaction functional groups in the molecules [1, 9]. This emphasises the need of identifying and establishing the structure and properties of asphaltenes at the molecular level. Due to the improvements in research and the use of sophisticated analytical instruments, studying asphaltenes at the molecular level has resulted in the development of better thermodynamic prediction methods. Using equations of state, the structural analysis findings are applied to forecast the APE. Flow assurance engineers use this APE data to design production systems that maximise oil production while minimising asphaltene precipitation in reservoirs and flowlines [10]. However, precipitation is not the only factor that effects deposition; in order to form a layer, particles must contact the wall and adhere to it [11]. Asphaltene deposition is a serious flow assurance issue in oil and gas production, and resolving it takes a tremendous amount of capital. It is developed when the stability of asphaltene is affected by pressure, temperature, and composition of the involved system. The higher the asphaltene onset pressure, the lower the pressure at Fig. 5.2 Asphaltene precipitation envelope [6]

84

A. Qasim and B. Lal

which asphaltene forms which is also known as Upper Asphaltenes Onset Pressure (UAOP) [12]. This phenomenon can exist near the wellbore as well as along the flow lines, expanding the potential deposition zone from the reservoir and near-wellbore regions to surface facilities. The lower asphaltene onset pressure is the pressure below the bubble point at which asphaltenes dissolve in a solution (LAOP). Asphaltene deposition is estimated the use of De Boer plot: This technique was suggested by De Boer et al. to assess when oil begins to form a solid phase, resulting in a reduction in flow rate. As revealed in Fig. 5.3, the De Boer plot shows the pressure differential between the starting pressure and the bubble point pressure against the initial density of the oil sample. There are three distinct zones depicted in this diagram: (1) Region A, which has a high risk of serious flow problems, (2) Region B, which faces moderate issues, and (3) Region C, which confronts minimal or minor flow issues [13]. When researching asphaltene flocculation and deposition in a pipe, the electro kinetic influence must be taken into account. This impact is caused by the electrical potential difference in the conduit caused by the movement of colloidal particles in the oil mixture, which promotes asphaltene deposition and clogging. Some of the parameters that have a considerable impact on this occurrence are the conduit’s characteristics include electrical, thermal, and wettability characteristics, pressure, temperature, flow regime, and oil mixture quality. Broseta et al. used a stainless-steel capillary to test the onset point and rate of asphaltene deposition when pressure, temperature, and composition were varied. This was accomplished by lowering the pressure across the capillary tube, which revealed the creation of a deposition layer. They also altered the standard light transmission mechanism to make it more receptive to fluids with a trace amount of asphaltene in them. Asphaltene deposition happened when the asphaltene was unstable under the process conditions. This procedure was also utilised to see if asphaltene deposition could be reversed [15].

Fig. 5.3 De Boer plot for Bubble Point [14]

5 Machine Learning in Asphaltenes Mitigation

85

Fig. 5.4 Cylindrical Taylor-Couette (TC) cell [14]

Taylor-Couette (TC) cell is a high-pressure cell that can be used in real-world oil fields to manufacture organic deposition including asphaltenes and waxes [14]. The Taylor-Couette (TC) cell is depicted schematically in Fig. 5.4. The middle half of the cell is made up of a spinning spindle that can simulate pipe flow (Fig. 5.4, part b). The cell also has a cooling/heating bath that adjusts the temperature by circulating the coolant around cylinder. Akbarzadeh et al. [16] used the TC cell, but with a few modifications to reduce the cell’s shortcomings. To address the cell’s inability to function with a low level of asphaltene, they used the fresh sample of oil. The most critical component in the deposition rate was found to be the shear rate. There were also more deposits at the reservoir oil’s bubble point pressure.

5.3 Asphaltene Mitigation Procedures 5.3.1 Mechanical Method The mechanical method is to scrape the asphaltene sediment out of the wells mechanically. The most common approach is to use a wire line unit; however, this method is slow and expensive when dealing with a long and tough deposit. Another approach is to utilise a Coiled tubing device and a hydro-blasting equipment to drill the deposit. This device, however, has the disadvantage of limiting operating pressure, making cleaning more difficult. Another method of cleaning is to apply pressure to the deposit in order to create a differential pressure across it [17].

86

A. Qasim and B. Lal

5.3.2 Ultrasonic Treatment Ultrasonic technology can be used to clean asphaltene-clogged portions of oil wells and reservoirs. Ultrasonic vibrations appear to disturb the maltenes that form a continuous phase to provide adhesive and ductile properties to the scattered asphaltenes [13]. Time, power, frequency, and the type of radiation necessary to remove asphaltene deposits all have an impact on the performance of ultrasonic waves. This method was tested on asphaltene clusters and permeability damage in carbonate porous media in reservoir rocks produced by asphaltene deposition. The use of ultrasonic radiation in that crude oil resulted in the disintegration of asphaltene clusters into fine sizes, as well as an improvement in reservoir rock permeability damage [18].

5.3.3 Thermal Treatment There are a variety of thermal methods for treating asphaltene deposition, including hot oiling, which includes injecting a hot oil into the well to remove asphaltene deposits. This method, however, can be harmful to the formation [19]. A down hole heater can be used for a short amount of time to melt asphaltene deposits in the wellbore or on tubing, which can then be pumped up with the created oil. The application of this approach is limited, however, due to the high cost of maintenance and the shortage of electric power. The use of heat-liberating chemicals, which requires pumping down a solution of equimolar ammonium chloride and sodium nitrate, is another thermal approach for eliminating asphaltene deposits. Using a buffer, the exothermic reaction is postponed until the fluid reaches the bottom-hole with a significant amount of nitrogen gas. However, in comparison to the traditional thermal method, this technology is quite expensive [20].

5.3.4 Bacterial Treatment In this treatment, bacteria are used to remediate asphaltene build-up. Almehaideb et al. [21] chose specialised bacteria with a high endurance for the extreme temperature and salinity conditions observed in the reservoir rock they studied in the lab. They exposed damaged cores to microorganisms in their experiment after they lost early oil permeability due to asphaltene accumulation. On average, bacterial stimulation resulted in a 54% improvement in defective core permeability.

5 Machine Learning in Asphaltenes Mitigation

87

5.3.5 Chemical Treatment Chemical treatment with solvents is required when mechanical treatments fail to remove asphaltene deposits. Asphaltene solvents are mostly made up of aromatic solvents. Alternatives to chemical solvents, such as de-asphaltened oils with high aromatics content were also used at low cost; xylene, with a low flash point of 28 °C. Toluene is much more volatile than benzene with a flashpoint of 5 °C, yet it is less effective. However, for a variety of reasons, including corrosion, safety concerns due to their low flash point, and environmental concerns, the use of these hydrocarbon solvents is restricted [5].

5.4 Asphaltene Prediction Models The asphaltene prediction models include the models for the precipitation and deposition. They are based on thermodynamic solubility techniques, colloidal method and deposition modelling. The details of these models are discussed in the following sub-sections.

5.4.1 Thermodynamic Solubility Technique Thomas et al. [22] formulated a regular solution theory for multicomponent systems to characterise the asphaltene precipitation behaviours. They used Prausnitz’s GE = UE equation for a multicomponent solid phase, where GE is the excess Gibbs free energy accounting for the liquid system’s non-ideality and UE is the excess internal energy. To simulate asphaltene precipitation in Western Canadian bitumens, Alboudwarej et al. [23] employed a regular solution theory of the liquid–liquid equilibrium. They investigated the effects of several solvents on precipitation. As the system pressure was above the bubble point, a liquid–liquid equilibrium was hypothesised. They divided bitumens into four basic pseudo-components based on the Saturate, Aromatic, Resin and Asphaltene (SARA) fraction to overcome the categorization challenge of the regular solution theory: saturates, aromatics, resins, and asphaltenes. The distribution of molar mass, molar volume, and solubility characteristics of asphaltene was a major challenge when utilising regular solution theory to simulate asphaltene precipitation. The polydispersity of asphaltene, the difficulty of lumping asphaltenes as a single component, and determining the precise and reliable amount of precipitation were all compelling reasons to use the Schultz-Zimm molar mass distribution to partition asphaltene into variable molar mass fractions. The proposed method was successful in mimicking the commencement of asphaltene precipitation as well as the amount of asphaltene precipitation. At intermediate solvent/bitumen ratios, however, the model underpredicted simulation results.

88

A. Qasim and B. Lal

Afterwards, Akbarzadeh et al. [24] updated the molar mass distribution function of the model employed by Thomas et al. with the gamma function and found the improved performance. According to the association model, asphaltene and resin both have active sites that allow them to bind to similar molecules and cause aggregation. Saturate and aromatic components are also considered neutral. Terminators and propagators are terms used to describe compounds that have one or more active sites. Finally, a combination of terminators and propagators make up asphaltene and resin. Thermal and hydrocracking processes modify the distribution function of molar weight, volume, and solubility, which are key characteristics in asphaltene precipitation, according to the researchers. The Flory–Huggins hypothesis was utilised by Hirschberg et al. [25] to model the amount of asphaltene precipitation. They employed Soave–Redlich–Kwong (SRK) equation of state (EoS) to simulate a vapour-liquid equilibrium thermodynamic condition. The liquid phase was made up of the solvent which was asphaltene-free and asphalt phases which contained asphaltene and resin. The Flory Huggins model had several discrepancies. First, there was an overestimation of asphaltene solubility in the presence of a large volume of solvent. Second, the model was unable to predict the amount of precipitation at pressures greater than 200 bar. Thirdly, asphaltene was thought to be homogenous. Rassamdana et al. [26] investigated the effects of nalkanes on a light oil sample using the Hirschberg model. They found a discrepancy between the model predictions and the experimental data. They argued that the difference originated from the concept of reversible precipitation events. A two-component Asphaltene Solubility Model (ASM) was later proposed based on the Flory–Huggins theory. Unlike previous implementations of the theory, the composition of the phases after asphaltene precipitation was not assumed, and the phases were defined by a link between refractive index and solubility properties. Despite its success in predicting the emergence of asphaltene, the ASM had a number of flaws discussed in literature [27, 28]. Changing the solubility parameter and molar volume, for example, required an optimization technique. Alternative solvents including pentane and pentadecane were also investigated using the same extent of solubility criteria. The Asphaltene Instability Trend (ASIST) was proposed based on the same premise, and the solubility parameters for numerous liquid solvents were plotted against the molar volume. In fact, ASIST found a linear relationship between the solubility parameter and the molar volume at the onset condition. Although some previous studies investigated the method’s usefulness for predicting asphaltene instability and the model was unable to effectively forecast the amount of precipitation [28, 29]. One of the simplest models in asphaltene precipitation is the cubic equation of state (EoS), which combines the solid phase fugacity correlation and the Peng-Robinson (PR) EoS. The asphaltene precipitated phase is assumed to be a pure solid in the model. The model is basic, but it is not exact enough, and it must be updated every time the components are altered [22]. To calculate the fugacity of components in a vapour-liquid equilibrium, Ngheim et al. [30] also used PR EoS. In their model, the heavy fraction of crude oil was divided into two categories: precipitating and non-precipitating. Dissociated asphaltene/resins made up the first percentage, while heavy paraffins and non-dissociable asphaltene/resins made up the latter. Although it

5 Machine Learning in Asphaltenes Mitigation

89

was dependent on the precise partitioning of the heavy fractions and their characteristics, the suggested model was successful in forecasting asphaltene phase separation. Furthermore, in the presence of a large number of solvents, the model failed to account for asphaltene precipitation. Other studies used PR EoS to investigate the asphaltene phase behaviour induced by n-alkanes, even designating thirty divisions to match the molar mass distribution of asphaltene. On the other hand, the effect of resins and aromatics on asphaltene stability has not been applied further [31, 32]. Based on Wertheim’s perturbation theory to the mixture, Chapman and associates developed Statistical Associating Fluid Theory, SAFT, a common model for modelling asphaltene phase behaviour. Perturbed Chain Statistical Associating Fluid Theory, PC-SAFT, appeared to be more suitable for simulating asphaltene behaviour than prior SAFT model variations [33]. Because the SAFT model’s effectiveness is heavily reliant on segment lumping and features, such as binary interaction factors, various methods of lumping in an oil mixture have been reported in the literature. Molecules are separated into a spherical chain of connected parts according to the SAFT theory. The number of segments per chain, segment diameter, and van der Waals energy of segments are all critical parameters that must be adjusted for saturated liquid densities and vapour pressures. These criteria are related to the molecular weight of a segment. PC-SAFT EoS was used by Gonzalez et al. [11] and Vargas et al. [34] to conduct substantial research on the modelling of asphaltene phase behaviour. They observed the effect of gas injection on the onset of asphaltene precipitation as well as the pressure at which bubbles form. They looked at how gas injections of methane, ethane, CO2 , and N2 affected the formation of asphaltene. To account for the polydispersity of asphaltene, it was split into three to nine subtractions and the SAFT parameters were modified [34]. Asphaltene precipitation was exaggerated in the proposed model since it took into consideration the polydispersity effect. Later, Alhammadi et al. [36] compared the PC-SAFT with the CPA, which contained the Peneloux shift parameter in its physical element, in terms of prediction performance. Although the Peneloux shift parameter was included to the cubic EoSs (SRK, PR, and the physical half of CPA), the PC-SAFT fared better in thermodynamic property modelling at equilibrium. To model the onset of asphaltene precipitation and bubble point pressure with and without gas injection, Arya et al. used PCSAFT EoS with the association contribution. They compared PC-SAFT with the association (WA) to PC-SAFT EoS without the association (WOA) and CPA EoS outcomes. They used the models to examine six reservoir fluids and found encouraging results, allowing the commencement of asphaltene precipitation to be adequately modelled. However, for two of the fluid samples, the PC-SAFT (WOA) was unable to correlate the higher onset pressure [35] as shown in Fig. 5.5.

90

A. Qasim and B. Lal

Fig. 5.5 Correlation and prediction of Upper Asphaltene Onset (UOP) and Bubble Point (BP) pressures, a without gas injection or GI, b with 5 mol% gas injection, c with 10 mol% gas injection, and d with 15 mol% gas injection [35]

5.4.2 Colloidal Technique Li and Firoozabadi [37] used PR EoS within the CPA framework to model the asphaltene phase behaviour. A physical component based on PR EoS and an association component based on Wertheim’s thermodynamic perturbation theory made up the CPA model. Oil was considered to include three spurious components: saturate, aromatic/resin, and asphaltene. The single variable in the model is the association energy parameter. Furthermore, the model succeeded of modelling precipitation incidence but not so much of forecasting the onset point. This problem can be traced back to a change in the association energy parameter. Shirani et al. [38] used a similar paradigm to study a real oil sample with fifteen pseudo-components, ignoring the

5 Machine Learning in Asphaltenes Mitigation

91

interaction of asphaltene with other components and focusing only on self-association of asphaltene particles. For the physical portion of the model, they looked at both SRK and PR EoSs and discovered that SRK EoS performed better than PR EoS and colloidal models. According to CPA research for modelling asphaltene phase behaviour, the chemical interaction of monomers leads to association due to the increase of new species. Some temperature-dependent variables were assumed to be constant, which is a flaw in the method [37]. The first instance colloidal theory was applied to asphaltene precipitation was by Pfeiffer and Saal [39]. It was claimed that lighter hydrocarbons in the oil combination peptize asphaltene, and a lack of resins to cover the asphaltene heavy particles caused asphaltene precipitation. Asphaltene aggregation and precipitation are caused by the transfer of peptizing agent which is a resin from the asphaltene phase to the oil phase and vice versa. The outer layer stabilises the asphaltene due to steric repulsion. As a result, adding a solvent (n-alkane) causes peptizing agents in the outer layer to transition to the oil phase, increasing the polarity of the asphaltene phase while decreasing the polarity of the oil phase, increasing the polarity of the asphaltene phase while decreasing the polarity of the oil phase. The polarity of the asphaltene phase reaches a point where the asphaltene micelles become linked and grow in size at first. One of the earliest applications of the colloidal approach to model asphaltene precipitation was by Leontaritis and Mansoori [40]. The particles of asphaltene were seen as a solid phase surrounded by resins. When an n-alkane solvent was applied to the oil, asphaltene precipitated. The precipitation condition was modelled using a Vapour-Liquid Equilibrium (VLE) calculation method. The critical resin concentration was changed based on the experimental findings. The model, however, is only valid when asphaltene precipitation is reversible i.e. asphaltene dissociation occurs. Other researchers [41, 42] used the colloidal structure and tweaked it slightly. For example, Pan and Firoozabadi [42] investigated two phases: a precipitated phase (asphaltene and resin) and a liquid phase. The thermodynamic parameters of the species were calculated using EoS, and phase compositions were determined by minimising the Gibbs free energy. The model has several problems, including the requirement for a large number of parameters and the absence of a clear relationship between the parameters and thermodynamic conditions such as pressure, temperature, and composition.

5.4.3 Asphaltene Deposition Modelling Asphaltene precipitation at a certain pressure and temperature facilitates flow assurance induced problems formation in the reservoir. When the solid phase evolves in the porous structure, the permeability of the rocks diminishes, lowering inflow performance. The models in the literature, as shown in Fig. 5.6, tend to assume the following

92

A. Qasim and B. Lal

Fig. 5.6 Asphaltene-deposition-induced rock impairment mechanisms [6]

mechanisms: (1) adsorption of asphaltene nano-aggregates in the reservoir’s capillary pores, forming a deposited layer that partially restricts flow, (2) clogging of pore throats by larger aggregates caused by particle deposition, and (3) shear removal of asphaltene particles, increasing the permeability of the rock. The flow impairment caused by asphaltene-induced formation damage was detected by researchers using several advanced mathematical models that accounted for the diffusivity of distinct phases in porous environments. The suspension of asphaltene nano-aggregates in liquid is considered in most of these models (oil phase). Gruesbeck and Collins [43] were the first to model the deposition of fines, up to 5 m, in porous media, indicating major changes in the permeability of the formation rock and accounting for the reduction in productivity. The diffusivity model was constructed by Wang and Civan [44], who used an empirical correlation to account for the deposition of asphaltene. The liquid influx terms were computed using the Darcy law, whereas the adsorption and clogging mechanisms in the deposition were described using empirical components. The overall mass balance of the asphaltene phase is represented by Eq. 5.1, and the correlation utilised to calculate deposition via adsorption, deposition removal as a result of drag force, and pore clogging is represented by Eq. 5.2. ∂wa L ∂ (ϕρa Cnp + ϕρ L wa L μ f ) = ρa ∂t ∂t ρa

∂wa L = αϕCnp − βwa L (μ L − μ L ,crit ) + ς Cnp μ f ∂t

(5.1) (5.2)

where ϕ is the porosity, ρ a is the density of asphaltene, C np is the concentration of nanoparticles, ρ L is the density of the liquid phase, waL is the mass fraction of dissolved asphaltene in the liquid phase, uf is the mean fluid velocity represented by the Darcy law, uL is the interstitial velocity of the liquid phase, uL,crit is the critical

5 Machine Learning in Asphaltenes Mitigation

93

interstitial velocity of the liquid phase, α is the empirical constant for deposition, β is empirical constant indicating removal of the deposit, and ζ is the empirical constant accounting for plug clogging. The constants were not dependent on particle size and obtained experimentally by core flooding. For the four phases of gas, oil, water, and asphaltene, Preceding researches undertook comprehensive reservoir simulations in cylindrical coordinates, accounting for reservoir damage induced by asphaltene deposition [45, 46]. The black oil model was used to estimate the fluid’s properties. Soulgani et al. [47] proposed a new adsorption model based on the Arrhenius kinetic equation that avoided Brownian particle diffusion along the pores’ walls. The rate of deposition and the mean velocity of fluids through the pores was found to be inversely dependent. Kord et al. [48] revised the plugging and adsorption terms in the Wang and Civan model using Arrhenius rate equations. The model outperformed the previous models when compared to flow loop studies. Behbahani et al. [49] coupled the asphaltene precipitation from equilibrium thermodynamics and the convection diffusion equations with Wang and Civan’s rock impairment model to study multilayer adsorption of asphaltene in the pores. The deposition process, on the other hand, was limited by thermodynamic restrictions, resulting in a minor contribution to the overall mass balance. Ramirez et al. [50], proposed one of the earliest asphaltene deposition model in flowlines. They stated molecular diffusion as the primary process for asphaltenes to accumulate on pipe walls. Similar to wax deposition, the asphaltene molecules moved toward the pipe walls as a result of the thermal difference between the bulk fluid temperature and the pipe walls. According to the model, the molecules diffused in the dissolved state and precipitated on the pipe wall, which is at a lower temperature than the bulk fluid. Near the wall, however, oil components diffuse into the main stream, causing asphaltene and oil molecules to diffuse in the reverse way. In addition to the mechanism, shear forces were expected to remove a portion of the deposit in the model. Mirzayi et al. [51] investigated at other mechanisms such gravity settling, thermophoresis, buoyancy, Brownian diffusion, drag force, and shear removal. Particle movement in both laminar and turbulent flows can be studied using these forces. Shirdel et al. [52] evaluated the deposition rate of asphaltene particles using typical particulate deposition principles in various flow regimes. Friedlander and Johnstone98 presented classical models of particle flow in turbulent conditions with eddy diffusion, which were compiled in this study. In addition, as recommended by Cleaver and Yates [53], a stochastic approach to determining the deposition was used. As seen in Eq. 5.3, the flow regime was determined on the basis of particle relaxation time. The model performances were compared to experimental data from the literature on iron particles, air flow, and oil-asphaltene flow, 29 and it was concluded that the models proposed by previous researchers were consistent with experimental data and could be used for asphaltene deposition as well. The Beal model was found to be the best among all.

94

A. Qasim and B. Lal

τ p+ =

ρ p d 2p 18μ f

.

f 2 u 2 avg

γ

(5.3)

Guan et al. [4] developed a one-dimensional transient model to account for crosssectional variance in asphaltene deposition along pipelines and predict deposition above the bubble point temperature. The EoS model was used to calculate the asphaltene equilibrium concentration i.e. solubility of asphaltene at a particular temperature and pressure while numerically solving the heat, mass, and momentum transport equations. The precipitation and aggregation mechanisms were assumed to be first-order kinetics while solving the concentration profile.

5.5 Machine Learning Application in Asphaltenes Precipitation and Deposition Control The effect of several variables and parameters on asphaltene precipitation was investigated using a Bayesian belief network (BBN) as an artificial intelligence modelling method. The parameters included pressure, diluents used and dilution ratio. The BBN model’s projected findings were compared to experimental precipitation data taken in a high-pressure cell and analysed using image analysis tools. The cell accessories make in-situ visual monitoring of asphaltene centres growth at high pressures and temperatures possible. The relative absolute discrepancy between model predictions and experimental data was found to be less than 4.6% on average. Under varied conditions, the established BBN model was also able to anticipate the start of asphaltene precipitation or the burst of nucleation. According to a comparison of their predictions, the BBN model anticipates asphaltene precipitation more accurately and covers a wider range of affected variables/parameters than the alternatives [54]. Figure 5.7 shows the structure of BBN model for asphaltene precipitation. Sarapardeh et al. [55] offered a reliable and predictive model for predicting asphaltene precipitation, particularly the least-squares support vector machine (LSSVM). This model was created and evaluated using 157 separate sets of experimental data for Fig. 5.7 Structure of the developed BBN for asphaltene precipitation [54]

5 Machine Learning in Asphaltenes Mitigation

95

32 different crude oils from a variety of Iranian oil reserves. Because the data ranges utilised to construct the model encompass many of Iran’s PVT data, the resulting model might be trusted to anticipate samples from additional Iranian oil reservoirs. The model’s adequacy and accuracy were determined by statistical and graphical error analysis. The findings showed that the developed model was capable of making accurate predictions based on experimental data. Furthermore, the suggested method accomplished of reproducing the real physical trend of asphaltene precipitation as a function of pressure variation. Finally, utilising the statistical Hat matrix, Williams plot, and residuals of the model results, the Leverage technique was applied to identify the likely outliers. All the experimental data, except for five instances, appeared to be reliable. As a result, given its applicability range, it was concluded that the developed model could be useful in forecasting asphaltene precipitation. This model may be used in any reservoir simulator software and provides adequate accuracy and performance when compared to existing techniques. Rostami et al. [56] employed Gaussian Process (GP) regression models to anticipate asphaltene precipitation in tank and live crude oils. To begin, feature selection was utilised to discover which parts of the training data set were most relevant for predicting asphaltene precipitation. Consequently, six feature sets were generated, each of which was utilised to develop a Gaussian process model for predicting asphaltene precipitation. The results of the models developed in this study were then compared to those of previously published publications. According to the results, their models outperformed the preceding studies from the literature. Na’imi et al. [57] used Support vector regression, a unique computer learning approach, was used to estimate the amount of asphaltene precipitation using experimental titration data. The results of the support vector regression model were compared to those of the artificial neural network and the scaling equation. The results indicated satisfactory agreement with experimental data and accurate prediction when compared to artificial neural networks and scaling equations. Sarapardeh et al. [58] predicted the amount of asphaltene precipitation during titration testing as a function of easily measured parameters such as temperature, solvent type, and solvent to oil dilution ratio. Asphaltene precipitation data was obtained from a variety of sources, and it covered a wide range of thermodynamic conditions and crude oil types. A least square support vector machine (LSSVM) was utilised for modelling, and it was modified using a stochastic process known as couples simulated annealing (CSA). The data bank was divided into four groups based on the kind of solvent and the solvent to oil dilution ratio. Then, for each area, a model was proposed, and the results showed that all of the proposed models can accurately calculate the amount of asphaltene precipitation. In summary, the proposed CSA-LSSVM models predicted asphaltene precipitation with an average absolute relative error of 9.46%. The suggested CSA-LSSVM models beat previously published models in both graphical and statistical assessments. Finally, a mathematical model was used to identify not only the suggested models’ application area, but also the quality of the experimental data and the presence of possible outliers. Only 3.3% of the data indicated possible outliers, indicating that all of the proposed models are statistically valid.

96

A. Qasim and B. Lal

Ghorbani et al. [59] used a machine learning technique to predict asphaltene precipitation under various conditions. The genetic algorithm-support vector regression (GA-SVR) was employed in this research as a new model for predicting the amount of asphaltene precipitation. To improve the SVR’s generalisation performance, GA was utilised to find the best optimal values of SVR parameters and kernel parameter at the same time. On the experimental data sets published in the literature, the GA-SVR model was trained and tested. Statistical error measurements and graphical analysis were used to compare the GASVR model’s performance against that of two scaling equation models. The findings revealed that the suggested model’s prediction performance was very dependable. Wang et al. [60] used coarse-grained molecular dynamics simulations for an archetypal asphaltene molecule. The phase diagram that mapped self-assembled morphologies as a function of temperature, pressure, and the n-heptane-toluene solvent ratio was developed. It was suggested that this information could be utilised to manage asphaltene aggregation by changing the external processing conditions. The low-dimensional free energy surfaces governing asphaltene self-assembly were discovered using simulations, graph matching, and nonlinear manifold learning. Researchers proposed the first use of many-body diffusion maps to reconstruct a pseudo-1D free energy landscape for molecular self-assembly, as well as a diffusion map version that was better suited to data sets with high local density changes. Increasing pressure had a minor impact on the terrain, destabilising the larger aggregates. Small cluster sizes and loose bonding configurations were stabilised by increasing temperature and toluene solvent fraction. The effects of these two were remarkably similar, even though the underlying molecular mechanisms were different. Ristanto [61] used historical bottom hole pressure and flow rate data to develop a reservoir model using machine learning methodologies without explicitly programming the mechanics of the flow. It was influenced by studying the past pattern of bottom hole pressure and flow rate or training set. Flow rate could be forecasted depending on bottom hole pressure using the adopted model. This model could also be used to aid in the diagnosing process. The actual pressure and flow rate response differed from what the model predicted if liquid loading, condensate banking, or wax/asphaltene deposition begin, indicating that the reservoir performance had changed. Previous studies applied machine learning approaches to single-phase cases and framed the problem as a linear problem with the nonlinearity highlighted in the characteristics, but this study employed machine learning and deep learning to solve multi-well and multiphase problems. The research revealed key characteristics of such situations as this study looked at the performance of ten different machine and deep learning algorithms. Python was found to be good for this since it had a wide variety of machine/deep learning libraries to choose from and is better suited to machine learning problems. Multiphase flow, reservoir heterogeneity, and data noise were all considered. Elkhatib et al. [62] designed the experiments by flowing asphaltene-in-toluene solutions through capillary polyetheretherketone tubes and measured their crosssectional areas with high-resolution scanning electron microscopy. Denoising, which

5 Machine Learning in Asphaltenes Mitigation

97

is an analysing local and global bias and variance and binarization using machinelearning techniques were utilised in a two-step digital image analysis to improve picture segmentation quality. Polydispersity divided particles on the tube surface into nanoaggregates (1.54 nm), small clusters (SCs, 410 nm), medium clusters (MCs, 1020 nm), large clusters (LCs, 20,100 nm), and extra-large clusters (XLCs, > 100 nm). A Langmuir adsorption isotherm was determined in toluene, with an adsorption free energy of 29 kJ/mol, which corresponded with previous observations. Nanoaggregates and SCs were the predominant elements of the adsorption layer due to their high mass diffusivity. As the concentration of asphaltene in toluene increased, a conflict between aggregation and adsorption was observed. Due to better self-assembly in the bulk phase, the number of adsorbed particles had been progressively decreasing. Adding n-heptane to toluene at various volume ratios induced the deposition of MCs, with a peak in particle size, number, and mass density around the start of precipitation. These clusters were possible fouling precursors because they act as building blocks of larger particles that amass on the surface over time. Limiting their deposition could be accomplished by increasing the flow rate or introducing chemical inhibitors that favour the formation of larger aggregates in the bulk phase under specific flow conditions. The findings of this study demonstrated that MC-rich petroleum fluids are more susceptible to flow assurance issues, and that effective flow enhancers enhance the aggregation of MCs into particles that are too large to deposit. Gesho et al. [62] developed a fully automated image processing and analysis method using data analytics, pattern recognition, and machine learning including deep learning techniques to automate image processing and investigate physical properties and nanoscale deposition of petroleum constituents, asphaltenes, on surfaces from hundreds of images. In order to accomplish this, many data preparation procedures such as picture filtering and quality assessment methodologies were originally devised. The retrieved information was then used to identify and quantify required physical attributes and deposition parameters using denosing and picture segmentation techniques. By comparing the model to experimental results from asphaltene deposition studies, they were able to validate the proposed technique. The model’s output was then compared against experimental data published in the literature. This application revealed the mechanism of asphaltene deposition, allowing for a better understanding of the process. The construction of fully automated image-processing model that characterises physical properties of deposited species is novel. Using a combination of data and descriptive models, researchers were also able to differentiate foreground and background information particles from SEM images, indicating that the model might be used in future image processing applications. The workflow, executed processes, and applied methods are shown in the four columns in Fig. 5.8. Ali et al. [63] employed machine learning methods to develop a realistic predictive model for asphaltene adsorption on MgO nanoparticles. Three machine learning (ML) methods were used to create the models: gradient boosting machine (GBM), bagging (BG), and random forest (RF). The models were created utilising 36 data points, four of which were nanoparticle surface area, nanoparticle dosage, experimental temperature, and asphaltene equilibrium concentration in the supernatant toluene. Correlation analysis was carried out using a heat map. When the surface area

98

A. Qasim and B. Lal

Fig. 5.8 Diagram of the Image Processing and Analysis Model. Yellow, Green, and Orange refer to deep learning, machine learning, and statistical analysis, respectively [62]

of the nanoparticles was increased, the adsorption of asphaltene on MgO nanoparticles is greatly enhanced, but when the nanoparticle dose was increased, the adsorption of asphaltene on MgO nanoparticles lowered significantly. Temperature and equilibrium concentration have no effect on the adsorption phenomenon. A new experimental dataset during the development process was used to validate the models.

5.5.1 Case Study The case study involves the data analysis from over 100 wells impacted by asphaltenes of onshore fields in Abu Dhabi by Abu Dhabi National Oil Company [64]. In order to detect the asphaltene problem earlier, an asphaltene-specific realtime sensor is required as clean-up operations and reactive maintenance rely on accessibility inspection and may affect the normal operation of the pipeline. In this study, the chosen sensor design was based on the concept of Electron Paramagnetic Resonance (EPR), in which free-radicals in asphaltene resonate with an external magnetic field. The EPR signal is proportional to the amount of asphaltene in the crude, with a signal reduction indicating probable deposition upstream of the sensor. From conception through commercialization, the study was based on the research collaboration between a national oil firm, a university, and a start-up technology supplier. The outcome is a first-of-its-kind industrial Internet of Things (IoT) realtime monitoring device that can detect asphaltene deposition and optimise chemical

5 Machine Learning in Asphaltenes Mitigation

99

programmes by combining surface data into an integrated flow assurance management system. By focusing on the asphaltene free-radical reaction rather than looking for a broad spectrum of chemicals, it was possible to miniaturise and ruggedize a device for oilfield applications. It was still required to show that the adjustment had not resulted in a reduction in resolution. Instead of having the device installed directly into one well for the first field trial in these onshore fields, the system was tested offline so that daily analysis from 15 distinct wells could be done and device resolution could be tested. The resolution was found to be superior than 0.1%. Furthermore, some wells showed nearly 5% variance from one day to the next, while others only showed 1% variation. The wells with the highest standard deviation have previously experienced greater asphaltene issues. The results from these 15 wells exceeded expectations, therefore a second field trial was launched, this time with the device mounted inline at the wellhead for real-time continuous monitoring. The use of this method is expected to aid in the planning of clean-up operations before a well is completely sealed. This should result in significant cost savings as well as reduced well downtime and output loss. A sensor was developed to notice the unusual response signature to asphaltene. Whether the asphaltene is in solution or not, peak-to-peak voltage, Vpp , is proportional to the amount of asphaltene in the crude, according to the laboratory experiments. The signal width, defined as the horizontal distance between two peaks, could be calculated using automated field matching of this theoretical curve, providing a reliable method of peak-to-peak voltage analysis. Although two crude samples in Figs. 5.9 and 5.10 show a correlation with particle size, only preliminary testing has been done to assess the efficiency of this computation. The first sample has a peak-to-peak voltage of 2518 mV (about 9.5% asphaltene) and a width of 0.85 (in normalized units), while the second has a peak-to-peak voltage of 1563 mV (roughly 5.6% asphaltene) and a width of 1.01. Because this is based on laboratory data, one of the pilot phase’s unknowns will be if we can detect spectral breadth variations and whether they can be linked to field activity or distinct reservoir zones. Significant ruggedization of the sensor was performed to prepare it for the onshore use in Abu Dhabi. The cloud-based approach was used and reviewed by researchers

Fig. 5.9 High-resolution microscope analysis of small asphaltene particles suspended in the oil (and some water droplets) and a narrow EPR spectral curve [64]

100

A. Qasim and B. Lal

Fig. 5.10 High-resolution microscope analysis of large asphaltene particles suspended in the oil and a broader spectral EPR curve [64]

in MicroSilicon Head Quarter. Cloud systems enabled data access for each hour with guaranteed backup and storage. It was further proposed that data validation should be done by the operator by conducting frequent well testing, gauge cutter runs and asphaltene content measurement through SARA analysis to corroborate the readings from the sensor. The industrial IoT real-time monitoring device is novel in flow assurance industry.

5.6 Conclusion Asphaltenes are complex molecules with the largest molecular weight known in crude oils, are far more hazardous than typical wax deposition. These are essentially polar molecules. In terms of chemical composition, asphaltenes are made up of heteroatoms such as carbon, nitrogen, hydrogen, sulphide, and oxygen. The point at which asphaltenes begin to separate from oil is known as the commencement of asphaltene precipitation which eventually results in their deposition. Once asphaltenes deposit inside the surface of the pipeline they cause hindrance to normal flow operation. Mechanical, ultrasonic, thermal, bacterial and chemical treatments are the main techniques used by flow assurance industry to mitigate asphaltenes deposition. Various asphaltenes prediction models have been reported in the literature to predict the onset of asphaltenes precipitation and deposition. In this regard, thermodynamic solubility technique, colloidal based models and asphaltene deposition modelling have been developed and discussed by the preceding researches. Currently researchers are focussing on machine learning techniques to predict the onset of asphaltenes precipitation and deposition at laboratory and industrial scale. The machine and deep learning methods included Bayesian belief network (BBN), Least-squares support vector machine (LSSVM), Support vector regression and Genetic algorithm-support vector regression (GA-SVR). It was concluded that the machine learning and deep learning methods were useful in predicting the temperature and pressure conditions of asphaltenes precipitation onset as the predictions

5 Machine Learning in Asphaltenes Mitigation

101

were accurate. In future the use of machine learning techniques can be advanced further with high accuracy in the field of asphaltenes mitigation.

References 1. Ghamartale A, Afzali S, Rezaei N, Zendehboudi S (2021) Asphaltene deposition control by chemical inhibitors : theoretical and practical prospects. Gulf Publishing Company, Austin 2. Lal B, Qasim A, Mohammad Sharif A (2021) Application of ionic liquids in wax, scale and Asphaltene deposition control. In: Ionic Liquids in Flow Assurance. Springer, Cham, pp 49–63 3. Kokal SL, Sayegh SG (1995) Asphaltenes: the cholesterol of petroleum. In: Proceedings of middle east oil show, vol 1, pp 169–181 4. Guan Q, Goharzadeh A, Chai JC, Vargas FM, Biswal SL, Chapman WG, Zhang M, Yap YF (2018) An integrated model for asphaltene deposition in wellbores/pipelines above bubble pressures. J Pet Sci Eng 169:353–373 5. Theyab MA (2018) Fluid flow assurance issues: literature review. Sci Fed J Pet 2:1–11 6. Al-Hosani A, Ravichandran S, Daraboina N (2021) Review of asphaltene deposition modeling in oil and gas production. Energy Fuels 35:965–986 7. Fan HF, Li ZB, Liang T (2007) Experimental study on using ionic liquids to upgrade heavy oil. Ranliao Huaxue Xuebao. J Fuel Chem Technol 35:32–35 8. Speight JG (1998) Asphaltenes and the structure of petroleum. Oil Gas Sci Technol 59:467–477 9. Ogunlaja AS, Hosten E, Tshentu ZR (2014) Dispersion of asphaltenes in petroleum with ionic liquids: evaluation of molecular interactions in the binary mixture. Ind Eng Chem Res 53:18390–18401 10. Bera A, Agarwal J, Shah M, Shah S, Vij RK (2020) Recent advances in ionic liquids as alternative to surfactants/chemicals for application in upstream oil industry. J Ind Eng Chem 82:17–30 11. Buenrostro-Gonzalez E, Lira-Galeana C, Gil-Villegas A, Wu J (2004) Asphaltene precipitation in crude oils: theory and experiments. AIChE J 50:2552–2570 12. Abutaqiya MIL, Sisco CJ, Wang J, Vargas FM (2019) Systematic investigation of asphaltene deposition in the wellbore and near-wellbore region of a deepwater oil reservoir under gas injection. Part 1: thermodynamic modeling of the phase behavior of polydisperse asphaltenes. Energy Fuels 33:3632–3644 13. de Boer RB, Leerlooyer K, Eigner MRP, van Bergen ARD (1995) Screening of crude oils for asphalt precipitation: theory, practice, and the selection of inhibitors. SPE Prod Facil 10:55–61 14. Alimohammadi S, Zendehboudi S, James L (2019) A comprehensive review of asphaltene deposition in petroleum reservoirs: theory, challenges, and tips. Fuel 252:753–791 15. Broseta D, Robin M, Savvidis T, Fejean C, Durandeau M, Zhou H (2000) Detection of Asphaltene deposition by capillary flow measurements. https://doi.org/10.2118/59294-ms 16. Akbarzadeh K, Eskin D, Ratulowski J, Taylor S (2011) Asphaltene deposition measurement and modeling for flow assurance of subsea tubings and pipelines. Proc Annu Offshore Technol Conf 1:256–264 17. Gharbi K, Benyounes K, Khodja M (2017) Removal and prevention of asphaltene deposition during oil production: a literature review. J Pet Sci Eng 158:351–360 18. Taheri-Shakib J, Shekarifard A, Naderi H (2018) Analysis of the asphaltene properties of heavy crude oil under ultrasonic and microwave irradiation. J Anal Appl Pyrolysis 129:171–180 19. Turosung SN, Ghosh B (2017) Application of ionic liquids in the upstream oil industry-a review. Int J Petrochem Res 1:50–60 20. Zekri AY, Shedid SA, Alkashef H (2003) User of laser technology for the treatment of asphaltene deposition in carbonate formations. Pet Sci Technol 21:1409–1426 21. Almehaideb RA, Zekri AY, Arab U (2001) Possible use of bacteria-steam to treat asphaltene deposition in carbonate rocks. In: SPE Europen form damage conference

102

A. Qasim and B. Lal

22. Thomas FB, Bennion DWDB, Bennion DWDB, Hunter BE (1992) Experimental and theoretical studies of solids precipitation from reservoir fluid. J Can Pet Technol. https://doi.org/10. 2118/92-01-02 23. Alboudwarej H, Akbarzadeh K, Beck J, Svrcek WY, Yarranton HW (2003) Regular solution model for asphaltene precipitation from bitumens and solvents. AIChE J 49:2948–2956 24. Akbarzadeh K, Alboudwarej H, Svrcek WY, Yarranton HW (2005) A generalized regular solution model for asphaltene precipitation from n-alkane diluted heavy oils and bitumens. Fluid Phase Equilib 232:159–170 25. Hirschberg A, deJong LNJ, Schipper BA, Meijer JG (1984) Influence of temperature and pressure on asphaltene flocculation. Soc Pet Eng J 24:283–293 26. Rassamdana H, Dabir B, Nematy M, Farhani M, Sahimi M (1996) Asphalt flocculation and deposition: I. The Onset of precipitation. AIChE J 42:10–22 27. Creek JL, Wang J, Buckley JS (2009) Verification of asphaltene-Instability-trend (asist) predictions for low-molecular-weight alkanes. SPE Prod Oper 24:360–367 28. Wang JX, Buckley JS (2001) An experimental approach to prediction of asphaltene flocculation. In: Proceeding of SPE international symposium oilfield chemistry, pp 179–187 29. Buckley JS, Wang J, Creek JL (2007) Solubility of the least-soluble asphaltenes. Asph Heavy Oils, Pet 401–437 30. Nghiem LX, Coombe DA (1997) Modeling asphaltene precipitation during primary depletion. SPE J 2:170–176 31. Vafaie-Sefti M, Mousavi-Dehghani SA, Mohammad-Zadeh M (2003) A simple model for asphaltene deposition in petroleum mixtures. Fluid Phase Equilib 206:1–11 32. Sabbagh O, Akbarzadeh K, Badamchi-Zadeh A, Svrcek WY, Yarranton HW (2006) Applying the PR-EoS to asphaltene precipitation from n-alkane diluted heavy oils and bitumens. Energy Fuels 20:625–634 33. Chapman WG, Keith Gubbins TJJE, Jackson G, Radosd M (1990) Emulsion polymerization in continuous reactors. In: Emulsion polymerization; Piirma, I. Science and technology of polymer colloids, vol 29, pp 51–59 34. Vargas FM, Gonzalez DL, Hirasaki GJ, Chapman WG (2009) Modeling asphaltene phase behavior in crude oil systems using the perturbed chain form of the statistical associating fluid theory (PC-SAFT) equation of state. Energy Fuels 23:1140–1146 35. Arya A, Liang X, Von Solms N, Kontogeorgis GM (2016) Modeling of asphaltene onset precipitation conditions with cubic plus association (CPA) and perturbed chain statistical associating fluid theory (PC-SAFT) equations of state. Energy Fuels 30:6835–6852 36. Alhammadi AA, Vargas FM, Chapman WG (2015) Comparison of cubic-plus-association and perturbed-chain statistical associating fluid theory methods for modeling asphaltene phase behavior and pressure-volume-temperature properties. Energy Fuels 29:2864–2875 37. Li Z, Firoozabadi A (2010) Modeling asphaltene precipitation by n-alkanes from heavy oils and bitumens using cubic-plus-association equation of state. Energy Fuels 24:1106–1113 38. Shirani B, Nikazar M, Naseri A, Mousavi-Dehghani SA (2012) Modeling of asphaltene precipitation utilizing association equation of state. Fuel 93:59–66 39. Pfeiffer JP, Saal RNJ (1940) Asphaltic bitumen as colloid system. J Phys Chem 44:139–149 40. Leontaritis KJ, Mansoori GA (1987) Asphaltene flocculation during oil production and processing: a thermodynamic colloidal model. Soc Pet Eng AIME, SPE 149–158 41. Victorov AI, Firoozabadi A (1996) Thermodynamic micellization model of asphaltene precipitation from petroleum fluids. AIChE J 42:1753–1764 42. Pan H, Firoozabadi A (2000) Thermodynamic micellization model for asphaltene precipitation inhibition. AIChE J 46:416–426 43. Gruesbeck C, Collins RE (1982) Entrainment and deposition of fine particles in porous media. Soc Pet Eng J 22:847–856 44. Wang S, Civan F (2001) Productivity decline of vertical and horizontal wells by asphaltene deposition in petroleum reservoirs. In: Proceedings of SPE international symposium oilfield chemistry, pp 145–160

5 Machine Learning in Asphaltenes Mitigation

103

45. Almehaideb RA (2004) Asphaltene precipitation and deposition in the near wellbore region: a modeling approach. J Pet Sci Eng 42:157–170 46. Solaimany-Nazar AR, Zonnouri A (2011) Modeling of asphaltene deposition in oil reservoirs during primary oil recovery. J Pet Sci Eng 75:251–259 47. Soulgani BS, Tohidi B, Jamialahmadi M, Rashtchian D (2011) Modeling formation damage due to asphaltene deposition in the porous media. Energy Fuels 25:753–761 48. Kord S, Mohammadzadeh O, Miri R, Soulgani BS (2014) Further investigation into the mechanisms of asphaltene deposition and permeability impairment in porous media using a modified analytical model. Fuel 117:259–268 49. Jafari Behbahani T, Ghotbi C, Taghikhani V, Shahrabadi A (2015) Étude Expérimentale Et Modélisation Mathématique Du Mécanisme De Déposition D’Asphaltène Dans Des Carottes De Forage. Oil Gas Sci Technol 70:1051–1074 50. Ramirez-Jaramillo E, Lira-Galeana C, Manero O (2006) Modeling asphaltene deposition in production pipelines. Energy Fuels 20:1184–1196 51. Mirzayi B, Mousavi Dehghani SA, Chakan MB (2013) Modeling of asphaltene deposition in pipelines. J Pet Sci Technol 3:15–23 52. Shirdel M, Paes D, Ribeiro P, Sepehrnoori K (2012) Evaluation and comparison of different models for asphaltene particle deposition in flow streams. J Pet Sci Eng 84–85:57–71 53. Cleaver JW, Yates B (1975) A sub layer model for the deposition of particles from a turbulent flow. Chem Eng Sci 30:983–992 54. Sayyad Amin J, Alamdari A, Mehranbod N, Ayatollahi S, Nikooee E (2010) Prediction of asphaltene precipitation: learning from data at different conditions. Energy Fuels 24:4046–4053 55. Hemmati-Sarapardeh A, Alipour-Yeganeh-Marand R, Naseri A, Safiabadi A, Gharagheizi F, Ilani-Kashkouli P, Mohammadi AH (2013) Asphaltene precipitation due to natural depletion of reservoir: determination using a SARA fraction based intelligent model. Fluid Phase Equilib 354:177–184 56. Rostami H, Khaksar Manshad A (2013) Prediction of asphaltene precipitation in live and tank crude oil using Gaussian process regression. Pet Sci Technol 31:913–922 57. Na’imi SR, Gholami A, Asoodeh M (2014) Prediction of crude oil asphaltene precipitation using support vector regression. J Dispers Sci Technol 35:518–523 58. Hemmati-Sarapardeh A, Ameli F, Dabir B, Ahmadi M, Mohammadi AH (2016) On the evaluation of asphaltene precipitation titration data: Modeling and data assessment. Fluid Phase Equilib 415:88–100 59. Ghorbani M, Zargar G, Jazayeri-Rad H (2016) Prediction of asphaltene precipitation using support vector regression tuned with genetic algorithms. Petroleum 2:301–306 60. Wang J, Gayatri MA, Ferguson AL (2017) Mesoscale simulation and machine learning of asphaltene aggregation phase behavior and molecular assembly landscapes. J Phys Chem B 121:4923–4944 61. Ristanto T (2018) Machine learning applied to multiphase production problems, pp 1–71 62. Gesho M, Chaisoontornyotin W, Elkhatib O, Goual L (2020) Auto-segmentation technique for SEM images using machine learning: asphaltene deposition case study. Ultramicroscopy 217:113074 63. Ali SI, Lalji SM, Haneef J, Ahsan U, Khan MA, Yousaf N (2021) Estimation of asphaltene adsorption on MgO nanoparticles using ensemble learning. Chemom Intell Lab Syst 208:104220 64. Abdallah D, Punnapala S, Al Daghar K, Kulbrandstad O, Godoy M, Lovell J, Madem S, Babakhani A (2019) From ideation to commercialization-development of the first real-time monitoring device for asphaltene deposition. In: Society of petroleum engineers-SPE gas oil technology showcase conference 2019, GOTS 2019. https://doi.org/10.2118/198615-ms

Chapter 6

Machine Learning for Scale Deposition in Oil and Gas Industry Sirisha Nallakukkala and Bhajan Lal

Abstract This chapter briefly discusses the type of machine learning methods used for scales precipitation in flow assurance. It also discussed the scale formation predictive models. Keywords Machine learning · Flow assurance · Scales · Predictions

6.1 Introduction In the oil and gas industry, scale precipitation generates a number of issues. Scale precipitation of inorganic salts like (CaCO3 , CaSO4 , BaSO4 , etc.) is a regular occurrence in the oil and gas industry. The sources and causes of this scale formation are diverse. The injection of water might be regarded as the key source of sulfate-scale precipitation resulting due to mixing of water. Scales can also form as a result of changes in the reservoir’s or well tubulars’ thermodynamic conditions. Precipitation can result also due to the changes in temperature, pH, pressure, and partial pressure of carbon dioxide (CO2 )/hydrogen sulphide [1].

6.2 Source of Scaling in Oil and Gas Industry Scaling in the oil and gas sector is mostly caused by the mixing of incompatible fluids. When two fluids interact chemically, they precipitate minerals. For instance, sea water with a high concentration of SO4 –2 and low amounts of Ca2+ , Ba2+ /Sr+2 , and formation waters with very low concentrations of SO4 2− but high concentrations S. Nallakukkala Chemical Engineering Department, Universiti Teknologi PETRONAS, 32610 Bandar Seri Iskandar, Perak Darul Ridzuan, Malaysia B. Lal (B) Research Centre for CO2 Capture (RCCO2C), Universiti Teknologi PETRONAS, 32610 Bandar Seri Iskandar, Perak, Malaysia e-mail: [email protected] © The Author(s), under exclusive license to Springer Nature Switzerland AG 2023 B. Lal et al. (eds.), Machine Learning and Flow Assurance in Oil and Gas Production, https://doi.org/10.1007/978-3-031-24231-1_6

105

106

S. Nallakukkala and B. Lal

of Ca2+ , Ba2+ , and Sr2+ are two examples of incompatible waters. As a result of the mixing of these liquids, CaSO4 , BaSO4 , and/or SrSO4 precipitate. Seawater and field-produced water (disposal water) can be incompatible. Scale deposition occurs when waste water is combined with seawater for re-injection [2]. According to one of the researchers [3] scales resulting from CaCO3 are very usual compared with other kinds of inorganic scales because scaling by CaCO3 is formed either inside the reservoir, within the production tubing, and at the downhole-pump that results in the decrease in efficiency due to plugging. Furthermore, CaCO3 can form scales at the wellhead and in the flow lines [2]. At high temperatures, CaCO3 has a very low solubility constant, making it the most stable scale type at reservoir pressure and temperature [4]. Some of the different forms of scale formations of CaCO3 are calcite, vaterite, and aragonite, and out of which calcite is the most prevalent variety found in the reservoir. Temperature, pH, ion content, such as calcium and bicarbonate, and ionic strength all play a vital role in the development of CaCO3 scale. The conditions that promote the formation of CaCO3 scales include CO2 solubility, pressure and temperature changes, these factors also promote the formation of iron carbonate scales. The release of CO2 will increase the pH of the solution, and thus promote the carbonate scale formation by reducing the scales solubility at higher pH [5].

6.3 Mechanism of Scale Deposition Scale deposition can occur with water due to supersaturation due to changes in pressure and temperature conditions. When two incompatible waters are mixed and supersaturation is attained then scales can deposit [1]. Supersaturation can be caused by several factors namely heating/cooling, evaporation of water, mixing and gas/liquid equilibria. Supersaturation can occur when a salt solution is cooled or when an inverse solubility salt solution is heated. As water evaporates from solution the solution becomes concentrated making the solution saturated or supersaturated. When the saturated solution comes in contact with hot surface it leads to direct deposition of scale on the surface. Sometimes during mixing the solubility limit may exceed when a soluble salt is added to other salt solution containing similar ion or results in a sparingly soluble salt. In such situations when ionic product is greater than the solubility constant supersaturation condition is attained. Due to the change of solubility with temperature, the mixing of saturated or near-saturated solutions may also result in supersaturation conditions. The equilibrium conditions of CO2 gas dissolved from atmospheric air in solution might affect the solubility of ions.

6 Machine Learning for Scale Deposition in Oil and Gas Industry

107

6.3.1 Types of Scales The types of scales frequently found in flow assurance are, sulfates of (Ba, Sr, Ca), oxides/hydroxides of (Fe, Mg), carbonates of (Ca, Mg, Fe), and sulphides (Fe) are the most prevalent scales found in oil and gas productions. The majority of the scales are either acid soluble or water soluble however, some are not soluble in both. A common example of water-soluble scale is sodium chloride. Acid soluble scales include calcium carbonate, iron sulphide, and iron oxide.

6.3.2 Influence of Impurities on Scale Formation Impurities adsorb on the site of the crystals, deposit and tend to interfere with the solid crystalline structures formation which results in decrease in nucleation and growth followed by change in precipitation. Deposits caused with mixed salts and impurities have a lower adhesion, and the net scaling rate is reduced due to partial removal of the deposit by shear force acting on the flow surface [6].

6.3.3 Scale Control Methods The nature and concentration of scaling species present in the raw feed determine the severity of a potential scaling challenge in a process. The following are the three basic techniques to controlling scale formation: • Removal/decrease of Scale-forming species • Water treatment is an efficient way to remove scaling issues for instance acidifying the feed and degassing CO2 generated from carbonates, can help avoid alkaline scale formation. • Chemical treatment is best alternative when conventional mechanical removal methods are ineffective or expensive. This is accomplished by employing acids or chelating agents, which are used to break apart acid-resistant scale by isolating and locking up the scale metallic ions within a closed ring-like structure, by allowing the scale minerals to dissolve by increasing their solubility.

6.4 Effect of Scaling to Equipment Pipelines In the oilfield water injection, equipment surface, wellbores and pipelines are prone to scaling resulting in blockage and also increase the corrosion rate of pipeline and increase the speed of sulphate reducing bacteria. Scaling also reduces the heat transfer

108

S. Nallakukkala and B. Lal

rate of the equipment resulting in shorter span of the equipment. Scaling also results in reducing the surface area of the channel by creating blockage and effecting the permeability of the reservoir.

6.5 Scale Inhibition Placement 6.5.1 Scale Inhibition Placement by the Squeeze Technique The common approach for injecting the inhibitor into the formation is to inject it into the water zone at high pressures followed by a brief shut-in time period. Certain conditions govern which inhibitor should be squeezed: first, the ability of the chemical to inhibit at low/high concentrations; second, the inhibitors ability to be adsorbed by the surface as well as that surface’s ability to hold the fluid; and third, the fluid’s ability to slowly release from the rock to maintain the minimum inhibitor concentration required for several months. The isotherm of desirable inhibitor should rise quickly and then decrease as the inhibitor concentration rises. Sometimes precipitation suggests that calcium salt may precipitate and coat the reservoir rock [7]. As a result, a large number of calcium ions attach to a single scale inhibitor molecule, as shown in the reaction below: INHIBITOR(Scale Inhibition) + Ca2+ ← SI_Ca[the inhibitor complex]

6.5.2 Pumping the Inhibitor with the Stimulation This approach has the advantage of being cost-effective because by using the same equipment both stimulation and inhibition can be performed at the same time. Smith et al. discovered that using too many scale inhibitors can interfere with the corrosion control agent in the HCl acid system [8].

6.5.3 Pumping the Inhibitor with Fracturing Fluid The opportunity to place the inhibitor fluid in the entire fracture is the main advantage to include inhibitor in the fracturing fluid. This method is cost-effective and easy to implement unless it doesn’t disturb the rheology of the fracturing fluid.

6 Machine Learning for Scale Deposition in Oil and Gas Industry

109

6.5.4 Inhibitor Impregnated into Proppant When the fracture is at risk of deterioration due to the scale, this treatment is used. The inhibitor adsorbs in the microscopic crevices of the proppant particles and is slowly released with the produced water.

6.6 Prediction Models Available for Scale Formation Detection During exploration of oil and gas from reservoirs, scaling is caused due to presence of water which affects the oil production [9]. Scaling is very complex issue that results due to changes in production parameters like the phase change, chemical reactions in the electrolyte solution, temperature, pressure, rate of dissolution, evaporation and precipitation adversely affect the scaling [10]. The scaling prediction has been explored extensively since the 1930s. Over the years, newer and more reliable scaling prediction models have been developed. Some of the scaling prediction tools or methods used presently are the. • Saturation index, • Solubility product rule, • Ion association theory. Water composition, temperature, pressure, mass and energy transfer [11] also affect the scaling in a reservoir. A new index was developed [12] to predict the carbonate scaling by saturation index method. Another researcher [13] predicted the carbonate scale using the thermodynamic solubility method and sulphate solubility product. The influence of various parameters like temperature, pressure and formation water composition on scaling are considered but phase change is not considered by these prediction models. As a result, they cannot accurately depict the inorganic salt scaling process in the reservoir. Hence its required to develop a model that takes phase change into consideration under high pressure and high temperature conditions. A multiphase scaling prediction model based on thermodynamics was proposed by Zheng et al. [14] that considers phase change, and reaction of inorganics salts scaling under multiphase equilibrium. The Oddo-Tomson saturation index was a common technique to predict the scaling in an electrolyte solution.

6.6.1 Saturation Index The Langelier Saturation Index (LSI) is an equilibrium model derived from the theoretical idea of saturation that provides indicator of degree of water saturation with respect to calcium carbonate.

110

S. Nallakukkala and B. Lal

Langelier saturation index (LSI) is given as. LSI = pH + TF + CHF + AF – 12.1 (TDS factor). where TF is the temperature factor. CHF is calcium hardness factor. AF is alkalinity factor. and 12.1 is a constant value for 1000 ppm of total dissolved solids (TDS). If the LSI < 0: There is no risk of scaling because the water will dissolve the CaCO3 . If the LSI > 0: Scale can form and result in precipitation of CaCO3 . If LSI ∼ = 0: Borderline scale potential. The index could be affected by changes in water quality, temperature, or evaporation. LSI is purely an equilibrium measure that only considers the thermodynamic driving force for the formation and growth of CaCO3 scales.

6.6.2 Inhibitor Impregnated into Proppant The insoluble electrolyte Am Bn (s) exhibits the following chemical equilibrium in solution at a given temperature and pressure: Am Bn (s) ⇔ m An+ (aq) + n B m− (aq) K sp = [An+ ]m · [B m− ]n where K sp is the thermodynamic solubility product of Am Bn (s) To analyse the scaling in the case of insoluble electrolyte solution the following rules can be utilised to analyse the occurrence of dissolution/precipitation. Rule 1: [An+ ]m · [B m− ]n >K sp : solution is saturated. Rule 2: [An+ ]m · [B m− ]n 1800 data points). In addition, unlike most previous research, we use thermodynamic properties as input features in the prediction algorithms, such as the activity-based contribution due to electrolytes, partial pressure of specific gases, and specific gravity of the total mixture. Random Forest (RF), Extra Trees (ET), and Extreme Gradient Boosting (XGBoost), three machine learning approaches, all showed high accuracy in estimating hydrate equilibrium conditions. For all of the ML models, the cumulative coefficient of determination (R2 ) percentage is greater than 97%. XGBoost surpasses RF and ET in terms of overall coefficient of determination (R2 ) and average absolute relative deviation (AARD), with 99.56% and 0.086%, respectively. Predicting the formation conditions of gas hydrates in salt water is crucial for hydrate management in activities such as flow assurance, deep-sea drilling, and hydrate-based technology development. In this regard, Xu et al. [108] recently employed five machine learning methods to develop prediction tools for calculating the temperature of methane hydrate formation in the presence of salt water in this study. Machine learning methods included Multiple Linear Regression, k-Nearest Neighbor, Support Vector Regression, Random Forest, and Gradient Boosting Regression. A total of 702 experimental data points from the literature were collected for modelling purposes between 1951 and 2020. The literature clearly shows that the use of machine learning techniques in gas hydrate studies is pertinent and different parameters including but not limited to hydrate formation temperature and pressure can successfuly be predicted. In the upcoming section, the case studies related to machine learning application in gas hydrates are presented and discussed.

9 Machine Learning Application in Gas Hydrates

167

9.7 Case Study This work involves the use of the data from the flowloop tests performed across a wide variety of experimental conditions at two pilot-scale flowloop facilities (FL1 and FL2), and field data from a dry tree facility in the Gulf of Mexico [109]. Srivastava et al. [109] determined regression, classification, and feature learning are used to analyse data sets from: (1) hydrate tests conducted at pilot-scale flowloop facilities (4,500 data points) and (2) transient operation field data using an algorithm like support vector machine (SVM) and neural networks (NN). Several independent input variables based on flowloop test data are used to calculate the hydrate fraction and probability of hydrate plugging in the pipeline, including water cut, gas-oil ratio, hydrate particle cohesive force, fluid velocity, oil viscosity, specific gravity, interfacial tension, and time in the hydrate stable zone. Using field data as input, including water cut, shut-down period (where applicable), and gas-oil ratio, the semisupervised learning model was utilised to determine the level of hydrate resistance to flow during restart or dead oil displacement following production shut-down. The flowloop-based machine learning model demonstrated high prediction accuracies in test and validation processes, and it was used to evaluate hydrate risks in a real field. The ability to construct field risk maps was demonstrated by a machine learning model based on field data. The hydrate management technique could be used to estimate the risk of hydrate development in subsea oil/gas pipelines using machine learning. As a companion to more complex transient multiphase flow simulations, this machine learning approach can aid in the development of sophisticated hydrate management strategies. In classification predictive modelling, approximating a mapping function (f) from input variables (X) to a discrete output variable is a data mining task (y). Some of the process variables (features) detected in the flowloop tests in this work are water cut, GOR, surface fluid velocity, oil specific gravity (SG), interfacial tension (IFT), viscosity, hydrate volume fraction (HVF), and hydrate inter-particle cohesive force (Fa). A value between 0 and 1 is assigned as a binary classification output and rounded up to the nearest integer. It designates probability of failure. The value of 0 indicates no plug formation while 1 means complete plug formation. This categorization model is depicted in Fig. 9.3. The machine learning algorithms/frameworks used in the model are the support vector classifier (SVC) and artificial neural networks (ANN). Figure 9.4 compares the HVF predicted by the neural network regression to the HVF recorded during the procedure to highlight the test and validation results. For the 913 test data points, the mean absolute error (MAE) was 0.018, the mean square error (MSE) was 0.0009, and the coefficient of determination (R2) was greater than 0.92. The results of the tests show that neural network regression is good at predicting hydrate formation and improves the applicability of the risk classification model indicated above.

168

A. Qasim and B. Lal

Fig. 9.3 A simple binary classification model that employs flowloop testing to predict the likelihood of hydrate clogging [109]

Fig. 9.4 Comparison of predicted and measured values of Hydrate volume fraction in the pipe using ANN model [109]

9.8 Conclusion Machine learning application in gas hydrate inhibition prediction and analysis is now well-established field of study in recent years as the power of computing has strengthened. In the flow assurance application regarding gas hydrate inhibition, most frequently, machine learning has been used to simulate gas hydrate equilibria, allowing models to be created that are better able to anticipate the highly nonflinear, multimodal phenomena of gas hydrate equilibria than statistical thermodynamics models. Various machine learning models have been published. Temperature, pressure, gas hydrate saturation and fluid composition prediction are all frequent input features for developed models. A regression model determines the equilibrium temperature, pressure or the desired output value. In the literature, both supervised and unsupervised learning methods have been employed for the application. As an instance in a previous study, a deep learning based model was used to predict

9 Machine Learning Application in Gas Hydrates

169

the hydrate equilibrium pressure. The higher R-squared value indicated a good fit. Among the different case studies, it was observed that the prediction accuracy of machine learning is strongly dependent on the amount of data input as large number of data points are suitable for the accurate prediction Apart from hydrate equilibrium temperature or pressure, different machine learning algorithms such as Ridge Regression, Decision Tree, Random Forest, AdaBoost and Neural Network have been employed to predict gas hydrate saturation values for number of well log combinations. In this case the results of neural network algorithm provided higher accuracy. The success of the machine learning model was due to ample availibity of required data points. Hydrate plugging risk can also be predicted through machine learning. In future, the use of machine learning can be enhaced further as the prediction algorithms get better and more reliable. The use of machine learning algorithms in flow loop can provide real time data to help improve the smooth flow of oil in the pipeline at commercial scale.

References 1. Makogon YF (2010) Natural gas hydrates—a promising source of energy. J Nat Gas Sci Eng 2:49–59 2. Sefidroodi H, Cheng Chua P, Kelland MA (2011) THF hydrate crystal growth inhibition with small anionic organic compounds and their synergistic properties with the kinetic hydrate inhibitor poly(N-vinylcaprolactam). Chem Eng Sci 66:2050–2056 3. Khan MS, Lal B, Shariff AM, Mukhtar H (2019) Ammonium hydroxide ILs as dual-functional gas hydrate inhibitors for binary mixed gas (carbon dioxide and methane) hydrates. J Mol Liq 274:33–44 4. Bavoh CB, Partoon B, Lal B, Keong LK (2016) Methane hydrate-liquid-vapour-equilibrium phase condition measurements in the presence of natural amino acids. J Nat Gas Sci Eng 37:425–434 5. Lal B, Nashed O, Chemical additives for gas hydrates 6. Akhfash M, Arjmandi M, Aman ZM, Boxall JA, May EF (2017) Gas hydrate thermodynamic inhibition with MDEA for reduced MEG circulation. J Chem Eng Data 62:2578–2583 7. Sun SC, Liu CL, Meng QG (2015) Hydrate phase equilibrium of binary guest-mixtures containing CO2 and N2 in various systems. J Chem Thermodyn 84:1–6 8. Li X-S, Xu C-G, Zhang Y, Ruan X-K, Li G, Wang Y (2016) Investigation into gas production from natural gas hydrate: a review. Appl Energy 172:286–322 9. Qasim A, Khan MS, Lal B, Shariff AM (2019) Phase equilibrium measurement and modeling approach to quaternary ammonium salts with and without monoethylene glycol for carbon dioxide hydrates. J Mol Liq 282:106–114 10. Qasim A., Lal B., Shariff A.M. IMC (2020) Role of ionic liquid-based multipurpose gas hydrate and corrosion inhibitors in gas transmission pipeline. In: Inamuddin AA (eds) Nanotechnol. Life Sci. Springer, Cham, Ist. Springer, Cham, pp 221–244 11. Mohammadi AH, Anderson R, Tohidi B (2005) Carbon monoxide clathrate hydrates: equilibrium data and thermodynamic modeling. AIChE J 51:2825–2833 12. Qasim A, Khan MS, Lal B, Shariff AM (2019) A perspective on dual purpose gas hydrate and corrosion inhibitors for flow assurance. J Pet Sci Eng 183:106418 13. Lal B, Qasim A, Sharif AM (2021) Ionic Liquids in Flow Assurance, 1st ed. https://doi.org/ 10.1007/978-3-030-63753-8 14. Sloan ED (2005) A changing hydrate paradigm—from apprehension to avoidance to risk management. Fluid Phase Equilib 228–229:67–74

170

A. Qasim and B. Lal

15. Cha M, Shin K, Kim J, Chang D, Seo Y, Lee H, Kang S-P (2013) Thermodynamic and kinetic hydrate inhibition performance of aqueous ethylene glycol solutions for natural gas. Chem Eng Sci 99:184–190 16. Khan MS, Cornelius BB, Lal B, Bustam MA (2018) Kinetic assessment of tetramethyl ammonium hydroxide (Ionic Liquid) for carbon dioxide, methane and binary mix gas hydrates. In: Rahman MM (ed) Recent Adv. Ion. Liq. IntechOpen, London, UK, pp 159–179 17. Khan MS, Partoon B, Bavoh CB, Lal B, Mellon NB (2017) Influence of tetramethylammonium hydroxide on methane and carbon dioxide gas hydrate phase equilibrium conditions. Fluid Phase Equilib 440:1–8 18. Koh CA (2002) Towards a fundamental understanding of natural gas hydrates. Chem Soc Rev 31:157–167 19. Xu C-G, Li X-S (2015) Research progress on methane production from natural gas hydrates. RSC Adv 5:54672–54699 20. Khan MS, Lal B, Bavoh CB, Keong LK, Bustam A (2017) Influence of ammonium based compounds for gas hydrate mitigation: a short review. Indian J Sci Technol 10:1–6 21. Hassan S, Adam F, Abu Bakar MR, Abdul Mudalip SK (2019) Evaluation of solvents’ effect on solubility, intermolecular interaction energies and habit of ascorbic acid crystals. J Saudi Chem Soc 23:239–248 22. Abolala M, Varaminian F (2015) Thermodynamic model for predicting equilibrium conditions of clathrate hydrates of noble gases + light hydrocarbons: combination of Van der WaalsPlatteeuw model and sPC-SAFT EoS. J Chem Thermodyn 81:89–94 23. Hassanpouryouzband A, Joonaki E, Vasheghani Farahani M et al (2020) Gas hydrates in sustainable chemistry. Chem Soc Rev 49:5225–5309 24. Nashed O, Partoon B, Lal B, Sabil KM, Shariff AM (2018) Review the impact of nanoparticles on the thermodynamics and kinetics of gas hydrate formation. J Nat Gas Sci Eng 55:452–465 25. Sum AK, Koh CA, Sloan ED (2009) Clathrate hydrates: from laboratory science to engineering practice. Ind Eng Chem Res 48:7457–7465 26. Jensen L, Thomsen K, Von Solms N (2011) Inhibition of structure I and II gas hydrates using synthetic and biological kinetic inhibitors. Energy Fuels 25:17–23 27. Del Villano L, Kelland MA (2010) An investigation into the kinetic hydrate inhibitor properties of two imidazolium-based ionic liquids on Structure II gas hydrate. Chem Eng Sci 65:5366– 5372 28. Koh CA, Sloan ED, Sum AK, Wu DT (2011) Fundamentals and applications of gas hydrates. Annu Rev Chem Biomol Eng 2:237–257 29. Qasim A, Khan MS, Lal B, Ismail MC, Rostani K (2020) Quaternary ammonium salts as thermodynamic hydrate inhibitors in the presence and absence of monoethylene glycol for methane hydrates. Fuel 259:116219 30. Tariq M, Rooney D, Othman E, Aparicio S, Atilhan M, Khraisheh M (2014) Gas hydrate inhibition : a review of the role of ionic liquids. Ind Eng Chem Res 53:17855–17868 31. Sloan ED, Koh CA, Sum AK (2010) Gas hydrate stability and sampling: the future as related to the phase diagram. Energies 3:1991–2000 32. Wang Y, Feng JC, Sen LX, Zhang Y (2018) Influence of well pattern on gas recovery from methane hydrate reservoir by large scale experimental investigation. Energy 152:34–45 33. Chatti I, Delahaye A, Fournaison L, Petitet JP (2005) Benefits and drawbacks of clathrate hydrates: a review of their areas of interest. Energy Convers Manag 46:1333–1343 34. Demirbas A (2010) Methane hydrates as potential energy resource: part 2—methane production processes from gas hydrates. Energy Convers Manag 51:1562–1571 35. Sain K, Gupta H (2012) Gas hydrates in India: potential and development. Gondwana Res 22:645–657 36. Yin Z, Chong ZR, Tan HK, Linga P (2016) Review of gas hydrate dissociation kinetic models for energy recovery. J Nat Gas Sci Eng 35:1362–1387 37. Qureshi MF, Khraisheh M, AlMomani F (2020) Experimentally measured methane hydrate phase equilibria and ionic liquids inhibition performance in Qatar’s seawater. Sci Rep 10:1–14

9 Machine Learning Application in Gas Hydrates

171

38. Babaee S, Hashemi H, Mohammadi AH, Naidoo P, Ramjugernath D (2015) Kinetic and thermodynamic behaviour of CF4 clathrate hydrates. J Chem Thermodyn 81:52–59 39. Bahadori A, Vuthaluru HB (2009) A novel correlation for estimation of hydrate forming condition of natural gases. J Nat Gas Chem 18:453–457 40. Haghighi H, Chapoy A, Burgess R, Tohidi B (2009) Experimental and thermodynamic modelling of systems containing water and ethylene glycol: application to flow assurance and gas processing. Fluid Phase Equilib 276:24–30 41. Obanijesu EO, Gubner R, Barifcani A, Pareek V, Tade MO (2014) The influence of corrosion inhibitors on hydrate formation temperature along the subsea natural gas pipelines. J Pet Sci Eng 120:239–252 42. Karamoddin M, Varaminian F (2013) Water desalination using R141b gas hydrate formation. Desalin Water Treat 52:2450–2456 43. Cha JH, Seol Y (2013) Increasing gas hydrate formation temperature for desalination of high salinity produced water with secondary guests. ACS Sustain Chem Eng 1:1218–1224 44. Panwar NL, Kaushik SC, Kothari S (2011) Role of renewable energy sources in environmental protection: a review. Renew Sustain Energy Rev 15:1513–1524 45. Linga P, Kumar R, Lee JD, Ripmeester J, Englezos P (2010) A new apparatus to enhance the rate of gas hydrate formation: application to capture of carbon dioxide. Int J Greenh Gas Control 4:630–637 46. Yaqub S, lal B, Kok Keong L (2019) Thermodynamic and kinetic effect of biodegradable polymers on carbondioxide hydrates. J Ind Eng Chem 79:131–145 47. Yaqub S, Lal B, Partoon B, Mellon NB (2018) Investigation of the task oriented dual function inhibitors in gas hydrate inhibition: a review. Fluid Phase Equilib 477:40–57 48. Bavoh CB, Lal B, Nashed O, Khan MS, Keong LK, Bustam MA (2016) COSMO-RS: an ionic liquid prescreening tool for gas hydrate mitigation. Chinese J Chem Eng 11:1619–1624 49. Khan MS, Mellon NB, Lal B (2016) Prelimnary Experimental evaluation for Methane (CH4) and Carbon dioxide (CO2 ) Gas hydrate mitigation. Procedia Eng 148:932–940 50. Bavoh C ius B, Lal B, Khan MS, Osei H, Ayuob M (2018) Inhibition effect of 1-ethyl-3methylimidazolium chloride on methane hydrate equilibrium. J Phys Conf Ser, p 012060 51. Chua PC, Sæbø M, Lunde A, Kelland MA (2011) Dual kinetic hydrate inhibition and scale inhibition by polyaspartamides. Energy Fuels 25:5165–5172 52. Khan MS, Lal B, Keong LK, Ahmed I (2019) Tetramethyl ammonium chloride as dual functional inhibitor for methane and carbon dioxide hydrates. Fuel 236:251–263 53. Netušil M, Ditl P (2012) Natural gas dehydration. Nat Gas Extr to End Use. https://doi.org/ 10.1016/B978-0-12-801499-8.00007-9 54. Gonfa G, Bustam MA, Sharif AM, Mohamad N, Ullah S (2015) Tuning ionic liquids for natural gas dehydration using COSMO-RS methodology. J Nat Gas Sci Eng. https://doi.org/ 10.1016/j.jngse.2015.09.062 55. Harrison SE (2010) Natural gas hydrates 56. Turosung SN, Ghosh B (2017) Application of ionic liquids in the upstream oil industry-a review. Int J Petrochemistry Res 1:50–60 57. Ke W, Chen D (2019) A short review on natural gas hydrate, kinetic hydrate inhibitors and inhibitor synergists. Chinese J Chem Eng 27:2049–2061 58. Sayani JKS, Pedapati SR, Lal B (2020) Phase behavior study on gas hydrates formation in gas dominant multiphase pipelines with crude oil and high CO2 mixed gas. Sci Rep 10:1–12 59. Avula VR, Gardas RL, Sangwai JS (2014) Modeling of methane hydrate inhibition in the presence of green solvent for offshore oil and gas pipeline. Proc Int Offshore Polar Eng Conf 3:49–54 60. Israelachvili JN (2011) Intermolecular and surface forces, 3rd edn. Elsevier, Waltham 61. Khan MS, Lal B, Keong LK, Sabil KM (2018) Experimental evaluation and thermodynamic modelling of AILs alkyl chain elongation on methane riched gas hydrate system. Fluid Phase Equilib 473:300–309 62. Sa JH, Lee BR (2011) Amino acids as natural inhibitors for hydrate formation in CO2 sequestration. Environ Sci Technol 45:5885–5891

172

A. Qasim and B. Lal

63. Sayani JKS, Pedapati SR, Kassim Z, Lal B (2021) Investigation on thermodynamic equilibrium conditions of methane hydrates in multiphase gas-dominant pipelines. ACS Omega 6:2505–2512 64. Heng-Joo Ng DBR, Ng HJ, Robinson DB (1985) Hydrate formation in systems containing methane, ethane, propane, carbon dioxide or hydrogen sulfide in the presence of methanol. Fluid Phase Equilib 21:145–155 65. Anderson FE, Prausnitz JM (1986) Inhibition of gas hydrates by methanol. AIChE J 32:1321– 1333 66. Kannan K, Punase A (2009) Low dosage, high efficiency and environment friendly inhibitors: a new horizon in gas hydrates mitigation in production systems. Soc Pet Eng Eur Conf Exhib 67. Huo Z, Freer E, Lamar M, Sannigrahi B, Knauss DM, Sloan ED (2001) Hydrate plug prevention by anti-agglomeration. Chem Eng Sci 56:4979–4991 68. Sharifi H, Ripmeester J, Walker VK, Englezos P (2014) Kinetic inhibition of natural gas hydrates in saline solutions and heptane. Fuel 117:109–117 69. Lee W, Shin JY, Cha JH, Kim KS, Kang SP (2016) Inhibition effect of ionic liquids and their mixtures with poly(N-vinylcaprolactam) on methane hydrate formation. J Ind Eng Chem 38:211–216 70. Saberi A, Alamdari A, Rasoolzadeh A, Mohammadi AH (2020) Insights into kinetic inhibition effects of MEG, PVP, and L-tyrosine aqueous solutions on natural gas hydrate formation. Pet Sci. https://doi.org/10.1007/s12182-020-00515-0 71. Sa J-H, Kwak G-H, Lee BR, Park D-H, Han K, Lee K-H (2013) Hydrophobic amino acids as a new class of kinetic inhibitors for gas hydrate formation. Sci Rep 3:2428 72. Del Villano L, Kommedal R, Kelland MA (2008) Class of kinetic hydrate inhibitors with good biodegradability. Energy Fuels 22:3143–3149 73. Bavoh CB, Lal B, Ben-Awuah J, Khan MS, Ofori-Sarpong G (2019) Kinetics of mixed amino acid and ionic liquid on CO2 hydrate formation. IOP Conf Ser Mater Sci Eng 495:012073 74. Mokhatab S, Wilkens RJ, Leontaritis KJ (2007) A Review of strategies for solving gas-hydrate problems in subsea pipelines. Energy Sources Part A Recover Util Environ Eff 29:39–45 75. Haniffa MAM, Hashim FM (2011) Review of hydrate prevention methods for deepwater pipelines. 2011 IEEE Conf Open Syst ICOS, 165–171 76. Moore JA, Ver Vers L, Conrad P (2009) Understanding kinetic hydrate inhibitor and corrosion inhibitor interactions. In: Offshore technology conference Houston, Texas, pp 1–20 77. Kang SP, Shin JY, Lim JS, Lee S (2014) Experimental measurement of the induction time of natural gas Hydrate and its prediction with polymeric kinetic inhibitor. Chem Eng Sci 116:817–823 78. Zeng H, Wilson LD, Walker VK, Ripmeester JA (2006) Effect of antifreeze proteins on the nucleation, growth, and the memory effect during tetrahydrofuran clathrate hydrate formation. J Am Chem Soc 128:2844–2850 79. Sloan ED, Subramanian S, Matthews PN, Lederhos JP, Khokhar AA (1998) Quantifying hydrate formation and kinetic inhibition. Ind Eng Chem Res 37:3124–3132 80. Ke W, Kelland MA (2016) Kinetic hydrate inhibitor studies for gas hydrate systems: a review of experimental equipment and test methods. Energy Fuels 30:10015–10028 81. Norland AK, Kelland M (2011) the Crystal growth inhibition of tetrahydrofuran hydrate with polyquaternary ammonium salts. 7th Int Conf Gas Hydrates (ICGH 2011). https://doi.org/10. 1016/j.ces.2011.11.003 82. Kelland MA (2006) History of the development of low dosage hydrate inhibitors. Energy Fuels 20:825–847 83. Kelland MA, Svartås TM, Andersen LD (2009) Gas hydrate anti-agglomerant properties of polypropoxylates and some other demulsifiers. J Pet Sci Eng 64:1–10 84. Hammerschmidt EG, Natural T, Company G (1934) Gas hydrates in natural gas transmission lines. Ind Eng Chem 26:851–855 85. Villard P (1888) On some new gas hydrates. Compt Rend 106:1602–1603 86. Yarveicy H, Ghiasi MM, Mohammadi AH (2018) Determination of the gas hydrate formation limits to isenthalpic Joule—Thomson expansions. Chem Eng Res Des 132:208–214

9 Machine Learning Application in Gas Hydrates

173

87. Irfan SA, Azeem B, Irshad K, Kushaari K (2020) Machine learning model for nutrient release from biopolymers coated controlled-release fertilizer, 1–12 88. Zahedi G, Karami Z, Yaghoobi H (2009) Prediction of hydrate formation temperature by both statistical models and artificial neural network approaches. Energy Convers Manag 50:2052– 2059 89. Shavesteh K, Heydari A, Kamalzadeh L, Aliaskari F (2006) Prediction of hydrate formation temperature for natural gas using artificial neural network. CHISA 2006—17th international congress chemistry process engineering 90. Zeinali N, Saber M, Ameri A (2012) Comparative analysis of hydrate formation pressure applying cubic equations of state (eos), artificial neural network (ann) and adaptive neurofuzzy inference system (anfis). Int J Thermodyn 15:91–101 91. Ghavipour MM, Ghavipour MM, Chitsazan M, Najibi SH, Ghidary SS (2013) Experimental study of natural gas hydrates and a novel use of neural network to predict hydrate formation conditions. Chem Eng Res Des 91:264–273 92. Elgibaly AA, Elkamel AM (1998) A new correlation for predicting hydrate formation conditions for various gas mixtures and inhibitors. Fluid Phase Equilib 152:23–42 93. Elgibaly A, Elkamel A (1999) Optimal hydrate inhibition policies with the aid of neural networks. Energy Fuels 13:105–113 94. Soroush E, Mesbah M, Shokrollahi A, Rozyn J, Lee M, Kashiwao T, Bahadori A (2015) Evolving a robust modeling tool for prediction of natural gas hydrate formation conditions. J Unconv Oil Gas Resour 12:45–55 95. Ward Z (2015) Phase equilibria of gas hydrates containing hydrogen sulfide and carbon dioxide. Colorado school of mines 96. Chapoy A, Mohammadi AH, Richon D (2007) Predicting the hydrate stability zones of natural gases using artificial neural networks. Oil Gas Sci Technol. https://doi.org/10.2516/ogst:200 7048 97. Mohammadi AH, Richon D (2010) Use of an artificial neural network algorithm to determine pressure-temperature phase diagrams of tert-butylamine + methane and tert-butylamine + hydrogen binary hydrates. Ind Eng Chem Res 49:10141–10143 98. Yarveicy H, Kariman A, Ghiasi MM (2014) Practical use of statistical learning theory for modeling freezing point depression of electrolyte solutions : LSSVM model. J Nat Gas Sci Eng 20:414–421 99. Babakhani SM, Bahmani M, Shariati J, Badr K, Balouchi Y (2015) Comparing the capability of artificial neural network (ANN) and CSMHYD program for predicting of hydrate formation pressure in binary mixtures. J Pet Sci Eng 136:78–87 100. Baghban A, Ali M, Pouladi B, Amanna B (2015) The Journal of Supercritical Fluids Phase equilibrium modeling of semi-clathrate hydrates of seven commonly gases in the presence of TBAB ionic liquid promoter based on a low parameter connectionist technique 101:184–192 101. Baghban A, Namvarrechi S, Phung LTK, Lee M, Bahadori A, Kashiwao T (2016) Phase equilibrium modelling of natural gas hydrate formation conditions using LSSVM approach. Pet Sci Technol 34:1431–1438 102. Rzasa MJ, Katz DL (1945) Calculation of static pressure gradients in gas wells. Trans AIME 160:100–113 103. Yarveicy H, Ghiasi MM (2017) Modeling of gas hydrate phase equilibria: extremely randomized trees and LSSVM approaches. J Mol Liq 243:533–541 104. Rebai N, Hadjadj A, Benmounah A, Berrouk AS, Boualleg SM (2019) Prediction of natural gas hydrates formation using a combination of thermodynamic and neural network modeling. J Pet Sci Eng 182:106270 105. Hosseinzadeh A, Mohammadi A, Soroush E (2020) Predicting semiclathrate hydrates dissociation pressure using a rigorous machine learning approach. J Dispers Sci Technol 41:863–872 106. Landgrebe MKB, Nkazi D (2019) Toward a robust, universal predictor of gas hydrate equilibria by means of a deep learning regression. https://doi.org/10.1021/acsomega.9b02961

174

A. Qasim and B. Lal

107. Acharya P V., Bahadur V (2021) Thermodynamic features-driven machine learning-based predictions of clathrate hydrate equilibria in the presence of electrolytes. Fluid Phase Equilib. https://doi.org/10.1016/j.fluid.2020.112894 108. Xu H, Jiao Z, Zhang Z, Huffman M, Wang Q (2021) Prediction of methane hydrate formation conditions in salt water using machine learning algorithms. Comput Chem Eng 151:107358 109. Qin H, Srivastava V, Wang H, Science C, Zerpa LE, Koh CA (2019) Machine learning models to predict gas hydrate plugging risks using flowloop and field data. Offshore Technol Conf. https://doi.org/10.4043/29411-MS

Chapter 10

Machine Learning Application Guidelines in Flow Assurance Cornelius Borecho Bavoh and Bhajan Lal

Abstract In this chapter guidelines for conducting an effective machine learning based prediction models in flow assurance areas is presented with much emphasis of data availability, data representation and model selection. Keywords Machine learning · Flow assurance · Big data · Models

10.1 Introduction Generally, the availability and processing of data is the most critical guidelines for any machine learning applications. This also involves the use of data that well represents the model of the choice. In this chapter we briefly discuss some useful guidelines for use machine learning in flow assurance [1, 2].

10.2 Data Selection Data is the currency needed to successfully conduct a machine learning prediction. This is the initial and important information needed to train or teach the model. The developed machine’s performance highly depends on the strength or weakness of the data. In the area of flow assurance, data might be experimental thermodynamic or kinetic parameters, images, signals, temperatures, pressures, inhibitors concentrations, additives molecular structures and properties, first-principles calculations, or complex simulation models. The use of big data is highly recommended in flow assurance applications, since this could be readily available from company’s actives C. B. Bavoh · B. Lal (B) Chemical Engineering Department, Universiti Teknologi PETRONAS, 32610 Bandar Seri Iskandar, Perak Darul Ridzuan, Malaysia e-mail: [email protected] Research Centre for CO2 Capture (RCCO2C), Universiti Teknologi PETRONAS, 32610 Bandar Seri Iskandar, Perak, Malaysia © The Author(s), under exclusive license to Springer Nature Switzerland AG 2023 B. Lal et al. (eds.), Machine Learning and Flow Assurance in Oil and Gas Production, https://doi.org/10.1007/978-3-031-24231-1_10

175

176

C. B. Bavoh and B. Lal

log data. For some systems such as thermodynamics of most flow assurance aspects, the use of existing simulations (such as PVTSIM, OLGA, etc.) could be the fasters source of huge database. Due to limitations on kinetics data and the high cost of experimentations, the use of published data in patents and articles could be relevant for such simulations. It must be stated that the kinetics of most flow assurance systems are very stochastics and system dependant. This further narrows the challenges of acquiring large flow assurance kinetics related data from literature. Data curation is an important aspect data preparation for the machine learning methods in flow assurance. Issues like data quality which range from the generations to the storage of data must be done in a manner to prevent biases. It is worth noting that, the data size and type is also dependant on the machine learning models. For instant, the data requirement for deep learning systems are different from the traditional modelling. The data used for ANNs are both used for learning and training. That is why they require huge amount of data. On the other hand, the data is mostly splintered into training, validations, and testing. Typically, most author widely use about 70% of the data for training and validation while the remaining 30% is used for testing. The training and validation are done at the same phase because the validation is used to provide an unbiased evaluation of the model fit during the training phase. However, the test data are unseen and is used to finally fit the model. This is mostly known as the main indicator of the model quality [1, 2].

10.3 Data Representation Aside from the just getting data, the next very important guideline needed to ensure a quality model is the representation of the data. In flow assurance systems the data could either be numerical and in image format. The ability to accurately define the right input model variables or feature is very important to yield an accurate model prediction. This process is known as feature selection and has been the topic of several studies. The feature selection must be done to target the actual variables that affect the output variable to be predicted. Also, the number of variables needed for the prediction must be well considered and properly determined. Limiting the number of selected features may reduce the computational cost of both training and executing the model, while improving the overall accuracy. This feature-selection process is of lesser importance in so-called deep learning methods, which are assumed to internally select those features that are considered to be important. Then, an input layer that consists of basic process parameters in flow assurance (e.g., pressure, temperature, gas gravity, moles consumed, rate of formation, induction time, etc.), feed characterizations (e.g., equilibrium, feed compositions), or hydrocarbon or inhibitor properties (e.g., gravity, concentration, molecular weight, surface tension, activity coefficient etc.) are often sufficient. It is mostly challenging to represent data set that are not numerical, especially when dealing with molecules and reaction in flow assurance systems. In addition, the stochastic nature of most flow assurance areas

10 Machine Learning Application Guidelines …

177

makes it difficult to accurately represent their data set in a machine learning model [1, 2].

10.4 Model Development The type of model for the selected data is the final step in machine learning modelling. Since there are several machine learning models, it is very difficulty to choose a models. This mostly require fundamental knowledge on the machine learning models coupled with vested command over the respective flow assurance modelling area. Currently in flow assurance modelling authors mostly use random models for predictions and sometimes compare their efficiency amongst themselves and traditional models. There are classification and regression models, however, the use of regression model is mostly used in flow assurance issues. The models could also be unsupervised, supervised, active, or transfer learning [3–5]. Generally, supervised learning is used in flow assurance issues, with few studies based on unsupervised learning. Common techniques such as k-means algorithm, decision trees [5], random forests [6], support vector machines [5], and ANNs [7] can be used for machine learning in flow assurance. Also, the use of hybrid models can be adopted with effective and suitable transfer functions.

References 1. Trinh C, Meimaroglou D, Hoppe S (2021) Machine learning in chemical product engineering: the state of the art and a guide for newcomers. Processes. https://doi.org/10.3390/pr9081456 2. Dobbelaere MR, Plehiers PP, Van de Vijver R, Stevens CV, Van Geem KM (2021) Machine learning in chemical engineering: strengths, weaknesses, opportunities, and threats. Engineering 7:1201–1211 3. Obanijesu EO, Omidiora EO (2008) Artificial neural network’s prediction of wax deposition potential of Nigerian crude oil for pipeline safety. Pet Sci Technol 26:1977–1991 4. Hosseinzadeh A, Mohammadi A, Soroush E (2020) Predicting semiclathrate hydrates dissociation pressure using a rigorous machine learning approach. J Dispers Sci Technol 41:863–872 5. Alhashem M (2019) Supervised machine learning in predicting multiphase flow regimes in horizontal pipes. Soc Pet Eng Abu Dhabi Int Pet Exhib Conf 2019, ADIP 2019. https://doi.org/ 10.2118/197545-ms 6. Acharya P V., Bahadur V (2021) Thermodynamic features-driven machine learning-based predictions of clathrate hydrate equilibria in the presence of electrolytes. Fluid Phase Equilib. https://doi.org/10.1016/j.fluid.2020.112894 7. Mohammadi AH, Richon D (2010) Use of an artificial neural network algorithm to determine pressure-temperature phase diagrams of tert-butylamine + methane and tert-butylamine + hydrogen binary hydrates. Ind Eng Chem Res 49:10141–10143