aslLBGKBC.h
Go to the documentation of this file.
/*
* Advanced Simulation Library <http://asl.org.il>
*
* Copyright 2015 Avtech Scientific <http://avtechscientific.com>
*
*
* This file is part of Advanced Simulation Library (ASL).
*
* ASL is free software: you can redistribute it and/or modify it
* under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, version 3 of the License.
*
* ASL 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 Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with ASL. If not, see <http://www.gnu.org/licenses/>.
*
*/
#ifndef ASLLBGKBC_H
#define ASLLBGKBC_H
#include "aslBCond.h"
#include "acl/aclMath/aclVectorOfElementsDef.h"
namespace acl{
class Kernel;
typedef std::shared_ptr<acl::Kernel> SPKernel;
class KernelMerger;
typedef std::shared_ptr<acl::KernelMerger> SPKernelMerger;
}
namespace asl
{
class LBGK;
typedef std::shared_ptr<LBGK> SPLBGK;
class PositionFunction;
typedef std::shared_ptr<PositionFunction> SPPositionFunction;
class BCLBGKCommon:public BCond
{
protected:
SPLBGK num;
std::vector<acl::SPKernel> kernels;
acl::SPKernelMerger km;
AVec<int> directionGroupsShifts;
AVec<int> directionGroupsSizes;
void sortDirections();
public:
BCLBGKCommon(SPLBGK nm);
virtual void execute();
};
class BCNoSlip: public BCLBGKCommon
{
public:
BCNoSlip(SPLBGK nm);
virtual void init();
};
class BCConstantPressure: public BCLBGKCommon
{
protected:
acl::VectorOfElements pressure;
public:
BCConstantPressure(SPLBGK nm, const acl::VectorOfElements & p);
virtual void init();
};
class BCConstantVelocity: public BCLBGKCommon
{
protected:
acl::VectorOfElements velocity;
public:
BCConstantVelocity(SPLBGK nm, const acl::VectorOfElements & v);
virtual void init();
};
class BCConstantPressureVelocity: public BCLBGKCommon
{
protected:
acl::VectorOfElements pressure;
acl::VectorOfElements velocity;
public:
BCConstantPressureVelocity(SPLBGK nm,
const acl::VectorOfElements & p,
const acl::VectorOfElements & v);
virtual void init();
};
class BCNoSlipMap:public BCondWithMap
{
protected:
std::unique_ptr<acl::Kernel> kernel;
SPLBGK num;
public:
BCNoSlipMap(SPLBGK nm, SPAbstractDataWithGhostNodes map);
~BCNoSlipMap();
virtual void execute();
virtual void init();
};
class BCVelocityMap:public BCondWithMap
{
protected:
std::unique_ptr<acl::Kernel> kernel;
SPLBGK num;
SPPositionFunction velocity;
public:
BCVelocityMap(SPLBGK nm,
SPPositionFunction v,
SPAbstractDataWithGhostNodes map);
BCVelocityMap(SPLBGK nm,
SPPositionFunction v,
SPAbstractDataWithGhostNodes map,
SPAbstractDataWithGhostNodes computationalDomain);
~BCVelocityMap();
virtual void execute();
virtual void init();
};
class BCConstantPressureVelocityMap:public BCondWithMap
{
protected:
std::unique_ptr<acl::Kernel> kernel;
SPLBGK num;
acl::VectorOfElements pressure;
acl::VectorOfElements velocity;
public:
BCConstantPressureVelocityMap(SPLBGK nm,
acl::VectorOfElements p,
SPAbstractDataWithGhostNodes map);
BCConstantPressureVelocityMap(SPLBGK nm,
acl::VectorOfElements p,
acl::VectorOfElements v,
SPAbstractDataWithGhostNodes map);
~BCConstantPressureVelocityMap();
virtual void execute();
virtual void init();
};
class BCTransportLimitedDepositionMap:public BCondWithMap
{
protected:
std::unique_ptr<acl::Kernel> kernel;
SPLBGK num;
acl::VectorOfElements p0;
acl::VectorOfElements limitingFactor;
public:
BCTransportLimitedDepositionMap(SPLBGK nm,
acl::VectorOfElements p,
acl::VectorOfElements lF,
SPAbstractDataWithGhostNodes map);
~BCTransportLimitedDepositionMap();
virtual void execute();
virtual void init();
};
class BCKineticsLimitedDepositionMap:public BCondWithMap
{
protected:
std::unique_ptr<acl::Kernel> kernel;
SPLBGK num;
acl::VectorOfElements p0;
acl::VectorOfElements limitingFactor;
acl::VectorOfElements beta;
public:
BCKineticsLimitedDepositionMap(SPLBGK nm,
acl::VectorOfElements p,
acl::VectorOfElements lF,
acl::VectorOfElements b,
SPAbstractDataWithGhostNodes map);
~BCKineticsLimitedDepositionMap();
virtual void execute();
virtual void init();
};
class ComputeSurfaceFluxMap:public BCondWithMap
{
protected:
std::unique_ptr<acl::Kernel> kernel;
SPLBGK num;
SPDataWithGhostNodesACLData fluxField;
public:
ComputeSurfaceFluxMap(SPLBGK nm,
SPDataWithGhostNodesACLData fF,
SPAbstractDataWithGhostNodes map);
~ComputeSurfaceFluxMap();
virtual void execute();
virtual void init();
};
class ComputeSurfaceForceMap:public BCondWithMap
{
protected:
std::unique_ptr<acl::Kernel> kernel;
SPLBGK num;
SPDataWithGhostNodesACLData forceField;
public:
ComputeSurfaceForceMap(SPLBGK nm,
SPDataWithGhostNodesACLData fF,
SPAbstractDataWithGhostNodes map);
~ComputeSurfaceForceMap();
virtual void execute();
virtual void init();
};
SPBCond generateBCNoSlip(SPLBGK nm, const std::vector<SlicesNames> & sl);
SPBCond generateBCConstantVelocity(SPLBGK nm, AVec<> v, const std::vector<SlicesNames> & sl);
SPBCond generateBCConstantPressure(SPLBGK nm, double p, const std::vector<SlicesNames> & sl);
SPBCond generateBCConstantPressureVelocity(SPLBGK nm,
double p,
AVec<> v,
const std::vector<SlicesNames> & sl);
SPNumMethod generateBCConstantPressure(SPLBGK nm, double p, SPAbstractDataWithGhostNodes map);
SPNumMethod generateBCConstantPressureVelocity(SPLBGK nm,
double p,
AVec<> v,
SPAbstractDataWithGhostNodes map);
SPNumMethod generateBCNoSlip(SPLBGK nm, SPAbstractDataWithGhostNodes map);
SPNumMethod generateBCNoSlipVel(SPLBGK nmU, SPAbstractDataWithGhostNodes map);
SPNumMethod generateBCNoSlipRho(SPLBGK nmU, SPAbstractDataWithGhostNodes map);
SPNumMethod generateBCVelocity(SPLBGK nm,
SPPositionFunction v,
SPAbstractDataWithGhostNodes map);
SPNumMethod generateBCVelocity(SPLBGK nm,
SPPositionFunction v,
SPAbstractDataWithGhostNodes map,
SPAbstractDataWithGhostNodes computationalDomain);
SPNumMethod generateBCVelocityVel(SPLBGK nm,
SPPositionFunction v,
SPAbstractDataWithGhostNodes map);
SPNumMethod generateBCTransportLimitedDeposition(SPLBGK nm,
double p0,
double limitingFactor,
SPAbstractDataWithGhostNodes map);
SPNumMethod generateBCKineticsLimitedDeposition(SPLBGK nm,
double beta,
double p0,
double limitingFactor,
SPAbstractDataWithGhostNodes map);
SPNumMethod generateComputeSurfaceFlux(SPLBGK nm,
SPDataWithGhostNodesACLData fF,
SPAbstractDataWithGhostNodes map);
SPNumMethod generateComputeSurfaceForce(SPLBGK nm,
SPDataWithGhostNodesACLData fF,
SPAbstractDataWithGhostNodes map);
} //asl
#endif //ASLBGKBC_H
acl::VectorOfElements
The class represents several Element.
Definition: aclVectorOfElementsDef.h:92
asl::AVec
Definition: aslVectorsDynamicLength.h:40
asl::BCConstantPressure
Bondary condition corresponding an in- or outflow boundary conditions with a given pressure.
Definition: aslLBGKBC.h:80
asl::BCConstantPressure::pressure
acl::VectorOfElements pressure
Definition: aslLBGKBC.h:82
asl::BCConstantPressure::BCConstantPressure
BCConstantPressure(SPLBGK nm, const acl::VectorOfElements &p)
asl::BCConstantPressure::init
virtual void init()
Builds the necesery internal data and kernels.
asl::BCConstantPressureVelocity
Bondary condition corresponding wall with given velocity for uncompressible.
Definition: aslLBGKBC.h:117
asl::BCConstantPressureVelocity::BCConstantPressureVelocity
BCConstantPressureVelocity(SPLBGK nm, const acl::VectorOfElements &p, const acl::VectorOfElements &v)
asl::BCConstantPressureVelocity::init
virtual void init()
Builds the necesery internal data and kernels.
asl::BCConstantPressureVelocity::velocity
acl::VectorOfElements velocity
Definition: aslLBGKBC.h:120
asl::BCConstantPressureVelocity::pressure
acl::VectorOfElements pressure
Definition: aslLBGKBC.h:119
asl::BCConstantPressureVelocityMap
Definition: aslLBGKBC.h:173
asl::BCConstantPressureVelocityMap::execute
virtual void execute()
Executes the numerical procedure.
asl::BCConstantPressureVelocityMap::kernel
std::unique_ptr< acl::Kernel > kernel
Definition: aslLBGKBC.h:175
asl::BCConstantPressureVelocityMap::pressure
acl::VectorOfElements pressure
Definition: aslLBGKBC.h:177
asl::BCConstantPressureVelocityMap::BCConstantPressureVelocityMap
BCConstantPressureVelocityMap(SPLBGK nm, acl::VectorOfElements p, SPAbstractDataWithGhostNodes map)
asl::BCConstantPressureVelocityMap::velocity
acl::VectorOfElements velocity
Definition: aslLBGKBC.h:178
asl::BCConstantPressureVelocityMap::BCConstantPressureVelocityMap
BCConstantPressureVelocityMap(SPLBGK nm, acl::VectorOfElements p, acl::VectorOfElements v, SPAbstractDataWithGhostNodes map)
asl::BCConstantPressureVelocityMap::num
SPLBGK num
Definition: aslLBGKBC.h:176
asl::BCConstantPressureVelocityMap::init
virtual void init()
Builds the necesery internal data and kernels.
asl::BCConstantPressureVelocityMap::~BCConstantPressureVelocityMap
~BCConstantPressureVelocityMap()
asl::BCConstantVelocity
Bondary condition corresponding wall with given velocity for uncompressible.
Definition: aslLBGKBC.h:100
asl::BCConstantVelocity::velocity
acl::VectorOfElements velocity
Definition: aslLBGKBC.h:102
asl::BCConstantVelocity::init
virtual void init()
Builds the necesery internal data and kernels.
asl::BCConstantVelocity::BCConstantVelocity
BCConstantVelocity(SPLBGK nm, const acl::VectorOfElements &v)
asl::BCKineticsLimitedDepositionMap
Set outflux corresponding to kinetics and transport limitations of the deposition rate.
Definition: aslLBGKBC.h:225
asl::BCKineticsLimitedDepositionMap::p0
acl::VectorOfElements p0
Definition: aslLBGKBC.h:229
asl::BCKineticsLimitedDepositionMap::beta
acl::VectorOfElements beta
Definition: aslLBGKBC.h:231
asl::BCKineticsLimitedDepositionMap::~BCKineticsLimitedDepositionMap
~BCKineticsLimitedDepositionMap()
asl::BCKineticsLimitedDepositionMap::BCKineticsLimitedDepositionMap
BCKineticsLimitedDepositionMap(SPLBGK nm, acl::VectorOfElements p, acl::VectorOfElements lF, acl::VectorOfElements b, SPAbstractDataWithGhostNodes map)
asl::BCKineticsLimitedDepositionMap::kernel
std::unique_ptr< acl::Kernel > kernel
Definition: aslLBGKBC.h:227
asl::BCKineticsLimitedDepositionMap::num
SPLBGK num
Definition: aslLBGKBC.h:228
asl::BCKineticsLimitedDepositionMap::execute
virtual void execute()
Executes the numerical procedure.
asl::BCKineticsLimitedDepositionMap::limitingFactor
acl::VectorOfElements limitingFactor
Definition: aslLBGKBC.h:230
asl::BCKineticsLimitedDepositionMap::init
virtual void init()
Builds the necesery internal data and kernels.
asl::BCLBGKCommon
Definition: aslLBGKBC.h:46
asl::BCLBGKCommon::kernels
std::vector< acl::SPKernel > kernels
Definition: aslLBGKBC.h:49
asl::BCLBGKCommon::directionGroupsShifts
AVec< int > directionGroupsShifts
Definition: aslLBGKBC.h:52
asl::BCLBGKCommon::BCLBGKCommon
BCLBGKCommon(SPLBGK nm)
asl::BCLBGKCommon::execute
virtual void execute()
Executes the numerical procedure.
asl::BCLBGKCommon::sortDirections
void sortDirections()
asl::BCLBGKCommon::num
SPLBGK num
Definition: aslLBGKBC.h:48
asl::BCLBGKCommon::km
acl::SPKernelMerger km
Definition: aslLBGKBC.h:50
asl::BCLBGKCommon::directionGroupsSizes
AVec< int > directionGroupsSizes
Definition: aslLBGKBC.h:53
asl::BCNoSlip
Bondary condition corresponding to a rigid wall ( )
Definition: aslLBGKBC.h:68
asl::BCNoSlip::init
virtual void init()
Builds the necesery internal data and kernels.
asl::BCNoSlip::BCNoSlip
BCNoSlip(SPLBGK nm)
asl::BCNoSlipMap
Bondary condition corresponding to a rigid wall ( )
Definition: aslLBGKBC.h:134
asl::BCNoSlipMap::execute
virtual void execute()
Executes the numerical procedure.
asl::BCNoSlipMap::BCNoSlipMap
BCNoSlipMap(SPLBGK nm, SPAbstractDataWithGhostNodes map)
asl::BCNoSlipMap::num
SPLBGK num
Definition: aslLBGKBC.h:137
asl::BCNoSlipMap::~BCNoSlipMap
~BCNoSlipMap()
asl::BCNoSlipMap::init
virtual void init()
Builds the necesery internal data and kernels.
asl::BCNoSlipMap::kernel
std::unique_ptr< acl::Kernel > kernel
Definition: aslLBGKBC.h:136
asl::BCTransportLimitedDepositionMap
Set outflux corresponding to transport limitation of the deposition rate.
Definition: aslLBGKBC.h:201
asl::BCTransportLimitedDepositionMap::num
SPLBGK num
Definition: aslLBGKBC.h:204
asl::BCTransportLimitedDepositionMap::kernel
std::unique_ptr< acl::Kernel > kernel
Definition: aslLBGKBC.h:203
asl::BCTransportLimitedDepositionMap::init
virtual void init()
Builds the necesery internal data and kernels.
asl::BCTransportLimitedDepositionMap::execute
virtual void execute()
Executes the numerical procedure.
asl::BCTransportLimitedDepositionMap::BCTransportLimitedDepositionMap
BCTransportLimitedDepositionMap(SPLBGK nm, acl::VectorOfElements p, acl::VectorOfElements lF, SPAbstractDataWithGhostNodes map)
asl::BCTransportLimitedDepositionMap::limitingFactor
acl::VectorOfElements limitingFactor
Definition: aslLBGKBC.h:206
asl::BCTransportLimitedDepositionMap::~BCTransportLimitedDepositionMap
~BCTransportLimitedDepositionMap()
asl::BCTransportLimitedDepositionMap::p0
acl::VectorOfElements p0
Definition: aslLBGKBC.h:205
asl::BCVelocityMap
Definition: aslLBGKBC.h:150
asl::BCVelocityMap::init
virtual void init()
Builds the necesery internal data and kernels.
asl::BCVelocityMap::BCVelocityMap
BCVelocityMap(SPLBGK nm, SPPositionFunction v, SPAbstractDataWithGhostNodes map, SPAbstractDataWithGhostNodes computationalDomain)
asl::BCVelocityMap::~BCVelocityMap
~BCVelocityMap()
asl::BCVelocityMap::BCVelocityMap
BCVelocityMap(SPLBGK nm, SPPositionFunction v, SPAbstractDataWithGhostNodes map)
asl::BCVelocityMap::kernel
std::unique_ptr< acl::Kernel > kernel
Definition: aslLBGKBC.h:152
asl::BCVelocityMap::velocity
SPPositionFunction velocity
Definition: aslLBGKBC.h:154
asl::BCVelocityMap::num
SPLBGK num
Definition: aslLBGKBC.h:153
asl::BCVelocityMap::execute
virtual void execute()
Executes the numerical procedure.
asl::BCondWithMap
Virtual class describes general interface for boundary conditions.
Definition: aslBCond.h:101
asl::BCondWithMap::map
SPAbstractDataWithGhostNodes map
boundary description for the particular BC
Definition: aslBCond.h:111
asl::BCondWithMap::computationalDomain
SPAbstractDataWithGhostNodes computationalDomain
Computational domain which contains all boundaries and the particular boundary as well.
Definition: aslBCond.h:114
asl::ComputeSurfaceFluxMap
Definition: aslLBGKBC.h:248
asl::ComputeSurfaceFluxMap::ComputeSurfaceFluxMap
ComputeSurfaceFluxMap(SPLBGK nm, SPDataWithGhostNodesACLData fF, SPAbstractDataWithGhostNodes map)
asl::ComputeSurfaceFluxMap::fluxField
SPDataWithGhostNodesACLData fluxField
Definition: aslLBGKBC.h:252
asl::ComputeSurfaceFluxMap::execute
virtual void execute()
Executes the numerical procedure.
asl::ComputeSurfaceFluxMap::init
virtual void init()
Builds the necesery internal data and kernels.
asl::ComputeSurfaceFluxMap::~ComputeSurfaceFluxMap
~ComputeSurfaceFluxMap()
asl::ComputeSurfaceFluxMap::num
SPLBGK num
Definition: aslLBGKBC.h:251
asl::ComputeSurfaceFluxMap::kernel
std::unique_ptr< acl::Kernel > kernel
Definition: aslLBGKBC.h:250
asl::ComputeSurfaceForceMap
Definition: aslLBGKBC.h:266
asl::ComputeSurfaceForceMap::num
SPLBGK num
Definition: aslLBGKBC.h:269
asl::ComputeSurfaceForceMap::kernel
std::unique_ptr< acl::Kernel > kernel
Definition: aslLBGKBC.h:268
asl::ComputeSurfaceForceMap::~ComputeSurfaceForceMap
~ComputeSurfaceForceMap()
asl::ComputeSurfaceForceMap::forceField
SPDataWithGhostNodesACLData forceField
Definition: aslLBGKBC.h:270
asl::ComputeSurfaceForceMap::execute
virtual void execute()
Executes the numerical procedure.
asl::ComputeSurfaceForceMap::init
virtual void init()
Builds the necesery internal data and kernels.
asl::ComputeSurfaceForceMap::ComputeSurfaceForceMap
ComputeSurfaceForceMap(SPLBGK nm, SPDataWithGhostNodesACLData fF, SPAbstractDataWithGhostNodes map)
asl::SPPositionFunction
std::shared_ptr< PositionFunction > SPPositionFunction
Definition: aslPositionFunction.h:58
asl::generateComputeSurfaceForce
SPNumMethod generateComputeSurfaceForce(SPLBGK nm, SPDataWithGhostNodesACLData fF, SPAbstractDataWithGhostNodes map)
asl::generateBCConstantVelocity
SPBCond generateBCConstantVelocity(SPLBGK nm, AVec<> v, const std::vector< SlicesNames > &sl)
asl::generateComputeSurfaceFlux
SPNumMethod generateComputeSurfaceFlux(SPLBGK nm, SPDataWithGhostNodesACLData fF, SPAbstractDataWithGhostNodes map)
asl::generateBCConstantPressure
SPBCond generateBCConstantPressure(SPLBGK nm, double p, const std::vector< SlicesNames > &sl)
asl::generateBCVelocityVel
SPNumMethod generateBCVelocityVel(SPLBGK nm, SPPositionFunction v, SPAbstractDataWithGhostNodes map)
asl::generateBCNoSlipVel
SPNumMethod generateBCNoSlipVel(SPLBGK nmU, SPAbstractDataWithGhostNodes map)
asl::generateBCTransportLimitedDeposition
SPNumMethod generateBCTransportLimitedDeposition(SPLBGK nm, double p0, double limitingFactor, SPAbstractDataWithGhostNodes map)
asl::generateBCConstantPressureVelocity
SPBCond generateBCConstantPressureVelocity(SPLBGK nm, double p, AVec<> v, const std::vector< SlicesNames > &sl)
asl::generateBCKineticsLimitedDeposition
SPNumMethod generateBCKineticsLimitedDeposition(SPLBGK nm, double beta, double p0, double limitingFactor, SPAbstractDataWithGhostNodes map)
asl::generateBCVelocity
SPNumMethod generateBCVelocity(SPLBGK nm, SPPositionFunction v, SPAbstractDataWithGhostNodes map)
asl::generateBCNoSlip
SPBCond generateBCNoSlip(SPLBGK nm, const std::vector< SlicesNames > &sl)
asl::generateBCNoSlipRho
SPNumMethod generateBCNoSlipRho(SPLBGK nmU, SPAbstractDataWithGhostNodes map)
acl
Advanced Computational Language.
Definition: acl.h:41
acl::map
std::shared_ptr< T > map(ElementData m)
Definition: aclMemBlock.h:68
acl::SPKernelMerger
std::shared_ptr< acl::KernelMerger > SPKernelMerger
Definition: aslLBGKBC.h:33
acl::SPKernel
std::shared_ptr< Kernel > SPKernel
Definition: aclKernelMerger.h:34
asl
Advanced Simulation Library.
Definition: aslDataInc.h:31
asl::SPAbstractDataWithGhostNodes
std::shared_ptr< AbstractDataWithGhostNodes > SPAbstractDataWithGhostNodes
Definition: aslGenerators.h:50
asl::SPNumMethod
std::shared_ptr< NumMethod > SPNumMethod
Definition: aslNumMethod.h:44
asl::SPBCond
std::shared_ptr< BCond > SPBCond
Definition: aslBCond.h:88
asl::SPDataWithGhostNodesACLData
std::shared_ptr< DataWithGhostNodesACLData > SPDataWithGhostNodesACLData
Definition: aslGenerators.h:47
asl::SPLBGK
std::shared_ptr< LBGK > SPLBGK
Definition: aslLBGK.h:133
aslBCond.h