/[escript]/trunk/finley/src/Assemble_gradient.c
ViewVC logotype

Diff of /trunk/finley/src/Assemble_gradient.c

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

revision 102 by jgs, Wed Dec 15 07:08:39 2004 UTC revision 123 by jgs, Fri Jul 8 04:08:13 2005 UTC
# Line 25  Line 25 
25  /*****************************************************************/  /*****************************************************************/
26    
27    
28    #define NODES 0
29    #define DOF 1
30    #define REDUCED_DOF 2
31    
32  void Finley_Assemble_gradient(Finley_NodeFile* nodes, Finley_ElementFile* elements,  void Finley_Assemble_gradient(Finley_NodeFile* nodes, Finley_ElementFile* elements,
33               escriptDataC* grad_data,escriptDataC* data) {               escriptDataC* grad_data,escriptDataC* data) {
34    
35    double *local_X=NULL, *local_data=NULL, *dVdv=NULL, *dvdV=NULL, *Vol=NULL, *d_datadv=NULL, *gradS=NULL,*data_array;    double *local_X=NULL, *local_data=NULL, *dVdv=NULL, *dvdV=NULL, *Vol=NULL, *d_datadv=NULL, *gradS=NULL,*data_array;
36    int numNodes,e,node_offset,*resort_nodes,i,q,type,NS_DOF,NN_DOF,dof_offset;    index_t node_offset,*resort_nodes=FALSE,dof_offset;
37    #define NODES 0    dim_t numNodes=0,e,i,q,NS_DOF=0,NN_DOF=0;
38    #define DOF 1    type_t type=DOF;
   #define REDUCED_DOF 2  
39    if (nodes==NULL || elements==NULL) return;    if (nodes==NULL || elements==NULL) return;
40    int NN=elements->ReferenceElement->Type->numNodes;    dim_t NN=elements->ReferenceElement->Type->numNodes;
41    int NS=elements->ReferenceElement->Type->numShapes;    dim_t NS=elements->ReferenceElement->Type->numShapes;
42    int id[NN];    index_t id[NN];
43    int numDim=nodes->numDim;    dim_t numDim=nodes->numDim;
44    int data_type=getFunctionSpaceType(data);    type_t data_type=getFunctionSpaceType(data);
45    int numComps=getDataPointSize(data);    dim_t numComps=getDataPointSize(data);
46    int numQuad=elements->ReferenceElement->numQuadNodes;    dim_t numQuad=elements->ReferenceElement->numQuadNodes;
47    for (i=0;i<NN;i++) id[i]=i;    for (i=0;i<NN;i++) id[i]=i;
48    
49      /* set some parameter */      /* set some parameter */
# Line 159  void Finley_Assemble_gradient(Finley_Nod Line 162  void Finley_Assemble_gradient(Finley_Nod
162            THREAD_MEMFREE(d_datadv);            THREAD_MEMFREE(d_datadv);
163        }        }
164    }    }
   #undef NODES  
   #undef DOF  
   #undef REDUCED_DOF  
165  }  }
166    #undef NODES
167    #undef DOF
168    #undef REDUCED_DOF
169  /*  /*
170   * $Log$   * $Log$
171     * Revision 1.5  2005/07/08 04:07:47  jgs
172     * Merge of development branch back to main trunk on 2005-07-08
173     *
174   * Revision 1.4  2004/12/15 07:08:32  jgs   * Revision 1.4  2004/12/15 07:08:32  jgs
175   * *** empty log message ***   * *** empty log message ***
176     * Revision 1.1.1.1.2.2  2005/06/29 02:34:48  gross
177     * some changes towards 64 integers in finley
178     *
179     * Revision 1.1.1.1.2.1  2004/11/24 01:37:12  gross
180     * some changes dealing with the integer overflow in memory allocation. Finley solves 4M unknowns now
181   *   *
182   *   *
183   *   *

Legend:
Removed from v.102  
changed lines
  Added in v.123

  ViewVC Help
Powered by ViewVC 1.1.26