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

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

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

revision 1902 by artak, Wed Oct 22 03:54:14 2008 UTC revision 2107 by artak, Fri Nov 28 04:39:07 2008 UTC
# Line 81  void Paso_Solver_setPreconditioner(Paso_ Line 81  void Paso_Solver_setPreconditioner(Paso_
81                break;                break;
82              case PASO_AMG:              case PASO_AMG:
83                if (options->verbose) printf("AMG preconditioner is used.\n");                if (options->verbose) printf("AMG preconditioner is used.\n");
84                prec->amg=Paso_Solver_getAMG(A->mainBlock,options->verbose,options->levels);                prec->amg=Paso_Solver_getAMG(A->mainBlock,options->verbose,0);
85                prec->type=PASO_AMG;                prec->type=PASO_AMG;
86                break;                break;
87    
# Line 99  void Paso_Solver_setPreconditioner(Paso_ Line 99  void Paso_Solver_setPreconditioner(Paso_
99  void Paso_Solver_solvePreconditioner(Paso_SystemMatrix* A,double* x,double* b){  void Paso_Solver_solvePreconditioner(Paso_SystemMatrix* A,double* x,double* b){
100      Paso_Solver_Preconditioner* prec=(Paso_Solver_Preconditioner*) A->solver;      Paso_Solver_Preconditioner* prec=(Paso_Solver_Preconditioner*) A->solver;
101            
       
102      switch (prec->type) {      switch (prec->type) {
103          default:          default:
104          case PASO_JACOBI:          case PASO_JACOBI:
# Line 155  void Paso_Solver_solvePreconditioner(Pas Line 154  void Paso_Solver_solvePreconditioner(Pas
154             MEMFREE(bnew);             MEMFREE(bnew);
155                        
156             }             }
            /* prec->gs->sweeps=prec->gs->sweeps-1;*/  
             
157             break;             break;
158           case PASO_AMG:           case PASO_AMG:
159             Paso_Solver_solveAMG(prec->amg,x,b);             Paso_Solver_solveAMG(prec->amg,x,b);

Legend:
Removed from v.1902  
changed lines
  Added in v.2107

  ViewVC Help
Powered by ViewVC 1.1.26