33 template<
class CloudType>
50 template<
class CloudType>
58 TFilmPatch_(sfm.TFilmPatch_),
59 CpFilmPatch_(sfm.CpFilmPatch_)
65 template<
class CloudType>
73 const label patchi = pp.
index();
74 const label meshFacei =
p.face();
75 const label facei = pp.
whichFace(meshFacei);
77 this->initFilmModels();
80 if (this->filmModel_ && this->filmModel_->isRegionPatch(patchi))
82 auto& film = *(this->filmModel_);
84 switch (this->interactionType_)
88 this->bounceInteraction(
p, pp, facei, keepParticle);
93 case KinematicSurfaceFilm<CloudType>::itAbsorb:
95 const scalar m =
p.nParticle()*
p.mass();
97 this->absorbInteraction
98 (film,
p, pp, facei, m, keepParticle);
103 case KinematicSurfaceFilm<CloudType>::itSplashBai:
106 const scalar pc = thermo_.thermo().p()[
p.cell()];
107 const liquidProperties& liq = thermo_.liquids().properties()[0];
108 const scalar
sigma = liq.sigma(pc,
p.T());
109 const scalar
mu = liq.mu(pc,
p.T());
113 this->deltaFilmPatch_[patchi][facei] < this->deltaWet_
118 this->drySplashInteraction
119 (film,
sigma,
mu,
p, pp, facei, keepParticle);
123 this->wetSplashInteraction
124 (film,
sigma,
mu,
p, pp, facei, keepParticle);
133 <<
"Unknown interaction type enumeration" 144 for (areaFilm& film : this->areaFilms_)
146 const label filmFacei
159 switch (this->interactionType_)
161 case KinematicSurfaceFilm<CloudType>::itBounce:
163 this->bounceInteraction(
p, pp, facei, keepParticle);
168 case KinematicSurfaceFilm<CloudType>::itAbsorb:
170 const scalar m =
p.nParticle()*
p.mass();
172 this->absorbInteraction
174 film,
p, pp, facei, m, keepParticle
179 case KinematicSurfaceFilm<CloudType>::itSplashBai:
182 const scalar pc = thermo_.thermo().p()[
p.cell()];
183 const liquidProperties& liq = thermo_.liquids().properties()[0];
184 const scalar
sigma = liq.sigma(pc,
p.T());
185 const scalar
mu = liq.mu(pc,
p.T());
189 film.
h()[filmFacei] < this->deltaWet_
194 this->drySplashInteraction
195 (film,
sigma,
mu,
p, pp, facei, keepParticle);
199 this->wetSplashInteraction
200 (film,
sigma,
mu,
p, pp, facei, keepParticle);
209 <<
"Unknown interaction type enumeration" 223 template<
class CloudType>
226 const label filmPatchi,
227 const label primaryPatchi,
239 filmModel.
toPrimary(filmPatchi, TFilmPatch_);
242 filmModel.
toPrimary(filmPatchi, CpFilmPatch_);
246 template<
class CloudType>
262 template<
class CloudType>
266 const label filmFacei
272 p.T() = TFilmPatch_[filmFacei];
273 p.Cp() = CpFilmPatch_[filmFacei];
277 template<
class CloudType>
Thermo parcel surface film model.
virtual void info()
Write surface film info.
bool isRegionPatch(const label patchi) const
True if patchi on the primary region is coupled to this region.
label whichFace(const label facei) const noexcept
Return label of face in patch from global face label.
const Internal::FieldType & primitiveField() const noexcept
Return a const-reference to the internal field values.
Base class for surface film models.
const areaScalarField & h() const
Access const reference h.
error FatalError
Error stream (stdout output on all processes), with additional 'FOAM FATAL ERROR' header text and sta...
A list of keyword definitions, which are a keyword followed by a number of values (eg...
virtual void setParcelProperties(parcelType &p, const label filmFacei) const
Set the individual parcel properties.
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
ThermoSurfaceFilm(const dictionary &dict, CloudType &owner)
Construct from components.
label whichFace(const label meshFacei) const
The area-face corresponding to the mesh-face, -1 if not found.
virtual const areaScalarField & Cp() const =0
Access const reference Cp.
dimensionedScalar sigma("sigma", dimMass/sqr(dimTime), transportProperties)
void toPrimary(const label regionPatchi, List< Type > ®ionField) const
Convert a local region field to the primary region.
virtual void cacheFilmFields(const label filmPatchi, const label primaryPatchi, const regionFilm &)
Cache the film fields in preparation for injection.
const faMesh & regionMesh() const
Return the region mesh database.
Thermo package for (S)olids (L)iquids and (G)ases Takes reference to thermo package, and provides:
errorManip< error > abort(error &err)
Kinematic parcel surface film model.
virtual const areaScalarField & Tf() const =0
Access const reference Tf.
virtual const volScalarField & Ts() const =0
Return the film surface temperature [K].
const dimensionedScalar mu
Atomic mass unit.
virtual const volScalarField & Cp() const =0
Return the film specific heat capacity [J/kg/K].
label index() const noexcept
The index of this patch in the boundaryMesh.
Registry of regIOobjects.
A patch is a list of labels that address the faces in the global face list.
virtual bool transferParcel(parcelType &p, const polyPatch &pp, bool &keepParticle)
Transfer parcel from cloud to surface film.
Templated base class for dsmc cloud.
const Boundary & boundaryField() const noexcept
Return const-reference to the boundary field.