#include <SpectralQuad.hpp>
|
static ErrorCode | evalFcn (const double *params, const double *field, const int ndim, const int num_tuples, double *work, double *result) |
| Forward-evaluation of field at parametric coordinates. More...
|
|
static ErrorCode | reverseEvalFcn (EvalFcn eval, JacobianFcn jacob, InsideFcn ins, const double *posn, const double *verts, const int nverts, const int ndim, const double iter_tol, const double inside_tol, double *work, double *params, int *is_inside) |
| Reverse-evaluation of parametric coordinates at physical space position. More...
|
|
static ErrorCode | jacobianFcn (const double *params, const double *verts, const int nverts, const int ndim, double *work, double *result) |
| Evaluate the jacobian at a specified parametric position. More...
|
|
static ErrorCode | integrateFcn (const double *field, const double *verts, const int nverts, const int ndim, const int num_tuples, double *work, double *result) |
| Forward-evaluation of field at parametric coordinates. More...
|
|
static ErrorCode | initFcn (const double *verts, const int nverts, double *&work) |
| Initialize this EvalSet. More...
|
|
static int | insideFcn (const double *params, const int ndim, const double tol) |
| Function that returns whether or not the parameters are inside the natural space of the element. More...
|
|
static EvalSet | eval_set () |
|
static bool | compatible (EntityType tp, int numv, EvalSet &eset) |
|
Definition at line 12 of file SpectralQuad.hpp.
◆ compatible()
static bool moab::SpectralQuad::compatible |
( |
EntityType |
tp, |
|
|
int |
numv, |
|
|
EvalSet & |
eset |
|
) |
| |
|
inlinestatic |
Definition at line 66 of file SpectralQuad.hpp.
67 {
68 if( tp != MBQUAD ) return false;
69 int i;
70 for( i = 3; i * i == numv || i * i > numv; i++ )
71 ;
72 if( i * i != numv ) return false;
73 eset = eval_set();
74 return true;
75 }
References eval_set(), and MBQUAD.
◆ eval_set()
static EvalSet moab::SpectralQuad::eval_set |
( |
| ) |
|
|
inlinestatic |
◆ evalFcn()
CartVect moab::SpectralQuad::evalFcn |
( |
const double * |
params, |
|
|
const double * |
field, |
|
|
const int |
ndim, |
|
|
const int |
num_tuples, |
|
|
double * |
work, |
|
|
double * |
result |
|
) |
| |
|
static |
Forward-evaluation of field at parametric coordinates.
Definition at line 78 of file SpectralQuad.cpp.
84 {
85
86 int d = 0;
87 for( d = 0; d < 2; d++ )
88 {
89 lagrange_0( &_ld[d], params[d] );
90 }
91 CartVect result;
92 for( d = 0; d < 3; d++ )
93 {
94 result[d] = tensor_i2( _ld[0].J, _ld[0].n, _ld[1].J, _ld[1].n, _xyz[d], _odwork );
95 }
96 return result;
97 }
References moab::Element::SpectralQuad::_ld, moab::Element::SpectralQuad::_odwork, moab::Element::SpectralQuad::_xyz, lagrange_0(), and tensor_i2().
Referenced by eval_set().
◆ initFcn()
static ErrorCode moab::SpectralQuad::initFcn |
( |
const double * |
verts, |
|
|
const int |
nverts, |
|
|
double *& |
work |
|
) |
| |
|
static |
◆ insideFcn()
int moab::SpectralQuad::insideFcn |
( |
const double * |
params, |
|
|
const int |
ndim, |
|
|
const double |
tol |
|
) |
| |
|
static |
Function that returns whether or not the parameters are inside the natural space of the element.
Definition at line 166 of file SpectralQuad.cpp.
167 {
168 return EvalSet::inside( params, ndim, tol );
169 }
◆ integrateFcn()
static ErrorCode moab::SpectralQuad::integrateFcn |
( |
const double * |
field, |
|
|
const double * |
verts, |
|
|
const int |
nverts, |
|
|
const int |
ndim, |
|
|
const int |
num_tuples, |
|
|
double * |
work, |
|
|
double * |
result |
|
) |
| |
|
static |
Forward-evaluation of field at parametric coordinates.
Referenced by eval_set().
◆ jacobianFcn()
static ErrorCode moab::SpectralQuad::jacobianFcn |
( |
const double * |
params, |
|
|
const double * |
verts, |
|
|
const int |
nverts, |
|
|
const int |
ndim, |
|
|
double * |
work, |
|
|
double * |
result |
|
) |
| |
|
static |
Evaluate the jacobian at a specified parametric position.
Referenced by eval_set().
◆ reverseEvalFcn()
bool moab::SpectralQuad::reverseEvalFcn |
( |
EvalFcn |
eval, |
|
|
JacobianFcn |
jacob, |
|
|
InsideFcn |
ins, |
|
|
const double * |
posn, |
|
|
const double * |
verts, |
|
|
const int |
nverts, |
|
|
const int |
ndim, |
|
|
const double |
iter_tol, |
|
|
const double |
inside_tol, |
|
|
double * |
work, |
|
|
double * |
params, |
|
|
int * |
is_inside |
|
) |
| |
|
static |
Reverse-evaluation of parametric coordinates at physical space position.
Definition at line 99 of file SpectralQuad.cpp.
108 {
109 params = init;
110
111
112 double x_star[3];
113 xyz.get( x_star );
114
115 double r[2] = { 0, 0 };
116 unsigned c = opt_no_constraints_3;
117 double dist = opt_findpt_2( &_data, (const double**)_xyz, x_star, r, &c );
118
119 if( dist > 0.9e+30 )
120 {
121 std::vector< CartVect > dummy;
122 throw Map::EvaluationError( CartVect( x_star ), dummy );
123 }
124
125
126
127 params = r;
128
129 return insideFcn( params, 2, inside_tol );
130 }
References moab::Element::SpectralQuad::_data, moab::Element::SpectralQuad::_xyz, opt_findpt_2(), and opt_no_constraints_3.
Referenced by eval_set().
◆ _data
◆ _glpoints
real * moab::SpectralQuad::_glpoints |
|
staticprotected |
◆ _init
bool moab::SpectralQuad::_init = false |
|
staticprotected |
◆ _ld
◆ _n
int moab::SpectralQuad::_n |
|
staticprotected |
◆ _odwork
real * moab::SpectralQuad::_odwork |
|
staticprotected |
◆ _z
real * moab::SpectralQuad::_z |
|
staticprotected |
The documentation for this class was generated from the following files: