79 const labelList& polyMeshSharedPointLabels =
82 const labelList& polyMeshSharedPointAddr =
89 forAll(mesh_.boundary(), patchI)
91 const faPatch& fap = mesh_.boundary()[patchI];
97 forAll(localPointLabels, pointI)
100 mesh_.patch().meshPoints()[localPointLabels[pointI]];
102 const label sharedPolyMeshPoint =
103 polyMeshSharedPointLabels.
find(polyMeshPoint);
107 sharedPolyMeshPoint != -1
108 && !sharedPointLabels.
found(localPointLabels[pointI])
111 globalList[polyMeshSharedPointAddr[sharedPolyMeshPoint]]
114 sharedPointLabels.
insert(localPointLabels[pointI]);
120 sharedPointLabels_ = sharedPointLabels.
toc();
125 for (label i=0; i<globalList.size(); ++i)
127 if (globalList[i] > 0)
129 globalList[i] = ++nGlobalPoints_;
133 sharedPointAddr_.setSize(sharedPointLabels_.size());
134 forAll(sharedPointAddr_, pointI)
136 const label polyMeshSharedPointIndex =
137 polyMeshSharedPointLabels.
find
139 mesh_.patch().meshPoints()[sharedPointLabels_[pointI]]
142 sharedPointAddr_[pointI] =
143 globalList[polyMeshSharedPointAddr[polyMeshSharedPointIndex]]
bool insert(const Key &key)
Insert a new entry, not overwriting existing entries.
List< Key > toc() const
The table of contents (the keys) in unsorted order.
bool found(const Key &key) const
Same as contains().
static void combineReduce(T &value, CombineOp cop, const int tag=UPstream::msgType(), const int communicator=UPstream::worldComm)
Reduce inplace (cf. MPI Allreduce) applying cop to inplace combine value from different processors.
void size(const label n)
Older name for setAddressableSize.
label find(const T &val) const
Find index of the first occurrence of the value.
Inter-processor communications stream.
~faGlobalMeshData()
Destructor.
const faMesh & mesh() const noexcept
Return mesh reference.
const labelList & sharedPointLabels() const noexcept
Return indices of local points that are globally shared.
faGlobalMeshData(const faGlobalMeshData &)=delete
No copy construct.
void updateMesh()
Change global mesh data given a topological change.
Finite area mesh (used for 2-D non-Euclidian finite area method) defined using a patch of faces on a ...
Finite area patch class. Used for 2-D non-Euclidian finite area method.
const labelList & pointLabels() const
Return patch point labels.
Various mesh related information for a parallel run. Upon construction, constructs all info using par...
const labelList & sharedPointAddr() const
Return addressing into the complete globally shared points list.
label nGlobalPoints() const
Return number of globally shared points.
const labelList & sharedPointLabels() const
Return indices of local points that are globally shared.
const polyMesh & mesh() const noexcept
Return the mesh reference.
const globalMeshData & globalData() const
Return parallel info (demand-driven).
Determines/represents processor-processor connection. After instantiation contains the processor-proc...
tmp< DimensionedField< TypeR, GeoMesh > > New(const tmp< DimensionedField< TypeR, GeoMesh > > &tf1, const word &name, const dimensionSet &dimensions, const bool initCopy=false)
Global function forwards to reuseTmpDimensionedField::New.
List< label > labelList
A List of labels.
HashSet< label, Hash< label > > labelHashSet
A HashSet of labels, uses label hasher.
const Type * isA(const U &obj)
Attempt dynamic_cast to Type.
Field< label > labelField
Specialisation of Field<T> for label.
static constexpr const zero Zero
Global zero (0).
Define the processor-processor connection table by walking a list of patches and detecting the proces...
#define forAll(list, i)
Loop across all elements in list.