Go to the documentation of this file.
47 Info <<
"Number of leaves per processor " << nLeavesPerProcessor <<
endl;
49 if( nLeavesPerProcessor == 0 )
52 Info <<
"Distributing leaves to processors" <<
endl;
61 label end = start - nLeavesPerProcessor;
72 procRange[procI].second() = leaves[start]->coordinates();
73 procRange[procI].first() = leaves[end+1]->coordinates();
75 for(;start>end;--start)
76 leaves[start]->setProcNo(procI);
81 Info <<
"Leaf " << leafI <<
" is in proc "
82 << leaves[leafI]->procNo() <<
endl;
98 (cc >= procRange[procI].first()) &&
99 (cc <= procRange[procI].second())
110 <<
" are " << neiProcs <<
endl;
116 nProcs[i] = neiProcs[i];
132 Info <<
"Finished distributing leaves to processors" <<
endl;
List< Pair< meshOctreeCubeCoordinates > > neiRange_
#define forAll(list, i)
Loop across all elements in list.
static label nProcs(const label communicator=0)
Number of processes in parallel run.
void distributeLeavesToProcessors()
const labelList & neiProcs() const
neighbour processors of the current one
Ostream & endl(Ostream &os)
Add newline and flush stream.
label size() const
Size of the active part of the list.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
OSstream Serr(cerr, "Serr")
void appendIfNotIn(const T &e)
LongList< meshOctreeCube * > leaves_
list of cubes which are leaves of the octree
bool purgeProcessorCubes(const short procNo)
delete boxes which are not local to the given processor
static int myProcNo(const label communicator=0)
Number of this process (starting from masterNo() = 0)
void setSize(const label)
Reset size of List.
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
meshOctreeCube * initialCubePtr_
Root cube of the octree structure.
void size(const label)
Override size to be inconsistent with allocated storage.
void createListOfLeaves()
create leaves
meshOctree & octree_
Reference to the octree.