/*---------------------------------------------------------------------------*\ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | \\ / A nd | www.openfoam.com \\/ M anipulation | ------------------------------------------------------------------------------- Copyright (C) 2011-2016 OpenFOAM Foundation ------------------------------------------------------------------------------- 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 "mappedFixedValueFvPatchField.H" #include "volFields.H" // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // template Foam::mappedFixedValueFvPatchField::mappedFixedValueFvPatchField ( const fvPatch& p, const DimensionedField& iF ) : fixedValueFvPatchField(p, iF), mappedPatchFieldBase(mappedPatchFieldBase::mapper(p, iF), *this) {} template Foam::mappedFixedValueFvPatchField::mappedFixedValueFvPatchField ( const fvPatch& p, const DimensionedField& iF, const dictionary& dict ) : fixedValueFvPatchField(p, iF, dict), mappedPatchFieldBase ( mappedPatchFieldBase::mapper(p, iF), *this, dict, *this // initial value for database operation ) {} template Foam::mappedFixedValueFvPatchField::mappedFixedValueFvPatchField ( const mappedFixedValueFvPatchField& ptf, const fvPatch& p, const DimensionedField& iF, const fvPatchFieldMapper& mapper ) : fixedValueFvPatchField(ptf, p, iF, mapper), mappedPatchFieldBase ( mappedPatchFieldBase::mapper(p, iF), *this, ptf ) {} template Foam::mappedFixedValueFvPatchField::mappedFixedValueFvPatchField ( const mappedFixedValueFvPatchField& ptf ) : fixedValueFvPatchField(ptf), mappedPatchFieldBase(ptf) {} template Foam::mappedFixedValueFvPatchField::mappedFixedValueFvPatchField ( const mappedFixedValueFvPatchField& ptf, const DimensionedField& iF ) : fixedValueFvPatchField(ptf, iF), mappedPatchFieldBase ( mappedPatchFieldBase::mapper(this->patch(), iF), *this, ptf ) {} // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // template void Foam::mappedFixedValueFvPatchField::updateCoeffs() { if (this->updated()) { return; } this->operator==(this->mappedField()); if (debug) { auto limits = gMinMax(*this); auto avg = gAverage(*this); Info<< "mapped on field:" << this->internalField().name() << " patch:" << this->patch().name() << " avg:" << avg << " min:" << limits.min() << " max:" << limits.max() << endl; } fixedValueFvPatchField::updateCoeffs(); } template void Foam::mappedFixedValueFvPatchField::write(Ostream& os) const { fvPatchField::write(os); mappedPatchFieldBase::write(os); fvPatchField::writeValueEntry(os); } // ************************************************************************* //