ATCModelTemplates.C
Go to the documentation of this file.
1/*---------------------------------------------------------------------------*\
2 ========= |
3 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4 \\ / O peration |
5 \\ / A nd | www.openfoam.com
6 \\/ M anipulation |
7-------------------------------------------------------------------------------
8 Copyright (C) 2007-2019 PCOpt/NTUA
9 Copyright (C) 2013-2019 FOSS GP
10 Copyright (C) 2019 OpenCFD Ltd.
11-------------------------------------------------------------------------------
12License
13 This file is part of OpenFOAM.
14
15 OpenFOAM is free software: you can redistribute it and/or modify it
16 under the terms of the GNU General Public License as published by
17 the Free Software Foundation, either version 3 of the License, or
18 (at your option) any later version.
19
20 OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
21 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
22 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
23 for more details.
24
25 You should have received a copy of the GNU General Public License
26 along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
27
28\*---------------------------------------------------------------------------*/
29
30#include "ATCModel.H"
32
33// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
34
35template<class Type>
37(
39 const labelList& cells
40)
41{
43 (
45 (
46 vf.name() + "Limiter",
48 mesh_,
51 ),
52 mesh_,
53 dimensionedScalar("limiter", dimless, 1.0),
55 );
56
58
59 //Limit actual field
60 vf *= limiter;
61}
62
63
64// ************************************************************************* //
const fvMesh & mesh_
Definition: ATCModel.H:79
void smoothFieldBasedOnCells(GeometricField< Type, fvPatchField, volMesh > &vf, const labelList &cells)
Smooth an arbitrary field on a given list of cells.
void computeLimiter()
Compute limiter based on the cells given by zeroATCcells.
Definition: ATCModel.C:45
const label nSmooth_
Definition: ATCModel.H:87
Generic GeometricField class.
Defines the attributes of an object for which implicit objectRegistry management is supported,...
Definition: IOobject.H:170
const word & name() const noexcept
Return the object name.
Definition: IOobjectI.H:65
static word timeName(const scalar t, const int precision=precision_)
Definition: Time.C:780
const Time & time() const
Return the top-level database.
Definition: fvMesh.H:290
This boundary condition applies a zero-gradient condition from the patch internal field onto the patc...
const cellShapeList & cells
const dimensionSet dimless
Dimensionless.
tmp< areaScalarField > limiter(const areaScalarField &phi)
Definition: faNVDscheme.C:38