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

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

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

revision 97 by jgs, Tue Dec 14 05:39:33 2004 UTC revision 100 by jgs, Wed Dec 15 03:48:48 2004 UTC
# Line 375  Finley_RefElement* Finley_RefElement_all Line 375  Finley_RefElement* Finley_RefElement_all
375        
376    /*  allocate the Finley_RefElement to be returned: */    /*  allocate the Finley_RefElement to be returned: */
377        
378    out=MEMALLOC(1,Finley_RefElement);    out=(Finley_RefElement*)MEMALLOC(sizeof(Finley_RefElement));
379    if (Finley_checkPtr(out)) return NULL;    if (Finley_checkPtr(out)) return NULL;
380    out->Type=&(Finley_RefElement_InfoList[id]);    out->Type=&(Finley_RefElement_InfoList[id]);
381    out->numQuadNodes=numQuadNodes;    out->numQuadNodes=numQuadNodes;
# Line 388  Finley_RefElement* Finley_RefElement_all Line 388  Finley_RefElement* Finley_RefElement_all
388        
389    int Ndim=Finley_RefElement_InfoList[id].numDim;    int Ndim=Finley_RefElement_InfoList[id].numDim;
390    int NS=Finley_RefElement_InfoList[id].numShapes;    int NS=Finley_RefElement_InfoList[id].numShapes;
391    out->QuadNodes=MEMALLOC(numQuadNodes*Ndim,double);    out->QuadNodes=(double *)MEMALLOC(numQuadNodes*Ndim*sizeof(double));
392    out->QuadWeights=MEMALLOC(numQuadNodes,double);    out->QuadWeights=(double *)MEMALLOC(numQuadNodes*sizeof(double));
393    out->S=MEMALLOC(NS*numQuadNodes,double);    out->S=(double *)MEMALLOC(NS*numQuadNodes*sizeof(double));
394    out->dSdv=MEMALLOC(NS*Ndim*numQuadNodes,double);    out->dSdv=(double *)MEMALLOC(NS*Ndim*numQuadNodes*sizeof(double));
395    if ( Finley_checkPtr(out->QuadNodes) || Finley_checkPtr(out->QuadWeights) || Finley_checkPtr(out->S) || Finley_checkPtr(out->dSdv) ) {    if ( Finley_checkPtr(out->QuadNodes) || Finley_checkPtr(out->QuadWeights) || Finley_checkPtr(out->S) || Finley_checkPtr(out->dSdv) ) {
396           Finley_RefElement_dealloc(out);           Finley_RefElement_dealloc(out);
397           return NULL;           return NULL;
# Line 449  ElementTypeId Finley_RefElement_getTypeI Line 449  ElementTypeId Finley_RefElement_getTypeI
449  }  }
450  /*  /*
451  * $Log$  * $Log$
452  * Revision 1.2  2004/12/14 05:39:30  jgs  * Revision 1.3  2004/12/15 03:48:45  jgs
453  * *** empty log message ***  * *** empty log message ***
454  *  *
 * Revision 1.1.1.1.2.1  2004/11/24 01:37:15  gross  
 * some changes dealing with the integer overflow in memory allocation. Finley solves 4M unknowns now  
 *  
455  * Revision 1.1.1.1  2004/10/26 06:53:57  jgs  * Revision 1.1.1.1  2004/10/26 06:53:57  jgs
456  * initial import of project esys2  * initial import of project esys2
457  *  *

Legend:
Removed from v.97  
changed lines
  Added in v.100

  ViewVC Help
Powered by ViewVC 1.1.26