From a52cae9102fe02d43dff6c8c480ee342fc808096 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Wed, 2 Dec 2015 15:39:45 +0000 Subject: [PATCH 001/447] reactingEulerFoam: Lookup fvOptions from the mesh rather than construct a local copy --- .../reactingEulerFoam/phaseSystems/phaseSystem/phaseSystem.C | 3 +-- .../reactingEulerFoam/phaseSystems/phaseSystem/phaseSystem.H | 3 --- .../reactingEulerFoam/phaseSystems/phaseSystem/phaseSystemI.H | 2 +- 3 files changed, 2 insertions(+), 6 deletions(-) diff --git a/applications/solvers/multiphase/reactingEulerFoam/phaseSystems/phaseSystem/phaseSystem.C b/applications/solvers/multiphase/reactingEulerFoam/phaseSystems/phaseSystem/phaseSystem.C index 4efd86189b..4202907a2e 100644 --- a/applications/solvers/multiphase/reactingEulerFoam/phaseSystems/phaseSystem/phaseSystem.C +++ b/applications/solvers/multiphase/reactingEulerFoam/phaseSystems/phaseSystem/phaseSystem.C @@ -154,8 +154,7 @@ Foam::phaseSystem::phaseSystem dimensionedScalar("dpdt", dimPressure/dimTime, 0) ), - MRF_(mesh_), - fvOptions_(mesh_) + MRF_(mesh_) { phi_.writeOpt() = IOobject::AUTO_WRITE; diff --git a/applications/solvers/multiphase/reactingEulerFoam/phaseSystems/phaseSystem/phaseSystem.H b/applications/solvers/multiphase/reactingEulerFoam/phaseSystems/phaseSystem/phaseSystem.H index c5ec2aa501..664add034f 100644 --- a/applications/solvers/multiphase/reactingEulerFoam/phaseSystems/phaseSystem/phaseSystem.H +++ b/applications/solvers/multiphase/reactingEulerFoam/phaseSystems/phaseSystem/phaseSystem.H @@ -176,9 +176,6 @@ protected: //- Optional MRF zones IOMRFZoneList MRF_; - //- Optional FV-options - mutable fv::options fvOptions_; - //- Blending methods blendingMethodTable blendingMethods_; diff --git a/applications/solvers/multiphase/reactingEulerFoam/phaseSystems/phaseSystem/phaseSystemI.H b/applications/solvers/multiphase/reactingEulerFoam/phaseSystems/phaseSystem/phaseSystemI.H index 125d286d9d..7f0e73be56 100644 --- a/applications/solvers/multiphase/reactingEulerFoam/phaseSystems/phaseSystem/phaseSystemI.H +++ b/applications/solvers/multiphase/reactingEulerFoam/phaseSystems/phaseSystem/phaseSystemI.H @@ -84,7 +84,7 @@ inline const Foam::IOMRFZoneList& Foam::phaseSystem::MRF() const inline Foam::fv::options& Foam::phaseSystem::fvOptions() const { - return fvOptions_; + return fv::options::New(mesh_); } From 633e2b1255c5bb3a843929caea6b9ebd23f48c32 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Wed, 2 Dec 2015 18:18:06 +0000 Subject: [PATCH 002/447] Minor updates to aid porting to FreeBSD Based on patches provided by Jason Bacon --- .../mesh/generation/foamyMesh/foamyQuadMesh/CV2DI.H | 4 ++-- src/OSspecific/POSIX/fileStat.C | 3 +-- src/OpenFOAM/primitives/ints/uint/uintIO.C | 6 +++--- src/OpenFOAM/primitives/ints/uint32/uint32.H | 2 +- src/OpenFOAM/primitives/ints/uint64/uint64.H | 2 +- 5 files changed, 8 insertions(+), 9 deletions(-) diff --git a/applications/utilities/mesh/generation/foamyMesh/foamyQuadMesh/CV2DI.H b/applications/utilities/mesh/generation/foamyMesh/foamyQuadMesh/CV2DI.H index 9e04cdcbbf..70319d5088 100644 --- a/applications/utilities/mesh/generation/foamyMesh/foamyQuadMesh/CV2DI.H +++ b/applications/utilities/mesh/generation/foamyMesh/foamyQuadMesh/CV2DI.H @@ -31,7 +31,7 @@ inline Foam::label Foam::CV2D::insertPoint const label type ) { - uint nVert = number_of_vertices(); + unsigned int nVert = number_of_vertices(); return insertPoint(toPoint(p), nVert, type); } @@ -55,7 +55,7 @@ inline Foam::label Foam::CV2D::insertPoint const label type ) { - uint nVert = number_of_vertices(); + unsigned int nVert = number_of_vertices(); Vertex_handle vh = insert(p); diff --git a/src/OSspecific/POSIX/fileStat.C b/src/OSspecific/POSIX/fileStat.C index bf04835f25..9826983d64 100644 --- a/src/OSspecific/POSIX/fileStat.C +++ b/src/OSspecific/POSIX/fileStat.C @@ -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 @@ -29,7 +29,6 @@ License #include #include -#include // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // diff --git a/src/OpenFOAM/primitives/ints/uint/uintIO.C b/src/OpenFOAM/primitives/ints/uint/uintIO.C index 859eb1f8f6..eb591db54c 100644 --- a/src/OpenFOAM/primitives/ints/uint/uintIO.C +++ b/src/OpenFOAM/primitives/ints/uint/uintIO.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -28,9 +28,9 @@ License // * * * * * * * * * * * * * * * IOstream Operators * * * * * * * * * * * * // -uint Foam::readUint(Istream& is) +unsigned int Foam::readUint(Istream& is) { - uint val; + unsigned int val; is >> val; return val; diff --git a/src/OpenFOAM/primitives/ints/uint32/uint32.H b/src/OpenFOAM/primitives/ints/uint32/uint32.H index 07058dcdcc..3b0ad01c7a 100644 --- a/src/OpenFOAM/primitives/ints/uint32/uint32.H +++ b/src/OpenFOAM/primitives/ints/uint32/uint32.H @@ -119,7 +119,7 @@ public: return p_; } - //- Access to the uint value + //- Access to the uint32_t value operator uint32_t&() { return p_; diff --git a/src/OpenFOAM/primitives/ints/uint64/uint64.H b/src/OpenFOAM/primitives/ints/uint64/uint64.H index c4f3b581c6..dc19659462 100644 --- a/src/OpenFOAM/primitives/ints/uint64/uint64.H +++ b/src/OpenFOAM/primitives/ints/uint64/uint64.H @@ -119,7 +119,7 @@ public: return p_; } - //- Access to the uint value + //- Access to the uint64_t value operator uint64_t&() { return p_; From 642690db30d30de1c8665a6e5c9f2d96c588cdc0 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Wed, 2 Dec 2015 20:33:00 +0000 Subject: [PATCH 003/447] kEpsilon: Minor update of the lookup of fvOptions --- src/TurbulenceModels/turbulenceModels/RAS/kEpsilon/kEpsilon.C | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/TurbulenceModels/turbulenceModels/RAS/kEpsilon/kEpsilon.C b/src/TurbulenceModels/turbulenceModels/RAS/kEpsilon/kEpsilon.C index 6a9266e8b0..1340268835 100644 --- a/src/TurbulenceModels/turbulenceModels/RAS/kEpsilon/kEpsilon.C +++ b/src/TurbulenceModels/turbulenceModels/RAS/kEpsilon/kEpsilon.C @@ -41,9 +41,7 @@ void kEpsilon::correctNut() { this->nut_ = Cmu_*sqr(k_)/epsilon_; this->nut_.correctBoundaryConditions(); - - fv::options& fvOptions(fv::options::New(this->mesh_)); - fvOptions.correct(this->nut_); + fv::options::New(this->mesh_).correct(this->nut_); BasicTurbulenceModel::correctNut(); } From 1a71623b469a0846534571f7d10ba441a9da26d4 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Wed, 2 Dec 2015 20:33:28 +0000 Subject: [PATCH 004/447] kOmega: Added support for fvOptions --- .../turbulenceModels/RAS/kOmega/kOmega.C | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/src/TurbulenceModels/turbulenceModels/RAS/kOmega/kOmega.C b/src/TurbulenceModels/turbulenceModels/RAS/kOmega/kOmega.C index 5f5e76c03f..81a986b07a 100644 --- a/src/TurbulenceModels/turbulenceModels/RAS/kOmega/kOmega.C +++ b/src/TurbulenceModels/turbulenceModels/RAS/kOmega/kOmega.C @@ -24,6 +24,7 @@ License \*---------------------------------------------------------------------------*/ #include "kOmega.H" +#include "fvOptions.H" #include "bound.H" // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -33,7 +34,6 @@ namespace Foam namespace RASModels { - // * * * * * * * * * * * * Protected Member Functions * * * * * * * * * * * // template @@ -41,6 +41,9 @@ void kOmega::correctNut() { this->nut_ = k_/omega_; this->nut_.correctBoundaryConditions(); + fv::options::New(this->mesh_).correct(this->nut_); + + BasicTurbulenceModel::correctNut(); } @@ -188,6 +191,7 @@ void kOmega::correct() const surfaceScalarField& alphaRhoPhi = this->alphaRhoPhi_; const volVectorField& U = this->U_; volScalarField& nut = this->nut_; + fv::options& fvOptions(fv::options::New(this->mesh_)); eddyViscosity >::correct(); @@ -214,13 +218,14 @@ void kOmega::correct() gamma_*alpha*rho*G*omega_/k_ - fvm::SuSp(((2.0/3.0)*gamma_)*alpha*rho*divU, omega_) - fvm::Sp(beta_*alpha*rho*omega_, omega_) + + fvOptions(alpha, rho, omega_) ); omegaEqn().relax(); - + fvOptions.constrain(omegaEqn()); omegaEqn().boundaryManipulate(omega_.boundaryField()); - solve(omegaEqn); + fvOptions.correct(omega_); bound(omega_, this->omegaMin_); @@ -234,10 +239,13 @@ void kOmega::correct() alpha*rho*G - fvm::SuSp((2.0/3.0)*alpha*rho*divU, k_) - fvm::Sp(Cmu_*alpha*rho*omega_, k_) + + fvOptions(alpha, rho, k_) ); kEqn().relax(); + fvOptions.constrain(kEqn()); solve(kEqn); + fvOptions.correct(k_); bound(k_, this->kMin_); correctNut(); From c005f6d68c36258a70c0fdd3a6876b60bee2b2e9 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Wed, 2 Dec 2015 20:33:43 +0000 Subject: [PATCH 005/447] kOmegaSST: Added support for fvOptions --- .../turbulenceModels/RAS/kOmegaSST/kOmegaSST.C | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/src/TurbulenceModels/turbulenceModels/RAS/kOmegaSST/kOmegaSST.C b/src/TurbulenceModels/turbulenceModels/RAS/kOmegaSST/kOmegaSST.C index 223492ba88..3255ff3411 100644 --- a/src/TurbulenceModels/turbulenceModels/RAS/kOmegaSST/kOmegaSST.C +++ b/src/TurbulenceModels/turbulenceModels/RAS/kOmegaSST/kOmegaSST.C @@ -24,6 +24,7 @@ License \*---------------------------------------------------------------------------*/ #include "kOmegaSST.H" +#include "fvOptions.H" #include "bound.H" #include "wallDist.H" @@ -112,6 +113,7 @@ void kOmegaSST::correctNut(const volScalarField& S2) { this->nut_ = a1_*k_/max(a1_*omega_, b1_*F23()*sqrt(S2)); this->nut_.correctBoundaryConditions(); + fv::options::New(this->mesh_).correct(this->nut_); BasicTurbulenceModel::correctNut(); } @@ -399,6 +401,7 @@ void kOmegaSST::correct() const surfaceScalarField& alphaRhoPhi = this->alphaRhoPhi_; const volVectorField& U = this->U_; volScalarField& nut = this->nut_; + fv::options& fvOptions(fv::options::New(this->mesh_)); eddyViscosity >::correct(); @@ -446,13 +449,14 @@ void kOmegaSST::correct() ) + Qsas(S2, gamma, beta) + omegaSource() + + fvOptions(alpha, rho, omega_) ); omegaEqn().relax(); - + fvOptions.constrain(omegaEqn()); omegaEqn().boundaryManipulate(omega_.boundaryField()); - solve(omegaEqn); + fvOptions.correct(omega_); bound(omega_, this->omegaMin_); } @@ -467,10 +471,13 @@ void kOmegaSST::correct() - fvm::SuSp((2.0/3.0)*alpha*rho*divU, k_) - fvm::Sp(alpha*rho*betaStar_*omega_, k_) + kSource() + + fvOptions(alpha, rho, k_) ); kEqn().relax(); + fvOptions.constrain(kEqn()); solve(kEqn); + fvOptions.correct(k_); bound(k_, this->kMin_); correctNut(S2); From 820529b0e6bfad8ef2f4100936a239011a9525e1 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Thu, 3 Dec 2015 08:40:56 +0000 Subject: [PATCH 006/447] foamInstallationTest: Updated help message --- bin/foamInstallationTest | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bin/foamInstallationTest b/bin/foamInstallationTest index ed4bb9c782..17b285a5ab 100755 --- a/bin/foamInstallationTest +++ b/bin/foamInstallationTest @@ -344,9 +344,9 @@ checkOpenFOAMEnvironment() echo "" echo "FATAL ERROR: OpenFOAM environment not configured." echo "" - echo " Please refer to the installation section of the README file:" - echo " /OpenFOAM-${WM_PROJECT_VERSION}/README" - echo " to source the OpenFOAM environment." + echo " Please follow the download and installation link in README.html:" + echo " /OpenFOAM-${WM_PROJECT_VERSION}/README.html" + echo " for information on setting-up the OpenFOAM environment." echo "" exit 1 } From 5e5e22f5f0fc7296e2276849921f824e0a7e2fab Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Thu, 3 Dec 2015 08:41:39 +0000 Subject: [PATCH 007/447] RNGkEpsilon: Added support for fvOptions --- .../turbulenceModels/RAS/RNGkEpsilon/RNGkEpsilon.C | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/src/TurbulenceModels/turbulenceModels/RAS/RNGkEpsilon/RNGkEpsilon.C b/src/TurbulenceModels/turbulenceModels/RAS/RNGkEpsilon/RNGkEpsilon.C index 1eec3da8a9..cc473482bb 100644 --- a/src/TurbulenceModels/turbulenceModels/RAS/RNGkEpsilon/RNGkEpsilon.C +++ b/src/TurbulenceModels/turbulenceModels/RAS/RNGkEpsilon/RNGkEpsilon.C @@ -24,6 +24,7 @@ License \*---------------------------------------------------------------------------*/ #include "RNGkEpsilon.H" +#include "fvOptions.H" #include "bound.H" // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -40,6 +41,7 @@ void RNGkEpsilon::correctNut() { this->nut_ = Cmu_*sqr(k_)/epsilon_; this->nut_.correctBoundaryConditions(); + fv::options::New(this->mesh_).correct(this->nut_); BasicTurbulenceModel::correctNut(); } @@ -249,6 +251,7 @@ void RNGkEpsilon::correct() const surfaceScalarField& alphaRhoPhi = this->alphaRhoPhi_; const volVectorField& U = this->U_; volScalarField& nut = this->nut_; + fv::options& fvOptions(fv::options::New(this->mesh_)); eddyViscosity >::correct(); @@ -282,13 +285,14 @@ void RNGkEpsilon::correct() - fvm::SuSp(((2.0/3.0)*C1_ + C3_)*alpha*rho*divU, epsilon_) - fvm::Sp(C2_*alpha*rho*epsilon_/k_, epsilon_) + epsilonSource() + + fvOptions(alpha, rho, epsilon_) ); epsEqn().relax(); - + fvOptions.constrain(epsEqn()); epsEqn().boundaryManipulate(epsilon_.boundaryField()); - solve(epsEqn); + fvOptions.correct(epsilon_); bound(epsilon_, this->epsilonMin_); @@ -304,10 +308,13 @@ void RNGkEpsilon::correct() - fvm::SuSp((2.0/3.0)*alpha*rho*divU, k_) - fvm::Sp(alpha*rho*epsilon_/k_, k_) + kSource() + + fvOptions(alpha, rho, k_) ); kEqn().relax(); + fvOptions.constrain(kEqn()); solve(kEqn); + fvOptions.correct(k_); bound(k_, this->kMin_); correctNut(); From e94f1385e5b339c9220938a312cc1a6dacae18a6 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Thu, 3 Dec 2015 08:42:08 +0000 Subject: [PATCH 008/447] realizableKE: Added support for fvOptions --- .../turbulenceModels/RAS/realizableKE/realizableKE.C | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/src/TurbulenceModels/turbulenceModels/RAS/realizableKE/realizableKE.C b/src/TurbulenceModels/turbulenceModels/RAS/realizableKE/realizableKE.C index 81212cb410..d955b973ef 100644 --- a/src/TurbulenceModels/turbulenceModels/RAS/realizableKE/realizableKE.C +++ b/src/TurbulenceModels/turbulenceModels/RAS/realizableKE/realizableKE.C @@ -24,6 +24,7 @@ License \*---------------------------------------------------------------------------*/ #include "realizableKE.H" +#include "fvOptions.H" #include "bound.H" // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -78,6 +79,7 @@ void realizableKE::correctNut { this->nut_ = rCmu(gradU, S2, magS)*sqr(k_)/epsilon_; this->nut_.correctBoundaryConditions(); + fv::options::New(this->mesh_).correct(this->nut_); BasicTurbulenceModel::correctNut(); } @@ -267,6 +269,7 @@ void realizableKE::correct() const surfaceScalarField& alphaRhoPhi = this->alphaRhoPhi_; const volVectorField& U = this->U_; volScalarField& nut = this->nut_; + fv::options& fvOptions(fv::options::New(this->mesh_)); eddyViscosity >::correct(); @@ -298,13 +301,14 @@ void realizableKE::correct() epsilon_ ) + epsilonSource() + + fvOptions(alpha, rho, epsilon_) ); epsEqn().relax(); - + fvOptions.constrain(epsEqn()); epsEqn().boundaryManipulate(epsilon_.boundaryField()); - solve(epsEqn); + fvOptions.correct(epsilon_); bound(epsilon_, this->epsilonMin_); @@ -320,10 +324,13 @@ void realizableKE::correct() - fvm::SuSp(2.0/3.0*alpha*rho*divU, k_) - fvm::Sp(alpha*rho*epsilon_/k_, k_) + kSource() + + fvOptions(alpha, rho, k_) ); kEqn().relax(); + fvOptions.constrain(kEqn()); solve(kEqn); + fvOptions.correct(k_); bound(k_, this->kMin_); correctNut(tgradU(), S2, magS); From 8d9f56d1b7de5df5e94864835c12d682adac51eb Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Thu, 3 Dec 2015 08:43:31 +0000 Subject: [PATCH 009/447] SpalartAllmaras: Added support for fvOptions --- .../turbulenceModels/RAS/SpalartAllmaras/SpalartAllmaras.C | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/TurbulenceModels/turbulenceModels/RAS/SpalartAllmaras/SpalartAllmaras.C b/src/TurbulenceModels/turbulenceModels/RAS/SpalartAllmaras/SpalartAllmaras.C index a029db7ad3..0883ea88e5 100644 --- a/src/TurbulenceModels/turbulenceModels/RAS/SpalartAllmaras/SpalartAllmaras.C +++ b/src/TurbulenceModels/turbulenceModels/RAS/SpalartAllmaras/SpalartAllmaras.C @@ -24,6 +24,7 @@ License \*---------------------------------------------------------------------------*/ #include "SpalartAllmaras.H" +#include "fvOptions.H" #include "bound.H" #include "wallDist.H" @@ -124,6 +125,7 @@ void SpalartAllmaras::correctNut { this->nut_ = nuTilda_*fv1; this->nut_.correctBoundaryConditions(); + fv::options::New(this->mesh_).correct(this->nut_); BasicTurbulenceModel::correctNut(); } @@ -354,6 +356,7 @@ void SpalartAllmaras::correct() const alphaField& alpha = this->alpha_; const rhoField& rho = this->rho_; const surfaceScalarField& alphaRhoPhi = this->alphaRhoPhi_; + fv::options& fvOptions(fv::options::New(this->mesh_)); eddyViscosity >::correct(); @@ -371,10 +374,13 @@ void SpalartAllmaras::correct() == Cb1_*alpha*rho*Stilda*nuTilda_ - fvm::Sp(Cw1_*alpha*rho*fw(Stilda)*nuTilda_/sqr(y_), nuTilda_) + + fvOptions(alpha, rho, nuTilda_) ); nuTildaEqn().relax(); + fvOptions.constrain(nuTildaEqn()); solve(nuTildaEqn); + fvOptions.correct(nuTilda_); bound(nuTilda_, dimensionedScalar("0", nuTilda_.dimensions(), 0.0)); nuTilda_.correctBoundaryConditions(); From 95687c59ec262a3f5fe3048b3114ecfca158028a Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Thu, 3 Dec 2015 09:15:09 +0000 Subject: [PATCH 010/447] wallShearStress: Now may be used with any turbulence model (laminar, RAS or LES/DES) Resolves feature-request http://www.openfoam.org/mantisbt/view.php?id=1939 --- .../wall/wallShearStress/wallShearStress.C | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) diff --git a/applications/utilities/postProcessing/wall/wallShearStress/wallShearStress.C b/applications/utilities/postProcessing/wall/wallShearStress/wallShearStress.C index 6f6609c2fd..b834cd1871 100644 --- a/applications/utilities/postProcessing/wall/wallShearStress/wallShearStress.C +++ b/applications/utilities/postProcessing/wall/wallShearStress/wallShearStress.C @@ -25,8 +25,8 @@ Application wallShearStress Description - Calculates and reports wall shear stress for all patches, for the - specified times when using RAS turbulence models. + Calculates and reports the turbulent wall shear stress for all patches, + for the specified times. Compressible modes is automatically selected based on the existence of the "thermophysicalProperties" dictionary required to construct the @@ -53,9 +53,9 @@ void calcIncompressible singlePhaseTransportModel laminarTransport(U, phi); - autoPtr model + autoPtr model ( - incompressible::New(U, phi, laminarTransport) + incompressible::turbulenceModel::New(U, phi, laminarTransport) ); const volSymmTensorField Reff(model->devReff()); @@ -102,15 +102,9 @@ void calcCompressible autoPtr pThermo(fluidThermo::New(mesh)); fluidThermo& thermo = pThermo(); - autoPtr model + autoPtr model ( - compressible::New - ( - rho, - U, - phi, - thermo - ) + compressible::turbulenceModel::New(rho, U, phi, thermo) ); const volSymmTensorField Reff(model->devRhoReff()); From a749019302b4153902097c7cb1eecf0d84681f52 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Thu, 3 Dec 2015 13:11:27 +0000 Subject: [PATCH 011/447] LaunderSharmaKE: Added support for fvOptions --- .../RAS/LaunderSharmaKE/LaunderSharmaKE.C | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/TurbulenceModels/turbulenceModels/RAS/LaunderSharmaKE/LaunderSharmaKE.C b/src/TurbulenceModels/turbulenceModels/RAS/LaunderSharmaKE/LaunderSharmaKE.C index d3fca3307b..e5fa331c72 100644 --- a/src/TurbulenceModels/turbulenceModels/RAS/LaunderSharmaKE/LaunderSharmaKE.C +++ b/src/TurbulenceModels/turbulenceModels/RAS/LaunderSharmaKE/LaunderSharmaKE.C @@ -24,6 +24,7 @@ License \*---------------------------------------------------------------------------*/ #include "LaunderSharmaKE.H" +#include "fvOptions.H" #include "bound.H" // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -56,6 +57,7 @@ void LaunderSharmaKE::correctNut() { this->nut_ = Cmu_*fMu()*sqr(k_)/epsilon_; this->nut_.correctBoundaryConditions(); + fv::options::New(this->mesh_).correct(this->nut_); BasicTurbulenceModel::correctNut(); } @@ -246,6 +248,7 @@ void LaunderSharmaKE::correct() const surfaceScalarField& alphaRhoPhi = this->alphaRhoPhi_; const volVectorField& U = this->U_; volScalarField& nut = this->nut_; + fv::options& fvOptions(fv::options::New(this->mesh_)); eddyViscosity >::correct(); @@ -274,10 +277,14 @@ void LaunderSharmaKE::correct() - fvm::Sp(C2_*f2()*alpha*rho*epsilon_/k_, epsilon_) + alpha*rho*E + epsilonSource() + + fvOptions(alpha, rho, epsilon_) ); epsEqn().relax(); + fvOptions.constrain(epsEqn()); + epsEqn().boundaryManipulate(epsilon_.boundaryField()); solve(epsEqn); + fvOptions.correct(epsilon_); bound(epsilon_, this->epsilonMin_); @@ -291,10 +298,13 @@ void LaunderSharmaKE::correct() alpha*rho*G - fvm::SuSp(2.0/3.0*alpha*rho*divU, k_) - fvm::Sp(alpha*rho*(epsilon_ + D)/k_, k_) + kSource() + + fvOptions(alpha, rho, k_) ); kEqn().relax(); + fvOptions.constrain(kEqn()); solve(kEqn); + fvOptions.correct(k_); bound(k_, this->kMin_); correctNut(); From 5f7ad8b82bc1f1a5412603eec310e240e4f447ad Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Thu, 3 Dec 2015 13:11:49 +0000 Subject: [PATCH 012/447] v2f: Added support for fvOptions --- .../turbulenceModels/RAS/v2f/v2f.C | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/src/TurbulenceModels/turbulenceModels/RAS/v2f/v2f.C b/src/TurbulenceModels/turbulenceModels/RAS/v2f/v2f.C index 4a76ee1870..df1597cba3 100644 --- a/src/TurbulenceModels/turbulenceModels/RAS/v2f/v2f.C +++ b/src/TurbulenceModels/turbulenceModels/RAS/v2f/v2f.C @@ -24,6 +24,7 @@ License \*---------------------------------------------------------------------------*/ #include "v2f.H" +#include "fvOptions.H" #include "bound.H" // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -56,6 +57,7 @@ void v2f::correctNut() { this->nut_ = min(CmuKEps_*sqr(k_)/epsilon_, this->Cmu_*v2_*Ts()); this->nut_.correctBoundaryConditions(); + fv::options::New(this->mesh_).correct(this->nut_); BasicTurbulenceModel::correctNut(); } @@ -284,6 +286,7 @@ void v2f::correct() const surfaceScalarField& alphaRhoPhi = this->alphaRhoPhi_; const volVectorField& U = this->U_; volScalarField& nut = this->nut_; + fv::options& fvOptions(fv::options::New(this->mesh_)); eddyViscosity >::correct(); @@ -323,13 +326,14 @@ void v2f::correct() Ceps1*alpha*rho*G/Ts - fvm::SuSp(((2.0/3.0)*Ceps1 + Ceps3_)*alpha*rho*divU, epsilon_) - fvm::Sp(Ceps2_*alpha*rho/Ts, epsilon_) + + fvOptions(alpha, rho, epsilon_) ); epsEqn().relax(); - + fvOptions.constrain(epsEqn()); epsEqn().boundaryManipulate(epsilon_.boundaryField()); - solve(epsEqn); + fvOptions.correct(epsilon_); bound(epsilon_, this->epsilonMin_); @@ -343,10 +347,13 @@ void v2f::correct() alpha*rho*G - fvm::SuSp((2.0/3.0)*alpha*rho*divU, k_) - fvm::Sp(alpha*rho*epsilon_/k_, k_) + + fvOptions(alpha, rho, k_) ); kEqn().relax(); + fvOptions.constrain(kEqn()); solve(kEqn); + fvOptions.correct(k_); bound(k_, this->kMin_); @@ -357,10 +364,13 @@ void v2f::correct() == - fvm::Sp(1.0/L2, f_) - 1.0/L2/k_*(v2fAlpha - C2_*G) + + fvOptions(alpha, rho, f_) ); fEqn().relax(); + fvOptions.constrain(fEqn()); solve(fEqn); + fvOptions.correct(f_); bound(f_, fMin_); @@ -373,10 +383,13 @@ void v2f::correct() == alpha*rho*min(k_*f_, C2_*G - v2fAlpha) - fvm::Sp(N*alpha*rho*epsilon_/k_, v2_) + + fvOptions(alpha, rho, v2_) ); v2Eqn().relax(); + fvOptions.constrain(v2Eqn()); solve(v2Eqn); + fvOptions.correct(v2_); bound(v2_, v2Min_); correctNut(); From a6f4bf60b8dc40feba7d099effa5cda257a30ee4 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Thu, 3 Dec 2015 13:12:10 +0000 Subject: [PATCH 013/447] LRR: Added support for fvOptions --- src/TurbulenceModels/turbulenceModels/RAS/LRR/LRR.C | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/src/TurbulenceModels/turbulenceModels/RAS/LRR/LRR.C b/src/TurbulenceModels/turbulenceModels/RAS/LRR/LRR.C index 2b8be52762..a955b9a205 100644 --- a/src/TurbulenceModels/turbulenceModels/RAS/LRR/LRR.C +++ b/src/TurbulenceModels/turbulenceModels/RAS/LRR/LRR.C @@ -24,6 +24,7 @@ License \*---------------------------------------------------------------------------*/ #include "LRR.H" +#include "fvOptions.H" #include "wallFvPatch.H" // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -40,6 +41,7 @@ void LRR::correctNut() { this->nut_ = this->Cmu_*sqr(k_)/epsilon_; this->nut_.correctBoundaryConditions(); + fv::options::New(this->mesh_).correct(this->nut_); BasicTurbulenceModel::correctNut(); } @@ -280,6 +282,7 @@ void LRR::correct() const surfaceScalarField& alphaRhoPhi = this->alphaRhoPhi_; const volVectorField& U = this->U_; volSymmTensorField& R = this->R_; + fv::options& fvOptions(fv::options::New(this->mesh_)); ReynoldsStress >::correct(); @@ -301,13 +304,14 @@ void LRR::correct() == Ceps1_*alpha*rho*G*epsilon_/k_ - fvm::Sp(Ceps2_*alpha*rho*epsilon_/k_, epsilon_) + + fvOptions(alpha, rho, epsilon_) ); epsEqn().relax(); - + fvOptions.constrain(epsEqn()); epsEqn().boundaryManipulate(epsilon_.boundaryField()); - solve(epsEqn); + fvOptions.correct(epsilon_); bound(epsilon_, this->epsilonMin_); @@ -344,6 +348,7 @@ void LRR::correct() alpha*rho*P - (2.0/3.0*(1 - C1_)*I)*alpha*rho*epsilon_ - C2_*alpha*rho*dev(P) + + fvOptions(alpha, rho, R) ); // Optionally add wall-refection term @@ -363,7 +368,9 @@ void LRR::correct() } REqn().relax(); + fvOptions.constrain(REqn()); solve(REqn); + fvOptions.correct(R); this->boundNormalStress(R); From 05fa38f5e3125950733791f1aa9725e500f3f5a8 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Thu, 3 Dec 2015 13:12:27 +0000 Subject: [PATCH 014/447] SSG: Added support for fvOptions --- src/TurbulenceModels/turbulenceModels/RAS/SSG/SSG.C | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/src/TurbulenceModels/turbulenceModels/RAS/SSG/SSG.C b/src/TurbulenceModels/turbulenceModels/RAS/SSG/SSG.C index 9f9cc53464..3e30c1fbed 100644 --- a/src/TurbulenceModels/turbulenceModels/RAS/SSG/SSG.C +++ b/src/TurbulenceModels/turbulenceModels/RAS/SSG/SSG.C @@ -24,6 +24,7 @@ License \*---------------------------------------------------------------------------*/ #include "SSG.H" +#include "fvOptions.H" #include "wallFvPatch.H" // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -40,6 +41,7 @@ void SSG::correctNut() { this->nut_ = this->Cmu_*sqr(k_)/epsilon_; this->nut_.correctBoundaryConditions(); + fv::options::New(this->mesh_).correct(this->nut_); BasicTurbulenceModel::correctNut(); } @@ -290,6 +292,7 @@ void SSG::correct() const surfaceScalarField& alphaRhoPhi = this->alphaRhoPhi_; const volVectorField& U = this->U_; volSymmTensorField& R = this->R_; + fv::options& fvOptions(fv::options::New(this->mesh_)); ReynoldsStress >::correct(); @@ -311,13 +314,14 @@ void SSG::correct() == Ceps1_*alpha*rho*G*epsilon_/k_ - fvm::Sp(Ceps2_*alpha*rho*epsilon_/k_, epsilon_) + + fvOptions(alpha, rho, epsilon_) ); epsEqn().relax(); - + fvOptions.constrain(epsEqn()); epsEqn().boundaryManipulate(epsilon_.boundaryField()); - solve(epsEqn); + fvOptions.correct(epsilon_); bound(epsilon_, this->epsilonMin_); @@ -364,10 +368,13 @@ void SSG::correct() + C4_*dev(twoSymm(b&S)) + C5_*twoSymm(b&Omega) ) + + fvOptions(alpha, rho, R) ); REqn().relax(); + fvOptions.constrain(REqn()); solve(REqn); + fvOptions.correct(R); this->boundNormalStress(R); From e8f532f8571a9382716f4114ea040147ab6cda41 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Thu, 3 Dec 2015 13:39:55 +0000 Subject: [PATCH 015/447] turbulenceModels/LES/kEqn: Added support for fvOptions --- src/TurbulenceModels/turbulenceModels/LES/kEqn/kEqn.C | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/TurbulenceModels/turbulenceModels/LES/kEqn/kEqn.C b/src/TurbulenceModels/turbulenceModels/LES/kEqn/kEqn.C index ef2b2b8535..4a87768c10 100644 --- a/src/TurbulenceModels/turbulenceModels/LES/kEqn/kEqn.C +++ b/src/TurbulenceModels/turbulenceModels/LES/kEqn/kEqn.C @@ -24,6 +24,7 @@ License \*---------------------------------------------------------------------------*/ #include "kEqn.H" +#include "fvOptions.H" // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -39,6 +40,7 @@ void kEqn::correctNut() { this->nut_ = Ck_*sqrt(k_)*this->delta(); this->nut_.correctBoundaryConditions(); + fv::options::New(this->mesh_).correct(this->nut_); BasicTurbulenceModel::correctNut(); } @@ -171,6 +173,7 @@ void kEqn::correct() const surfaceScalarField& alphaRhoPhi = this->alphaRhoPhi_; const volVectorField& U = this->U_; volScalarField& nut = this->nut_; + fv::options& fvOptions(fv::options::New(this->mesh_)); LESeddyViscosity::correct(); @@ -190,10 +193,13 @@ void kEqn::correct() - fvm::SuSp((2.0/3.0)*alpha*rho*divU, k_) - fvm::Sp(this->Ce_*alpha*rho*sqrt(k_)/this->delta(), k_) + kSource() + + fvOptions(alpha, rho, k_) ); kEqn().relax(); + fvOptions.constrain(kEqn()); solve(kEqn); + fvOptions.correct(k_); bound(k_, this->kMin_); correctNut(); From 2ddf4b7793362ac6d7dd7668b5505cecabed789c Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Thu, 3 Dec 2015 13:40:32 +0000 Subject: [PATCH 016/447] turbulenceModels/LES/Smagorinsky: Added support for fvOptions --- .../turbulenceModels/LES/Smagorinsky/Smagorinsky.C | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/TurbulenceModels/turbulenceModels/LES/Smagorinsky/Smagorinsky.C b/src/TurbulenceModels/turbulenceModels/LES/Smagorinsky/Smagorinsky.C index 9827f76063..8f11a96b9e 100644 --- a/src/TurbulenceModels/turbulenceModels/LES/Smagorinsky/Smagorinsky.C +++ b/src/TurbulenceModels/turbulenceModels/LES/Smagorinsky/Smagorinsky.C @@ -24,6 +24,7 @@ License \*---------------------------------------------------------------------------*/ #include "Smagorinsky.H" +#include "fvOptions.H" // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -69,6 +70,7 @@ void Smagorinsky::correctNut() this->nut_ = Ck_*this->delta()*sqrt(k); this->nut_.correctBoundaryConditions(); + fv::options::New(this->mesh_).correct(this->nut_); BasicTurbulenceModel::correctNut(); } From cb31786753dc2360bb53c73f531b0a3a4b195ed3 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Thu, 3 Dec 2015 13:48:20 +0000 Subject: [PATCH 017/447] turbulenceModels/LES/WALE: Added support for fvOptions --- src/TurbulenceModels/turbulenceModels/LES/WALE/WALE.C | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/TurbulenceModels/turbulenceModels/LES/WALE/WALE.C b/src/TurbulenceModels/turbulenceModels/LES/WALE/WALE.C index 49a353ba1d..e70ff8fabf 100644 --- a/src/TurbulenceModels/turbulenceModels/LES/WALE/WALE.C +++ b/src/TurbulenceModels/turbulenceModels/LES/WALE/WALE.C @@ -24,6 +24,7 @@ License \*---------------------------------------------------------------------------*/ #include "WALE.H" +#include "fvOptions.H" // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -89,6 +90,7 @@ void WALE::correctNut() { this->nut_ = Ck_*this->delta()*sqrt(this->k(fvc::grad(this->U_))); this->nut_.correctBoundaryConditions(); + fv::options::New(this->mesh_).correct(this->nut_); BasicTurbulenceModel::correctNut(); } From 248526928326f20900000907f0ba74f4252db53a Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Thu, 3 Dec 2015 13:48:42 +0000 Subject: [PATCH 018/447] turbulenceModels/LES/dynamicKEqn: Added support for fvOptions --- .../turbulenceModels/LES/dynamicKEqn/dynamicKEqn.C | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/TurbulenceModels/turbulenceModels/LES/dynamicKEqn/dynamicKEqn.C b/src/TurbulenceModels/turbulenceModels/LES/dynamicKEqn/dynamicKEqn.C index ac076991e8..1b61975899 100644 --- a/src/TurbulenceModels/turbulenceModels/LES/dynamicKEqn/dynamicKEqn.C +++ b/src/TurbulenceModels/turbulenceModels/LES/dynamicKEqn/dynamicKEqn.C @@ -24,6 +24,7 @@ License \*---------------------------------------------------------------------------*/ #include "dynamicKEqn.H" +#include "fvOptions.H" // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -107,6 +108,9 @@ void dynamicKEqn::correctNut { this->nut_ = Ck(D, KK)*sqrt(k_)*this->delta(); this->nut_.correctBoundaryConditions(); + fv::options::New(this->mesh_).correct(this->nut_); + + BasicTurbulenceModel::correctNut(); } @@ -243,6 +247,7 @@ void dynamicKEqn::correct() const surfaceScalarField& alphaRhoPhi = this->alphaRhoPhi_; const volVectorField& U = this->U_; volScalarField& nut = this->nut_; + fv::options& fvOptions(fv::options::New(this->mesh_)); LESeddyViscosity::correct(); @@ -266,10 +271,13 @@ void dynamicKEqn::correct() - fvm::SuSp((2.0/3.0)*alpha*rho*divU, k_) - fvm::Sp(Ce(D, KK)*alpha*rho*sqrt(k_)/this->delta(), k_) + kSource() + + fvOptions(alpha, rho, k_) ); kEqn().relax(); - kEqn().solve(); + fvOptions.constrain(kEqn()); + solve(kEqn); + fvOptions.correct(k_); bound(k_, this->kMin_); correctNut(D, KK); From 1ae82d6e0c20d643e529745029d8d0872a727390 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Thu, 3 Dec 2015 14:52:48 +0000 Subject: [PATCH 019/447] turbulenceModels/LES/dynamicLagrangian: Added support for fvOptions --- .../LES/dynamicLagrangian/dynamicLagrangian.C | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/src/TurbulenceModels/turbulenceModels/LES/dynamicLagrangian/dynamicLagrangian.C b/src/TurbulenceModels/turbulenceModels/LES/dynamicLagrangian/dynamicLagrangian.C index 6a6fb02b93..c0267708f5 100644 --- a/src/TurbulenceModels/turbulenceModels/LES/dynamicLagrangian/dynamicLagrangian.C +++ b/src/TurbulenceModels/turbulenceModels/LES/dynamicLagrangian/dynamicLagrangian.C @@ -24,6 +24,7 @@ License \*---------------------------------------------------------------------------*/ #include "dynamicLagrangian.H" +#include "fvOptions.H" // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -42,6 +43,9 @@ void dynamicLagrangian::correctNut { this->nut_ = (flm_/fmm_)*sqr(this->delta())*mag(dev(symm(gradU))); this->nut_.correctBoundaryConditions(); + fv::options::New(this->mesh_).correct(this->nut_); + + BasicTurbulenceModel::correctNut(); } @@ -157,6 +161,7 @@ void dynamicLagrangian::correct() // Local references const surfaceScalarField& phi = this->phi_; const volVectorField& U = this->U_; + fv::options& fvOptions(fv::options::New(this->mesh_)); LESeddyViscosity::correct(); @@ -190,11 +195,13 @@ void dynamicLagrangian::correct() == invT*LM - fvm::Sp(invT, flm_) + + fvOptions(flm_) ); flmEqn.relax(); + fvOptions.constrain(flmEqn); flmEqn.solve(); - + fvOptions.correct(flm_); bound(flm_, flm0_); volScalarField MM(M && M); @@ -206,11 +213,13 @@ void dynamicLagrangian::correct() == invT*MM - fvm::Sp(invT, fmm_) + + fvOptions(fmm_) ); fmmEqn.relax(); + fvOptions.constrain(fmmEqn); fmmEqn.solve(); - + fvOptions.correct(fmm_); bound(fmm_, fmm0_); correctNut(gradU); From 154893db0f4e228882cae673a6e28ab62444e54f Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Thu, 3 Dec 2015 14:53:12 +0000 Subject: [PATCH 020/447] turbulenceModels/LES/SpalartAllmarasDES: Added support for fvOptions --- .../LES/SpalartAllmarasDES/SpalartAllmarasDES.C | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/TurbulenceModels/turbulenceModels/LES/SpalartAllmarasDES/SpalartAllmarasDES.C b/src/TurbulenceModels/turbulenceModels/LES/SpalartAllmarasDES/SpalartAllmarasDES.C index ed5cae80da..02f35be372 100644 --- a/src/TurbulenceModels/turbulenceModels/LES/SpalartAllmarasDES/SpalartAllmarasDES.C +++ b/src/TurbulenceModels/turbulenceModels/LES/SpalartAllmarasDES/SpalartAllmarasDES.C @@ -24,6 +24,7 @@ License \*---------------------------------------------------------------------------*/ #include "SpalartAllmarasDES.H" +#include "fvOptions.H" // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -170,6 +171,7 @@ void SpalartAllmarasDES::correctNut { this->nut_ = nuTilda_*fv1; this->nut_.correctBoundaryConditions(); + fv::options::New(this->mesh_).correct(this->nut_); BasicTurbulenceModel::correctNut(); } @@ -412,6 +414,7 @@ void SpalartAllmarasDES::correct() const rhoField& rho = this->rho_; const surfaceScalarField& alphaRhoPhi = this->alphaRhoPhi_; const volVectorField& U = this->U_; + fv::options& fvOptions(fv::options::New(this->mesh_)); LESeddyViscosity::correct(); @@ -436,11 +439,14 @@ void SpalartAllmarasDES::correct() Cw1_*alpha*rho*fw(Stilda, dTilda)*nuTilda_/sqr(dTilda), nuTilda_ ) + + fvOptions(alpha, rho, nuTilda_) ); nuTildaEqn().relax(); + fvOptions.constrain(nuTildaEqn()); solve(nuTildaEqn); - bound(nuTilda_, dimensionedScalar("zero", nuTilda_.dimensions(), 0.0)); + fvOptions.correct(nuTilda_); + bound(nuTilda_, dimensionedScalar("0", nuTilda_.dimensions(), 0.0)); nuTilda_.correctBoundaryConditions(); correctNut(fv1); From da2c319a8da2cec29ee02349ffbd949e98d9e1a3 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Thu, 3 Dec 2015 14:53:27 +0000 Subject: [PATCH 021/447] turbulenceModels/LES/DeardorffDiffStress: Added support for fvOptions --- .../LES/DeardorffDiffStress/DeardorffDiffStress.C | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/TurbulenceModels/turbulenceModels/LES/DeardorffDiffStress/DeardorffDiffStress.C b/src/TurbulenceModels/turbulenceModels/LES/DeardorffDiffStress/DeardorffDiffStress.C index e958e93324..921ed47cf9 100644 --- a/src/TurbulenceModels/turbulenceModels/LES/DeardorffDiffStress/DeardorffDiffStress.C +++ b/src/TurbulenceModels/turbulenceModels/LES/DeardorffDiffStress/DeardorffDiffStress.C @@ -24,6 +24,7 @@ License \*---------------------------------------------------------------------------*/ #include "DeardorffDiffStress.H" +#include "fvOptions.H" // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -39,6 +40,7 @@ void DeardorffDiffStress::correctNut() { this->nut_ = Ck_*sqrt(this->k())*this->delta(); this->nut_.correctBoundaryConditions(); + fv::options::New(this->mesh_).correct(this->nut_); BasicTurbulenceModel::correctNut(); } @@ -174,6 +176,7 @@ void DeardorffDiffStress::correct() const surfaceScalarField& alphaRhoPhi = this->alphaRhoPhi_; const volVectorField& U = this->U_; volSymmTensorField& R = this->R_; + fv::options& fvOptions(fv::options::New(this->mesh_)); ReynoldsStress >::correct(); @@ -196,12 +199,15 @@ void DeardorffDiffStress::correct() alpha*rho*P + (4.0/5.0)*alpha*rho*k*D - ((2.0/3.0)*(1.0 - Cm_/this->Ce_)*I)*(alpha*rho*this->epsilon()) + + fvOptions(alpha, rho, R) ); REqn().relax(); + fvOptions.constrain(REqn()); REqn().solve(); - + fvOptions.correct(R); this->boundNormalStress(R); + correctNut(); } From fde2866a8b895dfd524dcdbed143cd093c507b83 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Thu, 3 Dec 2015 15:37:05 +0000 Subject: [PATCH 022/447] TurbulenceModels/phaseCompressible/RAS/LaheyKEpsilon: Added support for fvOptions --- .../phaseCompressible/RAS/LaheyKEpsilon/LaheyKEpsilon.C | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/TurbulenceModels/phaseCompressible/RAS/LaheyKEpsilon/LaheyKEpsilon.C b/src/TurbulenceModels/phaseCompressible/RAS/LaheyKEpsilon/LaheyKEpsilon.C index 843ecc015d..f70d750ee0 100644 --- a/src/TurbulenceModels/phaseCompressible/RAS/LaheyKEpsilon/LaheyKEpsilon.C +++ b/src/TurbulenceModels/phaseCompressible/RAS/LaheyKEpsilon/LaheyKEpsilon.C @@ -24,9 +24,8 @@ License \*---------------------------------------------------------------------------*/ #include "LaheyKEpsilon.H" -#include "addToRunTimeSelectionTable.H" +#include "fvOptions.H" #include "twoPhaseSystem.H" -#include "dragModel.H" // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -176,6 +175,9 @@ void LaheyKEpsilon::correctNut() *(mag(this->U_ - gasTurbulence.U())); this->nut_.correctBoundaryConditions(); + fv::options::New(this->mesh_).correct(this->nut_); + + BasicTurbulenceModel::correctNut(); } From 934aa987d97f3510e882d26bb7c59d757189c460 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Thu, 3 Dec 2015 15:43:27 +0000 Subject: [PATCH 023/447] TurbulenceModels/phaseCompressible/RAS/mixtureKEpsilon: Added support for fvOptions --- .../RAS/mixtureKEpsilon/mixtureKEpsilon.C | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/src/TurbulenceModels/phaseCompressible/RAS/mixtureKEpsilon/mixtureKEpsilon.C b/src/TurbulenceModels/phaseCompressible/RAS/mixtureKEpsilon/mixtureKEpsilon.C index f0b8a4f537..c65a63cb40 100644 --- a/src/TurbulenceModels/phaseCompressible/RAS/mixtureKEpsilon/mixtureKEpsilon.C +++ b/src/TurbulenceModels/phaseCompressible/RAS/mixtureKEpsilon/mixtureKEpsilon.C @@ -24,9 +24,9 @@ License \*---------------------------------------------------------------------------*/ #include "mixtureKEpsilon.H" +#include "fvOptions.H" #include "bound.H" #include "twoPhaseSystem.H" -#include "dragModel.H" #include "virtualMassModel.H" #include "fixedValueFvPatchFields.H" #include "inletOutletFvPatchFields.H" @@ -335,6 +335,9 @@ void mixtureKEpsilon::correctNut() { this->nut_ = Cmu_*sqr(k_)/epsilon_; this->nut_.correctBoundaryConditions(); + fv::options::New(this->mesh_).correct(this->nut_); + + BasicTurbulenceModel::correctNut(); } @@ -575,6 +578,8 @@ void mixtureKEpsilon::correct() volScalarField& km = km_(); volScalarField& epsilonm = epsilonm_(); + fv::options& fvOptions(fv::options::New(this->mesh_)); + eddyViscosity >::correct(); // Update the effective mixture density @@ -657,13 +662,14 @@ void mixtureKEpsilon::correct() - fvm::SuSp(((2.0/3.0)*C1_)*divUm, epsilonm) - fvm::Sp(C2_*epsilonm/km, epsilonm) + epsilonSource() + + fvOptions(epsilonm) ); epsEqn().relax(); - + fvOptions.constrain(epsEqn()); epsEqn().boundaryManipulate(epsilonm.boundaryField()); - solve(epsEqn); + fvOptions.correct(epsilonm); bound(epsilonm, this->epsilonMin_); @@ -679,10 +685,13 @@ void mixtureKEpsilon::correct() - fvm::SuSp((2.0/3.0)*divUm, km) - fvm::Sp(epsilonm/km, km) + kSource() + + fvOptions(km) ); kmEqn().relax(); + fvOptions.constrain(kmEqn()); solve(kmEqn); + fvOptions.correct(km); bound(km, this->kMin_); km.correctBoundaryConditions(); From 352f4ab80b74ea8fb0baae32b49139ec15e2435b Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Thu, 3 Dec 2015 16:17:23 +0000 Subject: [PATCH 024/447] TurbulenceModels/phaseCompressible/RAS/kOmegaSSTSato: Added support for fvOptions --- .../phaseCompressible/RAS/kOmegaSSTSato/kOmegaSSTSato.C | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/TurbulenceModels/phaseCompressible/RAS/kOmegaSSTSato/kOmegaSSTSato.C b/src/TurbulenceModels/phaseCompressible/RAS/kOmegaSSTSato/kOmegaSSTSato.C index 76d7e4d0be..f65de4583d 100644 --- a/src/TurbulenceModels/phaseCompressible/RAS/kOmegaSSTSato/kOmegaSSTSato.C +++ b/src/TurbulenceModels/phaseCompressible/RAS/kOmegaSSTSato/kOmegaSSTSato.C @@ -24,9 +24,8 @@ License \*---------------------------------------------------------------------------*/ #include "kOmegaSSTSato.H" -#include "addToRunTimeSelectionTable.H" +#include "fvOptions.H" #include "twoPhaseSystem.H" -#include "dragModel.H" // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -153,6 +152,9 @@ void kOmegaSSTSato::correctNut() *(mag(this->U_ - gasTurbulence.U())); this->nut_.correctBoundaryConditions(); + fv::options::New(this->mesh_).correct(this->nut_); + + BasicTurbulenceModel::correctNut(); } From cdb7b896bf55f12ad59f5e2a66c51f5b96e7d7f1 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Thu, 3 Dec 2015 16:17:40 +0000 Subject: [PATCH 025/447] TurbulenceModels/phaseCompressible/RAS/continuousGasKEpsilon: Added support for fvOptions --- .../RAS/continuousGasKEpsilon/continuousGasKEpsilon.C | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/TurbulenceModels/phaseCompressible/RAS/continuousGasKEpsilon/continuousGasKEpsilon.C b/src/TurbulenceModels/phaseCompressible/RAS/continuousGasKEpsilon/continuousGasKEpsilon.C index 86d6a7f334..e57eff4b84 100644 --- a/src/TurbulenceModels/phaseCompressible/RAS/continuousGasKEpsilon/continuousGasKEpsilon.C +++ b/src/TurbulenceModels/phaseCompressible/RAS/continuousGasKEpsilon/continuousGasKEpsilon.C @@ -24,7 +24,7 @@ License \*---------------------------------------------------------------------------*/ #include "continuousGasKEpsilon.H" -#include "addToRunTimeSelectionTable.H" +#include "fvOptions.H" #include "twoPhaseSystem.H" #include "virtualMassModel.H" @@ -136,6 +136,7 @@ void continuousGasKEpsilon::correctNut() volScalarField omega((1 - expThetar)/(1 + expThetar)); nutEff_ = omega*liquidTurbulence.nut(); + fv::options::New(this->mesh_).correct(nutEff_); } From d577e47b40737ebef1273be65234a79f129a256d Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Thu, 3 Dec 2015 16:18:04 +0000 Subject: [PATCH 026/447] TurbulenceModels/phaseCompressible/LES/Niceno: Added support for fvOptions --- .../phaseCompressible/LES/Niceno/NicenoKEqn.C | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/TurbulenceModels/phaseCompressible/LES/Niceno/NicenoKEqn.C b/src/TurbulenceModels/phaseCompressible/LES/Niceno/NicenoKEqn.C index 44eb97019b..212ec4da2e 100644 --- a/src/TurbulenceModels/phaseCompressible/LES/Niceno/NicenoKEqn.C +++ b/src/TurbulenceModels/phaseCompressible/LES/Niceno/NicenoKEqn.C @@ -24,9 +24,8 @@ License \*---------------------------------------------------------------------------*/ #include "NicenoKEqn.H" -#include "addToRunTimeSelectionTable.H" +#include "fvOptions.H" #include "twoPhaseSystem.H" -#include "dragModel.H" // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -165,6 +164,9 @@ void NicenoKEqn::correctNut() *(mag(this->U_ - gasTurbulence.U())); this->nut_.correctBoundaryConditions(); + fv::options::New(this->mesh_).correct(this->nut_); + + BasicTurbulenceModel::correctNut(); } From 12c4ba267e9952c4b552d4d11e359c7c9ed4035f Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Thu, 3 Dec 2015 16:38:43 +0000 Subject: [PATCH 027/447] TurbulenceModels/phaseCompressible/LES/continuousGasKEqn: Added support for fvOptions --- .../phaseCompressible/LES/continuousGasKEqn/continuousGasKEqn.C | 1 - 1 file changed, 1 deletion(-) diff --git a/src/TurbulenceModels/phaseCompressible/LES/continuousGasKEqn/continuousGasKEqn.C b/src/TurbulenceModels/phaseCompressible/LES/continuousGasKEqn/continuousGasKEqn.C index 00e23e7c32..31d646b759 100644 --- a/src/TurbulenceModels/phaseCompressible/LES/continuousGasKEqn/continuousGasKEqn.C +++ b/src/TurbulenceModels/phaseCompressible/LES/continuousGasKEqn/continuousGasKEqn.C @@ -24,7 +24,6 @@ License \*---------------------------------------------------------------------------*/ #include "continuousGasKEqn.H" -#include "addToRunTimeSelectionTable.H" #include "twoPhaseSystem.H" // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // From 297dc6ce8e97aad3eea83587e796bf3fdf32b56f Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Thu, 3 Dec 2015 16:39:00 +0000 Subject: [PATCH 028/447] TurbulenceModels/phaseCompressible/LES/SmagorinskyZhang: Added support for fvOptions --- .../phaseCompressible/LES/SmagorinskyZhang/SmagorinskyZhang.C | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/TurbulenceModels/phaseCompressible/LES/SmagorinskyZhang/SmagorinskyZhang.C b/src/TurbulenceModels/phaseCompressible/LES/SmagorinskyZhang/SmagorinskyZhang.C index f7bfe4fbf6..24a5aaa70f 100644 --- a/src/TurbulenceModels/phaseCompressible/LES/SmagorinskyZhang/SmagorinskyZhang.C +++ b/src/TurbulenceModels/phaseCompressible/LES/SmagorinskyZhang/SmagorinskyZhang.C @@ -24,6 +24,7 @@ License \*---------------------------------------------------------------------------*/ #include "SmagorinskyZhang.H" +#include "fvOptions.H" // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -142,6 +143,9 @@ void SmagorinskyZhang::correctNut() *(mag(this->U_ - gasTurbulence.U())); this->nut_.correctBoundaryConditions(); + fv::options::New(this->mesh_).correct(this->nut_); + + BasicTurbulenceModel::correctNut(); } From 4025d6ebdd60a882730d22ebd61fcabdebc31048 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Thu, 3 Dec 2015 16:39:13 +0000 Subject: [PATCH 029/447] reactingTwoPhaseEulerFoam/twoPhaseCompressibleTurbulenceModels/kineticTheoryModels: Added support for fvOptions --- .../kineticTheoryModel/kineticTheoryModel.C | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/applications/solvers/multiphase/reactingEulerFoam/reactingTwoPhaseEulerFoam/twoPhaseCompressibleTurbulenceModels/kineticTheoryModels/kineticTheoryModel/kineticTheoryModel.C b/applications/solvers/multiphase/reactingEulerFoam/reactingTwoPhaseEulerFoam/twoPhaseCompressibleTurbulenceModels/kineticTheoryModels/kineticTheoryModel/kineticTheoryModel.C index 83017e1557..e44534e398 100644 --- a/applications/solvers/multiphase/reactingEulerFoam/reactingTwoPhaseEulerFoam/twoPhaseCompressibleTurbulenceModels/kineticTheoryModels/kineticTheoryModel/kineticTheoryModel.C +++ b/applications/solvers/multiphase/reactingEulerFoam/reactingTwoPhaseEulerFoam/twoPhaseCompressibleTurbulenceModels/kineticTheoryModels/kineticTheoryModel/kineticTheoryModel.C @@ -26,6 +26,7 @@ License #include "kineticTheoryModel.H" #include "mathematicalConstants.H" #include "twoPhaseSystem.H" +#include "fvOptions.H" // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // @@ -417,6 +418,8 @@ void Foam::RASModels::kineticTheoryModel::correct() // 'thermal' conductivity (Table 3.3, p. 49) kappa_ = conductivityModel_->kappa(alpha, Theta_, gs0_, rho, da, e_); + fv::options& fvOptions(fv::options::New(mesh_)); + // Construct the granular temperature equation (Eq. 3.20, p. 44) // NB. note that there are two typos in Eq. 3.20: // Ps should be without grad @@ -436,10 +439,13 @@ void Foam::RASModels::kineticTheoryModel::correct() + fvm::Sp(-gammaCoeff, Theta_) + fvm::Sp(-J1, Theta_) + fvm::Sp(J2/(Theta_ + ThetaSmall), Theta_) + + fvOptions(alpha, rho, Theta_) ); ThetaEqn.relax(); + fvOptions.constrain(ThetaEqn); ThetaEqn.solve(); + fvOptions.correct(Theta_); } else { From e356211140bd2d80617c65f4b8dc649297a3ca8b Mon Sep 17 00:00:00 2001 From: Chris Greenshields Date: Fri, 4 Dec 2015 14:20:23 +0000 Subject: [PATCH 030/447] foamNewApp: script to create template for a new application Creates a directory containing source .C file and Make directory Will deprecate foamNewSource with App argument in due course --- bin/foamNewApp | 73 ++++++++++++++++++++++++++++++ etc/codeTemplates/app/Make/files | 3 ++ etc/codeTemplates/app/Make/options | 7 +++ etc/codeTemplates/app/app.C | 47 +++++++++++++++++++ 4 files changed, 130 insertions(+) create mode 100755 bin/foamNewApp create mode 100644 etc/codeTemplates/app/Make/files create mode 100644 etc/codeTemplates/app/Make/options create mode 100644 etc/codeTemplates/app/app.C diff --git a/bin/foamNewApp b/bin/foamNewApp new file mode 100755 index 0000000000..b2f664817b --- /dev/null +++ b/bin/foamNewApp @@ -0,0 +1,73 @@ +#!/bin/sh +#------------------------------------------------------------------------------ +# ========= | +# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox +# \\ / O peration | +# \\ / A nd | Copyright (C) 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 . +# +# Script +# foamNewApp +# +# Description +# Create directory with source and compilation files for a new application +# +#------------------------------------------------------------------------------ +Script=${0##*/} +DIR="$FOAM_ETC/codeTemplates/app" + +usage() { + while [ "$#" -ge 1 ]; do echo "$1"; shift; done + cat< + +* Create directory with source and compilation files for a new application + (dir) + - .C + - Make (dir) + - files + - options + Compiles an executable named in \$FOAM_USER_APPBIN: + $FOAM_USER_APPBIN +USAGE + exit 1 +} + +case "$1" in +(-h | -help) + usage + ;; +-*) + usage "$1 is not a valid filename" + ;; +esac + +[ "$#" -eq 1 ] || usage "Wrong number of arguments" +[ -d "$1" ] && usage "$1 directory already exists, aborting..." + +NAME=$1 + +echo "Creating application code directory $NAME" && mkdir $NAME +sed "s#NAME#${NAME}#g" ${DIR}/app.C > $NAME/$NAME.C + +echo "Creating Make subdirectory" && mkdir $NAME/Make +sed "s#NAME#${NAME}#g" ${DIR}/Make/files > $NAME/Make/files +cp ${DIR}/Make/options $NAME/Make + +#------------------------------------------------------------------------------ diff --git a/etc/codeTemplates/app/Make/files b/etc/codeTemplates/app/Make/files new file mode 100644 index 0000000000..bfe94ae06e --- /dev/null +++ b/etc/codeTemplates/app/Make/files @@ -0,0 +1,3 @@ +NAME.C + +EXE = $(FOAM_USER_APPBIN)/NAME diff --git a/etc/codeTemplates/app/Make/options b/etc/codeTemplates/app/Make/options new file mode 100644 index 0000000000..a3ae8da833 --- /dev/null +++ b/etc/codeTemplates/app/Make/options @@ -0,0 +1,7 @@ +EXE_INC = \ + -I$(LIB_SRC)/finiteVolume/lnInclude \ + -I$(LIB_SRC)/meshTools/lnInclude + +LIB_LIBS = \ + -lfiniteVolume \ + -lmeshTools diff --git a/etc/codeTemplates/app/app.C b/etc/codeTemplates/app/app.C new file mode 100644 index 0000000000..e143dcdf22 --- /dev/null +++ b/etc/codeTemplates/app/app.C @@ -0,0 +1,47 @@ +/*---------------------------------------------------------------------------*\ + ========= | + \\ / F ield | OpenFOAM: The Open Source CFD Toolbox + \\ / O peration | + \\ / A nd | Copyright (C) 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 . + +Application + NAME + +Description + +\*---------------------------------------------------------------------------*/ + +#include "fvCFD.H" + +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +int main(int argc, char *argv[]) +{ + #include "setRootCase.H" + #include "createTime.H" + + // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + + Info<< "\nEnd\n" << endl; + return 0; +} + + +// ************************************************************************* // From a3e555e72c7912b233bb8bd20da6752af63d6199 Mon Sep 17 00:00:00 2001 From: Chris Greenshields Date: Fri, 4 Dec 2015 14:33:56 +0000 Subject: [PATCH 031/447] foamNewBC: script to create template code for a new boundary condition Run foamNewBC -h for details --- bin/foamNewBC | 216 ++++++++++++++++++++++++++ etc/codeTemplates/BC/BC.C | 240 +++++++++++++++++++++++++++++ etc/codeTemplates/BC/BC.H | 246 ++++++++++++++++++++++++++++++ etc/codeTemplates/BC/BCs.C | 43 ++++++ etc/codeTemplates/BC/BCs.H | 49 ++++++ etc/codeTemplates/BC/BCsFwd.H | 50 ++++++ etc/codeTemplates/BC/Make/files | 3 + etc/codeTemplates/BC/Make/options | 7 + 8 files changed, 854 insertions(+) create mode 100755 bin/foamNewBC create mode 100644 etc/codeTemplates/BC/BC.C create mode 100644 etc/codeTemplates/BC/BC.H create mode 100644 etc/codeTemplates/BC/BCs.C create mode 100644 etc/codeTemplates/BC/BCs.H create mode 100644 etc/codeTemplates/BC/BCsFwd.H create mode 100644 etc/codeTemplates/BC/Make/files create mode 100644 etc/codeTemplates/BC/Make/options diff --git a/bin/foamNewBC b/bin/foamNewBC new file mode 100755 index 0000000000..12b894eda0 --- /dev/null +++ b/bin/foamNewBC @@ -0,0 +1,216 @@ +#!/bin/sh +#------------------------------------------------------------------------------ +# ========= | +# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox +# \\ / O peration | +# \\ / A nd | Copyright (C) 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 . +# +# Script +# foamNewBC +# +# Description +# Create directory of source and compilation files for a new BC +# +#------------------------------------------------------------------------------ +Script=${0##*/} +DIR="$FOAM_ETC/codeTemplates/BC" + +usage() { + while [ "$#" -ge 1 ]; do echo "$1"; shift; done + cat< + +* Create directory of source and compilation files for a new boundary condition + (dir) + - .C and .H source files + - Make (dir) + - files + - options + Compiles a library named lib.so in \$FOAM_USER_LIBBIN: + $FOAM_USER_LIBBIN + + conditions: +-f | -fixedValue | fixedValue +-m | -mixed | mixed + + options: +-a | -all | all | template (creates a template class) +-s | -scalar | scalar +-v | -vector | vector +-t | -tensor | tensor +-symmTensor | symmTensor +-sphericalTensor | sphericalTensor + +USAGE + exit 1 +} + +cap() { + echo $1 | sed -e 's/^./\U&/' +} + +# Implicitly covers a lone -help +[ "$#" -gt 1 ] || usage + +case "$1" in +(-h | -help) + usage + ;; +(-f | -fixedValue | fixedValue) + BASE=fixedValue + ;; +(-m | -mixed | mixed ) + BASE=mixed + ;; +(*) + usage "Unknown condition '$1'" + ;; +esac +shift + +case "$1" in +(-a | -all | all | template) + TYPE=Type + UNIT='VALUE-or-(VALUE 0 0)' + ;; +(-s | -scalar | scalar) + TYPE=scalar + UNIT=VALUE + ;; +(-v | -vector | vector) + TYPE=vector + UNIT='(VALUE 0 0)' + ;; +(-t | -tensor | tensor) + TYPE=tensor + UNIT='(VALUE 0 0 0 0 0 0 0 0)' + ;; +(-symmTensor | symmTensor) + TYPE=symmTensor + UNIT='(VALUE 0 0 0 0 0)' + ;; +(-sphericalTensor | sphericalTensor) + TYPE=sphericalTensor + UNIT=VALUE + ;; +(*) + usage "Unknown option '$1'" + ;; +esac +shift +[ "$#" -eq 1 ] || usage "Wrong number of arguments" +NAME=$1 + +# Prevents over-writing of existing directory +[ -d $NAME ] && usage "$NAME directory already exists, aborting..." +echo "Creating $NAME directory" && mkdir $NAME + +# Establish meta template files to copy +FILES=$(cd ${DIR} && ls *.*) +[ "$TYPE" = "Type" ] || FILES=$(cd ${DIR} && ls BC.[CH]) + +# Substitutions for meta-template files +FIELD="Field<${TYPE}>" +[ "$TYPE" = "Type" ] || FIELD=${TYPE}Field + +FVPATCHF=fvPatch$(cap $FIELD) +CLASS=$NAME$(cap $FVPATCHF) +PARENT=$BASE$(cap $FVPATCHF) +CONSTRUCT=$(echo $CLASS | sed 's///g') + +# Create some example values for the Description +n=0 +for N in $(echo "ZERO ONE TWO THREE FOUR") +do + eval $(expr $N='$(echo $UNIT | sed "s#VALUE#$n#g")') + n=$(( $n + 1 )) +done + +# Make substitutions to meta-template files +for F in $FILES +do + EXT=$(echo $F | sed "s#BC##") + NEWFILE=${CONSTRUCT}${EXT} + echo " Adding file ${NEWFILE}..." + + # Adds readScalar function when TYPE = scalar + sed -e "s#TYPE#${TYPE}#g" \ + -e "s#NAME#${NAME}#g" \ + -e "s#BASE#${BASE}#g" \ + -e "s#CONSTRUCT#${CONSTRUCT}#g" \ + -e "s#CLASS#${CLASS}#g" \ + -e "s#FIELD#${FIELD}#g" \ + -e "s#FVPATCHF#${FVPATCHF}#g" \ + -e "s#PARENT#${PARENT}#g" \ + -e "s#ZERO#${ZERO}#g" \ + -e "s#ONE#${ONE}#g" \ + -e "s#TWO#${TWO}#g" \ + -e "s#THREE#${THREE}#g" \ + -e "s#FOUR#${FOUR}#g" \ + -e 's/>>/> >/g' \ + ${DIR}/${F} > ${NAME}/${NEWFILE} + + case $BASE in + fixedValue) + # refValue(), refGrad(), valueFraction() removed + # phip removed + sed -i \ + -e '/refValue/d' \ + -e '/refGrad/d' \ + -e '/valueFraction/d' \ + -e '/phip/,/lookupPatchField/d' \ + ${NAME}/${NEWFILE} + ;; + mixed) + # evaluate() removed + # operator== becomes refValue() = + sed -i \ + -e '/evaluate/d' \ + -e 's/operator==/refValue() =/g' \ + ${NAME}/${NEWFILE} + ;; + esac + + case $TYPE in + Type) + # Build Macro removed (in ..Fields.C) + sed -i -e '/Build Macro/,/^}/d' \ + ${NAME}/${NEWFILE} + ;; + *) + # template removed + # this-> removed + # .template functionTemplate<...> becomes functionTemplate<...> + # template instantiation repository removed + sed -i \ + -e '/^template$/d' \ + -e 's/this->//g' \ + -e 's/\.template[\t ]*\([a-Z]\)/\.\1/g' \ + -e '/#ifdef NoRepository/,/\/\/ */d' \ + ${NAME}/${NEWFILE} + ;; + esac +done + +echo "Creating Make subdirectory" && cp -r ${DIR}/Make ${NAME} +COMPILED=$(cd ${NAME} && ls -r1 *C | head -1) # ...Fields.C for template class +sed -i -e "s#NAME#${NAME}#g" -e "s#COMPILED.*#${COMPILED}#g" ${NAME}/Make/files + +#------------------------------------------------------------------------------ diff --git a/etc/codeTemplates/BC/BC.C b/etc/codeTemplates/BC/BC.C new file mode 100644 index 0000000000..c518262cd9 --- /dev/null +++ b/etc/codeTemplates/BC/BC.C @@ -0,0 +1,240 @@ +/*---------------------------------------------------------------------------*\ + ========= | + \\ / F ield | OpenFOAM: The Open Source CFD Toolbox + \\ / O peration | + \\ / A nd | Copyright (C) 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 "CONSTRUCT.H" +#include "addToRunTimeSelectionTable.H" +#include "fvPatchFieldMapper.H" +#include "volFields.H" +#include "surfaceFields.H" + +// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * // + +template +Foam::scalar Foam::CLASS::t() const +{ + return this->db().time().timeOutputValue(); +} + + +// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // + +template +Foam::CLASS:: +CONSTRUCT +( + const fvPatch& p, + const DimensionedField& iF +) +: + PARENT(p, iF), + scalarData_(0.0), + data_(pTraits::zero), + fieldData_(p.size(), pTraits::zero), + timeVsData_(), + wordData_("wordDefault"), + labelData_(-1), + boolData_(false) +{ + this->refValue() = pTraits::zero; + this->refGrad() = pTraits::zero; + this->valueFraction() = 0.0; +} + + +template +Foam::CLASS:: +CONSTRUCT +( + const fvPatch& p, + const DimensionedField& iF, + const dictionary& dict +) +: + PARENT(p, iF), + scalarData_(readScalar(dict.lookup("scalarData"))), + data_(pTraits(dict.lookup("data"))), + fieldData_("fieldData", dict, p.size()), + timeVsData_(DataEntry::New("timeVsData", dict)), + wordData_(dict.lookupOrDefault("wordName", "wordDefault")), + labelData_(-1), + boolData_(false) +{ + this->refGrad() = pTraits::zero; + this->valueFraction() = 0.0; + + this->refValue() = FIELD("fieldData", dict, p.size()); + FVPATCHF::operator=(this->refValue()); + + PARENT::evaluate(); + + /* + //Initialise with the value entry if evaluation is not possible + FVPATCHF::operator= + ( + FIELD("value", dict, p.size()) + ); + this->refValue() = *this; + */ +} + + +template +Foam::CLASS:: +CONSTRUCT +( + const CLASS& ptf, + const fvPatch& p, + const DimensionedField& iF, + const fvPatchFieldMapper& mapper +) +: + PARENT(ptf, p, iF, mapper), + scalarData_(ptf.scalarData_), + data_(ptf.data_), + fieldData_(ptf.fieldData_, mapper), + timeVsData_(ptf.timeVsData_, false), + wordData_(ptf.wordData_), + labelData_(-1), + boolData_(ptf.boolData_) +{} + + +template +Foam::CLASS:: +CONSTRUCT +( + const CLASS& ptf +) +: + PARENT(ptf), + scalarData_(ptf.scalarData_), + data_(ptf.data_), + fieldData_(ptf.fieldData_), + timeVsData_(ptf.timeVsData_, false), + wordData_(ptf.wordData_), + labelData_(-1), + boolData_(ptf.boolData_) +{} + + +template +Foam::CLASS:: +CONSTRUCT +( + const CLASS& ptf, + const DimensionedField& iF +) +: + PARENT(ptf, iF), + scalarData_(ptf.scalarData_), + data_(ptf.data_), + fieldData_(ptf.fieldData_), + timeVsData_(ptf.timeVsData_, false), + wordData_(ptf.wordData_), + labelData_(-1), + boolData_(ptf.boolData_) +{} + + +// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // + +template +void Foam::CLASS::autoMap +( + const fvPatchFieldMapper& m +) +{ + PARENT::autoMap(m); + fieldData_.autoMap(m); +} + + +template +void Foam::CLASS::rmap +( + const FVPATCHF& ptf, + const labelList& addr +) +{ + PARENT::rmap(ptf, addr); + + const CLASS& tiptf = + refCast(ptf); + + fieldData_.rmap(tiptf.fieldData_, addr); +} + + +template +void Foam::CLASS::updateCoeffs() +{ + if (this->updated()) + { + return; + } + + PARENT::operator== + ( + data_ + + fieldData_ + + scalarData_*timeVsData_->value(t()) + ); + + const scalarField& phip = + this->patch().template lookupPatchField("phi"); + this->valueFraction() = 1.0 - pos(phip); + + PARENT::updateCoeffs(); +} + + +template +void Foam::CLASS::write +( + Ostream& os +) const +{ + FVPATCHF::write(os); + os.writeKeyword("scalarData") << scalarData_ << token::END_STATEMENT << nl; + os.writeKeyword("data") << data_ << token::END_STATEMENT << nl; + fieldData_.writeEntry("fieldData", os); + timeVsData_->writeData(os); + os.writeKeyword("wordData") << wordData_ << token::END_STATEMENT << nl; + this->writeEntry("value", os); +} + + +// * * * * * * * * * * * * * * Build Macro Function * * * * * * * * * * * * // + +namespace Foam +{ + makePatchTypeField + ( + FVPATCHF, + CLASS + ); +} + +// ************************************************************************* // diff --git a/etc/codeTemplates/BC/BC.H b/etc/codeTemplates/BC/BC.H new file mode 100644 index 0000000000..553a6c9183 --- /dev/null +++ b/etc/codeTemplates/BC/BC.H @@ -0,0 +1,246 @@ +/*---------------------------------------------------------------------------*\ + ========= | + \\ / F ield | OpenFOAM: The Open Source CFD Toolbox + \\ / O peration | + \\ / A nd | Copyright (C) 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::CONSTRUCT + +Group + grpGenericBoundaryConditions + +Description + This boundary condition provides a NAME condition, + calculated as: + + \f[ + Q = Q_{0} + Q_{p} + s*Q_{t} + \f] + + where + \vartable + s | single scalar value [units] + Q_{0} | single TYPE value [units] + Q_{p} | TYPE field across patch [units] + Q_{t} | TYPE function of time [units] + \endtable + + \heading Patch usage + + \table + Property | Description | Req'd? | Default + scalarData | single scalar value | yes | + data | single TYPE value | yes | + fieldData | TYPE field across patch | yes | + timeVsData | TYPE function of time | yes | + wordData | word, eg name of data object | no | wordDefault + \endtable + + Example of the boundary condition specification: + \verbatim + myPatch + { + type NAME; + scalarData -1; + data ONE; + fieldData uniform THREE; + timeVsData table ( + (0 ZERO) + (1 TWO) + ); + wordName anotherName; + value uniform FOUR; // optional initial value + } + \endverbatim + +SourceFiles + CONSTRUCT.C + +\*---------------------------------------------------------------------------*/ + +#ifndef CONSTRUCT_H +#define CONSTRUCT_H + +#include "BASEFvPatchFields.H" +#include "DataEntry.H" + +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +namespace Foam +{ + +/*---------------------------------------------------------------------------*\ + Class CONSTRUCT Declaration +\*---------------------------------------------------------------------------*/ + +template +class CONSTRUCT +: + public PARENT +{ + // Private data + + //- Single valued scalar quantity, e.g. a coefficient + scalar scalarData_; + + //- Single valued Type quantity, e.g. reference pressure pRefValue_ + // Other options include vector, tensor + TYPE data_; + + //- Field of Types, typically defined across patch faces + // e.g. total pressure p0_. Other options include vectorField + FIELD fieldData_; + + //- Type specified as a function of time for time-varying BCs + autoPtr > timeVsData_; + + //- Word entry, e.g. pName_ for name of the pressure field on database + word wordData_; + + //- Label, e.g. patch index, current time index + label labelData_; + + //- Boolean for true/false, e.g. specify if flow rate is volumetric_ + bool boolData_; + + + // Private Member Functions + + //- Return current time + scalar t() const; + + +public: + + //- Runtime type information + TypeName("NAME"); + + + // Constructors + + //- Construct from patch and internal field + CONSTRUCT + ( + const fvPatch&, + const DimensionedField& + ); + + //- Construct from patch, internal field and dictionary + CONSTRUCT + ( + const fvPatch&, + const DimensionedField&, + const dictionary& + ); + + //- Construct by mapping given BASETypeFvPatchField + // onto a new patch + CONSTRUCT + ( + const CLASS&, + const fvPatch&, + const DimensionedField&, + const fvPatchFieldMapper& + ); + + //- Construct as copy + CONSTRUCT + ( + const CLASS& + ); + + //- Construct and return a clone + virtual tmp clone() const + { + return tmp + ( + new CLASS(*this) + ); + } + + //- Construct as copy setting internal field reference + CONSTRUCT + ( + const CLASS&, + const DimensionedField& + ); + + //- Construct and return a clone setting internal field reference + virtual tmp clone + ( + const DimensionedField& iF + ) const + { + return tmp + ( + new CLASS + ( + *this, + iF + ) + ); + } + + + // Member functions + + // Mapping functions + + //- Map (and resize as needed) from self given a mapping object + virtual void autoMap + ( + const fvPatchFieldMapper& + ); + + //- Reverse map the given fvPatchField onto this fvPatchField + virtual void rmap + ( + const FVPATCHF&, + const labelList& + ); + + + // Evaluation functions + + //- Update the coefficients associated with the patch field + virtual void updateCoeffs(); + + + //- Write + virtual void write(Ostream&) const; +}; + + +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +} // End namespace Foam + +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +#ifdef NoRepository +# include "CONSTRUCT.C" +#endif + +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +#endif + +// ************************************************************************* // diff --git a/etc/codeTemplates/BC/BCs.C b/etc/codeTemplates/BC/BCs.C new file mode 100644 index 0000000000..09efcccb66 --- /dev/null +++ b/etc/codeTemplates/BC/BCs.C @@ -0,0 +1,43 @@ +/*---------------------------------------------------------------------------*\ + ========= | + \\ / F ield | OpenFOAM: The Open Source CFD Toolbox + \\ / O peration | + \\ / A nd | Copyright (C) 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 "CONSTRUCTs.H" +#include "addToRunTimeSelectionTable.H" +#include "volFields.H" + +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +namespace Foam +{ + +// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * // + +makePatchFields(NAME); + +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +} // End namespace Foam + +// ************************************************************************* // diff --git a/etc/codeTemplates/BC/BCs.H b/etc/codeTemplates/BC/BCs.H new file mode 100644 index 0000000000..fee1a95c9f --- /dev/null +++ b/etc/codeTemplates/BC/BCs.H @@ -0,0 +1,49 @@ +/*---------------------------------------------------------------------------*\ + ========= | + \\ / F ield | OpenFOAM: The Open Source CFD Toolbox + \\ / O peration | + \\ / A nd | Copyright (C) 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 . + +\*---------------------------------------------------------------------------*/ + +#ifndef CONSTRUCTs_H +#define CONSTRUCTs_H + +#include "CONSTRUCT.H" +#include "fieldTypes.H" + +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +namespace Foam +{ + +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +makePatchTypeFieldTypedefs(NAME); + +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +} // End namespace Foam + +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +#endif + +// ************************************************************************* // diff --git a/etc/codeTemplates/BC/BCsFwd.H b/etc/codeTemplates/BC/BCsFwd.H new file mode 100644 index 0000000000..366deb6009 --- /dev/null +++ b/etc/codeTemplates/BC/BCsFwd.H @@ -0,0 +1,50 @@ +/*---------------------------------------------------------------------------*\ + ========= | + \\ / F ield | OpenFOAM: The Open Source CFD Toolbox + \\ / O peration | + \\ / A nd | Copyright (C) 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 . + +\*---------------------------------------------------------------------------*/ + +#ifndef CONSTRUCTsFwd_H +#define CONSTRUCTsFwd_H + +#include "fieldTypes.H" + +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +namespace Foam +{ + +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +template class CONSTRUCT; + +makePatchTypeFieldTypedefs(NAME); + +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +} // End namespace Foam + +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +#endif + +// ************************************************************************* // diff --git a/etc/codeTemplates/BC/Make/files b/etc/codeTemplates/BC/Make/files new file mode 100644 index 0000000000..bf5c6588a5 --- /dev/null +++ b/etc/codeTemplates/BC/Make/files @@ -0,0 +1,3 @@ +COMPILED.C + +LIB = $(FOAM_USER_LIBBIN)/libNAME diff --git a/etc/codeTemplates/BC/Make/options b/etc/codeTemplates/BC/Make/options new file mode 100644 index 0000000000..a3ae8da833 --- /dev/null +++ b/etc/codeTemplates/BC/Make/options @@ -0,0 +1,7 @@ +EXE_INC = \ + -I$(LIB_SRC)/finiteVolume/lnInclude \ + -I$(LIB_SRC)/meshTools/lnInclude + +LIB_LIBS = \ + -lfiniteVolume \ + -lmeshTools From 17cc8483ef87eb1bcb849923889d6430cdaf1ad3 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Sat, 5 Dec 2015 16:12:57 +0000 Subject: [PATCH 032/447] saturationModels/Antoine: Corrected dimensions in Tsat Resolves bug-report http://www.openfoam.org/mantisbt/view.php?id=1940 --- .../saturationModels/Antoine/Antoine.C | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/applications/solvers/multiphase/reactingEulerFoam/interfacialCompositionModels/saturationModels/Antoine/Antoine.C b/applications/solvers/multiphase/reactingEulerFoam/interfacialCompositionModels/saturationModels/Antoine/Antoine.C index 90f1c989c5..b5b0629df1 100644 --- a/applications/solvers/multiphase/reactingEulerFoam/interfacialCompositionModels/saturationModels/Antoine/Antoine.C +++ b/applications/solvers/multiphase/reactingEulerFoam/interfacialCompositionModels/saturationModels/Antoine/Antoine.C @@ -95,7 +95,9 @@ Foam::saturationModels::Antoine::Tsat const volScalarField& p ) const { - return B_/(log(p) - A_) - C_; + return + B_/(log(p*dimensionedScalar("one", dimless/dimPressure, 1)) - A_) + - C_; } From b52f7571b92ba41c8a810258b79fcbcab4c7ed25 Mon Sep 17 00:00:00 2001 From: Chris Greenshields Date: Mon, 7 Dec 2015 14:15:14 +0000 Subject: [PATCH 033/447] foamNewApp: added execution and clock times to template --- etc/codeTemplates/app/app.C | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/etc/codeTemplates/app/app.C b/etc/codeTemplates/app/app.C index e143dcdf22..fb4c8ea78e 100644 --- a/etc/codeTemplates/app/app.C +++ b/etc/codeTemplates/app/app.C @@ -39,6 +39,10 @@ int main(int argc, char *argv[]) // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + Info<< nl << "ExecutionTime = " << runTime.elapsedCpuTime() << " s" + << " ClockTime = " << runTime.elapsedClockTime() << " s" + << nl << endl; + Info<< "\nEnd\n" << endl; return 0; } From cc996852a7d1e0ec06f384888004b13285fcd6b9 Mon Sep 17 00:00:00 2001 From: Chris Greenshields Date: Mon, 7 Dec 2015 17:28:40 +0000 Subject: [PATCH 034/447] foamNewApp: corrected template case --- etc/codeTemplates/app/Make/options | 2 +- etc/codeTemplates/app/app.C | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/etc/codeTemplates/app/Make/options b/etc/codeTemplates/app/Make/options index a3ae8da833..d27c95d033 100644 --- a/etc/codeTemplates/app/Make/options +++ b/etc/codeTemplates/app/Make/options @@ -2,6 +2,6 @@ EXE_INC = \ -I$(LIB_SRC)/finiteVolume/lnInclude \ -I$(LIB_SRC)/meshTools/lnInclude -LIB_LIBS = \ +EXE_LIBS = \ -lfiniteVolume \ -lmeshTools diff --git a/etc/codeTemplates/app/app.C b/etc/codeTemplates/app/app.C index fb4c8ea78e..911ba7c7de 100644 --- a/etc/codeTemplates/app/app.C +++ b/etc/codeTemplates/app/app.C @@ -43,7 +43,8 @@ int main(int argc, char *argv[]) << " ClockTime = " << runTime.elapsedClockTime() << " s" << nl << endl; - Info<< "\nEnd\n" << endl; + Info<< "End\n" << endl; + return 0; } From ce7b33b77ebd5bdd30f9acf4b7b8aaa9c1b2e603 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Mon, 7 Dec 2015 22:38:33 +0000 Subject: [PATCH 035/447] fvcAverage: Removed temporary Info statement --- src/finiteVolume/finiteVolume/fvc/fvcAverage.C | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/finiteVolume/finiteVolume/fvc/fvcAverage.C b/src/finiteVolume/finiteVolume/fvc/fvcAverage.C index c9b1052b8a..c6daac12d2 100644 --- a/src/finiteVolume/finiteVolume/fvc/fvcAverage.C +++ b/src/finiteVolume/finiteVolume/fvc/fvcAverage.C @@ -47,8 +47,6 @@ average const GeometricField& ssf ) { - Info<< "average" << endl; - const fvMesh& mesh = ssf.mesh(); tmp > taverage From f89d44292e9214be77ec2b660d21bd1a89a1f9f1 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Tue, 8 Dec 2015 11:57:37 +0000 Subject: [PATCH 036/447] fanFvPatchField, freestreamPressureFvPatchScalarField: added write function Resolves bug-report http://www.openfoam.org/mantisbt/view.php?id=1942 --- .../derived/fan/fanFvPatchField.C | 53 +++++++++++++------ .../derived/fan/fanFvPatchField.H | 3 ++ .../derived/fan/fanFvPatchFields.C | 2 +- .../freestreamPressureFvPatchScalarField.C | 14 ++++- .../freestreamPressureFvPatchScalarField.H | 4 ++ .../syringePressureFvPatchScalarField.C | 1 + 6 files changed, 57 insertions(+), 20 deletions(-) diff --git a/src/finiteVolume/fields/fvPatchFields/derived/fan/fanFvPatchField.C b/src/finiteVolume/fields/fvPatchFields/derived/fan/fanFvPatchField.C index 6885bd7d4d..3f855d52fa 100644 --- a/src/finiteVolume/fields/fvPatchFields/derived/fan/fanFvPatchField.C +++ b/src/finiteVolume/fields/fvPatchFields/derived/fan/fanFvPatchField.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -46,7 +46,23 @@ Foam::fanFvPatchField::fanFvPatchField const DimensionedField& iF ) : - uniformJumpFvPatchField(p, iF) + uniformJumpFvPatchField(p, iF), + phiName_("phi"), + rhoName_("rho") +{} + + +template +Foam::fanFvPatchField::fanFvPatchField +( + const fvPatch& p, + const DimensionedField& iF, + const dictionary& dict +) +: + uniformJumpFvPatchField(p, iF, dict), + phiName_(dict.lookupOrDefault("phi", "phi")), + rhoName_(dict.lookupOrDefault("rho", "rho")) {} @@ -59,19 +75,9 @@ Foam::fanFvPatchField::fanFvPatchField const fvPatchFieldMapper& mapper ) : - uniformJumpFvPatchField(ptf, p, iF, mapper) -{} - - -template -Foam::fanFvPatchField::fanFvPatchField -( - const fvPatch& p, - const DimensionedField& iF, - const dictionary& dict -) -: - uniformJumpFvPatchField(p, iF, dict) + uniformJumpFvPatchField(ptf, p, iF, mapper), + phiName_(ptf.phiName_), + rhoName_(ptf.rhoName_) {} @@ -81,7 +87,9 @@ Foam::fanFvPatchField::fanFvPatchField const fanFvPatchField& ptf ) : - uniformJumpFvPatchField(ptf) + uniformJumpFvPatchField(ptf), + phiName_(ptf.phiName_), + rhoName_(ptf.rhoName_) {} @@ -92,7 +100,9 @@ Foam::fanFvPatchField::fanFvPatchField const DimensionedField& iF ) : - uniformJumpFvPatchField(ptf, iF) + uniformJumpFvPatchField(ptf, iF), + phiName_(ptf.phiName_), + rhoName_(ptf.rhoName_) {} @@ -113,4 +123,13 @@ void Foam::fanFvPatchField::updateCoeffs() } +template +void Foam::fanFvPatchField::write(Ostream& os) const +{ + uniformJumpFvPatchField::write(os); + this->template writeEntryIfDifferent(os, "phi", "phi", phiName_); + this->template writeEntryIfDifferent(os, "rho", "rho", rhoName_); +} + + // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvPatchFields/derived/fan/fanFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/fan/fanFvPatchField.H index fd27dfecd3..2ad75b1da6 100644 --- a/src/finiteVolume/fields/fvPatchFields/derived/fan/fanFvPatchField.H +++ b/src/finiteVolume/fields/fvPatchFields/derived/fan/fanFvPatchField.H @@ -187,6 +187,9 @@ public: //- Update the coefficients associated with the patch field virtual void updateCoeffs(); + + //- Write + virtual void write(Ostream&) const; }; diff --git a/src/finiteVolume/fields/fvPatchFields/derived/fan/fanFvPatchFields.C b/src/finiteVolume/fields/fvPatchFields/derived/fan/fanFvPatchFields.C index ea9ecdea57..81adcbf2b8 100644 --- a/src/finiteVolume/fields/fvPatchFields/derived/fan/fanFvPatchFields.C +++ b/src/finiteVolume/fields/fvPatchFields/derived/fan/fanFvPatchFields.C @@ -78,7 +78,7 @@ Foam::fanFvPatchField::fanFvPatchField : uniformJumpFvPatchField(p, iF), phiName_(dict.lookupOrDefault("phi", "phi")), - rhoName_(dict.lookupOrDefault("rho", "none")) + rhoName_(dict.lookupOrDefault("rho", "rho")) { if (this->cyclicPatch().owner()) { diff --git a/src/finiteVolume/fields/fvPatchFields/derived/freestreamPressure/freestreamPressureFvPatchScalarField.C b/src/finiteVolume/fields/fvPatchFields/derived/freestreamPressure/freestreamPressureFvPatchScalarField.C index b50eac91b8..a32d667709 100644 --- a/src/finiteVolume/fields/fvPatchFields/derived/freestreamPressure/freestreamPressureFvPatchScalarField.C +++ b/src/finiteVolume/fields/fvPatchFields/derived/freestreamPressure/freestreamPressureFvPatchScalarField.C @@ -42,7 +42,7 @@ freestreamPressureFvPatchScalarField zeroGradientFvPatchScalarField(p, iF), UName_("U"), phiName_("phi"), - rhoName_("none") + rhoName_("rho") {} @@ -57,7 +57,7 @@ freestreamPressureFvPatchScalarField zeroGradientFvPatchScalarField(p, iF, dict), UName_(dict.lookupOrDefault("U", "U")), phiName_(dict.lookupOrDefault("phi", "phi")), - rhoName_(dict.lookupOrDefault("rho", "none")) + rhoName_(dict.lookupOrDefault("rho", "rho")) {} @@ -153,6 +153,16 @@ void Foam::freestreamPressureFvPatchScalarField::updateCoeffs() } +void Foam::freestreamPressureFvPatchScalarField::write(Ostream& os) const +{ + fvPatchScalarField::write(os); + writeEntryIfDifferent(os, "U", "U", UName_); + writeEntryIfDifferent(os, "phi", "phi", phiName_); + writeEntryIfDifferent(os, "rho", "rho", rhoName_); + writeEntry("value", os); +} + + // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // namespace Foam diff --git a/src/finiteVolume/fields/fvPatchFields/derived/freestreamPressure/freestreamPressureFvPatchScalarField.H b/src/finiteVolume/fields/fvPatchFields/derived/freestreamPressure/freestreamPressureFvPatchScalarField.H index 4d8c5d1807..49687b0ec9 100644 --- a/src/finiteVolume/fields/fvPatchFields/derived/freestreamPressure/freestreamPressureFvPatchScalarField.H +++ b/src/finiteVolume/fields/fvPatchFields/derived/freestreamPressure/freestreamPressureFvPatchScalarField.H @@ -167,6 +167,10 @@ public: //- Update the coefficients associated with the patch field virtual void updateCoeffs(); + + + //- Write + virtual void write(Ostream&) const; }; diff --git a/src/finiteVolume/fields/fvPatchFields/derived/syringePressure/syringePressureFvPatchScalarField.C b/src/finiteVolume/fields/fvPatchFields/derived/syringePressure/syringePressureFvPatchScalarField.C index 20690258a3..3407e259ab 100644 --- a/src/finiteVolume/fields/fvPatchFields/derived/syringePressure/syringePressureFvPatchScalarField.C +++ b/src/finiteVolume/fields/fvPatchFields/derived/syringePressure/syringePressureFvPatchScalarField.C @@ -243,6 +243,7 @@ void Foam::syringePressureFvPatchScalarField::write(Ostream& os) const os.writeKeyword("psI") << psI_ << token::END_STATEMENT << nl; os.writeKeyword("psi") << psi_ << token::END_STATEMENT << nl; os.writeKeyword("ams") << ams_ << token::END_STATEMENT << nl; + writeEntryIfDifferent(os, "phi", "phi", phiName_); writeEntry("value", os); } From 4aa6052a660b320d776e113ad0f10ff141a58a74 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Tue, 8 Dec 2015 14:24:12 +0000 Subject: [PATCH 037/447] uniformInletOutletFvPatchField: Update refValue in updateCoeffs Resolves bug-report http://www.openfoam.org/mantisbt/view.php?id=1943 --- .../uniformInletOutletFvPatchField.C | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/src/finiteVolume/fields/fvPatchFields/derived/uniformInletOutlet/uniformInletOutletFvPatchField.C b/src/finiteVolume/fields/fvPatchFields/derived/uniformInletOutlet/uniformInletOutletFvPatchField.C index 54217a529a..9e9809c91f 100644 --- a/src/finiteVolume/fields/fvPatchFields/derived/uniformInletOutlet/uniformInletOutletFvPatchField.C +++ b/src/finiteVolume/fields/fvPatchFields/derived/uniformInletOutlet/uniformInletOutletFvPatchField.C @@ -55,8 +55,8 @@ Foam::uniformInletOutletFvPatchField::uniformInletOutletFvPatchField phiName_(dict.lookupOrDefault("phi", "phi")), uniformInletValue_(DataEntry::New("uniformInletValue", dict)) { - const scalar t = this->db().time().timeOutputValue(); - this->refValue() = uniformInletValue_->value(t); + this->refValue() = + uniformInletValue_->value(this->db().time().timeOutputValue()); if (dict.found("value")) { @@ -91,8 +91,8 @@ Foam::uniformInletOutletFvPatchField::uniformInletOutletFvPatchField this->patchType() = ptf.patchType(); // Evaluate refValue since not mapped - const scalar t = this->db().time().timeOutputValue(); - this->refValue() = uniformInletValue_->value(t); + this->refValue() = + uniformInletValue_->value(this->db().time().timeOutputValue()); this->refGrad() = pTraits::zero; this->valueFraction() = 0.0; @@ -139,6 +139,9 @@ void Foam::uniformInletOutletFvPatchField::updateCoeffs() return; } + this->refValue() = + uniformInletValue_->value(this->db().time().timeOutputValue()); + const Field& phip = this->patch().template lookupPatchField ( @@ -175,8 +178,8 @@ void Foam::uniformInletOutletFvPatchField::autoMap mixedFvPatchField::autoMap(m); // Override - const scalar t = this->db().time().timeOutputValue(); - this->refValue() = uniformInletValue_->value(t); + this->refValue() = + uniformInletValue_->value(this->db().time().timeOutputValue()); } @@ -190,8 +193,8 @@ void Foam::uniformInletOutletFvPatchField::rmap mixedFvPatchField::rmap(ptf, addr); // Override - const scalar t = this->db().time().timeOutputValue(); - this->refValue() = uniformInletValue_->value(t); + this->refValue() = + uniformInletValue_->value(this->db().time().timeOutputValue()); } From fb871828a57c121742aa304e0dacbb1caee64575 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Tue, 8 Dec 2015 22:29:05 +0000 Subject: [PATCH 038/447] fvPatchFields, fvsPatchFields, pointPatchFields: specifically declare namespace of functions It is better to declare the namespace of each function in the C file rather than "open" the namespace as this may lead to inconsistencies between the declaration in the H files and definition in the C file. --- .../mixedFixedValueSlipFvPatchField.C | 72 +++++++--------- .../calculated/calculatedPointPatchField.C | 23 ++--- .../basic/coupled/coupledPointPatchField.C | 19 ++--- .../fixedValue/fixedValuePointPatchField.C | 19 ++--- .../zeroGradientPointPatchField.C | 19 ++--- .../constraint/empty/emptyPointPatchField.C | 17 +--- .../processor/processorPointPatchField.C | 21 ++--- .../symmetry/symmetryPointPatchField.C | 17 +--- .../symmetryPlanePointPatchField.C | 17 +--- .../derived/slip/slipPointPatchField.C | 19 ++--- .../uniformFixedValuePointPatchField.C | 25 ++---- .../pointPatchField/pointPatchField.C | 42 ++++----- .../kqRWallFunctionFvPatchField.C | 51 +++++------ .../fixedGradient/fixedGradientFvPatchField.C | 69 +++++++-------- .../basic/fixedValue/fixedValueFvPatchField.C | 33 +++---- .../basic/mixed/mixedFvPatchField.C | 74 ++++++++-------- .../basic/sliced/slicedFvPatchField.C | 85 ++++++++++--------- .../zeroGradient/zeroGradientFvPatchField.C | 59 ++++++------- .../constraint/cyclic/cyclicFvPatchField.C | 78 ++++++++--------- .../nonuniformTransformCyclicFvPatchField.C | 45 ++++------ .../symmetry/symmetryFvPatchField.C | 63 ++++++-------- .../freestream/freestreamFvPatchField.C | 47 +++++----- .../mappedField/mappedFieldFvPatchField.C | 54 +++++------- .../mappedFixedValueFvPatchField.C | 49 +++++------ .../oscillatingFixedValueFvPatchField.C | 63 ++++++-------- .../derived/slip/slipFvPatchField.C | 43 ++++------ .../timeVaryingMappedFixedValueFvPatchField.C | 32 +++---- .../turbulentInletFvPatchField.C | 63 ++++++-------- .../calculated/calculatedFvsPatchField.C | 49 +++++------ .../basic/coupled/coupledFvsPatchField.C | 45 ++++------ .../fixedValue/fixedValueFvsPatchField.C | 55 ++++++------ .../basic/sliced/slicedFvsPatchField.C | 56 ++++++------ .../constraint/cyclic/cyclicFvsPatchField.C | 63 ++++++-------- .../cyclicSlip/cyclicSlipFvsPatchField.C | 43 ++++------ .../constraint/empty/emptyFvsPatchField.C | 61 ++++++------- .../nonuniformTransformCyclicFvsPatchField.C | 45 ++++------ .../processor/processorFvsPatchField.C | 68 +++++++-------- .../processorCyclicFvsPatchField.C | 68 +++++++-------- .../symmetry/symmetryFvsPatchField.C | 61 ++++++------- .../symmetryPlaneFvsPatchField.C | 61 ++++++------- .../constraint/wedge/wedgeFvsPatchField.C | 61 ++++++------- .../fvsPatchField/fvsPatchField.C | 75 +++++++--------- .../genericPointPatchField.C | 23 ++--- .../zeroFixedValuePointPatchField.C | 21 ++--- 44 files changed, 857 insertions(+), 1216 deletions(-) diff --git a/applications/solvers/compressible/rhoCentralFoam/BCs/mixedFixedValueSlip/mixedFixedValueSlipFvPatchField.C b/applications/solvers/compressible/rhoCentralFoam/BCs/mixedFixedValueSlip/mixedFixedValueSlipFvPatchField.C index 5c1459381f..18155d5bca 100644 --- a/applications/solvers/compressible/rhoCentralFoam/BCs/mixedFixedValueSlip/mixedFixedValueSlipFvPatchField.C +++ b/applications/solvers/compressible/rhoCentralFoam/BCs/mixedFixedValueSlip/mixedFixedValueSlipFvPatchField.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -26,15 +26,10 @@ License #include "mixedFixedValueSlipFvPatchField.H" #include "symmTransformField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -mixedFixedValueSlipFvPatchField::mixedFixedValueSlipFvPatchField +Foam::mixedFixedValueSlipFvPatchField::mixedFixedValueSlipFvPatchField ( const fvPatch& p, const DimensionedField& iF @@ -47,7 +42,21 @@ mixedFixedValueSlipFvPatchField::mixedFixedValueSlipFvPatchField template -mixedFixedValueSlipFvPatchField::mixedFixedValueSlipFvPatchField +Foam::mixedFixedValueSlipFvPatchField::mixedFixedValueSlipFvPatchField +( + const fvPatch& p, + const DimensionedField& iF, + const dictionary& dict +) +: + transformFvPatchField(p, iF), + refValue_("refValue", dict, p.size()), + valueFraction_("valueFraction", dict, p.size()) +{} + + +template +Foam::mixedFixedValueSlipFvPatchField::mixedFixedValueSlipFvPatchField ( const mixedFixedValueSlipFvPatchField& ptf, const fvPatch& p, @@ -62,21 +71,7 @@ mixedFixedValueSlipFvPatchField::mixedFixedValueSlipFvPatchField template -mixedFixedValueSlipFvPatchField::mixedFixedValueSlipFvPatchField -( - const fvPatch& p, - const DimensionedField& iF, - const dictionary& dict -) -: - transformFvPatchField(p, iF), - refValue_("refValue", dict, p.size()), - valueFraction_("valueFraction", dict, p.size()) -{} - - -template -mixedFixedValueSlipFvPatchField::mixedFixedValueSlipFvPatchField +Foam::mixedFixedValueSlipFvPatchField::mixedFixedValueSlipFvPatchField ( const mixedFixedValueSlipFvPatchField& ptf ) @@ -86,8 +81,9 @@ mixedFixedValueSlipFvPatchField::mixedFixedValueSlipFvPatchField valueFraction_(ptf.valueFraction_) {} + template -mixedFixedValueSlipFvPatchField::mixedFixedValueSlipFvPatchField +Foam::mixedFixedValueSlipFvPatchField::mixedFixedValueSlipFvPatchField ( const mixedFixedValueSlipFvPatchField& ptf, const DimensionedField& iF @@ -101,9 +97,8 @@ mixedFixedValueSlipFvPatchField::mixedFixedValueSlipFvPatchField // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // -// Map from self template -void mixedFixedValueSlipFvPatchField::autoMap +void Foam::mixedFixedValueSlipFvPatchField::autoMap ( const fvPatchFieldMapper& m ) @@ -114,9 +109,8 @@ void mixedFixedValueSlipFvPatchField::autoMap } -// Reverse-map the given fvPatchField onto this fvPatchField template -void mixedFixedValueSlipFvPatchField::rmap +void Foam::mixedFixedValueSlipFvPatchField::rmap ( const fvPatchField& ptf, const labelList& addr @@ -132,9 +126,9 @@ void mixedFixedValueSlipFvPatchField::rmap } -// Return gradient at boundary template -tmp > mixedFixedValueSlipFvPatchField::snGrad() const +Foam::tmp > +Foam::mixedFixedValueSlipFvPatchField::snGrad() const { tmp nHat = this->patch().nf(); Field pif(this->patchInternalField()); @@ -147,9 +141,11 @@ tmp > mixedFixedValueSlipFvPatchField::snGrad() const } -// Evaluate the field on the patch template -void mixedFixedValueSlipFvPatchField::evaluate(const Pstream::commsTypes) +void Foam::mixedFixedValueSlipFvPatchField::evaluate +( + const Pstream::commsTypes +) { if (!this->updated()) { @@ -170,10 +166,9 @@ void mixedFixedValueSlipFvPatchField::evaluate(const Pstream::commsTypes) } -// Return defining fields template -tmp > -mixedFixedValueSlipFvPatchField::snGradTransformDiag() const +Foam::tmp > +Foam::mixedFixedValueSlipFvPatchField::snGradTransformDiag() const { vectorField nHat(this->patch().nf()); vectorField diag(nHat.size()); @@ -189,9 +184,8 @@ mixedFixedValueSlipFvPatchField::snGradTransformDiag() const } -// Write template -void mixedFixedValueSlipFvPatchField::write(Ostream& os) const +void Foam::mixedFixedValueSlipFvPatchField::write(Ostream& os) const { transformFvPatchField::write(os); refValue_.writeEntry("refValue", os); @@ -199,8 +193,4 @@ void mixedFixedValueSlipFvPatchField::write(Ostream& os) const } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/OpenFOAM/fields/pointPatchFields/basic/calculated/calculatedPointPatchField.C b/src/OpenFOAM/fields/pointPatchFields/basic/calculated/calculatedPointPatchField.C index 45f98495db..74846139eb 100644 --- a/src/OpenFOAM/fields/pointPatchFields/basic/calculated/calculatedPointPatchField.C +++ b/src/OpenFOAM/fields/pointPatchFields/basic/calculated/calculatedPointPatchField.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 @@ -27,11 +27,8 @@ License // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -namespace Foam -{ - template -const word& pointPatchField::calculatedType() +const Foam::word& Foam::pointPatchField::calculatedType() { return calculatedPointPatchField::typeName; } @@ -40,7 +37,7 @@ const word& pointPatchField::calculatedType() // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -calculatedPointPatchField::calculatedPointPatchField +Foam::calculatedPointPatchField::calculatedPointPatchField ( const pointPatch& p, const DimensionedField& iF @@ -51,7 +48,7 @@ calculatedPointPatchField::calculatedPointPatchField template -calculatedPointPatchField::calculatedPointPatchField +Foam::calculatedPointPatchField::calculatedPointPatchField ( const pointPatch& p, const DimensionedField& iF, @@ -63,7 +60,7 @@ calculatedPointPatchField::calculatedPointPatchField template -calculatedPointPatchField::calculatedPointPatchField +Foam::calculatedPointPatchField::calculatedPointPatchField ( const calculatedPointPatchField& ptf, const pointPatch& p, @@ -76,7 +73,7 @@ calculatedPointPatchField::calculatedPointPatchField template -calculatedPointPatchField::calculatedPointPatchField +Foam::calculatedPointPatchField::calculatedPointPatchField ( const calculatedPointPatchField& ptf, const DimensionedField& iF @@ -88,8 +85,8 @@ calculatedPointPatchField::calculatedPointPatchField template template -autoPtr > -pointPatchField::NewCalculatedType +Foam::autoPtr > +Foam::pointPatchField::NewCalculatedType ( const pointPatchField& pf ) @@ -122,8 +119,4 @@ pointPatchField::NewCalculatedType } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/OpenFOAM/fields/pointPatchFields/basic/coupled/coupledPointPatchField.C b/src/OpenFOAM/fields/pointPatchFields/basic/coupled/coupledPointPatchField.C index 434b6873f4..635f9b665e 100644 --- a/src/OpenFOAM/fields/pointPatchFields/basic/coupled/coupledPointPatchField.C +++ b/src/OpenFOAM/fields/pointPatchFields/basic/coupled/coupledPointPatchField.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 @@ -25,15 +25,10 @@ License #include "coupledPointPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * * // template -coupledPointPatchField::coupledPointPatchField +Foam::coupledPointPatchField::coupledPointPatchField ( const pointPatch& p, const DimensionedField& iF @@ -44,7 +39,7 @@ coupledPointPatchField::coupledPointPatchField template -coupledPointPatchField::coupledPointPatchField +Foam::coupledPointPatchField::coupledPointPatchField ( const pointPatch& p, const DimensionedField& iF, @@ -56,7 +51,7 @@ coupledPointPatchField::coupledPointPatchField template -coupledPointPatchField::coupledPointPatchField +Foam::coupledPointPatchField::coupledPointPatchField ( const coupledPointPatchField& ptf, const pointPatch& p, @@ -69,7 +64,7 @@ coupledPointPatchField::coupledPointPatchField template -coupledPointPatchField::coupledPointPatchField +Foam::coupledPointPatchField::coupledPointPatchField ( const coupledPointPatchField& ptf, const DimensionedField& iF @@ -79,8 +74,4 @@ coupledPointPatchField::coupledPointPatchField {} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/OpenFOAM/fields/pointPatchFields/basic/fixedValue/fixedValuePointPatchField.C b/src/OpenFOAM/fields/pointPatchFields/basic/fixedValue/fixedValuePointPatchField.C index 19bb6d8af5..2ef21cfdd2 100644 --- a/src/OpenFOAM/fields/pointPatchFields/basic/fixedValue/fixedValuePointPatchField.C +++ b/src/OpenFOAM/fields/pointPatchFields/basic/fixedValue/fixedValuePointPatchField.C @@ -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 @@ -26,15 +26,10 @@ License #include "fixedValuePointPatchField.H" #include "boolList.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -fixedValuePointPatchField::fixedValuePointPatchField +Foam::fixedValuePointPatchField::fixedValuePointPatchField ( const pointPatch& p, const DimensionedField& iF @@ -45,7 +40,7 @@ fixedValuePointPatchField::fixedValuePointPatchField template -fixedValuePointPatchField::fixedValuePointPatchField +Foam::fixedValuePointPatchField::fixedValuePointPatchField ( const pointPatch& p, const DimensionedField& iF, @@ -58,7 +53,7 @@ fixedValuePointPatchField::fixedValuePointPatchField template -fixedValuePointPatchField::fixedValuePointPatchField +Foam::fixedValuePointPatchField::fixedValuePointPatchField ( const fixedValuePointPatchField& ptf, const pointPatch& p, @@ -71,7 +66,7 @@ fixedValuePointPatchField::fixedValuePointPatchField template -fixedValuePointPatchField::fixedValuePointPatchField +Foam::fixedValuePointPatchField::fixedValuePointPatchField ( const fixedValuePointPatchField& ptf, const DimensionedField& iF @@ -81,8 +76,4 @@ fixedValuePointPatchField::fixedValuePointPatchField {} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/OpenFOAM/fields/pointPatchFields/basic/zeroGradient/zeroGradientPointPatchField.C b/src/OpenFOAM/fields/pointPatchFields/basic/zeroGradient/zeroGradientPointPatchField.C index 754ba28d75..9ca14e2ca5 100644 --- a/src/OpenFOAM/fields/pointPatchFields/basic/zeroGradient/zeroGradientPointPatchField.C +++ b/src/OpenFOAM/fields/pointPatchFields/basic/zeroGradient/zeroGradientPointPatchField.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 @@ -25,15 +25,10 @@ License #include "zeroGradientPointPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -zeroGradientPointPatchField::zeroGradientPointPatchField +Foam::zeroGradientPointPatchField::zeroGradientPointPatchField ( const pointPatch& p, const DimensionedField& iF @@ -44,7 +39,7 @@ zeroGradientPointPatchField::zeroGradientPointPatchField template -zeroGradientPointPatchField::zeroGradientPointPatchField +Foam::zeroGradientPointPatchField::zeroGradientPointPatchField ( const pointPatch& p, const DimensionedField& iF, @@ -56,7 +51,7 @@ zeroGradientPointPatchField::zeroGradientPointPatchField template -zeroGradientPointPatchField::zeroGradientPointPatchField +Foam::zeroGradientPointPatchField::zeroGradientPointPatchField ( const zeroGradientPointPatchField& ptf, const pointPatch& p, @@ -69,7 +64,7 @@ zeroGradientPointPatchField::zeroGradientPointPatchField template -zeroGradientPointPatchField::zeroGradientPointPatchField +Foam::zeroGradientPointPatchField::zeroGradientPointPatchField ( const zeroGradientPointPatchField& ptf, const DimensionedField& iF @@ -79,8 +74,4 @@ zeroGradientPointPatchField::zeroGradientPointPatchField {} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/OpenFOAM/fields/pointPatchFields/constraint/empty/emptyPointPatchField.C b/src/OpenFOAM/fields/pointPatchFields/constraint/empty/emptyPointPatchField.C index 6435a72c12..8fbbaadd07 100644 --- a/src/OpenFOAM/fields/pointPatchFields/constraint/empty/emptyPointPatchField.C +++ b/src/OpenFOAM/fields/pointPatchFields/constraint/empty/emptyPointPatchField.C @@ -25,15 +25,10 @@ License #include "emptyPointPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -emptyPointPatchField::emptyPointPatchField +Foam::emptyPointPatchField::emptyPointPatchField ( const pointPatch& p, const DimensionedField& iF @@ -44,7 +39,7 @@ emptyPointPatchField::emptyPointPatchField template -emptyPointPatchField::emptyPointPatchField +Foam::emptyPointPatchField::emptyPointPatchField ( const pointPatch& p, const DimensionedField& iF, @@ -66,7 +61,7 @@ emptyPointPatchField::emptyPointPatchField template -emptyPointPatchField::emptyPointPatchField +Foam::emptyPointPatchField::emptyPointPatchField ( const emptyPointPatchField& ptf, const pointPatch& p, @@ -89,7 +84,7 @@ emptyPointPatchField::emptyPointPatchField template -emptyPointPatchField::emptyPointPatchField +Foam::emptyPointPatchField::emptyPointPatchField ( const emptyPointPatchField& ptf, const DimensionedField& iF @@ -99,8 +94,4 @@ emptyPointPatchField::emptyPointPatchField {} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/OpenFOAM/fields/pointPatchFields/constraint/processor/processorPointPatchField.C b/src/OpenFOAM/fields/pointPatchFields/constraint/processor/processorPointPatchField.C index 8a647b6db0..011129adc8 100644 --- a/src/OpenFOAM/fields/pointPatchFields/constraint/processor/processorPointPatchField.C +++ b/src/OpenFOAM/fields/pointPatchFields/constraint/processor/processorPointPatchField.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 @@ -26,15 +26,10 @@ License #include "processorPointPatchField.H" #include "processorPolyPatch.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -processorPointPatchField::processorPointPatchField +Foam::processorPointPatchField::processorPointPatchField ( const pointPatch& p, const DimensionedField& iF @@ -46,7 +41,7 @@ processorPointPatchField::processorPointPatchField template -processorPointPatchField::processorPointPatchField +Foam::processorPointPatchField::processorPointPatchField ( const pointPatch& p, const DimensionedField& iF, @@ -59,7 +54,7 @@ processorPointPatchField::processorPointPatchField template -processorPointPatchField::processorPointPatchField +Foam::processorPointPatchField::processorPointPatchField ( const processorPointPatchField& ptf, const pointPatch& p, @@ -73,7 +68,7 @@ processorPointPatchField::processorPointPatchField template -processorPointPatchField::processorPointPatchField +Foam::processorPointPatchField::processorPointPatchField ( const processorPointPatchField& ptf, const DimensionedField& iF @@ -87,12 +82,8 @@ processorPointPatchField::processorPointPatchField // * * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * // template -processorPointPatchField::~processorPointPatchField() +Foam::processorPointPatchField::~processorPointPatchField() {} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/OpenFOAM/fields/pointPatchFields/constraint/symmetry/symmetryPointPatchField.C b/src/OpenFOAM/fields/pointPatchFields/constraint/symmetry/symmetryPointPatchField.C index 4e11109261..250b438ff9 100644 --- a/src/OpenFOAM/fields/pointPatchFields/constraint/symmetry/symmetryPointPatchField.C +++ b/src/OpenFOAM/fields/pointPatchFields/constraint/symmetry/symmetryPointPatchField.C @@ -25,15 +25,10 @@ License #include "symmetryPointPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -symmetryPointPatchField::symmetryPointPatchField +Foam::symmetryPointPatchField::symmetryPointPatchField ( const pointPatch& p, const DimensionedField& iF @@ -44,7 +39,7 @@ symmetryPointPatchField::symmetryPointPatchField template -symmetryPointPatchField::symmetryPointPatchField +Foam::symmetryPointPatchField::symmetryPointPatchField ( const pointPatch& p, const DimensionedField& iF, @@ -66,7 +61,7 @@ symmetryPointPatchField::symmetryPointPatchField template -symmetryPointPatchField::symmetryPointPatchField +Foam::symmetryPointPatchField::symmetryPointPatchField ( const symmetryPointPatchField& ptf, const pointPatch& p, @@ -89,7 +84,7 @@ symmetryPointPatchField::symmetryPointPatchField template -symmetryPointPatchField::symmetryPointPatchField +Foam::symmetryPointPatchField::symmetryPointPatchField ( const symmetryPointPatchField& ptf, const DimensionedField& iF @@ -99,8 +94,4 @@ symmetryPointPatchField::symmetryPointPatchField {} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/OpenFOAM/fields/pointPatchFields/constraint/symmetryPlane/symmetryPlanePointPatchField.C b/src/OpenFOAM/fields/pointPatchFields/constraint/symmetryPlane/symmetryPlanePointPatchField.C index c988248e2e..c402bad230 100644 --- a/src/OpenFOAM/fields/pointPatchFields/constraint/symmetryPlane/symmetryPlanePointPatchField.C +++ b/src/OpenFOAM/fields/pointPatchFields/constraint/symmetryPlane/symmetryPlanePointPatchField.C @@ -25,15 +25,10 @@ License #include "symmetryPlanePointPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -symmetryPlanePointPatchField::symmetryPlanePointPatchField +Foam::symmetryPlanePointPatchField::symmetryPlanePointPatchField ( const pointPatch& p, const DimensionedField& iF @@ -45,7 +40,7 @@ symmetryPlanePointPatchField::symmetryPlanePointPatchField template -symmetryPlanePointPatchField::symmetryPlanePointPatchField +Foam::symmetryPlanePointPatchField::symmetryPlanePointPatchField ( const pointPatch& p, const DimensionedField& iF, @@ -68,7 +63,7 @@ symmetryPlanePointPatchField::symmetryPlanePointPatchField template -symmetryPlanePointPatchField::symmetryPlanePointPatchField +Foam::symmetryPlanePointPatchField::symmetryPlanePointPatchField ( const symmetryPlanePointPatchField& ptf, const pointPatch& p, @@ -92,7 +87,7 @@ symmetryPlanePointPatchField::symmetryPlanePointPatchField template -symmetryPlanePointPatchField::symmetryPlanePointPatchField +Foam::symmetryPlanePointPatchField::symmetryPlanePointPatchField ( const symmetryPlanePointPatchField& ptf, const DimensionedField& iF @@ -128,8 +123,4 @@ void Foam::symmetryPlanePointPatchField::evaluate } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/OpenFOAM/fields/pointPatchFields/derived/slip/slipPointPatchField.C b/src/OpenFOAM/fields/pointPatchFields/derived/slip/slipPointPatchField.C index 62f95b4eb5..902e73f6f7 100644 --- a/src/OpenFOAM/fields/pointPatchFields/derived/slip/slipPointPatchField.C +++ b/src/OpenFOAM/fields/pointPatchFields/derived/slip/slipPointPatchField.C @@ -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 @@ -25,15 +25,10 @@ License #include "slipPointPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -slipPointPatchField::slipPointPatchField +Foam::slipPointPatchField::slipPointPatchField ( const pointPatch& p, const DimensionedField& iF @@ -44,7 +39,7 @@ slipPointPatchField::slipPointPatchField template -slipPointPatchField::slipPointPatchField +Foam::slipPointPatchField::slipPointPatchField ( const pointPatch& p, const DimensionedField& iF, @@ -56,7 +51,7 @@ slipPointPatchField::slipPointPatchField template -slipPointPatchField::slipPointPatchField +Foam::slipPointPatchField::slipPointPatchField ( const slipPointPatchField& ptf, const pointPatch& p, @@ -69,7 +64,7 @@ slipPointPatchField::slipPointPatchField template -slipPointPatchField::slipPointPatchField +Foam::slipPointPatchField::slipPointPatchField ( const slipPointPatchField& ptf, const DimensionedField& iF @@ -79,8 +74,4 @@ slipPointPatchField::slipPointPatchField {} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/OpenFOAM/fields/pointPatchFields/derived/uniformFixedValue/uniformFixedValuePointPatchField.C b/src/OpenFOAM/fields/pointPatchFields/derived/uniformFixedValue/uniformFixedValuePointPatchField.C index 0b626d888c..ae42db3989 100644 --- a/src/OpenFOAM/fields/pointPatchFields/derived/uniformFixedValue/uniformFixedValuePointPatchField.C +++ b/src/OpenFOAM/fields/pointPatchFields/derived/uniformFixedValue/uniformFixedValuePointPatchField.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -25,15 +25,10 @@ License #include "uniformFixedValuePointPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * * // template -uniformFixedValuePointPatchField:: +Foam::uniformFixedValuePointPatchField:: uniformFixedValuePointPatchField ( const pointPatch& p, @@ -46,7 +41,7 @@ uniformFixedValuePointPatchField template -uniformFixedValuePointPatchField:: +Foam::uniformFixedValuePointPatchField:: uniformFixedValuePointPatchField ( const pointPatch& p, @@ -73,7 +68,7 @@ uniformFixedValuePointPatchField template -uniformFixedValuePointPatchField:: +Foam::uniformFixedValuePointPatchField:: uniformFixedValuePointPatchField ( const uniformFixedValuePointPatchField& ptf, @@ -92,7 +87,7 @@ uniformFixedValuePointPatchField template -uniformFixedValuePointPatchField:: +Foam::uniformFixedValuePointPatchField:: uniformFixedValuePointPatchField ( const uniformFixedValuePointPatchField& ptf @@ -104,7 +99,7 @@ uniformFixedValuePointPatchField template -uniformFixedValuePointPatchField:: +Foam::uniformFixedValuePointPatchField:: uniformFixedValuePointPatchField ( const uniformFixedValuePointPatchField& ptf, @@ -123,7 +118,7 @@ uniformFixedValuePointPatchField // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -void uniformFixedValuePointPatchField::updateCoeffs() +void Foam::uniformFixedValuePointPatchField::updateCoeffs() { if (this->updated()) { @@ -138,7 +133,7 @@ void uniformFixedValuePointPatchField::updateCoeffs() template -void uniformFixedValuePointPatchField:: +void Foam::uniformFixedValuePointPatchField:: write(Ostream& os) const { // Note: write value @@ -147,8 +142,4 @@ write(Ostream& os) const } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/OpenFOAM/fields/pointPatchFields/pointPatchField/pointPatchField.C b/src/OpenFOAM/fields/pointPatchFields/pointPatchField/pointPatchField.C index 64daf799fd..92c62d0703 100644 --- a/src/OpenFOAM/fields/pointPatchFields/pointPatchField/pointPatchField.C +++ b/src/OpenFOAM/fields/pointPatchFields/pointPatchField/pointPatchField.C @@ -27,15 +27,10 @@ License #include "pointMesh.H" #include "dictionary.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -pointPatchField::pointPatchField +Foam::pointPatchField::pointPatchField ( const pointPatch& p, const DimensionedField& iF @@ -49,7 +44,7 @@ pointPatchField::pointPatchField template -pointPatchField::pointPatchField +Foam::pointPatchField::pointPatchField ( const pointPatch& p, const DimensionedField& iF, @@ -80,7 +75,7 @@ Foam::pointPatchField::pointPatchField template -pointPatchField::pointPatchField +Foam::pointPatchField::pointPatchField ( const pointPatchField& ptf ) @@ -93,7 +88,7 @@ pointPatchField::pointPatchField template -pointPatchField::pointPatchField +Foam::pointPatchField::pointPatchField ( const pointPatchField& ptf, const DimensionedField& iF @@ -109,14 +104,14 @@ pointPatchField::pointPatchField // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -const objectRegistry& pointPatchField::db() const +const Foam::objectRegistry& Foam::pointPatchField::db() const { return patch_.boundaryMesh().mesh()(); } template -void pointPatchField::write(Ostream& os) const +void Foam::pointPatchField::write(Ostream& os) const { os.writeKeyword("type") << type() << token::END_STATEMENT << nl; @@ -129,7 +124,8 @@ void pointPatchField::write(Ostream& os) const template -tmp > pointPatchField::patchInternalField() const +Foam::tmp > +Foam::pointPatchField::patchInternalField() const { return patchInternalField(internalField()); } @@ -137,7 +133,8 @@ tmp > pointPatchField::patchInternalField() const template template -tmp > pointPatchField::patchInternalField +Foam::tmp > +Foam::pointPatchField::patchInternalField ( const Field& iF, const labelList& meshPoints @@ -159,7 +156,8 @@ tmp > pointPatchField::patchInternalField template template -tmp > pointPatchField::patchInternalField +Foam::tmp > +Foam::pointPatchField::patchInternalField ( const Field& iF ) const @@ -170,7 +168,7 @@ tmp > pointPatchField::patchInternalField template template -void pointPatchField::addToInternalField +void Foam::pointPatchField::addToInternalField ( Field& iF, const Field& pF @@ -207,7 +205,7 @@ void pointPatchField::addToInternalField template template -void pointPatchField::addToInternalField +void Foam::pointPatchField::addToInternalField ( Field& iF, const Field& pF, @@ -246,7 +244,7 @@ void pointPatchField::addToInternalField template template -void pointPatchField::setInInternalField +void Foam::pointPatchField::setInInternalField ( Field& iF, const Field& pF, @@ -281,7 +279,7 @@ void pointPatchField::setInInternalField template template -void pointPatchField::setInInternalField +void Foam::pointPatchField::setInInternalField ( Field& iF, const Field& pF @@ -292,7 +290,7 @@ void pointPatchField::setInInternalField template -void pointPatchField::evaluate(const Pstream::commsTypes) +void Foam::pointPatchField::evaluate(const Pstream::commsTypes) { if (!updated_) { @@ -306,7 +304,7 @@ void pointPatchField::evaluate(const Pstream::commsTypes) // * * * * * * * * * * * * * * * IOstream Operators * * * * * * * * * * * * // template -Ostream& operator<< +Foam::Ostream& Foam::operator<< ( Ostream& os, const pointPatchField& ptf @@ -320,10 +318,6 @@ Ostream& operator<< } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // #include "pointPatchFieldNew.C" diff --git a/src/TurbulenceModels/turbulenceModels/derivedFvPatchFields/wallFunctions/kqRWallFunctions/kqRWallFunction/kqRWallFunctionFvPatchField.C b/src/TurbulenceModels/turbulenceModels/derivedFvPatchFields/wallFunctions/kqRWallFunctions/kqRWallFunction/kqRWallFunctionFvPatchField.C index 6afabdcc6c..4ecd27f1d6 100644 --- a/src/TurbulenceModels/turbulenceModels/derivedFvPatchFields/wallFunctions/kqRWallFunctions/kqRWallFunction/kqRWallFunctionFvPatchField.C +++ b/src/TurbulenceModels/turbulenceModels/derivedFvPatchFields/wallFunctions/kqRWallFunctions/kqRWallFunction/kqRWallFunctionFvPatchField.C @@ -28,15 +28,10 @@ License #include "addToRunTimeSelectionTable.H" #include "wallFvPatch.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * // template -void kqRWallFunctionFvPatchField::checkType() +void Foam::kqRWallFunctionFvPatchField::checkType() { if (!isA(this->patch())) { @@ -54,7 +49,7 @@ void kqRWallFunctionFvPatchField::checkType() // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -kqRWallFunctionFvPatchField::kqRWallFunctionFvPatchField +Foam::kqRWallFunctionFvPatchField::kqRWallFunctionFvPatchField ( const fvPatch& p, const DimensionedField& iF @@ -67,7 +62,21 @@ kqRWallFunctionFvPatchField::kqRWallFunctionFvPatchField template -kqRWallFunctionFvPatchField::kqRWallFunctionFvPatchField +Foam::kqRWallFunctionFvPatchField::kqRWallFunctionFvPatchField +( + const fvPatch& p, + const DimensionedField& iF, + const dictionary& dict +) +: + zeroGradientFvPatchField(p, iF, dict) +{ + checkType(); +} + + +template +Foam::kqRWallFunctionFvPatchField::kqRWallFunctionFvPatchField ( const kqRWallFunctionFvPatchField& ptf, const fvPatch& p, @@ -82,21 +91,7 @@ kqRWallFunctionFvPatchField::kqRWallFunctionFvPatchField template -kqRWallFunctionFvPatchField::kqRWallFunctionFvPatchField -( - const fvPatch& p, - const DimensionedField& iF, - const dictionary& dict -) -: - zeroGradientFvPatchField(p, iF, dict) -{ - checkType(); -} - - -template -kqRWallFunctionFvPatchField::kqRWallFunctionFvPatchField +Foam::kqRWallFunctionFvPatchField::kqRWallFunctionFvPatchField ( const kqRWallFunctionFvPatchField& tkqrwfpf ) @@ -108,7 +103,7 @@ kqRWallFunctionFvPatchField::kqRWallFunctionFvPatchField template -kqRWallFunctionFvPatchField::kqRWallFunctionFvPatchField +Foam::kqRWallFunctionFvPatchField::kqRWallFunctionFvPatchField ( const kqRWallFunctionFvPatchField& tkqrwfpf, const DimensionedField& iF @@ -123,7 +118,7 @@ kqRWallFunctionFvPatchField::kqRWallFunctionFvPatchField // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -void kqRWallFunctionFvPatchField::evaluate +void Foam::kqRWallFunctionFvPatchField::evaluate ( const Pstream::commsTypes commsType ) @@ -133,15 +128,11 @@ void kqRWallFunctionFvPatchField::evaluate template -void kqRWallFunctionFvPatchField::write(Ostream& os) const +void Foam::kqRWallFunctionFvPatchField::write(Ostream& os) const { zeroGradientFvPatchField::write(os); this->writeEntry("value", os); } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvPatchFields/basic/fixedGradient/fixedGradientFvPatchField.C b/src/finiteVolume/fields/fvPatchFields/basic/fixedGradient/fixedGradientFvPatchField.C index 112ddb42f4..2165282197 100644 --- a/src/finiteVolume/fields/fvPatchFields/basic/fixedGradient/fixedGradientFvPatchField.C +++ b/src/finiteVolume/fields/fvPatchFields/basic/fixedGradient/fixedGradientFvPatchField.C @@ -26,15 +26,10 @@ License #include "fixedGradientFvPatchField.H" #include "dictionary.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -fixedGradientFvPatchField::fixedGradientFvPatchField +Foam::fixedGradientFvPatchField::fixedGradientFvPatchField ( const fvPatch& p, const DimensionedField& iF @@ -46,7 +41,22 @@ fixedGradientFvPatchField::fixedGradientFvPatchField template -fixedGradientFvPatchField::fixedGradientFvPatchField +Foam::fixedGradientFvPatchField::fixedGradientFvPatchField +( + const fvPatch& p, + const DimensionedField& iF, + const dictionary& dict +) +: + fvPatchField(p, iF, dict), + gradient_("gradient", dict, p.size()) +{ + evaluate(); +} + + +template +Foam::fixedGradientFvPatchField::fixedGradientFvPatchField ( const fixedGradientFvPatchField& ptf, const fvPatch& p, @@ -70,22 +80,7 @@ fixedGradientFvPatchField::fixedGradientFvPatchField template -fixedGradientFvPatchField::fixedGradientFvPatchField -( - const fvPatch& p, - const DimensionedField& iF, - const dictionary& dict -) -: - fvPatchField(p, iF, dict), - gradient_("gradient", dict, p.size()) -{ - evaluate(); -} - - -template -fixedGradientFvPatchField::fixedGradientFvPatchField +Foam::fixedGradientFvPatchField::fixedGradientFvPatchField ( const fixedGradientFvPatchField& ptf ) @@ -96,7 +91,7 @@ fixedGradientFvPatchField::fixedGradientFvPatchField template -fixedGradientFvPatchField::fixedGradientFvPatchField +Foam::fixedGradientFvPatchField::fixedGradientFvPatchField ( const fixedGradientFvPatchField& ptf, const DimensionedField& iF @@ -110,7 +105,7 @@ fixedGradientFvPatchField::fixedGradientFvPatchField // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -void fixedGradientFvPatchField::autoMap +void Foam::fixedGradientFvPatchField::autoMap ( const fvPatchFieldMapper& m ) @@ -121,7 +116,7 @@ void fixedGradientFvPatchField::autoMap template -void fixedGradientFvPatchField::rmap +void Foam::fixedGradientFvPatchField::rmap ( const fvPatchField& ptf, const labelList& addr @@ -137,7 +132,7 @@ void fixedGradientFvPatchField::rmap template -void fixedGradientFvPatchField::evaluate(const Pstream::commsTypes) +void Foam::fixedGradientFvPatchField::evaluate(const Pstream::commsTypes) { if (!this->updated()) { @@ -154,7 +149,8 @@ void fixedGradientFvPatchField::evaluate(const Pstream::commsTypes) template -tmp > fixedGradientFvPatchField::valueInternalCoeffs +Foam::tmp > +Foam::fixedGradientFvPatchField::valueInternalCoeffs ( const tmp& ) const @@ -164,7 +160,8 @@ tmp > fixedGradientFvPatchField::valueInternalCoeffs template -tmp > fixedGradientFvPatchField::valueBoundaryCoeffs +Foam::tmp > +Foam::fixedGradientFvPatchField::valueBoundaryCoeffs ( const tmp& ) const @@ -174,8 +171,8 @@ tmp > fixedGradientFvPatchField::valueBoundaryCoeffs template -tmp > fixedGradientFvPatchField:: -gradientInternalCoeffs() const +Foam::tmp > +Foam::fixedGradientFvPatchField::gradientInternalCoeffs() const { return tmp > ( @@ -185,23 +182,19 @@ gradientInternalCoeffs() const template -tmp > fixedGradientFvPatchField:: -gradientBoundaryCoeffs() const +Foam::tmp > +Foam::fixedGradientFvPatchField::gradientBoundaryCoeffs() const { return gradient(); } template -void fixedGradientFvPatchField::write(Ostream& os) const +void Foam::fixedGradientFvPatchField::write(Ostream& os) const { fvPatchField::write(os); gradient_.writeEntry("gradient", os); } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvPatchFields/basic/fixedValue/fixedValueFvPatchField.C b/src/finiteVolume/fields/fvPatchFields/basic/fixedValue/fixedValueFvPatchField.C index 6ab4ce6e13..442d1b0fea 100644 --- a/src/finiteVolume/fields/fvPatchFields/basic/fixedValue/fixedValueFvPatchField.C +++ b/src/finiteVolume/fields/fvPatchFields/basic/fixedValue/fixedValueFvPatchField.C @@ -25,15 +25,10 @@ License #include "fixedValueFvPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -fixedValueFvPatchField::fixedValueFvPatchField +Foam::fixedValueFvPatchField::fixedValueFvPatchField ( const fvPatch& p, const DimensionedField& iF @@ -44,7 +39,7 @@ fixedValueFvPatchField::fixedValueFvPatchField template -fixedValueFvPatchField::fixedValueFvPatchField +Foam::fixedValueFvPatchField::fixedValueFvPatchField ( const fvPatch& p, const DimensionedField& iF, @@ -56,7 +51,7 @@ fixedValueFvPatchField::fixedValueFvPatchField template -fixedValueFvPatchField::fixedValueFvPatchField +Foam::fixedValueFvPatchField::fixedValueFvPatchField ( const fixedValueFvPatchField& ptf, const fvPatch& p, @@ -79,7 +74,7 @@ fixedValueFvPatchField::fixedValueFvPatchField template -fixedValueFvPatchField::fixedValueFvPatchField +Foam::fixedValueFvPatchField::fixedValueFvPatchField ( const fixedValueFvPatchField& ptf ) @@ -89,7 +84,7 @@ fixedValueFvPatchField::fixedValueFvPatchField template -fixedValueFvPatchField::fixedValueFvPatchField +Foam::fixedValueFvPatchField::fixedValueFvPatchField ( const fixedValueFvPatchField& ptf, const DimensionedField& iF @@ -102,7 +97,8 @@ fixedValueFvPatchField::fixedValueFvPatchField // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -tmp > fixedValueFvPatchField::valueInternalCoeffs +Foam::tmp > +Foam::fixedValueFvPatchField::valueInternalCoeffs ( const tmp& ) const @@ -115,7 +111,8 @@ tmp > fixedValueFvPatchField::valueInternalCoeffs template -tmp > fixedValueFvPatchField::valueBoundaryCoeffs +Foam::tmp > +Foam::fixedValueFvPatchField::valueBoundaryCoeffs ( const tmp& ) const @@ -125,29 +122,27 @@ tmp > fixedValueFvPatchField::valueBoundaryCoeffs template -tmp > fixedValueFvPatchField::gradientInternalCoeffs() const +Foam::tmp > +Foam::fixedValueFvPatchField::gradientInternalCoeffs() const { return -pTraits::one*this->patch().deltaCoeffs(); } template -tmp > fixedValueFvPatchField::gradientBoundaryCoeffs() const +Foam::tmp > +Foam::fixedValueFvPatchField::gradientBoundaryCoeffs() const { return this->patch().deltaCoeffs()*(*this); } template -void fixedValueFvPatchField::write(Ostream& os) const +void Foam::fixedValueFvPatchField::write(Ostream& os) const { fvPatchField::write(os); this->writeEntry("value", os); } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvPatchFields/basic/mixed/mixedFvPatchField.C b/src/finiteVolume/fields/fvPatchFields/basic/mixed/mixedFvPatchField.C index 23eef7e24b..fca0149d0c 100644 --- a/src/finiteVolume/fields/fvPatchFields/basic/mixed/mixedFvPatchField.C +++ b/src/finiteVolume/fields/fvPatchFields/basic/mixed/mixedFvPatchField.C @@ -25,15 +25,10 @@ License #include "mixedFvPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -mixedFvPatchField::mixedFvPatchField +Foam::mixedFvPatchField::mixedFvPatchField ( const fvPatch& p, const DimensionedField& iF @@ -47,7 +42,24 @@ mixedFvPatchField::mixedFvPatchField template -mixedFvPatchField::mixedFvPatchField +Foam::mixedFvPatchField::mixedFvPatchField +( + const fvPatch& p, + const DimensionedField& iF, + const dictionary& dict +) +: + fvPatchField(p, iF, dict), + refValue_("refValue", dict, p.size()), + refGrad_("refGradient", dict, p.size()), + valueFraction_("valueFraction", dict, p.size()) +{ + evaluate(); +} + + +template +Foam::mixedFvPatchField::mixedFvPatchField ( const mixedFvPatchField& ptf, const fvPatch& p, @@ -73,24 +85,7 @@ mixedFvPatchField::mixedFvPatchField template -mixedFvPatchField::mixedFvPatchField -( - const fvPatch& p, - const DimensionedField& iF, - const dictionary& dict -) -: - fvPatchField(p, iF, dict), - refValue_("refValue", dict, p.size()), - refGrad_("refGradient", dict, p.size()), - valueFraction_("valueFraction", dict, p.size()) -{ - evaluate(); -} - - -template -mixedFvPatchField::mixedFvPatchField +Foam::mixedFvPatchField::mixedFvPatchField ( const mixedFvPatchField& ptf ) @@ -103,7 +98,7 @@ mixedFvPatchField::mixedFvPatchField template -mixedFvPatchField::mixedFvPatchField +Foam::mixedFvPatchField::mixedFvPatchField ( const mixedFvPatchField& ptf, const DimensionedField& iF @@ -119,7 +114,7 @@ mixedFvPatchField::mixedFvPatchField // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -void mixedFvPatchField::autoMap +void Foam::mixedFvPatchField::autoMap ( const fvPatchFieldMapper& m ) @@ -132,7 +127,7 @@ void mixedFvPatchField::autoMap template -void mixedFvPatchField::rmap +void Foam::mixedFvPatchField::rmap ( const fvPatchField& ptf, const labelList& addr @@ -150,7 +145,7 @@ void mixedFvPatchField::rmap template -void mixedFvPatchField::evaluate(const Pstream::commsTypes) +void Foam::mixedFvPatchField::evaluate(const Pstream::commsTypes) { if (!this->updated()) { @@ -173,7 +168,8 @@ void mixedFvPatchField::evaluate(const Pstream::commsTypes) template -tmp > mixedFvPatchField::snGrad() const +Foam::tmp > +Foam::mixedFvPatchField::snGrad() const { return valueFraction_ @@ -184,7 +180,8 @@ tmp > mixedFvPatchField::snGrad() const template -tmp > mixedFvPatchField::valueInternalCoeffs +Foam::tmp > +Foam::mixedFvPatchField::valueInternalCoeffs ( const tmp& ) const @@ -195,7 +192,8 @@ tmp > mixedFvPatchField::valueInternalCoeffs template -tmp > mixedFvPatchField::valueBoundaryCoeffs +Foam::tmp > +Foam::mixedFvPatchField::valueBoundaryCoeffs ( const tmp& ) const @@ -207,14 +205,16 @@ tmp > mixedFvPatchField::valueBoundaryCoeffs template -tmp > mixedFvPatchField::gradientInternalCoeffs() const +Foam::tmp > +Foam::mixedFvPatchField::gradientInternalCoeffs() const { return -Type(pTraits::one)*valueFraction_*this->patch().deltaCoeffs(); } template -tmp > mixedFvPatchField::gradientBoundaryCoeffs() const +Foam::tmp > +Foam::mixedFvPatchField::gradientBoundaryCoeffs() const { return valueFraction_*this->patch().deltaCoeffs()*refValue_ @@ -223,7 +223,7 @@ tmp > mixedFvPatchField::gradientBoundaryCoeffs() const template -void mixedFvPatchField::write(Ostream& os) const +void Foam::mixedFvPatchField::write(Ostream& os) const { fvPatchField::write(os); refValue_.writeEntry("refValue", os); @@ -233,8 +233,4 @@ void mixedFvPatchField::write(Ostream& os) const } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvPatchFields/basic/sliced/slicedFvPatchField.C b/src/finiteVolume/fields/fvPatchFields/basic/sliced/slicedFvPatchField.C index 9e581c6e90..9938891051 100644 --- a/src/finiteVolume/fields/fvPatchFields/basic/sliced/slicedFvPatchField.C +++ b/src/finiteVolume/fields/fvPatchFields/basic/sliced/slicedFvPatchField.C @@ -25,15 +25,10 @@ License #include "slicedFvPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -slicedFvPatchField::slicedFvPatchField +Foam::slicedFvPatchField::slicedFvPatchField ( const fvPatch& p, const DimensionedField& iF, @@ -48,7 +43,7 @@ slicedFvPatchField::slicedFvPatchField template -slicedFvPatchField::slicedFvPatchField +Foam::slicedFvPatchField::slicedFvPatchField ( const fvPatch& p, const DimensionedField& iF @@ -59,7 +54,21 @@ slicedFvPatchField::slicedFvPatchField template -slicedFvPatchField::slicedFvPatchField +Foam::slicedFvPatchField::slicedFvPatchField +( + const fvPatch& p, + const DimensionedField& iF, + const dictionary& dict +) +: + fvPatchField(p, iF, dict) +{ + NotImplemented; +} + + +template +Foam::slicedFvPatchField::slicedFvPatchField ( const slicedFvPatchField& ptf, const fvPatch& p, @@ -74,21 +83,7 @@ slicedFvPatchField::slicedFvPatchField template -slicedFvPatchField::slicedFvPatchField -( - const fvPatch& p, - const DimensionedField& iF, - const dictionary& dict -) -: - fvPatchField(p, iF, dict) -{ - NotImplemented; -} - - -template -slicedFvPatchField::slicedFvPatchField +Foam::slicedFvPatchField::slicedFvPatchField ( const slicedFvPatchField& ptf, const DimensionedField& iF @@ -100,8 +95,10 @@ slicedFvPatchField::slicedFvPatchField UList::operator=(ptf); } + template -tmp > slicedFvPatchField::clone() const +Foam::tmp > +Foam::slicedFvPatchField::clone() const { return tmp > ( @@ -111,7 +108,7 @@ tmp > slicedFvPatchField::clone() const template -slicedFvPatchField::slicedFvPatchField +Foam::slicedFvPatchField::slicedFvPatchField ( const slicedFvPatchField& ptf ) @@ -129,7 +126,8 @@ slicedFvPatchField::slicedFvPatchField template -tmp > slicedFvPatchField::clone +Foam::tmp > +Foam::slicedFvPatchField::clone ( const DimensionedField& iF ) const @@ -142,7 +140,7 @@ tmp > slicedFvPatchField::clone template -slicedFvPatchField::~slicedFvPatchField() +Foam::slicedFvPatchField::~slicedFvPatchField() { // Set the fvPatchField storage pointer to NULL before its destruction // to protect the field it a slice of. @@ -153,7 +151,7 @@ slicedFvPatchField::~slicedFvPatchField() // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -tmp > slicedFvPatchField::snGrad() const +Foam::tmp > Foam::slicedFvPatchField::snGrad() const { NotImplemented; @@ -162,14 +160,15 @@ tmp > slicedFvPatchField::snGrad() const template -void slicedFvPatchField::updateCoeffs() +void Foam::slicedFvPatchField::updateCoeffs() { NotImplemented; } template -tmp > slicedFvPatchField::patchInternalField() const +Foam::tmp > +Foam::slicedFvPatchField::patchInternalField() const { NotImplemented; @@ -178,14 +177,15 @@ tmp > slicedFvPatchField::patchInternalField() const template -void slicedFvPatchField::patchInternalField(Field&) const +void Foam::slicedFvPatchField::patchInternalField(Field&) const { NotImplemented; } template -tmp > slicedFvPatchField::patchNeighbourField +Foam::tmp > +Foam::slicedFvPatchField::patchNeighbourField ( const Field& iField ) const @@ -197,7 +197,8 @@ tmp > slicedFvPatchField::patchNeighbourField template -tmp > slicedFvPatchField::patchNeighbourField() const +Foam::tmp > +Foam::slicedFvPatchField::patchNeighbourField() const { NotImplemented; @@ -206,7 +207,8 @@ tmp > slicedFvPatchField::patchNeighbourField() const template -tmp > slicedFvPatchField::valueInternalCoeffs +Foam::tmp > +Foam::slicedFvPatchField::valueInternalCoeffs ( const tmp& ) const @@ -218,7 +220,8 @@ tmp > slicedFvPatchField::valueInternalCoeffs template -tmp > slicedFvPatchField::valueBoundaryCoeffs +Foam::tmp > +Foam::slicedFvPatchField::valueBoundaryCoeffs ( const tmp& ) const @@ -230,7 +233,8 @@ tmp > slicedFvPatchField::valueBoundaryCoeffs template -tmp > slicedFvPatchField::gradientInternalCoeffs() const +Foam::tmp > +Foam::slicedFvPatchField::gradientInternalCoeffs() const { NotImplemented; @@ -239,7 +243,8 @@ tmp > slicedFvPatchField::gradientInternalCoeffs() const template -tmp > slicedFvPatchField::gradientBoundaryCoeffs() const +Foam::tmp > +Foam::slicedFvPatchField::gradientBoundaryCoeffs() const { NotImplemented; @@ -248,15 +253,11 @@ tmp > slicedFvPatchField::gradientBoundaryCoeffs() const template -void slicedFvPatchField::write(Ostream& os) const +void Foam::slicedFvPatchField::write(Ostream& os) const { fvPatchField::write(os); this->writeEntry("value", os); } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvPatchFields/basic/zeroGradient/zeroGradientFvPatchField.C b/src/finiteVolume/fields/fvPatchFields/basic/zeroGradient/zeroGradientFvPatchField.C index b33e00277b..af57247f24 100644 --- a/src/finiteVolume/fields/fvPatchFields/basic/zeroGradient/zeroGradientFvPatchField.C +++ b/src/finiteVolume/fields/fvPatchFields/basic/zeroGradient/zeroGradientFvPatchField.C @@ -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 @@ -26,15 +26,10 @@ License #include "zeroGradientFvPatchField.H" #include "fvPatchFieldMapper.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -zeroGradientFvPatchField::zeroGradientFvPatchField +Foam::zeroGradientFvPatchField::zeroGradientFvPatchField ( const fvPatch& p, const DimensionedField& iF @@ -45,20 +40,7 @@ zeroGradientFvPatchField::zeroGradientFvPatchField template -zeroGradientFvPatchField::zeroGradientFvPatchField -( - const zeroGradientFvPatchField& ptf, - const fvPatch& p, - const DimensionedField& iF, - const fvPatchFieldMapper& mapper -) -: - fvPatchField(ptf, p, iF, mapper) -{} - - -template -zeroGradientFvPatchField::zeroGradientFvPatchField +Foam::zeroGradientFvPatchField::zeroGradientFvPatchField ( const fvPatch& p, const DimensionedField& iF, @@ -72,7 +54,20 @@ zeroGradientFvPatchField::zeroGradientFvPatchField template -zeroGradientFvPatchField::zeroGradientFvPatchField +Foam::zeroGradientFvPatchField::zeroGradientFvPatchField +( + const zeroGradientFvPatchField& ptf, + const fvPatch& p, + const DimensionedField& iF, + const fvPatchFieldMapper& mapper +) +: + fvPatchField(ptf, p, iF, mapper) +{} + + +template +Foam::zeroGradientFvPatchField::zeroGradientFvPatchField ( const zeroGradientFvPatchField& zgpf ) @@ -82,7 +77,7 @@ zeroGradientFvPatchField::zeroGradientFvPatchField template -zeroGradientFvPatchField::zeroGradientFvPatchField +Foam::zeroGradientFvPatchField::zeroGradientFvPatchField ( const zeroGradientFvPatchField& zgpf, const DimensionedField& iF @@ -95,7 +90,7 @@ zeroGradientFvPatchField::zeroGradientFvPatchField // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -void zeroGradientFvPatchField::evaluate(const Pstream::commsTypes) +void Foam::zeroGradientFvPatchField::evaluate(const Pstream::commsTypes) { if (!this->updated()) { @@ -108,7 +103,8 @@ void zeroGradientFvPatchField::evaluate(const Pstream::commsTypes) template -tmp > zeroGradientFvPatchField::valueInternalCoeffs +Foam::tmp > +Foam::zeroGradientFvPatchField::valueInternalCoeffs ( const tmp& ) const @@ -121,7 +117,8 @@ tmp > zeroGradientFvPatchField::valueInternalCoeffs template -tmp > zeroGradientFvPatchField::valueBoundaryCoeffs +Foam::tmp > +Foam::zeroGradientFvPatchField::valueBoundaryCoeffs ( const tmp& ) const @@ -134,7 +131,8 @@ tmp > zeroGradientFvPatchField::valueBoundaryCoeffs template -tmp > zeroGradientFvPatchField::gradientInternalCoeffs() const +Foam::tmp > +Foam::zeroGradientFvPatchField::gradientInternalCoeffs() const { return tmp > ( @@ -144,7 +142,8 @@ tmp > zeroGradientFvPatchField::gradientInternalCoeffs() const template -tmp > zeroGradientFvPatchField::gradientBoundaryCoeffs() const +Foam::tmp > +Foam::zeroGradientFvPatchField::gradientBoundaryCoeffs() const { return tmp > ( @@ -153,8 +152,4 @@ tmp > zeroGradientFvPatchField::gradientBoundaryCoeffs() const } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvPatchFields/constraint/cyclic/cyclicFvPatchField.C b/src/finiteVolume/fields/fvPatchFields/constraint/cyclic/cyclicFvPatchField.C index 9090ec02bb..2e404f3a4a 100644 --- a/src/finiteVolume/fields/fvPatchFields/constraint/cyclic/cyclicFvPatchField.C +++ b/src/finiteVolume/fields/fvPatchFields/constraint/cyclic/cyclicFvPatchField.C @@ -26,15 +26,10 @@ License #include "cyclicFvPatchField.H" #include "transformField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -cyclicFvPatchField::cyclicFvPatchField +Foam::cyclicFvPatchField::cyclicFvPatchField ( const fvPatch& p, const DimensionedField& iF @@ -46,31 +41,7 @@ cyclicFvPatchField::cyclicFvPatchField template -cyclicFvPatchField::cyclicFvPatchField -( - const cyclicFvPatchField& ptf, - const fvPatch& p, - const DimensionedField& iF, - const fvPatchFieldMapper& mapper -) -: - coupledFvPatchField(ptf, p, iF, mapper), - cyclicPatch_(refCast(p)) -{ - if (!isA(this->patch())) - { - FatalErrorInFunction - << "' not constraint type '" << typeName << "'" - << "\n for patch " << p.name() - << " of field " << this->dimensionedInternalField().name() - << " in file " << this->dimensionedInternalField().objectPath() - << exit(FatalIOError); - } -} - - -template -cyclicFvPatchField::cyclicFvPatchField +Foam::cyclicFvPatchField::cyclicFvPatchField ( const fvPatch& p, const DimensionedField& iF, @@ -98,7 +69,31 @@ cyclicFvPatchField::cyclicFvPatchField template -cyclicFvPatchField::cyclicFvPatchField +Foam::cyclicFvPatchField::cyclicFvPatchField +( + const cyclicFvPatchField& ptf, + const fvPatch& p, + const DimensionedField& iF, + const fvPatchFieldMapper& mapper +) +: + coupledFvPatchField(ptf, p, iF, mapper), + cyclicPatch_(refCast(p)) +{ + if (!isA(this->patch())) + { + FatalErrorInFunction + << "' not constraint type '" << typeName << "'" + << "\n for patch " << p.name() + << " of field " << this->dimensionedInternalField().name() + << " in file " << this->dimensionedInternalField().objectPath() + << exit(FatalIOError); + } +} + + +template +Foam::cyclicFvPatchField::cyclicFvPatchField ( const cyclicFvPatchField& ptf ) @@ -110,7 +105,7 @@ cyclicFvPatchField::cyclicFvPatchField template -cyclicFvPatchField::cyclicFvPatchField +Foam::cyclicFvPatchField::cyclicFvPatchField ( const cyclicFvPatchField& ptf, const DimensionedField& iF @@ -124,7 +119,8 @@ cyclicFvPatchField::cyclicFvPatchField // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -tmp > cyclicFvPatchField::patchNeighbourField() const +Foam::tmp > +Foam::cyclicFvPatchField::patchNeighbourField() const { const Field& iField = this->internalField(); const labelUList& nbrFaceCells = @@ -157,8 +153,8 @@ tmp > cyclicFvPatchField::patchNeighbourField() const template -const cyclicFvPatchField& cyclicFvPatchField::neighbourPatchField() -const +const Foam::cyclicFvPatchField& +Foam::cyclicFvPatchField::neighbourPatchField() const { const GeometricField& fld = static_cast&> @@ -174,7 +170,7 @@ const template -void cyclicFvPatchField::updateInterfaceMatrix +void Foam::cyclicFvPatchField::updateInterfaceMatrix ( scalarField& result, const scalarField& psiInternal, @@ -202,7 +198,7 @@ void cyclicFvPatchField::updateInterfaceMatrix template -void cyclicFvPatchField::updateInterfaceMatrix +void Foam::cyclicFvPatchField::updateInterfaceMatrix ( Field& result, const Field& psiInternal, @@ -229,14 +225,10 @@ void cyclicFvPatchField::updateInterfaceMatrix template -void cyclicFvPatchField::write(Ostream& os) const +void Foam::cyclicFvPatchField::write(Ostream& os) const { fvPatchField::write(os); } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvPatchFields/constraint/nonuniformTransformCyclic/nonuniformTransformCyclicFvPatchField.C b/src/finiteVolume/fields/fvPatchFields/constraint/nonuniformTransformCyclic/nonuniformTransformCyclicFvPatchField.C index 9f828449ad..a8d4712b16 100644 --- a/src/finiteVolume/fields/fvPatchFields/constraint/nonuniformTransformCyclic/nonuniformTransformCyclicFvPatchField.C +++ b/src/finiteVolume/fields/fvPatchFields/constraint/nonuniformTransformCyclic/nonuniformTransformCyclicFvPatchField.C @@ -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 @@ -25,15 +25,10 @@ License #include "nonuniformTransformCyclicFvPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -nonuniformTransformCyclicFvPatchField:: +Foam::nonuniformTransformCyclicFvPatchField:: nonuniformTransformCyclicFvPatchField ( const fvPatch& p, @@ -45,7 +40,20 @@ nonuniformTransformCyclicFvPatchField template -nonuniformTransformCyclicFvPatchField:: +Foam::nonuniformTransformCyclicFvPatchField:: +nonuniformTransformCyclicFvPatchField +( + const fvPatch& p, + const DimensionedField& iF, + const dictionary& dict +) +: + cyclicFvPatchField(p, iF, dict) +{} + + +template +Foam::nonuniformTransformCyclicFvPatchField:: nonuniformTransformCyclicFvPatchField ( const nonuniformTransformCyclicFvPatchField& ptf, @@ -59,20 +67,7 @@ nonuniformTransformCyclicFvPatchField template -nonuniformTransformCyclicFvPatchField:: -nonuniformTransformCyclicFvPatchField -( - const fvPatch& p, - const DimensionedField& iF, - const dictionary& dict -) -: - cyclicFvPatchField(p, iF, dict) -{} - - -template -nonuniformTransformCyclicFvPatchField:: +Foam::nonuniformTransformCyclicFvPatchField:: nonuniformTransformCyclicFvPatchField ( const nonuniformTransformCyclicFvPatchField& ptf @@ -83,7 +78,7 @@ nonuniformTransformCyclicFvPatchField template -nonuniformTransformCyclicFvPatchField:: +Foam::nonuniformTransformCyclicFvPatchField:: nonuniformTransformCyclicFvPatchField ( const nonuniformTransformCyclicFvPatchField& ptf, @@ -94,8 +89,4 @@ nonuniformTransformCyclicFvPatchField {} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvPatchFields/constraint/symmetry/symmetryFvPatchField.C b/src/finiteVolume/fields/fvPatchFields/constraint/symmetry/symmetryFvPatchField.C index c6a2dc126a..4f27422ccd 100644 --- a/src/finiteVolume/fields/fvPatchFields/constraint/symmetry/symmetryFvPatchField.C +++ b/src/finiteVolume/fields/fvPatchFields/constraint/symmetry/symmetryFvPatchField.C @@ -25,15 +25,10 @@ License #include "symmetryFvPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -symmetryFvPatchField::symmetryFvPatchField +Foam::symmetryFvPatchField::symmetryFvPatchField ( const fvPatch& p, const DimensionedField& iF @@ -44,30 +39,7 @@ symmetryFvPatchField::symmetryFvPatchField template -symmetryFvPatchField::symmetryFvPatchField -( - const symmetryFvPatchField& ptf, - const fvPatch& p, - const DimensionedField& iF, - const fvPatchFieldMapper& mapper -) -: - basicSymmetryFvPatchField(ptf, p, iF, mapper) -{ - if (!isType(this->patch())) - { - FatalErrorInFunction - << "' not constraint type '" << typeName << "'" - << "\n for patch " << p.name() - << " of field " << this->dimensionedInternalField().name() - << " in file " << this->dimensionedInternalField().objectPath() - << exit(FatalIOError); - } -} - - -template -symmetryFvPatchField::symmetryFvPatchField +Foam::symmetryFvPatchField::symmetryFvPatchField ( const fvPatch& p, const DimensionedField& iF, @@ -92,7 +64,30 @@ symmetryFvPatchField::symmetryFvPatchField template -symmetryFvPatchField::symmetryFvPatchField +Foam::symmetryFvPatchField::symmetryFvPatchField +( + const symmetryFvPatchField& ptf, + const fvPatch& p, + const DimensionedField& iF, + const fvPatchFieldMapper& mapper +) +: + basicSymmetryFvPatchField(ptf, p, iF, mapper) +{ + if (!isType(this->patch())) + { + FatalErrorInFunction + << "' not constraint type '" << typeName << "'" + << "\n for patch " << p.name() + << " of field " << this->dimensionedInternalField().name() + << " in file " << this->dimensionedInternalField().objectPath() + << exit(FatalIOError); + } +} + + +template +Foam::symmetryFvPatchField::symmetryFvPatchField ( const symmetryFvPatchField& ptf ) @@ -102,7 +97,7 @@ symmetryFvPatchField::symmetryFvPatchField template -symmetryFvPatchField::symmetryFvPatchField +Foam::symmetryFvPatchField::symmetryFvPatchField ( const symmetryFvPatchField& ptf, const DimensionedField& iF @@ -112,8 +107,4 @@ symmetryFvPatchField::symmetryFvPatchField {} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvPatchFields/derived/freestream/freestreamFvPatchField.C b/src/finiteVolume/fields/fvPatchFields/derived/freestream/freestreamFvPatchField.C index 00396a7090..99dad9c4d9 100644 --- a/src/finiteVolume/fields/fvPatchFields/derived/freestream/freestreamFvPatchField.C +++ b/src/finiteVolume/fields/fvPatchFields/derived/freestream/freestreamFvPatchField.C @@ -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 @@ -25,15 +25,10 @@ License #include "freestreamFvPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -freestreamFvPatchField::freestreamFvPatchField +Foam::freestreamFvPatchField::freestreamFvPatchField ( const fvPatch& p, const DimensionedField& iF @@ -44,20 +39,7 @@ freestreamFvPatchField::freestreamFvPatchField template -freestreamFvPatchField::freestreamFvPatchField -( - const freestreamFvPatchField& ptf, - const fvPatch& p, - const DimensionedField& iF, - const fvPatchFieldMapper& mapper -) -: - inletOutletFvPatchField(ptf, p, iF, mapper) -{} - - -template -freestreamFvPatchField::freestreamFvPatchField +Foam::freestreamFvPatchField::freestreamFvPatchField ( const fvPatch& p, const DimensionedField& iF, @@ -85,7 +67,20 @@ freestreamFvPatchField::freestreamFvPatchField template -freestreamFvPatchField::freestreamFvPatchField +Foam::freestreamFvPatchField::freestreamFvPatchField +( + const freestreamFvPatchField& ptf, + const fvPatch& p, + const DimensionedField& iF, + const fvPatchFieldMapper& mapper +) +: + inletOutletFvPatchField(ptf, p, iF, mapper) +{} + + +template +Foam::freestreamFvPatchField::freestreamFvPatchField ( const freestreamFvPatchField& ptf ) @@ -95,7 +90,7 @@ freestreamFvPatchField::freestreamFvPatchField template -freestreamFvPatchField::freestreamFvPatchField +Foam::freestreamFvPatchField::freestreamFvPatchField ( const freestreamFvPatchField& ptf, const DimensionedField& iF @@ -108,7 +103,7 @@ freestreamFvPatchField::freestreamFvPatchField // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -void freestreamFvPatchField::write(Ostream& os) const +void Foam::freestreamFvPatchField::write(Ostream& os) const { fvPatchField::write(os); if (this->phiName_ != "phi") @@ -121,8 +116,4 @@ void freestreamFvPatchField::write(Ostream& os) const } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvPatchFields/derived/mappedField/mappedFieldFvPatchField.C b/src/finiteVolume/fields/fvPatchFields/derived/mappedField/mappedFieldFvPatchField.C index 5d359bc691..06047dcebd 100644 --- a/src/finiteVolume/fields/fvPatchFields/derived/mappedField/mappedFieldFvPatchField.C +++ b/src/finiteVolume/fields/fvPatchFields/derived/mappedField/mappedFieldFvPatchField.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 @@ -24,19 +24,13 @@ License \*---------------------------------------------------------------------------*/ #include "mappedFieldFvPatchField.H" - #include "volFields.H" #include "interpolationCell.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -mappedFieldFvPatchField::mappedFieldFvPatchField +Foam::mappedFieldFvPatchField::mappedFieldFvPatchField ( const fvPatch& p, const DimensionedField& iF @@ -49,7 +43,21 @@ mappedFieldFvPatchField::mappedFieldFvPatchField template -mappedFieldFvPatchField::mappedFieldFvPatchField +Foam::mappedFieldFvPatchField::mappedFieldFvPatchField +( + const fvPatch& p, + const DimensionedField& iF, + const dictionary& dict +) +: + fixedValueFvPatchField(p, iF, dict), + mappedPatchBase(p.patch(), dict), + mappedPatchFieldBase(*this, *this, dict) +{} + + +template +Foam::mappedFieldFvPatchField::mappedFieldFvPatchField ( const mappedFieldFvPatchField& ptf, const fvPatch& p, @@ -64,21 +72,7 @@ mappedFieldFvPatchField::mappedFieldFvPatchField template -mappedFieldFvPatchField::mappedFieldFvPatchField -( - const fvPatch& p, - const DimensionedField& iF, - const dictionary& dict -) -: - fixedValueFvPatchField(p, iF, dict), - mappedPatchBase(p.patch(), dict), - mappedPatchFieldBase(*this, *this, dict) -{} - - -template -mappedFieldFvPatchField::mappedFieldFvPatchField +Foam::mappedFieldFvPatchField::mappedFieldFvPatchField ( const fvPatch& p, const DimensionedField& iF, @@ -118,7 +112,7 @@ mappedFieldFvPatchField::mappedFieldFvPatchField template -mappedFieldFvPatchField::mappedFieldFvPatchField +Foam::mappedFieldFvPatchField::mappedFieldFvPatchField ( const mappedFieldFvPatchField& ptf ) @@ -130,7 +124,7 @@ mappedFieldFvPatchField::mappedFieldFvPatchField template -mappedFieldFvPatchField::mappedFieldFvPatchField +Foam::mappedFieldFvPatchField::mappedFieldFvPatchField ( const mappedFieldFvPatchField& ptf, const DimensionedField& iF @@ -145,7 +139,7 @@ mappedFieldFvPatchField::mappedFieldFvPatchField // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -void mappedFieldFvPatchField::updateCoeffs() +void Foam::mappedFieldFvPatchField::updateCoeffs() { if (this->updated()) { @@ -169,7 +163,7 @@ void mappedFieldFvPatchField::updateCoeffs() template -void mappedFieldFvPatchField::write(Ostream& os) const +void Foam::mappedFieldFvPatchField::write(Ostream& os) const { fvPatchField::write(os); mappedPatchBase::write(os); @@ -178,8 +172,4 @@ void mappedFieldFvPatchField::write(Ostream& os) const } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvPatchFields/derived/mappedFixedValue/mappedFixedValueFvPatchField.C b/src/finiteVolume/fields/fvPatchFields/derived/mappedFixedValue/mappedFixedValueFvPatchField.C index 0100f09730..a1a80c7342 100644 --- a/src/finiteVolume/fields/fvPatchFields/derived/mappedFixedValue/mappedFixedValueFvPatchField.C +++ b/src/finiteVolume/fields/fvPatchFields/derived/mappedFixedValue/mappedFixedValueFvPatchField.C @@ -27,15 +27,10 @@ License #include "mappedPatchBase.H" #include "volFields.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -mappedFixedValueFvPatchField::mappedFixedValueFvPatchField +Foam::mappedFixedValueFvPatchField::mappedFixedValueFvPatchField ( const fvPatch& p, const DimensionedField& iF @@ -47,7 +42,20 @@ mappedFixedValueFvPatchField::mappedFixedValueFvPatchField template -mappedFixedValueFvPatchField::mappedFixedValueFvPatchField +Foam::mappedFixedValueFvPatchField::mappedFixedValueFvPatchField +( + const fvPatch& p, + const DimensionedField& iF, + const dictionary& dict +) +: + fixedValueFvPatchField(p, iF, dict), + mappedPatchFieldBase(this->mapper(p, iF), *this, dict) +{} + + +template +Foam::mappedFixedValueFvPatchField::mappedFixedValueFvPatchField ( const mappedFixedValueFvPatchField& ptf, const fvPatch& p, @@ -61,20 +69,7 @@ mappedFixedValueFvPatchField::mappedFixedValueFvPatchField template -mappedFixedValueFvPatchField::mappedFixedValueFvPatchField -( - const fvPatch& p, - const DimensionedField& iF, - const dictionary& dict -) -: - fixedValueFvPatchField(p, iF, dict), - mappedPatchFieldBase(this->mapper(p, iF), *this, dict) -{} - - -template -mappedFixedValueFvPatchField::mappedFixedValueFvPatchField +Foam::mappedFixedValueFvPatchField::mappedFixedValueFvPatchField ( const mappedFixedValueFvPatchField& ptf ) @@ -85,7 +80,7 @@ mappedFixedValueFvPatchField::mappedFixedValueFvPatchField template -mappedFixedValueFvPatchField::mappedFixedValueFvPatchField +Foam::mappedFixedValueFvPatchField::mappedFixedValueFvPatchField ( const mappedFixedValueFvPatchField& ptf, const DimensionedField& iF @@ -99,7 +94,7 @@ mappedFixedValueFvPatchField::mappedFixedValueFvPatchField // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -const mappedPatchBase& mappedFixedValueFvPatchField::mapper +const Foam::mappedPatchBase& Foam::mappedFixedValueFvPatchField::mapper ( const fvPatch& p, const DimensionedField& iF @@ -119,7 +114,7 @@ const mappedPatchBase& mappedFixedValueFvPatchField::mapper template -void mappedFixedValueFvPatchField::updateCoeffs() +void Foam::mappedFixedValueFvPatchField::updateCoeffs() { if (this->updated()) { @@ -144,7 +139,7 @@ void mappedFixedValueFvPatchField::updateCoeffs() template -void mappedFixedValueFvPatchField::write(Ostream& os) const +void Foam::mappedFixedValueFvPatchField::write(Ostream& os) const { fvPatchField::write(os); mappedPatchFieldBase::write(os); @@ -152,8 +147,4 @@ void mappedFixedValueFvPatchField::write(Ostream& os) const } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvPatchFields/derived/oscillatingFixedValue/oscillatingFixedValueFvPatchField.C b/src/finiteVolume/fields/fvPatchFields/derived/oscillatingFixedValue/oscillatingFixedValueFvPatchField.C index 715586a369..141c69522e 100644 --- a/src/finiteVolume/fields/fvPatchFields/derived/oscillatingFixedValue/oscillatingFixedValueFvPatchField.C +++ b/src/finiteVolume/fields/fvPatchFields/derived/oscillatingFixedValue/oscillatingFixedValueFvPatchField.C @@ -26,15 +26,10 @@ License #include "oscillatingFixedValueFvPatchField.H" #include "mathematicalConstants.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * // template -scalar oscillatingFixedValueFvPatchField::currentScale() const +Foam::scalar Foam::oscillatingFixedValueFvPatchField::currentScale() const { const scalar t = this->db().time().timeOutputValue(); const scalar a = amplitude_->value(t); @@ -47,7 +42,7 @@ scalar oscillatingFixedValueFvPatchField::currentScale() const // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -oscillatingFixedValueFvPatchField::oscillatingFixedValueFvPatchField +Foam::oscillatingFixedValueFvPatchField::oscillatingFixedValueFvPatchField ( const fvPatch& p, const DimensionedField& iF @@ -63,25 +58,7 @@ oscillatingFixedValueFvPatchField::oscillatingFixedValueFvPatchField template -oscillatingFixedValueFvPatchField::oscillatingFixedValueFvPatchField -( - const oscillatingFixedValueFvPatchField& ptf, - const fvPatch& p, - const DimensionedField& iF, - const fvPatchFieldMapper& mapper -) -: - fixedValueFvPatchField(ptf, p, iF, mapper), - refValue_(ptf.refValue_, mapper), - offset_(ptf.offset_), - amplitude_(ptf.amplitude_, false), - frequency_(ptf.frequency_, false), - curTimeIndex_(-1) -{} - - -template -oscillatingFixedValueFvPatchField::oscillatingFixedValueFvPatchField +Foam::oscillatingFixedValueFvPatchField::oscillatingFixedValueFvPatchField ( const fvPatch& p, const DimensionedField& iF, @@ -114,7 +91,25 @@ oscillatingFixedValueFvPatchField::oscillatingFixedValueFvPatchField template -oscillatingFixedValueFvPatchField::oscillatingFixedValueFvPatchField +Foam::oscillatingFixedValueFvPatchField::oscillatingFixedValueFvPatchField +( + const oscillatingFixedValueFvPatchField& ptf, + const fvPatch& p, + const DimensionedField& iF, + const fvPatchFieldMapper& mapper +) +: + fixedValueFvPatchField(ptf, p, iF, mapper), + refValue_(ptf.refValue_, mapper), + offset_(ptf.offset_), + amplitude_(ptf.amplitude_, false), + frequency_(ptf.frequency_, false), + curTimeIndex_(-1) +{} + + +template +Foam::oscillatingFixedValueFvPatchField::oscillatingFixedValueFvPatchField ( const oscillatingFixedValueFvPatchField& ptf ) @@ -129,7 +124,7 @@ oscillatingFixedValueFvPatchField::oscillatingFixedValueFvPatchField template -oscillatingFixedValueFvPatchField::oscillatingFixedValueFvPatchField +Foam::oscillatingFixedValueFvPatchField::oscillatingFixedValueFvPatchField ( const oscillatingFixedValueFvPatchField& ptf, const DimensionedField& iF @@ -147,7 +142,7 @@ oscillatingFixedValueFvPatchField::oscillatingFixedValueFvPatchField // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -void oscillatingFixedValueFvPatchField::autoMap +void Foam::oscillatingFixedValueFvPatchField::autoMap ( const fvPatchFieldMapper& m ) @@ -158,7 +153,7 @@ void oscillatingFixedValueFvPatchField::autoMap template -void oscillatingFixedValueFvPatchField::rmap +void Foam::oscillatingFixedValueFvPatchField::rmap ( const fvPatchField& ptf, const labelList& addr @@ -174,7 +169,7 @@ void oscillatingFixedValueFvPatchField::rmap template -void oscillatingFixedValueFvPatchField::updateCoeffs() +void Foam::oscillatingFixedValueFvPatchField::updateCoeffs() { if (this->updated()) { @@ -197,7 +192,7 @@ void oscillatingFixedValueFvPatchField::updateCoeffs() template -void oscillatingFixedValueFvPatchField::write(Ostream& os) const +void Foam::oscillatingFixedValueFvPatchField::write(Ostream& os) const { fixedValueFvPatchField::write(os); refValue_.writeEntry("refValue", os); @@ -207,8 +202,4 @@ void oscillatingFixedValueFvPatchField::write(Ostream& os) const } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvPatchFields/derived/slip/slipFvPatchField.C b/src/finiteVolume/fields/fvPatchFields/derived/slip/slipFvPatchField.C index c7f30b6e10..83340f3fe5 100644 --- a/src/finiteVolume/fields/fvPatchFields/derived/slip/slipFvPatchField.C +++ b/src/finiteVolume/fields/fvPatchFields/derived/slip/slipFvPatchField.C @@ -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 @@ -25,15 +25,10 @@ License #include "slipFvPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -slipFvPatchField::slipFvPatchField +Foam::slipFvPatchField::slipFvPatchField ( const fvPatch& p, const DimensionedField& iF @@ -44,7 +39,19 @@ slipFvPatchField::slipFvPatchField template -slipFvPatchField::slipFvPatchField +Foam::slipFvPatchField::slipFvPatchField +( + const fvPatch& p, + const DimensionedField& iF, + const dictionary& dict +) +: + basicSymmetryFvPatchField(p, iF, dict) +{} + + +template +Foam::slipFvPatchField::slipFvPatchField ( const slipFvPatchField& ptf, const fvPatch& p, @@ -57,19 +64,7 @@ slipFvPatchField::slipFvPatchField template -slipFvPatchField::slipFvPatchField -( - const fvPatch& p, - const DimensionedField& iF, - const dictionary& dict -) -: - basicSymmetryFvPatchField(p, iF, dict) -{} - - -template -slipFvPatchField::slipFvPatchField +Foam::slipFvPatchField::slipFvPatchField ( const slipFvPatchField& ptf, const DimensionedField& iF @@ -80,7 +75,7 @@ slipFvPatchField::slipFvPatchField template -slipFvPatchField::slipFvPatchField +Foam::slipFvPatchField::slipFvPatchField ( const slipFvPatchField& ptf ) @@ -89,8 +84,4 @@ slipFvPatchField::slipFvPatchField {} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvPatchFields/derived/timeVaryingMappedFixedValue/timeVaryingMappedFixedValueFvPatchField.C b/src/finiteVolume/fields/fvPatchFields/derived/timeVaryingMappedFixedValue/timeVaryingMappedFixedValueFvPatchField.C index 3e2f43965b..1ef4675d4e 100644 --- a/src/finiteVolume/fields/fvPatchFields/derived/timeVaryingMappedFixedValue/timeVaryingMappedFixedValueFvPatchField.C +++ b/src/finiteVolume/fields/fvPatchFields/derived/timeVaryingMappedFixedValue/timeVaryingMappedFixedValueFvPatchField.C @@ -27,15 +27,10 @@ License #include "Time.H" #include "AverageIOField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -timeVaryingMappedFixedValueFvPatchField:: +Foam::timeVaryingMappedFixedValueFvPatchField:: timeVaryingMappedFixedValueFvPatchField ( const fvPatch& p, @@ -59,7 +54,7 @@ timeVaryingMappedFixedValueFvPatchField template -timeVaryingMappedFixedValueFvPatchField:: +Foam::timeVaryingMappedFixedValueFvPatchField:: timeVaryingMappedFixedValueFvPatchField ( const fvPatch& p, @@ -121,7 +116,7 @@ timeVaryingMappedFixedValueFvPatchField template -timeVaryingMappedFixedValueFvPatchField:: +Foam::timeVaryingMappedFixedValueFvPatchField:: timeVaryingMappedFixedValueFvPatchField ( const timeVaryingMappedFixedValueFvPatchField& ptf, @@ -148,7 +143,7 @@ timeVaryingMappedFixedValueFvPatchField template -timeVaryingMappedFixedValueFvPatchField:: +Foam::timeVaryingMappedFixedValueFvPatchField:: timeVaryingMappedFixedValueFvPatchField ( const timeVaryingMappedFixedValueFvPatchField& ptf @@ -172,7 +167,7 @@ timeVaryingMappedFixedValueFvPatchField template -timeVaryingMappedFixedValueFvPatchField:: +Foam::timeVaryingMappedFixedValueFvPatchField:: timeVaryingMappedFixedValueFvPatchField ( const timeVaryingMappedFixedValueFvPatchField& ptf, @@ -199,7 +194,7 @@ timeVaryingMappedFixedValueFvPatchField // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -void timeVaryingMappedFixedValueFvPatchField::autoMap +void Foam::timeVaryingMappedFixedValueFvPatchField::autoMap ( const fvPatchFieldMapper& m ) @@ -218,7 +213,7 @@ void timeVaryingMappedFixedValueFvPatchField::autoMap template -void timeVaryingMappedFixedValueFvPatchField::rmap +void Foam::timeVaryingMappedFixedValueFvPatchField::rmap ( const fvPatchField& ptf, const labelList& addr @@ -240,7 +235,7 @@ void timeVaryingMappedFixedValueFvPatchField::rmap template -void timeVaryingMappedFixedValueFvPatchField::checkTable() +void Foam::timeVaryingMappedFixedValueFvPatchField::checkTable() { // Initialise if (mapperPtr_.empty()) @@ -451,7 +446,7 @@ void timeVaryingMappedFixedValueFvPatchField::checkTable() template -void timeVaryingMappedFixedValueFvPatchField::updateCoeffs() +void Foam::timeVaryingMappedFixedValueFvPatchField::updateCoeffs() { if (this->updated()) { @@ -556,7 +551,10 @@ void timeVaryingMappedFixedValueFvPatchField::updateCoeffs() template -void timeVaryingMappedFixedValueFvPatchField::write(Ostream& os) const +void Foam::timeVaryingMappedFixedValueFvPatchField::write +( + Ostream& os +) const { fvPatchField::write(os); os.writeKeyword("setAverage") << setAverage_ << token::END_STATEMENT << nl; @@ -589,8 +587,4 @@ void timeVaryingMappedFixedValueFvPatchField::write(Ostream& os) const } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvPatchFields/derived/turbulentInlet/turbulentInletFvPatchField.C b/src/finiteVolume/fields/fvPatchFields/derived/turbulentInlet/turbulentInletFvPatchField.C index 4ad86d3c3f..55a3cda1db 100644 --- a/src/finiteVolume/fields/fvPatchFields/derived/turbulentInlet/turbulentInletFvPatchField.C +++ b/src/finiteVolume/fields/fvPatchFields/derived/turbulentInlet/turbulentInletFvPatchField.C @@ -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 @@ -25,15 +25,10 @@ License #include "turbulentInletFvPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -turbulentInletFvPatchField::turbulentInletFvPatchField +Foam::turbulentInletFvPatchField::turbulentInletFvPatchField ( const fvPatch& p, const DimensionedField& iF @@ -49,25 +44,7 @@ turbulentInletFvPatchField::turbulentInletFvPatchField template -turbulentInletFvPatchField::turbulentInletFvPatchField -( - const turbulentInletFvPatchField& ptf, - const fvPatch& p, - const DimensionedField& iF, - const fvPatchFieldMapper& mapper -) -: - fixedValueFvPatchField(ptf, p, iF, mapper), - ranGen_(label(0)), - fluctuationScale_(ptf.fluctuationScale_), - referenceField_(ptf.referenceField_, mapper), - alpha_(ptf.alpha_), - curTimeIndex_(-1) -{} - - -template -turbulentInletFvPatchField::turbulentInletFvPatchField +Foam::turbulentInletFvPatchField::turbulentInletFvPatchField ( const fvPatch& p, const DimensionedField& iF, @@ -96,7 +73,25 @@ turbulentInletFvPatchField::turbulentInletFvPatchField template -turbulentInletFvPatchField::turbulentInletFvPatchField +Foam::turbulentInletFvPatchField::turbulentInletFvPatchField +( + const turbulentInletFvPatchField& ptf, + const fvPatch& p, + const DimensionedField& iF, + const fvPatchFieldMapper& mapper +) +: + fixedValueFvPatchField(ptf, p, iF, mapper), + ranGen_(label(0)), + fluctuationScale_(ptf.fluctuationScale_), + referenceField_(ptf.referenceField_, mapper), + alpha_(ptf.alpha_), + curTimeIndex_(-1) +{} + + +template +Foam::turbulentInletFvPatchField::turbulentInletFvPatchField ( const turbulentInletFvPatchField& ptf ) @@ -111,7 +106,7 @@ turbulentInletFvPatchField::turbulentInletFvPatchField template -turbulentInletFvPatchField::turbulentInletFvPatchField +Foam::turbulentInletFvPatchField::turbulentInletFvPatchField ( const turbulentInletFvPatchField& ptf, const DimensionedField& iF @@ -129,7 +124,7 @@ turbulentInletFvPatchField::turbulentInletFvPatchField // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -void turbulentInletFvPatchField::autoMap +void Foam::turbulentInletFvPatchField::autoMap ( const fvPatchFieldMapper& m ) @@ -140,7 +135,7 @@ void turbulentInletFvPatchField::autoMap template -void turbulentInletFvPatchField::rmap +void Foam::turbulentInletFvPatchField::rmap ( const fvPatchField& ptf, const labelList& addr @@ -156,7 +151,7 @@ void turbulentInletFvPatchField::rmap template -void turbulentInletFvPatchField::updateCoeffs() +void Foam::turbulentInletFvPatchField::updateCoeffs() { if (this->updated()) { @@ -198,7 +193,7 @@ void turbulentInletFvPatchField::updateCoeffs() template -void turbulentInletFvPatchField::write(Ostream& os) const +void Foam::turbulentInletFvPatchField::write(Ostream& os) const { fvPatchField::write(os); os.writeKeyword("fluctuationScale") @@ -209,8 +204,4 @@ void turbulentInletFvPatchField::write(Ostream& os) const } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvsPatchFields/basic/calculated/calculatedFvsPatchField.C b/src/finiteVolume/fields/fvsPatchFields/basic/calculated/calculatedFvsPatchField.C index efe80d2f73..e6e1735fa1 100644 --- a/src/finiteVolume/fields/fvsPatchFields/basic/calculated/calculatedFvsPatchField.C +++ b/src/finiteVolume/fields/fvsPatchFields/basic/calculated/calculatedFvsPatchField.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -28,11 +28,8 @@ License // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -namespace Foam -{ - template -const word& fvsPatchField::calculatedType() +const Foam::word& Foam::fvsPatchField::calculatedType() { return calculatedFvsPatchField::typeName; } @@ -40,7 +37,7 @@ const word& fvsPatchField::calculatedType() // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -calculatedFvsPatchField::calculatedFvsPatchField +Foam::calculatedFvsPatchField::calculatedFvsPatchField ( const fvPatch& p, const DimensionedField& iF @@ -51,7 +48,19 @@ calculatedFvsPatchField::calculatedFvsPatchField template -calculatedFvsPatchField::calculatedFvsPatchField +Foam::calculatedFvsPatchField::calculatedFvsPatchField +( + const fvPatch& p, + const DimensionedField& iF, + const dictionary& dict +) +: + fvsPatchField(p, iF, Field("value", dict, p.size())) +{} + + +template +Foam::calculatedFvsPatchField::calculatedFvsPatchField ( const calculatedFvsPatchField& ptf, const fvPatch& p, @@ -64,19 +73,7 @@ calculatedFvsPatchField::calculatedFvsPatchField template -calculatedFvsPatchField::calculatedFvsPatchField -( - const fvPatch& p, - const DimensionedField& iF, - const dictionary& dict -) -: - fvsPatchField(p, iF, Field("value", dict, p.size())) -{} - - -template -calculatedFvsPatchField::calculatedFvsPatchField +Foam::calculatedFvsPatchField::calculatedFvsPatchField ( const calculatedFvsPatchField& ptf ) @@ -86,7 +83,7 @@ calculatedFvsPatchField::calculatedFvsPatchField template -calculatedFvsPatchField::calculatedFvsPatchField +Foam::calculatedFvsPatchField::calculatedFvsPatchField ( const calculatedFvsPatchField& ptf, const DimensionedField& iF @@ -97,7 +94,8 @@ calculatedFvsPatchField::calculatedFvsPatchField template -tmp > fvsPatchField::NewCalculatedType +Foam::tmp > +Foam::fvsPatchField::NewCalculatedType ( const fvPatch& p ) @@ -129,7 +127,8 @@ tmp > fvsPatchField::NewCalculatedType template template -tmp > fvsPatchField::NewCalculatedType +Foam::tmp > +Foam::fvsPatchField::NewCalculatedType ( const fvsPatchField& pf ) @@ -138,8 +137,4 @@ tmp > fvsPatchField::NewCalculatedType } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvsPatchFields/basic/coupled/coupledFvsPatchField.C b/src/finiteVolume/fields/fvsPatchFields/basic/coupled/coupledFvsPatchField.C index 0a619f50a4..13cc738613 100644 --- a/src/finiteVolume/fields/fvsPatchFields/basic/coupled/coupledFvsPatchField.C +++ b/src/finiteVolume/fields/fvsPatchFields/basic/coupled/coupledFvsPatchField.C @@ -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 @@ -25,15 +25,10 @@ License #include "coupledFvsPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -coupledFvsPatchField::coupledFvsPatchField +Foam::coupledFvsPatchField::coupledFvsPatchField ( const fvPatch& p, const DimensionedField& iF @@ -44,7 +39,7 @@ coupledFvsPatchField::coupledFvsPatchField template -coupledFvsPatchField::coupledFvsPatchField +Foam::coupledFvsPatchField::coupledFvsPatchField ( const fvPatch& p, const DimensionedField& iF, @@ -56,7 +51,19 @@ coupledFvsPatchField::coupledFvsPatchField template -coupledFvsPatchField::coupledFvsPatchField +Foam::coupledFvsPatchField::coupledFvsPatchField +( + const fvPatch& p, + const DimensionedField& iF, + const dictionary& dict +) +: + fvsPatchField(p, iF, dict) +{} + + +template +Foam::coupledFvsPatchField::coupledFvsPatchField ( const coupledFvsPatchField& ptf, const fvPatch& p, @@ -69,19 +76,7 @@ coupledFvsPatchField::coupledFvsPatchField template -coupledFvsPatchField::coupledFvsPatchField -( - const fvPatch& p, - const DimensionedField& iF, - const dictionary& dict -) -: - fvsPatchField(p, iF, dict) -{} - - -template -coupledFvsPatchField::coupledFvsPatchField +Foam::coupledFvsPatchField::coupledFvsPatchField ( const coupledFvsPatchField& ptf ) @@ -91,7 +86,7 @@ coupledFvsPatchField::coupledFvsPatchField template -coupledFvsPatchField::coupledFvsPatchField +Foam::coupledFvsPatchField::coupledFvsPatchField ( const coupledFvsPatchField& ptf, const DimensionedField& iF @@ -101,8 +96,4 @@ coupledFvsPatchField::coupledFvsPatchField {} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvsPatchFields/basic/fixedValue/fixedValueFvsPatchField.C b/src/finiteVolume/fields/fvsPatchFields/basic/fixedValue/fixedValueFvsPatchField.C index b791dca272..cf8f46bfa3 100644 --- a/src/finiteVolume/fields/fvsPatchFields/basic/fixedValue/fixedValueFvsPatchField.C +++ b/src/finiteVolume/fields/fvsPatchFields/basic/fixedValue/fixedValueFvsPatchField.C @@ -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 @@ -25,15 +25,10 @@ License #include "fixedValueFvsPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -fixedValueFvsPatchField::fixedValueFvsPatchField +Foam::fixedValueFvsPatchField::fixedValueFvsPatchField ( const fvPatch& p, const DimensionedField& iF @@ -44,7 +39,19 @@ fixedValueFvsPatchField::fixedValueFvsPatchField template -fixedValueFvsPatchField::fixedValueFvsPatchField +Foam::fixedValueFvsPatchField::fixedValueFvsPatchField +( + const fvPatch& p, + const DimensionedField& iF, + const dictionary& dict +) +: + fvsPatchField(p, iF, Field("value", dict, p.size())) +{} + + +template +Foam::fixedValueFvsPatchField::fixedValueFvsPatchField ( const fixedValueFvsPatchField& ptf, const fvPatch& p, @@ -57,19 +64,7 @@ fixedValueFvsPatchField::fixedValueFvsPatchField template -fixedValueFvsPatchField::fixedValueFvsPatchField -( - const fvPatch& p, - const DimensionedField& iF, - const dictionary& dict -) -: - fvsPatchField(p, iF, Field("value", dict, p.size())) -{} - - -template -fixedValueFvsPatchField::fixedValueFvsPatchField +Foam::fixedValueFvsPatchField::fixedValueFvsPatchField ( const fixedValueFvsPatchField& ptf ) @@ -79,7 +74,7 @@ fixedValueFvsPatchField::fixedValueFvsPatchField template -fixedValueFvsPatchField::fixedValueFvsPatchField +Foam::fixedValueFvsPatchField::fixedValueFvsPatchField ( const fixedValueFvsPatchField& ptf, const DimensionedField& iF @@ -92,7 +87,8 @@ fixedValueFvsPatchField::fixedValueFvsPatchField // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -tmp > fixedValueFvsPatchField::valueInternalCoeffs +Foam::tmp > +Foam::fixedValueFvsPatchField::valueInternalCoeffs ( const tmp& ) const @@ -105,7 +101,8 @@ tmp > fixedValueFvsPatchField::valueInternalCoeffs template -tmp > fixedValueFvsPatchField::valueBoundaryCoeffs +Foam::tmp > +Foam::fixedValueFvsPatchField::valueBoundaryCoeffs ( const tmp& ) const @@ -115,21 +112,19 @@ tmp > fixedValueFvsPatchField::valueBoundaryCoeffs template -tmp > fixedValueFvsPatchField::gradientInternalCoeffs() const +Foam::tmp > +Foam::fixedValueFvsPatchField::gradientInternalCoeffs() const { return -pTraits::one*this->patch().deltaCoeffs(); } template -tmp > fixedValueFvsPatchField::gradientBoundaryCoeffs() const +Foam::tmp > +Foam::fixedValueFvsPatchField::gradientBoundaryCoeffs() const { return this->patch().deltaCoeffs()*(*this); } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvsPatchFields/basic/sliced/slicedFvsPatchField.C b/src/finiteVolume/fields/fvsPatchFields/basic/sliced/slicedFvsPatchField.C index acef68f928..84182ccdfc 100644 --- a/src/finiteVolume/fields/fvsPatchFields/basic/sliced/slicedFvsPatchField.C +++ b/src/finiteVolume/fields/fvsPatchFields/basic/sliced/slicedFvsPatchField.C @@ -25,15 +25,10 @@ License #include "slicedFvsPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -slicedFvsPatchField::slicedFvsPatchField +Foam::slicedFvsPatchField::slicedFvsPatchField ( const fvPatch& p, const DimensionedField& iF, @@ -48,7 +43,7 @@ slicedFvsPatchField::slicedFvsPatchField template -slicedFvsPatchField::slicedFvsPatchField +Foam::slicedFvsPatchField::slicedFvsPatchField ( const fvPatch& p, const DimensionedField& iF @@ -59,7 +54,21 @@ slicedFvsPatchField::slicedFvsPatchField template -slicedFvsPatchField::slicedFvsPatchField +Foam::slicedFvsPatchField::slicedFvsPatchField +( + const fvPatch& p, + const DimensionedField& iF, + const dictionary& dict +) +: + fvsPatchField(p, iF, Field("value", dict, p.size())) +{ + NotImplemented; +} + + +template +Foam::slicedFvsPatchField::slicedFvsPatchField ( const slicedFvsPatchField& ptf, const fvPatch& p, @@ -74,21 +83,7 @@ slicedFvsPatchField::slicedFvsPatchField template -slicedFvsPatchField::slicedFvsPatchField -( - const fvPatch& p, - const DimensionedField& iF, - const dictionary& dict -) -: - fvsPatchField(p, iF, Field("value", dict, p.size())) -{ - NotImplemented; -} - - -template -slicedFvsPatchField::slicedFvsPatchField +Foam::slicedFvsPatchField::slicedFvsPatchField ( const slicedFvsPatchField& ptf, const DimensionedField& iF @@ -100,8 +95,10 @@ slicedFvsPatchField::slicedFvsPatchField UList::operator=(ptf); } + template -tmp > slicedFvsPatchField::clone() const +Foam::tmp > +Foam::slicedFvsPatchField::clone() const { return tmp > ( @@ -111,7 +108,7 @@ tmp > slicedFvsPatchField::clone() const template -slicedFvsPatchField::slicedFvsPatchField +Foam::slicedFvsPatchField::slicedFvsPatchField ( const slicedFvsPatchField& ptf ) @@ -129,7 +126,8 @@ slicedFvsPatchField::slicedFvsPatchField template -tmp > slicedFvsPatchField::clone +Foam::tmp > +Foam::slicedFvsPatchField::clone ( const DimensionedField& iF ) const @@ -142,7 +140,7 @@ tmp > slicedFvsPatchField::clone template -slicedFvsPatchField::~slicedFvsPatchField() +Foam::slicedFvsPatchField::~slicedFvsPatchField() { // Set the fvsPatchField storage pointer to NULL before its destruction // to protect the field it a slice of. @@ -150,8 +148,4 @@ slicedFvsPatchField::~slicedFvsPatchField() } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvsPatchFields/constraint/cyclic/cyclicFvsPatchField.C b/src/finiteVolume/fields/fvsPatchFields/constraint/cyclic/cyclicFvsPatchField.C index 6134ed61fa..15fe2d9df7 100644 --- a/src/finiteVolume/fields/fvsPatchFields/constraint/cyclic/cyclicFvsPatchField.C +++ b/src/finiteVolume/fields/fvsPatchFields/constraint/cyclic/cyclicFvsPatchField.C @@ -25,15 +25,10 @@ License #include "cyclicFvsPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -cyclicFvsPatchField::cyclicFvsPatchField +Foam::cyclicFvsPatchField::cyclicFvsPatchField ( const fvPatch& p, const DimensionedField& iF @@ -45,7 +40,30 @@ cyclicFvsPatchField::cyclicFvsPatchField template -cyclicFvsPatchField::cyclicFvsPatchField +Foam::cyclicFvsPatchField::cyclicFvsPatchField +( + const fvPatch& p, + const DimensionedField& iF, + const dictionary& dict +) +: + coupledFvsPatchField(p, iF, dict), + cyclicPatch_(refCast(p)) +{ + if (!isA(p)) + { + FatalIOErrorInFunction + ( + dict + ) << "patch " << this->patch().index() << " not cyclic type. " + << "Patch type = " << p.type() + << exit(FatalIOError); + } +} + + +template +Foam::cyclicFvsPatchField::cyclicFvsPatchField ( const cyclicFvsPatchField& ptf, const fvPatch& p, @@ -69,30 +87,7 @@ cyclicFvsPatchField::cyclicFvsPatchField template -cyclicFvsPatchField::cyclicFvsPatchField -( - const fvPatch& p, - const DimensionedField& iF, - const dictionary& dict -) -: - coupledFvsPatchField(p, iF, dict), - cyclicPatch_(refCast(p)) -{ - if (!isA(p)) - { - FatalIOErrorInFunction - ( - dict - ) << "patch " << this->patch().index() << " not cyclic type. " - << "Patch type = " << p.type() - << exit(FatalIOError); - } -} - - -template -cyclicFvsPatchField::cyclicFvsPatchField +Foam::cyclicFvsPatchField::cyclicFvsPatchField ( const cyclicFvsPatchField& ptf ) @@ -103,7 +98,7 @@ cyclicFvsPatchField::cyclicFvsPatchField template -cyclicFvsPatchField::cyclicFvsPatchField +Foam::cyclicFvsPatchField::cyclicFvsPatchField ( const cyclicFvsPatchField& ptf, const DimensionedField& iF @@ -114,8 +109,4 @@ cyclicFvsPatchField::cyclicFvsPatchField {} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvsPatchFields/constraint/cyclicSlip/cyclicSlipFvsPatchField.C b/src/finiteVolume/fields/fvsPatchFields/constraint/cyclicSlip/cyclicSlipFvsPatchField.C index 1e2425befb..8caad80e69 100644 --- a/src/finiteVolume/fields/fvsPatchFields/constraint/cyclicSlip/cyclicSlipFvsPatchField.C +++ b/src/finiteVolume/fields/fvsPatchFields/constraint/cyclicSlip/cyclicSlipFvsPatchField.C @@ -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 @@ -25,15 +25,10 @@ License #include "cyclicSlipFvsPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -cyclicSlipFvsPatchField::cyclicSlipFvsPatchField +Foam::cyclicSlipFvsPatchField::cyclicSlipFvsPatchField ( const fvPatch& p, const DimensionedField& iF @@ -44,7 +39,19 @@ cyclicSlipFvsPatchField::cyclicSlipFvsPatchField template -cyclicSlipFvsPatchField::cyclicSlipFvsPatchField +Foam::cyclicSlipFvsPatchField::cyclicSlipFvsPatchField +( + const fvPatch& p, + const DimensionedField& iF, + const dictionary& dict +) +: + cyclicFvsPatchField(p, iF, dict) +{} + + +template +Foam::cyclicSlipFvsPatchField::cyclicSlipFvsPatchField ( const cyclicSlipFvsPatchField& ptf, const fvPatch& p, @@ -57,19 +64,7 @@ cyclicSlipFvsPatchField::cyclicSlipFvsPatchField template -cyclicSlipFvsPatchField::cyclicSlipFvsPatchField -( - const fvPatch& p, - const DimensionedField& iF, - const dictionary& dict -) -: - cyclicFvsPatchField(p, iF, dict) -{} - - -template -cyclicSlipFvsPatchField::cyclicSlipFvsPatchField +Foam::cyclicSlipFvsPatchField::cyclicSlipFvsPatchField ( const cyclicSlipFvsPatchField& ptf ) @@ -79,7 +74,7 @@ cyclicSlipFvsPatchField::cyclicSlipFvsPatchField template -cyclicSlipFvsPatchField::cyclicSlipFvsPatchField +Foam::cyclicSlipFvsPatchField::cyclicSlipFvsPatchField ( const cyclicSlipFvsPatchField& ptf, const DimensionedField& iF @@ -89,8 +84,4 @@ cyclicSlipFvsPatchField::cyclicSlipFvsPatchField {} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvsPatchFields/constraint/empty/emptyFvsPatchField.C b/src/finiteVolume/fields/fvsPatchFields/constraint/empty/emptyFvsPatchField.C index 3af9ea3168..160d3e9365 100644 --- a/src/finiteVolume/fields/fvsPatchFields/constraint/empty/emptyFvsPatchField.C +++ b/src/finiteVolume/fields/fvsPatchFields/constraint/empty/emptyFvsPatchField.C @@ -27,15 +27,10 @@ License #include "fvPatchFieldMapper.H" #include "surfaceMesh.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -emptyFvsPatchField::emptyFvsPatchField +Foam::emptyFvsPatchField::emptyFvsPatchField ( const fvPatch& p, const DimensionedField& iF @@ -46,7 +41,29 @@ emptyFvsPatchField::emptyFvsPatchField template -emptyFvsPatchField::emptyFvsPatchField +Foam::emptyFvsPatchField::emptyFvsPatchField +( + const fvPatch& p, + const DimensionedField& iF, + const dictionary& dict +) +: + fvsPatchField(p, iF, Field(0)) +{ + if (!isType(p)) + { + FatalIOErrorInFunction + ( + dict + ) << "patch " << this->patch().index() << " not empty type. " + << "Patch type = " << p.type() + << exit(FatalIOError); + } +} + + +template +Foam::emptyFvsPatchField::emptyFvsPatchField ( const emptyFvsPatchField&, const fvPatch& p, @@ -69,29 +86,7 @@ emptyFvsPatchField::emptyFvsPatchField template -emptyFvsPatchField::emptyFvsPatchField -( - const fvPatch& p, - const DimensionedField& iF, - const dictionary& dict -) -: - fvsPatchField(p, iF, Field(0)) -{ - if (!isType(p)) - { - FatalIOErrorInFunction - ( - dict - ) << "patch " << this->patch().index() << " not empty type. " - << "Patch type = " << p.type() - << exit(FatalIOError); - } -} - - -template -emptyFvsPatchField::emptyFvsPatchField +Foam::emptyFvsPatchField::emptyFvsPatchField ( const emptyFvsPatchField& ptf ) @@ -106,7 +101,7 @@ emptyFvsPatchField::emptyFvsPatchField template -emptyFvsPatchField::emptyFvsPatchField +Foam::emptyFvsPatchField::emptyFvsPatchField ( const emptyFvsPatchField& ptf, const DimensionedField& iF @@ -116,8 +111,4 @@ emptyFvsPatchField::emptyFvsPatchField {} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvsPatchFields/constraint/nonuniformTransformCyclic/nonuniformTransformCyclicFvsPatchField.C b/src/finiteVolume/fields/fvsPatchFields/constraint/nonuniformTransformCyclic/nonuniformTransformCyclicFvsPatchField.C index 8540298cf0..ed83712884 100644 --- a/src/finiteVolume/fields/fvsPatchFields/constraint/nonuniformTransformCyclic/nonuniformTransformCyclicFvsPatchField.C +++ b/src/finiteVolume/fields/fvsPatchFields/constraint/nonuniformTransformCyclic/nonuniformTransformCyclicFvsPatchField.C @@ -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 @@ -25,15 +25,10 @@ License #include "nonuniformTransformCyclicFvsPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -nonuniformTransformCyclicFvsPatchField:: +Foam::nonuniformTransformCyclicFvsPatchField:: nonuniformTransformCyclicFvsPatchField ( const fvPatch& p, @@ -45,7 +40,20 @@ nonuniformTransformCyclicFvsPatchField template -nonuniformTransformCyclicFvsPatchField:: +Foam::nonuniformTransformCyclicFvsPatchField:: +nonuniformTransformCyclicFvsPatchField +( + const fvPatch& p, + const DimensionedField& iF, + const dictionary& dict +) +: + cyclicFvsPatchField(p, iF, dict) +{} + + +template +Foam::nonuniformTransformCyclicFvsPatchField:: nonuniformTransformCyclicFvsPatchField ( const nonuniformTransformCyclicFvsPatchField& ptf, @@ -59,20 +67,7 @@ nonuniformTransformCyclicFvsPatchField template -nonuniformTransformCyclicFvsPatchField:: -nonuniformTransformCyclicFvsPatchField -( - const fvPatch& p, - const DimensionedField& iF, - const dictionary& dict -) -: - cyclicFvsPatchField(p, iF, dict) -{} - - -template -nonuniformTransformCyclicFvsPatchField:: +Foam::nonuniformTransformCyclicFvsPatchField:: nonuniformTransformCyclicFvsPatchField ( const nonuniformTransformCyclicFvsPatchField& ptf @@ -83,7 +78,7 @@ nonuniformTransformCyclicFvsPatchField template -nonuniformTransformCyclicFvsPatchField:: +Foam::nonuniformTransformCyclicFvsPatchField:: nonuniformTransformCyclicFvsPatchField ( const nonuniformTransformCyclicFvsPatchField& ptf, @@ -94,8 +89,4 @@ nonuniformTransformCyclicFvsPatchField {} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvsPatchFields/constraint/processor/processorFvsPatchField.C b/src/finiteVolume/fields/fvsPatchFields/constraint/processor/processorFvsPatchField.C index 68eaf04816..a6fa161790 100644 --- a/src/finiteVolume/fields/fvsPatchFields/constraint/processor/processorFvsPatchField.C +++ b/src/finiteVolume/fields/fvsPatchFields/constraint/processor/processorFvsPatchField.C @@ -25,15 +25,10 @@ License #include "processorFvsPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -processorFvsPatchField::processorFvsPatchField +Foam::processorFvsPatchField::processorFvsPatchField ( const fvPatch& p, const DimensionedField& iF @@ -45,7 +40,7 @@ processorFvsPatchField::processorFvsPatchField template -processorFvsPatchField::processorFvsPatchField +Foam::processorFvsPatchField::processorFvsPatchField ( const fvPatch& p, const DimensionedField& iF, @@ -57,9 +52,31 @@ processorFvsPatchField::processorFvsPatchField {} -// Construct by mapping given processorFvsPatchField template -processorFvsPatchField::processorFvsPatchField +Foam::processorFvsPatchField::processorFvsPatchField +( + const fvPatch& p, + const DimensionedField& iF, + const dictionary& dict +) +: + coupledFvsPatchField(p, iF, dict), + procPatch_(refCast(p)) +{ + if (!isType(p)) + { + FatalIOErrorInFunction + ( + dict + ) << "patch " << this->patch().index() << " not processor type. " + << "Patch type = " << p.type() + << exit(FatalIOError); + } +} + + +template +Foam::processorFvsPatchField::processorFvsPatchField ( const processorFvsPatchField& ptf, const fvPatch& p, @@ -83,30 +100,7 @@ processorFvsPatchField::processorFvsPatchField template -processorFvsPatchField::processorFvsPatchField -( - const fvPatch& p, - const DimensionedField& iF, - const dictionary& dict -) -: - coupledFvsPatchField(p, iF, dict), - procPatch_(refCast(p)) -{ - if (!isType(p)) - { - FatalIOErrorInFunction - ( - dict - ) << "patch " << this->patch().index() << " not processor type. " - << "Patch type = " << p.type() - << exit(FatalIOError); - } -} - - -template -processorFvsPatchField::processorFvsPatchField +Foam::processorFvsPatchField::processorFvsPatchField ( const processorFvsPatchField& ptf ) @@ -117,7 +111,7 @@ processorFvsPatchField::processorFvsPatchField template -processorFvsPatchField::processorFvsPatchField +Foam::processorFvsPatchField::processorFvsPatchField ( const processorFvsPatchField& ptf, const DimensionedField& iF @@ -131,12 +125,8 @@ processorFvsPatchField::processorFvsPatchField // * * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * // template -processorFvsPatchField::~processorFvsPatchField() +Foam::processorFvsPatchField::~processorFvsPatchField() {} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvsPatchFields/constraint/processorCyclic/processorCyclicFvsPatchField.C b/src/finiteVolume/fields/fvsPatchFields/constraint/processorCyclic/processorCyclicFvsPatchField.C index e633442aca..0cfa469404 100644 --- a/src/finiteVolume/fields/fvsPatchFields/constraint/processorCyclic/processorCyclicFvsPatchField.C +++ b/src/finiteVolume/fields/fvsPatchFields/constraint/processorCyclic/processorCyclicFvsPatchField.C @@ -25,15 +25,10 @@ License #include "processorCyclicFvsPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -processorCyclicFvsPatchField::processorCyclicFvsPatchField +Foam::processorCyclicFvsPatchField::processorCyclicFvsPatchField ( const fvPatch& p, const DimensionedField& iF @@ -45,7 +40,7 @@ processorCyclicFvsPatchField::processorCyclicFvsPatchField template -processorCyclicFvsPatchField::processorCyclicFvsPatchField +Foam::processorCyclicFvsPatchField::processorCyclicFvsPatchField ( const fvPatch& p, const DimensionedField& iF, @@ -57,9 +52,31 @@ processorCyclicFvsPatchField::processorCyclicFvsPatchField {} -// Construct by mapping given processorCyclicFvsPatchField template -processorCyclicFvsPatchField::processorCyclicFvsPatchField +Foam::processorCyclicFvsPatchField::processorCyclicFvsPatchField +( + const fvPatch& p, + const DimensionedField& iF, + const dictionary& dict +) +: + coupledFvsPatchField(p, iF, dict), + procPatch_(refCast(p)) +{ + if (!isType(p)) + { + FatalIOErrorInFunction + ( + dict + ) << "patch " << this->patch().index() << " not processor type. " + << "Patch type = " << p.type() + << exit(FatalIOError); + } +} + + +template +Foam::processorCyclicFvsPatchField::processorCyclicFvsPatchField ( const processorCyclicFvsPatchField& ptf, const fvPatch& p, @@ -83,30 +100,7 @@ processorCyclicFvsPatchField::processorCyclicFvsPatchField template -processorCyclicFvsPatchField::processorCyclicFvsPatchField -( - const fvPatch& p, - const DimensionedField& iF, - const dictionary& dict -) -: - coupledFvsPatchField(p, iF, dict), - procPatch_(refCast(p)) -{ - if (!isType(p)) - { - FatalIOErrorInFunction - ( - dict - ) << "patch " << this->patch().index() << " not processor type. " - << "Patch type = " << p.type() - << exit(FatalIOError); - } -} - - -template -processorCyclicFvsPatchField::processorCyclicFvsPatchField +Foam::processorCyclicFvsPatchField::processorCyclicFvsPatchField ( const processorCyclicFvsPatchField& ptf ) @@ -117,7 +111,7 @@ processorCyclicFvsPatchField::processorCyclicFvsPatchField template -processorCyclicFvsPatchField::processorCyclicFvsPatchField +Foam::processorCyclicFvsPatchField::processorCyclicFvsPatchField ( const processorCyclicFvsPatchField& ptf, const DimensionedField& iF @@ -131,12 +125,8 @@ processorCyclicFvsPatchField::processorCyclicFvsPatchField // * * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * // template -processorCyclicFvsPatchField::~processorCyclicFvsPatchField() +Foam::processorCyclicFvsPatchField::~processorCyclicFvsPatchField() {} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvsPatchFields/constraint/symmetry/symmetryFvsPatchField.C b/src/finiteVolume/fields/fvsPatchFields/constraint/symmetry/symmetryFvsPatchField.C index 104052a54b..fef8848e67 100644 --- a/src/finiteVolume/fields/fvsPatchFields/constraint/symmetry/symmetryFvsPatchField.C +++ b/src/finiteVolume/fields/fvsPatchFields/constraint/symmetry/symmetryFvsPatchField.C @@ -25,15 +25,10 @@ License #include "symmetryFvsPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -symmetryFvsPatchField::symmetryFvsPatchField +Foam::symmetryFvsPatchField::symmetryFvsPatchField ( const fvPatch& p, const DimensionedField& iF @@ -44,7 +39,29 @@ symmetryFvsPatchField::symmetryFvsPatchField template -symmetryFvsPatchField::symmetryFvsPatchField +Foam::symmetryFvsPatchField::symmetryFvsPatchField +( + const fvPatch& p, + const DimensionedField& iF, + const dictionary& dict +) +: + fvsPatchField(p, iF, dict) +{ + if (!isType(p)) + { + FatalIOErrorInFunction + ( + dict + ) << "patch " << this->patch().index() << " not symmetry type. " + << "Patch type = " << p.type() + << exit(FatalIOError); + } +} + + +template +Foam::symmetryFvsPatchField::symmetryFvsPatchField ( const symmetryFvsPatchField& ptf, const fvPatch& p, @@ -67,29 +84,7 @@ symmetryFvsPatchField::symmetryFvsPatchField template -symmetryFvsPatchField::symmetryFvsPatchField -( - const fvPatch& p, - const DimensionedField& iF, - const dictionary& dict -) -: - fvsPatchField(p, iF, dict) -{ - if (!isType(p)) - { - FatalIOErrorInFunction - ( - dict - ) << "patch " << this->patch().index() << " not symmetry type. " - << "Patch type = " << p.type() - << exit(FatalIOError); - } -} - - -template -symmetryFvsPatchField::symmetryFvsPatchField +Foam::symmetryFvsPatchField::symmetryFvsPatchField ( const symmetryFvsPatchField& ptf ) @@ -99,7 +94,7 @@ symmetryFvsPatchField::symmetryFvsPatchField template -symmetryFvsPatchField::symmetryFvsPatchField +Foam::symmetryFvsPatchField::symmetryFvsPatchField ( const symmetryFvsPatchField& ptf, const DimensionedField& iF @@ -109,8 +104,4 @@ symmetryFvsPatchField::symmetryFvsPatchField {} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvsPatchFields/constraint/symmetryPlane/symmetryPlaneFvsPatchField.C b/src/finiteVolume/fields/fvsPatchFields/constraint/symmetryPlane/symmetryPlaneFvsPatchField.C index ade5b53c0e..c1d2d3d3c5 100644 --- a/src/finiteVolume/fields/fvsPatchFields/constraint/symmetryPlane/symmetryPlaneFvsPatchField.C +++ b/src/finiteVolume/fields/fvsPatchFields/constraint/symmetryPlane/symmetryPlaneFvsPatchField.C @@ -25,15 +25,10 @@ License #include "symmetryPlaneFvsPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -symmetryPlaneFvsPatchField::symmetryPlaneFvsPatchField +Foam::symmetryPlaneFvsPatchField::symmetryPlaneFvsPatchField ( const fvPatch& p, const DimensionedField& iF @@ -44,7 +39,29 @@ symmetryPlaneFvsPatchField::symmetryPlaneFvsPatchField template -symmetryPlaneFvsPatchField::symmetryPlaneFvsPatchField +Foam::symmetryPlaneFvsPatchField::symmetryPlaneFvsPatchField +( + const fvPatch& p, + const DimensionedField& iF, + const dictionary& dict +) +: + fvsPatchField(p, iF, dict) +{ + if (!isType(p)) + { + FatalIOErrorInFunction + ( + dict + ) << "patch " << this->patch().index() << " not symmetryPlane type. " + << "Patch type = " << p.type() + << exit(FatalIOError); + } +} + + +template +Foam::symmetryPlaneFvsPatchField::symmetryPlaneFvsPatchField ( const symmetryPlaneFvsPatchField& ptf, const fvPatch& p, @@ -67,29 +84,7 @@ symmetryPlaneFvsPatchField::symmetryPlaneFvsPatchField template -symmetryPlaneFvsPatchField::symmetryPlaneFvsPatchField -( - const fvPatch& p, - const DimensionedField& iF, - const dictionary& dict -) -: - fvsPatchField(p, iF, dict) -{ - if (!isType(p)) - { - FatalIOErrorInFunction - ( - dict - ) << "patch " << this->patch().index() << " not symmetryPlane type. " - << "Patch type = " << p.type() - << exit(FatalIOError); - } -} - - -template -symmetryPlaneFvsPatchField::symmetryPlaneFvsPatchField +Foam::symmetryPlaneFvsPatchField::symmetryPlaneFvsPatchField ( const symmetryPlaneFvsPatchField& ptf ) @@ -99,7 +94,7 @@ symmetryPlaneFvsPatchField::symmetryPlaneFvsPatchField template -symmetryPlaneFvsPatchField::symmetryPlaneFvsPatchField +Foam::symmetryPlaneFvsPatchField::symmetryPlaneFvsPatchField ( const symmetryPlaneFvsPatchField& ptf, const DimensionedField& iF @@ -109,8 +104,4 @@ symmetryPlaneFvsPatchField::symmetryPlaneFvsPatchField {} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvsPatchFields/constraint/wedge/wedgeFvsPatchField.C b/src/finiteVolume/fields/fvsPatchFields/constraint/wedge/wedgeFvsPatchField.C index ec31c57f1b..5c5ada449e 100644 --- a/src/finiteVolume/fields/fvsPatchFields/constraint/wedge/wedgeFvsPatchField.C +++ b/src/finiteVolume/fields/fvsPatchFields/constraint/wedge/wedgeFvsPatchField.C @@ -25,15 +25,10 @@ License #include "wedgeFvsPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -wedgeFvsPatchField::wedgeFvsPatchField +Foam::wedgeFvsPatchField::wedgeFvsPatchField ( const fvPatch& p, const DimensionedField& iF @@ -44,7 +39,29 @@ wedgeFvsPatchField::wedgeFvsPatchField template -wedgeFvsPatchField::wedgeFvsPatchField +Foam::wedgeFvsPatchField::wedgeFvsPatchField +( + const fvPatch& p, + const DimensionedField& iF, + const dictionary& dict +) +: + fvsPatchField(p, iF, dict) +{ + if (!isType(p)) + { + FatalIOErrorInFunction + ( + dict + ) << "patch " << this->patch().index() << " not wedge type. " + << "Patch type = " << p.type() + << exit(FatalIOError); + } +} + + +template +Foam::wedgeFvsPatchField::wedgeFvsPatchField ( const wedgeFvsPatchField& ptf, const fvPatch& p, @@ -67,29 +84,7 @@ wedgeFvsPatchField::wedgeFvsPatchField template -wedgeFvsPatchField::wedgeFvsPatchField -( - const fvPatch& p, - const DimensionedField& iF, - const dictionary& dict -) -: - fvsPatchField(p, iF, dict) -{ - if (!isType(p)) - { - FatalIOErrorInFunction - ( - dict - ) << "patch " << this->patch().index() << " not wedge type. " - << "Patch type = " << p.type() - << exit(FatalIOError); - } -} - - -template -wedgeFvsPatchField::wedgeFvsPatchField +Foam::wedgeFvsPatchField::wedgeFvsPatchField ( const wedgeFvsPatchField& ptf ) @@ -99,7 +94,7 @@ wedgeFvsPatchField::wedgeFvsPatchField template -wedgeFvsPatchField::wedgeFvsPatchField +Foam::wedgeFvsPatchField::wedgeFvsPatchField ( const wedgeFvsPatchField& ptf, const DimensionedField& iF @@ -109,8 +104,4 @@ wedgeFvsPatchField::wedgeFvsPatchField {} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/finiteVolume/fields/fvsPatchFields/fvsPatchField/fvsPatchField.C b/src/finiteVolume/fields/fvsPatchFields/fvsPatchField/fvsPatchField.C index 713f876c7d..cb0276cc7c 100644 --- a/src/finiteVolume/fields/fvsPatchFields/fvsPatchField/fvsPatchField.C +++ b/src/finiteVolume/fields/fvsPatchFields/fvsPatchField/fvsPatchField.C @@ -28,15 +28,10 @@ License #include "fvMesh.H" #include "fvPatchFieldMapper.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template -fvsPatchField::fvsPatchField +Foam::fvsPatchField::fvsPatchField ( const fvPatch& p, const DimensionedField& iF @@ -49,7 +44,7 @@ fvsPatchField::fvsPatchField template -fvsPatchField::fvsPatchField +Foam::fvsPatchField::fvsPatchField ( const fvPatch& p, const DimensionedField& iF, @@ -63,7 +58,7 @@ fvsPatchField::fvsPatchField template -fvsPatchField::fvsPatchField +Foam::fvsPatchField::fvsPatchField ( const fvsPatchField& ptf, const fvPatch& p, @@ -78,7 +73,7 @@ fvsPatchField::fvsPatchField template -fvsPatchField::fvsPatchField +Foam::fvsPatchField::fvsPatchField ( const fvPatch& p, const DimensionedField& iF, @@ -108,7 +103,7 @@ fvsPatchField::fvsPatchField template -fvsPatchField::fvsPatchField +Foam::fvsPatchField::fvsPatchField ( const fvsPatchField& ptf ) @@ -120,7 +115,7 @@ fvsPatchField::fvsPatchField template -fvsPatchField::fvsPatchField +Foam::fvsPatchField::fvsPatchField ( const fvsPatchField& ptf, const DimensionedField& iF @@ -135,14 +130,14 @@ fvsPatchField::fvsPatchField // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -const objectRegistry& fvsPatchField::db() const +const Foam::objectRegistry& Foam::fvsPatchField::db() const { return patch_.boundaryMesh().mesh(); } template -void fvsPatchField::check(const fvsPatchField& ptf) const +void Foam::fvsPatchField::check(const fvsPatchField& ptf) const { if (&patch_ != &(ptf.patch_)) { @@ -153,9 +148,8 @@ void fvsPatchField::check(const fvsPatchField& ptf) const } -// Map from self template -void fvsPatchField::autoMap +void Foam::fvsPatchField::autoMap ( const fvPatchFieldMapper& m ) @@ -164,9 +158,8 @@ void fvsPatchField::autoMap } -// Reverse-map the given fvsPatchField onto this fvsPatchField template -void fvsPatchField::rmap +void Foam::fvsPatchField::rmap ( const fvsPatchField& ptf, const labelList& addr @@ -176,9 +169,8 @@ void fvsPatchField::rmap } -// Write template -void fvsPatchField::write(Ostream& os) const +void Foam::fvsPatchField::write(Ostream& os) const { os.writeKeyword("type") << type() << token::END_STATEMENT << nl; this->writeEntry("value", os); @@ -188,7 +180,7 @@ void fvsPatchField::write(Ostream& os) const // * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * // template -void fvsPatchField::operator= +void Foam::fvsPatchField::operator= ( const UList& ul ) @@ -198,7 +190,7 @@ void fvsPatchField::operator= template -void fvsPatchField::operator= +void Foam::fvsPatchField::operator= ( const fvsPatchField& ptf ) @@ -209,7 +201,7 @@ void fvsPatchField::operator= template -void fvsPatchField::operator+= +void Foam::fvsPatchField::operator+= ( const fvsPatchField& ptf ) @@ -220,7 +212,7 @@ void fvsPatchField::operator+= template -void fvsPatchField::operator-= +void Foam::fvsPatchField::operator-= ( const fvsPatchField& ptf ) @@ -231,7 +223,7 @@ void fvsPatchField::operator-= template -void fvsPatchField::operator*= +void Foam::fvsPatchField::operator*= ( const fvsPatchField& ptf ) @@ -248,7 +240,7 @@ void fvsPatchField::operator*= template -void fvsPatchField::operator/= +void Foam::fvsPatchField::operator/= ( const fvsPatchField& ptf ) @@ -264,7 +256,7 @@ void fvsPatchField::operator/= template -void fvsPatchField::operator+= +void Foam::fvsPatchField::operator+= ( const Field& tf ) @@ -274,7 +266,7 @@ void fvsPatchField::operator+= template -void fvsPatchField::operator-= +void Foam::fvsPatchField::operator-= ( const Field& tf ) @@ -284,7 +276,7 @@ void fvsPatchField::operator-= template -void fvsPatchField::operator*= +void Foam::fvsPatchField::operator*= ( const scalarField& tf ) @@ -294,7 +286,7 @@ void fvsPatchField::operator*= template -void fvsPatchField::operator/= +void Foam::fvsPatchField::operator/= ( const scalarField& tf ) @@ -304,7 +296,7 @@ void fvsPatchField::operator/= template -void fvsPatchField::operator= +void Foam::fvsPatchField::operator= ( const Type& t ) @@ -314,7 +306,7 @@ void fvsPatchField::operator= template -void fvsPatchField::operator+= +void Foam::fvsPatchField::operator+= ( const Type& t ) @@ -324,7 +316,7 @@ void fvsPatchField::operator+= template -void fvsPatchField::operator-= +void Foam::fvsPatchField::operator-= ( const Type& t ) @@ -334,7 +326,7 @@ void fvsPatchField::operator-= template -void fvsPatchField::operator*= +void Foam::fvsPatchField::operator*= ( const scalar s ) @@ -344,7 +336,7 @@ void fvsPatchField::operator*= template -void fvsPatchField::operator/= +void Foam::fvsPatchField::operator/= ( const scalar s ) @@ -353,9 +345,8 @@ void fvsPatchField::operator/= } -// Force an assignment, overriding fixedValue status template -void fvsPatchField::operator== +void Foam::fvsPatchField::operator== ( const fvsPatchField& ptf ) @@ -365,7 +356,7 @@ void fvsPatchField::operator== template -void fvsPatchField::operator== +void Foam::fvsPatchField::operator== ( const Field& tf ) @@ -375,7 +366,7 @@ void fvsPatchField::operator== template -void fvsPatchField::operator== +void Foam::fvsPatchField::operator== ( const Type& t ) @@ -387,7 +378,7 @@ void fvsPatchField::operator== // * * * * * * * * * * * * * * * IOstream Operators * * * * * * * * * * * * // template -Ostream& operator<<(Ostream& os, const fvsPatchField& ptf) +Foam::Ostream& Foam::operator<<(Ostream& os, const fvsPatchField& ptf) { ptf.write(os); @@ -399,10 +390,6 @@ Ostream& operator<<(Ostream& os, const fvsPatchField& ptf) // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -} // End namespace Foam - -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -# include "fvsPatchFieldNew.C" +#include "fvsPatchFieldNew.C" // ************************************************************************* // diff --git a/src/genericPatchFields/genericPointPatchField/genericPointPatchField.C b/src/genericPatchFields/genericPointPatchField/genericPointPatchField.C index 08b254e658..bb7598b26a 100644 --- a/src/genericPatchFields/genericPointPatchField/genericPointPatchField.C +++ b/src/genericPatchFields/genericPointPatchField/genericPointPatchField.C @@ -26,15 +26,10 @@ License #include "genericPointPatchField.H" #include "pointPatchFieldMapper.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -genericPointPatchField::genericPointPatchField +Foam::genericPointPatchField::genericPointPatchField ( const pointPatch& p, const DimensionedField& iF @@ -47,7 +42,7 @@ genericPointPatchField::genericPointPatchField template -genericPointPatchField::genericPointPatchField +Foam::genericPointPatchField::genericPointPatchField ( const pointPatch& p, const DimensionedField& iF, @@ -308,7 +303,7 @@ genericPointPatchField::genericPointPatchField template -genericPointPatchField::genericPointPatchField +Foam::genericPointPatchField::genericPointPatchField ( const genericPointPatchField& ptf, const pointPatch& p, @@ -393,7 +388,7 @@ genericPointPatchField::genericPointPatchField template -genericPointPatchField::genericPointPatchField +Foam::genericPointPatchField::genericPointPatchField ( const genericPointPatchField& ptf, const DimensionedField& iF @@ -413,7 +408,7 @@ genericPointPatchField::genericPointPatchField // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template -void genericPointPatchField::autoMap +void Foam::genericPointPatchField::autoMap ( const pointPatchFieldMapper& m ) @@ -471,7 +466,7 @@ void genericPointPatchField::autoMap template -void genericPointPatchField::rmap +void Foam::genericPointPatchField::rmap ( const pointPatchField& ptf, const labelList& addr @@ -563,7 +558,7 @@ void genericPointPatchField::rmap template -void genericPointPatchField::write(Ostream& os) const +void Foam::genericPointPatchField::write(Ostream& os) const { os.writeKeyword("type") << actualTypeName_ << token::END_STATEMENT << nl; @@ -614,8 +609,4 @@ void genericPointPatchField::write(Ostream& os) const } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/mesh/autoMesh/autoHexMesh/externalDisplacementMeshMover/zeroFixedValue/zeroFixedValuePointPatchField.C b/src/mesh/autoMesh/autoHexMesh/externalDisplacementMeshMover/zeroFixedValue/zeroFixedValuePointPatchField.C index 4e3b6745ec..8ee5b49f04 100644 --- a/src/mesh/autoMesh/autoHexMesh/externalDisplacementMeshMover/zeroFixedValue/zeroFixedValuePointPatchField.C +++ b/src/mesh/autoMesh/autoHexMesh/externalDisplacementMeshMover/zeroFixedValue/zeroFixedValuePointPatchField.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2014 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2014-2015 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -25,15 +25,10 @@ License #include "zeroFixedValuePointPatchField.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * * // template -zeroFixedValuePointPatchField:: +Foam::zeroFixedValuePointPatchField:: zeroFixedValuePointPatchField ( const pointPatch& p, @@ -45,7 +40,7 @@ zeroFixedValuePointPatchField template -zeroFixedValuePointPatchField:: +Foam::zeroFixedValuePointPatchField:: zeroFixedValuePointPatchField ( const pointPatch& p, @@ -60,7 +55,7 @@ zeroFixedValuePointPatchField template -zeroFixedValuePointPatchField:: +Foam::zeroFixedValuePointPatchField:: zeroFixedValuePointPatchField ( const zeroFixedValuePointPatchField& ptf, @@ -77,7 +72,7 @@ zeroFixedValuePointPatchField template -zeroFixedValuePointPatchField:: +Foam::zeroFixedValuePointPatchField:: zeroFixedValuePointPatchField ( const zeroFixedValuePointPatchField& ptf @@ -88,7 +83,7 @@ zeroFixedValuePointPatchField template -zeroFixedValuePointPatchField:: +Foam::zeroFixedValuePointPatchField:: zeroFixedValuePointPatchField ( const zeroFixedValuePointPatchField& ptf, @@ -102,8 +97,4 @@ zeroFixedValuePointPatchField } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // From 67a9b8df73908909ff8b99b2c3f389416a89981c Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Wed, 9 Dec 2015 09:16:08 +0000 Subject: [PATCH 039/447] metisDecomp: Changed to use scalar rather than float Requires that metis is compiled with REALTYPEWIDTH set to 32 for SP and 64 for DP. --- src/parallel/decompose/metisDecomp/metisDecomp.C | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/parallel/decompose/metisDecomp/metisDecomp.C b/src/parallel/decompose/metisDecomp/metisDecomp.C index 1fb0ea1c39..d87619bd1d 100644 --- a/src/parallel/decompose/metisDecomp/metisDecomp.C +++ b/src/parallel/decompose/metisDecomp/metisDecomp.C @@ -25,7 +25,6 @@ License #include "metisDecomp.H" #include "addToRunTimeSelectionTable.H" -#include "floatScalar.H" #include "Time.H" extern "C" @@ -68,7 +67,7 @@ Foam::label Foam::metisDecomp::decompose // processor weights initialised with no size, only used if specified in // a file - Field processorWeights; + Field processorWeights; // cell weights (so on the vertices of the dual) List