Merge branch 'nextRelease' of ssh://turbo4.fsb.hr:2013/foam-extend into nextRelease

Merged with setFlux fix.
This commit is contained in:
Vanja Skuric 2016-04-12 10:30:36 +02:00
commit d870fbf964
16 changed files with 265 additions and 15 deletions

View file

@ -34,7 +34,7 @@
fvc::makeAbsolute(phi, U);
}
mesh.setFluxRequired(pcorr.name());
mesh.schemesDict().setFluxRequired(pcorr.name());
for(int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
{

View file

@ -26,7 +26,7 @@
phi = fvc::interpolate(U) & mesh.Sf();
mesh.setFluxRequired(pcorr.name());
mesh.schemesDict().setFluxRequired(pcorr.name());
for(int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
{

View file

@ -26,7 +26,7 @@
phi = fvc::interpolate(U) & mesh.Sf();
mesh.setFluxRequired(pcorr.name());
mesh.schemesDict().setFluxRequired(pcorr.name());
for(int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
{

View file

@ -36,7 +36,7 @@
immersedBoundaryAdjustPhi(phi, U);
adjustPhi(phi, U, pcorr);
mesh.setFluxRequired(pcorr.name());
mesh.schemesDict().setFluxRequired(pcorr.name());
for(int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
{

View file

@ -34,7 +34,7 @@
fvc::makeAbsolute(phi, U);
}
mesh.setFluxRequired(pcorr.name());
mesh.schemesDict().setFluxRequired(pcorr.name());
while (piso.correctNonOrthogonal())
{

View file

@ -24,7 +24,7 @@
pcorrTypes
);
mesh.setFluxRequired(pcorr.name());
mesh.schemesDict().setFluxRequired(pcorr.name());
while (piso.correctNonOrthogonal())
{

View file

@ -35,7 +35,7 @@
adjustPhi(phi, U, pcorr);
mesh.setFluxRequired(pcorr.name());
mesh.schemesDict().setFluxRequired(pcorr.name());
for(int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
{

View file

@ -42,7 +42,7 @@
adjustPhi(phi, U, pcorr);
mesh.setFluxRequired(pcorr.name());
mesh.schemesDict().setFluxRequired(pcorr.name());
for(int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
{

View file

@ -27,7 +27,7 @@
adjustPhi(phi, U, pcorr);
mesh.setFluxRequired(pcorr.name());
mesh.schemesDict().setFluxRequired(pcorr.name());
for(int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
{

View file

@ -34,7 +34,7 @@
adjustPhi(phi, U, pcorr);
mesh.setFluxRequired(pcorr.name());
mesh.schemesDict().setFluxRequired(pcorr.name());
for(int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
{

View file

@ -34,7 +34,7 @@
adjustPhi(phi, U, pcorr);
mesh.setFluxRequired(pcorr.name());
mesh.schemesDict().setFluxRequired(pcorr.name());
for(int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
{

View file

@ -365,6 +365,7 @@ $(snGradSchemes)/snGradScheme/snGradSchemes.C
$(snGradSchemes)/correctedSnGrad/correctedSnGrads.C
$(snGradSchemes)/limitedSnGrad/limitedSnGrads.C
$(snGradSchemes)/uncorrectedSnGrad/uncorrectedSnGrads.C
$(snGradSchemes)/orthogonalSnGrad/orthogonalSnGrads.C
$(snGradSchemes)/skewCorrectedSnGrad/skewCorrectedSnGrads.C
$(snGradSchemes)/fourthSnGrad/fourthSnGrads.C
/*

View file

@ -0,0 +1,76 @@
/*---------------------------------------------------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2011 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 <http://www.gnu.org/licenses/>.
Description
Simple central-difference snGrad scheme without non-orthogonal correction.
\*---------------------------------------------------------------------------*/
#include "orthogonalSnGrad.H"
#include "volFields.H"
#include "surfaceFields.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
namespace Foam
{
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
namespace fv
{
// * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * * //
template<class Type>
orthogonalSnGrad<Type>::~orthogonalSnGrad()
{}
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
template<class Type>
tmp<GeometricField<Type, fvsPatchField, surfaceMesh> >
orthogonalSnGrad<Type>::correction
(
const GeometricField<Type, fvPatchField, volMesh>&
) const
{
notImplemented
(
"orthogonalSnGrad<Type>::correction"
"(const GeometricField<Type, fvPatchField, volMesh>&)"
);
return tmp<GeometricField<Type, fvsPatchField, surfaceMesh> >(NULL);
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
} // End namespace fv
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
} // End namespace Foam
// ************************************************************************* //

View file

@ -0,0 +1,133 @@
/*---------------------------------------------------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2011 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 <http://www.gnu.org/licenses/>.
Class
Foam::fv::orthogonalSnGrad
Description
Simple central-difference snGrad scheme without non-orthogonal correction.
SourceFiles
orthogonalSnGrad.C
\*---------------------------------------------------------------------------*/
#ifndef orthogonalSnGrad_H
#define orthogonalSnGrad_H
#include "snGradScheme.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
namespace Foam
{
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
namespace fv
{
/*---------------------------------------------------------------------------*\
Class orthogonalSnGrad Declaration
\*---------------------------------------------------------------------------*/
template<class Type>
class orthogonalSnGrad
:
public snGradScheme<Type>
{
// Private Member Functions
//- Disallow default bitwise assignment
void operator=(const orthogonalSnGrad&);
public:
//- Runtime type information
TypeName("orthogonal");
// Constructors
//- Construct from mesh
orthogonalSnGrad(const fvMesh& mesh)
:
snGradScheme<Type>(mesh)
{}
//- Construct from mesh and data stream
orthogonalSnGrad(const fvMesh& mesh, Istream&)
:
snGradScheme<Type>(mesh)
{}
//- Destructor
virtual ~orthogonalSnGrad();
// Member Functions
//- Return the interpolation weighting factors for the given field
virtual tmp<surfaceScalarField> deltaCoeffs
(
const GeometricField<Type, fvPatchField, volMesh>&
) const
{
return this->mesh().deltaCoeffs();
}
//- Return true if this scheme uses an explicit correction
virtual bool corrected() const
{
return false;
}
//- Return the explicit correction to the orthogonalSnGrad
// for the given field
virtual tmp<GeometricField<Type, fvsPatchField, surfaceMesh> >
correction(const GeometricField<Type, fvPatchField, volMesh>&) const;
};
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
} // End namespace fv
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
} // End namespace Foam
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
#ifdef NoRepository
# include "orthogonalSnGrad.C"
#endif
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
#endif
// ************************************************************************* //

View file

@ -0,0 +1,42 @@
/*---------------------------------------------------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2011-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 <http://www.gnu.org/licenses/>.
Description
Simple central-difference snGrad scheme without non-orthogonal correction.
\*---------------------------------------------------------------------------*/
#include "orthogonalSnGrad.H"
#include "fvMesh.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
namespace Foam
{
namespace fv
{
makeSnGradScheme(orthogonalSnGrad)
}
}
// ************************************************************************* //

View file

@ -33,9 +33,7 @@ divSchemes
laplacianSchemes
{
default none;
laplacian(nu,U) Gauss linear corrected;
laplacian((1|A(U)),p) Gauss linear corrected;
default Gauss linear orthogonal;
}
interpolationSchemes
@ -46,7 +44,7 @@ interpolationSchemes
snGradSchemes
{
default corrected;
default orthogonal;
}
// ************************************************************************* //