35 namespace filmEjectionModels
57 U.primitiveField()/(
mag(
U.primitiveField()) + rootVSmall)
63 const scalar rMin = 1
e-6;
70 const scalar definedInvR1 = 1/
max(rMin, patchRadii_[i].
second());
75 const scalar rMax = 1e6;
79 if (
mag(invR1[i]) < 1/rMax)
89 tmp<scalarField> curvatureSeparation::calcCosAngle
94 const fvMesh& mesh = film_.
mesh;
96 const scalar magg(
mag(film_.g.value()));
97 const vector gHat(film_.g.value()/magg);
104 tmp<scalarField> tcosAngle
112 const label cellO = own[facei];
113 const label cellN = nbr[facei];
115 if (alphaRhoPhi[facei] > alphaRhoPhiMax[cellO])
117 alphaRhoPhiMax[cellO] = alphaRhoPhi[facei];
118 cosAngle[cellO] = -gHat & nf[facei];
120 if (-alphaRhoPhi[facei] > alphaRhoPhiMax[cellN])
122 alphaRhoPhiMax[cellN] = -alphaRhoPhi[facei];
123 cosAngle[cellN] = -gHat & -nf[facei];
130 alphaRhoPhi.boundaryField()[
patchi];
132 const fvPatch& pp = alphaRhoPhip.patch();
136 const labelList& faceCells = pp.faceCells();
141 const label celli = faceCells[i];
143 if (alphaRhoPhip[i] > alphaRhoPhiMax[celli])
145 alphaRhoPhiMax[celli] = alphaRhoPhip[i];
146 cosAngle[celli] = -gHat & nf[i];
165 gradNHat_(fvc::
grad(film_.nHat)),
168 dict.optionalSubDict(typeName +
"Coeffs")
169 .lookupOrDefault<scalar>(
"deltaByR1Min", scalar(0))
173 dict.optionalSubDict(typeName +
"Coeffs")
174 .lookupOrDefault(
"deltaStable", scalar(0))
181 const wordList& allPatchNames = film_.mesh.boundaryMesh().names();
196 const scalar radius = prIn[i].second();
204 patchRadii_.transfer(prData);
226 const scalarField cosAngle(calcCosAngle(film_.alphaRhoPhi));
228 const scalar magg(
mag(film_.g.value()));
230 const scalar deltaT = film_.mesh.time().deltaTValue();
233 const scalar Fthreshold = 1
e-10;
238 diameter_[celli] = 0;
242 delta[celli] > deltaStable_
244 &&
delta[celli]*invR1[celli] > deltaByR1Min_
247 const scalar R1 = 1/(invR1[celli] + rootVSmall);
248 const scalar R2 = R1 +
delta[celli];
253 *
magSqr(
U[celli])*72/60*invR1[celli];
258 *invR1[celli]*(
sqr(R1) -
sqr(R2))*cosAngle[celli];
261 const scalar Fs =
sigma[celli]/R2;
263 if (Fi + Fb + Fs + Fthreshold < 0)
267 (
delta[celli] - deltaStable_)/(deltaT*
delta[celli]);
270 diameter_[celli] =
delta[celli];
#define forAll(list, i)
Loop across all elements in list.
#define forAllReverse(list, i)
Reverse loop across all elements in list.
Macros for easy insertion into run-time selection tables.
Field with dimensions and associated with geometry type GeoMesh which is used to size the field and a...
A 1D vector of objects of type <T> that resizes itself as necessary to accept the new objects.
DynamicList< T, SizeInc, SizeMult, SizeDiv > & append(const T &)
Append an element at the end of the list.
Generic GeometricField class.
bool insert(const Key &key)
Insert a new entry.
bool found(const Key &) const
Return true if hashedEntry is found in table.
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
void size(const label)
Override size to be inconsistent with allocated storage.
A 2-tuple for storing two objects of different types.
A list of keyword definitions, which are a keyword followed by any number of values (e....
virtual bool movePoints()
Update for mesh motion.
virtual void topoChange(const polyTopoChangeMap &)
Update topology using the given map.
virtual void distribute(const polyDistributionMap &)
Redistribute or update using the given distribution map.
virtual void mapMesh(const polyMeshMap &)
Update from another mesh using the given map.
Curvature induced separation film to cloud ejection transfer model.
virtual bool movePoints()
Update for mesh motion.
virtual void correct()
Correct.
virtual void topoChange(const polyTopoChangeMap &)
Update topology using the given map.
virtual void distribute(const polyDistributionMap &)
Redistribute or update using the given distribution map.
virtual void mapMesh(const polyMeshMap &)
Update from another mesh using the given map.
virtual ~curvatureSeparation()
Destructor.
curvatureSeparation(const dictionary &dict, const solvers::isothermalFilm &film)
Construct from dictionary and film model.
Mesh data needed to do the Finite Volume discretisation.
const polyMesh & mesh() const
Return reference to polyMesh.
Class containing mesh-to-mesh mapping information after a mesh distribution where we send parts of me...
Class containing mesh-to-mesh mapping information.
const polyBoundaryMesh & boundaryMesh() const
Return boundary mesh.
Class containing mesh-to-mesh mapping information after a change in polyMesh topology.
Solver module for flow of compressible isothermal liquid films.
A class for managing temporary objects.
Calculate the gradient of the given field.
const dimensionedScalar sigma
Stefan-Boltzmann constant: default SI units: [W/m^2/K^4].
addToRunTimeSelectionTable(ejectionModel, BrunDripping, dictionary)
defineTypeNameAndDebug(BrunDripping, 0)
tmp< VolField< typename outerProduct< vector, Type >::type > > grad(const SurfaceField< Type > &ssf)
List< label > labelList
A List of labels.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
bool findStrings(const wordReListMatcher &matcher, const std::string &str)
Return true if string matches one of the regular expressions.
dimensionedSymmTensor sqr(const dimensionedVector &dv)
SurfaceField< scalar > surfaceScalarField
labelList second(const UList< labelPair > &p)
Field< scalar > scalarField
Specialisation of Field<T> for scalar.
labelList first(const UList< labelPair > &p)
Vector< scalar > vector
A scalar version of the templated Vector.
dimensioned< scalar > mag(const dimensioned< Type > &)
layerAndWeight max(const layerAndWeight &a, const layerAndWeight &b)
Field< vector > vectorField
Specialisation of Field<T> for vector.
UList< label > labelUList
dimensioned< scalar > magSqr(const dimensioned< Type > &)
fvsPatchField< scalar > fvsPatchScalarField