Abstract
Reservoir simulators model the highly nonlinear partial differential equations that represent flows in heterogeneous porous media. The system is made up of conservation equations for each thermodynamic species, flash equilibrium equations and some constraints. With advances in Field Development Planning (FDP) strategies, clients need to model highly complex Improved Oil Recovery processes such as gas re-injection and CO2 injection, which requires multi-component simulation models. The operating range of these simulation models is usually around the mixture critical point and this can be very difficult to simulate due to phase mislabeling and poor nonlinear convergence. We present a Machine Learning (ML) based approach that significantly accelerates such simulation models. One of the most important physical parameters required in order to simulate complex fluids in the subsurface is the critical temperature (Tcrit). There are advanced iterative methods to compute the critical point such as the algorithm proposed by Heidemann and Khalil (AIChE J 26,769–799, 1980) but, because these methods are too expensive, they are usually replaced by cheaper and less accurate methods such as the Li-correlation (Reid and Sherwood 1966). In this work we use a ML workflow that is based on two interacting fully connected neural networks, one a classifier and the other a regressor, that are used to replace physical algorithms for single phase labelling and improve the convergence of the simulator. We generate real time compositional training data using a linear mixing rule between the injected and the in-situ fluid compositions that can exhibit temporal evolution. In many complicated scenarios, a physical critical temperature does not exist and the iterative sequence fails to converge. We train the classifier to identify, a-priori, if a sequence of iterations will diverge. The regressor is then trained to predict an accurate value of Tcrit. A framework is developed inside the simulator based on TensorFlow that aids real time machine learning applications. The training data is generated within the simulator at the beginning of the simulation run and the ML models are trained on this data while the simulator is running. All the run-times presented in this paper include the time taken to generate the training data and train the models. Applying this ML workflow to real field gas re-injection cases suffering from severe convergence issues has resulted in a 10-fold reduction of the nonlinear iterations in the examples shown in this paper, with the overall run time reduced 2- to 10-fold, thus making complex FDP workflows several times faster. Such models are usually run many times in history matching and optimization workflows, which results in compounded computational savings. The workflow also results in more accurate prediction of the oil in place due to better single phase labelling.
Similar content being viewed by others
References
Abadi, M., Barham, P., Chen, J., Chen, Z., Davis, A., Dean, J., Devin, M., Ghemawat, S., Irving, G., Isard, M., et al.: Tensorflow: A system for large-scale machine learning. In: 12Th {USENIX} Symposium on Operating Systems Design and Implementation ({OSDI} 16), pp 265–283 (2016)
Alzayer, A.N., Voskov, D.V., Tchelepi, H.A.: Relative permeability of near-miscible fluids in compositional simulators. Transp. Porous Media 122, 547–573 (2018)
Aziz, K., Settari, A.: Petroleum reservoir simulation. Elsevier Applied Science (1979)
Baker, L.E., Luks, K.D.: Critical point and saturation pressure calculations for multipoint systems (includes associated paper 8871). SPE J. 20(1), 15–24 (1980)
Bennett, J., Schmidt, K.A.G.: Comparison of phase identification methods used in oil industry flow simulations. Energ. Fuels 31(4), 3370–3379 (2017)
Gaganis, V., Varotsis, N.: Machine Learning Methods to Speed up Compositional Reservoir Simulation. In: SPE Europec/EAGE Annual Conference.EAGE (2012)
Heidemann, R., Khalil, A.: The calculation of critical points. AIChE J. 26, 769–779 (1980)
Kashinath, A., Szulczewski, M., Dogru, A.: A fast algorithm for calculating isothermal phase behavior using machine learning. Fluid Phase Equilib. 465, 73–82 (2018)
Li, Y., Zhang, T., Sun, S., Gao, X.: Accelerating flash calculation through deep learning methods. J. Comput. Phys. 394, 153–165 (2019). https://doi.org/10.1016/j.jcp.2019.05.028
McKinney, W., et al.: Data structures for statistical computing in python. In: Proceedings of the 9th Python in Science Conference, vol. 445, pp 51–56. TX, Austin (2010)
Michelsen, M.L., Heidemann, R.A.: Calculation of critical points from cubic two-constant equations of state. AIChE J 27(3), 521–523 (1981). https://doi.org/10.1002/aic.690270326
Nichita, D.V.: Calculation of critical points using a reduction method. Fluid Phase Equilib. 228, 223–231 (2005)
Nichita, D.V.: A new method for critical points calculation from cubic eos. AIChE J 52, 1220–1227 (2005)
Oladokun, E., Sheth, S.M., Jönsthövel, T., Neylon, K.: Machine-Learning Informed Prediction of Linear Solver Tolerance for Non-Linear Solution Methods in Numerical Simulation. In: ECMOR XVII - 17Th European Conference on the Mathematics of Oil Recovery, 14-17 September, 2020. EAGE (2020)
Pedregosa, F., Varoquaux, G., Gramfort, A., Michel, V., Thirion, B., Grisel, O., Blondel, M., Prettenhofer, P., Weiss, R., Dubourg, V., et al.: Scikit-learn: Machine learning in python. J. Mach. Learn. Res. 12(Oct), 2825–2830 (2011)
Peng, D.Y., Robinson, D.B.: A new two-constant equation of state. Ind. Eng. Chem. Fundamen. 15(1), 59–64 (1976)
Petitfrère, M., De Loubens, R., Patacchini, L.: Continuous relative permeability model for compositional reservoir simulation, using the true critical point and accounting for miscibility. In: SPE Reservoir Simulation Conference. Society of Petroleum Engineers (2019)
Reid, R.C., Sherwood, T.K.: The Properties of Gases and Liquids, 2nd edn. McGraw, New York (1966)
Schlumberger: INTERSECT 2020.4 Technical description schlumberger (2020)
Sheth, S.M., McKee, F., Neylon, K., Fazil, G.: Intelligent time-stepping for practical numerical simulation. In: SPE Reservoir Simulation Conference. Society of Petroleum Engineers. To appear (2021)
Acknowledgements
The authors would like to thank Schlumberger management for permission to publish this work.
Author information
Authors and Affiliations
Corresponding author
Additional information
Publisher’s note
Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
Rights and permissions
About this article
Cite this article
Sheth, S., Heidari, M.R., Neylon, K. et al. Acceleration of thermodynamic computations in fluid flow applications. Comput Geosci 26, 1–11 (2022). https://doi.org/10.1007/s10596-021-10107-5
Received:
Accepted:
Published:
Issue Date:
DOI: https://doi.org/10.1007/s10596-021-10107-5