Integral evaluations have been implemented for all the ramp function1-s,
as well as the sine and square wave. Bounds handling has also been added
to the integration of table-type functions.
In addition, the sine wave "t0" paramater has been renamed "start" for
consistency with the ramp functions.
The general distribution has been extended to accept cumulative
distribution data, by means of a "cumulative" switch. The calculation of
the mean value has also been corrected for this distribution, and
additional header documentation and parameter checking has been added.
In addition, the distribution models now all print some basic
information (min, max and mean) into the log file to help in checking
that the specification is correct.
Patch contributed by Timo Niemi, VTT.
In order to avoid conflict with the use of ':' in model-specific fields,
e.g. "thermo:rho", in the "slash" syntax the '!' character is now used to refer
to the top-level dictionary.
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 dictionary file named testSlashDict2:
internalField 5.6;
active
{
type fixedValue;
value.air $internalField;
}
it is now possible to read entries from it directly in the dictionary file testSlashDict:
external
{
value $testSlashDict2!active/value.air;
}
active2
{
$testSlashDict2!active;
}
which expands to
external
{
value 5.6;
}
active2
{
type fixedValue;
value.air 5.6;
}
A new optional "slash" scoping syntax is now provided which is more intuitive
than the current "dot" syntax as it corresponds to the common directory/file
access syntax used in UNIX, and avoids limitations of the "dot" (see below)
e.g.
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
{
// This does expand
$U.air;
}
"#inputSyntax slash;" selects the new "slash" syntax.
"../" refers to the parent directory.
":" refers to the top-level directory.
The corresponding dictionary using the current "dot" syntax is
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
{
// This doesn't expand
$U.air;
}
Note that the "$U.air" expansion does not work in this case due to the
interference between the use of '.' for scoping and phase-name.
This is a fundamental problem which prompted the development of the new more
intuitive and flexible "slash" syntax.
The new syntax also allows a for planned future development to access entries
in directories in other files, e.g.
active
{
type fixedValue;
value.air $FOAM_CASE/internalFieldValues/value.air;
}
or
active
{
type fixedValue;
value.air :../internalFieldValues/value.air;
}
Currently these deleted function declarations are still in the private section
of the class declarations but will be moved by hand to the public section over
time as this is too complex to automate reliably.
Replaced all uses of complex Xfer class with C++11 "move" constructors and
assignment operators. Removed the now redundant Xfer class.
This substantial changes improves consistency between OpenFOAM and the C++11 STL
containers and algorithms, reduces memory allocation and copy overhead when
returning containers from functions and simplifies maintenance of the core
libraries significantly.
The writeEntry form is now defined and used consistently throughout OpenFOAM
making it easier to use and extend, particularly to support binary IO of complex
dictionary entries.
The radiation modelling library has been moved out of
thermophysicalProperties into the top-level source directory. Radiation
is a process, not a property, and belongs alongside turbulence,
combustion, etc...
The namespaces used within the radiation library have been made
consistent with the rest of the code. Selectable sub-models are in
namespaces named after their base classes. Some models have been
renamed remove the base type from the suffix, as this is unnecessary.
These renames are:
Old name: New name:
binaryAbsorptionEmission binary
cloudAbsorptionEmission cloud
constantAbsorptionEmission constant
greyMeanAbsorptionEmission greyMean/greyMeanCombustion
greyMeanSolidAbsorptionEmission greyMeanSolid
wideBandAbsorptionEmission wideBand/wideBandCombustion
cloudScatter cloud
constantScatter constant
mixtureFractionSoot mixtureFraction
Some absorption-emission models have been split into versions which do
and don't use the heat release rate. The version that does has been
given the post-fix "Combustion" and has been moved into the
combustionModels library. This removes the dependence on a registered
Qdot field, and makes the models compatible with the recent removal of
that field from the combustion solvers.
Registration occurs when the temporary field is transferred to a non-temporary
field via a constructor or if explicitly transferred to the database via the
regIOobject "store" methods.
Also extended the cubic equation test routine and modified the error
methods so that they more accurately generate the round of error of
evaluation.
This resolves bug report https://bugs.openfoam.org/view.php?id=3015
This is faster than the library functionality that it replaces, as it
allows the compiler to do inlining. It also does not utilise any static
state so generators do not interfere with each other. It is also faster
than the the array lookup in cachedRandom. The cachedRandom class
therefore offers no advantage over Random and has been removed.