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

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

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

revision 3378 by gross, Tue Oct 26 07:54:58 2010 UTC revision 3379 by gross, Wed Nov 24 04:48:49 2010 UTC
# Line 193  void Paso_Preconditioner_LocalSmoother_S Line 193  void Paso_Preconditioner_LocalSmoother_S
193     /* forward substitution */     /* forward substitution */
194        
195     if (n_block==1) {     if (n_block==1) {
196        Paso_BlockOps_MV_1(&x[0], &diag[0], &x[0]);        x[0]*=diag[0];
197        for (i = 1; i < n; ++i) {        for (i = 1; i < n; ++i) {
198       mm=ptr_main[i];       mm=ptr_main[i];
199       /* x_i=x_i-a_ik*x_k  (with k<i) */       /* x_i=x_i-a_ik*x_k  (with k<i) */
200       for (iptr_ik=A_p->pattern->ptr[i];iptr_ik<mm; ++iptr_ik) {       for (iptr_ik=A_p->pattern->ptr[i];iptr_ik<mm; ++iptr_ik) {
201          k=A_p->pattern->index[iptr_ik];            k=A_p->pattern->index[iptr_ik];
202          Paso_BlockOps_SMV_1(&x[i], &A_p->val[iptr_ik], &x[k]);          x[i]-=A_p->val[iptr_ik]*x[k];
203       }       }
204       Paso_BlockOps_MV_1(&x[i], &diag[i], &x[i]);       x[i]*=diag[i];
205        }        }
206     } else if (n_block==2) {     } else if (n_block==2) {
207        Paso_BlockOps_MV_2(&x[0], &diag[0], &x[0]);        Paso_BlockOps_MV_2(&x[0], &diag[0], &x[0]);

Legend:
Removed from v.3378  
changed lines
  Added in v.3379

  ViewVC Help
Powered by ViewVC 1.1.26