New Options for Chi Correction in MAC Projections#401
Merged
baperry2 merged 6 commits intoAMReX-Combustion:developmentfrom Sep 11, 2024
Merged
New Options for Chi Correction in MAC Projections#401baperry2 merged 6 commits intoAMReX-Combustion:developmentfrom
baperry2 merged 6 commits intoAMReX-Combustion:developmentfrom
Conversation
drummerdoc
approved these changes
Jul 23, 2024
drummerdoc
left a comment
There was a problem hiding this comment.
Not surprising that divu can be a bit messy. Does this get better with resolution?
Collaborator
Author
|
The convergence gets much better with smaller timesteps. I'm not sure about grid resolution, but I imagine that also helps. |
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.
This was needed for the manifold stuff, so moving it in now to capture some progress toward fully merging that capability. Probably won't merge the rest for a while though.
This PR does two things:
DivuEveryIter(current, remains default),DivuFirstIter(the estimate of Divu computed on the 0th SDC iteration is kept constant, and only the chi correction is used to drive the solution toward convergence)NoDivu(the Divu estimates are ignored in the MAC projection and only the chi correction is used to iteratively ensure the actual pressure (RhoRT) matches the desired value)For the PMF case, it can be observed that the second option provides better convergence of the pressure than the first. My working hypothesis is that updating the estimated divergence constraint essentially adds noise to the iterative update of the chi correction. The converged solution with infinite SDC iterations would be the same between all methods, but the rate of convergence is not. The existing approach is left as the default because the alternative
DivuFirstIterapproach hasn't been tested for a wide range of cases yet. TheNoDivuoption should never be used and is only included for comparison. In the latter two options, some compute could be saved by not recomputing the divergence estimate at each n+1,k, but for now it is computed but then ignored.