Divergence / Vorticity (uv2dv problem)
Added by Ana Aguilar over 4 years ago
Dear all,
I have been trying to figure out how to get divergence and vorticity from U-wind and V-wind. I read that in the documentation for uv2dv the data need to be in a regular gaussian grid and with the variable names of u and v. But I haven't been able to download my NetCDF files (ERA5 and CORDEX) in a regular gaussian grid. If I download my data as GRIB with a regular gaussian grid, then I can't rename the variables to u and v.
I tried to convert the grib file (that was in a regular gaussian grid) to netCDF using: cdo -f nc copy <input grib> <output netcdf> but then the output.nc was 'converted' to lat_lon.
Thanks in advance for the help you can provide me.
Best,
Ana
PD: I couldn't upload the file, because it was too heavy.
Replies (4)
RE: Divergence / Vorticity (uv2dv problem) - Added by Karin Meier-Fleischer over 4 years ago
Hi Ana,
without the data it's difficult to help.
Try
cdo -f nc -copy -setgridtype,regular infile.grb outfile.nc
-Karin
RE: Divergence / Vorticity (uv2dv problem) - Added by Ana Aguilar over 4 years ago
Thanks Karin for your fast response.
I tried your approach, but it didn't work. I got again the in grid type: lat_lon. But I continue and changed the names using and try to get the divergence/vorticity:
cdo -f nc -copy -setgridtype,regular uv_N320.grb uv_N320.nc cdo chname,var165,u,var166,v uv_N320.nc uv.nc cdo uv2dv uv.nc dv.nc
And then I got: U-wind and V-wind not found.
This time I am attaching one month of data in the three possible formats/grids that I can obtain the data.
Thanks again,
Ana
uv_F320.grb (18.6 MB) uv_F320.grb | in full (or regular) Gaussian grid N320 | ||
uv.nc (23.5 MB) uv.nc | lon_lat netCDF | ||
uv_N320.grb (18.9 MB) uv_N320.grb | ECMWF original reduced Gaussian grid |
RE: Divergence / Vorticity (uv2dv problem) - Added by Uwe Schulzweida over 4 years ago
For GRIB files you have to change the code numbers:
cdo uv2dv -chcode,165,131,166,132 -setgridtype,regular uv_N320.grb dv.grbUnfortunately this won't help you, because the function uv2dv needs the input data on a global Gaussian grid. The global spectral transformation used does not work for regional data, sorry.
RE: Divergence / Vorticity (uv2dv problem) - Added by Ana Aguilar over 4 years ago
Dear Uwe,
Thanks for your response.
For ERA5 data I can get the global, but when I have to move to CORDEX RCMs this will not be possible. But thanks for the information. I can move on to try other solutions.
Thanks,
Ana