contactAngleFvPatchScalarField Class Reference

General alpha contact angle boundary condition. More...

Inheritance diagram for contactAngleFvPatchScalarField:
Collaboration diagram for contactAngleFvPatchScalarField:

Public Types

enum  limitControls { lcNone , lcGradient , lcZeroGradient , lcAlpha }
 Alpha limit options. More...
 

Public Member Functions

 TypeName ("contactAngle")
 Runtime type information. More...
 
 contactAngleFvPatchScalarField (const fvPatch &, const DimensionedField< scalar, volMesh > &, const dictionary &)
 Construct from patch, internal field and dictionary. More...
 
 contactAngleFvPatchScalarField (const contactAngleFvPatchScalarField &, const fvPatch &, const DimensionedField< scalar, volMesh > &, const fvPatchFieldMapper &)
 Construct by mapping given contactAngleFvPatchScalarField. More...
 
 contactAngleFvPatchScalarField (const contactAngleFvPatchScalarField &)=delete
 Disallow copy without setting internal field reference. More...
 
 contactAngleFvPatchScalarField (const contactAngleFvPatchScalarField &, const DimensionedField< scalar, volMesh > &)
 Copy constructor setting internal field reference. More...
 
tmp< scalarFieldcosTheta (const fvPatchVectorField &Up, const vectorField &nHat) const
 Return the cosine of the contact angle. More...
 
virtual void evaluate (const Pstream::commsTypes commsType=Pstream::commsTypes::blocking)
 Evaluate the patch field. More...
 
virtual void write (Ostream &) const
 Write. More...
 

Public Attributes

limitControls limit_
 

Static Public Attributes

static const NamedEnum< limitControls, 4 > limitControlNames_
 

Detailed Description

General alpha contact angle boundary condition.

The essential entry "limit" controls the gradient of alpha1 on the wall:

  • none - Calculate the gradient from the contact-angle without limiter
  • gradient - Limit the wall-gradient such that alpha1 remains bounded on the wall
  • alpha - Bound the calculated alpha1 on the wall
  • zeroGradient - Set the gradient of alpha1 to 0 on the wall, i.e. reproduce previous behaviour, the pressure BCs can be left as before.

Note that if any of the first three options are used the boundary condition on p_rgh must set to guarantee that the flux is corrected to be zero at the wall e.g.:

<patchName>
{
    type            contactAngle;
    limit           none;
    theta0          70;
}
See also
Foam::contactAngleModel Foam::contactAngleModels::constant Foam::contactAngleModels::dynamic
Source files

Definition at line 75 of file contactAngleFvPatchScalarField.H.

Member Enumeration Documentation

◆ limitControls

Alpha limit options.

Enumerator
lcNone 
lcGradient 
lcZeroGradient 
lcAlpha 

Definition at line 91 of file contactAngleFvPatchScalarField.H.

Constructor & Destructor Documentation

◆ contactAngleFvPatchScalarField() [1/4]

contactAngleFvPatchScalarField ( const fvPatch p,
const DimensionedField< scalar, volMesh > &  iF,
const dictionary dict 
)

Construct from patch, internal field and dictionary.

Definition at line 59 of file contactAngleFvPatchScalarField.C.

References dict, Foam::evaluate(), fvPatchField< Type >::operator=(), and p.

Here is the call graph for this function:

◆ contactAngleFvPatchScalarField() [2/4]

contactAngleFvPatchScalarField ( const contactAngleFvPatchScalarField acpsf,
const fvPatch p,
const DimensionedField< scalar, volMesh > &  iF,
const fvPatchFieldMapper mapper 
)

Construct by mapping given contactAngleFvPatchScalarField.

onto a new patch

Definition at line 84 of file contactAngleFvPatchScalarField.C.

◆ contactAngleFvPatchScalarField() [3/4]

Disallow copy without setting internal field reference.

◆ contactAngleFvPatchScalarField() [4/4]

Copy constructor setting internal field reference.

Definition at line 98 of file contactAngleFvPatchScalarField.C.

Member Function Documentation

◆ TypeName()

TypeName ( "contactAngle"  )

Runtime type information.

◆ cosTheta()

Foam::tmp< Foam::scalarField > cosTheta ( const fvPatchVectorField Up,
const vectorField nHat 
) const

Return the cosine of the contact angle.

Definition at line 112 of file contactAngleFvPatchScalarField.C.

◆ evaluate()

void evaluate ( const Pstream::commsTypes  commsType = Pstream::commsTypes::blocking)
virtual

Evaluate the patch field.

Definition at line 122 of file contactAngleFvPatchScalarField.C.

References Foam::evaluate(), Foam::max(), Foam::min(), and Field< scalar >::operator=().

Here is the call graph for this function:

◆ write()

void write ( Ostream os) const
virtual

Write.

Definition at line 153 of file contactAngleFvPatchScalarField.C.

References Foam::vtkWriteOps::write(), and Foam::writeEntry().

Here is the call graph for this function:

Member Data Documentation

◆ limitControlNames_

Definition at line 99 of file contactAngleFvPatchScalarField.H.

◆ limit_

limitControls limit_

Definition at line 100 of file contactAngleFvPatchScalarField.H.


The documentation for this class was generated from the following files: