Commits

Peter Brune  committed f82387e

Fixed PCGAMG_Classical so that thresholding decreases fill as bugs are fixed

  • Participants
  • Parent commits 3c9ab2c

Comments (0)

Files changed (1)

File src/ksp/pc/impls/gamg/classical.c

     for (c = 0; c < ncols; c++) {
       if (PetscAbsScalar(rval[c]) > gamg->threshold*Amax) {
         idx++;
-      } else {
-        idx++;
       }
     }
     ierr = MatRestoreRow(lA,r,&ncols,&rcol,&rval);CHKERRQ(ierr);
       for (c = 0; c < ncols; c++) {
         if (PetscAbsScalar(rval[c]) > gamg->threshold*Amax) {
           idx++;
-        } else {
-          idx++;
         }
       }
       ierr = MatRestoreRow(gA,r,&ncols,&rcol,&rval);CHKERRQ(ierr);
         gcol[idx] = rcol[c];
         gval[idx] = rval[c];
         idx++;
-      } else {
-        gcol[idx] = rcol[c];
-        gval[idx] = 0.;
-        idx++;
       }
     }
     ierr = MatSetValues(*G,1,&r,idx,gcol,gval,INSERT_VALUES);CHKERRQ(ierr);