Previous: GEMPAK Projection Examples Next: GRID DIAGNOSTIC EXERCISES Table of contents Frames User Manual GEMPAK Online Tutorial

5.7| GEMPAK Grid Diagnostics
GEMPAK possess a robust set of mathmatical and meteorological functions which may be used in the grid programs to generate a wide range of diagnostics.

Formulas can be extended up to 128 characters. When designing complex equations, it is often helpful to develop the equation in pieces, or terms. In these cases, GDDIAG can be used to calculate store the terms, for ultimate use in the final expansion.

When storing grids with GDDIAG, the variable GRDNAM will be used to define a name for the new parameter. If this parameter is left blank, GEMPAK will compose a name based on the variables and functions used in the expression.


In-line Modifiers

Many times, a single GLEVEL, GDATTIM, or even GVCORD is not sufficient for calculating all the quantities in a formula. In these cases we need to use in-line modifiers.

In line expansions allow us to modify the values used for a parameter in a per-variable manner.

The following may be used to specify a value other than that which a variable would obtain if using the values specified in the user interface variables:

Additionally, we may need to specify more than 1 value, as in the case of a layer quantity such as thickness between pressure levels, or as in time differences such as the height change of a surface with time.

When we have to specify more than 1 value for a level or time parameter (either in GLEVEL and GDATTIM, or through the in-line modifiers) the values are separated with a : (colon).

Multiple Grid Files

When multiple grid files are used, a + character is used in the GDFILE variable to separate the filenames. Then when referencing which file a grid field should be found, the variable is appended with +n, where n is the number of the grid file in the order given in GDFILE.

Remember the batch script we created? Now we're going to modify it perform more complicated grid diagnostics.

1) Using the ability to open multiple input files, compare the 24 hour 500mb height forecast from the GFS and ETA models by computing the difference of the height fields.

2) Produce a contour plot of the 1000-500mb change in thickness between the 0 and 24 hour forecast ETA fields.

3) Contour the advection of 500mb geostrophic relative vorticity by the thermal wind in the 300mb to 700mb layer (ie Trenberth's Q-G formula).

4) Calculate and plot helicity for the 1000mb - 700mb layer using the formula:

 


Previous: GEMPAK Projection Examples Next: GRID DIAGNOSTIC EXERCISES Table of contents Frames User Manual GEMPAK Online Tutorial