-
Notifications
You must be signed in to change notification settings - Fork 241
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
Add cookbook for coupling global models to regional models #6229
base: main
Are you sure you want to change the base?
Add cookbook for coupling global models to regional models #6229
Conversation
63210db
to
ee77f9c
Compare
ee77f9c
to
50a4eaf
Compare
50a4eaf
to
4902e05
Compare
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.
Thank you for contributing this!
I've made a few suggestions for what to change, but it's great to have this explanation and have this workflow documented. I am sure there'll be a time when I want to look up how this works.
|
||
*This section was contributed by Daniel Douglas.* | ||
|
||
In this cookbook we showcase how to use the python script `extract_local_velocity.py` (located in the [/aspect/contrib/python/] directory) to prescribe velocity boundary conditions on a regional spherical chunk using the velocity solution from a global convection model. For the `extract_local_velocity.py` script to work, pvpython must be installed. The idea is that when simulating a 3D spherical chunk the choice of boundary conditions has a non-negligible effect on the regional solution. One can negate the boundary effects by increasing the domain of the regional model, but the far-field effects from global tectonics are still generally ignored by the regional model. By prescribing the velocity solution from a global convection model, the boundary conditions import some of the context of far-field global tectonics that would otherwise be missing from the regional model. We will compare the difference in the resulting solution from an instantaneous Stokes solution in a regional chunk when applying velocity boundary conditions from a global convection model, or applying free slip boundary conditions. In both cases, we will use the S20RTS model as the initial temperature distribution, and the simple material model. We choose the spherical chunk domain spanning from -55$^\circ$ < latitude < -20$\circ$, 152$\circ$ < longitude < 210$\circ$, and 4770 km < radius < 6370 km. |
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 link to [/aspect/contrib/python/] does not work.
I think you need to provide the actual location of the file in parenthesis after the rectangular brackets:
[contrib/python/](https://www.github.com/geodynamics/aspect/blob/main/contrib/python/)
or something like that.
|
||
*This section was contributed by Daniel Douglas.* | ||
|
||
In this cookbook we showcase how to use the python script `extract_local_velocity.py` (located in the [/aspect/contrib/python/] directory) to prescribe velocity boundary conditions on a regional spherical chunk using the velocity solution from a global convection model. For the `extract_local_velocity.py` script to work, pvpython must be installed. The idea is that when simulating a 3D spherical chunk the choice of boundary conditions has a non-negligible effect on the regional solution. One can negate the boundary effects by increasing the domain of the regional model, but the far-field effects from global tectonics are still generally ignored by the regional model. By prescribing the velocity solution from a global convection model, the boundary conditions import some of the context of far-field global tectonics that would otherwise be missing from the regional model. We will compare the difference in the resulting solution from an instantaneous Stokes solution in a regional chunk when applying velocity boundary conditions from a global convection model, or applying free slip boundary conditions. In both cases, we will use the S20RTS model as the initial temperature distribution, and the simple material model. We choose the spherical chunk domain spanning from -55$^\circ$ < latitude < -20$\circ$, 152$\circ$ < longitude < 210$\circ$, and 4770 km < radius < 6370 km. |
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.
increasing the domain --> increasing the domain size
|
||
*This section was contributed by Daniel Douglas.* | ||
|
||
In this cookbook we showcase how to use the python script `extract_local_velocity.py` (located in the [/aspect/contrib/python/] directory) to prescribe velocity boundary conditions on a regional spherical chunk using the velocity solution from a global convection model. For the `extract_local_velocity.py` script to work, pvpython must be installed. The idea is that when simulating a 3D spherical chunk the choice of boundary conditions has a non-negligible effect on the regional solution. One can negate the boundary effects by increasing the domain of the regional model, but the far-field effects from global tectonics are still generally ignored by the regional model. By prescribing the velocity solution from a global convection model, the boundary conditions import some of the context of far-field global tectonics that would otherwise be missing from the regional model. We will compare the difference in the resulting solution from an instantaneous Stokes solution in a regional chunk when applying velocity boundary conditions from a global convection model, or applying free slip boundary conditions. In both cases, we will use the S20RTS model as the initial temperature distribution, and the simple material model. We choose the spherical chunk domain spanning from -55$^\circ$ < latitude < -20$\circ$, 152$\circ$ < longitude < 210$\circ$, and 4770 km < radius < 6370 km. |
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 would also change "negate the boundary effects" to something like "reduce the boundary effects" or "diminish the boundary effects" since the boundary conditions will always have an influence.
|
||
*This section was contributed by Daniel Douglas.* | ||
|
||
In this cookbook we showcase how to use the python script `extract_local_velocity.py` (located in the [/aspect/contrib/python/] directory) to prescribe velocity boundary conditions on a regional spherical chunk using the velocity solution from a global convection model. For the `extract_local_velocity.py` script to work, pvpython must be installed. The idea is that when simulating a 3D spherical chunk the choice of boundary conditions has a non-negligible effect on the regional solution. One can negate the boundary effects by increasing the domain of the regional model, but the far-field effects from global tectonics are still generally ignored by the regional model. By prescribing the velocity solution from a global convection model, the boundary conditions import some of the context of far-field global tectonics that would otherwise be missing from the regional model. We will compare the difference in the resulting solution from an instantaneous Stokes solution in a regional chunk when applying velocity boundary conditions from a global convection model, or applying free slip boundary conditions. In both cases, we will use the S20RTS model as the initial temperature distribution, and the simple material model. We choose the spherical chunk domain spanning from -55$^\circ$ < latitude < -20$\circ$, 152$\circ$ < longitude < 210$\circ$, and 4770 km < radius < 6370 km. |
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.
$^\circ$
does not render a nice degree symbol. I think °
is better.
|
||
*This section was contributed by Daniel Douglas.* | ||
|
||
In this cookbook we showcase how to use the python script `extract_local_velocity.py` (located in the [/aspect/contrib/python/] directory) to prescribe velocity boundary conditions on a regional spherical chunk using the velocity solution from a global convection model. For the `extract_local_velocity.py` script to work, pvpython must be installed. The idea is that when simulating a 3D spherical chunk the choice of boundary conditions has a non-negligible effect on the regional solution. One can negate the boundary effects by increasing the domain of the regional model, but the far-field effects from global tectonics are still generally ignored by the regional model. By prescribing the velocity solution from a global convection model, the boundary conditions import some of the context of far-field global tectonics that would otherwise be missing from the regional model. We will compare the difference in the resulting solution from an instantaneous Stokes solution in a regional chunk when applying velocity boundary conditions from a global convection model, or applying free slip boundary conditions. In both cases, we will use the S20RTS model as the initial temperature distribution, and the simple material model. We choose the spherical chunk domain spanning from -55$^\circ$ < latitude < -20$\circ$, 152$\circ$ < longitude < 210$\circ$, and 4770 km < radius < 6370 km. |
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 will compare the difference in the resulting solution from an instantaneous Stokes solution in a regional chunk when applying velocity boundary conditions from a global convection model, or applying free slip boundary conditions.
That sentence reads a bit confusing, i.e., at first it's not clear what is being compared. I would change it to something like
"We will compare two regional instantaneous models in a chunk geometry, one applying velocity boundary conditions from a global convection model, the other applying free slip boundary conditions.
# boundary conditions. With the exception of the velocity boundary conditions and the | ||
# geometry model, the .prm file for this cookbook is identical to the `initial-condition-S20RTS` | ||
# cookbook .prm file. |
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.
In this case, you should include the other file and only list your changes here. You can then remove this text.
# boundary conditions. With the exception of the velocity boundary conditions and the | |
# geometry model, the .prm file for this cookbook is identical to the `initial-condition-S20RTS` | |
# cookbook .prm file. | |
include $ASPECT_SOURCE_DIR/cookbooks/initial-condition-S20RTS/S20RTS.prm |
# the instantaneous solution. | ||
set End time = 0 | ||
set Use years in output instead of seconds = true | ||
set Output directory = output-chunk-global-S20RTS |
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 assume this is changed from the original as well.
|
||
subsection Chunk | ||
set Chunk inner radius = 4770e3 | ||
set Chunk outer radius = 6370e3 |
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.
Your script says 6360e3, this says 6370e3. Should these be consistent?
# A model which takes utilizes the python script `extract_local_velocity.py` | ||
# to take the output of the global convection cookbook `initial-condition-S20RTS` | ||
# and apply the velocity as boundary conditions in a regional 3D spherical chunk. | ||
# This will outline the workflow for running the `extract_local_velocity.py` script, | ||
# and show how the solution to the regional spherical chunk model varies between the case | ||
# where the boundaries are free-slip, or when the boundaries are prescribed velocity | ||
# boundary conditions. With the exception of the velocity boundary conditions and the | ||
# geometry model, the .prm file for this cookbook is identical to the `initial-condition-S20RTS` | ||
# cookbook .prm file. |
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.
Since this input file does not use the output of the script, I would change the description to say what it actually does. And same as with the other file, include either the S20RTS or the global_regional_coupling file and then only list the lines that are different here.
@@ -105,6 +105,7 @@ cookbooks/continental_extension/doc/continental_extension.md | |||
cookbooks/inner_core_convection/doc/inner_core_convection.md | |||
cookbooks/lower_crustal_flow/doc/lower_crustal_flow.md | |||
cookbooks/global_melt/doc/global_melt.md | |||
cookbooks/global_regional_coupling/doc/global_regional_coupling.md |
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.
Maybe move it after the cookbooks/initial-condition-S20RTS/doc/initial-condition-S20RTS.md
model? These are not in alphabetic order, they're more in thematic order. And the gplates cookbook is another one about boundary conditions, so I think that would be a good spot.
/rebuild |
Motivated by a comment by @gassmoeller today during the ASPECT user meeting about how the python scripts in the contrib folder need to have some application in a cookbook.
This adds a cookbook which demonstrates the workflow that was intended for the python script added in PR #6019. That script takes the output of a global convection model and extracts the velocities along the boundaries of a 3D regional chunk model so that they can be used in an ASPECT model to capture far-field effects outside of the bounds of the regional model. In this cookbook I compare the velocities in a regional chunk when you do and do not account for the far-field effects of a global model, give an example of what the input file looks like, and also the workflow for running the python script.