/*---------------------------------------------------------------------------*\ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | \\ / A nd | www.openfoam.com \\/ M anipulation | ------------------------------------------------------------------------------- Copyright (C) 2011-2016 OpenFOAM Foundation Copyright (C) 2020 OpenCFD Ltd. ------------------------------------------------------------------------------- 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 "activeBaffleVelocityFvPatchVectorField.H" #include "addToRunTimeSelectionTable.H" #include "volFields.H" #include "surfaceFields.H" #include "cyclicFvPatch.H" // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // Foam::activeBaffleVelocityFvPatchVectorField:: activeBaffleVelocityFvPatchVectorField ( const fvPatch& p, const DimensionedField& iF ) : fixedValueFvPatchVectorField(p, iF), pName_("p"), cyclicPatchName_(), cyclicPatchLabel_(-1), orientation_(1), initWallSf_(0), initCyclicSf_(0), nbrCyclicSf_(0), openFraction_(0), openingTime_(0), maxOpenFractionDelta_(0), curTimeIndex_(-1) {} Foam::activeBaffleVelocityFvPatchVectorField:: activeBaffleVelocityFvPatchVectorField ( const activeBaffleVelocityFvPatchVectorField& ptf, const fvPatch& p, const DimensionedField& iF, const fvPatchFieldMapper& mapper ) : fixedValueFvPatchVectorField(ptf, p, iF, mapper), pName_(ptf.pName_), cyclicPatchName_(ptf.cyclicPatchName_), cyclicPatchLabel_(ptf.cyclicPatchLabel_), orientation_(ptf.orientation_), initWallSf_(ptf.initWallSf_), initCyclicSf_(ptf.initCyclicSf_), nbrCyclicSf_(ptf.nbrCyclicSf_), openFraction_(ptf.openFraction_), openingTime_(ptf.openingTime_), maxOpenFractionDelta_(ptf.maxOpenFractionDelta_), curTimeIndex_(-1) {} Foam::activeBaffleVelocityFvPatchVectorField:: activeBaffleVelocityFvPatchVectorField ( const fvPatch& p, const DimensionedField& iF, const dictionary& dict ) : fixedValueFvPatchVectorField(p, iF, dict, IOobjectOption::NO_READ), pName_(dict.getOrDefault("p", "p")), cyclicPatchName_(dict.lookup("cyclicPatch")), cyclicPatchLabel_(p.patch().boundaryMesh().findPatchID(cyclicPatchName_)), orientation_(dict.get