Allow updating coefficients and reuse same solver instances. (Draft) - #317
Open
julianlitz wants to merge 2 commits into
Open
Allow updating coefficients and reuse same solver instances. (Draft)#317julianlitz wants to merge 2 commits into
julianlitz wants to merge 2 commits into
Conversation
julianlitz
commented
Aug 11, 2026
| // Finalize solver setup (allocate data, build operators, etc.). | ||
| void setup(); | ||
|
|
||
| void updateOperatorValues(const DomainGeometry* domain_geometry = nullptr, |
Collaborator
Author
There was a problem hiding this comment.
It is possible to add such update Function.
Then you can keep using the same instance and avoid costly memory allocations.
I made this quick proof of concept with Claude.
Just let me know if we need such functionality or if you are fine with creating a new solver instance.
Depends how often you need to create a new instance if this refactoring is worth the effort.
Collaborator
Author
|
Getting Mumps and the CSR solver to work correctly will be a pain 😂 We can also just ignore those and do a full rebuild just for the smoothers and direct solver. Then at least we avoid the level allocations. |
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.
Merge Request - GuideLine Checklist
Guideline to check code before resolve WIP and approval, respectively.
As many checkboxes as possible should be ticked.
Checks by code author:
Always to be checked:
If functions were changed or functionality was added:
If new functionality was added:
If new third party software is used:
If new mathematical methods or epidemiological terms are used:
Checks by code reviewer(s):