Displacement fixed by projection onto triSurface. Use in a displacementMotionSolver as a bc on the pointDisplacement field. More...
Public Types | |
enum | projectMode { NEAREST, POINTNORMAL, FIXEDNORMAL } |
Public Member Functions | |
TypeName ("surfaceDisplacement") | |
Runtime type information. More... | |
surfaceDisplacementPointPatchVectorField (const pointPatch &, const DimensionedField< vector, pointMesh > &) | |
Construct from patch and internal field. More... | |
surfaceDisplacementPointPatchVectorField (const pointPatch &, const DimensionedField< vector, pointMesh > &, const dictionary &) | |
Construct from patch, internal field and dictionary. More... | |
surfaceDisplacementPointPatchVectorField (const surfaceDisplacementPointPatchVectorField &, const pointPatch &, const DimensionedField< vector, pointMesh > &, const pointPatchFieldMapper &) | |
Construct by mapping given patchField<vector> onto a new patch. More... | |
surfaceDisplacementPointPatchVectorField (const surfaceDisplacementPointPatchVectorField &) | |
Construct as copy. More... | |
virtual autoPtr< pointPatchVectorField > | clone () const |
Construct and return a clone. More... | |
surfaceDisplacementPointPatchVectorField (const surfaceDisplacementPointPatchVectorField &, const DimensionedField< vector, pointMesh > &) | |
Construct as copy setting internal field reference. More... | |
virtual autoPtr< pointPatchVectorField > | clone (const DimensionedField< vector, pointMesh > &iF) const |
Construct and return a clone setting internal field reference. More... | |
const searchableSurfaces & | surfaces () const |
Surface to follow. Demand loads surfaceNames. More... | |
virtual void | updateCoeffs () |
Update the coefficients associated with the patch field. More... | |
virtual void | write (Ostream &) const |
Write. More... | |
Private Member Functions | |
void | calcProjection (vectorField &displacement) const |
Calculate displacement (w.r.t. points0()) to project onto surface. More... | |
void | operator= (const surfaceDisplacementPointPatchVectorField &) |
Disallow default bitwise assignment. More... | |
Private Attributes | |
const vector | velocity_ |
Maximum velocity. More... | |
const dictionary | surfacesDict_ |
Names of surfaces. More... | |
const projectMode | projectMode_ |
How to project/project onto surface. More... | |
const vector | projectDir_ |
Direction to project. More... | |
const label | wedgePlane_ |
Plane for 2D wedge case or -1. More... | |
const word | frozenPointsZone_ |
pointZone with frozen points More... | |
autoPtr< searchableSurfaces > | surfacesPtr_ |
Demand driven: surface to project. More... | |
Static Private Attributes | |
static const NamedEnum< projectMode, 3 > | projectModeNames_ |
Project mode names. More... | |
Displacement fixed by projection onto triSurface. Use in a displacementMotionSolver as a bc on the pointDisplacement field.
Calculates the projection onto the surface according to the projectMode
This displacement is then clipped with the specified velocity * deltaT.
Optionally (intersection only) removes a component ("wedgePlane") to stay in 2D.
Needs:
Definition at line 73 of file surfaceDisplacementPointPatchVectorField.H.
enum projectMode |
Enumerator | |
---|---|
NEAREST | |
POINTNORMAL | |
FIXEDNORMAL |
Definition at line 82 of file surfaceDisplacementPointPatchVectorField.H.
surfaceDisplacementPointPatchVectorField | ( | const pointPatch & | p, |
const DimensionedField< vector, pointMesh > & | iF | ||
) |
Construct from patch and internal field.
Definition at line 305 of file surfaceDisplacementPointPatchVectorField.C.
surfaceDisplacementPointPatchVectorField | ( | const pointPatch & | p, |
const DimensionedField< vector, pointMesh > & | iF, | ||
const dictionary & | dict | ||
) |
Construct from patch, internal field and dictionary.
Definition at line 320 of file surfaceDisplacementPointPatchVectorField.C.
References Foam::exit(), Foam::FatalError, FatalErrorInFunction, and Foam::nl.
surfaceDisplacementPointPatchVectorField | ( | const surfaceDisplacementPointPatchVectorField & | ppf, |
const pointPatch & | p, | ||
const DimensionedField< vector, pointMesh > & | iF, | ||
const pointPatchFieldMapper & | mapper | ||
) |
Construct by mapping given patchField<vector> onto a new patch.
Definition at line 347 of file surfaceDisplacementPointPatchVectorField.C.
Construct as copy.
Definition at line 366 of file surfaceDisplacementPointPatchVectorField.C.
surfaceDisplacementPointPatchVectorField | ( | const surfaceDisplacementPointPatchVectorField & | ppf, |
const DimensionedField< vector, pointMesh > & | iF | ||
) |
Construct as copy setting internal field reference.
Definition at line 382 of file surfaceDisplacementPointPatchVectorField.C.
|
private |
Calculate displacement (w.r.t. points0()) to project onto surface.
Per point projection vector:
Definition at line 58 of file surfaceDisplacementPointPatchVectorField.C.
References polyMesh::boundaryMesh(), polyMesh::bounds(), Foam::endl(), forAll, PointIndexHit< Point >::hit(), Foam::Info, objectRegistry::lookupObject(), Foam::mag(), Foam::magSqr(), boundBox::max(), mesh, polyBoundaryMesh::mesh(), boundBox::min(), n, zone::name(), VectorSpace< Vector< scalar >, scalar, 3 >::nComponents, polyMesh::pointZones(), Foam::Pout, pZones(), PointIndexHit< Point >::rawPoint(), Foam::reduce(), Foam::returnReduce(), List::size(), Foam::sqr(), pointZone::whichPoint(), and Vector< scalar >::zero.
Referenced by surfaceDisplacementPointPatchVectorField::updateCoeffs().
|
private |
Disallow default bitwise assignment.
TypeName | ( | "surfaceDisplacement" | ) |
Runtime type information.
|
inlinevirtual |
Construct and return a clone.
Definition at line 166 of file surfaceDisplacementPointPatchVectorField.H.
|
inlinevirtual |
Construct and return a clone setting internal field reference.
Definition at line 186 of file surfaceDisplacementPointPatchVectorField.H.
const searchableSurfaces & surfaces | ( | ) | const |
Surface to follow. Demand loads surfaceNames.
Definition at line 400 of file surfaceDisplacementPointPatchVectorField.C.
References IOobject::MUST_READ, IOobject::NO_WRITE, surfaceDisplacementPointPatchVectorField::surfacesDict_, and surfaceDisplacementPointPatchVectorField::surfacesPtr_.
|
virtual |
Update the coefficients associated with the patch field.
Definition at line 426 of file surfaceDisplacementPointPatchVectorField.C.
References surfaceDisplacementPointPatchVectorField::calcProjection(), forAll, Foam::max(), mesh, Foam::min(), VectorSpace< Vector< scalar >, scalar, 3 >::nComponents, Foam::operator==(), and surfaceDisplacementPointPatchVectorField::velocity_.
|
virtual |
Write.
Definition at line 472 of file surfaceDisplacementPointPatchVectorField.C.
References token::END_STATEMENT, surfaceDisplacementPointPatchVectorField::frozenPointsZone_, Foam::nl, word::null, surfaceDisplacementPointPatchVectorField::projectDir_, surfaceDisplacementPointPatchVectorField::projectMode_, surfaceDisplacementPointPatchVectorField::projectModeNames_, surfaceDisplacementPointPatchVectorField::surfacesDict_, surfaceDisplacementPointPatchVectorField::velocity_, surfaceDisplacementPointPatchVectorField::wedgePlane_, write(), and Ostream::writeKeyword().
|
staticprivate |
Project mode names.
Definition at line 94 of file surfaceDisplacementPointPatchVectorField.H.
Referenced by surfaceDisplacementPointPatchVectorField::write().
|
private |
Maximum velocity.
Definition at line 97 of file surfaceDisplacementPointPatchVectorField.H.
Referenced by surfaceDisplacementPointPatchVectorField::updateCoeffs(), and surfaceDisplacementPointPatchVectorField::write().
|
private |
Names of surfaces.
Definition at line 100 of file surfaceDisplacementPointPatchVectorField.H.
Referenced by surfaceDisplacementPointPatchVectorField::surfaces(), and surfaceDisplacementPointPatchVectorField::write().
|
private |
How to project/project onto surface.
Definition at line 103 of file surfaceDisplacementPointPatchVectorField.H.
Referenced by surfaceDisplacementPointPatchVectorField::write().
|
private |
Direction to project.
Definition at line 106 of file surfaceDisplacementPointPatchVectorField.H.
Referenced by surfaceDisplacementPointPatchVectorField::write().
|
private |
Plane for 2D wedge case or -1.
Definition at line 109 of file surfaceDisplacementPointPatchVectorField.H.
Referenced by surfaceDisplacementPointPatchVectorField::write().
|
private |
pointZone with frozen points
Definition at line 112 of file surfaceDisplacementPointPatchVectorField.H.
Referenced by surfaceDisplacementPointPatchVectorField::write().
|
mutableprivate |
Demand driven: surface to project.
Definition at line 115 of file surfaceDisplacementPointPatchVectorField.H.
Referenced by surfaceDisplacementPointPatchVectorField::surfaces().
Copyright © 2011-2018 OpenFOAM | OPENFOAM® is a registered trademark of OpenCFD Ltd.