Changeset 17729


Ignore:
Timestamp:
04/14/14 16:50:29 (11 years ago)
Author:
Mathieu Morlighem
Message:

CHG: fixed spawn for gmesh tetras

Location:
issm/trunk-jpl/src/c/classes/Elements
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk-jpl/src/c/classes/Elements/Tetra.cpp

    r17694 r17729  
    107107
    108108        IssmDouble values[NUMVERTICES];
    109         int        indices[4][3] = {{0,1,2},{0,1,3},{1,2,3},{2,0,3}};
     109        //int        indices[4][3] = {{0,1,2},{0,1,3},{1,2,3},{2,0,3}};
     110        int        indices[4][3] = {{0,1,2},{3,1,0},{3,2,1},{3,0,2}};
    110111
    111112        /*Retrieve all inputs and parameters*/
     
    219220
    220221}/*}}}*/
     222/*FUNCTION Tetra::GetXcoord {{{*/
     223IssmDouble Tetra::GetXcoord(Gauss* gauss){
     224
     225        int    i;
     226        IssmDouble z;
     227        IssmDouble xyz_list[NUMVERTICES][3];
     228        IssmDouble z_list[NUMVERTICES];
     229
     230        ::GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES);
     231        for(i=0;i<NUMVERTICES;i++) z_list[i]=xyz_list[i][0];
     232        TetraRef::GetInputValue(&z,&z_list[0],(GaussTetra*)gauss,P1Enum);
     233
     234        return z;
     235}
     236/*}}}*/
     237/*FUNCTION Tetra::GetYcoord {{{*/
     238IssmDouble Tetra::GetYcoord(Gauss* gauss){
     239
     240        int    i;
     241        IssmDouble z;
     242        IssmDouble xyz_list[NUMVERTICES][3];
     243        IssmDouble z_list[NUMVERTICES];
     244
     245        ::GetVerticesCoordinates(&xyz_list[0][0],vertices,NUMVERTICES);
     246        for(i=0;i<NUMVERTICES;i++) z_list[i]=xyz_list[i][1];
     247        TetraRef::GetInputValue(&z,&z_list[0],(GaussTetra*)gauss,P1Enum);
     248
     249        return z;
     250}
     251/*}}}*/
    221252/*FUNCTION Tetra::GetZcoord {{{*/
    222253IssmDouble Tetra::GetZcoord(Gauss* gauss){
  • issm/trunk-jpl/src/c/classes/Elements/Tetra.h

    r17694 r17729  
    112112                void        GetInputValue(IssmDouble* pvalue,Node* node,int enumtype){_error_("not implemented yet");};
    113113                Node*       GetNode(int node_number){_error_("Not implemented");};
    114                 IssmDouble  GetXcoord(Gauss* gauss){_error_("Not implemented");};
    115                 IssmDouble  GetYcoord(Gauss* gauss){_error_("Not implemented");};
     114                IssmDouble  GetXcoord(Gauss* gauss);
     115                IssmDouble  GetYcoord(Gauss* gauss);
    116116                IssmDouble  GetZcoord(Gauss* gauss);
    117117                int         GetElementType(void);
Note: See TracChangeset for help on using the changeset viewer.