[petsc-dev] Algebraic Multigrid

Ari Rappaport arir at vosssci.com
Tue Jul 26 17:24:54 CDT 2016


So I commented out the line PCSetType(pc, PCGAMG). The line KSPSetFromOptions(ksp) was already in the code at the end of our initialization routine. I also added .petscrc to the working dir. Here is the current output. It seems as if Option left: name:-mg_levels_pc_type jacobi (no value) is still present in the output..I dunno.

-Ari

----- Original Message -----
From: "Mark Adams" <mfadams at lbl.gov>
To: "Ari Rappaport" <arir at vosssci.com>, "For users of the development version of PETSc" <petsc-dev at mcs.anl.gov>
Sent: Tuesday, July 26, 2016 4:03:03 PM
Subject: Re: [petsc-dev] Algebraic Multigrid


At the end of this you have: 



#PETSc Option Table entries: 
-ksp_view 
-mg_levels_pc_type jacobi 
-options_left 
#End of PETSc Option Table entries 
There is one unused database option. It is: 
Option left: name:-mg_levels_pc_type jacobi (no value) 


So this jacobi parameter is not being used. 


Do you call KPSSetFromOptions? Do you set solver parameters in the code? Like PCGAMG? 


You should not set anything in the code, it just confuses things at this point. Use KSPSetFromOptions(). You can hardwire stuff before this call, this just lets you set the defaults, but you should always call this last to let command line parameters override the defaults. 


You can put this in a .petscrc file in the working directory and try again. 



-ksp_type cg 
-ksp_max_it 50 

-ksp_rtol 1.e-6 
-ksp_converged_reason 
-pc_type gamg 
-pc_gamg_type agg 
-pc_gamg_agg_nsmooths 1 
-pc_gamg_coarse_eq_limit 10 
-pc_gamg_reuse_interpolation true 
-pc_gamg_square_graph 1 
-pc_gamg_threshold -0.05 
-mg_levels_ksp_max_it 2 
-mg_levels_ksp_type chebyshev 
-mg_levels_esteig_ksp_type cg 
-mg_levels_esteig_ksp_max_it 10 
-mg_levels_ksp_chebyshev_esteig 0,.05,0,1.05 
-mg_levels_pc_type jacobi 
-pc_hypre_type boomeramg 
-pc_hypre_boomeramg_no_CF 
-pc_hypre_boomeramg_agg_nl 1 
-pc_hypre_boomeramg_coarsen_type HMIS 
-pc_hypre_boomeramg_interp_type ext+i 

-------------- next part --------------
A non-text attachment was scrubbed...
Name: jacobi2.log
Type: text/x-log
Size: 9141 bytes
Desc: not available
URL: <http://lists.mcs.anl.gov/pipermail/petsc-dev/attachments/20160726/9d56aea2/attachment.bin>


More information about the petsc-dev mailing list