root/src/getglobalresults.c

/* [<][>][^][v][top][bottom][index][help] */

DEFINITIONS

This source file includes following definitions.
  1. getglobalresults

   1 /*     CalculiX - A 3-dimensional finite element program                 */
   2 /*              Copyright (C) 1998 Guido Dhondt                          */
   3 
   4 /*     This program is free software; you can redistribute it and/or     */
   5 /*     modify it under the terms of the GNU General Public License as    */
   6 /*     published by the Free Software Foundation(version 2);    */
   7 /*                                                                       */
   8 
   9 /*     This program is distributed in the hope that it will be useful,   */
  10 /*     but WITHOUT ANY WARRANTY; without even the implied warranty of    */ 
  11 /*     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the      */
  12 /*     GNU General Public License for more details.                      */
  13 
  14 /*     You should have received a copy of the GNU General Public License */
  15 /*     along with this program; if not, write to the Free Software       */
  16 /*     Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.         */
  17 
  18 #include <stdlib.h>
  19 #include <math.h>
  20 #include <stdio.h>
  21 #include <string.h>
  22 #include <unistd.h>
  23 #include <fcntl.h>
  24 #include <ctype.h>
  25 
  26 #include "CalculiX.h"
  27 #include "readfrd.h"
  28 
  29 void getglobalresults (char *jobnamec,ITG **integerglobp,double **doubleglobp,
  30                        ITG *nboun,ITG *iamboun,double *xboun, ITG *nload,
  31                        char *sideload,ITG *iamload, ITG *iglob,ITG *nforc,
  32                        ITG *iamforc,double *xforc,ITG *ithermal,ITG *nk,
  33                        double *t1,ITG *iamt1)
  34 {
  35  
  36     char  datin[MAX_LINE_LENGTH],text[13]="            ";
  37     Summen    anz[1]; 
  38     Nodes     *node=NULL;
  39     Elements  *elem=NULL;
  40     Datasets *lcase=NULL;
  41     
  42     ITG *kontet=NULL,*ifatet=NULL,*inodfa=NULL,*ipofa=NULL,type,n1,n2,n3,n4,
  43         *nnx=NULL,*nny=NULL,*nnz=NULL,*kon=NULL,*ipkon=NULL,*kontyp=NULL,
  44         *iparent=NULL,ifreefa=1,kflag=2,ne,netet,numnodes,nkon,
  45         indexe,istep,loadcase,nfaces,netet_,nktet=0,nfield,j,nodes[4],i,
  46         read_mode=1,nodenr,*integerglob=NULL,*ielemnr=NULL,istep_global;
  47     
  48     ITG i1[24]={3,7,8,6,4,3,8,1,3,8,5,6,3,5,8,1,2,3,5,6,2,5,3,1};
  49     ITG i2[12]={1,2,3,5,1,5,3,4,4,5,3,6};
  50     ITG i4[88]={5,20,17,13,20,8,19,16,19,7,18,15,18,6,17,14,
  51                 1,9,12,13,12,11,4,16,11,10,3,15,9,2,10,14,
  52                 9,13,11,12,11,13,16,12,13,17,19,20,13,19,16,20,
  53                 17,14,19,18,19,14,15,18,9,11,14,10,11,15,14,10,
  54                 11,19,16,13,11,15,19,14,11,14,19,17,11,19,13,17,
  55               11,14,17,9,11,17,13,9};
  56     ITG i5[56]={1,7,9,10,7,2,8,11,8,3,9,12,5,13,14,11,
  57               13,4,15,10,14,15,6,12,11,12,7,10,7,12,9,10,
  58                 11,7,12,8,12,7,9,8,13,15,11,10,11,15,12,10,
  59                 13,11,15,14,15,11,12,14};
  60     ITG i6[32]={8,9,10,4,1,5,7,8,7,6,3,10,9,8,10,7,
  61                 8,9,5,7,9,10,6,7,5,6,7,9,5,2,6,9};
  62     
  63     double *planfa=NULL,*cotet=NULL,*cgtet=NULL,*field=NULL,
  64         *x=NULL,*y=NULL,*z=NULL,*xo=NULL,*yo=NULL,*zo=NULL,
  65         *doubleglob=NULL;
  66     
  67     integerglob=*integerglobp;doubleglob=*doubleglobp;
  68 
  69     /*  The global mesh is remeshed into tetrahedral elements
  70 
  71         cotet(j,i):    j-coordinate of node i of tet mesh
  72         iparent(i):    parent element from global mesh for tet i
  73         kontet(4,i):   topology of tet i
  74         netet:         total # of tets
  75         cgtet(3,i):    center of gravity of tet i */
  76     
  77     /* reading the global coordinates and the topology from file
  78        (if any, else return) */
  79     
  80     if(strcmp1(&jobnamec[396]," ")==0)return;
  81     strcpy1(datin,&jobnamec[396],132); 
  82     for(i=0;i<MAX_LINE_LENGTH;i++){
  83         if(strcmp1(&datin[i]," ")==0){
  84             datin[i]='\0';
  85             break;
  86         }
  87     }
  88     
  89     /* determining the appropriate step number: scanning the SPC
  90        boundary conditions and distribed facial loads 
  91        if no global data is needed return*/
  92     
  93     istep=0;
  94     for(i=0;i<*nboun;i++){
  95         if((xboun[i]<1.9232931375)&&(xboun[i]>1.9232931373)){
  96             istep=iamboun[i];
  97             break;
  98         }
  99     }
 100     if(istep==0){
 101         for(i=0;i<*nforc;i++){
 102             if((xforc[i]<1.9232931375)&&(xforc[i]>1.9232931373)){
 103                 istep=iamforc[i];
 104                 break;
 105             }
 106         }
 107     }
 108     if(istep==0){
 109         for(i=0;i<*nload;i++){
 110             if(strcmp1(&sideload[20*i+2],"SM")==0){
 111                 istep=iamload[2*i];
 112                 break;
 113             }
 114         }
 115     }
 116     if((istep==0)&&(*ithermal>0)){
 117         for(i=0;i<*nk;i++){
 118             if((t1[i]<1.9232931375)&&(t1[i]>1.9232931373)){
 119                 istep=iamt1[i];
 120                 break;
 121             }
 122         }
 123     }
 124     if(istep==0){
 125         return;
 126     }else{
 127         *iglob=1;
 128     }
 129     
 130     /* initialization of the size of fields used in readfrd.c */
 131 
 132     anz->orign=0;
 133     anz->n=0;
 134     anz->e=0;
 135     anz->f=0;
 136     anz->g=0;
 137     anz->t=0;
 138     anz->l=0;
 139     anz->olc=0;
 140     anz->orignmax=0;
 141     anz->nmax=0;
 142     anz->nmin=MAX_INTEGER;
 143     anz->emax=0;
 144     anz->emin=MAX_INTEGER;
 145     anz->sets=0;
 146     anz->mats=0;
 147     anz->amps=0;
 148     anz->noffs=0;
 149     anz->eoffs=0;
 150     
 151     readfrd( datin, anz, &node, &elem, &lcase, read_mode);
 152     
 153     /* calculation of the highest node number */
 154     
 155     nktet=0;
 156     for(i=0;i<anz[0].n;i++){
 157         if(node[i].nr>nktet) nktet=node[i].nr;
 158     }
 159     NNEW(cotet,double,3*nktet);
 160     
 161     /* storing the global coordinates */
 162     
 163     for (i=0;i<anz[0].n;i++){
 164         nodenr=node[i].nr;
 165         j=nodenr-1;
 166         cotet[3*j]=node[nodenr].nx;
 167         cotet[3*j+1]=node[nodenr].ny;
 168         cotet[3*j+2]=node[nodenr].nz;
 169     }
 170     
 171     /* number of elements (not highest element number; this number
 172        is not needed) */
 173     
 174     ne=anz[0].e;
 175     
 176     /* storing the topology */
 177     
 178     indexe=0;
 179     NNEW(ielemnr,ITG,ne);
 180     NNEW(kontyp,ITG,ne);
 181     NNEW(ipkon,ITG,ne);
 182     NNEW(kon,ITG,20*ne);
 183     for(i=0;i<anz[0].e;i++){
 184         ielemnr[i]=elem[i].nr;
 185         kontyp[i]=elem[i].type;
 186         ipkon[i]=indexe;
 187         if(kontyp[i]==1){
 188             numnodes=8;
 189         }else if(kontyp[i]==2){
 190             numnodes=6;
 191         }else if(kontyp[i]==3){
 192             numnodes=4;
 193         }else if(kontyp[i]==4){
 194             numnodes=20;
 195         }else if(kontyp[i]==5){
 196             numnodes=15;
 197         }else if(kontyp[i]==6){
 198             numnodes=10;
 199         }else{
 200             printf("*WARNING in getglobalresults.c: element in global\n");
 201             printf("         mesh not recognized; cgx element type=%" ITGFORMAT "\n",kontyp[i]);
 202             continue;
 203         }
 204         for(j=0;j<numnodes;j++){
 205             kon[indexe++]=elem[i].nod[j];
 206         }
 207     }
 208     nkon=indexe;
 209     RENEW(kon,ITG,nkon);
 210     
 211     /* generating the tetrahedral elements */
 212     
 213     netet=0;
 214     netet_=22*ne;
 215     
 216     NNEW(iparent,ITG,netet_);
 217     NNEW(kontet,ITG,4*netet_);
 218     NNEW(ipofa,ITG,4*netet_);
 219     NNEW(inodfa,ITG,16*netet_);
 220     NNEW(ifatet,ITG,4*netet_);
 221     NNEW(planfa,double,16*netet_);
 222     
 223     /* initialization of fields */
 224     
 225     FORTRAN(init,(&nktet,inodfa,ipofa,&netet_));
 226     
 227     for(i=0;i<ne;i++){
 228         type=kontyp[i];
 229         indexe=ipkon[i]-1;
 230         if(type==1){
 231             
 232             /* C3D8* */
 233             
 234             for(j=0;j<6;j++){
 235                 nodes[0]=kon[indexe+i1[4*j]];
 236                 nodes[1]=kon[indexe+i1[4*j+1]];
 237                 nodes[2]=kon[indexe+i1[4*j+2]];
 238                 nodes[3]=kon[indexe+i1[4*j+3]];
 239                 iparent[netet]=i+1;
 240                 netet++;
 241                 FORTRAN(generatetet,(kontet,ifatet,&netet,inodfa,
 242                                      &ifreefa,planfa,ipofa,nodes,cotet));
 243             }
 244         }
 245         else if(type==2){
 246             
 247             /* C3D6 */
 248             
 249             for(j=0;j<3;j++){
 250                 nodes[0]=kon[indexe+i2[4*j]];
 251                 nodes[1]=kon[indexe+i2[4*j+1]];
 252                 nodes[2]=kon[indexe+i2[4*j+2]];
 253                 nodes[3]=kon[indexe+i2[4*j+3]];
 254                 iparent[netet]=i+1;
 255                 netet++;
 256                 FORTRAN(generatetet,(kontet,ifatet,&netet,inodfa,
 257                                      &ifreefa,planfa,ipofa,nodes,cotet));
 258             }
 259         }
 260         else if(type==3){
 261             
 262             /* C3D4 */
 263             
 264             nodes[0]=kon[indexe+1];
 265             nodes[1]=kon[indexe+2];
 266             nodes[2]=kon[indexe+3];
 267             nodes[3]=kon[indexe+4];
 268             iparent[netet]=i+1;
 269             netet++;
 270             FORTRAN(generatetet,(kontet,ifatet,&netet,inodfa,
 271                                  &ifreefa,planfa,ipofa,nodes,cotet));
 272         }
 273         else if(type==4){
 274             
 275             /* C3D20* */
 276             
 277             for(j=0;j<22;j++){
 278                 nodes[0]=kon[indexe+i4[4*j]];
 279                 nodes[1]=kon[indexe+i4[4*j+1]];
 280                 nodes[2]=kon[indexe+i4[4*j+2]];
 281                 nodes[3]=kon[indexe+i4[4*j+3]];
 282                 iparent[netet]=i+1;
 283                 netet++;
 284                 FORTRAN(generatetet,(kontet,ifatet,&netet,inodfa,
 285                                      &ifreefa,planfa,ipofa,nodes,cotet));
 286             }
 287         }
 288         else if(type==5){
 289             
 290             /* C3D15 */
 291             
 292             for(j=0;j<14;j++){
 293                 nodes[0]=kon[indexe+i5[4*j]];
 294                 nodes[1]=kon[indexe+i5[4*j+1]];
 295                 nodes[2]=kon[indexe+i5[4*j+2]];
 296                 nodes[3]=kon[indexe+i5[4*j+3]];
 297                 iparent[netet]=i+1;
 298                 netet++;
 299                 FORTRAN(generatetet,(kontet,ifatet,&netet,inodfa,
 300                                      &ifreefa,planfa,ipofa,nodes,cotet));
 301             }
 302         }
 303         else if(type==6){
 304             
 305             /* C3D10 */
 306             
 307             for(j=0;j<8;j++){
 308                 nodes[0]=kon[indexe+i6[4*j]];
 309                 nodes[1]=kon[indexe+i6[4*j+1]];
 310                 nodes[2]=kon[indexe+i6[4*j+2]];
 311                 nodes[3]=kon[indexe+i6[4*j+3]];
 312                 iparent[netet]=i+1;
 313                 netet++;
 314                 FORTRAN(generatetet,(kontet,ifatet,&netet,inodfa,
 315                                      &ifreefa,planfa,ipofa,nodes,cotet));
 316             }
 317         }
 318     }
 319     SFREE(ipofa);
 320     
 321     nfaces=ifreefa-1;
 322     
 323     RENEW(ifatet,ITG,4*netet);
 324     RENEW(iparent,ITG,netet);
 325     RENEW(planfa,double,4*nfaces);
 326     
 327     /* writing the tet mesh in frd format */
 328     
 329 //    FORTRAN(writetetmesh,(kontet,&netet,cotet,&nktet,field,&nfield));
 330     
 331     /* calculating the center of gravity of the tetrahedra */
 332     
 333     NNEW(cgtet,double,3*netet);
 334     for(i=0;i<netet;i++){
 335         n1=kontet[4*i]-1;
 336         n2=kontet[4*i+1]-1;
 337         n3=kontet[4*i+2]-1;
 338         n4=kontet[4*i+3]-1;
 339         cgtet[3*i]=(cotet[3*n1]+cotet[3*n2]+cotet[3*n3]+cotet[3*n4])/4.;
 340         cgtet[3*i+1]=(cotet[3*n1+1]+cotet[3*n2+1]+cotet[3*n3+1]+cotet[3*n4+1])/4.;
 341         cgtet[3*i+2]=(cotet[3*n1+2]+cotet[3*n2+2]+cotet[3*n3+2]+cotet[3*n4+2])/4.;
 342     }
 343     
 344     /* initialization of additional fields */
 345     
 346     NNEW(x,double,netet);
 347     NNEW(y,double,netet);
 348     NNEW(z,double,netet);
 349     NNEW(xo,double,netet);
 350     NNEW(yo,double,netet);
 351     NNEW(zo,double,netet);
 352     NNEW(nnx,ITG,netet);
 353     NNEW(nny,ITG,netet);
 354     NNEW(nnz,ITG,netet);
 355     for(i=0;i<netet;i++){
 356         nnx[i]=i+1;
 357         nny[i]=i+1;
 358         nnz[i]=i+1;
 359         x[i]=cgtet[3*i];
 360         y[i]=cgtet[3*i+1];
 361         z[i]=cgtet[3*i+2];
 362         xo[i]=x[i];
 363         yo[i]=y[i];
 364         zo[i]=z[i];
 365     }
 366     FORTRAN(dsort,(x,nnx,&netet,&kflag));
 367     FORTRAN(dsort,(y,nny,&netet,&kflag));
 368     FORTRAN(dsort,(z,nnz,&netet,&kflag));
 369     SFREE(cgtet);
 370     
 371     /* loading the step data : NDTEMP (1 variable), DISP (3 variables) and
 372        STRESS (6 variables), if present */
 373     
 374     NNEW(field,double,13*nktet);
 375     
 376     /* reading the temperatures */
 377     /* 1. determining the last temperature loadcase in the step */
 378     
 379     loadcase=-1;
 380     for(i=0;i<anz[0].l;i++){
 381         for(j=0;j<lcase[i].npheader;j++){
 382             if(strcmp1(&lcase[i].pheader[j][5],"PSTEP")==0){
 383                 strcpy1(text,&lcase[i].pheader[j][48],12);
 384                 istep_global=atoi(text);
 385                 break;
 386             }
 387         }
 388         if((istep_global==istep)&&
 389            (strcmp1(lcase[i].name,"NDTEMP")==0)){
 390             loadcase=i;
 391         }else if(istep_global>istep){
 392             break;
 393         }
 394     }
 395     
 396     /* 2. reading the data */
 397     
 398     if(loadcase>-1){
 399 //      if( readfrdblock(loadcase, anz, node, lcase )==-1) 
 400         if(!read_mode && readfrdblock(loadcase, anz, node, lcase )==-1) 
 401         {
 402             printf("ERROR in getglobalresults: Could not read data for Dataset:%" ITGFORMAT "\n", i+1); 
 403             FORTRAN(stop,());
 404         }
 405         
 406     /* 3. storing the data */
 407     
 408         for(i=0;i<anz[0].n;i++){
 409             nodenr=node[i].nr;
 410             field[13*(nodenr-1)]=lcase[loadcase].dat[0][nodenr];
 411         }
 412     }
 413     
 414     /* reading the displacements */
 415     /* 1. determining the last displacement loadcase in the step */
 416     
 417     loadcase=-1;
 418     for(i=0;i<anz[0].l;i++){
 419         for(j=0;j<lcase[i].npheader;j++){
 420             if(strcmp1(&lcase[i].pheader[j][5],"PSTEP")==0){
 421                 strcpy1(text,&lcase[i].pheader[j][48],12);
 422                 istep_global=atoi(text);
 423                 break;
 424             }
 425         }
 426         if((istep_global==istep)&&
 427 //         (strcmp1(lcase[i].name,"DISPR")==0)){
 428            (strcmp1(lcase[i].name,"DISP")==0)){
 429             loadcase=i;
 430         }else if(istep_global>istep){
 431             break;
 432         }
 433     }
 434     
 435     /* 2. reading the data */
 436     
 437     if(loadcase>-1){
 438 //      if( readfrdblock(loadcase, anz, node, lcase )==-1) 
 439         if(!read_mode && readfrdblock(loadcase, anz, node, lcase )==-1) 
 440         {
 441             printf("ERROR in getglobalresults: Could not read data for Dataset:%" ITGFORMAT "\n", i+1); 
 442             FORTRAN(stop,());
 443         }
 444         
 445     /* 3. storing the data */
 446     
 447         for(i=0;i<anz[0].n;i++){
 448             nodenr=node[i].nr;
 449             field[13*(nodenr-1)+1]=lcase[loadcase].dat[0][nodenr];
 450             field[13*(nodenr-1)+2]=lcase[loadcase].dat[1][nodenr];
 451             field[13*(nodenr-1)+3]=lcase[loadcase].dat[2][nodenr];
 452         }
 453     }
 454     
 455     /* reading the stresses */
 456     /* 1. determining the last stress loadcase in the step */
 457     
 458     loadcase=-1;
 459     for(i=0;i<anz[0].l;i++){
 460         for(j=0;j<lcase[i].npheader;j++){
 461             if(strcmp1(&lcase[i].pheader[j][5],"PSTEP")==0){
 462                 strcpy1(text,&lcase[i].pheader[j][48],12);
 463                 istep_global=atoi(text);
 464                 break;
 465             }
 466         }
 467         if((istep_global==istep)&&
 468            (strcmp1(lcase[i].name,"STRESS")==0)){
 469             loadcase=i;
 470         }else if(istep_global>istep){
 471             break;
 472         }
 473     }
 474     
 475     /* 2. reading the data */
 476     
 477     if(loadcase>-1){
 478 //      if( readfrdblock(loadcase, anz, node, lcase )==-1) 
 479         if(!read_mode && readfrdblock(loadcase, anz, node, lcase )==-1) 
 480         {
 481             printf("ERROR in getglobalresults: Could not read data for Dataset:%" ITGFORMAT "\n", i+1); 
 482             FORTRAN(stop,());
 483         }
 484         
 485     /* 3. storing the data */
 486     
 487         for(i=0;i<anz[0].n;i++){
 488             nodenr=node[i].nr;
 489             field[13*(nodenr-1)+4]=lcase[loadcase].dat[0][nodenr];
 490             field[13*(nodenr-1)+5]=lcase[loadcase].dat[1][nodenr];
 491             field[13*(nodenr-1)+6]=lcase[loadcase].dat[2][nodenr];
 492             field[13*(nodenr-1)+7]=lcase[loadcase].dat[3][nodenr];
 493             field[13*(nodenr-1)+8]=lcase[loadcase].dat[4][nodenr];
 494             field[13*(nodenr-1)+9]=lcase[loadcase].dat[5][nodenr];
 495         }
 496     }
 497     
 498     /* reading the forces */
 499     /* 1. determining the last force loadcase in the step */
 500     
 501     loadcase=-1;
 502     for(i=0;i<anz[0].l;i++){
 503         for(j=0;j<lcase[i].npheader;j++){
 504             if(strcmp1(&lcase[i].pheader[j][5],"PSTEP")==0){
 505                 strcpy1(text,&lcase[i].pheader[j][48],12);
 506                 istep_global=atoi(text);
 507                 break;
 508             }
 509         }
 510         if((istep_global==istep)&&
 511            (strcmp1(lcase[i].name,"FORC")==0)){
 512             loadcase=i;
 513         }else if(istep_global>istep){
 514             break;
 515         }
 516     }
 517     
 518     /* 2. reading the data */
 519     
 520     if(loadcase>-1){
 521         if(!read_mode && readfrdblock(loadcase, anz, node, lcase )==-1) 
 522         {
 523             printf("ERROR in getglobalresults: Could not read data for Dataset:%" ITGFORMAT "\n", i+1); 
 524             FORTRAN(stop,());
 525         }
 526         
 527     /* 3. storing the data */
 528     
 529         for(i=0;i<anz[0].n;i++){
 530             nodenr=node[i].nr;
 531             field[13*(nodenr-1)+10]=lcase[loadcase].dat[0][nodenr];
 532             field[13*(nodenr-1)+11]=lcase[loadcase].dat[1][nodenr];
 533             field[13*(nodenr-1)+12]=lcase[loadcase].dat[2][nodenr];
 534         }
 535     }
 536     
 537     SFREE(kontet);SFREE(inodfa);
 538     SFREE(node);SFREE(elem);
 539     for(j=0;j<anz->l;j++){
 540       freeDatasets(lcase,j);
 541     }
 542     SFREE(lcase);lcase=NULL;
 543     
 544     /* storing the global data in a common block */
 545     
 546     
 547     NNEW(integerglob,ITG,5+3*ne+nkon+8*netet);
 548     
 549     integerglob[0]=nktet;
 550     integerglob[1]=netet;
 551     integerglob[2]=ne;
 552     integerglob[3]=nkon;
 553     integerglob[4]=nfaces;
 554     memcpy(&integerglob[5],&nnx[0],sizeof(ITG)*netet);
 555     memcpy(&integerglob[netet+5],&nny[0],sizeof(ITG)*netet);
 556     memcpy(&integerglob[2*netet+5],&nnz[0],sizeof(ITG)*netet);
 557     memcpy(&integerglob[3*netet+5],&ifatet[0],sizeof(ITG)*4*netet);
 558     memcpy(&integerglob[7*netet+5],&kontyp[0],sizeof(ITG)*ne);
 559     memcpy(&integerglob[ne+7*netet+5],&ipkon[0],sizeof(ITG)*ne);
 560     memcpy(&integerglob[2*ne+7*netet+5],&kon[0],sizeof(ITG)*nkon);
 561     memcpy(&integerglob[nkon+2*ne+7*netet+5],&iparent[0],sizeof(ITG)*netet);
 562     memcpy(&integerglob[nkon+2*ne+8*netet+5],&ielemnr[0],sizeof(ITG)*ne);
 563     
 564     NNEW(doubleglob,double,16*nktet+4*nfaces+6*netet);
 565     
 566     memcpy(&doubleglob[0],&x[0],sizeof(double)*netet);
 567     memcpy(&doubleglob[netet],&y[0],sizeof(double)*netet);
 568     memcpy(&doubleglob[2*netet],&z[0],sizeof(double)*netet);
 569     memcpy(&doubleglob[3*netet],&xo[0],sizeof(double)*netet);
 570     memcpy(&doubleglob[4*netet],&yo[0],sizeof(double)*netet);
 571     memcpy(&doubleglob[5*netet],&zo[0],sizeof(double)*netet);
 572     memcpy(&doubleglob[6*netet],&planfa[0],sizeof(double)*4*nfaces);
 573     memcpy(&doubleglob[4*nfaces+6*netet],&field[0],sizeof(double)*13*nktet);
 574     memcpy(&doubleglob[13*nktet+4*nfaces+6*netet],&cotet[0],sizeof(double)*3*nktet);
 575     
 576     SFREE(nnx);SFREE(nny);SFREE(nnz);SFREE(ifatet);SFREE(kontyp);SFREE(ipkon);
 577     SFREE(kon);SFREE(iparent);SFREE(ielemnr);
 578 
 579     SFREE(x);SFREE(y);SFREE(z);SFREE(xo);SFREE(yo);SFREE(zo);
 580     SFREE(planfa);SFREE(field);SFREE(cotet);
 581 
 582     *integerglobp=integerglob;*doubleglobp=doubleglob;
 583     
 584     return;
 585 
 586 }

/* [<][>][^][v][top][bottom][index][help] */