32 template<
class CloudType>
46 const typename CloudType::parcelType&
p = iter();
52 if (useEquivalentSize_)
54 dEff *=
cbrt(
p.nParticle()*volumeFactor_);
57 rMin =
min(dEff, rMin);
59 rhoMax =
max(
p.rho(), rhoMax);
75 template<
class CloudType>
78 typename CloudType::parcelType&
p,
80 const WallSiteData<vector>& data,
86 const polyMesh& mesh = this->owner().mesh();
88 vector r_PW =
p.position(mesh) - site;
90 vector U_PW =
p.U() - data.wallData();
92 scalar r_PW_mag =
mag(r_PW);
94 scalar normalOverlapMag =
max(pREff - r_PW_mag, 0.0);
96 vector rHat_PW = r_PW/(r_PW_mag + vSmall);
98 scalar etaN = alpha_*
sqrt(
p.mass()*kN)*
pow025(normalOverlapMag);
102 *(kN*
pow(normalOverlapMag, b_) - etaN*(U_PW & rHat_PW));
109 -cohesionEnergyDensity_
117 U_PW - (U_PW & rHat_PW)*rHat_PW
118 + (
p.omega() ^ (pREff*-rHat_PW));
120 scalar deltaT = this->owner().mesh().time().deltaTValue();
122 vector& tangentialOverlap_PW =
123 p.collisionRecords().matchWallRecord(-r_PW, pREff).collisionData();
125 tangentialOverlap_PW += USlip_PW*deltaT;
127 scalar tangentialOverlapMag =
mag(tangentialOverlap_PW);
129 if (tangentialOverlapMag > vSmall)
131 scalar kT = 8.0*
sqrt(pREff*normalOverlapMag)*Gstar_;
138 if (kT*tangentialOverlapMag > mu_*
mag(fN_PW))
143 fT_PW = -mu_*
mag(fN_PW)*USlip_PW/
mag(USlip_PW);
145 tangentialOverlap_PW =
Zero;
149 fT_PW = - kT*tangentialOverlap_PW - etaT*USlip_PW;
154 p.torque() += (pREff*-rHat_PW) ^ fT_PW;
161 template<
class CloudType>
171 alpha_(this->coeffDict().template lookup<scalar>(
"alpha")),
172 b_(this->coeffDict().template lookup<scalar>(
"b")),
173 mu_(this->coeffDict().template lookup<scalar>(
"mu")),
174 cohesionEnergyDensity_
176 this->coeffDict().template lookup<scalar>(
"cohesionEnergyDensity")
179 collisionResolutionSteps_
181 this->coeffDict().template lookup<scalar>(
"collisionResolutionSteps")
184 useEquivalentSize_(
Switch(this->coeffDict().lookup(
"useEquivalentSize")))
186 if (useEquivalentSize_)
189 this->
coeffDict().template lookup<scalar>(
"volumeFactor");
192 scalar nu = this->
coeffDict().template lookup<scalar>(
"poissonsRatio");
194 scalar E = this->
coeffDict().template lookup<scalar>(
"youngsModulus");
200 Estar_ = 1/((1 -
sqr(pNu))/pE + (1 -
sqr(nu))/E);
202 Gstar_ = 1/(2*((2 + pNu -
sqr(pNu))/pE + (2 + nu -
sqr(nu))/E));
204 cohesion_ = (
mag(cohesionEnergyDensity_) > vSmall);
210 template<
class CloudType>
217 template<
class CloudType>
223 if (useEquivalentSize_)
225 return p.d()/2*
cbrt(
p.nParticle()*volumeFactor_);
234 template<
class CloudType>
241 template<
class CloudType>
244 if (!this->owner().size())
249 scalar rMin, rhoMax, UMagMax;
250 findMinMaxProperties(rMin, rhoMax, UMagMax);
253 const scalar minCollisionDeltaT =
256 *
pow(rhoMax/(Estar_*
sqrt(UMagMax) + small), 0.4)
257 /collisionResolutionSteps_;
259 return ceil(this->owner().time().deltaTValue()/minCollisionDeltaT);
263 template<
class CloudType>
273 scalar pREff = this->pREff(
p);
275 scalar kN = (4.0/3.0)*
sqrt(pREff)*Estar_;
277 forAll(flatSitePoints, siteI)
282 flatSitePoints[siteI],
290 forAll(sharpSitePoints, siteI)
297 sharpSitePoints[siteI],
298 sharpSiteData[siteI],
#define forAll(list, i)
Loop across all elements in list.
#define forAllConstIter(Container, container, iter)
Iterate across all elements in the container object of type.
Templated base class for dsmc cloud.
const List< typename ParcelType::constantProperties > & constProps() const
Return all of the constant properties.
ParcelType parcelType
Type of parcel the cloud was instantiated for.
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
A simple wrapper around bool so that it can be read as a word: true/false, on/off,...
Templated wall interaction class.
const dictionary & coeffDict() const
Return the coefficients dictionary.
const CloudType & owner() const
Return the owner cloud object.
Stores the patch ID and templated data to represent a collision with a wall to be passed to the wall ...
Forces between particles and walls, interacting with a spring, slider, damper model.
virtual ~WallSpringSliderDashpot()
Destructor.
virtual label nSubCycles() const
For WallModels that control the timestep, calculate the.
virtual scalar pREff(const typename CloudType::parcelType &p) const
Return the effective radius for a particle for the model.
WallSpringSliderDashpot(const dictionary &dict, CloudType &cloud)
Construct from dictionary.
virtual bool controlsTimestep() const
Whether the WallModel has a timestep limit that will.
A cloud is a collection of lagrangian particles.
A list of keyword definitions, which are a keyword followed by any number of values (e....
DSMCCloud< dsmcParcel > CloudType
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
dimensionedSymmTensor sqr(const dimensionedVector &dv)
vector point
Point is a vector.
layerAndWeight min(const layerAndWeight &a, const layerAndWeight &b)
dimensionedScalar pow(const dimensionedScalar &ds, const dimensionedScalar &expt)
Vector< scalar > vector
A scalar version of the templated Vector.
dimensionedScalar sqrt(const dimensionedScalar &ds)
dimensioned< scalar > mag(const dimensioned< Type > &)
layerAndWeight max(const layerAndWeight &a, const layerAndWeight &b)
dimensionedScalar cbrt(const dimensionedScalar &ds)
dimensionedScalar pow025(const dimensionedScalar &ds)