The new optional 'slash' scoping syntax is now the default and provides a more
intuitive and flexible syntax than the previous 'dot' syntax, corresponding to
the common directory/file access syntax used in UNIX, providing support for
reading entries from other dictionary files.
In the 'slash' syntax
'/' is the scope operator
'../' is the parent dictionary scope operator
'!' is the top-level dictionary scope operator
Examples:
internalField 3.4;
active
{
type fixedValue;
value.air $internalField;
}
inactive
{
type anotherFixedValue;
value $../active/value.air;
anotherValue $!active/value.air;
sub
{
value $../../active/value.air;
anotherValue $!active/value.air;
}
}
"U.*"
{
solver GAMG;
}
e.air
{
$U.air;
}
external
{
value $testSlashDict2!active/value.air;
}
active2
{
$testSlashDict2!active;
}
If there is a part of the keyword before the '!' then this is taken to be the
file name of the dictionary from which the entry will be looked-up using the
part of the keyword after the '!'. For example given a file testSlashDict containing
internalField 5.6;
active
{
type fixedValue;
value.air $internalField;
}
entries from it can be read directly from another file, e.g.
external
{
value $testSlashDict2!active/value.air;
}
active2
{
$testSlashDict2!active;
}
which expands to
external
{
value 5.6;
}
active2
{
type fixedValue;
value.air 5.6;
}
These examples are provided in applications/test/dictionary.
The the default syntax can be changed from 'slash' to 'dot' in etc/controlDict
to revert to the previous behaviour:
OptimisationSwitches
{
.
.
.
// Default dictionary scoping syntax
inputSyntax slash; // Change to dot for previous behaviour
}
or within a specific dictionary by adding the entry
See applications/test/dictionary/testDotDict.
Overview ======= + This is a template case for a closed volume + Setup to run buoyantSimpleFoam + The case is designed to be meshed with snappyHexMesh + snappyHexMesh is setup to use a single trisurface file named CAD.obj + Copy the CAD.obj file to the constant/triSurface directory + The CAD.obj can contain one or more regions to create patches in the mesh + The user can then specify different boundary condition on T on these patches Meshing ======= + Meshing is setup as in the inflowOutflow template + See $FOAM_ETC/templates/inflowOutflow/README for details + The setup includes an example for one named patch to be generated in the mesh + In snappyHexMeshDict, replace <CADregionName> with the name of region in the trisurface; replace <patchName> with the name of the resulting mesh patch Initialisation ============== + In the field files in the 0 directory, set initial values + The template includes a fixedValue boundary condition on <patchName> in 0/T + The user can replace <patchName> with a real mesh patch name and apply a fixed temperature on that patch