fvOptions: The "<type>Coeffs" sub-dictionary is now optional

For example the actuationDiskSource fvOption may now be specified

disk1
{
    type            actuationDiskSource;

    fields      (U);

    selectionMode   cellSet;
    cellSet         actuationDisk1;
    diskDir         (1 0 0);    // Orientation of the disk
    Cp              0.386;
    Ct              0.58;
    diskArea        40;
    upstreamPoint   (581849 4785810 1065);
}

rather than

disk1
{
    type            actuationDiskSource;
    active          on;

    actuationDiskSourceCoeffs
    {
        fields      (U);

        selectionMode   cellSet;
        cellSet         actuationDisk1;
        diskDir         (1 0 0);    // Orientation of the disk
        Cp              0.386;
        Ct              0.58;
        diskArea        40;
        upstreamPoint   (581849 4785810 1065);
    }
}

but this form is supported for backward compatibility.
This commit is contained in:
Henry Weller
2017-04-13 13:30:17 +01:00
parent e9ba8242ca
commit 8b55ea4fb1
39 changed files with 383 additions and 529 deletions

View File

@ -18,15 +18,11 @@ FoamFile
momentumSource
{
type meanVelocityForce;
active yes;
meanVelocityForceCoeffs
{
selectionMode all;
selectionMode all;
fields (U);
Ubar (0.1335 0 0);
}
fields (U);
Ubar (0.1335 0 0);
}

View File

@ -18,19 +18,15 @@ FoamFile
momentumSource
{
type vectorSemiImplicitSource;
active yes;
vectorSemiImplicitSourceCoeffs
timeStart 0.0;
duration 1000;
selectionMode all;
volumeMode specific;
injectionRateSuSp
{
timeStart 0.0;
duration 1000;
selectionMode all;
volumeMode specific;
injectionRateSuSp
{
U ((5 0 0) 0);
}
U ((5 0 0) 0);
}
}

View File

@ -50,13 +50,7 @@ IOdictionary fvOptions
)
);
const dictionary& gradPDict =
fvOptions.subDict("momentumSource").subDict
(
"vectorSemiImplicitSourceCoeffs"
).subDict
(
"injectionRateSuSp"
);
fvOptions.subDict("momentumSource").subDict("injectionRateSuSp");
const scalar K =
Tuple2<vector, scalar>(gradPDict.lookup("U")).first().x();