particle: Removed polyMesh reference

This reference represents unnecessary storage. The mesh can be obtained
from tracking data or passed to the particle evolution functions by
argument.

In addition, removing the mesh reference makes it possible to construct
as particle from an Istream without the need for an iNew class. This
simplifies stream-based transfer, and makes it possible for particles to
be communicated by a polyDistributionMap.
This commit is contained in:
Will Bainbridge
2022-09-20 08:45:34 +01:00
parent 3719f7d9de
commit 4c223b8aee
110 changed files with 787 additions and 1152 deletions

View File

@ -704,13 +704,19 @@ int main(int argc, char *argv[])
<< " for particle with index "
<< iter().index()
<< " at position "
<< iter().position() << nl
<< iter().position(meshes.completeMesh())
<< nl
<< "Cell number should be between 0 and "
<< meshes.completeMesh().nCells()-1 << nl
<< "On this mesh the particle should"
<< " be in cell "
<< meshes.completeMesh().findCell
(iter().position())
(
iter().position
(
meshes.completeMesh()
)
)
<< exit(FatalError);
}

View File

@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
\\ / A nd | Copyright (C) 2011-2018 OpenFOAM Foundation
\\ / A nd | Copyright (C) 2011-2022 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@ -88,7 +88,7 @@ Foam::lagrangianFieldDecomposer::lagrangianFieldDecomposer
ppi.coordinates(),
procCelli,
mappedTetFace,
ppi.procTetPt(procMesh, procCelli, mappedTetFace)
ppi.procTetPt(mesh, procMesh, procCelli, mappedTetFace)
)
);
}