77 #ifndef InjectedParticleDistributionInjection_H 78 #define InjectedParticleDistributionInjection_H 94 template<
class CloudType>
165 TypeName(
"injectedParticleDistributionInjection");
210 virtual scalar
volumeToInject(
const scalar time0,
const scalar time1);
219 const label nParcels,
231 const label nParcels,
void initialise()
Initialise injectors.
virtual ~InjectedParticleDistributionInjection()
Destructor.
A list of keyword definitions, which are a keyword followed by a number of values (eg...
Templated injection model class.
vector positionOffset_
Position offset to apply to input positions.
void info()
Write injection info.
virtual bool validInjection(const label parcelI)
Return flag to identify whether or not injection of parcelI is.
A simple wrapper around bool so that it can be read as a word: true/false, on/off, yes/no, any/none. Also accepts 0/1 as a string and shortcuts t/f, y/n.
scalar timeEnd() const
Return the end-of-injection time.
virtual scalar volumeToInject(const scalar time0, const scalar time1)
Volume of parcels to introduce relative to SOI.
virtual void updateMesh()
Set injector locations when mesh is updated.
const word & modelName() const
Return const access to the name of the sub-model.
scalarList startTime_
List of start time per injector.
const dictionary & dict() const
Return const access to the cloud dictionary.
scalarList volumeFlowRate_
List of volume flow rate per injector [m3/s].
virtual autoPtr< InjectionModel< CloudType > > clone() const
Construct and return a clone.
scalar binWidth_
Bin width when generating particle distributions.
const CloudType & owner() const
Return const access to the owner cloud.
label currentInjectori_
Current injector.
Switch ignoreOutOfBounds_
Flag to suppress errors if particle injection site is out-of-bounds.
Interrogates an injectedParticleCloud to convert the raw particle data into a set of 'binned' injecto...
bool applyDistributionMassTotal_
Flag to apply mass calculated from distribution instead of.
A class for handling words, derived from Foam::string.
scalarList endTime_
List of end time per injector.
virtual void setProperties(const label parcelI, const label nParcels, const scalar time, typename CloudType::parcelType &parcel)
Set the parcel properties.
ParcelType parcelType
Type of parcel the cloud was instantiated for.
A Vector of values with scalar precision, where scalar is float/double depending on the compilation f...
const word cloudName_
Name of cloud used to seed the new particles.
virtual label parcelsToInject(const scalar time0, const scalar time1)
Number of parcels to introduce relative to SOI.
PtrList< distributionModels::general > sizeDistribution_
List of size distribution model per injector.
TypeName("injectedParticleDistributionInjection")
Runtime type information.
List< vectorList > U_
List of parcel velocity per injector.
virtual bool fullyDescribed() const
Flag to identify whether model fully describes the parcel.
A list of pointers to objects of type <T>, with allocation/deallocation management of the pointers...
Pointer management similar to std::unique_ptr, with some additional methods and type checking...
label nParcelsInjected_
Running total of number of parcels injected.
List< vectorList > position_
List of position per injector.
InjectedParticleDistributionInjection(const dictionary &dict, CloudType &owner, const word &modelName)
Construct from dictionary.
label currentSamplei_
Current sample.
label resampleSize_
Resample size.
scalar parcelsPerInjector_
Target number of parcels to inject per injector.
label nParcelsInjected0_
Number of parcels injected in last step (local proc only)
Templated base class for dsmc cloud.
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.