All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
linearDamper Class Reference

Linear damper restraint. Operates in the local frame of the body. More...

Inheritance diagram for linearDamper:
Collaboration diagram for linearDamper:

Public Member Functions

 TypeName ("linearDamper")
 Runtime type information. More...
 
 linearDamper (const word &name, const dictionary &dict, const rigidBodyModel &model)
 Construct from components. More...
 
virtual autoPtr< restraintclone () const
 Construct and return a clone. More...
 
virtual ~linearDamper ()
 Destructor. More...
 
virtual void restrain (scalarField &tau, Field< spatialVector > &fx, const rigidBodyModelState &state) const
 Accumulate the retraint internal joint forces into the tau field and. More...
 
virtual bool read (const dictionary &dict)
 Update properties from given dictionary. More...
 
virtual void write (Ostream &) const
 Write. More...
 
- Public Member Functions inherited from restraint
 TypeName ("restraint")
 Runtime type information. More...
 
 declareRunTimeSelectionTable (autoPtr, restraint, dictionary,(const word &name, const dictionary &dict, const rigidBodyModel &model),(name, dict, model))
 
 restraint (const word &name, const dictionary &dict, const rigidBodyModel &model)
 Construct from the dict dictionary and Time. More...
 
virtual ~restraint ()
 Destructor. More...
 
const wordname () const
 Return the name. More...
 
label bodyID () const
 
const dictionarycoeffDict () const
 Return access to coeffs. More...
 

Additional Inherited Members

- Static Public Member Functions inherited from restraint
static autoPtr< restraintNew (const word &name, const dictionary &dict, const rigidBodyModel &model)
 Select constructed from the dict dictionary and Time. More...
 
- Protected Member Functions inherited from restraint
point bodyPoint (const point &p) const
 Transform the given point on the restrained body to the global frame. More...
 
spatialVector bodyPointVelocity (const point &p) const
 Transform the velocity of the given point on the restrained body. More...
 
- Protected Attributes inherited from restraint
word name_
 Name of the restraint. More...
 
label bodyID_
 ID of the body the restraint is applied to. More...
 
label bodyIndex_
 Index of the body the force is applied to. More...
 
dictionary coeffs_
 Restraint model specific coefficient dictionary. More...
 
const rigidBodyModelmodel_
 Reference to the model. More...
 

Detailed Description

Linear damper restraint. Operates in the local frame of the body.

Source files

Definition at line 52 of file linearDamper.H.

Constructor & Destructor Documentation

◆ linearDamper()

linearDamper ( const word name,
const dictionary dict,
const rigidBodyModel model 
)

Construct from components.

Definition at line 54 of file linearDamper.C.

References Foam::read().

Referenced by linearDamper::clone().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ~linearDamper()

~linearDamper ( )
virtual

Destructor.

Definition at line 68 of file linearDamper.C.

References linearDamper::restrain().

Referenced by linearDamper::clone().

Here is the call graph for this function:
Here is the caller graph for this function:

Member Function Documentation

◆ TypeName()

TypeName ( "linearDamper"  )

Runtime type information.

◆ clone()

virtual autoPtr<restraint> clone ( ) const
inlinevirtual

Construct and return a clone.

Implements restraint.

Definition at line 79 of file linearDamper.H.

References linearDamper::linearDamper(), linearDamper::read(), linearDamper::restrain(), linearDamper::write(), and linearDamper::~linearDamper().

Here is the call graph for this function:

◆ restrain()

void restrain ( scalarField tau,
Field< spatialVector > &  fx,
const rigidBodyModelState state 
) const
virtual

Accumulate the retraint internal joint forces into the tau field and.

external forces into the fx field

Implements restraint.

Definition at line 75 of file linearDamper.C.

References Foam::endl(), Foam::Info, linearDamper::read(), Field< Type >::T(), and Foam::Zero.

Referenced by linearDamper::clone(), and linearDamper::~linearDamper().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ read()

bool read ( const dictionary dict)
virtual

Update properties from given dictionary.

Reimplemented from restraint.

Definition at line 94 of file linearDamper.C.

References restraint::read(), and linearDamper::write().

Referenced by linearDamper::clone(), and linearDamper::restrain().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ write()

void write ( Ostream os) const
virtual

Write.

Implements restraint.

Definition at line 107 of file linearDamper.C.

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

Referenced by linearDamper::clone(), and linearDamper::read().

Here is the call graph for this function:
Here is the caller graph for this function:

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