[13980] | 1 | Index: ../trunk-jpl/src/c/classes/objects/Elements/Tria.cpp
|
---|
| 2 | ===================================================================
|
---|
| 3 | --- ../trunk-jpl/src/c/classes/objects/Elements/Tria.cpp (revision 13902)
|
---|
| 4 | +++ ../trunk-jpl/src/c/classes/objects/Elements/Tria.cpp (revision 13903)
|
---|
| 5 | @@ -161,7 +161,7 @@
|
---|
| 6 | }
|
---|
| 7 | }
|
---|
| 8 | /*}}}*/
|
---|
| 9 | -/*FUNCTION Tria::GetDofList {{{*/
|
---|
| 10 | +/*FUNCTION Tria::SetwiseNodeConnectivity{{{*/
|
---|
| 11 | void Tria::SetwiseNodeConnectivity(int* pd_nz,int* po_nz,Node* node,bool* flags,int set1_enum,int set2_enum){
|
---|
| 12 |
|
---|
| 13 | int index;
|
---|
| 14 | Index: ../trunk-jpl/src/c/classes/objects/Elements/Penta.cpp
|
---|
| 15 | ===================================================================
|
---|
| 16 | --- ../trunk-jpl/src/c/classes/objects/Elements/Penta.cpp (revision 13902)
|
---|
| 17 | +++ ../trunk-jpl/src/c/classes/objects/Elements/Penta.cpp (revision 13903)
|
---|
| 18 | @@ -2606,6 +2606,69 @@
|
---|
| 19 | else this->nodes=NULL;
|
---|
| 20 | }
|
---|
| 21 | /*}}}*/
|
---|
| 22 | +/*FUNCTION Penta::SetwiseNodeConnectivity{{{*/
|
---|
| 23 | +void Penta::SetwiseNodeConnectivity(int* pd_nz,int* po_nz,Node* node,bool* flags,int set1_enum,int set2_enum){
|
---|
| 24 | +
|
---|
| 25 | + int index;
|
---|
| 26 | + int set_enum;
|
---|
| 27 | +
|
---|
| 28 | + /*Find node index*/
|
---|
| 29 | + index = this->GetNodeIndex(node);
|
---|
| 30 | +
|
---|
| 31 | + /*Output */
|
---|
| 32 | + int d_nz = 0;
|
---|
| 33 | + int o_nz = 0;
|
---|
| 34 | +
|
---|
| 35 | + /*Loop over all nodes*/
|
---|
| 36 | + for(int i=0;i<6;i++){
|
---|
| 37 | +
|
---|
| 38 | + if(!flags[this->nodes[i]->Sid()]){
|
---|
| 39 | +
|
---|
| 40 | + /*flag current node so that no other element processes it*/
|
---|
| 41 | + flags[this->nodes[i]->Sid()]=true;
|
---|
| 42 | +
|
---|
| 43 | + /*What set are we interested in?*/
|
---|
| 44 | + if(i!=index)
|
---|
| 45 | + set_enum=set2_enum;
|
---|
| 46 | + else
|
---|
| 47 | + set_enum=set1_enum;
|
---|
| 48 | +
|
---|
| 49 | + /*if node is clone, we have an off-diagonal non-zero, else it is a diagonal non-zero*/
|
---|
| 50 | + switch(set2_enum){
|
---|
| 51 | + case FsetEnum:
|
---|
| 52 | + if(nodes[i]->indexing.fsize){
|
---|
| 53 | + if(this->nodes[i]->IsClone())
|
---|
| 54 | + o_nz += 1;
|
---|
| 55 | + else
|
---|
| 56 | + d_nz += 1;
|
---|
| 57 | + }
|
---|
| 58 | + break;
|
---|
| 59 | + case GsetEnum:
|
---|
| 60 | + if(nodes[i]->indexing.gsize){
|
---|
| 61 | + if(this->nodes[i]->IsClone())
|
---|
| 62 | + o_nz += 1;
|
---|
| 63 | + else
|
---|
| 64 | + d_nz += 1;
|
---|
| 65 | + }
|
---|
| 66 | + break;
|
---|
| 67 | + case SsetEnum:
|
---|
| 68 | + if(nodes[i]->indexing.ssize){
|
---|
| 69 | + if(this->nodes[i]->IsClone())
|
---|
| 70 | + o_nz += 1;
|
---|
| 71 | + else
|
---|
| 72 | + d_nz += 1;
|
---|
| 73 | + }
|
---|
| 74 | + break;
|
---|
| 75 | + default: _error_("not supported");
|
---|
| 76 | + }
|
---|
| 77 | + }
|
---|
| 78 | + }
|
---|
| 79 | +
|
---|
| 80 | + /*Assign output pointers: */
|
---|
| 81 | + *pd_nz=d_nz;
|
---|
| 82 | + *po_nz=o_nz;
|
---|
| 83 | +}
|
---|
| 84 | +/*}}}*/
|
---|
| 85 | /*FUNCTION Penta::SpawnTria {{{*/
|
---|
| 86 | Tria* Penta::SpawnTria(int g0, int g1, int g2){
|
---|
| 87 |
|
---|
| 88 | Index: ../trunk-jpl/src/c/classes/objects/Elements/Penta.h
|
---|
| 89 | ===================================================================
|
---|
| 90 | --- ../trunk-jpl/src/c/classes/objects/Elements/Penta.h (revision 13902)
|
---|
| 91 | +++ ../trunk-jpl/src/c/classes/objects/Elements/Penta.h (revision 13903)
|
---|
| 92 | @@ -79,7 +79,7 @@
|
---|
| 93 | void ComputeStressTensor();
|
---|
| 94 | void Configure(Elements* elements,Loads* loads,DataSet* nodes,Materials* materials,Parameters* parameters);
|
---|
| 95 | void SetCurrentConfiguration(Elements* elements,Loads* loads,DataSet* nodes,Materials* materials,Parameters* parameters);
|
---|
| 96 | - void SetwiseNodeConnectivity(int* d_nz,int* o_nz,Node* node,bool* flags,int set1_enum,int set2_enum){_error_("not implemented yet");};
|
---|
| 97 | + void SetwiseNodeConnectivity(int* d_nz,int* o_nz,Node* node,bool* flags,int set1_enum,int set2_enum);
|
---|
| 98 | void CreateKMatrix(Matrix<IssmDouble>* Kff, Matrix<IssmDouble>* Kfs,Vector<IssmDouble>* df);
|
---|
| 99 | void CreatePVector(Vector<IssmDouble>* pf);
|
---|
| 100 | void CreateJacobianMatrix(Matrix<IssmDouble>* Jff);
|
---|