|
| 1 | +--- |
| 2 | +title: Free flow over porous media 2D |
| 3 | +permalink: tutorials-free-flow-over-porous-media-2d.html |
| 4 | +keywords: DuMux, porous media |
| 5 | +summary: Flow-flow coupling example with porous media field and free flow field. |
| 6 | +--- |
| 7 | + |
| 8 | +{% note %} |
| 9 | +Get the [case files of this tutorial](https://github.com/precice/tutorials/tree/master/free-flow-over-porous-media-2d). Read how in the [tutorials introduction](https://precice.org/tutorials.html). |
| 10 | +{% endnote %} |
| 11 | + |
| 12 | +## Setup |
| 13 | + |
| 14 | +This tutorial solves a coupled system consisting of a one-phase free flow and a one-phase flow in a porous media. |
| 15 | + |
| 16 | +A pressure gradient is applied to the free flow domain from left to right. The top edge of the free-flow is a non-permeable wall with no-slip boundary conditions. In the porous media, there is a no-flow condition across the domain boundaries (left, bottom, and right boundaries). At the interface, a no-slip condition applies. The case is stationary (solved to a steady-state solution). |
| 17 | + |
| 18 | +The setting is illustrated in the following figure: |
| 19 | + |
| 20 | + |
| 21 | + |
| 22 | +## Configuration |
| 23 | + |
| 24 | +preCICE configuration (image generated using the [precice-config-visualizer](https://precice.org/tooling-config-visualization.html)): |
| 25 | + |
| 26 | + |
| 27 | + |
| 28 | +## Available solvers |
| 29 | + |
| 30 | +Both the participants are computed using the simulation code [DuMu<sup>x</sup>](https://git.iws.uni-stuttgart.de/dumux-repositories/dumux/). |
| 31 | + |
| 32 | +## Solver setup |
| 33 | + |
| 34 | +To solve the flows with the DuMux framework, the necessary DUNE modules need to be downloaded and set up. This is done by running `sh setup-dumux.sh` in the tutorial folder. |
| 35 | + |
| 36 | +Note that if an existing installation of DUNE modules is detected in a default location, this may lead to problems in running the `setup-dumux.sh` script. The script suppresses the environment variable `DUNE_CONTROL_PATH`. |
| 37 | + |
| 38 | +To only recompile the participants, run `sh compile-dumux-cases.sh` in the tutorial folder. |
| 39 | + |
| 40 | +## Running the simulation |
| 41 | + |
| 42 | +Each participant has a `run.sh` script. |
| 43 | + |
| 44 | +To run the free-flow participant, run: |
| 45 | + |
| 46 | +```bash |
| 47 | +cd free-flow-dumux |
| 48 | +./run.sh |
| 49 | +``` |
| 50 | + |
| 51 | +To run the porous-media participant, run: |
| 52 | + |
| 53 | +```bash |
| 54 | +cd porous-media-dumux |
| 55 | +./run.sh |
| 56 | +``` |
| 57 | + |
| 58 | +Participants can be executed only in serial. Parallel execution is not supported. The case takes approximately two minutes to finish. |
| 59 | + |
| 60 | +## Post-processing |
| 61 | + |
| 62 | +Both participants write VTU outputs, which can be viewed using ParaView. |
| 63 | + |
| 64 | +## Further information |
| 65 | + |
| 66 | +The results of the pressure and the velocity fields are as follows: |
| 67 | + |
| 68 | + |
| 69 | + |
| 70 | + |
| 71 | +Each solver folder contains an input file (`params.input`) that will be passed to the solver executables. This is a DuMUX input file describing the simulation setting, e.g., pressure, mesh size, time stepping, etc. |
0 commit comments