0

I know that we can get the residual if use 'sweep' to solve the equation, but what is the formula for computing residual in fipy? Is it the difference between the two sides of the equation? And why the residual of my equation decrease very slowly? Can anyone help me? Thanks !

1 Answers1

0

The residual returned by sweep() is the L2-norm of L*x - b (where L is the matrix, x is the solution vector, and b is the right-hand-side vector for the system of linear equations obtained from discretizing your equation(s)). I have filed issue #734 to add documentation of this.

As to why the residual is decreasing very slowly, that's impossible to say without knowing what equations you are solving and how you are solving them.

jeguyer
  • 2,379
  • 1
  • 11
  • 15