- in many cases the local communicator has the same communication
pattern for several timesteps so it can be reused instead of being
recreated. Avoids repeated MPI_Comm_free()/MPI_Comm_group() calls
- STYLE: eliminate bitSet intermediate when determining the sub-ranks
Calculates thrust, drag, torque and lift/drag/pressure coefficients
of single or multiple blades (eg, propeller, turbine blades)
This function object differs from the propellerInfo and forces
function objects in that all forces are calculated within the local
cylindrical coordinate system, which yields thrust and drag values
within the expected reference frame.
The output comprises:
- coefficients per radial bin
- area-weighted total coefficients
- integrated forces and torque
For convenient post-processing, the results are also written in a VTK
(.vtp) output format. All surface results are registered internally,
which makes them available for other function objects.
- originally only listed in functionObjectList, now also list the same
information under namespace functionObjects so it is more likely to
be found. Document the behaviour as a table to make it more
immediately visible than the text form.
- the indices(const wordRes& allow, const wordRes& deny) methods
were not defined consistently with the wordRes::filter handling.
wordRes::filter - allow/deny both empty:
= no filtering (ie, accept everything)
indices(allow,deny) - allow/deny both empty:
= return identity list (NEW behaviour)
= return empty list (OLD behaviour)
Consider the old behaviour a minor bug since the limited number of
callers had their own checks that avoided the poor behaviour.
Example of the inconsistent behaviour:
pbm.indices(wordRes(), wordRes({"non-existent"}))
--> identity list (old, new behaviour)
pbm.indices(wordRes(), wordRes())
--> identity list (new behaviour)
--> empty list (old behaviour)
- tests for list equality with different but compatible data types.
Eg, when comparing lists of int32 and int64 values.
STYLE: pass UList instead of List references into ListOps functors
- avoids intermediate allocation and re-assignment to self (#3374)
BUG: checkMesh (application) with questionable memory handling (#3374)
- move the contents of the new points instead of attempting to transfer
the entire list
COMP: replace mapDistribute specializations with if constexpr handling
- simplify future maintenance
- in messageStream::masterStream(int), it forwarded to stream()
without the communicator, which meant it would incorrectly check
UPstream::master(worldComm) and possibly not produce any output (or
block).
ENH: align MPI_Probe non-blocking handling with header description
- the header states that the commsType is non-blocking or not,
but the implementation actually checked for 'buffered' or not.
STYLE: fix some spacing and some documentation
- use functionObject writeInterval not timeInterval.
No change in behaviour since the missing writeInterval is treated
as '1' anyhow when using 'timeStep' for the writeControl
- consistent use of 'adjustable' vs 'adjustableRunTime'
- prefer '#eval{ vector(...) }' to calling '#eval' multiple times
ENH: improvements for GeometricBoundaryField evaluation
- early termination from evaluate_if() and evaluateCoupled().
- evaluateCoupled() now forwards to evaluate_if() and receives
additional handling for a 'void' parameter type.
BREAKING: extra template parameter for overset correctBoundaryCondition
- the true/false flag as a template parameter instead of as an
argument to use 'if constexpr' code
- encapsulates (foundObject && lookupPatchField) together,
similar to cfindObject
STYLE: remove unnecessary dummy parameters from lookupPatchField
- these were a workaround for a very old gcc bug and are no longer
needed. However, retain the (unneeded) second template parameter to
continue with not breaking existing old code - it has no overhead.
Signature:
void patchInternalField(UList<Type>& pfld) const;
// OLD: void patchInternalField(Field<Type>& pfld) const;
This change is necessary to allow collection into slices of a
larger list.
ENH: add {fa,fv}PatchField::patchNeighbourField(UList<Type>&)
- a retrieval version similar to patchInternalField(...)
STYLE: adjust AMI patch field private method names
- rename private method
patchNeighbourField(...) -> getNeighbourField(...)
to avoid access clashes with public methods
- remove undefined method neighbourSideField()
- the number of false positives has reduced, but in a few remaining
cases, the compiler cannot possibly "know" that the pointer stored
on the registry will outlive the scope of the method (for example)
gcc-13: suppressing these spurious warnings needs to be done at each
caller, which is simply not worth it, since later compiler versions
provide a cleaner solution.
gcc-14: the [[gnu::no_dangling]] attribute on the declaration
lets the compiler know the intent.
- additional FOAM_REAL_GNUC macro (defined in stdFoam.H) to define
the "real" gcc version and ignoring other compilers masquerading
as gcc.
COMP: rename MeshObject code to {cxx,txx}
- avoids issues on case-insensitive filesystems (#3316)
- the output parameter was previously a field and resized according to
the patch size. Now the output parameter must be pre-sized prior to
calling, which makes it possible to collect the patch internal
fields into slices of a larger list.
Signatures:
void patchInternalField
(
const UList<Type>& internalData,
UList<Type>& pfld // OLD: Field<Type>& pfld
) const;
void patchInternalField
(
const UList<Type>& internalData,
const labelUList& addressing,
UList<Type>& pfld // OLD: Field<Type>& pfld
) const;
This low-level change is not expected to affect any user code,
which would normally use a higher-level interface such as from
fvPatchField etc.
- can be used to pre-allocate space for internal+boundary field for
flat addressing (issue #3364).
For example:
DynamicField<Type> fld
(
std::pair<label,label>
(
GeoMesh::size(mesh),
GeoMesh::size(mesh)
+ (extra ? GeoMesh::boundary_size(mesh) : label(0))
)
);
ENH: base changes for GeometricField flags
- FieldBase 'localBoundaryConsistency_' and 'localBoundaryTolerance_'
for central handling of local boundary consistency checks.
- FieldBase 'unifiedGeometricField' for future extensions to GeometricField