From 5085a9807b87b4213d58a8b51456a4aba4dc67ac Mon Sep 17 00:00:00 2001 From: Henry Date: Tue, 6 Jan 2015 17:31:02 +0000 Subject: [PATCH] wallDist: separate the meshWaveWallDist from the wallDist interface In preparation for run-time selectable methods --- .../wallDependentModel/wallDependentModel.C | 4 +- .../postProcessing/wall/yPlusLES/yPlusLES.C | 4 +- .../postProcessing/wall/yPlusRAS/yPlusRAS.C | 2 +- src/finiteVolume/Make/files | 13 +-- .../meshWaveWallDist/meshWaveWallDist.C | 53 +++++++++++ .../meshWaveWallDist/meshWaveWallDist.H | 91 +++++++++++++++++++ .../{ => meshWaveWallDist}/patchDist.C | 56 ++++++------ .../{ => meshWaveWallDist}/patchDist.H | 66 ++++---------- .../{ => meshWaveWallDist}/wallDistData.C | 0 .../{ => meshWaveWallDist}/wallDistData.H | 0 .../{ => nearWallDist}/nearWallDist.C | 0 .../{ => nearWallDist}/nearWallDist.H | 0 .../{ => nearWallDist}/nearWallDistNoSearch.C | 0 .../{ => nearWallDist}/nearWallDistNoSearch.H | 0 .../fvMesh/wallDist/{ => wallDist}/wallDist.C | 32 ++++--- .../fvMesh/wallDist/{ => wallDist}/wallDist.H | 30 +++--- .../reflectionVectors.C | 0 .../reflectionVectors.H | 0 .../wallDistReflection.C | 0 .../wallDistReflection.H | 0 .../wallDist/wallPointYPlus/wallPointYPlus.H | 7 +- .../contactAngleForce/contactAngleForce.C | 2 +- 22 files changed, 244 insertions(+), 116 deletions(-) create mode 100644 src/finiteVolume/fvMesh/wallDist/meshWaveWallDist/meshWaveWallDist.C create mode 100644 src/finiteVolume/fvMesh/wallDist/meshWaveWallDist/meshWaveWallDist.H rename src/finiteVolume/fvMesh/wallDist/{ => meshWaveWallDist}/patchDist.C (71%) rename src/finiteVolume/fvMesh/wallDist/{ => meshWaveWallDist}/patchDist.H (63%) rename src/finiteVolume/fvMesh/wallDist/{ => meshWaveWallDist}/wallDistData.C (100%) rename src/finiteVolume/fvMesh/wallDist/{ => meshWaveWallDist}/wallDistData.H (100%) rename src/finiteVolume/fvMesh/wallDist/{ => nearWallDist}/nearWallDist.C (100%) rename src/finiteVolume/fvMesh/wallDist/{ => nearWallDist}/nearWallDist.H (100%) rename src/finiteVolume/fvMesh/wallDist/{ => nearWallDist}/nearWallDistNoSearch.C (100%) rename src/finiteVolume/fvMesh/wallDist/{ => nearWallDist}/nearWallDistNoSearch.H (100%) rename src/finiteVolume/fvMesh/wallDist/{ => wallDist}/wallDist.C (76%) rename src/finiteVolume/fvMesh/wallDist/{ => wallDist}/wallDist.H (85%) rename src/finiteVolume/fvMesh/wallDist/{ => wallDistReflection}/reflectionVectors.C (100%) rename src/finiteVolume/fvMesh/wallDist/{ => wallDistReflection}/reflectionVectors.H (100%) rename src/finiteVolume/fvMesh/wallDist/{ => wallDistReflection}/wallDistReflection.C (100%) rename src/finiteVolume/fvMesh/wallDist/{ => wallDistReflection}/wallDistReflection.H (100%) diff --git a/applications/solvers/multiphase/twoPhaseEulerFoam/interfacialModels/wallDependentModel/wallDependentModel.C b/applications/solvers/multiphase/twoPhaseEulerFoam/interfacialModels/wallDependentModel/wallDependentModel.C index f6c5109d5..2bc57b639 100644 --- a/applications/solvers/multiphase/twoPhaseEulerFoam/interfacialModels/wallDependentModel/wallDependentModel.C +++ b/applications/solvers/multiphase/twoPhaseEulerFoam/interfacialModels/wallDependentModel/wallDependentModel.C @@ -47,8 +47,6 @@ const Foam::volScalarField& Foam::wallDependentModel::yWall() const { if (!mesh_.foundObject("yWall")) { - wallDist w(mesh_); - volScalarField* yPtr ( new volScalarField @@ -62,7 +60,7 @@ const Foam::volScalarField& Foam::wallDependentModel::yWall() const IOobject::NO_WRITE, true ), - w.y() + wallDist(mesh_).y() ) ); diff --git a/applications/utilities/postProcessing/wall/yPlusLES/yPlusLES.C b/applications/utilities/postProcessing/wall/yPlusLES/yPlusLES.C index bbdfb0362..3e53aaa05 100644 --- a/applications/utilities/postProcessing/wall/yPlusLES/yPlusLES.C +++ b/applications/utilities/postProcessing/wall/yPlusLES/yPlusLES.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -57,7 +57,7 @@ int main(int argc, char *argv[]) if (timeI == 0 || state != fvMesh::UNCHANGED) { Info<< "Calculating wall distance\n" << endl; - wallDist y(mesh, true); + wallDist y(mesh); Info<< "Writing wall distance to field " << y.name() << nl << endl; y.write(); diff --git a/applications/utilities/postProcessing/wall/yPlusRAS/yPlusRAS.C b/applications/utilities/postProcessing/wall/yPlusRAS/yPlusRAS.C index 46614b7e5..3691d50f5 100644 --- a/applications/utilities/postProcessing/wall/yPlusRAS/yPlusRAS.C +++ b/applications/utilities/postProcessing/wall/yPlusRAS/yPlusRAS.C @@ -208,7 +208,7 @@ int main(int argc, char *argv[]) if (timeI == 0 || state != fvMesh::UNCHANGED) { Info<< "Calculating wall distance\n" << endl; - wallDist y(mesh, true); + wallDist y(mesh); Info<< "Writing wall distance to field " << y.name() << nl << endl; y.write(); } diff --git a/src/finiteVolume/Make/files b/src/finiteVolume/Make/files index 95f6101fe..b2b170640 100644 --- a/src/finiteVolume/Make/files +++ b/src/finiteVolume/Make/files @@ -38,13 +38,14 @@ $(derivedFvPatches)/regionCoupled/regionCoupledWallFvPatch.C wallDist = fvMesh/wallDist -$(wallDist)/patchDist.C $(wallDist)/wallPointYPlus/wallPointYPlus.C -$(wallDist)/nearWallDistNoSearch.C -$(wallDist)/nearWallDist.C -$(wallDist)/wallDist.C -$(wallDist)/reflectionVectors.C -$(wallDist)/wallDistReflection.C +$(wallDist)/nearWallDist/nearWallDistNoSearch.C +$(wallDist)/nearWallDist/nearWallDist.C +$(wallDist)/wallDist/wallDist.C +$(wallDist)/meshWaveWallDist/patchDist.C +$(wallDist)/meshWaveWallDist/meshWaveWallDist.C +$(wallDist)/wallDistReflection/reflectionVectors.C +$(wallDist)/wallDistReflection/wallDistReflection.C fvMeshMapper = fvMesh/fvMeshMapper diff --git a/src/finiteVolume/fvMesh/wallDist/meshWaveWallDist/meshWaveWallDist.C b/src/finiteVolume/fvMesh/wallDist/meshWaveWallDist/meshWaveWallDist.C new file mode 100644 index 000000000..a2ca9d656 --- /dev/null +++ b/src/finiteVolume/fvMesh/wallDist/meshWaveWallDist/meshWaveWallDist.C @@ -0,0 +1,53 @@ +/*---------------------------------------------------------------------------*\ + ========= | + \\ / F ield | OpenFOAM: The Open Source CFD Toolbox + \\ / O peration | + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation + \\/ M anipulation | +------------------------------------------------------------------------------- +License + This file is part of OpenFOAM. + + OpenFOAM is free software: you can redistribute it and/or modify it + under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + OpenFOAM is distributed in the hope that it will be useful, but WITHOUT + ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + for more details. + + You should have received a copy of the GNU General Public License + along with OpenFOAM. If not, see . + +\*---------------------------------------------------------------------------*/ + +#include "meshWaveWallDist.H" +#include "fvMesh.H" +#include "wallPolyPatch.H" + +// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // + +Foam::meshWaveWallDist::meshWaveWallDist +( + const fvMesh& mesh, + const bool correctWalls +) +: + patchDist + ( + mesh, + mesh.boundaryMesh().findPatchIDs(), + correctWalls + ) +{} + + +// * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * * // + +Foam::meshWaveWallDist::~meshWaveWallDist() +{} + + +// ************************************************************************* // diff --git a/src/finiteVolume/fvMesh/wallDist/meshWaveWallDist/meshWaveWallDist.H b/src/finiteVolume/fvMesh/wallDist/meshWaveWallDist/meshWaveWallDist.H new file mode 100644 index 000000000..fa9a9aea5 --- /dev/null +++ b/src/finiteVolume/fvMesh/wallDist/meshWaveWallDist/meshWaveWallDist.H @@ -0,0 +1,91 @@ +/*---------------------------------------------------------------------------*\ + ========= | + \\ / F ield | OpenFOAM: The Open Source CFD Toolbox + \\ / O peration | + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation + \\/ M anipulation | +------------------------------------------------------------------------------- +License + This file is part of OpenFOAM. + + OpenFOAM is free software: you can redistribute it and/or modify it + under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + OpenFOAM is distributed in the hope that it will be useful, but WITHOUT + ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + for more details. + + You should have received a copy of the GNU General Public License + along with OpenFOAM. If not, see . + +Class + Foam::meshWaveWallDist + +Description + Specialisation of patchDist for wall distance calculation + +SourceFiles + meshWaveWallDist.C + +\*---------------------------------------------------------------------------*/ + +#ifndef meshWaveWallDist_H +#define meshWaveWallDist_H + +#include "patchDist.H" + +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +namespace Foam +{ + +class fvMesh; + +/*---------------------------------------------------------------------------*\ + Class meshWaveWallDist Declaration +\*---------------------------------------------------------------------------*/ + +class meshWaveWallDist +: + public patchDist +{ + // Private Member Functions + + //- Disallow default bitwise copy construct + meshWaveWallDist(const meshWaveWallDist&); + + //- Disallow default bitwise assignment + void operator=(const meshWaveWallDist&); + + +public: + + // Constructors + + //- Construct from mesh and flag whether or not to correct wall. + // Calculate for all cells. correctWalls : correct wall (face&point) + // cells for correct distance, searching neighbours. + meshWaveWallDist + ( + const fvMesh& mesh, + const bool correctWalls = true + ); + + + //- Destructor + virtual ~meshWaveWallDist(); +}; + + +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +} // End namespace Foam + +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +#endif + +// ************************************************************************* // diff --git a/src/finiteVolume/fvMesh/wallDist/patchDist.C b/src/finiteVolume/fvMesh/wallDist/meshWaveWallDist/patchDist.C similarity index 71% rename from src/finiteVolume/fvMesh/wallDist/patchDist.C rename to src/finiteVolume/fvMesh/wallDist/meshWaveWallDist/patchDist.C index 6855f5a17..96747e9dd 100644 --- a/src/finiteVolume/fvMesh/wallDist/patchDist.C +++ b/src/finiteVolume/fvMesh/wallDist/meshWaveWallDist/patchDist.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -37,54 +37,58 @@ Foam::patchDist::patchDist const bool correctWalls ) : - volScalarField - ( - IOobject - ( - "y", - mesh.time().timeName(), - mesh - ), - mesh, - dimensionedScalar("y", dimLength, GREAT) - ), + mesh_(mesh), patchIDs_(patchIDs), correctWalls_(correctWalls), nUnset_(0) -{ - patchDist::correct(); -} - - -// * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * * // - -Foam::patchDist::~patchDist() {} // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // -void Foam::patchDist::correct() +Foam::tmp Foam::patchDist::y() const { + tmp ty + ( + new volScalarField + ( + IOobject + ( + "y", + mesh_.time().timeName(), + mesh_, + IOobject::NO_READ, + IOobject::NO_WRITE, + false + ), + mesh_, + dimensionedScalar("y", dimLength, GREAT) + ) + ); + + volScalarField& y = ty(); + // Calculate distance starting from patch faces - patchWave wave(mesh(), patchIDs_, correctWalls_); + patchWave wave(mesh_, patchIDs_, correctWalls_); // Transfer cell values from wave into *this - transfer(wave.distance()); + y.transfer(wave.distance()); // Transfer values on patches into boundaryField of *this - forAll(boundaryField(), patchI) + forAll(y.boundaryField(), patchI) { - if (!isA(boundaryField()[patchI])) + if (!isA(y.boundaryField()[patchI])) { scalarField& waveFld = wave.patchDistance()[patchI]; - boundaryField()[patchI].transfer(waveFld); + y.boundaryField()[patchI].transfer(waveFld); } } // Transfer number of unset values nUnset_ = wave.nUnset(); + + return ty; } diff --git a/src/finiteVolume/fvMesh/wallDist/patchDist.H b/src/finiteVolume/fvMesh/wallDist/meshWaveWallDist/patchDist.H similarity index 63% rename from src/finiteVolume/fvMesh/wallDist/patchDist.H rename to src/finiteVolume/fvMesh/wallDist/meshWaveWallDist/patchDist.H index 8c631cfe1..403b9e642 100644 --- a/src/finiteVolume/fvMesh/wallDist/patchDist.H +++ b/src/finiteVolume/fvMesh/wallDist/meshWaveWallDist/patchDist.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -25,33 +25,18 @@ Class Foam::patchDist Description - Calculation of distance to nearest patch for all cells and boundary. - Uses meshWave to do actual calculation. + Calculation of distance to nearest patch for all cells and boundary + using meshWave. - Distance correction: + Distance correction (correctWalls = true): + For each cell with face on wall calculate the true nearest point (by + triangle decomposition) on that face and do the same for that face's + pointNeighbours. This will find the true nearest distance in almost all + cases. Only very skewed cells or cells close to another wall might be + missed. - if correctWalls = true: - For each cell with face on wall calculate the true nearest point - (by triangle decomposition) on that face and do the same for that face's - pointNeighbours. This will find the true nearest distance in almost all - cases. Only very skewed cells or cells close to another wall might be - missed. - - For each cell with only one point on wall the same is done except now it - takes the pointFaces() of the wall point to look for the nearest point. - -Note - - correct() : for now does complete recalculation. (which usually is - ok since mesh is smoothed). However for topology change where geometry - in most of domain does not change you could think of starting from the - old cell values. Tried but not done since: - - meshWave would have to be called with old cellInfo. - This is List\ of nCells. - - cannot construct from distance (y_) only since we don't know a value - for origin_. (origin_ = GREAT already used to denote illegal value.) - - so we would have to store a List\ which unfortunately does - not get resized/mapped automatically upon mesh changes. + For each cell with only one point on wall the same is done except now it + takes the pointFaces() of the wall point to look for the nearest point. SourceFiles patchDist.C @@ -75,23 +60,20 @@ class fvMesh; \*---------------------------------------------------------------------------*/ class patchDist -: - public volScalarField { - - -private: - // Private Member Data + //- Reference to the mesh + const fvMesh& mesh_; + //- Set of patch IDs - labelHashSet patchIDs_; + const labelHashSet patchIDs_; //- Do accurate distance calculation for near-wall cells. - bool correctWalls_; + const bool correctWalls_; //- Number of unset cells and faces. - label nUnset_; + mutable label nUnset_; // Private Member Functions @@ -118,24 +100,16 @@ public: ); - //- Destructor - virtual ~patchDist(); - - // Member Functions - const volScalarField& y() const - { - return *this; - } + //- Calculate and return the distance to nearest patch + // for all cells and boundary + tmp y() const; label nUnset() const { return nUnset_; } - - //- Correct for mesh geom/topo changes - virtual void correct(); }; diff --git a/src/finiteVolume/fvMesh/wallDist/wallDistData.C b/src/finiteVolume/fvMesh/wallDist/meshWaveWallDist/wallDistData.C similarity index 100% rename from src/finiteVolume/fvMesh/wallDist/wallDistData.C rename to src/finiteVolume/fvMesh/wallDist/meshWaveWallDist/wallDistData.C diff --git a/src/finiteVolume/fvMesh/wallDist/wallDistData.H b/src/finiteVolume/fvMesh/wallDist/meshWaveWallDist/wallDistData.H similarity index 100% rename from src/finiteVolume/fvMesh/wallDist/wallDistData.H rename to src/finiteVolume/fvMesh/wallDist/meshWaveWallDist/wallDistData.H diff --git a/src/finiteVolume/fvMesh/wallDist/nearWallDist.C b/src/finiteVolume/fvMesh/wallDist/nearWallDist/nearWallDist.C similarity index 100% rename from src/finiteVolume/fvMesh/wallDist/nearWallDist.C rename to src/finiteVolume/fvMesh/wallDist/nearWallDist/nearWallDist.C diff --git a/src/finiteVolume/fvMesh/wallDist/nearWallDist.H b/src/finiteVolume/fvMesh/wallDist/nearWallDist/nearWallDist.H similarity index 100% rename from src/finiteVolume/fvMesh/wallDist/nearWallDist.H rename to src/finiteVolume/fvMesh/wallDist/nearWallDist/nearWallDist.H diff --git a/src/finiteVolume/fvMesh/wallDist/nearWallDistNoSearch.C b/src/finiteVolume/fvMesh/wallDist/nearWallDist/nearWallDistNoSearch.C similarity index 100% rename from src/finiteVolume/fvMesh/wallDist/nearWallDistNoSearch.C rename to src/finiteVolume/fvMesh/wallDist/nearWallDist/nearWallDistNoSearch.C diff --git a/src/finiteVolume/fvMesh/wallDist/nearWallDistNoSearch.H b/src/finiteVolume/fvMesh/wallDist/nearWallDist/nearWallDistNoSearch.H similarity index 100% rename from src/finiteVolume/fvMesh/wallDist/nearWallDistNoSearch.H rename to src/finiteVolume/fvMesh/wallDist/nearWallDist/nearWallDistNoSearch.H diff --git a/src/finiteVolume/fvMesh/wallDist/wallDist.C b/src/finiteVolume/fvMesh/wallDist/wallDist/wallDist.C similarity index 76% rename from src/finiteVolume/fvMesh/wallDist/wallDist.C rename to src/finiteVolume/fvMesh/wallDist/wallDist/wallDist.C index e089985d4..e771ff052 100644 --- a/src/finiteVolume/fvMesh/wallDist/wallDist.C +++ b/src/finiteVolume/fvMesh/wallDist/wallDist/wallDist.C @@ -24,24 +24,26 @@ License \*---------------------------------------------------------------------------*/ #include "wallDist.H" -#include "fvMesh.H" -#include "wallPolyPatch.H" +#include "meshWaveWallDist.H" // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // -Foam::wallDist::wallDist -( - const fvMesh& mesh, - const bool correctWalls -) +Foam::wallDist::wallDist(const fvMesh& mesh) : - patchDist + volScalarField ( + IOobject + ( + "y", + mesh.time().timeName(), + mesh + ), mesh, - mesh.boundaryMesh().findPatchIDs(), - correctWalls + dimensionedScalar("y", dimLength, GREAT) ) -{} +{ + correct(); +} // * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * * // @@ -50,4 +52,12 @@ Foam::wallDist::~wallDist() {} +// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // + +void Foam::wallDist::correct() +{ + volScalarField::operator=(meshWaveWallDist(mesh()).y()); +} + + // ************************************************************************* // diff --git a/src/finiteVolume/fvMesh/wallDist/wallDist.H b/src/finiteVolume/fvMesh/wallDist/wallDist/wallDist.H similarity index 85% rename from src/finiteVolume/fvMesh/wallDist/wallDist.H rename to src/finiteVolume/fvMesh/wallDist/wallDist/wallDist.H index 195c04dbc..ad4e94900 100644 --- a/src/finiteVolume/fvMesh/wallDist/wallDist.H +++ b/src/finiteVolume/fvMesh/wallDist/wallDist/wallDist.H @@ -35,26 +35,21 @@ SourceFiles #ifndef wallDist_H #define wallDist_H -#include "patchDist.H" +#include "volFields.H" // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // namespace Foam { -class fvMesh; - /*---------------------------------------------------------------------------*\ Class wallDist Declaration \*---------------------------------------------------------------------------*/ class wallDist : - public patchDist + public volScalarField { - -private: - // Private Member Functions //- Disallow default bitwise copy construct @@ -68,18 +63,23 @@ public: // Constructors - //- Construct from mesh and flag whether or not to correct wall. - // Calculate for all cells. correctWalls : correct wall (face&point) - // cells for correct distance, searching neighbours. - wallDist - ( - const fvMesh& mesh, - const bool correctWalls = true - ); + //- Construct from mesh + wallDist(const fvMesh& mesh); //- Destructor virtual ~wallDist(); + + + // Member Functions + + const volScalarField& y() const + { + return *this; + } + + //- Correct for mesh changes + virtual void correct(); }; diff --git a/src/finiteVolume/fvMesh/wallDist/reflectionVectors.C b/src/finiteVolume/fvMesh/wallDist/wallDistReflection/reflectionVectors.C similarity index 100% rename from src/finiteVolume/fvMesh/wallDist/reflectionVectors.C rename to src/finiteVolume/fvMesh/wallDist/wallDistReflection/reflectionVectors.C diff --git a/src/finiteVolume/fvMesh/wallDist/reflectionVectors.H b/src/finiteVolume/fvMesh/wallDist/wallDistReflection/reflectionVectors.H similarity index 100% rename from src/finiteVolume/fvMesh/wallDist/reflectionVectors.H rename to src/finiteVolume/fvMesh/wallDist/wallDistReflection/reflectionVectors.H diff --git a/src/finiteVolume/fvMesh/wallDist/wallDistReflection.C b/src/finiteVolume/fvMesh/wallDist/wallDistReflection/wallDistReflection.C similarity index 100% rename from src/finiteVolume/fvMesh/wallDist/wallDistReflection.C rename to src/finiteVolume/fvMesh/wallDist/wallDistReflection/wallDistReflection.C diff --git a/src/finiteVolume/fvMesh/wallDist/wallDistReflection.H b/src/finiteVolume/fvMesh/wallDist/wallDistReflection/wallDistReflection.H similarity index 100% rename from src/finiteVolume/fvMesh/wallDist/wallDistReflection.H rename to src/finiteVolume/fvMesh/wallDist/wallDistReflection/wallDistReflection.H diff --git a/src/finiteVolume/fvMesh/wallDist/wallPointYPlus/wallPointYPlus.H b/src/finiteVolume/fvMesh/wallDist/wallPointYPlus/wallPointYPlus.H index 0bcfaf760..469cc86f4 100644 --- a/src/finiteVolume/fvMesh/wallDist/wallPointYPlus/wallPointYPlus.H +++ b/src/finiteVolume/fvMesh/wallDist/wallPointYPlus/wallPointYPlus.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -60,9 +60,6 @@ class wallPointYPlus : public wallPointData { - -private: - // Private Member Functions //- Evaluate distance to point. Update distSqr, origin from whomever @@ -77,6 +74,7 @@ private: TrackingData& td ); + public: // Static data members @@ -154,7 +152,6 @@ inline bool contiguous() // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - } // End namespace Foam // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // diff --git a/src/regionModels/surfaceFilmModels/submodels/kinematic/force/contactAngleForce/contactAngleForce.C b/src/regionModels/surfaceFilmModels/submodels/kinematic/force/contactAngleForce/contactAngleForce.C index 2044f1fb7..a10cf4204 100644 --- a/src/regionModels/surfaceFilmModels/submodels/kinematic/force/contactAngleForce/contactAngleForce.C +++ b/src/regionModels/surfaceFilmModels/submodels/kinematic/force/contactAngleForce/contactAngleForce.C @@ -68,7 +68,7 @@ void contactAngleForce::initialise() patchDist dist(owner_.regionMesh(), patchIDs); - mask_ = pos(dist - dimensionedScalar("dLim", dimLength, dLim)); + mask_ = pos(dist.y() - dimensionedScalar("dLim", dimLength, dLim)); } }