Adds overset discretisation to selected physics: - diffusion : overLaplacianDyMFoam - incompressible steady : overSimpleFoam - incompressible transient : overPimpleDyMFoam - compressible transient: overRhoPimpleDyMFoam - two-phase VOF: overInterDyMFoam The overset method chosen is a parallel, fully implicit implementation whereby the interpolation (from donor to acceptor) is inserted as an adapted discretisation on the donor cells, such that the resulting matrix can be solved using the standard linear solvers. Above solvers come with a set of tutorials, showing how to create and set-up simple simulations from scratch.
167 lines
4.6 KiB
C++
167 lines
4.6 KiB
C++
/*---------------------------------------------------------------------------*\
|
|
========= |
|
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
|
\\ / O peration |
|
|
\\ / A nd | Copyright (C) 2011-2013 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::cyclicGAMGInterfaceField
|
|
|
|
Description
|
|
GAMG agglomerated cyclic interface field.
|
|
|
|
SourceFiles
|
|
cyclicGAMGInterfaceField.C
|
|
|
|
\*---------------------------------------------------------------------------*/
|
|
|
|
#ifndef cyclicGAMGInterfaceField_H
|
|
#define cyclicGAMGInterfaceField_H
|
|
|
|
#include "GAMGInterfaceField.H"
|
|
#include "cyclicGAMGInterface.H"
|
|
#include "cyclicLduInterfaceField.H"
|
|
|
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
|
|
|
namespace Foam
|
|
{
|
|
|
|
/*---------------------------------------------------------------------------*\
|
|
Class cyclicGAMGInterfaceField Declaration
|
|
\*---------------------------------------------------------------------------*/
|
|
|
|
class cyclicGAMGInterfaceField
|
|
:
|
|
public GAMGInterfaceField,
|
|
virtual public cyclicLduInterfaceField
|
|
{
|
|
// Private data
|
|
|
|
//- Local reference cast into the cyclic interface
|
|
const cyclicGAMGInterface& cyclicInterface_;
|
|
|
|
//- Is the transform required
|
|
bool doTransform_;
|
|
|
|
//- Rank of component for transformation
|
|
int rank_;
|
|
|
|
|
|
// Private Member Functions
|
|
|
|
//- Disallow default bitwise copy construct
|
|
cyclicGAMGInterfaceField(const cyclicGAMGInterfaceField&);
|
|
|
|
//- Disallow default bitwise assignment
|
|
void operator=(const cyclicGAMGInterfaceField&);
|
|
|
|
|
|
public:
|
|
|
|
//- Runtime type information
|
|
TypeName("cyclic");
|
|
|
|
|
|
// Constructors
|
|
|
|
//- Construct from GAMG interface and fine level interface field
|
|
cyclicGAMGInterfaceField
|
|
(
|
|
const GAMGInterface& GAMGCp,
|
|
const lduInterfaceField& fineInterfaceField
|
|
);
|
|
|
|
//- Construct from GAMG interface and fine level interface field
|
|
cyclicGAMGInterfaceField
|
|
(
|
|
const GAMGInterface& GAMGCp,
|
|
const bool doTransform,
|
|
const int rank
|
|
);
|
|
|
|
|
|
//- Destructor
|
|
virtual ~cyclicGAMGInterfaceField();
|
|
|
|
|
|
// Member Functions
|
|
|
|
// Access
|
|
|
|
//- Return size
|
|
label size() const
|
|
{
|
|
return cyclicInterface_.size();
|
|
}
|
|
|
|
|
|
//- Cyclic interface functions
|
|
|
|
//- Does the interface field perform the transfromation
|
|
virtual bool doTransform() const
|
|
{
|
|
return doTransform_;
|
|
}
|
|
|
|
//- Return face transformation tensor
|
|
virtual const tensorField& forwardT() const
|
|
{
|
|
return cyclicInterface_.forwardT();
|
|
}
|
|
|
|
//- Return neighbour-cell transformation tensor
|
|
virtual const tensorField& reverseT() const
|
|
{
|
|
return cyclicInterface_.reverseT();
|
|
}
|
|
|
|
//- Return rank of component for transform
|
|
virtual int rank() const
|
|
{
|
|
return rank_;
|
|
}
|
|
|
|
|
|
// Interface matrix update
|
|
|
|
//- Update result field based on interface functionality
|
|
virtual void updateInterfaceMatrix
|
|
(
|
|
scalarField& result,
|
|
const bool add,
|
|
const scalarField& psiInternal,
|
|
const scalarField& coeffs,
|
|
const direction cmpt,
|
|
const Pstream::commsTypes commsType
|
|
) const;
|
|
};
|
|
|
|
|
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
|
|
|
} // End namespace Foam
|
|
|
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
|
|
|
#endif
|
|
|
|
// ************************************************************************* //
|