diff --git a/applications/utilities/mesh/generation/foamyHexMesh/conformalVoronoiMesh/DelaunayMesh/DistributedDelaunayMesh.C b/applications/utilities/mesh/generation/foamyHexMesh/conformalVoronoiMesh/DelaunayMesh/DistributedDelaunayMesh.C index 277ed8caf2b96d2e0a33a086435d8d9375f8a4d6..2370c16ba3cd8ff0ade760acc971609dc3409456 100644 --- a/applications/utilities/mesh/generation/foamyHexMesh/conformalVoronoiMesh/DelaunayMesh/DistributedDelaunayMesh.C +++ b/applications/utilities/mesh/generation/foamyHexMesh/conformalVoronoiMesh/DelaunayMesh/DistributedDelaunayMesh.C @@ -254,31 +254,47 @@ void Foam::DistributedDelaunayMesh<Triangulation>::findProcessorBoundaryCells /Pstream::nProcs() ); + std::list<Cell_handle> infinite_cells; + Triangulation::incident_cells + ( + Triangulation::infinite_vertex(), + std::back_inserter(infinite_cells) + ); + for ( - All_cells_iterator cit = Triangulation::all_cells_begin(); - cit != Triangulation::all_cells_end(); - ++cit + typename std::list<Cell_handle>::iterator vcit = infinite_cells.begin(); + vcit != infinite_cells.end(); + ++vcit ) { - if (Triangulation::is_infinite(cit)) - { - // Index of infinite vertex in this cell. - int i = cit->index(Triangulation::infinite_vertex()); + Cell_handle cit = *vcit; - Cell_handle c = cit->neighbor(i); + // Index of infinite vertex in this cell. + int i = cit->index(Triangulation::infinite_vertex()); - if (c->unassigned()) - { - c->cellIndex() = this->getNewCellIndex(); + Cell_handle c = cit->neighbor(i); - if (checkProcBoundaryCell(c, circumsphereOverlaps)) - { - cellToCheck.insert(c->cellIndex()); - } + if (c->unassigned()) + { + c->cellIndex() = this->getNewCellIndex(); + + if (checkProcBoundaryCell(c, circumsphereOverlaps)) + { + cellToCheck.insert(c->cellIndex()); } } - else if (cit->parallelDualVertex()) + } + + + for + ( + Finite_cells_iterator cit = Triangulation::finite_cells_begin(); + cit != Triangulation::finite_cells_end(); + ++cit + ) + { + if (cit->parallelDualVertex()) { if (cit->unassigned()) { @@ -315,12 +331,20 @@ void Foam::DistributedDelaunayMesh<Triangulation>::findProcessorBoundaryCells continue; } - checkProcBoundaryCell + if ( - citNeighbor, - circumsphereOverlaps - ); + checkProcBoundaryCell + ( + citNeighbor, + circumsphereOverlaps + ) + ) + { + cellToCheck.insert(citNeighbor->cellIndex()); + } } + + cellToCheck.unset(cit->cellIndex()); } } } @@ -521,7 +545,6 @@ Foam::label Foam::DistributedDelaunayMesh<Triangulation>::referVertices << originalParallelVertices[vI].procIndex() << " " << originalParallelVertices[vI].index() << endl; } - } } } diff --git a/etc/caseDicts/foamyHexMeshDict b/etc/caseDicts/foamyHexMeshDict index d6f87bf6a34631c2d01076b61af5c2a89823851e..cd0c9367a3041bb5e30ef65831dedd1dd6bc3962 100644 --- a/etc/caseDicts/foamyHexMeshDict +++ b/etc/caseDicts/foamyHexMeshDict @@ -78,6 +78,7 @@ motionControl objOutput no; timeChecks no; + printVertexInfo off; maxLoadUnbalance 0.2; diff --git a/src/OpenFOAM/fields/Fields/Field/Field.C b/src/OpenFOAM/fields/Fields/Field/Field.C index 7460dba215f2623ea1efdeb61f37d853236ebc12..334eba8e418962b2c39e6d4b114b09ce21736e7a 100644 --- a/src/OpenFOAM/fields/Fields/Field/Field.C +++ b/src/OpenFOAM/fields/Fields/Field/Field.C @@ -677,7 +677,6 @@ template<class Type> template<class Form, class Cmpt, int nCmpt> void Foam::Field<Type>::operator=(const VectorSpace<Form,Cmpt,nCmpt>& vs) { - typedef VectorSpace<Form,Cmpt,nCmpt> VSType; TFOR_ALL_F_OP_S(Type, *this, =, VSType, vs) } diff --git a/src/OpenFOAM/memory/autoPtr/autoPtr.H b/src/OpenFOAM/memory/autoPtr/autoPtr.H index 0d5944128ef5760da6eda3d50fc93709d8e0202d..c3ea064fb11d207d0a49bc11b0228e945c71c8ad 100644 --- a/src/OpenFOAM/memory/autoPtr/autoPtr.H +++ b/src/OpenFOAM/memory/autoPtr/autoPtr.H @@ -63,11 +63,11 @@ public: //- Store object pointer inline explicit autoPtr(T* = 0); - //- Construct as copy by transfering pointer to this autoPtr and + //- Construct as copy by transferring pointer to this autoPtr and // setting the arguments pointer to NULL inline autoPtr(const autoPtr<T>&); - //- Construct either by transfering pointer or cloning. Should + //- Construct either by transferring pointer or cloning. Should // only be called with type that supports cloning. inline autoPtr(const autoPtr<T>&, const bool reUse); diff --git a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/epsilonWallFunctions/epsilonWallFunction/epsilonWallFunctionFvPatchScalarField.C b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/epsilonWallFunctions/epsilonWallFunction/epsilonWallFunctionFvPatchScalarField.C index 3f1ab4a2c221a5ec3f71bfdb49454fa4c8ae5cc2..90915d25eb4d700859d59d69cf33c4fdd23a9827 100644 --- a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/epsilonWallFunctions/epsilonWallFunction/epsilonWallFunctionFvPatchScalarField.C +++ b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/epsilonWallFunctions/epsilonWallFunction/epsilonWallFunctionFvPatchScalarField.C @@ -141,7 +141,7 @@ void epsilonWallFunctionFvPatchScalarField::createAveragingWeights() forAll(epsilonPatches, i) { label patchI = epsilonPatches[i]; - const fvPatchField& wf = weights.boundaryField()[patchI]; + const fvPatchScalarField& wf = weights.boundaryField()[patchI]; cornerWeights_[patchI] = 1.0/wf.patchInternalField(); } diff --git a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/omegaWallFunctions/omegaWallFunction/omegaWallFunctionFvPatchScalarField.C b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/omegaWallFunctions/omegaWallFunction/omegaWallFunctionFvPatchScalarField.C index 2f4e11dc20f99ed3e0d25d7d51620139795f88f1..d0d9865c5c9468cdac1a02d562f97cb802a8e5d3 100644 --- a/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/omegaWallFunctions/omegaWallFunction/omegaWallFunctionFvPatchScalarField.C +++ b/src/turbulenceModels/compressible/RAS/derivedFvPatchFields/wallFunctions/omegaWallFunctions/omegaWallFunction/omegaWallFunctionFvPatchScalarField.C @@ -143,7 +143,7 @@ void omegaWallFunctionFvPatchScalarField::createAveragingWeights() forAll(omegaPatches, i) { label patchI = omegaPatches[i]; - const fvPatchField& wf = weights.boundaryField()[patchI]; + const fvPatchScalarField& wf = weights.boundaryField()[patchI]; cornerWeights_[patchI] = 1.0/wf.patchInternalField(); } diff --git a/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/wallFunctions/epsilonWallFunctions/epsilonWallFunction/epsilonWallFunctionFvPatchScalarField.C b/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/wallFunctions/epsilonWallFunctions/epsilonWallFunction/epsilonWallFunctionFvPatchScalarField.C index dc08123d264a5f43a0e94c91dab6926b70d2489c..da2913f3044d915b3a32f93618184b88ef1287eb 100644 --- a/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/wallFunctions/epsilonWallFunctions/epsilonWallFunction/epsilonWallFunctionFvPatchScalarField.C +++ b/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/wallFunctions/epsilonWallFunctions/epsilonWallFunction/epsilonWallFunctionFvPatchScalarField.C @@ -141,7 +141,7 @@ void epsilonWallFunctionFvPatchScalarField::createAveragingWeights() forAll(epsilonPatches, i) { label patchI = epsilonPatches[i]; - const fvPatchField& wf = weights.boundaryField()[patchI]; + const fvPatchScalarField& wf = weights.boundaryField()[patchI]; cornerWeights_[patchI] = 1.0/wf.patchInternalField(); } diff --git a/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/wallFunctions/omegaWallFunctions/omegaWallFunction/omegaWallFunctionFvPatchScalarField.C b/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/wallFunctions/omegaWallFunctions/omegaWallFunction/omegaWallFunctionFvPatchScalarField.C index 69f8ffd170597e3a328c61c82d2d2a9d2df082c7..9aec38bc386a19e4e49bdf805aaf612052013b4f 100644 --- a/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/wallFunctions/omegaWallFunctions/omegaWallFunction/omegaWallFunctionFvPatchScalarField.C +++ b/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/wallFunctions/omegaWallFunctions/omegaWallFunction/omegaWallFunctionFvPatchScalarField.C @@ -143,7 +143,7 @@ void omegaWallFunctionFvPatchScalarField::createAveragingWeights() forAll(omegaPatches, i) { label patchI = omegaPatches[i]; - const fvPatchField& wf = weights.boundaryField()[patchI]; + const fvPatchScalarField& wf = weights.boundaryField()[patchI]; cornerWeights_[patchI] = 1.0/wf.patchInternalField(); }