<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body text="#000000" bgcolor="#FFFFFF">
<font face="Ubuntu">Hi,<br>
<br>
I confirm that <br>
<br>
-pc_type gamg -pc_mg_cycle_type v -pc_gamg_agg_nsmooths
1<br>
<br>
produces the correct shift in PETSc 3.4.<br>
So my problem is solved. I will upgrade to 3.4 in my productive
machine installation.<br>
It is a Cray machine (Blue Waters). Assuming I want to use the
Cray compiler, which options should I use for ./configure<br>
for the installation.<br>
<br>
Thank you<br>
<br>
<br>
</font>
<div class="moz-cite-prefix">On 05/29/2013 09:05 PM, Jed Brown
wrote:<br>
</div>
<blockquote cite="mid:8761y1w1si.fsf@mcs.anl.gov" type="cite">
<pre wrap="">Michele Rosso <a class="moz-txt-link-rfc2396E" href="mailto:mrosso@uci.edu"><mrosso@uci.edu></a> writes:
</pre>
<blockquote type="cite">
<pre wrap="">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.
</pre>
</blockquote>
<pre wrap="">
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);
}
</pre>
</blockquote>
<br>
</body>
</html>