Replies: 1 comment 4 replies
-
Yikes! Can you post some sample code, especially showing your call to |
Beta Was this translation helpful? Give feedback.
4 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello,
first of all, thank you for the great work. Metpy, and its integration with xarray, has been incredibly useful for my research.
I am writing about using
metpy.calc.vorticity
on a Lambert Azimuthal Equal Area grid around the north pole. As can be seen in the left panel of the attached picture, the sign of the computed vorticity is inverted in the upper half of the domain. The right panel shows what the vorticity should look like, as computed with xarray'sdifferentiate
.The issue seems to originate in the azimuth dependent change of sign within the
metpy.calc.lat_lon_grid_deltas
function. Indeed, if I comment out line 848 and line 854 ofmetpy/calc/tools.py
, the vorticity is returned with the correct sign over the entire domain. At the same time, I am afraid that changing the code will break the computation on other grids.The definition of the grid I am using is
grid = { 'grid_mapping_name':'lambert_azimuthal_equal_area', 'longitude_of_projection_origin':0, 'latitude_of_projection_origin':90, 'false_easting':0, 'false_northing':0 }
Any help in understanding how to compute the correct vorticity would be greatly appreciated.
Thank you again for the great work!
Gianluca
Beta Was this translation helpful? Give feedback.
All reactions