rustychris / stomel

Spatial tools for ocean modeling in python
GNU General Public License v2.0
10 stars 6 forks source link

Regional refinement #2

Open pwolfram opened 8 years ago

pwolfram commented 8 years ago

Is there a way to take an existing mesh that has a hole and essentially using that mesh as a fixed mesh then fill it in to produce an location of enhanced refinement? Is this something that needs to be done in an ad hoc manner, e.g., provide the boundary for the region of interior refinement as a set of fixed points and then join that mesh with its parent or is there an already established way to do this?

Essentially the end goal is to have a periodic mesh that has a region of interior refinement. We already have the periodic mesh but a general method to produce interior refinement is lacking. Attempts via a conformal transform yields highly limited refinement rates and is not practical or generally useful. Stomel seems like the ideal tool to build this type of grid because it all but guarantees an orthogonal mesh for highly generalized density functions.

Provided this is straight forward to implement in stomel this could even be a PR with an example notebook to demonstrate usage.

cc @vanroekel

rustychris commented 8 years ago

Hi Phil - Check out the second notebook example just added. Not fully tested yet, but hopefully the method is clear. If this seems like it would fit the bill, we could collaborate on making this a bit more streamlined.

pwolfram commented 8 years ago

Thanks @rustychris! This perfect-- thank you very much for the outline of how to do this! Essentially what I need to do is to build out a reader / writer for the MPAS format and then follow your workflow. The reader/writer should not be too difficult and is probably worth of a PR on its own. The tricky part is ensuring that "protected" boundary topology is protected, e.g., ensure that periodicity is not accidentally removed on output, but it seems like that wouldn't be too hard. Thanks for setting us up here... more later.