OOFEM
2.4
OOFEM.org - Object Oriented Finite Element Solver
|
Abstract class representing field. More...
#include <field.h>
Public Member Functions | |
Field (FieldType b) | |
Constructor. More... | |
virtual | ~Field () |
virtual int | evaluateAt (FloatArray &answer, const FloatArray &coords, ValueModeType mode, TimeStep *tStep)=0 |
Evaluates the field at given point. More... | |
virtual int | evaluateAt (FloatArray &answer, DofManager *dman, ValueModeType mode, TimeStep *tStep)=0 |
Evaluates the field at given DofManager. More... | |
FieldType | giveType () |
Returns the type of receiver. More... | |
virtual contextIOResultType | saveContext (DataStream &stream, ContextMode mode)=0 |
Stores receiver state to output stream. More... | |
virtual contextIOResultType | restoreContext (DataStream &stream, ContextMode mode)=0 |
Restores the receiver state previously written in stream. More... | |
std::string | errorInfo (const char *func) const |
Returns string for prepending output (used by error reporting macros). More... | |
virtual const char * | giveClassName () const =0 |
Protected Attributes | |
FieldType | type |
Abstract class representing field.
Field represent the spatial distribution of certain variable. Field is able to evaluate its value at any point of interest. The field is usually associated to specific domain.
|
inline |
std::string oofem::Field::errorInfo | ( | const char * | func | ) | const |
Returns string for prepending output (used by error reporting macros).
Definition at line 40 of file field.C.
References giveClassName().
|
pure virtual |
Evaluates the field at given point.
coords | Coordinates of the point of interest |
answer | Field evaluated at coordinate. |
tStep | Time step to evaluate for. |
mode | Mode of value (total, velocity,...). |
Implemented in oofem::UnstructuredGridField, oofem::PrimaryField, oofem::UniformGridField, oofem::InternalVariableField, oofem::DofManValueField, oofem::SmoothedNodalInternalVariableField, and oofem::MaskedPrimaryField.
|
pure virtual |
Evaluates the field at given DofManager.
This potentially can be resolved quickly, as receiver data may be described using values at dofManagers. Here an additional issue exists: one needs to make sure, that passed dman is from the same domain, so that its number can be used to perform suggested quick evaluation.
If this is not the case (the field is described differently), the response can be evaluated using dofman coordinates in a standard way.
[out] | answer | Evaluated field for dman. |
dman | Reference to dofManager. | |
mode | Mode of value (total, velocity,...). | |
tStep | Time step to evaluate for. |
Implemented in oofem::UnstructuredGridField, oofem::PrimaryField, oofem::DofManValueField, oofem::UniformGridField, oofem::InternalVariableField, oofem::SmoothedNodalInternalVariableField, and oofem::MaskedPrimaryField.
|
pure virtual |
Implemented in oofem::UnstructuredGridField, oofem::PrimaryField, oofem::DofManValueField, oofem::UniformGridField, oofem::InternalVariableField, oofem::SmoothedNodalInternalVariableField, and oofem::MaskedPrimaryField.
Referenced by errorInfo().
|
inline |
Returns the type of receiver.
Definition at line 120 of file field.h.
References oofem::errorInfo().
|
pure virtual |
Restores the receiver state previously written in stream.
Reads the FEMComponent class-id in order to allow test consistency.
stream | Input stream. |
mode | Determines amount of info in stream (state, definition,...). |
Throws | an ContextIOERR exception if error encountered. |
Implemented in oofem::UnstructuredGridField, oofem::PrimaryField, oofem::DofManValueField, oofem::UniformGridField, oofem::DofDistributedPrimaryField, oofem::InternalVariableField, oofem::SmoothedNodalInternalVariableField, and oofem::MaskedPrimaryField.
|
pure virtual |
Stores receiver state to output stream.
Writes the FEMComponent class-id in order to allow test whether correct data are then restored.
stream | Output stream. |
mode | Determines amount of info in stream (state, definition,...). |
Throws | an ContextIOERR exception if error encountered. |
Implemented in oofem::UnstructuredGridField, oofem::PrimaryField, oofem::DofManValueField, oofem::UniformGridField, oofem::DofDistributedPrimaryField, oofem::InternalVariableField, oofem::SmoothedNodalInternalVariableField, and oofem::MaskedPrimaryField.