-
Notifications
You must be signed in to change notification settings - Fork 64
/
Copy pathapfComplex.h
58 lines (46 loc) · 1.84 KB
/
apfComplex.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
#ifndef APFCOMPLEX_H_
#define APFCOMPLEX_H_
#include "apfComplexType.h"
#include "apfElementType.h"
namespace apf
{
// forward decls for the interface
class ComplexField;
class Mesh;
class FieldShape;
class MeshEntity;
class VectorElement;
typedef VectorElement MeshElement;
class Vector3;
template <class T>
class NewArray;
ComplexField* createComplexPackedField(Mesh* m,
const char* name,
int components,
FieldShape* shape = NULL);
void freeze(ComplexField* f);
void unfreeze(ComplexField* f);
bool isFrozen(ComplexField* f);
/** \brief Return the contiguous array storing this field.
\details This function is only defined for fields
which are using array storage, for which apf::isFrozen
returns true.
\note If the underlying field data type is NOT double_complex,
this will cause an assert fail in all compile modes.
*/
double_complex* getComplexArrayData(ComplexField * f);
void zeroField(ComplexField* f);
void setComponents(ComplexField* f, MeshEntity* e, int node, double_complex const * components);
void getComponents(ComplexField* f, MeshEntity* e, int node, double_complex * components);
ComplexElement* createElement(ComplexField* f, MeshElement* e);
ComplexElement* createElement(ComplexField* f, MeshEntity* e);
void destroyElement(ComplexElement* e);
MeshElement* getMeshElement(ComplexElement* e);
MeshEntity* getMeshEntity(ComplexElement* e);
void getComponents(ComplexElement* e, Vector3 const& param, double_complex* components);
int countNodes(ComplexElement* e);
void getShapeValues(ComplexElement* e, Vector3 const& local, NewArray<double>& values);
void getShapeGrads(ComplexElement* e, Vector3 const& local, NewArray<double>& grades);
void getPackedNodes(ComplexElement* e, NewArray<double_complex>& values);
}
#endif