Skip to content

Fix finite relative-residual at 0th iteration - #3713

Merged
jorgensd merged 2 commits into
FEniCS:mainfrom
RemDelaporteMathurin:patch-1
Apr 28, 2025
Merged

Fix finite relative-residual at 0th iteration#3713
jorgensd merged 2 commits into
FEniCS:mainfrom
RemDelaporteMathurin:patch-1

Conversation

@RemDelaporteMathurin

Copy link
Copy Markdown
Contributor

For what it's worth, this is my attempt at fixing the issue described here by @mcjbo

In legacy-fenics, at the 0th Newton iteration of each timestep, the relative residual was inf. This is no-longer the case in dolfinx and it makes a bunch of our use cases extremely tricky to solve as the step sometimes solves in zero iterations (ie. doesn't solve) when it should.

@jorgensd told me the plan was to replace the NewtonSolver altogether but I thought this could be a quick fix in the meantime

@chrisrichardson

Copy link
Copy Markdown
Contributor

Looks OK to me, it's a pretty minor change.

@RemDelaporteMathurin

Copy link
Copy Markdown
Contributor Author

Just to give a bit more context:

In transient simualtions we sometimes have convergence in zero iterations, leading to:

image
image

Whereas in legacy fenics, the same problem yielded:

image

This is a simple decay problem

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants