CET Volume 86 DOI: 10.3303/CET2186167 Paper Received: 12 August 2020; Revised: 5 February 2021; Accepted: 9 May 2021 Please cite this article as: Mandis M., Chebeir J., Baratti R., Romagnoli J.A., Tronci S., 2021, Machine Learning for Monitoring and Control of Ngl Recovery Plants, Chemical Engineering Transactions, 86, 997-1002 DOI:10.3303/CET2186167 CHEMICAL ENGINEERING TRANSACTIONS VOL. 86, 2021 A publication of The Italian Association of Chemical Engineering Online at www.cetjournal.it Guest Editors: Sauro Pierucci, Jiří Jaromír Klemeš Copyright © 2021, AIDIC Servizi S.r.l. ISBN 978-88-95608-84-6; ISSN 2283-9216 Machine Learning for Monitoring and Control Of NGL Recovery Plants Marta Mandisa, Jorge A. Chebeirb, Roberto Barattia, José A. Romagnolib, Stefania Troncia a Dip. di Ingegneria Meccanica, Chimica e dei Materiali, Università degli Studi di Cagliari, Cagliari, Italy b Department of Chemical Engineering, Louisiana State University,Baton Rouge, United States of America stefania.tronci@dimcm.unica.it In this contribution, the monitoring and control problem of the natural gas liquids (NGL) extraction process is addressed by exploiting a data-driven approach. The cold residue reflux (CRR) process scheme is considered and simulated by using the process simulator Aspen HYSYS®, with the main targets of the achievement of 84% ethane recovery and low levels of methane impurity at the bottom of the demethanizer column. The respect of product quality is obtained by designing a proper control strategy that uses a data-driven approach based on a neural network to estimate the unmeasured outputs. The performance of the controlled system is assessed by simulating the process under various input conditions evaluating different control structures such as direct control and cascade control of the temperature in the column. 1. Introduction Technological advances in extraction processes have turned natural gas into an energy resource increasingly used across the world. An additional source of profit comes from natural gas liquids (NGL), the C2+ hydrocarbon fraction contained in the raw gas. NGL has a higher market value than natural gas, as a source of feedstock materials for other production processes (Mokhatab et al., 2015), therefore it is preferable to separate these components from the raw gas, which is instead mainly used as fuel. For this purpose, different plant schemes have been studied and developed beginning from the conventional process scheme to optimize the recovery of these valuable elements and minimize the energy demand required by the process (Wilkinson and Hudson,1992). Among the developed schemes one of the most common is the cold residue recycle (CRR), where through plant modifications, that provide a reflux flow rate in the demethanizer column, it is possible to obtain a higher ethane recovery. In previous contributions by the authors, the cold residue reflux (CRR) process model was developed in the process simulator HYSYS®, which was selected due to its reliable performance in petrochemical, petroleum refining, oil assays, and all related industry (Chebier et al., 2019a). The CRR process has been constructed based on realistic operating conditions and has been used for the analysis and control of the separation process of NGL in the presence of typical disturbances (Chebier et al., 2019b). The previous studies showed that deviation of product quality from the target can be minimized by an appropriate control strategy, that can be based on temperature measurements and the estimation of the bottom boil-up (Tronci et al., 2020). The use of the simulator allows the collection of data that can be used to monitor the correct process performance and, through the use of deep learning techniques, to develop data-driven sensors. In this paper, the results previously obtained have been improved by exploiting data-driven modeling techniques to provides a trustworthy online estimation of these variables based on recorded historical measurements of measurable process variables (Zhang et al., 2014; Ghadipasha et al., 2018). The main goals of the present work can be summarized in the following points: (i) an accurate estimation of the boil-up used in the ratio control loop, (ii) the estimation of product composition using the easy-to-measure process variables usually available in industrial plants and (iii) the development of an inferential control for methane concentration that gives the set- point to the column temperature control loop. For this purpose, feedforward neural networks have been used 997 to relate measured outputs to the unmeasured variables, enhancing the behavior of the control loops and the product quality by the estimation of the quality-relevant variables in real time. The obtained neural network models have been implemented in the process simulator HYSYS® and their performances have been tested by exciting the systems with various input signals. 2. Description of NGL recovery plant The dynamic simulation of CRR process was developed in the process simulator Aspen HYSYS® and based on realistic operating conditions optimized under nominal operation (Chebeir et al., 2019). The raw gas was fed to the separation units with a molar flow rate of 4980 kmol/h and composition with a low content of liquids (Table 1). The following inlet conditions were used: pressure equal to 5818 kPa and temperature equal to 35 °C. Table 1. Feed gas composition for the NGL recovery plant Component Composition Nitrogen 0.01 Methane 0.93 Ethane 0.03 Propane 0.015 Butanes 0.009 Pentanes 0.003 Hexanes 0.003 %C2+ 6 The main difference of this process structure when compared to other schemes (Chebier et al., 2019) resides in the incorporation of a reflux stream in the column overhead. The methane reflux intends to improve the rectifying section so that only a negligible amount of ethane and heavier components escaped from the column overhead. The scheme of the process is reported in Figure 1, along with the designed control loops. Figure 1. CRR scheme and control structure 3. Control strategy The target values for the demethanizer are 84% for ethane recovery and 1 mol% for methane concentration in the bottom. The ethane recovery has been maintained by controlling the temperature in the separator TK-100 (Figure 1), while the methane concentration has been indirectly controlled by the temperature loop. The efficiency of the column temperature controller has been improved by adding a flow-rate controller as slave of the temperature controller in a cascade configuration (Tronci et al., 2020). The flow-rate controller maintains 998 constant the ratio between boil-up and bottom and uses an estimation of the boil-up because it is not measured in real plants. Even if the position of the temperature measurement has been properly set using a per-component contribution diagram (Porru et al., 2015), its control does not guarantee the respect of methane concentration targets when feed composition changes. This problem has been solved by using an inferential control that has been added to the cascade. The configuration for methane control is therefore formed by three loops. The external loop is the methane composition control, that gives the set-point to the temperature control. The most internal loop is the flow-rate controller that receives the set-point from the temperature loop. 4. Data-driven soft sensor The control strategy represented in Figure 1 needs the evaluation of two variables, the bottom boil-up and the methane concentration, which are not usually measured in industrial plant. If an analyzer is present for measuring product concentration, it takes time to perform the analysis. An accurate real-time estimation of such variables can indeed improve control performances. Furthermore, the effectiveness of the two control loops to reach the required ethane recovery can be continuously evaluated by estimating ethane concentration in the bottom product. Such considerations led to the development of data-driven tools for the estimation of the measured variables. Because of their successful application in the process industry, feedforward neural networks have been used to relate the unmeasured outputs to the available variables. In this work, a knowledge-based approach supported by statistical tools has been used to identify the inputs of the network, which are the variables affecting the estimated output. The selected network architecture has one hidden layer and the number of hidden neurons has been selected starting with the simplest model, with only one hidden unit, and adding one more neuron until a significant change in the model performance was observed (Spigno and Tronci, 2015; Tronci et al., 2019). Input and hidden layers have been augmented with an extra neuron, the bias, which provides a constant output signal equal to one. The selection of the best neural network model has been accomplished by considering the determination coefficient (R2) and mean squared error (MSE) as performance indexes. 5. Results 5.1 Soft sensor Data (one month of operation with sampling time of 10 minutes) for training the network have been obtained by considering changes in the feed flow rate and inlet composition. The former variation simulates the variability due to natural gas daily demand (range of variation: 4500-5500 kmol/h), while the latter mimics changes in extraction basin characteristics (range of variation for methane: 0.92-0.94; range of variation for ethane: 0.02-0.04%). The measured data collected to train the neural networks include noise normally distributed with zero-mean, in order to obtain a more realistic representation of real plants data. Standard deviation equal to 0.04 °C and 20kPA has been used for temperature and pressure measurements, respectively. Variations of ±1% have been considered for flowrate measurements, ±0.2% for level measurements and ±2% for composition measurements. The structure of the NN models for the estimation of boil-up, methane and ethane are reported in Table 2 along with the statistical performance indexes. Table 2. Neural networks inputs and statistical performances Boil-up Inputs Temperature difference between tray 28 and bottom; column bottom temperature; bottom product temperature and bottom product flow rate. Hidden neurons R2 Train MSE Train R2 TEST MSE TEST 6 0.997 3.88E-02 0.990 3.59E-02 Methane conc. Inputs Temperature difference between tray 28 and bottom; separator temperature; separator pressure and bottom product flow rate. Hidden neurons R2 Train MSE Train R2 TEST MSE TEST 3 0.985 2.55E-07 0.953 1.59E-07 Ethane rec. Inputs Temperature difference between tray 28 and bottom; separator temperature; separator pressure; bottom product flow rate; separator liquid product flow and separator level. Hidden neurons R2 Train MSE Train R2 TEST MSE TEST 3 0.941 1.34E-04 0.807 1.37E-04 999 To validate reconstruction capabilities of the neural networks, they were implemented in the Aspen HYSYS® simulation and compared with the actual values of the target variables by varying the input flow rate with step changes of different amplitudes. Results are reported in Figure 2. It is worth noting that validation has been performed by considering different input changes concerning to the ones used for selecting the best neural network models. Figure 2. Comparison of actual boil-up and boil-up soft-sensor measurements (left panel); comparison of actual methane concentration and methane soft-sensor measurements (central panel); comparison of actual ethane recovery end ethane recovery soft-sensor measurements (right panel). Figure 2 shows that the software sensors for boil-up (left panel) and methane composition (central panel) are able to reproduce the actual variables trend quite accurately. The soft sensor for ethane recovery shows poorer performance with respect to the other ones, because it cannot predict peaks but only the average trend. It is nevertheless useful for monitoring this production index if no other information is available in the plant. 5.2 Control performance The performances of the soft sensors and the proposed control structures to maintain ethane recovery of 84% and methane composition of 1 mol% in the bottom product of the demethanizer column have been evaluated by simulating the process under feed disturbances considering step variations in the inlet flow rate of ±10%. For sake of brevity, only the results obtained when the inlet flow rate is increased are reported. The following control structure are considered: (i) conventional controller (direct temperature control in the separator and demethanizer column), (ii) two loops cascade with boil-up estimated with the neural network (hereafter indicated with CAS-1), (iii) three loops cascade with delayed methane measurements (hereafter indicated with CAS-2) and (iv) three loops cascade with methane estimated with the neural network (hereafter indicated with CAS-3). In Figure 3 the responses for a 10% increasing in the inlet flow rate is depicted. In this case, product composition is indirectly controlled by keeping separator and column temperature at the required set-point. Considering the column tray temperature profile (left panel, top), the cascade control CAS-1 drastically reduces the initial variation with respect to the conventional control. This behavior implies a reduction of methane initial deviation and a faster response of this variable. Even if the temperature is kept at the required set-point, methane concentration does not reach the target, but a final offset of 0.3% is obtained with the two control strategies. The implementation of the soft-sensor for ethane recovery (Figure 3, right panel, bottom) can reduce the impact of noise in the measurement and give a satisfactory reconstruction of the ethane recovery behavior. To satisfy the specifics for the product composition, another control loop has been added. In particular, a methane composition controller has been designed to adjust the temperature controller setpoint, leading to the implementation of three loops cascade controllers. Two different situations have been considered: (i) the use of delayed concentration measurements obtained through the use of an on-line analyzer and (ii) an inferential control based on the estimation of the neural network model. In Figure 4, the comparison between the two control strategies CAS-2 and CAS-3 are reported. It is worth noting that when using delayed measurement, the sample is taken every 30 minutes, and the analyzer has a delay equal to 10. 1000 Figure 3. Profiles obtained with conventional controller and the proposed two loops cascade controller (CAS- 1) for methane impurity level (left panel) and the temperature control for ethane recovery (right panel) for a 10% increase on the inlet flow rate. Figure 4. Profiles obtained with the three loops cascade controller for methane impurity level with on-line and delayed methane measurements (CAS-2) and with methane soft-sensor (CAS-3) (left panel) and the temperature control for ethane recovery (right panel) for a 10% increase on the inlet flow rate. Figure 4 shows the behaviors obtained in response to a 10% increase in the inlet flow rate. The methane composition profiles (Figure 4, left panel, bottom) with the CAS-2 control shows a higher initial deviation and sluggish response. The use of delayed measurements implies a more conservative control action. When the estimation is available in real time (CAS-3) the performance of the controlled system improves because the initial deviation is smaller and the controlled output response is faster. Because of the estimation error of the soft-sensor, a small offset is present when using the inferential control. The implementation of the soft-sensor 1001 for ethane recovery (Figure 4, bottom right panel) filters the noise in the measurement and gives a satisfactory reconstruction of the ethane response. 6. Conclusions The control problem of a process for the extraction of natural gas liquids was addressed by exploiting neural network modeling to obtain a real-time estimation of critical variables. The developed soft-sensors were able to effectively reconstruct the dynamic behavior of the boil-up of the demethanizer column and the methane concentration in the bottom product. Those estimations were successfully used as controlled outputs in two different control configurations to guaranteeing the required target for both feed flowrate and inlet composition variations. The same data-driven approach was also applied to estimate the recovery of ethanol in the demethanizer, obtaining a valuable tool for monitoring the process in real-time when the analyzer has a long delay or is not present. In order to improve the estimation capabilities of the soft-sensors and controllers, a new campaign of simulations will be conducted to better characterize the process in the designed target conditions. Further investigations are also planned to evaluate the performance of different data-driven algorithms. References Chebeir, J., Salas, S., & Romagnoli, J., 2019a, Simulation-based Optimization and Control of a Natural Gas Liquids Recovery Unit, Chemical Engineering Transactions, 74, 757-762. Chebeir, J., Salas, S.D., Romagnoli, J.A., 2019b, Operability assessment on alternative natural gas liquids recovery schemes, J. Nat. Gas Sci. Eng., 71, pp. 102974. Ghadipasha N., Romagnoli, J.A., Tronci, S., Baratti,2018, A model-based approach for controlling particle size distribution in combined cooling-antisolvent crystallization processes, Chemical Engineering Science, 190(23), 260-272. Mokhatab, S., Poe, W.A., Mak, J.Y., 2015, Handbook of Natural Gas Transmission and Processing: Principles and Practices. Gulf Professional Publishing, New York, NY. Porru, M., Baratti, R., Alvarez, J., 2015, Energy saving through control in an industrial multicomponent distillation column, IFAC-PapersOnLine, 48(8), 1138-1143. Spigno, G., Tronci, S., 2015, Development of hybrid models for a vapor-phase fungi bioreactor, Mathematical Problems in Engineering, 2015. Tronci, S., Chebeir, J. A., Mandis, M., Baratti, R., Romagnoli, J. A., 2020, Control Strategies for Natural Gas Liquids Recovery Plants. In Computer Aided Chemical Engineering (Vol. 48, pp. 1291-1296). Elsevier. Tronci, S., Van Neer, P., Giling, E., Stelwagen, U., Piras, D., Mei, R., Corominas, F., Grosso , M., 2019, In-line monitoring and control of rheological properties through data-driven ultrasound soft-sensors, Sensors, 19(22), 5009. Wilkinson, J.D., Hudson, H.M., 1992, Improved NGL Recovery Designs: Maximise Operating Flexibility and Product Recoveries, Tulsa, USA. Zhang, B., Willis, R., Romagnoli, J.A., Fois, C., Tronci, S., Baratti, R., 2014, Image-based multiresolution-ANN approach for online particle size characterization, Industrial and Engineering Chemistry Research, 53(17),2008-7018. 1002