/[escript]/branches/doubleplusgood/dudley/src/ElementFile_gather.cpp
ViewVC logotype

Diff of /branches/doubleplusgood/dudley/src/ElementFile_gather.cpp

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

trunk/esys2/finley/src/finleyC/ElementFile_gather.c revision 82 by jgs, Tue Oct 26 06:53:54 2004 UTC trunk/finley/src/finleyC/ElementFile_gather.c revision 155 by jgs, Wed Nov 9 02:02:19 2005 UTC
# Line 1  Line 1 
1  /* $Id$ */  /*
2     ******************************************************************************
3     *                                                                            *
4     *       COPYRIGHT  ACcESS 2003,2004,2005 -  All Rights Reserved              *
5     *                                                                            *
6     * This software is the property of ACcESS. No part of this code              *
7     * may be copied in any form or by any means without the expressed written    *
8     * consent of ACcESS.  Copying, use or modification of this software          *
9     * by any unauthorised person is illegal unless that person has a software    *
10     * license agreement with ACcESS.                                             *
11     *                                                                            *
12     ******************************************************************************
13    */
14    
15  /**************************************************************/  /**************************************************************/
16    
17  /*   Finley: ElementFile */  /*   Finley: ElementFile */
# Line 9  Line 22 
22    
23  /**************************************************************/  /**************************************************************/
24    
25  /*   Copyrights by ACcESS Australia 2003/04 */  /*  Author: gross@access.edu.au */
26  /*   Author: gross@access.edu.au */  /*  Version: $Id$ */
 /*   Version: $Id$ */  
27    
28  /**************************************************************/  /**************************************************************/
29    
 #include "Finley.h"  
30  #include "ElementFile.h"  #include "ElementFile.h"
31    
32  /**************************************************************/  /**************************************************************/
33    
34  void Finley_ElementFile_gather(int* index, Finley_ElementFile* in, Finley_ElementFile* out) {  void Finley_ElementFile_gather(index_t* index, Finley_ElementFile* in, Finley_ElementFile* out) {
35     maybelong e,k,j;     index_t k;
36     maybelong NN_in=in->ReferenceElement->Type->numNodes;     dim_t e,j;
37     maybelong NN_out=out->ReferenceElement->Type->numNodes;     dim_t NN_in=in->ReferenceElement->Type->numNodes;
38       dim_t NN_out=out->ReferenceElement->Type->numNodes;
39     if (in!=NULL) {     if (in!=NULL) {
40       /*OMP */       /*OMP */
41       #pragma omp parallel for private(e,k,j) schedule(static)       #pragma omp parallel for private(e,k,j) schedule(static)
# Line 31  void Finley_ElementFile_gather(int* inde Line 43  void Finley_ElementFile_gather(int* inde
43          k=index[e];          k=index[e];
44          out->Id[e]=in->Id[k];          out->Id[e]=in->Id[k];
45          out->Tag[e]=in->Tag[k];          out->Tag[e]=in->Tag[k];
46          out->Color[e]=in->Color[k]+out->numColors;          out->Color[e]=in->Color[k]+out->maxColor+1;
47          for(j=0;j<MIN(NN_out,NN_in);j++) out->Nodes[INDEX2(j,e,NN_out)]=in->Nodes[INDEX2(j,k,NN_in)];          for(j=0;j<MIN(NN_out,NN_in);j++) out->Nodes[INDEX2(j,e,NN_out)]=in->Nodes[INDEX2(j,k,NN_in)];
48       }       }
49       out->numColors+=in->numColors;       out->minColor=MIN(out->minColor,in->minColor+out->maxColor+1);
50         out->maxColor=MAX(out->maxColor,in->maxColor+out->maxColor+1);
51     }     }
52  }  }
53  /*  /*
54  * $Log$  * $Log$
55  * Revision 1.1  2004/10/26 06:53:57  jgs  * Revision 1.3  2005/09/15 03:44:22  jgs
56  * Initial revision  * Merge of development branch dev-02 back to main trunk on 2005-09-15
57    *
58    * Revision 1.2.2.1  2005/09/07 06:26:18  gross
59    * the solver from finley are put into the standalone package paso now
60    *
61    * Revision 1.2  2005/07/08 04:07:49  jgs
62    * Merge of development branch back to main trunk on 2005-07-08
63    *
64    * Revision 1.1.1.1.2.2  2005/06/30 01:53:55  gross
65    * a bug in coloring fixed
66    *
67    * Revision 1.1.1.1.2.1  2005/06/29 02:34:49  gross
68    * some changes towards 64 integers in finley
69    *
70    * Revision 1.1.1.1  2004/10/26 06:53:57  jgs
71    * initial import of project esys2
72  *  *
73  * Revision 1.1.1.1  2004/06/24 04:00:40  johng  * Revision 1.1.1.1  2004/06/24 04:00:40  johng
74  * Initial version of eys using boost-python.  * Initial version of eys using boost-python.

Legend:
Removed from v.82  
changed lines
  Added in v.155

  ViewVC Help
Powered by ViewVC 1.1.26