Changeset 5906
- Timestamp:
- 09/20/10 10:22:33 (14 years ago)
- Location:
- issm/trunk/src/c
- Files:
-
- 1 deleted
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk/src/c/Makefile.am
r5891 r5906 267 267 ./shared/Sorting/sorting.h\ 268 268 ./shared/Elements/elements.h\ 269 ./shared/Elements/ResolvePointers.cpp\270 269 ./shared/Elements/Paterson.cpp\ 271 270 ./shared/Elements/GetVerticesCoordinates.cpp\ … … 823 822 ./shared/Sorting/sorting.h\ 824 823 ./shared/Elements/elements.h\ 825 ./shared/Elements/ResolvePointers.cpp\826 824 ./shared/Elements/Paterson.cpp\ 827 825 ./shared/Elements/GetVerticesCoordinates.cpp\ -
issm/trunk/src/c/shared/Elements/GetVerticesCoordinates.cpp
r3685 r5906 5 5 #include "../../objects/objects.h" 6 6 7 int GetVerticesCoordinates( double* xyz, Node** nodes, int num grids){7 int GetVerticesCoordinates( double* xyz, Node** nodes, int numvertices){ 8 8 9 int i; 9 /*In debugging mode, check that nodes is not a NULL pointer*/ 10 ISSMASSERT(nodes); 10 11 11 for ( i=0; i<numgrids;i++) {12 for(int i=0;i<numvertices;i++) { 12 13 xyz[i*3+0]=nodes[i]->GetX(); 13 14 xyz[i*3+1]=nodes[i]->GetY(); 14 15 xyz[i*3+2]=nodes[i]->GetZ(); 15 16 } 16 17 17 } 18 -
issm/trunk/src/c/shared/Elements/elements.h
r4385 r5906 9 9 #include "../../Container/Container.h" 10 10 11 void ResolvePointers(Object** objects,int* object_ids,int* object_offsets,int num_objects,DataSet* dataset);12 11 double Paterson(double temperature); 13 int GetVerticesCoordinates(double* xyz, Node** nodes, int numgrids); 12 int GetVerticesCoordinates(double* xyz, Node** nodes, int numvertices); 13 14 14 inline void printarray(double* array,int lines,int cols=1){ 15 int i,j;16 15 printf("\n"); 17 for (i=0;i<lines;i++){16 for(int i=0;i<lines;i++){ 18 17 printf(" [ "); 19 for (j=0;j<cols;j++){ 20 printf(" %12.6g ",array[i*cols+j]); 21 } 18 for(int j=0;j<cols;j++) printf(" %12.6g ",array[i*cols+j]); 22 19 printf(" ]\n"); 23 20 } … … 25 22 } 26 23 inline void printarray(int* array,int lines,int cols=1){ 27 int i,j;28 24 printf("\n"); 29 for (i=0;i<lines;i++){25 for(int i=0;i<lines;i++){ 30 26 printf(" [ "); 31 for (j=0;j<cols;j++){ 32 printf(" %6i",array[i*cols+j]); 33 } 27 for(int j=0;j<cols;j++) printf(" %6i",array[i*cols+j]); 34 28 printf(" ]\n"); 35 29 }
Note:
See TracChangeset
for help on using the changeset viewer.