Skip to content

Conversation

@reint-fischer
Copy link
Contributor

@reint-fischer reint-fischer commented Nov 18, 2025

I have rewritten the interpolation tutorial to work in v4. To do this we needed to fix the XLinearInvdistLandTracer interpolator (in #2389).

TODO

  • List all parcels.interpolators.*
  • Discuss writing your own interpolator
  • Fix C-grid Tracer interpolation

@erikvansebille
Copy link
Member

I think it would also be good to make clear in the notebook that these are the interpolators for structured (X) grids. This notebook currently doesn't discuss unstructured (UX) grids. Do we want to do that in this same tutorial? Or in another one?

@fluidnumerics-joe, do you have a simple fieldset we can use for a tutorial like this too? Do you want to write it?

@reint-fischer
Copy link
Contributor Author

reint-fischer commented Nov 18, 2025

The C-grid tracer interpolation method now returns values from the bottom-left corner rather than the top-right (as in v3).

image

@erikvansebille is this because the default indexing is now as in MITgcm or should we change something?

@erikvansebille
Copy link
Member

Good catch, @reint-fischer! The parsing of grid indexing to the Interpolators still needs to be fixed, it's on the high-priority "Must have" list before v4 (but no tracking Issue yet).

@reint-fischer
Copy link
Contributor Author

I think it would also be good to make clear in the notebook that these are the interpolators for structured (X) grids. This notebook currently doesn't discuss unstructured (UX) grids. Do we want to do that in this same tutorial? Or in another one?

@fluidnumerics-joe, do you have a simple fieldset we can use for a tutorial like this too? Do you want to write it?

If there is a simple UX grid fieldset, I would be happy to work with Joe to implement it in this tutorial. If not, I can add a TODO note in the notebook

@reint-fischer
Copy link
Contributor Author

I have scaffolded out some further explanation on interpolation, including on unstructured grids and implementing partial slip and free slip boundary conditions. I think it would be useful to have a separate .md explanation similar to the Kernel loop tutorial, which is not a how-to guide notebook, but rather discusses how interpolation functions work in parcels and how to use the interpolator API to write your own. I have now created a rough draft in explanation_interpolators.md. Please let me know if you have any thoughts about this.

@reint-fischer reint-fischer merged commit e4da651 into v4-dev Nov 20, 2025
11 checks passed
@github-project-automation github-project-automation bot moved this from Backlog to Done in Parcels development Nov 20, 2025
@reint-fischer reint-fischer deleted the interpolation_tutorial_v4 branch November 20, 2025 07:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

3 participants