36 #ifndef StochasticCollisionModel_H
37 #define StochasticCollisionModel_H
53 template<
class CloudType>
61 virtual void collide(
typename CloudType::parcelType::trackingData& td) = 0;
118 void update(
typename CloudType::parcelType::trackingData& td);
128 #define makeStochasticCollisionModel(CloudType) \
130 typedef Foam::CloudType::momentumCloudType CloudType##momentumCloudType; \
132 defineNamedTemplateTypeNameAndDebug \
134 Foam::StochasticCollisionModel<CloudType##momentumCloudType>, \
139 defineTemplateRunTimeSelectionTable \
141 StochasticCollisionModel<CloudType##momentumCloudType>, \
147 #define makeStochasticCollisionModelType(SS, CloudType) \
149 typedef Foam::CloudType::momentumCloudType CloudType##momentumCloudType; \
151 defineNamedTemplateTypeNameAndDebug \
153 Foam::SS<CloudType##momentumCloudType>, \
157 Foam::StochasticCollisionModel<CloudType##momentumCloudType>:: \
158 adddictionaryConstructorToTable<Foam::SS<CloudType##momentumCloudType>>\
159 add##SS##CloudType##momentumCloudType##ConstructorToTable_;
Base class for cloud sub-models.
const CloudType & owner() const
Return const access to the owner cloud.
Templated base class for dsmc cloud.
Templated stochastic collision model class.
StochasticCollisionModel(CloudType &owner)
Construct null from owner.
void update(typename CloudType::parcelType::trackingData &td)
Update the model.
declareRunTimeSelectionTable(autoPtr, StochasticCollisionModel, dictionary,(const dictionary &dict, CloudType &owner),(dict, owner))
Declare runtime constructor selection table.
virtual ~StochasticCollisionModel()
Destructor.
virtual autoPtr< StochasticCollisionModel< CloudType > > clone() const =0
Construct and return a clone.
static autoPtr< StochasticCollisionModel< CloudType > > New(const dictionary &dict, CloudType &owner)
Selector.
TypeName("collisionModel")
Runtime type information.
virtual void collide(typename CloudType::parcelType::trackingData &td)=0
Main collision routine.
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...
A list of keywords followed by any number of values (e.g. words and numbers) or sub-dictionaries.
const dictionary & dict() const
Return const access to the cloud dictionary.
A class for handling words, derived from string.
fileType type(const fileName &, const bool checkVariants=true, const bool followLink=true)
Return the file type: directory or file.
Macros to ease declaration of run-time selection tables.