52#ifndef PatchInjection_H
53#define PatchInjection_H
63class distributionModel;
69template<
class CloudType>
99 const label parcelsPerSecond_;
115 label currentParceli_;
163 virtual scalar
timeEnd()
const;
169 virtual scalar
volumeToInject(
const scalar time0,
const scalar time1);
181 const label nParcels,
192 const label nParcels,
const CloudType & owner() const
Return const access to the owner cloud.
Templated base class for dsmc cloud.
ParcelType parcelType
Type of parcel the cloud was instantiated for.
Enum is a wrapper around a list of names/values that represent particular enumeration (or int) values...
Templated injection model class.
TypeName("patchInjection")
Runtime type information.
velocityType
Velocity type enumeration.
@ vtFixedValue
User supplied fixed value.
@ vtPatchValue
Patch face values.
@ vtZeroGradient
Patch internal cell values.
virtual autoPtr< InjectionModel< CloudType > > clone() const
Construct and return a clone.
virtual scalar volumeToInject(const scalar time0, const scalar time1)
Volume of parcels to introduce relative to SOI.
virtual ~PatchInjection()=default
Destructor.
virtual label parcelsToInject(const scalar time0, const scalar time1)
Number of parcels to introduce relative to SOI.
virtual void setPositionAndCell(const label parcelI, const label nParcels, const scalar time, vector &position, label &cellOwner, label &tetFacei, label &tetPti)
Set the injection position and owner cell, tetFace and tetPt.
virtual bool validInjection(const label parcelI)
Return flag to identify whether or not injection of parcelI is.
virtual void setProperties(const label parcelI, const label nParcels, const scalar time, typename CloudType::parcelType &parcel)
Set the parcel properties.
static const Enum< velocityType > velocityTypeNames_
Velocity type names.
virtual void updateMesh()
Set injector locations when mesh is updated.
virtual bool fullyDescribed() const
Flag to identify whether model fully describes the parcel.
virtual scalar timeEnd() const
Return the end-of-injection time.
Pointer management similar to std::unique_ptr, with some additional methods and type checking.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
void updateMesh()
Update for new mesh topology.
label setPositionAndCell(const fvMesh &mesh, const scalar fraction01, Random &rnd, vector &position, label &cellOwner, label &tetFacei, label &tetPti)
Set the injection position and owner cell, tetFace and tetPt.
const dictionary & dict() const
Return const access to the cloud dictionary.
const word & modelName() const
Return const access to the name of the sub-model.
A class for handling words, derived from Foam::string.
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.