Re: [idvusers] Problem with plotting thermal wind vectors from GRIB2 files

Kevin and IDV users List-

As I told Kevin offline, I'm going to add some functionality to the layerDifference and layerAverage functions that will allow the user to specify the units of the levels. The default value is to use the units of the levels in the data. I will add this after the next 3.0 update to make sure it doesn't create any unforseen problems.

So, Kevin will be able to change his formula below to be:

thrm(F1,user_Top_of_Layer[default=500],user_Bottom_of_Layer [default=1000],user_Level_Units[default=hPa])

However, one thing to note about this is that the IDV has to download all the levels and then select out the levels that the user requests. For large grids, this can take some time. The user can use the Levels tab in the Data Subset panel to select the range from the top level to bottom level to reduce the amount of data downloaded, but that still can be quite a lot of data.

Another way to do this is to create a formula that takes just the two levels. For thermal wind, the formula is:

      THRM ( S ) = [ u (GEO(S)) (level1) - u (GEO(S)) (level2),
                     v (GEO(S)) (level1) - v (GEO(S)) (level2) ]

basically, subtract the components of the geostrophic wind of the base level from the top level. This can be rewritten as:

sub(geo(zTop), geo(zBase))

and the user would select two parameters - z at the top level and z at the base level. While it would be more selecting, it would reduce the amount of data read and speed up the processing time.

Just some food for thought.


On 2/3/12 9:52 AM, Kevin R. Tyle wrote:
Hi all,

I set up a formula in IDV to plot thermal wind vectors, a la:
<derived description="thermal wind in a layer"
[default=1000])" id="thermalWind" isdefault="false" isenduser="true">

Whenever I do this on a GRIB2 format grid file, e.g. realtime NAM or GFS
from the motherlode or atm-nsf opendap servers, I end up with all
missing data when I load in the formula, specify my levels, and choose
the 3D geopotential height from the GRIB2 file.

If I do the same on the same model data that has been converted to
GEMPAK, and also with the sample model data used in the IDV Workshop
(which I believe is GRIB1), the thermal wind vectors plot fine.

I suspect there is some issue specifically related to GRIB2 format here ...

Thanks for looking into this!


Kevin Tyle, Systems Administrator
Dept. of Atmospheric & Environmental Sciences
University at Albany
Earth Science 235, 1400 Washington Avenue
Albany, NY 12222
Email: ktyle@xxxxxxxxxx
Phone: 518-442-4578

idvusers mailing list
For list information, to unsubscribe, visit:

Don Murray