[petsc-users] Galerkin multigrid coarsening

Torquil Macdonald Sørensen torquil at gmail.com
Fri Jan 31 11:13:25 CST 2014


On 30 January 2014 22:05, Jed Brown <jed at jedbrown.org> wrote:
>
> > I did not have an opportunity to test what happens if I don't set any
> > restriction, but I'm hoping it will then use P^T, as before.
>
> Yes, it will.

Only setting the interpolation, and not the restriction, results in a
crash for me (with output given at the bottom of this message).
Looking at the changed code, is it not the case that if "restrct" is
unset, the code will still try to use it in the MatMatMatMult() inside
the else-part of the new code? If restrct is not set, it will surely
differ from "interpolate" in the tests on lines 628 and 641, and
therefore trigger the else-part of the if-else constructs, thereby
causing this crash, right?

I applied the changes to the "master"-branch, so I'm hoping that is
not the reason for this problem. Here is the output I'm getting when
only setting the interpolation:

[0]PETSC ERROR: --------------------- Error Message
------------------------------------
[0]PETSC ERROR: Null argument, when expecting valid pointer!
[0]PETSC ERROR: Null Object: Parameter # 1!
[0]PETSC ERROR:
------------------------------------------------------------------------
[0]PETSC ERROR: Petsc Development GIT revision: v3.4.3-2428-g0a70bb0
GIT Date: 2014-01-30 13:56:44 -0600
[0]PETSC ERROR: See docs/changes/index.html for recent updates.
[0]PETSC ERROR: See docs/faq.html for hints about trouble shooting.
[0]PETSC ERROR: See docs/index.html for manual pages.
[0]PETSC ERROR:
------------------------------------------------------------------------
[0]PETSC ERROR: ./timeevolution.exe on a arch-linux2-cxx-debug named
enlil.uio.no by tmac Fri Jan 31 18:00:41 2014
[0]PETSC ERROR: Libraries linked from
/mn/anatu/cma-u3/tmac/usr/stow/petsc_complex_debug_cpp/lib
[0]PETSC ERROR: Configure run at Fri Jan 31 17:54:00 2014
[0]PETSC ERROR: Configure options
--prefix=/mn/anatu/cma-u3/tmac/usr/stow/petsc_complex_debug_cpp
--with-clanguage=C++ --with-scalar-type=complex
--with-shared-libraries=1 --with-debugging=1 --with-superlu=1
--with-superlu-lib=/mn/anatu/cma-u3/tmac/usr/lib/libsuperlu.so
--with-superlu-include=/mn/anatu/cma-u3/tmac/usr/include/superlu
--with-ptscotch=1
--with-ptscotch-include=/mn/anatu/cma-u3/tmac/usr/include/scotch
--with-ptscotch-lib="[/mn/anatu/cma-u3/tmac/usr/lib/libptscotch.so,/mn/anatu/cma-u3/tmac/usr/lib/libptscotcherr.so,/mn/anatu/cma-u3/tmac/usr/lib/libscotch.so,/mn/anatu/cma-u3/tmac/usr/lib/libscotcherr.so]"
--with-blas-lib=/mn/anatu/cma-u3/tmac/usr/lib/libsatlas.so
--with-lapack-lib=/mn/anatu/cma-u3/tmac/usr/lib/libsatlas.so
--with-fortran-interfaces=0
[0]PETSC ERROR:
------------------------------------------------------------------------
[0]PETSC ERROR: MatMatMatMult() line 9069 in
/work/petsc/src/mat/interface/matrix.c
[0]PETSC ERROR: PCSetUp_MG() line 631 in /work/petsc/src/ksp/pc/impls/mg/mg.c
[0]PETSC ERROR: PCSetUp() line 888 in /work/petsc/src/ksp/pc/interface/precon.c
[0]PETSC ERROR: KSPSetUp() line 278 in
/work/petsc/src/ksp/ksp/interface/itfunc.c
[0]PETSC ERROR: main() line 244 in /mn/anatu/cma-u3/tmac/research/sim/prog.cpp

Setting both the interpolation and restriction works fine, as I
mentioned in the earlier message.

Best regards
Torquil Sørensen


More information about the petsc-users mailing list