Simulating flow through rocks at unprecedented scale
9 June 2026
Researchers at EPCC and Heriot-Watt University have published a paper in the Journal of Computational Science, demonstrating scalable CFD simulations on multi-billion voxel micro-CT images of porous materials using OpenFOAM on ARCHER2. This enables pore-scale simulations at a scale that was previously computationally out of reach.
Above: Pressure distribution inside the cylindrical core samples, shown by cropping the top-right quadrant to reveal internal fields. (a) Bentheimer and (b) Estaillades.
EPCC's Gavin Pringle describes the work that led to the newly published paper Scalable CFD simulations in multi-billion voxel micro-CT images of porous materials using OpenFOAM on ARCHER2.
The work, carried out in collaboration with Dr Julien Maes and Dr Hannah Menke at Heriot-Watt University's Institute of GeoEnergy Engineering, was funded through ARCHER2's Embedded CSE (eCSE) programme.
Central to the research is GeoChemFoam, the world's most advanced open source pore-scale numerical simulator, built on top of OpenFOAM. Developed at Heriot-Watt University, GeoChemFoam simulates heat transfer, multiphase flow, and reactive transport in porous media, with applications in hydrogen storage, CO₂ capture and storage, fuel cells, geothermal energy, and contaminant transport. The goal of this eCSE project was to substantially extend the scalability of GeoChemFoam and, indeed, OpenFOAM, and then to make GeoChemFoam available on ARCHER2.
The challenge
Porous materials research increasingly relies on 3D X-ray micro-CT imaging to capture a material's pore structure at micron-scale resolution, with CFD simulations then run directly on these images. The computational challenge is considerable: a single micro-CT image can contain billions of voxels, and the mesh generation and pre-processing steps in OpenFOAM were inherently serial, i.e. constrained to a single core and by the memory of one node. This forced researchers to work on small sub-volumes or coarser representations, risking significant errors when extrapolating to the full domain. In heterogeneous rock samples, for instance, permeability estimates based on a sub-region can be drastically unrepresentative of the whole.
Parallelising the inherently serial
My own contribution was to tackle these serial bottlenecks directly. Two key OpenFOAM routines, namely blockMesh and decomposePar, were substituted with Python-based tooling developed to decompose and distribute large micro-CT datasets across many cores and to exploit the aggregate memory of ARCHER2's nodes.
The outcome is a workflow capable of running CFD simulations on multi-billion voxel domains: jobs that were simply intractable before. Importantly, the implementation is entirely general: it is not hard-coded to rock or geoscience data, and can be applied to any volumetric porous material dataset.
Impact
The ability to run high-fidelity pore-scale simulations at this scale has broad implications. In energy and environmental research, it enables more confident modelling of CO₂ sequestration, hydrogen storage, and subsurface flow. In materials science, it opens up detailed simulation of concrete, stone, and construction materials for durability assessment. Chemical engineers can apply the tools to catalyst and filter design, while biomedical researchers can model fluid transport in tissue scaffolds and biomaterial implants.
Beyond individual disciplines, the project demonstrates the wider return on investment that eCSE-style HPC software development can deliver: solving a fundamental scalability problem in OpenFOAM in a way that benefits a broad user community.
This work was funded under the Embedded CSE (eCSE) programme of the ARCHER2 UK National Supercomputing Service (project ARCHER2-eCSE10-2).
Read more
Paper
GeoChemFoam on ARCHER2
GeoChemFoam v5.1, along with a 64-bit version of OpenFOAM, is now centrally available on ARCHER2. Full documentation is available on the GeoChemFoam wiki. Further details are available in the ARCHER2 eCSE10-02 technical report and the ARCHER2 Research Case Study.