Versions Compared
Key
- This line was added.
- This line was removed.
- Formatting was changed.
1. Experiment with using the different grib_dump options
(-O, -a and –t). Inspect the GRIB message in the files file1.grib1 and file1.grib2 and identify:
the GRIB edition used to encode the messages
the (MARS) parameter ID, date, time, forecast step and the grid geometry
What are the maximum, minimum and average values of the fields?
Expand | ||
---|---|---|
| ||
To view the keys available for GRIB1 and GRIB2 have a look at the parameter database at http://apps.ecmwf.int/codes/grib/
Similarly for the file file2.grib2
|
2. Use grib_ls to print the centre, dataDate, stepRange, levelType, shortName and paramId for msl.grib1 and msl.grib2 and order by ascending stepRange.
Experiment with both –P and –p options and ‘key:i’, ‘key:s’
Which keys does grib_ls show by default for the two files ?
What fields do they contain
Expand | ||
---|---|---|
| ||
To list the GRIB messages in msl.grib1, use:
The file contains mean sea-level pressure (shortName=msl) from the ECMWF ENS control forecast (dataType=cf) for 6-hourly steps from 6 to 24 hours for dataDate=20190201. The messages are encoded in GRIB edition 1.
|
3. Find the value of the MSLP at the grid point nearest to ECMWF (Lat 51.42°N, Lon 0.95° W) at each forecast step
What is the lat-lon value of the grid point nearest to ECMWF ?
How far is the chosen grid point from ECMWF ?
Use the file lsm.grib1 to provide a land-sea mask - are all four nearest grid points land points (mask ≥ 0.5) ?
Expand | ||
---|---|---|
| ||
To list the nearest points to ECMWF (Lat 51.42 N, Lon 0.95 W) use 4 of 4 messages in msl.grib1 4 of 4 total messages in 1 files Input Point: latitude=51.42 longitude=-0.95 Grid Point chosen #2 index=156197 latitude=51.38 longitude=359.03 distance=4.79 (Km) Other grid Points - 1 - index=156198 latitude=51.38 longitude=359.35 distance=21.64 (Km) - 2 - index=156197 latitude=51.38 longitude=359.03 distance=4.79 (Km) - 3 - index=155082 latitude=51.52 longitude=359.35 distance=23.65 (Km) - 4 - index=155081 latitude=51.52 longitude=359.03 distance=11.09 (Km) Note we specify the longitude of 0.95 W with -0.95 ! The nearest grid point is at latitude=51.38 longitude=359.03 (=0.97 W) and is 4.79 km from ECMWF. msl.grib1 stepRange value 6 98263.5 12 98621.1 18 99085.2 24 99593.2 4 of 4 messages in msl.grib1 4 of 4 total messages in 1 files Input Point: latitude=51.42 longitude=-0.95 Grid Point chosen #2 index=156197 latitude=51.38 longitude=359.03 distance=4.79 (Km) Other grid Points - 1 - index=156198 latitude=51.38 longitude=359.35 distance=21.64 (Km) - 2 - index=156197 latitude=51.38 longitude=359.03 distance=4.79 (Km) - 3 - index=155082 latitude=51.52 longitude=359.35 distance=23.65 (Km) - 4 - index=155081 latitude=51.52 longitude=359.03 distance=11.09 (Km)
msl.grib1 stepRange value1 value2 value3 value4 6 98236.5 98263.5 98293.5 98319.2 12 98596.1 98621.1 98644.4 98666.1 18 99043 99085.2 99074.5 99116 24 99547 99593.2 99561.5 99612.2 4 of 4 messages in msl.grib1 4 of 4 total messages in 1 files Input Point: latitude=51.42 longitude=-0.95 Grid Point chosen #2 index=156197 latitude=51.38 longitude=359.03 distance=4.79 (Km) Other grid Points - 1 - index=156198 latitude=51.38 longitude=359.35 distance=21.64 (Km) - 2 - index=156197 latitude=51.38 longitude=359.03 distance=4.79 (Km) - 3 - index=155082 latitude=51.52 longitude=359.35 distance=23.65 (Km) - 4 - index=155081 latitude=51.52 longitude=359.03 distance=11.09 (Km) To specify the land-sea mask, use: msl.grib1 stepRange value 6 98263.5 12 98621.1 18 99085.2 24 99593.2 4 of 4 messages in msl.grib1 4 of 4 total messages in 1 files Input Point: latitude=51.42 longitude=-0.95 Grid Point chosen #2 index=156197 latitude=51.38 longitude=359.03 distance=4.79 (Km) Mask values: - 1 - index=156198 latitude=51.38 longitude=359.35 distance=21.64 (Km) value=1.00 - 2 - index=156197 latitude=51.38 longitude=359.03 distance=4.79 (Km) value=0.99 - 3 - index=155082 latitude=51.52 longitude=359.35 distance=23.65 (Km) value=0.99 - 4 - index=155081 latitude=51.52 longitude=359.03 distance=11.09 (Km) value=0.99 Here the mask value at the end of the line showing the four nearest grid points indicates which are land points: Land points have mask ≥ 0.5; sea points have mask<0.5. This works in the same way for msl.grib2. Note that you can pass the land-sea mask file as either GRIB edition 1 or GRIB edition 2. |