State-dependent custom operators for block preconditioning - #1649
Open
tlroy wants to merge 6 commits into
Open
Conversation
tlroy
force-pushed
the
roy/state-dependent-custom-schur
branch
from
August 19, 2026 19:59
fff47df to
e911c14
Compare
tupek2
reviewed
Aug 19, 2026
|
|
||
| mfem::Vector block_view; | ||
| block_view.MakeRef(const_cast<mfem::Vector&>(state), block_begin, block_size); | ||
| *field.get() = block_view; |
Collaborator
There was a problem hiding this comment.
Directly updating the FiniteElementState within a FieldState is a bit scary because the
FieldState is tracked on the graph, so this could potentially make the graph invalid; perhaps
a scratch FiniteElementState could be used instead.
Contributor
Author
There was a problem hiding this comment.
Ok I made a change so that the weak-form block operator assembles from temporary copies of the input fields, rather than overwriting FieldStates.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds state-dependent custom Schur complement approximations for block preconditioners.
Users can provide a custom Schur operator directly, or define one from a weak form whose coefficients depend on the current nonlinear solution. Before each Newton linearization, the preconditioner rebuilds that operator using the latest block state, then uses it for the Schur solve. The PR also adds the weak-form helper API and tests for fixed and state-dependent custom Schur approximations.