[petsc-users] When does DIVERGED_LINE_SEARCH Happen?
Barry Smith
bsmith at mcs.anl.gov
Sat Mar 15 10:15:12 CDT 2014
Failed line search are almost always due to an incorrect Jacobian. Please let us know if the suggestions at http://www.mcs.anl.gov/petsc/documentation/faq.html#newton don’t help.
Barry
On Mar 14, 2014, at 8:57 PM, Dafang Wang <dafang.wang at jhu.edu> wrote:
> Hi,
>
> Does anyone know what the error code DIVERGED_LINE_SEARCH means in the SNES nonlinear solve? Or what scenario would lead to this error code?
>
> Running a solid mechanics simulation, I found that the occurrence of DIVERGED_LINE_SEARCH was very unpredictable and sensitive to the input values to my nonlinear system, although my system should not be that unstable. As shown by the two examples below, my system diverged in one case and converged in the other, although the input values in these two cases differed by only 1e-4,
>
> Moreover, the Newton steps in the two cases were very similar up to NL step 1. Since then, however, Case 1 encountered a line-search divergence whereas Case 2 converged successfully. This is my main confusion. (Note that each residual vector contains 3e04 DOF, so when their L2 norms differ within 1e-4, the two systems should be very close.)
>
> My simulation input consists of two scalar values (p1 and p2), each of which acts as a constant pressure boundary condition.
>
> Case 1, diverge:
> p1= -10.190869 p2= -2.367555
> NL step 0, |residual|_2 = 1.621402e-02
> Line search: Using full step: fnorm 1.621401550027e-02 gnorm 7.022558235262e-05
> NL step 1, |residual|_2 = 7.022558e-05
> Line search: Using full step: fnorm 7.022558235262e-05 gnorm 1.636418730611e-06
> NL step 2, |residual|_2 = 1.636419e-06
> Nonlinear solve did not converge due to DIVERGED_LINE_SEARCH iterations 2
> Case 2: converge:
> p1= -10.190747 p2= -2.367558
> NL step 0, |residual|_2 = 1.621380e-02
> Line search: Using full step: fnorm 1.621379778276e-02 gnorm 6.976373804153e-05
> NL step 1, |residual|_2 = 6.976374e-05
> Line search: Using full step: fnorm 6.976373804153e-05 gnorm 4.000992847275e-07
> NL step 2, |residual|_2 = 4.000993e-07
> Line search: Using full step: fnorm 4.000992847275e-07 gnorm 1.621646014441e-08
> NL step 3, |residual|_2 = 1.621646e-08
> Nonlinear solve converged due to CONVERGED_SNORM_RELATIVE iterations 3
>
> Aside from the input values, the initial solution in both cases may differ very slightly. (Each case is one time step in a time-sequence simulation. The two cases behaved nearly identically up to the last time step before the step shown above, so their initial solutions may differ by a cumulative error but such error should be very small.) Is it possible that little difference in initial guess leads to different local minimum regions where the line search in Case 1 failed?
>
> Any comments will be greatly appreciated.
>
> Thanks,
> Dafang
> --
> Dafang Wang, Ph.D
> Postdoctoral Fellow
> Institute of Computational Medicine
> Department of Biomedical Engineering
> Johns Hopkins University
> Hackerman Hall Room 218
> Baltimore, MD, 21218
More information about the petsc-users
mailing list