Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

There are several programs distributed with OpenIFS that can be useful in working with the grids used by the model. These are documented here.

All these programs except for 'gaussgr' are compiled executables, build when the OpenIFS model is compiled. By default, after compilation, they can be found in the 'make' directory in the build sub-directory pointed to by the OIFS_COMP & OIFS_BUILD environment variables. e.g. for OIFS_COMP=gnu, OIFS_BUILD=opt, the compiled executables are found in 'make/gnu-opt/oifs/bin'.


Number of latitudes in a grid: gaussgr

The command 'gaussgr' returns the number of latitudes between the pole and the equator for a given input resolution and grid type. It is a bash script and can be found in the 'bin' directory of the OpenIFS distribution.

Code Block
languagebash
titleTo see command arguments...
% gaussgr -h
Usage: gaussgr  -r resol  -g gtype
     resol : spectral truncation wavenumber
     gtype should be one of:
       l_2    - linear reduced (default)
       l_full - linear regular (full)
       _2     - quadratic reduced
       _full  - quadratic regular (full)
       _3     - cubic reduced
       _4     - cubic octahedral


Info

For grid types, see 3 Horizontal Resolution and Configurations


Code Block
languagebash
titleShow latitudes for Tco95 cubic octahedral grid...
% gaussgr -r 95 -g _4
96


Code Block
languagebash
titleShow latitudes for Tl511 linear reduced grid...
% gaussgr -r 511 -g l_2
256


Get resolution of GRIB files: getres

This command will provide all resolution information by reading OpenIFS GRIB files (both initial files and model output files).

Note getres.exe is a compiled program provided with OpenIFS and not a Bash script.

Code Block
languagebash
titleTo see command arguments...
% getres.exe -h
  GETRES VERSION  1.0                                                            
  getres -s spfile -g gpfile -p path [-o out]
  delivers :
  INPUT_RESOL, INPUT_LEVELS, INPUT_GTYPE
     spfile = input spectral file (required)
     gpfile = input grid-point file (required)
     path   = dirpathname of resol-table file
     out    = output filename (default:"result"

The command expects the location of the 'resolution: res' files provided with in the 'ifsdata' directory. It helps if the OpenIFS environment variable OIFS_DATA_DIR is set (see the file oifs-config.sh in the OpenIFS distribution).

Code Block
languagebash
titleExtract resolution information from T21 test GRIB files...
% getres.exe -s ICMSHepc8INIT -g ICMGGepc8INIT -p $OIFS_DATA_DIR/rtables
  GETRES VERSION  1.0                                                            
  OUTPUT FILENAME IS "./result" 
  INPUT_RESOL=          21
  INPUT_LEVELS=          19
  INPUT_GTYPE= _full


Code Block
languagebash
titleExtract resolution information from cubic octahedral initial files...
% getres.exe -s ICMSHhah0INIT -g ICMGGhah0INIT -p $OIFS_DATA_DIR/rtables
  GETRES VERSION  1.0                                                            
  OUTPUT FILENAME IS "./result" 
  PATH openifs/ifsdata/43r3/rtables/rtable_4095                                                                          
  INPUT_RESOL=          95
  INPUT_LEVELS=          60
  INPUT_GTYPE= _4   


HTML Comment
hiddentrue

grib_set_vtable

this sets grib headers according to a specified resolution.



HTML Comment
hiddentrue

rgrid

This is a MPI enabled command that, in the 43r3 code at least, doesn't appear to support cubic & cubic octahedral grids. Omit this for now?








Excerpt Include
Credits
Credits
nopaneltrue





Panel
borderColorgrey

On this page ...

Table of Contents


Panel
borderColorgrey
titleIn this section...

Children Display
depth1
pageGrid and Resolution