-
Notifications
You must be signed in to change notification settings - Fork 166
Rayleigh-Benard demo using Irksome and patch smoothing #4319
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
* Post-release updates * Set source ref in workflows
* Make linkcheck not prevent later steps * Set AIMS as a flaky link
…didate Merge release changes into master
* Interpolation onto subfunctions * More generic approach using fieldsplit * Interpolate: Fix parloop args ordering * Fix dual * Interpolate from MixedFunctionSpace * Test Interpolate from vector/mixed to mixed * Interpolate from (scalar/mixed) to (scalar/mixed) Co-authored-by: Pablo Brubeck <[email protected]> --------- Co-authored-by: David A. Ham <[email protected]>
demos/time_dependent_rayleigh_benard/timedep-rayleigh-benard.py.rst
Outdated
Show resolved
Hide resolved
* demo for steady Boussinesq problem with integral constraints * fix demo python file locations --------- Co-authored-by: David Ham <[email protected]>
except ImportError: | ||
import sys | ||
warning("Unable to import irksome.") | ||
sys.exit(0) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Rather than do this I would just include a bit like: "This tutorial assumes that you have Irksome installed as well as Firedrake. Instructions for installing Irksome can be found ."
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is how the netgen tutorial is written. But, to make sure the demo runs in our CI, we'll either need to fail gracefully (without an exception) or put Irksome in our CI.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We definitely need irksome in CI for this to land.
…y.rst Co-authored-by: Pablo Brubeck <[email protected]>
…e into rckirby/brandy
Ensure that restoring a BC from checkpoint returns a new BC and doesn't incorrectly modify the program variable BC. --------- Co-authored-by: David A. Ham <[email protected]> Co-authored-by: Pablo Brubeck <[email protected]>
except ImportError: | ||
import sys | ||
warning("Unable to import irksome.") | ||
sys.exit(0) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We definitely need irksome in CI for this to land.
demos/time_dependent_rayleigh_benard/timedep-rayleigh-benard.py.rst
Outdated
Show resolved
Hide resolved
demos/time_dependent_rayleigh_benard/timedep-rayleigh-benard.py.rst
Outdated
Show resolved
Hide resolved
Ts = [] | ||
cur_step = 0 | ||
while float(t) < 1.0: | ||
print(f"t = {float(t)}") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If I had intended you to put print statements in time loops, I would never have given you ProgressBar
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will be the only firedrake demo with a progress bar, FYI.
Ts.append(upT.subfunctions[2].copy(deepcopy=True)) | ||
|
||
|
||
nsp = 16 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is the plotting in the time loop code block? This looks quite odd on the rendered version.
try: | ||
animation.save("benard_temp.mp4", writer="ffmpeg") | ||
except: | ||
print("Failed to write movie! Try installing `ffmpeg`.") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
missing link to Python version of demo.
@@ -0,0 +1,269 @@ | |||
Steady Boussinesq problem with integral constraints |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please don't also attempt to re-merge the Boussinesq demo.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have absolutely no idea how this got here, or why I now have so many changed files after merging.
demos/time_dependent_rayleigh_benard/timedep-rayleigh-benard.py.rst
Outdated
Show resolved
Hide resolved
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The last step is to make the animation and save it to a file. :: | |
…y.rst Co-authored-by: Pablo Brubeck <[email protected]>
…e into rckirby/brandy
…y.rst Co-authored-by: David A. Ham <[email protected]>
demos/time_dependent_rayleigh_benard/timedep-rayleigh-benard.py.rst
Outdated
Show resolved
Hide resolved
Something has gone dreadfully wrong on merging...I'm going to close this and start again. |
Description
Add a demo using Irksome for a time-dependent Rayleigh-Benard convection problem. We use a monolithic multigrid scheme with Vanka patch relaxation for the time stepping.