/* This file is part of the OpenLB library
*
* Copyright (C) 2006,2007 Orestis Malaspinas and Jonas Latt
* E-mail contact: info@openlb.net
* The most recent release of OpenLB can be downloaded at
*
*
* This program 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 2
* of the License, or (at your option) any later version.
*
* This program 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 this program; if not, write to the Free
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
* Boston, MA 02110-1301, USA.
*/
#ifndef INAMURO_BOUNDARY_3D_HH
#define INAMURO_BOUNDARY_3D_HH
#include "inamuroBoundary3D.h"
#include "inamuroNewtonRaphsonDynamics.h"
#include "inamuroNewtonRaphsonDynamics.hh"
#include "boundaryInstantiator3D.h"
#include "momentaOnBoundaries3D.h"
namespace olb {
template
class InamuroBoundaryManager3D {
public:
template static Momenta*
getVelocityBoundaryMomenta();
template static Dynamics*
getVelocityBoundaryDynamics(T omega, Momenta& momenta);
template static PostProcessorGenerator3D*
getVelocityBoundaryProcessor(int x0, int x1, int y0, int y1, int z0, int z1);
template static Momenta*
getPressureBoundaryMomenta();
template static Dynamics*
getPressureBoundaryDynamics(T omega, Momenta& momenta);
template static PostProcessorGenerator3D*
getPressureBoundaryProcessor(int x0, int x1, int y0, int y1, int z0, int z1);
template static PostProcessorGenerator3D*
getConvectionBoundaryProcessor(int x0, int x1, int y0, int y1, int z0, int z1, T* uAv = NULL);
template static Momenta*
getExternalVelocityEdgeMomenta();
template static Dynamics*
getExternalVelocityEdgeDynamics(T omega, Momenta& momenta);
template static PostProcessorGenerator3D*
getExternalVelocityEdgeProcessor(int x0, int x1, int y0, int y1, int z0, int z1);
template static Momenta*
getInternalVelocityEdgeMomenta();
template static Dynamics*
getInternalVelocityEdgeDynamics(T omega, Momenta& momenta);
template static PostProcessorGenerator3D*
getInternalVelocityEdgeProcessor(int x0, int x1, int y0, int y1, int z0, int z1);
template static Momenta*
getExternalVelocityCornerMomenta();
template static Dynamics*
getExternalVelocityCornerDynamics(T omega, Momenta& momenta);
template static PostProcessorGenerator3D*
getExternalVelocityCornerProcessor(int x, int y, int z);
template static Momenta*
getInternalVelocityCornerMomenta();
template static Dynamics*
getInternalVelocityCornerDynamics(T omega, Momenta& momenta);
template static PostProcessorGenerator3D*
getInternalVelocityCornerProcessor(int x, int y, int z);
};
////////// InamuroBoundaryManager3D /////////////////////////////////////////
template
template
Momenta*
InamuroBoundaryManager3D::getVelocityBoundaryMomenta()
{
return new BasicDirichletBM;
}
template
template
Dynamics* InamuroBoundaryManager3D::
getVelocityBoundaryDynamics(T omega, Momenta& momenta)
{
return new InamuroNewtonRaphsonDynamics(omega, momenta);
}
template
template
PostProcessorGenerator3D*
InamuroBoundaryManager3D::
getVelocityBoundaryProcessor(int x0, int x1, int y0, int y1, int z0, int z1)
{
return nullptr;
}
template
template
Momenta*
InamuroBoundaryManager3D::getPressureBoundaryMomenta()
{
return new BasicDirichletBM;
}
template
template
Dynamics* InamuroBoundaryManager3D::
getPressureBoundaryDynamics(T omega, Momenta& momenta)
{
return new InamuroNewtonRaphsonDynamics(omega, momenta);
}
template
template
PostProcessorGenerator3D*
InamuroBoundaryManager3D::
getPressureBoundaryProcessor(int x0, int x1, int y0, int y1, int z0, int z1)
{
return nullptr;
}
template
template
PostProcessorGenerator3D*
InamuroBoundaryManager3D::
getConvectionBoundaryProcessor(int x0, int x1, int y0, int y1, int z0, int z1, T* uAv)
{
return nullptr;
}
template
template
Momenta*
InamuroBoundaryManager3D::getExternalVelocityEdgeMomenta()
{
return new FixedVelocityBM;
}
template
template
Dynamics*
InamuroBoundaryManager3D::
getExternalVelocityEdgeDynamics(T omega, Momenta& momenta)
{
return new MixinDynamics(omega, momenta);
}
template
template
PostProcessorGenerator3D*
InamuroBoundaryManager3D::
getExternalVelocityEdgeProcessor(int x0, int x1, int y0, int y1, int z0, int z1)
{
return new OuterVelocityEdgeProcessorGenerator3D(x0,x1, y0,y1, z0,z1);
}
template
template
Momenta*
InamuroBoundaryManager3D::getInternalVelocityEdgeMomenta()
{
return new InnerEdgeVelBM3D;
}
template
template
Dynamics*
InamuroBoundaryManager3D::
getInternalVelocityEdgeDynamics(T omega, Momenta& momenta)
{
return new CombinedRLBdynamics(omega, momenta);
}
template
template
PostProcessorGenerator3D*
InamuroBoundaryManager3D::
getInternalVelocityEdgeProcessor(int x0, int x1, int y0, int y1, int z0, int z1)
{
return nullptr;
}
template
template
Momenta*
InamuroBoundaryManager3D::getExternalVelocityCornerMomenta()
{
return new FixedVelocityBM;
}
template
template
Dynamics*
InamuroBoundaryManager3D::
getExternalVelocityCornerDynamics(T omega, Momenta& momenta)
{
return new MixinDynamics(omega, momenta);
}
template
template
PostProcessorGenerator3D*
InamuroBoundaryManager3D::
getExternalVelocityCornerProcessor(int x, int y, int z)
{
return new OuterVelocityCornerProcessorGenerator3D (x,y,z);
}
template
template
Momenta*
InamuroBoundaryManager3D::getInternalVelocityCornerMomenta()
{
return new InnerCornerVelBM3D;
}
template
template
Dynamics*
InamuroBoundaryManager3D::
getInternalVelocityCornerDynamics(T omega, Momenta& momenta)
{
return new CombinedRLBdynamics(omega, momenta);
}
template
template
PostProcessorGenerator3D*
InamuroBoundaryManager3D::
getInternalVelocityCornerProcessor(int x, int y, int z)
{
return nullptr;
}
////////// Factory functions //////////////////////////////////////////////////
template
OnLatticeBoundaryCondition3D* createInamuroBoundaryCondition3D(BlockLatticeStructure3D& block)
{
return new BoundaryConditionInstantiator3D <
T, DESCRIPTOR,
InamuroBoundaryManager3D > (block);
}
} // namespace olb
#endif