1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | foam-extend: Open Source CFD
4 \\ / O peration | Version: 3.2
5 \\ / A nd | Web: http://www.foam-extend.org
6 \\/ M anipulation | For copyright notice see file Copyright
7 -------------------------------------------------------------------------------
9 This file is part of foam-extend.
11 foam-extend is free software: you can redistribute it and/or modify it
12 under the terms of the GNU General Public License as published by the
13 Free Software Foundation, either version 3 of the License, or (at your
14 option) any later version.
16 foam-extend is distributed in the hope that it will be useful, but
17 WITHOUT ANY WARRANTY; without even the implied warranty of
18 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19 General Public License for more details.
21 You should have received a copy of the GNU General Public License
22 along with foam-extend. If not, see <http://www.gnu.org/licenses/>.
25 fixedDisplacementZeroShearFvPatchVectorField
28 The component of the displacement normal to the patch is applied,
29 and the shear traction is set to zero.
30 Patch contains non-orthogonal correction.
33 fixedDisplacementZeroShearFvPatchVectorField.C
37 Based on velocityDisplacement by Aleksandar Karac
39 \*---------------------------------------------------------------------------*/
41 #ifndef fixedDisplacementZeroShearFvPatchVectorField_H
42 #define fixedDisplacementZeroShearFvPatchVectorField_H
44 #include "fvPatchFields.H"
45 #include "directionMixedFvPatchFields.H"
46 #include "nonLinearGeometry.H"
49 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
54 /*---------------------------------------------------------------------------*\
55 Class directionMixedFvPatch Declaration
56 \*---------------------------------------------------------------------------*/
58 class fixedDisplacementZeroShearFvPatchVectorField
60 public directionMixedFvPatchVectorField
64 //- Name of the displacement field
65 const word fieldName_;
67 //- Is it a non linear solver
68 nonLinearGeometry::nonLinearType nonLinear_;
70 //- if it is an orthropic solver
75 //- Runtime type information
76 TypeName("fixedDisplacementZeroShear");
81 //- Construct from patch and internal field
82 fixedDisplacementZeroShearFvPatchVectorField
85 const DimensionedField<vector, volMesh>&
88 //- Construct from patch, internal field and dictionary
89 fixedDisplacementZeroShearFvPatchVectorField
92 const DimensionedField<vector, volMesh>&,
96 //- Construct by mapping given
97 // fixedDisplacementZeroShearFvPatchVectorField
99 fixedDisplacementZeroShearFvPatchVectorField
101 const fixedDisplacementZeroShearFvPatchVectorField&,
103 const DimensionedField<vector, volMesh>&,
104 const fvPatchFieldMapper&
107 //- Construct and return a clone
108 virtual tmp<fvPatchField<vector> > clone() const
110 return tmp<fvPatchField<vector> >
112 new fixedDisplacementZeroShearFvPatchVectorField(*this)
116 //- Construct as copy setting internal field reference
117 fixedDisplacementZeroShearFvPatchVectorField
119 const fixedDisplacementZeroShearFvPatchVectorField&,
120 const DimensionedField<vector, volMesh>&
123 //- Construct and return a clone setting internal field reference
124 virtual tmp<fvPatchField<vector> > clone
126 const DimensionedField<vector, volMesh>& iF
129 return tmp<fvPatchField<vector> >
131 new fixedDisplacementZeroShearFvPatchVectorField(*this, iF)
137 virtual ~fixedDisplacementZeroShearFvPatchVectorField()
145 //- Map (and resize as needed) from self given a mapping object
148 const fvPatchFieldMapper&
151 //- Reverse map the given fvPatchField onto this fvPatchField
154 const fvPatchField<vector>&,
159 // Evaluation functions
161 //- Update the coefficients associated with the patch field
162 virtual void updateCoeffs();
166 virtual void write(Ostream&) const;
174 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
176 } // End namespace Foam
178 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
182 // ************************************************************************* //