OpenPNM: A Pore Network Modeling Package - Gostick, Jeff; Burns, Alan; Lehnert, Werner; Putz, Andreas; Aghighi, Mahmoudreza; Hinebaugh, James; Tranter, Tom; Hoeh, Michael A.; Day, Harold; Spellacy, Brennan; Sharqawy, Mostafa H.; Bazylak, Aimy (Computing in science & engineering, 2016)
Pore network modeling is a widely used technique for simulating multiphase transport in porous materials, but there are very few software options available. This work outlines the OpenPNM package that was jointly developed by several porous media research groups to help address this gap. OpenPNM is written in Python using NumPy and SciPy for most mathematical operations, thus combining Python's ease of use with the performance necessary to perform large simulations. The package assists the user with managing and interacting with all the topological, geometrical, and thermophysical data. It also includes a suite of commonly used algorithms for simulating percolation and performing transport calculations on pore networks. Most importantly, it was designed to be highly flexible to suit any application and be easily customized to include user-specified pore-scale physics models. The framework is fast, powerful, and concise. An illustrative example is included that determines the effective diffusivity through a partially water-saturated porous material with just 29 lines of code.