|
IFEM
90A354
|
Class for spline-based finite element scalar fields in 3D. More...
#include <SplineField3D.h>


Public Member Functions | |
| SplineField3D (const ASMs3D *patch, const RealArray &v, char basis=1, char cmp=1, const char *name=nullptr) | |
| The constructor sets the number of space dimensions and fields. More... | |
| SplineField3D (const Go::SplineVolume *svol, const RealArray &v, const char *name=nullptr) | |
| Construct directly from volume. More... | |
| virtual | ~SplineField3D () |
| Empty destructor. | |
| virtual double | valueNode (size_t node) const |
| Computes the value in a given node/control point. More... | |
| virtual double | valueFE (const ItgPoint &x) const |
| Computes the value at a given local coordinate. More... | |
| virtual double | valueCoor (const Vec4 &x) const |
| Computes the value at a given global coordinate. More... | |
| virtual bool | valueGrid (RealArray &val, const int *npe) const |
| Computes the value at a grid of visualization points. More... | |
| virtual bool | gradFE (const ItgPoint &x, Vector &grad) const |
| Computes the gradient for a given local coordinate. More... | |
| virtual bool | hessianFE (const ItgPoint &x, Matrix &H) const |
| Computes the hessian for a given local coordinate. More... | |
Public Member Functions inherited from FieldBase | |
| virtual | ~FieldBase () |
| Empty destructor. | |
| size_t | getNoElm () const |
| Returns the number of elements. | |
| size_t | getNoNodes () const |
| Returns the number of nodal/control points. | |
Public Member Functions inherited from Field | |
| virtual | ~Field () |
| Empty destructor. | |
| const char * | getFieldName () const |
| Returns the name of field. | |
| virtual bool | gradCoor (const Vec4 &x, Vector &grad) const |
| Computes the gradient for a given global/physical coordinate. More... | |
Protected Attributes | |
| const Go::SplineVolume * | basis |
| Spline basis description. | |
| const Go::SplineVolume * | vol |
| Spline geometry description. | |
Protected Attributes inherited from FieldBase | |
| size_t | nelm |
| Number of elements/knot-spans. | |
| size_t | nno |
| Number of nodes/control points. | |
| Vector | values |
| Nodal field values. | |
Protected Attributes inherited from Field | |
| std::string | fname |
| Name of the field. | |
Private Attributes | |
| unsigned char | nsd |
| Number of space dimensions. | |
Additional Inherited Members | |
Static Public Member Functions inherited from Field | |
| static Field * | create (const ASMbase *pch, const RealArray &v, char basis=1, char cmp=1, const char *name=nullptr) |
| Creates a dynamically allocated field object. More... | |
Protected Member Functions inherited from FieldBase | |
| FieldBase (const char *name=nullptr) | |
| The constructor sets the field name. More... | |
Protected Member Functions inherited from Field | |
| Field (const char *name=nullptr) | |
| The constructor sets the field name. More... | |
Class for spline-based finite element scalar fields in 3D.
This class implements the functions required to evaluate a 3D spline scalar field at a given point in parametrical or physical coordinates.
| SplineField3D::SplineField3D | ( | const ASMs3D * | patch, |
| const RealArray & | v, | ||
| char | basis = 1, |
||
| char | cmp = 1, |
||
| const char * | name = nullptr |
||
| ) |
The constructor sets the number of space dimensions and fields.
| [in] | patch | The spline patch on which the field is to be defined |
| [in] | v | Array of control point field values |
| [in] | basis | Basis to use from patch |
| [in] | cmp | Component to use from source field. Pass 0 to use the vector as-is. |
| [in] | name | Name of spline field |
References basis, utl::vector< T >::begin(), ASMbase::getNoFields(), ASMs3D::getNoNodes(), ASMbase::getNoSpaceDim(), FieldBase::nelm, FieldBase::nno, nsd, utl::vector< T >::resize(), and FieldBase::values.
| SplineField3D::SplineField3D | ( | const Go::SplineVolume * | svol, |
| const RealArray & | v, | ||
| const char * | name = nullptr |
||
| ) |
Construct directly from volume.
| [in] | svol | The spline volume to use |
| [in] | v | Array of control point field values |
| [in] | name | Name of spline field |
References FieldBase::values.
Computes the gradient for a given local coordinate.
| [in] | x | Local coordinate of evaluation point |
| [out] | grad | Gradient of solution in a given local coordinate |
Implements Field.
References basis, SplineField::evalBasis(), SplineField::evalMapping(), utl::gather(), utl::matrix< T >::multiply(), FieldBase::values, and vol.
Computes the hessian for a given local coordinate.
| [in] | x | Local coordinate of evaluation point |
| [out] | H | Hessian of solution in a given local coordinate |
Reimplemented from Field.
References basis, SplineField::evalBasis(), SplineField::evalMapping(), utl::gather(), utl::matrix3d< T >::multiply(), utl::matrix< T >::resize(), FieldBase::values, and vol.
|
virtual |
|
virtual |
Computes the value at a given local coordinate.
| [in] | x | Local coordinate of evaluation point |
Implements Field.
References basis, utl::vector< T >::dot(), utl::gather(), ASMs3D::scatterInd(), ItgPoint::u, ItgPoint::v, FieldBase::values, and ItgPoint::w.
Referenced by valueCoor().
|
virtual |
Computes the value at a grid of visualization points.
| [out] | val | Field values at the visualization points |
| [in] | npe | Number of visualization nodes over each knot span |
Reimplemented from Field.
References basis, utl::vector< T >::dot(), utl::gather(), ASMs3D::scatterInd(), and FieldBase::values.
|
virtual |
Computes the value in a given node/control point.
| [in] | node | Node number |
Implements Field.
References FieldBase::nno, and FieldBase::values.