1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
5 \\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
7 -------------------------------------------------------------------------------
9 This file is part of OpenFOAM.
11 OpenFOAM 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 2 of the License, or (at your
14 option) any later version.
16 OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
17 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
18 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
21 You should have received a copy of the GNU General Public License
22 along with OpenFOAM; if not, write to the Free Software Foundation,
23 Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
26 Foam::sixDoFRigidBodyMotionConstraints::fixedAxis
29 sixDoFRigidBodyMotionConstraint. Axis of body fixed global
35 \*---------------------------------------------------------------------------*/
40 #include "sixDoFRigidBodyMotionConstraint.H"
44 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
49 namespace sixDoFRigidBodyMotionConstraints
52 /*---------------------------------------------------------------------------*\
53 Class fixedAxis Declaration
54 \*---------------------------------------------------------------------------*/
58 public sixDoFRigidBodyMotionConstraint
63 //- Reference axis in global space
69 //- Runtime type information
70 TypeName("fixedAxis");
75 //- Construct from components
78 const dictionary& sDoFRBMCDict
81 //- Construct and return a clone
82 virtual autoPtr<sixDoFRigidBodyMotionConstraint> clone() const
84 return autoPtr<sixDoFRigidBodyMotionConstraint>
98 //- Calculate the constraint position, force and moment.
99 // Global reference frame vectors. Returns boolean stating
100 // whether the constraint been converged to tolerance.
101 virtual bool constrain
103 const sixDoFRigidBodyMotion& motion,
104 const vector& existingConstraintForce,
105 const vector& existingConstraintMoment,
107 vector& constraintPosition,
108 vector& constraintForceIncrement,
109 vector& constraintMomentIncrement
112 //- Update properties from given dictionary
113 virtual bool read(const dictionary& sDoFRBMCCoeff);
116 virtual void write(Ostream&) const;
120 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
122 } // End namespace solidBodyMotionFunctions
123 } // End namespace Foam
125 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
129 // ************************************************************************* //