/[escript]/trunk/finley/src/Mesh_rec8.cpp
ViewVC logotype

Diff of /trunk/finley/src/Mesh_rec8.cpp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 4491 by caltinay, Fri May 31 07:09:03 2013 UTC revision 4492 by caltinay, Tue Jul 2 01:44:11 2013 UTC
# Line 41  Finley_Mesh* Finley_RectangularMesh_Rec8 Line 41  Finley_Mesh* Finley_RectangularMesh_Rec8
41    dim_t N0,N1,NE0,NE1,i0,i1,k,Nstride0=0,Nstride1=0;    dim_t N0,N1,NE0,NE1,i0,i1,k,Nstride0=0,Nstride1=0;
42    dim_t totalNECount,faceNECount,NDOF0=0,NDOF1=0,NFaceElements,NN, local_NE0, local_NE1, local_N0=0, local_N1=0;    dim_t totalNECount,faceNECount,NDOF0=0,NDOF1=0,NFaceElements,NN, local_NE0, local_NE1, local_N0=0, local_N1=0;
43    index_t e_offset1, e_offset0, offset0=0, offset1=0, global_i0, global_i1;    index_t e_offset1, e_offset0, offset0=0, offset1=0, global_i0, global_i1;
44    Finley_ReferenceElementSet *refPoints=NULL, *refContactElements=NULL, *refFaceElements=NULL, *refElements=NULL;    ReferenceElementSet *refPoints=NULL, *refContactElements=NULL, *refFaceElements=NULL, *refElements=NULL;
45    index_t node0, myRank;    index_t node0, myRank;
46    Finley_Mesh* out;    Finley_Mesh* out;
47    Esys_MPIInfo *mpi_info = NULL;    Esys_MPIInfo *mpi_info = NULL;
# Line 75  Finley_Mesh* Finley_RectangularMesh_Rec8 Line 75  Finley_Mesh* Finley_RectangularMesh_Rec8
75    if (generateAllNodes) {    if (generateAllNodes) {
76       /* Finley_setError(SYSTEM_ERROR,"full element order for Hex elements is not supported yet."); */       /* Finley_setError(SYSTEM_ERROR,"full element order for Hex elements is not supported yet."); */
77       if (useMacroElements) {       if (useMacroElements) {
78            refElements= Finley_ReferenceElementSet_alloc(Finley_Rec9Macro,order,reduced_order);            refElements= ReferenceElementSet_alloc(Rec9Macro,order,reduced_order);
79       } else {       } else {
80            refElements=Finley_ReferenceElementSet_alloc(Finley_Rec9, order,reduced_order);            refElements=ReferenceElementSet_alloc(Rec9, order,reduced_order);
81       }       }
82       if (useElementsOnFace) {       if (useElementsOnFace) {
83           Finley_setError(SYSTEM_ERROR,"rich elements for Finley_Rec9 elements is not supported yet.");           Finley_setError(SYSTEM_ERROR,"rich elements for Finley_Rec9 elements is not supported yet.");
84       } else {       } else {
85           if (useMacroElements) {           if (useMacroElements) {
86               refFaceElements=Finley_ReferenceElementSet_alloc(Finley_Line3Macro, order, reduced_order);               refFaceElements=ReferenceElementSet_alloc(Line3Macro, order, reduced_order);
87           } else {           } else {
88               refFaceElements=Finley_ReferenceElementSet_alloc(Finley_Line3, order, reduced_order);               refFaceElements=ReferenceElementSet_alloc(Line3, order, reduced_order);
89           }           }
90           refContactElements=Finley_ReferenceElementSet_alloc(Finley_Line3_Contact, order, reduced_order);           refContactElements=ReferenceElementSet_alloc(Line3_Contact, order, reduced_order);
91       }       }
92    
93    } else  {    } else  {
94       refElements= Finley_ReferenceElementSet_alloc(Finley_Rec8,order,reduced_order);       refElements= ReferenceElementSet_alloc(Rec8,order,reduced_order);
95       if (useElementsOnFace) {       if (useElementsOnFace) {
96           refFaceElements= Finley_ReferenceElementSet_alloc(Finley_Rec8Face ,order,reduced_order);           refFaceElements= ReferenceElementSet_alloc(Rec8Face ,order,reduced_order);
97           refContactElements=Finley_ReferenceElementSet_alloc(Finley_Rec8Face_Contact, order, reduced_order);           refContactElements=ReferenceElementSet_alloc(Rec8Face_Contact, order, reduced_order);
98    
99       } else {       } else {
100           refFaceElements= Finley_ReferenceElementSet_alloc(Finley_Line3 ,order,reduced_order);           refFaceElements= ReferenceElementSet_alloc(Line3 ,order,reduced_order);
101           refContactElements=Finley_ReferenceElementSet_alloc(Finley_Line3_Contact, order, reduced_order);           refContactElements=ReferenceElementSet_alloc(Line3_Contact, order, reduced_order);
102    
103       }       }
104    }    }
105    refPoints=Finley_ReferenceElementSet_alloc(Finley_Point1, order, reduced_order);    refPoints=ReferenceElementSet_alloc(Point1, order, reduced_order);
106    
107    
108    if ( Finley_noError()) {    if ( Finley_noError()) {
# Line 342  Finley_Mesh* Finley_RectangularMesh_Rec8 Line 342  Finley_Mesh* Finley_RectangularMesh_Rec8
342        Finley_Mesh_free(out);        Finley_Mesh_free(out);
343     }     }
344      /* free up memory */      /* free up memory */
345      Finley_ReferenceElementSet_dealloc(refPoints);      ReferenceElementSet_dealloc(refPoints);
346      Finley_ReferenceElementSet_dealloc(refContactElements);      ReferenceElementSet_dealloc(refContactElements);
347      Finley_ReferenceElementSet_dealloc(refFaceElements);      ReferenceElementSet_dealloc(refFaceElements);
348      Finley_ReferenceElementSet_dealloc(refElements);      ReferenceElementSet_dealloc(refElements);
349      Esys_MPIInfo_free( mpi_info );        Esys_MPIInfo_free( mpi_info );  
350    
351     return out;     return out;

Legend:
Removed from v.4491  
changed lines
  Added in v.4492

  ViewVC Help
Powered by ViewVC 1.1.26