[petsc-users] Solving Poisson equation with multigrid

Michele Rosso mrosso at uci.edu
Fri May 31 16:48:10 CDT 2013


Hi,

I confirm that

         -pc_type gamg  -pc_mg_cycle_type v  -pc_gamg_agg_nsmooths 1

produces the correct shift in PETSc 3.4.
So my problem is solved.   I will upgrade to 3.4 in my productive 
machine installation.
It is a Cray machine (Blue Waters). Assuming I want to use the Cray 
compiler, which options should I use for ./configure
for the installation.

Thank you


On 05/29/2013 09:05 PM, Jed Brown wrote:
> Michele Rosso <mrosso at uci.edu> writes:
>
>> Hi,
>>
>> I proceeded as Matt suggested. I am running without nullspace
>> (Dirichlet's BCs) with the following options:
>>
>> -pc_type gamg  -pc_mg_cycle_type v  -pc_gamg_agg_nsmooths 1
>> -mg_coarse_sub_pc_factor_shift_type NONZERO -ksp_view -options_left
>>
>> The results are fine and the run finishes. The output of -ksp_view does
>> not say anything about the coarse solver being shifted.
> With petsc-3.4, it has these lines:
>
>            tolerance for zero pivot 2.22045e-14
>            using diagonal shift on blocks to prevent zero pivot
>
> You can try a proposed fix in the branch 'jed/fix-gamg-coarse'.
>
>
>
> Hong, I think this diagnostic output is unintuitive for a user that
> doesn't know this relation.  Shall we add the enum names to the output
> lines below?
>
>      if (factor->info.shifttype==(PetscReal)MAT_SHIFT_POSITIVE_DEFINITE) {
>        ierr = PetscViewerASCIIPrintf(viewer,"  using Manteuffel shift\n");CHKERRQ(ierr);
>      }
>      if (factor->info.shifttype==(PetscReal)MAT_SHIFT_NONZERO) {
>        ierr = PetscViewerASCIIPrintf(viewer,"  using diagonal shift to prevent zero pivot\n");CHKERRQ(ierr);
>      }
>      if (factor->info.shifttype==(PetscReal)MAT_SHIFT_INBLOCKS) {
>        ierr = PetscViewerASCIIPrintf(viewer,"  using diagonal shift on blocks to prevent zero pivot\n");CHKERRQ(ierr);
>      }
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20130531/3078e852/attachment.html>


More information about the petsc-users mailing list