| 1 | /*!\file Numericalflux.h
|
|---|
| 2 | * \brief: header file for icefront object
|
|---|
| 3 | */
|
|---|
| 4 |
|
|---|
| 5 | #ifndef _NUMERICALFLUX_H_
|
|---|
| 6 | #define _NUMERICALFLUX_H_
|
|---|
| 7 |
|
|---|
| 8 | /*Headers:*/
|
|---|
| 9 | #include "./Load.h"
|
|---|
| 10 | class Hook;
|
|---|
| 11 | class Parameters;
|
|---|
| 12 | class Inputs;
|
|---|
| 13 | class IoModel;
|
|---|
| 14 | class Element;
|
|---|
| 15 | class Vertex;
|
|---|
| 16 | class ElementMatrix;
|
|---|
| 17 | class ElementVector;
|
|---|
| 18 |
|
|---|
| 19 | class Numericalflux: public Load {
|
|---|
| 20 |
|
|---|
| 21 | public:
|
|---|
| 22 | int id;
|
|---|
| 23 | int analysis_type;
|
|---|
| 24 | int flux_type;
|
|---|
| 25 |
|
|---|
| 26 | /*Hooks*/
|
|---|
| 27 | Hook *helement;
|
|---|
| 28 | Hook *hnodes;
|
|---|
| 29 | Hook *hvertices;
|
|---|
| 30 |
|
|---|
| 31 | /*Corresponding fields*/
|
|---|
| 32 | Element *element;
|
|---|
| 33 | Vertex **vertices;
|
|---|
| 34 | Node **nodes;
|
|---|
| 35 | Parameters *parameters;
|
|---|
| 36 |
|
|---|
| 37 | /*Numericalflux constructors,destructors {{{*/
|
|---|
| 38 | Numericalflux();
|
|---|
| 39 | Numericalflux(int numericalflux_id,int i,int index,IoModel* iomodel,int analysis_type);
|
|---|
| 40 | ~Numericalflux();
|
|---|
| 41 | /*}}}*/
|
|---|
| 42 | /*Object virtual functions definitions:{{{ */
|
|---|
| 43 | void Echo();
|
|---|
| 44 | void DeepEcho();
|
|---|
| 45 | int Id();
|
|---|
| 46 | int ObjectEnum();
|
|---|
| 47 | Object *copy();
|
|---|
| 48 | /*}}}*/
|
|---|
| 49 | /*Update virtual functions resolution: {{{*/
|
|---|
| 50 | void InputUpdateFromVector(IssmDouble* vector, int name, int type){/*Do nothing*/}
|
|---|
| 51 | void InputUpdateFromMatrixDakota(IssmDouble* matrix, int nrows, int ncols, int name, int type){/*Do nothing*/}
|
|---|
| 52 | void InputUpdateFromVectorDakota(IssmDouble* vector, int name, int type){/*Do nothing*/}
|
|---|
| 53 | void InputUpdateFromConstant(IssmDouble constant, int name){/*Do nothing*/};
|
|---|
| 54 | void InputUpdateFromConstant(int constant, int name){/*Do nothing*/};
|
|---|
| 55 | void InputUpdateFromConstant(bool constant, int name){_error_("Not implemented yet!");}
|
|---|
| 56 | void InputUpdateFromIoModel(int index, IoModel* iomodel){_error_("not implemented yet");};
|
|---|
| 57 | /*}}}*/
|
|---|
| 58 | /*Load virtual functions definitions: {{{*/
|
|---|
| 59 | void Configure(Elements* elements,Loads* loads,Nodes* nodes,Vertices* vertices,Materials* materials,Parameters* parameters);
|
|---|
| 60 | void SetCurrentConfiguration(Elements* elements,Loads* loads,Nodes* nodes,Vertices* vertices,Materials* materials,Parameters* parameters);
|
|---|
| 61 | void CreateKMatrix(Matrix<IssmDouble>* Kff, Matrix<IssmDouble>* Kfs);
|
|---|
| 62 | void CreatePVector(Vector<IssmDouble>* pf);
|
|---|
| 63 | void GetNodesSidList(int* sidlist);
|
|---|
| 64 | void GetNodesLidList(int* lidlist);
|
|---|
| 65 | int GetNumberOfNodes(void);
|
|---|
| 66 | void CreateJacobianMatrix(Matrix<IssmDouble>* Jff){_error_("Not implemented yet");};
|
|---|
| 67 | bool IsPenalty(void);
|
|---|
| 68 | void PenaltyCreateJacobianMatrix(Matrix<IssmDouble>* Jff,IssmDouble kmax){_error_("Not implemented yet");};
|
|---|
| 69 | void PenaltyCreateKMatrix(Matrix<IssmDouble>* Kff, Matrix<IssmDouble>* kfs, IssmDouble kmax);
|
|---|
| 70 | void PenaltyCreatePVector(Vector<IssmDouble>* pf, IssmDouble kmax);
|
|---|
| 71 | void SetwiseNodeConnectivity(int* d_nz,int* o_nz,Node* node,bool* flags,int* flagsindices,int set1_enum,int set2_enum);
|
|---|
| 72 | bool InAnalysis(int analysis_type);
|
|---|
| 73 | /*}}}*/
|
|---|
| 74 | /*Numericalflux management:{{{*/
|
|---|
| 75 | void GetNormal(IssmDouble* normal,IssmDouble xyz_list[4][3]);
|
|---|
| 76 | ElementMatrix* CreateKMatrixMasstransport(void);
|
|---|
| 77 | ElementMatrix* CreateKMatrixMasstransportInternal(void);
|
|---|
| 78 | ElementMatrix* CreateKMatrixMasstransportBoundary(void);
|
|---|
| 79 | ElementMatrix* CreateKMatrixBalancethickness(void);
|
|---|
| 80 | ElementMatrix* CreateKMatrixBalancethicknessInternal(void);
|
|---|
| 81 | ElementMatrix* CreateKMatrixBalancethicknessBoundary(void);
|
|---|
| 82 | ElementMatrix* CreateKMatrixAdjointBalancethickness(void);
|
|---|
| 83 | ElementMatrix* CreateKMatrixAdjointBalancethicknessInternal(void);
|
|---|
| 84 | ElementMatrix* CreateKMatrixAdjointBalancethicknessBoundary(void);
|
|---|
| 85 | ElementVector* CreatePVectorMasstransport(void);
|
|---|
| 86 | ElementVector* CreatePVectorMasstransportInternal(void);
|
|---|
| 87 | ElementVector* CreatePVectorMasstransportBoundary(void);
|
|---|
| 88 | ElementVector* CreatePVectorBalancethickness(void);
|
|---|
| 89 | ElementVector* CreatePVectorBalancethicknessInternal(void);
|
|---|
| 90 | ElementVector* CreatePVectorBalancethicknessBoundary(void);
|
|---|
| 91 | ElementVector* CreatePVectorAdjointBalancethickness(void);
|
|---|
| 92 | /*}}}*/
|
|---|
| 93 |
|
|---|
| 94 | };
|
|---|
| 95 |
|
|---|
| 96 | #endif /* _NUMERICALFLUX_H_ */
|
|---|