Dam-break problem (3D, Adaptive mesh)

Update: July 10, 2017
OpenFOAM 4.x

Case directory

$FOAM_TUTORIALS/multiphase/interDyMFoam/ras/damBreakWithObstacle

Summary

Model geometry Model geometry

We calculate the dam-break problem (collapse of the water column) in a space with a cubic obstacle at the bottom for 2 seconds. Only a Y-maximum face of the analysis domain is assumed to be open, while the other faces are walls. The mesh is dynamically refined during the calculation to improve the accuracy of the air-liquid interface calculation (adaptive mesh refinement).

The settings for mesh refinement are specified in the file "constant/dynamicMeshDict" as follows.

dynamicFvMesh   dynamicRefineFvMesh;

dynamicRefineFvMeshCoeffs
{
    // How often to refine
    refineInterval  1;

    // Field to be refinement on
    field           alpha.water;

    // Refine field inbetween lower..upper
    lowerRefineLevel 0.001;
    upperRefineLevel 0.999;

    // If value < unrefineLevel unrefine
    unrefineLevel   10;

    // Have slower than 2:1 refinement
    nBufferLayers   1;

    // Refine cells only up to maxRefinement levels
    maxRefinement   2;

    // Stop refinement if maxCells reached
    maxCells        200000;

    // Flux field and corresponding velocity field. Fluxes on changed
    // faces get recalculated by interpolating the velocity. Use 'none'
    // on surfaceScalarFields that do not need to be reinterpolated.
    correctFluxes
    (
        (phi none)
        (nHatf none)
        (rhoPhi none)
        (alphaPhi none)
        (ghf none)
    );

    // Write the refinement level as a volScalarField
    dumpLevel       true;
}

Initially, the mesh is uniform and the number of meshes is 32256. During the calculation, the mesh is dynamically refined so that it becomes finer near the liquid surface.

The calculation result is as follows.

Surface of water volume ratio 0.5
Surface of water volume ratio 0.5 and mesh cross section at initial time Surface of water volume ratio 0.5 and mesh cross section at initial time
Surface of water volume ratio 0.5 and mesh cross section at 0.4 sec Surface of water volume ratio 0.5 and mesh cross section at 0.4 sec

We can see that the mesh is dynamically refined so that it becomes finer near the liquid surface.

Commands

cp -r $FOAM_TUTORIALS/multiphase/interDyMFoam/ras/damBreakWithObstacle damBreakWithObstacle
cd damBreakWithObstacle

cp -r 0.orig 0
blockMesh
topoSet
subsetMesh -overwrite c0 -patch walls
setFields

interDyMFoam

paraFoam

Calculation time

5 hours 54 minutes 6.1 seconds *Single, Inter(R) Core(TM) i7-2600 CPU @ 3.40GHz 3.40GHz