View Issue Details

IDProjectCategoryView StatusLast Update
0003667OpenFOAMBugpublic2021-04-27 20:29
ReporterTobermory Assigned Tohenry  
PrioritylowSeverityminorReproducibilityalways
Status closedResolutionsuspended 
PlatformAllOSAllOS VersionAll
Summary0003667: Dam break tutorial pressure initialisation
DescriptionThe dam break tutorial is set up to initialise with a zero p_rgh field, but without an hRef entry in the constant folder. This means that the pressure field is calculated as zero at the foot of the water column (where it should be the pressure equivalent to the hydrostatic weight of the column), and ~-2800Pa at the top of the column (where it should be zero) - see the attached pic.

The hRef offset needs to be set at the initial height of water column, i.e.:

/*--------------------------------*- C++ -*----------------------------------*\
  ========= |
  \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
   \\ / O peration | Website: https://openfoam.org
    \\ / A nd | Version: 8
     \\/ M anipulation |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version 2.0;
    format ascii;
    class uniformDimensionedScalarField;
    location "constant";
    object hRef;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

dimensions [0 1 0 0 0 0 0];
value 0.290476; //chosen to match the height of the initial water column

// ************************************************************************* //

and then the pressure field is correct - see the second attached pic. The change will probably have minimal impact on the ensuing solution, but it avoids the nonsense looking condition at t=0.
Steps To ReproduceJust run the tutorial, as is.
TagsNo tags attached.

Activities

Tobermory

2021-04-27 18:22

reporter  

current-p.png (17,801 bytes)   
current-p.png (17,801 bytes)   
fixed-p.png (17,907 bytes)   
fixed-p.png (17,907 bytes)   

henry

2021-04-27 20:06

manager   ~0012002

This is not an ideal solution, our plan is to implement a more general initialisation step for all p_rgh solvers but we need further funding for this work.

Tobermory

2021-04-27 20:15

reporter   ~0012003

Okay - understood. Please close out the issue then.

henry

2021-04-27 20:29

manager   ~0012004

Pending funding for a more general solution.

Issue History

Date Modified Username Field Change
2021-04-27 18:22 Tobermory New Issue
2021-04-27 18:22 Tobermory File Added: current-p.png
2021-04-27 18:22 Tobermory File Added: fixed-p.png
2021-04-27 20:06 henry Note Added: 0012002
2021-04-27 20:15 Tobermory Note Added: 0012003
2021-04-27 20:29 henry Assigned To => henry
2021-04-27 20:29 henry Status new => closed
2021-04-27 20:29 henry Resolution open => suspended
2021-04-27 20:29 henry Note Added: 0012004