uniformDensityHydrostaticPressureFvPatchScalarField: Require value entry for post-processing

This commit is contained in:
Henry Weller
2018-04-04 13:10:28 +01:00
parent b17c0e3fa1
commit 53e9706f7e
2 changed files with 8 additions and 19 deletions

View File

@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation
\\ / A nd | Copyright (C) 2011-2018 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@ -54,23 +54,11 @@ uniformDensityHydrostaticPressureFvPatchScalarField
const dictionary& dict
)
:
fixedValueFvPatchScalarField(p, iF, dict, false),
fixedValueFvPatchScalarField(p, iF, dict, true),
rho_(readScalar(dict.lookup("rho"))),
pRefValue_(readScalar(dict.lookup("pRefValue"))),
pRefPoint_(dict.lookup("pRefPoint"))
{
if (dict.found("value"))
{
fvPatchField<scalar>::operator=
(
scalarField("value", dict, p.size())
);
}
else
{
evaluate();
}
}
{}
Foam::uniformDensityHydrostaticPressureFvPatchScalarField::

View File

@ -47,9 +47,10 @@ Description
Usage
\table
Property | Description | Required | Default value
rho | uniform density [kg/m3] | yes |
pRefValue | reference pressure [Pa] | yes |
pRefPoint | reference pressure location | yes |
rho | Uniform density [kg/m3] | yes |
pRefValue | Reference pressure [Pa] | yes |
pRefPoint | Reference pressure location | yes |
value | Initial value | yes |
\endtable
Example of the boundary condition specification:
@ -60,7 +61,7 @@ Usage
rho rho;
pRefValue 1e5;
pRefPoint (0 0 0);
value uniform 0; // optional initial value
value uniform 0; // Required initial value
}
\endverbatim