Discussion Closed This discussion was created more than 6 months ago and has been closed. To start a new discussion with a link back to this one, click here.

Error on convergence plot versus Relative Error

Please login with a confirmed email address before reporting spam

How exactly does the error that is shown on the convergence plot relate to the relative error needed for actual convergence? The plot seems to suggest that the current solution has an absolute error of around 10e-10 however when the solution stopped it returned the message:

The relative error (4e+002) is greater than the relative tolerance.

My guess is that the error shown on the plot is the difference between the current solution and the estimated exact solution. Why is the relative error so drastically different and why is it important for convergence if the current and exact solution appear to be very close in value?

I have attached a picture of my convergence plot.

Any insight would be appreciated. Thanks!

- Peter


1 Reply Last Post 31.01.2014, 08:58 GMT-5
Henrik Sönnerlind COMSOL Employee

Please login with a confirmed email address before reporting spam

Posted: 1 decade ago 31.01.2014, 08:58 GMT-5
Hi,

Without knowing the details of your solver configuration, I will attempt to give an explanation.

The graph of the error in the nonlinear solver shows an estimate of the relative error in the solution after each iteration. With default settings, the convergence criterion is 1E-3, so unless you have tightened the tolerances very much, you would expect convergence already after iteration 3.

There are however a number of underlying sanity checks which also need be passed if the solution is to be accepted. In your case, it seems that the error estimate in the underlying linear solver is to large. Think of the nonlinear problem as




What you see in the graph is an attempt to estimate in iteration i. But while solving the problem using the Newton method, the stiffness matrix must be inverted in each iteration. When the equation solver doing that job finds that is ill-conditioned, it will signal an a error. This is the error message that you see printed.

You can suppress this check. Go into the solver sequence, identify the 'Error' section in the 'Direct' node, and change 'Check error estimate' from 'Automatic' to 'No'. If you do so, you will probably get a converged solution, but you must inspect you results critically, since the error estimate in the nonlinear procedure may be inaccurate in this situation.

You can also try setting 'Check error estimate' to 'Yes'. In that case, the nonlinear solver will give up as soon as an ill-conditioned matrix is encountered. In this way you can investigate if your problem is ill-conditioned right from the start, or as an effect of nonlinearities in the solution.

Another discussion about convergence can be found in www.comsol.com/community/forums/general/thread/35375

Regards,
Henrik
Hi, Without knowing the details of your solver configuration, I will attempt to give an explanation. The graph of the error in the nonlinear solver shows an estimate of the relative error in the solution after each iteration. With default settings, the convergence criterion is 1E-3, so unless you have tightened the tolerances very much, you would expect convergence already after iteration 3. There are however a number of underlying sanity checks which also need be passed if the solution is to be accepted. In your case, it seems that the error estimate in the underlying linear solver is to large. Think of the nonlinear problem as [math] \mathbf K (\mathbf u) \mathbf u= \mathbf f [/math] What you see in the graph is an attempt to estimate [math] \mathbf u^{(i)} - \mathbf u_{exact} [/math] in iteration i. But while solving the problem using the Newton method, the stiffness matrix [math] \mathbf K [/math] must be inverted in each iteration. When the equation solver doing that job finds that [math] \mathbf K^{(i)} [/math] is ill-conditioned, it will signal an a error. This is the error message that you see printed. You can suppress this check. Go into the solver sequence, identify the 'Error' section in the 'Direct' node, and change 'Check error estimate' from 'Automatic' to 'No'. If you do so, you will probably get a converged solution, but you must inspect you results critically, since the error estimate in the nonlinear procedure may be inaccurate in this situation. You can also try setting 'Check error estimate' to 'Yes'. In that case, the nonlinear solver will give up as soon as an ill-conditioned matrix is encountered. In this way you can investigate if your problem is ill-conditioned right from the start, or as an effect of nonlinearities in the solution. Another discussion about convergence can be found in http://www.comsol.com/community/forums/general/thread/35375 Regards, Henrik

Note that while COMSOL employees may participate in the discussion forum, COMSOL® software users who are on-subscription should submit their questions via the Support Center for a more comprehensive response from the Technical Support team.