SNES Convergence

Barry Smith bsmith at mcs.anl.gov
Mon Jan 7 15:35:35 CST 2008


   Sean,

     Can you run the ls version with the additional options -info - 
snes_monitor and send
the results?  You could also make a run with -snes_mf_operator and see  
if that "converges"
in the same way or not (this is another check that the analytic  
Jacobian is right/wrong).


     Thanks

      Barry

On Jan 7, 2008, at 3:30 PM, Sean Dettrick wrote:

> Hi,
>
> I am solving a version of the Grad-Shafranov equation, F(x)=0, which  
> but for some extra spatial dependences is similar in form to the 2D  
> Bratu equation in snes/examples/tutorials/ex5.c.  I started with the  
> ex5.c code, introducing just enough changes to model the new  
> system.  The analytic Jacobian function appears to be correct, with  
> a Norm of matrix ratio < 1.e9 (found using -snes_type test).
>
> The problem I am having is that in most cases the SNES solver does  
> not converge to a solution x of F(x)=0.  Rather, what happens is  
> that the fnorm (obtained in a monitor function) converges to some  
> large non-zero value, and F(x) seems to get "stuck", i.e. it  
> converges to a large non-zero result.  Even though it is clearly not  
> a solution, the  -snes_converged_reason is reported as "Nonlinear  
> solve converged due to CONVERGED_TR_DELTA".  The intermediate KSP  
> steps have -ksp_converged_reason reported as "Linear solve converged  
> due to CONVERGED_STEP_LENGTH".  I have been typically running with  
> parameters -da_grid_x 100 -da_grid_y 101 -snes_converged_reason - 
> ksp_converged_reason -snes_type tr -ksp_type gmres -snes_max_it 100.
>
> Does this sound like a familiar scenario with a familiar solution?   
> Or can anyone point me to some documentation that describes the SNES  
> tr and ls parameters in more detail than the manual.pdf?
> Or can anyone recommend the best SNES and KSP parameters for the  
> Bratu example?
>
> Any help or advice would be greatly appreciated.
>
> Thanks,
> Sean Dettrick




More information about the petsc-users mailing list