Scalable hybrid framework for geothermal simulation

Various novel computing architectures, like massively parallel and multi-core, as well as computing accelerators, like GPUs or TPUs, continue to emerge regularly. In order to harvest the performance benefits of these architectures to the full extent and speed up the simulation, the source code has to be inevitably rewritten, sometimes almost completely. The biggest challenge here in terms of complexity, variety and size is linearization procedure since it depends on the governing equations, choice of primary unknowns, physical/chemical phenomena taken into account, and other factors. In this project, we demonstrate how to extract complex physics-related computations from the main simulation loop, leaving only an algebraic multilinear interpolation kernel instead.

The key element here is operator-based linearization (OBL)1. The state-based terms of governing equations are parametrized in the physical space of the problem forming dynamically expanding lookup tables. These tables are used in linearization to approximate operators along with derivatives with respect to governing unknowns using piecewise multilinear interpolation in physical space. Typical representation of operator in 2D parameter-space (pressure-composition).

The method not only significantly reduces the amount of property-related computations, but detaches physics and simulation kernels. In combination with linear solvers, which usually have made available soon once the new architecture is introduced, the approach accommodates execution of the entire nonlinear loop on the latest hardware and computational architectures2. The balance between the accuracy and performance is managed via the approximation error of physical description. Time spent on linerization of 3-component compositional run in full SPE10 (728 nonlinear iterations).

The framework is implemented in C++11 and exposed into Python coupling the flexibility of the script language with the performance of C++. Moreover, particular framework components can be extended in Python and still be involved in the C++ simulation process. In addition, all fluid / rock properties, involved in the computation of state operators, can be derived in Python without serious impact on overall simulation performance thanks to OBL. The integrated simulation framework exploits the approach to provide the flexible, modular, computationally efficient modeling package for various applications, including geothermal3, thermal-compositional4, and reactive compositional problems5.



Thermal flow and transport with dissolution

Increasing demand for geothermal energy in the Netherlands has led to the investigation of high enthalpy carbonate reservoirs, located in the Lower Carboniferous (Dinantian carbonates). Pilot projects have encountered heavily karstified reservoir intervals during the drilling process, resulting in unpredicted hazards. The origin of the karst has been interpreted as a combination of epigenic and hypogenic processes6. Predicting the spatial distribution of hypogenic caves and other discontinuity networks in the subsurface is currently in an underdeveloped state, mainly due to our inability to obtain images of the subsurface at sufficient resolution but also due to the high complexity of the system (interplay between chemical, mechanical, and flow processes).

This project mainly focusses on the development of a reactive transport module for DARTS, in particular on the implementation of the Element Based Formulation5 and fully unstructured discretization methods for (naturally) fractured reservoirs7.
Preliminary results on dissolution patterns in carbonates, obtained with the Reactive Transport and unstructured discretization modules in DARTS.

The next steps of this research are on combining three methods: 1) large-scale high-resolution outcrop data, acquired with a Mobile Mapping System (handheld LiDAR); 2) small-scale laboratory experiments studying the interplay between dissolution of the fracture plane under mechanical stress; 3) integrating this in numerical models acquired with DARTS simulation framework. This will lead to improved predictions on the spatial distribution of karst and other discontinuity networks in the subsurface.
Comparison between the High-Resolution LiDAR point cloud data set and color photographs (from inside the cave systems).



Flow and reactive transport in high-enthalpy geothermal systems

This project will focus on the phase-transition induced nonlinear flow problem, in combination with chemical reactions, within high-enthalpy geothermal systems. In comparison with low-enthalpy geothermal systems limited to a production of hot water, the obvious features of high-enthalpy systems are significantly higher temperature and steam (or water-steam) dominated physical behaviors. A phase transition is happening due to the heat exchange between the injected cold water and in-situ rock/fluid. In addition, the chemical equilibrium, present in the original reservoir, may be disturbed by both the fluid transport and reaction with injected water containing different temperature and chemical species which can become complicated by a liquid-vapor phase transition with salt dissolution and precipitation.

Because of phase transition and the large variation in thermo-dynamic properties between liquid water and steam, the nonlinear numerical solution of governing equations in fully-implicit approximation can experience difficulties commonly known as ‘negative compressibility’.
Convergence map using Newton update.

A multi-level physics parameterization approach is proposed to solve this problem within Operator-Based Linearization (OBL) framework1. In the OBL approach, the continuous operators in the covering equations, related to different physical mechanisms (e.g. convection or conduction), are translated into multi-dimensional tables. In the course of a simulation, only the supporting points are evaluated based on the reference physics while points between them are interpolated. The coarser the physics is, the more linear the operators become. In our continuation approach, we start with the coarse approximation of the governing physics in pressure-enthalpy parameter-space. Due to a more linear form of operators, only a few nonlinear iterations reduce residual below the predefined tolerance. Next, the OBL approximation is modified towards the reference nonlinear physics and a few more iterations bring the residual below the tolerance again. With the refinement in physics, the solution will gradually approach the final results where residual will satisfy the convergence criteria of the reference physics.
Convergence map using OBL continuation.

The proposed continuation approach avoids the negative compressibility phenomena since the problem at coarser approximation has a unique gradient pointing towards the correct solution. The proposed method is unconditionally stable as can be seen in the figure below. As a result, simulation can perform at larger timesteps in comparison to the traditional Newton-based nonlinear solution. Convergence map for regular initial guesses in OBL-contunuity (left) and conventional Newton (right) solvers.




Modeling of variation in liquid mobility in foam EOR

Liquid injectivity directly following foam is very poor. Liquid first fingers through the trapped foam. It then dissolves gas trapped within the fingers, and overall mobility rises sharply. During prolonged gas injection following foam, however, a region forms near the inlet and slowly propagates downstream in which gas mobility is much greater. The abrupt rise in gas mobility appears to reflect a significant decline in water saturation. This decline reflects in part liquid evaporation, and also pressure-driven flow and capillary effects on the core scale. In this region, the mobility of subsequently injected liquid is much greater than downstream, and liquid sweeps the entire core cross-section rather than a single finger. Mobility in the region of liquid fingering is insensitive to the quality of foam injected before gas and the duration of the period of gas injection. These results suggest that there is a small region very near the well, crucial to overall injectivity, in which liquid mobility is much greater than that further from the well. Foam injection experimental results8.

This project aims to predictive modeling of this phenomena. An accurate model should be constructed at a continuous core scale and incorporate all important phenomena - phase behavior in the gas-brine system, effective foam model, surfactant model with shear-thinning rheology etc. Once the model is constructed, it will be implemented in DARTS framework with all important governing properties. This model will be compared with experiments and used as an initial guess for a data-driven OBL-based model. Next, the OBL model will be regressed to the experimental data and serve as a platform for numerical upscaling to the reservoir (field) scale.



Dynamic simulation of the geothermal well performance

Recently, the innovative idea of the geothermal well with the composite well has been proposed. There are significant advantages that composite well can bring to the industry including lower installation cost, resistance to corrosion, and the transparency for monitoring the near well area. Despite this, the long term exploitation of this casing may introduce additional risks and uncertainties, mechanical deformation and chemical interactions with the fluid and the reservoirs. In addition, the hydrocarbon co-production lead to the multiphase flow in the well which can have a strong impact on the performance of reservoirs and surface facilities.

In order to use such technologies intelligently, it requires a robust model to capture efficiently the above-mentioned physics in the well. We will design a numerical framework for predictive simulation and monitoring of geothermal wells taking into account, thermal, hydraulic, mechanical and chemical interactions coupled with the flow in a wellbore and near wellbore porous media. This framework will be based on the farther enhanced multi-segmented well model originated from petroleum-related reservoir simulation.



References:

  1. Voskov, D.V, 2017. Operator-based linearization approach for modeling of multiphase multi-component flow in porous media, Journal of Computational Physics, 337, 275-288. doi:10.1016/j.jcp.2017.02.041
  2. Khait, M., D. Voskov, 2017. GPU-offloaded general-purpose simulator for multiphase flow in porous media, SPE Reservoir Simulation Conference, pp. 1293-1302. doi:10.2118/182663-MS
  3. Khait M., D. Voskov, 2018. Operator-based linearization for efficient modeling of geothermal processes, Geothermics, 74, 7-18. doi:10.1016/j.geothermics.2018.01.012
  4. Khait, M., D. Voskov, 2018. Adaptive parameterization for solving of thermal/compositional nonlinear flow and transport with buoyancy, SPE Journal, 23 (2), pp. 522-534. doi:10.2118/182685-PA
  5. Kala, K., D. Voskov, 2018. Parameterization of element balance formulation in reactive compositional flow and transport, 16th European Conference on the Mathematics of Oil Recovery, ECMOR. doi:10.3997/2214-4609.201802113
  6. Reijmer, J. J., Johan, H., Jaarsma, B., & Boots, R. (2017). Seismic stratigraphy of dinantian carbonatesin the southern netherlands and northern belgium.Netherlands Journal of Geosciences,96(4),353–379. doi:10.1017/njg.2017.33
  7. Karimi-Fard, M., Durlofsky, L. J., & Aziz, K. (2003, January). An efficient discrete fracture model applicable for general purpose reservoir simulators. In SPE Reservoir Simulation Symposium. Society of Petroleum Engineers. doi:10.2118/79699-MS
  8. Gong J., Vincent-Bonnieu S., Kamarul Bahrim R., Groenenboom J., Farajzadeh R., Rossen W. (2018) Modelling of liquid injectivity in surfactant-alternating-gas foam enhanced oil recovery. In SPE EOR Conference at Oil and Gas West Asia. Society of Petroleum Engineers, 2018. doi:10.2118/190435-MS