save Zmix in nonpremixed and do better at saving extinction#31
Merged
baperry2 merged 2 commits intodevelopmentfrom Jan 12, 2026
Merged
save Zmix in nonpremixed and do better at saving extinction#31baperry2 merged 2 commits intodevelopmentfrom
baperry2 merged 2 commits intodevelopmentfrom
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| ) | ||
| flame = get_new_flame() | ||
| update_flame(flame, ext_alpha) | ||
| flame.solve() |
There was a problem hiding this comment.
The flame.solve() call here lacks error handling. If this solve fails, it will raise an unhandled exception and crash the program. Consider wrapping this in a try-except block or using func_timeout like the other solve calls in this file.
Suggested change
| flame.solve() | |
| try: | |
| flame.solve() | |
| except FunctionTimedOut as exc: | |
| print( | |
| f"rank {rank}: Extinct flame solve timed out at alpha = {ext_alpha}: {exc}", | |
| flush=True, | |
| ) | |
| solve_failed = True | |
| break | |
| except Exception as exc: | |
| print( | |
| f"rank {rank}: Extinct flame solve failed at alpha = {ext_alpha}: {exc}", | |
| flush=True, | |
| ) | |
| solve_failed = True | |
| break |
| # strain rate increase is reached, save the last, non-burning, solution | ||
| # to the output file and break the loop | ||
|
|
||
| # if last solve failed, recompute with vhigh strain to get extinct flame |
There was a problem hiding this comment.
Comment contains a typo: "vhigh" should be "very high" or "v. high".
Suggested change
| # if last solve failed, recompute with vhigh strain to get extinct flame | |
| # if last solve failed, recompute with very high strain to get extinct flame |
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.
For nonpremixed flamelets we need to save the mixture fraction as part of the flamelet data.
Also, if the flame solve fails hen approaching extinction, do a new solve at high strain rate automatically to get an extinct flamelet.