From 1a17ce00c45a8a256aadb4336be71a8b33910155 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Mon, 17 Apr 2023 10:31:10 +0100 Subject: [PATCH] fv::bound: New fvConstraint to bound a scalar field where it is below the specified minimum Class Foam::fv::bound Description Bound the specified scalar field where it is below the specified minimum. Where the field is unbounded it is set to the maximum of the average of the neighbouring cell values and the specified minimum. Usage Example usage: \verbatim limitp { type bound; field p; min 100; } \endverbatim --- .../incompressible/RAS/qZeta/qZeta.C | 4 +- .../cfdTools/general/bound/bound.C | 26 +- .../cfdTools/general/bound/bound.H | 16 +- src/fvConstraints/Make/files | 5 +- .../fixedTemperatureConstraint.C | 241 ------------------ .../fixedTemperatureConstraint.H | 195 -------------- .../fixedValueConstraint.C | 183 ------------- .../fixedValueConstraint.H | 156 ------------ .../limitPressure/limitPressure.C | 1 - 9 files changed, 27 insertions(+), 800 deletions(-) delete mode 100644 src/fvConstraints/fixedTemperatureConstraint/fixedTemperatureConstraint.C delete mode 100644 src/fvConstraints/fixedTemperatureConstraint/fixedTemperatureConstraint.H delete mode 100644 src/fvConstraints/fixedValueConstraint/fixedValueConstraint.C delete mode 100644 src/fvConstraints/fixedValueConstraint/fixedValueConstraint.H diff --git a/src/MomentumTransportModels/incompressible/RAS/qZeta/qZeta.C b/src/MomentumTransportModels/incompressible/RAS/qZeta/qZeta.C index 3cf3734d33..9ba59191fd 100644 --- a/src/MomentumTransportModels/incompressible/RAS/qZeta/qZeta.C +++ b/src/MomentumTransportModels/incompressible/RAS/qZeta/qZeta.C @@ -184,7 +184,7 @@ qZeta::qZeta IOobject::NO_READ, IOobject::AUTO_WRITE ), - sqrt(bound(k_, kMin_)), + sqrt(max(k_, kMin_)), k_.boundaryField().types() ), @@ -198,7 +198,7 @@ qZeta::qZeta IOobject::NO_READ, IOobject::AUTO_WRITE ), - bound(epsilon_, epsilonMin_)/(2.0*q_), + max(epsilon_, epsilonMin_)/(2.0*q_), epsilon_.boundaryField().types() ) { diff --git a/src/finiteVolume/cfdTools/general/bound/bound.C b/src/finiteVolume/cfdTools/general/bound/bound.C index fd545a2b06..436942d54b 100644 --- a/src/finiteVolume/cfdTools/general/bound/bound.C +++ b/src/finiteVolume/cfdTools/general/bound/bound.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | Website: https://openfoam.org - \\ / A nd | Copyright (C) 2011-2022 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2023 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -24,17 +24,15 @@ License \*---------------------------------------------------------------------------*/ #include "bound.H" -#include "volFields.H" #include "fvcAverage.H" // * * * * * * * * * * * * * * * Global Functions * * * * * * * * * * * * * // -Foam::volScalarField& -Foam::bound(volScalarField& vsf, const dimensionedScalar& lowerBound) +bool Foam::bound(volScalarField& vsf, const dimensionedScalar& min) { - const scalar minVsf = min(vsf).value(); + const scalar minVsf = Foam::min(vsf).value(); - if (minVsf < lowerBound.value()) + if (minVsf < min.value()) { Info<< "bounding " << vsf.name() << ", min: " << minVsf @@ -47,16 +45,20 @@ Foam::bound(volScalarField& vsf, const dimensionedScalar& lowerBound) max ( vsf.primitiveField(), - fvc::average(max(vsf, lowerBound))().primitiveField() - * pos0(-vsf.primitiveField()) + fvc::average(max(vsf, min))().primitiveField() + *pos0(-vsf.primitiveField()) ), - lowerBound.value() + min.value() ); - vsf.boundaryFieldRef() = max(vsf.boundaryField(), lowerBound.value()); - } + vsf.boundaryFieldRef() = max(vsf.boundaryField(), min.value()); - return vsf; + return true; + } + else + { + return false; + } } diff --git a/src/finiteVolume/cfdTools/general/bound/bound.H b/src/finiteVolume/cfdTools/general/bound/bound.H index 319c937ed0..aa36e2233a 100644 --- a/src/finiteVolume/cfdTools/general/bound/bound.H +++ b/src/finiteVolume/cfdTools/general/bound/bound.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | Website: https://openfoam.org - \\ / A nd | Copyright (C) 2011-2018 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2023 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -25,10 +25,12 @@ InNamespace Foam Description - Bound the given scalar field if it has gone unbounded. + Bound the given scalar field where it is below the specified minimum. - Used extensively in RAS and LES turbulence models, but also of use - within solvers. + Where the field is unbounded it is set to the maximum of the average of + the neighbouring cell values and the specified minimum. + + Used extensively in RAS and LES turbulence models to bound k, epsilon etc. SourceFiles bound.C @@ -48,10 +50,8 @@ namespace Foam // * * * * * * * * * * * * * * * Global Functions * * * * * * * * * * * * * // -//- Bound the given scalar field if it has gone unbounded. -// Return the bounded field. -// Used extensively in RAS and LES turbulence models. -volScalarField& bound(volScalarField&, const dimensionedScalar& lowerBound); +//- Bound the given scalar field where it is below the specified min value +bool bound(volScalarField&, const dimensionedScalar& min); // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // diff --git a/src/fvConstraints/Make/files b/src/fvConstraints/Make/files index 15ab3ad94e..7ba332a868 100644 --- a/src/fvConstraints/Make/files +++ b/src/fvConstraints/Make/files @@ -1,8 +1,9 @@ -fixedValueConstraint/fixedValueConstraint.C -fixedTemperatureConstraint/fixedTemperatureConstraint.C +fixedValue/fixedValueConstraint.C +fixedTemperature/fixedTemperatureConstraint.C limitTemperature/limitTemperature.C limitPressure/limitPressure.C limitMag/limitMag.C +bound/boundConstraint.C meanVelocityForce/meanVelocityForce.C meanVelocityForce/patchMeanVelocityForce/patchMeanVelocityForce.C diff --git a/src/fvConstraints/fixedTemperatureConstraint/fixedTemperatureConstraint.C b/src/fvConstraints/fixedTemperatureConstraint/fixedTemperatureConstraint.C deleted file mode 100644 index 87183fefbe..0000000000 --- a/src/fvConstraints/fixedTemperatureConstraint/fixedTemperatureConstraint.C +++ /dev/null @@ -1,241 +0,0 @@ -/*---------------------------------------------------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Copyright (C) 2012-2023 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 "fixedTemperatureConstraint.H" -#include "fvMesh.H" -#include "fvMatrices.H" -#include "basicThermo.H" -#include "addToRunTimeSelectionTable.H" - -// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * // - -namespace Foam -{ - namespace fv - { - defineTypeNameAndDebug(fixedTemperatureConstraint, 0); - addToRunTimeSelectionTable - ( - fvConstraint, - fixedTemperatureConstraint, - dictionary - ); - } - - template<> - const char* NamedEnum:: - names[] = - { - "uniform", - "lookup" - }; -} - -const Foam::NamedEnum - Foam::fv::fixedTemperatureConstraint::modeNames_; - - -// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * // - -void Foam::fv::fixedTemperatureConstraint::readCoeffs() -{ - mode_ = modeNames_.read(coeffs().lookup("mode")); - - switch (mode_) - { - case temperatureMode::uniform: - { - TValue_.reset - ( - Function1::New("temperature", coeffs()).ptr() - ); - break; - } - case temperatureMode::lookup: - { - TName_ = coeffs().lookupOrDefault("T", "T"); - break; - } - } - - phaseName_ = coeffs().lookupOrDefault("phase", word::null); - - fraction_ = - coeffs().found("fraction") - ? Function1::New("fraction", coeffs()) - : autoPtr>(); -} - - -// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // - -Foam::fv::fixedTemperatureConstraint::fixedTemperatureConstraint -( - const word& name, - const word& modelType, - const fvMesh& mesh, - const dictionary& dict -) -: - fvConstraint(name, modelType, mesh, dict), - set_(mesh, coeffs()), - mode_(temperatureMode::uniform), - TValue_(nullptr), - TName_(word::null), - phaseName_(word::null) -{ - readCoeffs(); -} - - -// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // - -Foam::wordList Foam::fv::fixedTemperatureConstraint::constrainedFields() const -{ - const basicThermo& thermo = - mesh().lookupObject - ( - IOobject::groupName(physicalProperties::typeName, phaseName_) - ); - - return wordList(1, thermo.he().name()); -} - - -bool Foam::fv::fixedTemperatureConstraint::constrain -( - fvMatrix& eqn, - const word& fieldName -) const -{ - const labelUList cells = set_.cells(); - - const basicThermo& thermo = - mesh().lookupObject - ( - IOobject::groupName(physicalProperties::typeName, phaseName_) - ); - - const scalar t = mesh().time().userTimeValue(); - - switch (mode_) - { - case temperatureMode::uniform: - { - const scalarField Tuni(cells.size(), TValue_->value(t)); - const scalarField heuni(thermo.he(Tuni, cells)); - - if (fraction_.valid()) - { - eqn.setValues - ( - cells, - heuni, - scalarList(cells.size(), fraction_->value(t)) - ); - } - else - { - eqn.setValues(cells, heuni); - } - - break; - } - case temperatureMode::lookup: - { - const volScalarField& T = - mesh().lookupObject(TName_); - const scalarField Tlkp(T, cells); - const scalarField helkp(thermo.he(Tlkp, cells)); - - if (fraction_.valid()) - { - eqn.setValues - ( - cells, - helkp, - scalarList(cells.size(), fraction_->value(t)) - ); - } - else - { - eqn.setValues(cells, helkp); - } - - break; - } - } - - return cells.size(); -} - - -bool Foam::fv::fixedTemperatureConstraint::movePoints() -{ - set_.movePoints(); - return true; -} - - -void Foam::fv::fixedTemperatureConstraint::topoChange -( - const polyTopoChangeMap& map -) -{ - set_.topoChange(map); -} - - -void Foam::fv::fixedTemperatureConstraint::mapMesh(const polyMeshMap& map) -{ - set_.mapMesh(map); -} - - -void Foam::fv::fixedTemperatureConstraint::distribute -( - const polyDistributionMap& map -) -{ - set_.distribute(map); -} - - -bool Foam::fv::fixedTemperatureConstraint::read(const dictionary& dict) -{ - if (fvConstraint::read(dict)) - { - set_.read(coeffs()); - readCoeffs(); - return true; - } - else - { - return false; - } -} - - -// ************************************************************************* // diff --git a/src/fvConstraints/fixedTemperatureConstraint/fixedTemperatureConstraint.H b/src/fvConstraints/fixedTemperatureConstraint/fixedTemperatureConstraint.H deleted file mode 100644 index 75c6bbae8e..0000000000 --- a/src/fvConstraints/fixedTemperatureConstraint/fixedTemperatureConstraint.H +++ /dev/null @@ -1,195 +0,0 @@ -/*---------------------------------------------------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Copyright (C) 2012-2023 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::fv::fixedTemperatureConstraint - -Description - Fixed temperature equation constraint - -Usage - \verbatim - fixedTemperature - { - type fixedTemperatureConstraint; - - select all; - - phase gas; // Optional phase name - - // Uniform temperature constraint - mode uniform; - temperature constant 500; // Uniform temperature - - // // Looked-up field temperature constraint - // T T; // Temperature field name - } - \endverbatim - - Note: - The 'uniform' option allows the use of a time-varying uniform - temperature by means of the Function1 type. - -SourceFiles - fixedTemperatureConstraint.C - -\*---------------------------------------------------------------------------*/ - -#ifndef fixedTemperatureConstraint_H -#define fixedTemperatureConstraint_H - -#include "fvConstraint.H" -#include "fvCellSet.H" -#include "NamedEnum.H" -#include "Function1.H" - -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ -namespace fv -{ - -/*---------------------------------------------------------------------------*\ - Class fixedTemperatureConstraint Declaration -\*---------------------------------------------------------------------------*/ - -class fixedTemperatureConstraint -: - public fvConstraint -{ -public: - - //- Temperature mode - enum class temperatureMode - { - uniform, - lookup - }; - - //- String representation of mode enums - static const NamedEnum modeNames_; - - -private: - - // Private Data - - //- The set of cells the fvConstraint applies to - fvCellSet set_; - - //- Operation mode - temperatureMode mode_; - - //- Uniform temperature [K] - autoPtr> TValue_; - - //- Temperature field name - word TName_; - - //- Optional phase name - word phaseName_; - - //- Fraction of the constraint to apply. Facilitates ramping, or - // pulsing, or deactivation after a time. Should take a value between - // 0 and 1. Defaults to 1 (i.e., apply all of the constraint). - autoPtr> fraction_; - - - // Private Member Functions - - //- Non-virtual read - void readCoeffs(); - - -public: - - //- Runtime type information - TypeName("fixedTemperatureConstraint"); - - - // Constructors - - //- Construct from components - fixedTemperatureConstraint - ( - const word& name, - const word& modelType, - const fvMesh& mesh, - const dictionary& dict - ); - - //- Disallow default bitwise copy construction - fixedTemperatureConstraint(const fixedTemperatureConstraint&) = delete; - - - //- Destructor - virtual ~fixedTemperatureConstraint() - {} - - - // Member Functions - - //- Return the list of fields constrained by the fvConstraint - virtual wordList constrainedFields() const; - - //- Constrain energy equation to fix the temperature - virtual bool constrain - ( - fvMatrix& eqn, - const word& fieldName - ) const; - - //- Update for mesh motion - virtual bool movePoints(); - - //- Update topology using the given map - virtual void topoChange(const polyTopoChangeMap&); - - //- Update from another mesh using the given map - virtual void mapMesh(const polyMeshMap&); - - //- Redistribute or update using the given distribution map - virtual void distribute(const polyDistributionMap&); - - //- Read dictionary - virtual bool read(const dictionary& dict); - - - // Member Operators - - //- Disallow default bitwise assignment - void operator=(const fixedTemperatureConstraint&) = delete; -}; - - -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace fv -} // End namespace Foam - -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -#endif - -// ************************************************************************* // diff --git a/src/fvConstraints/fixedValueConstraint/fixedValueConstraint.C b/src/fvConstraints/fixedValueConstraint/fixedValueConstraint.C deleted file mode 100644 index 646bc2efea..0000000000 --- a/src/fvConstraints/fixedValueConstraint/fixedValueConstraint.C +++ /dev/null @@ -1,183 +0,0 @@ -/*---------------------------------------------------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Copyright (C) 2016-2023 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 "fixedValueConstraint.H" -#include "fvMesh.H" -#include "fvMatrices.H" -#include "fvcSurfaceIntegrate.H" -#include "addToRunTimeSelectionTable.H" - -// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * // - -namespace Foam -{ -namespace fv -{ - defineTypeNameAndDebug(fixedValueConstraint, 0); - - addToRunTimeSelectionTable - ( - fvConstraint, - fixedValueConstraint, - dictionary - ); -} -} - - -// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * // - -void Foam::fv::fixedValueConstraint::readCoeffs() -{ - fieldValues_.clear(); - forAllConstIter(dictionary, coeffs().subDict("fieldValues"), iter) - { - fieldValues_.set - ( - iter().keyword(), - new unknownTypeFunction1 - ( - iter().keyword(), - coeffs().subDict("fieldValues") - ) - ); - } - - fraction_ = - coeffs().found("fraction") - ? Function1::New("fraction", coeffs()) - : autoPtr>(); -} - - -template -bool Foam::fv::fixedValueConstraint::constrainType -( - fvMatrix& eqn, - const word& fieldName -) const -{ - const scalar t = mesh().time().userTimeValue(); - - const List values - ( - set_.nCells(), - fieldValues_[fieldName]->value(t) - ); - - if (fraction_.valid()) - { - eqn.setValues - ( - set_.cells(), - values, - scalarList(set_.nCells(), fraction_->value(t)) - ); - } - else - { - eqn.setValues(set_.cells(), values); - } - - return set_.nCells(); -} - - -// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // - -Foam::fv::fixedValueConstraint::fixedValueConstraint -( - const word& name, - const word& modelType, - const fvMesh& mesh, - const dictionary& dict -) -: - fvConstraint(name, modelType, mesh, dict), - set_(mesh, coeffs()) -{ - readCoeffs(); -} - - -// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // - -Foam::wordList Foam::fv::fixedValueConstraint::constrainedFields() const -{ - return fieldValues_.toc(); -} - - -FOR_ALL_FIELD_TYPES -( - IMPLEMENT_FV_CONSTRAINT_CONSTRAIN, - fv::fixedValueConstraint -); - - -bool Foam::fv::fixedValueConstraint::movePoints() -{ - set_.movePoints(); - return true; -} - - -void Foam::fv::fixedValueConstraint::topoChange(const polyTopoChangeMap& map) -{ - set_.topoChange(map); -} - - -void Foam::fv::fixedValueConstraint::mapMesh(const polyMeshMap& map) -{ - set_.mapMesh(map); -} - - -void Foam::fv::fixedValueConstraint::distribute -( - const polyDistributionMap& map -) -{ - set_.distribute(map); -} - - -bool Foam::fv::fixedValueConstraint::read(const dictionary& dict) -{ - if (fvConstraint::read(dict)) - { - set_.read(coeffs()); - readCoeffs(); - return true; - } - else - { - return false; - } -} - - -// ************************************************************************* // diff --git a/src/fvConstraints/fixedValueConstraint/fixedValueConstraint.H b/src/fvConstraints/fixedValueConstraint/fixedValueConstraint.H deleted file mode 100644 index d4e1f4a635..0000000000 --- a/src/fvConstraints/fixedValueConstraint/fixedValueConstraint.H +++ /dev/null @@ -1,156 +0,0 @@ -/*---------------------------------------------------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Copyright (C) 2016-2023 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::fv::fixedValueConstraint - -Description - Constrain the field values within a specified region. - -Usage - For example to set the turbulence properties within a porous region: - \verbatim - porosityTurbulence - { - type fixedValueConstraint; - - select cellZone; - cellZone porosity; - - fieldValues - { - k 1; - epsilon 150; - } - } - \endverbatim - -SourceFiles - fixedValueConstraint.C - -\*---------------------------------------------------------------------------*/ - -#ifndef fixedValueConstraint_H -#define fixedValueConstraint_H - -#include "fvConstraint.H" -#include "fvCellSet.H" -#include "unknownTypeFunction1.H" -#include "HashPtrTable.H" - -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ -namespace fv -{ - -/*---------------------------------------------------------------------------*\ - Class fixedValueConstraint Declaration -\*---------------------------------------------------------------------------*/ - -class fixedValueConstraint -: - public fvConstraint -{ - // Private Member Data - - //- The set of cells the fvConstraint applies to - fvCellSet set_; - - //- Field values - HashPtrTable fieldValues_; - - //- Fraction of the constraint to apply. Facilitates ramping, or - // pulsing, or deactivation after a time. Should take a value between - // 0 and 1. Defaults to 1 (i.e., apply all of the constraint). - autoPtr> fraction_; - - - // Private Member Functions - - //- Non-virtual read - void readCoeffs(); - - //- Set value on a field - template - inline bool constrainType - ( - fvMatrix& eqn, - const word& fieldName - ) const; - - -public: - - //- Runtime type information - TypeName("fixedValueConstraint"); - - - // Constructors - - //- Construct from components - fixedValueConstraint - ( - const word& name, - const word& modelType, - const fvMesh& mesh, - const dictionary& dict - ); - - - // Member Functions - - //- Return the list of fields constrained by the fvConstraint - virtual wordList constrainedFields() const; - - //- Add a constraint to an equation - FOR_ALL_FIELD_TYPES(DEFINE_FV_CONSTRAINT_CONSTRAIN); - - //- Update for mesh motion - virtual bool movePoints(); - - //- Update topology using the given map - virtual void topoChange(const polyTopoChangeMap&); - - //- Update from another mesh using the given map - virtual void mapMesh(const polyMeshMap&); - - //- Redistribute or update using the given distribution map - virtual void distribute(const polyDistributionMap&); - - //- Read source dictionary - virtual bool read(const dictionary& dict); -}; - - -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace fv -} // End namespace Foam - -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -#endif - -// ************************************************************************* // diff --git a/src/fvConstraints/limitPressure/limitPressure.C b/src/fvConstraints/limitPressure/limitPressure.C index 9329b1e79e..b5f29c6785 100644 --- a/src/fvConstraints/limitPressure/limitPressure.C +++ b/src/fvConstraints/limitPressure/limitPressure.C @@ -237,7 +237,6 @@ void Foam::fv::limitPressure::distribute(const polyDistributionMap&) {} - bool Foam::fv::limitPressure::read(const dictionary& dict) { if (fvConstraint::read(dict))