For a given point within a given mesh, the existing `meshWave` method gives
the orthogonal distance to a patch. In meshes with very steep terrain (e.g.
a hill of 90 [deg], this might be problematic for the fields that require
the distance to the patch associated with the terrain surface.
`directionalMeshWave` is a variant of `meshWave` distance-to-patch method,
which ignores the component in the specified direction. Can be used e.g. to
calculate the distance in the z-direction only.
TUT: add example of directionalMeshWave to mesh/moveDynamicMesh/SnakeCanyon
Requirement by CENER
Implementation by Mattijs Janssens
- takes a search string and a replacement character.
The replacement character can also be a nul char ('\0'), which
simply removes the characters.
Possible uses:
* Replace reserved characters
str.replaceAny("<>:", '_');
* Remove shell meta-characters or reserved filesystem characters
str.replaceAny("*?<>{}[]:", '\0');
- construct from dimensioned/value, defaulting name from value.
Can be convenient for these type of operations:
max(.., dimensionedScalar(somedims, 0.5))
- construct from dimensioned/one, forwarding to pTraits::one.
Can be convenient for constructors:
volScalarField( ..., dimensionedScalar(somedims, one{}))
ENH: minor updates to zero/one classes.
- add global 'One' constant for symmetry with 'Zero'.
- clearer than passing a reference to a dummy variable,
or relying on move occuring within the copy constructor
(historical, but should be deprecated)
STYLE: consistent autoPtr syntax for uncollated file operations
- can help in circumstances when an zero-sized entry is written on
some processors, but the compound-type may be useful for determining
a particular code path when re-reading the files. Ensures that the
information is consistent on all processors.
STYLE: adjust separation of includes between List.H and UList.H
1) The sign of radiative flux (qr) for modes Power and HeatFlux was
corrected.
2) Relaxation factor implementation was incomplete. Now caching
valueFraction and refValue from the previous time step.
- as a side-effect of recent changes, command-line stripping of .gz
extensions on input was lost. For example,
OK: surfaceTransformPoints file.stl ...
Fail: surfaceTransformPoints file.stl.gz ...
- restore the previous behaviour of silently stripping the '.gz'
extension on input.
ENH: add triSurface::New selector entry point
- for symmetry with MeshedSurface
Now the thermal baffle can be extrapolated from a patch which is
coupled to the bottom patch of the solid region.
The user can set the T bc on the 'top' patch of the solid.
The new keyword is 'internal' and its default is true. Check new
tutorial for an example:
tutorials/heatTransfer/buoyantSimpleFoam/roomWithThickCeiling/
- reads/write shell elements
Output elements are "bunched" according to type and their set
without reordering.
- preliminary reading of solids without extraction.
Handling of *Surface specifications is not implemented
- enhancement and potential breaking change.
Nastran surface writer previously used the keyword 'scale' for
field scaling, which was applied uniformly to all output fields.
Change the meaning of 'scale' to be geometric scaling
(consistent with reading triSurfaceMesh etc).
New 'fieldScale' entry is an optional dictionary of scaling
parameters.
Example,
nastran
{
scale 1000; // [m] -> [mm]
fieldScale
{
"p.*" 0.01; // [Pa] -> [mbar]
}
}
- adjustments to internal handling to improve run-time addition of
other formats (eg, with additional user library)
For example, to write a binary STL with a '.stl' extension:
$ surfaceMeshConvert input.obj -write-format stlb output.stl
Or in a sampler,
to specify the input type without ambiguity:
surf
{
type meshedSurface;
surface sampling.inp;
fileType starcd;
scale 0.001;
...
}
STYLE: regularize naming for input/output scaling
* -read-scale (compat: -scaleIn)
* -write-scale (compat: -scaleOut)
CONFIG: change edge/surface selection name for STARCD format
- now select as "starcd" instead of "inp" to avoid naming ambiguity
with abaqus
- had a PrimitivePatch with SubField, but now use const pointField&.
There is no derivation path from a pointIOField to SubField<point>,
so a const reference makes more sense.
- face_type, point_type (similar to STL value_type, etc).
The naming avoids potential confusion with template parameters.
- rename private typedef from ParentType to MeshReference for more
consistency with polySurface etc.
- regression introduced by 431c9632f9
The triSurface dictionary constructor applies the scaling,
and thus it can be reported, but not applied in triSurfaceMesh
- previously used a Pstream::exit() invoked from the argList
destructor to handle all MPI shutdown, but this has the unfortunate
side-effect of using a fixed return value for the program exit.
Instead use the Pstream::shutdown() method in the destructor and allow
the normal program exit codes as usual. This means that the
following code now works as expected.
```
argList args(...);
if (...)
{
InfoErr<< "some error\n";
return 1;
}
```