/[escript]/trunk/paso/src/Solver_AMG.c
ViewVC logotype

Diff of /trunk/paso/src/Solver_AMG.c

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

revision 1891 by artak, Fri Oct 17 00:15:17 2008 UTC revision 1892 by artak, Fri Oct 17 00:55:59 2008 UTC
# Line 80  Paso_Solver_AMG* Paso_Solver_getAMG(Paso Line 80  Paso_Solver_AMG* Paso_Solver_getAMG(Paso
80    Paso_SparseMatrix * schur=NULL;    Paso_SparseMatrix * schur=NULL;
81    Paso_SparseMatrix * schur_withFillIn=NULL;    Paso_SparseMatrix * schur_withFillIn=NULL;
82    double A11,A12,A13,A21,A22,A23,A31,A32,A33,D,time0,time1,time2;    double A11,A12,A13,A21,A22,A23,A31,A32,A33,D,time0,time1,time2;
   schur_withFillIn=MEMALLOC(1,Paso_SparseMatrix);  
83        
84    /* identify independend set of rows/columns */    /* identify independend set of rows/columns */
85    mis_marker=TMPMEMALLOC(n,index_t);    mis_marker=TMPMEMALLOC(n,index_t);
# Line 340  void Paso_Solver_solveAMG(Paso_Solver_AM Line 339  void Paso_Solver_solveAMG(Paso_Solver_AM
339       dim_t n_block=amg->n_block;       dim_t n_block=amg->n_block;
340       double *r=MEMALLOC(amg->n,double);       double *r=MEMALLOC(amg->n,double);
341       double *x0=MEMALLOC(amg->n,double);       double *x0=MEMALLOC(amg->n,double);
342         Paso_Solver_GS* GS=NULL;
343            
344       if (amg->level==0) {       if (amg->level==0) {
345          /* x=invA_FF*b  */          /* x=invA_FF*b  */
# Line 348  void Paso_Solver_solveAMG(Paso_Solver_AM Line 348  void Paso_Solver_solveAMG(Paso_Solver_AM
348           fprintf(stdout,"LEVEL %d \n",amg->level);           fprintf(stdout,"LEVEL %d \n",amg->level);
349          /* presmoothing on (Shure, x, b, r) */          /* presmoothing on (Shure, x, b, r) */
350          /****************/          /****************/
          Paso_Solver_GS* GS=MEMALLOC(1,Paso_Solver_GS);  
351           GS=Paso_Solver_getGS(amg->A,-1);           GS=Paso_Solver_getGS(amg->A,-1);
352           Paso_Solver_solveGS(GS,x,b);           Paso_Solver_solveGS(GS,x,b);
353                    
# Line 374  void Paso_Solver_solveAMG(Paso_Solver_AM Line 373  void Paso_Solver_solveAMG(Paso_Solver_AM
373          }          }
374    
375          /****************/          /****************/
376          /* Coursening part */          /* Corsening part */
377                    
378          /* r_F=A_FF^-1*r_F  */          /* r_F=A_FF^-1*r_F  */
379          /*Paso_Solver_applyBlockDiagonalMatrix(n_block,amg->n_F,amg->inv_A_FF,amg->A_FF_pivot,amg->b_F,amg->b_F);          /*Paso_Solver_applyBlockDiagonalMatrix(n_block,amg->n_F,amg->inv_A_FF,amg->A_FF_pivot,amg->b_F,amg->b_F);

Legend:
Removed from v.1891  
changed lines
  Added in v.1892

  ViewVC Help
Powered by ViewVC 1.1.26