MOAB: Mesh Oriented datABase
(version 5.4.1)
|
#include <RefMeshTargetCalculator.hpp>
Public Member Functions | |
MESQUITE_EXPORT | RefMeshTargetCalculator (ReferenceMeshInterface *ref_mesh, bool orient_2d=false) |
virtual MESQUITE_EXPORT | ~RefMeshTargetCalculator () |
virtual MESQUITE_EXPORT bool | get_3D_target (PatchData &pd, size_t element, Sample sample, MsqMatrix< 3, 3 > &W_out, MsqError &err) |
Get a target matrix. | |
virtual MESQUITE_EXPORT bool | get_2D_target (PatchData &pd, size_t element, Sample sample, MsqMatrix< 2, 2 > &W_out, MsqError &err) |
Get a target matrix. | |
virtual MESQUITE_EXPORT bool | get_surface_target (PatchData &pd, size_t element, Sample sample, MsqMatrix< 3, 2 > &W_out, MsqError &err) |
Get a target matrix. | |
virtual bool | have_surface_orient () const |
Use 3x2 W for surface elements if true, 2x2 W if false. | |
Private Attributes | |
ReferenceMeshInterface * | refMesh |
bool | orient2D |
Definition at line 47 of file RefMeshTargetCalculator.hpp.
MESQUITE_EXPORT MBMesquite::RefMeshTargetCalculator::RefMeshTargetCalculator | ( | ReferenceMeshInterface * | ref_mesh, |
bool | orient_2d = false |
||
) | [inline] |
Definition at line 50 of file RefMeshTargetCalculator.hpp.
Definition at line 42 of file RefMeshTargetCalculator.cpp.
{}
bool MBMesquite::RefMeshTargetCalculator::get_2D_target | ( | PatchData & | pd, |
size_t | element, | ||
Sample | sample, | ||
MsqMatrix< 2, 2 > & | W_out, | ||
MsqError & | err | ||
) | [virtual] |
Get a target matrix.
pd | The current PatchData |
element | The index an element within the patch data. |
sample | The sample point in the element. |
W_out | The resulting target matrix. |
Implements MBMesquite::TargetCalculator.
Definition at line 64 of file RefMeshTargetCalculator.cpp.
References MBMesquite::TargetCalculator::factor_surface(), get_surface_target(), and MSQ_CHKERR.
{ MsqMatrix< 3, 2 > W_orient; bool valid = get_surface_target( pd, element, sample, W_orient, err ); if( MSQ_CHKERR( err ) || !valid ) return false; MsqMatrix< 3, 2 > V; MsqMatrix< 2, 2 > Q, delta; double lambda; valid = factor_surface( W_orient, lambda, V, Q, delta, err ); W_out = lambda * Q * delta; return !MSQ_CHKERR( err ) && valid; }
bool MBMesquite::RefMeshTargetCalculator::get_3D_target | ( | PatchData & | pd, |
size_t | element, | ||
Sample | sample, | ||
MsqMatrix< 3, 3 > & | W_out, | ||
MsqError & | err | ||
) | [virtual] |
Get a target matrix.
pd | The current PatchData |
element | The index an element within the patch data. |
sample | The sample point in the element. |
W_out | The resulting target matrix. |
Implements MBMesquite::TargetCalculator.
Definition at line 44 of file RefMeshTargetCalculator.cpp.
References MBMesquite::TargetCalculator::get_refmesh_Jacobian_3D(), MSQ_CHKERR, and refMesh.
{ get_refmesh_Jacobian_3D( refMesh, pd, element, sample, W_out, err ); return !MSQ_CHKERR( err ); }
bool MBMesquite::RefMeshTargetCalculator::get_surface_target | ( | PatchData & | pd, |
size_t | element, | ||
Sample | sample, | ||
MsqMatrix< 3, 2 > & | W_out, | ||
MsqError & | err | ||
) | [virtual] |
Get a target matrix.
pd | The current PatchData |
element | The index an element within the patch data. |
sample | The sample point in the element. |
W_out | The resulting target matrix. |
Implements MBMesquite::TargetCalculator.
Definition at line 54 of file RefMeshTargetCalculator.cpp.
References MBMesquite::TargetCalculator::get_refmesh_Jacobian_2D(), MSQ_CHKERR, and refMesh.
Referenced by get_2D_target().
{ get_refmesh_Jacobian_2D( refMesh, pd, element, sample, W_out, err ); return !MSQ_CHKERR( err ); }
virtual bool MBMesquite::RefMeshTargetCalculator::have_surface_orient | ( | ) | const [inline, virtual] |
Use 3x2 W for surface elements if true, 2x2 W if false.
If true, then the targets for surface elements attempt some control of orientation and therefore get_surface_target must be used to get the targets. If false, then the target contains no orientation data and is therefore the same as the corresponding 2D target for surface elements. In this case, get_2D_target should be used.
Implements MBMesquite::TargetCalculator.
Definition at line 96 of file RefMeshTargetCalculator.hpp.
References orient2D.
{ return orient2D; }
bool MBMesquite::RefMeshTargetCalculator::orient2D [private] |
Definition at line 103 of file RefMeshTargetCalculator.hpp.
Referenced by have_surface_orient().
Definition at line 102 of file RefMeshTargetCalculator.hpp.
Referenced by get_3D_target(), and get_surface_target().