@@ -15,10 +15,10 @@ Free flow is modeled in the upper subdomain, while the lower subdomain models a
There are three sub folders: `interface` (Exercise 1), `models` (Exercise 2) and `turbulence` (Exercise 3).
The problem-related files for this exercise are:
* Three __main files__ for the three sub-tasks :`exerciseinterfacecouplingffpm.cc`, `exercisemodelscouplingffpm.cc`, `exerciseturbulencecouplingffpm.cc`,
* Three __free flow problem files__: `interfaceffproblem.hh`, `modelsffproblem.hh`, `turbulenceffproblem.hh`
* Three __porous medium flow problem files__: `interfacepmproblem.hh`, `modelspmproblem.hh`, `turbulencepmproblem.hh`
* The __input files__: `exercise_interface_coupling_ff-pm.input`, `exercise_models_coupling_ff-pm.input`, `exercise_turbulence_coupling_ff-pm.input`,
* Three __main files__ for the three sub-tasks :`interface/main.cc`, `models/main.cc`, `turbulence/main.cc`,
* Three __free flow problem files__: `interface/freeflowsubproblem.hh`, `models/freeflowsubproblem.hh`, `turbulence/freeflowsubproblem.hh`
* Three __porous medium flow problem files__: `interface/porousmediumsubproblem.hh`, `models/porousmediumsubproblem.hh`, `turbulence/porousmediumsubproblem.hh`
* The __input files__: `interface/params.input`, `models/parmas.input`, `turbulence/params.input`,
* The __spatial parameters files__: `1pspatialparams.hh`, `2pspatialparams.hh`
...
...
@@ -27,8 +27,8 @@ The same applies for types such as `GridManager`, `FVGridGeometry`, `Problem`, e
Since we use a monolithic coupling scheme, there is only one `Assembler` and one `NewtonSolver`.
The problem files very much look like "regular", uncoupled ones with the exception that they hold a pointer to the `CouplingManager` which allows to evaluate the coupling conditions and to exchange information between the coupled models.
The coupling conditions are realized technically in terms of boundary condition. For instance, in lines 178 and 179
in `ex_interface_ffproblem.hh`, `couplingNeumann` boundary conditions are set, which means that the free flow models evaluates the
The coupling conditions are realized technically in terms of boundary condition. For instance,
in `interface/freeflowsubproblem.hh`, `couplingNeumann` boundary conditions are set, which means that the free flow models evaluates the
mass and momentum fluxes coming from the porous domain and uses these values as boundary conditions at the interface.
Note the certain checks are performed when combining different models, e.g., the fluid system has to be the same for both domains
...
...
@@ -57,7 +57,7 @@ Currently, a velocity profile is set on the upper free flow boundary, which lead
__Task A: Change the flow direction__
Open the file `ex_interface_ffproblem.hh` and navigate to line 148, where the types of boundary condition are set.
Open the file `interface/freeflowsubproblem.hh` and navigate to the part, where the types of boundary condition are set.
Instead of applying a fixed velocity profile at the top of the domain, we want to use fixed pressure boundary conditions
at the left and right side of the free flow domain, while the top represents an impermeable wall.
...
...
@@ -134,10 +134,10 @@ with a Beavers-Joseph-Saffman (BJS) boundary condition for the respective moment
values.setBJS(Indices::momentumXBalanceIdx);
```
at the position where the coupling boundary conditions are set in `ex_interface_ffproblem.hh`.
at the position where the coupling boundary conditions are set in `interface/freeflowsubproblem.hh`.
To check if the simulation behaves as expected, we can compare the velocity profile $`v_x(y)`$ with the analytical solution provided by [Beavers and Joseph (1967)](https://doi.org/10.1017/S0022112067001375).
For doing so, we uncomment line 212 in `ex_interface_coupling_ff-pm.cc`.
For doing so, we uncomment line 212 in `exerciseinterfacecouplingffpm.cc`.
@@ -148,7 +148,7 @@ the analytical solution of $`v_x`$ on the free flow domain. Play around with the
__Task C: Cange shape of interface__
Now we want to include a non-flat interface between the two domains. We use `dune-subgrid` to construct
two grids for the two domains from one common host grid. Comment out lines 96-106 in `ex_interface_coupling_ff-pm.cc` and comment lines 114-149 in the same file. This will instantiate a host grid and define two helper lambda functions that are used to choose elements from to host grid for the respective sub grid. In the given case,
two grids for the two domains from one common host grid. Comment out lines 96-106 in `exerciseinterfacecouplingffpm.cc` and comment lines 114-149 in the same file. This will instantiate a host grid and define two helper lambda functions that are used to choose elements from to host grid for the respective sub grid. In the given case,
the domain is split in two haves, separated by a sinusoidal interface.
```cpp
...
...
@@ -167,7 +167,7 @@ auto elementSelectorDarcy = [&](const auto& element)
Make sure, that you have uncommented the lines including the grid managers in both problem files
```cpp
#include<dumux/io/grid/subgridmanager.hh>
#include<dumux/io/grid/gridmanager_sub.hh>
```
and do the changes in the respective lines for the `Grid` property.
...
...
@@ -216,7 +216,7 @@ __Task A: Change the model__:
In the first task, the porous-medium model will be changed from a 1p2c system to a 2p2c system.
Although a 2p2c system is plugged in, we still want to simulate the same situation as before, i.e., air with water vapor in both domains.
The following changes have to be made in the porous-medium model (`ex_models_pmproblem.hh`):
The following changes have to be made in the porous-medium model (`models/porousmediumsubproblem.hh`):
* Include the 2pnc model: include the respective headers and inherit from the new model `TwoPNC`
* Exchange the spatial parameters for the 1-phase system by those for a 2-phase system (hint: two occurrences).
* Since two phases are involved now, we do not need to use the OnePAdapter anymore. Change to property of the FluidSystem such that `H2OAir` is used directly.
...
...
@@ -314,7 +314,7 @@ All the prepared files can be found in the subfolder `exercise-coupling-ff-pm/tu
__Task A__:
The file `ex_turbulence_ffproblem.hh` is your free flow problem file within this exercise.
The file `freeflowsubproblem.hh` is your free flow problem file within this exercise.
For using the compositional zero equation turbulence model, the following header files need to be included:
```
...
...
@@ -347,7 +347,7 @@ To get all these interactions, you have to call
```cpp
stokesProblem->updateStaticWallProperties();
```
in `ex_turbulence_coupling_ff-pm.cc`.
in `main.cc`.
However, there is also a solution-dependent component of these interactions, e.g. for a correct
damping of the eddy viscosity toward the wall, the velocity gradient at the wall and inside the