Python-Based Tools for Modeling Transport in Porous Media Columns

Boyang Lu and David Lampert

Volume 14, Issue 1 (July 2023), pp. 8–16

PDF icon Download PDF

  author={Boyang Lu and David Lampert},
  title={Python-Based Tools for Modeling Transport in Porous Media Columns},
  journal={The Journal of Computational Science Education},
Copied to clipboard!

The fate and transport of dissolved constituents in porous media has important applications in the earth and environmental sciences and many engineering disciplines. Mathematical models are commonly applied to simulate the movement of substances in porous media using the advection-dispersion equation. Whereas computer programs based on numerical solutions are commonly employed to solve the governing equations for these problems, analytical solutions also exist for some important one-dimensional cases. These solutions are often still quite complex to apply in practice, and therefore computational tools are still needed to apply them to determine the concentrations of dissolved substances as a function of space and time. The Python Programming Language provides a variety of tools that enable implementation of analytical solutions into useful tools and facilitate their application to experimental data. Python provides an important but underutilized tool in environmental modeling courses. This article highlights the development of a series of Python-based computing tools that can be used to numerically compute the values of an analytical solution to the onedimensional advection-dispersion equation. These tools are targeted to graduate and advanced undergraduate courses that teach environmental modeling and the application of Python for computing.