[grads] 01/06: New upstream release 2.1.a3

Alastair McKinstry mckinstry at moszumanska.debian.org
Tue Jan 5 13:14:47 UTC 2016


This is an automated email from the git hooks/post-receive script.

mckinstry pushed a commit to branch debian/master
in repository grads.

commit 10692651667a612e0268d1f1a568f291f9236e10
Author: Alastair McKinstry <mckinstry at debian.org>
Date:   Sun Jan 3 09:52:47 2016 +0000

    New upstream release 2.1.a3
---
 COPYRIGHT                                 |   13 +-
 INSTALL                                   |   19 +-
 Makefile.in                               |    4 +-
 acinclude.m4                              |   44 +
 aclocal.m4                                |   12 -
 configure                                 | 1926 +++++++++++++++++--
 configure.ac                              |  123 +-
 data/font0.dat                            |   95 +
 data/font1.dat                            |   95 +
 data/font2.dat                            |   95 +
 data/font3.dat                            |   95 +
 data/font5.dat                            |   96 +
 data/hires                                |  Bin 0 -> 1746985 bytes
 data/lowres                               |  Bin 0 -> 51318 bytes
 data/mres                                 |  Bin 0 -> 179044 bytes
 data/tables/B2L-058-000-B                 |  911 +++++++++
 data/tables/B2L-058-000-D                 |   27 +
 data/tables/B2L-058-001-B                 |  779 ++++++++
 data/tables/B2L-058-001-B.001             |  779 ++++++++
 data/tables/B2L-058-001-D                 |   25 +
 data/tables/B2L-058-001-D.001             |   25 +
 data/tables/B2L-058-003-B                 |  520 +++++
 data/tables/B2L-128-001-B                 |   95 +
 data/tables/B2L-128-001-B.001             |   94 +
 data/tables/B2L-128-001-D                 |   25 +
 data/tables/B2L-128-001-D.001             |   25 +
 data/tables/B2M-000-000-0                 |  308 +++
 data/tables/B2M-000-000-A                 |  259 +++
 data/tables/B2M-000-000-B                 |  702 +++++++
 data/tables/B2M-000-000-D                 | 1606 ++++++++++++++++
 data/tables/B2M-000-002-0                 |  308 +++
 data/tables/B2M-000-002-A                 |  259 +++
 data/tables/B2M-000-002-B                 |  710 +++++++
 data/tables/B2M-000-002-D                 | 1878 ++++++++++++++++++
 data/tables/B2M-000-003-0                 |  308 +++
 data/tables/B2M-000-003-A                 |  259 +++
 data/tables/B2M-000-003-B                 |  482 +++++
 data/tables/B2M-000-003-D                 | 1174 ++++++++++++
 data/tables/B3L-058-000-B                 |  520 +++++
 data/tables/B3L-058-000-D                 | 1154 +++++++++++
 data/tables/B3L-058-005-B                 |  779 ++++++++
 data/tables/B3L-058000-005000-B           |  908 +++++++++
 data/tables/B3L-098-001-B                 |   81 +
 data/tables/B3L-098-001-D                 | 1274 +++++++++++++
 data/tables/B3L-128-001-B                 |    7 +
 data/tables/B3L-160000-000001-B           |   52 +
 data/tables/B3L-160000-000001-B-forHDGOES |   52 +
 data/tables/B3L-160000-000001-D           |   83 +
 data/tables/B3L-160000-000001-D-forHDGOES |   83 +
 data/tables/B3L-160000-006001-B           |  814 ++++++++
 data/tables/B3L-160000-006001-B.txt       |  817 ++++++++
 data/tables/B3L-160000-006001-D           | 2673 ++++++++++++++++++++++++++
 data/tables/B3L-160000-006001-D.txt       | 2673 ++++++++++++++++++++++++++
 data/tables/B3L-200-001-B                 |   28 +
 data/tables/B3M-000-003-0                 |  308 +++
 data/tables/B3M-000-004-0                 |  308 +++
 data/tables/B3M-000-004-A                 |  259 +++
 data/tables/B3M-000-004-B                 |  635 +++++++
 data/tables/B3M-000-004-D                 | 1760 +++++++++++++++++
 data/tables/B3M-000-005-0                 |  308 +++
 data/tables/B3M-000-005-A                 |  259 +++
 data/tables/B3M-000-005-B                 |  635 +++++++
 data/tables/B3M-000-005-B.new             |  609 ++++++
 data/tables/B3M-000-005-D                 | 1760 +++++++++++++++++
 data/tables/B3M-000-006-0                 |  308 +++
 data/tables/B3M-000-006-A                 |  259 +++
 data/tables/B3M-000-006-B                 |  648 +++++++
 data/tables/B3M-000-006-D                 | 2001 +++++++++++++++++++
 data/tables/B3M-000-007-0                 |  115 ++
 data/tables/B3M-000-007-A                 |  259 +++
 data/tables/B3M-000-007-B                 |  682 +++++++
 data/tables/B3M-000-007-D                 | 1933 +++++++++++++++++++
 data/tables/B3M-000-008-0                 |  115 ++
 data/tables/B3M-000-008-A                 |  259 +++
 data/tables/B3M-000-008-B                 |  765 ++++++++
 data/tables/B3M-000-008-D                 | 2061 ++++++++++++++++++++
 data/tables/B3M-000-009-0                 |  115 ++
 data/tables/B3M-000-009-A                 |  259 +++
 data/tables/B3M-000-009-B                 |  819 ++++++++
 data/tables/B3M-000-009-D                 | 2226 ++++++++++++++++++++++
 data/tables/B3M-000-010-0                 |  121 ++
 data/tables/B3M-000-010-A                 |  259 +++
 data/tables/B3M-000-010-B                 |  848 +++++++++
 data/tables/B3M-000-010-D                 | 2397 +++++++++++++++++++++++
 data/tables/convert.c                     |  170 ++
 data/udunits.dat                          |  682 +++++++
 doc/Tutorial_Espanol.doc                  |  Bin 171008 -> 177664 bytes
 doc/ascii.html                            |  149 ++
 doc/basemap.html                          |  139 ++
 doc/colorcontrol.html                     |  160 +-
 doc/descriptorfile.html                   |   45 +-
 doc/drawingtips.html                      |   46 +
 doc/font.html                             |   82 +-
 doc/fontcontrol.html                      |   76 +-
 doc/gadoc.html                            |   49 +-
 doc/gadoc_files.tar.gz                    |  Bin 5278845 -> 0 bytes
 doc/gradcomdclear.html                    |   32 +-
 doc/gradcomddisableprint.html             |   17 +-
 doc/gradcomddrawbutton.html               |   63 +-
 doc/gradcomddrawwxsym.html                |   38 +-
 doc/gradcomdenableprint.html              |   30 +-
 doc/gradcomdgxprint.html                  |   86 +
 doc/gradcomdquery.html                    |  204 +-
 doc/gradcomdsdfwrite.html                 |  143 +-
 doc/gradcomdsetantialias.html             |   18 +
 doc/gradcomdsetbackground.html            |   19 +-
 doc/gradcomdsetccols.html                 |   45 +-
 doc/gradcomdsetdefval.html                |  108 +-
 doc/gradcomdsetfont.html                  |   69 +-
 doc/gradcomdsetgxout.html                 |  179 +-
 doc/gradcomdsethershey.html               |   29 +
 doc/gradcomdsetlwid.html                  |   27 +
 doc/gradcomdsetsdfwrite.html              |   85 +-
 doc/gradcomdsettile.html                  |  117 ++
 doc/gradcomdsetvrange.html                |   32 +-
 doc/gradcomdsetvrange2.html               |   16 +-
 doc/gradcomdsetwxcols.html                |   24 +-
 doc/gradfuncaave.html                     |   89 +-
 doc/gradfuncasum.html                     |   55 +-
 doc/gradfunclterp.html                    |   93 +-
 doc/gradutilgrib2scan.html                |  134 +-
 doc/gradutilgribmap.html                  |  144 +-
 doc/imageoutput.html                      |  144 +-
 doc/images/basemapUS.png                  |  Bin 0 -> 37678 bytes
 doc/images/basemap_demo.png               |  Bin 0 -> 21223 bytes
 doc/images/basemap_demo2.png              |  Bin 0 -> 59731 bytes
 doc/images/cmarks.png                     |  Bin 0 -> 826 bytes
 doc/images/letters.png                    |  Bin 0 -> 7981 bytes
 doc/images/pattern_demo.png               |  Bin 0 -> 19880 bytes
 doc/images/pattern_demo2.png              |  Bin 0 -> 173574 bytes
 doc/images/shp_demo4.png                  |  Bin 0 -> 103526 bytes
 doc/images/strpos.png                     |  Bin 0 -> 26246 bytes
 doc/indexlist.html                        |  771 +-------
 doc/library.html                          |   10 +-
 doc/mathfunctions.html                    |  196 +-
 doc/pagecontrol.html                      |    4 +-
 doc/script.html                           | 1283 ++++++++++++-
 doc/shapefiles.html                       |   81 +-
 doc/supplibs.html                         |  153 +-
 doc/templates.html                        |   35 +-
 doc/tutorial.html                         |  375 +---
 doc/tutorial_fig9.png                     |  Bin 0 -> 13067 bytes
 src/Makefile.am                           |   61 +-
 src/Makefile.in                           |  108 +-
 src/VERSION                               |    2 +-
 src/bitmaps2.h                            |   24 +
 src/bufrscan.c                            |    3 +-
 src/bufrstn.c                             |    3 +-
 src/config.h.in                           |    3 +
 src/dodstn.c                              |    3 +-
 src/gabufr.c                              |    3 +-
 src/gabufr.h                              |    3 +-
 src/gabufrtbl.c                           |    3 +-
 src/gacfg.c                               |   60 +-
 src/gaddes.c                              |  332 ++--
 src/gaexpr.c                              |   50 +-
 src/gafunc.c                              |   17 +-
 src/gagmap.c                              | 1308 ++++++++-----
 src/gagmap.h                              |    7 +-
 src/gagui.c                               |    1 -
 src/gagx.c                                |  420 ++--
 src/gaio.c                                |  104 +-
 src/galloc.c                              |    3 +
 src/gamach.c                              |    5 +-
 src/gasdf.c                               |    9 +-
 src/gauser.c                              |  785 ++++++--
 src/gautil.c                              |  103 +-
 src/grads.c                               |   32 +-
 src/grads.h                               |   19 +-
 src/grib2scan.c                           |   67 +-
 src/gribmap.c                             |   57 +-
 src/gribscan.c                            |   11 +-
 src/gs.h                                  |    3 +-
 src/gscrpt.c                              |    3 +-
 src/gstmp.c                               |    7 +-
 src/gx.h                                  |   99 +-
 src/gxC.c                                 | 1135 +++++++++++
 src/gxC.h                                 |   67 +
 src/gxGD.c                                |  386 ++++
 src/gxGD.h                                |   23 +
 src/gxX.c                                 | 2953 ++---------------------------
 src/{gxX.c => gxX11.c}                    |  146 +-
 src/gxchpl.c                              |  360 ++--
 src/gxcntr.c                              |  213 +--
 src/gxdxwd.c                              |    2 +
 src/gxeps.c                               | 1775 -----------------
 src/gxgif.c                               | 2683 --------------------------
 src/gxhpng.c                              |  437 -----
 src/gxmeta.c                              | 1374 +++++++++-----
 src/gxprint.c                             |  114 ++
 src/gxprintGD.c                           |   97 +
 src/gxps.c                                |  635 -------
 src/gxshad.c                              |    3 +-
 src/gxshad2.c                             |    3 +-
 src/gxstrm.c                              |    3 +-
 src/gxsubs.c                              |  296 +--
 src/gxtran.c                              |  312 ---
 src/gxwmap.c                              |   17 +-
 src/mtables.c                             |  734 -------
 src/stnmap.c                              |    7 +-
 src/wx.h                                  |    3 +-
 201 files changed, 59118 insertions(+), 14387 deletions(-)

diff --git a/COPYRIGHT b/COPYRIGHT
index 9600039..e816a72 100644
--- a/COPYRIGHT
+++ b/COPYRIGHT
@@ -1,18 +1,17 @@
     The Grid Analysis and Display System (GrADS) 
 
-    Copyright (C) 1988-2010 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+    Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
 
     The Center for Ocean-Land-Atmosphere Studies (COLA) is the center
     within IGES where GrADS is developed and maintained.
 
     The copyright holders cann be contacted at:
 
-         COLA/IGES
-         4041 Powder Mill Rd.  Suite 302
-         Calverton, MD  20705
-
-         Phone:  301 595 7000
+    Center for Ocean-Land-Atmosphere Studies (COLA)
+    George Mason University
+    280 Research Hall, Mail Stop 6C5
+    4400 University Drive
+    Fairfax, VA 22030 
 
     This program is free software; you can redistribute it and/or modify
     it under the terms of the GNU General Public License as published by
diff --git a/INSTALL b/INSTALL
index 5386187..f02d9b8 100644
--- a/INSTALL
+++ b/INSTALL
@@ -1,13 +1,11 @@
 	       GrADS - Grid Analysis and Display System
-			     Version 2.0
+			     Version 2.1
 
-                      http://grads.iges.org/grads
-
-                       GrADS Executables for UNIX
+                         http://iges.org/grads
 
 GrADS is distributed freely and is copyrighted under the GNU Public License. 
 Please read the COPYRIGHT file for more complete information. 
-For download information consult http://grads.iges.org/grads/downloads.html
+For download information consult http://iges.org/grads/downloads.html
 
 The executables contained in this tar file are typically placed in the
 directory /usr/local/bin. If you do not have write permission for your
@@ -21,19 +19,15 @@ directory.
 After unpacking the first tar file, you should have the following executables:
 
      grads            GrADS - The basic package
-     gradsdap         GrADS enabled to read data remotely via OPeNDAP
      gribmap          Creates an index file that "maps" a GRIB data set for a GrADS descriptor file
      gribscan         Extracts grid info from a GRIB data set
      grib2scan        Extracts grid info from a GRIB2 data set
      bufrscan         Reads BUFR messages and prints out ascii values 
-     gxps             Converts GrADS metafiles to Postscript
-     gxeps            Converts GrADS metafiles to Encapsulated Postscript
-     gxtran           Displays metafiles
      stnmap           Maps station data
      wgrib            See http://www.cpc.ncep.noaa.gov/products/wesley/wgrib.html
 
 A second tar file (data.tar.Z) contains the GrADS fonts and maps data sets is 
-also necessary and can be downloaded from http://grads.iges.org/grads/downloads.html.
+also necessary and can be downloaded from http://iges.org/grads/downloads.html.
 
 The contents of data.tar are typically placed in the directory
 /usr/local/lib/grads, the default location for these files. If you do not have
@@ -46,8 +40,3 @@ know where to find these files.
      tar xvf data.tar
      setenv GADDIR dirname (If dirname is not /usr/local/lib/grads)
 
-
-Documentation and Additional Information
-----------------------------------------
-
-Consult the GrADS homepage http://grads.iges.org/grads
diff --git a/Makefile.in b/Makefile.in
index f8b8618..6b788cb 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -184,6 +184,8 @@ build_alias = @build_alias@
 build_cpu = @build_cpu@
 build_os = @build_os@
 build_vendor = @build_vendor@
+cairo_inc = @cairo_inc@
+cairo_libs = @cairo_libs@
 dap_libs = @dap_libs@
 datadir = @datadir@
 exec_prefix = @exec_prefix@
@@ -504,7 +506,7 @@ distcheck: dist
 	*.zip*) \
 	  unzip $(distdir).zip ;;\
 	esac
-	chmod -R a-w $(distdir); chmod a+w $(distdir)
+	chmod -R a-w $(distdir); chmod u+w $(distdir)
 	mkdir $(distdir)/_build
 	mkdir $(distdir)/_inst
 	chmod a-w $(distdir)
diff --git a/acinclude.m4 b/acinclude.m4
index 9cfa0fb..3d07309 100644
--- a/acinclude.m4
+++ b/acinclude.m4
@@ -6,6 +6,7 @@ dnl  program. The merged "aclocal.m4" file is in turn used by the "autoconf"
 dnl  program to generate the "configure" script. 
 dnl
 
+
 dnl GA_SET_SUPPLIBS : Find a supplibs directory. 
 dnl		      If SUPPLIBS environment variable is not set, then 
 dnl  		      search for "supplibs" in the paths given in the args
@@ -73,6 +74,23 @@ AC_DEFUN([GA_UNSET_FLAGS],
   LIBS=$ga_saved_libs
 ])
 
+dnl GA_SET_CAIRO_FLAGS : Sets the compile and link paths to place where cairo is installed
+dnl 		   and saves original settings for restoration by GA_UNSET_FLAGS
+dnl  no args
+
+AC_DEFUN([GA_SET_CAIRO_FLAGS],
+[
+  # Use to make temporary changes to -I and -L paths 
+  # Just for use during tests, because configure and make may run 
+  # from different directories. 
+  ga_saved_cppflags=$CPPFLAGS
+  ga_saved_ldflags=$LDFLAGS
+  ga_saved_libs=$LIBS
+  CPPFLAGS="-I/opt/local/include/cairo"
+  LDFLAGS="-L/opt/local/lib"
+
+])
+
 dnl GA_SET_LIB_VAR : Puts necessary linker options to link with libraries given into
 dnl                  a shell variable. They will have the form 'supplib_dir/libname.a'.
 dnl   args:	   : shell-variable-name, list-of-libraries (e.g. [readline termcap])
@@ -85,6 +103,17 @@ AC_DEFUN([GA_SET_LIB_VAR],
   done  
 ])
 
+dnl GA_SET_DYNLIB_VAR : Puts necessary linker options to link dynamically with libraries given into
+dnl                  a shell variable. They will have the form '-lname'.
+dnl   args:	   : shell-variable-name, list-of-libraries (e.g. [cairo_libs cairo])
+AC_DEFUN([GA_SET_DYNLIB_VAR],
+[
+  ga_lib_prefix='-l'
+  for ga_lib_name in $2 ; do
+      $1="$$1 ${ga_lib_prefix}${ga_lib_name}"
+  done  
+])
+
 dnl GA_SET_INCLUDE_VAR : Puts necessary options to compile with include directories 
 dnl                      given into a shell variable. 
 dnl   args:	   : shell-variable-name, list-of-directories 
@@ -96,3 +125,18 @@ AC_DEFUN([GA_SET_INCLUDE_VAR],
       $1="$$1 ${ga_include_prefix}/${ga_include_name}"
   done  
 ])
+
+dnl GA_SET_CAIRO_INCLUDE : Puts necessary options to compile with cairo include directory
+dnl   no args
+AC_DEFUN([GA_SET_CAIRO_INCLUDE],
+[
+  $1="-I/opt/local/include/cairo"
+])
+
+dnl GA_SET_CAIRO_LIB : Puts necessary options to compile with cairo library 
+dnl   no args
+AC_DEFUN([GA_SET_CAIRO_LIB],
+[
+  ga_lib_prefix='$(supp_lib_dir)'
+  $1="-L${ga_lib_prefix} -lcairo "
+])
diff --git a/aclocal.m4 b/aclocal.m4
index e457d2d..b93811a 100644
--- a/aclocal.m4
+++ b/aclocal.m4
@@ -116,18 +116,6 @@ AC_CONFIG_COMMANDS_PRE(
 Usually this means the macro was only invoked conditionally.]])
 fi])])
 
-# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005
-# Free Software Foundation, Inc.
-#
-# This file is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# serial 8
-
-# AM_CONFIG_HEADER is obsolete.  It has been replaced by AC_CONFIG_HEADERS.
-AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)])
-
 # Do all the work for Automake.                             -*- Autoconf -*-
 
 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005
diff --git a/configure b/configure
index e72a4c0..a95f3dd 100755
--- a/configure
+++ b/configure
@@ -1,6 +1,6 @@
 #! /bin/sh
 # Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.59 for GrADS 2.0.2.
+# Generated by GNU Autoconf 2.59 for GrADS 2.1.a3.
 #
 # Report bugs to <jma at iges.org>.
 #
@@ -269,8 +269,8 @@ SHELL=${CONFIG_SHELL-/bin/sh}
 # Identity of this package.
 PACKAGE_NAME='GrADS'
 PACKAGE_TARNAME='grads'
-PACKAGE_VERSION='2.0.2'
-PACKAGE_STRING='GrADS 2.0.2'
+PACKAGE_VERSION='2.1.a3'
+PACKAGE_STRING='GrADS 2.1.a3'
 PACKAGE_BUGREPORT='jma at iges.org'
 
 ac_default_prefix=`pwd`
@@ -311,7 +311,7 @@ ac_includes_default="\
 # include <unistd.h>
 #endif"
 
-ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA CYGPATH_W PACKAGE VERSION ACLOCAL AUTOCONF AUTOMAKE AUTOHEADER MAKEINFO install_sh STRIP ac_ct_STRIP INS [...]
+ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA CYGPATH_W PACKAGE VERSION ACLOCAL AUTOCONF AUTOMAKE AUTOHEADER MAKEINFO install_sh STRIP ac_ct_STRIP INS [...]
 ac_subst_files=''
 
 # Initialize some variables set by options.
@@ -812,7 +812,7 @@ if test "$ac_init_help" = "long"; then
   # Omit some internal or obsolete options to make the list less imposing.
   # This message is too long to be a string in the A/UX 3.1 sh.
   cat <<_ACEOF
-\`configure' configures GrADS 2.0.2 to adapt to many kinds of systems.
+\`configure' configures GrADS 2.1.a3 to adapt to many kinds of systems.
 
 Usage: $0 [OPTION]... [VAR=VALUE]...
 
@@ -882,7 +882,7 @@ fi
 
 if test -n "$ac_init_help"; then
   case $ac_init_help in
-     short | recursive ) echo "Configuration of GrADS 2.0.2:";;
+     short | recursive ) echo "Configuration of GrADS 2.1.a3:";;
    esac
   cat <<\_ACEOF
 
@@ -904,6 +904,7 @@ Optional Packages:
   --with-gui              Athena X11 widget-based GUI
   --with-readline         command line editing
   --with-printim          image output
+  --with-cairo            cairo image rendering
   --with-grib2            GRIB2 data format
   --with-sdf              all self-describing formats
                           (HDF4,HDF5,NetCDF,OPeNDAP)
@@ -1044,7 +1045,7 @@ fi
 test -n "$ac_init_help" && exit 0
 if $ac_init_version; then
   cat <<\_ACEOF
-GrADS configure 2.0.2
+GrADS configure 2.1.a3
 generated by GNU Autoconf 2.59
 
 Copyright (C) 2003 Free Software Foundation, Inc.
@@ -1058,7 +1059,7 @@ cat >&5 <<_ACEOF
 This file contains any messages produced by compilers while
 running configure, to aid debugging if configure makes a mistake.
 
-It was created by GrADS $as_me 2.0.2, which was
+It was created by GrADS $as_me 2.1.a3, which was
 generated by GNU Autoconf 2.59.  Invocation command line was
 
   $ $0 $@
@@ -1710,7 +1711,7 @@ fi
 
 # Define the identity of the package.
  PACKAGE='grads'
- VERSION='2.0.2'
+ VERSION='2.1.a3'
 
 
 # Some tools Automake needs.
@@ -1832,6 +1833,7 @@ am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
 
 
 
+#AM_CONFIG_HEADER([src/config.h])
           ac_config_headers="$ac_config_headers src/config.h"
 
 
@@ -1889,6 +1891,12 @@ if test "${with_printim+set}" = set; then
 
 fi;
 
+# Check whether --with-cairo or --without-cairo was given.
+if test "${with_cairo+set}" = set; then
+  withval="$with_cairo"
+
+fi;
+
 # Check whether --with-grib2 or --without-grib2 was given.
 if test "${with_grib2+set}" = set; then
   withval="$with_grib2"
@@ -3232,7 +3240,7 @@ case "$host" in
 
   *darwin*)
     is_darwin="yes"
-    LDFLAGS="$LDFLAGS -lSystemStubs"
+#    LDFLAGS="$LDFLAGS -lSystemStubs"
   ;;
 
   cray-*-*)
@@ -6461,6 +6469,10 @@ _ACEOF
 fi
 
 
+
+
+
+
 # ----------------------------------------------------
 # Check for optional feature support
 # ----------------------------------------------------
@@ -6538,7 +6550,6 @@ fi
 
 
 
-
 # ----------------------------------------------------
 # Check for optional feature support
 # ----------------------------------------------------
@@ -6552,6 +6563,7 @@ use_geotiff=no
 have_zlib=no
 have_libpng=no
 have_jpeg=no
+have_xml2=no
 use_printim=no
 use_grib2=no
 have_udunits=no
@@ -6561,6 +6573,7 @@ use_nc=no
 use_nc4=no
 use_dap=no
 use_gadap=no
+use_cairo=no
 
 # look for libraries to support gui interface
 echo
@@ -11217,7 +11230,7 @@ done
   ga_saved_libs=$LIBS
   CPPFLAGS=""
 
-    for ga_inc_name in libpng12 ; do
+    for ga_inc_name in libpng15 ; do
       CPPFLAGS="$CPPFLAGS -I${ga_supplib_dir}/include/${ga_inc_name}"
     done
 
@@ -11225,13 +11238,13 @@ done
   LDFLAGS="-L${ga_supplib_dir}/lib "
   LIBS="$LIBS "
 
-    echo "$as_me:$LINENO: checking for main in -lpng12" >&5
-echo $ECHO_N "checking for main in -lpng12... $ECHO_C" >&6
-if test "${ac_cv_lib_png12_main+set}" = set; then
+    echo "$as_me:$LINENO: checking for main in -lpng15" >&5
+echo $ECHO_N "checking for main in -lpng15... $ECHO_C" >&6
+if test "${ac_cv_lib_png15_main+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   ac_check_lib_save_LIBS=$LIBS
-LIBS="-lpng12  $LIBS"
+LIBS="-lpng15  $LIBS"
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -11270,20 +11283,20 @@ if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
-  ac_cv_lib_png12_main=yes
+  ac_cv_lib_png15_main=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_lib_png12_main=no
+ac_cv_lib_png15_main=no
 fi
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 LIBS=$ac_check_lib_save_LIBS
 fi
-echo "$as_me:$LINENO: result: $ac_cv_lib_png12_main" >&5
-echo "${ECHO_T}$ac_cv_lib_png12_main" >&6
-if test $ac_cv_lib_png12_main = yes; then
+echo "$as_me:$LINENO: result: $ac_cv_lib_png15_main" >&5
+echo "${ECHO_T}$ac_cv_lib_png15_main" >&6
+if test $ac_cv_lib_png15_main = yes; then
    have_libpng=yes
 
 fi
@@ -11609,7 +11622,7 @@ if test $ac_cv_lib_gd_gdImageCreate = yes; then
 
   ga_lib_prefix='$(supp_lib_dir)/lib'
   ga_lib_suffix='.a'
-  for ga_lib_name in gd png12 z jpeg ; do
+  for ga_lib_name in gd png15 z jpeg ; do
       printim_libs="$printim_libs ${ga_lib_prefix}${ga_lib_name}${ga_lib_suffix}"
   done
 
@@ -11617,7 +11630,7 @@ if test $ac_cv_lib_gd_gdImageCreate = yes; then
 
   ga_lib_prefix='$(supp_lib_dir)/lib'
   ga_lib_suffix='.a'
-  for ga_lib_name in gd png12 z ; do
+  for ga_lib_name in gd png15 z ; do
       printim_libs="$printim_libs ${ga_lib_prefix}${ga_lib_name}${ga_lib_suffix}"
   done
 
@@ -12575,9 +12588,8 @@ cat >>confdefs.h <<\_ACEOF
 #define GXPNG 0
 _ACEOF
 
-  echo "- printim disabled (Warning: gxtran will not be built)"
+  echo "- printim disabled"
 else
-  extra_utils="$extra_utils gxtran"
 
 
 
@@ -12588,12 +12600,13 @@ _ACEOF
   echo "+ printim enabled"
 fi
 
-# look for libraries to support grib2
+# Look for libraries to support cairo graphics library
 echo
-if test "$with_grib2" != "no" ; then
+if test "$with_cairo" != "no" ; then
   # check if supplibs directory exists
   if test "Z$ga_supplib_dir" != "Z" ; then
-    echo "Checking in supplibs for libraries to support grib2 ..."
+    echo "Checking in supplibs for libraries to support cairo ..."
+    # zlib
     if test "$have_zlib" = "no" ; then
 
   # Use to make temporary changes to -I and -L paths
@@ -12838,6 +12851,7 @@ done
   LIBS=$ga_saved_libs
 
     fi
+    # libpng
     if test "$have_libpng" = "no" ; then
 
   # Use to make temporary changes to -I and -L paths
@@ -12848,7 +12862,7 @@ done
   ga_saved_libs=$LIBS
   CPPFLAGS=""
 
-    for ga_inc_name in libpng12 ; do
+    for ga_inc_name in libpng15 ; do
       CPPFLAGS="$CPPFLAGS -I${ga_supplib_dir}/include/${ga_inc_name}"
     done
 
@@ -12856,13 +12870,13 @@ done
   LDFLAGS="-L${ga_supplib_dir}/lib "
   LIBS="$LIBS "
 
-      echo "$as_me:$LINENO: checking for main in -lpng12" >&5
-echo $ECHO_N "checking for main in -lpng12... $ECHO_C" >&6
-if test "${ac_cv_lib_png12_main+set}" = set; then
+      echo "$as_me:$LINENO: checking for main in -lpng15" >&5
+echo $ECHO_N "checking for main in -lpng15... $ECHO_C" >&6
+if test "${ac_cv_lib_png15_main+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   ac_check_lib_save_LIBS=$LIBS
-LIBS="-lpng12  $LIBS"
+LIBS="-lpng15  $LIBS"
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -12901,20 +12915,20 @@ if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
-  ac_cv_lib_png12_main=yes
+  ac_cv_lib_png15_main=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_lib_png12_main=no
+ac_cv_lib_png15_main=no
 fi
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 LIBS=$ac_check_lib_save_LIBS
 fi
-echo "$as_me:$LINENO: result: $ac_cv_lib_png12_main" >&5
-echo "${ECHO_T}$ac_cv_lib_png12_main" >&6
-if test $ac_cv_lib_png12_main = yes; then
+echo "$as_me:$LINENO: result: $ac_cv_lib_png15_main" >&5
+echo "${ECHO_T}$ac_cv_lib_png15_main" >&6
+if test $ac_cv_lib_png15_main = yes; then
    have_libpng=yes
 
 fi
@@ -12926,8 +12940,8 @@ fi
   LIBS=$ga_saved_libs
 
     fi
-    if test "$have_zlib" = "yes" -a "$have_libpng" = "yes" ; then
-      have_libjasper=no
+    # libxml2
+    if test "$have_xml2" = "no" ; then
 
   # Use to make temporary changes to -I and -L paths
   # Just for use during tests, because configure and make may run
@@ -12936,18 +12950,22 @@ fi
   ga_saved_ldflags=$LDFLAGS
   ga_saved_libs=$LIBS
   CPPFLAGS=""
-  :
+
+    for ga_inc_name in libxml2 ; do
+      CPPFLAGS="$CPPFLAGS -I${ga_supplib_dir}/include/${ga_inc_name}"
+    done
+
   CPPFLAGS="$CPPFLAGS "
   LDFLAGS="-L${ga_supplib_dir}/lib "
   LIBS="$LIBS "
 
-      echo "$as_me:$LINENO: checking for main in -ljasper" >&5
-echo $ECHO_N "checking for main in -ljasper... $ECHO_C" >&6
-if test "${ac_cv_lib_jasper_main+set}" = set; then
+      echo "$as_me:$LINENO: checking for main in -lxml2" >&5
+echo $ECHO_N "checking for main in -lxml2... $ECHO_C" >&6
+if test "${ac_cv_lib_xml2_main+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   ac_check_lib_save_LIBS=$LIBS
-LIBS="-ljasper  $LIBS"
+LIBS="-lxml2  $LIBS"
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -12986,21 +13004,21 @@ if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
-  ac_cv_lib_jasper_main=yes
+  ac_cv_lib_xml2_main=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_lib_jasper_main=no
+ac_cv_lib_xml2_main=no
 fi
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 LIBS=$ac_check_lib_save_LIBS
 fi
-echo "$as_me:$LINENO: result: $ac_cv_lib_jasper_main" >&5
-echo "${ECHO_T}$ac_cv_lib_jasper_main" >&6
-if test $ac_cv_lib_jasper_main = yes; then
-   have_libjasper=yes
+echo "$as_me:$LINENO: result: $ac_cv_lib_xml2_main" >&5
+echo "${ECHO_T}$ac_cv_lib_xml2_main" >&6
+if test $ac_cv_lib_xml2_main = yes; then
+   have_xml2=yes
 
 fi
 
@@ -13010,7 +13028,12 @@ fi
   LDFLAGS=$ga_saved_ldflags
   LIBS=$ga_saved_libs
 
-      if test "$have_libjasper" = "yes" ; then
+    fi
+
+    if test "$have_xml2" = "yes"; then
+    if test "$have_zlib" = "yes" -a "$have_libpng" = "yes"; then
+      # pixman, fontconfig, freetype, Xrender, and cairo
+      # check for required header files
 
   # Use to make temporary changes to -I and -L paths
   # Just for use during tests, because configure and make may run
@@ -13020,7 +13043,7 @@ fi
   ga_saved_libs=$LIBS
   CPPFLAGS=""
 
-    for ga_inc_name in grib2c ; do
+    for ga_inc_name in cairo fontconfig freetype2 pixman-1 ; do
       CPPFLAGS="$CPPFLAGS -I${ga_supplib_dir}/include/${ga_inc_name}"
     done
 
@@ -13028,18 +13051,18 @@ fi
   LDFLAGS="-L${ga_supplib_dir}/lib "
   LIBS="$LIBS "
 
-        if test "${ac_cv_header_grib2_h+set}" = set; then
-  echo "$as_me:$LINENO: checking for grib2.h" >&5
-echo $ECHO_N "checking for grib2.h... $ECHO_C" >&6
-if test "${ac_cv_header_grib2_h+set}" = set; then
+      if test "${ac_cv_header_cairo_h+set}" = set; then
+  echo "$as_me:$LINENO: checking for cairo.h" >&5
+echo $ECHO_N "checking for cairo.h... $ECHO_C" >&6
+if test "${ac_cv_header_cairo_h+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 fi
-echo "$as_me:$LINENO: result: $ac_cv_header_grib2_h" >&5
-echo "${ECHO_T}$ac_cv_header_grib2_h" >&6
+echo "$as_me:$LINENO: result: $ac_cv_header_cairo_h" >&5
+echo "${ECHO_T}$ac_cv_header_cairo_h" >&6
 else
   # Is the header compilable?
-echo "$as_me:$LINENO: checking grib2.h usability" >&5
-echo $ECHO_N "checking grib2.h usability... $ECHO_C" >&6
+echo "$as_me:$LINENO: checking cairo.h usability" >&5
+echo $ECHO_N "checking cairo.h usability... $ECHO_C" >&6
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -13047,7 +13070,7 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-#include <grib2.h>
+#include <cairo.h>
 _ACEOF
 rm -f conftest.$ac_objext
 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
@@ -13083,15 +13106,15 @@ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
 echo "${ECHO_T}$ac_header_compiler" >&6
 
 # Is the header present?
-echo "$as_me:$LINENO: checking grib2.h presence" >&5
-echo $ECHO_N "checking grib2.h presence... $ECHO_C" >&6
+echo "$as_me:$LINENO: checking cairo.h presence" >&5
+echo $ECHO_N "checking cairo.h presence... $ECHO_C" >&6
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-#include <grib2.h>
+#include <cairo.h>
 _ACEOF
 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
@@ -13125,25 +13148,25 @@ echo "${ECHO_T}$ac_header_preproc" >&6
 # So?  What about this header?
 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
   yes:no: )
-    { echo "$as_me:$LINENO: WARNING: grib2.h: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: grib2.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: grib2.h: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: grib2.h: proceeding with the compiler's result" >&2;}
+    { echo "$as_me:$LINENO: WARNING: cairo.h: accepted by the compiler, rejected by the preprocessor!" >&5
+echo "$as_me: WARNING: cairo.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
+    { echo "$as_me:$LINENO: WARNING: cairo.h: proceeding with the compiler's result" >&5
+echo "$as_me: WARNING: cairo.h: proceeding with the compiler's result" >&2;}
     ac_header_preproc=yes
     ;;
   no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: grib2.h: present but cannot be compiled" >&5
-echo "$as_me: WARNING: grib2.h: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: grib2.h:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: grib2.h:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: grib2.h: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: grib2.h: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: grib2.h:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: grib2.h:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: grib2.h: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: grib2.h: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: grib2.h: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: grib2.h: in the future, the compiler will take precedence" >&2;}
+    { echo "$as_me:$LINENO: WARNING: cairo.h: present but cannot be compiled" >&5
+echo "$as_me: WARNING: cairo.h: present but cannot be compiled" >&2;}
+    { echo "$as_me:$LINENO: WARNING: cairo.h:     check for missing prerequisite headers?" >&5
+echo "$as_me: WARNING: cairo.h:     check for missing prerequisite headers?" >&2;}
+    { echo "$as_me:$LINENO: WARNING: cairo.h: see the Autoconf documentation" >&5
+echo "$as_me: WARNING: cairo.h: see the Autoconf documentation" >&2;}
+    { echo "$as_me:$LINENO: WARNING: cairo.h:     section \"Present But Cannot Be Compiled\"" >&5
+echo "$as_me: WARNING: cairo.h:     section \"Present But Cannot Be Compiled\"" >&2;}
+    { echo "$as_me:$LINENO: WARNING: cairo.h: proceeding with the preprocessor's result" >&5
+echo "$as_me: WARNING: cairo.h: proceeding with the preprocessor's result" >&2;}
+    { echo "$as_me:$LINENO: WARNING: cairo.h: in the future, the compiler will take precedence" >&5
+echo "$as_me: WARNING: cairo.h: in the future, the compiler will take precedence" >&2;}
     (
       cat <<\_ASBOX
 ## --------------------------- ##
@@ -13154,44 +13177,42 @@ _ASBOX
       sed "s/^/$as_me: WARNING:     /" >&2
     ;;
 esac
-echo "$as_me:$LINENO: checking for grib2.h" >&5
-echo $ECHO_N "checking for grib2.h... $ECHO_C" >&6
-if test "${ac_cv_header_grib2_h+set}" = set; then
+echo "$as_me:$LINENO: checking for cairo.h" >&5
+echo $ECHO_N "checking for cairo.h... $ECHO_C" >&6
+if test "${ac_cv_header_cairo_h+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_cv_header_grib2_h=$ac_header_preproc
+  ac_cv_header_cairo_h=$ac_header_preproc
 fi
-echo "$as_me:$LINENO: result: $ac_cv_header_grib2_h" >&5
-echo "${ECHO_T}$ac_cv_header_grib2_h" >&6
+echo "$as_me:$LINENO: result: $ac_cv_header_cairo_h" >&5
+echo "${ECHO_T}$ac_cv_header_cairo_h" >&6
 
 fi
-if test $ac_cv_header_grib2_h = yes; then
-   echo "$as_me:$LINENO: checking for main in -lgrib2c" >&5
-echo $ECHO_N "checking for main in -lgrib2c... $ECHO_C" >&6
-if test "${ac_cv_lib_grib2c_main+set}" = set; then
+if test $ac_cv_header_cairo_h = yes; then
+   if test "${ac_cv_header_cairo_xlib_h+set}" = set; then
+  echo "$as_me:$LINENO: checking for cairo-xlib.h" >&5
+echo $ECHO_N "checking for cairo-xlib.h... $ECHO_C" >&6
+if test "${ac_cv_header_cairo_xlib_h+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
+fi
+echo "$as_me:$LINENO: result: $ac_cv_header_cairo_xlib_h" >&5
+echo "${ECHO_T}$ac_cv_header_cairo_xlib_h" >&6
 else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lgrib2c  $LIBS"
+  # Is the header compilable?
+echo "$as_me:$LINENO: checking cairo-xlib.h usability" >&5
+echo $ECHO_N "checking cairo-xlib.h usability... $ECHO_C" >&6
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-
-
-int
-main ()
-{
-main ();
-  ;
-  return 0;
-}
+$ac_includes_default
+#include <cairo-xlib.h>
 _ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+  (eval $ac_compile) 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
@@ -13205,75 +13226,119 @@ if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; } &&
-	 { ac_try='test -s conftest$ac_exeext'
+	 { ac_try='test -s conftest.$ac_objext'
   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
   (eval $ac_try) 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
-  ac_cv_lib_grib2c_main=yes
+  ac_header_compiler=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_lib_grib2c_main=no
-fi
-rm -f conftest.err conftest.$ac_objext \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+ac_header_compiler=no
 fi
-echo "$as_me:$LINENO: result: $ac_cv_lib_grib2c_main" >&5
-echo "${ECHO_T}$ac_cv_lib_grib2c_main" >&6
-if test $ac_cv_lib_grib2c_main = yes; then
-   use_grib2=yes
-
-  ga_include_prefix='-I$(supp_include_dir)'
-
-  for ga_include_name in grib2c ; do
-      grib2_inc="$grib2_inc ${ga_include_prefix}/${ga_include_name}"
-  done
-
-
-  ga_lib_prefix='$(supp_lib_dir)/lib'
-  ga_lib_suffix='.a'
-  for ga_lib_name in grib2c jasper png12 z ; do
-      grib2_libs="$grib2_libs ${ga_lib_prefix}${ga_lib_name}${ga_lib_suffix}"
-  done
-
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
+echo "${ECHO_T}$ac_header_compiler" >&6
 
+# Is the header present?
+echo "$as_me:$LINENO: checking cairo-xlib.h presence" >&5
+echo $ECHO_N "checking cairo-xlib.h presence... $ECHO_C" >&6
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+#include <cairo-xlib.h>
+_ACEOF
+if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
+  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } >/dev/null; then
+  if test -s conftest.err; then
+    ac_cpp_err=$ac_c_preproc_warn_flag
+    ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
+  else
+    ac_cpp_err=
+  fi
+else
+  ac_cpp_err=yes
 fi
+if test -z "$ac_cpp_err"; then
+  ac_header_preproc=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
 
-
+  ac_header_preproc=no
 fi
+rm -f conftest.err conftest.$ac_ext
+echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
+echo "${ECHO_T}$ac_header_preproc" >&6
 
+# So?  What about this header?
+case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
+  yes:no: )
+    { echo "$as_me:$LINENO: WARNING: cairo-xlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
+echo "$as_me: WARNING: cairo-xlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
+    { echo "$as_me:$LINENO: WARNING: cairo-xlib.h: proceeding with the compiler's result" >&5
+echo "$as_me: WARNING: cairo-xlib.h: proceeding with the compiler's result" >&2;}
+    ac_header_preproc=yes
+    ;;
+  no:yes:* )
+    { echo "$as_me:$LINENO: WARNING: cairo-xlib.h: present but cannot be compiled" >&5
+echo "$as_me: WARNING: cairo-xlib.h: present but cannot be compiled" >&2;}
+    { echo "$as_me:$LINENO: WARNING: cairo-xlib.h:     check for missing prerequisite headers?" >&5
+echo "$as_me: WARNING: cairo-xlib.h:     check for missing prerequisite headers?" >&2;}
+    { echo "$as_me:$LINENO: WARNING: cairo-xlib.h: see the Autoconf documentation" >&5
+echo "$as_me: WARNING: cairo-xlib.h: see the Autoconf documentation" >&2;}
+    { echo "$as_me:$LINENO: WARNING: cairo-xlib.h:     section \"Present But Cannot Be Compiled\"" >&5
+echo "$as_me: WARNING: cairo-xlib.h:     section \"Present But Cannot Be Compiled\"" >&2;}
+    { echo "$as_me:$LINENO: WARNING: cairo-xlib.h: proceeding with the preprocessor's result" >&5
+echo "$as_me: WARNING: cairo-xlib.h: proceeding with the preprocessor's result" >&2;}
+    { echo "$as_me:$LINENO: WARNING: cairo-xlib.h: in the future, the compiler will take precedence" >&5
+echo "$as_me: WARNING: cairo-xlib.h: in the future, the compiler will take precedence" >&2;}
+    (
+      cat <<\_ASBOX
+## --------------------------- ##
+## Report this to jma at iges.org ##
+## --------------------------- ##
+_ASBOX
+    ) |
+      sed "s/^/$as_me: WARNING:     /" >&2
+    ;;
+esac
+echo "$as_me:$LINENO: checking for cairo-xlib.h" >&5
+echo $ECHO_N "checking for cairo-xlib.h... $ECHO_C" >&6
+if test "${ac_cv_header_cairo_xlib_h+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_cv_header_cairo_xlib_h=$ac_header_preproc
+fi
+echo "$as_me:$LINENO: result: $ac_cv_header_cairo_xlib_h" >&5
+echo "${ECHO_T}$ac_cv_header_cairo_xlib_h" >&6
 
-
-  # Use to undo temporary changes to -I and -L paths
-  CPPFLAGS=$ga_saved_cppflags
-  LDFLAGS=$ga_saved_ldflags
-  LIBS=$ga_saved_libs
-
-      fi
-    fi
-  fi
-    # if we haven't got what we need, look outside supplibs for grib2
-  if test "$use_grib2" != "yes" -a "$ga_dyn_supplibs" = "yes" ; then
-    echo
-    echo "Checking in system locations for grib2 libraries ..."
-
-  ga_check_grib2="no"
-  if test "${ac_cv_header_grib2_h+set}" = set; then
-  echo "$as_me:$LINENO: checking for grib2.h" >&5
-echo $ECHO_N "checking for grib2.h... $ECHO_C" >&6
-if test "${ac_cv_header_grib2_h+set}" = set; then
+fi
+if test $ac_cv_header_cairo_xlib_h = yes; then
+   if test "${ac_cv_header_fontconfig_h+set}" = set; then
+  echo "$as_me:$LINENO: checking for fontconfig.h" >&5
+echo $ECHO_N "checking for fontconfig.h... $ECHO_C" >&6
+if test "${ac_cv_header_fontconfig_h+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 fi
-echo "$as_me:$LINENO: result: $ac_cv_header_grib2_h" >&5
-echo "${ECHO_T}$ac_cv_header_grib2_h" >&6
+echo "$as_me:$LINENO: result: $ac_cv_header_fontconfig_h" >&5
+echo "${ECHO_T}$ac_cv_header_fontconfig_h" >&6
 else
   # Is the header compilable?
-echo "$as_me:$LINENO: checking grib2.h usability" >&5
-echo $ECHO_N "checking grib2.h usability... $ECHO_C" >&6
+echo "$as_me:$LINENO: checking fontconfig.h usability" >&5
+echo $ECHO_N "checking fontconfig.h usability... $ECHO_C" >&6
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -13281,7 +13346,7 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-#include <grib2.h>
+#include <fontconfig.h>
 _ACEOF
 rm -f conftest.$ac_objext
 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
@@ -13317,15 +13382,15 @@ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
 echo "${ECHO_T}$ac_header_compiler" >&6
 
 # Is the header present?
-echo "$as_me:$LINENO: checking grib2.h presence" >&5
-echo $ECHO_N "checking grib2.h presence... $ECHO_C" >&6
+echo "$as_me:$LINENO: checking fontconfig.h presence" >&5
+echo $ECHO_N "checking fontconfig.h presence... $ECHO_C" >&6
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-#include <grib2.h>
+#include <fontconfig.h>
 _ACEOF
 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
@@ -13359,25 +13424,25 @@ echo "${ECHO_T}$ac_header_preproc" >&6
 # So?  What about this header?
 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
   yes:no: )
-    { echo "$as_me:$LINENO: WARNING: grib2.h: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: grib2.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: grib2.h: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: grib2.h: proceeding with the compiler's result" >&2;}
+    { echo "$as_me:$LINENO: WARNING: fontconfig.h: accepted by the compiler, rejected by the preprocessor!" >&5
+echo "$as_me: WARNING: fontconfig.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
+    { echo "$as_me:$LINENO: WARNING: fontconfig.h: proceeding with the compiler's result" >&5
+echo "$as_me: WARNING: fontconfig.h: proceeding with the compiler's result" >&2;}
     ac_header_preproc=yes
     ;;
   no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: grib2.h: present but cannot be compiled" >&5
-echo "$as_me: WARNING: grib2.h: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: grib2.h:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: grib2.h:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: grib2.h: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: grib2.h: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: grib2.h:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: grib2.h:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: grib2.h: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: grib2.h: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: grib2.h: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: grib2.h: in the future, the compiler will take precedence" >&2;}
+    { echo "$as_me:$LINENO: WARNING: fontconfig.h: present but cannot be compiled" >&5
+echo "$as_me: WARNING: fontconfig.h: present but cannot be compiled" >&2;}
+    { echo "$as_me:$LINENO: WARNING: fontconfig.h:     check for missing prerequisite headers?" >&5
+echo "$as_me: WARNING: fontconfig.h:     check for missing prerequisite headers?" >&2;}
+    { echo "$as_me:$LINENO: WARNING: fontconfig.h: see the Autoconf documentation" >&5
+echo "$as_me: WARNING: fontconfig.h: see the Autoconf documentation" >&2;}
+    { echo "$as_me:$LINENO: WARNING: fontconfig.h:     section \"Present But Cannot Be Compiled\"" >&5
+echo "$as_me: WARNING: fontconfig.h:     section \"Present But Cannot Be Compiled\"" >&2;}
+    { echo "$as_me:$LINENO: WARNING: fontconfig.h: proceeding with the preprocessor's result" >&5
+echo "$as_me: WARNING: fontconfig.h: proceeding with the preprocessor's result" >&2;}
+    { echo "$as_me:$LINENO: WARNING: fontconfig.h: in the future, the compiler will take precedence" >&5
+echo "$as_me: WARNING: fontconfig.h: in the future, the compiler will take precedence" >&2;}
     (
       cat <<\_ASBOX
 ## --------------------------- ##
@@ -13388,32 +13453,1494 @@ _ASBOX
       sed "s/^/$as_me: WARNING:     /" >&2
     ;;
 esac
-echo "$as_me:$LINENO: checking for grib2.h" >&5
-echo $ECHO_N "checking for grib2.h... $ECHO_C" >&6
-if test "${ac_cv_header_grib2_h+set}" = set; then
+echo "$as_me:$LINENO: checking for fontconfig.h" >&5
+echo $ECHO_N "checking for fontconfig.h... $ECHO_C" >&6
+if test "${ac_cv_header_fontconfig_h+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_cv_header_grib2_h=$ac_header_preproc
+  ac_cv_header_fontconfig_h=$ac_header_preproc
 fi
-echo "$as_me:$LINENO: result: $ac_cv_header_grib2_h" >&5
-echo "${ECHO_T}$ac_cv_header_grib2_h" >&6
+echo "$as_me:$LINENO: result: $ac_cv_header_fontconfig_h" >&5
+echo "${ECHO_T}$ac_cv_header_fontconfig_h" >&6
 
 fi
-if test $ac_cv_header_grib2_h = yes; then
-   echo "$as_me:$LINENO: checking for main in -lgrib2c" >&5
-echo $ECHO_N "checking for main in -lgrib2c... $ECHO_C" >&6
-if test "${ac_cv_lib_grib2c_main+set}" = set; then
+if test $ac_cv_header_fontconfig_h = yes; then
+   if test "${ac_cv_header_ft2build_h+set}" = set; then
+  echo "$as_me:$LINENO: checking for ft2build.h" >&5
+echo $ECHO_N "checking for ft2build.h... $ECHO_C" >&6
+if test "${ac_cv_header_ft2build_h+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
+fi
+echo "$as_me:$LINENO: result: $ac_cv_header_ft2build_h" >&5
+echo "${ECHO_T}$ac_cv_header_ft2build_h" >&6
 else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lgrib2c  $LIBS"
+  # Is the header compilable?
+echo "$as_me:$LINENO: checking ft2build.h usability" >&5
+echo $ECHO_N "checking ft2build.h usability... $ECHO_C" >&6
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-
+$ac_includes_default
+#include <ft2build.h>
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+  (eval $ac_compile) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+	 { ac_try='test -z "$ac_c_werror_flag"
+			 || test ! -s conftest.err'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; } &&
+	 { ac_try='test -s conftest.$ac_objext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  ac_header_compiler=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_header_compiler=no
+fi
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
+echo "${ECHO_T}$ac_header_compiler" >&6
+
+# Is the header present?
+echo "$as_me:$LINENO: checking ft2build.h presence" >&5
+echo $ECHO_N "checking ft2build.h presence... $ECHO_C" >&6
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+#include <ft2build.h>
+_ACEOF
+if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
+  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } >/dev/null; then
+  if test -s conftest.err; then
+    ac_cpp_err=$ac_c_preproc_warn_flag
+    ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
+  else
+    ac_cpp_err=
+  fi
+else
+  ac_cpp_err=yes
+fi
+if test -z "$ac_cpp_err"; then
+  ac_header_preproc=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+  ac_header_preproc=no
+fi
+rm -f conftest.err conftest.$ac_ext
+echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
+echo "${ECHO_T}$ac_header_preproc" >&6
+
+# So?  What about this header?
+case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
+  yes:no: )
+    { echo "$as_me:$LINENO: WARNING: ft2build.h: accepted by the compiler, rejected by the preprocessor!" >&5
+echo "$as_me: WARNING: ft2build.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
+    { echo "$as_me:$LINENO: WARNING: ft2build.h: proceeding with the compiler's result" >&5
+echo "$as_me: WARNING: ft2build.h: proceeding with the compiler's result" >&2;}
+    ac_header_preproc=yes
+    ;;
+  no:yes:* )
+    { echo "$as_me:$LINENO: WARNING: ft2build.h: present but cannot be compiled" >&5
+echo "$as_me: WARNING: ft2build.h: present but cannot be compiled" >&2;}
+    { echo "$as_me:$LINENO: WARNING: ft2build.h:     check for missing prerequisite headers?" >&5
+echo "$as_me: WARNING: ft2build.h:     check for missing prerequisite headers?" >&2;}
+    { echo "$as_me:$LINENO: WARNING: ft2build.h: see the Autoconf documentation" >&5
+echo "$as_me: WARNING: ft2build.h: see the Autoconf documentation" >&2;}
+    { echo "$as_me:$LINENO: WARNING: ft2build.h:     section \"Present But Cannot Be Compiled\"" >&5
+echo "$as_me: WARNING: ft2build.h:     section \"Present But Cannot Be Compiled\"" >&2;}
+    { echo "$as_me:$LINENO: WARNING: ft2build.h: proceeding with the preprocessor's result" >&5
+echo "$as_me: WARNING: ft2build.h: proceeding with the preprocessor's result" >&2;}
+    { echo "$as_me:$LINENO: WARNING: ft2build.h: in the future, the compiler will take precedence" >&5
+echo "$as_me: WARNING: ft2build.h: in the future, the compiler will take precedence" >&2;}
+    (
+      cat <<\_ASBOX
+## --------------------------- ##
+## Report this to jma at iges.org ##
+## --------------------------- ##
+_ASBOX
+    ) |
+      sed "s/^/$as_me: WARNING:     /" >&2
+    ;;
+esac
+echo "$as_me:$LINENO: checking for ft2build.h" >&5
+echo $ECHO_N "checking for ft2build.h... $ECHO_C" >&6
+if test "${ac_cv_header_ft2build_h+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_cv_header_ft2build_h=$ac_header_preproc
+fi
+echo "$as_me:$LINENO: result: $ac_cv_header_ft2build_h" >&5
+echo "${ECHO_T}$ac_cv_header_ft2build_h" >&6
+
+fi
+if test $ac_cv_header_ft2build_h = yes; then
+   if test "${ac_cv_header_pixman_h+set}" = set; then
+  echo "$as_me:$LINENO: checking for pixman.h" >&5
+echo $ECHO_N "checking for pixman.h... $ECHO_C" >&6
+if test "${ac_cv_header_pixman_h+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+fi
+echo "$as_me:$LINENO: result: $ac_cv_header_pixman_h" >&5
+echo "${ECHO_T}$ac_cv_header_pixman_h" >&6
+else
+  # Is the header compilable?
+echo "$as_me:$LINENO: checking pixman.h usability" >&5
+echo $ECHO_N "checking pixman.h usability... $ECHO_C" >&6
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+$ac_includes_default
+#include <pixman.h>
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+  (eval $ac_compile) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+	 { ac_try='test -z "$ac_c_werror_flag"
+			 || test ! -s conftest.err'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; } &&
+	 { ac_try='test -s conftest.$ac_objext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  ac_header_compiler=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_header_compiler=no
+fi
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
+echo "${ECHO_T}$ac_header_compiler" >&6
+
+# Is the header present?
+echo "$as_me:$LINENO: checking pixman.h presence" >&5
+echo $ECHO_N "checking pixman.h presence... $ECHO_C" >&6
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+#include <pixman.h>
+_ACEOF
+if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
+  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } >/dev/null; then
+  if test -s conftest.err; then
+    ac_cpp_err=$ac_c_preproc_warn_flag
+    ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
+  else
+    ac_cpp_err=
+  fi
+else
+  ac_cpp_err=yes
+fi
+if test -z "$ac_cpp_err"; then
+  ac_header_preproc=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+  ac_header_preproc=no
+fi
+rm -f conftest.err conftest.$ac_ext
+echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
+echo "${ECHO_T}$ac_header_preproc" >&6
+
+# So?  What about this header?
+case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
+  yes:no: )
+    { echo "$as_me:$LINENO: WARNING: pixman.h: accepted by the compiler, rejected by the preprocessor!" >&5
+echo "$as_me: WARNING: pixman.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
+    { echo "$as_me:$LINENO: WARNING: pixman.h: proceeding with the compiler's result" >&5
+echo "$as_me: WARNING: pixman.h: proceeding with the compiler's result" >&2;}
+    ac_header_preproc=yes
+    ;;
+  no:yes:* )
+    { echo "$as_me:$LINENO: WARNING: pixman.h: present but cannot be compiled" >&5
+echo "$as_me: WARNING: pixman.h: present but cannot be compiled" >&2;}
+    { echo "$as_me:$LINENO: WARNING: pixman.h:     check for missing prerequisite headers?" >&5
+echo "$as_me: WARNING: pixman.h:     check for missing prerequisite headers?" >&2;}
+    { echo "$as_me:$LINENO: WARNING: pixman.h: see the Autoconf documentation" >&5
+echo "$as_me: WARNING: pixman.h: see the Autoconf documentation" >&2;}
+    { echo "$as_me:$LINENO: WARNING: pixman.h:     section \"Present But Cannot Be Compiled\"" >&5
+echo "$as_me: WARNING: pixman.h:     section \"Present But Cannot Be Compiled\"" >&2;}
+    { echo "$as_me:$LINENO: WARNING: pixman.h: proceeding with the preprocessor's result" >&5
+echo "$as_me: WARNING: pixman.h: proceeding with the preprocessor's result" >&2;}
+    { echo "$as_me:$LINENO: WARNING: pixman.h: in the future, the compiler will take precedence" >&5
+echo "$as_me: WARNING: pixman.h: in the future, the compiler will take precedence" >&2;}
+    (
+      cat <<\_ASBOX
+## --------------------------- ##
+## Report this to jma at iges.org ##
+## --------------------------- ##
+_ASBOX
+    ) |
+      sed "s/^/$as_me: WARNING:     /" >&2
+    ;;
+esac
+echo "$as_me:$LINENO: checking for pixman.h" >&5
+echo $ECHO_N "checking for pixman.h... $ECHO_C" >&6
+if test "${ac_cv_header_pixman_h+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_cv_header_pixman_h=$ac_header_preproc
+fi
+echo "$as_me:$LINENO: result: $ac_cv_header_pixman_h" >&5
+echo "${ECHO_T}$ac_cv_header_pixman_h" >&6
+
+fi
+if test $ac_cv_header_pixman_h = yes; then
+   echo "$as_me:$LINENO: checking for main in -lpixman-1" >&5
+echo $ECHO_N "checking for main in -lpixman-1... $ECHO_C" >&6
+if test "${ac_cv_lib_pixman_1_main+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_check_lib_save_LIBS=$LIBS
+LIBS="-lpixman-1  $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+
+
+int
+main ()
+{
+main ();
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+  (eval $ac_link) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+	 { ac_try='test -z "$ac_c_werror_flag"
+			 || test ! -s conftest.err'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; } &&
+	 { ac_try='test -s conftest$ac_exeext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  ac_cv_lib_pixman_1_main=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_cv_lib_pixman_1_main=no
+fi
+rm -f conftest.err conftest.$ac_objext \
+      conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:$LINENO: result: $ac_cv_lib_pixman_1_main" >&5
+echo "${ECHO_T}$ac_cv_lib_pixman_1_main" >&6
+if test $ac_cv_lib_pixman_1_main = yes; then
+   echo "$as_me:$LINENO: checking for main in -lfontconfig" >&5
+echo $ECHO_N "checking for main in -lfontconfig... $ECHO_C" >&6
+if test "${ac_cv_lib_fontconfig_main+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_check_lib_save_LIBS=$LIBS
+LIBS="-lfontconfig  $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+
+
+int
+main ()
+{
+main ();
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+  (eval $ac_link) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+	 { ac_try='test -z "$ac_c_werror_flag"
+			 || test ! -s conftest.err'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; } &&
+	 { ac_try='test -s conftest$ac_exeext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  ac_cv_lib_fontconfig_main=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_cv_lib_fontconfig_main=no
+fi
+rm -f conftest.err conftest.$ac_objext \
+      conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:$LINENO: result: $ac_cv_lib_fontconfig_main" >&5
+echo "${ECHO_T}$ac_cv_lib_fontconfig_main" >&6
+if test $ac_cv_lib_fontconfig_main = yes; then
+   echo "$as_me:$LINENO: checking for main in -lfreetype" >&5
+echo $ECHO_N "checking for main in -lfreetype... $ECHO_C" >&6
+if test "${ac_cv_lib_freetype_main+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_check_lib_save_LIBS=$LIBS
+LIBS="-lfreetype  $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+
+
+int
+main ()
+{
+main ();
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+  (eval $ac_link) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+	 { ac_try='test -z "$ac_c_werror_flag"
+			 || test ! -s conftest.err'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; } &&
+	 { ac_try='test -s conftest$ac_exeext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  ac_cv_lib_freetype_main=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_cv_lib_freetype_main=no
+fi
+rm -f conftest.err conftest.$ac_objext \
+      conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:$LINENO: result: $ac_cv_lib_freetype_main" >&5
+echo "${ECHO_T}$ac_cv_lib_freetype_main" >&6
+if test $ac_cv_lib_freetype_main = yes; then
+   echo "$as_me:$LINENO: checking for main in -lXrender" >&5
+echo $ECHO_N "checking for main in -lXrender... $ECHO_C" >&6
+if test "${ac_cv_lib_Xrender_main+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_check_lib_save_LIBS=$LIBS
+LIBS="-lXrender  $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+
+
+int
+main ()
+{
+main ();
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+  (eval $ac_link) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+	 { ac_try='test -z "$ac_c_werror_flag"
+			 || test ! -s conftest.err'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; } &&
+	 { ac_try='test -s conftest$ac_exeext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  ac_cv_lib_Xrender_main=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_cv_lib_Xrender_main=no
+fi
+rm -f conftest.err conftest.$ac_objext \
+      conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:$LINENO: result: $ac_cv_lib_Xrender_main" >&5
+echo "${ECHO_T}$ac_cv_lib_Xrender_main" >&6
+if test $ac_cv_lib_Xrender_main = yes; then
+   echo "$as_me:$LINENO: checking for main in -lcairo" >&5
+echo $ECHO_N "checking for main in -lcairo... $ECHO_C" >&6
+if test "${ac_cv_lib_cairo_main+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_check_lib_save_LIBS=$LIBS
+LIBS="-lcairo  $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+
+
+int
+main ()
+{
+main ();
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+  (eval $ac_link) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+	 { ac_try='test -z "$ac_c_werror_flag"
+			 || test ! -s conftest.err'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; } &&
+	 { ac_try='test -s conftest$ac_exeext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  ac_cv_lib_cairo_main=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_cv_lib_cairo_main=no
+fi
+rm -f conftest.err conftest.$ac_objext \
+      conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:$LINENO: result: $ac_cv_lib_cairo_main" >&5
+echo "${ECHO_T}$ac_cv_lib_cairo_main" >&6
+if test $ac_cv_lib_cairo_main = yes; then
+   use_cairo="yes"
+
+  ga_include_prefix='-I$(supp_include_dir)'
+
+  for ga_include_name in cairo freetype2 fontconfig libpng15 pixman-1 ; do
+      cairo_inc="$cairo_inc ${ga_include_prefix}/${ga_include_name}"
+  done
+
+
+  ga_lib_prefix='$(supp_lib_dir)/lib'
+  ga_lib_suffix='.a'
+  for ga_lib_name in cairo Xrender fontconfig freetype pixman-1 png15 xml2 z ; do
+      cairo_libs="$cairo_libs ${ga_lib_prefix}${ga_lib_name}${ga_lib_suffix}"
+  done
+
+
+fi
+
+
+fi
+
+
+fi
+
+
+fi
+
+
+fi
+
+
+fi
+
+
+
+fi
+
+
+
+fi
+
+
+
+fi
+
+
+
+fi
+
+
+
+  # Use to undo temporary changes to -I and -L paths
+  CPPFLAGS=$ga_saved_cppflags
+  LDFLAGS=$ga_saved_ldflags
+  LIBS=$ga_saved_libs
+
+    fi
+    fi
+  fi
+fi
+if test "$use_cairo" != "yes" ; then
+
+cat >>confdefs.h <<\_ACEOF
+#define USECAIRO 0
+_ACEOF
+
+  echo "- cairo disabled"
+else
+
+
+
+cat >>confdefs.h <<\_ACEOF
+#define USECAIRO 1
+_ACEOF
+
+  echo "+ cairo enabled"
+fi
+
+
+# look for libraries to support grib2
+echo
+if test "$with_grib2" != "no" ; then
+  # check if supplibs directory exists
+  if test "Z$ga_supplib_dir" != "Z" ; then
+    echo "Checking in supplibs for libraries to support grib2 ..."
+    if test "$have_zlib" = "no" ; then
+
+  # Use to make temporary changes to -I and -L paths
+  # Just for use during tests, because configure and make may run
+  # from different directories.
+  ga_saved_cppflags=$CPPFLAGS
+  ga_saved_ldflags=$LDFLAGS
+  ga_saved_libs=$LIBS
+  CPPFLAGS=""
+
+    for ga_inc_name in zlib ; do
+      CPPFLAGS="$CPPFLAGS -I${ga_supplib_dir}/include/${ga_inc_name}"
+    done
+
+  CPPFLAGS="$CPPFLAGS "
+  LDFLAGS="-L${ga_supplib_dir}/lib "
+  LIBS="$LIBS "
+
+
+for ac_header in zlib.h
+do
+as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
+  echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
+else
+  # Is the header compilable?
+echo "$as_me:$LINENO: checking $ac_header usability" >&5
+echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+$ac_includes_default
+#include <$ac_header>
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+  (eval $ac_compile) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+	 { ac_try='test -z "$ac_c_werror_flag"
+			 || test ! -s conftest.err'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; } &&
+	 { ac_try='test -s conftest.$ac_objext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  ac_header_compiler=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_header_compiler=no
+fi
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
+echo "${ECHO_T}$ac_header_compiler" >&6
+
+# Is the header present?
+echo "$as_me:$LINENO: checking $ac_header presence" >&5
+echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+#include <$ac_header>
+_ACEOF
+if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
+  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } >/dev/null; then
+  if test -s conftest.err; then
+    ac_cpp_err=$ac_c_preproc_warn_flag
+    ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
+  else
+    ac_cpp_err=
+  fi
+else
+  ac_cpp_err=yes
+fi
+if test -z "$ac_cpp_err"; then
+  ac_header_preproc=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+  ac_header_preproc=no
+fi
+rm -f conftest.err conftest.$ac_ext
+echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
+echo "${ECHO_T}$ac_header_preproc" >&6
+
+# So?  What about this header?
+case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
+  yes:no: )
+    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
+echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
+echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
+    ac_header_preproc=yes
+    ;;
+  no:yes:* )
+    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
+echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
+echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
+echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
+echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
+echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
+echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
+    (
+      cat <<\_ASBOX
+## --------------------------- ##
+## Report this to jma at iges.org ##
+## --------------------------- ##
+_ASBOX
+    ) |
+      sed "s/^/$as_me: WARNING:     /" >&2
+    ;;
+esac
+echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  eval "$as_ac_Header=\$ac_header_preproc"
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
+
+fi
+if test `eval echo '${'$as_ac_Header'}'` = yes; then
+  cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
+_ACEOF
+  echo "$as_me:$LINENO: checking for compress in -lz" >&5
+echo $ECHO_N "checking for compress in -lz... $ECHO_C" >&6
+if test "${ac_cv_lib_z_compress+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_check_lib_save_LIBS=$LIBS
+LIBS="-lz  $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+
+/* Override any gcc2 internal prototype to avoid an error.  */
+#ifdef __cplusplus
+extern "C"
+#endif
+/* We use char because int might match the return type of a gcc2
+   builtin and then its argument prototype would still apply.  */
+char compress ();
+int
+main ()
+{
+compress ();
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+  (eval $ac_link) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+	 { ac_try='test -z "$ac_c_werror_flag"
+			 || test ! -s conftest.err'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; } &&
+	 { ac_try='test -s conftest$ac_exeext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  ac_cv_lib_z_compress=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_cv_lib_z_compress=no
+fi
+rm -f conftest.err conftest.$ac_objext \
+      conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:$LINENO: result: $ac_cv_lib_z_compress" >&5
+echo "${ECHO_T}$ac_cv_lib_z_compress" >&6
+if test $ac_cv_lib_z_compress = yes; then
+   have_zlib=yes
+
+fi
+
+
+fi
+
+done
+
+
+  # Use to undo temporary changes to -I and -L paths
+  CPPFLAGS=$ga_saved_cppflags
+  LDFLAGS=$ga_saved_ldflags
+  LIBS=$ga_saved_libs
+
+    fi
+    if test "$have_libpng" = "no" ; then
+
+  # Use to make temporary changes to -I and -L paths
+  # Just for use during tests, because configure and make may run
+  # from different directories.
+  ga_saved_cppflags=$CPPFLAGS
+  ga_saved_ldflags=$LDFLAGS
+  ga_saved_libs=$LIBS
+  CPPFLAGS=""
+
+    for ga_inc_name in libpng15 ; do
+      CPPFLAGS="$CPPFLAGS -I${ga_supplib_dir}/include/${ga_inc_name}"
+    done
+
+  CPPFLAGS="$CPPFLAGS "
+  LDFLAGS="-L${ga_supplib_dir}/lib "
+  LIBS="$LIBS "
+
+      echo "$as_me:$LINENO: checking for main in -lpng15" >&5
+echo $ECHO_N "checking for main in -lpng15... $ECHO_C" >&6
+if test "${ac_cv_lib_png15_main+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_check_lib_save_LIBS=$LIBS
+LIBS="-lpng15  $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+
+
+int
+main ()
+{
+main ();
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+  (eval $ac_link) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+	 { ac_try='test -z "$ac_c_werror_flag"
+			 || test ! -s conftest.err'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; } &&
+	 { ac_try='test -s conftest$ac_exeext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  ac_cv_lib_png15_main=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_cv_lib_png15_main=no
+fi
+rm -f conftest.err conftest.$ac_objext \
+      conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:$LINENO: result: $ac_cv_lib_png15_main" >&5
+echo "${ECHO_T}$ac_cv_lib_png15_main" >&6
+if test $ac_cv_lib_png15_main = yes; then
+   have_libpng=yes
+
+fi
+
+
+  # Use to undo temporary changes to -I and -L paths
+  CPPFLAGS=$ga_saved_cppflags
+  LDFLAGS=$ga_saved_ldflags
+  LIBS=$ga_saved_libs
+
+    fi
+    if test "$have_zlib" = "yes" -a "$have_libpng" = "yes" ; then
+      have_libjasper=no
+
+  # Use to make temporary changes to -I and -L paths
+  # Just for use during tests, because configure and make may run
+  # from different directories.
+  ga_saved_cppflags=$CPPFLAGS
+  ga_saved_ldflags=$LDFLAGS
+  ga_saved_libs=$LIBS
+  CPPFLAGS=""
+  :
+  CPPFLAGS="$CPPFLAGS "
+  LDFLAGS="-L${ga_supplib_dir}/lib "
+  LIBS="$LIBS "
+
+      echo "$as_me:$LINENO: checking for main in -ljasper" >&5
+echo $ECHO_N "checking for main in -ljasper... $ECHO_C" >&6
+if test "${ac_cv_lib_jasper_main+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_check_lib_save_LIBS=$LIBS
+LIBS="-ljasper  $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+
+
+int
+main ()
+{
+main ();
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+  (eval $ac_link) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+	 { ac_try='test -z "$ac_c_werror_flag"
+			 || test ! -s conftest.err'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; } &&
+	 { ac_try='test -s conftest$ac_exeext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  ac_cv_lib_jasper_main=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_cv_lib_jasper_main=no
+fi
+rm -f conftest.err conftest.$ac_objext \
+      conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:$LINENO: result: $ac_cv_lib_jasper_main" >&5
+echo "${ECHO_T}$ac_cv_lib_jasper_main" >&6
+if test $ac_cv_lib_jasper_main = yes; then
+   have_libjasper=yes
+
+fi
+
+
+  # Use to undo temporary changes to -I and -L paths
+  CPPFLAGS=$ga_saved_cppflags
+  LDFLAGS=$ga_saved_ldflags
+  LIBS=$ga_saved_libs
+
+      if test "$have_libjasper" = "yes" ; then
+
+  # Use to make temporary changes to -I and -L paths
+  # Just for use during tests, because configure and make may run
+  # from different directories.
+  ga_saved_cppflags=$CPPFLAGS
+  ga_saved_ldflags=$LDFLAGS
+  ga_saved_libs=$LIBS
+  CPPFLAGS=""
+
+    for ga_inc_name in grib2c ; do
+      CPPFLAGS="$CPPFLAGS -I${ga_supplib_dir}/include/${ga_inc_name}"
+    done
+
+  CPPFLAGS="$CPPFLAGS "
+  LDFLAGS="-L${ga_supplib_dir}/lib "
+  LIBS="$LIBS "
+
+        if test "${ac_cv_header_grib2_h+set}" = set; then
+  echo "$as_me:$LINENO: checking for grib2.h" >&5
+echo $ECHO_N "checking for grib2.h... $ECHO_C" >&6
+if test "${ac_cv_header_grib2_h+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+fi
+echo "$as_me:$LINENO: result: $ac_cv_header_grib2_h" >&5
+echo "${ECHO_T}$ac_cv_header_grib2_h" >&6
+else
+  # Is the header compilable?
+echo "$as_me:$LINENO: checking grib2.h usability" >&5
+echo $ECHO_N "checking grib2.h usability... $ECHO_C" >&6
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+$ac_includes_default
+#include <grib2.h>
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+  (eval $ac_compile) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+	 { ac_try='test -z "$ac_c_werror_flag"
+			 || test ! -s conftest.err'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; } &&
+	 { ac_try='test -s conftest.$ac_objext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  ac_header_compiler=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_header_compiler=no
+fi
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
+echo "${ECHO_T}$ac_header_compiler" >&6
+
+# Is the header present?
+echo "$as_me:$LINENO: checking grib2.h presence" >&5
+echo $ECHO_N "checking grib2.h presence... $ECHO_C" >&6
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+#include <grib2.h>
+_ACEOF
+if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
+  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } >/dev/null; then
+  if test -s conftest.err; then
+    ac_cpp_err=$ac_c_preproc_warn_flag
+    ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
+  else
+    ac_cpp_err=
+  fi
+else
+  ac_cpp_err=yes
+fi
+if test -z "$ac_cpp_err"; then
+  ac_header_preproc=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+  ac_header_preproc=no
+fi
+rm -f conftest.err conftest.$ac_ext
+echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
+echo "${ECHO_T}$ac_header_preproc" >&6
+
+# So?  What about this header?
+case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
+  yes:no: )
+    { echo "$as_me:$LINENO: WARNING: grib2.h: accepted by the compiler, rejected by the preprocessor!" >&5
+echo "$as_me: WARNING: grib2.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
+    { echo "$as_me:$LINENO: WARNING: grib2.h: proceeding with the compiler's result" >&5
+echo "$as_me: WARNING: grib2.h: proceeding with the compiler's result" >&2;}
+    ac_header_preproc=yes
+    ;;
+  no:yes:* )
+    { echo "$as_me:$LINENO: WARNING: grib2.h: present but cannot be compiled" >&5
+echo "$as_me: WARNING: grib2.h: present but cannot be compiled" >&2;}
+    { echo "$as_me:$LINENO: WARNING: grib2.h:     check for missing prerequisite headers?" >&5
+echo "$as_me: WARNING: grib2.h:     check for missing prerequisite headers?" >&2;}
+    { echo "$as_me:$LINENO: WARNING: grib2.h: see the Autoconf documentation" >&5
+echo "$as_me: WARNING: grib2.h: see the Autoconf documentation" >&2;}
+    { echo "$as_me:$LINENO: WARNING: grib2.h:     section \"Present But Cannot Be Compiled\"" >&5
+echo "$as_me: WARNING: grib2.h:     section \"Present But Cannot Be Compiled\"" >&2;}
+    { echo "$as_me:$LINENO: WARNING: grib2.h: proceeding with the preprocessor's result" >&5
+echo "$as_me: WARNING: grib2.h: proceeding with the preprocessor's result" >&2;}
+    { echo "$as_me:$LINENO: WARNING: grib2.h: in the future, the compiler will take precedence" >&5
+echo "$as_me: WARNING: grib2.h: in the future, the compiler will take precedence" >&2;}
+    (
+      cat <<\_ASBOX
+## --------------------------- ##
+## Report this to jma at iges.org ##
+## --------------------------- ##
+_ASBOX
+    ) |
+      sed "s/^/$as_me: WARNING:     /" >&2
+    ;;
+esac
+echo "$as_me:$LINENO: checking for grib2.h" >&5
+echo $ECHO_N "checking for grib2.h... $ECHO_C" >&6
+if test "${ac_cv_header_grib2_h+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_cv_header_grib2_h=$ac_header_preproc
+fi
+echo "$as_me:$LINENO: result: $ac_cv_header_grib2_h" >&5
+echo "${ECHO_T}$ac_cv_header_grib2_h" >&6
+
+fi
+if test $ac_cv_header_grib2_h = yes; then
+   echo "$as_me:$LINENO: checking for main in -lgrib2c" >&5
+echo $ECHO_N "checking for main in -lgrib2c... $ECHO_C" >&6
+if test "${ac_cv_lib_grib2c_main+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_check_lib_save_LIBS=$LIBS
+LIBS="-lgrib2c  $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+
+
+int
+main ()
+{
+main ();
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+  (eval $ac_link) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+	 { ac_try='test -z "$ac_c_werror_flag"
+			 || test ! -s conftest.err'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; } &&
+	 { ac_try='test -s conftest$ac_exeext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  ac_cv_lib_grib2c_main=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_cv_lib_grib2c_main=no
+fi
+rm -f conftest.err conftest.$ac_objext \
+      conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:$LINENO: result: $ac_cv_lib_grib2c_main" >&5
+echo "${ECHO_T}$ac_cv_lib_grib2c_main" >&6
+if test $ac_cv_lib_grib2c_main = yes; then
+   use_grib2=yes
+
+  ga_include_prefix='-I$(supp_include_dir)'
+
+  for ga_include_name in grib2c ; do
+      grib2_inc="$grib2_inc ${ga_include_prefix}/${ga_include_name}"
+  done
+
+
+  ga_lib_prefix='$(supp_lib_dir)/lib'
+  ga_lib_suffix='.a'
+  for ga_lib_name in grib2c jasper png15 z ; do
+      grib2_libs="$grib2_libs ${ga_lib_prefix}${ga_lib_name}${ga_lib_suffix}"
+  done
+
+
+fi
+
+
+fi
+
+
+
+  # Use to undo temporary changes to -I and -L paths
+  CPPFLAGS=$ga_saved_cppflags
+  LDFLAGS=$ga_saved_ldflags
+  LIBS=$ga_saved_libs
+
+      fi
+    fi
+  fi
+    # if we haven't got what we need, look outside supplibs for grib2
+  if test "$use_grib2" != "yes" -a "$ga_dyn_supplibs" = "yes" ; then
+    echo
+    echo "Checking in system locations for grib2 libraries ..."
+
+  ga_check_grib2="no"
+  if test "${ac_cv_header_grib2_h+set}" = set; then
+  echo "$as_me:$LINENO: checking for grib2.h" >&5
+echo $ECHO_N "checking for grib2.h... $ECHO_C" >&6
+if test "${ac_cv_header_grib2_h+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+fi
+echo "$as_me:$LINENO: result: $ac_cv_header_grib2_h" >&5
+echo "${ECHO_T}$ac_cv_header_grib2_h" >&6
+else
+  # Is the header compilable?
+echo "$as_me:$LINENO: checking grib2.h usability" >&5
+echo $ECHO_N "checking grib2.h usability... $ECHO_C" >&6
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+$ac_includes_default
+#include <grib2.h>
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+  (eval $ac_compile) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+	 { ac_try='test -z "$ac_c_werror_flag"
+			 || test ! -s conftest.err'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; } &&
+	 { ac_try='test -s conftest.$ac_objext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  ac_header_compiler=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_header_compiler=no
+fi
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
+echo "${ECHO_T}$ac_header_compiler" >&6
+
+# Is the header present?
+echo "$as_me:$LINENO: checking grib2.h presence" >&5
+echo $ECHO_N "checking grib2.h presence... $ECHO_C" >&6
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+#include <grib2.h>
+_ACEOF
+if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
+  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } >/dev/null; then
+  if test -s conftest.err; then
+    ac_cpp_err=$ac_c_preproc_warn_flag
+    ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
+  else
+    ac_cpp_err=
+  fi
+else
+  ac_cpp_err=yes
+fi
+if test -z "$ac_cpp_err"; then
+  ac_header_preproc=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+  ac_header_preproc=no
+fi
+rm -f conftest.err conftest.$ac_ext
+echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
+echo "${ECHO_T}$ac_header_preproc" >&6
+
+# So?  What about this header?
+case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
+  yes:no: )
+    { echo "$as_me:$LINENO: WARNING: grib2.h: accepted by the compiler, rejected by the preprocessor!" >&5
+echo "$as_me: WARNING: grib2.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
+    { echo "$as_me:$LINENO: WARNING: grib2.h: proceeding with the compiler's result" >&5
+echo "$as_me: WARNING: grib2.h: proceeding with the compiler's result" >&2;}
+    ac_header_preproc=yes
+    ;;
+  no:yes:* )
+    { echo "$as_me:$LINENO: WARNING: grib2.h: present but cannot be compiled" >&5
+echo "$as_me: WARNING: grib2.h: present but cannot be compiled" >&2;}
+    { echo "$as_me:$LINENO: WARNING: grib2.h:     check for missing prerequisite headers?" >&5
+echo "$as_me: WARNING: grib2.h:     check for missing prerequisite headers?" >&2;}
+    { echo "$as_me:$LINENO: WARNING: grib2.h: see the Autoconf documentation" >&5
+echo "$as_me: WARNING: grib2.h: see the Autoconf documentation" >&2;}
+    { echo "$as_me:$LINENO: WARNING: grib2.h:     section \"Present But Cannot Be Compiled\"" >&5
+echo "$as_me: WARNING: grib2.h:     section \"Present But Cannot Be Compiled\"" >&2;}
+    { echo "$as_me:$LINENO: WARNING: grib2.h: proceeding with the preprocessor's result" >&5
+echo "$as_me: WARNING: grib2.h: proceeding with the preprocessor's result" >&2;}
+    { echo "$as_me:$LINENO: WARNING: grib2.h: in the future, the compiler will take precedence" >&5
+echo "$as_me: WARNING: grib2.h: in the future, the compiler will take precedence" >&2;}
+    (
+      cat <<\_ASBOX
+## --------------------------- ##
+## Report this to jma at iges.org ##
+## --------------------------- ##
+_ASBOX
+    ) |
+      sed "s/^/$as_me: WARNING:     /" >&2
+    ;;
+esac
+echo "$as_me:$LINENO: checking for grib2.h" >&5
+echo $ECHO_N "checking for grib2.h... $ECHO_C" >&6
+if test "${ac_cv_header_grib2_h+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_cv_header_grib2_h=$ac_header_preproc
+fi
+echo "$as_me:$LINENO: result: $ac_cv_header_grib2_h" >&5
+echo "${ECHO_T}$ac_cv_header_grib2_h" >&6
+
+fi
+if test $ac_cv_header_grib2_h = yes; then
+   echo "$as_me:$LINENO: checking for main in -lgrib2c" >&5
+echo $ECHO_N "checking for main in -lgrib2c... $ECHO_C" >&6
+if test "${ac_cv_lib_grib2c_main+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_check_lib_save_LIBS=$LIBS
+LIBS="-lgrib2c  $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+
 
 int
 main ()
@@ -21682,7 +23209,7 @@ echo
 # Some non-configuration-dependent GrADS macros
 
 cat >>confdefs.h <<\_ACEOF
-#define GRADS_VERSION "2.0.2"
+#define GRADS_VERSION "2.1.a3"
 _ACEOF
 
 
@@ -21785,7 +23312,7 @@ build_info="Built `date` for ${host}"
 
    echo \
 "  +=========================================================================+"
-   echo "   GrADS "2.0.2 ":" $build_info
+   echo "   GrADS "2.1.a3 ":" $build_info
    echo \
 "  +=========================================================================+"
    echo
@@ -21818,6 +23345,19 @@ if test "$use_printim" = "yes" ; then
 else
    echo "  |  - printim disabled           |"
 fi
+if test "$use_cairo" = "yes" ; then
+   echo "  |  + cairo enabled              |"
+else
+   echo "  |  - cairo disabled             |"
+   echo "  |                               |"
+   echo "  |  * * * * * * * * * * * * * *  |"
+   echo "  |  *      !! WARNING !!      *  |"
+   echo "  |  *  THIS VERSION OF GrADS  *  |"
+   echo "  |  *    WILL NOT COMPILE     *  |"
+   echo "  |  *     WITHOUT CAIRO!      *  |"
+   echo "  |  * * * * * * * * * * * * * *  |"
+   echo "  |                               |"
+fi
 if test "$use_grib2" = "yes" ; then
    echo "  |  + grib2 enabled              |"
 else
@@ -21869,7 +23409,7 @@ fi
    echo "  +-------------------------------+"
 
 echo "configure: creating src/VERSION"
-echo 2.0.2 > src/VERSION
+echo 2.1.a3 > src/VERSION
 
 echo "configure: creating src/buildinfo.h"
 mkdir -p src
@@ -22302,7 +23842,7 @@ _ASBOX
 } >&5
 cat >&5 <<_CSEOF
 
-This file was extended by GrADS $as_me 2.0.2, which was
+This file was extended by GrADS $as_me 2.1.a3, which was
 generated by GNU Autoconf 2.59.  Invocation command line was
 
   CONFIG_FILES    = $CONFIG_FILES
@@ -22362,7 +23902,7 @@ _ACEOF
 
 cat >>$CONFIG_STATUS <<_ACEOF
 ac_cs_version="\\
-GrADS config.status 2.0.2
+GrADS config.status 2.1.a3
 configured by $0, generated by GNU Autoconf 2.59,
   with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
 
@@ -22630,6 +24170,8 @@ s, at GD_CONFIG@,$GD_CONFIG,;t t
 s, at GD_LDFLAGS@,$GD_LDFLAGS,;t t
 s, at printim_inc@,$printim_inc,;t t
 s, at printim_libs@,$printim_libs,;t t
+s, at cairo_inc@,$cairo_inc,;t t
+s, at cairo_libs@,$cairo_libs,;t t
 s, at G2_LIBS@,$G2_LIBS,;t t
 s, at grib2_inc@,$grib2_inc,;t t
 s, at grib2_libs@,$grib2_libs,;t t
diff --git a/configure.ac b/configure.ac
index e1f037f..4492a13 100644
--- a/configure.ac
+++ b/configure.ac
@@ -7,7 +7,7 @@ dnl  See acinclude.m4 for definitions of the GA_xxx macros
 
 # The version number
 # below is the "master" version that will appear in all code, etc.
-AC_INIT(GrADS, [2.0.2], [jma at iges.org])
+AC_INIT(GrADS, [2.1.a3], [jma at iges.org])
 
 # Require autoconf 2.52 (comes with Mac OS X 10.2) or newer
 AC_PREREQ(2.52) 
@@ -20,7 +20,8 @@ AC_CONFIG_AUX_DIR(etc)
 # disable dependency checking
 AM_INIT_AUTOMAKE([1.6 no-define no-dependencies])
 
-AM_CONFIG_HEADER([src/config.h])
+#AM_CONFIG_HEADER([src/config.h])
+AC_CONFIG_HEADERS([src/config.h])
 
 # The following macro prevents annoying interactions between CVS and 
 # automake, which result in make attempting to invoke autotools 
@@ -40,6 +41,8 @@ AC_ARG_WITH(readline, [AC_HELP_STRING([--with-readline],
                                       [command line editing])])
 AC_ARG_WITH(printim,  [AC_HELP_STRING([--with-printim],
                                       [image output])])
+AC_ARG_WITH(cairo,    [AC_HELP_STRING([--with-cairo],
+                                      [cairo image rendering])])
 AC_ARG_WITH(grib2,    [AC_HELP_STRING([--with-grib2],
                                       [GRIB2 data format])])
 AC_ARG_WITH(sdf,      [AC_HELP_STRING([--with-sdf],
@@ -120,7 +123,7 @@ dnl    guilibadd="-lSM -lICE"
 
   *darwin*)
     is_darwin="yes"
-    LDFLAGS="$LDFLAGS -lSystemStubs"
+#    LDFLAGS="$LDFLAGS -lSystemStubs"
   ;;
 
   cray-*-*)
@@ -205,6 +208,10 @@ AC_TYPE_OFF_T
 AC_SYS_LARGEFILE
 AC_FUNC_FSEEKO
 
+
+
+
+
 # ----------------------------------------------------
 # Check for optional feature support
 # ----------------------------------------------------
@@ -250,7 +257,6 @@ AC_ARG_VAR(SUPPLIBS,
            [Custom path (must be absolute) to a GrADS supplib distribution])
 
 
-
 # ----------------------------------------------------
 # Check for optional feature support
 # ----------------------------------------------------
@@ -264,6 +270,7 @@ use_geotiff=no
 have_zlib=no
 have_libpng=no
 have_jpeg=no
+have_xml2=no
 use_printim=no
 use_grib2=no
 have_udunits=no
@@ -273,6 +280,7 @@ use_nc=no
 use_nc4=no
 use_dap=no
 use_gadap=no
+use_cairo=no
 
 # look for libraries to support gui interface
 echo
@@ -455,8 +463,8 @@ if test "$with_printim" != "no" ; then
       ])
     ])
     GA_UNSET_FLAGS
-    GA_SET_FLAGS([libpng12])
-    AC_CHECK_LIB([png12], [main], 
+    GA_SET_FLAGS([libpng15])
+    AC_CHECK_LIB([png15], [main], 
     [ have_libpng=yes 
     ])
     GA_UNSET_FLAGS
@@ -472,9 +480,9 @@ if test "$with_printim" != "no" ; then
         [ use_printim=yes
           GA_SET_INCLUDE_VAR([printim_inc], [gd])
 	  if test "$have_jpeg" = "yes" ; then
-	    GA_SET_LIB_VAR([printim_libs], [gd png12 z jpeg])
+	    GA_SET_LIB_VAR([printim_libs], [gd png15 z jpeg])
 	  else
-  	    GA_SET_LIB_VAR([printim_libs], [gd png12 z])
+  	    GA_SET_LIB_VAR([printim_libs], [gd png15 z])
           fi
         ])
       ])
@@ -494,15 +502,91 @@ if test "$with_printim" != "no" ; then
 fi
 if test "$use_printim" != "yes" ; then
   AC_DEFINE(GXPNG, 0, [Enable printim using zlib, libpng, and libgd])
-  echo "- printim disabled (Warning: gxtran will not be built)" 
+  echo "- printim disabled" 
 else
-  extra_utils="$extra_utils gxtran"
   AC_SUBST(printim_inc)
   AC_SUBST(printim_libs)
   AC_DEFINE(GXPNG, 1, [Enable printim using zlib, libpng, and libgd])
   echo "+ printim enabled" 
 fi
 
+# Look for libraries to support cairo graphics library 
+echo
+if test "$with_cairo" != "no" ; then
+  # check if supplibs directory exists 
+  if test "Z$ga_supplib_dir" != "Z" ; then 
+    echo "Checking in supplibs for libraries to support cairo ..."
+    # zlib
+    if test "$have_zlib" = "no" ; then
+      GA_SET_FLAGS([zlib])
+      AC_CHECK_HEADERS([zlib.h], 
+      [ AC_CHECK_LIB([z], [compress], 
+        [ have_zlib=yes 
+        ])
+      ])
+      GA_UNSET_FLAGS
+    fi
+    # libpng
+    if test "$have_libpng" = "no" ; then
+      GA_SET_FLAGS([libpng15])
+      AC_CHECK_LIB([png15], [main], 
+      [ have_libpng=yes 
+      ])
+      GA_UNSET_FLAGS
+    fi
+    # libxml2
+    if test "$have_xml2" = "no" ; then
+      GA_SET_FLAGS([libxml2])
+      AC_CHECK_LIB([xml2], [main], 
+      [ have_xml2=yes 
+      ])
+      GA_UNSET_FLAGS
+    fi
+
+    if test "$have_xml2" = "yes"; then
+    if test "$have_zlib" = "yes" -a "$have_libpng" = "yes"; then
+      # pixman, fontconfig, freetype, Xrender, and cairo
+      # check for required header files 
+      GA_SET_FLAGS([cairo fontconfig freetype2 pixman-1])
+      AC_CHECK_HEADER(cairo.h,
+      [ AC_CHECK_HEADER(cairo-xlib.h,
+      [ AC_CHECK_HEADER(fontconfig.h,
+      [ AC_CHECK_HEADER(ft2build.h,
+      [ AC_CHECK_HEADER(pixman.h,
+      [ AC_CHECK_LIB(pixman-1,main,
+  	[ AC_CHECK_LIB(fontconfig,main,
+          [ AC_CHECK_LIB(freetype,main,
+            [ AC_CHECK_LIB(Xrender,main,
+              [ AC_CHECK_LIB(cairo,main,
+                [ use_cairo="yes"
+                  GA_SET_INCLUDE_VAR([cairo_inc], [cairo freetype2 fontconfig libpng15 pixman-1])
+                  GA_SET_LIB_VAR(cairo_libs, [cairo Xrender fontconfig freetype pixman-1 png15 xml2 z])
+	        ])
+              ])
+            ])
+          ])
+        ])
+      ])
+      ])
+      ])
+      ])
+      ])
+      GA_UNSET_FLAGS
+    fi
+    fi
+  fi
+fi
+if test "$use_cairo" != "yes" ; then
+  AC_DEFINE(USECAIRO, 0, [Caiiro not enabled])
+  echo "- cairo disabled" 
+else
+  AC_SUBST(cairo_inc)
+  AC_SUBST(cairo_libs)
+  AC_DEFINE(USECAIRO, 1, [Cairo enabled])
+  echo "+ cairo enabled" 
+fi
+
+
 # look for libraries to support grib2
 echo
 if test "$with_grib2" != "no" ; then
@@ -519,8 +603,8 @@ if test "$with_grib2" != "no" ; then
       GA_UNSET_FLAGS
     fi
     if test "$have_libpng" = "no" ; then
-      GA_SET_FLAGS([libpng12])
-      AC_CHECK_LIB([png12], [main], 
+      GA_SET_FLAGS([libpng15])
+      AC_CHECK_LIB([png15], [main], 
       [ have_libpng=yes 
       ])
       GA_UNSET_FLAGS
@@ -538,7 +622,7 @@ if test "$with_grib2" != "no" ; then
         [ AC_CHECK_LIB([grib2c], [main], 
           [ use_grib2=yes 
             GA_SET_INCLUDE_VAR([grib2_inc], [grib2c])
-            GA_SET_LIB_VAR([grib2_libs], [grib2c jasper png12 z])
+            GA_SET_LIB_VAR([grib2_libs], [grib2c jasper png15 z])
           ])
         ])
         GA_UNSET_FLAGS
@@ -940,6 +1024,19 @@ if test "$use_printim" = "yes" ; then
 else
    echo "  |  - printim disabled           |"
 fi 
+if test "$use_cairo" = "yes" ; then
+   echo "  |  + cairo enabled              |"
+else
+   echo "  |  - cairo disabled             |"
+   echo "  |                               |"
+   echo "  |  * * * * * * * * * * * * * *  |"
+   echo "  |  *      !! WARNING !!      *  |"
+   echo "  |  *  THIS VERSION OF GrADS  *  |"
+   echo "  |  *    WILL NOT COMPILE     *  |"
+   echo "  |  *     WITHOUT CAIRO!      *  |"
+   echo "  |  * * * * * * * * * * * * * *  |"
+   echo "  |                               |"
+fi 
 if test "$use_grib2" = "yes" ; then
    echo "  |  + grib2 enabled              |"
 else
diff --git a/data/font0.dat b/data/font0.dat
new file mode 100644
index 0000000..c35a310
--- /dev/null
+++ b/data/font0.dat
@@ -0,0 +1,95 @@
+  1I[
+  9MWRFRT RRYQZR[SZRY
+  6JZNFNM RVFVM
+ 12H]SBLb RYBRb RLOZO RKUYU
+ 27H\PBP_ RTBT_ RYIWGTFPFMGKIKKLMMNOOUQWRXSYUYXWZT[P[MZKX
+ 32F^[FI[ RNFPHPJOLMMKMIKIIJGLFNFPGSHVHYG[F RWTUUTWTYV[X[ZZ[X[VYTWT
+ 35E_\O\N[MZMYNXPVUTXRZP[L[JZIYHWHUISJRQNRMSKSIRGPFNGMIMKNNPQUXWZY[[[\Z\Y
+  3NVRFRM
+ 11KYVBTDRGPKOPOTPYR]T`Vb
+ 11KYNBPDRGTKUPUTTYR]P`Nb
+  9JZRLRX RMOWU RWOMU
+  6E_RIR[ RIR[R
+  9MWSZR[QZRYSZS\R^Q_
+  3E_IR[R
+  6MWRYQZR[SZRY
+  3G][BIb
+ 18H\QFNGLJKOKRLWNZQ[S[VZXWYRYOXJVGSFQF
+  5H\NJPISFS[
+ 15H\LKLJMHNGPFTFVGWHXJXLWNUQK[Y[
+ 16H\MFXFRNUNWOXPYSYUXXVZS[P[MZLYKW
+  7H\UFKTZT RUFU[
+ 18H\WFMFLOMNPMSMVNXPYSYUXXVZS[P[MZLYKW
+ 24H\XIWGTFRFOGMJLOLTMXOZR[S[VZXXYUYTXQVOSNRNOOMQLT
+  6H\YFO[ RKFYF
+ 30H\PFMGLILKMMONSOVPXRYTYWXYWZT[P[MZLYKWKTLRNPQOUNWMXKXIWGTFPF
+ 24H\XMWPURRSQSNRLPKMKLLINGQFRFUGWIXMXRWWUZR[P[MZLX
+ 12MWRMQNROSNRM RRYQZR[SZRY
+ 15MWRMQNROSNRM RSZR[QZRYSZS\R^Q_
+  4F^ZIJRZ[
+  6E_IO[O RIU[U
+  4F^JIZRJ[
+ 21I[LKLJMHNGPFTFVGWHXJXLWNVORQRT RRYQZR[SZRY
+ 43E`WNVLTKQKOLNMMPMSNUPVSVUUVS RWKVSVUXVZV\T]Q]O\L[JYHWGTFQFNGLHJJILHOHRIUJWLYNZQ[T[WZYY
+  9I[RFJ[ RRFZ[ RMTWT
+ 24G\KFK[ RKFTFWGXHYJYLXNWOTP RKPTPWQXRYTYWXYWZT[K[
+ 19H]ZKYIWGUFQFOGMILKKNKSLVMXOZQ[U[WZYXZV
+ 16G\KFK[ RKFRFUGWIXKYNYSXVWXUZR[K[
+ 12H[LFL[ RLFYF RLPTP RL[Y[
+  9HZLFL[ RLFYF RLPTP
+ 23H]ZKYIWGUFQFOGMILKKNKSLVMXOZQ[U[WZYXZVZS RUSZS
+  9G]KFK[ RYFY[ RKPYP
+  3NVRFR[
+ 11JZVFVVUYTZR[P[NZMYLVLT
+  9G\KFK[ RYFKT RPOY[
+  6HYLFL[ RL[X[
+ 12F^JFJ[ RJFR[ RZFR[ RZFZ[
+  9G]KFK[ RKFY[ RYFY[
+ 22G]PFNGLIKKJNJSKVLXNZP[T[VZXXYVZSZNYKXIVGTFPF
+ 14G\KFK[ RKFTFWGXHYJYMXOWPTQKQ
+ 25G]PFNGLIKKJNJSKVLXNZP[T[VZXXYVZSZNYKXIVGTFPF RSWY]
+ 17G\KFK[ RKFTFWGXHYJYLXNWOTPKP RRPY[
+ 21H\YIWGTFPFMGKIKKLMMNOOUQWRXSYUYXWZT[P[MZKX
+  6JZRFR[ RKFYF
+ 11G]KFKULXNZQ[S[VZXXYUYF
+  6I[JFR[ RZFR[
+ 12F^HFM[ RRFM[ RRFW[ R\FW[
+  6H\KFY[ RYFK[
+  7I[JFRPR[ RZFRP
+  9H\YFK[ RKFYF RK[Y[
+  9KYOBOb ROBVB RObVb
+  3G]IB[b
+  9KYUBUb RNBUB RNbUb
+  4JZNMRFVM
+  3G[Gb[b
+  7LXPFUL RPFOGUL
+ 18I\XMX[ RXPVNTMQMONMPLSLUMXOZQ[T[VZXX
+ 18H[LFL[ RLPNNPMSMUNWPXSXUWXUZS[P[NZLX
+ 15I[XPVNTMQMONMPLSLUMXOZQ[T[VZXX
+ 18I\XFX[ RXPVNTMQMONMPLSLUMXOZQ[T[VZXX
+ 18I[LSXSXQWOVNTMQMONMPLSLUMXOZQ[T[VZXX
+  9MYWFUFSGRJR[ ROMVM
+ 23I\XMX]W`VaTbQbOa RXPVNTMQMONMPLSLUMXOZQ[T[VZXX
+ 11I\MFM[ RMQPNRMUMWNXQX[
+  9NVQFRGSFREQF RRMR[
+ 12MWRFSGTFSERF RSMS^RaPbNb
+  9IZMFM[ RWMMW RQSX[
+  3NVRFR[
+ 19CaGMG[ RGQJNLMOMQNRQR[ RRQUNWMZM\N]Q][
+ 11I\MMM[ RMQPNRMUMWNXQX[
+ 18I\QMONMPLSLUMXOZQ[T[VZXXYUYSXPVNTMQM
+ 18H[LMLb RLPNNPMSMUNWPXSXUWXUZS[P[NZLX
+ 18I\XMXb RXPVNTMQMONMPLSLUMXOZQ[T[VZXX
+  9KXOMO[ ROSPPRNTMWM
+ 18J[XPWNTMQMNNMPNRPSUTWUXWXXWZT[Q[NZMX
+  9MYRFRWSZU[W[ ROMVM
+ 11I\MMMWNZP[S[UZXW RXMX[
+  6JZLMR[ RXMR[
+ 12G]JMN[ RRMN[ RRMV[ RZMV[
+  6J[MMX[ RXMM[
+ 10JZLMR[ RXMR[P_NaLbKb
+  9J[XMM[ RMMXM RM[X[
+ 20KYTBRCQEQGRISJTLTNSPORSTTVTXSZR[Q]Q_RaTb
+  3NVRBRb
+ 20KYPBRCSESGRIQJPLPNQPURQTPVPXQZR[S]S_RaPb
+ 14F^IUISJPLONOOPPQTTVUXUZT[Q[O
diff --git a/data/font1.dat b/data/font1.dat
new file mode 100644
index 0000000..200e8dc
--- /dev/null
+++ b/data/font1.dat
@@ -0,0 +1,95 @@
+  1I[
+ 15MWRFQHRTSHRF RRHRN RRYQZR[SZRY
+ 12JZNFMM ROFMM RVFUM RWFUM
+ 12H]SFLb RYFRb RLQZQ RKWYW
+ 42H\PBP_ RTBT_ RXIWJXKYJYIWGTFPFMGKIKKLMMNOOUQWRYT RKKMMONUPWQXRYTYXWZT[P[MZKXKWLVMWLX
+ 32F^[FI[ RNFPHPJOLMMKMIKIIJGLFNFPGSHVHYG[F RWTUUTWTYV[X[ZZ[X[VYTWT
+ 49F_[NZO[P\O\N[MZMYNXPVUTXRZP[M[JZIXIUJSPORMSKSIRGPFNGMIMKNNPQUXWZZ[[[\Z\Y RM[KZJXJUKSMQ RMKNMVXXZZ[
+  6NVRFQM RSFQM
+ 20KYVBTDRGPKOPOTPYR]T`Vb RTDRHQKPPPTQYR\T`
+ 20KYNBPDRGTKUPUTTYR]P`Nb RPDRHSKTPTTSYR\P`
+  9JZRFRR RMIWO RWIMO
+  6E_RIR[ RIR[R
+  8MWR[QZRYSZS\R^Q_
+  3E_IR[R
+  6MWRYQZR[SZRY
+  3G][BIb
+ 40H\QFNGLJKOKRLWNZQ[S[VZXWYRYOXJVGSFQF RQFOGNHMJLOLRMWNYOZQ[ RS[UZVYWWXRXOWJVHUGSF
+ 11H\NJPISFS[ RRGR[ RN[W[
+ 45H\LJMKLLKKKJLHMGPFTFWGXHYJYLXNUPPRNSLUKXK[ RTFVGWHXJXLWNTPPR RKYLXNXSZVZXYYX RNXS[W[XZYXYV
+ 47H\LJMKLLKKKJLHMGPFTFWGXIXLWNTOQO RTFVGWIWLVNTO RTOVPXRYTYWXYWZT[P[MZLYKWKVLUMVLW RWQXTXWWYVZT[
+ 13H\THT[ RUFU[ RUFJUZU RQ[X[
+ 39H\MFKP RKPMNPMSMVNXPYSYUXXVZS[P[MZLYKWKVLUMVLW RSMUNWPXSXUWXUZS[ RMFWF RMGRGWF
+ 48H\WIVJWKXJXIWGUFRFOGMILKKOKULXNZQ[S[VZXXYUYTXQVOSNRNOOMQLT RRFPGNIMKLOLUMXOZQ[ RS[UZWXXUXTWQUOSN
+ 31H\KFKL RKJLHNFPFUIWIXHYF RLHNGPGUI RYFYIXLTQSSRVR[ RXLSQRSQVQ[
+ 63H\PFMGLILLMNPOTOWNXLXIWGTFPF RPFNGMIMLNNPO RTOVNWLWIVGTF RPOMPLQKSKWLYMZP[T[WZXYYWYSXQWPTO RPONPMQLSLWMYNZP[ RT[VZWYXWXSWQVPTO
+ 48H\XMWPURRSQSNRLPKMKLLINGQFSFVGXIYLYRXVWXUZR[O[MZLXLWMVNWMX RQSORMPLMLLMIOGQF RSFUGWIXLXRWVVXTZR[
+ 12MWRMQNROSNRM RRYQZR[SZRY
+ 14MWRMQNROSNRM RR[QZRYSZS\R^Q_
+  4F^ZIJRZ[
+  6E_IO[O RIU[U
+  4F^JIZRJ[
+ 32I[MJNKMLLKLJMHNGPFSFVGWHXJXLWNVORQRT RSFUGVHWJWLVNTP RRYQZR[SZRY
+ 56E`WNVLTKQKOLNMMPMSNUPVSVUUVS RQKOMNPNSOUPV RWKVSVUXVZV\T]Q]O\L[JYHWGTFQFNGLHJJILHOHRIUJWLYNZQ[T[WZYYZX RXKWSWUXV
+ 18H\RFK[ RRFY[ RRIX[ RMUVU RI[O[ RU[[[
+ 45G]LFL[ RMFM[ RIFUFXGYHZJZLYNXOUP RUFWGXHYJYLXNWOUP RMPUPXQYRZTZWYYXZU[I[ RUPWQXRYTYWXYWZU[
+ 32G\XIYLYFXIVGSFQFNGLIKKJNJSKVLXNZQ[S[VZXXYV RQFOGMILKKNKSLVMXOZQ[
+ 30G]LFL[ RMFM[ RIFSFVGXIYKZNZSYVXXVZS[I[ RSFUGWIXKYNYSXVWXUZS[
+ 22G\LFL[ RMFM[ RSLST RIFYFYLXF RMPSP RI[Y[YUX[
+ 20G[LFL[ RMFM[ RSLST RIFYFYLXF RMPSP RI[P[
+ 40G^XIYLYFXIVGSFQFNGLIKKJNJSKVLXNZQ[S[VZXX RQFOGMILKKNKSLVMXOZQ[ RXSX[ RYSY[ RUS\S
+ 27F^KFK[ RLFL[ RXFX[ RYFY[ RHFOF RUF\F RLPXP RH[O[ RU[\[
+ 12MXRFR[ RSFS[ ROFVF RO[V[
+ 20KZUFUWTZR[P[NZMXMVNUOVNW RTFTWSZR[ RQFXF
+ 27F\KFK[ RLFL[ RYFLS RQOY[ RPOX[ RHFOF RUF[F RH[O[ RU[[[
+ 14I[NFN[ ROFO[ RKFRF RK[Z[ZUY[
+ 30F_KFK[ RLFRX RKFR[ RYFR[ RYFY[ RZFZ[ RHFLF RYF]F RH[N[ RV[][
+ 21G^LFL[ RMFYY RMHY[ RYFY[ RIFMF RVF\F RI[O[
+ 44G]QFNGLIKKJOJRKVLXNZQ[S[VZXXYVZRZOYKXIVGSFQF RQFOGMILKKOKRLVMXOZQ[ RS[UZWXXVYRYOXKWIUGSF
+ 29G]LFL[ RMFM[ RIFUFXGYHZJZMYOXPUQMQ RUFWGXHYJYMXOWPUQ RI[P[
+ 64G]QFNGLIKKJOJRKVLXNZQ[S[VZXXYVZRZOYKXIVGSFQF RQFOGMILKKOKRLVMXOZQ[ RS[UZWXXVYRYOXKWIUGSF RNYNXOVQURUTVUXV_W`Y`Z^Z] RUXV\W^X_Y_Z^
+ 45G]LFL[ RMFM[ RIFUFXGYHZJZLYNXOUPMP RUFWGXHYJYLXNWOUP RI[P[ RRPTQURXYYZZZ[Y RTQUSWZX[Z[[Y[X
+ 34H\XIYFYLXIVGSFPFMGKIKKLMMNOOUQWRYT RKKMMONUPWQXRYTYXWZT[Q[NZLXKUK[LX
+ 16I\RFR[ RSFS[ RLFKLKFZFZLYF RO[V[
+ 23F^KFKULXNZQ[S[VZXXYUYF RLFLUMXOZQ[ RHFOF RVF\F
+ 15H\KFR[ RLFRX RYFR[ RIFOF RUF[F
+ 24F^JFN[ RKFNV RRFN[ RRFV[ RSFVV RZFV[ RGFNF RWF]F
+ 21H\KFX[ RLFY[ RYFK[ RIFOF RUF[F RI[O[ RU[[[
+ 20H]KFRQR[ RLFSQS[ RZFSQ RIFOF RVF\F RO[V[
+ 16H\XFK[ RYFL[ RLFKLKFYF RK[Y[YUX[
+ 12KYOBOb RPBPb ROBVB RObVb
+  3G]IB[b
+ 12KYTBTb RUBUb RNBUB RNbUb
+  8G]JTROZT RJTRPZT
+  3G[Gb[b
+  7LXPFUL RPFOGUL
+ 39I]NONPMPMONNPMTMVNWOXQXXYZZ[ RWOWXXZZ[[[ RWQVRPSMTLVLXMZP[S[UZWX RPSNTMVMXNZP[
+ 33G\LFL[ RMFM[ RMPONQMSMVNXPYSYUXXVZS[Q[OZMX RSMUNWPXSXUWXUZS[ RIFMF
+ 28H[WPVQWRXQXPVNTMQMNNLPKSKULXNZQ[S[VZXX RQMONMPLSLUMXOZQ[
+ 36H]WFW[ RXFX[ RWPUNSMQMNNLPKSKULXNZQ[S[UZWX RQMONMPLSLUMXOZQ[ RTFXF RW[[[
+ 31H[LSXSXQWOVNTMQMNNLPKSKULXNZQ[S[VZXX RWSWPVN RQMONMPLSLUMXOZQ[
+ 22KXUGTHUIVHVGUFSFQGPIP[ RSFRGQIQ[ RMMUM RM[T[
+ 60I\QMONNOMQMSNUOVQWSWUVVUWSWQVOUNSMQM RONNPNTOV RUVVTVPUN RVOWNYMYNWN RNUMVLXLYM[P\U\X]Y^ RLYMZP[U[X\Y^Y_XaUbObLaK_K^L\O[
+ 28G]LFL[ RMFM[ RMPONRMTMWNXPX[ RTMVNWPW[ RIFMF RI[P[ RT[[[
+ 18MXRFQGRHSGRF RRMR[ RSMS[ ROMSM RO[V[
+ 25MXSFRGSHTGSF RTMT_SaQbObNaN`O_P`Oa RSMS_RaQb RPMTM
+ 27G\LFL[ RMFM[ RWMMW RRSX[ RQSW[ RIFMF RTMZM RI[P[ RT[Z[
+ 12MXRFR[ RSFS[ ROFSF RO[V[
+ 44BcGMG[ RHMH[ RHPJNMMOMRNSPS[ ROMQNRPR[ RSPUNXMZM]N^P^[ RZM\N]P][ RDMHM RD[K[ RO[V[ RZ[a[
+ 28G]LML[ RMMM[ RMPONRMTMWNXPX[ RTMVNWPW[ RIMMM RI[P[ RT[[[
+ 36H\QMNNLPKSKULXNZQ[S[VZXXYUYSXPVNSMQM RQMONMPLSLUMXOZQ[ RS[UZWXXUXSWPUNSM
+ 36G\LMLb RMMMb RMPONQMSMVNXPYSYUXXVZS[Q[OZMX RSMUNWPXSXUWXUZS[ RIMMM RIbPb
+ 33H\WMWb RXMXb RWPUNSMQMNNLPKSKULXNZQ[S[UZWX RQMONMPLSLUMXOZQ[ RTb[b
+ 23IZNMN[ ROMO[ ROSPPRNTMWMXNXOWPVOWN RKMOM RK[R[
+ 32J[WOXMXQWOVNTMPMNNMOMQNRPSUUWVXW RMPNQPRUTWUXVXYWZU[Q[OZNYMWM[NY
+ 16KZPFPWQZS[U[WZXX RQFQWRZS[ RMMUM
+ 28G]LMLXMZP[R[UZWX RMMMXNZP[ RWMW[ RXMX[ RIMMM RTMXM RW[[[
+ 15I[LMR[ RMMRY RXMR[ RJMPM RTMZM
+ 24F^JMN[ RKMNX RRMN[ RRMV[ RSMVX RZMV[ RGMNM RWM]M
+ 21H\LMW[ RMMX[ RXML[ RJMPM RTMZM RJ[P[ RT[Z[
+ 22H[LMR[ RMMRY RXMR[P_NaLbKbJaK`La RJMPM RTMZM
+ 16I[WML[ RXMM[ RMMLQLMXM RL[X[XWW[
+ 40KYTBRCQDPFPHQJRKSMSOQQ RRCQEQGRISJTLTNSPORSTTVTXSZR[Q]Q_Ra RQSSUSWRYQZP\P^Q`RaTb
+  3NVRBRb
+ 40KYPBRCSDTFTHSJRKQMQOSQ RRCSESGRIQJPLPNQPURQTPVPXQZR[S]S_Ra RSSQUQWRYSZT\T^S`RaPb
+ 24F^IUISJPLONOPPTSVTXTZS[Q RISJQLPNPPQTTVUXUZT[Q[O
diff --git a/data/font2.dat b/data/font2.dat
new file mode 100644
index 0000000..20f2c12
--- /dev/null
+++ b/data/font2.dat
@@ -0,0 +1,95 @@
+  1I[
+ 17MXUFTGRS RUGRS RUFVGRS RPYOZP[QZPY
+ 12I[PFNM RQFNM RYFWM RZFWM
+ 12H]SFLb RYFRb RLQZQ RKWYW
+ 41H]TBL_ RYBQ_ RZJYKZL[K[JZHYGVFRFOGMIMKNMONVRXT RMKOMVQWRXTXWWYVZS[O[LZKYJWJVKULVKW
+ 32F^[FI[ RNFPHPJOLMMKMIKIIJGLFNFPGSHVHYG[F RWTUUTWTYV[X[ZZ[X[VYTWT
+ 55E_\N[O\P]O]N\M[MYNWPRXPZN[K[HZGXGVHTISKRPPROTMUKUITGRFPGOIOLPRQUSXUZW[Y[ZYZX RK[IZHXHVITJSPP ROLPQQTSWUYWZYZZY
+  6NWUFSM RVFSM
+ 20KZZBVESHQKOONTNXO]P`Qb RVESIQMPPOUOZP_Qb
+ 20JYSBTDUGVLVPUUSYQ\N_Jb RSBTEUJUOTTSWQ[N_
+  9JZRFRR RMIWO RWIMO
+  6E_RIR[ RIR[R
+  8MXP[OZPYQZQ[P]N_
+  3E_IR[R
+  6MXPYOZP[QZPY
+  3G]_BEb
+ 42H]TFQGOIMLLOKSKVLYMZO[Q[TZVXXUYRZNZKYHXGVFTF RTFRGPINLMOLSLVMYO[ RQ[SZUXWUXRYNYKXHVF
+ 15H]TJO[ RVFP[ RVFSIPKNL RUIQKNL
+ 42H]OJPKOLNKNJOHPGSFVFYGZIZKYMWOTQPSMUKWI[ RVFXGYIYKXMVOPS RJYKXMXRZUZWYXW RMXR[U[WZXW
+ 50H]OJPKOLNKNJOHPGSFVFYGZIZKYMVOSP RVFXGYIYKXMVO RQPSPVQWRXTXWWYVZS[O[LZKYJWJVKULVKW RSPUQVRWTWWVYUZS[
+ 10H]XGR[ RYFS[ RYFJUZU
+ 39H]QFLP RQF[F RQGVG[F RLPMOPNSNVOWPXRXUWXUZR[O[LZKYJWJVKULVKW RSNUOVPWRWUVXTZR[
+ 46H]YIXJYKZJZIYGWFTFQGOIMLLOKSKWLYMZO[R[UZWXXVXSWQVPTOQOOPMRLT RTFRGPINLMOLSLXMZ RR[TZVXWVWRVP
+ 30H]NFLL R[FZIXLSRQUPWO[ RXLRRPUOWN[ RMIPFRFWI RNHPGRGWIYIZH[F
+ 63H]SFPGOHNJNMOOQPTPXOYNZLZIYGVFSF RSFQGPHOJOMPOQP RTPWOXNYLYIXGVF RQPMQKSJUJXKZN[R[VZWYXWXTWRVQTP RQPNQLSKUKXLZN[ RR[UZVYWWWSVQ
+ 46H]YMXOVQTRQROQNPMNMKNIPGSFVFXGYHZJZNYRXUVXTZQ[N[LZKXKWLVMWLX ROQNONKOIQGSF RXGYIYNXRWUUXSZQ[
+ 11MXSMRNSOTNSM RPYOZP[QZ
+ 14MXSMRNSOTNSM RP[OZPYQZQ[P]N_
+  4F^ZIJRZ[
+  6E_IO[O RIU[U
+  4F^JIZRJ[
+ 34H]OJPKOLNKNJOHPGSFWFZG[I[KZMYNSPQQQSRTTT RWFYGZIZKYMXNVO RPYOZP[QZPY
+ 56E`WNVLTKQKOLNMMPMSNUPVSVUUVS RQKOMNPNSOUPV RWKVSVUXVZV\T]Q]O\L[JYHWGTFQFNGLHJJILHOHRIUJWLYNZQ[T[WZYYZX RXKWSWUXV
+ 18H\UFH[ RUFV[ RTHU[ RLUUU RF[L[ RR[X[
+ 41F^OFI[ RPFJ[ RLFWFZG[I[KZNYOVP RWFYGZIZKYNXOVP RMPVPXQYSYUXXVZR[F[ RVPWQXSXUWXUZR[
+ 34H]ZH[H\F[L[JZHYGWFTFQGOIMLLOKSKVLYMZP[S[UZWXXV RTFRGPINLMOLSLVMYNZP[
+ 30F]OFI[ RPFJ[ RLFUFXGYHZKZOYSWWUYSZO[F[ RUFWGXHYKYOXSVWTYRZO[
+ 22F]OFI[ RPFJ[ RTLRT RLF[FZLZF RMPSP RF[U[WVT[
+ 20F\OFI[ RPFJ[ RTLRT RLF[FZLZF RMPSP RF[M[
+ 42H^ZH[H\F[L[JZHYGWFTFQGOIMLLOKSKVLYMZP[R[UZWXYT RTFRGPINLMOLSLVMYNZP[ RR[TZVXXT RUT\T
+ 27E_NFH[ ROFI[ R[FU[ R\FV[ RKFRF RXF_F RLPXP RE[L[ RR[Y[
+ 12LYUFO[ RVFP[ RRFYF RL[S[
+ 21I[XFSWRYQZO[M[KZJXJVKULVKW RWFRWQYO[ RTF[F
+ 27F]OFI[ RPFJ[ R]FLS RSOW[ RROV[ RLFSF RYF_F RF[M[ RS[Y[
+ 14H\QFK[ RRFL[ RNFUF RH[W[YUV[
+ 30E`NFH[ RNFO[ ROFPY R\FO[ R\FV[ R]FW[ RKFOF R\F`F RE[K[ RS[Z[
+ 21F_OFI[ ROFVX ROIV[ R\FV[ RLFOF RYF_F RF[L[
+ 42G]SFPGNILLKOJSJVKYLZN[Q[TZVXXUYRZNZKYHXGVFSF RSFQGOIMLLOKSKVLYN[ RQ[SZUXWUXRYNYKXHVF
+ 27F]OFI[ RPFJ[ RLFXF[G\I\K[NYPUQMQ RXFZG[I[KZNXPUQ RF[M[
+ 61G]SFPGNILLKOJSJVKYLZN[Q[TZVXXUYRZNZKYHXGVFSF RSFQGOIMLLOKSKVLYN[ RQ[SZUXWUXRYNYKXHVF RLYLXMVOUPURVSXS_T`V`W^W] RSXT^U_V_W^
+ 42F^OFI[ RPFJ[ RLFWFZG[I[KZNYOVPMP RWFYGZIZKYNXOVP RRPTQURVZW[Y[ZYZX RURWYXZYZZY RF[M[
+ 35G^ZH[H\F[L[JZHYGVFRFOGMIMKNMONVRXT RMKOMVQWRXTXWWYVZS[O[LZKYJWJUI[JYKY
+ 16H]UFO[ RVFP[ ROFLLNF]F\L\F RL[S[
+ 25F_NFKQJUJXKZN[R[UZWXXU\F ROFLQKUKXLZN[ RKFRF RYF_F
+ 15H\NFO[ ROFPY R\FO[ RLFRF RXF^F
+ 24E_MFK[ RNFLY RUFK[ RUFS[ RVFTY R]FS[ RJFQF RZF`F
+ 21G]NFU[ ROFV[ R\FH[ RLFRF RXF^F RF[L[ RR[X[
+ 20H]NFRPO[ ROFSPP[ R]FSP RLFRF RYF_F RL[S[
+ 16G][FH[ R\FI[ ROFLLNF\F RH[V[XUU[
+ 12KYOBOb RPBPb ROBVB RObVb
+  3G]IB[b
+ 12KYTBTb RUBUb RNBUB RNbUb
+  8G]JTROZT RJTRPZT
+  3G[Gb[b
+  7LXPFUL RPFOGUL
+ 39H]XMVTUXUZV[Y[[Y\W RYMWTVXVZW[ RVTVQUNSMQMNNLQKTKWLYMZO[Q[SZUWVT RQMONMQLTLXMZ
+ 36H[PFLSLVMYNZ RQFMS RMSNPPNRMTMVNWOXQXTWWUZR[P[NZMWMS RVNWPWTVWTZR[ RMFQF
+ 25I[WPWQXQXPWNUMRMONMQLTLWMYNZP[R[UZWW RRMPNNQMTMXNZ
+ 42H]ZFVTUXUZV[Y[[Y\W R[FWTVXVZW[ RVTVQUNSMQMNNLQKTKWLYMZO[Q[SZUWVT RQMONMQLTLXMZ RWF[F
+ 26I[MVQUTTWRXPWNUMRMONMQLTLWMYNZP[R[UZWX RRMPNNQMTMXNZ
+ 35KZZGYHZI[H[GZFXFVGUHTJSMP[O_Na RXFVHUJTNRWQ[P^O`NaLbJbIaI`J_K`Ja ROMYM
+ 43H\YMU[T^RaObLbJaI`I_J^K_J` RXMT[S^QaOb RVTVQUNSMQMNNLQKTKWLYMZO[Q[SZUWVT RQMONMQLTLXMZ
+ 31H]PFJ[ RQFK[ RMTOPQNSMUMWNXOXQVWVZW[ RUMWOWQUWUZV[Y[[Y\W RMFQF
+ 26LYUFTGUHVGUF RMQNOPMSMTNTQRWRZS[ RRMSNSQQWQZR[U[WYXW
+ 32LYVFUGVHWGVF RNQOOQMTMUNUQR[Q^P`OaMbKbJaJ`K_L`Ka RSMTNTQQ[P^O`Mb
+ 34H\PFJ[ RQFK[ RXNWOXPYOYNXMWMUNQROSMS ROSQTSZT[ ROSPTRZS[U[WZYW RMFQF
+ 18MYUFQTPXPZQ[T[VYWW RVFRTQXQZR[ RRFVF
+ 52AbBQCOEMHMINIPHTF[ RGMHNHPGTE[ RHTJPLNNMPMRNSOSQP[ RPMRORQO[ RRTTPVNXMZM\N]O]Q[W[Z\[ RZM\O\QZWZZ[[^[`YaW
+ 37F]GQHOJMMMNNNPMTK[ RLMMNMPLTJ[ RMTOPQNSMUMWNXOXQVWVZW[ RUMWOWQUWUZV[Y[[Y\W
+ 32I[RMONMQLTLWMYNZP[R[UZWWXTXQWOVNTMRM RRMPNNQMTMXNZ RR[TZVWWTWPVN
+ 42G\HQIOKMNMONOPNTJb RMMNNNPMTIb RNTOQQNSMUMWNXOYQYTXWVZS[Q[OZNWNT RWNXPXTWWUZS[ RFbMb
+ 33H\XMRb RYMSb RVTVQUNSMQMNNLQKTKWLYMZO[Q[SZUWVT RQMONMQLTLXMZ RObVb
+ 26IZJQKOMMPMQNQPPTN[ ROMPNPPOTM[ RPTRPTNVMXMYNYOXPWOXN
+ 28J[XOXPYPYOXNUMRMONNONQORVVWW RNPOQVUWVWYVZS[P[MZLYLXMXMY
+ 18KYTFPTOXOZP[S[UYVW RUFQTPXPZQ[ RNMWM
+ 37F]GQHOJMMMNNNQLWLYN[ RLMMNMQKWKYLZN[P[RZTXVT RXMVTUXUZV[Y[[Y\W RYMWTVXVZW[
+ 26H\IQJOLMOMPNPQNWNYP[ RNMONOQMWMYNZP[Q[TZVXXUYQYMXMYO
+ 41C`DQEOGMJMKNKQIWIYK[ RIMJNJQHWHYIZK[M[OZQXRV RTMRVRYSZU[W[YZ[X\V]R]M\M]O RUMSVSYU[
+ 42H\KQMNOMRMSOSR RQMRORRQVPXNZL[K[JZJYKXLYKZ RQVQYR[U[WZYW RYNXOYPZOZNYMXMVNTPSRRVRYS[
+ 41G\HQIOKMNMONOQMWMYO[ RMMNNNQLWLYMZO[Q[SZUXWT RZMV[U^SaPbMbKaJ`J_K^L_K` RYMU[T^RaPb
+ 31H\YMXOVQNWLYK[ RLQMOOMRMVO RMOONRNVOXO RLYNYRZUZWY RNYR[U[WYXW
+ 40KYTBRCQDPFPHQJRKSMSOQQ RRCQEQGRISJTLTNSPORSTTVTXSZR[Q]Q_Ra RQSSUSWRYQZP\P^Q`RaTb
+  3NVRBRb
+ 40KYPBRCSDTFTHSJRKQMQOSQ RRCSESGRIQJPLPNQPURQTPVPXQZR[S]S_Ra RSSQUQWRYSZT\T^S`RaPb
+ 24F^IUISJPLONOPPTSVTXTZS[Q RISJQLPNPPQTTVUXUZT[Q[O
diff --git a/data/font3.dat b/data/font3.dat
new file mode 100644
index 0000000..84e255c
--- /dev/null
+++ b/data/font3.dat
@@ -0,0 +1,95 @@
+  1I[
+  9E_YIK[ RIO[O RIU[U
+ 11E_XP[RXT RUMZRUW RIRZR
+ 11JZPLRITL RMORJWO RRJR[
+ 11E_LPIRLT ROMJROW RJR[R
+ 11JZPXR[TX RMURZWU RRIRZ
+ 10E[HMLMRY RKMR[ R[BR[
+ 13F^ZJSJOKMLKNJQJSKVMXOYSZZZ
+ 13F^JZJSKOLMNKQJSJVKXMYOZSZZ
+ 13F^JJQJUKWLYNZQZSYVWXUYQZJZ
+  6G]KKYY RYKKY
+ 13F^JJJQKULWNYQZSZVYXWYUZQZJ
+  9F^RJR[ RJRZR RJ[Z[
+  9F^RJR[ RJJZJ RJRZR
+ 30KYQFOGNINKOMQNSNUMVKVIUGSFQF RQFNIOMSNVKUGQF RSFOGNKQNUMVISF
+ 15E_RIQJRKSJRI RIR[R RRYQZR[SZRY
+  6MWRQQRRSSRRQ
+ 16PTQPPQPSQTSTTSTQSPQP RRQQRRSSRRQ
+ 35NVQNOONQNSOUQVSVUUVSVQUOSNQN ROQOS RPPPT RQOQU RRORU RSOSU RTPTT RUQUS
+ 10PTQPPQPSQTSTTSTQSPQP
+ 14NVQNOONQNSOUQVSVUUVSVQUOSNQN
+ 18KYQKNLLNKQKSLVNXQYSYVXXVYSYQXNVLSKQK
+ 44I\XRWOVNTMRMONMQLTLWMYNZP[R[UZWXXUYPYKXHWGUFRFPGOHOIPIPH RRMPNNQMTMXNZ RR[TZVXWUXPXKWHUF
+ 15H\JFR[ RKFRY RZFR[ RJFZF RKGYG
+ 10AbDMIMRY RHNR[ Rb:R[
+ 32F^[CZD[E\D\C[BYBWCUETGSJRNPZO^N` RVDUFTJRVQZP]O_MaKbIbHaH`I_J`Ia
+ 50F^[CZD[E\D\C[BYBWCUETGSJRNPZO^N` RVDUFTJRVQZP]O_MaKbIbHaH`I_J`Ia RQKNLLNKQKSLVNXQYSYVXXVYSYQXNVLSKQK
+ 46JZUITJUKVJVIUGSFQFOGNINKOMQOVR ROMTPVRWTWVVXTZ RPNNPMRMTNVPXU[ RNVSYU[V]V_UaSbQbOaN_N^O]P^O_
+ 10F^ZFJMZT RJVZV RJ[Z[
+  9E_IM[M RIR[R RIW[W
+ 10F^JFZMJT RJVZV RJ[Z[
+ 26F_\S[UYVWVUUTTQPPONNLNJOIQISJULVNVPUQTTPUOWNYN[O\Q\S
+ 17MWRLMUWURL RROOT RROUT RRRQT RRRST
+ 15H\RFK[ RRFY[ RRIX[ RI[O[ RU[[[
+ 18E_RIQJRKSJRI RIYHZI[JZIY R[YZZ[[\Z[Y
+ 14I[NFN[ ROFO[ RKFZFZLYF RK[R[
+ 15H\RFJ[ RRFZ[ RRIY[ RKZYZ RJ[Z[
+ 36G]KEJJ RZEYJ RONNS RVNUS RKWJ\ RZWY\ RKGYG RKHYH ROPUP ROQUQ RKYYY RKZYZ
+ 33F^RHNLKPJSJUKWMXOXQWRU RRHVLYPZSZUYWWXUXSWRU RRUQYP\ RRUSYT\ RP\T\
+ 26F^RNQKPINHMHKIJKJOKRLTNWR\ RRNSKTIVHWHYIZKZOYRXTVWR\
+ 20F^RGPJLOIR RRGTJXO[R RIRLUPZR] R[RXUTZR]
+ 48F^RTTWVXXXZW[U[SZQXPVPSQ RSQUOVMVKUISHQHOINKNMOOQQ RQQNPLPJQISIUJWLXNXPWRT RRTQYP\ RRTSYT\ RP\T\
+ 55F^ISJSLTMVMXLZ RISIRJQLQMRNTNWMYLZ RRGPIOLOOQUQXPZR\ RRGTIULUOSUSXTZR\ R[S[RZQXQWRVTVWWYXZ R[SZSXTWVWXXZ RKVYV
+  6LXLLLXXXXLLL
+ 27NVNNNVVVVNNN ROOOU RPOPU RQOQU RRORU RSOSU RTOTU RUOUU
+  5KYRJKVYVRJ
+  6LXRHLRR\XRRH
+ 56G]QFNGLIKKJOJRKVLXNZQ[S[VZXXYVZRZOYKXIVGSFQF RQFOGMILKKOKRLVMXOZQ[ RS[UZWXXVYRYOXKWIUGSF ROMOT RUMUT ROPUP ROQUQ
+ 21F^KHK\ RLHL\ RXHX\ RYHY\ RHH\H RH\O\ RU\\\
+ 12JZRIPOJOOSMYRUWYUSZOTORI
+ 22LXRLNWXPLPVWRL RRRRL RRRLP RRRNW RRRVW RRRXP
+ 20H]KHRQJ\ RJHQQ RJHYHZMXH RK[X[ RJ\Y\ZWX\
+ 38E`QFNGKIILHOHRIUKXNZQ[T[WZZX\U]R]O\LZIWGTFQF RROQPQQRRSRTQTPSORO RRPRQSQSPRP
+ 33I\KKKILGMFOFPGQIRMR[ RKIMGOGQI RZKZIYGXFVFUGTISMS[ RZIXGVGTI RO[V[
+ 26MWMRMQNOONQMSMUNVOWQWR RPNTN ROOUO RNPVP RNQVQ RMRWR
+ 48H]RFR[ RSFS[ RPKMLLMKOKRLTMUPVUVXUYTZRZOYMXLUKPK RPKNLMMLOLRMTNUPV RUVWUXTYRYOXMWLUK ROFVF RO[V[
+ 23I[KMMMONPPU_VaWb RMMNNOPT_UaWbYb RZMYOWRM]K`Jb
+ 41G^RFR[ RSFS[ RIMJLLMMQNSOTQU RJLKMLQMSNTQUTUWTXSYQZM[L RTUVTWSXQYM[L\M ROFVF RO[V[
+ 43G]JXK[O[MWKSJPJLKIMGPFTFWGYIZLZPYSWWU[Y[ZX RMWLTKPKLLINGPF RTFVGXIYLYPXTWW RKZNZ RVZYZ
+ 30JZRFQHRJSHRF RRFRb RRQQTRbSTRQ RLMNNPMNLLM RLMXM RTMVNXMVLTM
+ 12I\XFX[ RKFXF RPPXP RK[X[
+ 56JZRFQHRJSHRF RRFRT RRPQRSVRXQVSRRP RRTRb RR^Q`RbS`R^ RLMNNPMNLLM RLMXM RTMVNXMVLTM RL[N\P[NZL[ RL[X[ RT[V\X[VZT[
+ 34>fRAPCMDJDGCEA>H at JAMAZB]D_G`M`PaRc RRATCWDZD]C_AfHdJcMcZb]`_]`W`TaRc
+ 33AcRAPCMDJDGCEABGAKAPBTDXG\L`Rc RRATCWDZD]C_AbGcKcPbT`X]\X`Rc RBHbH
+  8MWRHSGRFQGQIRKSL
+ 40G^QMNNLPKRJUJXKZN[P[RZUWWTYPZM RQMONMPLRKUKXLZN[ RQMSMUNVPXXYZZ[ RSMTNUPWXXZZ[[[
+ 57G\TFQGOIMMLPKTJZIb RTFRGPINMMPLTKZJb RTFVFXGYHYKXMWNTOPO RVFXHXKWMVNTO RPOTPVRWTWWVYUZR[P[NZMYLV RPOSPURVTVWUYTZR[
+ 28H\IPKNMMOMQNROSRSVRZOb RJOLNPNRO RZMYPXRSYP^Nb RYMXPWRSY
+ 44I\VNTMRMONMQLTLWMYNZP[R[UZWWXTXQWOSJRHRFSEUEWFYH RRMPNNQMTMXNZ RR[TZVWWTWPVNTKSISGTFVFYH
+ 32I[XPVNTMPMNNNPPRSS RPMONOPQRSS RSSNTLVLXMZP[S[UZWX RSSOTMVMXNZP[
+ 31I[TFRGQHQIRJUKZKZJWKSMPOMRLULWMYP[S]T_TaSbQbPa RULQONRMUMWNYP[
+ 32G]HQIOKMNMONOPNTL[ RMMNNNPMTK[ RNTPPRNTMVMXNYOYRXWUb RVMXOXRWWTb
+ 44F]GQHOJMMMNNNPMUMXNZO[ RLMMNMPLULXMZO[Q[SZUXWUXRYMYIXGVFTFRHRJSMUPWRZT RSZUWVUWRXMXIWGVF
+ 15LXRMPTOXOZP[S[UYVW RSMQTPXPZQ[
+ 45IZTFRGQHQIRJUKXK RUKQLOMNONQPSSTVT RUKRLPMOOOQQSST RSTOUMVLXLZN\S^T_TaRbPb RSTPUNVMXMZO\S^
+ 29H\NMJ[ ROMK[ RXMYNZNYMWMUNQROSMS ROSQTSZT[ ROSPTRZS[U[WZYW
+ 23H\KFMFOGPHQJWXXZY[ RMFOHPJVXWZY[Z[ RRMJ[ RRMK[
+ 28F]MMGb RNMHb RMPLVLYN[P[RZTXVU RXMUXUZV[Y[[Y\W RYMVXVZW[
+ 24H\NML[ ROMNSMXL[ RYMXQVU RZMYPXRVUTWQYOZL[ RKMOM
+ 32I[RMONMQLTLWMYNZP[R[UZWWXTXQWOVNTMRM RRMPNNQMTMXNZ RR[TZVWWTWPVN
+ 22G]PNL[ RPNM[ RVNV[ RVNW[ RIPKNNM[M RIPKONN[N
+ 25IZWNUMRMONMPLSLVMYNZQ[T[VZ RRMPNNPMSMVNYOZQ[ RMTUT
+ 31H[LVMYNZP[R[UZWWXTXQWOVNTMRMONMQLTHb RR[TZVWWTWPVN RRMPNNQMTIb
+ 35H][MQMNNLQKTKWLYMZO[Q[TZVWWTWQVOUNSM RQMONMQLTLXMZ RQ[SZUWVTVPUN RUN[N
+ 16H\SNP[ RSNQ[ RJPLNOMZM RJPLOONZN
+ 31H\IQJOLMOMPNPPNVNYP[ RNMONOPMVMYNZP[Q[TZVXXUYRYOXMWNXOYR RXUYO
+ 37G]ONMOKQJTJWKYLZN[Q[TZWXYUZRZOXMVMTORSPXMb RJWLYNZQZTYWWYU RZOXNVNTPRSPYNb
+ 44F]JQLOONNMLNJQITIWJZK[M[OZQWRT RIWJYKZMZOYQW RQTQWRZS[U[WZYWZTZQYNXMWNYOZQ RQWRYSZUZWYYW
+ 42G]UFOb RVFNb RQMMNKPJSJVKXMZP[S[WZYXZUZRYPWNTMQM RQMNNLPKSKVLXNZP[ RS[VZXXYUYRXPVNTM
+ 34F]UFOb RVFNb RGQHOJMMMNNNPMUMXOZRZTYWVYS RLMMNMPLULXMZO[R[TZVXXUYS[M
+ 43I\TFQGOJNLMOLTLXMZO[Q[TZVWWUXRYMYIXGVFTF RTFRGPJOLNOMTMXNZO[ RQ[SZUWVUWRXMXIWGVF RNPWP
+  6F^RBR[ RI[[[
+  6KYOBOb RUBUb
+ 28G]IIJKKOKUJYI[ R[IZKYOYUZY[[ RIIKJOKUKYJ[I RI[KZOYUYYZ[[
+ 24F^IUISJPLONOPPTSVTXTZS[Q RISJQLPNPPQTTVUXUZT[Q[O
diff --git a/data/font5.dat b/data/font5.dat
new file mode 100644
index 0000000..2329d23
--- /dev/null
+++ b/data/font5.dat
@@ -0,0 +1,96 @@
+  1I[
+ 34MXRFQGQIRQ RRFRTST RRFSFST RSFTGTISQ RRXQYQZR[S[TZTYSXRX RRYRZSZSYRY
+ 22I[NFMGMM RNGMM RNFOGMM RWFVGVM RWGVM RWFXGVM
+ 12H]SFLb RYFRb RLQZQ RKWYW
+ 56H\PBP_ RTBT_ RXKXJWJWLYLYJXHWGTFPFMGKIKLLNOPURWSXUXXWZ RLLMNOOUQWRXT RMGLILKMMONUPXRYTYWXYWZT[P[MZLYKWKUMUMWLWLV
+ 32F^[FI[ RNFPHPJOLMMKMIKIIJGLFNFPGSHVHYG[F RWTUUTWTYV[X[ZZ[X[VYTWT
+ 74E_[O[NZNZP\P\N[MZMYNXPVUTXRZP[L[JZIXIUJSPORMSKSIRGPFNGMIMLNOPRTWWZY[[[\Y\X RKZJXJUKSLR RRMSI RSKRG RNGMK RNNPQTVWYYZ RN[LZKXKULSPO RMINMQQUVXYZZ[Z\Y
+ 11NWSFRGRM RSGRM RSFTGRM
+ 27KYUBSDQGOKNPNTOYQ]S`Ub RQHPKOOOUPYQ\ RSDRFQIPOPUQ[R^S`
+ 27KYOBQDSGUKVPVTUYS]Q`Ob RSHTKUOUUTYS\ RQDRFSITOTUS[R^Q`
+ 39JZRFQGSQRR RRFRR RRFSGQQRR RMINIVOWO RMIWO RMIMJWNWO RWIVINOMO RWIMO RWIWJMNMO
+ 16F_RIRZSZ RRISISZ RJQ[Q[R RJQJR[R
+ 24MXTZS[R[QZQYRXSXTYT\S^Q_ RRYRZSZSYRY RS[T\ RTZS^
+  8F_JQ[Q[R RJQJR[R
+ 16MXRXQYQZR[S[TZTYSXRX RRYRZSZSYRY
+  8G^[BIbJb R[B\BJb
+ 50H\QFNGLJKOKRLWNZQ[S[VZXWYRYOXJVGSFQF RNHMJLNLSMWNY RVYWWXSXNWJVH RQFOGNIMNMSNXOZQ[ RS[UZVXWSWNVIUGSF
+ 28H\QHQ[ RRHRZ RSFS[ RSFPINJ RM[W[ RQZO[ RQYP[ RSYT[ RSZU[
+ 62H\LJLKMKMJLJ RLIMINJNKMLLLKKKJLHMGPFTFWGXHYJYLXNUPPRNSLUKXK[ RWHXJXLWN RTFVGWJWLVNTPPR RKYLXNXSYWYYX RNXSZWZXY RNXS[W[XZYXYV
+ 76H\LJLKMKMJLJ RLIMINJNKMLLLKKKJLHMGPFTFWGXIXLWNTO RVGWIWLVN RSFUGVIVLUNSO RQOTOVPXRYTYWXYWZT[P[MZLYKWKVLUMUNVNWMXLX RWRXTXWWY RSOUPVQWTWWVZT[ RLVLWMWMVLV
+ 28H\SIS[ RTHTZ RUFU[ RUFJUZU RP[X[ RSZQ[ RSYR[ RUYV[ RUZW[
+ 55H\MFKPMNPMSMVNXPYSYUXXVZS[P[MZLYKWKVLUMUNVNWMXLX RWPXRXVWX RSMUNVOWRWVVYUZS[ RLVLWMWMVLV RMFWF RMGUG RMHQHUGWF
+ 69H\VIVJWJWIVI RWHVHUIUJVKWKXJXIWGUFRFOGMILKKOKULXNZQ[S[VZXXYUYTXQVOSNQNOONPMR RNIMKLOLUMXNY RWXXVXSWQ RRFPGOHNJMNMUNXOZQ[ RS[UZVYWVWSVPUOSN
+ 43H\KFKL RYFYIXLTQSSRWR[ RSRRTQWQ[ RXLSQQTPWP[R[ RKJLHNFPFUIWIXHYF RMHNGPGRH RKJLINHPHUI
+ 79H\PFMGLILLMNPOTOWNXLXIWGTFPF RNGMIMLNN RVNWLWIVG RPFOGNINLONPO RTOUNVLVIUGTF RPOMPLQKSKWLYMZP[T[WZXYYWYSXQWPTO RMQLSLWMY RWYXWXSWQ RPONPMSMWNZP[ RT[VZWWWSVPTO
+ 69H\MWMXNXNWMW RWOVQURSSQSNRLPKMKLLINGQFSFVGXIYLYRXVWXUZR[O[MZLXLWMVNVOWOXNYMY RMPLNLKMI RVHWIXLXRWVVX RQSORNQMNMKNHOGQF RSFUGVIWLWSVWUYTZR[
+ 32MXRMQNQORPSPTOTNSMRM RRNROSOSNRN RRXQYQZR[S[TZTYSXRX RRYRZSZSYRY
+ 40MXRMQNQORPSPTOTNSMRM RRNROSOSNRN RTZS[R[QZQYRXSXTYT\S^Q_ RRYRZSZSYRY RS[T\ RTZS^
+  4F^ZIJRZ[
+ 16F_JM[M[N RJMJN[N RJU[U[V RJUJV[V
+  4F^JIZRJ[
+ 52I\MKMJNJNLLLLJMHNGPFTFWGXHYJYLXNWOSQ RWHXIXMWN RTFVGWIWMVOUP RRQRTSTSQRQ RRXQYQZR[S[TZTYSXRX RRYRZSZSYRY
+ 56E`WNVLTKQKOLNMMPMSNUPVSVUUVS RQKOMNPNSOUPV RWKVSVUXVZV\T]Q]O\L[JYHWGTFQFNGLHJJILHOHRIUJWLYNZQ[T[WZYYZX RXKWSWUXV
+ 36H\RFKZ RQIW[ RRIX[ RRFY[ RMUVU RI[O[ RT[[[ RKZJ[ RKZM[ RWZU[ RWYV[ RXYZ[
+ 78G]LFL[ RMGMZ RNFN[ RIFUFXGYHZJZLYNXOUP RXHYJYLXN RUFWGXIXMWOUP RNPUPXQYRZTZWYYXZU[I[ RXRYTYWXY RUPWQXSXXWZU[ RJFLG RKFLH ROFNH RPFNG RLZJ[ RLYK[ RNYO[ RNZP[
+ 37G\XIYFYLXIVGTFQFNGLIKKJNJSKVLXNZQ[T[VZXXYV RMILKKNKSLVMX RQFOGMJLNLSMWOZQ[
+ 62G]LFL[ RMGMZ RNFN[ RIFSFVGXIYKZNZSYVXXVZS[I[ RWIXKYNYSXVWX RSFUGWJXNXSWWUZS[ RJFLG RKFLH ROFNH RPFNG RLZJ[ RLYK[ RNYO[ RNZP[
+ 83G\LFL[ RMGMZ RNFN[ RIFYFYL RNPTP RTLTT RI[Y[YU RJFLG RKFLH ROFNH RPFNG RTFYG RVFYH RWFYI RXFYL RTLSPTT RTNRPTR RTOPPTQ RLZJ[ RLYK[ RNYO[ RNZP[ RT[YZ RV[YY RW[YX RX[YU
+ 70G[LFL[ RMGMZ RNFN[ RIFYFYL RNPTP RTLTT RI[Q[ RJFLG RKFLH ROFNH RPFNG RTFYG RVFYH RWFYI RXFYL RTLSPTT RTNRPTR RTOPPTQ RLZJ[ RLYK[ RNYO[ RNZP[
+ 60G^XIYFYLXIVGTFQFNGLIKKJNJSKVLXNZQ[T[VZXZY[YS RMILKKNKSLVMX RQFOGMJLNLSMWOZQ[ RXTXY RWSWYVZ RTS\S RUSWT RVSWU RZSYU R[SYT
+ 81F^KFK[ RLGLZ RMFM[ RWFW[ RXGXZ RYFY[ RHFPF RTF\F RMPWP RH[P[ RT[\[ RIFKG RJFKH RNFMH ROFMG RUFWG RVFWH RZFYH R[FYG RKZI[ RKYJ[ RMYN[ RMZO[ RWZU[ RWYV[ RYYZ[ RYZ[[
+ 39LXQFQ[ RRGRZ RSFS[ RNFVF RN[V[ ROFQG RPFQH RTFSH RUFSG RQZO[ RQYP[ RSYT[ RSZU[
+ 45JJSFSWRZQ[ RTGTWSZ RUFUWTZQ[O[MZLXLVMUNUOVOWNXMX RMVMWNWNVMV RPFXF RQFSG RRFSH RVFUH RWFUG
+ 69F\KFK[ RLGLZ RMFM[ RXGMR RPPW[ RQPX[ RQNY[ RHFPF RUF[F RH[P[ RT[[[ RIFKG RJFKH RNFMH ROFMG RWFXG RZFXG RKZI[ RKYJ[ RMYN[ RMZO[ RWYU[ RWYZ[
+ 52I[NFN[ ROGOZ RPFP[ RKFSF RK[Z[ZU RLFNG RMFNH RQFPH RRFPG RNZL[ RNYM[ RPYQ[ RPZR[ RU[ZZ RW[ZY RX[ZX RY[ZU
+ 63E_JFJZ RJFQ[ RKFQX RLFRX RXFQ[ RXFX[ RYGYZ RZFZ[ RGFLF RXF]F RG[M[ RU[][ RHFJG R[FZH R\FZG RJZH[ RJZL[ RXZV[ RXYW[ RZY[[ RZZ\[
+ 39F^KFKZ RKFY[ RLFXX RMFYX RYGY[ RHFMF RVF\F RH[N[ RIFKG RWFYG R[FYG RKZI[ RKZM[
+ 54G]QFNGLIKKJOJRKVLXNZQ[S[VZXXYVZRZOYKXIVGSFQF RMILKKNKSLVMX RWXXVYSYNXKWI RQFOGMJLNLSMWOZQ[ RS[UZWWXSXNWJUGSF
+ 59G]LFL[ RMGMZ RNFN[ RIFUFXGYHZJZMYOXPUQNQ RXHYJYMXO RUFWGXIXNWPUQ RI[Q[ RJFLG RKFLH ROFNH RPFNG RLZJ[ RLYK[ RNYO[ RNZP[
+ 77G]QFNGLIKKJOJRKVLXNZQ[S[VZXXYVZRZOYKXIVGSFQF RMILKKNKSLVMX RWXXVYSYNXKWI RQFOGMJLNLSMWOZQ[ RS[UZWWXSXNWJUGSF RNXOVQURUTVUXV^W`Y`Z^Z\ RV\W^X_Y_ RUXW]X^Y^Z]
+ 80G]LFL[ RMGMZ RNFN[ RIFUFXGYHZJZLYNXOUPNP RXHYJYLXN RUFWGXIXMWOUP RRPTQUSWYX[Z[[Y[W RWWXYYZZZ RTQURXXYYZY[X RI[Q[ RJFLG RKFLH ROFNH RPFNG RLZJ[ RLYK[ RNYO[ RNZP[
+ 44H\XIYFYLXIVGSFPFMGKIKLLNOPURWSXUXXWZ RLLMNOOUQWRXT RMGLILKMMONUPXRYTYWXYWZT[Q[NZLXKUK[LX
+ 57H\JFJL RQFQ[ RRGRZ RSFS[ RZFZL RJFZF RN[V[ RKFJL RLFJI RMFJH ROFJG RUFZG RWFZH RXFZI RYFZL RQZO[ RQYP[ RSYT[ RSZU[
+ 45F^KFKULXNZQ[S[VZXXYUYG RLGLVMX RMFMVNYOZQ[ RHFPF RVF\F RIFKG RJFKH RNFMH ROFMG RWFYG R[FYG
+ 34H\KFR[ RLFRXR[ RMFSX RYGR[ RIFPF RUF[F RJFLH RNFMH ROFMG RWFYG RZFYG
+ 55F^JFN[ RKFNVN[ RLFOV RRFOVN[ RRFV[ RSFVVV[ RTFWV RZGWVV[ RGFOF RRFTF RWF]F RHFKG RIFKH RMFLH RNFLG RXFZG R\FZG
+ 54H\KFW[ RLFX[ RMFY[ RXGLZ RIFPF RUF[F RI[O[ RT[[[ RJFMH RNFMH ROFMG RVFXG RZFXG RLZJ[ RLZN[ RWZU[ RWYV[ RWYZ[
+ 48G]JFQQQ[ RKFRQRZ RLFSQS[ RYGSQ RHFOF RVF\F RN[V[ RIFKG RNFLG RWFYG R[FYG RQZO[ RQYP[ RSYT[ RSZU[
+ 41H\YFKFKL RWFK[ RXFL[ RYFM[ RK[Y[YU RLFKL RMFKI RNFKH RPFKG RT[YZ RV[YY RW[YX RX[YU
+ 12KYOBOb RPBPb ROBVB RObVb
+  3G]IB[b
+ 12KYTBTb RUBUb RNBUB RNbUb
+  8G]JTROZT RJTRPZT
+  3G[Gb[b
+  7LXPFUL RPFOGUL
+ 54I]NPNOOOOQMQMONNPMTMVNWOXQXXYZZ[ RVOWQWXXZ RTMUNVPVXWZZ[[[ RVRUSPTMULWLXMZP[S[UZVX RNUMWMXNZ RUSQTOUNWNXOZP[
+ 47G\LFL[MZOZ RMGMY RIFNFNZ RNPONQMSMVNXPYSYUXXVZS[Q[OZNX RWPXRXVWX RSMUNVOWRWVVYUZS[ RJFLG RKFLH
+ 34H[WQWPVPVRXRXPVNTMQMNNLPKSKULXNZQ[S[VZXX RMPLRLVMX RQMONNOMRMVNYOZQ[
+ 52H]VFV[[[ RWGWZ RSFXFX[ RVPUNSMQMNNLPKSKULXNZQ[S[UZVX RMPLRLVMX RQMONNOMRMVNYOZQ[ RTFVG RUFVH RXYY[ RXZZ[
+ 41H[MSXSXQWOVNSMQMNNLPKSKULXNZQ[S[VZXX RWRWQVO RMPLRLVMX RVSVPUNSM RQMONNOMRMVNYOZQ[
+ 40KYWHWGVGVIXIXGWFTFRGQHPKP[ RRHQKQZ RTFSGRIR[ RMMVM RM[U[ RPZN[ RPYO[ RRYS[ RRZT[
+ 89I\XNYOZNYMXMVNUO RQMONNOMQMSNUOVQWSWUVVUWSWQVOUNSMQM ROONQNSOU RUUVSVQUO RQMPNOPOTPVQW RSWTVUTUPTNSM RNUMVLXLYM[N\Q]U]X^Y_ RN[Q\U\X] RLYMZP[U[X\Y^Y_XaUbObLaK_K^L\O[ RObMaL_L^M\O[
+ 65G^LFL[ RMGMZ RIFNFN[ RNQOOPNRMUMWNXOYRY[ RWOXRXZ RUMVNWQW[ RI[Q[ RT[\[ RJFLG RKFLH RLZJ[ RLYK[ RNYO[ RNZP[ RWZU[ RWYV[ RYYZ[ RYZ[[
+ 43LXQFQHSHSFQF RRFRH RQGSG RQMQ[ RRNRZ RNMSMS[ RN[V[ ROMQN RPMQO RQZO[ RQYP[ RSYT[ RSZU[
+ 41KXRFRHTHTFRF RSFSH RRGTG RRMR^QaPb RSNS]R` ROMTMT]S`RaPbMbLaL_N_NaMaM` RPMRN RQMRO
+ 61G]LFL[ RMGMZ RIFNFN[ RWNNW RRSY[ RRTX[ RQTW[ RTM[M RI[Q[ RT[[[ RJFLG RKFLH RUMWN RZMWN RLZJ[ RLYK[ RNYO[ RNZP[ RWYU[ RVYZ[
+ 31LXQFQ[ RRGRZ RNFSFS[ RN[V[ ROFQG RPFQH RQZO[ RQYP[ RSYT[ RSZU[
+ 99AcFMF[ RGNGZ RCMHMH[ RHQIOJNLMOMQNROSRS[ RQORRRZ ROMPNQQQ[ RSQTOUNWMZM\N]O^R^[ R\O]R]Z RZM[N\Q\[ RC[K[ RN[V[ RY[a[ RDMFN REMFO RFZD[ RFYE[ RHYI[ RHZJ[ RQZO[ RQYP[ RSYT[ RSZU[ R\ZZ[ R\Y[[ R^Y_[ R^Z`[
+ 65G^LML[ RMNMZ RIMNMN[ RNQOOPNRMUMWNXOYRY[ RWOXRXZ RUMVNWQW[ RI[Q[ RT[\[ RJMLN RKMLO RLZJ[ RLYK[ RNYO[ RNZP[ RWZU[ RWYV[ RYYZ[ RYZ[[
+ 46H\QMNNLPKSKULXNZQ[S[VZXXYUYSXPVNSMQM RMPLRLVMX RWXXVXRWP RQMONNOMRMVNYOZQ[ RS[UZVYWVWRVOUNSM
+ 60G\LMLb RMNMa RIMNMNb RNPONQMSMVNXPYSYUXXVZS[Q[OZNX RWPXRXVWX RSMUNVOWRWVVYUZS[ RIbQb RJMLN RKMLO RLaJb RL`Kb RN`Ob RNaPb
+ 55H\VNVb RWOWa RUNWNXMXb RVPUNSMQMNNLPKSKULXNZQ[S[UZVX RMPLRLVMX RQMONNOMRMVNYOZQ[ RSb[b RVaTb RV`Ub RX`Yb RXaZb
+ 43IZNMN[ RONOZ RKMPMP[ RWOWNVNVPXPXNWMUMSNQPPS RK[S[ RLMNN RMMNO RNZL[ RNYM[ RPYQ[ RPZR[
+ 43J[WOXMXQWOVNTMPMNNMOMQNSPTUUWVXY RNNMQ RNRPSUTWU RXVWZ RMONQPRUSWTXVXYWZU[Q[OZNYMWM[NY
+ 22KZPHPVQYRZT[V[XZYX RQHQWRY RPHRFRWSZT[ RMMVM
+ 43G^LMLVMYNZP[S[UZVYWW RMNMWNY RIMNMNWOZP[ RWMW[\[ RXNXZ RTMYMY[ RJMLN RKMLO RYYZ[ RYZ[[
+ 31I[LMR[ RMMRY RNMSY RXNSYR[ RJMQM RTMZM RKMNO RPMNN RVMXN RYMXN
+ 45F^JMN[ RKMNX RLMOX RRMOXN[ RRMV[ RSMVX RRMTMWX RZNWXV[ RGMOM RWM]M RHMKN RNMLN RXMZN R\MZN
+ 48H\LMV[ RMMW[ RNMX[ RWNMZ RJMQM RTMZM RJ[P[ RS[Z[ RKMMN RPMNN RUMWN RYMWN RMZK[ RMZO[ RVZT[ RWZY[
+ 40H[LMR[ RMMRY RNMSY RXNSYP_NaLbJbIaI_K_KaJaJ` RJMQM RTMZM RKMNO RPMNN RVMXN RYMXN
+ 41I[VML[ RWMM[ RXMN[ RXMLMLQ RL[X[XW RMMLQ RNMLP ROMLO RQMLN RS[XZ RU[XY RV[XX RW[XW
+ 40KYTBRCQDPFPHQJRKSMSOQQ RRCQEQGRISJTLTNSPORSTTVTXSZR[Q]Q_Ra RQSSUSWRYQZP\P^Q`RaTb
+  3NVRBRb
+ 40KYPBRCSDTFTHSJRKQMQOSQ RRCSESGRIQJPLPNQPURQTPVPXQZR[S]S_Ra RSSQUQWRYSZT\T^S`RaPb
+ 24F^IUISJPLONOPPTSVTXTZS[Q RISJQLPNPPQTTVUXUZT[Q[O
+
\ No newline at end of file
diff --git a/data/hires b/data/hires
new file mode 100644
index 0000000..bbea60c
Binary files /dev/null and b/data/hires differ
diff --git a/data/lowres b/data/lowres
new file mode 100644
index 0000000..afdcf58
Binary files /dev/null and b/data/lowres differ
diff --git a/data/mres b/data/mres
new file mode 100644
index 0000000..9395146
Binary files /dev/null and b/data/mres differ
diff --git a/data/tables/B2L-058-000-B b/data/tables/B2L-058-000-B
new file mode 100644
index 0000000..53e3d1d
--- /dev/null
+++ b/data/tables/B2L-058-000-B
@@ -0,0 +1,911 @@
+#
+# SCCS KEYWORDS: @(#)B2L-058-000-B	1.2 08/13/99
+#
+# B2L-058-000-B - Special local BUFR Table B for center 058 (FNMOC) for those
+# cases when an FNOC-generated BUFR message uses local descriptors but has a
+# value of 0 in Section 1, Octet 12 (thus indicating that it does not use
+# local descriptors).
+#
+# <<Change Notice>> v1.2 25 Aug 1999 -- Laws,D.J.
+#   WMO bufr table B ver 1998.
+#
+#                                       Data
+#F      X       Y       Scale   RefVal  Width   Units   Element Name
+  0;    0;     1;    0;           0;   24;    CCITT_IA5; Table A: entry
+  0;    0;     2;    0;           0;  256;    CCITT_IA5; Table A: data category description, line 1
+  0;    0;     3;    0;           0;  256;    CCITT_IA5; Table A: data category description, line 2
+  0;    0;     5;    0;           0;   24;    CCITT_IA5; BUFR edition number
+  0;    0;    10;    0;           0;    8;    CCITT_IA5; F descriptor to be added or defined
+  0;    0;    11;    0;           0;   16;    CCITT_IA5; X descriptor to be added or defined
+  0;    0;    12;    0;           0;   24;    CCITT_IA5; Y descriptor to be added or defined
+  0;    0;    13;    0;           0;  256;    CCITT_IA5; Element name, line 1
+  0;    0;    14;    0;           0;  256;    CCITT_IA5; Element name, line 2
+  0;    0;    15;    0;           0;  192;    CCITT_IA5; Units name
+  0;    0;    16;    0;           0;    8;    CCITT_IA5; Units scale sign
+  0;    0;    17;    0;           0;   24;    CCITT_IA5; Units scale
+  0;    0;    18;    0;           0;    8;    CCITT_IA5; Units reference sign
+  0;    0;    19;    0;           0;   80;    CCITT_IA5; Units reference value
+  0;    0;    20;    0;           0;   24;    CCITT_IA5; Element data width
+  0;    0;    30;    0;           0;   40;    CCITT_IA5; Descriptor defining sequence
+  0;    1;     1;    0;           0;    7;      numeric; WMO block number (II)
+  0;    1;     2;    0;           0;   10;      numeric; WMO station number (iii)
+  0;    1;     3;    0;           0;    3;   code_table; WMO region number
+  0;    1;     4;    0;           0;    3;      numeric; WMO region sub-area
+  0;    1;     5;    0;           0;   17;      numeric; Buoy/platform identifier
+  0;    1;     6;    0;           0;   64;    CCITT_IA5; Aircraft identifier (I2I2I2)
+  0;    1;     7;    0;           0;   10;   code_table; Satellite identifier (I2I2I2)
+  0;    1;     8;    0;           0;   64;    CCITT_IA5; Aircraft registration number (tail number)
+  0;    1;     9;    0;           0;   64;    CCITT_IA5; Type of commerical aircraft
+  0;    1;    10;    0;           0;   64;    CCITT_IA5; Stationary buoy platform identifier
+  0;    1;    11;    0;           0;   72;    CCITT_IA5; Ship or mobile land station identifier (D...D)
+  0;    1;    12;    0;           0;    9;     deg_true; Direction of motion of moving observing platform
+  0;    1;    13;    0;           0;   10;          m/s; Speed of motion of moving observing platform
+  0;    1;    14;    2;           0;   10;          m/s; Platform drift speed (high precision) (VBVB)
+  0;    1;    15;    0;           0;  160;    CCITT_IA5; Station or site name
+  0;    1;    20;    0;           0;    4;      numeric; WMO Region sub-area
+  0;    1;    21;    0;           0;   14;      numeric; Synoptic feature identifier
+  0;    1;    25;    0;           0;   24;    CCITT_IA5; Storm identifier
+  0;    1;    26;    0;           0;   64;    CCITT_IA5; WMO storm name
+  0;    1;    31;    0;           0;   16;   code_table; Generating center
+  0;    1;    32;    0;           0;    8;   code_table; Generating application
+  0;    1;    33;    0;           0;    8;   code_table; Generating center
+  0;    1;    34;    0;           0;    8;   code_table; Generating sub-center
+  0;    1;    41;    5; -1073741824;   31;          m/s; Absolute platform velocity - first component
+  0;    1;    42;    5; -1073741824;   31;          m/s; Absolute platform velocity - second component
+  0;    1;    43;    5; -1073741824;   31;          m/s; Absolute platform velocity - third component
+  0;    1;    60;    0;           0;   64;    CCITT_IA5; Aircraft reporting point (Beacon identifier)
+  0;    1;    63;    0;           0;   64;    CCITT_IA5; ICAO location indicator (CCCC)
+  0;    1;    64;    0;           0;   32;    CCITT_IA5; Runway designator
+  0;    1;    75;    0;           0;   40;    CCITT_IA5; Tide station identification
+  0;    1;   192;    0;           0;   24;    CCITT_IA5; Receiving circuit
+  0;    1;   193;    0;           0;    4;   code_table; Global octant
+  0;    1;   194;    0;           0;    4;      numeric; Beam position
+  0;    1;   195;    0;           0;    4;      numeric; Decimal point value (dp)
+  0;    1;   196;    0;           0;   64;    CCITT_IA5; Observation number
+  0;    1;   197;    0;           0;    6;      numeric; Runway number
+  0;    1;   198;    0;           0;   10;   code_table; Marsden square number
+  0;    1;   199;    0;           0;   64;    CCITT_IA5; nature of mission
+  0;    1;   200;    0;           0;    2;   code_table; Radar Capability indicator (XXX)
+  0;    1;   201;    0;           0;    8;   code_table; Country or agency that operates the satellite
+  0;    1;   203;    0;           0;   16;    CCITT_IA5; Satellite name
+  0;    1;   204;    0;           0;   16;    CCITT_IA5; Satellite series
+  0;    1;   206;    0;           0;   32;    CCITT_IA5; TOVS generating center name
+  0;    1;   207;    0;           0;   72;    CCITT_IA5; File name
+  0;    1;   208;    0;           0;    4;   code_table; Satellite data type
+  0;    1;   209;    0;           0;    8;   code_table; Observation type for MCSST
+  0;    1;   210;    0;           0;    7;   code_table; Observation source
+  0;    1;   211;    0;           0;    5;      numeric; Beam position
+  0;    1;   212;    0;           0;   24;      numeric; Data processing block number
+  0;    1;   213;    0;           0;    3;   code_table; Tip source type identifier
+  0;    1;   214;    0;           0;   32;    CCITT_IA5; Header originator
+  0;    1;   215;    0;           0;   48;    CCITT_IA5; Bulletin header update or correction indicator
+  0;    1;   216;    0;           0;   14;      numeric; Engineering status
+  0;    1;   217;    0;           0;    5;      numeric; Satellite number
+  0;    1;   218;    0;           0;  176;    CCITT_IA5; Sequence (report) type
+  0;    1;   219;    0;           0;   40;    CCITT_IA5; Mission number
+  0;    1;   220;    0;           0;    7;      numeric; Observation number
+  0;    1;   221;    0;           0;    8;   code_table; Surface type
+  0;    1;   222;    0;           0;   32;    CCITT_IA5; Report modifier
+  0;    1;   223;    0;           0;    3;   code_table; Runway parallel indicator
+  0;    1;   224;    0;           0;    5;   code_table; Terrain code identifier
+  0;    2;     1;    0;           0;    2;   code_table; Type of station (ix)
+  0;    2;     2;    0;           0;    4;   flag_table; Type of instrumentation for wind measurement (ewew)
+  0;    2;     3;    0;           0;    4;   code_table; Type of measuring instrumentation used (a4, I3,
+  0;    2;     4;    0;           0;    4;   code_table; Type of instrumentation for evaporation measurement or
+  0;    2;     5;    2;           0;    7;        deg_K; Precision of temperature observed (s3)
+  0;    2;    11;    0;           0;    8;   code_table; Radiosonde type (rara)
+  0;    2;    12;    0;           0;    4;   code_table; Radiosonde computational method
+  0;    2;    13;    0;           0;    4;   code_table; Solar and infrared radiation correction (Sr)
+  0;    2;    14;    0;           0;    7;   code_table; Tracking technique/status of system (sasa)
+  0;    2;    15;    0;           0;    4;   code_table; Radiosonde completeness
+  0;    2;    20;    0;           0;    9;   code_table; satellite classification
+  0;    2;    21;    0;           0;    9;   flag_table; Satellite instrumentation data used in processing
+  0;    2;    22;    0;           0;    8;   flag_table; Satellite data processing technique used
+  0;    2;    23;    0;           0;    4;   code_table; Cloud motion computational method
+  0;    2;    24;    0;           0;    4;   code_table; Integrated mean humidity computational method
+  0;    2;    25;    0;           0;   25;   flag_table; Satellite channel(s) used in computation
+  0;    2;    26;    2;           0;   12;            m; Cross track resolution
+  0;    2;    27;    2;           0;   12;            m; Along track resolution
+  0;    2;    28;    0;           0;   18;            m; segment size at nadir in X direction
+  0;    2;    29;    0;           0;   18;            m; segment size at nadir in Y direction
+  0;    2;    30;    0;           0;    3;   code_table; Method of current measurement (k5)
+  0;    2;    31;    0;           0;    5;   code_table; Duration and time of current measurement
+  0;    2;    32;    0;           0;    2;   code_table; Indicator for digitization (k1)
+  0;    2;    33;    0;           0;    3;   code_table; Method of salinity/depth measurement (k2)
+  0;    2;    34;    0;           0;    5;   code_table; Drogue type (id)
+  0;    2;    35;    0;           0;    9;            m; Cable length (ZdZdZd)
+  0;    2;    36;    0;           0;    2;   code_table; Buoy type (Ip or Vi...Vi)
+  0;    2;    37;    0;           0;    3;   code_table; Method of tidal observation
+  0;    2;    38;    0;           0;    4;   code_table; Sea surface temperature method indicator
+  0;    2;    39;    0;           0;    3;   code_table; Wet bulb temperature method indicator
+  0;    2;    40;    0;           0;    4;   code_table; Method of removing velocity and motion table
+  0;    2;    41;    0;           0;    6;   code_table; Method for estimating reports related to synoptic
+  0;    2;    44;    0;           0;    4;   code_table; Spectral calculation method (Im)
+  0;    2;    45;    0;           0;    4;   code_table; Platform type (Ip)
+  0;    2;    46;    0;           0;    4;   code_table; Wave measurement instrument (no symbol letters)
+  0;    2;    48;    0;           0;    4;   code_table; Satellite sensor indicator
+  0;    2;    49;    0;           0;    8;   flag_table; Geostationary satellite data-processing technique used
+  0;    2;    50;    0;           0;   20;   flag_table; Geostationary sounder satellite channels used
+  0;    2;    51;    0;           0;    4;   code_table; Indicator to specify observing method for extreme
+  0;    2;    52;    0;           0;    6;   flag_table; Geostationary imager satellite channels used
+  0;    2;    53;    0;           0;    4;   code_table; GOES-I/M brightness temperature CCITT_IA5istics
+  0;    2;    54;    0;           0;    4;   code_table; GOES-I/M soundings parameter CCITT_IA5istics
+  0;    2;    55;    0;           0;    4;   code_table; Geostationary_soundings statistical parameters
+  0;    2;    56;    0;           0;    4;   code_table; Geostationary soundings accuracy statistics
+  0;    2;    57;    0;           0;    4;   code_table; Origin of first guess information for GOES-I/M
+  0;    2;    58;    0;           0;    4;   code_table; Valid times of first guess information for
+  0;    2;    59;    0;           0;    4;   code_table; Origin of analysis information for GOES-I/M soundings
+  0;    2;    60;    0;           0;    4;   code_table; Origin of surface information for GOES-I/M soundings
+  0;    2;    61;    0;           0;    3;   code_table; Aircraft navigation system (s1)
+  0;    2;    62;    0;           0;    4;   code_table; Type of aircraft data relay system
+  0;    2;    63;    2;      -18000;   16;          deg; Aircraft roll angle
+  0;    2;    64;    0;           0;    2;   code_table; Roll angle quality
+  0;    2;    65;    0;           0;   40;    CCITT_IA5; ACARS ground receiving station
+  0;    2;    70;    0;           0;    4;   code_table; Original specification of latitude/longitude
+  0;    2;   100;    1;           0;   12;           dB; Radar constant
+  0;    2;   101;    0;           0;    4;   code_table; Type of antenna
+  0;    2;   102;    0;           0;    8;            m; Antenna height above tower
+  0;    2;   103;    0;           0;    2;   flag_table; Radome
+  0;    2;   104;    0;           0;    4;   code_table; Antenna polarisation
+  0;    2;   105;    0;           0;    6;           dB; Maximum antenna gain
+  0;    2;   106;    1;           0;    6;          deg; 3-dB bandwidth
+  0;    2;   107;    0;           0;    6;           dB; Sidelobe suppression
+  0;    2;   108;    0;           0;    6;           dB; Crosspol discrimination (on axis)
+  0;    2;   109;    2;           0;   12;        deg/s; Antenna speed (azimuth)
+  0;    2;   110;    2;           0;   12;        deg/s; Antenna speed (elevation)
+  0;    2;   111;    1;           0;   10;          deg; Radar incidence angle
+  0;    2;   112;    1;           0;   12;          deg; Radar azimuth angle
+  0;    2;   113;    0;           0;    4;      numeric; Number of azimuth looks
+  0;    2;   114;    0;           0;   15;         m**2; Antenna effective surface area
+  0;    2;   121;   -8;           0;    7;           Hz; Mean frequency
+  0;    2;   122;   -6;        -128;    8;           Hz; Frequency agility range
+  0;    2;   123;   -4;           0;    7;            W; Peak power
+  0;    2;   124;   -1;           0;    7;            W; Average power
+  0;    2;   125;   -1;           0;    8;           Hz; Pulse repetition frequency
+  0;    2;   126;    7;           0;    6;            s; Pulse width
+  0;    2;   127;   -6;           0;    7;           Hz; Receiver intermediate frequency
+  0;    2;   128;   -5;           0;    6;           Hz; Intermediate frequency bandwidth
+  0;    2;   129;    0;        -150;    5;           dB; Minimum detectable signal
+  0;    2;   130;    0;           0;    7;           dB; Dynamic range
+  0;    2;   131;    0;           0;    2;   flag_table; Sensitivity time control (STC)
+  0;    2;   132;    2;           0;    6;          deg; Azimuth pointing accuracy
+  0;    2;   133;    2;           0;    6;          deg; Elevation pointing accuracy
+  0;    2;   134;    2;           0;   16;          deg; Antenna beam azimuth
+  0;    2;   135;    2;       -9000;   15;          deg; Antenna elevation
+  0;    2;   136;   -3;           0;   16;            m; Range processed by range attenuation correction
+  0;    2;   140;    0;           0;    9;          deg; Satellite radar beam azimuth angle
+  0;    2;   141;    0;           0;   24;    CCITT_IA5; Measurement type serial number/identifier
+  0;    2;   142;    0;           0;   32;    CCITT_IA5; Ozone instrument
+  0;    2;   143;    0;           0;    7;   code_table; Ozone instrument type
+  0;    2;   144;    0;           0;    4;   code_table; Measurement type for Brewer instruments
+  0;    2;   145;    0;           0;    4;   code_table; Wave length setting for Dobson instruments
+  0;    2;   146;    0;           0;    4;   code_table; Source conditions for Dobson instruments
+  0;    2;   152;    0;           0;   31;   flag_table; satellite instrument used in data processing
+  0;    2;   153;   -8;           0;   26;           Hz; satellite channel centre frequency
+  0;    2;   154;   -8;           0;   26;           Hz; satellite channel band width
+  0;    2;   163;    0;           0;    4;   code_table; height assignment method
+  0;    2;   164;    0;           0;    3;   code_table; tracer correlation method
+  0;    2;   167;    0;           0;    4;   code_table; radiance computational method
+  0;    2;   190;    0;           0;    8;   code_table; U, v quality indicator
+  0;    2;   191;    0;           0;    4;   code_table; W quality indicator
+  0;    2;   192;    0;           0;    2;   code_table; Wind units source ID
+  0;    2;   193;    0;           0;   20;      numeric; satellite channels used in computation
+  0;    2;   194;    0;           0;   15;      numeric; satellite channels used in computation
+  0;    2;   195;    0;           0;    4;   code_table; Reason for no report OR ground equipment
+  0;    2;   196;    0;           0;    7;   code_table; Type of thermodynamic sensing equipment (eTeT)
+  0;    2;   197;    0;           0;    3;   code_table; Correction technique (cT, cw)
+  0;    2;   198;    0;           0;    4;   code_table; Data reduction method (mr)
+  0;    2;   199;    0;           0;    4;      numeric; grp_pos_ind
+  0;    2;   200;    0;           0;    3;   code_table; Indicator for frequency or wave number (Ia)
+  0;    2;   201;    0;           0;    3;   code_table; Type of rocket motor (rm)
+  0;    2;   202;    0;           0;    7;   code_table; Type of wind sensing equipment (ewew)
+  0;    2;   203;    0;           0;    3;   code_table; Method of determining direction of moving platform
+  0;    2;   204;    0;           0;    3;   code_table; Method of determining speed of moving platform
+  0;    2;   205;    0;           0;    3;   code_table; Ozone flag
+  0;    2;   206;    0;           0;    4;   code_table; Algorithm identifier
+  0;    2;   207;    0;           0;    5;   code_table; Equation identifier
+  0;    2;   208;    0;           0;    2;   code_table; Type of method for measuring pressure
+  0;    2;   209;    0;           0;   10;   code_table; Xbt instrument type (IxIxIx)
+  0;    2;   210;    0;           0;    7;   code_table; Recorder type (XRXR)
+  0;    2;   211;    0;           0;    8;   flag_table; Sensor status flag
+  0;    2;   212;    0;           0;    2;   flag_table; Maintenance Check flag
+  0;    2;   213;    0;           0;    5;      numeric; satellite channels used in computation
+  0;    4;     1;    0;           0;   12;           yr; Year (4-digit)
+  0;    4;     2;    0;           0;    4;           mo; Month
+  0;    4;     3;    0;           0;    6;          day; Day
+  0;    4;     4;    0;           0;    5;           hr; Hour
+  0;    4;     5;    0;           0;    6;          min; Minute
+  0;    4;     6;    0;           0;    6;            s; Second
+  0;    4;    11;    0;       -1024;   11;           yr; Time increment - year
+  0;    4;    12;    0;       -1024;   11;           mo; Time increment - month
+  0;    4;    13;    0;       -1024;   11;          day; Time increment - day
+  0;    4;    14;    0;       -1024;   11;           hr; Time increment - hour
+  0;    4;    15;    0;       -2048;   12;          min; Time increment - minutes
+  0;    4;    16;    0;       -4096;   13;            s; Time increment - seconds
+  0;    4;    21;    0;       -1024;   11;           yr; Time period or displacement - year
+  0;    4;    22;    0;       -1024;   11;           mo; Time period or displacement - month
+  0;    4;    23;    0;       -1024;   11;          day; Time period or displacement - month
+  0;    4;    24;    0;       -2048;   12;           hr; Time period or displacement - hour
+  0;    4;    25;    0;       -2048;   12;          min; Time period or displacement - minutes
+  0;    4;    26;    0;       -4096;   13;            s; Time period or displacement - seconds
+  0;    4;    31;    0;           0;    8;           hr; Duration of time relating to following value
+  0;    4;    32;    0;           0;    6;          min; Duration of time relating to following value
+  0;    4;    41;    0;       -1440;   12;          min; Time difference, UTC - LMT
+  0;    4;    43;    0;           0;    9;          day; Day of the year
+  0;    4;    53;    0;           0;    6;      numeric; Number of days with precipitation equal or
+  0;    4;   192;    0;           0;    4;   code_table; Precipitation time period (tR)
+  0;    4;   193;    0;           0;   31;      numeric; Last time that this observation record was
+  0;    4;   200;    0;           0;   12;           yr; Time of receipt - year
+  0;    4;   201;    0;           0;    4;           mo; Time of receipt - month
+  0;    4;   202;    0;           0;    6;          day; Time of receipt - day
+  0;    4;   203;    0;           0;    5;           hr; Time of receipt - hour
+  0;    4;   204;    0;           0;    6;          min; Time of receipt - minute
+  0;    4;   206;    3;           0;   27;            s; GMT seconds
+  0;    5;     1;    5;    -9000000;   25;          deg; Latitude (high accuracy)
+  0;    5;     2;    2;       -9000;   15;          deg; Latitude (coarse accuracy) (La...La)
+  0;    5;    11;    5;    -9000000;   25;          deg; Latitude increment (high accuracy)
+  0;    5;    12;    2;       -9000;   15;          deg; Latitude increment (coarse accuracy)
+  0;    5;    21;    2;           0;   16;     deg_true; Bearing or azimuth
+  0;    5;    22;    2;           0;   16;     deg_true; Solar azimuth
+  0;    5;    30;    0;           0;   12;          deg; Direction (spectral)
+  0;    5;    31;    0;           0;   12;      numeric; Row number
+  0;    5;    33;   -1;           0;   16;            m; Pixel size on horizontal - 1
+  0;    5;    40;    0;           0;   24;      numeric; Orbit number
+  0;    5;    41;    0;           0;    8;      numeric; Scan line number
+  0;    5;    42;    0;           0;    6;      numeric; Channel number
+  0;    5;    43;    0;           0;    8;      numeric; Field of view number
+  0;    5;    52;    0;           0;    5;      numeric; Channel number increment
+  0;    5;    53;    0;           0;    5;      numeric; Field of view number increment
+  0;    5;   192;    0;           0;    3;      numeric; Image line number
+  0;    5;   193;    0;           0;    4;      numeric; Image sample number
+  0;    5;   194;    0;           0;   14;      numeric; Orbit number
+  0;    5;   195;    6;   -90000000;   28;          deg; six decimal pt latitude
+  0;    5;   196;    0;           0;   16;      numeric; Orbit number
+  0;    5;   197;    0;           0;    8;      numeric; Frame number
+  0;    5;   198;    0;           0;   24;      numeric; Orbit number
+  0;    5;   199;    0;           0;   20;      numeric; Orbit number
+  0;    6;     1;    5;   -18000000;   26;          deg; Longtiude (high accuracy)
+  0;    6;     2;    2;      -18000;   16;          deg; Longtiude (coarse accuracy) (Lo...Lo)
+  0;    6;     3;    2;      -18000;   16;          deg; Alternate longtiude
+  0;    6;    11;    5;   -18000000;   26;          deg; Longtiude increment (high accuracy)
+  0;    6;    12;    2;      -18000;   16;          deg; Longtiude increment (coarse accuracy)
+  0;    6;    21;   -1;           0;   13;            m; Distance
+  0;    6;    30;    5;           0;   13;        rad/m; Wavenumber (spectral)
+  0;    6;    31;    0;           0;   12;      numeric; Column number
+  0;    6;    33;   -1;           0;   16;            m; Pixel size on horizontal - 2
+  0;    6;   192;    6;  -180000000;   29;          deg; six decimal pt longitude
+  0;    7;     1;    0;        -400;   15;            m; Height of station (hohohoho)
+  0;    7;     2;   -1;         -40;   16;            m; Height or altitude (hahaha, hIhIhI, HmHmHm, HH,
+  0;    7;     3;   -1;        -400;   17;    m**2/s**2; Geopotential
+  0;    7;     4;   -1;           0;   14;           Pa; Pressure (Pa...Pa, Paob...Paob, Po...Po, PtPtPt, or PAPA)
+  0;    7;     5;    0;        -400;   12;            m; Height increment
+  0;    7;     6;    0;           0;   15;            m; Height above station
+  0;    7;     7;    0;       -1000;   17;            m; Height
+  0;    7;     8;    0;      -10000;   20;    m**2/s**2; Geopotential
+  0;    7;    21;    2;       -9000;   15;          deg; Elevation
+  0;    7;    22;    2;       -9000;   15;          deg; Solar elevation
+  0;    7;    24;    2;       -9000;   15;          deg; Satellite zenith angle
+  0;    7;    61;    2;           0;   14;            m; Depth below land surface
+  0;    7;    62;    1;           0;   17;            m; Depth below sea surface
+  0;    7;   190;    0;           0;   12;            m; Height increment
+  0;    7;   192;    2;           0;   13;          deg; Local zenith angle
+  0;    7;   196;    0;           0;    4;   code_table; Station height precision
+  0;    7;   197;    1;           0;   11;          deg; Solar zenith angle
+  0;    7;   198;    2;       -6000;   14;          deg; Satellite zenith angle
+  0;    7;   199;    1;           0;   11;          deg; Solar azimuth angle
+  0;    7;   200;    2;           0;   17;           Pa; Geopotential height
+  0;    7;   223;    2;           0;   14;          deg; Solar zenith angle
+  0;    7;   224;    1;           0;   14;            m; Surface elevation
+  0;    8;     1;    0;           0;    7;   flag_table; Vertical sounding significance
+  0;    8;     2;    0;           0;    6;   code_table; Vertical significance (surface observations)
+  0;    8;     3;    0;           0;    6;   code_table; Vertical significance (satellite observations)
+  0;    8;     4;    0;           0;    3;   code_table; Phase of aircraft flight (ipipip)
+  0;    8;     5;    0;           0;    4;   code_table; Surface synoptic features significance
+  0;    8;    11;    0;           0;    6;   code_table; Horizontal significance
+  0;    8;    12;    0;           0;    2;   code_table; land/sea qualifier
+  0;    8;    13;    0;           0;    2;   code_table; Day/night qualifier
+  0;    8;    14;    0;           0;    4;   code_table; Qualification for runway visual range
+  0;    8;    16;    0;           0;    3;   code_table; Change indicator of a trend-type forecast or
+  0;    8;    17;    0;           0;    2;   code_table; Qualifier of the time when the forecast
+  0;    8;    20;    0;           0;   16;      numeric; Qualification for runway visual range
+  0;    8;    21;    0;           0;    5;   code_table; Time significance
+  0;    8;    22;    0;           0;   16;      numeric; Total number (with respect to accumulation or
+  0;    8;    23;    0;           0;    6;   code_table; First order statistics
+  0;    8;    24;    0;           0;    6;   code_table; Difference statistics
+  0;    8;    25;    0;           0;    4;   code_table; Time difference qualifier
+  0;    8;    30;    0;           0;   13;      numeric; Manual on Codes (Volume I.1, Section C)
+  0;    8;    51;    0;           0;    3;   code_table; Qualifier for number of missing values in
+  0;    8;    52;    0;           0;    5;   code_table; Condition for which number of days of
+  0;    8;    53;    0;           0;    2;   code_table; Day of occurrence qualifier
+  0;    8;   194;    0;           0;    4;   code_table; Flight condition (fc)
+  0;   10;     1;    0;        -400;   15;            m; Height of land surface
+  0;   10;     2;   -1;         -40;   16;            m; Height (HHH)
+  0;   10;     3;   -1;        -400;   17;    m**2/s**2; Geopotential
+  0;   10;     4;   -1;           0;   14;           Pa; Pressure
+  0;   10;     7;    0;       -1000;   17;            m; Height
+  0;   10;     8;    0;      -10000;   20;    m**2/s**2; Geopotential
+  0;   10;    31;    2; -1073741824;   31;    deg_K*m/s; In direction of the North Pole, distance
+  0;   10;    50;    2;           0;   16;            m; Standard deviation altitude
+  0;   10;    51;   -1;           0;   14;           Pa; Pressure reduced to mean sea level (PPPP)
+  0;   10;    52;   -1;           0;   14;           Pa; Altimeter setting (QNH) (PH...PH)
+  0;   10;    60;   -1;       -1024;   11;           Pa; Pressure change (ppp)
+  0;   10;    61;   -1;        -500;   10;           Pa; 3 hour pressure change
+  0;   10;    62;   -1;       -1000;   11;           Pa; 24 hour pressure change
+  0;   10;    63;    0;           0;    4;   code_table; Characteristic of pressure tendency (a, w, or
+  0;   10;    70;    0;        -400;   16;            m; Indicated aircraft altitude
+  0;   10;   197;    0;           0;    4;   code_table; Index pertaining to geopotential height (j)
+  0;   10;   199;    0;       -1024;   16;            m; Geopotential height difference
+  0;   10;   200;    0;       -1024;   16;            m; Geopotental height correction
+  0;   10;   201;    0;           0;   14;   code_table; Pressure tendency QC ID
+  0;   10;   203;    0;           0;    4;   code_table; Geopotential height quality control flag
+  0;   10;   213;    0;       -1024;   16;            m; Geopotential height
+  0;   10;   224;    0;           0;    4;   code_table; Station level pressure QC ID
+  0;   10;   251;    0;           0;    4;   code_table; Mean sea level pressure QC ID
+  0;   11;     1;    0;           0;    9;     deg_true; Wind direction (dd, dodo>dndn, dmagdmag)
+  0;   11;     2;    1;           0;   12;          m/s; Wind speed (ff, fff, or fofofo>fnfnfn)
+  0;   11;     3;    1;       -4096;   13;          m/s; U-component
+  0;   11;     4;    1;       -4096;   13;          m/s; V-component
+  0;   11;     5;    1;        -512;   10;         Pa/s; W-component
+  0;   11;     6;    2;       -4096;   13;          m/s; W-component
+  0;   11;    11;    0;           0;    9;     deg_true; Wind direction at 10 m
+  0;   11;    12;    1;           0;   12;          m/s; Wind speed at 10 m
+  0;   11;    13;    0;           0;    9;     deg_true; Wind direction at 5 m
+  0;   11;    14;    1;           0;   12;          m/s; Wind speed at 5 m
+  0;   11;    16;    0;           0;    9;     deg_true; Extreme counterclockwise wind direction of a variable
+  0;   11;    17;    0;           0;    9;     deg_true; Extreme clockwise wind direction of a variable
+  0;   11;    21;    9;      -65536;   17;          1/s; Relative vorticity
+  0;   11;    22;    9;      -65536;   17;          1/s; Divergence
+  0;   11;    23;   -2;      -65536;   17;       m**2/s; Velocity potential
+  0;   11;    31;    0;           0;    4;   code_table; Degree of turbulence (B...B or BA)
+  0;   11;    32;   -1;         -40;   16;            m; Height of base of turbulence (BabBabBab or
+  0;   11;    33;   -1;         -40;   16;            m; Height of top of turbulence (BatBatBat or
+  0;   11;    34;    1;       -1024;   11;          m/s; Vertical gust velocity
+  0;   11;    35;    2;       -8192;   14;       m/s**2; Vertical gust acceleration
+  0;   11;    36;    1;           0;   10;          m/s; Maximum derived equivalent vertical gust
+  0;   11;    41;    1;           0;   12;          m/s; Maximum wind speed (gusts) (fm...fm)
+  0;   11;    42;    1;           0;   12;          m/s; Maximum wind speed (10 minute mean wind)
+  0;   11;    43;    0;           0;    9;     deg_true; Maximum wind gust direction
+  0;   11;    44;    0;           0;    9;     deg_true; Mean wind direction for surface -- 1500
+  0;   11;    45;    1;           0;   12;          m/s; Mean wind speed for surface -- 1500
+  0;   11;    49;    0;           0;    9;     deg_true; Standard deviation of wind direction
+  0;   11;    50;    1;           0;   12;          m/s; Standard deviation horizontal wind speed
+  0;   11;    51;    1;           0;    8;          m/s; Standard deviation vertical wind component
+  0;   11;    61;    1;           0;   12;          m/s; Absolute wind shear (1 kilometer layer below)
+  0;   11;    62;    1;           0;   12;          m/s; Absolute wind shear (1 kilometer layer above)
+  0;   11;    70;    0;           0;   32;    CCITT_IA5; Designator of the runway affected by wind
+  0;   11;    71;    3;        -128;   14;    m**2/s**2; Turbulent vertical momentum flux
+  0;   11;    72;    3;        -128;   11;         km/s; Turbulent vertical buoyancy flux
+  0;   11;    73;    2;       -1024;   13;    m**2/s**2; Turbulent kinetic energy
+  0;   11;    74;    2;       -1024;   10;    m**2/s**2; Dissipitation energy
+  0;   11;    75;    2;           0;    8;   (m**2/3)/s; Mean turbulence intensity
+  0;   11;    76;    2;           0;    8;   (m**2/3)/s; Peak turbulence intensity
+  0;   11;   195;    0;           0;    2;   code_table; Wind type at flight altitude (dt)
+  0;   11;   200;    0;           0;    4;   code_table; Wind QC ID
+  0;   11;   203;    1;       -4096;   13;          m/s; Wind u-component difference
+  0;   11;   204;    1;       -4096;   13;          m/s; Wind v-component difference
+  0;   11;   205;    0;           0;    4;   code_table; Turbulence (B) (WMO code table 0300)
+  0;   11;   206;    0;           0;    2;   code_table; Flight level wind method (da)
+  0;   11;   207;    0;           0;    2;   code_table; Extreme wind speed ID
+  0;   11;   213;    1;       -4096;   13;          m/s; Wind u-component correction
+  0;   11;   214;    1;       -4096;   13;          m/s; Wind v-component correction
+  0;   11;   244;    0;           0;   16;     deg_true; Direction of wind
+  0;   11;   245;    2;           0;   16;          m/s; wnd_spd
+  0;   11;   246;    1;           0;    8;          m/s; Ocean surface wind speed
+  0;   12;     1;    1;           0;   12;        deg_K; Temperature/dry bulb temperature (Ta, TsTsTs, TtTt, or
+  0;   12;     2;    1;           0;   12;        deg_K; Wet bulb temperature (TbTbTb)
+  0;   12;     3;    1;           0;   12;        deg_K; Dewpoint (TdTdTd or T'dT'd)
+  0;   12;     4;    1;           0;   12;        deg_K; Dry bulb temperature at 2 meters (Tao>Tan,
+  0;   12;     5;    1;           0;   12;        deg_K; Wet bulb temperature at 2 meters
+  0;   12;     6;    1;           0;   12;        deg_K; Dewpoint temperature at 2 meters
+  0;   12;     7;    1;           0;   12;        deg_K; Virtual temperature
+  0;   12;    11;    1;           0;   12;        deg_K; Maximum temperature
+  0;   12;    12;    1;           0;   12;        deg_K; Minimum temperature (TnTnTn)
+  0;   12;    13;    1;           0;   12;        deg_K; Ground minimum temperature past 12 hours
+  0;   12;    14;    1;           0;   12;        deg_K; Maximum temperature at 2 meters, past 12
+  0;   12;    15;    1;           0;   12;        deg_K; Minimum temperature at 2 meters, past 12
+  0;   12;    16;    1;           0;   12;        deg_K; Maximum temperature at 2 meters, past 24
+  0;   12;    17;    1;           0;   12;        deg_K; Minimum temperature at 2 meters, past 24
+  0;   12;    30;    1;           0;   12;        deg_K; Soil temperature (ToTo)
+  0;   12;    51;    1;           0;   10;        deg_K; Standard deviation temperature
+  0;   12;    52;    1;           0;   12;        deg_K; Highest daily mean temperature
+  0;   12;    53;    1;           0;   12;        deg_K; Lowest daily mean temperature
+  0;   12;    61;    1;           0;   12;        deg_K; Skin temperature
+  0;   12;    62;    1;           0;   12;        deg_K; Equivalent black body temperature
+  0;   12;    63;    1;           0;   12;        deg_K; Brightness temperature
+  0;   12;    70;    2;           0;   16;        deg_K; Vertical polarization 19GHz brightness temperature
+  0;   12;    71;    1;           0;   12;        deg_K; Coldest cluster temperature
+  0;   12;    72;    2;           0;   16;        deg_K; Vertical polarization 22GHz brightness temperature
+  0;   12;    73;    2;           0;   16;        deg_K; Vertical polarization 37GHz brightness temperature
+  0;   12;    74;    2;           0;   16;        deg_K; Horizontal polarization 37GHz brightness temperature
+  0;   12;    75;    2;           0;   16;        deg_K; Vertical polarization 85GHz brightness temperature
+  0;   12;    76;    2;           0;   16;        deg_K; Horizontal polarization 85GHz brightness temperature
+  0;   12;   192;    0;           0;    4;   code_table; Wet bulb temperature indicator
+  0;   12;   193;    2;           0;   16;        deg_K; SSU brightness temperature
+  0;   12;   194;    2;           0;   16;        deg_K; Dewpoint
+  0;   12;   195;    0;           0;    4;   code_table; Dewpoint, aircraft altitude, air temperature indicator (id)
+  0;   12;   196;    2;           0;   16;        deg_K; Dewpoint difference
+  0;   12;   201;    0;           0;    4;   code_table; Air temperature QC ID
+  0;   12;   213;    0;           0;    4;   code_table; Dewpoint QC ID
+  0;   12;   215;    0;           0;    2;   code_table; Temperature precision flag
+  0;   12;   220;    2;           0;   16;        deg_K; HIRS brightness temperature
+  0;   12;   221;    2;           0;   16;        deg_K; MSU brightness temperature
+  0;   13;     1;    5;           0;   14;        kg/kg; Specific humidity
+  0;   13;     2;    5;           0;   14;        kg/kg; Mixing ratio
+  0;   13;     3;    0;           0;    7;      percent; Relative humidity (U1>Un or U...U)
+  0;   13;     4;   -1;           0;   10;           Pa; Vapor pressure
+  0;   13;     5;    3;           0;    7;      kg/m**3; Vapor density (p1p1p1)
+  0;   13;     6;   -1;         -40;   16;            m; Mixing heights
+  0;   13;    11;    1;          -1;   14;      kg/m**2; Total precipitation/total water equivalent (Aw or R...R)
+  0;   13;    12;    2;          -2;   12;            m; Depth of fresh snow
+  0;   13;    13;    2;          -2;   16;            m; Total snow depth (sss)
+  0;   13;    14;    4;           0;   12;    kg/m**2/s; Rainfall/water equivalent of snow (average rate)
+  0;   13;    15;    7;           0;   12;          m/s; Snowfall (averaged rate)
+  0;   13;    16;    0;           0;    7;      kg/m**2; Precipitable water (www)
+  0;   13;    19;    1;          -1;   14;      kg/m**2; Total precipitation past 1 hour
+  0;   13;    20;    1;          -1;   14;      kg/m**2; Total precipitation past 3 hours
+  0;   13;    21;    1;          -1;   14;      kg/m**2; Total precipitation past 6 hours
+  0;   13;    22;    1;          -1;   14;      kg/m**2; Total precipitation past 12 hours
+  0;   13;    23;    1;          -1;   14;      kg/m**2; Total precipitation past 24 hours (R24...R24)
+  0;   13;    31;    0;           0;    7;      kg/m**2; Evapotranspiration
+  0;   13;    32;    1;           0;    8;      kg/m**2; Evaporation/evapotranspiration
+  0;   13;    33;    1;           0;   10;      kg/m**2; Evaporation/evapotranspiration
+  0;   13;    38;    0;           0;    2;   code_table; Superadiabatic indicator
+  0;   13;    39;    0;           0;    3;   code_table; Terrain type (ice/snow)
+  0;   13;    41;    0;           0;    4;   code_table; Pasquill-Gifford stability category
+  0;   13;    42;    0;         -20;    6;        deg_K; Parcel lifted index (to 500 hPa)
+  0;   13;    43;    0;         -20;    6;        deg_K; Best lifted index (to 500 hPa)
+  0;   13;    51;    0;           0;    4;   code_table; Frequency group, precipitation
+  0;   13;    52;    1;          -1;   14;      kg/m**2; Highest daily amount of precipiation
+  0;   13;    71;    1;           0;    7;      kg/m**2; Liquid water
+  0;   13;    75;    0;           0;    8;      percent; Land snow cloud
+  0;   13;    76;    2;           0;    6;            m; Snow-water equivalent
+  0;   13;   192;    0;           0;    4;   code_table; Precipitation identifier (iR)
+  0;   13;   193;    0;           0;   10;   code_table; Precipitation amount
+  0;   13;   194;    3;       -9210;   16;         g/kg; First guess mixing ratios
+  0;   13;   195;    0;           0;   10;      kg/m**3; Density (p1p1p1)
+  0;   13;   196;    0;           0;    7;           mm; Soil moisture
+  0;   13;   197;    0;           0;    3;   code_table; Rain indicator
+  0;   13;   198;    2;           0;   11;           cm; Total precipatable water
+  0;   13;   199;    0;           0;    2;      numeric; prcp_ind_id
+  0;   13;   203;    0;           0;    4;   code_table; Relative humidity QC ID
+  0;   13;   217;    0;           0;    8;      numeric; Precipitation flag (SSM/T)
+  0;   13;   218;    2;           0;   11;    kg/(m**2); Cloud water
+  0;   13;   219;    1;           0;   10;    kg/(m**2); Ocean water vapor
+  0;   13;   220;    1;           0;    9;        mm/hr; Rain rate
+  0;   13;   221;    2;           0;   14;    kg/(m**2); Cloud Liquid Water
+  0;   14;     1;   -3;       -2048;   12;       J/m**2; Longwave radiation, integrated over 24 hours (FLFLFL)
+  0;   14;     2;   -3;       -2048;   12;       J/m**2; Longwave radiation, integrated over period specififed
+  0;   14;     3;   -3;       -2048;   12;       J/m**2; Shortwave radiation, integrated over 24 hours (FiFiFi)
+  0;   14;     4;   -3;       -2048;   12;       J/m**2; Shortwave radiation, integrated over period specified (FsFsFs)
+  0;   14;    11;   -3;       -2048;   12;       J/m**2; Net longwave radiation, integrated over 24 hours
+  0;   14;    12;   -3;       -2048;   12;       J/m**2; Net longwave radiation, integrated over period specified
+  0;   14;    13;   -3;       -2048;   12;       J/m**2; Net shortwave radiation, integrated over 24 hours
+  0;   14;    14;   -3;       -2048;   12;       J/m**2; Net shortwave radiation, integrated over period specified
+  0;   14;    15;   -4;      -16384;   15;       J/m**2; Net radiation, integrated over 24 hours
+  0;   14;    16;   -4;      -16384;   15;       J/m**2; Net radiation, integrated over period specified
+  0;   14;    17;   -3;       -2048;   12;       W/m**2; Instantaneous long wave radiation
+  0;   14;    18;   -3;       -2048;   12;       W/m**2; Instantaneous short wave radiation
+  0;   14;    19;    0;           0;    7;      percent; Surface albedo
+  0;   14;    20;   -4;           0;   15;       J/m**2; Global solar radiation, integrated over 24 hours
+  0;   14;    21;   -4;           0;   15;       J/m**2; Global solar radiation, integrated over period specified
+  0;   14;    22;   -4;           0;   15;       J/m**2; Diffuse solar radiation, integrated over 24 hours
+  0;   14;    23;   -4;           0;   15;       J/m**2; Diffuse solar radiation, integrated over period specified
+  0;   14;    24;   -4;           0;   15;       J/m**2; Direct solar radiation, integrated over 24 hours
+  0;   14;    25;   -4;           0;   15;       J/m**2; Direct solar radiation, integrated over period specififed
+  0;   14;    26;    0;           0;    7;      percent; Albedo at top of clouds
+  0;   14;    31;    0;           0;   11;          min; Total sunshine
+  0;   14;    32;    0;           0;   10;           hr; Total sunshine
+  0;   14;    33;    0;           0;    9;      percent; Total sunshine (precentage)
+  0;   14;    42;    0;           0;    7;      percent; Bi-directional reflectance
+  0;   15;     1;    0;           0;   10;  dobson_unit; Ozone
+  0;   15;     2;    2;           0;   10;      numeric; Air-mass (slant path at 22 km)
+  0;   15;    11;    3;       14000;   13;  log(1/m**2); Log 10 of integrated electron density
+  0;   15;    15;    0;           0;   31;      numeric; Maximum spectral composition before normalization
+  0;   19;     1;    0;           0;    6;   code_table; Type of synoptic features
+  0;   19;     2;   -2;           0;   12;            m; Effective radius of feature
+  0;   19;     3;    0;           0;    8;          m/s; Wind speed threshold
+  0;   19;     4;   -2;           0;   12;            m; Effective radius of feature with respect to
+  0;   19;     5;    0;           0;    9;     deg_true; Direction of motion of features (dsds)
+  0;   19;     6;    2;           0;   14;          m/s; Speed of motion of features
+  0;   19;     7;   -3;           0;   12;            m; Effective radius of features
+  0;   19;     8;    0;           0;    3;   code_table; Vertical extent of circulation
+  0;   19;     9;   -3;           0;   12;            m; Effective radiation with respect to FFF above
+  0;   20;     1;   -1;           0;   13;            m; Horizontal visibility (Dv, Vi, V...V, or VxVxVxVx)
+  0;   20;     2;   -1;           0;    7;            m; Vertical visibility
+  0;   20;     3;    0;           0;    9;   code_table; Present weather (ww or w'w')
+  0;   20;     4;    0;           0;    5;   code_table; Past weather (1) (Wa1Wa2 or W1W2)
+  0;   20;     5;    0;           0;    5;   code_table; Past weather (2) (wawa)
+  0;   20;     9;    0;           0;    4;   code_table; General Weather Indicator
+  0;   20;    10;    0;           0;    7;      percent; Cloud cover (total) (N, NcNc, or Ns...Ns)
+  0;   20;    11;    0;           0;    4;   code_table; Cloud amount (N or Ns...Ns)
+  0;   20;    12;    0;           0;    6;   code_table; Cloud type (C, Ct, CH, CL, or
+  0;   20;    13;   -1;         -40;   11;            m; Height of base of cloud (h, hshs,
+  0;   20;    14;   -1;         -40;   11;            m; Height of top of cloud (HfHfHf or
+  0;   20;    15;   -1;           0;   14;           Pa; Pressure at the base of cloud
+  0;   20;    16;   -1;           0;   14;           Pa; Pressure at the top of cloud (PcPcPc)
+  0;   20;    17;    0;           0;    4;   code_table; Cloud top description
+  0;   20;    18;    0;           0;    2;   code_table; Tendency of runway visual range
+  0;   20;    19;    0;           0;   72;    CCITT_IA5; Significant present or forecast weather
+  0;   20;    20;    0;           0;   32;    CCITT_IA5; Significant recent weather phenomena
+  0;   20;    31;    2;           0;    7;            m; Ice deposit (thickness) (EsEs)
+  0;   20;    32;    0;           0;    3;   code_table; Rate of ice accretion (Rs)
+  0;   20;    33;    0;           0;    4;   flag_table; Cause of ice accretion (Is)
+  0;   20;    34;    0;           0;    5;   code_table; Sea ice concentration (Ci)
+  0;   20;    35;    0;           0;    4;   code_table; Amount and type of ice (zii...zii)
+  0;   20;    36;    0;           0;    5;   code_table; Ice situation
+  0;   20;    37;    0;           0;    5;   code_table; Ice development (bi)
+  0;   20;    38;    0;           0;   12;     deg_true; Bearing of ice edge
+  0;   20;    39;   -1;           0;   13;            m; Ice distance
+  0;   20;    41;    0;           0;    4;   code_table; Rate of icing (Ir)
+  0;   20;    51;    0;           0;    7;      percent; Amount of low clouds
+  0;   20;    52;    0;           0;    7;      percent; Amount of middle clouds
+  0;   20;    53;    0;           0;    7;      percent; Amount of high clouds
+  0;   20;    61;    0;           0;   12;            m; Runway visual range (RVR) (VR...VR)
+  0;   20;    62;    0;           0;    5;   code_table; State of the ground (with or without
+  0;   20;    63;    0;           0;   10;   code_table; Special phenomena
+  0;   20;   192;    0;           0; 2040;    CCITT_IA5; Remark
+  0;   20;   193;    0;           0; 1024;    CCITT_IA5; 128 char plain language text remark
+  0;   20;   194;    0;           0;   11;      kg/m**2; cloud liquid water
+  0;   20;   196;    0;           0;    8;    CCITT_IA5; Runway visibility tendency
+  0;   20;   197;    0;           0;    2;   flag_table; Landing wind shear indicator
+  0;   20;   199;    0;           0;    9;     deg_true; Visibility direction
+  0;   20;   205;    0;           0;   24;    CCITT_IA5; Cloud significant convection
+  0;   20;   206;    0;           0;   64;    CCITT_IA5; Significant present weather conditions
+  0;   20;   207;    0;           0;    4;   code_table; Pressure and altitude significance
+  0;   20;   208;    0;           0;    4;   code_table; Significant weather changes (Ws)
+  0;   20;   209;    0;           0;    4;   code_table; Distance of weather changes (Ss)
+  0;   20;   210;    0;           0;    4;   code_table; Distant weather (Wd)
+  0;   20;   211;    0;           0;    4;   code_table; Bearing of distant weather (dw)
+  0;   20;   213;    0;           0;    4;   code_table; Icing and contrail types (It)
+  0;   20;   216;    0;           0;    7;   code_table; Altitude of layer base where icing occurred
+  0;   20;   219;    0;           0;    4;   code_table; Distance to center or line midpoint
+  0;   20;   220;    0;           0;    4;   code_table; Orientation of ellipse (Sr)
+  0;   20;   221;   -3;           0;   16;            m; Echo width or diameter (Ew)
+  0;   20;   222;   -3;           0;   16;            m; Echo axis length (El)
+  0;   20;   223;    0;           0;    8;   code_table; Echo CCITT_IA5 (ce)
+  0;   20;   224;    0;           0;    4;   code_table; Intensity of echo (Ie)
+  0;   20;   225;    0;           0;    3;   code_table; In flight horizontal visibility (Vi)
+  0;   20;   236;    0;           0;    8;    CCITT_IA5; Cloud base height
+  0;   20;   237;    0;           0;    7;   code_table; Horizontal visbility
+  0;   20;   240;    0;           0;    4;   code_table; Present weather (w)
+  0;   20;   242;    0;           0;    5;   code_table; Bearing of ice edge
+  0;   20;   244;    0;           0;    4;   code_table; cloud base height
+  0;   20;   245;    0;           0;  640;    CCITT_IA5; Remarks in plain language
+  0;   20;   246;    0;           0;    7;      percent; Ice coverage
+  0;   20;   247;    0;           0; 1656;    CCITT_IA5; Ice plain language text remarks
+  0;   20;   248;    0;           0;    2;   code_table; Ice age identifier
+  0;   20;   249;    0;           0;    2;   code_table; Ice edge identifier
+  0;   20;   254;    0;           0;    8;    CCITT_IA5; Extreme value indicator
+  0;   20;   255;    0;           0; 2040;    CCITT_IA5; Plain language text remarks
+  0;   21;     1;    0;         -64;    7;           dB; Horizontal reflectivity
+  0;   21;     2;    0;         -64;    7;           dB; Vertical reflectivity
+  0;   21;     3;    1;          -5;    7;           dB; Differential reflectivity
+  0;   21;     5;    0;         -65;    6;           dB; Linear depolarization ratio
+  0;   21;     6;    0;         -65;    6;           dB; Circular depolarization ratio
+  0;   21;    11;    0;        -128;    8;          m/s; Doppler mean velocity in X direction
+  0;   21;    12;    0;        -128;    8;          m/s; Doppler mean velocity in Y direction
+  0;   21;    13;    0;        -128;    8;          m/s; Doppler mean velocity in Z direction
+  0;   21;    14;    1;       -4096;   13;          m/s; Doppler mean velocity (radiational)
+  0;   21;    17;    1;       -4096;    8;          m/s; Doppler velocity spectral width
+  0;   21;    21;   -3;           0;    4;            m; Echo tops
+  0;   21;    30;    0;         -32;    8;           dB; Signal to noise ratio
+  0;   21;    31;    0;           0;    7;      kg/m**2; Vertical integrated liquid water content
+  0;   21;    36;    7;           0;   12;          m/s; Radar rainfall intensity
+  0;   21;    41;   -2;           0;    8;            m; Bright band height
+  0;   21;    51;    0;        -256;    8;           dB; Signal power above 1 MW
+  0;   21;    62;    2;       -5000;   13;           dB; Backscatter
+  0;   21;    63;    1;           0;   10;      percent; Radiometric resolution (noise value)
+  0;   21;    64;    0;           0;    8;      numeric; Clutter noise estimate
+  0;   21;    65;    0;        -127;    8;      numeric; Missing packet counter
+  0;   21;    66;    0;           0;   12;   flag_table; Wave scatterometer product confidence
+  0;   21;    67;    0;           0;   13;   flag_table; Wind product confidence data
+  0;   21;    68;    0;           0;    8;   flag_table; Radar altimeter product confidence data
+  0;   21;    69;    0;           0;   10;   flag_table; SST product confidence data
+  0;   21;    71;    0;           0;   16;      numeric; Peakiness
+  0;   21;    72;    0;           0;    4;   flag_table; Satellite altimeter calibration status
+  0;   21;    73;    0;           0;    9;   flag_table; Satellite altimeter instrument mode
+  0;   21;    75;    0;           0;    8;      numeric; Spectral intensity
+  0;   21;    76;    0;           0;    3;   code_table; Representation of intensities
+  0;   21;    77;    3;           0;   14;            m; Altitude correction (ionosphere)
+  0;   21;    78;    3;           0;    9;            m; Altitude correction (dry troposphere)
+  0;   21;    79;    3;        2000;   10;            m; Altitude correction (wet troposphere)
+  0;   21;    80;    3;           0;   11;            m; Altitude correction (calibration constant)
+  0;   21;    81;    3;           0;   10;            m; Open loop correction (height-time loop)
+  0;   21;    82;    3;       -3000;   14;           dB; Open loop correction (auto gain control)
+  0;   21;    85;    0;           0;    4;      numeric; ATSR sea surface temperature across-track band number
+  0;   21;   192;    0;           0;   14;            m; Heave sensor spectral peak length
+  0;   21;   193;    1;           0;   14;            s; Heave sensor spectral peak period
+  0;   21;   194;    2;           0;   14;      percent; AVHRR channel average
+  0;   21;   195;    2;           0;   14;      percent; Space view channel standard deviation
+  0;   21;   196;    2;           0;   15;        deg_K; Algorithm identifier
+  0;   21;   197;    2;           0;   15;        deg_K; AVHRR channel average
+  0;   21;   198;    2;       -5000;   13;           dB; Backscatter
+  0;   21;   199;    1;           0;   10;      percent; Noise figure percentage
+  0;   21;   200;    3;           0;   12;            m; aerosol_optical_depth
+  0;   22;     1;    0;           0;    9;     deg_true; Direction of waves (dddd, da1da1, or d1d1>dndn)
+  0;   22;     2;    0;           0;    9;     deg_true; Direction of wind waves
+  0;   22;     3;    0;           0;    9;     deg_true; Direction of swell waves (dw1dw1 or dw2dw2)
+  0;   22;     4;    0;           0;    9;     deg_true; Direction of current (dodo>dndn or DcDc))
+  0;   22;    11;    0;           0;    6;            s; Period of waves (D'D'D'D', PaPaPaPa, or PwPw)
+  0;   22;    12;    0;           0;    6;            s; Period of wind waves
+  0;   22;    13;    0;           0;    6;            s; Period of swell waves (Pw1Pw1 or Pw2Pw2)
+  0;   22;    21;    1;           0;   10;            m; Height of waves (D'D'D'D' or HsHsHsHs)
+  0;   22;    22;    1;           0;   10;            m; Height of wind waves (HwHw)
+  0;   22;    23;    1;           0;   10;            m; Height of swell waves (Hw1Hw1 or Hw2Hw2)
+  0;   22;    25;    2;           0;   10;            m; Standard deviation wave height
+  0;   22;    26;    2;           0;   10;            m; Standard deviation of significant wave height
+  0;   22;    31;    2;           0;   13;          m/s; Speed of current (cococo>cncncn or VcVc)
+  0;   22;    37;    3;      -10000;   15;            m; Tidal elevation with respect to national land
+  0;   22;    38;    3;      -10000;   15;            m; Tidal elevation with respect to local chart
+  0;   22;    39;    3;       -5000;   12;            m; Meteorological residual tidal elevation (surge or offset)
+  0;   22;    40;    3;       -5000;   14;            m; Meteorological residual tidal elevation (surge or offset)
+  0;   22;    41;    1;           0;   12;        deg_K; Sea surface temperature (15 day running mean)
+  0;   22;    42;    1;           0;   12;        deg_K; Sea temperature (T1T1T1>TnTnTn)
+  0;   22;    43;    2;           0;   15;        deg_K; Sea temperature (ToToToTo>TnTnTnTn)
+  0;   22;    44;    1;           0;   14;          m/s; Sound velocity
+  0;   22;    50;    2;           0;    8;        deg_K; Standard deviation sea surface temperature
+  0;   22;    61;    0;           0;    4;   code_table; State of sea
+  0;   22;    62;    2;           0;   14;          ppt; Salinity (SoSoSoSo>SnSnSnSn)
+  0;   22;    63;    0;           0;   14;            m; Total water depth (hhh or ZdZdZdZd)
+  0;   22;    67;    0;           0;   10;   code_table; Instrument type for water temperature profile measurement
+  0;   22;    68;    0;           0;    7;   code_table; Water temperature profile recorder types
+  0;   22;    70;    2;           0;   13;            m; Significant wave height (D'..D', Hm..Hm, Hs..Hs, or
+  0;   22;    71;    1;           0;    9;            s; Spectral peak wave period (Psp..Psp or Pw..Pw)
+  0;   22;    72;    0;           0;   13;            m; Spectral peak wave length (Pa..Pa, Pp..Pp, Psa..Psa,
+  0;   22;    73;    2;           0;   13;            m; Maximum wave height (D'..D', Hm..Hm, Hs..Hs, or
+  0;   22;    74;    1;           0;    9;            s; Average wave period (D'..D', Pa..Pa, Pp..Pp, Pp..Pp,
+  0;   22;    75;    0;           0;   13;            m; Average wave length (Pa..Pa, Pp..Pp, Psa..Psa, Psp..Psp,
+  0;   22;    76;    0;           0;    9;     deg_true; Direction from which dominant waves are comming
+  0;   22;    77;    0;           0;    9;          deg; Directional spread of dominant wave (dsds)
+  0;   22;    78;    0;           0;   12;            s; Duration of wave record (D'D'D'D')
+  0;   22;    79;    0;           0;   16;            m; Length of wave record (D'D'D'D')
+  0;   22;    80;    3;           0;   10;           Hz; Waveband central frequency (f1f1f1 ... fnfnfn)
+  0;   22;    81;    5;           0;   13;          1/m; Waveband central wave number (f1f1f1 ... fnfnfn)
+  0;   22;    82;    2;           0;   20;        m**2s; Sensor spectral density frequency (Cm..Cm or Csm..Csm)
+  0;   22;    83;    2;           0;   20;         m**3; Sensor spectral density number (Cm..Cm or Csm..Csm)
+  0;   22;    84;    0;           0;    7;      numeric; Sensor band number (nmnm or nsmmsm)
+  0;   22;    85;    0;           0;    7;      percent; Sensor ratio (c1c1..cnc or csncsnn)
+  0;   22;    86;    0;           0;    9;     deg_true; Mean direction from which waves are coming
+  0;   22;    87;    0;           0;    9;     deg_true; Principal direction from which waves are coming
+  0;   22;    88;    2;           0;    7;      numeric; First normalized polar coefficient (r1r1 or r2r2)
+  0;   22;    89;    2;           0;    7;      numeric; Second normalized polar coefficient (r1r1 or r2r2)
+  0;   22;    90;    2;           0;   20;        m**2s; Non-directional spectral estimate by wave frequency
+  0;   22;    91;    2;           0;   20;         m**3; Non-directional spectral estimate by wave number
+  0;   22;    92;    2;           0;   20;    m**2s/rad; Directional spectral estimate by wave frequency
+  0;   22;    93;    2;           0;   20;         m**4; Directional spectral estimate by wave number
+  0;   22;    94;    0;           0;    7;      numeric; Total number of wave bands described (BTBT)
+  0;   22;    95;    0;           0;    8;          deg; Directional spread of individual waves
+  0;   22;    96;    3;           0;    4;          1/s; Spectral band width
+  0;   22;   120;    0;           0;    5;   code_table; Tide station automated water level check
+  0;   22;   121;    0;           0;    5;   code_table; Tide station manual water level check
+  0;   22;   122;    0;           0;    5;   code_table; Tide station automated meteorological data check
+  0;   22;   123;    0;           0;    5;   code_table; Tide station manual meteorological data check
+  0;   22;   192;    6;   -10000000;   25;           cm; corrected sea sfc ht
+  0;   22;   194;    0;           0;    4;   code_table; Wave spectra exponent (x)
+  0;   22;   196;    0;           0;    7;      numeric; Number of wave bands affected by the
+  0;   22;   200;    0;           0;   14;            m; Distance sample interval (SSSS)
+  0;   22;   203;    3;           0;   10;           Hz; Frequency increment (fdfdfd)
+  0;   22;   204;    5;           0;   13;          1/m; Wave number increment (fdfdfd)
+  0;   22;   205;    3;           0;   20; m**2/(Hz*rad); Wave spectra
+  0;   22;   206;    4;           0;   10;      numeric; Drag coefficient
+  0;   22;   207;    2;           0;   16;            m; Maximum wave height
+  0;   22;   208;    2;           0;   16;            m; Significant wave height
+  0;   22;   209;    0;           0;    7;   code_table; directional spread
+  0;   22;   211;    0;           0;    8;   code_table; Bogus water mass classification
+  0;   22;   212;    0;           0;    8;   code_table; Discriminant water mass classification
+  0;   22;   213;    1;           0;   10;      percent; Classification probability
+  0;   22;   218;    0;           0;    7;      numeric; Slope sensor band number
+  0;   22;   219;    0;           0;    7;      percent; Slope sensor ratio
+  0;   22;   220;    0;           0;    8;   code_table; Front number
+  0;   22;   224;   -2;           0;   14;            m; Distance to front
+  0;   22;   232;    0;           0;    4;   code_table; Sea surface temperature method indicator
+  0;   22;   233;    0;           0;    3;   code_table; Sea temperature averaging period
+  0;   22;   236;    0;           0;    8;   code_table; Swell wave direction
+  0;   22;   237;   -2;           0;   14;            m; Significant wave height
+  0;   22;   238;   -2;           0;   14;            m; Maximum wave height
+  0;   22;   239;    0;           0;    6;      numeric; Wave spectra direction count
+  0;   22;   240;    0;           0;    6;      numeric; Wave spectra frequency count
+  0;   22;   241;    3;      -32768;   16;      Nt/m**2; Wave stress u-component
+  0;   22;   242;    3;      -32768;   16;      Nt/m**2; Wave stress v-component
+  0;   22;   243;    0;           0;    7;      percent; Whitecap probability
+  0;   22;   245;    2;           0;   16;        deg_K; Surface temperature
+  0;   22;   246;    3;      -32768;   16;      Nt/m**2; Wind stress u-component
+  0;   22;   247;    3;      -32768;   16;      Nt/m**2; Wind stress v-component
+  0;   22;   248;    0;           0;   16;     deg_true; Wind wave direction
+  0;   22;   249;    2;           0;   16;            m; Height of wind wave
+  0;   22;   250;    1;           0;   16;            s; Period of wind waves
+  0;   22;   251;    0;           0;    6;      numeric; Wave spectra direction
+  0;   22;   252;    0;           0;    6;      numeric; Wave spectra frequency
+  0;   22;   253;    0;           0;   16;     deg_true; Direction of swell waves
+  0;   22;   254;    2;           0;   16;            m; Height of swell waves
+  0;   22;   255;    1;           0;   16;            s; Period of swell waves
+  0;   23;     1;    0;           0;    3;   code_table; Accident early notification - article applicable
+  0;   23;     2;    0;           0;    5;   code_table; Activity or facility involved in incident
+  0;   23;     3;    0;           0;    3;   code_table; Type of release
+  0;   23;     4;    0;           0;    3;   code_table; Countermeasures taken near border
+  0;   23;     5;    0;           0;    2;   code_table; Cause of incident
+  0;   23;     6;    0;           0;    3;   code_table; Incident situation
+  0;   23;     7;    0;           0;    3;   code_table; Characteristic of release
+  0;   23;     8;    0;           0;    2;   code_table; State of current release
+  0;   23;     9;    0;           0;    2;   code_table; State of expected release
+  0;   23;    16;    0;           0;    2;   code_table; Possibility of significant chemical toxic health effect
+  0;   23;    17;    6;           0;   20;       m**3/s; Flow discharge of major recipient
+  0;   23;    18;    0;           0;    3;   code_table; release behavior over time
+  0;   23;    19;    0;      -15000;   17;            m; Actual release height
+  0;   23;    21;    0;      -15000;   17;            m; Effective release height
+  0;   23;    22;    0;           0;   24;            m; Distance of relative point or site of
+  0;   23;    23;    1;           0;   12;          m/s; Main transport speed in atmosphere
+  0;   23;    24;    2;           0;   13;          m/s; Main transport speed in water
+  0;   23;    25;    2;           0;   13;          m/s; Main transport speed in ground water
+  0;   23;    27;    0;           0;    9;     deg_true; Main transport direction in atmosphere
+  0;   23;    28;    0;           0;    9;     deg_true; Main transport direction in water
+  0;   23;    29;    0;           0;    9;     deg_true; Main transport direction in ground water
+  0;   23;    31;    0;           0;    2;   code_table; Possibility that plume will encounter precipitation in
+  0;   23;    32;    0;           0;    2;   code_table; Plume will encounter change in wind direction
+  0;   24;     1;  -11;           0;   28;           Bq; Estimate of radiatioactivity released up to specified
+  0;   24;     2;  -11;           0;   28;           Bq; Estimated maximum potential release
+  0;   24;     3;    0;           0;    5;   code_table; Composition of release
+  0;   24;     4;    0;           0;   16;    CCITT_IA5; Element name
+  0;   24;     5;    0;           0;    9;      numeric; Isotope mass
+  0;   24;    11;    2;           0;   32;          mSv; Dose
+  0;   24;    12;    2;           0;   32;          mSv; Trajectory dose (defined location and expected time
+  0;   24;    13;    2;           0;   32;          mSv; Gamma dose in air along the main
+  0;   24;    21;    2;           0;   32;      Bq/m**3; Air concentration (named isotope type including gross
+  0;   24;    22;    2;           0;   32;         Bq/l; Concentration in precipitation (of named isotope type)
+  0;   25;     1;   -1;           0;    6;            m; Range gate length
+  0;   25;     2;    0;           0;    4;      numeric; Number of gates averaged
+  0;   25;     3;    0;           0;    8;      numeric; Number of integrated pulses
+  0;   25;     4;    0;           0;    2;   code_table; Echo processing
+  0;   25;     5;    0;           0;    2;   code_table; Echo integration
+  0;   25;     6;    0;           0;    3;   code_table; Z to R conversion
+  0;   25;     7;    0;           0;   12;      numeric; Z to R conversion factor
+  0;   25;     8;    2;           0;    9;      numeric; Z to R conversion exponent
+  0;   25;     9;    0;           0;    4;   flag_table; Calibration method
+  0;   25;    10;    0;           0;    4;   code_table; Clutter treatment
+  0;   25;    11;    0;           0;    2;   code_table; Ground occultation correction (screening)
+  0;   25;    12;    0;           0;    2;   code_table; Range attenuation correction
+  0;   25;    13;    0;           0;    2;   flag_table; Bright band correction
+  0;   25;    15;    0;           0;    2;   flag_table; Radome attenuation correction
+  0;   25;    16;    5;           0;    6;         dB/m; Clear air attenuation correction
+  0;   25;    17;    0;           0;    2;   flag_table; Precipitation attenuation correction
+  0;   25;    19;    2;           0;    7;      numeric; A to Z law for attenuation exponent
+  0;   25;    20;    0;           0;    2;   code_table; Mean speed estimation
+  0;   25;    21;    0;           0;    8;   flag_table; Wind computation enhancement
+  0;   25;    28;    7;           0;    6;      numeric; A to Z law for attenuation factor
+  0;   25;    30;    0;           0;    2;   code_table; SST usage
+  0;   25;    32;    0;           0;    2;   code_table; Wind profiler mode information
+  0;   25;    33;    0;           0;    2;   code_table; Wind profiler submode information
+  0;   25;    34;    0;           0;    4;   flag_table; Wind profiler Q/C test results
+  0;   25;    40;    0;           0;    4;   code_table; CO2 wind product derivation
+  0;   25;    41;    0;           0;    3;   code_table; Method of determining direction of moving platform
+  0;   25;    42;    0;           0;    3;   code_table; Method of determining speed of moving platform
+  0;   25;    43;    4;           0;   15;            s; Time sample interval (SSSS)
+  0;   25;    44;    2;           0;   14;            m; Distance sample interval (SSSS)
+  0;   25;    45;    0;           0;   21;   flag_table; HIRS channel combination
+  0;   25;    46;    0;           0;    5;   flag_table; MSU channel combination
+  0;   25;    47;    0;           0;    4;   flag_table; SSU channel combination
+  0;   25;    48;    0;           0;   16;   flag_table; AMSU-A channel combination
+  0;   25;    49;    0;           0;    6;   flag_table; AMSU-B channel combination
+  0;   25;    51;    0;           0;    7;   flag_table; AVHRR channel combination
+  0;   25;    53;    0;           0;   12;   flag_table; Observation quality
+  0;   25;    60;    0;           0;   14;      numeric; Software identification
+  0;   25;   192;    0;           0;    8;   code_table; Type of correction
+  0;   25;   193;    0;           0;    3;   code_table; Land/sea flag
+  0;   25;   194;    0;           0;    2;   code_table; Day/night flag
+  0;   25;   195;    0;           0;    6;      numeric; Surface model pressure
+  0;   25;   196;    0;           0;   16;      numeric; Scan line count
+  0;   25;   197;    0;           0;    5;      numeric; Box counter
+  0;   25;   198;    0;           0;    3;      numeric; Minibox counter
+  0;   25;   199;    0;           0;    3;   code_table; Water vapor flag
+  0;   25;   200;    0;           0;    3;   code_table; TOVS retrieval low 20
+  0;   25;   201;    0;           0;    3;   code_table; TOVS retrieval temps high 20
+  0;   25;   202;    0;           0;    2;   code_table; TOVS super adiabatic flag
+  0;   25;   203;    0;           0;    2;   code_table; TOVS skin temperature flag
+  0;   25;   204;    0;           0;    2;   code_table; Stratospheric sounding unit flag
+  0;   25;   205;    0;           0;    4;   code_table; Latitude zones
+  0;   25;   206;    0;           0;    4;   code_table; TOVS instrument combinations
+  0;   25;   207;    0;           0;    6;      numeric; HIRS scan position number
+  0;   25;   208;    0;           0;    8;   code_table; TARM flag
+  0;   25;   209;    0;           0;    4;   code_table; DMSP flag
+  0;   25;   211;    0;           0;   17;      numeric; B-scan start time
+  0;   25;   212;    0;           0;    7;      numeric; Counter (1-64)
+  0;   25;   213;    0;           0;    5;   code_table; Calculated surface type
+  0;   25;   214;    0;           0;    3;   code_table; Season flag
+  0;   25;   215;    0;        -127;    8;      numeric; Missing packet counter
+  0;   25;   216;    0;           0;    3;   code_table; Observation Quality Code
+  0;   26;     1;    1;           0;   12;           hr; Principle time of daily reading in UTC
+  0;   26;     2;    1;           0;   12;           hr; Principle time of daily reading in UTC
+  0;   26;     3;    0;       -1440;   12;          min; Time difference
+  0;   27;     1;    5;    -9000000;   25;          deg; Latitude (high accuracy)
+  0;   27;     2;    2;       -9000;   15;          deg; Latitude (coarse accuracy)
+  0;   27;     3;    2;       -9000;   15;          deg; Alternate latitude
+  0;   27;    20;    0;           0;   16;      numeric; Satellite location counter
+  0;   27;    21;    0;           0;   16;      numeric; Satellite sub-location dimensions
+  0;   27;    31;    2; -1073741824;   31;            m; In direction of 0 degrees longitude, distance
+  0;   28;     1;    5;   -18000000;   26;          deg; Longtiude (high accuracy)
+  0;   28;     2;    2;      -18000;   16;          deg; Longtiude (coarse accuracy)
+  0;   28;     3;    2;      -18000;   16;          deg; Alternate longtiude
+  0;   28;    31;    2; -1073741824;   31;            m; In direction 90 degrees East, distance from
+  0;   29;     1;    0;           0;    3;   code_table; Projection type
+  0;   29;     2;    0;           0;    3;   code_table; Coordinate grid type (Wr)
+  0;   30;     1;    0;           0;    4;      numeric; Pixel value (4 bits)
+  0;   30;     2;    0;           0;    8;      numeric; Pixel value (8 bits)
+  0;   30;     4;    0;           0;   16;      numeric; Pixel value (16 bits)
+  0;   30;    21;    0;           0;   12;      numeric; Number of pixels per row
+  0;   30;    22;    0;           0;   12;      numeric; Number of pixels per column
+  0;   30;    31;    0;           0;    4;   code_table; Picture type
+  0;   30;    32;    0;           0;   16;   flag_table; Combined picture
+  0;   31;     0;    0;           0;    1;      numeric; Short delayed descriptor replication factor
+  0;   31;     2;    0;           0;   16;      numeric; Extended delayed descriptor replication factor (65536 or
+  0;   31;    12;    0;           0;   16;      numeric; Extended delayed descriptor and data replication factor
+  0;   31;    21;    0;           0;    6;   code_table; Associated field significance
+  0;   31;    31;    0;           0;    1;   flag_table; Data present indicator
+  0;   31;   192;    0;           0;    8;   code_table; Associated QC indicator
+  0;   31;   193;    0;           0;    8;   code_table; QC description identifier, indicates why a value
+  0;   31;   194;    2;           0;    7;      numeric; Associated correlation
+  0;   31;   195;    2;           0;    7;      numeric; Associated probability of error
+  0;   31;   196;    0;           0;   13;   flag_table; UWI product confidence flag
+  0;   31;   197;    0;           0;   12;      numeric; Solution probability
+  0;   33;     2;    0;           0;    2;   code_table; Quality information
+  0;   33;     3;    0;           0;    3;   code_table; Quality information
+  0;   33;     7;    0;           0;    7;      percent; Per cent confidence
+  0;   33;    20;    0;           0;    3;   code_table; Quality control indication of following value
+  0;   33;    21;    0;           0;    2;   code_table; Quality of following value
+  0;   33;    22;    0;           0;    2;   code_table; Quality of buoy satellite transmission
+  0;   33;    23;    0;           0;    2;   code_table; Quality of buoy location
+  0;   33;    24;    0;           0;    4;   code_table; Station elevation quality mark (for mobile stations)
+  0;   33;    25;    0;           0;    3;   code_table; ACARS interpolated values table
+  0;   33;    26;    0;           0;    6;   code_table; Mixing ratio quality
+  0;   33;    35;    0;           0;    4;   code_table; manual/automatic quality control
+  0;   33;    36;    0;           0;    7;      percent; nominal confidence threshold wind dir
+  0;   48;     1;    0;           0;  128;    CCITT_IA5; Classification
+  0;   48;     2;    0;           0;  128;    CCITT_IA5; Classification modifier
+  0;   48;     3;    0;           0;  552;    CCITT_IA5; Release as
+  0;   48;     4;    0;           0;   12;           yr; Declassification - year
+  0;   48;     5;    0;           0;    4;           mo; Declassification - month
+  0;   48;     6;    0;           0;    6;          day; Declassification - day
+  0;   48;     7;    0;           0;  552;    CCITT_IA5; Release not
+  0;   48;     8;    0;           0;   64;    CCITT_IA5; Sender of original observation data
+  0;   48;     9;    0;           0;   80;    CCITT_IA5; Declassification instructions
+  0;   48;    10;    0;           0;   12;           yr; Send - year
+  0;   48;    11;    0;           0;    4;           mo; Send - month
+  0;   48;    12;    0;           0;    6;          day; Send - day
+  0;   48;    13;    0;           0;    4;           hr; Send - hour
+  0;   48;    14;    0;           0;    6;          min; Send - minutes
+  0;   48;    15;    0;           0;  552;    CCITT_IA5; Release to information
+  0;   48;    16;    0;           0;    5;           hr; Send - hour
+  0;   48;    17;    0;           0; 1104;    CCITT_IA5; Release to
+  0;   48;    18;    0;           0;  552;    CCITT_IA5; Release not
+  0;   48;    19;    0;           0;  552;    CCITT_IA5; Declassification instructions
+  0;   48;    20;    0;           0;  552;    CCITT_IA5; Classification modifier
+  0;   48;    21;    0;           0;  552;    CCITT_IA5; Sender of observational data
+  0;   48;    22;    0;           0;  160;    CCITT_IA5; Classification
+  0;   48;    27;    0;           0;   12;           yr; Receipt - year
+  0;   48;    28;    0;           0;    4;           mo; Receipt - month
+  0;   48;    29;    0;           0;    6;          day; Receipt - day
+  0;   48;    30;    0;           0;    5;           hr; Receipt - hour
+  0;   48;    31;    0;           0;    6;          min; Receipt - minutes
+  0;   48;    32;    0;           0;   48;    CCITT_IA5; Bulletin header update or correction indicator
+  0;   48;    33;    0;           0;   24;    CCITT_IA5; Receiving circuit
+  0;   48;    34;    0;           0;    6;      numeric; Near-duplicate combination count
+  0;   50;     1;    0;           0;    2;   code_table; Quality of measurement of pressure, sst, air
+  0;   50;     2;    0;           0;    2;   code_table; Quality of buoy satellite transmission (QN)
+  0;   50;     3;    0;           0;    4;   code_table; IGOSS quality codes (Qd, Qd1, Qd2, Q1,
+  0;   50;     6;    0;           0;    3;   code_table; Location quality codes (QL)
+  0;   50;    10;    2;           0;   15;        deg_K; GDEM temperature
+  0;   50;    14;    2;           0;   15;        deg_K; Feature model temperature
+  0;   50;    18;    0;           0;   16;      numeric; Reliability
+  0;   50;    33;    0;           0;    8;      numeric; Count of boundary points
+  0;   50;    34;    3;           0;   16;      numeric; Frequency ratio
+  0;   50;    35;    0;           0;   12;            s; Time step of data (time increment)
+  0;   50;    42;    2;           0;   12;      numeric; Mean wave direction
+  0;   50;    43;    3;           0;   12;      numeric; Mean wave frequency
+  0;   50;    44;    4;           0;   12;      numeric; First frequency
+  0;   50;   100;    0;           0;   12;           yr; Analysis DTG - year
+  0;   50;   101;    0;           0;    4;           mo; Analysis DTG - month
+  0;   50;   102;    0;           0;    6;          day; Analysis DTG - day
+  0;   50;   103;    0;           0;    5;           hr; Analysis DTG - hour
+  0;   50;   104;    0;           0;    6;      numeric; Last observed sea depth
+  0;   51;     3;    0;           0;    5;   flag_table; Processing status
+  0;   51;     6;    0;           0;    6;      numeric; Combination count
+  0;   51;     7;    0;           0;    2;   code_table; Quality control process status
diff --git a/data/tables/B2L-058-000-D b/data/tables/B2L-058-000-D
new file mode 100644
index 0000000..5f2667f
--- /dev/null
+++ b/data/tables/B2L-058-000-D
@@ -0,0 +1,27 @@
+#
+# B2L-058-000-D - Special local BUFR Table D for center 058 (FNMOC) for those
+# cases when an FNOC-generated BUFR message uses local descriptors but has a
+# value of 0 in Section 1, Octet 12 (thus indicating that it does not use
+# local descriptors).
+#
+# Descriptor sequences are terminated with -1
+#
+# Sequences do not need to appear in any order.  Sequence A
+# which includes sequence B, may appear before sequence B
+# is defined.
+#
+
+# Phony local descriptors left over from debuggin
+#
+#3	5	1
+#	0	2	102		# Antenna height above tower base (8 bits)
+#	0	2	104		# Antenna polarization            (4 bits)
+#	0	2	113		# Number of azimuth looks         (4 bits)
+#	-1
+#
+#3	5	1
+#	0	2	 11		# Radiosonde type                 (8 bits)
+#	0	2	 22		# Satellite DP technique used     (8 bits)
+#	0	2	102		# Antenna height above tower base (8 bits)
+#	-1
+
diff --git a/data/tables/B2L-058-001-B b/data/tables/B2L-058-001-B
new file mode 100644
index 0000000..47ab8fc
--- /dev/null
+++ b/data/tables/B2L-058-001-B
@@ -0,0 +1,779 @@
+#
+# B2L-058-001-B.001 - Local BUFR Table B for center 058 (FNMOC),
+# Minor Local Version 1
+#
+#					Data
+#F	X	Y	Scale	RefVal	Width	Units	Element Name
+  0;    0;      1;      0;           0;   24;    CCITT_IA5; Table A: entry
+  0;    0;      2;      0;           0;  256;    CCITT_IA5; Table A: data category description, line 1
+  0;    0;      3;      0;           0;  256;    CCITT_IA5; Table A: data category description, line 2
+  0;    0;      5;      0;           0;   24;    CCITT_IA5; BUFR edition number
+  0;    0;     10;      0;           0;    8;    CCITT_IA5; F descriptor to be added or defined
+  0;    0;     11;      0;           0;   16;    CCITT_IA5; X descriptor to be added or defined
+  0;    0;     12;      0;           0;   24;    CCITT_IA5; Y descriptor to be added or defined
+  0;    0;     13;      0;           0;  256;    CCITT_IA5; Element name, line 1
+  0;    0;     14;      0;           0;  256;    CCITT_IA5; Element name, line 2
+  0;    0;     15;      0;           0;  192;    CCITT_IA5; Units name
+  0;    0;     16;      0;           0;    8;    CCITT_IA5; Units scale sign
+  0;    0;     17;      0;           0;   24;    CCITT_IA5; Units scale (u)
+  0;    0;     18;      0;           0;    8;    CCITT_IA5; Units reference sign
+  0;    0;     19;      0;           0;   80;    CCITT_IA5; Units reference value
+  0;    0;     20;      0;           0;   24;    CCITT_IA5; Element data width
+  0;    0;     30;      0;           0;   40;    CCITT_IA5; Descriptor defining sequence
+  0;    1;      1;      0;           0;    7;      Numeric; WMO block number (II)
+  0;    1;      2;      0;           0;   10;      Numeric; WMO station number (iii)
+  0;    1;      3;      0;           0;    3;      Numeric; WMO region number
+  0;    1;      4;      0;           0;    3;      Numeric; WMO region sub-area
+  0;    1;      5;      0;           0;   17;      Numeric; Buoy/platform identifier
+  0;    1;      6;      0;           0;   64;    CCITT_IA5; Aircraft identifier (flight number) (Ia...Ia)
+  0;    1;      7;      0;           0;   10;   Code_Table; Satellite identifier (I1I2I2)
+  0;    1;      8;      0;           0;   64;    CCITT_IA5; Aircraft registration number (tail number)
+  0;    1;      9;      0;           0;   64;    CCITT_IA5; Type of commerical aircraft
+  0;    1;     10;      0;           0;   64;    CCITT_IA5; Stationary buoy platform identifier
+  0;    1;     11;      0;           0;   72;    CCITT_IA5; Ship call sign (D...D)
+  0;    1;     12;      0;           0;    9;     deg_true; Direction of motion of moving observing platform (dBdB)
+  0;    1;     13;      0;           0;   10;          m/s; Speed of motion of moving observing platform
+  0;    1;     14;      2;           0;   10;          m/s; Platform drift speed (high precision) (VBVB)
+  0;    1;     21;      0;           0;   14;      Numeric; Synoptic feature identifier
+  0;    1;     25;      0;           0;   24;    CCITT_IA5; Storm identifier
+  0;    1;     26;      0;           0;   64;    CCITT_IA5; WMO storm name
+  0;    1;     31;      0;           0;   16;      Numeric; Generating center
+  0;    1;     50;      0;           0;   48;    CCITT_IA5; NMC report identifier
+  0;    1;     62;      0;           0;   40;    CCITT_IA5; National assigned station identifier
+  0;    1;     63;      0;           0;   64;    CCITT_IA5; ICAO location indicator (CCCC)
+  0;    1;    192;      0;           0;   24;    CCITT_IA5; Receiving circuit
+  0;    1;    193;      0;           0;    4;   Code_Table; global octant
+  0;    1;    195;      0;           0;   10;      Numeric; Marsden square number
+  0;    1;    197;      0;           0;    6;      Numeric; Runway number
+  0;    1;    198;      0;           0;   16;   Code_Table; Sea station type
+  0;    1;    200;      0;           0;    2;   Code_Table; Radar Capability indicator (XXX)
+  0;    1;    201;      0;           0;    8;   Code_Table; Country or agency that operates the satellite
+  0;    1;    203;      0;           0;   16;    CCITT_IA5; Satellite name
+  0;    1;    204;      0;           0;   16;    CCITT_IA5; Satellite series
+  0;    1;    206;      0;           0;   32;    CCITT_IA5; TOVS generating center name
+  0;    1;    207;      0;           0;   72;    CCITT_IA5; File name
+  0;    1;    208;      0;           0;    4;   Code_Table; Satellite data type
+  0;    1;    209;      0;           0;    8;   Code_Table; Observation type for MCSST
+  0;    1;    210;      0;           0;    7;   Code_Table; Observation source
+  0;    1;    211;      0;           0;    4;      Numeric; Beam position
+  0;    1;    212;      0;           0;   24;      Numeric; Data processing block number
+  0;    1;    213;      0;           0;    3;   Code_Table; Tip source type identifier
+  0;    1;    214;      0;           0;   32;    CCITT_IA5; Header originator
+  0;    1;    215;      0;           0;   48;    CCITT_IA5; Bulletin header update or correction indicator
+  0;    1;    216;      0;           0;   14;      Numeric; Engineering status
+  0;    1;    217;      0;           0;    5;      Numeric; Satellite number
+  0;    1;    218;      0;           0;  176;    CCITT_IA5; Sequence (report) type
+  0;    1;    219;      0;           0;   40;    CCITT_IA5; Mission number
+  0;    1;    220;      0;           0;    7;      Numeric; Observation number
+  0;    1;    221;      0;           0;    8;   Code_Table; Surface type
+  0;    1;    222;      0;           0;   32;    CCITT_IA5; Report modifier
+  0;    1;    223;      0;           0;    3;   Code_Table; Runway parallel indicator
+  0;    1;    224;      0;           0;    5;   Code_Table; Terrain code identifier
+  0;    2;      1;      0;           0;    2;   Code_Table; Type of station (ix)
+  0;    2;      2;      0;           0;    4;   Flag_Table; Type of instrumentation for wind measurement (ewew)
+  0;    2;      3;      0;           0;    4;   Code_Table; Type of measuring instrumentation used (a4, I3, or I4)
+  0;    2;      4;      0;           0;    4;   Code_Table; Type of instrumentation for evaporation measur
+  0;    2;      5;      2;           0;    7;        deg_K; Precision of temperature observed (s3)
+  0;    2;     11;      0;           0;    8;   Code_Table; Radiosonde type (rara)
+  0;    2;     12;      0;           0;    4;   Code_Table; Radiosonde computational method
+  0;    2;     13;      0;           0;    4;   Code_Table; Solar and infrared radiation correction (Sr)
+  0;    2;     14;      0;           0;    7;   Code_Table; Tracking technique/status of system (sasa)
+  0;    2;     15;      0;           0;    4;   Code_Table; Radiosonde completeness
+  0;    2;     21;      0;           0;    9;   Flag_Table; Satellite instrumentation data used in processing
+  0;    2;     22;      0;           0;    8;   Flag_Table; Satellite data processing technique used
+  0;    2;     23;      0;           0;    4;   Code_Table; Cloud motion computational method
+  0;    2;     24;      0;           0;    4;   Code_Table; Integrated mean humidity computational method
+  0;    2;     25;      0;           0;   25;   Flag_Table; Satellite channel(s) used in computation
+  0;    2;     26;      2;           0;   12;            m; Cross track resolution
+  0;    2;     27;      2;           0;   12;            m; Along track resolution
+  0;    2;     28;      0;           0;   32;   Flag_Table; Geostationary sounder satellite channels used
+  0;    2;     29;      0;           0;    8;   Flag_Table; Geostationary sounder satellite channels used
+  0;    2;     30;      0;           0;    3;   Code_Table; Method of current measurement (k5)
+  0;    2;     31;      0;           0;    5;   Code_Table; Duration and time of current measurement
+  0;    2;     32;      0;           0;    2;   Code_Table; Indicator for digitization (k1)
+  0;    2;     33;      0;           0;    3;   Code_Table; Method of salinity/depth measurement (k2)
+  0;    2;     34;      0;           0;    5;   Code_Table; Drogue type (id)
+  0;    2;     35;      0;           0;    9;            m; Cable length (ZdZdZd)
+  0;    2;     36;      0;           0;    2;   Code_Table; Buoy type (Ip or Vi...Vi)
+  0;    2;     38;      0;           0;    4;   Code_Table; Sea surface temperature method indicator
+  0;    2;     39;      0;           0;    4;   Code_Table; Wet bulb temperature method indicator
+  0;    2;     40;      0;           0;    4;   Code_Table; Method of removing velocity and motion
+  0;    2;     41;      0;           0;    6;   Code_Table; Method for estimating reports related to synoptic features
+  0;    2;     42;      0;           0;    6;   Code_Table; Method of report construction (Qn)
+  0;    2;     43;      0;           0;    6;   Code_Table; Precision of latitude/longitude report (At or QL)
+  0;    2;     47;      0;           0;    4;   Code_Table; Method of removing ship velocity
+  0;    2;     51;      0;           0;    4;   Code_Table; Indicator to specify observing method for extreme temperatures
+  0;    2;     61;      0;           0;    3;   Code_Table; Aircraft navigation system (s1)
+  0;    2;     62;      0;           0;    4;   Code_Table; Type of aircraft data relay system
+  0;    2;     63;      2;      -18000;   16;          deg; Aircraft roll angle
+  0;    2;     70;      0;           0;    4;   Code_Table; Original specification of latitude/longitude
+  0;    2;    101;      0;           0;    4;   Code_Table; Type of antenna
+  0;    2;    102;      0;           0;    8;            m; Antenna height above tower
+  0;    2;    103;      0;           0;    2;   Flag_Table; Radome
+  0;    2;    104;      0;           0;    4;   Code_Table; Antenna polarisation
+  0;    2;    105;      0;           0;    6;           dB; Maximum antenna gain
+  0;    2;    106;      1;           0;    6;          deg; 3-dB bandwidth
+  0;    2;    107;      0;           0;    6;           dB; Sidelobe suppression
+  0;    2;    108;      0;           0;    6;           dB; Crosspol discrimination (on axis)
+  0;    2;    109;      2;           0;   12;        deg/s; Antenna speed (azimuth)
+  0;    2;    110;      2;           0;   12;        deg/s; Antenna speed (elevation)
+  0;    2;    111;      1;           0;   10;          deg; Radar incidence angle
+  0;    2;    112;      1;           0;   12;          deg; Radar azimuth angle
+  0;    2;    113;      0;           0;    4;      Numeric; Number of azimuth looks
+  0;    2;    114;      0;           0;   15;         m**2; Antenna effective surface area
+  0;    2;    121;     -8;           0;    7;           Hz; Mean frequency
+  0;    2;    122;     -6;        -128;    8;           Hz; Frequency agility range
+  0;    2;    123;     -4;           0;    7;            W; Peak power
+  0;    2;    124;     -1;           0;    7;            W; Average power
+  0;    2;    125;     -1;           0;    8;           Hz; Pulse repetition frequency
+  0;    2;    126;      7;           0;    6;            s; Pulse width
+  0;    2;    127;     -6;           0;    7;           Hz; Receiver intermediate frequency
+  0;    2;    128;     -5;           0;    6;           Hz; Intermediate frequency bandwidth
+  0;    2;    129;      0;        -150;    5;           dB; Minimum detectable signal
+  0;    2;    130;      0;           0;    7;           dB; Dynamic range
+  0;    2;    131;      0;           0;    2;   Flag_Table; Sensitivity time control
+  0;    2;    132;      2;           0;    6;          deg; Azimuth pointing accuracy
+  0;    2;    133;      2;           0;    6;          deg; Elevation pointing accuracy
+  0;    2;    134;      2;           0;   16;          deg; Antenna beam azimuth
+  0;    2;    135;      2;       -9000;   15;          deg; Antenna elevation
+  0;    2;    141;      0;           0;   24;    CCITT_IA5; Measurement type serial number/identifier
+  0;    2;    142;      0;           0;    8;   Code_Table; Ozone instrument
+  0;    2;    143;      0;           0;    7;      Numeric; Instrument type
+  0;    2;    190;      0;           0;    8;   Code_Table; U, v quality indicator
+  0;    2;    191;      0;           0;    4;   Code_Table; W quality indicator
+  0;    2;    194;      0;           0;    8;   Code_Table; Spectral calculation method
+  0;    2;    199;      0;           0;    4;      Numeric; grp_pos_ind
+  0;    2;    203;      0;           0;    3;   Code_Table; Method of determining direction of moving platform
+  0;    2;    204;      0;           0;    3;   Code_Table; Method of determining speed of moving platform
+  0;    2;    205;      0;           0;    3;   Code_Table; Ozone flag
+  0;    2;    206;      0;           0;    4;   Code_Table; Algorithm identifier
+  0;    2;    207;      0;           0;    5;   Code_Table; Equation identifier
+  0;    2;    208;      0;           0;    2;   Code_Table; Type of method for measuring pressure
+  0;    2;    209;      0;           0;   10;   Code_Table; Xbt instrument type (IxIxIx)
+  0;    2;    210;      0;           0;    7;   Code_Table; Recorder type (XRXR)
+  0;    2;    211;      0;           0;    8;   Flag_Table; Sensor status flag
+  0;    2;    212;      0;           0;    2;   Flag_Table; Maintenance Check flag
+  0;    4;      1;      0;           0;   12;           yr; Year (4-digit)
+  0;    4;      2;      0;           0;    4;           mo; Month
+  0;    4;      3;      0;           0;    6;          day; Day
+  0;    4;      4;      0;           0;    5;           hr; Hour
+  0;    4;      5;      0;           0;    6;          min; Minute
+  0;    4;      6;      0;           0;    6;            s; Second
+  0;    4;     11;      0;       -1024;   11;           yr; Time increment - year
+  0;    4;     12;      0;       -1024;   11;           mo; Time increment - month
+  0;    4;     13;      0;       -1024;   11;          day; Time increment - day
+  0;    4;     14;      0;       -1024;   11;           hr; Time increment - hour
+  0;    4;     15;      0;       -2048;   12;          min; Time increment - minutes
+  0;    4;     16;      0;       -4096;   13;            s; Time increment - seconds
+  0;    4;     21;      0;       -1024;   11;           yr; Time period or displacement - year
+  0;    4;     22;      0;       -1024;   11;           mo; Time period or displacement - month
+  0;    4;     23;      0;       -1024;   11;          day; Time period or displacement - month
+  0;    4;     24;      0;       -2048;   12;           hr; Time period or displacement - hour
+  0;    4;     25;      0;       -2048;   12;          min; Time period or displacement - minutes
+  0;    4;     26;      0;       -4096;   13;            s; Time period or displacement - seconds
+  0;    4;     31;      0;           0;    8;           hr; Duration of time relative to following value (TT)
+  0;    4;     41;      0;       -1440;   12;          min; Time difference, UTC - LMT
+  0;    4;     43;      0;           0;    9;          day; Day of the year
+  0;    4;     44;      0;           0;    3;   Code_Table; Day of the week (Y)
+  0;    4;     53;      0;           0;    6;      Numeric; Number of days with precipitation equal or more than 1 mm
+  0;    4;     70;      0;           0;    8;      Numeric; Sample number
+  0;    4;    192;      0;           0;    4;   Code_Table; Precipitation time period (tR)
+  0;    4;    193;      0;           0;   31;   Code_Table; Last time that this observation record was updated
+  0;    4;    200;      0;           0;   12;           yr; Time of receipt - year
+  0;    4;    201;      0;           0;    4;           mo; Time of receipt - month
+  0;    4;    202;      0;           0;    6;          day; Time of receipt - day
+  0;    4;    203;      0;           0;    5;           hr; Time of receipt - hour
+  0;    4;    204;      0;           0;    6;          min; Time of receipt - minute
+  0;    4;    206;      3;           0;   27;            s; GMT seconds
+  0;    5;      1;      5;    -9000000;   25;          deg; Latitude (high accuracy)
+  0;    5;      2;      2;       -9000;   15;          deg; Latitude (coarse accuracy) (La...La)
+  0;    5;      3;      2;       -9000;   15;          deg; Alternate latitude
+  0;    5;     11;      5;    -9000000;   25;          deg; Latitude increment (high accuracy)
+  0;    5;     12;      2;       -9000;   15;          deg; Latitude increment (coarse accuracy)
+  0;    5;     21;      2;           0;   16;     deg_true; Bearing or azimuth
+  0;    5;     22;      2;           0;   16;     deg_true; Solar azimuth
+  0;    5;     30;      0;           0;   12;          deg; Direction (spectral)
+  0;    5;     31;      0;           0;   12;      Numeric; Row number
+  0;    5;     33;     -1;           0;   16;            m; Pixel size on horizontal - 1
+  0;    5;     40;      0;           0;   24;      Numeric; Orbit number
+  0;    5;     41;      0;           0;    8;      Numeric; Scan line number
+  0;    5;     42;      0;           0;    6;      Numeric; Channel number
+  0;    5;     43;      0;           0;    8;      Numeric; Field of view number
+  0;    5;     50;      5;           0;   17;      Numeric; Sigma level
+  0;    5;     52;      0;           0;    5;      Numeric; Channel number increment
+  0;    5;     53;      0;           0;    5;      Numeric; Field of view number increment
+  0;    5;    192;      0;           0;    3;      Numeric; Image line number
+  0;    5;    193;      0;           0;    4;      Numeric; Image sample number
+  0;    5;    194;      0;           0;   14;      Numeric; Orbit number
+  0;    5;    196;      0;           0;   16;      Numeric; Orbit number
+  0;    5;    197;      0;           0;    8;      Numeric; Frame number
+  0;    5;    199;      0;           0;   20;      Numeric; Orbit number
+  0;    6;      1;      5;   -18000000;   26;          deg; Longtiude (high accuracy)
+  0;    6;      2;      2;      -18000;   16;          deg; Longtiude (coarse accuracy) (Lo...Lo)
+  0;    6;      3;      2;      -18000;   16;          deg; Alternate longtiude
+  0;    6;     11;      5;   -18000000;   26;          deg; Longtiude increment (high accuracy)
+  0;    6;     12;      2;      -18000;   16;          deg; Longtiude increment (coarse accuracy)
+  0;    6;     21;     -1;           0;   13;            m; Distance
+  0;    6;     30;      5;           0;   13;        rad/m; Wavenumber (spectral)
+  0;    6;     31;      0;           0;   12;      Numeric; Column number
+  0;    6;     33;     -1;           0;   16;            m; Pixel size on horizontal - 2
+  0;    7;      1;      0;        -400;   15;            m; Height of station (hohohoho)
+  0;    7;      2;     -1;         -40;   16;            m; Height or altitude (hahaha, hIhIhI, HmHmHm, HH, tnu2, or tnu3)
+  0;    7;      3;     -1;        -400;   17;    m**2/s**2; Geopotential
+  0;    7;      4;     -1;           0;   14;           Pa; Pressure (Pa...Pa, Paob...Paob, Po...Po, PtPtPt, or PAPA)
+  0;    7;      5;      0;        -400;   12;            m; Height increment
+  0;    7;      6;      0;           0;   15;            m; Height above station
+  0;    7;      7;      0;       -1000;   17;            m; Geopotential height
+  0;    7;     21;      2;       -9000;   15;          deg; Elevation
+  0;    7;     22;      2;       -9000;   15;          deg; Solar elevation
+  0;    7;     61;      2;           0;   14;            m; Depth below land surface
+  0;    7;     62;      1;           0;   17;            m; Depth below sea surface
+  0;    7;    190;      0;           0;   12;            m; Height increment
+  0;    7;    192;      2;           0;   13;          deg; Local zenith angle
+  0;    7;    196;      0;           0;    4;   Code_Table; Station height precision
+  0;    7;    197;      1;           0;   11;          deg; Solar zenith angle
+  0;    7;    198;      2;       -6000;   14;          deg; Satellite zenith angle
+  0;    7;    199;      1;           0;   11;          deg; Solar azimuth angle
+  0;    7;    223;      2;           0;   14;          deg; Solar zenith angle
+  0;    7;    224;      1;           0;   14;            m; Surface elevation
+  0;    8;      0;      0;           0;    4;   Code_Table; Vertical significance (forecast soundings)
+  0;    8;      1;      0;           0;    7;   Flag_Table; Vertical sounding significance
+  0;    8;      2;      0;           0;    6;   Code_Table; Vertical significance (surface observations)
+  0;    8;      3;      0;           0;    6;   Code_Table; Vertical significance (satellite observations)
+  0;    8;      4;      0;           0;    3;   Code_Table; Phase of aircraft flight (ipipip)
+  0;    8;      5;      0;           0;    4;   Code_Table; Surface synoptic features significance
+  0;    8;     11;      0;           0;    6;   Code_Table; Horizontal significance
+  0;    8;     12;      0;           0;    2;   Code_Table; land/sea qualifier
+  0;    8;     13;      0;           0;    2;   Code_Table; Day/night qualifier
+  0;    8;     21;      0;           0;    5;   Code_Table; Time significance
+  0;    8;     22;      0;           0;   16;      Numeric; Total number (with respect to accumulation or average)
+  0;    8;     24;      0;           0;    8;   Code_Table; Type of difference
+  0;    8;     31;      0;           0;    8;    CCITT_IA5; Data category
+  0;    8;     32;      0;           0;   14;   Code_Table; Data significance for simulated forecast
+  0;    8;     33;      0;           0;    3;   Code_Table; Data significance for corrected forecast
+  0;    8;     34;      0;           0;    3;   Code_Table; Data significance for simulated retrievals
+  0;    8;     35;      0;           0;    3;   Code_Table; Data significance for corrected retrievals
+  0;    8;     36;      0;           0;    3;   Code_Table; Data significance for simulated analysis
+  0;    8;     37;      0;           0;    3;   Code_Table; Data significance for corrected analysis
+  0;    8;     38;      0;           0;    3;   Code_Table; Data significance for sigma level data
+  0;    8;     51;      0;           0;    3;   Code_Table; Qualifier for number of missing values in calculation of statistic
+  0;    8;     52;      0;           0;    5;   Code_Table; Condition for which number of days of occurrence follows
+  0;    8;     53;      0;           0;    2;   Code_Table; Day of occurrence qualifier
+  0;    8;     70;      0;           0;    8;   Code_Table; Surface Type Code ID
+  0;    8;    194;      0;           0;    4;   Code_Table; Flight condition (fc)
+  0;   10;      1;      0;        -400;   15;            m; Height of land surface
+  0;   10;      2;     -1;         -40;   16;            m; Height (HHH)
+  0;   10;      3;     -1;        -400;   17;    m**2/s**2; Geopotential
+  0;   10;      4;     -1;           0;   14;           Pa; Pressure
+  0;   10;      7;      0;       -1000;   17;            m; Geopotential height
+  0;   10;     50;      2;           0;   16;            m; Standard deviation altitude
+  0;   10;     51;     -1;           0;   14;           Pa; Pressure reduced to mean sea level (PPPP)
+  0;   10;     52;     -1;           0;   14;           Pa; Altimeter setting (QNH) (PH...PH)
+  0;   10;     60;     -1;       -1024;   11;           Pa; Pressure change (ppp)
+  0;   10;     61;     -1;        -500;   10;           Pa; 3 hour pressure change
+  0;   10;     62;     -1;       -1000;   11;           Pa; 24 hour pressure change
+  0;   10;     63;      0;           0;    4;   Code_Table; Characteristic of pressure tendency (a, w, or w'w')
+  0;   10;    103;      0;           0;    4;   Code_Table; Geopotential thickness QC ID
+  0;   10;    197;      0;           0;    4;   Code_Table; Index pertaining to geopotential height (j)
+  0;   10;    199;      0;       -1024;   16;            m; Geopotential height difference
+  0;   10;    200;      0;       -1024;   16;            m; Geopotental height correction
+  0;   10;    201;      0;           0;   14;   Code_Table; Pressure tendency QC ID
+  0;   10;    203;      0;           0;    4;   Code_Table; Geopotential height quality control flag
+  0;   10;    213;      0;       -1024;   16;            m; Geopotential height
+  0;   10;    224;      0;           0;    4;   Code_Table; Station level pressure QC ID
+  0;   10;    251;      0;           0;    4;   Code_Table; Mean sea level pressure QC ID
+  0;   11;      1;      0;           0;    9;     deg_true; Wind direction (dd, dodo>dndn, dmagdmag)
+  0;   11;      2;      1;           0;   12;          m/s; Wind speed (ff, fff, or fofofo>fnfnfn)
+  0;   11;      3;      1;       -4096;   13;          m/s; U-component
+  0;   11;      4;      1;       -4096;   13;          m/s; V-component
+  0;   11;      5;      1;        -512;   10;         Pa/s; W-component
+  0;   11;      6;      2;       -4096;   13;          m/s; W-component
+  0;   11;     11;      0;           0;    9;     deg_true; Wind direction at 10 m
+  0;   11;     12;      1;           0;   12;          m/s; Wind speed at 10 m
+  0;   11;     13;      0;           0;    9;     deg_true; Wind direction at 5 m
+  0;   11;     14;      1;           0;   12;          m/s; Wind speed at 5 m
+  0;   11;     21;      9;      -65536;   17;          1/s; Relative vorticity
+  0;   11;     22;      9;      -65536;   17;          1/s; Divergence
+  0;   11;     23;     -2;      -65536;   17;       m**2/s; Velocity potential
+  0;   11;     31;      0;           0;    4;   Code_Table; Degree of turbulence (B...B or BA)
+  0;   11;     32;     -1;         -40;   16;            m; Height of base of turbulence (BabBabBab or B1B1B1)
+  0;   11;     33;     -1;         -40;   16;            m; Height of top of turbulence (BatBatBat or B1B1B1)
+  0;   11;     34;      1;       -1024;   11;          m/s; Vertical gust velocity
+  0;   11;     35;      2;       -8192;   14;       m/s**2; Vertical gust acceleration
+  0;   11;     36;      1;           0;   10;          m/s; Maximum derived equivalent vertical gust
+  0;   11;     41;      1;           0;   12;          m/s; Maximum wind speed (gusts) (fm...fm)
+  0;   11;     42;      1;           0;   12;          m/s; Maximum wind speed (10 minute mean wind)
+  0;   11;     43;      1;           0;   12;          m/s; Surface - 5000 feet mean LYR wind speed (dmdm)
+  0;   11;     44;      0;           0;    9;     deg_true; Surface - 5000 feet mean LYR wind direction
+  0;   11;     45;      0;           0;    9;     deg_true; Maximum wind (gust) direction
+  0;   11;     50;      1;           0;   12;          m/s; Standard deviation horizontal wind speed
+  0;   11;     51;      1;           0;    8;          m/s; Standard deviation vertical wind component
+  0;   11;     61;      1;           0;   12;          m/s; Absolute wind shear (1 kilometer layer below)
+  0;   11;     62;      1;           0;   12;          m/s; Absolute wind shear (1 kilometer layer above)
+  0;   11;    195;      0;           0;    2;   Code_Table; Wind type at flight altitude (dt)
+  0;   11;    200;      0;           0;    4;   Code_Table; Wind QC ID
+  0;   11;    203;      1;       -4096;   13;          m/s; Wind u-component difference
+  0;   11;    204;      1;       -4096;   13;          m/s; Wind v-component difference
+  0;   11;    205;      0;           0;    4;   Code_Table; Turbulence (B) (WMO code table 0300)
+  0;   11;    206;      0;           0;    2;   Code_Table; Flight level wind method (da)
+  0;   11;    207;      0;           0;    2;   Code_Table; Extreme wind speed ID
+  0;   11;    213;      1;       -4096;   13;          m/s; Wind u-component correction
+  0;   11;    214;      1;       -4096;   13;          m/s; Wind v-component correction
+  0;   11;    244;      0;           0;   16;     deg_true; Direction of wind
+  0;   11;    245;      2;           0;   16;          m/s; wnd_spd
+  0;   11;    246;      1;           0;    8;          m/s; Ocean surface wind speed
+  0;   12;      1;      1;           0;   12;        deg_K; Temperature/dry bulb temperature (Ta, TsTsTs, TtTt, or TxTxTx)
+  0;   12;      2;      1;           0;   12;        deg_K; Wet bulb temperature (TbTbTb)
+  0;   12;      3;      1;           0;   12;        deg_K; Dewpoint (TdTdTd or T'dT'd)
+  0;   12;      4;      1;           0;   12;        deg_K; Dry bulb temperature at 2 meters (Tao>Tan, ToTo>tnTn, or TT)
+  0;   12;      5;      1;           0;   12;        deg_K; Wet bulb temperature at 2 meters
+  0;   12;      6;      1;           0;   12;        deg_K; Dewpoint temperature at 2 meters
+  0;   12;      7;      1;           0;   12;        deg_K; Virtual temperature
+  0;   12;     11;      1;           0;   12;        deg_K; Maximum temperature
+  0;   12;     12;      1;           0;   12;        deg_K; Minimum temperature (TnTnTn)
+  0;   12;     13;      1;           0;   12;        deg_K; Ground minimum temperature past 12 hours
+  0;   12;     14;      1;           0;   12;        deg_K; Maximum temperature at 2 meters, past 12 hours
+  0;   12;     15;      1;           0;   12;        deg_K; Minimum temperature at 2 meters, past 12 hours
+  0;   12;     16;      1;           0;   12;        deg_K; Maximum temperature at 2 meters, past 24 hours
+  0;   12;     17;      1;           0;   12;        deg_K; Minimum temperature at 2 meters, past 24 hours
+  0;   12;     20;      2;       -2000;   12;    deg_K/day; Radiative heating profile
+  0;   12;     30;      1;           0;   12;        deg_K; Soil temperature (ToTo)
+  0;   12;     40;     -3;       -2048;   12;       W/m**2; Sensible heat flux
+  0;   12;     48;      0;        -200;    8;        deg_K; Land/snow surface temperature
+  0;   12;     51;      1;           0;   10;        deg_K; Standard deviation temperature
+  0;   12;     52;      1;           0;   12;        deg_K; Highest daily mean temperature
+  0;   12;     53;      1;           0;   12;        deg_K; Lowest daily mean temperature
+  0;   12;     61;      1;           0;   12;        deg_K; Skin temperature
+  0;   12;     62;      1;           0;   12;        deg_K; Equivalent black body temperature
+  0;   12;     63;      1;           0;   12;        deg_K; Brightness temperature
+  0;   12;     70;      2;           0;   16;        deg_K; Vertical polarization 19GHz brightness temperature
+  0;   12;     71;      2;           0;   16;        deg_K; Horizontal polarization 19GHz brightness temperature
+  0;   12;     72;      2;           0;   16;        deg_K; Vertical polarization 22GHz brightness temperature
+  0;   12;     73;      2;           0;   16;        deg_K; Vertical polarization 37GHz brightness temperature
+  0;   12;     74;      2;           0;   16;        deg_K; Horizontal polarization 37GHz brightness temperature
+  0;   12;     75;      2;           0;   16;        deg_K; Vertical polarization 85GHz brightness temperature
+  0;   12;     76;      2;           0;   16;        deg_K; Horizontal polarization 85GHz brightness temperature
+  0;   12;    192;      0;           0;    4;   Code_Table; Wet bulb temperature indicator
+  0;   12;    193;      2;           0;   16;        deg_K; SSU brightness temperature
+  0;   12;    194;      2;           0;   16;        deg_K; Dewpoint
+  0;   12;    195;      0;           0;    4;   Code_Table; Dewpoint, aircraft altitude, air temperature indicator (id)
+  0;   12;    196;      2;           0;   16;        deg_K; Dewpoint difference
+  0;   12;    201;      0;           0;    4;   Code_Table; Air temperature QC ID
+  0;   12;    213;      0;           0;    4;   Code_Table; Dewpoint QC ID
+  0;   12;    215;      0;           0;    2;   Code_Table; Temperature precision flag
+  0;   12;    220;      2;           0;   16;        deg_K; HIRS brightness temperature
+  0;   12;    221;      2;           0;   16;        deg_K; MSU brightness temperature
+  0;   13;      1;      5;           0;   14;        kg/kg; Specific humidity
+  0;   13;      2;      5;           0;   14;        kg/kg; Mixing ratio
+  0;   13;      3;      0;           0;    7;      percent; Relative humidity (U1>Un or U...U)
+  0;   13;      4;     -1;           0;   10;           Pa; Vapor pressure
+  0;   13;      5;      3;           0;    7;      kg/m**3; Vapor density (p1p1p1)
+  0;   13;      6;     -1;         -40;   16;            m; Mixing heights
+  0;   13;     11;      1;          -1;   14;      kg/m**2; Total precipitation/total water equivalent (Aw or R...R)
+  0;   13;     12;      2;          -2;   12;            m; Depth of fresh snow
+  0;   13;     13;      2;          -2;   16;            m; Total snow depth (sss)
+  0;   13;     14;      4;           0;   12;    kg/m**2/s; Rainfall/water equivalent of snow (average rate)
+  0;   13;     15;      7;           0;   12;          m/s; Snowfall (averaged rate)
+  0;   13;     16;      0;           0;    7;      kg/m**2; Precipitable water (www)
+  0;   13;     19;      1;          -1;   14;      kg/m**2; Total precipitation past 1 hour
+  0;   13;     20;      1;          -1;   14;      kg/m**2; Total precipitation past 3 hours
+  0;   13;     21;      1;          -1;   14;      kg/m**2; Total precipitation past 6 hours
+  0;   13;     22;      1;          -1;   14;      kg/m**2; Total precipitation past 12 hours
+  0;   13;     23;      1;          -1;   14;      kg/m**2; Total precipitation past 24 hours (R24...R24)
+  0;   13;     31;      0;           0;    7;      kg/m**2; Evapotranspiration
+  0;   13;     32;      1;           0;    8;      kg/m**2; Evaporation/evapotranspiration
+  0;   13;     40;     -3;       -2048;   12;       W/m**2; Latent heat flux
+  0;   13;     41;      0;           0;    4;   Code_Table; Pasquill-Gifford stability category
+  0;   13;     42;      0;         -20;    6;        deg_K; Parcel lifted index (to 500 hPa)
+  0;   13;     43;      0;         -20;    6;        deg_K; Best lifted index (to 500 hPa)
+  0;   13;     51;      0;           0;    4;   Code_Table; Frequency group, precipitation
+  0;   13;     52;      1;          -1;   14;      kg/m**2; Highest daily amount of precipiation
+  0;   13;     71;      1;           0;    7;      kg/m**2; Liquid water
+  0;   13;     75;      0;           0;    8;      percent; Land snow cloud
+  0;   13;     76;      2;           0;    6;            m; Snow-water equivalent
+  0;   13;    176;      0;           0;    7;   Code_Table; Precipitable water precision flag
+  0;   13;    192;      0;           0;    4;   Code_Table; Precipitation identifier (iR)
+  0;   13;    193;      0;           0;   10;   Code_Table; Precipitation amount
+  0;   13;    194;      3;           0;   16;         g/kg; First guess mixing ratios
+  0;   13;    197;      0;           0;    3;   Code_Table; Rain indicator
+  0;   13;    203;      0;           0;    4;   Code_Table; Relative hunidity QC ID
+  0;   13;    217;      0;           0;    8;      Numeric; Precipitation flag (SSM/T)
+  0;   13;    218;      2;           0;   11;    kg/(m**2); Cloud water
+  0;   13;    219;      2;           0;   10;           cm; Total precipitable water
+  0;   13;    220;      1;           0;    9;        mm/hr; Rain rate
+  0;   13;    221;      2;           0;   14;    kg/(m**2); Cloud Liquid Water
+  0;   14;      1;     -3;       -2048;   12;       J/m**2; Longwave radiation, integrated over 24 hours (FLFLFL)
+  0;   14;      3;     -3;       -2048;   12;       J/m**2; Shortwave radiation, integrated over 24 hours (FiFiFi)
+  0;   14;      4;     -3;       -2048;   12;       J/m**2; Shortwave radiation, integrated over period specified (FsFsFs)
+  0;   14;     11;     -3;       -2048;   12;       J/m**2; Net longwave radiation, integrated over 24 hours
+  0;   14;     12;     -3;       -2048;   12;       J/m**2; Net longwave radiation, integrated over period specified
+  0;   14;     13;     -3;       -2048;   12;       J/m**2; Net shortwave radiation, integrated over 24 hours
+  0;   14;     14;     -3;       -2048;   12;       J/m**2; Net shortwave radiation, integrated over period specified
+  0;   14;     15;     -4;      -16384;   15;       J/m**2; Net radiation, integrated over 24 hours
+  0;   14;     16;     -4;      -16384;   15;       J/m**2; Net radiation, integrated over period specified
+  0;   14;     17;     -3;       -2048;   12;       W/m**2; Instantaneous long wave radiation
+  0;   14;     18;     -3;       -2048;   12;       W/m**2; Instantaneous short wave radiation
+  0;   14;     19;      0;           0;    7;      percent; Surface albedo
+  0;   14;     20;     -4;           0;   15;       J/m**2; Global solar radiation, integrated over 24 hours
+  0;   14;     21;     -4;           0;   15;       J/m**2; Global radiation, integrated over period specified
+  0;   14;     22;     -4;           0;   15;       J/m**2; Diffuse solar radiation, integrated over 24 hours
+  0;   14;     23;     -4;           0;   15;       J/m**2; Diffuse solar radiation, integratedi over period specified
+  0;   14;     24;     -4;           0;   15;       J/m**2; Direct solar radiation, integrated over 24 hours
+  0;   14;     25;     -4;           0;   15;       J/m**2; Direct solar radiation, integrated over period specified
+  0;   14;     31;      0;           0;   11;          min; Total sunshine
+  0;   14;     32;      0;           0;   10;           hr; Total sunshine
+  0;   14;     33;      0;           0;    9;      percent; Total sunshine (precentage)
+  0;   14;     41;      0;           0;    7;      percent; Short wave albedo
+  0;   14;     42;      0;           0;    7;      percent; Bi-directional reflectance
+  0;   15;      1;      0;           0;   10;  dobson_unit; Ozone
+  0;   15;      2;      2;           0;   10;      Numeric; Air-mass (slant path at 22 km)
+  0;   19;      1;      0;           0;    6;   Code_Table; Type of synoptic features
+  0;   19;      2;     -2;           0;   12;            m; Effective radius of feature
+  0;   19;      3;      0;           0;    8;          m/s; Wind speed threshold
+  0;   19;      4;     -2;           0;   12;            m; Effective radius of feature with respect to wind speeds above threshold
+  0;   19;      5;      0;           0;    9;     deg_true; Direction of motion of features (dsds)
+  0;   19;      6;      2;           0;   14;          m/s; Speed of motion of features
+  0;   19;      7;     -3;           0;   12;            m; Effective radius of features
+  0;   19;      8;      0;           0;    3;   Code_Table; Vertical extent of circulation
+  0;   19;      9;     -3;           0;   12;            m; Effective radiation with respect to FFF above threshold
+  0;   20;      1;     -1;           0;   13;            m; Horizontal visibility (Dv, Vi, V...V, or VxVxVxVx)
+  0;   20;      2;     -1;           0;    7;            m; Vertical visibility
+  0;   20;      3;      0;           0;    9;   Code_Table; Present weather (ww or w'w')
+  0;   20;      4;      0;           0;    5;   Code_Table; Past weather (1) (Wa1Wa2 or W1W2)
+  0;   20;      5;      0;           0;    5;   Code_Table; Past weather (2) (wawa)
+  0;   20;      9;     -1;         -40;   11;            m; Ceiling
+  0;   20;     10;      0;           0;    7;      percent; Cloud cover (total) (N, NcNc, or Ns...Ns)
+  0;   20;     11;      0;           0;    4;   Code_Table; Cloud amount (N or Ns...Ns)
+  0;   20;     12;      0;           0;    6;   Code_Table; Cloud type (C, Ct, CH, CL, or CM)
+  0;   20;     13;     -1;         -40;   11;            m; Height of base of cloud (h, hshs, hshshs, or H'H')
+  0;   20;     14;     -1;         -40;   11;            m; Height of top of cloud (HfHfHf or HtHt)
+  0;   20;     15;     -1;           0;   14;           Pa; Pressure at the base of cloud
+  0;   20;     16;     -1;           0;   14;           Pa; Pressure at the top of cloud (PcPcPc)
+  0;   20;     17;      0;           0;    4;   Code_Table; Cloud top description
+  0;   20;     18;     -1;          40;   11;            m; Low estimated height of cloud top
+  0;   20;     19;     -1;          40;   11;            m; High estimated height of cloud top (H1>Hn)
+  0;   20;     21;      0;           0;    4;   Code_Table; Middle cloud amount
+  0;   20;     22;      0;           0;    4;   Code_Table; High cloud amount
+  0;   20;     23;      0;           0;    7;      percent; Satellite sensed effective cloud amount
+  0;   20;     30;      0;           0;    4;   Code_Table; Total ice concentration
+  0;   20;     31;      2;           0;    7;            m; Ice deposit (thickness) (EsEs)
+  0;   20;     32;      0;           0;    3;   Code_Table; Rate of ice accretion (Rs)
+  0;   20;     33;      0;           0;    4;   Flag_Table; Cause of ice accretion (Is)
+  0;   20;     34;      0;           0;    5;   Code_Table; Sea ice concentration (Ci)
+  0;   20;     35;      0;           0;    4;   Code_Table; Amount and type of ice (zii...zii)
+  0;   20;     36;      0;           0;    5;   Code_Table; Ice situation
+  0;   20;     37;      0;           0;    5;   Code_Table; Ice development (bi)
+  0;   20;     38;      0;           0;   12;     deg_true; Bearing of ice edge
+  0;   20;     39;     -1;           0;   13;            m; Ice distance
+  0;   20;     41;      0;           0;    4;   Code_Table; Rate of icing (Ir)
+  0;   20;     49;      0;           0;   10;   Code_Table; Type of stability measure
+  0;   20;     50;      0;           0;   10;      Numeric; Value of stability
+  0;   20;     51;      0;           0;    7;      percent; Amount of low clouds
+  0;   20;     52;      0;           0;    7;      percent; Amount of middle clouds
+  0;   20;     53;      0;           0;    7;      percent; Amount of high clouds
+  0;   20;     61;      0;           0;   12;            m; Runway visual range (RVR) (VR...VR)
+  0;   20;     62;      0;           0;    5;   Code_Table; State of the ground (with or without snow) (E')
+  0;   20;     63;      0;           0;   10;   Code_Table; Special phenomena
+  0;   20;     71;      0;           0;    2;   Code_Table; Ice age code ID
+  0;   20;     72;      0;           0;    2;   Code_Table; Ice edge code ID
+  0;   20;    196;      0;           0;    8;    CCITT_IA5; Runway visibility tendency
+  0;   20;    197;      0;           0;    2;   Flag_Table; Landing wind shear indicator
+  0;   20;    199;      0;           0;    8;     deg_true; Visibility direction
+  0;   20;    205;      0;           0;   24;    CCITT_IA5; Cloud significant convection
+  0;   20;    206;      0;           0;   64;    CCITT_IA5; Significant present weather conditions
+  0;   20;    207;      0;           0;    4;   Code_Table; Pressure and altitude significance
+  0;   20;    208;      0;           0;    4;   Code_Table; Significant weather changes (Ws)
+  0;   20;    209;      0;           0;    4;   Code_Table; Distance of weather changes (Ss)
+  0;   20;    210;      0;           0;    4;   Code_Table; Distant weather (Wd)
+  0;   20;    211;      0;           0;    4;   Code_Table; Bearing of distant weather (dw)
+  0;   20;    213;      0;           0;    4;   Code_Table; Icing and contrail types (It)
+  0;   20;    216;      0;           0;    7;   Code_Table; Altitude of layer base where icing occurred (hihi)
+  0;   20;    219;      0;           0;    4;   Code_Table; Distance to center or line midpoint
+  0;   20;    220;      0;           0;    4;   Code_Table; Orientation of ellipse (Sr)
+  0;   20;    221;     -3;           0;   16;            m; Echo width or diameter (Ew)
+  0;   20;    222;     -3;           0;   16;            m; Echo axis length (El)
+  0;   20;    223;      0;           0;    8;   Code_Table; Echo character (ce)
+  0;   20;    224;      0;           0;    4;   Code_Table; Intensity of echo (Ie)
+  0;   20;    225;      0;           0;    3;   Code_Table; In flight horizontal visibility (Vi)
+  0;   20;    236;      0;           0;    8;    CCITT_IA5; Cloud base height
+  0;   20;    237;      0;           0;    7;   Code_Table; Horizontal visbility
+  0;   20;    240;      0;           0;    4;   Code_Table; Present weather (w)
+  0;   20;    242;      0;           0;    5;   Code_Table; Bearing of ice edge
+  0;   20;    244;      0;           0;    4;   Code_Table; cloud base height
+  0;   20;    245;      0;           0;  640;    CCITT_IA5; Remarks in plain language
+  0;   20;    246;      0;           0;    7;      percent; Ice coverage
+  0;   20;    247;      0;           0; 1656;    CCITT_IA5; Ice plain language text remarks
+  0;   20;    248;      0;           0;    7;   Code_Table; Height of base of cloud (hshs)
+  0;   20;    249;      0;           0;    7;   Code_Table; Height of top of cloud (HtHt)
+  0;   20;    254;      0;           0;    8;    CCITT_IA5; Extreme value indicator
+  0;   20;    255;      0;           0; 2040;    CCITT_IA5; Plain language text remarks
+  0;   21;      1;      0;         -64;    7;           dB; Horizontal reflectivity
+  0;   21;      2;      0;         -64;    7;           dB; Vertical reflectivity
+  0;   21;      3;      1;          -5;    7;           dB; Differential reflectivity
+  0;   21;      5;      0;         -65;    6;           dB; Linear depolarization ratio
+  0;   21;      6;      0;         -65;    6;           dB; Circular depolarization ratio
+  0;   21;     11;      0;        -128;    8;          m/s; Doppler mean velocity in X direction
+  0;   21;     12;      0;        -128;    8;          m/s; Doppler mean velocity in Y direction
+  0;   21;     13;      0;        -128;    8;          m/s; Doppler mean velocity in Z direction
+  0;   21;     14;      1;       -4096;   13;          m/s; Doppler mean velocity (radiational)
+  0;   21;     17;      1;       -4096;    8;          m/s; Doppler velocity spectral width
+  0;   21;     21;     -3;           0;    4;            m; Echo tops
+  0;   21;     30;      0;         -32;    8;           dB; Signal to noise ratio
+  0;   21;     31;      0;           0;    7;      kg/m**2; Vertical integrated liquid water content
+  0;   21;     36;      7;           0;   12;          m/s; Radar rainfall intensity
+  0;   21;     41;     -2;           0;    8;            m; Bright band height
+  0;   21;     51;      0;        -256;    8;           dB; Signal power above 1 MW
+  0;   21;    192;      0;           0;   14;            m; Heave sensor spectral peak length
+  0;   21;    193;      1;           0;   14;            s; Heave sensor spectral peak period
+  0;   21;    194;      2;           0;   14;      percent; AVHRR channel average
+  0;   21;    195;      2;           0;   14;      percent; Space view channel standard deviation
+  0;   21;    196;      2;           0;   15;        deg_K; Algorithm identifier
+  0;   21;    197;      2;           0;   15;        deg_K; AVHRR channel average
+  0;   21;    198;      2;       -5000;   13;           dB; Backscatter
+  0;   21;    199;      1;           0;   10;      percent; Noise figure percentage
+  0;   22;      1;      0;           0;    9;     deg_true; Direction of waves (dddd, da1da1, or d1d1>dndn)
+  0;   22;      2;      0;           0;    9;     deg_true; Direction of wind waves
+  0;   22;      3;      0;           0;    9;     deg_true; Direction of swell waves (dw1dw1 or dw2dw2)
+  0;   22;      4;      0;           0;    9;     deg_true; Direction of current (dodo>dndn or DcDc))
+  0;   22;     11;      0;           0;    6;            s; Period of waves (D'D'D'D', PaPaPaPa, or PwPw)
+  0;   22;     12;      0;           0;    6;            s; Period of wind waves
+  0;   22;     13;      0;           0;    6;            s; Period of swell waves (Pw1Pw1 or Pw2Pw2)
+  0;   22;     21;      1;           0;   10;            m; Height of waves (D'D'D'D' or HsHsHsHs)
+  0;   22;     22;      1;           0;   10;            m; Height of wind waves (HwHw)
+  0;   22;     23;      1;           0;   10;            m; Height of swell waves (Hw1Hw1 or Hw2Hw2)
+  0;   22;     25;      2;           0;   10;            m; Standard deviation wave
+  0;   22;     31;      2;           0;   13;          m/s; Speed of current (cococo>cncncn or VcVc)
+  0;   22;     41;      1;           0;   12;        deg_K; Sea surface temperature (15 day running mean)
+  0;   22;     42;      1;           0;   12;        deg_K; Sea temperature (T1T1T1>TnTnTn)
+  0;   22;     43;      2;           0;   15;        deg_K; Sea temperature (ToToToTo>TnTnTnTn)
+  0;   22;     44;      1;           0;   14;          m/s; Sound velocity
+  0;   22;     50;      2;           0;    8;        deg_K; Standard deviation sea surface temperature
+  0;   22;     61;      0;           0;    4;   Code_Table; State of sea
+  0;   22;     62;      2;           0;   14;          ppt; Salinity (SoSoSoSo>SnSnSnSn)
+  0;   22;     63;      0;           0;   14;            m; Total water depth (hhh or ZdZdZdZd)
+  0;   22;    105;     -1;           0;    6;     deg_true; Direction of waves (da2da2)
+  0;   22;    143;      2;           0;   13;        deg_K; Sea temperature
+  0;   22;    192;      0;           0;   14;            m; Wave length
+  0;   22;    193;      2;           0;   14;            m; Slope sensor significant wave height
+  0;   22;    194;      0;           0;   14;            m; Slope sensor spectral peak length
+  0;   22;    195;      1;           0;   14;            s; Slope sensor spectral peak period
+  0;   22;    196;      1;           0;   14;            s; Slope sensor mean wave period
+  0;   22;    197;      0;           0;   14;            m; Slope sensor mean wave length
+  0;   22;    198;      0;           0;    7;     deg_true; Wave directional spread
+  0;   22;    199;      1;           0;   14;            s; Time sample interval
+  0;   22;    200;      0;           0;   14;            m; Distance sample interval
+  0;   22;    201;      1;           0;   14;            s; Recorded wave duration
+  0;   22;    202;      0;           0;   14;            m; Recorded wave length
+  0;   22;    203;      0;           0;    7;      Numeric; Count of bands described
+  0;   22;    204;      0;           0;    4;   Code_Table; Wave expiration
+  0;   22;    205;      3;           0;   20; m**2/(Hz*rad); Wave spectra
+  0;   22;    206;      4;           0;   10;      Numeric; Drag coefficient
+  0;   22;    207;      2;           0;   16;            m; Maximum wave height
+  0;   22;    208;      2;           0;   16;            m; Significant wave height
+  0;   22;    209;      0;           0;    7;   Code_Table; directional spread
+  0;   22;    211;      0;           0;    8;   Code_Table; Bogus water mass classification
+  0;   22;    212;      0;           0;    8;   Code_Table; Discriminant water mass classification
+  0;   22;    213;      1;           0;   10;      percent; Classification probability
+  0;   22;    214;      0;           0;   10;      m**2/Hz; Heave sensor spectral density frequency
+  0;   22;    215;      0;           0;   10;         m**3; Heave sensor spectral density number
+  0;   22;    216;      0;           0;    7;      Numeric; Heave sensor band number
+  0;   22;    217;      0;           0;    7;      percent; Heave sensor ratio
+  0;   22;    218;      0;           0;    7;      Numeric; Slope sensor band number
+  0;   22;    219;      0;           0;    7;      percent; Slope sensor ratio
+  0;   22;    220;      0;           0;    8;   Code_Table; Front number
+  0;   22;    224;     -2;           0;   14;            m; Distance to front
+  0;   22;    229;      0;           0;    7;   Code_Table; Wave direction
+  0;   22;    232;      0;           0;    4;   Code_Table; Sea surface temperature method indicator
+  0;   22;    233;      0;           0;    3;   Code_Table; Sea temperature averaging period
+  0;   22;    236;      0;           0;    8;   Code_Table; Swell wave direction
+  0;   22;    237;     -2;           0;   14;            m; Significant wave height
+  0;   22;    238;     -2;           0;   14;            m; Maximum wave height
+  0;   22;    239;      0;           0;    6;      Numeric; Wave spectra direction count
+  0;   22;    240;      0;           0;    6;      Numeric; Wave spectra frequency count
+  0;   22;    241;      3;      -32768;   16;      Nt/m**2; Wave stress u-component
+  0;   22;    242;      3;      -32768;   16;      Nt/m**2; Wave stress v-component
+  0;   22;    243;      0;           0;    7;      percent; Whitecap probability
+  0;   22;    244;      0;           0;    7;   Code_Table; Estimated wave direction of spectral wave
+  0;   22;    245;      2;           0;   16;        deg_K; Surface temperature
+  0;   22;    246;      3;      -32768;   16;      Nt/m**2; Wind stress u-component
+  0;   22;    247;      3;      -32768;   16;      Nt/m**2; Wind stress v-component
+  0;   22;    248;      0;           0;   16;     deg_true; Wind wave direction
+  0;   22;    249;      2;           0;   16;            m; Height of wind wave
+  0;   22;    250;      1;           0;   16;            s; Period of wind waves
+  0;   22;    251;      0;           0;    6;      Numeric; Wave spectra direction
+  0;   22;    252;      0;           0;    6;      Numeric; Wave spectra frequency
+  0;   22;    253;      0;           0;   16;     deg_true; Direction of swell waves
+  0;   22;    254;      2;           0;   16;            m; Height of swell waves
+  0;   22;    255;      1;           0;   16;            s; Period of swell waves
+  0;   23;      1;      0;           0;    3;   Code_Table; Accident early notification - article applicable
+  0;   23;      2;      0;           0;    5;   Code_Table; Activity or facility involved in incident
+  0;   23;      3;      0;           0;    3;   Code_Table; Type of release
+  0;   23;      4;      0;           0;    3;   Code_Table; Countermeasures taken near border
+  0;   23;      5;      0;           0;    2;   Code_Table; Cause of incident
+  0;   23;      6;      0;           0;    3;   Code_Table; Incident situation
+  0;   23;      7;      0;           0;    3;   Code_Table; Characteristic of release
+  0;   23;      8;      0;           0;    2;   Code_Table; State of current release
+  0;   23;      9;      0;           0;    2;   Code_Table; State of expected release
+  0;   23;     16;      0;           0;    2;   Code_Table; Possibility of significant chemical toxic health effect
+  0;   23;     17;      6;           0;   20;       m**3/s; Flow discharge of major recipient
+  0;   23;     18;      0;           0;    3;   Code_Table; release behavior over time
+  0;   23;     19;      0;      -15000;   17;            m; Actual release height
+  0;   23;     21;      0;      -15000;   17;            m; Effective release height
+  0;   23;     22;      0;           0;   24;            m; Distance of relative point or site of incident
+  0;   23;     23;      1;           0;   12;          m/s; Main transport speed in atmosphere
+  0;   23;     24;      2;           0;   13;          m/s; Main transport speed in water
+  0;   23;     25;      2;           0;   13;          m/s; Main transport speed in ground water
+  0;   23;     27;      0;           0;    9;     deg_true; Main transport direction in atmosphere
+  0;   23;     28;      0;           0;    9;     deg_true; Main transport direction in water
+  0;   23;     29;      0;           0;    9;     deg_true; Main transport direction in ground water
+  0;   23;     31;      0;           0;    2;   Code_Table; Possibility that plume will encounter precip
+  0;   23;     32;      0;           0;    2;   Code_Table; Plume will encounter change in wind direction and/or speed flag
+  0;   24;      1;    -11;           0;   28;           Bq; Estimate of radioactivity released up to specified time
+  0;   24;      2;    -11;           0;   28;           Bq; Estimated maximum potential release
+  0;   24;      3;      0;           0;    5;   Code_Table; Composition of release
+  0;   24;      4;      0;           0;   16;    CCITT_IA5; Element name
+  0;   24;      5;      0;           0;    9;      Numeric; Isotope mass
+  0;   24;     11;      2;           0;   32;          mSv; Dose
+  0;   24;     12;      2;           0;   32;          mSv; Trajectory dose (defined location and expected time of arrival)
+  0;   24;     13;      2;           0;   32;          mSv; Gamma dose in air along the main transport path
+  0;   24;     21;      2;           0;   32;      Bq/m**3; Air concentration (named isotope type including gross beta)
+  0;   24;     22;      2;           0;   32;         Bq/l; Concentration in precipitation (of named isotope type)
+  0;   25;      1;     -1;           0;    6;            m; Range gate length
+  0;   25;      2;      0;           0;    4;      Numeric; Number of gates averaged
+  0;   25;      3;      0;           0;    8;      Numeric; Number of integrated pulses
+  0;   25;      4;      0;           0;    2;   Code_Table; Echo processing
+  0;   25;      5;      0;           0;    2;   Code_Table; Echo integration
+  0;   25;      6;      0;           0;    3;   Code_Table; Z to R conversion
+  0;   25;      7;      0;           0;   12;      Numeric; Z to R conversion factor
+  0;   25;      8;      2;           0;    9;      Numeric; Z to R conversion exponent
+  0;   25;      9;      0;           0;    4;   Flag_Table; Calibration method
+  0;   25;     10;      0;           0;    4;   Code_Table; Clutter treatment
+  0;   25;     11;      0;           0;    2;   Code_Table; Ground occultation correction (screening)
+  0;   25;     12;      0;           0;    2;   Code_Table; Range attenuation correction
+  0;   25;     13;      0;           0;    2;   Flag_Table; Bright band correction
+  0;   25;     15;      0;           0;    2;   Flag_Table; Radome attenuation correction
+  0;   25;     16;      5;           0;    6;         dB/m; Clear air attenuation correction
+  0;   25;     17;      0;           0;    2;   Flag_Table; Precipitation attenuation correction
+  0;   25;     18;      7;           0;    6;      Numeric; A to Z law for attenuation factor
+  0;   25;     19;      2;           0;    7;      Numeric; A to Z law for attenuation exponent
+  0;   25;     20;      0;           0;    2;   Code_Table; Mean speed estimation
+  0;   25;     21;      0;           0;    8;   Flag_Table; Wind computation enhancement
+  0;   25;     30;      0;           0;    2;   Code_Table; SST usage
+  0;   25;     31;      0;           0;    2;   Code_Table; 15 day SST availability
+  0;   25;     32;      0;           0;    2;   Code_Table; NOAA wind profiler high/low mode data
+  0;   25;     33;      0;           0;    2;   Code_Table; NOAA wind profiler submode
+  0;   25;     34;      0;           0;    4;   Code_Table; NOAA wind profiler Q/C test results
+  0;   25;     35;      0;           0;    3;   Code_Table; First guess adjustment
+  0;   25;     36;      3;       -5000;   14;      Numeric; NSTAR average value
+  0;   25;     37;      0;           0;    2;   Code_Table; HIRS-8 surface air temperature
+  0;   25;     38;      0;           0;    3;   Code_Table; TOVS filter flags
+  0;   25;     41;      0;           0;    3;   Code_Table; Method of determining direction of moving platform
+  0;   25;     42;      0;           0;    3;   Code_Table; Method of determining speed of moving platform
+  0;   25;    192;      0;           0;    8;   Code_Table; Type of correction
+  0;   25;    193;      0;           0;    3;   Code_Table; Land/sea flag
+  0;   25;    194;      0;           0;    2;   Code_Table; Day/night flag
+  0;   25;    195;      0;           0;    6;      Numeric; Surface model pressure
+  0;   25;    196;      0;           0;   16;      Numeric; Scan line count
+  0;   25;    197;      0;           0;    5;      Numeric; Box counter
+  0;   25;    198;      0;           0;    3;      Numeric; Minibox counter
+  0;   25;    199;      0;           0;    3;   Code_Table; Water vapor flag
+  0;   25;    200;      0;           0;    3;   Code_Table; TOVS retrieval low 20
+  0;   25;    201;      0;           0;    3;   Code_Table; TOVS retrieval temps high 20
+  0;   25;    202;      0;           0;    2;   Code_Table; TOVS super adiabatic flag
+  0;   25;    203;      0;           0;    2;   Code_Table; TOVS skin temperature flag
+  0;   25;    204;      0;           0;    2;   Code_Table; Stratospheric sounding unit flag
+  0;   25;    205;      0;           0;    4;   Code_Table; Latitude zones
+  0;   25;    206;      0;           0;    4;   Code_Table; TOVS instrument combinations
+  0;   25;    208;      0;           0;    8;   Code_Table; TARM flag
+  0;   25;    209;      0;           0;    4;   Code_Table; DMSP flag
+  0;   25;    211;      0;           0;   17;      Numeric; B-scan start time
+  0;   25;    212;      0;           0;    7;      Numeric; Counter (1-64)
+  0;   25;    213;      0;           0;    5;   Code_Table; Calculated surface type
+  0;   25;    214;      0;           0;    3;   Code_Table; Season flag
+  0;   25;    215;      0;        -127;    8;      Numeric; Missing packet counter
+  0;   25;    216;      0;           0;    3;   Code_Table; Observation Quality Code
+  0;   26;      1;      1;           0;   12;           hr; Principle time of daily reading in UTC of maximum temperature
+  0;   26;      2;      1;           0;   12;           hr; Principle time of daily reading in UTC of minimum temperature
+  0;   27;      1;      5;    -9000000;   25;          deg; Latitude (high accuracy)
+  0;   27;      2;      2;       -9000;   15;          deg; Latitude (coarse accuracy)
+  0;   27;      3;      2;       -9000;   15;          deg; Alternate latitude
+  0;   27;     20;      0;           0;   16;      Numeric; Satellite location counter
+  0;   27;     21;      0;           0;   16;      Numeric; Satellite sub-location dimensions
+  0;   28;      1;      5;   -18000000;   26;          deg; Longtiude (high accuracy)
+  0;   28;      2;      2;      -18000;   16;          deg; Longtiude (coarse accuracy)
+  0;   28;      3;      2;      -18000;   16;          deg; Alternate longtiude
+  0;   29;      1;      0;           0;    3;   Code_Table; Projection type
+  0;   29;      2;      0;           0;    2;   Code_Table; Coordinate grid type (Wr)
+  0;   30;      1;      0;           0;    4;      Numeric; Pixel value (4 bits)
+  0;   30;     21;      0;           0;   12;      Numeric; Number of pixels per row
+  0;   30;     22;      0;           0;   12;      Numeric; Number of pixels per column
+  0;   30;     31;      0;           0;    4;   Code_Table; Picture type
+  0;   30;     32;      0;           0;   16;   Flag_Table; Combined picture
+  0;   31;      0;      0;           0;    1;   Flag_Table; Delayed descriptor replication switch (1 bit)
+  0;   31;      1;      0;           0;    8;      Numeric; Delayed descriptor replication factor (255 or less)
+  0;   31;      2;      0;           0;   16;      Numeric; Extended delayed descriptor replication factor (65536 or less)
+  0;   31;     11;      0;           0;    8;      Numeric; Delayed descriptor and data replication factor
+  0;   31;     12;      0;           0;   16;      Numeric; Extended delayed descriptor and data replication factor
+  0;   31;     21;      0;           0;    6;   Code_Table; Associated field significance
+  0;   31;    192;      0;           0;    8;   Code_Table; Associated QC indicator
+  0;   31;    193;      0;           0;    8;   Code_Table; QC description identifier, indicates why a value is bad
+  0;   31;    194;      2;           0;    7;      Numeric; Associated correlation
+  0;   31;    195;      2;           0;    7;      Numeric; Associated probability of error
+  0;   31;    196;      0;           0;   13;   Flag_Table; UWI product confidence flag
+  0;   31;    197;      0;           0;   12;      Numeric; Solution probability
+  0;   31;    201;      0;           0;   10;      Numeric; Delayed replication factor (1023 or less)
+  0;   31;    211;      0;           0;    3;      Numeric; Delayed replication factor (15 or less)
+  0;   31;    221;      0;           0;    5;      Numeric; Delayed replication count (31 or less)
+  0;   31;    231;      0;           0;    6;      Numeric; Delayed replication factor (63 or less)
+  0;   31;    241;      0;           0;    4;      Numeric; Delayed replication factor (15 or less)
+  0;   48;      1;      0;           0;  128;    CCITT_IA5; Classification
+  0;   48;      2;      0;           0;  128;    CCITT_IA5; Classification modifier
+  0;   48;      3;      0;           0;  552;    CCITT_IA5; Release as
+  0;   48;      4;      0;           0;   12;           yr; Declassification - year
+  0;   48;      5;      0;           0;    4;           mo; Declassification - month
+  0;   48;      6;      0;           0;    6;          day; Declassification - day
+  0;   48;      7;      0;           0;  552;    CCITT_IA5; Release not
+  0;   48;      8;      0;           0;   64;    CCITT_IA5; Sender of original observation data
+  0;   48;      9;      0;           0;   80;    CCITT_IA5; Declassification instructions
+  0;   48;     10;      0;           0;   12;           yr; Send - year
+  0;   48;     11;      0;           0;    4;           mo; Send - month
+  0;   48;     12;      0;           0;    6;          day; Send - day
+  0;   48;     13;      0;           0;    4;           hr; Send - hour
+  0;   48;     14;      0;           0;    6;          min; Send - minutes
+  0;   48;     15;      0;           0;  552;    CCITT_IA5; Release to information
+  0;   48;     16;      0;           0;    5;           hr; Send - hour
+  0;   48;     17;      0;           0; 1104;    CCITT_IA5; Release to
+  0;   48;     18;      0;           0;  552;    CCITT_IA5; Release not
+  0;   48;     19;      0;           0;  552;    CCITT_IA5; Declassification instructions
+  0;   48;     20;      0;           0;  552;    CCITT_IA5; Classification modifier
+  0;   48;     21;      0;           0;  552;    CCITT_IA5; Sender of observational data
+  0;   48;     22;      0;           0;  160;    CCITT_IA5; Classification
+  0;   48;     27;      0;           0;   12;           yr; Receipt - year
+  0;   48;     28;      0;           0;    4;           mo; Receipt - month
+  0;   48;     29;      0;           0;    6;          day; Receipt - day
+  0;   48;     30;      0;           0;    5;           hr; Receipt - hour
+  0;   48;     31;      0;           0;    6;          min; Receipt - minutes
+  0;   48;     32;      0;           0;   48;    CCITT_IA5; Bulletin header update or correction indicator
+  0;   48;     33;      0;           0;   24;    CCITT_IA5; Receiving circuit
+  0;   48;     34;      0;           0;    6;      Numeric; Near-duplicate combination count
+  0;   50;      1;      0;           0;    2;   Code_Table; Quality of measurement of pressure, sst,
+  0;   50;      2;      0;           0;    2;   Code_Table; Quality of buoy satellite transmission (QN)
+  0;   50;      3;      0;           0;    4;   Code_Table; IGOSS quality codes (Qd, Qd1, Qd2, Q1, Qt)
+  0;   50;      6;      0;           0;    3;   Code_Table; Location quality codes (QL)
+  0;   50;     10;      2;           0;   15;        deg_K; GDEM temperature
+  0;   50;     14;      2;           0;   15;        deg_K; Feature model temperature
+  0;   50;     18;      0;           0;   16;      Numeric; Reliability
+  0;   50;     33;      0;           0;    8;      Numeric; Count of boundary points
+  0;   50;     34;      3;           0;   16;      Numeric; Frequency ratio
+  0;   50;     35;      0;           0;   12;            s; Time step of data (time increment)
+  0;   50;     42;      2;           0;   12;      Numeric; Mean wave direction
+  0;   50;     43;      3;           0;   12;      Numeric; Mean wave frequency
+  0;   50;     44;      4;           0;   12;      Numeric; First frequency
+  0;   50;    100;      0;           0;   12;           yr; Analysis DTG - year
+  0;   50;    101;      0;           0;    4;           mo; Analysis DTG - month
+  0;   50;    102;      0;           0;    6;          day; Analysis DTG - day
+  0;   50;    103;      0;           0;    5;           hr; Analysis DTG - hour
+  0;   50;    104;      0;           0;    6;      Numeric; Last observed sea depth
+  0;   51;      3;      0;           0;    5;   Flag_Table; Processing status
+  0;   51;      6;      0;           0;    6;      Numeric; Combination count
+  0;   51;      7;      0;           0;    2;   Code_Table; Quality control process status
diff --git a/data/tables/B2L-058-001-B.001 b/data/tables/B2L-058-001-B.001
new file mode 100644
index 0000000..bd3db56
--- /dev/null
+++ b/data/tables/B2L-058-001-B.001
@@ -0,0 +1,779 @@
+#
+# B2L-058-001-B.001 - Local BUFR Table B for center 058 (FNMOC),
+# Minor Local Version 1
+#
+#					Data
+#F	X	Y	Scale	RefVal	Width	Units	Element Name
+0	0	1	0	0	24	CCITT_IA5	Table A: entry
+0	0	2	0	0	256	CCITT_IA5	Table A: data category description, line 1
+0	0	3	0	0	256	CCITT_IA5	Table A: data category description, line 2
+0	0	5	0	0	24	CCITT_IA5	BUFR edition number
+0	0	10	0	0	8	CCITT_IA5	F descriptor to be added or defined
+0	0	11	0	0	16	CCITT_IA5	X descriptor to be added or defined
+0	0	12	0	0	24	CCITT_IA5	Y descriptor to be added or defined
+0	0	13	0	0	256	CCITT_IA5	Element name, line 1
+0	0	14	0	0	256	CCITT_IA5	Element name, line 2
+0	0	15	0	0	192	CCITT_IA5	Units name
+0	0	16	0	0	8	CCITT_IA5	Units scale sign
+0	0	17	0	0	24	CCITT_IA5	Units scale (u)
+0	0	18	0	0	8	CCITT_IA5	Units reference sign
+0	0	19	0	0	80	CCITT_IA5	Units reference value
+0	0	20	0	0	24	CCITT_IA5	Element data width
+0	0	30	0	0	40	CCITT_IA5	Descriptor defining sequence
+0	1	1	0	0	7	Numeric	WMO block number (II)
+0	1	2	0	0	10	Numeric	WMO station number (iii)
+0	1	3	0	0	3	Numeric	WMO region number
+0	1	4	0	0	3	Numeric	WMO region sub-area
+0	1	5	0	0	17	Numeric	Buoy/platform identifier
+0	1	6	0	0	64	CCITT_IA5	Aircraft identifier (flight number) (Ia...Ia)
+0	1	7	0	0	10	Code_Table	Satellite identifier (I1I2I2)
+0	1	8	0	0	64	CCITT_IA5	Aircraft registration number (tail number)
+0	1	9	0	0	64	CCITT_IA5	Type of commerical aircraft
+0	1	10	0	0	64	CCITT_IA5	Stationary buoy platform identifier
+0	1	11	0	0	72	CCITT_IA5	Ship call sign (D...D)
+0	1	12	0	0	9	deg_true	Direction of motion of moving observing platform (dBdB)
+0	1	13	0	0	10	m/s	Speed of motion of moving observing platform
+0	1	14	2	0	10	m/s	Platform drift speed (high precision) (VBVB)
+0	1	21	0	0	14	Numeric	Synoptic feature identifier
+0	1	25	0	0	24	CCITT_IA5	Storm identifier
+0	1	26	0	0	64	CCITT_IA5	WMO storm name
+0	1	31	0	0	16	Numeric	Generating center
+0	1	50	0	0	48	CCITT_IA5	NMC report identifier
+0	1	62	0	0	40	CCITT_IA5	National assigned station identifier
+0	1	63	0	0	64	CCITT_IA5	ICAO location indicator (CCCC)
+0	1	192	0	0	24	CCITT_IA5	Receiving circuit
+0	1	193	0	0	4	Code_Table	global octant
+0	1	195	0	0	10	Numeric	Marsden square number
+0	1	197	0	0	6	Numeric	Runway number
+0	1	198	0	0	16	Code_Table	Sea station type
+0	1	200	0	0	2	Code_Table	Radar Capability indicator (XXX)
+0	1	201	0	0	8	Code_Table	Country or agency that operates the satellite
+0	1	203	0	0	16	CCITT_IA5	Satellite name
+0	1	204	0	0	16	CCITT_IA5	Satellite series
+0	1	206	0	0	32	CCITT_IA5	TOVS generating center name
+0	1	207	0	0	72	CCITT_IA5	File name
+0	1	208	0	0	4	Code_Table	Satellite data type
+0	1	209	0	0	8	Code_Table	Observation type for MCSST
+0	1	210	0	0	7	Code_Table	Observation source
+0	1	211	0	0	4	Numeric	Beam position
+0	1	212	0	0	24	Numeric	Data processing block number
+0	1	213	0	0	3	Code_Table	Tip source type identifier
+0	1	214	0	0	32	CCITT_IA5	Header originator
+0	1	215	0	0	48	CCITT_IA5	Bulletin header update or correction indicator
+0	1	216	0	0	14	Numeric	Engineering status
+0	1	217	0	0	5	Numeric	Satellite number
+0	1	218	0	0	176	CCITT_IA5	Sequence (report) type
+0	1	219	0	0	40	CCITT_IA5	Mission number
+0	1	220	0	0	7	Numeric	Observation number
+0	1	221	0	0	8	Code_Table	Surface type
+0	1	222	0	0	32	CCITT_IA5	Report modifier
+0	1	223	0	0	3	Code_Table	Runway parallel indicator
+0	1	224	0	0	5	Code_Table	Terrain code identifier
+0	2	1	0	0	2	Code_Table	Type of station (ix)
+0	2	2	0	0	4	Flag_Table	Type of instrumentation for wind measurement (ewew)
+0	2	3	0	0	4	Code_Table	Type of measuring instrumentation used (a4, I3, or I4)
+0	2	4	0	0	4	Code_Table	Type of instrumentation for evaporation measur
+0	2	5	2	0	7	deg_K	Precision of temperature observed (s3)
+0	2	11	0	0	8	Code_Table	Radiosonde type (rara)
+0	2	12	0	0	4	Code_Table	Radiosonde computational method
+0	2	13	0	0	4	Code_Table	Solar and infrared radiation correction (Sr)
+0	2	14	0	0	7	Code_Table	Tracking technique/status of system (sasa)
+0	2	15	0	0	4	Code_Table	Radiosonde completeness
+0	2	21	0	0	9	Flag_Table	Satellite instrumentation data used in processing
+0	2	22	0	0	8	Flag_Table	Satellite data processing technique used
+0	2	23	0	0	4	Code_Table	Cloud motion computational method
+0	2	24	0	0	4	Code_Table	Integrated mean humidity computational method
+0	2	25	0	0	25	Flag_Table	Satellite channel(s) used in computation
+0	2	26	2	0	12	m	Cross track resolution
+0	2	27	2	0	12	m	Along track resolution
+0	2	28	0	0	32	Flag_Table	Geostationary sounder satellite channels used
+0	2	29	0	0	8	Flag_Table	Geostationary sounder satellite channels used
+0	2	30	0	0	3	Code_Table	Method of current measurement (k5)
+0	2	31	0	0	5	Code_Table	Duration and time of current measurement
+0	2	32	0	0	2	Code_Table	Indicator for digitization (k1)
+0	2	33	0	0	3	Code_Table	Method of salinity/depth measurement (k2)
+0	2	34	0	0	5	Code_Table	Drogue type (id)
+0	2	35	0	0	9	m	Cable length (ZdZdZd)
+0	2	36	0	0	2	Code_Table	Buoy type (Ip or Vi...Vi)
+0	2	38	0	0	4	Code_Table	Sea surface temperature method indicator
+0	2	39	0	0	4	Code_Table	Wet bulb temperature method indicator
+0	2	40	0	0	4	Code_Table	Method of removing velocity and motion
+0	2	41	0	0	6	Code_Table	Method for estimating reports related to synoptic features
+0	2	42	0	0	6	Code_Table	Method of report construction (Qn)
+0	2	43	0	0	6	Code_Table	Precision of latitude/longitude report (At or QL)
+0	2	47	0	0	4	Code_Table	Method of removing ship velocity
+0	2	51	0	0	4	Code_Table	Indicator to specify observing method for extreme temperatures
+0	2	61	0	0	3	Code_Table	Aircraft navigation system (s1)
+0	2	62	0	0	4	Code_Table	Type of aircraft data relay system
+0	2	63	2	-18000	16	deg	Aircraft roll angle
+0	2	70	0	0	4	Code_Table	Original specification of latitude/longitude
+0	2	101	0	0	4	Code_Table	Type of antenna
+0	2	102	0	0	8	m	Antenna height above tower
+0	2	103	0	0	2	Flag_Table	Radome
+0	2	104	0	0	4	Code_Table	Antenna polarisation
+0	2	105	0	0	6	dB	Maximum antenna gain
+0	2	106	1	0	6	deg	3-dB bandwidth
+0	2	107	0	0	6	dB	Sidelobe suppression
+0	2	108	0	0	6	dB	Crosspol discrimination (on axis)
+0	2	109	2	0	12	deg/s	Antenna speed (azimuth)
+0	2	110	2	0	12	deg/s	Antenna speed (elevation)
+0	2	111	1	0	10	deg	Radar incidence angle
+0	2	112	1	0	12	deg	Radar azimuth angle
+0	2	113	0	0	4	Numeric	Number of azimuth looks
+0	2	114	0	0	15	m**2	Antenna effective surface area
+0	2	121	-8	0	7	Hz	Mean frequency
+0	2	122	-6	-128	8	Hz	Frequency agility range
+0	2	123	-4	0	7	W	Peak power
+0	2	124	-1	0	7	W	Average power
+0	2	125	-1	0	8	Hz	Pulse repetition frequency
+0	2	126	7	0	6	s	Pulse width
+0	2	127	-6	0	7	Hz	Receiver intermediate frequency
+0	2	128	-5	0	6	Hz	Intermediate frequency bandwidth
+0	2	129	0	-150	5	dB	Minimum detectable signal
+0	2	130	0	0	7	dB	Dynamic range
+0	2	131	0	0	2	Flag_Table	Sensitivity time control
+0	2	132	2	0	6	deg	Azimuth pointing accuracy
+0	2	133	2	0	6	deg	Elevation pointing accuracy
+0	2	134	2	0	16	deg	Antenna beam azimuth
+0	2	135	2	-9000	15	deg	Antenna elevation
+0	2	141	0	0	24	CCITT_IA5	Measurement type serial number/identifier
+0	2	142	0	0	8	Code_Table	Ozone instrument
+0	2	143	0	0	7	Numeric	Instrument type
+0	2	190	0	0	8	Code_Table	U, v quality indicator
+0	2	191	0	0	4	Code_Table	W quality indicator
+0	2	194	0	0	8	Code_Table	Spectral calculation method
+0	2	199	0	0	4	Numeric	grp_pos_ind
+0	2	203	0	0	3	Code_Table	Method of determining direction of moving platform
+0	2	204	0	0	3	Code_Table	Method of determining speed of moving platform
+0	2	205	0	0	3	Code_Table	Ozone flag
+0	2	206	0	0	4	Code_Table	Algorithm identifier
+0	2	207	0	0	5	Code_Table	Equation identifier
+0	2	208	0	0	2	Code_Table	Type of method for measuring pressure
+0	2	209	0	0	10	Code_Table	Xbt instrument type (IxIxIx)
+0	2	210	0	0	7	Code_Table	Recorder type (XRXR)
+0	2	211	0	0	8	Flag_Table	Sensor status flag
+0	2	212	0	0	2	Flag_Table	Maintenance Check flag
+0	4	1	0	0	12	yr	Year (4-digit)
+0	4	2	0	0	4	mo	Month
+0	4	3	0	0	6	day	Day
+0	4	4	0	0	5	hr	Hour
+0	4	5	0	0	6	min	Minute
+0	4	6	0	0	6	s	Second
+0	4	11	0	-1024	11	yr	Time increment - year
+0	4	12	0	-1024	11	mo	Time increment - month
+0	4	13	0	-1024	11	day	Time increment - day
+0	4	14	0	-1024	11	hr	Time increment - hour
+0	4	15	0	-2048	12	min	Time increment - minutes
+0	4	16	0	-4096	13	s	Time increment - seconds
+0	4	21	0	-1024	11	yr	Time period or displacement - year
+0	4	22	0	-1024	11	mo	Time period or displacement - month
+0	4	23	0	-1024	11	day	Time period or displacement - month
+0	4	24	0	-2048	12	hr	Time period or displacement - hour
+0	4	25	0	-2048	12	min	Time period or displacement - minutes
+0	4	26	0	-4096	13	s	Time period or displacement - seconds
+0	4	31	0	0	8	hr	Duration of time relative to following value (TT)
+0	4	41	0	-1440	12	min	Time difference, UTC - LMT
+0	4	43	0	0	9	day	Day of the year
+0	4	44	0	0	3	Code_Table	Day of the week (Y)
+0	4	53	0	0	6	Numeric	Number of days with precipitation equal or more than 1 mm
+0	4	70	0	0	8	Numeric	Sample number
+0	4	192	0	0	4	Code_Table	Precipitation time period (tR)
+0	4	193	0	0	31	Code_Table	Last time that this observation record was updated
+0	4	200	0	0	12	yr	Time of receipt - year
+0	4	201	0	0	4	mo	Time of receipt - month
+0	4	202	0	0	6	day	Time of receipt - day
+0	4	203	0	0	5	hr	Time of receipt - hour
+0	4	204	0	0	6	min	Time of receipt - minute
+0	4	206	3	0	27	s	GMT seconds
+0	5	1	5	-9000000	25	deg	Latitude (high accuracy)
+0	5	2	2	-9000	15	deg	Latitude (coarse accuracy) (La...La)
+0	5	3	2	-9000	15	deg	Alternate latitude
+0	5	11	5	-9000000	25	deg	Latitude increment (high accuracy)
+0	5	12	2	-9000	15	deg	Latitude increment (coarse accuracy)
+0	5	21	2	0	16	deg_true	Bearing or azimuth
+0	5	22	2	0	16	deg_true	Solar azimuth
+0	5	30	0	0	12	deg	Direction (spectral)
+0	5	31	0	0	12	Numeric	Row number
+0	5	33	-1	0	16	m	Pixel size on horizontal - 1
+0	5	40	0	0	24	Numeric	Orbit number
+0	5	41	0	0	8	Numeric	Scan line number
+0	5	42	0	0	6	Numeric	Channel number
+0	5	43	0	0	8	Numeric	Field of view number
+0	5	50	5	0	17	Numeric	Sigma level
+0	5	52	0	0	5	Numeric	Channel number increment
+0	5	53	0	0	5	Numeric	Field of view number increment
+0	5	192	0	0	3	Numeric	Image line number
+0	5	193	0	0	4	Numeric	Image sample number
+0	5	194	0	0	14	Numeric	Orbit number
+0	5	196	0	0	16	Numeric	Orbit number
+0	5	197	0	0	8	Numeric	Frame number
+0	5	199	0	0	20	Numeric	Orbit number
+0	6	1	5	-18000000	26	deg	Longtiude (high accuracy)
+0	6	2	2	-18000	16	deg	Longtiude (coarse accuracy) (Lo...Lo)
+0	6	3	2	-18000	16	deg	Alternate longtiude
+0	6	11	5	-18000000	26	deg	Longtiude increment (high accuracy)
+0	6	12	2	-18000	16	deg	Longtiude increment (coarse accuracy)
+0	6	21	-1	0	13	m	Distance
+0	6	30	5	0	13	rad/m	Wavenumber (spectral)
+0	6	31	0	0	12	Numeric	Column number
+0	6	33	-1	0	16	m	Pixel size on horizontal - 2
+0	7	1	0	-400	15	m	Height of station (hohohoho)
+0	7	2	-1	-40	16	m	Height or altitude (hahaha, hIhIhI, HmHmHm, HH, tnu2, or tnu3)
+0	7	3	-1	-400	17	m**2/s**2	Geopotential
+0	7	4	-1	0	14	Pa	Pressure (Pa...Pa, Paob...Paob, Po...Po, PtPtPt, or PAPA)
+0	7	5	0	-400	12	m	Height increment
+0	7	6	0	0	15	m	Height above station
+0	7	7	0	-1000	17	m	Geopotential height
+0	7	21	2	-9000	15	deg	Elevation
+0	7	22	2	-9000	15	deg	Solar elevation
+0	7	61	2	0	14	m	Depth below land surface
+0	7	62	1	0	17	m	Depth below sea surface
+0	7	190	0	0	12	m	Height increment
+0	7	192	2	0	13	deg	Local zenith angle
+0	7	196	0	0	4	Code_Table	Station height precision
+0	7	197	1	0	11	deg	Solar zenith angle
+0	7	198	2	-6000	14	deg	Satellite zenith angle
+0	7	199	1	0	11	deg	Solar azimuth angle
+0	7	223	2	0	14	deg	Solar zenith angle
+0	7	224	1	0	14	m	Surface elevation
+0	8	0	0	0	4	Code_Table	Vertical significance (forecast soundings)
+0	8	1	0	0	7	Flag_Table	Vertical sounding significance
+0	8	2	0	0	6	Code_Table	Vertical significance (surface observations)
+0	8	3	0	0	6	Code_Table	Vertical significance (satellite observations)
+0	8	4	0	0	3	Code_Table	Phase of aircraft flight (ipipip)
+0	8	5	0	0	4	Code_Table	Surface synoptic features significance
+0	8	11	0	0	6	Code_Table	Horizontal significance
+0	8	12	0	0	2	Code_Table	land/sea qualifier
+0	8	13	0	0	2	Code_Table	Day/night qualifier
+0	8	21	0	0	5	Code_Table	Time significance
+0	8	22	0	0	16	Numeric	Total number (with respect to accumulation or average)
+0	8	24	0	0	8	Code_Table	Type of difference
+0	8	31	0	0	8	CCITT_IA5	Data category
+0	8	32	0	0	14	Code_Table	Data significance for simulated forecast
+0	8	33	0	0	3	Code_Table	Data significance for corrected forecast
+0	8	34	0	0	3	Code_Table	Data significance for simulated retrievals
+0	8	35	0	0	3	Code_Table	Data significance for corrected retrievals
+0	8	36	0	0	3	Code_Table	Data significance for simulated analysis
+0	8	37	0	0	3	Code_Table	Data significance for corrected analysis
+0	8	38	0	0	3	Code_Table	Data significance for sigma level data
+0	8	51	0	0	3	Code_Table	Qualifier for number of missing values in calculation of statistic
+0	8	52	0	0	5	Code_Table	Condition for which number of days of occurrence follows
+0	8	53	0	0	2	Code_Table	Day of occurrence qualifier
+0	8	70	0	0	8	Code_Table	Surface Type Code ID
+0	8	194	0	0	4	Code_Table	Flight condition (fc)
+0	10	1	0	-400	15	m	Height of land surface
+0	10	2	-1	-40	16	m	Height (HHH)
+0	10	3	-1	-400	17	m**2/s**2	Geopotential
+0	10	4	-1	0	14	Pa	Pressure
+0	10	7	0	-1000	17	m	Geopotential height
+0	10	50	2	0	16	m	Standard deviation altitude
+0	10	51	-1	0	14	Pa	Pressure reduced to mean sea level (PPPP)
+0	10	52	-1	0	14	Pa	Altimeter setting (QNH) (PH...PH)
+0	10	60	-1	-1024	11	Pa	Pressure change (ppp)
+0	10	61	-1	-500	10	Pa	3 hour pressure change
+0	10	62	-1	-1000	11	Pa	24 hour pressure change
+0	10	63	0	0	4	Code_Table	Characteristic of pressure tendency (a, w, or w'w')
+0	10	103	0	0	4	Code_Table	Geopotential thickness QC ID
+0	10	197	0	0	4	Code_Table	Index pertaining to geopotential height (j)
+0	10	199	0	-1024	16	m	Geopotential height difference
+0	10	200	0	-1024	16	m	Geopotental height correction
+0	10	201	0	0	14	Code_Table	Pressure tendency QC ID
+0	10	203	0	0	4	Code_Table	Geopotential height quality control flag
+0	10	213	0	-1024	16	m	Geopotential height
+0	10	224	0	0	4	Code_Table	Station level pressure QC ID
+0	10	251	0	0	4	Code_Table	Mean sea level pressure QC ID
+0	11	1	0	0	9	deg_true	Wind direction (dd, dodo>dndn, dmagdmag)
+0	11	2	1	0	12	m/s	Wind speed (ff, fff, or fofofo>fnfnfn)
+0	11	3	1	-4096	13	m/s	U-component
+0	11	4	1	-4096	13	m/s	V-component
+0	11	5	1	-512	10	Pa/s	W-component
+0	11	6	2	-4096	13	m/s	W-component
+0	11	11	0	0	9	deg_true	Wind direction at 10 m
+0	11	12	1	0	12	m/s	Wind speed at 10 m
+0	11	13	0	0	9	deg_true	Wind direction at 5 m
+0	11	14	1	0	12	m/s	Wind speed at 5 m
+0	11	21	9	-65536	17	1/s	Relative vorticity
+0	11	22	9	-65536	17	1/s	Divergence
+0	11	23	-2	-65536	17	m**2/s	Velocity potential
+0	11	31	0	0	4	Code_Table	Degree of turbulence (B...B or BA)
+0	11	32	-1	-40	16	m	Height of base of turbulence (BabBabBab or B1B1B1)
+0	11	33	-1	-40	16	m	Height of top of turbulence (BatBatBat or B1B1B1)
+0	11	34	1	-1024	11	m/s	Vertical gust velocity
+0	11	35	2	-8192	14	m/s**2	Vertical gust acceleration
+0	11	36	1	0	10	m/s	Maximum derived equivalent vertical gust
+0	11	41	1	0	12	m/s	Maximum wind speed (gusts) (fm...fm)
+0	11	42	1	0	12	m/s	Maximum wind speed (10 minute mean wind)
+0	11	43	1	0	12	m/s	Surface - 5000 feet mean LYR wind speed (dmdm)
+0	11	44	0	0	9	deg_true	Surface - 5000 feet mean LYR wind direction
+0	11	45	0	0	9	deg_true	Maximum wind (gust) direction
+0	11	50	1	0	12	m/s	Standard deviation horizontal wind speed
+0	11	51	1	0	8	m/s	Standard deviation vertical wind component
+0	11	61	1	0	12	m/s	Absolute wind shear (1 kilometer layer below)
+0	11	62	1	0	12	m/s	Absolute wind shear (1 kilometer layer above)
+0	11	195	0	0	2	Code_Table	Wind type at flight altitude (dt)
+0	11	200	0	0	4	Code_Table	Wind QC ID
+0	11	203	1	-4096	13	m/s	Wind u-component difference
+0	11	204	1	-4096	13	m/s	Wind v-component difference
+0	11	205	0	0	4	Code_Table	Turbulence (B) (WMO code table 0300)
+0	11	206	0	0	2	Code_Table	Flight level wind method (da)
+0	11	207	0	0	2	Code_Table	Extreme wind speed ID
+0	11	213	1	-4096	13	m/s	Wind u-component correction
+0	11	214	1	-4096	13	m/s	Wind v-component correction
+0	11	244	0	0	16	deg_true	Direction of wind
+0	11	245	2	0	16	m/s	wnd_spd
+0	11	246	1	0	8	m/s	Ocean surface wind speed
+0	12	1	1	0	12	deg_K	Temperature/dry bulb temperature (Ta, TsTsTs, TtTt, or TxTxTx)
+0	12	2	1	0	12	deg_K	Wet bulb temperature (TbTbTb)
+0	12	3	1	0	12	deg_K	Dewpoint (TdTdTd or T'dT'd)
+0	12	4	1	0	12	deg_K	Dry bulb temperature at 2 meters (Tao>Tan, ToTo>tnTn, or TT)
+0	12	5	1	0	12	deg_K	Wet bulb temperature at 2 meters
+0	12	6	1	0	12	deg_K	Dewpoint temperature at 2 meters
+0	12	7	1	0	12	deg_K	Virtual temperature
+0	12	11	1	0	12	deg_K	Maximum temperature
+0	12	12	1	0	12	deg_K	Minimum temperature (TnTnTn)
+0	12	13	1	0	12	deg_K	Ground minimum temperature past 12 hours
+0	12	14	1	0	12	deg_K	Maximum temperature at 2 meters, past 12 hours
+0	12	15	1	0	12	deg_K	Minimum temperature at 2 meters, past 12 hours
+0	12	16	1	0	12	deg_K	Maximum temperature at 2 meters, past 24 hours
+0	12	17	1	0	12	deg_K	Minimum temperature at 2 meters, past 24 hours
+0	12	20	2	-2000	12	deg_K/day	Radiative heating profile
+0	12	30	1	0	12	deg_K	Soil temperature (ToTo)
+0	12	40	-3	-2048	12	W/m**2	Sensible heat flux
+0	12	48	0	-200	8	deg_K	Land/snow surface temperature
+0	12	51	1	0	10	deg_K	Standard deviation temperature
+0	12	52	1	0	12	deg_K	Highest daily mean temperature
+0	12	53	1	0	12	deg_K	Lowest daily mean temperature
+0	12	61	1	0	12	deg_K	Skin temperature
+0	12	62	1	0	12	deg_K	Equivalent black body temperature
+0	12	63	1	0	12	deg_K	Brightness temperature
+0	12	70	2	0	16	deg_K	Vertical polarization 19GHz brightness temperature
+0	12	71	2	0	16	deg_K	Horizontal polarization 19GHz brightness temperature
+0	12	72	2	0	16	deg_K	Vertical polarization 22GHz brightness temperature
+0	12	73	2	0	16	deg_K	Vertical polarization 37GHz brightness temperature
+0	12	74	2	0	16	deg_K	Horizontal polarization 37GHz brightness temperature
+0	12	75	2	0	16	deg_K	Vertical polarization 85GHz brightness temperature
+0	12	76	2	0	16	deg_K	Horizontal polarization 85GHz brightness temperature
+0	12	192	0	0	4	Code_Table	Wet bulb temperature indicator
+0	12	193	2	0	16	deg_K	SSU brightness temperature
+0	12	194	2	0	16	deg_K	Dewpoint
+0	12	195	0	0	4	Code_Table	Dewpoint, aircraft altitude, air temperature indicator (id)
+0	12	196	2	0	16	deg_K	Dewpoint difference
+0	12	201	0	0	4	Code_Table	Air temperature QC ID
+0	12	213	0	0	4	Code_Table	Dewpoint QC ID
+0	12	215	0	0	2	Code_Table	Temperature precision flag
+0	12	220	2	0	16	deg_K	HIRS brightness temperature
+0	12	221	2	0	16	deg_K	MSU brightness temperature
+0	13	1	5	0	14	kg/kg	Specific humidity
+0	13	2	5	0	14	kg/kg	Mixing ratio
+0	13	3	0	0	7	percent	Relative humidity (U1>Un or U...U)
+0	13	4	-1	0	10	Pa	Vapor pressure
+0	13	5	3	0	7	kg/m**3	Vapor density (p1p1p1)
+0	13	6	-1	-40	16	m	Mixing heights
+0	13	11	1	-1	14	kg/m**2	Total precipitation/total water equivalent (Aw or R...R)
+0	13	12	2	-2	12	m	Depth of fresh snow
+0	13	13	2	-2	16	m	Total snow depth (sss)
+0	13	14	4	0	12	kg/m**2/s	Rainfall/water equivalent of snow (average rate)
+0	13	15	7	0	12	m/s	Snowfall (averaged rate)
+0	13	16	0	0	7	kg/m**2	Precipitable water (www)
+0	13	19	1	-1	14	kg/m**2	Total precipitation past 1 hour
+0	13	20	1	-1	14	kg/m**2	Total precipitation past 3 hours
+0	13	21	1	-1	14	kg/m**2	Total precipitation past 6 hours
+0	13	22	1	-1	14	kg/m**2	Total precipitation past 12 hours
+0	13	23	1	-1	14	kg/m**2	Total precipitation past 24 hours (R24...R24)
+0	13	31	0	0	7	kg/m**2	Evapotranspiration
+0	13	32	1	0	8	kg/m**2	Evaporation/evapotranspiration
+0	13	40	-3	-2048	12	W/m**2	Latent heat flux
+0	13	41	0	0	4	Code_Table	Pasquill-Gifford stability category
+0	13	42	0	-20	6	deg_K	Parcel lifted index (to 500 hPa)
+0	13	43	0	-20	6	deg_K	Best lifted index (to 500 hPa)
+0	13	51	0	0	4	Code_Table	Frequency group, precipitation
+0	13	52	1	-1	14	kg/m**2	Highest daily amount of precipiation
+0	13	71	1	0	7	kg/m**2	Liquid water
+0	13	75	0	0	8	percent	Land snow cloud
+0	13	76	2	0	6	m	Snow-water equivalent
+0	13	176	0	0	7	Code_Table	Precipitable water precision flag
+0	13	192	0	0	4	Code_Table	Precipitation identifier (iR)
+0	13	193	0	0	10	Code_Table	Precipitation amount
+0	13	194	3	0	16	g/kg	First guess mixing ratios
+0	13	197	0	0	3	Code_Table	Rain indicator
+0	13	203	0	0	4	Code_Table	Relative hunidity QC ID
+0	13	217	0	0	8	Numeric	Precipitation flag (SSM/T)
+0	13	218	2	0	11	kg/(m**2)	Cloud water
+0	13	219	2	0	10	cm	Total precipitable water
+0	13	220	1	0	9	mm/hr	Rain rate
+0	13	221	2	0	14	kg/(m**2)	Cloud Liquid Water
+0	14	1	-3	-2048	12	J/m**2	Longwave radiation, integrated over 24 hours (FLFLFL)
+0	14	3	-3	-2048	12	J/m**2	Shortwave radiation, integrated over 24 hours (FiFiFi)
+0	14	4	-3	-2048	12	J/m**2	Shortwave radiation, integrated over period specified (FsFsFs)
+0	14	11	-3	-2048	12	J/m**2	Net longwave radiation, integrated over 24 hours
+0	14	12	-3	-2048	12	J/m**2	Net longwave radiation, integrated over period specified
+0	14	13	-3	-2048	12	J/m**2	Net shortwave radiation, integrated over 24 hours
+0	14	14	-3	-2048	12	J/m**2	Net shortwave radiation, integrated over period specified
+0	14	15	-4	-16384	15	J/m**2	Net radiation, integrated over 24 hours
+0	14	16	-4	-16384	15	J/m**2	Net radiation, integrated over period specified
+0	14	17	-3	-2048	12	W/m**2	Instantaneous long wave radiation
+0	14	18	-3	-2048	12	W/m**2	Instantaneous short wave radiation
+0	14	19	0	0	7	percent	Surface albedo
+0	14	20	-4	0	15	J/m**2	Global solar radiation, integrated over 24 hours
+0	14	21	-4	0	15	J/m**2	Global radiation, integrated over period specified
+0	14	22	-4	0	15	J/m**2	Diffuse solar radiation, integrated over 24 hours
+0	14	23	-4	0	15	J/m**2	Diffuse solar radiation, integratedi over period specified
+0	14	24	-4	0	15	J/m**2	Direct solar radiation, integrated over 24 hours
+0	14	25	-4	0	15	J/m**2	Direct solar radiation, integrated over period specified
+0	14	31	0	0	11	min	Total sunshine
+0	14	32	0	0	10	hr	Total sunshine
+0	14	33	0	0	9	percent	Total sunshine (precentage)
+0	14	41	0	0	7	percent	Short wave albedo
+0	14	42	0	0	7	percent	Bi-directional reflectance
+0	15	1	0	0	10	dobson_unit	Ozone
+0	15	2	2	0	10	Numeric	Air-mass (slant path at 22 km)
+0	19	1	0	0	6	Code_Table	Type of synoptic features
+0	19	2	-2	0	12	m	Effective radius of feature
+0	19	3	0	0	8	m/s	Wind speed threshold
+0	19	4	-2	0	12	m	Effective radius of feature with respect to wind speeds above threshold
+0	19	5	0	0	9	deg_true	Direction of motion of features (dsds)
+0	19	6	2	0	14	m/s	Speed of motion of features
+0	19	7	-3	0	12	m	Effective radius of features
+0	19	8	0	0	3	Code_Table	Vertical extent of circulation
+0	19	9	-3	0	12	m	Effective radiation with respect to FFF above threshold
+0	20	1	-1	0	13	m	Horizontal visibility (Dv, Vi, V...V, or VxVxVxVx)
+0	20	2	-1	0	7	m	Vertical visibility
+0	20	3	0	0	9	Code_Table	Present weather (ww or w'w')
+0	20	4	0	0	5	Code_Table	Past weather (1) (Wa1Wa2 or W1W2)
+0	20	5	0	0	5	Code_Table	Past weather (2) (wawa)
+0	20	9	-1	-40	11	m	Ceiling
+0	20	10	0	0	7	percent	Cloud cover (total) (N, NcNc, or Ns...Ns)
+0	20	11	0	0	4	Code_Table	Cloud amount (N or Ns...Ns)
+0	20	12	0	0	6	Code_Table	Cloud type (C, Ct, CH, CL, or CM)
+0	20	13	-1	-40	11	m	Height of base of cloud (h, hshs, hshshs, or H'H')
+0	20	14	-1	-40	11	m	Height of top of cloud (HfHfHf or HtHt)
+0	20	15	-1	0	14	Pa	Pressure at the base of cloud
+0	20	16	-1	0	14	Pa	Pressure at the top of cloud (PcPcPc)
+0	20	17	0	0	4	Code_Table	Cloud top description
+0	20	18	-1	40	11	m	Low estimated height of cloud top
+0	20	19	-1	40	11	m	High estimated height of cloud top (H1>Hn)
+0	20	21	0	0	4	Code_Table	Middle cloud amount
+0	20	22	0	0	4	Code_Table	High cloud amount
+0	20	23	0	0	7	percent	Satellite sensed effective cloud amount
+0	20	30	0	0	4	Code_Table	Total ice concentration
+0	20	31	2	0	7	m	Ice deposit (thickness) (EsEs)
+0	20	32	0	0	3	Code_Table	Rate of ice accretion (Rs)
+0	20	33	0	0	4	Flag_Table	Cause of ice accretion (Is)
+0	20	34	0	0	5	Code_Table	Sea ice concentration (Ci)
+0	20	35	0	0	4	Code_Table	Amount and type of ice (zii...zii)
+0	20	36	0	0	5	Code_Table	Ice situation
+0	20	37	0	0	5	Code_Table	Ice development (bi)
+0	20	38	0	0	12	deg_true	Bearing of ice edge
+0	20	39	-1	0	13	m	Ice distance
+0	20	41	0	0	4	Code_Table	Rate of icing (Ir)
+0	20	49	0	0	10	Code_Table	Type of stability measure
+0	20	50	0	0	10	Numeric	Value of stability
+0	20	51	0	0	7	percent	Amount of low clouds
+0	20	52	0	0	7	percent	Amount of middle clouds
+0	20	53	0	0	7	percent	Amount of high clouds
+0	20	61	0	0	12	m	Runway visual range (RVR) (VR...VR)
+0	20	62	0	0	5	Code_Table	State of the ground (with or without snow) (E')
+0	20	63	0	0	10	Code_Table	Special phenomena
+0	20	71	0	0	2	Code_Table	Ice age code ID
+0	20	72	0	0	2	Code_Table	Ice edge code ID
+0	20	196	0	0	8	CCITT_IA5	Runway visibility tendency
+0	20	197	0	0	2	Flag_Table	Landing wind shear indicator
+0	20	199	0	0	8	deg_true	Visibility direction
+0	20	205	0	0	24	CCITT_IA5	Cloud significant convection
+0	20	206	0	0	64	CCITT_IA5	Significant present weather conditions
+0	20	207	0	0	4	Code_Table	Pressure and altitude significance
+0	20	208	0	0	4	Code_Table	Significant weather changes (Ws)
+0	20	209	0	0	4	Code_Table	Distance of weather changes (Ss)
+0	20	210	0	0	4	Code_Table	Distant weather (Wd)
+0	20	211	0	0	4	Code_Table	Bearing of distant weather (dw)
+0	20	213	0	0	4	Code_Table	Icing and contrail types (It)
+0	20	216	0	0	7	Code_Table	Altitude of layer base where icing occurred (hihi)
+0	20	219	0	0	4	Code_Table	Distance to center or line midpoint
+0	20	220	0	0	4	Code_Table	Orientation of ellipse (Sr)
+0	20	221	-3	0	16	m	Echo width or diameter (Ew)
+0	20	222	-3	0	16	m	Echo axis length (El)
+0	20	223	0	0	8	Code_Table	Echo character (ce)
+0	20	224	0	0	4	Code_Table	Intensity of echo (Ie)
+0	20	225	0	0	3	Code_Table	In flight horizontal visibility (Vi)
+0	20	236	0	0	8	CCITT_IA5	Cloud base height
+0	20	237	0	0	7	Code_Table	Horizontal visbility
+0	20	240	0	0	4	Code_Table	Present weather (w)
+0	20	242	0	0	5	Code_Table	Bearing of ice edge
+0	20	244	0	0	4	Code_Table	cloud base height
+0	20	245	0	0	640	CCITT_IA5	Remarks in plain language
+0	20	246	0	0	7	percent	Ice coverage
+0	20	247	0	0	1656	CCITT_IA5	Ice plain language text remarks
+0	20	248	0	0	7	Code_Table	Height of base of cloud (hshs)
+0	20	249	0	0	7	Code_Table	Height of top of cloud (HtHt)
+0	20	254	0	0	8	CCITT_IA5	Extreme value indicator
+0	20	255	0	0	2040	CCITT_IA5	Plain language text remarks
+0	21	1	0	-64	7	dB	Horizontal reflectivity
+0	21	2	0	-64	7	dB	Vertical reflectivity
+0	21	3	1	-5	7	dB	Differential reflectivity
+0	21	5	0	-65	6	dB	Linear depolarization ratio
+0	21	6	0	-65	6	dB	Circular depolarization ratio
+0	21	11	0	-128	8	m/s	Doppler mean velocity in X direction
+0	21	12	0	-128	8	m/s	Doppler mean velocity in Y direction
+0	21	13	0	-128	8	m/s	Doppler mean velocity in Z direction
+0	21	14	1	-4096	13	m/s	Doppler mean velocity (radiational)
+0	21	17	1	-4096	8	m/s	Doppler velocity spectral width
+0	21	21	-3	0	4	m	Echo tops
+0	21	30	0	-32	8	dB	Signal to noise ratio
+0	21	31	0	0	7	kg/m**2	Vertical integrated liquid water content
+0	21	36	7	0	12	m/s	Radar rainfall intensity
+0	21	41	-2	0	8	m	Bright band height
+0	21	51	0	-256	8	dB	Signal power above 1 MW
+0	21	192	0	0	14	m	Heave sensor spectral peak length
+0	21	193	1	0	14	s	Heave sensor spectral peak period
+0	21	194	2	0	14	percent	AVHRR channel average
+0	21	195	2	0	14	percent	Space view channel standard deviation
+0	21	196	2	0	15	deg_K	Algorithm identifier
+0	21	197	2	0	15	deg_K	AVHRR channel average
+0	21	198	2	-5000	13	dB	Backscatter
+0	21	199	1	0	10	percent	Noise figure percentage
+0	22	1	0	0	9	deg_true	Direction of waves (dddd, da1da1, or d1d1>dndn)
+0	22	2	0	0	9	deg_true	Direction of wind waves
+0	22	3	0	0	9	deg_true	Direction of swell waves (dw1dw1 or dw2dw2)
+0	22	4	0	0	9	deg_true	Direction of current (dodo>dndn or DcDc))
+0	22	11	0	0	6	s	Period of waves (D'D'D'D', PaPaPaPa, or PwPw)
+0	22	12	0	0	6	s	Period of wind waves
+0	22	13	0	0	6	s	Period of swell waves (Pw1Pw1 or Pw2Pw2)
+0	22	21	1	0	10	m	Height of waves (D'D'D'D' or HsHsHsHs)
+0	22	22	1	0	10	m	Height of wind waves (HwHw)
+0	22	23	1	0	10	m	Height of swell waves (Hw1Hw1 or Hw2Hw2)
+0	22	25	2	0	10	m	Standard deviation wave
+0	22	31	2	0	13	m/s	Speed of current (cococo>cncncn or VcVc)
+0	22	41	1	0	12	deg_K	Sea surface temperature (15 day running mean)
+0	22	42	1	0	12	deg_K	Sea temperature (T1T1T1>TnTnTn)
+0	22	43	2	0	15	deg_K	Sea temperature (ToToToTo>TnTnTnTn)
+0	22	44	1	0	14	m/s	Sound velocity
+0	22	50	2	0	8	deg_K	Standard deviation sea surface temperature
+0	22	61	0	0	4	Code_Table	State of sea
+0	22	62	2	0	14	ppt	Salinity (SoSoSoSo>SnSnSnSn)
+0	22	63	0	0	14	m	Total water depth (hhh or ZdZdZdZd)
+0	22	105	-1	0	6	deg_true	Direction of waves (da2da2)
+0	22	143	2	0	13	deg_K	Sea temperature
+0	22	192	0	0	14	m	Wave length
+0	22	193	2	0	14	m	Slope sensor significant wave height
+0	22	194	0	0	14	m	Slope sensor spectral peak length
+0	22	195	1	0	14	s	Slope sensor spectral peak period
+0	22	196	1	0	14	s	Slope sensor mean wave period
+0	22	197	0	0	14	m	Slope sensor mean wave length
+0	22	198	0	0	7	deg_true	Wave directional spread
+0	22	199	1	0	14	s	Time sample interval
+0	22	200	0	0	14	m	Distance sample interval
+0	22	201	1	0	14	s	Recorded wave duration
+0	22	202	0	0	14	m	Recorded wave length
+0	22	203	0	0	7	Numeric	Count of bands described
+0	22	204	0	0	4	Code_Table	Wave expiration
+0	22	205	3	0	20	m**2/(Hz*rad)	Wave spectra
+0	22	206	4	0	10	Numeric	Drag coefficient
+0	22	207	2	0	16	m	Maximum wave height
+0	22	208	2	0	16	m	Significant wave height
+0	22	209	0	0	7	Code_Table	directional spread
+0	22	211	0	0	8	Code_Table	Bogus water mass classification
+0	22	212	0	0	8	Code_Table	Discriminant water mass classification
+0	22	213	1	0	10	percent	Classification probability
+0	22	214	0	0	10	m**2/Hz	Heave sensor spectral density frequency
+0	22	215	0	0	10	m**3	Heave sensor spectral density number
+0	22	216	0	0	7	Numeric	Heave sensor band number
+0	22	217	0	0	7	percent	Heave sensor ratio
+0	22	218	0	0	7	Numeric	Slope sensor band number
+0	22	219	0	0	7	percent	Slope sensor ratio
+0	22	220	0	0	8	Code_Table	Front number
+0	22	224	-2	0	14	m	Distance to front
+0	22	229	0	0	7	Code_Table	Wave direction
+0	22	232	0	0	4	Code_Table	Sea surface temperature method indicator
+0	22	233	0	0	3	Code_Table	Sea temperature averaging period
+0	22	236	0	0	8	Code_Table	Swell wave direction
+0	22	237	-2	0	14	m	Significant wave height
+0	22	238	-2	0	14	m	Maximum wave height
+0	22	239	0	0	6	Numeric	Wave spectra direction count
+0	22	240	0	0	6	Numeric	Wave spectra frequency count
+0	22	241	3	-32768	16	Nt/m**2	Wave stress u-component
+0	22	242	3	-32768	16	Nt/m**2	Wave stress v-component
+0	22	243	0	0	7	percent	Whitecap probability
+0	22	244	0	0	7	Code_Table	Estimated wave direction of spectral wave
+0	22	245	2	0	16	deg_K	Surface temperature
+0	22	246	3	-32768	16	Nt/m**2	Wind stress u-component
+0	22	247	3	-32768	16	Nt/m**2	Wind stress v-component
+0	22	248	0	0	16	deg_true	Wind wave direction
+0	22	249	2	0	16	m	Height of wind wave
+0	22	250	1	0	16	s	Period of wind waves
+0	22	251	0	0	6	Numeric	Wave spectra direction
+0	22	252	0	0	6	Numeric	Wave spectra frequency
+0	22	253	0	0	16	deg_true	Direction of swell waves
+0	22	254	2	0	16	m	Height of swell waves
+0	22	255	1	0	16	s	Period of swell waves
+0	23	1	0	0	3	Code_Table	Accident early notification - article applicable
+0	23	2	0	0	5	Code_Table	Activity or facility involved in incident
+0	23	3	0	0	3	Code_Table	Type of release
+0	23	4	0	0	3	Code_Table	Countermeasures taken near border
+0	23	5	0	0	2	Code_Table	Cause of incident
+0	23	6	0	0	3	Code_Table	Incident situation
+0	23	7	0	0	3	Code_Table	Characteristic of release
+0	23	8	0	0	2	Code_Table	State of current release
+0	23	9	0	0	2	Code_Table	State of expected release
+0	23	16	0	0	2	Code_Table	Possibility of significant chemical toxic health effect
+0	23	17	6	0	20	m**3/s	Flow discharge of major recipient
+0	23	18	0	0	3	Code_Table	release behavior over time
+0	23	19	0	-15000	17	m	Actual release height
+0	23	21	0	-15000	17	m	Effective release height
+0	23	22	0	0	24	m	Distance of relative point or site of incident
+0	23	23	1	0	12	m/s	Main transport speed in atmosphere
+0	23	24	2	0	13	m/s	Main transport speed in water
+0	23	25	2	0	13	m/s	Main transport speed in ground water
+0	23	27	0	0	9	deg_true	Main transport direction in atmosphere
+0	23	28	0	0	9	deg_true	Main transport direction in water
+0	23	29	0	0	9	deg_true	Main transport direction in ground water
+0	23	31	0	0	2	Code_Table	Possibility that plume will encounter precip
+0	23	32	0	0	2	Code_Table	Plume will encounter change in wind direction and/or speed flag
+0	24	1	-11	0	28	Bq	Estimate of radioactivity released up to specified time
+0	24	2	-11	0	28	Bq	Estimated maximum potential release
+0	24	3	0	0	5	Code_Table	Composition of release
+0	24	4	0	0	16	CCITT_IA5	Element name
+0	24	5	0	0	9	Numeric	Isotope mass
+0	24	11	2	0	32	mSv	Dose
+0	24	12	2	0	32	mSv	Trajectory dose (defined location and expected time of arrival)
+0	24	13	2	0	32	mSv	Gamma dose in air along the main transport path
+0	24	21	2	0	32	Bq/m**3	Air concentration (named isotope type including gross beta)
+0	24	22	2	0	32	Bq/l	Concentration in precipitation (of named isotope type)
+0	25	1	-1	0	6	m	Range gate length
+0	25	2	0	0	4	Numeric	Number of gates averaged
+0	25	3	0	0	8	Numeric	Number of integrated pulses
+0	25	4	0	0	2	Code_Table	Echo processing
+0	25	5	0	0	2	Code_Table	Echo integration
+0	25	6	0	0	3	Code_Table	Z to R conversion
+0	25	7	0	0	12	Numeric	Z to R conversion factor
+0	25	8	2	0	9	Numeric	Z to R conversion exponent
+0	25	9	0	0	4	Flag_Table	Calibration method
+0	25	10	0	0	4	Code_Table	Clutter treatment
+0	25	11	0	0	2	Code_Table	Ground occultation correction (screening)
+0	25	12	0	0	2	Code_Table	Range attenuation correction
+0	25	13	0	0	2	Flag_Table	Bright band correction
+0	25	15	0	0	2	Flag_Table	Radome attenuation correction
+0	25	16	5	0	6	dB/m	Clear air attenuation correction
+0	25	17	0	0	2	Flag_Table	Precipitation attenuation correction
+0	25	18	7	0	6	Numeric	A to Z law for attenuation factor
+0	25	19	2	0	7	Numeric	A to Z law for attenuation exponent
+0	25	20	0	0	2	Code_Table	Mean speed estimation
+0	25	21	0	0	8	Flag_Table	Wind computation enhancement
+0	25	30	0	0	2	Code_Table	SST usage
+0	25	31	0	0	2	Code_Table	15 day SST availability
+0	25	32	0	0	2	Code_Table	NOAA wind profiler high/low mode data
+0	25	33	0	0	2	Code_Table	NOAA wind profiler submode
+0	25	34	0	0	4	Code_Table	NOAA wind profiler Q/C test results
+0	25	35	0	0	3	Code_Table	First guess adjustment
+0	25	36	3	-5000	14	Numeric	NSTAR average value
+0	25	37	0	0	2	Code_Table	HIRS-8 surface air temperature
+0	25	38	0	0	3	Code_Table	TOVS filter flags
+0	25	41	0	0	3	Code_Table	Method of determining direction of moving platform
+0	25	42	0	0	3	Code_Table	Method of determining speed of moving platform
+0	25	192	0	0	8	Code_Table	Type of correction
+0	25	193	0	0	3	Code_Table	Land/sea flag
+0	25	194	0	0	2	Code_Table	Day/night flag
+0	25	195	0	0	6	Numeric	Surface model pressure
+0	25	196	0	0	16	Numeric	Scan line count
+0	25	197	0	0	5	Numeric	Box counter
+0	25	198	0	0	3	Numeric	Minibox counter
+0	25	199	0	0	3	Code_Table	Water vapor flag
+0	25	200	0	0	3	Code_Table	TOVS retrieval low 20
+0	25	201	0	0	3	Code_Table	TOVS retrieval temps high 20
+0	25	202	0	0	2	Code_Table	TOVS super adiabatic flag
+0	25	203	0	0	2	Code_Table	TOVS skin temperature flag
+0	25	204	0	0	2	Code_Table	Stratospheric sounding unit flag
+0	25	205	0	0	4	Code_Table	Latitude zones
+0	25	206	0	0	4	Code_Table	TOVS instrument combinations
+0	25	208	0	0	8	Code_Table	TARM flag
+0	25	209	0	0	4	Code_Table	DMSP flag
+0	25	211	0	0	17	Numeric	B-scan start time
+0	25	212	0	0	7	Numeric	Counter (1-64)
+0	25	213	0	0	5	Code_Table	Calculated surface type
+0	25	214	0	0	3	Code_Table	Season flag
+0	25	215	0	-127	8	Numeric	Missing packet counter
+0	25	216	0	0	3	Code_Table	Observation Quality Code
+0	26	1	1	0	12	hr	Principle time of daily reading in UTC of maximum temperature
+0	26	2	1	0	12	hr	Principle time of daily reading in UTC of minimum temperature
+0	27	1	5	-9000000	25	deg	Latitude (high accuracy)
+0	27	2	2	-9000	15	deg	Latitude (coarse accuracy)
+0	27	3	2	-9000	15	deg	Alternate latitude
+0	27	20	0	0	16	Numeric	Satellite location counter
+0	27	21	0	0	16	Numeric	Satellite sub-location dimensions
+0	28	1	5	-18000000	26	deg	Longtiude (high accuracy)
+0	28	2	2	-18000	16	deg	Longtiude (coarse accuracy)
+0	28	3	2	-18000	16	deg	Alternate longtiude
+0	29	1	0	0	3	Code_Table	Projection type
+0	29	2	0	0	2	Code_Table	Coordinate grid type (Wr)
+0	30	1	0	0	4	Numeric	Pixel value (4 bits)
+0	30	21	0	0	12	Numeric	Number of pixels per row
+0	30	22	0	0	12	Numeric	Number of pixels per column
+0	30	31	0	0	4	Code_Table	Picture type
+0	30	32	0	0	16	Flag_Table	Combined picture
+0	31	0	0	0	1	Flag_Table	Delayed descriptor replication switch (1 bit)
+0	31	1	0	0	8	Numeric	Delayed descriptor replication factor (255 or less)
+0	31	2	0	0	16	Numeric	Extended delayed descriptor replication factor (65536 or less)
+0	31	11	0	0	8	Numeric	Delayed descriptor and data replication factor
+0	31	12	0	0	16	Numeric	Extended delayed descriptor and data replication factor
+0	31	21	0	0	6	Code_Table	Associated field significance
+0	31	192	0	0	8	Code_Table	Associated QC indicator
+0	31	193	0	0	8	Code_Table	QC description identifier, indicates why a value is bad
+0	31	194	2	0	7	Numeric	Associated correlation
+0	31	195	2	0	7	Numeric	Associated probability of error
+0	31	196	0	0	13	Flag_Table	UWI product confidence flag
+0	31	197	0	0	12	Numeric	Solution probability
+0	31	201	0	0	10	Numeric	Delayed replication factor (1023 or less)
+0	31	211	0	0	3	Numeric	Delayed replication factor (15 or less)
+0	31	221	0	0	5	Numeric	Delayed replication count (31 or less)
+0	31	231	0	0	6	Numeric	Delayed replication factor (63 or less)
+0	31	241	0	0	4	Numeric	Delayed replication factor (15 or less)
+0	48	1	0	0	128	CCITT_IA5	Classification
+0	48	2	0	0	128	CCITT_IA5	Classification modifier
+0	48	3	0	0	552	CCITT_IA5	Release as
+0	48	4	0	0	12	yr	Declassification - year
+0	48	5	0	0	4	mo	Declassification - month
+0	48	6	0	0	6	day	Declassification - day
+0	48	7	0	0	552	CCITT_IA5	Release not
+0	48	8	0	0	64	CCITT_IA5	Sender of original observation data
+0	48	9	0	0	80	CCITT_IA5	Declassification instructions
+0	48	10	0	0	12	yr	Send - year
+0	48	11	0	0	4	mo	Send - month
+0	48	12	0	0	6	day	Send - day
+0	48	13	0	0	4	hr	Send - hour
+0	48	14	0	0	6	min	Send - minutes
+0	48	15	0	0	552	CCITT_IA5	Release to information
+0	48	16	0	0	5	hr	Send - hour
+0	48	17	0	0	1104	CCITT_IA5	Release to
+0	48	18	0	0	552	CCITT_IA5	Release not
+0	48	19	0	0	552	CCITT_IA5	Declassification instructions
+0	48	20	0	0	552	CCITT_IA5	Classification modifier
+0	48	21	0	0	552	CCITT_IA5	Sender of observational data
+0	48	22	0	0	160	CCITT_IA5	Classification
+0	48	27	0	0	12	yr	Receipt - year
+0	48	28	0	0	4	mo	Receipt - month
+0	48	29	0	0	6	day	Receipt - day
+0	48	30	0	0	5	hr	Receipt - hour
+0	48	31	0	0	6	min	Receipt - minutes
+0	48	32	0	0	48	CCITT_IA5	Bulletin header update or correction indicator
+0	48	33	0	0	24	CCITT_IA5	Receiving circuit
+0	48	34	0	0	6	Numeric	Near-duplicate combination count
+0	50	1	0	0	2	Code_Table	Quality of measurement of pressure, sst,
+0	50	2	0	0	2	Code_Table	Quality of buoy satellite transmission (QN)
+0	50	3	0	0	4	Code_Table	IGOSS quality codes (Qd, Qd1, Qd2, Q1, Qt)
+0	50	6	0	0	3	Code_Table	Location quality codes (QL)
+0	50	10	2	0	15	deg_K	GDEM temperature
+0	50	14	2	0	15	deg_K	Feature model temperature
+0	50	18	0	0	16	Numeric	Reliability
+0	50	33	0	0	8	Numeric	Count of boundary points
+0	50	34	3	0	16	Numeric	Frequency ratio
+0	50	35	0	0	12	s	Time step of data (time increment)
+0	50	42	2	0	12	Numeric	Mean wave direction
+0	50	43	3	0	12	Numeric	Mean wave frequency
+0	50	44	4	0	12	Numeric	First frequency
+0	50	100	0	0	12	yr	Analysis DTG - year
+0	50	101	0	0	4	mo	Analysis DTG - month
+0	50	102	0	0	6	day	Analysis DTG - day
+0	50	103	0	0	5	hr	Analysis DTG - hour
+0	50	104	0	0	6	Numeric	Last observed sea depth
+0	51	3	0	0	5	Flag_Table	Processing status
+0	51	6	0	0	6	Numeric	Combination count
+0	51	7	0	0	2	Code_Table	Quality control process status
diff --git a/data/tables/B2L-058-001-D b/data/tables/B2L-058-001-D
new file mode 100644
index 0000000..a82ef5c
--- /dev/null
+++ b/data/tables/B2L-058-001-D
@@ -0,0 +1,25 @@
+#
+# B2L-058-001-D.001 - Local BUFR Table D (Lists of Common Sequences)
+# for Center 058 (FNMOC), Minor Local Version 1
+#
+# Descriptor sequences are terminated with -1
+#
+# Sequences do not need to appear in any order.  Sequence A
+# which includes sequence B, may appear before sequence B
+# is defined.
+#
+
+# Phony local descriptor for debugging purposes
+#
+#3	5	1
+#	0	2	102		# Antenna height above tower base (8 bits)
+#	0	2	104		# Antenna polarization            (4 bits)
+#	0	2	113		# Number of azimuth looks         (4 bits)
+#	-1
+#
+3	5	1
+	0	2	 11		# Radiosonde type                 (8 bits)
+	0	2	 22		# Satellite DP technique used     (8 bits)
+	0	2	102		# Antenna height above tower base (8 bits)
+	-1
+
diff --git a/data/tables/B2L-058-001-D.001 b/data/tables/B2L-058-001-D.001
new file mode 100644
index 0000000..a82ef5c
--- /dev/null
+++ b/data/tables/B2L-058-001-D.001
@@ -0,0 +1,25 @@
+#
+# B2L-058-001-D.001 - Local BUFR Table D (Lists of Common Sequences)
+# for Center 058 (FNMOC), Minor Local Version 1
+#
+# Descriptor sequences are terminated with -1
+#
+# Sequences do not need to appear in any order.  Sequence A
+# which includes sequence B, may appear before sequence B
+# is defined.
+#
+
+# Phony local descriptor for debugging purposes
+#
+#3	5	1
+#	0	2	102		# Antenna height above tower base (8 bits)
+#	0	2	104		# Antenna polarization            (4 bits)
+#	0	2	113		# Number of azimuth looks         (4 bits)
+#	-1
+#
+3	5	1
+	0	2	 11		# Radiosonde type                 (8 bits)
+	0	2	 22		# Satellite DP technique used     (8 bits)
+	0	2	102		# Antenna height above tower base (8 bits)
+	-1
+
diff --git a/data/tables/B2L-058-003-B b/data/tables/B2L-058-003-B
new file mode 100644
index 0000000..3baba63
--- /dev/null
+++ b/data/tables/B2L-058-003-B
@@ -0,0 +1,520 @@
+#
+# BUFR Table B - Classification of Elements
+#
+# sccs keywords: @(#)Table_B.txt	1.1 05/07/97
+#					Data
+#F	X	Y	Scale	RefVal	Width	Units	Element Name
+  0;    0;      1;      0;           0;   24;    CCITT_IA5; Table A: entry
+  0;    0;      2;      0;           0;  256;    CCITT_IA5; Table A: data category description, line 1
+  0;    0;      3;      0;           0;  256;    CCITT_IA5; Table A: data category description, line 2
+  0;    0;      5;      0;           0;   24;    CCITT_IA5; BUFR edition number
+  0;    0;     10;      0;           0;    8;    CCITT_IA5; F descriptor to be added or defined
+  0;    0;     11;      0;           0;   16;    CCITT_IA5; X descriptor to be added or defined
+  0;    0;     12;      0;           0;   24;    CCITT_IA5; Y descriptor to be added or defined
+  0;    0;     13;      0;           0;  256;    CCITT_IA5; Element name, line 1
+  0;    0;     14;      0;           0;  256;    CCITT_IA5; Element name, line 2
+  0;    0;     15;      0;           0;  192;    CCITT_IA5; Units name
+  0;    0;     16;      0;           0;    8;    CCITT_IA5; Units scale sign
+  0;    0;     17;      0;           0;   24;    CCITT_IA5; Units scale
+  0;    0;     18;      0;           0;    8;    CCITT_IA5; Units reference sign
+  0;    0;     19;      0;           0;   80;    CCITT_IA5; Units reference value
+  0;    0;     20;      0;           0;   24;    CCITT_IA5; Element data width
+  0;    0;     30;      0;           0;   48;    CCITT_IA5; Descriptor defining sequence
+
+  0;    1;      1;      0;           0;    7;      Numeric; WMO block number
+  0;    1;      2;      0;           0;   10;      Numeric; WMO station number
+  0;    1;      3;      0;           0;    3;      Numeric; WMO region number
+  0;    1;      4;      0;           0;    3;      Numeric; WMO region sub-area
+  0;    1;      5;      0;           0;   17;      Numeric; Buoy/platform identifier
+  0;    1;      6;      0;           0;   64;    CCITT_IA5; Aircraft identifier (flight number)
+  0;    1;      7;      0;           0;   10;   Code_Table; Satellite identifier
+  0;    1;      8;      0;           0;   64;    CCITT_IA5; Aircraft registration number (tail number)
+  0;    1;      9;      0;           0;   64;    CCITT_IA5; Type of commerical aircraft
+  0;    1;     10;      0;           0;   64;    CCITT_IA5; Stationary buoy platform identifier
+  0;    1;     11;      0;           0;   72;    CCITT_IA5; Ship's call sign
+  0;    1;     12;      0;           0;    9;     deg_true; Direction of motion of moving observing platform
+  0;    1;     13;      0;           0;   10;          m/s; Speed of motion of moving observing platform
+  0;    1;     14;      2;           0;   10;          m/s; Platform drift speed (high precision)
+  0;    1;     21;      0;           0;   14;      Numeric; Synoptic feature identifier
+  0;    1;     25;      0;           0;   24;    CCITT_IA5; Storm identifier
+  0;    1;     26;      0;           0;   64;    CCITT_IA5; WMO storm name
+  0;    1;     31;      0;           0;   16;      Numeric; Generating center
+# Local descriptors?
+#0	1	50	0	0	48	CCITT_IA5	NMC report identifier
+#0	1	62	0	0	40	CCITT_IA5	National assigned station identifier
+  0;    1;     63;      0;           0;   64;    CCITT_IA5; ICAO location indicator
+
+  0;    2;      1;      0;           0;    2;   Code_Table; Type of station
+  0;    2;      2;      0;           0;    4;   Flag_Table; Type of instrumentation for wind measurement
+  0;    2;      3;      0;           0;    4;   Code_Table; Type of measuring instrumentation used
+  0;    2;      4;      0;           0;    4;   Code_Table; Type of instrumentation for evaporation measurement or type of crop for which evapotranspiration is reported
+  0;    2;      5;      2;           0;    7;          deg; Precision of temperature observed
+  0;    2;     11;      0;           0;    8;   Code_Table; Radiosonde type
+  0;    2;     12;      0;           0;    4;   Code_Table; Radiosonde computational method
+  0;    2;     13;      0;           0;    4;   Code_Table; Solar and infrared radiation correction
+  0;    2;     14;      0;           0;    7;   Code_Table; Tracking technique/status of system
+  0;    2;     15;      0;           0;    4;   Code_Table; Radiosonde completeness
+  0;    2;     21;      0;           0;    9;   Flag_Table; Satellite instrumentation data used in processing
+  0;    2;     22;      0;           0;    8;   Flag_Table; Satellite data processing technique used
+  0;    2;     23;      0;           0;    4;   Code_Table; Cloud motion computational method
+  0;    2;     24;      0;           0;    4;   Code_Table; Integrated mean humidity computational method
+  0;    2;     25;      0;           0;   25;   Flag_Table; Satellite channel(s) used in computation
+  0;    2;     26;      2;           0;   12;            m; Cross track resolution
+  0;    2;     27;      2;           0;   12;            m; Along track resolution
+# Local descriptors?
+#0	2	28	0	0	32	Flag_Table	Geostationary sounder satellite channels used
+#0	2	29	0	0	8	Flag_Table	Geostationary sounder satellite channels used
+  0;    2;     30;      0;           0;    3;   Flag_Table; GOES I/M parameter calculation data source
+  0;    2;     31;      0;           0;    5;   Code_Table; Method of current measurement
+  0;    2;     32;      0;           0;    2;   Code_Table; Indicator for digitization
+  0;    2;     33;      0;           0;    3;   Code_Table; Method of salinity/depth measurement
+  0;    2;     34;      0;           0;    5;   Code_Table; Drogue type
+  0;    2;     35;      0;           0;    9;            m; Cable length
+  0;    2;     36;      0;           0;    2;   Code_Table; Buoy type
+  0;    2;     41;      0;           0;    6;   Code_Table; Method for estimating reports related to synoptic features
+  0;    2;     42;      0;           0;    6;   Code_Table; Method of report construction
+  0;    2;     43;      0;           0;    6;   Code_Table; Precision of latitude/longitude report
+  0;    2;     61;      0;           0;    3;   Code_Table; Aircraft navigation system
+  0;    2;     62;      0;           0;    4;   Code_Table; Type of aircraft data relay system
+  0;    2;     63;      2;      -18000;   16;          deg; Aircraft roll angle
+  0;    2;     70;      0;           0;    4;   Code_Table; Original specification of latitude/longitude
+  0;    2;    101;      0;           0;    4;   Code_Table; Type of antenna
+  0;    2;    102;      0;           0;    8;            m; Antenna height above tower
+  0;    2;    103;      0;           0;    2;   Flag_Table; Radome
+  0;    2;    104;      0;           0;    4;   Code_Table; Antenna polarisation
+  0;    2;    105;      0;           0;    6;           dB; Maximum antenna gain
+  0;    2;    106;      1;           0;    6;          deg; 3-dB bandwidth
+  0;    2;    107;      0;           0;    6;           dB; Sidelobe suppression
+  0;    2;    108;      0;           0;    6;           dB; Crosspol discrimination (on axis)
+  0;    2;    109;      2;           0;   12;        deg/s; Antenna speed (azimuth)
+  0;    2;    110;      2;           0;   12;        deg/s; Antenna speed (elevation)
+  0;    2;    111;      1;           0;   10;          deg; Radar incidence angle
+  0;    2;    112;      1;           0;   12;          deg; Radar azimuth angle
+  0;    2;    113;      0;           0;    4;      Numeric; Number of azimuth looks
+  0;    2;    114;      0;           0;   15;         m**2; Antenna effective surface area
+  0;    2;    121;     -8;           0;    7;           Hz; Mean frequency
+  0;    2;    122;     -6;        -128;    8;           Hz; Frequency agility range
+  0;    2;    123;     -4;           0;    7;            W; Peak power
+  0;    2;    124;     -1;           0;    7;            W; Average power
+  0;    2;    125;     -1;           0;    8;           Hz; Pulse repetition frequency
+  0;    2;    126;      7;           0;    6;            s; Pulse width
+  0;    2;    127;     -6;           0;    7;           Hz; Receiver intermediate frequency
+  0;    2;    128;     -5;           0;    6;           Hz; Intermediate frequency bandwidth
+  0;    2;    129;      0;        -150;    5;           dB; Minimum detectable signal
+  0;    2;    130;      0;           0;    7;           dB; Dynamic range
+  0;    2;    131;      0;           0;    2;   Flag_Table; Sensitivity time control
+  0;    2;    132;      2;           0;    6;          deg; Azimuth pointing accuracy
+  0;    2;    133;      2;           0;    6;          deg; Elevation pointing accuracy
+  0;    2;    134;      2;           0;   16;          deg; Antenna beam azimuth
+  0;    2;    135;      2;       -9000;   15;          deg; Antenna elevation
+  0;    2;    190;      0;           0;    8;   Code_Table; U, v quality indicator
+  0;    2;    191;      0;           0;    4;   Code_Table; W quality indicator
+
+  0;    4;      1;      0;           0;   12;         Year; Year
+  0;    4;      2;      0;           0;    4;           mo; Month
+  0;    4;      3;      0;           0;    6;          Day; Day
+  0;    4;      4;      0;           0;    5;           hr; Hour
+  0;    4;      5;      0;           0;    6;          min; Minute
+  0;    4;      6;      0;           0;    6;            s; Second
+  0;    4;     11;      0;       -1024;   11;         Year; Time increment
+  0;    4;     12;      0;       -1024;   11;           mo; Time increment
+  0;    4;     13;      0;       -1024;   11;         Days; Time increment
+  0;    4;     14;      0;       -1024;   11;           hr; Time increment
+  0;    4;     15;      0;       -2048;   12;          min; Time increment
+  0;    4;     16;      0;       -4096;   13;            s; Time increment
+  0;    4;     21;      0;       -1024;   11;         Year; Time period or displacement
+  0;    4;     22;      0;       -1024;   11;           mo; Time period or displacement
+  0;    4;     23;      0;       -1024;   11;         Days; Time period or displacement
+  0;    4;     24;      0;       -2048;   12;           hr; Time period or displacement
+  0;    4;     25;      0;       -2048;   12;          min; Time period or displacement
+  0;    4;     26;      0;       -4096;   13;            s; Time period or displacement
+  0;    4;     31;      0;           0;    8;           hr; Duration of time relative to followinG value
+  0;    4;     43;      0;           0;    9;          Day; Day of the year
+  0;    4;     44;      0;           0;    3;   Code_Table; Day of the week
+
+  0;    5;      1;      5;    -9000000;   25;          deg; Latitude (high accuracy)
+  0;    5;      2;      2;       -9000;   15;          deg; Latitude (coarse accuracy)
+  0;    5;      3;      2;       -9000;   15;          deg; Alternate latitude
+  0;    5;     11;      5;    -9000000;   25;          deg; Latitude increment (high accuracy)
+  0;    5;     12;      2;       -9000;   15;          deg; Latitude increment (coarse accuracy)
+  0;    5;     21;      2;           0;   16;     deg_true; Bearing or azimuth
+  0;    5;     22;      2;           0;   16;     deg_true; Solar azimuth
+  0;    5;     30;      0;           0;   12;          deg; Direction (spectral)
+  0;    5;     31;      0;           0;   12;      Numeric; Row number
+  0;    5;     33;     -1;           0;   16;            m; Pixel size on horizontal - 1
+  0;    5;     40;      0;           0;   24;      Numeric; Orbit number
+  0;    5;     41;      0;           0;    8;      Numeric; Scan line number
+  0;    5;     42;      0;           0;    6;      Numeric; Channel number
+  0;    5;     43;      0;           0;    8;      Numeric; Field of view number
+  0;    5;     50;      5;           0;   17;      Numeric; Sigma level
+  0;    5;     52;      0;           0;    5;      Numeric; Channel number increment
+  0;    5;     53;      0;           0;    5;      Numeric; Field of view number increment
+
+  0;    6;      1;      5;   -18000000;   26;          deg; Longtiude (high accuracy)
+  0;    6;      2;      2;      -18000;   16;          deg; Longtiude (coarse accuracy)
+  0;    6;      3;      2;      -18000;   16;          deg; Alternate longtiude
+  0;    6;     11;      5;   -18000000;   26;          deg; Longtiude increment (high accuracy)
+  0;    6;     12;      2;      -18000;   16;          deg; Longtiude increment (coarse accuracy)
+  0;    6;     21;     -1;           0;   13;            m; Distance
+  0;    6;     30;      5;           0;   13;        rad/m; Wavenumber (spectral)
+  0;    6;     31;      0;           0;   12;      Numeric; Column number
+  0;    6;     33;     -1;           0;   16;            m; Pixel size on horizontal - 2
+
+  0;    7;      1;      0;        -400;   15;            m; Height of station
+  0;    7;      2;     -1;         -40;   16;            m; Height or altitude
+  0;    7;      3;     -1;        -400;   17;    m**2/s**2; Geopotential
+  0;    7;      4;     -1;           0;   14;           Pa; Pressure
+  0;    7;      5;      0;        -400;   12;            m; Height increment
+  0;    7;      6;      0;           0;   15;            m; Height above station
+  0;    7;     21;      2;       -9000;   15;          deg; Elevation
+  0;    7;     22;      2;       -9000;   15;          deg; Solar elevation
+  0;    7;     61;      2;           0;   14;            m; Depth below land surface
+  0;    7;     62;      1;           0;   17;            m; Depth below sea surface
+  0;    7;    190;      0;           0;   12;            m; Height increment
+
+  0;    8;      1;      0;           0;    7;   Flag_Table; Vertical sounding significance
+  0;    8;      2;      0;           0;    6;   Code_Table; Vertical significance (surface observations)
+  0;    8;      3;      0;           0;    6;   Code_Table; Vertical significance (satellite observations)
+  0;    8;      4;      0;           0;    3;   Code_Table; Phase of aircraft flight
+  0;    8;      5;      0;           0;    4;   Code_Table; Surface synoptic features significance
+  0;    8;      0;      0;           0;    4;   Code_Table; Vertical significance (forecast soundings)
+  0;    8;     11;      0;           0;    6;   Code_Table; Horizontal significance
+  0;    8;     12;      0;           0;    2;   Code_Table; land/sea qualifier
+  0;    8;     13;      0;           0;    2;   Code_Table; Day/night qualifier
+  0;    8;     21;      0;           0;    5;   Code_Table; Time significance
+  0;    8;     22;      0;           0;   16;      Numeric; Total number (with respect to accumulation or average)
+  0;    8;     31;      0;           0;    8;         BUFR; Table A	Data category
+  0;    8;     32;      0;           0;   14;   Code_Table; Data significance for simulated forecast
+  0;    8;     33;      0;           0;    3;   Code_Table; Data significance for corrected forecast
+  0;    8;     34;      0;           0;    3;   Code_Table; Data significance for simulated retrievals
+  0;    8;     35;      0;           0;    3;   Code_Table; Data significance for corrected retrievals
+  0;    8;     36;      0;           0;    3;   Code_Table; Data significance for simulated analysis
+  0;    8;     37;      0;           0;    3;   Code_Table; Data significance for corrected analysis
+  0;    8;     38;      0;           0;    3;   Code_Table; Data significance for sigma level data
+
+  0;   10;      1;      0;        -400;   15;            m; Height of land surface
+  0;   10;      2;     -1;         -40;   16;            m; Height
+  0;   10;      3;     -1;        -400;   17;    m**2/s**2; Geopotential
+  0;   10;      4;     -1;           0;   14;           Pa; Pressure
+  0;   10;     50;      2;           0;   16;            m; Standard deviation altitude
+  0;   10;     51;     -1;           0;   14;           Pa; Pressure reduced to mean sea level
+  0;   10;     52;     -1;           0;   14;           Pa; Altimeter setting (QNH)
+  0;   10;     60;     -1;       -1024;   11;           Pa; Pressure change
+  0;   10;     61;     -1;        -500;   10;           Pa; 3 hour pressure change
+  0;   10;     62;     -1;       -1000;   11;           Pa; 24 hour pressure change
+  0;   10;     63;      0;           0;    4;   Code_Table; Characteristic of pressure tendency
+
+  0;   11;      1;      0;           0;    9;     deg_true; Wind direction
+  0;   11;      2;      1;           0;   12;          m/s; Wind speed
+  0;   11;      3;      1;       -4096;   13;          m/s; U-component
+  0;   11;      4;      1;       -4096;   13;          m/s; V-component
+  0;   11;      5;      1;        -512;   10;         Pa/s; W-component
+  0;   11;      6;      2;       -4096;   13;          m/s; W-component
+  0;   11;     11;      0;           0;    9;     deg_true; Wind direction at 10 m
+  0;   11;     12;      1;           0;   12;          m/s; Wind speed at 10 m
+  0;   11;     13;      0;           0;    9;     deg_true; Wind direction at 5 m
+  0;   11;     14;      1;           0;   12;          m/s; Wind speed at 5 m
+  0;   11;     21;      9;      -65536;   17;        s**-1; Relative vorticity
+  0;   11;     22;      9;      -65536;   17;        s**-1; Divergence
+  0;   11;     23;     -2;      -65536;   17;       m**2/s; Velocity potential
+  0;   11;     31;      0;           0;    4;   Code_Table; Degree of turbulence
+  0;   11;     32;     -1;         -40;   16;            m; Height of base of turbulence
+  0;   11;     33;     -1;         -40;   16;            m; Height of top of turbulence
+  0;   11;     34;      1;       -1024;   11;          m/s; Vertical gust velocity
+  0;   11;     35;      2;       -8192;   14;       m/s**2; Vertical gust acceleration
+  0;   11;     36;      1;           0;   10;         m/si; Maximum derived equivalent vertical gust
+  0;   11;     41;      1;           0;   12;          m/s; Maximum wind speed (gusts)
+  0;   11;     42;      1;           0;   12;          m/s; Maximum wind speed (10 minute mean wind)
+  0;   11;     43;      1;           0;   12;          m/s; Surface - 5000 feet mean LYR wind speed
+  0;   11;     44;      0;           0;    9;     deg_true; Surface - 5000 feet mean LYR wind direction
+  0;   11;     45;      0;           0;    9;     deg_true; Maximum wind (gust) direction
+  0;   11;     50;      1;           0;   12;          m/s; Standard deviation horizontal wind speed
+  0;   11;     51;      1;           0;    8;          m/s; Standard deviation vertical wind component
+  0;   11;     61;      1;           0;   12;          m/s; Absolute wind shear (1 kilometer layer below)
+  0;   11;     62;      1;           0;   12;          m/s; Absolute wind shear (1 kilometer layer above)
+
+  0;   12;      1;      1;           0;   12;        deg_K; Temperature/dry bulb temperature
+  0;   12;      2;      1;           0;   12;        deg_K; Wet bulb temperature
+  0;   12;      3;      1;           0;   12;        deg_K; Dewpoint temperature
+  0;   12;      4;      1;           0;   12;        deg_K; Dry bulb temperature at 2 meters
+  0;   12;      5;      1;           0;   12;        deg_K; Wet bulb temperature at 2 meters
+  0;   12;      6;      1;           0;   12;        deg_K; Dewpoint temperature at 2 meters
+  0;   12;      7;      1;           0;   12;        deg_K; Virtual temperature
+  0;   12;     11;      1;           0;   12;        deg_K; Maximum temperature
+  0;   12;     12;      1;           0;   12;        deg_K; Minimum temperature
+  0;   12;     13;      1;           0;   12;        deg_K; Ground minimum temperature past 12 hours
+  0;   12;     14;      1;           0;   12;        deg_K; Maximum temperature at 2 meters, past 12 hours
+  0;   12;     15;      1;           0;   12;        deg_K; Minimum temperature at 2 meters, past 12 hours
+  0;   12;     16;      1;           0;   12;        deg_K; Maximum temperature at 2 meters, past 24 hours
+  0;   12;     17;      1;           0;   12;        deg_K; Minimum temperature at 2 meters, past 24 hours
+  0;   12;     20;      2;       -2000;   12;    deg_K/day; Radiative heating profile
+  0;   12;     30;      1;           0;   12;        deg_K; Soil temperature
+  0;   12;     40;     -3;       -2048;   12;       W/m**2; Sensible heat flux
+  0;   12;     61;      1;           0;   12;        deg_K; Skin temperature
+  0;   12;     62;      1;           0;   12;        deg_K; Equivalent black body temperature
+  0;   12;     63;      1;           0;   12;        deg_K; Brightness temperature
+
+  0;   13;      1;      5;           0;   14;        kg/kg; Specific humidity
+  0;   13;      2;      5;           0;   14;        kg/kg; Mixing ratio
+  0;   13;      3;      0;           0;    7;      percent; Relative humidity
+  0;   13;      4;     -1;           0;   10;           Pa; Vapor pressure
+  0;   13;      5;      3;           0;    7;      kg/m**3; Vapor density
+  0;   13;      6;     -1;         -40;   16;            m; Mixing heights
+  0;   13;     11;      4;          -1;   14;      kg/m**2; Total precipitation/total water equivalent
+  0;   13;     12;      2;          -2;   12;            m; Depth of fresh snow
+  0;   13;     13;      2;          -2;   16;            m; Total snow depth
+  0;   13;     14;      4;           0;   12;    kg/m**2/s; Rainfall/water equivalent of snow (average rate)
+  0;   13;     15;      7;           0;   12;          m/s; Snowfall (averaged rate)
+  0;   13;     16;      0;           0;    7;      kg/m**2; Precipitable water
+  0;   13;     19;      1;          -1;   14;      kg/m**2; Total precipitation past 1 hour
+  0;   13;     20;      1;          -1;   14;      kg/m**2; Total precipitation past 3 hours
+  0;   13;     21;      1;          -1;   14;      kg/m**2; Total precipitation past 6 hours
+  0;   13;     22;      1;          -1;   14;      kg/m**2; Total precipitation past 12 hours
+  0;   13;     23;      1;          -1;   14;      kg/m**2; Total precipitation past 24 hours
+  0;   13;     31;      0;           0;    7;      kg/m**2; Evapotranspiration
+  0;   13;     32;      1;           0;    8;      kg/m**2; Evaporation/evapotranspiration
+  0;   13;     40;     -3;       -2048;   12;       W/m**2; Latent heat flux
+  0;   13;     41;      0;           0;    4;   Code_Table; Pasquill-Gifford stability category
+  0;   13;     42;      0;         -20;    6;        deg_K; US NWS lifted index
+
+  0;   14;      1;     -3;       -2048;   12;  Joules/m**2; Longwave radiation, integrated over 24 hours
+  0;   14;      3;     -3;       -2048;   12;  Joules/m**2; Shortwave radiation, integrated over 24 hours
+  0;   14;      4;     -3;       -2048;   12;  Joules/m**2; Shortwave radiation, integrated over period specified
+  0;   14;     11;     -3;       -2048;   12;  Joules/m**2; Net longwave radiation, integrated over 24 hours
+  0;   14;     12;     -3;       -2048;   12;  Joules/m**2; Net longwave radiation, integrated over period specified
+  0;   14;     13;     -3;       -2048;   12;  Joules/m**2; Net shortwave radiation, integrated over 24 hours
+  0;   14;     14;     -3;       -2048;   12;  Joules/m**2; Net shortwave radiation, integrated over period specified
+  0;   14;     15;     -4;      -16384;   15;  Joules/m**2; Net radiation, integrated over 24 hours
+  0;   14;     16;     -4;      -16384;   15;  Joules/m**2; Net radiation, integrated over period specified
+  0;   14;     17;     -3;       -2048;   12;       W/m**2; Instantaneous long wave radiation
+  0;   14;     18;     -3;       -2048;   12;       W/m**2; Instantaneous short wave radiation
+  0;   14;     19;      0;           0;    7;      percent; Surface albedo
+  0;   14;     20;     -4;           0;   15;  Joules/m**2; Global solar radiation, integrated over 24 hours
+  0;   14;     21;     -4;           0;   15;  Joules/m**2; Global radiation, integrated over period specified
+  0;   14;     22;     -4;           0;   15;  Joules/m**2; Diffuse solar radiation, integrated over 24 hours
+  0;   14;     23;     -4;           0;   15;  Joules/m**2; Diffuse solar radiation, integratedi over period specified
+  0;   14;     24;     -4;           0;   15;  Joules/m**2; Direct solar radiation, integrated over 24 hours
+  0;   14;     25;     -4;           0;   15;  Joules/m**2; Direct solar radiation, integrated over period specified
+  0;   14;     31;      0;           0;   11;          min; Total sunshine
+  0;   14;     32;      0;           0;   10;           hr; Total sunshine
+  0;   14;     41;      0;           0;    7;      percent; Short wave albedo
+  0;   14;     42;      0;           0;    7;      percent; Bi-directional reflectance
+
+  0;   15;      1;      0;           0;   10;       Dobson; units	Ozone
+
+  0;   19;      1;      0;           0;    6;   Code_Table; Type of synoptic features
+  0;   19;      2;     -2;           0;   12;            m; Effective radius of feature
+  0;   19;      3;      0;           0;    8;          m/s; Wind speed threshold
+  0;   19;      4;     -2;           0;   12;            m; Effective radius of feature with respect to wind speeds above threshold
+  0;   19;      5;      0;           0;    9;     deg_true; Direction of motion of features
+  0;   19;      6;      2;           0;   14;          m/s; Speed of motion of features
+  0;   19;      7;     -3;           0;   12;            m; Effective radius of features
+  0;   19;      8;      0;           0;    3;   Code_Table; Vertical extent of circulation
+  0;   19;      9;     -3;           0;   12;            m; Effective radiation with respect to FFF above threshold
+
+  0;   20;      1;     -1;           0;   13;            m; Horizontal visibility
+  0;   20;      2;     -1;           0;    7;            m; Vertical visibility
+  0;   20;      3;      0;           0;    9;   Code_Table; Present weather
+  0;   20;      4;      0;           0;    5;   Code_Table; Past weather (1)
+  0;   20;      5;      0;           0;    5;   Code_Table; Past weather (2)
+  0;   20;      9;     -1;         -40;   11;            m; Ceiling
+  0;   20;     10;      0;           0;    7;      percent; Cloud cover (total)
+  0;   20;     11;      0;           0;    4;   Code_Table; Cloud amount
+  0;   20;     12;      0;           0;    6;   Code_Table; Cloud type
+  0;   20;     13;     -1;         -40;   11;            m; Height of base of cloud
+  0;   20;     14;     -1;         -40;   11;            m; Height of top of cloud
+  0;   20;     15;     -1;           0;   14;           Pa; Pressure at the base of cloud
+  0;   20;     16;     -1;           0;   14;           Pa; Pressure at the top of cloud
+  0;   20;     17;      0;           0;    4;   Code_Table; Cloud top description
+  0;   20;     18;     -1;          40;   11;            m; Low estimated height of cloud top
+  0;   20;     19;     -1;          40;   11;            m; High estimated height of cloud top
+  0;   20;     20;      0;           0;    4;   Code_Table; Low cloud amount
+  0;   20;     21;      0;           0;    4;   Code_Table; Middle cloud amount
+  0;   20;     22;      0;           0;    4;   Code_Table; High cloud amount
+  0;   20;     23;      0;           0;    7;      percent; Satellite sensed effective cloud amount
+  0;   20;     31;      2;           0;    7;            m; Ice deposit (thickness)
+  0;   20;     32;      0;           0;    3;   Code_Table; Rate of ice accretion
+  0;   20;     33;      0;           0;    4;   Flag_Table; Cause of ice accretion
+  0;   20;     34;      0;           0;    5;   Code_Table; Sea ice concentration
+  0;   20;     35;      0;           0;    4;   Code_Table; Amount and type of ice
+  0;   20;     36;      0;           0;    5;   Code_Table; Ice situation
+  0;   20;     37;      0;           0;    5;   Code_Table; Ice development
+  0;   20;     38;      0;           0;   12;     deg_true; Bearing of ice edge
+  0;   20;     39;     -1;           0;   13;            m; Ice distance
+  0;   20;     41;      0;           0;    4;   Code_Table; Airframe icing
+  0;   20;     49;      0;           0;   10;   Code_Table; Type of stability measure
+  0;   20;     50;      0;           0;   10;      Numeric; Value of stability
+  0;   20;     51;      0;           0;    7;      percent; Amount of low clouds
+  0;   20;     52;      0;           0;    7;      percent; Amount of middle clouds
+  0;   20;     53;      0;           0;    7;      percent; Amount of high clouds
+  0;   20;     61;      0;           0;   12;            m; Runway visual range (RVR)
+  0;   20;     62;      0;           0;    5;   Code_Table; State of the ground(with or without snow)
+  0;   20;     63;      0;           0;   10;   Code_Table; Special phenomena
+
+  0;   21;      1;      0;         -64;    7;           dB; Horizontal reflectivity
+  0;   21;      2;      0;         -64;    7;           dB; Vertical reflectivity
+  0;   21;      3;      1;          -5;    7;           dB; Differential reflectivity
+  0;   21;      5;      0;         -65;    6;           dB; Linear depolarization ratio
+  0;   21;      6;      0;         -65;    6;           dB; Circular depolarization ratio
+  0;   21;     11;      0;        -128;    8;          m/s; Doppler mean velocity in X direction
+  0;   21;     12;      0;        -128;    8;          m/s; Doppler mean velocity in Y direction
+  0;   21;     13;      0;        -128;    8;          m/s; Doppler mean velocity in Z direction
+  0;   21;     14;      1;       -4096;   13;          m/s; Doppler mean velocity (radiational)
+  0;   21;     17;      1;       -4096;    8;          m/s; Doppler velocity spectral width
+  0;   21;     21;     -3;           0;    4;            m; Echo tops
+  0;   21;     30;      0;         -32;    8;           dB; Signal to noise ratio
+  0;   21;     31;      0;           0;    7;      kg/m**2; Vertical integrated liquid water content
+  0;   21;     36;      7;           0;   12;          m/s; Radar rainfall intensity
+  0;   21;     41;     -2;           0;    8;            m; Bright band height
+  0;   21;     51;      0;        -256;    8;           dB; Signal power above 1 MW
+
+  0;   22;      1;      0;           0;    9;     deg_true; Direction of waves
+  0;   22;      2;      0;           0;    9;     deg_true; Direction of wind waves
+  0;   22;      3;      0;           0;    9;     deg_true; Direction of swell waves
+  0;   22;      4;      0;           0;    9;     deg_true; Direction of current waves
+  0;   22;     11;      0;           0;    6;            s; Period of waves
+  0;   22;     12;      0;           0;    6;            s; Period of wind waves
+  0;   22;     13;      0;           0;    6;            s; Period of swell waves
+  0;   22;     21;      1;           0;   10;            m; Height of waves
+  0;   22;     22;      1;           0;   10;            m; Height of wind waves
+  0;   22;     23;      1;           0;   10;            m; Height of swell waves
+  0;   22;     25;      2;           0;   10;            m; Standard deviation wave
+  0;   22;     31;      2;           0;   13;          m/s; Speed of current
+  0;   22;     41;      1;           0;   12;        deg_K; Sea surface temperature (15 day running mean)
+  0;   22;     42;      1;           0;   12;        deg_K; Sea temperature
+  0;   22;     43;      2;           0;   15;        deg_K; Sea temperature
+  0;   22;     44;      1;           0;   14;          m/s; Sound velocity
+  0;   22;     50;      2;           0;    8;            K; Standard deviation sea surface temperature
+  0;   22;     61;      0;           0;    4;   Code_Table; State of sea
+  0;   22;     62;      2;           0;   12;          ppt; Salinity
+  0;   22;     63;      0;           0;   14;            m; Total water depth
+  0;   22;    105;     -1;           0;    6;     deg_true; Direction of waves
+  0;   22;    143;      2;        2650;   13;        deg_K; Sea temperature
+
+  0;   23;      1;      0;           0;    3;   Code_Table; Accident early notification - article applicable
+  0;   23;      2;      0;           0;    5;   Code_Table; Activity or facility involved in incident
+  0;   23;      3;      0;           0;    3;   Code_Table; Type of release
+  0;   23;      4;      0;           0;    3;   Code_Table; Countermeasures taken near border
+  0;   23;      5;      0;           0;    2;   Code_Table; Cause of incident
+  0;   23;      6;      0;           0;    3;   Code_Table; Incident situation
+  0;   23;      7;      0;           0;    3;   Code_Table; Characteristic of release
+  0;   23;      8;      0;           0;    2;   Code_Table; State of current release
+  0;   23;      9;      0;           0;    2;   Code_Table; State of expected release
+  0;   23;     16;      0;           0;    2;   Code_Table; Possibility of significant chemical toxic health effect
+  0;   23;     17;      6;           0;   20;       m**3/s; Flow discharge of major recipient
+  0;   23;     18;      0;           0;    3;   Code_Table; release behavior over time
+  0;   23;     19;      0;      -15000;   17;            m; Actual release height
+  0;   23;     21;      0;      -15000;   17;            m; Effective release height
+  0;   23;     22;      0;           0;   24;            m; Distance of relative point or site of incident
+  0;   23;     23;      1;           0;   12;          m/s; Main transport speed in atmosphere
+  0;   23;     24;      2;           0;   13;          m/s; Main transport speed in water
+  0;   23;     25;      2;           0;   13;          m/s; Main transport speed in ground water
+  0;   23;     27;      0;           0;    9;     deg_true; Main transport direction in atmosphere
+  0;   23;     28;      0;           0;    9;     deg_true; Main transport direction in water
+  0;   23;     29;      0;           0;    9;     deg_true; Main transport direction in ground water
+  0;   23;     31;      0;           0;    2;   Code_Table; Possibility that plume will encounter precipitation cwin state in which incident occurred
+  0;   23;     32;      0;           0;    2;   Code_Table; Plume will encounter ichange in wind direction and/or speed flag
+
+  0;   24;      1;     -1;           0;   28;           Bq; Estimate of radiatioactivity released up to specified time
+  0;   24;      2;     -1;           0;   28;           Bq; Estimated maximum potential release
+  0;   24;      3;      0;           0;    5;   Code_Table; Composition of release
+  0;   24;      4;      0;           0;   16;    CCITT_IA5; Element name
+  0;   24;      5;      0;           0;    9;      Numeric; Isotope mass
+  0;   24;     11;      2;           0;   32;          mSv; Dose
+  0;   24;     12;      2;           0;   32;          mSv; Trajectory dose (defined location and expected time of arrival)
+  0;   24;     13;      2;           0;   32;          mSv; Gamma dose in air along the main transport path (defined location and time period
+  0;   24;     21;      2;           0;   32;      Bq/m**3; Air concentration (named isotope type including gross beta)
+  0;   24;     22;      2;           0;   32;         Bq/l; Concentration in precipitation (of named isotope type)
+
+  0;   25;      1;     -1;           0;    6;            m; Range gate length
+  0;   25;      2;      0;           0;    4;      Numeric; Number of gates averaged
+  0;   25;      3;      0;           0;    8;      Numeric; Number of integrated pulses
+  0;   25;      4;      0;           0;    2;   Code_Table; Echo processing
+  0;   25;      5;      0;           0;    2;   Code_Table; Echo integration
+  0;   25;      6;      0;           0;    3;   Code_Table; Z to R conversion
+  0;   25;      7;      0;           0;   12;      Numeric; Z to R conversion factor
+  0;   25;      8;      2;           0;    9;      Numeric; Z to R conversion exponent
+  0;   25;      9;      0;           0;    4;   Flag_Table; Calibration method
+  0;   25;     10;      0;           0;    4;   Code_Table; Clutter treatment
+  0;   25;     11;      0;           0;    2;   Code_Table; Ground occultation correction (screening)
+  0;   25;     12;      0;           0;    2;   Code_Table; Range attenuation correction
+  0;   25;     13;      0;           0;    2;   Flag_Table; Bright band correction
+  0;   25;     15;      0;           0;    2;   Flag_Table; Radome attenuation correction
+  0;   25;     16;      5;           0;    6;         dB/m; Clear air attenuation correction
+  0;   25;     17;      0;           0;    2;   Flag_Table; Precipitation attenuation correction
+  0;   25;     18;      7;           0;    6;      Numeric; A to Z law for attenuation factor
+  0;   25;     19;      2;           0;    7;      Numeric; A to Z law for attenuation exponent
+  0;   25;     20;      0;           0;    2;   Code_Table; Mean speed estimation
+  0;   25;     21;      0;           0;    8;   Flag_Table; Wind computation enhancement
+  0;   25;     30;      0;           0;    2;   Code_Table; SST usage
+  0;   25;     31;      0;           0;    2;   Code_Table; 15 day SST availability
+  0;   25;     32;      0;           0;    2;   Code_Table; NOAA wind profiler high/low mode data
+  0;   25;     33;      0;           0;    2;   Code_Table; NOAA wind profiler submode
+  0;   25;     34;      0;           0;    4;   Code_Table; NOAA wind profiler Q/C test results
+  0;   25;     35;      0;           0;    3;   Code_Table; First guess adjustment
+  0;   25;     36;      3;       -5000;   14;      Numeric; NSTAR average value
+  0;   25;     37;      0;           0;    2;   Code_Table; HIRS-8 surface air temperature
+  0;   25;     38;      0;           0;    3;   Code_Table; TOVS filter flags
+
+  0;   27;      1;      5;    -9000000;   25;          deg; Latitude (high accuracy)
+  0;   27;      2;      2;       -9000;   15;          deg; Latitude (coarse accuracy)
+  0;   27;      3;      2;       -9000;   15;          deg; Alternate latitude
+  0;   27;     20;      0;           0;   16;      Numeric; Satellite locationon counter
+  0;   27;     21;      0;           0;   16;      Numeric; Satellite sub-locationon dimensions
+
+  0;   28;      1;      5;   -18000000;   26;          deg; Longtiude (high accuracy)
+  0;   28;      2;      2;      -18000;   16;          deg; Longtiude (coarse accuracy)
+  0;   28;      3;      2;      -18000;   16;          deg; Alternate longtiude
+
+  0;   29;      1;      0;           0;    3;   Code_Table; Projection type
+  0;   29;      2;      0;           0;    2;   Code_Table; Coordinate grid type
+
+  0;   30;      1;      0;           0;    4;      Numeric; Pixel value (4 bits)
+  0;   30;     21;      0;           0;   12;      Numeric; Number of pixels per row
+  0;   30;     22;      0;           0;   12;      Numeric; Number of pixels per column
+  0;   30;     31;      0;           0;    4;   Code_Table; Picture type
+  0;   30;     32;      0;           0;   16;   Flag_Table; Combined picture
+
+  0;   31;      0;      0;           0;    1;   Flag_Table; Delayed descriptor replication switch
+  0;   31;      1;      0;           0;    8;      Numeric; Delayed descriptor replication factor
+  0;   31;      2;      0;           0;   16;      Numeric; Extended delayed descriptor replication factor
+  0;   31;     11;      0;           0;    8;      Numeric; Delayed descriptor and data repetion factor
+  0;   31;     12;      0;           0;   16;      Numeric; Extended delayed descriptor and data repitition factor
+  0;   31;     21;      0;           0;    6;   Code_Table; Associated field significance
+
+#0	0	0	0	0	0	undef	undefined used for SSMI - temporary
+
+  0;   50;    200;      2;      636700;   24;           km; Altitude(km)
+  0;   50;    201;      6;           0;   24;  Rad(Si)/sec; Dosage
+  0;   50;    202;      6;           0;   24;        Gauss; B-Field
+  0;   50;    203;      3;      -20000;   24;           Re; Coordinate
+  0;   50;    204;      3;           0;   24;            -; L-Shell
+
+  0;   51;    200;     -2;           0;   24; KeV/(cm2-s-Sr); e-Energy Flux
+  0;   51;    201;     -2;           0;   24; #/(cm2-s-Sr); e-Number Flux
+  0;   51;    202;     -2;           0;   24; KeV/(cm2-s-Sr); i-Energy Flux
+  0;   51;    203;     -2;           0;   24; #/(cm2-s-Sr); i-Number Flux
+  0;   51;    204;      6;         -10;   24;         mhos; Ped Conduct.
+  0;   51;    205;      6;         -10;   24;         mhos; Hall Conduct.
+
+  0;   52;    200;      5;           0;   26;            -; S4
+  0;   52;    201;      5;           0;   25;            -; SI
+  0;   52;    202;      5;           0;   24;            -; PCT
+  0;   52;    203;      5;           0;   24;            -; PRMS
+
+  0;   53;    200;     -1;           0;   25;       cm**-3; Ne
+  0;   53;    201;      3;           0;   24;          MHz; FE
+  0;   53;    202;      3;           0;   24;          MHz; FoF2
+  0;   53;    203;      3;           0;   20;           km; HE
+  0;   53;    204;      3;           0;   20;           km; HF2
+#
+# Table definitions
+#
+#0	63	000	0	0	0	-	End of Table Descriptors
+#0	63	001	0	0	8	Numeric	Number of Dimensions
+#0	63	002	0	0	8	Numeric	Dimension Size
+#0	63	003	0	0	8	Code_Table	Object Type
+#0	63	004	0	0	8	Flag_Table	Flags
+#0	63	005	0	0	16	Numeric	Object Count
+#0	63	006	0	0	16	Numeric	Object Offset
+#0	63	007	0	0	8	Code_Table	Axis Label
diff --git a/data/tables/B2L-128-001-B b/data/tables/B2L-128-001-B
new file mode 100644
index 0000000..b6c0134
--- /dev/null
+++ b/data/tables/B2L-128-001-B
@@ -0,0 +1,95 @@
+#
+# B2L-128-001-B.001 - Local BUFR Table B for center 128 (NRL Monterey),
+# Minor Local Version 1
+#
+#					Data
+#F	X	Y	Scale	RefVal	Width	Units	Element Name
+  0;    0;      0;      0;           0;    0;        undef; undefined used for SSMI - temporary
+
+  0;    1;     50;      0;           0;   48;    CCITT_IA5; NMC report identifier
+  0;    1;     62;      0;           0;   40;    CCITT_IA5; National assigned station identifier
+
+  0;    2;     28;      0;           0;   32;   Flag_Table; Geostationary sounder satellite channels used
+  0;    2;     29;      0;           0;    8;   Flag_Table; Geostationary sounder satellite channels used
+  0;    2;    190;      0;           0;    8;   Code_Table; U, v quality indicator
+  0;    2;    191;      0;           0;    4;   Code_Table; W quality indicator
+
+  0;    4;     44;      0;           0;    3;   Code_Table; Day of the week
+
+  0;    5;      3;      2;       -9000;   15;          deg; Alternate latitude
+  0;    5;     50;      5;           0;   17;      Numeric; Sigma level
+
+  0;    6;      3;      2;      -18000;   16;          deg; Alternate longtiude
+
+  0;    8;      0;      0;           0;    4;   Code_Table; Vertical significance (forecast soundings)
+  0;    8;     31;      0;           0;    8;         BUFR; Table A	Data category
+  0;    8;     32;      0;           0;   14;   Code_Table; Data significance for simulated forecast
+  0;    8;     33;      0;           0;    3;   Code_Table; Data significance for corrected forecast
+  0;    8;     34;      0;           0;    3;   Code_Table; Data significance for simulated retrievals
+  0;    8;     35;      0;           0;    3;   Code_Table; Data significance for corrected retrievals
+  0;    8;     36;      0;           0;    3;   Code_Table; Data significance for simulated analysis
+  0;    8;     37;      0;           0;    3;   Code_Table; Data significance for corrected analysis
+  0;    8;     38;      0;           0;    3;   Code_Table; Data significance for sigma level data
+
+  0;   12;     20;      2;       -2000;   12;    deg_K/day; Radiative heating profile
+  0;   12;     40;     -3;       -2048;   12;       W/m**2; Sensible heat flux
+
+  0;   13;     40;     -3;       -2048;   12;       W/m**2; Latent heat flux
+
+  0;   14;     41;      0;           0;    7;      percent; Short wave albedo
+
+  0;   20;      9;     -1;         -40;   11;            m; Ceiling
+  0;   20;     18;     -1;          40;   11;            m; Low estimated height of cloud top
+  0;   20;     19;     -1;          40;   11;            m; High estimated height of cloud top
+  0;   20;     20;      0;           0;    4;   Code_Table; Low cloud amount
+  0;   20;     21;      0;           0;    4;   Code_Table; Middle cloud amount
+  0;   20;     22;      0;           0;    4;   Code_Table; High cloud amount
+  0;   20;     23;      0;           0;    7;      percent; Satellite sensed effective cloud amount
+  0;   20;     49;      0;           0;   10;   Code_Table; Type of stability measure
+  0;   20;     50;      0;           0;   10;      Numeric; Value of stability
+
+  0;   22;    105;     -1;           0;    6;     deg_true; Direction of waves
+  0;   22;    143;      2;        2650;   13;        deg_K; Sea temperature
+
+  0;   25;     31;      0;           0;    2;   Code_Table; 15 day SST availability
+  0;   25;     35;      0;           0;    3;   Code_Table; First guess adjustment
+  0;   25;     36;      3;       -5000;   14;      Numeric; NSTAR average value
+  0;   25;     37;      0;           0;    2;   Code_Table; HIRS-8 surface air temperature
+  0;   25;     38;      0;           0;    3;   Code_Table; TOVS filter flags
+
+  0;   50;    200;      2;      636700;   24;           km; Altitude(km)
+  0;   50;    201;      6;           0;   24;  Rad(Si)/sec; Dosage
+  0;   50;    202;      6;           0;   24;        Gauss; B-Field
+  0;   50;    203;      3;      -20000;   24;           Re; Coordinate
+  0;   50;    204;      3;           0;   24;            -; L-Shell
+
+  0;   51;    200;     -2;           0;   24; KeV/(cm2-s-Sr); e-Energy Flux
+  0;   51;    201;     -2;           0;   24; #/(cm2-s-Sr); e-Number Flux
+  0;   51;    202;     -2;           0;   24; KeV/(cm2-s-Sr); i-Energy Flux
+  0;   51;    203;     -2;           0;   24; #/(cm2-s-Sr); i-Number Flux
+  0;   51;    204;      6;         -10;   24;         mhos; Ped Conduct.
+  0;   51;    205;      6;         -10;   24;         mhos; Hall Conduct.
+
+  0;   52;    200;      5;           0;   26;            -; S4
+  0;   52;    201;      5;           0;   25;            -; SI
+  0;   52;    202;      5;           0;   24;            -; PCT
+  0;   52;    203;      5;           0;   24;            -; PRMS
+
+  0;   53;    200;     -1;           0;   25;       cm**-3; Ne
+  0;   53;    201;      3;           0;   24;          MHz; FE
+  0;   53;    202;      3;           0;   24;          MHz; FoF2
+  0;   53;    203;      3;           0;   20;           km; HE
+  0;   53;    204;      3;           0;   20;           km; HF2
+
+#
+# Table definitions
+#
+  0;   63;      0;      0;           0;    0;            -; End of Table Descriptors
+  0;   63;      1;      0;           0;    8;      Numeric; Number of Dimensions
+  0;   63;      2;      0;           0;    8;      Numeric; Dimension Size
+  0;   63;      3;      0;           0;    8;   Code_Table; Object Type
+  0;   63;      4;      0;           0;    8;   Flag_Table; Flags
+  0;   63;      5;      0;           0;   16;      Numeric; Object Count
+  0;   63;      6;      0;           0;   16;      Numeric; Object Offset
+  0;   63;      7;      0;           0;    8;   Code_Table; Axis Label
+  0;   22;    203;      2;      -18000;   16;      summary; break angle
diff --git a/data/tables/B2L-128-001-B.001 b/data/tables/B2L-128-001-B.001
new file mode 100644
index 0000000..53b0bd7
--- /dev/null
+++ b/data/tables/B2L-128-001-B.001
@@ -0,0 +1,94 @@
+#
+# B2L-128-001-B.001 - Local BUFR Table B for center 128 (NRL Monterey),
+# Minor Local Version 1
+#
+#					Data
+#F	X	Y	Scale	RefVal	Width	Units	Element Name
+0	0	0	0	0	0	undef	undefined used for SSMI - temporary
+
+0	1	50	0	0	48	CCITT_IA5	NMC report identifier
+0	1	62	0	0	40	CCITT_IA5	National assigned station identifier
+
+0	2	28	0	0	32	Flag_Table	Geostationary sounder satellite channels used
+0	2	29	0	0	8	Flag_Table	Geostationary sounder satellite channels used
+0	2	190	0	0	8	Code_Table	U, v quality indicator
+0	2	191	0	0	4	Code_Table	W quality indicator
+
+0	4	44	0	0	3	Code_Table	Day of the week
+
+0	5	3	2	-9000	15	deg	Alternate latitude
+0	5	50	5	0	17	Numeric	Sigma level
+
+0	6	3	2	-18000	16	deg	Alternate longtiude
+
+0	8	0	0	0	4	Code_Table	Vertical significance (forecast soundings)
+0	8	31	0	0	8	BUFR Table A	Data category
+0	8	32	0	0	14	Code_Table	Data significance for simulated forecast
+0	8	33	0	0	3	Code_Table	Data significance for corrected forecast
+0	8	34	0	0	3	Code_Table	Data significance for simulated retrievals
+0	8	35	0	0	3	Code_Table	Data significance for corrected retrievals
+0	8	36	0	0	3	Code_Table	Data significance for simulated analysis
+0	8	37	0	0	3	Code_Table	Data significance for corrected analysis
+0	8	38	0	0	3	Code_Table	Data significance for sigma level data
+
+0	12	20	2	-2000	12	deg_K/day	Radiative heating profile
+0	12	40	-3	-2048	12	W/m**2	Sensible heat flux
+
+0	13	40	-3	-2048	12	W/m**2	Latent heat flux
+
+0	14	41	0	0	7	percent	Short wave albedo
+
+0	20	9	-1	-40	11	m	Ceiling
+0	20	18	-1	40	11	m	Low estimated height of cloud top
+0	20	19	-1	40	11	m	High estimated height of cloud top
+0	20	20	0	0	4	Code_Table	Low cloud amount
+0	20	21	0	0	4	Code_Table	Middle cloud amount
+0	20	22	0	0	4	Code_Table	High cloud amount
+0	20	23	0	0	7	percent	Satellite sensed effective cloud amount
+0	20	49	0	0	10	Code_Table	Type of stability measure
+0	20	50	0	0	10	Numeric	Value of stability
+
+0	22	105	-1	0	6	deg_true	Direction of waves
+0	22	143	2	2650	13	deg_K	Sea temperature
+
+0	25	31	0	0	2	Code_Table	15 day SST availability
+0	25	35	0	0	3	Code_Table	First guess adjustment
+0	25	36	3	-5000	14	Numeric	NSTAR average value
+0	25	37	0	0	2	Code_Table	HIRS-8 surface air temperature
+0	25	38	0	0	3	Code_Table	TOVS filter flags
+
+0	50	200	2	636700	24	km	Altitude(km)
+0	50	201	6	0	24	Rad(Si)/sec	Dosage
+0	50	202	6	0	24	Gauss	B-Field
+0	50	203	3	-20000	24	Re	Coordinate
+0	50	204	3	0	24	-	L-Shell
+
+0	51	200	-2	0	24	KeV/(cm2-s-Sr)	e-Energy Flux
+0	51	201	-2	0	24	#/(cm2-s-Sr)	e-Number Flux
+0	51	202	-2	0	24	KeV/(cm2-s-Sr)	i-Energy Flux
+0	51	203	-2	0	24	#/(cm2-s-Sr)	i-Number Flux
+0	51	204	6	-10	24	mhos	Ped Conduct.
+0	51	205	6	-10	24	mhos	Hall Conduct.
+
+0	52	200	5	0	26	-	S4
+0	52	201	5	0	25	-	SI
+0	52	202	5	0	24	-	PCT
+0	52	203	5	0	24	-	PRMS
+
+0	53	200	-1	0	25	cm**-3	Ne
+0	53	201	3	0	24	MHz	FE
+0	53	202	3	0	24	MHz	FoF2
+0	53	203	3	0	20	km	HE
+0	53	204	3	0	20	km	HF2
+
+#
+# Table definitions
+#
+0	63	000	0	0	0	-	End of Table Descriptors
+0	63	001	0	0	8	Numeric	Number of Dimensions
+0	63	002	0	0	8	Numeric	Dimension Size
+0	63	003	0	0	8	Code_Table	Object Type
+0	63	004	0	0	8	Flag_Table	Flags
+0	63	005	0	0	16	Numeric	Object Count
+0	63	006	0	0	16	Numeric	Object Offset
+0	63	007	0	0	8	Code_Table	Axis Label
diff --git a/data/tables/B2L-128-001-D b/data/tables/B2L-128-001-D
new file mode 100644
index 0000000..f94bc40
--- /dev/null
+++ b/data/tables/B2L-128-001-D
@@ -0,0 +1,25 @@
+#
+# B2L-128-001-D.001 - Local BUFR Table D (Lists of Common Sequences)
+# for center 128 (NRL Monterey), Minor Local Version 1
+#
+# Descriptor sequences are terminated with -1
+#
+# Sequences do not need to appear in any order.  Sequence A
+# which includes sequence B, may appear before sequence B
+# is defined.
+#
+
+# Phony local descriptor for debugging purposes
+#
+#3	5	1
+#	0	2	102		# Antenna height above tower base (8 bits)
+#	0	2	104		# Antenna polarization            (4 bits)
+#	0	2	113		# Number of azimuth looks         (4 bits)
+#	-1
+#
+3	5	1
+	0	2	 11		# Radiosonde type                 (8 bits)
+	0	2	 22		# Satellite DP technique used     (8 bits)
+	0	2	102		# Antenna height above tower base (8 bits)
+	-1
+
diff --git a/data/tables/B2L-128-001-D.001 b/data/tables/B2L-128-001-D.001
new file mode 100644
index 0000000..f94bc40
--- /dev/null
+++ b/data/tables/B2L-128-001-D.001
@@ -0,0 +1,25 @@
+#
+# B2L-128-001-D.001 - Local BUFR Table D (Lists of Common Sequences)
+# for center 128 (NRL Monterey), Minor Local Version 1
+#
+# Descriptor sequences are terminated with -1
+#
+# Sequences do not need to appear in any order.  Sequence A
+# which includes sequence B, may appear before sequence B
+# is defined.
+#
+
+# Phony local descriptor for debugging purposes
+#
+#3	5	1
+#	0	2	102		# Antenna height above tower base (8 bits)
+#	0	2	104		# Antenna polarization            (4 bits)
+#	0	2	113		# Number of azimuth looks         (4 bits)
+#	-1
+#
+3	5	1
+	0	2	 11		# Radiosonde type                 (8 bits)
+	0	2	 22		# Satellite DP technique used     (8 bits)
+	0	2	102		# Antenna height above tower base (8 bits)
+	-1
+
diff --git a/data/tables/B2M-000-000-0 b/data/tables/B2M-000-000-0
new file mode 100644
index 0000000..b68ae8b
--- /dev/null
+++ b/data/tables/B2M-000-000-0
@@ -0,0 +1,308 @@
+##############################################################################
+# BUFR Table 0
+#
+#
+# Notes
+# -----
+#
+# * This table comes from GRIB Code Table 0 (Identification of center)
+#
+# * A value of 1 in the first column indicates a center that uses minor
+#   version numbers with local tables.  Since minor local table version
+#   numbers are stored in Section 1, Octet 18, the value in the first
+#   column must not be set if a center uses Section 1, Octet 18 for other
+#   purposes (i.e., ECMWF).
+#
+#
+##############################################################################
+
+0	  0	RESERVED
+
+# 1-9: WMCs
+
+0	  1	Melbourne
+0	  2	Melbourne
+0	  3	Melbourne
+0	  4	Moscow
+0	  5	Moscow
+0	  6	Moscow
+0	  7	US Weather Service - National Meteorological Center (NMC)
+0	  8	US National Weather Service Telecommunications Gateway (NWSTG)
+0	  9	Reserved for USA
+
+# 10-25: Centers in Region I
+
+0	 10	Cairo (RSMC/RAFC)
+0	 11	Cairo (RSMC/RAFC)
+0	 12	Dakar (RSMC/RAFC)
+0	 13	Dakar (RSMC/RAFC)
+0	 14	Nairobi (RSMC/RAFC)
+0	 15	Nairobi (RSMC/RAFC)
+0	 16	Antananarivo (RSMC)
+0	 17	Antananarivo (RSMC)
+0	 18	Tunis-Casablanca (RSMC/RAFC)
+0	 19	Tunis-Casablanca (RSMC/RAFC)
+0	 20	Las Palmas (RAFC)
+0	 21	Algiers (RSMC)
+0	 22	Lagos (RSMC)
+0	 23	Lagos (RSMC)
+0	 24	Reserved for other centers in Region I
+0	 25	Reserved for other centers in Region I
+
+# 26-40 Centers in Region II
+
+0	 26	Khabarovsk (RSMC)
+0	 27	Khabarovsk (RSMC)
+0	 28	New Delhi (RSMC/RAFC)
+0	 29	New Delhi (RSMC/RAFC)
+0	 30	Novosibirsk (RSMC)
+0	 31	Novosibirsk (RSMC)
+0	 32	Tashkent (RSMC)
+0	 33	Tashkent (RSMC)
+0	 34	Tokyo (RSMC), Japan Meteorological Agency
+0	 35	Tokyo (RSMC/RAFC)
+0	 36	Bangkok (RAFC)
+0	 37	Ulan Bator
+0	 38	Beijing (RSMC)
+0	 39	Beijing (RSMC)
+0	 40	Reserved for other centers in Region II
+
+# 41-50: Centers in Region III
+
+0	 41	Buenos Aires (RSMC/RAFC)
+0	 42	Buenos Aires (RSMC/RAFC)
+0	 43	Brasilia (RSMC/RAFC)
+0	 44	Brasilia (RSMC/RAFC)
+0	 45	Santiago
+0	 46	Brazilian Space Agency - INPE
+0	 47	Reserved for other centers in Region III
+0	 48	Reserved for other centers in Region III
+0	 49	Reserved for other centers in Region III
+0	 50	Reserved for other centers in Region III
+
+# 51-63: Centers in Region IV
+
+0	 51	Miami (RSMC/RAFC)
+0	 52	Miami (RSMC), National Hurricane Center
+0	 53	Montreal (RSMC)
+0	 54	Montreal (RSMC)
+0	 55	San Francisco
+0	 56	RESERVED
+0	 57	US Air Force - Air Force Global Weather Central (AFGWC)
+1	 58	Fleet Numerical Oceanography Center (FNOC), Monterey, CA, USA
+0	 59	The NOAA Forecast Systems Laboratory, Boulder, CO, USA
+0	 60	Reserved for other centers in Region IV
+0	 61	Reserved for other centers in Region IV
+0	 62	Reserved for other centers in Region IV
+0	 63	Reserved for other centers in Region IV
+
+# 64-73: Centers in Region V
+
+0	 64	Honolulu (RAFC)
+0	 65	Darwin (RSMC/RAFC)
+0	 66	Darwin (RSMC/RAFC)
+0	 67	Melbourne (RSMC)
+0	 68	RESERVED
+0	 69	Wellington (RSMC/RAFC)
+0	 70	Wellington (RSMC/RAFC)
+0	 71	Reserved for other centers in Region V
+0	 72	Reserved for other centers in Region V
+0	 73	Reserved for other centers in Region V
+
+# 74-98: Centers in Region VI
+
+0	 74	UK Meteorological Office - Bracknell
+0	 75	UK Meteorological Office - Bracknell
+0	 76	Moscow (RSMC/RAFC)
+0	 77	RESERVED
+0	 78	Offenbach (RSMC)
+0	 79	Offenbach (RSMC)
+0	 80	Rome (RSMC/RAFC)
+0	 81	Rome (RSMC/RAFC)
+0	 82	Norrkoping (RSMC)
+0	 83	Norrkoping (RSMC)
+0	 84	Paris (RAFC)
+0	 85	Toulouse
+0	 86	Helsinki
+0	 87	Belgrade
+0	 88	Oslo
+0	 89	Prague
+0	 90	Episkopi
+0	 91	Ankara
+0	 92	Francfort/Main (RAFC)
+0	 93	London (WAFC)
+0	 94	Copenhagen
+0	 95	Rota
+0	 96	Athens
+0	 97	European Space Agency (ESA)
+
+# ECMWF (Center 98) does not support minor local table version numbers
+# so DO NOT set the first value to 1.
+
+0	 98	European Center for Medium Range Weather Forecasts (ECMWF)(RSMC)
+0	 99	De Bilt
+
+# 100-127: RESERVED
+
+0	100	RESERVED
+0	101	RESERVED
+0	102	RESERVED
+0	103	RESERVED
+0	104	RESERVED
+0	105	RESERVED
+0	106	RESERVED
+0	107	RESERVED
+0	108	RESERVED
+0	109	RESERVED
+0	110	RESERVED
+0	111	RESERVED
+0	112	RESERVED
+0	113	RESERVED
+0	114	RESERVED
+0	115	RESERVED
+0	116	RESERVED
+0	117	RESERVED
+0	118	RESERVED
+0	119	RESERVED
+0	120	RESERVED
+0	121	RESERVED
+0	122	RESERVED
+0	123	RESERVED
+0	124	RESERVED
+0	125	RESERVED
+0	126	RESERVED
+0	127	RESERVED
+
+# 128-254: NATIONAL USE
+
+1	128	Naval Research Laboratory (NRL), Monterey CA
+0	129	CAST
+0	130	AFCCC
+0	131	PL
+0	132	ARL
+0	133	WES
+0	134	NATIONAL USE
+0	135	NATIONAL USE
+0	136	NATIONAL USE
+0	137	NATIONAL USE
+0	138	NATIONAL USE
+0	139	NATIONAL USE
+0	140	NATIONAL USE
+0	141	NATIONAL USE
+0	142	NATIONAL USE
+0	143	NATIONAL USE
+0	144	NATIONAL USE
+0	145	NATIONAL USE
+0	146	NATIONAL USE
+0	147	NATIONAL USE
+0	148	NATIONAL USE
+0	149	NATIONAL USE
+0	150	NATIONAL USE
+0	151	NATIONAL USE
+0	152	NATIONAL USE
+0	153	NATIONAL USE
+0	154	NATIONAL USE
+0	155	NATIONAL USE
+0	156	NATIONAL USE
+0	157	NATIONAL USE
+0	158	NATIONAL USE
+0	159	NATIONAL USE
+0	160	NATIONAL USE
+0	161	NATIONAL USE
+0	162	NATIONAL USE
+0	163	NATIONAL USE
+0	164	NATIONAL USE
+0	165	NATIONAL USE
+0	166	NATIONAL USE
+0	167	NATIONAL USE
+0	168	NATIONAL USE
+0	169	NATIONAL USE
+0	170	NATIONAL USE
+0	171	NATIONAL USE
+0	172	NATIONAL USE
+0	173	NATIONAL USE
+0	174	NATIONAL USE
+0	175	NATIONAL USE
+0	176	NATIONAL USE
+0	177	NATIONAL USE
+0	178	NATIONAL USE
+0	179	NATIONAL USE
+0	180	NATIONAL USE
+0	181	NATIONAL USE
+0	182	NATIONAL USE
+0	183	NATIONAL USE
+0	184	NATIONAL USE
+0	185	NATIONAL USE
+0	186	NATIONAL USE
+0	187	NATIONAL USE
+0	188	NATIONAL USE
+0	189	NATIONAL USE
+0	190	NATIONAL USE
+0	191	NATIONAL USE
+0	192	NATIONAL USE
+0	193	NATIONAL USE
+0	194	NATIONAL USE
+0	195	NATIONAL USE
+0	196	NATIONAL USE
+0	197	NATIONAL USE
+0	198	NATIONAL USE
+0	199	NATIONAL USE
+0	200	NATIONAL USE
+0	201	NATIONAL USE
+0	202	NATIONAL USE
+0	203	NATIONAL USE
+0	204	NATIONAL USE
+0	205	NATIONAL USE
+0	206	NATIONAL USE
+0	207	NATIONAL USE
+0	208	NATIONAL USE
+0	209	NATIONAL USE
+0	210	NATIONAL USE
+0	211	NATIONAL USE
+0	212	NATIONAL USE
+0	213	NATIONAL USE
+0	214	NATIONAL USE
+0	215	NATIONAL USE
+0	216	NATIONAL USE
+0	217	NATIONAL USE
+0	218	NATIONAL USE
+0	219	NATIONAL USE
+0	220	NATIONAL USE
+0	221	NATIONAL USE
+0	222	NATIONAL USE
+0	223	NATIONAL USE
+0	224	NATIONAL USE
+0	225	NATIONAL USE
+0	226	NATIONAL USE
+0	227	NATIONAL USE
+0	228	NATIONAL USE
+0	229	NATIONAL USE
+0	230	NATIONAL USE
+0	231	NATIONAL USE
+0	232	NATIONAL USE
+0	233	NATIONAL USE
+0	234	NATIONAL USE
+0	235	NATIONAL USE
+0	236	NATIONAL USE
+0	237	NATIONAL USE
+0	238	NATIONAL USE
+0	239	NATIONAL USE
+0	240	NATIONAL USE
+0	241	NATIONAL USE
+0	242	NATIONAL USE
+0	243	NATIONAL USE
+0	244	NATIONAL USE
+0	245	NATIONAL USE
+0	246	NATIONAL USE
+0	247	NATIONAL USE
+0	248	NATIONAL USE
+0	249	NATIONAL USE
+0	250	NATIONAL USE
+0	251	NATIONAL USE
+0	252	NATIONAL USE
+0	253	NATIONAL USE
+0	254	NATIONAL USE
+
+# 255: Used to indicate missing or unknown center
+
+0	255	MISSING VALUE
diff --git a/data/tables/B2M-000-000-A b/data/tables/B2M-000-000-A
new file mode 100644
index 0000000..7ccbff5
--- /dev/null
+++ b/data/tables/B2M-000-000-A
@@ -0,0 +1,259 @@
+#
+# BUFR Table A - Data Category
+#
+  0	Surface data - land
+  1	Surface data - sea
+  2	Vertical soundings (other than satellite)
+  3	Vertical soundings (satellite)
+  4	Single level upper-air data (other than satellite)
+  5	Single level upper-air data (satellite)
+  6	Radar data
+  7	Synoptic features
+  8	Physical/chemical constituents
+  9	Dispersal and transport
+ 10	Radiological data
+ 11	BUFR tables, complete replacement or update
+ 12	Surface data (satellite)
+ 13	RESERVED
+ 14	RESERVED
+ 15	RESERVED
+ 16	RESERVED
+ 17	RESERVED
+ 18	RESERVED
+ 19	RESERVED
+ 20	Status information
+ 21	Radiances (satellite measured)
+ 22	RESERVED
+ 23	RESERVED
+ 24	RESERVED
+ 25	RESERVED
+ 26	RESERVED
+ 27	RESERVED
+ 28	RESERVED
+ 29	RESERVED
+ 30	RESERVED
+ 31	Oceanographic data
+ 32	RESERVED
+ 33	RESERVED
+ 34	RESERVED
+ 35	RESERVED
+ 36	RESERVED
+ 37	RESERVED
+ 38	RESERVED
+ 39	RESERVED
+ 40	RESERVED
+ 41	RESERVED
+ 42	RESERVED
+ 43	RESERVED
+ 44	RESERVED
+ 45	RESERVED
+ 46	RESERVED
+ 47	RESERVED
+ 48	RESERVED
+ 49	RESERVED
+ 50	RESERVED
+ 51	RESERVED
+ 52	RESERVED
+ 53	RESERVED
+ 54	RESERVED
+ 55	RESERVED
+ 56	RESERVED
+ 57	RESERVED
+ 58	RESERVED
+ 59	RESERVED
+ 60	RESERVED
+ 61	RESERVED
+ 62	RESERVED
+ 63	RESERVED
+ 64	RESERVED
+ 65	RESERVED
+ 66	RESERVED
+ 67	RESERVED
+ 68	RESERVED
+ 69	RESERVED
+ 70	RESERVED
+ 71	RESERVED
+ 72	RESERVED
+ 73	RESERVED
+ 74	RESERVED
+ 75	RESERVED
+ 76	RESERVED
+ 77	RESERVED
+ 78	RESERVED
+ 79	RESERVED
+ 80	RESERVED
+ 81	RESERVED
+ 82	RESERVED
+ 83	RESERVED
+ 84	RESERVED
+ 85	RESERVED
+ 86	RESERVED
+ 87	RESERVED
+ 88	RESERVED
+ 89	RESERVED
+ 90	RESERVED
+ 91	RESERVED
+ 92	RESERVED
+ 93	RESERVED
+ 94	RESERVED
+ 95	RESERVED
+ 96	RESERVED
+ 97	RESERVED
+ 98	RESERVED
+ 99	RESERVED
+100	RESERVED
+101	Image data
+102	RESERVED
+103	RESERVED
+104	RESERVED
+105	RESERVED
+106	RESERVED
+107	RESERVED
+108	RESERVED
+109	RESERVED
+110	RESERVED
+111	RESERVED
+112	RESERVED
+113	RESERVED
+114	RESERVED
+115	RESERVED
+116	RESERVED
+117	RESERVED
+118	RESERVED
+119	RESERVED
+120	RESERVED
+121	RESERVED
+122	RESERVED
+123	RESERVED
+124	RESERVED
+125	RESERVED
+126	RESERVED
+127	RESERVED
+128	RESERVED
+129	RESERVED
+130	RESERVED
+131	RESERVED
+132	RESERVED
+133	RESERVED
+134	RESERVED
+135	RESERVED
+136	RESERVED
+137	RESERVED
+138	RESERVED
+139	RESERVED
+140	RESERVED
+141	RESERVED
+142	RESERVED
+143	RESERVED
+144	RESERVED
+145	RESERVED
+146	RESERVED
+147	RESERVED
+148	RESERVED
+149	RESERVED
+150	RESERVED
+151	RESERVED
+152	RESERVED
+153	RESERVED
+154	RESERVED
+155	RESERVED
+156	RESERVED
+157	RESERVED
+158	RESERVED
+159	RESERVED
+160	RESERVED
+161	RESERVED
+162	RESERVED
+163	RESERVED
+164	RESERVED
+165	RESERVED
+166	RESERVED
+167	RESERVED
+168	RESERVED
+169	RESERVED
+170	RESERVED
+171	RESERVED
+172	RESERVED
+173	RESERVED
+174	RESERVED
+175	RESERVED
+176	RESERVED
+177	RESERVED
+178	RESERVED
+179	RESERVED
+180	RESERVED
+181	RESERVED
+182	RESERVED
+183	RESERVED
+184	RESERVED
+185	RESERVED
+186	RESERVED
+187	RESERVED
+188	RESERVED
+189	RESERVED
+190	RESERVED
+191	RESERVED
+192	RESERVED
+193	RESERVED
+194	RESERVED
+195	RESERVED
+196	RESERVED
+197	RESERVED
+198	RESERVED
+199	RESERVED
+200	RESERVED
+201	RESERVED
+202	RESERVED
+203	RESERVED
+204	RESERVED
+205	RESERVED
+206	RESERVED
+207	RESERVED
+208	RESERVED
+209	RESERVED
+210	RESERVED
+211	RESERVED
+212	RESERVED
+213	RESERVED
+214	RESERVED
+215	RESERVED
+216	RESERVED
+217	RESERVED
+218	RESERVED
+219	RESERVED
+220	RESERVED
+221	RESERVED
+222	RESERVED
+223	RESERVED
+224	RESERVED
+225	RESERVED
+226	RESERVED
+227	RESERVED
+228	RESERVED
+229	RESERVED
+230	RESERVED
+231	RESERVED
+232	RESERVED
+233	RESERVED
+234	RESERVED
+235	RESERVED
+236	Message Type 005-001 SATWIND GOES. INFRARED CHANNEL
+237	Message Type 005-002 SATWIND GOES. VISIBLE CHANNEL
+238	Message Type 005-003 SATWIND GOES. WATER VAPOR CHANNEL
+239	Message Type 005-004 SATWIND GOES. CHANNEL COMBINATION 
+240	Message Type 005-021 SATWIND INDIA. INFRARED CHANNEL
+241	Message Type 005-022 SATWIND INDIA. VISIBLE CHANNEL
+242	Message Type 005-023 SATWIND INDIA. WATER VAPOR CHANNEL
+243	Message Type 005-024 SATWIND INDIA. CHANNEL COMBINATION
+244	Message Type 005-041 SATWIND JAPAN. INFRARED CHANNEL
+245	Message Type 005-042 SATWIND JAPAN. VISIBLE CHANNEL
+246	Message Type 005-043 SATWIND JAPAN. WATER VAPOR CHANNEL
+247	Message Type 005-044 SATWIND JAPAN. CHANNEL COMBINATION
+248	Message Type 005-061 SATWIND EUMETSAT. INFRARED CHANNEL
+249	Message Type 005-062 SATWIND EUMETSAT. VISIBLE CHANNEL
+250	Message Type 005-063 SATWIND EUMETSAT. WATER VAPOR CHANNEL
+251	Message Type 005-064 SATWIND EUMETSAT. CHANNEL COMBINATION
+252	FOR EXPERIMENTAL USE
+253	FOR EXPERIMENTAL USE
+254	FOR EXPERIMENTAL USE
+255	Indicator for local use, with sub-category
diff --git a/data/tables/B2M-000-000-B b/data/tables/B2M-000-000-B
new file mode 100644
index 0000000..4a11827
--- /dev/null
+++ b/data/tables/B2M-000-000-B
@@ -0,0 +1,702 @@
+#
+# BUFR Table B - Classification of Elements
+#
+#                                       Data
+#F      X       Y       Scale   RefVal  Width   Units           Element Name
+  0;    0;      1;      0;           0;   24;    CCITT_IA5; TABLE A ENTRY
+  0;    0;      2;      0;           0;  256;    CCITT_IA5; TABLE A  DATA CATEGORY DESCRIPTIO
+  0;    0;      3;      0;           0;  256;    CCITT_IA5; TABLE A DATA CATEGORY DESCRIPTION
+  0;    0;      5;      0;           0;   24;    CCITT_IA5; BUFR EDITION NUMBER
+  0;    0;     10;      0;           0;    8;    CCITT_IA5; F DESCRIPTOR TO BE ADDED OR DEFIN
+  0;    0;     11;      0;           0;   16;    CCITT_IA5; X DESCRIPTOR TO BE ADDED OR DEFIN
+  0;    0;     12;      0;           0;   24;    CCITT_IA5; Y DESCRIPTOR TO BE ADDED OR DEFIN
+  0;    0;     13;      0;           0;  256;    CCITT_IA5; ELEMENT NAME LN 1
+  0;    0;     14;      0;           0;  256;    CCITT_IA5; ELEMENT NAME LN 2
+  0;    0;     15;      0;           0;  192;    CCITT_IA5; UNITS NAME
+  0;    0;     16;      0;           0;    8;    CCITT_IA5; UNITS SCALE SIGN
+  0;    0;     17;      0;           0;   24;    CCITT_IA5; UNITS SCALE
+  0;    0;     18;      0;           0;    8;    CCITT_IA5; UNITS REFERENCE SIGN
+  0;    0;     19;      0;           0;   80;    CCITT_IA5; UNITS REFERENCE VALUE
+  0;    0;     20;      0;           0;   24;    CCITT_IA5; ELEMENT DATA WIDTH
+  0;    0;     30;      0;           0;   48;    CCITT_IA5; DESCRIPTOR DEFINING SEQUENCE
+  0;    1;      1;      0;           0;    7;      NUMERIC; WMO BLOCK NUMBER
+  0;    1;      2;      0;           0;   10;      NUMERIC; WMO STATION NUMBER
+  0;    1;      3;      0;           0;    3;      NUMERIC; WMO REGION NUMBER
+  0;    1;      4;      0;           0;    3;      NUMERIC; WMO REGION SUB-AREA
+  0;    1;      5;      0;           0;   17;      NUMERIC; BUOY/PLATFORM IDENTIFIER
+  0;    1;      6;      0;           0;   64;    CCITT_IA5; AIRCRAFT IDENTIFIER (FLIGHT NUMBE
+  0;    1;      7;      0;           0;   10;   CODE_TABLE; SATELLITE IDENTIFIER
+  0;    1;      8;      0;           0;   64;    CCITT_IA5; AIRCRAFT REGISTRATION NUMBER (TAI
+  0;    1;      9;      0;           0;   64;    CCITT_IA5; TYPE OF COMMERCIAL ACFT
+  0;    1;     10;      0;           0;   64;    CCITT_IA5; STATIONARY BOUY PLATFORM IDENTIFI
+  0;    1;     11;      0;           0;   72;    CCITT_IA5; SHIP CALL SIGN
+  0;    1;     12;      0;           0;    9; DEGREES_TRUE; DIRECTION OF MOTION OBSERVING PLA
+  0;    1;     13;      0;           0;   10; METER/SECOND; SPEED OF MOTION OF OBSERVING PLAT
+  0;    1;     14;      2;           0;   10; METER/SECOND; PLATFORM DRIFT SPEED (HIGH PRECIS
+  0;    1;     15;      0;           0;    4;   CODE_TABLE; TRUE DIR OF MOVING PLATFORM PAST
+  0;    1;     16;      0;           0;    4;   CODE_TABLE; AVG SPD MOVING PLATFORM PAST 3 HO
+  0;    1;     21;      0;           0;   14;      NUMERIC; SYNOPTIC FEATURE ID
+  0;    1;     25;      0;           0;   24;    CCITT_IA5; STORM IDENTIFIER
+  0;    1;     26;      0;           0;   64;    CCITT_IA5; WMO STORM NAME
+  0;    1;     31;      0;           0;   16;   CODE_TABLE; GENERATING CENTER
+  0;    1;     32;      0;           0;    8;   CODE_TABLE; GENERATING APPLICATION
+  0;    1;     50;      0;           0;   48;    CCITT_IA5; NMC REPORT IDENTIFIER
+  0;    1;     62;      0;           0;   40;    CCITT_IA5; NAT'L ASSIGNED STATION IDENTIFIER
+  0;    1;     63;      0;           0;   64;    CCITT_IA5; ICAO LOCATION IDENTIFIER
+  0;    1;    192;      0;           0;    4;    CCITT_IA5; RADIOSONDE REPORT PART
+  0;    1;    193;      0;           0;   64;    CCITT_IA5; SATELLITE IDENTIFIER
+  0;    1;    194;      0;           0;   64;    CCITT_IA5; BULLETIN HEADER
+  0;    1;    195;      0;           0;   48;    CCITT_IA5; NMC REPORT IDENTIFIER
+  0;    1;    196;      0;           0;   96;    CCITT_IA5; ALPHANUMERIC IDENTIFIER
+  0;    1;    197;      0;           0;   64;    CCITT_IA5; RADIOSONDE SHIP OR MOBILE LND STN
+  0;    2;      1;      0;           0;    2;   CODE_TABLE; TYPE OF STATION
+  0;    2;      2;      0;           0;    4;   FLAG_TABLE; TYPE OF INSTR. FOR WIND MEASUREME
+  0;    2;      3;      0;           0;    4;   CODE_TABLE; TYPE OF MEASURING INSTRUMENT USED
+  0;    2;      4;      0;           0;    4;   CODE_TABLE; TYPE OF INSTR/CROP FOR EVAP/EVAPO
+  0;    2;      5;      2;           0;    7;      DEGREES; PRECISION OF TEMPERATURE OBS.
+  0;    2;     11;      0;           0;    8;   CODE_TABLE; RADIOSONDE TYPE
+  0;    2;     12;      0;           0;    4;   CODE_TABLE; RADIOSONDE COMPUTATIONAL METHOD
+  0;    2;     13;      0;           0;    4;   CODE_TABLE; SOLAR AND INFRARED RADIATION CORR
+  0;    2;     14;      0;           0;    7;   CODE_TABLE; TRACKING TECHNIQUE/STATUS OF SYST
+  0;    2;     15;      0;           0;    4;   CODE_TABLE; RADIOSONDE COMPLETENESS
+  0;    2;     21;      0;           0;    9;   FLAG_TABLE; SATELLITE INSTRUMENT DATA USED IN
+  0;    2;     22;      0;           0;    8;   FLAG_TABLE; SATELLITE DATA PROCESSING TECHNIQ
+  0;    2;     23;      0;           0;    4;   CODE_TABLE; SATELLITE DERIVED WIND COMPUTATIO
+  0;    2;     24;      0;           0;    4;   CODE_TABLE; INT. MEAN HUMIDITY COMPUTATIONAL
+  0;    2;     25;      0;           0;   25;   FLAG_TABLE; SATELLITE CHANNEL(S) USED IN COMP
+  0;    2;     26;      2;           0;   12;       METERS; CROSS TRACK RESOLUTION
+  0;    2;     27;      2;           0;   12;       METERS; ALONG TRACK RESOLUTION
+  0;    2;     28;      0;           0;   32;   FLAG_TABLE; GEOSTAT. SOUNDER SATELL CHAN'LS U
+  0;    2;     29;      0;           0;    8;   FLAG_TABLE; GEOSTAT. SOUNDER SATELL CHAN'LS U
+  0;    2;     30;      0;           0;    3;   CODE_TABLE; METH OF CURRENT MEASUREMENT
+  0;    2;     31;      0;           0;    5;   CODE_TABLE; DURATION & TIME OF CURRENT CODE M
+  0;    2;     32;      0;           0;    2;   CODE_TABLE; INDICATOR FOR DIGITIZATION
+  0;    2;     33;      0;           0;    3;   CODE_TABLE; METHOD OF SALINITY/DEPTH MEASUREM
+  0;    2;     34;      0;           0;    5;   CODE_TABLE; DROGUE TYPE
+  0;    2;     35;      0;           0;    9;       METERS; CABLE LENGTH
+  0;    2;     36;      0;           0;    2;   CODE_TABLE; BUOY TYPE
+  0;    2;     37;      0;           0;    3;   CODE_TABLE; METHOD OF TIDAL OBSERVATION
+  0;    2;     38;      0;           0;    3;   CODE_TABLE; METH OF SEA SURFACE TEMPERATURE M
+  0;    2;     39;      0;           0;    3;   CODE_TABLE; METH OF WET BULB TEMPERATURE MEAS
+  0;    2;     40;      0;           0;    4;   CODE_TABLE; METH RMV CODE VELOC & MOTION OF P
+  0;    2;     41;      0;           0;    6;   CODE_TABLE; METH FOR EST RPTS OF SYNOP FEATUR
+  0;    2;     42;      0;           0;    6;   CODE_TABLE; METHOD OF REPORT CONSTRUCTION
+  0;    2;     43;      0;           0;    6;   CODE_TABLE; PRECISION OF LAT/LON REPORT
+  0;    2;     51;      0;           0;    4;   CODE_TABLE; INDIC TO SPECIFY OBS METH EXTRM T
+  0;    2;     61;      0;           0;    3;   CODE_TABLE; AIRCRAFT NAVIGATION   SYSTEM
+  0;    2;     62;      0;           0;    4;   CODE_TABLE; TYPE OF AIRCRAFT DATA RELAY SYSTE
+  0;    2;     63;      2;      -18000;   16;      DEGREES; AIRCRAFT ROLL ANGLE
+  0;    2;     70;      0;           0;    4;   CODE_TABLE; ORIGINAL SPECIFICATION OF LAT/LON
+  0;    2;    101;      0;           0;    4;   CODE_TABLE; TYPE OF ANTENNA
+  0;    2;    102;      0;           0;    8;       METERS; ANTENNA HGT ABOVE TOWER
+  0;    2;    103;      0;           0;    2;        FLAGE; TABLE     RADOME
+  0;    2;    104;      0;           0;    4;   CODE_TABLE; ANTENNA POLARIZATION
+  0;    2;    105;      0;           0;    6;           DB; MAXIMUM ANTENNA GAIN
+  0;    2;    106;      1;           0;    6;      DEGREES; 3 - DB BANDWIDTH
+  0;    2;    107;      0;           0;    6;           DB; SIDELOBE SUPRESSION
+  0;    2;    108;      0;           0;    6;           DB; CROSSPOL DISCRI. (ON AXIS)
+  0;    2;    109;      2;           0;   12; DEGREES/SECOND; ANTENNA SPEED (AZIMUTH)
+  0;    2;    110;      2;           0;   12; DEGREES/SECOND; ANTENNA SPEED (ELEVATION)
+  0;    2;    111;      1;           0;   10;      DEGREES; RADAR INCIDENCE ANGLE
+  0;    2;    112;      1;           0;   12;      DEGREES; RADAR AZIMUTH ANGLE
+  0;    2;    113;      0;           0;    4;     NUMERICS; NO. OF AZIMUTH LOOKS
+  0;    2;    114;      0;           0;   15;         M**2; ANTENNA EFFECTIVE SURFACE AREA
+  0;    2;    121;      8;           0;    7;           HZ; MEAN FREQUENCY
+  0;    2;    122;      6;        -128;    8;           HZ; FREQUENCY AGILITY RANGE
+  0;    2;    123;      4;           0;    7;        WATTS; PEAK POWER
+  0;    2;    124;      1;           0;    7;        WATTS; AVERAGE POWER
+  0;    2;    125;      1;           0;    8;           HZ; PULSE REPETITION FREQUENCY
+  0;    2;    126;      7;           0;    6;       SECOND; PULSE WIDTH
+  0;    2;    127;      6;           0;    7;           HZ; RECEIVER INTERMEDIATE FREQUENCY
+  0;    2;    128;      5;           0;    6;           HZ; INTERMEDIATE FREQUENCY BANDWIDTH
+  0;    2;    129;      0;        -150;    5;           DB; MINIMUM DETECTABLE SIGNAL
+  0;    2;    130;      0;           0;    7;           DB; DYNAMIC RANGE
+  0;    2;    131;      0;           0;    2;   FLAG_TABLE; SENSITIVITY TIME CONTROL
+  0;    2;    132;      2;           0;    6;      DEGREES; AZIMUTH POINTING ACCURACY
+  0;    2;    133;      2;           0;    6;      DEGREES; ELEVATION POINTING ACCURACY
+  0;    2;    134;      2;           0;   16;      DEGREES; ANTENNA BEAM AZIMUTH
+  0;    2;    135;      2;       -9000;   15;      DEGREES; ANTENNA ELEVATION
+  0;    2;    140;      0;           0;    9;      DEGREES; SATELLITE RADAR BEAM AZIMUTH ANGL
+  0;    2;    141;      0;           0;   24;    CCITT_IA5; MEAS.TYPE SERIAL NBR/IDENT
+  0;    2;    142;      0;           0;   32;    CCITT_IA5; OZONE INSTRUMENT
+  0;    2;    143;      0;           0;    7;      NUMERIC; INSTRUMENT TYPE
+  0;    2;    183;      0;           0;    1;   CODE_TABLE; QUALITY OF PRESSURE MEASUREMENT
+  0;    2;    184;      0;           0;    1;   CODE_TABLE; QUALITY OF WATER SFC TEMP MEASURE
+  0;    2;    185;      0;           0;    1;   CODE_TABLE; QUALITY OF AIR TEMP MEASUREMENT
+  0;    2;    186;      0;           0;    3;   CODE_TABLE; QUAL CONTROL INDIC FOR FOLLOWING
+  0;    2;    187;      0;           0;    1;   CODE_TABLE; QUALITY OF BUOY SATELLIT TRANSMIS
+  0;    2;    188;      0;           0;    3;   CODE_TABLE; QUAL CONTROL INDICATOR FOR BUOY L
+  0;    2;    189;      0;           0;    3;   CODE_TABLE; QUAL CONTROL INDIC FOR BUOY TIME
+  0;    2;    190;      0;           0;    8;   CODE_TABLE; U, V QUALITY INDICATOR
+  0;    2;    191;      0;           0;    4;   CODE_TABLE; W QUALITY INDICATOR
+  0;    2;    192;      0;           0;    6;   CODE_TABLE; RADIOSONDE CORRECTION TYPE APPLIE
+  0;    2;    193;      0;           0;    3;   CODE_TABLE; IND TYPE OF STN OPERATION PAST/PR
+  0;    2;    200;      0;           0;    4;   CODE_TABLE; OBJECTIVE FORECAST TECHNIQUE USED
+  0;    2;    206;      0;           0;    4;        MONTH; MONTH  - RELEASE TIME
+  0;    2;    207;      0;           0;    6;          DAY; DAY    - RELEASE TIME
+  0;    2;    208;      0;           0;    5;         HOUR; HOUR   - RELEASE TIME
+  0;    2;    209;      0;           0;    6;       MINUTE; MINUTE - RELEASE TIME
+  0;    2;    210;      0;           0;    3;   FLAG_TABLE; STATION/SEA LEVEL COMPARISON
+  0;    4;      1;      0;           0;   12;         YEAR; YEAR
+  0;    4;      2;      0;           0;    4;        MONTH; MONTH
+  0;    4;      3;      0;           0;    6;          DAY; DAY
+  0;    4;      4;      0;           0;    5;         HOUR; HOUR
+  0;    4;      5;      0;           0;    6;       MINUTE; MINUTE
+  0;    4;      6;      0;           0;    6;       SECOND; SECOND
+  0;    4;     11;      0;       -1024;   11;        YEARS; TIME INCREMENT
+  0;    4;     12;      0;       -1024;   11;       MONTHS; TIME INCREMENT
+  0;    4;     13;      0;       -1024;   11;         DAYS; TIME INCREMENT
+  0;    4;     14;      0;       -1024;   11;        HOURS; TIME INCREMENT
+  0;    4;     15;      0;       -2048;   12;      MINUTES; TIME INCREMENT
+  0;    4;     16;      0;       -4096;   13;      SECONDS; TIME INCREMENT
+  0;    4;     21;      0;       -1024;   11;        YEARS; TIME PERIOD OR DISPLACEMENT
+  0;    4;     22;      0;       -1024;   11;       MONTHS; TIME PERIOD OR DISPLACEMENT
+  0;    4;     23;      0;       -1024;   11;         DAYS; TIME PERIOD OR DISPLACEMENT
+  0;    4;     24;      0;       -2048;   12;        HOURS; TIME PERIOD OR DISPLACEMENT
+  0;    4;     25;      0;       -2048;   12;      MINUTES; TIME PERIOD OR DISPLACEMENT
+  0;    4;     26;      0;       -4096;   13;      SECONDS; TIME PERIOD OR DISPLACEMENT
+  0;    4;     31;      0;           0;    8;         HOUR; DUR OF TIME REL TO FOLLOWING VALU
+  0;    4;     41;      0;       -1440;   12;       MINUTE; TIME DIFFERENCE UTC - LMT
+  0;    4;     43;      0;           0;    9;          DAY; DAY OF THE YEAR
+  0;    4;     44;      0;           0;    3;   CODE_TABLE; DAY OF THE WEEK
+  0;    4;     53;      0;           0;    6;      NUMERIC; NUMBER OF DAYS WITH PRECIP => 1MM
+  0;    4;    192;      0;           0;   12;        HOURS; RECIEPT TIME - REPORT TIME
+  0;    4;    193;      0;           0;   12;      MINUTES; RECIEPT TIME - REPORT TIME
+  0;    4;    194;      0;           0;   12;        HOURS; RELEASE TIME OF SONDE
+  0;    4;    195;      0;           0;    5;         HOUR; FORECAST CYCLE HOUR
+  0;    4;    200;      0;           0;   12;         YEAR; YEAR   - TIME OF RECEIPT
+  0;    4;    201;      0;           0;    4;        MONTH; MONTH  - TIME OF RECEIPT
+  0;    4;    202;      0;           0;    6;          DAY; DAY    - TIME OF RECEIPT
+  0;    4;    203;      0;           0;    5;         HOUR; HOUR   - TIME OF RECEIPT
+  0;    4;    204;      0;           0;    6;       MINUTE; MINUTE - TIME OF RECEIPT
+  0;    4;    205;      0;           0;    6;       SECOND; SECOND - TIME OF RECEIPT
+  0;    4;    206;      0;           0;   32;       SECOND; DATA BASE INGEST TIME FROM 1 JAN
+  0;    4;    207;      0;           0;    5;         HOUR; HOUR - TIME OF MAX WIND (GUST)
+  0;    4;    208;      0;           0;    6;       MINUTE; MINUTE - TIME OF NAX WIND (GUST)
+  0;    5;      1;      5;    -9000000;   25;      DEGREES; LATITUDE(HIGH ACCURACY)
+  0;    5;      2;      2;       -9000;   15;      DEGREES; LATITUDE(COARSE ACCURACY)
+  0;    5;      3;      2;       -9000;   15;      DEGREES; ALTERNATE LATITUDE
+  0;    5;     11;      5;    -9000000;   25;      DEGREES; LATITUDE INCREMENT(HIGH ACCURACY)
+  0;    5;     12;      2;       -9000;   15;      DEGREES; LATITUDE INCREMENT(COARSE ACCURAC
+  0;    5;     21;      2;           0;   16; DEGREES_TRUE; BEARING OR AZIMUTH
+  0;    5;     22;      2;           0;   16; DEGREES_TRUE; SOLAR AZIMUTH
+  0;    5;     30;      0;           0;   12;      DEGREES; DIRECTION (SPECTRAL)
+  0;    5;     31;      0;           0;   12;      NUMERIC; ROW NUMBER
+  0;    5;     33;      1;           0;   16;       METERS; PIXEL SIZE ON HORIZONTAL-1
+  0;    5;     40;      0;           0;   24;      NUMERIC; ORBIT NUMBER
+  0;    5;     41;      0;           0;    8;      NUMERIC; SCAN LINE NUMBER
+  0;    5;     42;      0;           0;    6;      NUMERIC; CHANNEL NUMBER
+  0;    5;     43;      0;           0;    8;      NUMERIC; FIELD OF VIEW NUMBER
+  0;    5;     50;      5;           0;   17;      NUMERIC; SIGMA LEVEL
+  0;    5;     52;      0;           0;    5;      NUMERIC; CHANNEL NUMBER INCREMENT
+  0;    5;     53;      0;           0;    5;      NUMERIC; FIELD OF VIEW NUMBER INCREMENT
+  0;    6;      1;      5;   -18000000;   26;      DEGREES; LONGITUDE (HIGH ACCURACY)
+  0;    6;      2;      2;      -18000;   16;      DEGREES; LONGITUDE (COARSE ACCURACY)
+  0;    6;      3;      2;      -18000;   16;      DEGREES; ALTERNATE LONGITUDE
+  0;    6;     11;      5;   -18000000;   26;      DEGREES; LONGITUDE INCREMENT (HIGH ACCURAC
+  0;    6;     12;      2;      -18000;   16;      DEGREES; LONGITUDE INCREMENT (COARSE ACCUR
+  0;    6;     21;      1;           0;   13;       METERS; DISTANCE
+  0;    6;     30;      5;           0;   13;        RAD/M; WAVENUMBER (SPECTRAL)
+  0;    6;     31;      0;           0;   12;      NUMERIC; COLUMN NUMBER
+  0;    6;     33;      1;           0;   16;       METERS; PIXEL SIZE ON HORIZONTAL-2
+  0;    7;      1;      0;        -400;   15;       METERS; HEIGHT OF STATION
+  0;    7;      2;      1;         -40;   16;       METERS; HEIGHT OR ALTITUDE
+  0;    7;      3;      1;        -400;   17;    M**2/S**2; GEOPOTENTIAL
+  0;    7;      4;      1;           0;   14;      PASCALS; PRESSURE
+  0;    7;      5;      0;        -400;   12;       METERS; HEIGHT INCREMENT
+  0;    7;      6;      0;           0;   15;       METERS; HEIGHT ABOVE STATION
+  0;    7;      7;      0;       -1000;   17;            M; HEIGHT
+  0;    7;      8;      0;      -10000;   20;    M**2/S**2; GEOPOTENTIAL
+  0;    7;     21;      2;       -9000;   15;      DEGREES; ELEVATION
+  0;    7;     22;      2;       -9000;   15;      DEGREES; SOLAR ELEVATION
+  0;    7;     61;      2;           0;   14;       METERS; DEPTH BELOW LAND SURFACE
+  0;    7;     62;      1;           0;   17;       METERS; DEPTH BELOW SEA SURFACE
+  0;    7;    190;      0;           0;   12;       METERS; HEIGHT INCREMENT
+  0;    7;    192;      0;        -400;   17;          GPM; FLIGHT LEVEL (PRESSURE ALTITUDE)
+  0;    7;    193;      0;        -400;   17;         GPDM; FLIGHT LEVEL (PRESSURE ALTITUDE)
+  0;    7;    194;      0;        -400;   15;            M; HEIGHT OR ALTITUDE ABOVE MSL
+  0;    8;      1;      0;           0;    7;   FLAG_TABLE; VERTICAL SOUNDING SIGNIFICANCE
+  0;    8;      2;      0;           0;    6;   CODE_TABLE; VERT. SIGNIFICANCE (SFC OBSERVATI
+  0;    8;      3;      0;           0;    6;   CODE_TABLE; VERT. SIGNIFICANCE (SAT OBSERVATI
+  0;    8;      4;      0;           0;    3;   CODE_TABLE; PHASE OF AIRCRAFT FLIGHT
+  0;    8;      5;      0;           0;    4;   CODE_TABLE; SURFACE SYNOPTIC FEATURE SIGNIFIC
+  0;    8;     10;      0;           0;    4;   CODE_TABLE; VERT SIGNIFICANCE(FORECAST SOUNDI
+  0;    8;     11;      0;           0;    6;   CODE_TABLE; HORIZONTAL SIGNIFICANCE
+  0;    8;     12;      0;           0;    2;   CODE_TABLE; LAND/SEA QUALIFIER
+  0;    8;     13;      0;           0;    2;   CODE_TABLE; DAY/NIGHT QUALIFIER
+  0;    8;     20;      0;           0;   16;      NUMERIC; TOTAL NR MISG ENTITIES W/RES TO A
+  0;    8;     21;      0;           0;    5;   CODE_TABLE; TIME SIGNIFICANCE
+  0;    8;     22;      0;           0;   16;      NUMERIC; TOTAL NUMBER(W/RESPECT TO ACCUM O
+  0;    8;     23;      0;           0;    7;   CODE_TABLE; FIRST ORDER STATISTICS
+  0;    8;     24;      0;           0;    7;   CODE_TABLE; DIFFERENCE STATISTICS
+  0;    8;     31;      0;           0;    8;         BUFR; TABLE A    DATA CATEGORY
+  0;    8;     32;      0;           0;   14;   CODE_TABLE; DATA SIGNIF-INTERACTIVE RETRIEVAL
+  0;    8;     51;      0;           0;    3;   CODE_TABLE; QUALIFIER-NR MISG VALUES IN CALC
+  0;    8;     52;      0;           0;    5;   CODE_TABLE; COND. FOR  WHICH NR OF DAYS OF OC
+  0;    8;     53;      0;           0;    2;   CODE_TABLE; DAY OF OCCURRENCE QUALIFIER
+  0;    8;    192;      0;           0;   16;      NUMERIC; UPDATE SEQUENCE NUMBER
+  0;    8;    193;      0;           0;   16;      NUMERIC; OBSERVATION DATABASE KEY
+  0;    8;    194;      0;           0;    6;   CODE_TABLE; CORRECTION INDICATOR
+  0;    8;    195;      0;           0;    6;   CODE_TABLE; QUALITY CONTROL TYPE
+  0;    8;    196;      0;           0;    6;   CODE_TABLE; QUALITY CONTROL DECISION
+  0;    8;    197;      0;           0;    5;   CODE_TABLE; RECORD TEMPERATURE KEY
+  0;    8;    198;      0;           0;    4;   CODE_TABLE; TIME SIGNIFICANCE
+  0;    8;    199;      0;           0;    3;   CODE_TABLE; SOURCE UNITS OF WIND SPEED
+  0;    8;    200;      0;           0;    4;      NUMERIC; NMC QUALITY MARK
+  0;    8;    232;      0;           0;   14;   CODE_TABLE; DATA SIGNIF-INTERACTIVE RETRIEVAL
+  0;    9;      6;      3;           0;   10;      SECONDS; TIME OF ASCENDING NODE
+  0;   10;      1;      0;        -400;   15;       METERS; HEIGHT OF LAND SURFACE
+  0;   10;      2;      1;         -40;   16;       METERS; HEIGHT
+  0;   10;      3;      1;        -400;   17;    M**2/S**2; GEOPOTENTIAL
+  0;   10;      4;      1;           0;   14;      PASCALS; PRESSURE
+  0;   10;      7;      0;       -1000;   17;       METERS; HEIGHT
+  0;   10;      8;      0;      -10000;   20;    M**2/S**2; GEOPOTENTIAL
+  0;   10;     50;      2;           0;   16;       METERS; STD. DEV. ALTITUDE
+  0;   10;     51;      1;           0;   14;      PASCALS; PRESSURE REDUCED TO MSL
+  0;   10;     52;      1;           0;   14;      PASCALS; ALTIMETER SETTING (QNH)
+  0;   10;     60;      1;       -1024;   11;      PASCALS; PRESSURE CHANGE
+  0;   10;     61;      1;        -500;   10;      PASCALS; 3 HOUR PRESSURE CHANGE
+  0;   10;     62;      1;       -1000;   11;      PASCALS; 24 HOUR PRESSURE CHANGE
+  0;   10;     63;      0;           0;    4;   CODE_TABLE; CHARACTERISTIC OF PRESSURE TENDEN
+  0;   10;    192;      0;        -400;   17;          GPM; GEOPOTENTIAL HEIGHT
+  0;   10;    193;      0;        -400;   17;         GPDM; GEOPOTENTIAL HEIGHT
+  0;   10;    194;      0;       -2000;   17;          GPM; DEPARTURE FROM ICAO STD ATMOSPHER
+  0;   10;    195;      0;        -400;   17;           DM; GEOMETRIC HEIGHT
+  0;   11;      1;      0;           0;    9; DEGREES_TRUE; WIND DIRECTION
+  0;   11;      2;      1;           0;   12; METERS/SECOND; WIND SPEED
+  0;   11;      3;      1;       -4096;   13; METERS/SECOND; U-COMPONENT
+  0;   11;      4;      1;       -4096;   13; METERS/SECOND; V-COMPONENT
+  0;   11;      5;      1;        -512;   10; PASCALS/SECOND; W-COMPONENT
+  0;   11;      6;      2;       -4096;   13; METERS/SECOND; W-COMPONENT
+  0;   11;     11;      0;           0;    9; DEGREES_TRUE; WIND DIRECTION AT 10 METERS
+  0;   11;     12;      1;           0;   12; METERS/SECOND; WIND SPEED AT 10 METERS
+  0;   11;     13;      0;           0;    9; DEGREES_TRUE; WIND DIRECTION AT 5 METERS
+  0;   11;     14;      1;           0;   12; METERS/SECOND; WIND SPEED AT 5 METERS
+  0;   11;     21;      9;      -65536;   17;   SECOND**-1; RELATIVE VORTICITY
+  0;   11;     22;      9;      -65536;   17;   SECOND**-1; DIVERGENCE
+  0;   11;     23;      2;      -65536;   17;  M**2/SECOND; VELOCITY POTENTIAL
+  0;   11;     31;      0;           0;    4;   CODE_TABLE; DEGREE OF TURBULENCE
+  0;   11;     32;      1;         -40;   16;       METERS; HEIGHT OF BASE OF TURBULENCE
+  0;   11;     33;      1;         -40;   16;       METERS; HEIGHT OF TOP OF TURBULENCE
+  0;   11;     34;      1;       -1024;   11; METERS/SECOND; VERTICAL GUST VELOCITY
+  0;   11;     35;      2;       -8192;   14; METERS/SECOND**2VERTICAL; GUST ACCELERATION
+  0;   11;     36;      1;           0;   10; METERS/SECOND; MAXIMUM DERIVED EQUIVALENT VERTIC
+  0;   11;     41;      1;           0;   12; METERS/SECOND; MAX WIND SPEED (GUSTS)
+  0;   11;     42;      1;           0;   12; METERS/SECOND; MAX WIND SPEED(10 MIN MEAN WIND)
+  0;   11;     43;      0;           0;    9; DEGREES_TRUE; MAXIMUM WIND GUST DIRECTION
+  0;   11;     44;      0;           0;    9; DEGREES_TRUE; SFC-5000FT MEAN LYR WIND DIRECTIO
+  0;   11;     49;      0;           0;    9; DEGREES_TRUE; STD. DEV. OF WIND DIRECTION
+  0;   11;     50;      1;           0;   12; METERS/SECOND; STD. DEV. HORIZ WIND SPEED
+  0;   11;     51;      1;           0;    8; METERS/SECOND; STD DEV VERT WIND COMPONENT
+  0;   11;     61;      1;           0;   12; METERS/SECOND; ABSOLUTE WIND SHEAR(1KM LAYER BEL
+  0;   11;     62;      1;           0;   12; METERS/SECOND; ABSOLUTE WIND SHEAR(1KM LAYER ABO
+  0;   11;    192;      1;       -1024;   11; METERS/SECOND; MEAN U-COMPONENT
+  0;   11;    193;      1;       -1024;   11; METERS/SECOND; MEAN V-COMPONENT
+  0;   11;    194;      1;        -128;    8; METERS/SECOND; MEAN W-COMPONENT
+  0;   11;    195;      1;           0;    9; METERS/SECOND; STANDARD DEVIATION U
+  0;   11;    196;      1;           0;    9; METERS/SECOND; STANDARD DEVIATION V
+  0;   11;    197;      1;           0;    6; METERS/SECOND; STANDARD DEVIATION W
+  0;   11;    198;      1;           0;   12; METERS/SECOND; WIND SPEED 10000FT (EXTRAPLOATED)
+  0;   11;    199;      1;           0;   12; METERS/SECOND; WIND SPEED 20000FT (EXTRAPOLATED)
+  0;   11;    200;      1;           0;   12; METERS/SECOND; INFLATED WIND SPEED (MOS)
+  0;   11;    201;      1;           0;   12; METERS/SECOND; MEAN WIND SPEED PAST 12 HRS
+  0;   11;    210;      1;           0;   12; METERS/SECOND; ROOT MEAN SQUARE VECTOR WIND ERRO
+  0;   11;    221;      0;           0;    9; DEGREES_TRUE; MEAN WIND DIR 5000FT-10000FT
+  0;   11;    222;      1;           0;   12; METERS/SECOND; MEAN WIND SPEED 5000FT-10000FT
+  0;   11;    223;      1;           0;   12; METERS/SECOND; 10 METER EXTRAPOLATED WIND SPEED
+  0;   11;    224;      1;           0;   12; METERS/SECOND; 20 METER EXTRAPOLATED WIND SPEED
+  0;   12;      1;      1;           0;   12; DEGREES_KELVIN; TEMPERATURE/DRY BULB TEMPERATURE
+  0;   12;      2;      1;           0;   12; DEGREES_KELVIN; WET BULB TEMPERATURE
+  0;   12;      3;      1;           0;   12; DEGREES_KELVIN; DEW POINT TEMPERATURE
+  0;   12;      4;      1;           0;   12; DEGREES_KELVIN; DRY BULB TEMPERATURE AT 2 METERS
+  0;   12;      5;      1;           0;   12; DEGREES_KELVIN; WET BULB TEMPERATURE AT 2 METERS
+  0;   12;      6;      1;           0;   12; DEGREES_KELVIN; DEW POINT TEMPERATURE AT 2 METERS
+  0;   12;      7;      1;           0;   12; DEGREES_KELVIN; VIRTUAL TEMPERATURE
+  0;   12;     11;      1;           0;   12; DEGREES_KELVIN; MAXIMUM TEMPERATURE
+  0;   12;     12;      1;           0;   12; DEGREES_KELVIN; MINIMUM TEMPERATURE
+  0;   12;     13;      1;           0;   12; DEGREES_KELVIN; GROUND MINIMUM TEMPERATURE PAST 1
+  0;   12;     14;      1;           0;   12; DEGREES_KELVIN; MAXIMUM TEMPERATURE AT 2MTRS,PAST
+  0;   12;     15;      1;           0;   12; DEGREES_KELVIN; MINIMUM TEMPERATURE AT 2MTRS,PAST
+  0;   12;     16;      1;           0;   12; DEGREES_KELVIN; MAXIMUM TEMPERATURE AT 2MTRS,PAST
+  0;   12;     17;      1;           0;   12; DEGREES_KELVIN; MINIMUM TEMPERATURE AT 2MTRS,PAST
+  0;   12;     20;      2;       -2000;   12;          DEG; K/DAY       RADIATIVE HEATING PROFILE
+  0;   12;     30;      1;           0;   12; DEGREES_KELVIN; SOIL TEMPERATURE
+  0;   12;     40;      3;       -2048;   12; WATTS/METER**2; SENSIBLE HEAT FLUX
+  0;   12;     51;      1;           0;   10; DEGREES_KELVIN; STANDARD DEVIATION TEMPERATURE
+  0;   12;     52;      1;           0;   12; DEGREES_KELVIN; HIGHEST DAILY MEAN TEMPERATURE
+  0;   12;     53;      1;           0;   12; DEGREES_KELVIN; LOWEST DAILY MEAN TEMPERATURE
+  0;   12;     61;      1;           0;   12; DEGREES_KELVIN; SKIN TEMPERATURE
+  0;   12;     62;      1;           0;   12; DEGREES_KELVIN; EQUIVALENT BLACK BODY TEMPERATURE
+  0;   12;     63;      1;           0;   12; DEGREES_KELVIN; BRIGHTNESS TEMPERATURE
+  0;   12;    192;      0;           0;    6;   CODE_TABLE; PRECISION OF AIRCRAFT TEMPERATURE
+  0;   12;    193;      1;           0;   12; DEGREES_KELVIN; TEMPERATURE (CITY)
+  0;   12;    194;      1;           0;   12; DEGREES_KELVIN; MAXIMUM TEMPERATURE (CITY)
+  0;   12;    195;      1;           0;   12; DEGREES_KELVIN; MINIMUM TEMPERATURE (CITY)
+  0;   12;    200;      1;           0;   12; DEGREES_KELVIN; DAYTIME MAX TEMPERATURE
+  0;   12;    201;      1;           0;   12; DEGREES_KELVIN; NIGHTTIME MIN TEMPERATURE (MOS)
+  0;   13;      1;      5;           0;   14;        KG/KG; SPECIFIC HUMIDITY
+  0;   13;      2;      5;           0;   14;        KG/KG; MIXING RATIO
+  0;   13;      3;      0;           0;    7;            %; RELATIVE HUMIDITY
+  0;   13;      4;      1;           0;   10;      PASCALS; VAPOR PRESSURE
+  0;   13;      5;      3;           0;    7;  KG/METER**3; VAPOR DENSITY
+  0;   13;      6;      1;         -40;   16;       METERS; MIXING HEIGHTS
+  0;   13;     11;      1;          -1;   14;  KG/METER**2; TOTAL PRECIPITATION/TOTAL WATER E
+  0;   13;     12;      2;          -2;   12;       METERS; DEPTH OF FRESH SNOW
+  0;   13;     13;      2;          -2;   16;       METERS; TOTAL SNOW DEPTH
+  0;   13;     14;      4;           0;   12; KG/METER**2/SEC; RAINFALL/WATER EQUIV OF SNOW(AVG
+  0;   13;     15;      7;           0;   12; METERS/SECOND; SNOWFALL (AVERAGED RATE)
+  0;   13;     16;      0;           0;    7;  KG/METER**2; PRECIPITABLE WATER
+  0;   13;     19;      1;          -1;   14;  KG/METER**2; TOTAL PRECIPITATION PAST 1 HOUR
+  0;   13;     20;      1;          -1;   14;  KG/METER**2; TOTAL PRECIPITATION PAST 3 HOURS
+  0;   13;     21;      1;          -1;   14;  KG/METER**2; TOTAL PRECIPITATION PAST 6 HOURS
+  0;   13;     22;      1;          -1;   14;  KG/METER**2; TOTAL PRECIPITATION PAST 12 HOURS
+  0;   13;     23;      1;          -1;   14;  KG/METER**2; TOTAL PRECIPITATION PAST 24 HOURS
+  0;   13;     31;      0;           0;    7;  KG/METER**2; EVAPOTRANSPIRATION
+  0;   13;     32;      1;           0;    8;  KG/METER**2; EVAP/EVAPOTRANSPIRATION
+  0;   13;     40;      3;       -2048;   12; WATTS/METER**2; LATENT HEAT FLUX
+  0;   13;     41;      0;           0;    4;   CODE_TABLE; PASQUELL-GIFFORD STAB
+  0;   13;     42;      0;         -20;    6; DEGREES_KELVIN; PARCEL LIFTED INDEX (TO 500 HPA)
+  0;   13;     43;      0;         -20;    6; DEGREES_KELVIN; BEST LIFTED INDEX (TO 500 HPA)
+  0;   13;     51;      0;           0;    4;   CODE_TABLE; FREQ GRP, PRECIPITATION
+  0;   13;     52;      1;          -1;   14;          KG/; M**2        HIGHEST DAILY AMT OF PRECIPITATIO
+  0;   13;    192;      0;           0;    6;   CODE_TABLE; PRECIPITABLE WATER QUALITY
+  0;   13;    193;      4;          -1;   14;     KGM/M**2; 24 HR PRECIPITATION (CITY)
+  0;   13;    194;      0;           0;    3;   CODE_TABLE; INDIC INCLUSION/OMISSION OF PRECI
+  0;   14;      1;      3;       -2048;   12; JOULES/METER**2; LONGWAVE RADIATION. INTEGRATED 24
+  0;   14;      2;      3;       -2048;   12; JOULES/METER**2; LONGWAVE RAD. INTEGRATED SPEC.PER
+  0;   14;      3;      3;       -2048;   12; JOULES/METER**2; SHORTWAVE RAD. INTEGRATED 24 HOUR
+  0;   14;      4;      3;       -2048;   12; JOULES/METER**2; SHORTWAVE RAD. INTEGRATED SPEC PE
+  0;   14;     11;      3;       -2048;   12; JOULES/METER**2; NET LONGWAVE RAD. INTEG. 24 HOURS
+  0;   14;     12;      3;       -2048;   12; JOULES/METER**2; NET LONGWAVE RAD. INT SPEC PERIOD
+  0;   14;     13;      3;       -2048;   12; JOULES/METER**2; NET SHORTWAVE RAD. INTEG 24 HOURS
+  0;   14;     14;      3;       -2048;   12; JOULES/METER**2; NET SHORTWAVE RAD. INTEG SPEC PER
+  0;   14;     15;      4;      -16384;   15; JOULES/METER**2; NET RAD INTEGRATED OVER 24 HOURS
+  0;   14;     16;      4;      -16384;   15; JOULES/METER**2; NET RADIATION INTEG OVR PD SPECIF
+  0;   14;     17;      3;       -2048;   12; WATTS/METER**2; INSTANTANEOUS LONG WAVE RADIATION
+  0;   14;     18;      3;       -2048;   12; WATTS/METER**2; INSTANTANEOUS SHORT WAVE RADIATIO
+  0;   14;     19;      0;           0;    7;            %; SURFACE ALBEDO
+  0;   14;     20;      4;           0;   15; JOULES/METER**2; GLOBAL SOLAR RAD INTEG OVER  24 H
+  0;   14;     21;      4;           0;   15; JOULES/METER**2; GLOBAL RADIATION INTEG OVER PD SP
+  0;   14;     22;      4;           0;   15; JOULES/METER**2; DIFFUSE SOLAR RAD INTEG OVER  24
+  0;   14;     23;      4;           0;   15; JOULES/METER**2; DIFFUSE SOLAR RAD INTEG OVER PD S
+  0;   14;     24;      4;           0;   15; JOULES/METER**2; DIRECT SOLAR RAD INTEG OVER  24 H
+  0;   14;     25;      4;           0;   15; JOULES/METER**2; DIRECT SOLAR RAD INTEG OVER PD SP
+  0;   14;     31;      0;           0;   11;      MINUTES; TOTAL SUNSHINE
+  0;   14;     32;      0;           0;   10;        HOURS; TOTAL SUNSHINE
+  0;   14;     33;      0;           0;    9;            %; TOTAL SUNSHINE(PERCENTAGE)
+  0;   14;     41;      0;           0;    7;            %; SHORT WAVE ALBEDO
+  0;   14;     42;      0;           0;    7;            %; BI-DIRECTIONAL REFLECTANCE
+  0;   14;    200;      0;           0;    7;            %; PERCENT OF POSSIBLE SUNSHINE
+  0;   15;      1;      0;           0;   10;       DOBSON; UNITS    OZONE
+  0;   15;      2;      2;           0;   10;      NUMERIC; AIR-MASS (SLANT PATH AT 22KM)
+  0;   15;     11;      3;       14000;   12;     LOG/M**2; LOG_E OF INTEGRATED ELECTRON DENS
+  0;   19;      1;      0;           0;    6;   CODE_TABLE; TYPE OF SYNOPTIC FEATURE
+  0;   19;      2;      2;           0;   12;       METERS; EFFECTIVE RADIUS OF FEATURE
+  0;   19;      3;      0;           0;    8; METERS/SECOND; WIND SPEED THRESHOLD
+  0;   19;      4;      2;           0;   12;       METERS; EFF RAD OF FEAT W/RESP TO WINDS A
+  0;   19;      5;      0;           0;    9;          DEG; TRUE        DIRECTION OF MOTION OF FEATURE
+  0;   19;      6;      2;           0;   14; METERS/SECOND; SPEED OF MOTION OF FEATURE
+  0;   19;      7;      3;           0;   12;       METERS; EFFECTIVE RADIUS OF FEATURE
+  0;   19;      8;      0;           0;    3;   CODE_TABLE; VERTICAL EXTENT OF CIRCULATION
+  0;   19;      9;      3;           0;   12;       METERS; EFF. RAD. W/RESPECT TO FFF ABV TH
+  0;   20;      1;      1;           0;   13;       METERS; HORIZONTAL VISIBILITY
+  0;   20;      2;      1;           0;    7;       METERS; VERTICAL VISIBILITY
+  0;   20;      3;      0;           0;    9;   CODE_TABLE; PRESENT WEATHER
+  0;   20;      4;      0;           0;    5;   CODE_TABLE; PAST WEATHER (1)
+  0;   20;      5;      0;           0;    5;   CODE_TABLE; PAST WEATHER (2)
+  0;   20;      9;      1;         -40;   11;       METERS; CEILING
+  0;   20;     10;      0;           0;    7;            %; CLOUD COVER (TOTAL)
+  0;   20;     11;      0;           0;    4;   CODE_TABLE; CLOUD AMOUNT
+  0;   20;     12;      0;           0;    6;   CODE_TABLE; CLOUD TYPE
+  0;   20;     13;      1;         -40;   11;       METERS; HEIGHT OF BASE OF CLOUD
+  0;   20;     14;      1;         -40;   11;       METERS; HEIGHT OF TOP OF CLOUD
+  0;   20;     15;      1;           0;   14;      PASCALS; PRESSURE AT THE BASE OF CLOUD
+  0;   20;     16;      1;           0;   14;      PASCALS; PRESSURE AT THE TOP OF CLOUD
+  0;   20;     17;      0;           0;    4;   CODE_TABLE; CLOUD TOP DESCRIPTION
+  0;   20;     18;      1;          40;   11;       METERS; LOWEST HGT OF CLD TOP
+  0;   20;     19;      1;          40;   11;       METERS; HIGHEST HGT OF CLD TOP
+  0;   20;     20;      0;           0;    4; CODE_TABLE(02001LOW; CLOUD AMOUNT
+  0;   20;     21;      0;           0;    4; CODE_TABLE(02001MIDDLE; CLOUD AMOUNT
+  0;   20;     22;      0;           0;    4; CODE_TABLE(02001HIGH; CLOUD AMOUNT
+  0;   20;     23;      0;           0;    7;            %; SATELLITE SENSED EFF CLOUD AMOUNT
+  0;   20;     31;      2;           0;    7;       METERS; ICE DEPOSIT (THICKNESS)
+  0;   20;     32;      0;           0;    3;   CODE_TABLE; RATE OF ICE ACCRETION
+  0;   20;     33;      0;           0;    4;   FLAG_TABLE; CAUSE OF ICE ACCRETION
+  0;   20;     34;      0;           0;    5;   CODE_TABLE; SEA ICE CONCENTRATION
+  0;   20;     35;      0;           0;    4;   CODE_TABLE; AMOUNT AND TYPE OF ICE
+  0;   20;     36;      0;           0;    5;   CODE_TABLE; ICE SITUATION
+  0;   20;     37;      0;           0;    5;   CODE_TABLE; ICE DEVELOPMENT
+  0;   20;     38;      0;           0;   12; DEGREES_TRUE; BEARING OF ICE EDGE
+  0;   20;     39;      1;           0;   13;       METERS; ICE DISTANCE
+  0;   20;     41;      0;           0;    4;   CODE_TABLE; AIRFRAME ICING
+  0;   20;     51;      0;           0;    7;            %; AMOUNT OF LOW CLOUDS
+  0;   20;     52;      0;           0;    7;            %; AMOUNT OF MIDDLE CLOUDS
+  0;   20;     53;      0;           0;    7;            %; AMOUNT OF HIGH CLOUDS
+  0;   20;     61;      0;           0;   12;       METERS; RUNWAY VISUAL RANGE (RVR)
+  0;   20;     62;      0;           0;    5;   CODE_TABLE; STATE OF GROUND(W /WO SNOW)
+  0;   20;     63;      0;           0;   10;   CODE_TABLE; SPECIAL PHENOMENA
+  0;   20;    192;      0;           0;    7;   CODE_TABLE; VISIBILITY TOWARDS SEA(WMO TABLE
+  0;   20;    200;      0;           0;    7;            %; MEAN CLD COVER (OPAQUE) PAST 12 H
+  0;   21;      1;      0;         -64;    7;           DB; HORIZONTAL REFLECTIVITY
+  0;   21;      2;      0;         -64;    7;           DB; VERTICAL REFLECTIVITY
+  0;   21;      3;      1;          -5;    7;           DB; DIFFERENTIAL REFLECTIVITY
+  0;   21;      5;      0;         -65;    6;           DB; LINEAR DEPOLARIZATION RATIO
+  0;   21;      6;      0;         -65;    6;           DB; CIRCULAR DEPOLARIZATION RATIO
+  0;   21;     11;      0;        -128;    8; METERS/SECOND; DOPPLER MEAN VELOCITY IN X DIRECT
+  0;   21;     12;      0;        -128;    8; METERS/SECOND; DOPPLER MEAN VELOCITY IN Y DIRECT
+  0;   21;     13;      0;        -128;    8; METERS/SECOND; DOPPLER MEAN VELOCITY IN Z DIRECT
+  0;   21;     14;      1;       -4096;   13; METERS/SECOND; DOPPLER MEAN VELOCITY (RADIAL)
+  0;   21;     17;      1;           0;    8; METERS/SECOND; DOPPLER VELOCITY SPECTRAL WIDTH
+  0;   21;     21;      3;           0;    4;       METERS; ECHO TOPS
+  0;   21;     30;      0;         -32;    8;           DB; SIGNAL TO NOISE RATIO
+  0;   21;     31;      0;           0;    7; KILOGRAMS/METER*VERT.; INTEGRATED LIQ. WATER CONTE
+  0;   21;     36;      7;           0;   12; METERS/SECOND; RADAR RAINFALL INTENSITY
+  0;   21;     41;      2;           0;    8;       METERS; BRIGHT BAND HEIGHT
+  0;   21;     51;      0;        -256;    8;           DB; SIGNAL POWER ABOVE 1MW
+  0;   21;     62;      2;       -5000;   13;     DECIBELS; BACKSCATTER
+  0;   21;     63;      0;           0;    7;            %; NOISE FIGURE
+  0;   21;     64;      0;           0;   10;      NUMERIC; CLUTTER NOISE ESTIMATE
+  0;   21;     65;      0;        -127;    8;      NUMERIC; MISSING PACKET COUNTER
+  0;   21;     66;      0;           0;   12;   FLAG_TABLE; WAVE SCATTEROMETER PRODUCT CONFID
+  0;   21;     67;      0;           0;   12;   FLAG_TABLE; WIND SCATTEROMETER PRODUCT CONFID
+  0;   21;     68;      0;           0;    8;   FLAG_TABLE; RADAR ALTIMETER PRODUCT CONFIDENC
+  0;   21;     69;      0;           0;    7;   FLAG_TABLE; ATSR SEA SFC TEMP QUAL ANALYSIS T
+  0;   21;     70;      0;           0;   15;   FLAG_TABLE; REPROCESSED WIND SCATTEROMETER PR
+  0;   21;     71;      0;           0;   16;      NUMERIC; PEAKINESS
+  0;   21;     72;      0;           0;    4;   FLAG_TABLE; SATELLITE ALTIMETER CALIBRATION S
+  0;   21;     73;      0;           0;    9;   FLAG_TABLE; SATELLITE ALTIMETER INSTRUMENT MO
+  0;   21;     74;      2;        -512;   10; DEGREES_KELVIN; MULTI/SINGLE VIEW DIFFERENCE
+  0;   21;     75;      0;           0;    8;      NUMERIC; SPECTRAL INTENSITY
+  0;   21;     76;      0;           0;    3;   CODE_TABLE; REPRESENTATION OF INTENSITIES
+  0;   21;     77;      3;           0;   14;       METERS; ALTITUDE CORRECTION (IONOSPHERE)
+  0;   21;     78;      3;           0;    9;       METERS; ALTITUDE CORRECTION (DRY TROPOSPH
+  0;   21;     79;      3;        2000;   10;       METERS; ALTITUDE CORRECTION (WET TROPOSPH
+  0;   21;     80;      3;           0;   11;       METERS; ALTITUDE CORRECTION (CALIB. CONST
+  0;   21;     81;      3;           0;   10;       METERS; OPEN LOOP CORRECTION (HGT-TIME LO
+  0;   21;     82;      3;       -3000;   14;     DECIBELS; OPEN LOOP CORRECTION (AUTO GAIN C
+  0;   21;     83;      0;           0;    7;            %; AMBIGUITY REMOVAL CONFIDENCE
+  0;   21;     84;      0;           0;    3;   CODE_TABLE; ATSR SEA SFC TEMP QUALITY SUMMARY
+  0;   21;     85;      0;           0;    4;      NUMERIC; ATSR SEA SFC TEMP ACROSS TRACK BA
+  0;   21;    192;      0;           0;    7;           DB; SPECTRAL PEAK POWER 0TH MOMENT
+  0;   21;    193;      1;       -4096;   13; METERS/SECOND; SPECTRAL PEAK POWER 1ST MOMENT
+  0;   21;    194;      1;           0;    8; METERS/SECOND; SPECTRAL PEAK POWER 2ND MOMENT
+  0;   22;      1;      0;           0;    9; DEGREES_TRUE; DIRECTION OF WAVES
+  0;   22;      2;      0;           0;    9; DEGREES_TRUE; DIRECTION OF WIND WAVES
+  0;   22;      3;      0;           0;    9; DEGREES_TRUE; DIRECTION OF SWELL WAVES
+  0;   22;      4;      0;           0;    9; DEGREES_TRUE; DIRECTION OF CURRENT WAVES
+  0;   22;     11;      0;           0;    6;      SECONDS; PERIOD OF WAVES
+  0;   22;     12;      0;           0;    6;      SECONDS; PERIOD OF WIND WAVES
+  0;   22;     13;      0;           0;    6;      SECONDS; PERIOD OF SWELL WAVES
+  0;   22;     21;      1;           0;   10;       METERS; HEIGHT OF WAVES
+  0;   22;     22;      1;           0;   10;       METERS; HEIGHT OF WIND WAVES
+  0;   22;     23;      1;           0;   10;       METERS; HEIGHT OF SWELL WAVES
+  0;   22;     25;      2;           0;   10;       METERS; STANDARD DEVIATION WAVE
+  0;   22;     26;      2;           0;   10;       METERS; STANDARD DEVIATION SIG WAVE HEIGH
+  0;   22;     31;      2;           0;   13; METERS/SECOND; SPEED OF CURRENT
+  0;   22;     37;      3;      -10000;   15;       METERS; TIDAL ELEV WITH RESPECT TO LAND D
+  0;   22;     38;      3;      -10000;   15;       METERS; TIDAL ELEV WITH RESPECT TO CHART
+  0;   22;     39;      3;       -5000;   12;       METERS; MET RESIDUAL TIDAL ELEV (SURGE OR
+  0;   22;     41;      1;           0;   12; DEGREES_KELVIN; SEA SFC TEM (15 DAY RUNNING MEAN)
+  0;   22;     42;      1;           0;   12; DEGREES_KELVIN; SEA TEMPERATURE
+  0;   22;     43;      2;           0;   15; DEGREES_KELVIN; SEA TEMPERATURE
+  0;   22;     44;      1;           0;   14; METERS/SECOND; SOUND VELOCITY
+  0;   22;     50;      2;           0;    8;            K; STD DEV SEA-SURFACE TEMPERATURE
+  0;   22;     61;      0;           0;    4;   CODE_TABLE; STATE OF SEA
+  0;   22;     62;      2;           0;   12;   PARTS/1000; SALINITY
+  0;   22;     63;      0;           0;   14;       METERS; TOTAL WATER DEPTH
+  0;   22;    105;      1;           0;    6; DEGREES_TRUE; DIRECTION OF WAVES
+  0;   22;    143;      2;        2650;   13; DEGREES_KELVIN; SEA TEMPERATURE
+  0;   22;    192;      0;           0;    4;   CODE_TABLE; TIDE INDICATOR
+  0;   22;    193;      1;           0;   10;       METERS; ABS VALUE DEPT OF TIDE FROM PRED
+  0;   22;    194;      3;        -305;   12;       METERS; DEPT OF TIDE FROM MEAN LOWER LOW
+  0;   23;      1;      0;           0;    3;   CODE_TABLE; ACCIDENT EARLY NOTIFICATION ART.A
+  0;   23;      2;      0;           0;    5;   CODE_TABLE; ACTIVITY OR FACILITY INVOLVED IN
+  0;   23;      3;      0;           0;    3;   CODE_TABLE; TYPE OF RELEASE
+  0;   23;      4;      0;           0;    3;   CODE_TABLE; COUNTERMEASURES TAKEN NR BORDER
+  0;   23;      5;      0;           0;    2;   CODE_TABLE; CAUSE  OF INCIDENT
+  0;   23;      6;      0;           0;    3;   CODE_TABLE; INCIDENT SITUATION
+  0;   23;      7;      0;           0;    3;   CODE_TABLE; CHARACTERISTIC OF RELEASE
+  0;   23;      8;      0;           0;    2;   CODE_TABLE; STATE OF CURRENT RELEASE
+  0;   23;      9;      0;           0;    2;   CODE_TABLE; STATE OF EXPECTED RELEASE
+  0;   23;     16;      0;           0;    2;   CODE_TABLE; POSS. OF SIG CHEM.TOXIC HEALTH EF
+  0;   23;     17;      6;           0;   20; METER**3/SECOND; FLOW DISCHARGE OF MAJ. RECIPIENT
+  0;   23;     18;      0;           0;    3;   CODE_TABLE; RELEASE BEHAVIOR OVER TIME
+  0;   23;     19;      0;      -15000;   17;       METERS; ACTUAL RELEASE HEIGHT
+  0;   23;     21;      0;      -15000;   17;       METERS; EFFECTIVE RELEASE HEIGHT
+  0;   23;     22;      0;           0;   24;       METERS; DIST. OF REL PT OR SITE OF INCIDE
+  0;   23;     23;      1;           0;   12; METERS/SECOND; MAIN TRANSPORT SPEED IN ATMOSPHER
+  0;   23;     24;      2;           0;   13; METERS/SECOND; MAIN TRANSPORT SPEED IN WATER
+  0;   23;     25;      2;           0;   13; METERS/SECOND; MAIN TRANSPORT SPEED IN GROUND WA
+  0;   23;     27;      0;           0;    9; DEGREES_TRUE; MAIN TRANSPORT DIR IN ATMOSPHERE
+  0;   23;     28;      0;           0;    9; DEGREES_TRUE; MAIN TRANSPORT DIR IN WATER
+  0;   23;     29;      0;           0;    9; DEGREES_TRUE; MAIN TRANSPORT DIR IN GROUND WATE
+  0;   23;     31;      0;           0;    2;   CODE_TABLE; POSS PLUME/PRECIP ENCOUNTER
+  0;   23;     32;      0;           0;    2;   CODE_TABLE; PLUME ENCOUNTER DIR/SPD CHANGE
+  0;   24;      1;      1;           0;   28;           BQ; EST. OF RADIOACTIVITY REL.TO SPEC
+  0;   24;      2;      1;           0;   28;           BQ; EST MAXIMUM POTENTIAL RELEASE
+  0;   24;      3;      0;           0;    5;   CODE_TABLE; COMPOSITION OF RELEASE
+  0;   24;      4;      0;           0;   16;    CCITT_IA5; ELEMENT NAME
+  0;   24;      5;      0;           0;    9;      NUMERIC; ISOTOPE MASS
+  0;   24;     11;      2;           0;   32;          MSV; DOSE
+  0;   24;     12;      2;           0;   32;          MSV; TRAJ DOSE(DEF LOC & EXP TIME OF A
+  0;   24;     13;      2;           0;   32;          MSV; GAMMA DOSE IN AIR ALG MAIN TRAN P
+  0;   24;     21;      2;           0;   32;  BQ/METER**3; AIR CONC.(NAMED ISOTOPE INC GROSS
+  0;   24;     22;      2;           0;   32;         BQ/L; CONC IN PRECIP(OF NAMED ISOTOPE T
+  0;   25;      1;      1;           0;    6;       METERS; RANGE GATE LENGTH
+  0;   25;      2;      0;           0;    4;      NUMERIC; NR OF GATES AVERAGED
+  0;   25;      3;      0;           0;    8;      NUMERIC; NR. OF INTEGRATED PULSES
+  0;   25;      4;      0;           0;    2;   CODE_TABLE; ECHO PROCESSING
+  0;   25;      5;      0;           0;    2;   CODE_TABLE; ECHO INTEGRATION
+  0;   25;      6;      0;           0;    3;   CODE_TABLE; Z TO R CONVERSION
+  0;   25;      7;      0;           0;   12;      NUMERIC; Z TO R CONVERSION FACTOR
+  0;   25;      8;      2;           0;    9;      NUMERIC; Z TO R CONVERSION EXPONENT
+  0;   25;      9;      0;           0;    4;   FLAG_TABLE; CALIBRATION METHOD
+  0;   25;     10;      0;           0;    4;   CODE_TABLE; CLUTTER TREATMENT
+  0;   25;     11;      0;           0;    2;   CODE_TABLE; GND. OCCULTATION CORR. (SCREENING
+  0;   25;     12;      0;           0;    2;   CODE_TABLE; RANGE ATTENUATION CORRECTION
+  0;   25;     13;      0;           0;    2;   FLAG_TABLE; BRIGHT BAND CORRECTION
+  0;   25;     15;      0;           0;    2;   FLAG_TABLE; RADOME ATTENUATION CORRECTION
+  0;   25;     16;      5;           0;    6;     DB/METER; CLEAR AIR ATTENUATION CORRECTION
+  0;   25;     17;      0;           0;    2;   FLAG_TABLE; PRECIPITATION ATTENUATION CORRECT
+  0;   25;     18;      7;           0;    6;      NUMERIC; A TO Z LAW FOR ATTENUATION FACTOR
+  0;   25;     19;      2;           0;    7;      NUMERIC; A TO Z LAW FOR ATTENUATION EXPONE
+  0;   25;     20;      0;           0;    2;   CODE_TABLE; MEAN SPEED ESTIMATION
+  0;   25;     21;      0;           0;    8;   FLAG_TABLE; WIND COMPUTATION ENHANCEMENT
+  0;   25;     30;      0;           0;    2;   CODE_TABLE; SST USAGE
+  0;   25;     31;      0;           0;    2;   CODE_TABLE; 15 DAY SST AVAILABILITY
+  0;   25;     32;      0;           0;    2;   CODE_TABLE; NOAA WIND PROFILER HIGH/LOW MODE
+  0;   25;     33;      0;           0;    2;   CODE_TABLE; NOAA WIND PROFILER SUBMODE
+  0;   25;     34;      0;           0;    4;   CODE_TABLE; NOAA WIND PROFILER Q/C TEST RESUL
+  0;   25;     35;      0;           0;    3;   CODE_TABLE; FIRST GUESS ADJUSTMENT
+  0;   25;     36;      3;       -5000;   14;      NUMERIC; NSTAR AVERAGE VALUE
+  0;   25;     37;      0;           0;    2;   CODE_TABLE; HIRS-8 SFC AIR TEMP
+  0;   25;     38;      0;           0;    3;   CODE_TABLE; TOVS FILTER FLAGS
+  0;   25;    202;      0;           0;    4;   FLAG_TABLE; TEMPERATURE CHANNEL SELECTION FLA
+  0;   25;    204;      0;           0;    8;   FLAG_TABLE; MATCHUP QUALITY TEST FLAGS
+  0;   25;    205;      0;           0;    8;   FLAG_TABLE; RETRIEVAL/DPI QUALITY TEST FLAGS
+  0;   25;    209;      3;           0;   12; DECIMAL_HOURS; DPI TIME DIFFERENCE (READ AS MINU
+  0;   25;    210;      3;           0;   19;       METERS; DPI DISTANCE
+  0;   25;    211;      3;           0;   12; DECIMAL_HOURS; QUANTITATIVE RETRIEVAL TIME DIFFE
+  0;   25;    212;      3;           0;   19;       METERS; QUANTITATIVE RETRIEVAL DISTANCE
+  0;   26;      1;      1;           0;   12;         HOUR; PCPL TIME OF DAILY RDG IN UTC MAX
+  0;   26;      2;      1;           0;   12;         HOUR; PCPL TIME OF DAILY RDG IN UTC MIN
+  0;   26;     31;      2;  -107341824;   31;       METERS; DIST FM EARTH CENTER IN DIR NORTH
+  0;   26;     32;      2;  -107341824;   31;       METERS; DIST FM EARTH CENTER IN DIR NORTH
+  0;   26;     41;      5;  -107341824;   31; METERS/SECOND; VEL W/RESP EARTH CTR IN DIR NORTH
+  0;   27;      1;      5;    -9000000;   25;      DEGREES; LATITUDE (HIGH ACCURACY)
+  0;   27;      2;      2;       -9000;   15;      DEGREES; LATITUDE (COARSE ACCURACY)
+  0;   27;      3;      2;       -9000;   15;      DEGREES; ALTERNATE LATITUDE
+  0;   27;     20;      0;           0;   16;      NUMERIC; SATELLITE LOCATION COUNTER
+  0;   27;     21;      0;           0;   16;      NUMERIC; SATELLITE SUB-LOCATION DIMENSIONS
+  0;   27;     31;      2;  -107341824;   31;       METERS; DIST FM EARTH CENTER IN DIR 0 DEG
+  0;   27;     41;      5;  -107341824;   31; METERS/SECOND; VEL W/RESP EARTH CTR N DIR 0 DEG
+  0;   28;      1;      5;   -18000000;   26;      DEGREES; LONGITUDE (HIGH ACCURACY)
+  0;   28;      2;      2;      -18000;   16;      DEGREES; LONGITUDE (COARSE ACCURACY)
+  0;   28;      3;      2;      -18000;   16;      DEGREES; ALTERNATE LONGITUDE
+  0;   28;     31;      2;  -107341824;   31;       METERS; DIST FMEARTH CENTER IN DIR 90 DEG
+  0;   28;     41;      5;  -107341824;   31; METERS/SECOND; VEL W/RESP EARTH CTR IN DIR 90 DE
+  0;   29;      1;      0;           0;    3;   CODE_TABLE; PROJECTION TYPE
+  0;   29;      2;      0;           0;    3;   CODE_TABLE; COORDINATE GRID TYPE
+  0;   30;      1;      0;           0;    4;      NUMERIC; PIXEL VALUE (4 BITS)
+  0;   30;     21;      0;           0;   12;      NUMERIC; NUMBER OF PIXELS PER ROW
+  0;   30;     22;      0;           0;   12;      NUMERIC; NUMBER OF PIXELS PER COLUMN
+  0;   30;     31;      0;           0;    4;   CODE_TABLE; PICTURE TYPE
+  0;   30;     32;      0;           0;   16;   FLAG_TABLE; COMBINED PICTURE
+  0;   31;      0;      0;           0;    1;   FLAG_TABLE; DELAYED REPLICATION SWITCH
+  0;   31;      1;      0;           0;    8;      NUMERIC; DELAYED DESCRIPTOR REPLICATION FA
+  0;   31;      2;      0;           0;   16;      NUMERIC; EXT DELAYED DESCRIPTOR REPLICAT.
+  0;   31;     11;      0;           0;    8;      NUMERIC; DELAYED DESC. & DATA REPITIT. FAC
+  0;   31;     12;      0;           0;   16;      NUMERIC; EXT DELAYED DESC. & DATA REPITIT.
+  0;   31;     21;      0;           0;    6;   CODE_TABLE; ASSOCIATED FIELD SIGNIFICANCE
+  0;   31;     31;      0;           0;    1;   FLAG_TABLE; DATA PRESENT INDICATOR
+  0;   31;    192;      0;           0;    9;   CODE_TABLE; NOAA WIND PROFILER HIGH/LOW MODE
+  0;   31;    193;      0;           0;    2;   CODE_TABLE; NOAA WIND PROFILER SUBMODE
+  0;   31;    194;      0;           0;    4;   CODE_TABLE; NOAA WIND PROFILER Q/C TEST RESUL
+  0;   33;      2;      0;           0;    2;   CODE_TABLE; QUALITY INFORMATION
+  0;   33;      3;      0;           0;    3;   CODE_TABLE; QUALITY INFORMATION
+  0;   33;      4;      0;           0;    7;            %; % CONFIDENCE
+  0;   50;      1;      0;           0;   17;      NUMERIC; REPORT SEQUENCE NUMBER
+  0;   50;     20;      0;           0;    4;   CODE_TABLE; DATA QUALITY INDICATOR
+  0;   55;      6;      0;           0;   10;   CODE_TABLE; NMC REPORT TYPE
+  0;   58;      1;      0;           0;   48;    CCITT_IA5; BULLETIN HEADING
+  0;   58;      2;      0;           0;   80;    CCITT_IA5; AIRCRAFT TYPE
+  0;   58;      3;      0;        -400;   17;          GPM; ICING BASE
+  0;   58;      4;      0;        -400;   17;          GPM; ICING TOP
+  0;   58;      5;      0;           0;  224;    CCITT_IA5; COMPLETE BULLETIN HEADER
+  0;   60;      1;      0;           0;    7;            %; PROB. OF LIQ PCPN GE .01 INCH PAS
+  0;   60;      2;      0;           0;    7;            %; PROB. OF LIQ PCPN GE .01 INCH PAS
+  0;   60;      3;      0;           0;    7;            %; PROB. OF LIQ PCPN GE .01 INCH PAS
+  0;   60;      4;      0;           0;    7;            %; PROB. OF LIQ PCPN GE .10 INCH PAS
+  0;   60;      5;      0;           0;    7;            %; PROB. OF LIQ PCPN GE .10 INCH PAS
+  0;   60;      6;      0;           0;    7;            %; PROB. OF LIQ PCPN GE .10 INCH PAS
+  0;   60;      7;      0;           0;    7;            %; PROB. OF LIQ PCPN GE .25 INCH PAS
+  0;   60;      8;      0;           0;    7;            %; PROB. OF LIQ PCPN GE .25 INCH PAS
+  0;   60;      9;      0;           0;    7;            %; PROB. OF LIQ PCPN GE .25 INCH PAS
+  0;   60;     10;      0;           0;    7;            %; PROB. OF LIQ PCPN GE .50 INCH PAS
+  0;   60;     11;      0;           0;    7;            %; PROB. OF LIQ PCPN GE .50 INCH PAS
+  0;   60;     12;      0;           0;    7;            %; PROB. OF LIQ PCPN GE .50 INCH PAS
+  0;   60;     13;      0;           0;    7;            %; PROB. OF LIQ PCP GE 1.00 INCH PAS
+  0;   60;     14;      0;           0;    7;            %; PROB. OF LIQ PCP GE 1.00 INCH PAS
+  0;   60;     15;      0;           0;    7;            %; PROB. OF LIQ PCP GE 1.00 INCH PAS
+  0;   60;     16;      0;           0;    7;            %; PROB. OF LIQ PCP GE 2.00 INCH PAS
+  0;   60;     17;      0;           0;    7;            %; PROB. OF LIQ PCP GE 2.00 INCH PAS
+  0;   60;     18;      0;           0;    7;            %; REL FRQ GE .01 LQ EQV PCP PAST 12
+  0;   60;     19;      0;           0;    7;            %; REL FRQ GE .01 LQ EQV PCP PAST 24
+  0;   60;     20;      0;           0;    7;            %; COND PROB PCP TYPE FREEZING
+  0;   60;     21;      0;           0;    7;            %; COND PROB PCP TYPE SNOW
+  0;   60;     22;      0;           0;    7;            %; COND PROB PCP TYPE LIQUID
+  0;   60;     23;      0;           0;    7;            %; COND PROB PCP TYPE DRIZZLE
+  0;   60;     24;      0;           0;    7;            %; COND PROB PCP TYPE CONTINUOUS
+  0;   60;     25;      0;           0;    7;            %; COND PROB PCP TYPE SHOWERS
+  0;   60;     26;      0;           0;    7;            %; PROB SNOW AMT GE TRACE PAST 6HRS
+  0;   60;     27;      0;           0;    7;            %; PROB SNOW AMT GE TRACE PAST 12HRS
+  0;   60;     28;      0;           0;    7;            %; PROB SNOW AMT GE TRACE PAST 24HRS
+  0;   60;     29;      0;           0;    7;            %; PROB SNOW AMT GE 2.0IN PAST 6HRS
+  0;   60;     30;      0;           0;    7;            %; PROB SNOW AMT GE 2.0IN PAST 12HRS
+  0;   60;     31;      0;           0;    7;            %; PROB SNOW AMT GE 2.0IN PAST 24HRS
+  0;   60;     32;      0;           0;    7;            %; PROB SNOW AMT GE 4.0IN PAST 12HRS
+  0;   60;     33;      0;           0;    7;            %; PROB SNOW AMT GE 4.0IN PAST 24HRS
+  0;   60;     34;      0;           0;    7;            %; PROB SNOW AMT GE 6.0IN PAST 12HRS
+  0;   60;     35;      0;           0;    7;            %; PROB SNOW AMT GE 6.0IN PAST 24HRS
+  0;   60;     36;      0;           0;    7;            %; COND PROB SNOW PAST 12 HRS
+  0;   60;     37;      0;           0;    7;            %; COND REL FRQ PROB SNOW PAST 12 HR
+  0;   60;     38;      0;           0;    7;            %; PROB OPAQUE SKY COVER  CLEAR
+  0;   60;     39;      0;           0;    7;            %; PROB OPAQUE SKY COVER  SCATTERED
+  0;   60;     40;      0;           0;    7;            %; PROB OPAQUE SKY COVER  BROKEN
+  0;   60;     41;      0;           0;    7;            %; PROB OPAQUE SKY COVER  OVERCAST
+  0;   60;     42;      0;           0;    7;            %; PROB CIG HGT < 200 FT
+  0;   60;     43;      0;           0;    7;            %; PROB CIG HGT 200-400 FT
+  0;   60;     44;      0;           0;    7;            %; PROB CIG HGT 500-900 FT
+  0;   60;     45;      0;           0;    7;            %; PROB CIG HGT 1000-3000 FT
+  0;   60;     46;      0;           0;    7;            %; PROB CIG HGT 3100-6500 FT
+  0;   60;     47;      0;           0;    7;            %; PROB CIG HGT 6600-12000 FT
+  0;   60;     48;      0;           0;    7;            %; PROB CIG HGT GT 12000 FT
+  0;   60;     49;      0;           0;    7;            %; PROB VSBY < 0/2 MILES
+  0;   60;     50;      0;           0;    7;            %; PROB VSBY < 0/2 - 7/8 MILES
+  0;   60;     51;      0;           0;    7;            %; PROB VSBY < 0 - 2 3/4 MILES
+  0;   60;     52;      0;           0;    7;            %; PROB VSBY < 3 - 5 MILES
+  0;   60;     53;      0;           0;    7;            %; PROB VSBY > 5   MILES
+  0;   60;     54;      0;           0;    7;            %; PROB OBS TO VISION  BLOWING PHENO
+  0;   60;     55;      0;           0;    7;            %; PROB OBS TO VISION  HAZE
+  0;   60;     56;      0;           0;    7;            %; PROB OBS TO VISION  FOG
+  0;   60;     57;      0;           0;    7;            %; PROB OBS TO VISION  NONE
+  0;   60;     58;      0;           0;    7;            %; PROB TSTM PAST 6 HRS
+  0;   60;     59;      0;           0;    7;            %; PROB TSTM PAST 12HRS
+  0;   60;     60;      0;           0;    7;            %; PROB TSTM PAST 24HRS
+  0;   60;     61;      0;           0;    7;            %; PROB SVR WX PAST 6 HRS
+  0;   60;     62;      0;           0;    7;            %; PROB SVR WX PAST 12HRS
+  0;   60;     63;      0;           0;    7;            %; PROB SVR WX PAST 24HRS
+  0;   60;     64;      0;           0;    7;            %; CLIM AVG CLD COVER (OPAQUE)
+  0;   60;     65;      1;           0;   12; METERS/SECOND; CLIMATIC WIND SPEED
+  0;   60;     66;      1;           0;   12; DEGREES_KELVIN; CLIMATIC(NORMAL) DAY MAX TEMP
+  0;   60;     67;      1;           0;   12; DEGREES_KELVIN; CLIMATIC(NORMAL) NIGHT MIN TEMP
+  0;   60;     90;      0;           0;    4;   CODE_TABLE; QUANT PCP FCST (CATEGORIES)
+  0;   60;     91;      0;           0;    3;   CODE_TABLE; COND PCP TYPE FCST (CATS)
+  0;   60;     92;      0;           0;    3;   CODE_TABLE; COND PCP CHARACTER FCST (CATS)
+  0;   60;     93;      0;           0;    3;   CODE_TABLE; QUANT SNOW AMT FCST (CATS)
+  0;   60;     94;      0;           0;    4;   CODE_TABLE; CIG HEIGHT FCST (CATS)
+  0;   60;     95;      0;           0;    3;   CODE_TABLE; VISIBILITY FCST (CATS)
+  0;   60;     96;      0;           0;    3;   CODE_TABLE; OBSTRUCT TO VISION FCST (CATS)
+  0;   60;     97;      0;           0;    2;   CODE_TABLE; THUNDERSTORM FCST (CATS)
+  0;   60;     98;      0;           0;    2;   CODE_TABLE; SEVERE WEATHER FCST (CATS)
+  0;   63;    255;      0;           0;    1;      NUMERIC; FILL BIT
diff --git a/data/tables/B2M-000-000-D b/data/tables/B2M-000-000-D
new file mode 100644
index 0000000..38f03ea
--- /dev/null
+++ b/data/tables/B2M-000-000-D
@@ -0,0 +1,1606 @@
+3	0	2 
+	0	0	2 
+	0	0	3 
+	-1 
+ 
+3	0	3 
+	0	0	10 
+	0	0	11 
+	0	0	12 
+	-1 
+ 
+3	0	4 
+	3	0	3 
+	0	0	13 
+	0	0	14 
+	0	0	15 
+	0	0	16 
+	0	0	17 
+	0	0	18 
+	0	0	19 
+	0	0	20 
+	-1 
+ 
+3	0	10 
+	3	0	3 
+	1	1	0 
+	0	31	1 
+	0	0	30 
+	-1 
+ 
+3	1	1 
+	0	1	1 
+	0	1	2 
+	-1 
+ 
+3	1	2 
+	0	1	3 
+	0	1	4 
+	0	1	5 
+	-1 
+ 
+3	1	3 
+	0	1	11 
+	0	1	12 
+	0	1	13 
+	-1 
+ 
+3	1	11 
+	0	4	1 
+	0	4	2 
+	0	4	3 
+	-1 
+ 
+3	1	12 
+	0	4	4 
+	0	4	5 
+	-1 
+ 
+3	1	13 
+	3	1	12 
+	0	4	6 
+	-1 
+ 
+3	1	21 
+	0	5	1 
+	0	6	1 
+	-1 
+ 
+3	1	22 
+	3	1	21 
+	0	7	1 
+	-1 
+ 
+3	1	23 
+	0	5	2 
+	0	6	2 
+	-1 
+ 
+3	1	24 
+	3	1	23 
+	0	7	1 
+	-1 
+ 
+3	1	25 
+	3	1	23 
+	0	4	3 
+	3	1	12 
+	-1 
+ 
+3	1	26 
+	3	1	21 
+	0	4	3 
+	0	4	3 
+	0	4	4 
+	0	4	4 
+	0	4	5 
+	0	4	5 
+	-1 
+ 
+3	1	31 
+	3	1	1 
+	0	2	1 
+	3	1	11 
+	3	1	12 
+	3	1	22 
+	-1 
+ 
+3	1	32 
+	3	1	1 
+	0	2	1 
+	3	1	11 
+	3	1	12 
+	3	1	24 
+	-1 
+ 
+3	1	33 
+	0	1	5 
+	0	2	1 
+	3	1	11 
+	3	1	12 
+	3	1	21 
+	-1 
+ 
+3	1	34 
+	0	1	5 
+	0	2	1 
+	3	1	11 
+	3	1	12 
+	3	1	23 
+	-1 
+ 
+3	1	35 
+	0	1	5 
+	0	1	12 
+	0	1	13 
+	0	2	1 
+	3	1	11 
+	3	1	12 
+	3	1	23 
+	-1 
+ 
+3	1	36 
+	3	1	3 
+	0	2	1 
+	3	1	11 
+	3	1	12 
+	3	1	23 
+	-1 
+ 
+3	1	37 
+	3	1	1 
+	0	2	11 
+	0	2	12 
+	3	1	11 
+	3	1	12 
+	3	1	22 
+	-1 
+ 
+3	1	38 
+	3	1	1 
+	0	2	11 
+	0	2	12 
+	3	1	11 
+	3	1	12 
+	3	1	24 
+	-1 
+ 
+3	1	39 
+	3	1	3 
+	0	1	11 
+	0	1	12 
+	3	1	11 
+	3	1	12 
+	3	1	23 
+	-1 
+ 
+3	1	40 
+	3	1	3 
+	0	2	11 
+	0	2	12 
+	3	1	11 
+	3	1	12 
+	3	1	24 
+	-1 
+ 
+3	1	41 
+	0	1	7 
+	0	2	21 
+	0	2	22 
+	3	1	11 
+	3	1	12 
+	-1 
+ 
+3	1	42 
+	3	1	41 
+	3	1	21 
+	-1 
+ 
+3	1	43 
+	0	1	7 
+	0	2	23 
+	3	1	11 
+	3	1	13 
+	3	1	21 
+	-1 
+ 
+3	1	44 
+	0	1	7 
+	0	2	24 
+	3	1	11 
+	3	1	13 
+	3	1	21 
+	-1 
+ 
+3	1	51 
+	0	1	6 
+	0	2	61 
+	3	1	11 
+	3	1	12 
+	3	1	21 
+	0	8	4 
+	-1 
+ 
+3	1	62 
+	1	1	0 
+	0	31	1 
+	3	1	1 
+	-1 
+ 
+3	1	190 
+	0	4	192 
+	0	4	193 
+	-1 
+ 
+3	1	191 
+	0	8	192 
+	0	8	193 
+	0	8	194 
+	0	8	195 
+	0	8	196 
+	-1 
+ 
+3	1	192 
+	3	1	11 
+	0	4	4 
+	3	1	23 
+	-1 
+ 
+3	2	1 
+	0	10	4 
+	0	10	51 
+	0	10	61 
+	0	10	63 
+	-1 
+ 
+3	2	2 
+	0	10	4 
+	0	7	4 
+	0	10	3 
+	0	10	61 
+	0	10	63 
+	-1 
+ 
+3	2	3 
+	0	11	11 
+	0	11	12 
+	0	12	4 
+	0	12	6 
+	0	13	3 
+	0	20	1 
+	0	20	3 
+	0	20	4 
+	0	20	5 
+	-1 
+ 
+3	2	4 
+	0	20	10 
+	0	8	2 
+	0	20	11 
+	0	20	13 
+	0	20	12 
+	0	20	12 
+	0	20	12 
+	-1 
+ 
+3	2	5 
+	0	8	2 
+	0	20	11 
+	0	20	12 
+	0	20	13 
+	-1 
+ 
+3	2	11 
+	3	2	1 
+	3	2	3 
+	3	2	4 
+	-1 
+ 
+3	2	12 
+	3	2	2 
+	3	2	3 
+	3	2	4 
+	-1 
+ 
+3	2	21 
+	0	22	1 
+	0	22	11 
+	0	22	21 
+	-1 
+ 
+3	2	22 
+	0	22	2 
+	0	22	12 
+	0	22	22 
+	-1 
+ 
+3	2	23 
+	0	22	3 
+	0	22	13 
+	0	22	23 
+	-1 
+ 
+3	2	24 
+	3	2	22 
+	3	2	23 
+	3	2	23 
+	-1 
+ 
+3	2	190 
+	0	10	51 
+	0	10	61 
+	0	10	63 
+	0	11	1 
+	0	11	2 
+	0	12	1 
+	0	12	3 
+	-1 
+ 
+3	2	191 
+	0	12	11 
+	0	12	12 
+	0	20	62 
+	0	20	63 
+	-1 
+ 
+3	2	192 
+	0	20	1 
+	3	2	193 
+	-1 
+ 
+3	2	193 
+	0	20	1 
+	3	2	197 
+	-1 
+ 
+3	2	194 
+	0	4	31 
+	0	13	11 
+	-1 
+ 
+3	2	195 
+	0	2	2 
+	0	11	41 
+	0	10	52 
+	0	4	31 
+	0	13	12 
+	0	13	13 
+	0	10	192 
+	0	10	62 
+	-1 
+ 
+3	2	196 
+	0	10	4 
+	3	2	193 
+	-1 
+ 
+3	2	197 
+	0	20	3 
+	0	20	4 
+	0	20	5 
+	-1 
+ 
+3	2	199 
+	3	1	32 
+	3	1	190 
+	3	1	191 
+	3	2	190 
+	-1 
+ 
+3	3	1 
+	0	7	3 
+	0	11	1 
+	0	11	2 
+	-1 
+ 
+3	3	2 
+	0	7	4 
+	0	11	1 
+	0	11	2 
+	-1 
+ 
+3	3	3 
+	0	7	4 
+	0	10	3 
+	0	12	1 
+	0	12	3 
+	-1 
+ 
+3	3	4 
+	3	3	3 
+	0	11	1 
+	0	11	2 
+	-1 
+ 
+3	3	11 
+	0	7	3 
+	0	8	1 
+	0	11	1 
+	0	11	2 
+	-1 
+ 
+3	3	12 
+	0	7	4 
+	0	8	1 
+	0	11	1 
+	0	11	2 
+	-1 
+ 
+3	3	13 
+	0	7	4 
+	0	8	1 
+	0	10	3 
+	0	12	1 
+	0	13	3 
+	0	11	1 
+	0	11	2 
+	-1 
+ 
+3	3	14 
+	0	7	4 
+	0	8	1 
+	0	10	3 
+	0	12	1 
+	0	12	3 
+	0	11	1 
+	0	11	2 
+	-1 
+ 
+3	3	21 
+	0	7	4 
+	0	7	4 
+	2	4	7 
+	0	31	21 
+	-1 
+ 
+3	3	22 
+	3	3	21 
+	0	10	3 
+	2	4	0 
+	-1 
+ 
+3	3	23 
+	3	3	21 
+	0	12	1 
+	2	4	0 
+	-1 
+ 
+3	3	24 
+	3	3	21 
+	0	13	16 
+	2	4	0 
+	-1 
+ 
+3	3	25 
+	0	2	25 
+	2	4	7 
+	0	31	21 
+	0	12	63 
+	2	4	0 
+	-1 
+ 
+3	3	26 
+	0	7	4 
+	0	8	3 
+	2	4	7 
+	0	31	21 
+	0	12	1 
+	2	4	0 
+	-1 
+ 
+3	3	27 
+	0	7	4 
+	2	4	7 
+	0	31	21 
+	0	10	3 
+	2	4	0 
+	-1 
+ 
+3	3	31 
+	0	7	4 
+	0	8	3 
+	0	7	21 
+	0	7	22 
+	0	8	12 
+	0	12	61 
+	-1 
+ 
+3	3	32 
+	0	20	11 
+	0	20	16 
+	-1 
+ 
+3	3	192 
+	0	1	7 
+	3	1	11 
+	3	1	13 
+	3	1	23 
+	3	3	193 
+	3	3	194 
+	3	3	195 
+	3	3	196 
+	3	3	197 
+	-1 
+ 
+3	3	193 
+	0	5	22 
+	0	8	12 
+	0	12	61 
+	0	8	3 
+	0	7	4 
+	0	2	22 
+	0	27	20 
+	0	22	42 
+	0	8	3 
+	-1 
+ 
+3	3	194 
+	1	3	15 
+	0	7	4 
+	0	7	4 
+	0	12	7 
+	0	8	3 
+	1	3	3 
+	0	7	4 
+	0	7	4 
+	0	13	16 
+	0	8	3 
+	-1 
+ 
+3	3	195 
+	0	7	4 
+	0	12	7 
+	0	8	3 
+	0	15	1 
+	0	8	3 
+	0	7	4 
+	0	20	10 
+	0	2	21 
+	-1 
+ 
+3	3	196 
+	1	1	20 
+	0	12	62 
+	0	2	21 
+	1	1	4 
+	0	12	62 
+	0	2	21 
+	-1 
+ 
+3	3	197 
+	1	1	3 
+	0	12	62 
+	1	3	20 
+	0	10	4 
+	0	12	7 
+	0	10	2 
+	1	2	5 
+	0	10	4 
+	0	12	3 
+	-1 
+ 
+3	4	1 
+	0	8	3 
+	0	10	4 
+	0	12	1 
+	0	11	1 
+	0	11	2 
+	-1 
+ 
+3	4	2 
+	0	8	3 
+	0	10	4 
+	0	11	1 
+	0	11	2 
+	-1 
+ 
+3	4	3 
+	0	8	3 
+	0	12	1 
+	-1 
+ 
+3	4	4 
+	0	8	3 
+	0	10	4 
+	0	20	10 
+	0	12	1 
+	-1 
+ 
+3	4	5 
+	0	2	24 
+	0	7	4 
+	0	7	4 
+	0	13	3 
+	-1 
+ 
+3	4	6 
+	0	14	1 
+	0	14	1 
+	0	14	3 
+	-1 
+ 
+3	6	1 
+	0	2	32 
+	1	2	0 
+	0	31	1 
+	0	7	62 
+	0	22	42 
+	-1 
+ 
+3	6	2 
+	0	2	31 
+	0	22	4 
+	0	22	31 
+	-1 
+ 
+3	6	3 
+	0	2	2 
+	0	11	11 
+	0	11	12 
+	0	12	4 
+	-1 
+ 
+3	6	4 
+	0	2	32 
+	0	2	33 
+	1	3	0 
+	0	31	1 
+	0	7	62 
+	0	22	42 
+	0	22	62 
+	-1 
+ 
+3	6	5 
+	0	2	31 
+	1	3	0 
+	0	31	1 
+	0	7	62 
+	0	22	4 
+	0	22	31 
+	-1 
+ 
+3	6	6 
+	3	6	3 
+	3	6	2 
+	0	22	63 
+	-1 
+ 
+3	6	7 
+	0	1	12 
+	0	1	14 
+	3	6	8 
+	0	4	24 
+	0	27	3 
+	0	28	3 
+	-1 
+ 
+3	6	8 
+	0	2	34 
+	0	2	35 
+	0	2	36 
+	-1 
+ 
+3	6	9 
+	0	10	4 
+	0	10	61 
+	0	10	63 
+	0	11	1 
+	0	11	2 
+	0	12	4 
+	0	13	3 
+	0	22	42 
+	-1 
+ 
+3	7	1 
+	3	1	31 
+	3	2	11 
+	-1 
+ 
+3	7	2 
+	3	1	32 
+	3	2	11 
+	-1 
+ 
+3	7	3 
+	3	7	1 
+	1	1	0 
+	0	31	1 
+	3	2	5 
+	-1 
+ 
+3	7	4 
+	3	7	2 
+	1	1	0 
+	0	31	1 
+	3	2	5 
+	-1 
+ 
+3	7	5 
+	3	7	1 
+	1	1	4 
+	3	2	5 
+	-1 
+ 
+3	7	6 
+	3	7	2 
+	1	1	4 
+	3	2	5 
+	-1 
+ 
+3	7	7 
+	3	1	31 
+	3	2	12 
+	-1 
+ 
+3	7	8 
+	3	1	32 
+	3	2	12 
+	-1 
+ 
+3	7	192 
+	0	20	11 
+	0	20	12 
+	0	20	13 
+	-1 
+ 
+3	7	193 
+	3	2	199 
+	0	20	1 
+	0	20	10 
+	0	12	11 
+	0	12	12 
+	0	20	62 
+	3	2	194 
+	-1 
+ 
+3	7	194 
+	3	2	199 
+	0	20	1 
+	3	2	4 
+	3	2	5 
+	3	2	191 
+	3	2	194 
+	-1 
+ 
+3	7	195 
+	3	2	199 
+	0	10	4 
+	3	2	193 
+	3	2	4 
+	1	1	2 
+	3	2	5 
+	3	2	191 
+	3	2	194 
+	-1 
+ 
+3	7	196 
+	3	2	199 
+	3	2	196 
+	3	2	4 
+	1	1	4 
+	3	2	5 
+	3	2	191 
+	1	1	2 
+	3	2	194 
+	3	2	195 
+	-1 
+ 
+3	7	197 
+	3	2	199 
+	3	2	194 
+	-1 
+ 
+3	8	1 
+	3	1	33 
+	3	2	11 
+	0	22	42 
+	-1 
+ 
+3	8	2 
+	3	1	34 
+	3	2	11 
+	0	22	42 
+	-1 
+ 
+3	8	3 
+	3	1	35 
+	3	2	11 
+	0	22	42 
+	-1 
+ 
+3	8	4 
+	3	1	36 
+	3	2	11 
+	0	22	42 
+	-1 
+ 
+3	8	5 
+	3	8	4 
+	3	2	24 
+	-1 
+ 
+3	8	6 
+	0	10	4 
+	0	10	61 
+	0	10	63 
+	0	11	1 
+	0	11	2 
+	0	12	4 
+	0	13	3 
+	0	22	42 
+	-1 
+ 
+3	9	1 
+	3	1	37 
+	1	1	0 
+	0	31	1 
+	3	3	11 
+	-1 
+ 
+3	9	2 
+	3	1	38 
+	1	1	0 
+	0	31	1 
+	3	3	11 
+	-1 
+ 
+3	9	3 
+	3	1	37 
+	1	1	0 
+	0	31	1 
+	3	3	12 
+	-1 
+ 
+3	9	4 
+	3	1	38 
+	1	1	0 
+	0	31	1 
+	3	3	12 
+	-1 
+ 
+3	9	5 
+	3	1	37 
+	3	2	4 
+	1	1	0 
+	0	31	1 
+	3	3	13 
+	-1 
+ 
+3	9	6 
+	3	1	38 
+	3	2	4 
+	1	1	0 
+	0	31	1 
+	3	3	13 
+	-1 
+ 
+3	9	7 
+	3	1	4 
+	3	2	4 
+	1	1	0 
+	0	31	1 
+	3	3	14 
+	-1 
+ 
+3	9	8 
+	3	1	38 
+	3	2	4 
+	1	1	0 
+	0	31	1 
+	3	3	14 
+	-1 
+ 
+3	9	11 
+	3	1	39 
+	1	1	0 
+	0	31	1 
+	3	3	11 
+	-1 
+ 
+3	9	12 
+	3	1	39 
+	1	1	0 
+	0	31	1 
+	3	3	12 
+	-1 
+ 
+3	9	13 
+	3	1	39 
+	3	2	4 
+	1	1	0 
+	0	31	1 
+	3	3	13 
+	-1 
+ 
+3	9	14 
+	3	1	39 
+	3	2	4 
+	1	1	0 
+	0	31	1 
+	3	3	14 
+	-1 
+ 
+3	9	15 
+	3	9	16 
+	3	9	17 
+	3	9	18 
+	-1 
+ 
+3	9	16 
+	3	1	40 
+	1	1	0 
+	0	31	1 
+	3	3	12 
+	-1 
+ 
+3	9	17 
+	3	1	40 
+	3	2	4 
+	1	1	0 
+	0	31	1 
+	3	3	13 
+	-1 
+ 
+3	9	18 
+	3	1	40 
+	3	2	4 
+	1	1	0 
+	0	31	1 
+	3	3	14 
+	-1 
+ 
+3	9	19 
+	3	1	31 
+	0	2	3 
+	1	1	0 
+	0	31	1 
+	3	3	11 
+	-1 
+ 
+3	9	20 
+	3	1	31 
+	0	2	3 
+	1	4	0 
+	0	31	1 
+	0	7	3 
+	0	11	3 
+	0	11	4 
+	0	11	5 
+	-1 
+ 
+3	10	1 
+	3	1	42 
+	3	3	31 
+	3	3	32 
+	1	1	26 
+	3	3	25 
+	-1 
+ 
+3	10	2 
+	3	1	42 
+	3	3	31 
+	3	3	32 
+	1	1	9 
+	3	3	23 
+	-1 
+ 
+3	10	3 
+	3	1	42 
+	3	3	31 
+	3	3	32 
+	1	1	6 
+	3	3	23 
+	-1 
+ 
+3	10	4 
+	3	1	42 
+	3	3	31 
+	3	3	32 
+	1	1	3 
+	3	3	24 
+	-1 
+ 
+3	11	1 
+	3	1	51 
+	0	7	2 
+	0	12	1 
+	0	11	1 
+	0	11	2 
+	0	11	31 
+	0	11	32 
+	0	11	33 
+	0	20	41 
+	-1 
+ 
+3	12	1 
+	3	1	43 
+	3	4	1 
+	-1 
+ 
+3	12	2 
+	3	1	43 
+	3	4	2 
+	-1 
+ 
+3	12	3 
+	3	1	42 
+	3	4	3 
+	-1 
+ 
+3	12	4 
+	3	1	42 
+	3	4	4 
+	-1 
+ 
+3	12	5 
+	3	1	42 
+	0	20	14 
+	-1 
+ 
+3	12	6 
+	3	1	42 
+	3	4	5 
+	-1 
+ 
+3	12	7 
+	3	1	42 
+	3	4	6 
+	-1 
+ 
+3	12	10 
+	0	1	7 
+	0	5	40 
+	0	2	21 
+	0	5	41 
+	0	4	1 
+	0	4	43 
+	-1 
+ 
+3	12	11 
+	2	2	131 
+	2	1	149 
+	0	4	6 
+	2	1	0 
+	2	2	132 
+	0	10	2 
+	2	2	0 
+	0	5	43 
+	0	5	53 
+	-1 
+ 
+3	12	12 
+	2	2	130 
+	2	1	132 
+	1	1	19 
+	0	12	63 
+	2	1	0 
+	2	2	0 
+	-1 
+ 
+3	12	13 
+	0	5	42 
+	2	2	130 
+	2	1	135 
+	0	12	63 
+	2	1	0 
+	2	2	0 
+	-1 
+ 
+3	12	14 
+	3	12	10 
+	3	12	11 
+	1	5	56 
+	3	1	23 
+	0	5	42 
+	0	5	52 
+	3	12	12 
+	3	12	13 
+	-1 
+ 
+3	12	15 
+	1	9	11 
+	3	1	23 
+	0	5	42 
+	0	5	52 
+	2	2	129 
+	2	1	132 
+	1	1	4 
+	0	12	63 
+	2	2	0 
+	2	1	0 
+	-1 
+ 
+3	12	16 
+	3	12	10 
+	3	12	11 
+	3	12	15 
+	-1 
+ 
+3	12	17 
+	1	9	8 
+	3	1	23 
+	0	5	42 
+	0	5	52 
+	2	2	129 
+	2	1	132 
+	1	1	3 
+	0	12	63 
+	2	2	0 
+	2	1	0 
+	-1 
+ 
+3	12	18 
+	3	12	10 
+	3	12	11 
+	3	12	17 
+	-1 
+ 
+3	13	9 
+	0	21	1 
+	1	1	0 
+	0	31	1 
+	0	21	1 
+	-1 
+ 
+3	13	10 
+	0	21	36 
+	1	1	0 
+	0	31	1 
+	0	21	36 
+	-1 
+ 
+3	13	31 
+	0	6	2 
+	0	6	12 
+	1	1	0 
+	0	31	2 
+	0	30	1 
+	-1 
+ 
+3	13	32 
+	0	5	2 
+	0	5	12 
+	1	1	0 
+	0	31	2 
+	3	13	31 
+	-1 
+ 
+3	13	41 
+	0	6	2 
+	0	6	12 
+	1	6	0 
+	0	31	1 
+	1	1	0 
+	0	31	11 
+	0	30	1 
+	1	1	0 
+	0	31	1 
+	0	30	1 
+	-1 
+ 
+3	13	42 
+	0	5	2 
+	0	5	12 
+	1	1	0 
+	0	31	2 
+	3	13	41 
+	-1 
+ 
+3	15	1 
+	0	8	3 
+	3	1	11 
+	3	1	12 
+	3	1	23 
+	3	6	1 
+	-1 
+ 
+3	15	2 
+	0	8	3 
+	3	1	11 
+	3	1	12 
+	3	1	23 
+	3	6	4 
+	-1 
+ 
+3	16	1 
+	3	1	192 
+	0	1	21 
+	0	2	41 
+	0	19	1 
+	0	10	51 
+	0	19	2 
+	0	19	3 
+	0	19	4 
+	-1 
+ 
+3	18	1 
+	3	1	25 
+	0	24	11 
+	-1 
+ 
+3	18	3 
+	3	1	26 
+	0	24	5 
+	0	24	4 
+	0	24	21 
+	-1 
+ 
+3	18	4 
+	3	1	25 
+	0	4	31 
+	0	13	11 
+	0	24	5 
+	0	24	4 
+	0	24	22 
+	-1 
+ 
+3	21	1 
+	0	2	101 
+	0	2	114 
+	0	2	105 
+	0	2	106 
+	0	2	107 
+	0	2	121 
+	-1 
+ 
+3	21	3 
+	0	21	51 
+	0	21	14 
+	0	21	17 
+	0	21	30 
+	-1 
+ 
+3	21	4 
+	3	1	31 
+	0	2	3 
+	1	1	0 
+	0	31	1 
+	3	21	3 
+	-1 
+ 
+3	21	5 
+	0	25	4 
+	0	2	121 
+	0	2	122 
+	0	2	123 
+	0	2	124 
+	0	2	125 
+	0	2	126 
+	0	2	127 
+	3	21	192 
+	-1 
+ 
+3	21	6 
+	0	25	1 
+	0	25	2 
+	0	25	3 
+	0	25	5 
+	-1 
+ 
+3	21	7 
+	0	25	9 
+	0	25	10 
+	0	25	11 
+	0	25	12 
+	0	25	13 
+	0	25	15 
+	0	25	16 
+	0	25	17 
+	-1 
+ 
+3	21	8 
+	0	25	6 
+	0	25	7 
+	0	25	8 
+	-1 
+ 
+3	21	9 
+	0	25	18 
+	0	25	19 
+	-1 
+ 
+3	21	10 
+	0	2	101 
+	0	7	2 
+	0	2	102 
+	0	2	103 
+	0	2	104 
+	0	2	105 
+	0	2	106 
+	0	2	107 
+	0	2	108 
+	3	21	193 
+	-1 
+ 
+3	21	11 
+	0	30	31 
+	0	30	32 
+	0	29	2 
+	-1 
+ 
+3	21	12 
+	1	1	0 
+	0	31	1 
+	0	2	135 
+	-1 
+ 
+3	21	192 
+	0	2	128 
+	0	2	129 
+	0	2	130 
+	0	2	131 
+	-1 
+ 
+3	21	193 
+	0	2	109 
+	0	2	110 
+	0	2	132 
+	0	2	133 
+	-1 
+ 
+3	55	1 
+	3	55	4 
+	3	55	5 
+	0	12	192 
+	0	12	1 
+	0	11	1 
+	0	11	2 
+	0	2	61 
+	0	10	194 
+	-1 
+ 
+3	55	2 
+	0	11	31 
+	0	11	32 
+	0	11	33 
+	-1 
+ 
+3	55	3 
+	0	20	41 
+	0	58	3 
+	0	58	4 
+	-1 
+ 
+3	55	4 
+	0	58	1 
+	0	58	2 
+	0	1	8 
+	0	1	6 
+	3	1	11 
+	3	1	12 
+	0	4	192 
+	0	4	193 
+	3	1	23 
+	-1 
+ 
+3	55	5 
+	0	2	43 
+	0	8	193 
+	0	8	194 
+	0	8	195 
+	0	8	196 
+	0	2	42 
+	0	7	192 
+	0	7	4 
+	-1 
+ 
+3	58	1 
+	0	58	1 
+	0	1	11 
+	0	1	8 
+	0	1	6 
+	3	1	11 
+	3	1	12 
+	0	4	192 
+	0	4	193 
+	3	58	2 
+	3	58	3 
+	-1 
+ 
+3	58	2 
+	0	2	43 
+	0	8	193 
+	0	8	194 
+	0	8	195 
+	0	8	196 
+	0	2	42 
+	0	7	192 
+	0	7	4 
+	0	8	4 
+	0	12	192 
+	-1 
+ 
+3	58	3 
+	0	12	1 
+	0	11	1 
+	0	11	2 
+	0	2	61 
+	0	10	194 
+	-1 
+ 
+3	58	4 
+	0	11	31 
+	0	11	32 
+	0	11	33 
+	-1 
+ 
+3	58	5 
+	0	20	41 
+	0	58	3 
+	0	58	4 
+	-1 
+ 
+3	59	1 
+	3	59	2 
+	3	59	3 
+	3	59	4 
+	3	59	5 
+	3	59	6 
+	3	59	7 
+	3	59	8 
+	-1 
+ 
+3	59	2 
+	0	58	1 
+	0	1	11 
+	3	1	11 
+	3	1	12 
+	3	1	23 
+	0	7	1 
+	-1 
+ 
+3	59	3 
+	0	4	192 
+	0	4	193 
+	0	8	193 
+	0	8	194 
+	0	8	195 
+	0	8	196 
+	0	2	2 
+	-1 
+ 
+3	59	4 
+	0	1	12 
+	0	1	13 
+	0	10	4 
+	0	10	51 
+	0	4	31 
+	0	10	63 
+	0	10	61 
+	0	10	62 
+	0	12	1 
+	0	12	3 
+	-1 
+ 
+3	59	5 
+	0	11	1 
+	0	11	2 
+	0	4	31 
+	0	11	41 
+	0	12	11 
+	0	12	12 
+	0	4	31 
+	0	13	11 
+	0	4	31 
+	0	13	11 
+	-1 
+ 
+3	59	6 
+	0	20	1 
+	0	20	3 
+	0	20	4 
+	0	20	5 
+	0	20	10 
+	0	20	63 
+	0	20	63 
+	0	8	2 
+	0	20	11 
+	0	10	13 
+	-1 
+ 
+3	59	7 
+	0	20	12 
+	0	20	12 
+	0	20	12 
+	1	4	4 
+	0	8	2 
+	0	20	11 
+	0	20	12 
+	0	20	13 
+	-1 
+ 
+3	59	8 
+	0	22	42 
+	0	22	12 
+	0	22	22 
+	1	1	2 
+	3	2	23 
+	0	20	31 
+	0	20	32 
+	0	20	32 
+	-1 
+ 
+3	60	1 
+	3	60	2 
+	3	60	3 
+	3	60	4 
+	3	60	5 
+	3	60	6 
+	3	60	7 
+	3	60	8 
+	-1 
+ 
+3	60	2 
+	0	58	1 
+	3	1	1 
+	3	1	11 
+	3	1	12 
+	3	1	23 
+	3	59	3 
+	-1 
+ 
+3	60	3 
+	0	7	4 
+	0	10	4 
+	0	10	192 
+	0	10	51 
+	0	4	31 
+	0	10	63 
+	0	10	61 
+	0	10	62 
+	0	12	1 
+	0	12	3 
+	-1 
+ 
+3	60	4 
+	0	11	1 
+	0	11	2 
+	0	4	31 
+	0	11	41 
+	0	12	11 
+	0	12	12 
+	0	10	52 
+	-1 
+ 
+3	60	5 
+	0	4	31 
+	0	13	11 
+	0	40	31 
+	0	13	11 
+	0	40	31 
+	0	13	12 
+	0	13	13 
+	-1 
+ 
+3	60	6 
+	0	20	62 
+	0	20	3 
+	0	20	4 
+	0	20	5 
+	0	20	10 
+	0	20	63 
+	0	20	63 
+	-1 
+ 
+3	60	7 
+	0	20	1 
+	0	8	2 
+	0	20	11 
+	0	20	13 
+	0	20	12 
+	0	20	12 
+	0	20	12 
+	-1 
+ 
+3	60	8 
+	1	4	4 
+	0	8	2 
+	0	20	11 
+	0	20	12 
+	0	20	13 
+	0	22	42 
+	0	22	12 
+	0	22	22 
+	3	2	23 
+	0	2	1 
+	-1
diff --git a/data/tables/B2M-000-002-0 b/data/tables/B2M-000-002-0
new file mode 100644
index 0000000..b68ae8b
--- /dev/null
+++ b/data/tables/B2M-000-002-0
@@ -0,0 +1,308 @@
+##############################################################################
+# BUFR Table 0
+#
+#
+# Notes
+# -----
+#
+# * This table comes from GRIB Code Table 0 (Identification of center)
+#
+# * A value of 1 in the first column indicates a center that uses minor
+#   version numbers with local tables.  Since minor local table version
+#   numbers are stored in Section 1, Octet 18, the value in the first
+#   column must not be set if a center uses Section 1, Octet 18 for other
+#   purposes (i.e., ECMWF).
+#
+#
+##############################################################################
+
+0	  0	RESERVED
+
+# 1-9: WMCs
+
+0	  1	Melbourne
+0	  2	Melbourne
+0	  3	Melbourne
+0	  4	Moscow
+0	  5	Moscow
+0	  6	Moscow
+0	  7	US Weather Service - National Meteorological Center (NMC)
+0	  8	US National Weather Service Telecommunications Gateway (NWSTG)
+0	  9	Reserved for USA
+
+# 10-25: Centers in Region I
+
+0	 10	Cairo (RSMC/RAFC)
+0	 11	Cairo (RSMC/RAFC)
+0	 12	Dakar (RSMC/RAFC)
+0	 13	Dakar (RSMC/RAFC)
+0	 14	Nairobi (RSMC/RAFC)
+0	 15	Nairobi (RSMC/RAFC)
+0	 16	Antananarivo (RSMC)
+0	 17	Antananarivo (RSMC)
+0	 18	Tunis-Casablanca (RSMC/RAFC)
+0	 19	Tunis-Casablanca (RSMC/RAFC)
+0	 20	Las Palmas (RAFC)
+0	 21	Algiers (RSMC)
+0	 22	Lagos (RSMC)
+0	 23	Lagos (RSMC)
+0	 24	Reserved for other centers in Region I
+0	 25	Reserved for other centers in Region I
+
+# 26-40 Centers in Region II
+
+0	 26	Khabarovsk (RSMC)
+0	 27	Khabarovsk (RSMC)
+0	 28	New Delhi (RSMC/RAFC)
+0	 29	New Delhi (RSMC/RAFC)
+0	 30	Novosibirsk (RSMC)
+0	 31	Novosibirsk (RSMC)
+0	 32	Tashkent (RSMC)
+0	 33	Tashkent (RSMC)
+0	 34	Tokyo (RSMC), Japan Meteorological Agency
+0	 35	Tokyo (RSMC/RAFC)
+0	 36	Bangkok (RAFC)
+0	 37	Ulan Bator
+0	 38	Beijing (RSMC)
+0	 39	Beijing (RSMC)
+0	 40	Reserved for other centers in Region II
+
+# 41-50: Centers in Region III
+
+0	 41	Buenos Aires (RSMC/RAFC)
+0	 42	Buenos Aires (RSMC/RAFC)
+0	 43	Brasilia (RSMC/RAFC)
+0	 44	Brasilia (RSMC/RAFC)
+0	 45	Santiago
+0	 46	Brazilian Space Agency - INPE
+0	 47	Reserved for other centers in Region III
+0	 48	Reserved for other centers in Region III
+0	 49	Reserved for other centers in Region III
+0	 50	Reserved for other centers in Region III
+
+# 51-63: Centers in Region IV
+
+0	 51	Miami (RSMC/RAFC)
+0	 52	Miami (RSMC), National Hurricane Center
+0	 53	Montreal (RSMC)
+0	 54	Montreal (RSMC)
+0	 55	San Francisco
+0	 56	RESERVED
+0	 57	US Air Force - Air Force Global Weather Central (AFGWC)
+1	 58	Fleet Numerical Oceanography Center (FNOC), Monterey, CA, USA
+0	 59	The NOAA Forecast Systems Laboratory, Boulder, CO, USA
+0	 60	Reserved for other centers in Region IV
+0	 61	Reserved for other centers in Region IV
+0	 62	Reserved for other centers in Region IV
+0	 63	Reserved for other centers in Region IV
+
+# 64-73: Centers in Region V
+
+0	 64	Honolulu (RAFC)
+0	 65	Darwin (RSMC/RAFC)
+0	 66	Darwin (RSMC/RAFC)
+0	 67	Melbourne (RSMC)
+0	 68	RESERVED
+0	 69	Wellington (RSMC/RAFC)
+0	 70	Wellington (RSMC/RAFC)
+0	 71	Reserved for other centers in Region V
+0	 72	Reserved for other centers in Region V
+0	 73	Reserved for other centers in Region V
+
+# 74-98: Centers in Region VI
+
+0	 74	UK Meteorological Office - Bracknell
+0	 75	UK Meteorological Office - Bracknell
+0	 76	Moscow (RSMC/RAFC)
+0	 77	RESERVED
+0	 78	Offenbach (RSMC)
+0	 79	Offenbach (RSMC)
+0	 80	Rome (RSMC/RAFC)
+0	 81	Rome (RSMC/RAFC)
+0	 82	Norrkoping (RSMC)
+0	 83	Norrkoping (RSMC)
+0	 84	Paris (RAFC)
+0	 85	Toulouse
+0	 86	Helsinki
+0	 87	Belgrade
+0	 88	Oslo
+0	 89	Prague
+0	 90	Episkopi
+0	 91	Ankara
+0	 92	Francfort/Main (RAFC)
+0	 93	London (WAFC)
+0	 94	Copenhagen
+0	 95	Rota
+0	 96	Athens
+0	 97	European Space Agency (ESA)
+
+# ECMWF (Center 98) does not support minor local table version numbers
+# so DO NOT set the first value to 1.
+
+0	 98	European Center for Medium Range Weather Forecasts (ECMWF)(RSMC)
+0	 99	De Bilt
+
+# 100-127: RESERVED
+
+0	100	RESERVED
+0	101	RESERVED
+0	102	RESERVED
+0	103	RESERVED
+0	104	RESERVED
+0	105	RESERVED
+0	106	RESERVED
+0	107	RESERVED
+0	108	RESERVED
+0	109	RESERVED
+0	110	RESERVED
+0	111	RESERVED
+0	112	RESERVED
+0	113	RESERVED
+0	114	RESERVED
+0	115	RESERVED
+0	116	RESERVED
+0	117	RESERVED
+0	118	RESERVED
+0	119	RESERVED
+0	120	RESERVED
+0	121	RESERVED
+0	122	RESERVED
+0	123	RESERVED
+0	124	RESERVED
+0	125	RESERVED
+0	126	RESERVED
+0	127	RESERVED
+
+# 128-254: NATIONAL USE
+
+1	128	Naval Research Laboratory (NRL), Monterey CA
+0	129	CAST
+0	130	AFCCC
+0	131	PL
+0	132	ARL
+0	133	WES
+0	134	NATIONAL USE
+0	135	NATIONAL USE
+0	136	NATIONAL USE
+0	137	NATIONAL USE
+0	138	NATIONAL USE
+0	139	NATIONAL USE
+0	140	NATIONAL USE
+0	141	NATIONAL USE
+0	142	NATIONAL USE
+0	143	NATIONAL USE
+0	144	NATIONAL USE
+0	145	NATIONAL USE
+0	146	NATIONAL USE
+0	147	NATIONAL USE
+0	148	NATIONAL USE
+0	149	NATIONAL USE
+0	150	NATIONAL USE
+0	151	NATIONAL USE
+0	152	NATIONAL USE
+0	153	NATIONAL USE
+0	154	NATIONAL USE
+0	155	NATIONAL USE
+0	156	NATIONAL USE
+0	157	NATIONAL USE
+0	158	NATIONAL USE
+0	159	NATIONAL USE
+0	160	NATIONAL USE
+0	161	NATIONAL USE
+0	162	NATIONAL USE
+0	163	NATIONAL USE
+0	164	NATIONAL USE
+0	165	NATIONAL USE
+0	166	NATIONAL USE
+0	167	NATIONAL USE
+0	168	NATIONAL USE
+0	169	NATIONAL USE
+0	170	NATIONAL USE
+0	171	NATIONAL USE
+0	172	NATIONAL USE
+0	173	NATIONAL USE
+0	174	NATIONAL USE
+0	175	NATIONAL USE
+0	176	NATIONAL USE
+0	177	NATIONAL USE
+0	178	NATIONAL USE
+0	179	NATIONAL USE
+0	180	NATIONAL USE
+0	181	NATIONAL USE
+0	182	NATIONAL USE
+0	183	NATIONAL USE
+0	184	NATIONAL USE
+0	185	NATIONAL USE
+0	186	NATIONAL USE
+0	187	NATIONAL USE
+0	188	NATIONAL USE
+0	189	NATIONAL USE
+0	190	NATIONAL USE
+0	191	NATIONAL USE
+0	192	NATIONAL USE
+0	193	NATIONAL USE
+0	194	NATIONAL USE
+0	195	NATIONAL USE
+0	196	NATIONAL USE
+0	197	NATIONAL USE
+0	198	NATIONAL USE
+0	199	NATIONAL USE
+0	200	NATIONAL USE
+0	201	NATIONAL USE
+0	202	NATIONAL USE
+0	203	NATIONAL USE
+0	204	NATIONAL USE
+0	205	NATIONAL USE
+0	206	NATIONAL USE
+0	207	NATIONAL USE
+0	208	NATIONAL USE
+0	209	NATIONAL USE
+0	210	NATIONAL USE
+0	211	NATIONAL USE
+0	212	NATIONAL USE
+0	213	NATIONAL USE
+0	214	NATIONAL USE
+0	215	NATIONAL USE
+0	216	NATIONAL USE
+0	217	NATIONAL USE
+0	218	NATIONAL USE
+0	219	NATIONAL USE
+0	220	NATIONAL USE
+0	221	NATIONAL USE
+0	222	NATIONAL USE
+0	223	NATIONAL USE
+0	224	NATIONAL USE
+0	225	NATIONAL USE
+0	226	NATIONAL USE
+0	227	NATIONAL USE
+0	228	NATIONAL USE
+0	229	NATIONAL USE
+0	230	NATIONAL USE
+0	231	NATIONAL USE
+0	232	NATIONAL USE
+0	233	NATIONAL USE
+0	234	NATIONAL USE
+0	235	NATIONAL USE
+0	236	NATIONAL USE
+0	237	NATIONAL USE
+0	238	NATIONAL USE
+0	239	NATIONAL USE
+0	240	NATIONAL USE
+0	241	NATIONAL USE
+0	242	NATIONAL USE
+0	243	NATIONAL USE
+0	244	NATIONAL USE
+0	245	NATIONAL USE
+0	246	NATIONAL USE
+0	247	NATIONAL USE
+0	248	NATIONAL USE
+0	249	NATIONAL USE
+0	250	NATIONAL USE
+0	251	NATIONAL USE
+0	252	NATIONAL USE
+0	253	NATIONAL USE
+0	254	NATIONAL USE
+
+# 255: Used to indicate missing or unknown center
+
+0	255	MISSING VALUE
diff --git a/data/tables/B2M-000-002-A b/data/tables/B2M-000-002-A
new file mode 100644
index 0000000..2a5d7db
--- /dev/null
+++ b/data/tables/B2M-000-002-A
@@ -0,0 +1,259 @@
+#
+# BUFR Table A - Data Category
+#
+  0	Surface data - land
+  1	Surface data - sea
+  2	Vertical soundings (other than satellite)
+  3	Vertical soundings (satellite)
+  4	Single level upper-air data (other than satellite)
+  5	Single level upper-air data (satellite)
+  6	Radar data
+  7	Synoptic features
+  8	Physical/chemical constituents
+  9	Dispersal and transport
+ 10	Radiological data
+ 11	BUFR tables, complete replacement or update
+ 12	Surface data (satellite)
+ 13	RESERVED
+ 14	RESERVED
+ 15	RESERVED
+ 16	RESERVED
+ 17	RESERVED
+ 18	RESERVED
+ 19	RESERVED
+ 20	Status information
+ 21	Radiances (satellite measured)
+ 22	RESERVED
+ 23	RESERVED
+ 24	RESERVED
+ 25	RESERVED
+ 26	RESERVED
+ 27	RESERVED
+ 28	RESERVED
+ 29	RESERVED
+ 30	RESERVED
+ 31	Oceanographic data
+ 32	RESERVED
+ 33	RESERVED
+ 34	RESERVED
+ 35	RESERVED
+ 36	RESERVED
+ 37	RESERVED
+ 38	RESERVED
+ 39	RESERVED
+ 40	RESERVED
+ 41	RESERVED
+ 42	RESERVED
+ 43	RESERVED
+ 44	RESERVED
+ 45	RESERVED
+ 46	RESERVED
+ 47	RESERVED
+ 48	RESERVED
+ 49	RESERVED
+ 50	RESERVED
+ 51	RESERVED
+ 52	RESERVED
+ 53	RESERVED
+ 54	RESERVED
+ 55	RESERVED
+ 56	RESERVED
+ 57	RESERVED
+ 58	RESERVED
+ 59	RESERVED
+ 60	RESERVED
+ 61	RESERVED
+ 62	RESERVED
+ 63	RESERVED
+ 64	RESERVED
+ 65	RESERVED
+ 66	RESERVED
+ 67	RESERVED
+ 68	RESERVED
+ 69	RESERVED
+ 70	RESERVED
+ 71	RESERVED
+ 72	RESERVED
+ 73	RESERVED
+ 74	RESERVED
+ 75	RESERVED
+ 76	RESERVED
+ 77	RESERVED
+ 78	RESERVED
+ 79	RESERVED
+ 80	RESERVED
+ 81	RESERVED
+ 82	RESERVED
+ 83	RESERVED
+ 84	RESERVED
+ 85	RESERVED
+ 86	RESERVED
+ 87	RESERVED
+ 88	RESERVED
+ 89	RESERVED
+ 90	RESERVED
+ 91	RESERVED
+ 92	RESERVED
+ 93	RESERVED
+ 94	RESERVED
+ 95	RESERVED
+ 96	RESERVED
+ 97	RESERVED
+ 98	RESERVED
+ 99	RESERVED
+100	RESERVED
+101	Image data
+102	RESERVED
+103	RESERVED
+104	RESERVED
+105	RESERVED
+106	RESERVED
+107	RESERVED
+108	RESERVED
+109	RESERVED
+110	RESERVED
+111	RESERVED
+112	RESERVED
+113	RESERVED
+114	RESERVED
+115	RESERVED
+116	RESERVED
+117	RESERVED
+118	RESERVED
+119	RESERVED
+120	RESERVED
+121	RESERVED
+122	RESERVED
+123	RESERVED
+124	RESERVED
+125	RESERVED
+126	RESERVED
+127	RESERVED
+128	RESERVED
+129	RESERVED
+130	RESERVED
+131	RESERVED
+132	RESERVED
+133	RESERVED
+134	RESERVED
+135	RESERVED
+136	RESERVED
+137	RESERVED
+138	RESERVED
+139	RESERVED
+140	RESERVED
+141	RESERVED
+142	RESERVED
+143	RESERVED
+144	RESERVED
+145	RESERVED
+146	RESERVED
+147	RESERVED
+148	RESERVED
+149	RESERVED
+150	RESERVED
+151	RESERVED
+152	RESERVED
+153	RESERVED
+154	RESERVED
+155	RESERVED
+156	RESERVED
+157	RESERVED
+158	RESERVED
+159	RESERVED
+160	RESERVED
+161	RESERVED
+162	RESERVED
+163	RESERVED
+164	RESERVED
+165	RESERVED
+166	RESERVED
+167	RESERVED
+168	RESERVED
+169	RESERVED
+170	RESERVED
+171	RESERVED
+172	RESERVED
+173	RESERVED
+174	RESERVED
+175	RESERVED
+176	RESERVED
+177	RESERVED
+178	RESERVED
+179	RESERVED
+180	RESERVED
+181	RESERVED
+182	RESERVED
+183	RESERVED
+184	RESERVED
+185	RESERVED
+186	RESERVED
+187	RESERVED
+188	RESERVED
+189	RESERVED
+190	RESERVED
+191	RESERVED
+192	RESERVED
+193	RESERVED
+194	RESERVED
+195	RESERVED
+196	RESERVED
+197	RESERVED
+198	RESERVED
+199	RESERVED
+200	RESERVED
+201	RESERVED
+202	RESERVED
+203	RESERVED
+204	RESERVED
+205	RESERVED
+206	RESERVED
+207	RESERVED
+208	RESERVED
+209	RESERVED
+210	RESERVED
+211	RESERVED
+212	RESERVED
+213	RESERVED
+214	RESERVED
+215	RESERVED
+216	RESERVED
+217	RESERVED
+218	RESERVED
+219	RESERVED
+220	RESERVED
+221	RESERVED
+222	RESERVED
+223	RESERVED
+224	RESERVED
+225	RESERVED
+226	RESERVED
+227	RESERVED
+228	RESERVED
+229	RESERVED
+230	RESERVED
+231	RESERVED
+232	RESERVED
+233	RESERVED
+234	RESERVED
+235	RESERVED
+236	RESERVED
+237	RESERVED
+238	RESERVED
+239	RESERVED
+240	FOR EXPERIMENTAL USE
+241	FOR EXPERIMENTAL USE
+242	FOR EXPERIMENTAL USE
+243	FOR EXPERIMENTAL USE
+244	FOR EXPERIMENTAL USE
+245	FOR EXPERIMENTAL USE
+246	FOR EXPERIMENTAL USE
+247	FOR EXPERIMENTAL USE
+248	FOR EXPERIMENTAL USE
+249	FOR EXPERIMENTAL USE
+250	FOR EXPERIMENTAL USE
+251	FOR EXPERIMENTAL USE
+252	FOR EXPERIMENTAL USE
+253	FOR EXPERIMENTAL USE
+254	FOR EXPERIMENTAL USE
+255	Indicator for local use, with sub-category
diff --git a/data/tables/B2M-000-002-B b/data/tables/B2M-000-002-B
new file mode 100644
index 0000000..68bed0e
--- /dev/null
+++ b/data/tables/B2M-000-002-B
@@ -0,0 +1,710 @@
+#
+# BUFR Table B - Classification of Elements
+#
+#                                       Data
+#F      X       Y       Scale   RefVal  Width   Units           Element Name
+  0;    0;      1;      0;           0;   24;    CCITT_IA5; TABLE A ENTRY
+  0;    0;      2;      0;           0;  256;    CCITT_IA5; TABLE A  DATA CATEGORY DESCRIPTIO
+  0;    0;      3;      0;           0;  256;    CCITT_IA5; TABLE A DATA CATEGORY DESCRIPTION
+  0;    0;      5;      0;           0;   24;    CCITT_IA5; BUFR EDITION NUMBER
+  0;    0;     10;      0;           0;    8;    CCITT_IA5; F DESCRIPTOR TO BE ADDED OR DEFIN
+  0;    0;     11;      0;           0;   16;    CCITT_IA5; X DESCRIPTOR TO BE ADDED OR DEFIN
+  0;    0;     12;      0;           0;   24;    CCITT_IA5; Y DESCRIPTOR TO BE ADDED OR DEFIN
+  0;    0;     13;      0;           0;  256;    CCITT_IA5; ELEMENT NAME LN 1
+  0;    0;     14;      0;           0;  256;    CCITT_IA5; ELEMENT NAME LN 2
+  0;    0;     15;      0;           0;  192;    CCITT_IA5; UNITS NAME
+  0;    0;     16;      0;           0;    8;    CCITT_IA5; UNITS SCALE SIGN
+  0;    0;     17;      0;           0;   24;    CCITT_IA5; UNITS SCALE
+  0;    0;     18;      0;           0;    8;    CCITT_IA5; UNITS REFERENCE SIGN
+  0;    0;     19;      0;           0;   80;    CCITT_IA5; UNITS REFERENCE VALUE
+  0;    0;     20;      0;           0;   24;    CCITT_IA5; ELEMENT DATA WIDTH
+  0;    0;     30;      0;           0;   48;    CCITT_IA5; DESCRIPTOR DEFINING SEQUENCE
+  0;    1;      1;      0;           0;    7;      NUMERIC; WMO BLOCK NUMBER
+  0;    1;      2;      0;           0;   10;      NUMERIC; WMO STATION NUMBER
+  0;    1;      3;      0;           0;    3;      NUMERIC; WMO REGION NUMBER
+  0;    1;      4;      0;           0;    3;      NUMERIC; WMO REGION SUB-AREA
+  0;    1;      5;      0;           0;   17;      NUMERIC; BUOY/PLATFORM IDENTIFIER
+  0;    1;      6;      0;           0;   64;    CCITT_IA5; AIRCRAFT IDENTIFIER (FLIGHT NUMBE
+  0;    1;      7;      0;           0;   10;   CODE_TABLE; SAID SATELLITE IDENTIFIER
+  0;    1;      8;      0;           0;   64;    CCITT_IA5; AIRCRAFT REGISTRATION NUMBER (TAI
+  0;    1;      9;      0;           0;   64;    CCITT_IA5; TYPE OF COMMERCIAL ACFT
+  0;    1;     10;      0;           0;   64;    CCITT_IA5; STATIONARY BOUY PLATFORM IDENTIFI
+  0;    1;     11;      0;           0;   72;    CCITT_IA5; SHIP CALL SIGN
+  0;    1;     12;      0;           0;    9; DEGREES_TRUE; DIRECTION OF MOTION OBSERVING PLA
+  0;    1;     13;      0;           0;   10; METER/SECOND; SPEED OF MOTION OF OBSERVING PLAT
+  0;    1;     14;      2;           0;   10; METER/SECOND; PLATFORM DRIFT SPEED (HIGH PRECIS
+  0;    1;     15;      0;           0;    4;   CODE_TABLE; TRUE DIR OF MOVING PLATFORM PAST
+  0;    1;     16;      0;           0;    4;   CODE_TABLE; AVG SPD MOVING PLATFORM PAST 3 HO
+  0;    1;     21;      0;           0;   14;      NUMERIC; SYNOPTIC FEATURE ID
+  0;    1;     25;      0;           0;   24;    CCITT_IA5; STORM IDENTIFIER
+  0;    1;     26;      0;           0;   64;    CCITT_IA5; WMO STORM NAME
+  0;    1;     31;      0;           0;   16;   CODE_TABLE; GENERATING CENTER
+  0;    1;     32;      0;           0;    8;   CODE_TABLE; GENERATING APPLICATION
+  0;    1;     50;      0;           0;   48;    CCITT_IA5; NMC REPORT IDENTIFIER
+  0;    1;     62;      0;           0;   40;    CCITT_IA5; NAT'L ASSIGNED STATION IDENTIFIER
+  0;    1;     63;      0;           0;   64;    CCITT_IA5; ICLI ICAO LOCATION IDENTIFIER
+  0;    1;    164;      0;           0;   32;    CCITT_IA5; SEQNUM  LDM SEQUENCE NUMBER
+  0;    1;    192;      0;           0;    4;    CCITT_IA5; RADIOSONDE REPORT PART
+  0;    1;    193;      0;           0;   64;    CCITT_IA5; SATELLITE IDENTIFIER
+  0;    1;    194;      0;           0;   64;    CCITT_IA5; BUHD BULLETIN HEADER
+  0;    1;    195;      0;           0;    8;    CCITT_IA5; SACO  COUNTRY/AGENCY OPERATING SATELLITE
+  0;    1;    196;      0;           0;   16;    CCITT_IA5; SANA INDICATOR FIGURE FOR SATELLITE NAME
+  0;    1;    197;      0;           0;   64;    CCITT_IA5; RADIOSONDE SHIP OR MOBILE LND STN
+  0;    1;    198;      0;           0;   64;    CCITT_IA5; RPID REPORT IDENTIFIER
+  0;    1;    204;      0;           0;    8;   CODE_TABLE; SWPR SATELLITE WIND PRODUCER
+  0;    2;      1;      0;           0;    2;   CODE_TABLE; TYPE OF STATION
+  0;    2;      2;      0;           0;    4;   FLAG_TABLE; TYPE OF INSTR. FOR WIND MEASUREME
+  0;    2;      3;      0;           0;    4;   CODE_TABLE; TYPE OF MEASURING INSTRUMENT USED
+  0;    2;      4;      0;           0;    4;   CODE_TABLE; TYPE OF INSTR/CROP FOR EVAP/EVAPO
+  0;    2;      5;      2;           0;    7;      DEGREES; PRECISION OF TEMPERATURE OBS.
+  0;    2;     11;      0;           0;    8;   CODE_TABLE; RADIOSONDE TYPE
+  0;    2;     12;      0;           0;    4;   CODE_TABLE; RADIOSONDE COMPUTATIONAL METHOD
+  0;    2;     13;      0;           0;    4;   CODE_TABLE; SOLAR AND INFRARED RADIATION CORR
+  0;    2;     14;      0;           0;    7;   CODE_TABLE; TRACKING TECHNIQUE/STATUS OF SYST
+  0;    2;     15;      0;           0;    4;   CODE_TABLE; RADIOSONDE COMPLETENESS
+  0;    2;     21;      0;           0;    9;   FLAG_TABLE; SATELLITE INSTRUMENT DATA USED IN
+  0;    2;     22;      0;           0;    8;   FLAG_TABLE; SATELLITE DATA PROCESSING TECHNIQ
+  0;    2;     23;      0;           0;    8;   CODE_TABLE; CMCM SATELLITE DERIVED WIND COMPUTATIO
+  0;    2;     24;      0;           0;    4;   CODE_TABLE; INT. MEAN HUMIDITY COMPUTATIONAL
+  0;    2;     25;      0;           0;   25;   FLAG_TABLE; SATELLITE CHANNEL(S) USED IN COMP
+  0;    2;     26;      2;           0;   12;       METERS; CROSS TRACK RESOLUTION
+  0;    2;     27;      2;           0;   12;       METERS; ALONG TRACK RESOLUTION
+  0;    2;     28;      0;           0;   32;   FLAG_TABLE; GEOSTAT. SOUNDER SATELL CHAN'LS U
+  0;    2;     29;      0;           0;    8;   FLAG_TABLE; GEOSTAT. SOUNDER SATELL CHAN'LS U
+  0;    2;     30;      0;           0;    3;   CODE_TABLE; METH OF CURRENT MEASUREMENT
+  0;    2;     31;      0;           0;    5;   CODE_TABLE; DURATION & TIME OF CURRENT CODE M
+  0;    2;     32;      0;           0;    2;   CODE_TABLE; INDICATOR FOR DIGITIZATION
+  0;    2;     33;      0;           0;    3;   CODE_TABLE; METHOD OF SALINITY/DEPTH MEASUREM
+  0;    2;     34;      0;           0;    5;   CODE_TABLE; DROGUE TYPE
+  0;    2;     35;      0;           0;    9;       METERS; CABLE LENGTH
+  0;    2;     36;      0;           0;    2;   CODE_TABLE; BUOY TYPE
+  0;    2;     37;      0;           0;    3;   CODE_TABLE; METHOD OF TIDAL OBSERVATION
+  0;    2;     38;      0;           0;    3;   CODE_TABLE; METH OF SEA SURFACE TEMPERATURE M
+  0;    2;     39;      0;           0;    3;   CODE_TABLE; METH OF WET BULB TEMPERATURE MEAS
+  0;    2;     40;      0;           0;    4;   CODE_TABLE; METH RMV CODE VELOC & MOTION OF P
+  0;    2;     41;      0;           0;    6;   CODE_TABLE; METH FOR EST RPTS OF SYNOP FEATUR
+  0;    2;     42;      0;           0;    6;   CODE_TABLE; METHOD OF REPORT CONSTRUCTION
+  0;    2;     43;      0;           0;    6;   CODE_TABLE; PRECISION OF LAT/LON REPORT
+  0;    2;     51;      0;           0;    4;   CODE_TABLE; INDIC TO SPECIFY OBS METH EXTRM T
+  0;    2;     61;      0;           0;    3;   CODE_TABLE; AIRCRAFT NAVIGATION   SYSTEM
+  0;    2;     62;      0;           0;    4;   CODE_TABLE; TYPE OF AIRCRAFT DATA RELAY SYSTE
+  0;    2;     63;      2;      -18000;   16;      DEGREES; AIRCRAFT ROLL ANGLE
+  0;    2;     70;      0;           0;    4;   CODE_TABLE; ORIGINAL SPECIFICATION OF LAT/LON
+  0;    2;    101;      0;           0;    4;   CODE_TABLE; TYPE OF ANTENNA
+  0;    2;    102;      0;           0;    8;       METERS; ANTENNA HGT ABOVE TOWER
+  0;    2;    103;      0;           0;    2;        FLAGE; TABLE     RADOME
+  0;    2;    104;      0;           0;    4;   CODE_TABLE; ANTENNA POLARIZATION
+  0;    2;    105;      0;           0;    6;           DB; MAXIMUM ANTENNA GAIN
+  0;    2;    106;      1;           0;    6;      DEGREES; 3 - DB BANDWIDTH
+  0;    2;    107;      0;           0;    6;           DB; SIDELOBE SUPRESSION
+  0;    2;    108;      0;           0;    6;           DB; CROSSPOL DISCRI. (ON AXIS)
+  0;    2;    109;      2;           0;   12; DEGREES/SECOND; ANTENNA SPEED (AZIMUTH)
+  0;    2;    110;      2;           0;   12; DEGREES/SECOND; ANTENNA SPEED (ELEVATION)
+  0;    2;    111;      1;           0;   10;      DEGREES; RADAR INCIDENCE ANGLE
+  0;    2;    112;      1;           0;   12;      DEGREES; RADAR AZIMUTH ANGLE
+  0;    2;    113;      0;           0;    4;     NUMERICS; NO. OF AZIMUTH LOOKS
+  0;    2;    114;      0;           0;   15;         M**2; ANTENNA EFFECTIVE SURFACE AREA
+  0;    2;    121;      8;           0;    7;           HZ; MEAN FREQUENCY
+  0;    2;    122;      6;        -128;    8;           HZ; FREQUENCY AGILITY RANGE
+  0;    2;    123;      4;           0;    7;        WATTS; PEAK POWER
+  0;    2;    124;      1;           0;    7;        WATTS; AVERAGE POWER
+  0;    2;    125;      1;           0;    8;           HZ; PULSE REPETITION FREQUENCY
+  0;    2;    126;      7;           0;    6;       SECOND; PULSE WIDTH
+  0;    2;    127;      6;           0;    7;           HZ; RECEIVER INTERMEDIATE FREQUENCY
+  0;    2;    128;      5;           0;    6;           HZ; INTERMEDIATE FREQUENCY BANDWIDTH
+  0;    2;    129;      0;        -150;    5;           DB; MINIMUM DETECTABLE SIGNAL
+  0;    2;    130;      0;           0;    7;           DB; DYNAMIC RANGE
+  0;    2;    131;      0;           0;    2;   FLAG_TABLE; SENSITIVITY TIME CONTROL
+  0;    2;    132;      2;           0;    6;      DEGREES; AZIMUTH POINTING ACCURACY
+  0;    2;    133;      2;           0;    6;      DEGREES; ELEVATION POINTING ACCURACY
+  0;    2;    134;      2;           0;   16;      DEGREES; ANTENNA BEAM AZIMUTH
+  0;    2;    135;      2;       -9000;   15;      DEGREES; ANTENNA ELEVATION
+  0;    2;    140;      0;           0;    9;      DEGREES; SATELLITE RADAR BEAM AZIMUTH ANGL
+  0;    2;    141;      0;           0;   24;    CCITT_IA5; MEAS.TYPE SERIAL NBR/IDENT
+  0;    2;    142;      0;           0;   32;    CCITT_IA5; OZONE INSTRUMENT
+  0;    2;    143;      0;           0;    7;      NUMERIC; INSTRUMENT TYPE
+  0;    2;    183;      0;           0;    1;   CODE_TABLE; QUALITY OF PRESSURE MEASUREMENT
+  0;    2;    184;      0;           0;    1;   CODE_TABLE; QUALITY OF WATER SFC TEMP MEASURE
+  0;    2;    185;      0;           0;    1;   CODE_TABLE; QUALITY OF AIR TEMP MEASUREMENT
+  0;    2;    186;      0;           0;    3;   CODE_TABLE; QUAL CONTROL INDIC FOR FOLLOWING
+  0;    2;    187;      0;           0;    1;   CODE_TABLE; QUALITY OF BUOY SATELLIT TRANSMIS
+  0;    2;    188;      0;           0;    3;   CODE_TABLE; QUAL CONTROL INDICATOR FOR BUOY L
+  0;    2;    189;      0;           0;    3;   CODE_TABLE; QUAL CONTROL INDIC FOR BUOY TIME
+  0;    2;    190;      0;           0;    8;   CODE_TABLE; U, V QUALITY INDICATOR
+  0;    2;    191;      0;           0;    4;   CODE_TABLE; W QUALITY INDICATOR
+  0;    2;    192;      0;           0;    6;   CODE_TABLE; RADIOSONDE CORRECTION TYPE APPLIE
+  0;    2;    193;      0;           0;    3;   CODE_TABLE; IND TYPE OF STN OPERATION PAST/PR
+  0;    2;    200;      0;           0;    4;   CODE_TABLE; OBJECTIVE FORECAST TECHNIQUE USED
+  0;    2;    206;      0;           0;    4;        MONTH; MONTH  - RELEASE TIME
+  0;    2;    207;      0;           0;    6;          DAY; DAY    - RELEASE TIME
+  0;    2;    208;      0;           0;    5;         HOUR; HOUR   - RELEASE TIME
+  0;    2;    209;      0;           0;    6;       MINUTE; MINUTE - RELEASE TIME
+  0;    2;    210;      0;           0;    3;   FLAG_TABLE; STATION/SEA LEVEL COMPARISON
+  0;    4;      1;      0;           0;   12;         YEAR; YEAR   YEAR
+  0;    4;      2;      0;           0;    4;        MONTH; MNTH MONTH
+  0;    4;      3;      0;           0;    6;          DAY; DAYS DAY
+  0;    4;      4;      0;           0;    5;         HOUR; HOUR HOUR
+  0;    4;      5;      0;           0;    6;       MINUTE; MINU MINUTE
+  0;    4;      6;      0;           0;    6;       SECOND; SECOND
+  0;    4;     11;      0;       -1024;   11;        YEARS; TIME INCREMENT
+  0;    4;     12;      0;       -1024;   11;       MONTHS; TIME INCREMENT
+  0;    4;     13;      0;       -1024;   11;         DAYS; TIME INCREMENT
+  0;    4;     14;      0;       -1024;   11;        HOURS; TIME INCREMENT
+  0;    4;     15;      0;       -2048;   12;      MINUTES; TIME INCREMENT
+  0;    4;     16;      0;       -4096;   13;      SECONDS; TIME INCREMENT
+  0;    4;     21;      0;       -1024;   11;        YEARS; TIME PERIOD OR DISPLACEMENT
+  0;    4;     22;      0;       -1024;   11;       MONTHS; TIME PERIOD OR DISPLACEMENT
+  0;    4;     23;      0;       -1024;   11;         DAYS; TIME PERIOD OR DISPLACEMENT
+  0;    4;     24;      0;       -2048;   12;        HOURS; TIME PERIOD OR DISPLACEMENT
+  0;    4;     25;      0;       -2048;   12;      MINUTES; TIME PERIOD OR DISPLACEMENT
+  0;    4;     26;      0;       -4096;   13;      SECONDS; TIME PERIOD OR DISPLACEMENT
+  0;    4;     31;      0;           0;    8;         HOUR; DUR OF TIME REL TO FOLLOWING VALU
+  0;    4;     41;      0;       -1440;   12;       MINUTE; TIME DIFFERENCE UTC - LMT
+  0;    4;     43;      0;           0;    9;          DAY; DAY OF THE YEAR
+  0;    4;     44;      0;           0;    3;   CODE_TABLE; DAY OF THE WEEK
+  0;    4;     53;      0;           0;    6;      NUMERIC; NUMBER OF DAYS WITH PRECIP => 1MM
+  0;    4;    192;      0;           0;   12;        HOURS; RECIEPT TIME - REPORT TIME
+  0;    4;    193;      0;           0;   12;      MINUTES; RECIEPT TIME - REPORT TIME
+  0;    4;    194;      0;           0;   12;        HOURS; RELEASE TIME OF SONDE
+  0;    4;    195;      0;           0;    5;         HOUR; FORECAST CYCLE HOUR
+  0;    4;    200;      0;           0;   12;         YEAR; RCYR YEAR   - TIME OF RECEIPT
+  0;    4;    201;      0;           0;    4;        MONTH; RCMO MONTH  - TIME OF RECEIPT
+  0;    4;    202;      0;           0;    6;          DAY; RCDY DAY    - TIME OF RECEIPT
+  0;    4;    203;      0;           0;    5;         HOUR; RCHR HOUR   - TIME OF RECEIPT
+  0;    4;    204;      0;           0;    6;       MINUTE; RCMI MINUTE - TIME OF RECEIPT
+  0;    4;    205;      0;           0;    6;       SECOND; SECOND - TIME OF RECEIPT
+  0;    4;    206;      0;           0;   32;       SECOND; DATA BASE INGEST TIME FROM 1 JAN
+  0;    4;    207;      0;           0;    5;         HOUR; HOUR - TIME OF MAX WIND (GUST)
+  0;    4;    208;      0;           0;    6;       MINUTE; MINUTE - TIME OF NAX WIND (GUST)
+  0;    5;      1;      5;    -9000000;   25;      DEGREES; LATITUDE(HIGH ACCURACY)
+  0;    5;      2;      2;       -9000;   15;      DEGREES; CLAT LATITUDE(COARSE ACCURACY)
+  0;    5;      3;      2;       -9000;   15;      DEGREES; ALTERNATE LATITUDE
+  0;    5;     11;      5;    -9000000;   25;      DEGREES; LATITUDE INCREMENT(HIGH ACCURACY)
+  0;    5;     12;      2;       -9000;   15;      DEGREES; LATITUDE INCREMENT(COARSE ACCURAC
+  0;    5;     21;      2;           0;   16; DEGREES_TRUE; BEARING OR AZIMUTH
+  0;    5;     22;      2;           0;   16; DEGREES_TRUE; SOLAR AZIMUTH
+  0;    5;     30;      0;           0;   12;      DEGREES; DIRECTION (SPECTRAL)
+  0;    5;     31;      0;           0;   12;      NUMERIC; ROW NUMBER
+  0;    5;     33;      1;           0;   16;       METERS; PIXEL SIZE ON HORIZONTAL-1
+  0;    5;     40;      0;           0;   24;      NUMERIC; ORBIT NUMBER
+  0;    5;     41;      0;           0;    8;      NUMERIC; SCAN LINE NUMBER
+  0;    5;     42;      0;           0;    6;      NUMERIC; CHANNEL NUMBER
+  0;    5;     43;      0;           0;    8;      NUMERIC; FIELD OF VIEW NUMBER
+  0;    5;     50;      5;           0;   17;      NUMERIC; SIGMA LEVEL
+  0;    5;     52;      0;           0;    5;      NUMERIC; CHANNEL NUMBER INCREMENT
+  0;    5;     53;      0;           0;    5;      NUMERIC; FIELD OF VIEW NUMBER INCREMENT
+  0;    6;      1;      5;   -18000000;   26;      DEGREES; LONGITUDE (HIGH ACCURACY)
+  0;    6;      2;      2;      -18000;   16;      DEGREES; CLON LONGITUDE (COARSE ACCURACY)
+  0;    6;      3;      2;      -18000;   16;      DEGREES; ALTERNATE LONGITUDE
+  0;    6;     11;      5;   -18000000;   26;      DEGREES; LONGITUDE INCREMENT (HIGH ACCURAC
+  0;    6;     12;      2;      -18000;   16;      DEGREES; LONGITUDE INCREMENT (COARSE ACCUR
+  0;    6;     21;      1;           0;   13;       METERS; DISTANCE
+  0;    6;     30;      5;           0;   13;        RAD/M; WAVENUMBER (SPECTRAL)
+  0;    6;     31;      0;           0;   12;      NUMERIC; COLUMN NUMBER
+  0;    6;     33;      1;           0;   16;       METERS; PIXEL SIZE ON HORIZONTAL-2
+  0;    7;      1;      0;        -400;   15;       METERS; HEIGHT OF STATION
+  0;    7;      2;      1;         -40;   16;       METERS; HEIGHT OR ALTITUDE
+  0;    7;      3;      1;        -400;   17;    M**2/S**2; GEOPOTENTIAL
+  0;    7;      4;     -1;           0;   14;      PASCALS; PRLC PRESSURE
+  0;    7;      5;      0;        -400;   12;       METERS; HEIGHT INCREMENT
+  0;    7;      6;      0;           0;   15;       METERS; HEIGHT ABOVE STATION
+  0;    7;      7;      0;       -1000;   17;            M; HEIGHT
+  0;    7;      8;      0;      -10000;   20;    M**2/S**2; GEOPOTENTIAL
+  0;    7;     21;      2;       -9000;   15;      DEGREES; ELEVATION
+  0;    7;     22;      2;       -9000;   15;      DEGREES; SOLAR ELEVATION
+  0;    7;     61;      2;           0;   14;       METERS; DEPTH BELOW LAND SURFACE
+  0;    7;     62;      1;           0;   17;       METERS; DEPTH BELOW SEA SURFACE
+  0;    7;    190;      0;           0;   12;       METERS; HEIGHT INCREMENT
+  0;    7;    192;      0;        -400;   17;          GPM; FLIGHT LEVEL (PRESSURE ALTITUDE)
+  0;    7;    193;      0;        -400;   17;         GPDM; FLIGHT LEVEL (PRESSURE ALTITUDE)
+  0;    7;    194;      0;        -400;   15;            M; HEIGHT OR ALTITUDE ABOVE MSL
+  0;    8;      1;      0;           0;    7;   FLAG_TABLE; VERTICAL SOUNDING SIGNIFICANCE
+  0;    8;      2;      0;           0;    6;   CODE_TABLE; VERT. SIGNIFICANCE (SFC OBSERVATI
+  0;    8;      3;      0;           0;    6;   CODE_TABLE; VERT. SIGNIFICANCE (SAT OBSERVATI
+  0;    8;      4;      0;           0;    3;   CODE_TABLE; PHASE OF AIRCRAFT FLIGHT
+  0;    8;      5;      0;           0;    4;   CODE_TABLE; SURFACE SYNOPTIC FEATURE SIGNIFIC
+  0;    8;     10;      0;           0;    4;   CODE_TABLE; VERT SIGNIFICANCE(FORECAST SOUNDI
+  0;    8;     11;      0;           0;    6;   CODE_TABLE; HORIZONTAL SIGNIFICANCE
+  0;    8;     12;      0;           0;    2;   CODE_TABLE; LAND/SEA QUALIFIER
+  0;    8;     13;      0;           0;    2;   CODE_TABLE; DAY/NIGHT QUALIFIER
+  0;    8;     20;      0;           0;   16;      NUMERIC; TOTAL NR MISG ENTITIES W/RES TO A
+  0;    8;     21;      0;           0;    5;   CODE_TABLE; TIME SIGNIFICANCE
+  0;    8;     22;      0;           0;   16;      NUMERIC; TOTAL NUMBER(W/RESPECT TO ACCUM O
+  0;    8;     23;      0;           0;    7;   CODE_TABLE; FIRST ORDER STATISTICS
+  0;    8;     24;      0;           0;    7;   CODE_TABLE; DIFFERENCE STATISTICS
+  0;    8;     31;      0;           0;    8;         BUFR; TABLE A    DATA CATEGORY
+  0;    8;     32;      0;           0;   14;   CODE_TABLE; DATA SIGNIF-INTERACTIVE RETRIEVAL
+  0;    8;     51;      0;           0;    3;   CODE_TABLE; QUALIFIER-NR MISG VALUES IN CALC
+  0;    8;     52;      0;           0;    5;   CODE_TABLE; COND. FOR  WHICH NR OF DAYS OF OC
+  0;    8;     53;      0;           0;    2;   CODE_TABLE; DAY OF OCCURRENCE QUALIFIER
+  0;    8;    192;      0;           0;   16;      NUMERIC; UPDATE SEQUENCE NUMBER
+  0;    8;    193;      0;           0;   16;      NUMERIC; OBSERVATION DATABASE KEY
+  0;    8;    194;      0;           0;    6;   CODE_TABLE; CORRECTION INDICATOR
+  0;    8;    195;      0;           0;    6;   CODE_TABLE; QUALITY CONTROL TYPE
+  0;    8;    196;      0;           0;    6;   CODE_TABLE; QUALITY CONTROL DECISION
+  0;    8;    197;      0;           0;    5;   CODE_TABLE; RECORD TEMPERATURE KEY
+  0;    8;    198;      0;           0;    4;   CODE_TABLE; TIME SIGNIFICANCE
+  0;    8;    199;      0;           0;    3;   CODE_TABLE; SUWS SOURCE UNITS OF WIND SPEED
+  0;    8;    200;      0;           0;    4;      NUMERIC; NMC QUALITY MARK
+  0;    8;    202;      0;           0;    6;   CODE_TABLE; RCTS RECEIPT TIME SIGNIFICANT
+  0;    8;    232;      0;           0;   14;   CODE_TABLE; DATA SIGNIF-INTERACTIVE RETRIEVAL
+  0;    9;      6;      3;           0;   10;      SECONDS; TIME OF ASCENDING NODE
+  0;   10;      1;      0;        -400;   15;       METERS; HEIGHT OF LAND SURFACE
+  0;   10;      2;      1;         -40;   16;       METERS; HEIGHT
+  0;   10;      3;      1;        -400;   17;    M**2/S**2; GEOPOTENTIAL
+  0;   10;      4;      1;           0;   14;      PASCALS; PRESSURE
+  0;   10;      7;      0;       -1000;   17;       METERS; HGHT HEIGHT
+  0;   10;      8;      0;      -10000;   20;    M**2/S**2; GEOPOTENTIAL
+  0;   10;     50;      2;           0;   16;       METERS; STD. DEV. ALTITUDE
+  0;   10;     51;      1;           0;   14;      PASCALS; PRESSURE REDUCED TO MSL
+  0;   10;     52;      1;           0;   14;      PASCALS; ALTIMETER SETTING (QNH)
+  0;   10;     60;      1;       -1024;   11;      PASCALS; PRESSURE CHANGE
+  0;   10;     61;      1;        -500;   10;      PASCALS; 3 HOUR PRESSURE CHANGE
+  0;   10;     62;      1;       -1000;   11;      PASCALS; 24 HOUR PRESSURE CHANGE
+  0;   10;     63;      0;           0;    4;   CODE_TABLE; CHARACTERISTIC OF PRESSURE TENDEN
+  0;   10;    192;      0;        -400;   17;          GPM; GEOPOTENTIAL HEIGHT
+  0;   10;    193;      0;        -400;   17;         GPDM; GEOPOTENTIAL HEIGHT
+  0;   10;    194;      0;       -2000;   17;          GPM; DEPARTURE FROM ICAO STD ATMOSPHER
+  0;   10;    195;      0;        -400;   17;           DM; GEOMETRIC HEIGHT
+  0;   11;      1;      0;           0;    9; DEGREES_TRUE; WDIR WIND DIRECTION
+  0;   11;      2;      1;           0;   12; METERS/SECOND; WSPD WIND SPEED
+  0;   11;      3;      1;       -4096;   13; METERS/SECOND; U-COMPONENT
+  0;   11;      4;      1;       -4096;   13; METERS/SECOND; V-COMPONENT
+  0;   11;      5;      1;        -512;   10; PASCALS/SECOND; W-COMPONENT
+  0;   11;      6;      2;       -4096;   13; METERS/SECOND; W-COMPONENT
+  0;   11;     11;      0;           0;    9; DEGREES_TRUE; WIND DIRECTION AT 10 METERS
+  0;   11;     12;      1;           0;   12; METERS/SECOND; WIND SPEED AT 10 METERS
+  0;   11;     13;      0;           0;    9; DEGREES_TRUE; WIND DIRECTION AT 5 METERS
+  0;   11;     14;      1;           0;   12; METERS/SECOND; WIND SPEED AT 5 METERS
+  0;   11;     21;      9;      -65536;   17;   SECOND**-1; RELATIVE VORTICITY
+  0;   11;     22;      9;      -65536;   17;   SECOND**-1; DIVERGENCE
+  0;   11;     23;      2;      -65536;   17;  M**2/SECOND; VELOCITY POTENTIAL
+  0;   11;     31;      0;           0;    4;   CODE_TABLE; DEGREE OF TURBULENCE
+  0;   11;     32;      1;         -40;   16;       METERS; HEIGHT OF BASE OF TURBULENCE
+  0;   11;     33;      1;         -40;   16;       METERS; HEIGHT OF TOP OF TURBULENCE
+  0;   11;     34;      1;       -1024;   11; METERS/SECOND; VERTICAL GUST VELOCITY
+  0;   11;     35;      2;       -8192;   14; METERS/SECOND**2VERTICAL; GUST ACCELERATION
+  0;   11;     36;      1;           0;   10; METERS/SECOND; MAXIMUM DERIVED EQUIVALENT VERTIC
+  0;   11;     41;      1;           0;   12; METERS/SECOND; MAX WIND SPEED (GUSTS)
+  0;   11;     42;      1;           0;   12; METERS/SECOND; MAX WIND SPEED(10 MIN MEAN WIND)
+  0;   11;     43;      0;           0;    9; DEGREES_TRUE; MAXIMUM WIND GUST DIRECTION
+  0;   11;     44;      0;           0;    9; DEGREES_TRUE; SFC-5000FT MEAN LYR WIND DIRECTIO
+  0;   11;     49;      0;           0;    9; DEGREES_TRUE; STD. DEV. OF WIND DIRECTION
+  0;   11;     50;      1;           0;   12; METERS/SECOND; STD. DEV. HORIZ WIND SPEED
+  0;   11;     51;      1;           0;    8; METERS/SECOND; STD DEV VERT WIND COMPONENT
+  0;   11;     61;      1;           0;   12; METERS/SECOND; ABSOLUTE WIND SHEAR(1KM LAYER BEL
+  0;   11;     62;      1;           0;   12; METERS/SECOND; ABSOLUTE WIND SHEAR(1KM LAYER ABO
+  0;   11;    192;      1;       -1024;   11; METERS/SECOND; MEAN U-COMPONENT
+  0;   11;    193;      1;       -1024;   11; METERS/SECOND; MEAN V-COMPONENT
+  0;   11;    194;      1;        -128;    8; METERS/SECOND; MEAN W-COMPONENT
+  0;   11;    195;      1;           0;    9; METERS/SECOND; STANDARD DEVIATION U
+  0;   11;    196;      1;           0;    9; METERS/SECOND; STANDARD DEVIATION V
+  0;   11;    197;      1;           0;    6; METERS/SECOND; STANDARD DEVIATION W
+  0;   11;    198;      1;           0;   12; METERS/SECOND; WIND SPEED 10000FT (EXTRAPLOATED)
+  0;   11;    199;      1;           0;   12; METERS/SECOND; WIND SPEED 20000FT (EXTRAPOLATED)
+  0;   11;    200;      1;           0;   12; METERS/SECOND; INFLATED WIND SPEED (MOS)
+  0;   11;    201;      1;           0;   12; METERS/SECOND; MEAN WIND SPEED PAST 12 HRS
+  0;   11;    210;      1;           0;   12; METERS/SECOND; ROOT MEAN SQUARE VECTOR WIND ERRO
+  0;   11;    221;      0;           0;    9; DEGREES_TRUE; MEAN WIND DIR 5000FT-10000FT
+  0;   11;    222;      1;           0;   12; METERS/SECOND; MEAN WIND SPEED 5000FT-10000FT
+  0;   11;    223;      1;           0;   12; METERS/SECOND; 10 METER EXTRAPOLATED WIND SPEED
+  0;   11;    224;      1;           0;   12; METERS/SECOND; 20 METER EXTRAPOLATED WIND SPEED
+  0;   12;      1;      1;           0;   12; DEGREES_KELVIN; TMDB TEMPERATURE/DRY BULB TEMPERATURE
+  0;   12;      2;      1;           0;   12; DEGREES_KELVIN; WET BULB TEMPERATURE
+  0;   12;      3;      1;           0;   12; DEGREES_KELVIN; DEW POINT TEMPERATURE
+  0;   12;      4;      1;           0;   12; DEGREES_KELVIN; DRY BULB TEMPERATURE AT 2 METERS
+  0;   12;      5;      1;           0;   12; DEGREES_KELVIN; WET BULB TEMPERATURE AT 2 METERS
+  0;   12;      6;      1;           0;   12; DEGREES_KELVIN; DEW POINT TEMPERATURE AT 2 METERS
+  0;   12;      7;      1;           0;   12; DEGREES_KELVIN; VIRTUAL TEMPERATURE
+  0;   12;     11;      1;           0;   12; DEGREES_KELVIN; MAXIMUM TEMPERATURE
+  0;   12;     12;      1;           0;   12; DEGREES_KELVIN; MINIMUM TEMPERATURE
+  0;   12;     13;      1;           0;   12; DEGREES_KELVIN; GROUND MINIMUM TEMPERATURE PAST 1
+  0;   12;     14;      1;           0;   12; DEGREES_KELVIN; MAXIMUM TEMPERATURE AT 2MTRS,PAST
+  0;   12;     15;      1;           0;   12; DEGREES_KELVIN; MINIMUM TEMPERATURE AT 2MTRS,PAST
+  0;   12;     16;      1;           0;   12; DEGREES_KELVIN; MAXIMUM TEMPERATURE AT 2MTRS,PAST
+  0;   12;     17;      1;           0;   12; DEGREES_KELVIN; MINIMUM TEMPERATURE AT 2MTRS,PAST
+  0;   12;     20;      2;       -2000;   12;          DEG; K/DAY       RADIATIVE HEATING PROFILE
+  0;   12;     30;      1;           0;   12; DEGREES_KELVIN; SOIL TEMPERATURE
+  0;   12;     40;      3;       -2048;   12; WATTS/METER**2; SENSIBLE HEAT FLUX
+  0;   12;     51;      1;           0;   10; DEGREES_KELVIN; STANDARD DEVIATION TEMPERATURE
+  0;   12;     52;      1;           0;   12; DEGREES_KELVIN; HIGHEST DAILY MEAN TEMPERATURE
+  0;   12;     53;      1;           0;   12; DEGREES_KELVIN; LOWEST DAILY MEAN TEMPERATURE
+  0;   12;     61;      1;           0;   12; DEGREES_KELVIN; SKIN TEMPERATURE
+  0;   12;     62;      1;           0;   12; DEGREES_KELVIN; EQUIVALENT BLACK BODY TEMPERATURE
+  0;   12;     63;      1;           0;   12; DEGREES_KELVIN; BRIGHTNESS TEMPERATURE
+  0;   12;    192;      0;           0;    6;   CODE_TABLE; PRECISION OF AIRCRAFT TEMPERATURE
+  0;   12;    193;      1;           0;   12; DEGREES_KELVIN; TEMPERATURE (CITY)
+  0;   12;    194;      1;           0;   12; DEGREES_KELVIN; MAXIMUM TEMPERATURE (CITY)
+  0;   12;    195;      1;           0;   12; DEGREES_KELVIN; MINIMUM TEMPERATURE (CITY)
+  0;   12;    200;      1;           0;   12; DEGREES_KELVIN; DAYTIME MAX TEMPERATURE
+  0;   12;    201;      1;           0;   12; DEGREES_KELVIN; NIGHTTIME MIN TEMPERATURE (MOS)
+  0;   13;      1;      5;           0;   14;        KG/KG; SPECIFIC HUMIDITY
+  0;   13;      2;      5;           0;   14;        KG/KG; MIXING RATIO
+  0;   13;      3;      0;           0;    7;            %; RELATIVE HUMIDITY
+  0;   13;      4;      1;           0;   10;      PASCALS; VAPOR PRESSURE
+  0;   13;      5;      3;           0;    7;  KG/METER**3; VAPOR DENSITY
+  0;   13;      6;      1;         -40;   16;       METERS; MIXING HEIGHTS
+  0;   13;     11;      1;          -1;   14;  KG/METER**2; TOTAL PRECIPITATION/TOTAL WATER E
+  0;   13;     12;      2;          -2;   12;       METERS; DEPTH OF FRESH SNOW
+  0;   13;     13;      2;          -2;   16;       METERS; TOTAL SNOW DEPTH
+  0;   13;     14;      4;           0;   12; KG/METER**2/SEC; RAINFALL/WATER EQUIV OF SNOW(AVG
+  0;   13;     15;      7;           0;   12; METERS/SECOND; SNOWFALL (AVERAGED RATE)
+  0;   13;     16;      0;           0;    7;  KG/METER**2; PRECIPITABLE WATER
+  0;   13;     19;      1;          -1;   14;  KG/METER**2; TOTAL PRECIPITATION PAST 1 HOUR
+  0;   13;     20;      1;          -1;   14;  KG/METER**2; TOTAL PRECIPITATION PAST 3 HOURS
+  0;   13;     21;      1;          -1;   14;  KG/METER**2; TOTAL PRECIPITATION PAST 6 HOURS
+  0;   13;     22;      1;          -1;   14;  KG/METER**2; TOTAL PRECIPITATION PAST 12 HOURS
+  0;   13;     23;      1;          -1;   14;  KG/METER**2; TOTAL PRECIPITATION PAST 24 HOURS
+  0;   13;     31;      0;           0;    7;  KG/METER**2; EVAPOTRANSPIRATION
+  0;   13;     32;      1;           0;    8;  KG/METER**2; EVAP/EVAPOTRANSPIRATION
+  0;   13;     40;      3;       -2048;   12; WATTS/METER**2; LATENT HEAT FLUX
+  0;   13;     41;      0;           0;    4;   CODE_TABLE; PASQUELL-GIFFORD STAB
+  0;   13;     42;      0;         -20;    6; DEGREES_KELVIN; PARCEL LIFTED INDEX (TO 500 HPA)
+  0;   13;     43;      0;         -20;    6; DEGREES_KELVIN; BEST LIFTED INDEX (TO 500 HPA)
+  0;   13;     51;      0;           0;    4;   CODE_TABLE; FREQ GRP, PRECIPITATION
+  0;   13;     52;      1;          -1;   14;          KG/; M**2        HIGHEST DAILY AMT OF PRECIPITATIO
+  0;   13;    192;      0;           0;    6;   CODE_TABLE; PRECIPITABLE WATER QUALITY
+  0;   13;    193;      4;          -1;   14;     KGM/M**2; 24 HR PRECIPITATION (CITY)
+  0;   13;    194;      0;           0;    3;   CODE_TABLE; INDIC INCLUSION/OMISSION OF PRECI
+  0;   14;      1;      3;       -2048;   12; JOULES/METER**2; LONGWAVE RADIATION. INTEGRATED 24
+  0;   14;      2;      3;       -2048;   12; JOULES/METER**2; LONGWAVE RAD. INTEGRATED SPEC.PER
+  0;   14;      3;      3;       -2048;   12; JOULES/METER**2; SHORTWAVE RAD. INTEGRATED 24 HOUR
+  0;   14;      4;      3;       -2048;   12; JOULES/METER**2; SHORTWAVE RAD. INTEGRATED SPEC PE
+  0;   14;     11;      3;       -2048;   12; JOULES/METER**2; NET LONGWAVE RAD. INTEG. 24 HOURS
+  0;   14;     12;      3;       -2048;   12; JOULES/METER**2; NET LONGWAVE RAD. INT SPEC PERIOD
+  0;   14;     13;      3;       -2048;   12; JOULES/METER**2; NET SHORTWAVE RAD. INTEG 24 HOURS
+  0;   14;     14;      3;       -2048;   12; JOULES/METER**2; NET SHORTWAVE RAD. INTEG SPEC PER
+  0;   14;     15;      4;      -16384;   15; JOULES/METER**2; NET RAD INTEGRATED OVER 24 HOURS
+  0;   14;     16;      4;      -16384;   15; JOULES/METER**2; NET RADIATION INTEG OVR PD SPECIF
+  0;   14;     17;      3;       -2048;   12; WATTS/METER**2; INSTANTANEOUS LONG WAVE RADIATION
+  0;   14;     18;      3;       -2048;   12; WATTS/METER**2; INSTANTANEOUS SHORT WAVE RADIATIO
+  0;   14;     19;      0;           0;    7;            %; SURFACE ALBEDO
+  0;   14;     20;      4;           0;   15; JOULES/METER**2; GLOBAL SOLAR RAD INTEG OVER  24 H
+  0;   14;     21;      4;           0;   15; JOULES/METER**2; GLOBAL RADIATION INTEG OVER PD SP
+  0;   14;     22;      4;           0;   15; JOULES/METER**2; DIFFUSE SOLAR RAD INTEG OVER  24
+  0;   14;     23;      4;           0;   15; JOULES/METER**2; DIFFUSE SOLAR RAD INTEG OVER PD S
+  0;   14;     24;      4;           0;   15; JOULES/METER**2; DIRECT SOLAR RAD INTEG OVER  24 H
+  0;   14;     25;      4;           0;   15; JOULES/METER**2; DIRECT SOLAR RAD INTEG OVER PD SP
+  0;   14;     31;      0;           0;   11;      MINUTES; TOTAL SUNSHINE
+  0;   14;     32;      0;           0;   10;        HOURS; TOTAL SUNSHINE
+  0;   14;     33;      0;           0;    9;            %; TOTAL SUNSHINE(PERCENTAGE)
+  0;   14;     41;      0;           0;    7;            %; SHORT WAVE ALBEDO
+  0;   14;     42;      0;           0;    7;            %; BI-DIRECTIONAL REFLECTANCE
+  0;   14;    200;      0;           0;    7;            %; PERCENT OF POSSIBLE SUNSHINE
+  0;   15;      1;      0;           0;   10;       DOBSON; UNITS    OZONE
+  0;   15;      2;      2;           0;   10;      NUMERIC; AIR-MASS (SLANT PATH AT 22KM)
+  0;   15;     11;      3;       14000;   12;     LOG/M**2; LOG_E OF INTEGRATED ELECTRON DENS
+  0;   19;      1;      0;           0;    6;   CODE_TABLE; TYPE OF SYNOPTIC FEATURE
+  0;   19;      2;      2;           0;   12;       METERS; EFFECTIVE RADIUS OF FEATURE
+  0;   19;      3;      0;           0;    8; METERS/SECOND; WIND SPEED THRESHOLD
+  0;   19;      4;      2;           0;   12;       METERS; EFF RAD OF FEAT W/RESP TO WINDS A
+  0;   19;      5;      0;           0;    9;          DEG; TRUE        DIRECTION OF MOTION OF FEATURE
+  0;   19;      6;      2;           0;   14; METERS/SECOND; SPEED OF MOTION OF FEATURE
+  0;   19;      7;      3;           0;   12;       METERS; EFFECTIVE RADIUS OF FEATURE
+  0;   19;      8;      0;           0;    3;   CODE_TABLE; VERTICAL EXTENT OF CIRCULATION
+  0;   19;      9;      3;           0;   12;       METERS; EFF. RAD. W/RESPECT TO FFF ABV TH
+  0;   20;      1;      1;           0;   13;       METERS; HORIZONTAL VISIBILITY
+  0;   20;      2;      1;           0;    7;       METERS; VERTICAL VISIBILITY
+  0;   20;      3;      0;           0;    9;   CODE_TABLE; PRESENT WEATHER
+  0;   20;      4;      0;           0;    5;   CODE_TABLE; PAST WEATHER (1)
+  0;   20;      5;      0;           0;    5;   CODE_TABLE; PAST WEATHER (2)
+  0;   20;      9;      1;         -40;   11;       METERS; CEILING
+  0;   20;     10;      0;           0;    7;            %; CLOUD COVER (TOTAL)
+  0;   20;     11;      0;           0;    4;   CODE_TABLE; CLOUD AMOUNT
+  0;   20;     12;      0;           0;    6;   CODE_TABLE; CLOUD TYPE
+  0;   20;     13;      1;         -40;   11;       METERS; HEIGHT OF BASE OF CLOUD
+  0;   20;     14;      1;         -40;   11;       METERS; HEIGHT OF TOP OF CLOUD
+  0;   20;     15;      1;           0;   14;      PASCALS; PRESSURE AT THE BASE OF CLOUD
+  0;   20;     16;      1;           0;   14;      PASCALS; PRESSURE AT THE TOP OF CLOUD
+  0;   20;     17;      0;           0;    4;   CODE_TABLE; CLOUD TOP DESCRIPTION
+  0;   20;     18;      1;          40;   11;       METERS; LOWEST HGT OF CLD TOP
+  0;   20;     19;      1;          40;   11;       METERS; HIGHEST HGT OF CLD TOP
+  0;   20;     20;      0;           0;    4; CODE_TABLE(02001LOW; CLOUD AMOUNT
+  0;   20;     21;      0;           0;    4; CODE_TABLE(02001MIDDLE; CLOUD AMOUNT
+  0;   20;     22;      0;           0;    4; CODE_TABLE(02001HIGH; CLOUD AMOUNT
+  0;   20;     23;      0;           0;    7;            %; SATELLITE SENSED EFF CLOUD AMOUNT
+  0;   20;     31;      2;           0;    7;       METERS; ICE DEPOSIT (THICKNESS)
+  0;   20;     32;      0;           0;    3;   CODE_TABLE; RATE OF ICE ACCRETION
+  0;   20;     33;      0;           0;    4;   FLAG_TABLE; CAUSE OF ICE ACCRETION
+  0;   20;     34;      0;           0;    5;   CODE_TABLE; SEA ICE CONCENTRATION
+  0;   20;     35;      0;           0;    4;   CODE_TABLE; AMOUNT AND TYPE OF ICE
+  0;   20;     36;      0;           0;    5;   CODE_TABLE; ICE SITUATION
+  0;   20;     37;      0;           0;    5;   CODE_TABLE; ICE DEVELOPMENT
+  0;   20;     38;      0;           0;   12; DEGREES_TRUE; BEARING OF ICE EDGE
+  0;   20;     39;      1;           0;   13;       METERS; ICE DISTANCE
+  0;   20;     41;      0;           0;    4;   CODE_TABLE; AIRFRAME ICING
+  0;   20;     51;      0;           0;    7;            %; AMOUNT OF LOW CLOUDS
+  0;   20;     52;      0;           0;    7;            %; AMOUNT OF MIDDLE CLOUDS
+  0;   20;     53;      0;           0;    7;            %; AMOUNT OF HIGH CLOUDS
+  0;   20;     61;      0;           0;   12;       METERS; RUNWAY VISUAL RANGE (RVR)
+  0;   20;     62;      0;           0;    5;   CODE_TABLE; STATE OF GROUND(W /WO SNOW)
+  0;   20;     63;      0;           0;   10;   CODE_TABLE; SPECIAL PHENOMENA
+  0;   20;    192;      0;           0;    7;   CODE_TABLE; VISIBILITY TOWARDS SEA(WMO TABLE
+  0;   20;    200;      0;           0;    7;            %; MEAN CLD COVER (OPAQUE) PAST 12 H
+  0;   21;      1;      0;         -64;    7;           DB; HORIZONTAL REFLECTIVITY
+  0;   21;      2;      0;         -64;    7;           DB; VERTICAL REFLECTIVITY
+  0;   21;      3;      1;          -5;    7;           DB; DIFFERENTIAL REFLECTIVITY
+  0;   21;      5;      0;         -65;    6;           DB; LINEAR DEPOLARIZATION RATIO
+  0;   21;      6;      0;         -65;    6;           DB; CIRCULAR DEPOLARIZATION RATIO
+  0;   21;     11;      0;        -128;    8; METERS/SECOND; DOPPLER MEAN VELOCITY IN X DIRECT
+  0;   21;     12;      0;        -128;    8; METERS/SECOND; DOPPLER MEAN VELOCITY IN Y DIRECT
+  0;   21;     13;      0;        -128;    8; METERS/SECOND; DOPPLER MEAN VELOCITY IN Z DIRECT
+  0;   21;     14;      1;       -4096;   13; METERS/SECOND; DOPPLER MEAN VELOCITY (RADIAL)
+  0;   21;     17;      1;           0;    8; METERS/SECOND; DOPPLER VELOCITY SPECTRAL WIDTH
+  0;   21;     21;      3;           0;    4;       METERS; ECHO TOPS
+  0;   21;     30;      0;         -32;    8;           DB; SIGNAL TO NOISE RATIO
+  0;   21;     31;      0;           0;    7; KILOGRAMS/METER*VERT.; INTEGRATED LIQ. WATER CONTE
+  0;   21;     36;      7;           0;   12; METERS/SECOND; RADAR RAINFALL INTENSITY
+  0;   21;     41;      2;           0;    8;       METERS; BRIGHT BAND HEIGHT
+  0;   21;     51;      0;        -256;    8;           DB; SIGNAL POWER ABOVE 1MW
+  0;   21;     62;      2;       -5000;   13;     DECIBELS; BACKSCATTER
+  0;   21;     63;      0;           0;    7;            %; NOISE FIGURE
+  0;   21;     64;      0;           0;   10;      NUMERIC; CLUTTER NOISE ESTIMATE
+  0;   21;     65;      0;        -127;    8;      NUMERIC; MISSING PACKET COUNTER
+  0;   21;     66;      0;           0;   12;   FLAG_TABLE; WAVE SCATTEROMETER PRODUCT CONFID
+  0;   21;     67;      0;           0;   12;   FLAG_TABLE; WIND SCATTEROMETER PRODUCT CONFID
+  0;   21;     68;      0;           0;    8;   FLAG_TABLE; RADAR ALTIMETER PRODUCT CONFIDENC
+  0;   21;     69;      0;           0;    7;   FLAG_TABLE; ATSR SEA SFC TEMP QUAL ANALYSIS T
+  0;   21;     70;      0;           0;   15;   FLAG_TABLE; REPROCESSED WIND SCATTEROMETER PR
+  0;   21;     71;      0;           0;   16;      NUMERIC; PEAKINESS
+  0;   21;     72;      0;           0;    4;   FLAG_TABLE; SATELLITE ALTIMETER CALIBRATION S
+  0;   21;     73;      0;           0;    9;   FLAG_TABLE; SATELLITE ALTIMETER INSTRUMENT MO
+  0;   21;     74;      2;        -512;   10; DEGREES_KELVIN; MULTI/SINGLE VIEW DIFFERENCE
+  0;   21;     75;      0;           0;    8;      NUMERIC; SPECTRAL INTENSITY
+  0;   21;     76;      0;           0;    3;   CODE_TABLE; REPRESENTATION OF INTENSITIES
+  0;   21;     77;      3;           0;   14;       METERS; ALTITUDE CORRECTION (IONOSPHERE)
+  0;   21;     78;      3;           0;    9;       METERS; ALTITUDE CORRECTION (DRY TROPOSPH
+  0;   21;     79;      3;        2000;   10;       METERS; ALTITUDE CORRECTION (WET TROPOSPH
+  0;   21;     80;      3;           0;   11;       METERS; ALTITUDE CORRECTION (CALIB. CONST
+  0;   21;     81;      3;           0;   10;       METERS; OPEN LOOP CORRECTION (HGT-TIME LO
+  0;   21;     82;      3;       -3000;   14;     DECIBELS; OPEN LOOP CORRECTION (AUTO GAIN C
+  0;   21;     83;      0;           0;    7;            %; AMBIGUITY REMOVAL CONFIDENCE
+  0;   21;     84;      0;           0;    3;   CODE_TABLE; ATSR SEA SFC TEMP QUALITY SUMMARY
+  0;   21;     85;      0;           0;    4;      NUMERIC; ATSR SEA SFC TEMP ACROSS TRACK BA
+  0;   21;    192;      0;           0;    7;           DB; SPECTRAL PEAK POWER 0TH MOMENT
+  0;   21;    193;      1;       -4096;   13; METERS/SECOND; SPECTRAL PEAK POWER 1ST MOMENT
+  0;   21;    194;      1;           0;    8; METERS/SECOND; SPECTRAL PEAK POWER 2ND MOMENT
+  0;   22;      1;      0;           0;    9; DEGREES_TRUE; DIRECTION OF WAVES
+  0;   22;      2;      0;           0;    9; DEGREES_TRUE; DIRECTION OF WIND WAVES
+  0;   22;      3;      0;           0;    9; DEGREES_TRUE; DIRECTION OF SWELL WAVES
+  0;   22;      4;      0;           0;    9; DEGREES_TRUE; DIRECTION OF CURRENT WAVES
+  0;   22;     11;      0;           0;    6;      SECONDS; PERIOD OF WAVES
+  0;   22;     12;      0;           0;    6;      SECONDS; PERIOD OF WIND WAVES
+  0;   22;     13;      0;           0;    6;      SECONDS; PERIOD OF SWELL WAVES
+  0;   22;     21;      1;           0;   10;       METERS; HEIGHT OF WAVES
+  0;   22;     22;      1;           0;   10;       METERS; HEIGHT OF WIND WAVES
+  0;   22;     23;      1;           0;   10;       METERS; HEIGHT OF SWELL WAVES
+  0;   22;     25;      2;           0;   10;       METERS; STANDARD DEVIATION WAVE
+  0;   22;     26;      2;           0;   10;       METERS; STANDARD DEVIATION SIG WAVE HEIGH
+  0;   22;     31;      2;           0;   13; METERS/SECOND; SPEED OF CURRENT
+  0;   22;     37;      3;      -10000;   15;       METERS; TIDAL ELEV WITH RESPECT TO LAND D
+  0;   22;     38;      3;      -10000;   15;       METERS; TIDAL ELEV WITH RESPECT TO CHART
+  0;   22;     39;      3;       -5000;   12;       METERS; MET RESIDUAL TIDAL ELEV (SURGE OR
+  0;   22;     41;      1;           0;   12; DEGREES_KELVIN; SEA SFC TEM (15 DAY RUNNING MEAN)
+  0;   22;     42;      1;           0;   12; DEGREES_KELVIN; SEA TEMPERATURE
+  0;   22;     43;      2;           0;   15; DEGREES_KELVIN; SEA TEMPERATURE
+  0;   22;     44;      1;           0;   14; METERS/SECOND; SOUND VELOCITY
+  0;   22;     50;      2;           0;    8;            K; STD DEV SEA-SURFACE TEMPERATURE
+  0;   22;     61;      0;           0;    4;   CODE_TABLE; STATE OF SEA
+  0;   22;     62;      2;           0;   12;   PARTS/1000; SALINITY
+  0;   22;     63;      0;           0;   14;       METERS; TOTAL WATER DEPTH
+  0;   22;    105;      1;           0;    6; DEGREES_TRUE; DIRECTION OF WAVES
+  0;   22;    143;      2;        2650;   13; DEGREES_KELVIN; SEA TEMPERATURE
+  0;   22;    192;      0;           0;    4;   CODE_TABLE; TIDE INDICATOR
+  0;   22;    193;      1;           0;   10;       METERS; ABS VALUE DEPT OF TIDE FROM PRED
+  0;   22;    194;      3;        -305;   12;       METERS; DEPT OF TIDE FROM MEAN LOWER LOW
+  0;   23;      1;      0;           0;    3;   CODE_TABLE; ACCIDENT EARLY NOTIFICATION ART.A
+  0;   23;      2;      0;           0;    5;   CODE_TABLE; ACTIVITY OR FACILITY INVOLVED IN
+  0;   23;      3;      0;           0;    3;   CODE_TABLE; TYPE OF RELEASE
+  0;   23;      4;      0;           0;    3;   CODE_TABLE; COUNTERMEASURES TAKEN NR BORDER
+  0;   23;      5;      0;           0;    2;   CODE_TABLE; CAUSE  OF INCIDENT
+  0;   23;      6;      0;           0;    3;   CODE_TABLE; INCIDENT SITUATION
+  0;   23;      7;      0;           0;    3;   CODE_TABLE; CHARACTERISTIC OF RELEASE
+  0;   23;      8;      0;           0;    2;   CODE_TABLE; STATE OF CURRENT RELEASE
+  0;   23;      9;      0;           0;    2;   CODE_TABLE; STATE OF EXPECTED RELEASE
+  0;   23;     16;      0;           0;    2;   CODE_TABLE; POSS. OF SIG CHEM.TOXIC HEALTH EF
+  0;   23;     17;      6;           0;   20; METER**3/SECOND; FLOW DISCHARGE OF MAJ. RECIPIENT
+  0;   23;     18;      0;           0;    3;   CODE_TABLE; RELEASE BEHAVIOR OVER TIME
+  0;   23;     19;      0;      -15000;   17;       METERS; ACTUAL RELEASE HEIGHT
+  0;   23;     21;      0;      -15000;   17;       METERS; EFFECTIVE RELEASE HEIGHT
+  0;   23;     22;      0;           0;   24;       METERS; DIST. OF REL PT OR SITE OF INCIDE
+  0;   23;     23;      1;           0;   12; METERS/SECOND; MAIN TRANSPORT SPEED IN ATMOSPHER
+  0;   23;     24;      2;           0;   13; METERS/SECOND; MAIN TRANSPORT SPEED IN WATER
+  0;   23;     25;      2;           0;   13; METERS/SECOND; MAIN TRANSPORT SPEED IN GROUND WA
+  0;   23;     27;      0;           0;    9; DEGREES_TRUE; MAIN TRANSPORT DIR IN ATMOSPHERE
+  0;   23;     28;      0;           0;    9; DEGREES_TRUE; MAIN TRANSPORT DIR IN WATER
+  0;   23;     29;      0;           0;    9; DEGREES_TRUE; MAIN TRANSPORT DIR IN GROUND WATE
+  0;   23;     31;      0;           0;    2;   CODE_TABLE; POSS PLUME/PRECIP ENCOUNTER
+  0;   23;     32;      0;           0;    2;   CODE_TABLE; PLUME ENCOUNTER DIR/SPD CHANGE
+  0;   24;      1;      1;           0;   28;           BQ; EST. OF RADIOACTIVITY REL.TO SPEC
+  0;   24;      2;      1;           0;   28;           BQ; EST MAXIMUM POTENTIAL RELEASE
+  0;   24;      3;      0;           0;    5;   CODE_TABLE; COMPOSITION OF RELEASE
+  0;   24;      4;      0;           0;   16;    CCITT_IA5; ELEMENT NAME
+  0;   24;      5;      0;           0;    9;      NUMERIC; ISOTOPE MASS
+  0;   24;     11;      2;           0;   32;          MSV; DOSE
+  0;   24;     12;      2;           0;   32;          MSV; TRAJ DOSE(DEF LOC & EXP TIME OF A
+  0;   24;     13;      2;           0;   32;          MSV; GAMMA DOSE IN AIR ALG MAIN TRAN P
+  0;   24;     21;      2;           0;   32;  BQ/METER**3; AIR CONC.(NAMED ISOTOPE INC GROSS
+  0;   24;     22;      2;           0;   32;         BQ/L; CONC IN PRECIP(OF NAMED ISOTOPE T
+  0;   25;      1;      1;           0;    6;       METERS; RANGE GATE LENGTH
+  0;   25;      2;      0;           0;    4;      NUMERIC; NR OF GATES AVERAGED
+  0;   25;      3;      0;           0;    8;      NUMERIC; NR. OF INTEGRATED PULSES
+  0;   25;      4;      0;           0;    2;   CODE_TABLE; ECHO PROCESSING
+  0;   25;      5;      0;           0;    2;   CODE_TABLE; ECHO INTEGRATION
+  0;   25;      6;      0;           0;    3;   CODE_TABLE; Z TO R CONVERSION
+  0;   25;      7;      0;           0;   12;      NUMERIC; Z TO R CONVERSION FACTOR
+  0;   25;      8;      2;           0;    9;      NUMERIC; Z TO R CONVERSION EXPONENT
+  0;   25;      9;      0;           0;    4;   FLAG_TABLE; CALIBRATION METHOD
+  0;   25;     10;      0;           0;    4;   CODE_TABLE; CLUTTER TREATMENT
+  0;   25;     11;      0;           0;    2;   CODE_TABLE; GND. OCCULTATION CORR. (SCREENING
+  0;   25;     12;      0;           0;    2;   CODE_TABLE; RANGE ATTENUATION CORRECTION
+  0;   25;     13;      0;           0;    2;   FLAG_TABLE; BRIGHT BAND CORRECTION
+  0;   25;     15;      0;           0;    2;   FLAG_TABLE; RADOME ATTENUATION CORRECTION
+  0;   25;     16;      5;           0;    6;     DB/METER; CLEAR AIR ATTENUATION CORRECTION
+  0;   25;     17;      0;           0;    2;   FLAG_TABLE; PRECIPITATION ATTENUATION CORRECT
+  0;   25;     18;      7;           0;    6;      NUMERIC; A TO Z LAW FOR ATTENUATION FACTOR
+  0;   25;     19;      2;           0;    7;      NUMERIC; A TO Z LAW FOR ATTENUATION EXPONE
+  0;   25;     20;      0;           0;    2;   CODE_TABLE; MEAN SPEED ESTIMATION
+  0;   25;     21;      0;           0;    8;   FLAG_TABLE; WIND COMPUTATION ENHANCEMENT
+  0;   25;     30;      0;           0;    2;   CODE_TABLE; SST USAGE
+  0;   25;     31;      0;           0;    2;   CODE_TABLE; 15 DAY SST AVAILABILITY
+  0;   25;     32;      0;           0;    2;   CODE_TABLE; NOAA WIND PROFILER HIGH/LOW MODE
+  0;   25;     33;      0;           0;    2;   CODE_TABLE; NOAA WIND PROFILER SUBMODE
+  0;   25;     34;      0;           0;    4;   CODE_TABLE; NOAA WIND PROFILER Q/C TEST RESUL
+  0;   25;     35;      0;           0;    3;   CODE_TABLE; FIRST GUESS ADJUSTMENT
+  0;   25;     36;      3;       -5000;   14;      NUMERIC; NSTAR AVERAGE VALUE
+  0;   25;     37;      0;           0;    2;   CODE_TABLE; HIRS-8 SFC AIR TEMP
+  0;   25;     38;      0;           0;    3;   CODE_TABLE; TOVS FILTER FLAGS
+  0;   25;    202;      0;           0;    4;   FLAG_TABLE; TEMPERATURE CHANNEL SELECTION FLA
+  0;   25;    204;      0;           0;    8;   FLAG_TABLE; MATCHUP QUALITY TEST FLAGS
+  0;   25;    205;      0;           0;    8;   FLAG_TABLE; RETRIEVAL/DPI QUALITY TEST FLAGS
+  0;   25;    209;      3;           0;   12; DECIMAL_HOURS; DPI TIME DIFFERENCE (READ AS MINU
+  0;   25;    210;      3;           0;   19;       METERS; DPI DISTANCE
+  0;   25;    211;      3;           0;   12; DECIMAL_HOURS; QUANTITATIVE RETRIEVAL TIME DIFFE
+  0;   25;    212;      3;           0;   19;       METERS; QUANTITATIVE RETRIEVAL DISTANCE
+  0;   26;      1;      1;           0;   12;         HOUR; PCPL TIME OF DAILY RDG IN UTC MAX
+  0;   26;      2;      1;           0;   12;         HOUR; PCPL TIME OF DAILY RDG IN UTC MIN
+  0;   26;     31;      2;  -107341824;   31;       METERS; DIST FM EARTH CENTER IN DIR NORTH
+  0;   26;     32;      2;  -107341824;   31;       METERS; DIST FM EARTH CENTER IN DIR NORTH
+  0;   26;     41;      5;  -107341824;   31; METERS/SECOND; VEL W/RESP EARTH CTR IN DIR NORTH
+  0;   27;      1;      5;    -9000000;   25;      DEGREES; LATITUDE (HIGH ACCURACY)
+  0;   27;      2;      2;       -9000;   15;      DEGREES; LATITUDE (COARSE ACCURACY)
+  0;   27;      3;      2;       -9000;   15;      DEGREES; ALTERNATE LATITUDE
+  0;   27;     20;      0;           0;   16;      NUMERIC; SATELLITE LOCATION COUNTER
+  0;   27;     21;      0;           0;   16;      NUMERIC; SATELLITE SUB-LOCATION DIMENSIONS
+  0;   27;     31;      2;  -107341824;   31;       METERS; DIST FM EARTH CENTER IN DIR 0 DEG
+  0;   27;     41;      5;  -107341824;   31; METERS/SECOND; VEL W/RESP EARTH CTR N DIR 0 DEG
+  0;   28;      1;      5;   -18000000;   26;      DEGREES; LONGITUDE (HIGH ACCURACY)
+  0;   28;      2;      2;      -18000;   16;      DEGREES; LONGITUDE (COARSE ACCURACY)
+  0;   28;      3;      2;      -18000;   16;      DEGREES; ALTERNATE LONGITUDE
+  0;   28;     31;      2;  -107341824;   31;       METERS; DIST FMEARTH CENTER IN DIR 90 DEG
+  0;   28;     41;      5;  -107341824;   31; METERS/SECOND; VEL W/RESP EARTH CTR IN DIR 90 DE
+  0;   29;      1;      0;           0;    3;   CODE_TABLE; PROJECTION TYPE
+  0;   29;      2;      0;           0;    3;   CODE_TABLE; COORDINATE GRID TYPE
+  0;   30;      1;      0;           0;    4;      NUMERIC; PIXEL VALUE (4 BITS)
+  0;   30;     21;      0;           0;   12;      NUMERIC; NUMBER OF PIXELS PER ROW
+  0;   30;     22;      0;           0;   12;      NUMERIC; NUMBER OF PIXELS PER COLUMN
+  0;   30;     31;      0;           0;    4;   CODE_TABLE; PICTURE TYPE
+  0;   30;     32;      0;           0;   16;   FLAG_TABLE; COMBINED PICTURE
+  0;   31;      0;      0;           0;    1;   FLAG_TABLE; DELAYED REPLICATION SWITCH
+  0;   31;      1;      0;           0;    8;      NUMERIC; DELAYED DESCRIPTOR REPLICATION FA
+  0;   31;      2;      0;           0;   16;      NUMERIC; EXT DELAYED DESCRIPTOR REPLICAT.
+  0;   31;     11;      0;           0;    8;      NUMERIC; DELAYED DESC. & DATA REPITIT. FAC
+  0;   31;     12;      0;           0;   16;      NUMERIC; EXT DELAYED DESC. & DATA REPITIT.
+  0;   31;     21;      0;           0;    6;   CODE_TABLE; ASSOCIATED FIELD SIGNIFICANCE
+  0;   31;     31;      0;           0;    1;   FLAG_TABLE; DATA PRESENT INDICATOR
+  0;   31;    192;      0;           0;    9;   CODE_TABLE; NOAA WIND PROFILER HIGH/LOW MODE
+  0;   31;    193;      0;           0;    2;   CODE_TABLE; NOAA WIND PROFILER SUBMODE
+  0;   31;    194;      0;           0;    4;   CODE_TABLE; NOAA WIND PROFILER Q/C TEST RESUL
+  0;   33;      2;      0;           0;    2;   CODE_TABLE; QUALITY INFORMATION
+  0;   33;      3;      0;           0;    3;   CODE_TABLE; QUALITY INFORMATION
+  0;   33;      4;      0;           0;    7;            %; % CONFIDENCE
+  0;   33;    216;      0;           0;    4;   CODE_TABLE; SWQM SATELLITE WIND QUALITY MARK
+  0;   50;      1;      0;           0;   17;      NUMERIC; REPORT SEQUENCE NUMBER
+  0;   50;     20;      0;           0;    4;   CODE_TABLE; DATA QUALITY INDICATOR
+  0;   55;      6;      0;           0;   10;   CODE_TABLE; NMC REPORT TYPE
+  0;   58;      1;      0;           0;   48;    CCITT_IA5; BULLETIN HEADING
+  0;   58;      2;      0;           0;   80;    CCITT_IA5; AIRCRAFT TYPE
+  0;   58;      3;      0;        -400;   17;          GPM; ICING BASE
+  0;   58;      4;      0;        -400;   17;          GPM; ICING TOP
+  0;   58;      5;      0;           0;  224;    CCITT_IA5; COMPLETE BULLETIN HEADER
+  0;   58;      6;      0;           0;   64;    CCITT_IA5; BULTIM BULLETIN HEADER DATE/TIME DATA
+  0;   58;      7;      0;           0;   24;    CCITT_IA5; BBB WMO BBB INDICATOR
+  0;   60;      1;      0;           0;    7;            %; PROB. OF LIQ PCPN GE .01 INCH PAS
+  0;   60;      2;      0;           0;    7;            %; PROB. OF LIQ PCPN GE .01 INCH PAS
+  0;   60;      3;      0;           0;    7;            %; PROB. OF LIQ PCPN GE .01 INCH PAS
+  0;   60;      4;      0;           0;    7;            %; PROB. OF LIQ PCPN GE .10 INCH PAS
+  0;   60;      5;      0;           0;    7;            %; PROB. OF LIQ PCPN GE .10 INCH PAS
+  0;   60;      6;      0;           0;    7;            %; PROB. OF LIQ PCPN GE .10 INCH PAS
+  0;   60;      7;      0;           0;    7;            %; PROB. OF LIQ PCPN GE .25 INCH PAS
+  0;   60;      8;      0;           0;    7;            %; PROB. OF LIQ PCPN GE .25 INCH PAS
+  0;   60;      9;      0;           0;    7;            %; PROB. OF LIQ PCPN GE .25 INCH PAS
+  0;   60;     10;      0;           0;    7;            %; PROB. OF LIQ PCPN GE .50 INCH PAS
+  0;   60;     11;      0;           0;    7;            %; PROB. OF LIQ PCPN GE .50 INCH PAS
+  0;   60;     12;      0;           0;    7;            %; PROB. OF LIQ PCPN GE .50 INCH PAS
+  0;   60;     13;      0;           0;    7;            %; PROB. OF LIQ PCP GE 1.00 INCH PAS
+  0;   60;     14;      0;           0;    7;            %; PROB. OF LIQ PCP GE 1.00 INCH PAS
+  0;   60;     15;      0;           0;    7;            %; PROB. OF LIQ PCP GE 1.00 INCH PAS
+  0;   60;     16;      0;           0;    7;            %; PROB. OF LIQ PCP GE 2.00 INCH PAS
+  0;   60;     17;      0;           0;    7;            %; PROB. OF LIQ PCP GE 2.00 INCH PAS
+  0;   60;     18;      0;           0;    7;            %; REL FRQ GE .01 LQ EQV PCP PAST 12
+  0;   60;     19;      0;           0;    7;            %; REL FRQ GE .01 LQ EQV PCP PAST 24
+  0;   60;     20;      0;           0;    7;            %; COND PROB PCP TYPE FREEZING
+  0;   60;     21;      0;           0;    7;            %; COND PROB PCP TYPE SNOW
+  0;   60;     22;      0;           0;    7;            %; COND PROB PCP TYPE LIQUID
+  0;   60;     23;      0;           0;    7;            %; COND PROB PCP TYPE DRIZZLE
+  0;   60;     24;      0;           0;    7;            %; COND PROB PCP TYPE CONTINUOUS
+  0;   60;     25;      0;           0;    7;            %; COND PROB PCP TYPE SHOWERS
+  0;   60;     26;      0;           0;    7;            %; PROB SNOW AMT GE TRACE PAST 6HRS
+  0;   60;     27;      0;           0;    7;            %; PROB SNOW AMT GE TRACE PAST 12HRS
+  0;   60;     28;      0;           0;    7;            %; PROB SNOW AMT GE TRACE PAST 24HRS
+  0;   60;     29;      0;           0;    7;            %; PROB SNOW AMT GE 2.0IN PAST 6HRS
+  0;   60;     30;      0;           0;    7;            %; PROB SNOW AMT GE 2.0IN PAST 12HRS
+  0;   60;     31;      0;           0;    7;            %; PROB SNOW AMT GE 2.0IN PAST 24HRS
+  0;   60;     32;      0;           0;    7;            %; PROB SNOW AMT GE 4.0IN PAST 12HRS
+  0;   60;     33;      0;           0;    7;            %; PROB SNOW AMT GE 4.0IN PAST 24HRS
+  0;   60;     34;      0;           0;    7;            %; PROB SNOW AMT GE 6.0IN PAST 12HRS
+  0;   60;     35;      0;           0;    7;            %; PROB SNOW AMT GE 6.0IN PAST 24HRS
+  0;   60;     36;      0;           0;    7;            %; COND PROB SNOW PAST 12 HRS
+  0;   60;     37;      0;           0;    7;            %; COND REL FRQ PROB SNOW PAST 12 HR
+  0;   60;     38;      0;           0;    7;            %; PROB OPAQUE SKY COVER  CLEAR
+  0;   60;     39;      0;           0;    7;            %; PROB OPAQUE SKY COVER  SCATTERED
+  0;   60;     40;      0;           0;    7;            %; PROB OPAQUE SKY COVER  BROKEN
+  0;   60;     41;      0;           0;    7;            %; PROB OPAQUE SKY COVER  OVERCAST
+  0;   60;     42;      0;           0;    7;            %; PROB CIG HGT < 200 FT
+  0;   60;     43;      0;           0;    7;            %; PROB CIG HGT 200-400 FT
+  0;   60;     44;      0;           0;    7;            %; PROB CIG HGT 500-900 FT
+  0;   60;     45;      0;           0;    7;            %; PROB CIG HGT 1000-3000 FT
+  0;   60;     46;      0;           0;    7;            %; PROB CIG HGT 3100-6500 FT
+  0;   60;     47;      0;           0;    7;            %; PROB CIG HGT 6600-12000 FT
+  0;   60;     48;      0;           0;    7;            %; PROB CIG HGT GT 12000 FT
+  0;   60;     49;      0;           0;    7;            %; PROB VSBY < 0/2 MILES
+  0;   60;     50;      0;           0;    7;            %; PROB VSBY < 0/2 - 7/8 MILES
+  0;   60;     51;      0;           0;    7;            %; PROB VSBY < 0 - 2 3/4 MILES
+  0;   60;     52;      0;           0;    7;            %; PROB VSBY < 3 - 5 MILES
+  0;   60;     53;      0;           0;    7;            %; PROB VSBY > 5   MILES
+  0;   60;     54;      0;           0;    7;            %; PROB OBS TO VISION  BLOWING PHENO
+  0;   60;     55;      0;           0;    7;            %; PROB OBS TO VISION  HAZE
+  0;   60;     56;      0;           0;    7;            %; PROB OBS TO VISION  FOG
+  0;   60;     57;      0;           0;    7;            %; PROB OBS TO VISION  NONE
+  0;   60;     58;      0;           0;    7;            %; PROB TSTM PAST 6 HRS
+  0;   60;     59;      0;           0;    7;            %; PROB TSTM PAST 12HRS
+  0;   60;     60;      0;           0;    7;            %; PROB TSTM PAST 24HRS
+  0;   60;     61;      0;           0;    7;            %; PROB SVR WX PAST 6 HRS
+  0;   60;     62;      0;           0;    7;            %; PROB SVR WX PAST 12HRS
+  0;   60;     63;      0;           0;    7;            %; PROB SVR WX PAST 24HRS
+  0;   60;     64;      0;           0;    7;            %; CLIM AVG CLD COVER (OPAQUE)
+  0;   60;     65;      1;           0;   12; METERS/SECOND; CLIMATIC WIND SPEED
+  0;   60;     66;      1;           0;   12; DEGREES_KELVIN; CLIMATIC(NORMAL) DAY MAX TEMP
+  0;   60;     67;      1;           0;   12; DEGREES_KELVIN; CLIMATIC(NORMAL) NIGHT MIN TEMP
+  0;   60;     90;      0;           0;    4;   CODE_TABLE; QUANT PCP FCST (CATEGORIES)
+  0;   60;     91;      0;           0;    3;   CODE_TABLE; COND PCP TYPE FCST (CATS)
+  0;   60;     92;      0;           0;    3;   CODE_TABLE; COND PCP CHARACTER FCST (CATS)
+  0;   60;     93;      0;           0;    3;   CODE_TABLE; QUANT SNOW AMT FCST (CATS)
+  0;   60;     94;      0;           0;    4;   CODE_TABLE; CIG HEIGHT FCST (CATS)
+  0;   60;     95;      0;           0;    3;   CODE_TABLE; VISIBILITY FCST (CATS)
+  0;   60;     96;      0;           0;    3;   CODE_TABLE; OBSTRUCT TO VISION FCST (CATS)
+  0;   60;     97;      0;           0;    2;   CODE_TABLE; THUNDERSTORM FCST (CATS)
+  0;   60;     98;      0;           0;    2;   CODE_TABLE; SEVERE WEATHER FCST (CATS)
+  0;   63;      0;      0;           0;   16;        BYTES; BIT COUNT
+  0;   63;    255;      0;           0;    1;      NUMERIC; FILL BIT
diff --git a/data/tables/B2M-000-002-D b/data/tables/B2M-000-002-D
new file mode 100644
index 0000000..712d71c
--- /dev/null
+++ b/data/tables/B2M-000-002-D
@@ -0,0 +1,1878 @@
+3	0	2 
+	0	0	2 
+	0	0	3 
+	-1 
+ 
+3	0	3 
+	0	0	10 
+	0	0	11 
+	0	0	12 
+	-1 
+ 
+3	0	4 
+	3	0	3 
+	0	0	13 
+	0	0	14 
+	0	0	15 
+	0	0	16 
+	0	0	17 
+	0	0	18 
+	0	0	19 
+	0	0	20 
+	-1 
+ 
+3	0	10 
+	3	0	3 
+	1	1	0 
+	0	31	1 
+	0	0	30 
+	-1 
+ 
+3	1	1 
+	0	1	1 
+	0	1	2 
+	-1 
+ 
+3	1	2 
+	0	1	3 
+	0	1	4 
+	0	1	5 
+	-1 
+ 
+3	1	3 
+	0	1	11 
+	0	1	12 
+	0	1	13 
+	-1 
+ 
+3	1	11 
+	0	4	1 
+	0	4	2 
+	0	4	3 
+	-1 
+ 
+3	1	12 
+	0	4	4 
+	0	4	5 
+	-1 
+ 
+3	1	13 
+	3	1	12 
+	0	4	6 
+	-1 
+ 
+3	1	21 
+	0	5	1 
+	0	6	1 
+	-1 
+ 
+3	1	22 
+	3	1	21 
+	0	7	1 
+	-1 
+ 
+3	1	23 
+	0	5	2 
+	0	6	2 
+	-1 
+ 
+3	1	24 
+	3	1	23 
+	0	7	1 
+	-1 
+ 
+3	1	25 
+	3	1	23 
+	0	4	3 
+	3	1	12 
+	-1 
+ 
+3	1	26 
+	3	1	21 
+	0	4	3 
+	0	4	3 
+	0	4	4 
+	0	4	4 
+	0	4	5 
+	0	4	5 
+	-1 
+ 
+3	1	31 
+	3	1	1 
+	0	2	1 
+	3	1	11 
+	3	1	12 
+	3	1	22 
+	-1 
+ 
+3	1	32 
+	3	1	1 
+	0	2	1 
+	3	1	11 
+	3	1	12 
+	3	1	24 
+	-1 
+ 
+3	1	33 
+	0	1	5 
+	0	2	1 
+	3	1	11 
+	3	1	12 
+	3	1	21 
+	-1 
+ 
+3	1	34 
+	0	1	5 
+	0	2	1 
+	3	1	11 
+	3	1	12 
+	3	1	23 
+	-1 
+ 
+3	1	35 
+	0	1	5 
+	0	1	12 
+	0	1	13 
+	0	2	1 
+	3	1	11 
+	3	1	12 
+	3	1	23 
+	-1 
+ 
+3	1	36 
+	3	1	3 
+	0	2	1 
+	3	1	11 
+	3	1	12 
+	3	1	23 
+	-1 
+ 
+3	1	37 
+	3	1	1 
+	0	2	11 
+	0	2	12 
+	3	1	11 
+	3	1	12 
+	3	1	22 
+	-1 
+ 
+3	1	38 
+	3	1	1 
+	0	2	11 
+	0	2	12 
+	3	1	11 
+	3	1	12 
+	3	1	24 
+	-1 
+ 
+3	1	39 
+	3	1	3 
+	0	1	11 
+	0	1	12 
+	3	1	11 
+	3	1	12 
+	3	1	23 
+	-1 
+ 
+3	1	40 
+	3	1	3 
+	0	2	11 
+	0	2	12 
+	3	1	11 
+	3	1	12 
+	3	1	24 
+	-1 
+ 
+3	1	41 
+	0	1	7 
+	0	2	21 
+	0	2	22 
+	3	1	11 
+	3	1	12 
+	-1 
+ 
+3	1	42 
+	3	1	41 
+	3	1	21 
+	-1 
+ 
+3	1	43 
+	0	1	7 
+	0	2	23 
+	3	1	11 
+	3	1	13 
+	3	1	21 
+	-1 
+ 
+3	1	44 
+	0	1	7 
+	0	2	24 
+	3	1	11 
+	3	1	13 
+	3	1	21 
+	-1 
+ 
+3	1	51 
+	0	1	6 
+	0	2	61 
+	3	1	11 
+	3	1	12 
+	3	1	21 
+	0	8	4 
+	-1 
+ 
+3	1	62 
+	1	1	0 
+	0	31	1 
+	3	1	1 
+	-1 
+ 
+3	1	190 
+	0	4	192 
+	0	4	193 
+	-1 
+ 
+3	1	191 
+	0	8	192 
+	0	8	193 
+	0	8	194 
+	0	8	195 
+	0	8	196 
+	-1 
+ 
+3	1	192 
+	3	1	11 
+	0	4	4 
+	3	1	23 
+	-1 
+ 
+3	2	1 
+	0	10	4 
+	0	10	51 
+	0	10	61 
+	0	10	63 
+	-1 
+ 
+3	2	2 
+	0	10	4 
+	0	7	4 
+	0	10	3 
+	0	10	61 
+	0	10	63 
+	-1 
+ 
+3	2	3 
+	0	11	11 
+	0	11	12 
+	0	12	4 
+	0	12	6 
+	0	13	3 
+	0	20	1 
+	0	20	3 
+	0	20	4 
+	0	20	5 
+	-1 
+ 
+3	2	4 
+	0	20	10 
+	0	8	2 
+	0	20	11 
+	0	20	13 
+	0	20	12 
+	0	20	12 
+	0	20	12 
+	-1 
+ 
+3	2	5 
+	0	8	2 
+	0	20	11 
+	0	20	12 
+	0	20	13 
+	-1 
+ 
+3	2	11 
+	3	2	1 
+	3	2	3 
+	3	2	4 
+	-1 
+ 
+3	2	12 
+	3	2	2 
+	3	2	3 
+	3	2	4 
+	-1 
+ 
+3	2	21 
+	0	22	1 
+	0	22	11 
+	0	22	21 
+	-1 
+ 
+3	2	22 
+	0	22	2 
+	0	22	12 
+	0	22	22 
+	-1 
+ 
+3	2	23 
+	0	22	3 
+	0	22	13 
+	0	22	23 
+	-1 
+ 
+3	2	24 
+	3	2	22 
+	3	2	23 
+	3	2	23 
+	-1 
+ 
+3	2	190 
+	0	10	51 
+	0	10	61 
+	0	10	63 
+	0	11	1 
+	0	11	2 
+	0	12	1 
+	0	12	3 
+	-1 
+ 
+3	2	191 
+	0	12	11 
+	0	12	12 
+	0	20	62 
+	0	20	63 
+	-1 
+ 
+3	2	192 
+	0	20	1 
+	3	2	193 
+	-1 
+ 
+3	2	193 
+	0	20	1 
+	3	2	197 
+	-1 
+ 
+3	2	194 
+	0	4	31 
+	0	13	11 
+	-1 
+ 
+3	2	195 
+	0	2	2 
+	0	11	41 
+	0	10	52 
+	0	4	31 
+	0	13	12 
+	0	13	13 
+	0	10	192 
+	0	10	62 
+	-1 
+ 
+3	2	196 
+	0	10	4 
+	3	2	193 
+	-1 
+ 
+3	2	197 
+	0	20	3 
+	0	20	4 
+	0	20	5 
+	-1 
+ 
+3	2	199 
+	3	1	32 
+	3	1	190 
+	3	1	191 
+	3	2	190 
+	-1 
+ 
+3	3	1 
+	0	7	3 
+	0	11	1 
+	0	11	2 
+	-1 
+ 
+3	3	2 
+	0	7	4 
+	0	11	1 
+	0	11	2 
+	-1 
+ 
+3	3	3 
+	0	7	4 
+	0	10	3 
+	0	12	1 
+	0	12	3 
+	-1 
+ 
+3	3	4 
+	3	3	3 
+	0	11	1 
+	0	11	2 
+	-1 
+ 
+3	3	11 
+	0	7	3 
+	0	8	1 
+	0	11	1 
+	0	11	2 
+	-1 
+ 
+3	3	12 
+	0	7	4 
+	0	8	1 
+	0	11	1 
+	0	11	2 
+	-1 
+ 
+3	3	13 
+	0	7	4 
+	0	8	1 
+	0	10	3 
+	0	12	1 
+	0	13	3 
+	0	11	1 
+	0	11	2 
+	-1 
+ 
+3	3	14 
+	0	7	4 
+	0	8	1 
+	0	10	3 
+	0	12	1 
+	0	12	3 
+	0	11	1 
+	0	11	2 
+	-1 
+ 
+3	3	21 
+	0	7	4 
+	0	7	4 
+	2	4	7 
+	0	31	21 
+	-1 
+ 
+3	3	22 
+	3	3	21 
+	0	10	3 
+	2	4	0 
+	-1 
+ 
+3	3	23 
+	3	3	21 
+	0	12	1 
+	2	4	0 
+	-1 
+ 
+3	3	24 
+	3	3	21 
+	0	13	16 
+	2	4	0 
+	-1 
+ 
+3	3	25 
+	0	2	25 
+	2	4	7 
+	0	31	21 
+	0	12	63 
+	2	4	0 
+	-1 
+ 
+3	3	26 
+	0	7	4 
+	0	8	3 
+	2	4	7 
+	0	31	21 
+	0	12	1 
+	2	4	0 
+	-1 
+ 
+3	3	27 
+	0	7	4 
+	2	4	7 
+	0	31	21 
+	0	10	3 
+	2	4	0 
+	-1 
+ 
+3	3	31 
+	0	7	4 
+	0	8	3 
+	0	7	21 
+	0	7	22 
+	0	8	12 
+	0	12	61 
+	-1 
+ 
+3	3	32 
+	0	20	11 
+	0	20	16 
+	-1 
+ 
+3	3	192 
+	0	1	7 
+	3	1	11 
+	3	1	13 
+	3	1	23 
+	3	3	193 
+	3	3	194 
+	3	3	195 
+	3	3	196 
+	3	3	197 
+	-1 
+ 
+3	3	193 
+	0	5	22 
+	0	8	12 
+	0	12	61 
+	0	8	3 
+	0	7	4 
+	0	2	22 
+	0	27	20 
+	0	22	42 
+	0	8	3 
+	-1 
+ 
+3	3	194 
+	1	3	15 
+	0	7	4 
+	0	7	4 
+	0	12	7 
+	0	8	3 
+	1	3	3 
+	0	7	4 
+	0	7	4 
+	0	13	16 
+	0	8	3 
+	-1 
+ 
+3	3	195 
+	0	7	4 
+	0	12	7 
+	0	8	3 
+	0	15	1 
+	0	8	3 
+	0	7	4 
+	0	20	10 
+	0	2	21 
+	-1 
+ 
+3	3	196 
+	1	1	20 
+	0	12	62 
+	0	2	21 
+	1	1	4 
+	0	12	62 
+	0	2	21 
+	-1 
+ 
+3	3	197 
+	1	1	3 
+	0	12	62 
+	1	3	20 
+	0	10	4 
+	0	12	7 
+	0	10	2 
+	1	2	5 
+	0	10	4 
+	0	12	3 
+	-1 
+ 
+3	4	1 
+	0	8	3 
+	0	10	4 
+	0	12	1 
+	0	11	1 
+	0	11	2 
+	-1 
+ 
+3	4	2 
+	0	8	3 
+	0	10	4 
+	0	11	1 
+	0	11	2 
+	-1 
+ 
+3	4	3 
+	0	8	3 
+	0	12	1 
+	-1 
+ 
+3	4	4 
+	0	8	3 
+	0	10	4 
+	0	20	10 
+	0	12	1 
+	-1 
+ 
+3	4	5 
+	0	2	24 
+	0	7	4 
+	0	7	4 
+	0	13	3 
+	-1 
+ 
+3	4	6 
+	0	14	1 
+	0	14	1 
+	0	14	3 
+	-1 
+ 
+3	6	1 
+	0	2	32 
+	1	2	0 
+	0	31	1 
+	0	7	62 
+	0	22	42 
+	-1 
+ 
+3	6	2 
+	0	2	31 
+	0	22	4 
+	0	22	31 
+	-1 
+ 
+3	6	3 
+	0	2	2 
+	0	11	11 
+	0	11	12 
+	0	12	4 
+	-1 
+ 
+3	6	4 
+	0	2	32 
+	0	2	33 
+	1	3	0 
+	0	31	1 
+	0	7	62 
+	0	22	42 
+	0	22	62 
+	-1 
+ 
+3	6	5 
+	0	2	31 
+	1	3	0 
+	0	31	1 
+	0	7	62 
+	0	22	4 
+	0	22	31 
+	-1 
+ 
+3	6	6 
+	3	6	3 
+	3	6	2 
+	0	22	63 
+	-1 
+ 
+3	6	7 
+	0	1	12 
+	0	1	14 
+	3	6	8 
+	0	4	24 
+	0	27	3 
+	0	28	3 
+	-1 
+ 
+3	6	8 
+	0	2	34 
+	0	2	35 
+	0	2	36 
+	-1 
+ 
+3	6	9 
+	0	10	4 
+	0	10	61 
+	0	10	63 
+	0	11	1 
+	0	11	2 
+	0	12	4 
+	0	13	3 
+	0	22	42 
+	-1 
+ 
+3	7	1 
+	3	1	31 
+	3	2	11 
+	-1 
+ 
+3	7	2 
+	3	1	32 
+	3	2	11 
+	-1 
+ 
+3	7	3 
+	3	7	1 
+	1	1	0 
+	0	31	1 
+	3	2	5 
+	-1 
+ 
+3	7	4 
+	3	7	2 
+	1	1	0 
+	0	31	1 
+	3	2	5 
+	-1 
+ 
+3	7	5 
+	3	7	1 
+	1	1	4 
+	3	2	5 
+	-1 
+ 
+3	7	6 
+	3	7	2 
+	1	1	4 
+	3	2	5 
+	-1 
+ 
+3	7	7 
+	3	1	31 
+	3	2	12 
+	-1 
+ 
+3	7	8 
+	3	1	32 
+	3	2	12 
+	-1 
+ 
+3	7	192 
+	0	20	11 
+	0	20	12 
+	0	20	13 
+	-1 
+ 
+3	7	193 
+	3	2	199 
+	0	20	1 
+	0	20	10 
+	0	12	11 
+	0	12	12 
+	0	20	62 
+	3	2	194 
+	-1 
+ 
+3	7	194 
+	3	2	199 
+	0	20	1 
+	3	2	4 
+	3	2	5 
+	3	2	191 
+	3	2	194 
+	-1 
+ 
+3	7	195 
+	3	2	199 
+	0	10	4 
+	3	2	193 
+	3	2	4 
+	1	1	2 
+	3	2	5 
+	3	2	191 
+	3	2	194 
+	-1 
+ 
+3	7	196 
+	3	2	199 
+	3	2	196 
+	3	2	4 
+	1	1	4 
+	3	2	5 
+	3	2	191 
+	1	1	2 
+	3	2	194 
+	3	2	195 
+	-1 
+ 
+3	7	197 
+	3	2	199 
+	3	2	194 
+	-1 
+ 
+3	8	1 
+	3	1	33 
+	3	2	11 
+	0	22	42 
+	-1 
+ 
+3	8	2 
+	3	1	34 
+	3	2	11 
+	0	22	42 
+	-1 
+ 
+3	8	3 
+	3	1	35 
+	3	2	11 
+	0	22	42 
+	-1 
+ 
+3	8	4 
+	3	1	36 
+	3	2	11 
+	0	22	42 
+	-1 
+ 
+3	8	5 
+	3	8	4 
+	3	2	24 
+	-1 
+ 
+3	8	6 
+	0	10	4 
+	0	10	61 
+	0	10	63 
+	0	11	1 
+	0	11	2 
+	0	12	4 
+	0	13	3 
+	0	22	42 
+	-1 
+ 
+3	9	1 
+	3	1	37 
+	1	1	0 
+	0	31	1 
+	3	3	11 
+	-1 
+ 
+3	9	2 
+	3	1	38 
+	1	1	0 
+	0	31	1 
+	3	3	11 
+	-1 
+ 
+3	9	3 
+	3	1	37 
+	1	1	0 
+	0	31	1 
+	3	3	12 
+	-1 
+ 
+3	9	4 
+	3	1	38 
+	1	1	0 
+	0	31	1 
+	3	3	12 
+	-1 
+ 
+3	9	5 
+	3	1	37 
+	3	2	4 
+	1	1	0 
+	0	31	1 
+	3	3	13 
+	-1 
+ 
+3	9	6 
+	3	1	38 
+	3	2	4 
+	1	1	0 
+	0	31	1 
+	3	3	13 
+	-1 
+ 
+3	9	7 
+	3	1	4 
+	3	2	4 
+	1	1	0 
+	0	31	1 
+	3	3	14 
+	-1 
+ 
+3	9	8 
+	3	1	38 
+	3	2	4 
+	1	1	0 
+	0	31	1 
+	3	3	14 
+	-1 
+ 
+3	9	11 
+	3	1	39 
+	1	1	0 
+	0	31	1 
+	3	3	11 
+	-1 
+ 
+3	9	12 
+	3	1	39 
+	1	1	0 
+	0	31	1 
+	3	3	12 
+	-1 
+ 
+3	9	13 
+	3	1	39 
+	3	2	4 
+	1	1	0 
+	0	31	1 
+	3	3	13 
+	-1 
+ 
+3	9	14 
+	3	1	39 
+	3	2	4 
+	1	1	0 
+	0	31	1 
+	3	3	14 
+	-1 
+ 
+3	9	15 
+	3	9	16 
+	3	9	17 
+	3	9	18 
+	-1 
+ 
+3	9	16 
+	3	1	40 
+	1	1	0 
+	0	31	1 
+	3	3	12 
+	-1 
+ 
+3	9	17 
+	3	1	40 
+	3	2	4 
+	1	1	0 
+	0	31	1 
+	3	3	13 
+	-1 
+ 
+3	9	18 
+	3	1	40 
+	3	2	4 
+	1	1	0 
+	0	31	1 
+	3	3	14 
+	-1 
+ 
+3	9	19 
+	3	1	31 
+	0	2	3 
+	1	1	0 
+	0	31	1 
+	3	3	11 
+	-1 
+ 
+3	9	20 
+	3	1	31 
+	0	2	3 
+	1	4	0 
+	0	31	1 
+	0	7	3 
+	0	11	3 
+	0	11	4 
+	0	11	5 
+	-1 
+ 
+3	10	1 
+	3	1	42 
+	3	3	31 
+	3	3	32 
+	1	1	26 
+	3	3	25 
+	-1 
+ 
+3	10	2 
+	3	1	42 
+	3	3	31 
+	3	3	32 
+	1	1	9 
+	3	3	23 
+	-1 
+ 
+3	10	3 
+	3	1	42 
+	3	3	31 
+	3	3	32 
+	1	1	6 
+	3	3	23 
+	-1 
+ 
+3	10	4 
+	3	1	42 
+	3	3	31 
+	3	3	32 
+	1	1	3 
+	3	3	24 
+	-1 
+ 
+3	11	1 
+	3	1	51 
+	0	7	2 
+	0	12	1 
+	0	11	1 
+	0	11	2 
+	0	11	31 
+	0	11	32 
+	0	11	33 
+	0	20	41 
+	-1 
+ 
+3	12	1 
+	3	1	43 
+	3	4	1 
+	-1 
+ 
+3	12	2 
+	3	1	43 
+	3	4	2 
+	-1 
+ 
+3	12	3 
+	3	1	42 
+	3	4	3 
+	-1 
+ 
+3	12	4 
+	3	1	42 
+	3	4	4 
+	-1 
+ 
+3	12	5 
+	3	1	42 
+	0	20	14 
+	-1 
+ 
+3	12	6 
+	3	1	42 
+	3	4	5 
+	-1 
+ 
+3	12	7 
+	3	1	42 
+	3	4	6 
+	-1 
+ 
+3	12	10 
+	0	1	7 
+	0	5	40 
+	0	2	21 
+	0	5	41 
+	0	4	1 
+	0	4	43 
+	-1 
+ 
+3	12	11 
+	2	2	131 
+	2	1	149 
+	0	4	6 
+	2	1	0 
+	2	2	132 
+	0	10	2 
+	2	2	0 
+	0	5	43 
+	0	5	53 
+	-1 
+ 
+3	12	12 
+	2	2	130 
+	2	1	132 
+	1	1	19 
+	0	12	63 
+	2	1	0 
+	2	2	0 
+	-1 
+ 
+3	12	13 
+	0	5	42 
+	2	2	130 
+	2	1	135 
+	0	12	63 
+	2	1	0 
+	2	2	0 
+	-1 
+ 
+3	12	14 
+	3	12	10 
+	3	12	11 
+	1	5	56 
+	3	1	23 
+	0	5	42 
+	0	5	52 
+	3	12	12 
+	3	12	13 
+	-1 
+ 
+3	12	15 
+	1	9	11 
+	3	1	23 
+	0	5	42 
+	0	5	52 
+	2	2	129 
+	2	1	132 
+	1	1	4 
+	0	12	63 
+	2	2	0 
+	2	1	0 
+	-1 
+ 
+3	12	16 
+	3	12	10 
+	3	12	11 
+	3	12	15 
+	-1 
+ 
+3	12	17 
+	1	9	8 
+	3	1	23 
+	0	5	42 
+	0	5	52 
+	2	2	129 
+	2	1	132 
+	1	1	3 
+	0	12	63 
+	2	2	0 
+	2	1	0 
+	-1 
+ 
+3	12	18 
+	3	12	10 
+	3	12	11 
+	3	12	17 
+	-1 
+ 
+3	13	9 
+	0	21	1 
+	1	1	0 
+	0	31	1 
+	0	21	1 
+	-1 
+ 
+3	13	10 
+	0	21	36 
+	1	1	0 
+	0	31	1 
+	0	21	36 
+	-1 
+ 
+3	13	31 
+	0	6	2 
+	0	6	12 
+	1	1	0 
+	0	31	2 
+	0	30	1 
+	-1 
+ 
+3	13	32 
+	0	5	2 
+	0	5	12 
+	1	1	0 
+	0	31	2 
+	3	13	31 
+	-1 
+ 
+3	13	41 
+	0	6	2 
+	0	6	12 
+	1	6	0 
+	0	31	1 
+	1	1	0 
+	0	31	11 
+	0	30	1 
+	1	1	0 
+	0	31	1 
+	0	30	1 
+	-1 
+ 
+3	13	42 
+	0	5	2 
+	0	5	12 
+	1	1	0 
+	0	31	2 
+	3	13	41 
+	-1 
+ 
+3	15	1 
+	0	8	3 
+	3	1	11 
+	3	1	12 
+	3	1	23 
+	3	6	1 
+	-1 
+ 
+3	15	2 
+	0	8	3 
+	3	1	11 
+	3	1	12 
+	3	1	23 
+	3	6	4 
+	-1 
+ 
+3	16	1 
+	3	1	192 
+	0	1	21 
+	0	2	41 
+	0	19	1 
+	0	10	51 
+	0	19	2 
+	0	19	3 
+	0	19	4 
+	-1 
+ 
+3	18	1 
+	3	1	25 
+	0	24	11 
+	-1 
+ 
+3	18	3 
+	3	1	26 
+	0	24	5 
+	0	24	4 
+	0	24	21 
+	-1 
+ 
+3	18	4 
+	3	1	25 
+	0	4	31 
+	0	13	11 
+	0	24	5 
+	0	24	4 
+	0	24	22 
+	-1 
+ 
+3	21	1 
+	0	2	101 
+	0	2	114 
+	0	2	105 
+	0	2	106 
+	0	2	107 
+	0	2	121 
+	-1 
+ 
+3	21	3 
+	0	21	51 
+	0	21	14 
+	0	21	17 
+	0	21	30 
+	-1 
+ 
+3	21	4 
+	3	1	31 
+	0	2	3 
+	1	1	0 
+	0	31	1 
+	3	21	3 
+	-1 
+ 
+3	21	5 
+	0	25	4 
+	0	2	121 
+	0	2	122 
+	0	2	123 
+	0	2	124 
+	0	2	125 
+	0	2	126 
+	0	2	127 
+	3	21	192 
+	-1 
+ 
+3	21	6 
+	0	25	1 
+	0	25	2 
+	0	25	3 
+	0	25	5 
+	-1 
+ 
+3	21	7 
+	0	25	9 
+	0	25	10 
+	0	25	11 
+	0	25	12 
+	0	25	13 
+	0	25	15 
+	0	25	16 
+	0	25	17 
+	-1 
+ 
+3	21	8 
+	0	25	6 
+	0	25	7 
+	0	25	8 
+	-1 
+ 
+3	21	9 
+	0	25	18 
+	0	25	19 
+	-1 
+ 
+3	21	10 
+	0	2	101 
+	0	7	2 
+	0	2	102 
+	0	2	103 
+	0	2	104 
+	0	2	105 
+	0	2	106 
+	0	2	107 
+	0	2	108 
+	3	21	193 
+	-1 
+ 
+3	21	11 
+	0	30	31 
+	0	30	32 
+	0	29	2 
+	-1 
+ 
+3	21	12 
+	1	1	0 
+	0	31	1 
+	0	2	135 
+	-1 
+ 
+3	21	192 
+	0	2	128 
+	0	2	129 
+	0	2	130 
+	0	2	131 
+	-1 
+ 
+3	21	193 
+	0	2	109 
+	0	2	110 
+	0	2	132 
+	0	2	133 
+	-1 
+ 
+3	55	1 
+	3	55	4 
+	3	55	5 
+	0	12	192 
+	0	12	1 
+	0	11	1 
+	0	11	2 
+	0	2	61 
+	0	10	194 
+	-1 
+ 
+3	55	2 
+	0	11	31 
+	0	11	32 
+	0	11	33 
+	-1 
+ 
+3	55	3 
+	0	20	41 
+	0	58	3 
+	0	58	4 
+	-1 
+ 
+3	55	4 
+	0	58	1 
+	0	58	2 
+	0	1	8 
+	0	1	6 
+	3	1	11 
+	3	1	12 
+	0	4	192 
+	0	4	193 
+	3	1	23 
+	-1 
+ 
+3	55	5 
+	0	2	43 
+	0	8	193 
+	0	8	194 
+	0	8	195 
+	0	8	196 
+	0	2	42 
+	0	7	192 
+	0	7	4 
+	-1 
+ 
+3	58	1 
+	0	58	1 
+	0	1	11 
+	0	1	8 
+	0	1	6 
+	3	1	11 
+	3	1	12 
+	0	4	192 
+	0	4	193 
+	3	58	2 
+	3	58	3 
+	-1 
+ 
+3	58	2 
+	0	2	43 
+	0	8	193 
+	0	8	194 
+	0	8	195 
+	0	8	196 
+	0	2	42 
+	0	7	192 
+	0	7	4 
+	0	8	4 
+	0	12	192 
+	-1 
+ 
+3	58	3 
+	0	12	1 
+	0	11	1 
+	0	11	2 
+	0	2	61 
+	0	10	194 
+	-1 
+ 
+3	58	4 
+	0	11	31 
+	0	11	32 
+	0	11	33 
+	-1 
+ 
+3	58	5 
+	0	20	41 
+	0	58	3 
+	0	58	4 
+	-1 
+ 
+3	59	1 
+	3	59	2 
+	3	59	3 
+	3	59	4 
+	3	59	5 
+	3	59	6 
+	3	59	7 
+	3	59	8 
+	-1 
+ 
+3	59	2 
+	0	58	1 
+	0	1	11 
+	3	1	11 
+	3	1	12 
+	3	1	23 
+	0	7	1 
+	-1 
+ 
+3	59	3 
+	0	4	192 
+	0	4	193 
+	0	8	193 
+	0	8	194 
+	0	8	195 
+	0	8	196 
+	0	2	2 
+	-1 
+ 
+3	59	4 
+	0	1	12 
+	0	1	13 
+	0	10	4 
+	0	10	51 
+	0	4	31 
+	0	10	63 
+	0	10	61 
+	0	10	62 
+	0	12	1 
+	0	12	3 
+	-1 
+ 
+3	59	5 
+	0	11	1 
+	0	11	2 
+	0	4	31 
+	0	11	41 
+	0	12	11 
+	0	12	12 
+	0	4	31 
+	0	13	11 
+	0	4	31 
+	0	13	11 
+	-1 
+ 
+3	59	6 
+	0	20	1 
+	0	20	3 
+	0	20	4 
+	0	20	5 
+	0	20	10 
+	0	20	63 
+	0	20	63 
+	0	8	2 
+	0	20	11 
+	0	10	13 
+	-1 
+ 
+3	59	7 
+	0	20	12 
+	0	20	12 
+	0	20	12 
+	1	4	4 
+	0	8	2 
+	0	20	11 
+	0	20	12 
+	0	20	13 
+	-1 
+ 
+3	59	8 
+	0	22	42 
+	0	22	12 
+	0	22	22 
+	1	1	2 
+	3	2	23 
+	0	20	31 
+	0	20	32 
+	0	20	32 
+	-1 
+ 
+3	60	1 
+	1       1       0
+        0       31      2
+	-1 
+ 
+3	60	2 
+	1       1       0
+        0       31      1
+	-1 
+ 
+3	60	3 
+	1       1       0
+        0       31      1 
+	-1 
+ 
+3	60	4 
+	1       1       0
+        0       31      0
+	-1 
+ 
+3	60	5 
+	0	4	31 
+	0	13	11 
+	0	40	31 
+	0	13	11 
+	0	40	31 
+	0	13	12 
+	0	13	13 
+	-1 
+ 
+3	60	6 
+	0	20	62 
+	0	20	3 
+	0	20	4 
+	0	20	5 
+	0	20	10 
+	0	20	63 
+	0	20	63 
+	-1 
+ 
+3	60	7 
+	0	20	1 
+	0	8	2 
+	0	20	11 
+	0	20	13 
+	0	20	12 
+	0	20	12 
+	0	20	12 
+	-1 
+ 
+3	60	8 
+	1	4	4 
+	0	8	2 
+	0	20	11 
+	0	20	12 
+	0	20	13 
+	0	22	42 
+	0	22	12 
+	0	22	22 
+	3	2	23 
+	0	2	1 
+	-1
+	
+3       62      61
+        0       4       1
+	0       4       2
+	0       4       3
+	0       4       4
+	0       4       5
+	-1
+
+3       62      62
+        0       5       2
+	0       6       2
+	0       7       4
+	0       12      1
+	0       11      1
+	0       11      2
+	0       10      7
+	0       33      216
+	0       1       204
+	-1
+	
+3       62      63
+        0       5       2
+	0       6       2
+	0       7       4
+	0       12      1
+	0       11      1
+	0       11      2
+        -1        
+
+3       63      1
+        0       1       164
+	0       1       194
+	0       1       63
+	0       58      6
+	0       58      7
+	-1
+	
+3       63      3
+        0       8       202
+	0       4       200
+	0       4       201
+	0       4       202
+	0       4       203
+	0       4       204
+	-1
+
+3       63      236
+        0       4       1
+        0       4       2
+        0       4       3
+        0       4       4
+        0       5       2
+        0       6       2
+        0       1       198
+	0       2       23
+	0       1       204
+	0       1       7
+	0       7       4
+	0       10      7
+	0       12      1
+	0       11      1
+	0       11      2
+	0       33      216
+	0       4       5
+	-1
+	
+3       63      237
+        0       4       1
+        0       4       2
+        0       4       3
+        0       4       4
+        0       5       2
+        0       6       2
+        0       1       198
+	0       2       23
+	0       12      4
+	0       1       7
+	0       7       4
+	0       10      7
+	0       12      1
+	0       11      1
+	0       11      2
+	0       33      216
+	0       4       5
+	-1
+
+3      63       238
+        0       4       1
+        0       4       2
+        0       4       3
+        0       4       4
+        0       5       2
+        0       6       2
+        0       1       198
+	0       2       23
+	0       12      4
+	0       1       7
+	0       7       4
+	0       10      7
+	0       12      1
+	0       11      1
+	0       11      2
+	0       33      216
+	0       4       5
+	-1
+
+3      63       239
+        0       4       1
+        0       4       2
+        0       4       3
+        0       4       4
+        0       5       2
+        0       6       2
+        0       1       198
+	0       2       23
+	0       12      4
+	0       1       7
+	0       7       4
+	0       10      7
+	0       12      1
+	0       11      1
+	0       11      2
+	0       33      216
+	0       4       5
+	-1
+	
+3       63      240
+        3       63      1
+	3       60      2
+	3       63      3
+	0       1       198
+	0       1       7
+	0       1       195
+	0       1       196
+	3       62      61
+	0       8       199
+	0       2       23
+	3       62      63
+	-1
+	
+3       63      241
+        3       63      1
+	3       60      2
+	3       63      3
+	0       1       198
+	0       1       7
+	0       1       195
+	0       1       196
+	3       62      61
+	0       8       199
+	0       2       23
+	3       62      63
+	-1
+
+3       63      242
+        3       63      1
+	3       60      2
+	3       63      3
+	0       1       198
+	0       1       7
+	0       1       195
+	0       1       196
+	3       62      61
+	0       8       199
+	0       2       23
+	3       62      63
+	-1
+	
+3       63      243
+        3       63      1
+	3       60      2
+	3       63      3
+	0       1       198
+	0       1       7
+	0       1       195
+	0       1       196
+	3       62      61
+	0       8       199
+	0       2       23
+	3       62      63
+	-1
+
+3       63      244
+        3       63      1
+	3       60      2
+	3       63      3
+	0       1       198
+	0       1       7
+	0       1       195
+	0       1       196
+	3       62      61
+	0       8       199
+	0       2       23
+	3       62      63
+	-1
+
+3       63      245
+        3       63      1
+	3       60      2
+	3       63      3
+	0       1       198
+	0       1       7
+	0       1       195
+	0       1       196
+	3       62      61
+	0       8       199
+	0       2       23
+	3       62      63
+	-1
+
+3       63      246
+        3       63      1
+	3       60      2
+	3       63      3
+	0       1       198
+	0       1       7
+	0       1       195
+	0       1       196
+	3       62      61
+	0       8       199
+	0       2       23
+	3       62      63
+	-1
+
+3       63      247
+        3       63      1
+	3       60      2
+	3       63      3
+	0       1       198
+	0       1       7
+	0       1       195
+	0       1       196
+	3       62      61
+	0       8       199
+	0       2       23
+	3       62      63
+	-1
+
+3       63      248
+        3       63      1
+	3       60      2
+	3       63      3
+	0       1       198
+	0       1       7
+	0       1       195
+	0       1       196
+	3       62      61
+	0       8       199
+	0       2       23
+	3       62      63
+	-1
+
+3       63      249
+        3       63      1
+	3       60      2
+	3       63      3
+	0       1       198
+	0       1       7
+	0       1       195
+	0       1       196
+	3       62      61
+	0       8       199
+	0       2       23
+	3       62      63
+	-1
+
+3       63      250
+        3       63      1
+	3       60      2
+	3       63      3
+	0       1       198
+	0       1       7
+	0       1       195
+	0       1       196
+	3       62      61
+	0       8       199
+	0       2       23
+	3       62      63
+	-1
+
+3       63      251
+        3       63      1
+	3       60      2
+	3       63      3
+	0       1       198
+	0       1       7
+	0       1       195
+	0       1       196
+	3       62      61
+	0       8       199
+	0       2       23
+	3       62      63
+	-1
diff --git a/data/tables/B2M-000-003-0 b/data/tables/B2M-000-003-0
new file mode 100644
index 0000000..b68ae8b
--- /dev/null
+++ b/data/tables/B2M-000-003-0
@@ -0,0 +1,308 @@
+##############################################################################
+# BUFR Table 0
+#
+#
+# Notes
+# -----
+#
+# * This table comes from GRIB Code Table 0 (Identification of center)
+#
+# * A value of 1 in the first column indicates a center that uses minor
+#   version numbers with local tables.  Since minor local table version
+#   numbers are stored in Section 1, Octet 18, the value in the first
+#   column must not be set if a center uses Section 1, Octet 18 for other
+#   purposes (i.e., ECMWF).
+#
+#
+##############################################################################
+
+0	  0	RESERVED
+
+# 1-9: WMCs
+
+0	  1	Melbourne
+0	  2	Melbourne
+0	  3	Melbourne
+0	  4	Moscow
+0	  5	Moscow
+0	  6	Moscow
+0	  7	US Weather Service - National Meteorological Center (NMC)
+0	  8	US National Weather Service Telecommunications Gateway (NWSTG)
+0	  9	Reserved for USA
+
+# 10-25: Centers in Region I
+
+0	 10	Cairo (RSMC/RAFC)
+0	 11	Cairo (RSMC/RAFC)
+0	 12	Dakar (RSMC/RAFC)
+0	 13	Dakar (RSMC/RAFC)
+0	 14	Nairobi (RSMC/RAFC)
+0	 15	Nairobi (RSMC/RAFC)
+0	 16	Antananarivo (RSMC)
+0	 17	Antananarivo (RSMC)
+0	 18	Tunis-Casablanca (RSMC/RAFC)
+0	 19	Tunis-Casablanca (RSMC/RAFC)
+0	 20	Las Palmas (RAFC)
+0	 21	Algiers (RSMC)
+0	 22	Lagos (RSMC)
+0	 23	Lagos (RSMC)
+0	 24	Reserved for other centers in Region I
+0	 25	Reserved for other centers in Region I
+
+# 26-40 Centers in Region II
+
+0	 26	Khabarovsk (RSMC)
+0	 27	Khabarovsk (RSMC)
+0	 28	New Delhi (RSMC/RAFC)
+0	 29	New Delhi (RSMC/RAFC)
+0	 30	Novosibirsk (RSMC)
+0	 31	Novosibirsk (RSMC)
+0	 32	Tashkent (RSMC)
+0	 33	Tashkent (RSMC)
+0	 34	Tokyo (RSMC), Japan Meteorological Agency
+0	 35	Tokyo (RSMC/RAFC)
+0	 36	Bangkok (RAFC)
+0	 37	Ulan Bator
+0	 38	Beijing (RSMC)
+0	 39	Beijing (RSMC)
+0	 40	Reserved for other centers in Region II
+
+# 41-50: Centers in Region III
+
+0	 41	Buenos Aires (RSMC/RAFC)
+0	 42	Buenos Aires (RSMC/RAFC)
+0	 43	Brasilia (RSMC/RAFC)
+0	 44	Brasilia (RSMC/RAFC)
+0	 45	Santiago
+0	 46	Brazilian Space Agency - INPE
+0	 47	Reserved for other centers in Region III
+0	 48	Reserved for other centers in Region III
+0	 49	Reserved for other centers in Region III
+0	 50	Reserved for other centers in Region III
+
+# 51-63: Centers in Region IV
+
+0	 51	Miami (RSMC/RAFC)
+0	 52	Miami (RSMC), National Hurricane Center
+0	 53	Montreal (RSMC)
+0	 54	Montreal (RSMC)
+0	 55	San Francisco
+0	 56	RESERVED
+0	 57	US Air Force - Air Force Global Weather Central (AFGWC)
+1	 58	Fleet Numerical Oceanography Center (FNOC), Monterey, CA, USA
+0	 59	The NOAA Forecast Systems Laboratory, Boulder, CO, USA
+0	 60	Reserved for other centers in Region IV
+0	 61	Reserved for other centers in Region IV
+0	 62	Reserved for other centers in Region IV
+0	 63	Reserved for other centers in Region IV
+
+# 64-73: Centers in Region V
+
+0	 64	Honolulu (RAFC)
+0	 65	Darwin (RSMC/RAFC)
+0	 66	Darwin (RSMC/RAFC)
+0	 67	Melbourne (RSMC)
+0	 68	RESERVED
+0	 69	Wellington (RSMC/RAFC)
+0	 70	Wellington (RSMC/RAFC)
+0	 71	Reserved for other centers in Region V
+0	 72	Reserved for other centers in Region V
+0	 73	Reserved for other centers in Region V
+
+# 74-98: Centers in Region VI
+
+0	 74	UK Meteorological Office - Bracknell
+0	 75	UK Meteorological Office - Bracknell
+0	 76	Moscow (RSMC/RAFC)
+0	 77	RESERVED
+0	 78	Offenbach (RSMC)
+0	 79	Offenbach (RSMC)
+0	 80	Rome (RSMC/RAFC)
+0	 81	Rome (RSMC/RAFC)
+0	 82	Norrkoping (RSMC)
+0	 83	Norrkoping (RSMC)
+0	 84	Paris (RAFC)
+0	 85	Toulouse
+0	 86	Helsinki
+0	 87	Belgrade
+0	 88	Oslo
+0	 89	Prague
+0	 90	Episkopi
+0	 91	Ankara
+0	 92	Francfort/Main (RAFC)
+0	 93	London (WAFC)
+0	 94	Copenhagen
+0	 95	Rota
+0	 96	Athens
+0	 97	European Space Agency (ESA)
+
+# ECMWF (Center 98) does not support minor local table version numbers
+# so DO NOT set the first value to 1.
+
+0	 98	European Center for Medium Range Weather Forecasts (ECMWF)(RSMC)
+0	 99	De Bilt
+
+# 100-127: RESERVED
+
+0	100	RESERVED
+0	101	RESERVED
+0	102	RESERVED
+0	103	RESERVED
+0	104	RESERVED
+0	105	RESERVED
+0	106	RESERVED
+0	107	RESERVED
+0	108	RESERVED
+0	109	RESERVED
+0	110	RESERVED
+0	111	RESERVED
+0	112	RESERVED
+0	113	RESERVED
+0	114	RESERVED
+0	115	RESERVED
+0	116	RESERVED
+0	117	RESERVED
+0	118	RESERVED
+0	119	RESERVED
+0	120	RESERVED
+0	121	RESERVED
+0	122	RESERVED
+0	123	RESERVED
+0	124	RESERVED
+0	125	RESERVED
+0	126	RESERVED
+0	127	RESERVED
+
+# 128-254: NATIONAL USE
+
+1	128	Naval Research Laboratory (NRL), Monterey CA
+0	129	CAST
+0	130	AFCCC
+0	131	PL
+0	132	ARL
+0	133	WES
+0	134	NATIONAL USE
+0	135	NATIONAL USE
+0	136	NATIONAL USE
+0	137	NATIONAL USE
+0	138	NATIONAL USE
+0	139	NATIONAL USE
+0	140	NATIONAL USE
+0	141	NATIONAL USE
+0	142	NATIONAL USE
+0	143	NATIONAL USE
+0	144	NATIONAL USE
+0	145	NATIONAL USE
+0	146	NATIONAL USE
+0	147	NATIONAL USE
+0	148	NATIONAL USE
+0	149	NATIONAL USE
+0	150	NATIONAL USE
+0	151	NATIONAL USE
+0	152	NATIONAL USE
+0	153	NATIONAL USE
+0	154	NATIONAL USE
+0	155	NATIONAL USE
+0	156	NATIONAL USE
+0	157	NATIONAL USE
+0	158	NATIONAL USE
+0	159	NATIONAL USE
+0	160	NATIONAL USE
+0	161	NATIONAL USE
+0	162	NATIONAL USE
+0	163	NATIONAL USE
+0	164	NATIONAL USE
+0	165	NATIONAL USE
+0	166	NATIONAL USE
+0	167	NATIONAL USE
+0	168	NATIONAL USE
+0	169	NATIONAL USE
+0	170	NATIONAL USE
+0	171	NATIONAL USE
+0	172	NATIONAL USE
+0	173	NATIONAL USE
+0	174	NATIONAL USE
+0	175	NATIONAL USE
+0	176	NATIONAL USE
+0	177	NATIONAL USE
+0	178	NATIONAL USE
+0	179	NATIONAL USE
+0	180	NATIONAL USE
+0	181	NATIONAL USE
+0	182	NATIONAL USE
+0	183	NATIONAL USE
+0	184	NATIONAL USE
+0	185	NATIONAL USE
+0	186	NATIONAL USE
+0	187	NATIONAL USE
+0	188	NATIONAL USE
+0	189	NATIONAL USE
+0	190	NATIONAL USE
+0	191	NATIONAL USE
+0	192	NATIONAL USE
+0	193	NATIONAL USE
+0	194	NATIONAL USE
+0	195	NATIONAL USE
+0	196	NATIONAL USE
+0	197	NATIONAL USE
+0	198	NATIONAL USE
+0	199	NATIONAL USE
+0	200	NATIONAL USE
+0	201	NATIONAL USE
+0	202	NATIONAL USE
+0	203	NATIONAL USE
+0	204	NATIONAL USE
+0	205	NATIONAL USE
+0	206	NATIONAL USE
+0	207	NATIONAL USE
+0	208	NATIONAL USE
+0	209	NATIONAL USE
+0	210	NATIONAL USE
+0	211	NATIONAL USE
+0	212	NATIONAL USE
+0	213	NATIONAL USE
+0	214	NATIONAL USE
+0	215	NATIONAL USE
+0	216	NATIONAL USE
+0	217	NATIONAL USE
+0	218	NATIONAL USE
+0	219	NATIONAL USE
+0	220	NATIONAL USE
+0	221	NATIONAL USE
+0	222	NATIONAL USE
+0	223	NATIONAL USE
+0	224	NATIONAL USE
+0	225	NATIONAL USE
+0	226	NATIONAL USE
+0	227	NATIONAL USE
+0	228	NATIONAL USE
+0	229	NATIONAL USE
+0	230	NATIONAL USE
+0	231	NATIONAL USE
+0	232	NATIONAL USE
+0	233	NATIONAL USE
+0	234	NATIONAL USE
+0	235	NATIONAL USE
+0	236	NATIONAL USE
+0	237	NATIONAL USE
+0	238	NATIONAL USE
+0	239	NATIONAL USE
+0	240	NATIONAL USE
+0	241	NATIONAL USE
+0	242	NATIONAL USE
+0	243	NATIONAL USE
+0	244	NATIONAL USE
+0	245	NATIONAL USE
+0	246	NATIONAL USE
+0	247	NATIONAL USE
+0	248	NATIONAL USE
+0	249	NATIONAL USE
+0	250	NATIONAL USE
+0	251	NATIONAL USE
+0	252	NATIONAL USE
+0	253	NATIONAL USE
+0	254	NATIONAL USE
+
+# 255: Used to indicate missing or unknown center
+
+0	255	MISSING VALUE
diff --git a/data/tables/B2M-000-003-A b/data/tables/B2M-000-003-A
new file mode 100644
index 0000000..2a5d7db
--- /dev/null
+++ b/data/tables/B2M-000-003-A
@@ -0,0 +1,259 @@
+#
+# BUFR Table A - Data Category
+#
+  0	Surface data - land
+  1	Surface data - sea
+  2	Vertical soundings (other than satellite)
+  3	Vertical soundings (satellite)
+  4	Single level upper-air data (other than satellite)
+  5	Single level upper-air data (satellite)
+  6	Radar data
+  7	Synoptic features
+  8	Physical/chemical constituents
+  9	Dispersal and transport
+ 10	Radiological data
+ 11	BUFR tables, complete replacement or update
+ 12	Surface data (satellite)
+ 13	RESERVED
+ 14	RESERVED
+ 15	RESERVED
+ 16	RESERVED
+ 17	RESERVED
+ 18	RESERVED
+ 19	RESERVED
+ 20	Status information
+ 21	Radiances (satellite measured)
+ 22	RESERVED
+ 23	RESERVED
+ 24	RESERVED
+ 25	RESERVED
+ 26	RESERVED
+ 27	RESERVED
+ 28	RESERVED
+ 29	RESERVED
+ 30	RESERVED
+ 31	Oceanographic data
+ 32	RESERVED
+ 33	RESERVED
+ 34	RESERVED
+ 35	RESERVED
+ 36	RESERVED
+ 37	RESERVED
+ 38	RESERVED
+ 39	RESERVED
+ 40	RESERVED
+ 41	RESERVED
+ 42	RESERVED
+ 43	RESERVED
+ 44	RESERVED
+ 45	RESERVED
+ 46	RESERVED
+ 47	RESERVED
+ 48	RESERVED
+ 49	RESERVED
+ 50	RESERVED
+ 51	RESERVED
+ 52	RESERVED
+ 53	RESERVED
+ 54	RESERVED
+ 55	RESERVED
+ 56	RESERVED
+ 57	RESERVED
+ 58	RESERVED
+ 59	RESERVED
+ 60	RESERVED
+ 61	RESERVED
+ 62	RESERVED
+ 63	RESERVED
+ 64	RESERVED
+ 65	RESERVED
+ 66	RESERVED
+ 67	RESERVED
+ 68	RESERVED
+ 69	RESERVED
+ 70	RESERVED
+ 71	RESERVED
+ 72	RESERVED
+ 73	RESERVED
+ 74	RESERVED
+ 75	RESERVED
+ 76	RESERVED
+ 77	RESERVED
+ 78	RESERVED
+ 79	RESERVED
+ 80	RESERVED
+ 81	RESERVED
+ 82	RESERVED
+ 83	RESERVED
+ 84	RESERVED
+ 85	RESERVED
+ 86	RESERVED
+ 87	RESERVED
+ 88	RESERVED
+ 89	RESERVED
+ 90	RESERVED
+ 91	RESERVED
+ 92	RESERVED
+ 93	RESERVED
+ 94	RESERVED
+ 95	RESERVED
+ 96	RESERVED
+ 97	RESERVED
+ 98	RESERVED
+ 99	RESERVED
+100	RESERVED
+101	Image data
+102	RESERVED
+103	RESERVED
+104	RESERVED
+105	RESERVED
+106	RESERVED
+107	RESERVED
+108	RESERVED
+109	RESERVED
+110	RESERVED
+111	RESERVED
+112	RESERVED
+113	RESERVED
+114	RESERVED
+115	RESERVED
+116	RESERVED
+117	RESERVED
+118	RESERVED
+119	RESERVED
+120	RESERVED
+121	RESERVED
+122	RESERVED
+123	RESERVED
+124	RESERVED
+125	RESERVED
+126	RESERVED
+127	RESERVED
+128	RESERVED
+129	RESERVED
+130	RESERVED
+131	RESERVED
+132	RESERVED
+133	RESERVED
+134	RESERVED
+135	RESERVED
+136	RESERVED
+137	RESERVED
+138	RESERVED
+139	RESERVED
+140	RESERVED
+141	RESERVED
+142	RESERVED
+143	RESERVED
+144	RESERVED
+145	RESERVED
+146	RESERVED
+147	RESERVED
+148	RESERVED
+149	RESERVED
+150	RESERVED
+151	RESERVED
+152	RESERVED
+153	RESERVED
+154	RESERVED
+155	RESERVED
+156	RESERVED
+157	RESERVED
+158	RESERVED
+159	RESERVED
+160	RESERVED
+161	RESERVED
+162	RESERVED
+163	RESERVED
+164	RESERVED
+165	RESERVED
+166	RESERVED
+167	RESERVED
+168	RESERVED
+169	RESERVED
+170	RESERVED
+171	RESERVED
+172	RESERVED
+173	RESERVED
+174	RESERVED
+175	RESERVED
+176	RESERVED
+177	RESERVED
+178	RESERVED
+179	RESERVED
+180	RESERVED
+181	RESERVED
+182	RESERVED
+183	RESERVED
+184	RESERVED
+185	RESERVED
+186	RESERVED
+187	RESERVED
+188	RESERVED
+189	RESERVED
+190	RESERVED
+191	RESERVED
+192	RESERVED
+193	RESERVED
+194	RESERVED
+195	RESERVED
+196	RESERVED
+197	RESERVED
+198	RESERVED
+199	RESERVED
+200	RESERVED
+201	RESERVED
+202	RESERVED
+203	RESERVED
+204	RESERVED
+205	RESERVED
+206	RESERVED
+207	RESERVED
+208	RESERVED
+209	RESERVED
+210	RESERVED
+211	RESERVED
+212	RESERVED
+213	RESERVED
+214	RESERVED
+215	RESERVED
+216	RESERVED
+217	RESERVED
+218	RESERVED
+219	RESERVED
+220	RESERVED
+221	RESERVED
+222	RESERVED
+223	RESERVED
+224	RESERVED
+225	RESERVED
+226	RESERVED
+227	RESERVED
+228	RESERVED
+229	RESERVED
+230	RESERVED
+231	RESERVED
+232	RESERVED
+233	RESERVED
+234	RESERVED
+235	RESERVED
+236	RESERVED
+237	RESERVED
+238	RESERVED
+239	RESERVED
+240	FOR EXPERIMENTAL USE
+241	FOR EXPERIMENTAL USE
+242	FOR EXPERIMENTAL USE
+243	FOR EXPERIMENTAL USE
+244	FOR EXPERIMENTAL USE
+245	FOR EXPERIMENTAL USE
+246	FOR EXPERIMENTAL USE
+247	FOR EXPERIMENTAL USE
+248	FOR EXPERIMENTAL USE
+249	FOR EXPERIMENTAL USE
+250	FOR EXPERIMENTAL USE
+251	FOR EXPERIMENTAL USE
+252	FOR EXPERIMENTAL USE
+253	FOR EXPERIMENTAL USE
+254	FOR EXPERIMENTAL USE
+255	Indicator for local use, with sub-category
diff --git a/data/tables/B2M-000-003-B b/data/tables/B2M-000-003-B
new file mode 100644
index 0000000..3abdd78
--- /dev/null
+++ b/data/tables/B2M-000-003-B
@@ -0,0 +1,482 @@
+#
+# BUFR Table B - Classification of Elements
+#
+#					Data
+#F	X	Y	Scale	RefVal	Width	Units	Element Name
+  0;    0;      1;      0;           0;   24;    CCITT_IA5; Table A: entry
+  0;    0;      2;      0;           0;  256;    CCITT_IA5; Table A: data category description, line 1
+  0;    0;      3;      0;           0;  256;    CCITT_IA5; Table A: data category description, line 2
+  0;    0;      5;      0;           0;   24;    CCITT_IA5; BUFR edition number
+  0;    0;     10;      0;           0;    8;    CCITT_IA5; F descriptor to be added or defined
+  0;    0;     11;      0;           0;   16;    CCITT_IA5; X descriptor to be added or defined
+  0;    0;     12;      0;           0;   24;    CCITT_IA5; Y descriptor to be added or defined
+  0;    0;     13;      0;           0;  256;    CCITT_IA5; Element name, line 1
+  0;    0;     14;      0;           0;  256;    CCITT_IA5; Element name, line 2
+  0;    0;     15;      0;           0;  192;    CCITT_IA5; Units name
+  0;    0;     16;      0;           0;    8;    CCITT_IA5; Units scale sign
+  0;    0;     17;      0;           0;   24;    CCITT_IA5; Units scale
+  0;    0;     18;      0;           0;    8;    CCITT_IA5; Units reference sign
+  0;    0;     19;      0;           0;   80;    CCITT_IA5; Units reference value
+  0;    0;     20;      0;           0;   24;    CCITT_IA5; Element data width
+  0;    0;     30;      0;           0;   48;    CCITT_IA5; Descriptor defining sequence
+
+  0;    1;      1;      0;           0;    7;      Numeric; WMO block number
+  0;    1;      2;      0;           0;   10;      Numeric; WMO station number
+  0;    1;      3;      0;           0;    3;      Numeric; WMO region number
+  0;    1;      4;      0;           0;    3;      Numeric; WMO region sub-area
+  0;    1;      5;      0;           0;   17;      Numeric; Buoy/platform identifier
+  0;    1;      6;      0;           0;   64;    CCITT_IA5; Aircraft identifier (flight number)
+  0;    1;      7;      0;           0;   10;   Code_Table; Satellite identifier
+  0;    1;      8;      0;           0;   64;    CCITT_IA5; Aircraft registration number (tail number)
+  0;    1;      9;      0;           0;   64;    CCITT_IA5; Type of commerical aircraft
+  0;    1;     10;      0;           0;   64;    CCITT_IA5; Stationary buoy platform identifier
+  0;    1;     11;      0;           0;   72;    CCITT_IA5; Ship's call sign
+  0;    1;     12;      0;           0;    9;     deg_true; Direction of motion of moving observing platform
+  0;    1;     13;      0;           0;   10;          m/s; Speed of motion of moving observing platform
+  0;    1;     14;      2;           0;   10;          m/s; Platform drift speed (high precision)
+  0;    1;     21;      0;           0;   14;      Numeric; Synoptic feature identifier
+  0;    1;     25;      0;           0;   24;    CCITT_IA5; Storm identifier
+  0;    1;     26;      0;           0;   64;    CCITT_IA5; WMO storm name
+  0;    1;     31;      0;           0;   16;   Code_Table; Generating center
+  0;    1;     63;      0;           0;   64;    CCITT_IA5; ICAO location indicator
+
+  0;    2;      1;      0;           0;    2;   Code_Table; Type of station
+  0;    2;      2;      0;           0;    4;   Flag_Table; Type of instrumentation for wind measurement
+  0;    2;      3;      0;           0;    4;   Code_Table; Type of measuring instrumentation used
+  0;    2;      4;      0;           0;    4;   Code_Table; Type of instrumentation for evaporation measurement or type of crop for which evapotranspiration is reported
+  0;    2;      5;      2;           0;    7;          deg; Precision of temperature observed
+  0;    2;     11;      0;           0;    8;   Code_Table; Radiosonde type
+  0;    2;     12;      0;           0;    4;   Code_Table; Radiosonde computational method
+  0;    2;     13;      0;           0;    4;   Code_Table; Solar and infrared radiation correction
+  0;    2;     14;      0;           0;    7;   Code_Table; Tracking technique/status of system
+  0;    2;     15;      0;           0;    4;   Code_Table; Radiosonde completeness
+  0;    2;     21;      0;           0;    9;   Flag_Table; Satellite instrumentation data used in processing
+  0;    2;     22;      0;           0;    8;   Flag_Table; Satellite data processing technique used
+  0;    2;     23;      0;           0;    4;   Code_Table; Satellite derived wind computation method
+  0;    2;     24;      0;           0;    4;   Code_Table; Integrated mean humidity computational method
+  0;    2;     25;      0;           0;   25;   Flag_Table; Satellite channel(s) used in computation
+  0;    2;     26;      2;           0;   12;            m; Cross track resolution
+  0;    2;     27;      2;           0;   12;            m; Along track resolution
+  0;    2;     30;      0;           0;    3;   Code_Table; Method of current measurement
+  0;    2;     31;      0;           0;    5;   Code_Table; Duration and time of current measurement
+  0;    2;     32;      0;           0;    2;   Code_Table; Indicator for digitization
+  0;    2;     33;      0;           0;    3;   Code_Table; Method of salinity/depth measurement
+  0;    2;     34;      0;           0;    5;   Code_Table; Drogue type
+  0;    2;     35;      0;           0;    9;            m; Cable length
+  0;    2;     36;      0;           0;    2;   Code_Table; Buoy type
+  0;    2;     37;      0;           0;    3;   Code_Table; Method of tidal observation
+  0;    2;     38;      0;           0;    4;   Code_Table; Method of sea-surface temperature measurement
+  0;    2;     39;      0;           0;    3;   Code_Table; Method of wet-buld temperature measurement
+  0;    2;     40;      0;           0;    4;   Code_Table; Method of removing velocity and motion of platform from current
+  0;    2;     41;      0;           0;    6;   Code_Table; Method for estimating reports related to synoptic features
+  0;    2;     42;      0;           0;    6;   Code_Table; Method of report construction
+  0;    2;     43;      0;           0;    6;   Code_Table; Precision of latitude/longitude report
+  0;    2;     51;      0;           0;    4;   Code_Table; Indicator ro specify observing method for extreme temperatures
+  0;    2;     61;      0;           0;    3;   Code_Table; Aircraft navigation system
+  0;    2;     62;      0;           0;    4;   Code_Table; Type of aircraft data relay system
+  0;    2;     63;      2;      -18000;   16;          deg; Aircraft roll angle
+  0;    2;     70;      0;           0;    4;   Code_Table; Original specification of latitude/longitude
+  0;    2;    100;      1;           0;   12;           dB; Radar constant
+  0;    2;    101;      0;           0;    4;   Code_Table; Type of antenna
+  0;    2;    102;      0;           0;    8;            m; Antenna height above tower
+  0;    2;    103;      0;           0;    2;   Flag_Table; Radome
+  0;    2;    104;      0;           0;    4;   Code_Table; Antenna polarisation
+  0;    2;    105;      0;           0;    6;           dB; Maximum antenna gain
+  0;    2;    106;      1;           0;    6;          deg; 3-dB bandwidth
+  0;    2;    107;      0;           0;    6;           dB; Sidelobe suppression
+  0;    2;    108;      0;           0;    6;           dB; Crosspol discrimination (on axis)
+  0;    2;    109;      2;           0;   12;        deg/s; Antenna speed (azimuth)
+  0;    2;    110;      2;           0;   12;        deg/s; Antenna speed (elevation)
+  0;    2;    111;      1;           0;   10;          deg; Radar incidence angle
+  0;    2;    112;      1;           0;   12;          deg; Radar azimuth angle
+  0;    2;    113;      0;           0;    4;      Numeric; Number of azimuth looks
+  0;    2;    114;      0;           0;   15;         m**2; Antenna effective surface area
+  0;    2;    121;     -8;           0;    7;           Hz; Mean frequency
+  0;    2;    122;     -6;        -128;    8;           Hz; Frequency agility range
+  0;    2;    123;     -4;           0;    7;            W; Peak power
+  0;    2;    124;     -1;           0;    7;            W; Average power
+  0;    2;    125;     -1;           0;    8;           Hz; Pulse repetition frequency
+  0;    2;    126;      7;           0;    6;            s; Pulse width
+  0;    2;    127;     -6;           0;    7;           Hz; Receiver intermediate frequency
+  0;    2;    128;     -5;           0;    6;           Hz; Intermediate frequency bandwidth
+  0;    2;    129;      0;        -150;    5;           dB; Minimum detectable signal
+  0;    2;    130;      0;           0;    7;           dB; Dynamic range
+  0;    2;    131;      0;           0;    2;   Flag_Table; Sensitivity time control
+  0;    2;    132;      2;           0;    6;          deg; Azimuth pointing accuracy
+  0;    2;    133;      2;           0;    6;          deg; Elevation pointing accuracy
+  0;    2;    134;      2;           0;   16;          deg; Antenna beam azimuth
+  0;    2;    135;      2;       -9000;   15;          deg; Antenna elevation
+  0;    2;    136;     -3;           0;   16;            m; Range processed by range attenuation correction
+  0;    2;    141;      0;           0;   24;    CCITT_IA5; Measurement type
+  0;    2;    142;      0;           0;   32;    CCITT_IA5; Ozone instrument serial number/identification
+  0;    2;    143;      0;           0;    7;      Numeric; Instrument type
+
+  0;    4;      1;      0;           0;   12;         Year; Year
+  0;    4;      2;      0;           0;    4;           mo; Month
+  0;    4;      3;      0;           0;    6;          Day; Day
+  0;    4;      4;      0;           0;    5;           hr; Hour
+  0;    4;      5;      0;           0;    6;          min; Minute
+  0;    4;      6;      0;           0;    6;            s; Second
+  0;    4;     11;      0;       -1024;   11;         Year; Time increment
+  0;    4;     12;      0;       -1024;   11;           mo; Time increment
+  0;    4;     13;      0;       -1024;   11;         Days; Time increment
+  0;    4;     14;      0;       -1024;   11;           hr; Time increment
+  0;    4;     15;      0;       -2048;   12;          min; Time increment
+  0;    4;     16;      0;       -4096;   13;            s; Time increment
+  0;    4;     21;      0;       -1024;   11;         Year; Time period or displacement
+  0;    4;     22;      0;       -1024;   11;           mo; Time period or displacement
+  0;    4;     23;      0;       -1024;   11;         Days; Time period or displacement
+  0;    4;     24;      0;       -2048;   12;           hr; Time period or displacement
+  0;    4;     25;      0;       -2048;   12;          min; Time period or displacement
+  0;    4;     26;      0;       -4096;   13;            s; Time period or displacement
+  0;    4;     31;      0;           0;    8;           hr; Duration of time relative to followinG value
+  0;    4;     41;      0;       -1440;   12;       Minute; Time Difference, UTC-LMT
+  0;    4;     43;      0;           0;    9;          Day; Day of the year
+  0;    4;     53;      0;           0;    6;      Numeric; Number of days with precipition equal to or more than 1mm
+  0;    4;    192;      0;           0;    3;   Code_Table; Season
+
+  0;    5;      1;      5;    -9000000;   25;          deg; Latitude (high accuracy)
+  0;    5;      2;      2;       -9000;   15;          deg; Latitude (coarse accuracy)
+  0;    5;     11;      5;    -9000000;   25;          deg; Latitude increment (high accuracy)
+  0;    5;     12;      2;       -9000;   15;          deg; Latitude increment (coarse accuracy)
+  0;    5;     21;      2;           0;   16;     deg_true; Bearing or azimuth
+  0;    5;     22;      2;           0;   16;     deg_true; Solar azimuth
+  0;    5;     30;      0;           0;   12;          deg; Direction (spectral)
+  0;    5;     31;      0;           0;   12;      Numeric; Row number
+  0;    5;     33;     -1;           0;   16;            m; Pixel size on horizontal - 1
+  0;    5;     40;      0;           0;   24;      Numeric; Orbit number
+  0;    5;     41;      0;           0;    8;      Numeric; Scan line number
+  0;    5;     42;      0;           0;    6;      Numeric; Channel number
+  0;    5;     43;      0;           0;    8;      Numeric; Field of view number
+  0;    5;     52;      0;           0;    5;      Numeric; Channel number increment
+  0;    5;     53;      0;           0;    5;      Numeric; Field of view number increment
+
+  0;    6;      1;      5;   -18000000;   26;          deg; Longitude (high accuracy)
+  0;    6;      2;      2;      -18000;   16;          deg; Longitude (coarse accuracy)
+  0;    6;     11;      5;   -18000000;   26;          deg; Longitude increment (high accuracy)
+  0;    6;     12;      2;      -18000;   16;          deg; Longitude increment (coarse accuracy)
+  0;    6;     21;     -1;           0;   13;            m; Distance
+  0;    6;     30;      5;           0;   13;        rad/m; Wavenumber (spectral)
+  0;    6;     31;      0;           0;   12;      Numeric; Column number
+  0;    6;     33;     -1;           0;   16;            m; Pixel size on horizontal - 2
+
+  0;    7;      1;      0;        -400;   15;            m; Height of station
+  0;    7;      2;     -1;         -40;   16;            m; Height or altitude
+  0;    7;      3;     -1;        -400;   17;    m**2/s**2; Geopotential
+  0;    7;      4;     -1;           0;   14;           Pa; Pressure
+  0;    7;      5;      0;        -400;   12;            m; Height increment
+  0;    7;      6;      0;           0;   15;            m; Height above station
+  0;    7;      7;      0;       -1000;   17;            m; Height
+  0;    7;      8;      0;      -10000;   20;    m**2/s**2; Geopotential
+  0;    7;     21;      2;       -9000;   15;          deg; Elevation
+  0;    7;     22;      2;       -9000;   15;          deg; Solar elevation
+  0;    7;     61;      2;           0;   14;            m; Depth below land surface
+  0;    7;     62;      1;           0;   17;            m; Depth below sea surface
+  0;    7;    190;      0;           0;   12;            m; Height increment
+
+  0;    8;      1;      0;           0;    7;   Flag_Table; Vertical sounding significance
+  0;    8;      2;      0;           0;    6;   Code_Table; Vertical significance (surface observations)
+  0;    8;      3;      0;           0;    6;   Code_Table; Vertical significance (satellite observations)
+  0;    8;      4;      0;           0;    3;   Code_Table; Phase of aircraft flight
+  0;    8;      5;      0;           0;    4;   Code_Table; Surface synoptic features significance
+  0;    8;     11;      0;           0;    6;   Code_Table; Horizontal significance
+  0;    8;     12;      0;           0;    2;   Code_Table; land/sea qualifier
+  0;    8;     13;      0;           0;    2;   Code_Table; Day/night qualifier
+  0;    8;     20;      0;           0;   16;      Numeric; Total number of missing entities (with respect to accumulation or average)
+  0;    8;     21;      0;           0;    5;   Code_Table; Time significance
+  0;    8;     22;      0;           0;   16;      Numeric; Total number (with respect to accumulation or average)
+  0;    8;     51;      0;           0;    3;   Code_Table; Qualifier for number of missing values in calculation of statistic
+  0;    8;     52;      0;           0;    5;   Code_Table; Condition for which number of days of occurance follows
+  0;    8;     53;      0;           0;    2;   COde_Table; Day of occurance qualifier
+
+  0;   10;      1;      0;        -400;   15;            m; Height of land surface
+  0;   10;      2;     -1;         -40;   16;            m; Height
+  0;   10;      3;     -1;        -400;   17;    m**2/s**2; Geopotential
+  0;   10;      4;     -1;           0;   14;           Pa; Pressure
+  0;   10;      7;      0;       -1000;   17;            m; Height
+  0;   10;      8;      0;      -10000;   20;    m**2/s**2; Geopotential
+  0;   10;     50;      2;           0;   16;            m; Standard deviation altitude
+  0;   10;     51;     -1;           0;   14;           Pa; Pressure reduced to mean sea level
+  0;   10;     52;     -1;           0;   14;           Pa; Altimeter setting (QNH)
+  0;   10;     60;     -1;       -1024;   11;           Pa; Pressure change
+  0;   10;     61;     -1;        -500;   10;           Pa; 3 hour pressure change
+  0;   10;     62;     -1;       -1000;   11;           Pa; 24 hour pressure change
+  0;   10;     63;      0;           0;    4;   Code_Table; Characteristic of pressure tendency
+
+  0;   11;      1;      0;           0;    9;     deg_true; Wind direction
+  0;   11;      2;      1;           0;   12;          m/s; Wind speed
+  0;   11;      3;      1;       -4096;   13;          m/s; U-component
+  0;   11;      4;      1;       -4096;   13;          m/s; V-component
+  0;   11;      5;      1;        -512;   10;         Pa/s; W-component
+  0;   11;      6;      2;       -4096;   13;          m/s; W-component
+  0;   11;     11;      0;           0;    9;     deg_true; Wind direction at 10 m
+  0;   11;     12;      1;           0;   12;          m/s; Wind speed at 10 m
+  0;   11;     13;      0;           0;    9;     deg_true; Wind direction at 5 m
+  0;   11;     14;      1;           0;   12;          m/s; Wind speed at 5 m
+  0;   11;     21;      9;      -65536;   17;        s**-1; Relative vorticity
+  0;   11;     22;      9;      -65536;   17;        s**-1; Divergence
+  0;   11;     23;     -2;      -65536;   17;       m**2/s; Velocity potential
+  0;   11;     31;      0;           0;    4;   Code_Table; Degree of turbulence
+  0;   11;     32;     -1;         -40;   16;            m; Height of base of turbulence
+  0;   11;     33;     -1;         -40;   16;            m; Height of top of turbulence
+  0;   11;     34;      1;       -1024;   11;          m/s; Vertical gust velocity
+  0;   11;     35;      2;       -8192;   14;       m/s**2; Vertical gust acceleration
+  0;   11;     36;      1;           0;   10;          m/s; Maximum derived equivalent vertical gust speed
+  0;   11;     41;      1;           0;   12;          m/s; Maximum wind speed (gusts)
+  0;   11;     42;      1;           0;   12;          m/s; Maximum wind speed (10 minute mean wind)
+  0;   11;     43;      0;           0;    9;     deg_true; Maximum wind gust direction
+  0;   11;     49;      0;           0;    9;     deg_true; Standard deviation of wind direction
+  0;   11;     50;      1;           0;   12;          m/s; Standard deviation horizontal wind speed
+  0;   11;     51;      1;           0;    8;          m/s; Standard deviation vertical wind speed
+  0;   11;     61;      1;           0;   12;          m/s; Absolute wind shear in 1 kilometer layer below
+  0;   11;     62;      1;           0;   12;          m/s; Absolute wind shear in1 kilometer layer above
+
+  0;   12;      1;      1;           0;   12;        deg_K; Temperature/dry bulb temperature
+  0;   12;      2;      1;           0;   12;        deg_K; Wet bulb temperature
+  0;   12;      3;      1;           0;   12;        deg_K; Dewpoint temperature
+  0;   12;      4;      1;           0;   12;        deg_K; Dry bulb temperature at 2 meters
+  0;   12;      5;      1;           0;   12;        deg_K; Wet bulb temperature at 2 meters
+  0;   12;      6;      1;           0;   12;        deg_K; Dewpoint temperature at 2 meters
+  0;   12;      7;      1;           0;   12;        deg_K; Virtual temperature
+  0;   12;     11;      1;           0;   12;        deg_K; Maximum temperature
+  0;   12;     12;      1;           0;   12;        deg_K; Minimum temperature
+  0;   12;     13;      1;           0;   12;        deg_K; Ground minimum temperature past 12 hours
+  0;   12;     14;      1;           0;   12;        deg_K; Maximum temperature at 2 meters, past 12 hours
+  0;   12;     15;      1;           0;   12;        deg_K; Minimum temperature at 2 meters, past 12 hours
+  0;   12;     16;      1;           0;   12;        deg_K; Maximum temperature at 2 meters, past 24 hours
+  0;   12;     17;      1;           0;   12;        deg_K; Minimum temperature at 2 meters, past 24 hours
+  0;   12;     30;      1;           0;   12;        deg_K; Soil temperature
+  0;   12;     51;      1;           0;   10;        deg_K; Standard deviation of temperature
+  0;   12;     52;      1;           0;   12;        deg_K; Highest daily mean temperature
+  0;   12;     53;      1;           0;   12;        deg_K; Lowest daily mean temperature
+  0;   12;     61;      1;           0;   12;        deg_K; Skin temperature
+  0;   12;     62;      1;           0;   12;        deg_K; Equivalent black body temperature
+  0;   12;     63;      1;           0;   12;        deg_K; Brightness temperature
+
+  0;   13;      1;      5;           0;   14;        kg/kg; Specific humidity
+  0;   13;      2;      5;           0;   14;        kg/kg; Mixing ratio
+  0;   13;      3;      0;           0;    7;      percent; Relative humidity
+  0;   13;      4;     -1;           0;   10;           Pa; Vapor pressure
+  0;   13;      5;      3;           0;    7;      kg/m**3; Vapor density
+  0;   13;      6;     -1;         -40;   16;            m; Mixing heights
+  0;   13;     11;      4;          -1;   14;      kg/m**2; Total precipitation/total water equivalent
+  0;   13;     12;      2;          -2;   12;            m; Depth of fresh snow
+  0;   13;     13;      2;          -2;   16;            m; Total snow depth
+  0;   13;     14;      4;           0;   12;    kg/m**2/s; Rainfall/water equivalent of snow (average rate)
+  0;   13;     15;      7;           0;   12;          m/s; Snowfall (averaged rate)
+  0;   13;     16;      0;           0;    7;      kg/m**2; Precipitable water
+  0;   13;     19;      1;          -1;   14;      kg/m**2; Total precipitation past 1 hour
+  0;   13;     20;      1;          -1;   14;      kg/m**2; Total precipitation past 3 hours
+  0;   13;     21;      1;          -1;   14;      kg/m**2; Total precipitation past 6 hours
+  0;   13;     22;      1;          -1;   14;      kg/m**2; Total precipitation past 12 hours
+  0;   13;     23;      1;          -1;   14;      kg/m**2; Total precipitation past 24 hours
+  0;   13;     31;      0;           0;    7;      kg/m**2; Evapotranspiration
+  0;   13;     32;      1;           0;    8;      kg/m**2; Evaporation/evapotranspiration
+  0;   13;     41;      0;           0;    4;   Code_Table; Pasquill-Gifford stability category
+  0;   13;     42;      0;         -20;    6;        deg_K; Parcel lifted index (to 500 hPa)
+  0;   13;     43;      0;         -20;    6;        deg_K; Best lifted index (to 500 hPa)
+  0;   13;     51;      0;           0;    4;   Code_Table; Frequency group, precipition
+  0;   13;     52;      1;          -1;   14;      kg/m**2; Highest daily amount of precipition
+
+  0;   14;      1;     -3;       -2048;   12;  Joules/m**2; Longwave radiation, integrated over 24 hours
+  0;   14;      2;     -3;       -2048;   12;  Joules/m**2; Longwave radiation, integrated over period specified
+  0;   14;      3;     -3;       -2048;   12;  Joules/m**2; Shortwave radiation, integrated over 24 hours
+  0;   14;      4;     -3;       -2048;   12;  Joules/m**2; Shortwave radiation, integrated over period specified
+  0;   14;     11;     -3;       -2048;   12;  Joules/m**2; Net longwave radiation, integrated over 24 hours
+  0;   14;     12;     -3;       -2048;   12;  Joules/m**2; Net longwave radiation, integrated over period specified
+  0;   14;     13;     -3;       -2048;   12;  Joules/m**2; Net shortwave radiation, integrated over 24 hours
+  0;   14;     14;     -3;       -2048;   12;  Joules/m**2; Net shortwave radiation, integrated over period specified
+  0;   14;     15;     -4;      -16384;   15;  Joules/m**2; Net radiation, integrated over 24 hours
+  0;   14;     16;     -4;      -16384;   15;  Joules/m**2; Net radiation, integrated over period specified
+  0;   14;     17;     -3;       -2048;   12;       W/m**2; Instantaneous long wave radiation
+  0;   14;     18;     -3;       -2048;   12;       W/m**2; Instantaneous short wave radiation
+  0;   14;     19;      0;           0;    7;      percent; Surface albedo
+  0;   14;     20;     -4;           0;   15;  Joules/m**2; Global solar radiation, integrated over 24 hours
+  0;   14;     21;     -4;           0;   15;  Joules/m**2; Global radiation, integrated over period specified
+  0;   14;     22;     -4;           0;   15;  Joules/m**2; Diffuse solar radiation, integrated over 24 hours
+  0;   14;     23;     -4;           0;   15;  Joules/m**2; Diffuse solar radiation, integratedi over period specified
+  0;   14;     24;     -4;           0;   15;  Joules/m**2; Direct solar radiation, integrated over 24 hours
+  0;   14;     25;     -4;           0;   15;  Joules/m**2; Direct solar radiation, integrated over period specified
+  0;   14;     31;      0;           0;   11;          min; Total sunshine
+  0;   14;     32;      0;           0;   10;           hr; Total sunshine
+  0;   14;     33;      0;           0;    9;      percent; Total sunshine
+  0;   14;     42;      0;           0;    7;      percent; Bi-directional reflectance
+
+  0;   15;      1;      0;           0;   10;       Dobson; units	Ozone
+  0;   15;      2;      2;           0;   10;      Numeric; Air mass (slant path at 22km)
+
+  0;   19;      1;      0;           0;    6;   Code_Table; Type of synoptic features
+  0;   19;      2;     -2;           0;   12;            m; Effective radius of feature
+  0;   19;      3;      0;           0;    8;          m/s; Wind speed threshold
+  0;   19;      4;     -2;           0;   12;            m; Effective radius of feature with respect to wind speeds above threshold
+  0;   19;      5;      0;           0;    9;     deg_true; Direction of motion of features
+  0;   19;      6;      2;           0;   14;          m/s; Speed of motion of features
+  0;   19;      7;     -3;           0;   12;            m; Effective radius of features
+  0;   19;      8;      0;           0;    3;   Code_Table; Vertical extent of circulation
+  0;   19;      9;     -3;           0;   12;            m; Effective radius with respect to wind speed above threshold (large storms)
+
+  0;   20;      1;     -1;           0;   13;            m; Horizontal visibility
+  0;   20;      2;     -1;           0;    7;            m; Vertical visibility
+  0;   20;      3;      0;           0;    9;   Code_Table; Present weather
+  0;   20;      4;      0;           0;    5;   Code_Table; Past weather (1)
+  0;   20;      5;      0;           0;    5;   Code_Table; Past weather (2)
+  0;   20;     10;      0;           0;    7;      percent; Cloud cover (total)
+  0;   20;     11;      0;           0;    4;   Code_Table; Cloud amount
+  0;   20;     12;      0;           0;    6;   Code_Table; Cloud type
+  0;   20;     13;     -1;         -40;   11;            m; Height of base of cloud
+  0;   20;     14;     -1;         -40;   11;            m; Height of top of cloud
+  0;   20;     15;     -1;           0;   14;           Pa; Pressure at the base of cloud
+  0;   20;     16;     -1;           0;   14;           Pa; Pressure at the top of cloud
+  0;   20;     17;      0;           0;    4;   Code_Table; Cloud top description
+  0;   20;     31;      2;           0;    7;            m; Ice deposit (thickness)
+  0;   20;     32;      0;           0;    3;   Code_Table; Rate of ice accretion
+  0;   20;     33;      0;           0;    4;   Flag_Table; Cause of ice accretion
+  0;   20;     34;      0;           0;    5;   Code_Table; Sea ice concentration
+  0;   20;     35;      0;           0;    4;   Code_Table; Amount and type of ice
+  0;   20;     36;      0;           0;    5;   Code_Table; Ice situation
+  0;   20;     37;      0;           0;    5;   Code_Table; Ice development
+  0;   20;     38;      0;           0;   12;     deg_true; Bearing of ice edge
+  0;   20;     39;     -1;           0;   13;            m; Ice distance
+  0;   20;     41;      0;           0;    4;   Code_Table; Airframe icing
+  0;   20;     51;      0;           0;    7;      percent; Amount of low clouds
+  0;   20;     52;      0;           0;    7;      percent; Amount of middle clouds
+  0;   20;     53;      0;           0;    7;      percent; Amount of high clouds
+  0;   20;     61;      0;           0;   12;            m; Runway visual range (RVR)
+  0;   20;     62;      0;           0;    5;   Code_Table; State of the ground(with or without snow)
+  0;   20;     63;      0;           0;   10;   Code_Table; Special phenomena
+
+  0;   21;      1;      0;         -64;    7;           dB; Horizontal reflectivity
+  0;   21;      2;      0;         -64;    7;           dB; Vertical reflectivity
+  0;   21;      3;      1;          -5;    7;           dB; Differential reflectivity
+  0;   21;      5;      0;         -65;    6;           dB; Linear depolarization ratio
+  0;   21;      6;      0;         -65;    6;           dB; Circular depolarization ratio
+  0;   21;     11;      0;        -128;    8;          m/s; Doppler mean velocity in X direction
+  0;   21;     12;      0;        -128;    8;          m/s; Doppler mean velocity in Y direction
+  0;   21;     13;      0;        -128;    8;          m/s; Doppler mean velocity in Z direction
+  0;   21;     14;      1;       -4096;   13;          m/s; Doppler mean velocity (radiational)
+  0;   21;     17;      1;           0;    8;          m/s; Doppler velocity spectral width
+  0;   21;     21;     -3;           0;    4;            m; Echo tops
+  0;   21;     30;      0;         -32;    8;           dB; Signal to noise ratio
+  0;   21;     31;      0;           0;    7;      kg/m**2; Vertical integrated liquid water content
+  0;   21;     36;      7;           0;   12;          m/s; Radar rainfall intensity
+  0;   21;     41;     -2;           0;    8;            m; Bright band height
+  0;   21;     51;      0;        -256;    8;           dB; Signal power above 1 MW
+
+  0;   22;      1;      0;           0;    9;     deg_true; Direction of waves
+  0;   22;      2;      0;           0;    9;     deg_true; Direction of wind waves
+  0;   22;      3;      0;           0;    9;     deg_true; Direction of swell waves
+  0;   22;      4;      0;           0;    9;     deg_true; Direction of current waves
+  0;   22;     11;      0;           0;    6;            s; Period of waves
+  0;   22;     12;      0;           0;    6;            s; Period of wind waves
+  0;   22;     13;      0;           0;    6;            s; Period of swell waves
+  0;   22;     21;      1;           0;   10;            m; Height of waves
+  0;   22;     22;      1;           0;   10;            m; Height of wind waves
+  0;   22;     23;      1;           0;   10;            m; Height of swell waves
+  0;   22;     25;      2;           0;   10;            m; Standard deviation wave
+  0;   22;     31;      2;           0;   13;          m/s; Speed of current
+  0;   22;     37;      3;      -10000;   15;            m; Tidal elevation with respect to national chart datum
+  0;   22;     38;      3;      -10000;   15;            m; Tidal elevation with respect to local chart datum
+  0;   22;     39;      3;       -5000;   12;            m; Meteorological residual tidal elevation (surge or offset)
+  0;   22;     41;      1;           0;   12;        deg_K; Sea surface temperature (15 day running mean)
+  0;   22;     42;      1;           0;   12;        deg_K; Sea temperature
+  0;   22;     43;      2;           0;   15;        deg_K; Sea temperature
+  0;   22;     44;      1;           0;   14;          m/s; Sound velocity
+  0;   22;     50;      2;           0;    8;            K; Standard deviation sea surface temperature
+  0;   22;     61;      0;           0;    4;   Code_Table; State of sea
+  0;   22;     62;      2;           0;   14;          ppt; Salinity
+  0;   22;     63;      0;           0;   14;            m; Total water depth
+
+  0;   23;      1;      0;           0;    3;   Code_Table; Accident early notification - article applicable
+  0;   23;      2;      0;           0;    5;   Code_Table; Activity or facility involved in incident
+  0;   23;      3;      0;           0;    3;   Code_Table; Type of release
+  0;   23;      4;      0;           0;    3;   Code_Table; Countermeasures taken near border
+  0;   23;      5;      0;           0;    2;   Code_Table; Cause of incident
+  0;   23;      6;      0;           0;    3;   Code_Table; Incident situation
+  0;   23;      7;      0;           0;    3;   Code_Table; Characteristic of release
+  0;   23;      8;      0;           0;    2;   Code_Table; State of current release
+  0;   23;      9;      0;           0;    2;   Code_Table; State of expected release
+  0;   23;     16;      0;           0;    2;   Code_Table; Possibility of significant chemical toxic health effect
+  0;   23;     17;      6;           0;   20;       m**3/s; Flow discharge of major recipient
+  0;   23;     18;      0;           0;    3;   Code_Table; release behavior over time
+  0;   23;     19;      0;      -15000;   17;            m; Actual release height
+  0;   23;     21;      0;      -15000;   17;            m; Effective release height
+  0;   23;     22;      0;           0;   24;            m; Distance of relative point or site of incident
+  0;   23;     23;      1;           0;   12;          m/s; Main transport speed in atmosphere
+  0;   23;     24;      2;           0;   13;          m/s; Main transport speed in water
+  0;   23;     25;      2;           0;   13;          m/s; Main transport speed in ground water
+  0;   23;     27;      0;           0;    9;     deg_true; Main transport direction in atmosphere
+  0;   23;     28;      0;           0;    9;     deg_true; Main transport direction in water
+  0;   23;     29;      0;           0;    9;     deg_true; Main transport direction in ground water
+  0;   23;     31;      0;           0;    2;   Code_Table; Possibility that plume will encounter precipitation cwin state in which incident occurred
+  0;   23;     32;      0;           0;    2;   Code_Table; Plume will encounter ichange in wind direction and/or speed flag
+
+  0;   24;      1;     -1;           0;   28;           Bq; Estimate of radiatioactivity released up to specified time
+  0;   24;      2;     -1;           0;   28;           Bq; Estimated maximum potential release
+  0;   24;      3;      0;           0;    5;   Code_Table; Composition of release
+  0;   24;      4;      0;           0;   16;    CCITT_IA5; Element name
+  0;   24;      5;      0;           0;    9;      Numeric; Isotope mass
+  0;   24;     11;      2;           0;   32;          mSv; Dose
+  0;   24;     12;      2;           0;   32;          mSv; Trajectory dose (defined location and expected time of arrival)
+  0;   24;     13;      2;           0;   32;          mSv; Gamma dose in air along the main transport path (defined location and time period
+  0;   24;     21;      2;           0;   32;      Bq/m**3; Air concentration (named isotope type including gross beta)
+  0;   24;     22;      2;           0;   32;         Bq/l; Concentration in precipitation (of named isotope type)
+
+  0;   25;      1;     -1;           0;    6;            m; Range gate length
+  0;   25;      2;      0;           0;    4;      Numeric; Number of gates averaged
+  0;   25;      3;      0;           0;    8;      Numeric; Number of integrated pulses
+  0;   25;      4;      0;           0;    2;   Code_Table; Echo processing
+  0;   25;      5;      0;           0;    2;   Code_Table; Echo integration
+  0;   25;      6;      0;           0;    3;   Code_Table; Z to R conversion
+  0;   25;      7;      0;           0;   12;      Numeric; Z to R conversion factor
+  0;   25;      8;      2;           0;    9;      Numeric; Z to R conversion exponent
+  0;   25;      9;      0;           0;    4;   Flag_Table; Calibration method
+  0;   25;     10;      0;           0;    4;   Code_Table; Clutter treatment
+  0;   25;     11;      0;           0;    2;   Code_Table; Ground occultation correction (screening)
+  0;   25;     12;      0;           0;    2;   Code_Table; Range attenuation correction
+  0;   25;     13;      0;           0;    2;   Flag_Table; Bright band correction
+  0;   25;     15;      0;           0;    2;   Flag_Table; Radome attenuation correction
+  0;   25;     16;      5;           0;    6;         dB/m; Clear air attenuation correction
+  0;   25;     17;      0;           0;    2;   Flag_Table; Precipitation attenuation correction
+  0;   25;     18;      7;           0;    6;      Numeric; A to Z law for attenuation factor
+  0;   25;     19;      2;           0;    7;      Numeric; A to Z law for attenuation exponent
+  0;   25;     20;      0;           0;    2;   Code_Table; Mean speed estimation
+  0;   25;     21;      0;           0;    8;   Flag_Table; Wind computation enhancement
+  0;   25;     30;      0;           0;    2;   Code_Table; SST usage
+  0;   25;     32;      0;           0;    2;   Code_Table; NOAA wind profiler high/low mode data
+  0;   25;     33;      0;           0;    2;   Code_Table; NOAA wind profiler submode
+  0;   25;     34;      0;           0;    4;   Code_Table; NOAA wind profiler Q/C test results
+  0;   25;     40;      0;           0;    4;   Code_Table; CO2 wind product derivation
+  0;   25;     41;      0;           0;    2;   Code_Table; Moving platform direction reporting method
+  0;   25;     42;      0;           0;    2;   Code_Table; Moving platform speed reporting method
+
+  0;   26;      1;      1;           0;   12;         Hour; Principal time of daily reading in UTC of maximum temperature
+  0;   26;      2;      1;           0;   12;         Hour; Principal time of daily reading in UTC of minimum temperature
+
+  0;   27;      1;      5;    -9000000;   25;          deg; Latitude (high accuracy)
+  0;   27;      2;      2;       -9000;   15;          deg; Latitude (coarse accuracy)
+  0;   27;      3;      2;       -9000;   15;          deg; Alternate latitude
+  0;   27;     20;      0;           0;   16;      Numeric; Satellite locationon counter
+  0;   27;     21;      0;           0;   16;      Numeric; Satellite sub-locationon dimensions
+
+  0;   28;      1;      5;   -18000000;   26;          deg; Longitude (high accuracy)
+  0;   28;      2;      2;      -18000;   16;          deg; Longitude (coarse accuracy)
+  0;   28;      3;      2;      -18000;   16;          deg; Alternate longtiude
+
+  0;   29;      1;      0;           0;    3;   Code_Table; Projection type
+  0;   29;      2;      0;           0;    2;   Code_Table; Coordinate grid type
+
+  0;   30;      1;      0;           0;    4;      Numeric; Pixel value (4 bits)
+  0;   30;      2;      0;           0;    8;      Numeric; Pixel value (8 bits)
+  0;   30;      4;      0;           0;   16;      Numeric; Pixel value (16 bits)
+  0;   30;     21;      0;           0;   12;      Numeric; Number of pixels per row
+  0;   30;     22;      0;           0;   12;      Numeric; Number of pixels per column
+  0;   30;     31;      0;           0;    4;   Code_Table; Picture type
+  0;   30;     32;      0;           0;   16;   Flag_Table; Combined picture
+
+  0;   31;      0;      0;           0;    1;   Flag_Table; Delayed descriptor replication switch
+  0;   31;      1;      0;           0;    8;      Numeric; Delayed descriptor replication factor
+  0;   31;      2;      0;           0;   16;      Numeric; Extended delayed descriptor replication factor
+  0;   31;     11;      0;           0;    8;      Numeric; Delayed descriptor and data repetion factor
+  0;   31;     12;      0;           0;   16;      Numeric; Extended delayed descriptor and data repitition factor
+  0;   31;     21;      0;           0;    6;   Code_Table; Associated field significance
+
diff --git a/data/tables/B2M-000-003-D b/data/tables/B2M-000-003-D
new file mode 100644
index 0000000..23feaf2
--- /dev/null
+++ b/data/tables/B2M-000-003-D
@@ -0,0 +1,1174 @@
+#
+# BUFR Table D (Lists of Common Sequences)
+#
+# Descriptor sequences are terminated with -1
+#
+# Sequences do not need to appear in any order.  Sequence A
+# which includes sequence B, may appear before sequence B
+# is defined.
+#
+3	0	2
+	0	0	2
+	0	0	3
+	-1
+
+3	0	3
+	0	0	10
+	0	0	11
+	0	0	12
+	-1
+
+3	0	4
+	3	0	3
+	0	0	13
+	0	0	14
+	0	0	15
+	0	0	16
+	0	0	17
+	0	0	18
+	0	0	19
+	0	0	20
+	-1
+
+3	0	10
+	3	0	3
+	1	1	0
+	0	31	1
+	0	0	30
+	-1
+
+3	1	1
+	0	1	1
+	0	1	2
+	-1
+
+3	1	2
+	0	1	3
+	0	1	4
+	0	1	5
+	-1
+
+3	1	3
+	0	1	11
+	0	1	12
+	0	1	13
+	-1
+
+3	1	11
+	0	4	1
+	0	4	2
+	0	4	3
+	-1
+
+3	1	12
+	0	4	4
+	0	4	5
+	-1
+
+3	1	13
+	0	4	4
+	0	4	5
+	0	4	6
+	-1
+
+3	1	21
+	0	5	1
+	0	6	1
+	-1
+
+3	1	22
+	0	5	1
+	0	6	1
+	0	7	1
+	-1
+
+3	1	23
+	0	5	2
+	0	6	2
+	-1
+
+3	1	24
+	0	5	2
+	0	6	2
+	0	7	1
+	-1
+
+3	1	25
+	3	1	23
+	0	4	3
+	3	1	12
+	-1
+
+3	1	26
+	3	1	21
+	0	4	3
+	0	4	3
+	0	4	4
+	0	4	4
+	0	4	5
+	0	4	5
+	-1
+
+3	1	31
+	3	1	1
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	22
+	-1
+
+3	1	32
+	3	1	1
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	24
+	-1
+
+3	1	33
+	0	1	5
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	21
+	-1
+
+3	1	34
+	0	1	5
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	35
+	0	1	5
+	0	1	12
+	0	1	13
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	36
+	3	1	3
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	37
+	3	1	1
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	22
+	-1
+
+3	1	38
+	3	1	1
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	24
+	-1
+
+3	1	39
+	3	1	3
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	40
+	3	1	3
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	24
+	-1
+
+3	1	41
+	0	1	7
+	0	2	21
+	0	2	22
+	3	1	11
+	3	1	12
+	-1
+
+3	1	42
+	3	1	41
+	3	1	21
+	-1
+
+3	1	43
+	0	1	7
+	0	2	23
+	3	1	11
+	3	1	13
+	3	1	21
+	-1
+
+3	1	44
+	0	1	7
+	0	2	24
+	3	1	11
+	3	1	13
+	3	1	21
+	-1
+
+3	1	51
+	0	1	6
+	0	2	61
+	3	1	11
+	3	1	12
+	3	1	21
+	0	8	4
+	-1
+
+3	1	62
+	1	1	0
+	0	31	1
+	3	1	1
+	-1
+
+3	2	1
+	0	10	4
+	0	10	51
+	0	10	61
+	0	10	63
+	-1
+
+3	2	2
+	0	10	4
+	0	7	4
+	0	10	3
+	0	10	61
+	0	10	63
+	-1
+
+3	2	3
+	0	11	11
+	0	11	12
+	0	12	4
+	0	12	6
+	0	13	3
+	0	20	1
+	0	20	3
+	0	20	4
+	0	20	5
+	-1
+
+3	2	4
+	0	20	10
+	0	8	2
+	0	20	11
+	0	20	13
+	0	20	12
+	0	20	12
+	0	20	12
+	-1
+
+3	2	5
+	0	8	2
+	0	20	11
+	0	20	12
+	0	20	13
+	-1
+
+3	2	11
+	3	2	1
+	3	2	3
+	3	2	4
+	-1
+
+3	2	12
+	3	2	2
+	3	2	3
+	3	2	4
+	-1
+
+3	2	21
+	0	22	1
+	0	22	11
+	0	22	21
+	-1
+
+3	2	22
+	0	22	2
+	0	22	12
+	0	22	22
+	-1
+
+3	2	23
+	0	22	3
+	0	22	13
+	0	22	23
+	-1
+
+3	2	24
+	3	2	22
+	1	1	2
+	3	2	23
+	-1
+
+3	2	51
+	0	10	4
+	0	10	51
+	0	7	4
+	0	10	3
+	0	12	4
+	0	12	51
+	0	12	16
+	0	12	17
+	0	13	4
+	1	2	4
+	0	8	51
+	0	8	20
+	-1
+
+3	3	1
+	0	7	3
+	0	11	1
+	0	11	22
+	-1
+
+3	3	2
+	0	7	4
+	0	11	1
+	0	11	2
+	-1
+
+3	3	3
+	0	7	4
+	0	10	3
+	0	12	1
+	0	12	3
+	-1
+
+3	3	4
+	0	7	4
+	0	10	3
+	0	12	1
+	0	12	3
+	0	11	1
+	0	11	2
+	-1
+
+3	3	11
+	0	7	3
+	0	8	1
+	0	11	1
+	0	11	2
+	-1
+
+3	3	12
+	0	7	4
+	0	8	1
+	0	11	1
+	0	11	2
+	-1
+
+3	3	13
+	0	7	4
+	0	8	1
+	0	10	3
+	0	12	1
+	0	13	3
+	0	11	1
+	0	11	2
+	-1
+
+3	3	14
+	0	7	4
+	0	8	1
+	0	10	3
+	0	12	1
+	0	12	3
+	0	11	1
+	0	11	2
+	-1
+
+3	3	21
+	0	7	4
+	0	7	4
+	2	4	7
+	0	31	21
+	-1
+
+3	3	22
+	3	3	21
+	0	10	3
+	2	4	0
+	-1
+
+3	3	23
+	3	3	21
+	0	12	1
+	2	4	0
+	-1
+
+3	3	24
+	3	3	21
+	0	13	16
+	2	4	0
+	-1
+
+3	3	25
+	0	2	25
+	2	4	7
+	0	31	21
+	0	12	63
+	2	4	0
+	-1
+
+3	3	26
+	0	7	4
+	0	8	3
+	2	4	7
+	0	31	21
+	0	12	1
+	2	4	0
+	-1
+
+3	3	27
+	0	7	4
+	2	4	7
+	0	31	21
+	0	10	3
+	2	4	0
+	-1
+
+3	3	31
+	0	7	4
+	0	8	3
+	0	7	21
+	0	7	22
+	0	8	12
+	0	12	61
+	-1
+
+3	3	32
+	0	20	11
+	0	20	16
+	-1
+
+3	4	1
+	0	8	3
+	0	10	4
+	0	12	1
+	0	11	1
+	0	11	2
+	-1
+
+3	4	2
+	0	8	3
+	0	10	4
+	0	11	1
+	0	11	2
+	-1
+
+3	4	3
+	0	8	3
+	0	12	1
+	-1
+
+3	4	4
+	0	8	3
+	0	10	4
+	0	20	10
+	0	12	1
+	-1
+
+3	4	5
+	0	2	24
+	0	7	4
+	0	7	4
+	0	13	3
+	-1
+
+3	4	6
+	0	14	1
+	0	14	1
+	0	14	3
+	-1
+
+3	6	1
+	0	2	32
+	1	2	0
+	0	31	1
+	0	7	62
+	0	22	42
+	-1
+
+3	6	2
+	0	2	31
+	0	22	4
+	0	22	31
+	-1
+
+3	6	3
+	0	2	2
+	0	11	11
+	0	11	12
+	0	12	4
+	-1
+
+3	6	4
+	0	2	32
+	0	2	33
+	1	3	0
+	0	31	1
+	0	7	62
+	0	22	43
+	0	22	62
+	-1
+
+3	6	5
+	0	2	31
+	1	3	0
+	0	31	1
+	0	7	62
+	0	22	4
+	0	22	31
+	-1
+
+3	6	6
+	3	6	3
+	3	6	2
+	0	22	63
+	-1
+
+3	6	7
+	0	1	12
+	0	1	14
+	3	6	8
+	0	4	24
+	0	27	3
+	0	28	3
+	-1
+
+3	6	8
+	0	2	34
+	0	2	35
+	0	2	36
+	-1
+
+3	7	1
+	3	1	31
+	3	2	11
+	-1
+
+3	7	2
+	3	1	32
+	3	2	11
+	-1
+
+3	7	3
+	3	7	1
+	1	1	0
+	0	31	1
+	3	2	5
+	-1
+
+3	7	4
+	3	7	2
+	1	1	0
+	0	31	1
+	3	2	5
+	-1
+
+3	7	5
+	3	7	1
+	1	1	4
+	3	2	5
+	-1
+
+3	7	6
+	3	7	2
+	1	1	4
+	3	2	5
+	-1
+
+3	7	7
+	3	1	31
+	3	2	12
+	-1
+
+3	7	8
+	3	1	32
+	3	2	12
+	-1
+
+3	8	1
+	3	1	33
+	3	2	11
+	0	22	42
+	-1
+
+3	8	2
+	3	1	34
+	3	2	11
+	0	22	42
+	-1
+
+3	8	3
+	3	1	35
+	3	2	11
+	0	22	42
+	-1
+
+3	8	4
+	3	1	36
+	3	2	11
+	0	22	42
+	-1
+
+3	8	5
+	3	8	4
+	3	2	24
+	-1
+
+3	8	6
+	0	10	4
+	0	10	61
+	0	10	63
+	0	11	1
+	0	11	2
+	0	12	4
+	0	13	3
+	0	22	42
+	-1
+
+3	9	1
+	3	1	37
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	2
+	3	1	38
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	3
+	3	1	37
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	4
+	3	1	38
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	5
+	3	1	37
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	6
+	3	1	38
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	7
+	3	1	37
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	8
+	3	1	38
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	11
+	3	1	39
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	12
+	3	1	39
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	13
+	3	1	39
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	14
+	3	1	39
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	15
+	3	1	40
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	16
+	3	1	40
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	17
+	3	1	40
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	18
+	3	1	40
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	19
+	3	1	31
+	0	2	3
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	20
+	3	1	31
+	0	2	3
+	1	4	0
+	0	31	1
+	0	7	3
+	0	11	3
+	0	11	4
+	0	11	5
+	-1
+
+3	10	1
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	26
+	3	3	25
+	-1
+
+3	10	2
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	9
+	3	3	23
+	-1
+
+3	10	3
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	6
+	3	3	23
+	-1
+
+3	10	4
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	3
+	3	3	24
+	-1
+
+3	11	1
+	3	1	51
+	0	7	2
+	0	12	1
+	0	11	1
+	0	11	2
+	0	11	31
+	0	11	32
+	0	11	33
+	0	20	41
+	-1
+
+3	12	1
+	3	1	43
+	3	4	1
+	-1
+
+3	12	2
+	3	1	43
+	3	4	2
+	-1
+
+3	12	3
+	3	1	42
+	3	4	3
+	-1
+
+3	12	4
+	3	1	42
+	3	4	4
+	-1
+
+3	12	5
+	3	1	42
+	0	20	14
+	-1
+
+3	12	6
+	3	1	44
+	3	4	5
+	-1
+
+3	12	7
+	3	1	42
+	3	4	6
+	-1
+
+3	12	10
+	0	1	7
+	0	5	40
+	0	2	21
+	0	5	41
+	0	4	1
+	0	4	43
+	-1
+
+3	12	11
+	2	2	131
+	2	1	149
+	0	4	6
+	2	1	0
+	1	2	32
+	0	10	2
+	2	2	0
+	0	5	43
+	0	5	53
+	-1
+
+3	12	12
+	2	2	129
+	2	1	132
+	1	1	19
+	0	12	63
+	2	1	0
+	2	2	0
+	-1
+
+3	12	13
+	0	5	42
+	2	2	129
+	2	1	135
+	0	12	63
+	2	1	0
+	2	2	0
+	-1
+
+3	12	14
+	3	12	10
+	3	12	11
+	1	5	56
+	3	1	23
+	0	5	42
+	0	5	52
+	3	12	12
+	3	12	13
+	-1
+
+3	12	15
+	1	9	11
+	3	1	23
+	0	5	42
+	0	5	52
+	2	2	129
+	2	1	132
+	1	1	4
+	0	12	63
+	2	2	0
+	2	1	0
+	-1
+
+3	12	16
+	3	12	10
+	3	12	11
+	3	12	15
+	-1
+
+3	12	17
+	1	9	8
+	3	1	23
+	0	5	42
+	0	5	52
+	2	2	129
+	2	1	132
+	1	1	3
+	0	12	63
+	2	2	0
+	2	1	0
+	-1
+
+3	12	18
+	3	12	10
+	3	12	11
+	3	12	17
+	-1
+
+3	13	9
+	0	21	1
+	1	1	0
+	0	31	1
+	0	21	1
+	-1
+
+3	13	10
+	0	21	36
+	1	1	0
+	0	31	1
+	0	21	36
+	-1
+
+3	13	31
+	0	6	2
+	0	6	12
+	1	1	0
+	0	31	2
+	0	30	1
+	-1
+
+3	13	32
+	0	5	2
+	0	5	12
+	1	1	0
+	0	31	2
+	3	13	31
+	-1
+
+3	13	41
+	0	6	2
+	1	10	0
+	0	31	1
+	1	4	0
+	0	31	1
+	0	6	12
+	1	1	0
+	0	31	12
+	0	30	1
+	0	6	12
+	1	1	0
+	0	31	1
+	0	30	1
+	-1
+
+3	13	42
+	0	5	2
+	0	5	12
+	1	1	0
+	0	31	2
+	3	13	41
+	-1
+
+3	13	43
+	0	6	2
+	0	5	2
+	0	5	12
+	1	12	0
+	0	31	1
+	1	10	0
+	0	31	1
+	1	04	0
+	0	31	1
+	0	6	12
+	1	1	0
+	0	31	11
+	0	30	1
+	1	1	0
+	0	31	1
+	0	30	1
+	-1
+	
+3	15	1
+	0	1	11
+	3	1	11
+	3	1	12
+	3	1	23
+	3	6	1
+	-1
+
+3	15	2
+	0	1	11
+	3	1	11
+	3	1	12
+	3	1	23
+	3	6	4
+	-1
+
+3	16	1
+	3	1	11
+	0	4	4
+	3	1	23
+	0	1	21
+	0	2	41
+	0	19	1
+	0	10	51
+	0	19	2
+	0	19	3
+	0	19	4
+	-1
+
+3	18	1
+	3	1	25
+	0	24	11
+	-1
+
+3	18	3
+	3	1	26
+	0	24	5
+	0	24	4
+	0	24	21
+	-1
+
+3	18	4
+	3	1	25
+	0	4	23
+	0	13	11
+	0	24	5
+	0	24	4
+	0	24	22
+	-1
+
+3	21	1
+	0	2	101
+	0	2	114
+	0	2	105
+	0	2	106
+	0	2	107
+	0	2	121
+	-1
+
+3	21	3
+	0	21	51
+	0	21	14
+	0	21	17
+	0	21	30
+	-1
+
+3	21	4
+	3	1	31
+	0	2	3
+	1	1	0
+	0	31	1
+	3	21	3
+	-1
+
+3	21	5
+	0	25	4
+	0	2	121
+	0	2	122
+	0	2	123
+	0	2	124
+	0	2	125
+	0	2	126
+	0	2	127
+	0	2	128
+	0	2	129
+	0	2	130
+	0	2	131
+	-1
+
+3	21	6
+	0	25	1
+	0	25	2
+	0	25	3
+	0	25	5
+	-1
+
+3	21	7
+	0	25	9
+	0	25	10
+	0	25	11
+	0	25	12
+	0	25	13
+	0	25	15
+	0	25	16
+	0	25	17
+	-1
+
+3	21	8
+	0	25	6
+	0	25	7
+	0	25	8
+	-1
+
+3	21	9
+	0	25	18
+	0	25	19
+	-1
+
+3	21	10
+	0	2	101
+	0	7	2
+	0	2	102
+	0	2	103
+	0	2	104
+	0	2	105
+	0	2	106
+	0	2	107
+	0	2	108
+	0	2	109
+	0	2	110
+	0	2	132
+	0	2	133
+	-1
+
+3	21	11
+	0	30	31
+	0	30	32
+	0	29	2
+	-1
+
+3	21	12
+	1	1	0
+	0	31	1
+	0	2	135
+	0	2	135
+	-1
diff --git a/data/tables/B3L-058-000-B b/data/tables/B3L-058-000-B
new file mode 100644
index 0000000..3baba63
--- /dev/null
+++ b/data/tables/B3L-058-000-B
@@ -0,0 +1,520 @@
+#
+# BUFR Table B - Classification of Elements
+#
+# sccs keywords: @(#)Table_B.txt	1.1 05/07/97
+#					Data
+#F	X	Y	Scale	RefVal	Width	Units	Element Name
+  0;    0;      1;      0;           0;   24;    CCITT_IA5; Table A: entry
+  0;    0;      2;      0;           0;  256;    CCITT_IA5; Table A: data category description, line 1
+  0;    0;      3;      0;           0;  256;    CCITT_IA5; Table A: data category description, line 2
+  0;    0;      5;      0;           0;   24;    CCITT_IA5; BUFR edition number
+  0;    0;     10;      0;           0;    8;    CCITT_IA5; F descriptor to be added or defined
+  0;    0;     11;      0;           0;   16;    CCITT_IA5; X descriptor to be added or defined
+  0;    0;     12;      0;           0;   24;    CCITT_IA5; Y descriptor to be added or defined
+  0;    0;     13;      0;           0;  256;    CCITT_IA5; Element name, line 1
+  0;    0;     14;      0;           0;  256;    CCITT_IA5; Element name, line 2
+  0;    0;     15;      0;           0;  192;    CCITT_IA5; Units name
+  0;    0;     16;      0;           0;    8;    CCITT_IA5; Units scale sign
+  0;    0;     17;      0;           0;   24;    CCITT_IA5; Units scale
+  0;    0;     18;      0;           0;    8;    CCITT_IA5; Units reference sign
+  0;    0;     19;      0;           0;   80;    CCITT_IA5; Units reference value
+  0;    0;     20;      0;           0;   24;    CCITT_IA5; Element data width
+  0;    0;     30;      0;           0;   48;    CCITT_IA5; Descriptor defining sequence
+
+  0;    1;      1;      0;           0;    7;      Numeric; WMO block number
+  0;    1;      2;      0;           0;   10;      Numeric; WMO station number
+  0;    1;      3;      0;           0;    3;      Numeric; WMO region number
+  0;    1;      4;      0;           0;    3;      Numeric; WMO region sub-area
+  0;    1;      5;      0;           0;   17;      Numeric; Buoy/platform identifier
+  0;    1;      6;      0;           0;   64;    CCITT_IA5; Aircraft identifier (flight number)
+  0;    1;      7;      0;           0;   10;   Code_Table; Satellite identifier
+  0;    1;      8;      0;           0;   64;    CCITT_IA5; Aircraft registration number (tail number)
+  0;    1;      9;      0;           0;   64;    CCITT_IA5; Type of commerical aircraft
+  0;    1;     10;      0;           0;   64;    CCITT_IA5; Stationary buoy platform identifier
+  0;    1;     11;      0;           0;   72;    CCITT_IA5; Ship's call sign
+  0;    1;     12;      0;           0;    9;     deg_true; Direction of motion of moving observing platform
+  0;    1;     13;      0;           0;   10;          m/s; Speed of motion of moving observing platform
+  0;    1;     14;      2;           0;   10;          m/s; Platform drift speed (high precision)
+  0;    1;     21;      0;           0;   14;      Numeric; Synoptic feature identifier
+  0;    1;     25;      0;           0;   24;    CCITT_IA5; Storm identifier
+  0;    1;     26;      0;           0;   64;    CCITT_IA5; WMO storm name
+  0;    1;     31;      0;           0;   16;      Numeric; Generating center
+# Local descriptors?
+#0	1	50	0	0	48	CCITT_IA5	NMC report identifier
+#0	1	62	0	0	40	CCITT_IA5	National assigned station identifier
+  0;    1;     63;      0;           0;   64;    CCITT_IA5; ICAO location indicator
+
+  0;    2;      1;      0;           0;    2;   Code_Table; Type of station
+  0;    2;      2;      0;           0;    4;   Flag_Table; Type of instrumentation for wind measurement
+  0;    2;      3;      0;           0;    4;   Code_Table; Type of measuring instrumentation used
+  0;    2;      4;      0;           0;    4;   Code_Table; Type of instrumentation for evaporation measurement or type of crop for which evapotranspiration is reported
+  0;    2;      5;      2;           0;    7;          deg; Precision of temperature observed
+  0;    2;     11;      0;           0;    8;   Code_Table; Radiosonde type
+  0;    2;     12;      0;           0;    4;   Code_Table; Radiosonde computational method
+  0;    2;     13;      0;           0;    4;   Code_Table; Solar and infrared radiation correction
+  0;    2;     14;      0;           0;    7;   Code_Table; Tracking technique/status of system
+  0;    2;     15;      0;           0;    4;   Code_Table; Radiosonde completeness
+  0;    2;     21;      0;           0;    9;   Flag_Table; Satellite instrumentation data used in processing
+  0;    2;     22;      0;           0;    8;   Flag_Table; Satellite data processing technique used
+  0;    2;     23;      0;           0;    4;   Code_Table; Cloud motion computational method
+  0;    2;     24;      0;           0;    4;   Code_Table; Integrated mean humidity computational method
+  0;    2;     25;      0;           0;   25;   Flag_Table; Satellite channel(s) used in computation
+  0;    2;     26;      2;           0;   12;            m; Cross track resolution
+  0;    2;     27;      2;           0;   12;            m; Along track resolution
+# Local descriptors?
+#0	2	28	0	0	32	Flag_Table	Geostationary sounder satellite channels used
+#0	2	29	0	0	8	Flag_Table	Geostationary sounder satellite channels used
+  0;    2;     30;      0;           0;    3;   Flag_Table; GOES I/M parameter calculation data source
+  0;    2;     31;      0;           0;    5;   Code_Table; Method of current measurement
+  0;    2;     32;      0;           0;    2;   Code_Table; Indicator for digitization
+  0;    2;     33;      0;           0;    3;   Code_Table; Method of salinity/depth measurement
+  0;    2;     34;      0;           0;    5;   Code_Table; Drogue type
+  0;    2;     35;      0;           0;    9;            m; Cable length
+  0;    2;     36;      0;           0;    2;   Code_Table; Buoy type
+  0;    2;     41;      0;           0;    6;   Code_Table; Method for estimating reports related to synoptic features
+  0;    2;     42;      0;           0;    6;   Code_Table; Method of report construction
+  0;    2;     43;      0;           0;    6;   Code_Table; Precision of latitude/longitude report
+  0;    2;     61;      0;           0;    3;   Code_Table; Aircraft navigation system
+  0;    2;     62;      0;           0;    4;   Code_Table; Type of aircraft data relay system
+  0;    2;     63;      2;      -18000;   16;          deg; Aircraft roll angle
+  0;    2;     70;      0;           0;    4;   Code_Table; Original specification of latitude/longitude
+  0;    2;    101;      0;           0;    4;   Code_Table; Type of antenna
+  0;    2;    102;      0;           0;    8;            m; Antenna height above tower
+  0;    2;    103;      0;           0;    2;   Flag_Table; Radome
+  0;    2;    104;      0;           0;    4;   Code_Table; Antenna polarisation
+  0;    2;    105;      0;           0;    6;           dB; Maximum antenna gain
+  0;    2;    106;      1;           0;    6;          deg; 3-dB bandwidth
+  0;    2;    107;      0;           0;    6;           dB; Sidelobe suppression
+  0;    2;    108;      0;           0;    6;           dB; Crosspol discrimination (on axis)
+  0;    2;    109;      2;           0;   12;        deg/s; Antenna speed (azimuth)
+  0;    2;    110;      2;           0;   12;        deg/s; Antenna speed (elevation)
+  0;    2;    111;      1;           0;   10;          deg; Radar incidence angle
+  0;    2;    112;      1;           0;   12;          deg; Radar azimuth angle
+  0;    2;    113;      0;           0;    4;      Numeric; Number of azimuth looks
+  0;    2;    114;      0;           0;   15;         m**2; Antenna effective surface area
+  0;    2;    121;     -8;           0;    7;           Hz; Mean frequency
+  0;    2;    122;     -6;        -128;    8;           Hz; Frequency agility range
+  0;    2;    123;     -4;           0;    7;            W; Peak power
+  0;    2;    124;     -1;           0;    7;            W; Average power
+  0;    2;    125;     -1;           0;    8;           Hz; Pulse repetition frequency
+  0;    2;    126;      7;           0;    6;            s; Pulse width
+  0;    2;    127;     -6;           0;    7;           Hz; Receiver intermediate frequency
+  0;    2;    128;     -5;           0;    6;           Hz; Intermediate frequency bandwidth
+  0;    2;    129;      0;        -150;    5;           dB; Minimum detectable signal
+  0;    2;    130;      0;           0;    7;           dB; Dynamic range
+  0;    2;    131;      0;           0;    2;   Flag_Table; Sensitivity time control
+  0;    2;    132;      2;           0;    6;          deg; Azimuth pointing accuracy
+  0;    2;    133;      2;           0;    6;          deg; Elevation pointing accuracy
+  0;    2;    134;      2;           0;   16;          deg; Antenna beam azimuth
+  0;    2;    135;      2;       -9000;   15;          deg; Antenna elevation
+  0;    2;    190;      0;           0;    8;   Code_Table; U, v quality indicator
+  0;    2;    191;      0;           0;    4;   Code_Table; W quality indicator
+
+  0;    4;      1;      0;           0;   12;         Year; Year
+  0;    4;      2;      0;           0;    4;           mo; Month
+  0;    4;      3;      0;           0;    6;          Day; Day
+  0;    4;      4;      0;           0;    5;           hr; Hour
+  0;    4;      5;      0;           0;    6;          min; Minute
+  0;    4;      6;      0;           0;    6;            s; Second
+  0;    4;     11;      0;       -1024;   11;         Year; Time increment
+  0;    4;     12;      0;       -1024;   11;           mo; Time increment
+  0;    4;     13;      0;       -1024;   11;         Days; Time increment
+  0;    4;     14;      0;       -1024;   11;           hr; Time increment
+  0;    4;     15;      0;       -2048;   12;          min; Time increment
+  0;    4;     16;      0;       -4096;   13;            s; Time increment
+  0;    4;     21;      0;       -1024;   11;         Year; Time period or displacement
+  0;    4;     22;      0;       -1024;   11;           mo; Time period or displacement
+  0;    4;     23;      0;       -1024;   11;         Days; Time period or displacement
+  0;    4;     24;      0;       -2048;   12;           hr; Time period or displacement
+  0;    4;     25;      0;       -2048;   12;          min; Time period or displacement
+  0;    4;     26;      0;       -4096;   13;            s; Time period or displacement
+  0;    4;     31;      0;           0;    8;           hr; Duration of time relative to followinG value
+  0;    4;     43;      0;           0;    9;          Day; Day of the year
+  0;    4;     44;      0;           0;    3;   Code_Table; Day of the week
+
+  0;    5;      1;      5;    -9000000;   25;          deg; Latitude (high accuracy)
+  0;    5;      2;      2;       -9000;   15;          deg; Latitude (coarse accuracy)
+  0;    5;      3;      2;       -9000;   15;          deg; Alternate latitude
+  0;    5;     11;      5;    -9000000;   25;          deg; Latitude increment (high accuracy)
+  0;    5;     12;      2;       -9000;   15;          deg; Latitude increment (coarse accuracy)
+  0;    5;     21;      2;           0;   16;     deg_true; Bearing or azimuth
+  0;    5;     22;      2;           0;   16;     deg_true; Solar azimuth
+  0;    5;     30;      0;           0;   12;          deg; Direction (spectral)
+  0;    5;     31;      0;           0;   12;      Numeric; Row number
+  0;    5;     33;     -1;           0;   16;            m; Pixel size on horizontal - 1
+  0;    5;     40;      0;           0;   24;      Numeric; Orbit number
+  0;    5;     41;      0;           0;    8;      Numeric; Scan line number
+  0;    5;     42;      0;           0;    6;      Numeric; Channel number
+  0;    5;     43;      0;           0;    8;      Numeric; Field of view number
+  0;    5;     50;      5;           0;   17;      Numeric; Sigma level
+  0;    5;     52;      0;           0;    5;      Numeric; Channel number increment
+  0;    5;     53;      0;           0;    5;      Numeric; Field of view number increment
+
+  0;    6;      1;      5;   -18000000;   26;          deg; Longtiude (high accuracy)
+  0;    6;      2;      2;      -18000;   16;          deg; Longtiude (coarse accuracy)
+  0;    6;      3;      2;      -18000;   16;          deg; Alternate longtiude
+  0;    6;     11;      5;   -18000000;   26;          deg; Longtiude increment (high accuracy)
+  0;    6;     12;      2;      -18000;   16;          deg; Longtiude increment (coarse accuracy)
+  0;    6;     21;     -1;           0;   13;            m; Distance
+  0;    6;     30;      5;           0;   13;        rad/m; Wavenumber (spectral)
+  0;    6;     31;      0;           0;   12;      Numeric; Column number
+  0;    6;     33;     -1;           0;   16;            m; Pixel size on horizontal - 2
+
+  0;    7;      1;      0;        -400;   15;            m; Height of station
+  0;    7;      2;     -1;         -40;   16;            m; Height or altitude
+  0;    7;      3;     -1;        -400;   17;    m**2/s**2; Geopotential
+  0;    7;      4;     -1;           0;   14;           Pa; Pressure
+  0;    7;      5;      0;        -400;   12;            m; Height increment
+  0;    7;      6;      0;           0;   15;            m; Height above station
+  0;    7;     21;      2;       -9000;   15;          deg; Elevation
+  0;    7;     22;      2;       -9000;   15;          deg; Solar elevation
+  0;    7;     61;      2;           0;   14;            m; Depth below land surface
+  0;    7;     62;      1;           0;   17;            m; Depth below sea surface
+  0;    7;    190;      0;           0;   12;            m; Height increment
+
+  0;    8;      1;      0;           0;    7;   Flag_Table; Vertical sounding significance
+  0;    8;      2;      0;           0;    6;   Code_Table; Vertical significance (surface observations)
+  0;    8;      3;      0;           0;    6;   Code_Table; Vertical significance (satellite observations)
+  0;    8;      4;      0;           0;    3;   Code_Table; Phase of aircraft flight
+  0;    8;      5;      0;           0;    4;   Code_Table; Surface synoptic features significance
+  0;    8;      0;      0;           0;    4;   Code_Table; Vertical significance (forecast soundings)
+  0;    8;     11;      0;           0;    6;   Code_Table; Horizontal significance
+  0;    8;     12;      0;           0;    2;   Code_Table; land/sea qualifier
+  0;    8;     13;      0;           0;    2;   Code_Table; Day/night qualifier
+  0;    8;     21;      0;           0;    5;   Code_Table; Time significance
+  0;    8;     22;      0;           0;   16;      Numeric; Total number (with respect to accumulation or average)
+  0;    8;     31;      0;           0;    8;         BUFR; Table A	Data category
+  0;    8;     32;      0;           0;   14;   Code_Table; Data significance for simulated forecast
+  0;    8;     33;      0;           0;    3;   Code_Table; Data significance for corrected forecast
+  0;    8;     34;      0;           0;    3;   Code_Table; Data significance for simulated retrievals
+  0;    8;     35;      0;           0;    3;   Code_Table; Data significance for corrected retrievals
+  0;    8;     36;      0;           0;    3;   Code_Table; Data significance for simulated analysis
+  0;    8;     37;      0;           0;    3;   Code_Table; Data significance for corrected analysis
+  0;    8;     38;      0;           0;    3;   Code_Table; Data significance for sigma level data
+
+  0;   10;      1;      0;        -400;   15;            m; Height of land surface
+  0;   10;      2;     -1;         -40;   16;            m; Height
+  0;   10;      3;     -1;        -400;   17;    m**2/s**2; Geopotential
+  0;   10;      4;     -1;           0;   14;           Pa; Pressure
+  0;   10;     50;      2;           0;   16;            m; Standard deviation altitude
+  0;   10;     51;     -1;           0;   14;           Pa; Pressure reduced to mean sea level
+  0;   10;     52;     -1;           0;   14;           Pa; Altimeter setting (QNH)
+  0;   10;     60;     -1;       -1024;   11;           Pa; Pressure change
+  0;   10;     61;     -1;        -500;   10;           Pa; 3 hour pressure change
+  0;   10;     62;     -1;       -1000;   11;           Pa; 24 hour pressure change
+  0;   10;     63;      0;           0;    4;   Code_Table; Characteristic of pressure tendency
+
+  0;   11;      1;      0;           0;    9;     deg_true; Wind direction
+  0;   11;      2;      1;           0;   12;          m/s; Wind speed
+  0;   11;      3;      1;       -4096;   13;          m/s; U-component
+  0;   11;      4;      1;       -4096;   13;          m/s; V-component
+  0;   11;      5;      1;        -512;   10;         Pa/s; W-component
+  0;   11;      6;      2;       -4096;   13;          m/s; W-component
+  0;   11;     11;      0;           0;    9;     deg_true; Wind direction at 10 m
+  0;   11;     12;      1;           0;   12;          m/s; Wind speed at 10 m
+  0;   11;     13;      0;           0;    9;     deg_true; Wind direction at 5 m
+  0;   11;     14;      1;           0;   12;          m/s; Wind speed at 5 m
+  0;   11;     21;      9;      -65536;   17;        s**-1; Relative vorticity
+  0;   11;     22;      9;      -65536;   17;        s**-1; Divergence
+  0;   11;     23;     -2;      -65536;   17;       m**2/s; Velocity potential
+  0;   11;     31;      0;           0;    4;   Code_Table; Degree of turbulence
+  0;   11;     32;     -1;         -40;   16;            m; Height of base of turbulence
+  0;   11;     33;     -1;         -40;   16;            m; Height of top of turbulence
+  0;   11;     34;      1;       -1024;   11;          m/s; Vertical gust velocity
+  0;   11;     35;      2;       -8192;   14;       m/s**2; Vertical gust acceleration
+  0;   11;     36;      1;           0;   10;         m/si; Maximum derived equivalent vertical gust
+  0;   11;     41;      1;           0;   12;          m/s; Maximum wind speed (gusts)
+  0;   11;     42;      1;           0;   12;          m/s; Maximum wind speed (10 minute mean wind)
+  0;   11;     43;      1;           0;   12;          m/s; Surface - 5000 feet mean LYR wind speed
+  0;   11;     44;      0;           0;    9;     deg_true; Surface - 5000 feet mean LYR wind direction
+  0;   11;     45;      0;           0;    9;     deg_true; Maximum wind (gust) direction
+  0;   11;     50;      1;           0;   12;          m/s; Standard deviation horizontal wind speed
+  0;   11;     51;      1;           0;    8;          m/s; Standard deviation vertical wind component
+  0;   11;     61;      1;           0;   12;          m/s; Absolute wind shear (1 kilometer layer below)
+  0;   11;     62;      1;           0;   12;          m/s; Absolute wind shear (1 kilometer layer above)
+
+  0;   12;      1;      1;           0;   12;        deg_K; Temperature/dry bulb temperature
+  0;   12;      2;      1;           0;   12;        deg_K; Wet bulb temperature
+  0;   12;      3;      1;           0;   12;        deg_K; Dewpoint temperature
+  0;   12;      4;      1;           0;   12;        deg_K; Dry bulb temperature at 2 meters
+  0;   12;      5;      1;           0;   12;        deg_K; Wet bulb temperature at 2 meters
+  0;   12;      6;      1;           0;   12;        deg_K; Dewpoint temperature at 2 meters
+  0;   12;      7;      1;           0;   12;        deg_K; Virtual temperature
+  0;   12;     11;      1;           0;   12;        deg_K; Maximum temperature
+  0;   12;     12;      1;           0;   12;        deg_K; Minimum temperature
+  0;   12;     13;      1;           0;   12;        deg_K; Ground minimum temperature past 12 hours
+  0;   12;     14;      1;           0;   12;        deg_K; Maximum temperature at 2 meters, past 12 hours
+  0;   12;     15;      1;           0;   12;        deg_K; Minimum temperature at 2 meters, past 12 hours
+  0;   12;     16;      1;           0;   12;        deg_K; Maximum temperature at 2 meters, past 24 hours
+  0;   12;     17;      1;           0;   12;        deg_K; Minimum temperature at 2 meters, past 24 hours
+  0;   12;     20;      2;       -2000;   12;    deg_K/day; Radiative heating profile
+  0;   12;     30;      1;           0;   12;        deg_K; Soil temperature
+  0;   12;     40;     -3;       -2048;   12;       W/m**2; Sensible heat flux
+  0;   12;     61;      1;           0;   12;        deg_K; Skin temperature
+  0;   12;     62;      1;           0;   12;        deg_K; Equivalent black body temperature
+  0;   12;     63;      1;           0;   12;        deg_K; Brightness temperature
+
+  0;   13;      1;      5;           0;   14;        kg/kg; Specific humidity
+  0;   13;      2;      5;           0;   14;        kg/kg; Mixing ratio
+  0;   13;      3;      0;           0;    7;      percent; Relative humidity
+  0;   13;      4;     -1;           0;   10;           Pa; Vapor pressure
+  0;   13;      5;      3;           0;    7;      kg/m**3; Vapor density
+  0;   13;      6;     -1;         -40;   16;            m; Mixing heights
+  0;   13;     11;      4;          -1;   14;      kg/m**2; Total precipitation/total water equivalent
+  0;   13;     12;      2;          -2;   12;            m; Depth of fresh snow
+  0;   13;     13;      2;          -2;   16;            m; Total snow depth
+  0;   13;     14;      4;           0;   12;    kg/m**2/s; Rainfall/water equivalent of snow (average rate)
+  0;   13;     15;      7;           0;   12;          m/s; Snowfall (averaged rate)
+  0;   13;     16;      0;           0;    7;      kg/m**2; Precipitable water
+  0;   13;     19;      1;          -1;   14;      kg/m**2; Total precipitation past 1 hour
+  0;   13;     20;      1;          -1;   14;      kg/m**2; Total precipitation past 3 hours
+  0;   13;     21;      1;          -1;   14;      kg/m**2; Total precipitation past 6 hours
+  0;   13;     22;      1;          -1;   14;      kg/m**2; Total precipitation past 12 hours
+  0;   13;     23;      1;          -1;   14;      kg/m**2; Total precipitation past 24 hours
+  0;   13;     31;      0;           0;    7;      kg/m**2; Evapotranspiration
+  0;   13;     32;      1;           0;    8;      kg/m**2; Evaporation/evapotranspiration
+  0;   13;     40;     -3;       -2048;   12;       W/m**2; Latent heat flux
+  0;   13;     41;      0;           0;    4;   Code_Table; Pasquill-Gifford stability category
+  0;   13;     42;      0;         -20;    6;        deg_K; US NWS lifted index
+
+  0;   14;      1;     -3;       -2048;   12;  Joules/m**2; Longwave radiation, integrated over 24 hours
+  0;   14;      3;     -3;       -2048;   12;  Joules/m**2; Shortwave radiation, integrated over 24 hours
+  0;   14;      4;     -3;       -2048;   12;  Joules/m**2; Shortwave radiation, integrated over period specified
+  0;   14;     11;     -3;       -2048;   12;  Joules/m**2; Net longwave radiation, integrated over 24 hours
+  0;   14;     12;     -3;       -2048;   12;  Joules/m**2; Net longwave radiation, integrated over period specified
+  0;   14;     13;     -3;       -2048;   12;  Joules/m**2; Net shortwave radiation, integrated over 24 hours
+  0;   14;     14;     -3;       -2048;   12;  Joules/m**2; Net shortwave radiation, integrated over period specified
+  0;   14;     15;     -4;      -16384;   15;  Joules/m**2; Net radiation, integrated over 24 hours
+  0;   14;     16;     -4;      -16384;   15;  Joules/m**2; Net radiation, integrated over period specified
+  0;   14;     17;     -3;       -2048;   12;       W/m**2; Instantaneous long wave radiation
+  0;   14;     18;     -3;       -2048;   12;       W/m**2; Instantaneous short wave radiation
+  0;   14;     19;      0;           0;    7;      percent; Surface albedo
+  0;   14;     20;     -4;           0;   15;  Joules/m**2; Global solar radiation, integrated over 24 hours
+  0;   14;     21;     -4;           0;   15;  Joules/m**2; Global radiation, integrated over period specified
+  0;   14;     22;     -4;           0;   15;  Joules/m**2; Diffuse solar radiation, integrated over 24 hours
+  0;   14;     23;     -4;           0;   15;  Joules/m**2; Diffuse solar radiation, integratedi over period specified
+  0;   14;     24;     -4;           0;   15;  Joules/m**2; Direct solar radiation, integrated over 24 hours
+  0;   14;     25;     -4;           0;   15;  Joules/m**2; Direct solar radiation, integrated over period specified
+  0;   14;     31;      0;           0;   11;          min; Total sunshine
+  0;   14;     32;      0;           0;   10;           hr; Total sunshine
+  0;   14;     41;      0;           0;    7;      percent; Short wave albedo
+  0;   14;     42;      0;           0;    7;      percent; Bi-directional reflectance
+
+  0;   15;      1;      0;           0;   10;       Dobson; units	Ozone
+
+  0;   19;      1;      0;           0;    6;   Code_Table; Type of synoptic features
+  0;   19;      2;     -2;           0;   12;            m; Effective radius of feature
+  0;   19;      3;      0;           0;    8;          m/s; Wind speed threshold
+  0;   19;      4;     -2;           0;   12;            m; Effective radius of feature with respect to wind speeds above threshold
+  0;   19;      5;      0;           0;    9;     deg_true; Direction of motion of features
+  0;   19;      6;      2;           0;   14;          m/s; Speed of motion of features
+  0;   19;      7;     -3;           0;   12;            m; Effective radius of features
+  0;   19;      8;      0;           0;    3;   Code_Table; Vertical extent of circulation
+  0;   19;      9;     -3;           0;   12;            m; Effective radiation with respect to FFF above threshold
+
+  0;   20;      1;     -1;           0;   13;            m; Horizontal visibility
+  0;   20;      2;     -1;           0;    7;            m; Vertical visibility
+  0;   20;      3;      0;           0;    9;   Code_Table; Present weather
+  0;   20;      4;      0;           0;    5;   Code_Table; Past weather (1)
+  0;   20;      5;      0;           0;    5;   Code_Table; Past weather (2)
+  0;   20;      9;     -1;         -40;   11;            m; Ceiling
+  0;   20;     10;      0;           0;    7;      percent; Cloud cover (total)
+  0;   20;     11;      0;           0;    4;   Code_Table; Cloud amount
+  0;   20;     12;      0;           0;    6;   Code_Table; Cloud type
+  0;   20;     13;     -1;         -40;   11;            m; Height of base of cloud
+  0;   20;     14;     -1;         -40;   11;            m; Height of top of cloud
+  0;   20;     15;     -1;           0;   14;           Pa; Pressure at the base of cloud
+  0;   20;     16;     -1;           0;   14;           Pa; Pressure at the top of cloud
+  0;   20;     17;      0;           0;    4;   Code_Table; Cloud top description
+  0;   20;     18;     -1;          40;   11;            m; Low estimated height of cloud top
+  0;   20;     19;     -1;          40;   11;            m; High estimated height of cloud top
+  0;   20;     20;      0;           0;    4;   Code_Table; Low cloud amount
+  0;   20;     21;      0;           0;    4;   Code_Table; Middle cloud amount
+  0;   20;     22;      0;           0;    4;   Code_Table; High cloud amount
+  0;   20;     23;      0;           0;    7;      percent; Satellite sensed effective cloud amount
+  0;   20;     31;      2;           0;    7;            m; Ice deposit (thickness)
+  0;   20;     32;      0;           0;    3;   Code_Table; Rate of ice accretion
+  0;   20;     33;      0;           0;    4;   Flag_Table; Cause of ice accretion
+  0;   20;     34;      0;           0;    5;   Code_Table; Sea ice concentration
+  0;   20;     35;      0;           0;    4;   Code_Table; Amount and type of ice
+  0;   20;     36;      0;           0;    5;   Code_Table; Ice situation
+  0;   20;     37;      0;           0;    5;   Code_Table; Ice development
+  0;   20;     38;      0;           0;   12;     deg_true; Bearing of ice edge
+  0;   20;     39;     -1;           0;   13;            m; Ice distance
+  0;   20;     41;      0;           0;    4;   Code_Table; Airframe icing
+  0;   20;     49;      0;           0;   10;   Code_Table; Type of stability measure
+  0;   20;     50;      0;           0;   10;      Numeric; Value of stability
+  0;   20;     51;      0;           0;    7;      percent; Amount of low clouds
+  0;   20;     52;      0;           0;    7;      percent; Amount of middle clouds
+  0;   20;     53;      0;           0;    7;      percent; Amount of high clouds
+  0;   20;     61;      0;           0;   12;            m; Runway visual range (RVR)
+  0;   20;     62;      0;           0;    5;   Code_Table; State of the ground(with or without snow)
+  0;   20;     63;      0;           0;   10;   Code_Table; Special phenomena
+
+  0;   21;      1;      0;         -64;    7;           dB; Horizontal reflectivity
+  0;   21;      2;      0;         -64;    7;           dB; Vertical reflectivity
+  0;   21;      3;      1;          -5;    7;           dB; Differential reflectivity
+  0;   21;      5;      0;         -65;    6;           dB; Linear depolarization ratio
+  0;   21;      6;      0;         -65;    6;           dB; Circular depolarization ratio
+  0;   21;     11;      0;        -128;    8;          m/s; Doppler mean velocity in X direction
+  0;   21;     12;      0;        -128;    8;          m/s; Doppler mean velocity in Y direction
+  0;   21;     13;      0;        -128;    8;          m/s; Doppler mean velocity in Z direction
+  0;   21;     14;      1;       -4096;   13;          m/s; Doppler mean velocity (radiational)
+  0;   21;     17;      1;       -4096;    8;          m/s; Doppler velocity spectral width
+  0;   21;     21;     -3;           0;    4;            m; Echo tops
+  0;   21;     30;      0;         -32;    8;           dB; Signal to noise ratio
+  0;   21;     31;      0;           0;    7;      kg/m**2; Vertical integrated liquid water content
+  0;   21;     36;      7;           0;   12;          m/s; Radar rainfall intensity
+  0;   21;     41;     -2;           0;    8;            m; Bright band height
+  0;   21;     51;      0;        -256;    8;           dB; Signal power above 1 MW
+
+  0;   22;      1;      0;           0;    9;     deg_true; Direction of waves
+  0;   22;      2;      0;           0;    9;     deg_true; Direction of wind waves
+  0;   22;      3;      0;           0;    9;     deg_true; Direction of swell waves
+  0;   22;      4;      0;           0;    9;     deg_true; Direction of current waves
+  0;   22;     11;      0;           0;    6;            s; Period of waves
+  0;   22;     12;      0;           0;    6;            s; Period of wind waves
+  0;   22;     13;      0;           0;    6;            s; Period of swell waves
+  0;   22;     21;      1;           0;   10;            m; Height of waves
+  0;   22;     22;      1;           0;   10;            m; Height of wind waves
+  0;   22;     23;      1;           0;   10;            m; Height of swell waves
+  0;   22;     25;      2;           0;   10;            m; Standard deviation wave
+  0;   22;     31;      2;           0;   13;          m/s; Speed of current
+  0;   22;     41;      1;           0;   12;        deg_K; Sea surface temperature (15 day running mean)
+  0;   22;     42;      1;           0;   12;        deg_K; Sea temperature
+  0;   22;     43;      2;           0;   15;        deg_K; Sea temperature
+  0;   22;     44;      1;           0;   14;          m/s; Sound velocity
+  0;   22;     50;      2;           0;    8;            K; Standard deviation sea surface temperature
+  0;   22;     61;      0;           0;    4;   Code_Table; State of sea
+  0;   22;     62;      2;           0;   12;          ppt; Salinity
+  0;   22;     63;      0;           0;   14;            m; Total water depth
+  0;   22;    105;     -1;           0;    6;     deg_true; Direction of waves
+  0;   22;    143;      2;        2650;   13;        deg_K; Sea temperature
+
+  0;   23;      1;      0;           0;    3;   Code_Table; Accident early notification - article applicable
+  0;   23;      2;      0;           0;    5;   Code_Table; Activity or facility involved in incident
+  0;   23;      3;      0;           0;    3;   Code_Table; Type of release
+  0;   23;      4;      0;           0;    3;   Code_Table; Countermeasures taken near border
+  0;   23;      5;      0;           0;    2;   Code_Table; Cause of incident
+  0;   23;      6;      0;           0;    3;   Code_Table; Incident situation
+  0;   23;      7;      0;           0;    3;   Code_Table; Characteristic of release
+  0;   23;      8;      0;           0;    2;   Code_Table; State of current release
+  0;   23;      9;      0;           0;    2;   Code_Table; State of expected release
+  0;   23;     16;      0;           0;    2;   Code_Table; Possibility of significant chemical toxic health effect
+  0;   23;     17;      6;           0;   20;       m**3/s; Flow discharge of major recipient
+  0;   23;     18;      0;           0;    3;   Code_Table; release behavior over time
+  0;   23;     19;      0;      -15000;   17;            m; Actual release height
+  0;   23;     21;      0;      -15000;   17;            m; Effective release height
+  0;   23;     22;      0;           0;   24;            m; Distance of relative point or site of incident
+  0;   23;     23;      1;           0;   12;          m/s; Main transport speed in atmosphere
+  0;   23;     24;      2;           0;   13;          m/s; Main transport speed in water
+  0;   23;     25;      2;           0;   13;          m/s; Main transport speed in ground water
+  0;   23;     27;      0;           0;    9;     deg_true; Main transport direction in atmosphere
+  0;   23;     28;      0;           0;    9;     deg_true; Main transport direction in water
+  0;   23;     29;      0;           0;    9;     deg_true; Main transport direction in ground water
+  0;   23;     31;      0;           0;    2;   Code_Table; Possibility that plume will encounter precipitation cwin state in which incident occurred
+  0;   23;     32;      0;           0;    2;   Code_Table; Plume will encounter ichange in wind direction and/or speed flag
+
+  0;   24;      1;     -1;           0;   28;           Bq; Estimate of radiatioactivity released up to specified time
+  0;   24;      2;     -1;           0;   28;           Bq; Estimated maximum potential release
+  0;   24;      3;      0;           0;    5;   Code_Table; Composition of release
+  0;   24;      4;      0;           0;   16;    CCITT_IA5; Element name
+  0;   24;      5;      0;           0;    9;      Numeric; Isotope mass
+  0;   24;     11;      2;           0;   32;          mSv; Dose
+  0;   24;     12;      2;           0;   32;          mSv; Trajectory dose (defined location and expected time of arrival)
+  0;   24;     13;      2;           0;   32;          mSv; Gamma dose in air along the main transport path (defined location and time period
+  0;   24;     21;      2;           0;   32;      Bq/m**3; Air concentration (named isotope type including gross beta)
+  0;   24;     22;      2;           0;   32;         Bq/l; Concentration in precipitation (of named isotope type)
+
+  0;   25;      1;     -1;           0;    6;            m; Range gate length
+  0;   25;      2;      0;           0;    4;      Numeric; Number of gates averaged
+  0;   25;      3;      0;           0;    8;      Numeric; Number of integrated pulses
+  0;   25;      4;      0;           0;    2;   Code_Table; Echo processing
+  0;   25;      5;      0;           0;    2;   Code_Table; Echo integration
+  0;   25;      6;      0;           0;    3;   Code_Table; Z to R conversion
+  0;   25;      7;      0;           0;   12;      Numeric; Z to R conversion factor
+  0;   25;      8;      2;           0;    9;      Numeric; Z to R conversion exponent
+  0;   25;      9;      0;           0;    4;   Flag_Table; Calibration method
+  0;   25;     10;      0;           0;    4;   Code_Table; Clutter treatment
+  0;   25;     11;      0;           0;    2;   Code_Table; Ground occultation correction (screening)
+  0;   25;     12;      0;           0;    2;   Code_Table; Range attenuation correction
+  0;   25;     13;      0;           0;    2;   Flag_Table; Bright band correction
+  0;   25;     15;      0;           0;    2;   Flag_Table; Radome attenuation correction
+  0;   25;     16;      5;           0;    6;         dB/m; Clear air attenuation correction
+  0;   25;     17;      0;           0;    2;   Flag_Table; Precipitation attenuation correction
+  0;   25;     18;      7;           0;    6;      Numeric; A to Z law for attenuation factor
+  0;   25;     19;      2;           0;    7;      Numeric; A to Z law for attenuation exponent
+  0;   25;     20;      0;           0;    2;   Code_Table; Mean speed estimation
+  0;   25;     21;      0;           0;    8;   Flag_Table; Wind computation enhancement
+  0;   25;     30;      0;           0;    2;   Code_Table; SST usage
+  0;   25;     31;      0;           0;    2;   Code_Table; 15 day SST availability
+  0;   25;     32;      0;           0;    2;   Code_Table; NOAA wind profiler high/low mode data
+  0;   25;     33;      0;           0;    2;   Code_Table; NOAA wind profiler submode
+  0;   25;     34;      0;           0;    4;   Code_Table; NOAA wind profiler Q/C test results
+  0;   25;     35;      0;           0;    3;   Code_Table; First guess adjustment
+  0;   25;     36;      3;       -5000;   14;      Numeric; NSTAR average value
+  0;   25;     37;      0;           0;    2;   Code_Table; HIRS-8 surface air temperature
+  0;   25;     38;      0;           0;    3;   Code_Table; TOVS filter flags
+
+  0;   27;      1;      5;    -9000000;   25;          deg; Latitude (high accuracy)
+  0;   27;      2;      2;       -9000;   15;          deg; Latitude (coarse accuracy)
+  0;   27;      3;      2;       -9000;   15;          deg; Alternate latitude
+  0;   27;     20;      0;           0;   16;      Numeric; Satellite locationon counter
+  0;   27;     21;      0;           0;   16;      Numeric; Satellite sub-locationon dimensions
+
+  0;   28;      1;      5;   -18000000;   26;          deg; Longtiude (high accuracy)
+  0;   28;      2;      2;      -18000;   16;          deg; Longtiude (coarse accuracy)
+  0;   28;      3;      2;      -18000;   16;          deg; Alternate longtiude
+
+  0;   29;      1;      0;           0;    3;   Code_Table; Projection type
+  0;   29;      2;      0;           0;    2;   Code_Table; Coordinate grid type
+
+  0;   30;      1;      0;           0;    4;      Numeric; Pixel value (4 bits)
+  0;   30;     21;      0;           0;   12;      Numeric; Number of pixels per row
+  0;   30;     22;      0;           0;   12;      Numeric; Number of pixels per column
+  0;   30;     31;      0;           0;    4;   Code_Table; Picture type
+  0;   30;     32;      0;           0;   16;   Flag_Table; Combined picture
+
+  0;   31;      0;      0;           0;    1;   Flag_Table; Delayed descriptor replication switch
+  0;   31;      1;      0;           0;    8;      Numeric; Delayed descriptor replication factor
+  0;   31;      2;      0;           0;   16;      Numeric; Extended delayed descriptor replication factor
+  0;   31;     11;      0;           0;    8;      Numeric; Delayed descriptor and data repetion factor
+  0;   31;     12;      0;           0;   16;      Numeric; Extended delayed descriptor and data repitition factor
+  0;   31;     21;      0;           0;    6;   Code_Table; Associated field significance
+
+#0	0	0	0	0	0	undef	undefined used for SSMI - temporary
+
+  0;   50;    200;      2;      636700;   24;           km; Altitude(km)
+  0;   50;    201;      6;           0;   24;  Rad(Si)/sec; Dosage
+  0;   50;    202;      6;           0;   24;        Gauss; B-Field
+  0;   50;    203;      3;      -20000;   24;           Re; Coordinate
+  0;   50;    204;      3;           0;   24;            -; L-Shell
+
+  0;   51;    200;     -2;           0;   24; KeV/(cm2-s-Sr); e-Energy Flux
+  0;   51;    201;     -2;           0;   24; #/(cm2-s-Sr); e-Number Flux
+  0;   51;    202;     -2;           0;   24; KeV/(cm2-s-Sr); i-Energy Flux
+  0;   51;    203;     -2;           0;   24; #/(cm2-s-Sr); i-Number Flux
+  0;   51;    204;      6;         -10;   24;         mhos; Ped Conduct.
+  0;   51;    205;      6;         -10;   24;         mhos; Hall Conduct.
+
+  0;   52;    200;      5;           0;   26;            -; S4
+  0;   52;    201;      5;           0;   25;            -; SI
+  0;   52;    202;      5;           0;   24;            -; PCT
+  0;   52;    203;      5;           0;   24;            -; PRMS
+
+  0;   53;    200;     -1;           0;   25;       cm**-3; Ne
+  0;   53;    201;      3;           0;   24;          MHz; FE
+  0;   53;    202;      3;           0;   24;          MHz; FoF2
+  0;   53;    203;      3;           0;   20;           km; HE
+  0;   53;    204;      3;           0;   20;           km; HF2
+#
+# Table definitions
+#
+#0	63	000	0	0	0	-	End of Table Descriptors
+#0	63	001	0	0	8	Numeric	Number of Dimensions
+#0	63	002	0	0	8	Numeric	Dimension Size
+#0	63	003	0	0	8	Code_Table	Object Type
+#0	63	004	0	0	8	Flag_Table	Flags
+#0	63	005	0	0	16	Numeric	Object Count
+#0	63	006	0	0	16	Numeric	Object Offset
+#0	63	007	0	0	8	Code_Table	Axis Label
diff --git a/data/tables/B3L-058-000-D b/data/tables/B3L-058-000-D
new file mode 100644
index 0000000..5e6e218
--- /dev/null
+++ b/data/tables/B3L-058-000-D
@@ -0,0 +1,1154 @@
+#
+# BUFR Table D (Lists of Common Sequences)
+#
+# sccs keywords: @(#)Table_D.txt	1.1 05/07/97
+#
+# Descriptor sequences are terminated with -1
+#
+# Sequences do not need to appear in any order.  Sequence A
+# which includes sequence B, may appear before sequence B
+# is defined.
+#
+3	0	2
+	0	0	2
+	0	0	3
+	-1
+
+3	0	4
+	3	0	3
+	0	0	13
+	0	0	14
+	0	0	15
+	0	0	16
+	0	0	17
+	0	0	18
+	0	0	19
+	0	0	20
+	-1
+
+3	0	3
+	0	0	10
+	0	0	11
+	0	0	12
+	-1
+
+3	0	10
+	3	0	3
+	1	1	0
+	0	31	1
+	0	0	30
+	-1
+
+3	1	1
+	0	1	1
+	0	1	2
+	-1
+
+3	1	2
+	0	1	3
+	0	1	4
+	0	1	5
+	-1
+
+3	1	3
+	0	1	11
+	0	1	12
+	0	1	13
+	-1
+
+3	1	11
+	0	4	1
+	0	4	2
+	0	4	3
+	-1
+
+3	1	12
+	0	4	4
+	0	4	5
+	-1
+
+3	1	13
+	0	4	4
+	0	4	5
+	0	4	6
+	-1
+
+3	1	21
+	0	5	1
+	0	6	1
+	-1
+
+3	1	22
+	0	5	1
+	0	6	1
+	0	7	1
+	-1
+
+3	1	23
+	0	5	2
+	0	6	2
+	-1
+
+3	1	24
+	0	5	2
+	0	6	2
+	0	7	2
+	-1
+
+3	1	25
+	3	1	23
+	0	4	3
+	3	1	12
+	-1
+
+3	1	26
+	3	1	21
+	0	4	3
+	0	4	3
+	0	4	4
+	0	4	4
+	0	4	5
+	0	4	5
+	-1
+
+3	1	31
+	3	1	1
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	22
+	-1
+
+3	1	32
+	3	1	1
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	24
+	-1
+
+3	1	33
+	0	1	5
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	21
+	-1
+
+3	1	34
+	0	1	5
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	35
+	0	1	5
+	0	1	12
+	0	1	13
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	36
+	3	1	3
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	37
+	3	1	1
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	22
+	-1
+
+3	1	38
+	3	1	1
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	24
+	-1
+
+3	1	39
+	3	1	3
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	40
+	3	1	3
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	24
+	-1
+
+3	1	41
+	0	1	7
+	0	2	21
+	0	2	22
+	3	1	11
+	3	1	12
+	-1
+
+3	1	42
+	3	1	41
+	3	1	21
+	-1
+
+3	1	43
+	0	1	7
+	0	2	23
+	3	1	11
+	3	1	13
+	3	1	21
+	-1
+
+3	1	44
+	0	1	7
+	0	2	24
+	3	1	11
+	3	1	13
+	3	1	21
+	-1
+
+3	1	51
+	0	1	6
+	0	2	61
+	3	1	11
+	3	1	12
+	3	1	21
+	0	8	4
+	-1
+
+3	1	62
+	1	1	0
+	0	31	1
+	3	1	1
+	-1
+
+3	2	1
+	0	10	4
+	0	10	51
+	0	10	61
+	0	10	63
+	-1
+
+3	2	2
+	0	10	4
+	0	7	4
+	0	10	3
+	0	10	61
+	0	10	63
+	-1
+
+3	2	3
+	0	11	11
+	0	11	12
+	0	12	4
+	0	12	6
+	0	13	3
+	0	20	1
+	0	20	3
+	0	20	4
+	0	20	5
+	-1
+
+3	2	4
+	0	20	10
+	0	8	2
+	0	20	11
+	0	20	13
+	0	20	12
+	0	20	12
+	0	20	12
+	-1
+
+3	2	5
+	0	8	2
+	0	20	11
+	0	20	12
+	0	20	13
+	-1
+
+3	2	11
+	3	2	1
+	3	2	3
+	3	2	4
+	-1
+
+3	2	12
+	3	2	2
+	3	2	3
+	3	2	4
+	-1
+
+3	2	21
+	0	22	1
+	0	22	11
+	0	22	21
+	-1
+
+3	2	22
+	0	22	2
+	0	22	12
+	0	22	22
+	-1
+
+3	2	23
+	0	22	3
+	0	22	13
+	0	22	23
+	-1
+
+3	2	24
+	3	2	22
+	1	1	2
+	3	2	23
+	-1
+
+3	2	51
+	0	10	4
+	0	10	51
+	0	7	4
+	0	10	3
+	0	12	4
+	0	12	51
+	0	12	16
+	0	12	17
+	0	13	4
+	1	2	4
+	0	8	51
+	0	8	20
+	-1
+
+3	3	1
+	0	7	3
+	0	11	1
+	0	11	22
+	-1
+
+3	3	2
+	0	7	4
+	0	11	1
+	0	11	2
+	-1
+
+3	3	3
+	0	7	4
+	0	10	3
+	0	12	1
+	0	12	3
+	-1
+
+3	3	4
+	0	7	4
+	0	10	3
+	0	12	1
+	0	12	3
+	0	11	1
+	0	11	2
+	-1
+
+3	3	11
+	0	7	3
+	0	8	1
+	0	11	1
+	0	11	2
+	-1
+
+3	3	12
+	0	7	4
+	0	8	1
+	0	11	1
+	0	11	2
+	-1
+
+3	3	13
+	0	7	4
+	0	8	1
+	0	10	3
+	0	12	1
+	0	13	3
+	0	11	1
+	0	11	2
+	-1
+
+3	3	14
+	0	7	4
+	0	8	1
+	0	10	3
+	0	12	1
+	0	12	3
+	0	11	1
+	0	11	2
+	-1
+
+3	3	21
+	0	7	4
+	0	7	4
+	2	4	7
+	0	31	21
+	-1
+
+3	3	22
+	3	3	21
+	0	10	3
+	2	4	0
+	-1
+
+3	3	23
+	3	3	21
+	0	12	1
+	2	4	0
+	-1
+
+3	3	24
+	3	3	21
+	0	13	16
+	2	4	0
+	-1
+
+3	3	25
+	0	2	25
+	2	4	7
+	0	31	21
+	0	12	63
+	2	4	0
+	-1
+
+3	3	26
+	0	7	4
+	0	8	3
+	2	4	7
+	0	31	21
+	0	12	1
+	2	4	0
+	-1
+
+3	3	27
+	0	7	4
+	2	4	7
+	0	31	21
+	0	10	3
+	2	4	0
+	-1
+
+3	3	31
+	0	7	4
+	0	8	3
+	0	7	21
+	0	7	22
+	0	8	12
+	0	12	61
+	-1
+
+3	3	32
+	0	20	11
+	0	20	16
+	-1
+
+3	4	1
+	0	8	3
+	0	10	4
+	0	12	1
+	0	11	1
+	0	11	2
+	-1
+
+3	4	2
+	0	8	3
+	0	10	4
+	0	11	1
+	0	11	2
+	-1
+
+3	4	3
+	0	8	3
+	0	12	1
+	-1
+
+3	4	4
+	0	8	3
+	0	10	4
+	0	20	10
+	0	12	1
+	-1
+
+3	4	5
+	0	2	24
+	0	7	4
+	0	7	4
+	0	13	3
+	-1
+
+3	4	6
+	0	14	1
+	0	14	1
+	0	14	3
+	-1
+
+3	6	1
+	0	2	32
+	1	2	0
+	0	31	1
+	0	7	62
+	0	22	42
+	-1
+
+3	6	2
+	0	2	31
+	0	22	4
+	0	22	31
+	-1
+
+3	6	3
+	0	2	2
+	0	11	11
+	0	11	12
+	0	12	4
+	-1
+
+3	6	4
+	0	2	32
+	0	2	33
+	1	3	0
+	0	31	1
+	0	7	62
+	0	22	43
+	0	22	62
+	-1
+
+3	6	5
+	0	2	31
+	1	3	0
+	0	31	1
+	0	7	62
+	0	22	4
+	0	22	31
+	-1
+
+3	6	6
+	3	6	3
+	3	6	2
+	0	22	63
+	-1
+
+3	6	7
+	0	1	12
+	0	1	14
+	3	6	8
+	0	4	24
+	0	27	3
+	0	28	3
+	-1
+
+3	6	8
+	0	2	34
+	0	2	35
+	0	2	36
+	-1
+
+3	7	1
+	3	1	31
+	3	2	11
+	-1
+
+3	7	2
+	3	1	32
+	3	2	11
+	-1
+
+3	7	3
+	3	7	1
+	1	1	0
+	0	31	1
+	3	2	5
+	-1
+
+3	7	4
+	3	7	2
+	1	1	0
+	0	31	1
+	3	2	5
+	-1
+
+3	7	5
+	3	7	1
+	1	1	4
+	3	2	5
+	-1
+
+3	7	6
+	3	7	2
+	1	1	4
+	3	2	5
+	-1
+
+3	7	7
+	3	1	31
+	3	2	12
+	-1
+
+3	7	8
+	3	1	32
+	3	2	12
+	-1
+
+3	8	1
+	3	1	33
+	3	2	11
+	0	22	42
+	-1
+
+3	8	2
+	3	1	34
+	3	2	11
+	0	22	42
+	-1
+
+3	8	3
+	3	1	35
+	3	2	11
+	0	22	42
+	-1
+
+3	8	4
+	3	1	36
+	3	2	11
+	0	22	42
+	-1
+
+3	8	5
+	3	8	4
+	3	2	24
+	-1
+
+3	8	6
+	0	10	4
+	0	10	61
+	0	10	63
+	0	11	1
+	0	11	2
+	0	12	4
+	0	13	3
+	0	22	42
+	-1
+
+3	9	1
+	3	1	37
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	2
+	3	1	38
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	3
+	3	1	37
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	4
+	3	1	38
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	5
+	3	1	37
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	6
+	3	1	38
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	7
+	3	1	37
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	8
+	3	1	38
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	11
+	3	1	39
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	12
+	3	1	39
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	13
+	3	1	39
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	14
+	3	1	39
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	15
+	3	1	40
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	16
+	3	1	40
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	17
+	3	1	40
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	18
+	3	1	40
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	19
+	3	1	31
+	0	2	3
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	20
+	3	1	31
+	0	2	3
+	1	4	0
+	0	31	1
+	0	7	3
+	0	11	3
+	0	11	4
+	0	11	5
+	-1
+
+3	10	1
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	26
+	3	3	25
+	-1
+
+3	10	2
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	9
+	3	3	23
+	-1
+
+3	10	3
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	6
+	3	3	23
+	-1
+
+3	10	4
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	3
+	3	3	24
+	-1
+
+3	11	1
+	3	1	51
+	0	7	2
+	0	12	1
+	0	11	1
+	0	11	2
+	0	11	31
+	0	11	32
+	0	11	33
+	0	20	41
+	-1
+
+3	12	1
+	3	1	43
+	3	4	1
+	-1
+
+3	12	2
+	3	1	43
+	3	4	2
+	-1
+
+3	12	3
+	3	1	42
+	3	4	3
+	-1
+
+3	12	4
+	3	1	42
+	3	4	4
+	-1
+
+3	12	5
+	3	1	42
+	0	20	14
+	-1
+
+3	12	6
+	3	1	44
+	3	4	5
+	-1
+
+3	12	7
+	3	1	42
+	3	4	6
+	-1
+
+3	12	10
+	0	1	7
+	0	5	40
+	0	2	21
+	0	5	41
+	0	4	1
+	0	4	43
+	-1
+
+3	12	11
+	2	2	131
+	2	1	149
+	0	4	6
+	2	1	0
+	1	2	32
+	0	10	2
+	2	2	0
+	0	5	43
+	0	5	53
+	-1
+
+3	12	12
+	2	2	129
+	2	1	132
+	1	1	19
+	0	12	63
+	2	1	0
+	2	2	0
+	-1
+
+3	12	13
+	0	5	42
+	2	2	129
+	2	1	135
+	0	12	63
+	2	1	0
+	2	2	0
+	-1
+
+3	12	14
+	3	12	10
+	3	12	11
+	1	5	56
+	3	1	23
+	0	5	42
+	0	5	52
+	3	12	12
+	3	12	13
+	-1
+
+3	12	15
+	1	9	11
+	3	1	23
+	0	5	42
+	0	5	52
+	2	2	129
+	2	1	132
+	1	1	4
+	0	12	63
+	2	2	0
+	2	1	0
+	-1
+
+3	12	16
+	3	12	10
+	3	12	11
+	3	12	15
+	-1
+
+3	12	17
+	1	9	8
+	3	1	23
+	0	5	42
+	0	5	52
+	2	2	129
+	2	1	132
+	1	1	3
+	0	12	63
+	2	2	0
+	2	1	0
+	-1
+
+3	12	18
+	3	12	10
+	3	12	11
+	3	12	17
+	-1
+
+3	13	9
+	0	21	1
+	1	1	0
+	0	31	1
+	0	21	1
+	-1
+
+3	13	10
+	0	21	36
+	1	1	0
+	0	31	1
+	0	21	36
+	-1
+
+3	13	31
+	0	6	2
+	0	6	12
+	1	1	0
+	0	31	2
+	0	30	1
+	-1
+
+3	13	32
+	0	5	2
+	0	5	12
+	1	1	0
+	0	31	2
+	3	13	31
+	-1
+
+3	13	41
+	0	6	2
+	0	6	12
+	1	6	0
+	0	31	1
+	1	1	0
+	0	31	11
+	0	30	1
+	1	1	0
+	0	31	1
+	0	30	1
+	-1
+
+3	13	42
+	0	5	2
+	0	5	12
+	1	1	0
+	0	31	2
+	3	13	41
+	-1
+
+3	15	1
+	0	1	11
+	3	1	11
+	3	1	12
+	3	1	23
+	3	6	1
+	-1
+
+3	15	2
+	0	1	11
+	3	1	11
+	3	1	12
+	3	1	23
+	3	6	4
+	-1
+
+3	16	1
+	3	1	11
+	0	4	4
+	3	1	23
+	0	1	21
+	0	2	41
+	0	19	1
+	0	10	51
+	0	19	2
+	0	19	3
+	0	19	4
+	-1
+
+3	18	1
+	3	1	25
+	0	24	11
+	-1
+
+3	18	3
+	3	1	26
+	0	24	5
+	0	24	4
+	0	24	21
+	-1
+
+3	18	4
+	3	1	25
+	0	4	23
+	0	13	11
+	0	24	5
+	0	24	4
+	0	24	22
+	-1
+
+3	21	1
+	0	2	101
+	0	2	114
+	0	2	105
+	0	2	106
+	0	2	107
+	0	2	121
+	-1
+
+3	21	3
+	0	21	51
+	0	21	14
+	0	21	17
+	0	21	30
+	-1
+
+3	21	4
+	3	1	31
+	0	2	3
+	1	1	0
+	0	31	1
+	3	21	3
+	-1
+
+3	21	5
+	0	25	4
+	0	2	121
+	0	2	122
+	0	2	123
+	0	2	124
+	0	2	125
+	0	2	126
+	0	2	127
+	0	2	128
+	0	2	129
+	0	2	130
+	0	2	131
+	-1
+
+3	21	6
+	0	25	1
+	0	25	2
+	0	25	3
+	0	25	5
+	-1
+
+3	21	7
+	0	25	9
+	0	25	10
+	0	25	11
+	0	25	12
+	0	25	13
+	0	25	15
+	0	25	16
+	0	25	17
+	-1
+
+3	21	8
+	0	25	6
+	0	25	7
+	0	25	8
+	-1
+
+3	21	9
+	0	25	18
+	0	25	19
+	-1
+
+3	21	10
+	0	2	101
+	0	7	2
+	0	2	102
+	0	2	103
+	0	2	104
+	0	2	105
+	0	2	106
+	0	2	107
+	0	2	108
+	0	2	109
+	0	2	110
+	0	2	132
+	0	2	133
+	-1
+
+3	21	11
+	0	30	31
+	0	30	32
+	0	29	2
+	-1
+
+3	21	12
+	1	1	0
+	0	31	1
+	0	2	135
+	0	2	135
+	-1
diff --git a/data/tables/B3L-058-005-B b/data/tables/B3L-058-005-B
new file mode 100644
index 0000000..47ab8fc
--- /dev/null
+++ b/data/tables/B3L-058-005-B
@@ -0,0 +1,779 @@
+#
+# B2L-058-001-B.001 - Local BUFR Table B for center 058 (FNMOC),
+# Minor Local Version 1
+#
+#					Data
+#F	X	Y	Scale	RefVal	Width	Units	Element Name
+  0;    0;      1;      0;           0;   24;    CCITT_IA5; Table A: entry
+  0;    0;      2;      0;           0;  256;    CCITT_IA5; Table A: data category description, line 1
+  0;    0;      3;      0;           0;  256;    CCITT_IA5; Table A: data category description, line 2
+  0;    0;      5;      0;           0;   24;    CCITT_IA5; BUFR edition number
+  0;    0;     10;      0;           0;    8;    CCITT_IA5; F descriptor to be added or defined
+  0;    0;     11;      0;           0;   16;    CCITT_IA5; X descriptor to be added or defined
+  0;    0;     12;      0;           0;   24;    CCITT_IA5; Y descriptor to be added or defined
+  0;    0;     13;      0;           0;  256;    CCITT_IA5; Element name, line 1
+  0;    0;     14;      0;           0;  256;    CCITT_IA5; Element name, line 2
+  0;    0;     15;      0;           0;  192;    CCITT_IA5; Units name
+  0;    0;     16;      0;           0;    8;    CCITT_IA5; Units scale sign
+  0;    0;     17;      0;           0;   24;    CCITT_IA5; Units scale (u)
+  0;    0;     18;      0;           0;    8;    CCITT_IA5; Units reference sign
+  0;    0;     19;      0;           0;   80;    CCITT_IA5; Units reference value
+  0;    0;     20;      0;           0;   24;    CCITT_IA5; Element data width
+  0;    0;     30;      0;           0;   40;    CCITT_IA5; Descriptor defining sequence
+  0;    1;      1;      0;           0;    7;      Numeric; WMO block number (II)
+  0;    1;      2;      0;           0;   10;      Numeric; WMO station number (iii)
+  0;    1;      3;      0;           0;    3;      Numeric; WMO region number
+  0;    1;      4;      0;           0;    3;      Numeric; WMO region sub-area
+  0;    1;      5;      0;           0;   17;      Numeric; Buoy/platform identifier
+  0;    1;      6;      0;           0;   64;    CCITT_IA5; Aircraft identifier (flight number) (Ia...Ia)
+  0;    1;      7;      0;           0;   10;   Code_Table; Satellite identifier (I1I2I2)
+  0;    1;      8;      0;           0;   64;    CCITT_IA5; Aircraft registration number (tail number)
+  0;    1;      9;      0;           0;   64;    CCITT_IA5; Type of commerical aircraft
+  0;    1;     10;      0;           0;   64;    CCITT_IA5; Stationary buoy platform identifier
+  0;    1;     11;      0;           0;   72;    CCITT_IA5; Ship call sign (D...D)
+  0;    1;     12;      0;           0;    9;     deg_true; Direction of motion of moving observing platform (dBdB)
+  0;    1;     13;      0;           0;   10;          m/s; Speed of motion of moving observing platform
+  0;    1;     14;      2;           0;   10;          m/s; Platform drift speed (high precision) (VBVB)
+  0;    1;     21;      0;           0;   14;      Numeric; Synoptic feature identifier
+  0;    1;     25;      0;           0;   24;    CCITT_IA5; Storm identifier
+  0;    1;     26;      0;           0;   64;    CCITT_IA5; WMO storm name
+  0;    1;     31;      0;           0;   16;      Numeric; Generating center
+  0;    1;     50;      0;           0;   48;    CCITT_IA5; NMC report identifier
+  0;    1;     62;      0;           0;   40;    CCITT_IA5; National assigned station identifier
+  0;    1;     63;      0;           0;   64;    CCITT_IA5; ICAO location indicator (CCCC)
+  0;    1;    192;      0;           0;   24;    CCITT_IA5; Receiving circuit
+  0;    1;    193;      0;           0;    4;   Code_Table; global octant
+  0;    1;    195;      0;           0;   10;      Numeric; Marsden square number
+  0;    1;    197;      0;           0;    6;      Numeric; Runway number
+  0;    1;    198;      0;           0;   16;   Code_Table; Sea station type
+  0;    1;    200;      0;           0;    2;   Code_Table; Radar Capability indicator (XXX)
+  0;    1;    201;      0;           0;    8;   Code_Table; Country or agency that operates the satellite
+  0;    1;    203;      0;           0;   16;    CCITT_IA5; Satellite name
+  0;    1;    204;      0;           0;   16;    CCITT_IA5; Satellite series
+  0;    1;    206;      0;           0;   32;    CCITT_IA5; TOVS generating center name
+  0;    1;    207;      0;           0;   72;    CCITT_IA5; File name
+  0;    1;    208;      0;           0;    4;   Code_Table; Satellite data type
+  0;    1;    209;      0;           0;    8;   Code_Table; Observation type for MCSST
+  0;    1;    210;      0;           0;    7;   Code_Table; Observation source
+  0;    1;    211;      0;           0;    4;      Numeric; Beam position
+  0;    1;    212;      0;           0;   24;      Numeric; Data processing block number
+  0;    1;    213;      0;           0;    3;   Code_Table; Tip source type identifier
+  0;    1;    214;      0;           0;   32;    CCITT_IA5; Header originator
+  0;    1;    215;      0;           0;   48;    CCITT_IA5; Bulletin header update or correction indicator
+  0;    1;    216;      0;           0;   14;      Numeric; Engineering status
+  0;    1;    217;      0;           0;    5;      Numeric; Satellite number
+  0;    1;    218;      0;           0;  176;    CCITT_IA5; Sequence (report) type
+  0;    1;    219;      0;           0;   40;    CCITT_IA5; Mission number
+  0;    1;    220;      0;           0;    7;      Numeric; Observation number
+  0;    1;    221;      0;           0;    8;   Code_Table; Surface type
+  0;    1;    222;      0;           0;   32;    CCITT_IA5; Report modifier
+  0;    1;    223;      0;           0;    3;   Code_Table; Runway parallel indicator
+  0;    1;    224;      0;           0;    5;   Code_Table; Terrain code identifier
+  0;    2;      1;      0;           0;    2;   Code_Table; Type of station (ix)
+  0;    2;      2;      0;           0;    4;   Flag_Table; Type of instrumentation for wind measurement (ewew)
+  0;    2;      3;      0;           0;    4;   Code_Table; Type of measuring instrumentation used (a4, I3, or I4)
+  0;    2;      4;      0;           0;    4;   Code_Table; Type of instrumentation for evaporation measur
+  0;    2;      5;      2;           0;    7;        deg_K; Precision of temperature observed (s3)
+  0;    2;     11;      0;           0;    8;   Code_Table; Radiosonde type (rara)
+  0;    2;     12;      0;           0;    4;   Code_Table; Radiosonde computational method
+  0;    2;     13;      0;           0;    4;   Code_Table; Solar and infrared radiation correction (Sr)
+  0;    2;     14;      0;           0;    7;   Code_Table; Tracking technique/status of system (sasa)
+  0;    2;     15;      0;           0;    4;   Code_Table; Radiosonde completeness
+  0;    2;     21;      0;           0;    9;   Flag_Table; Satellite instrumentation data used in processing
+  0;    2;     22;      0;           0;    8;   Flag_Table; Satellite data processing technique used
+  0;    2;     23;      0;           0;    4;   Code_Table; Cloud motion computational method
+  0;    2;     24;      0;           0;    4;   Code_Table; Integrated mean humidity computational method
+  0;    2;     25;      0;           0;   25;   Flag_Table; Satellite channel(s) used in computation
+  0;    2;     26;      2;           0;   12;            m; Cross track resolution
+  0;    2;     27;      2;           0;   12;            m; Along track resolution
+  0;    2;     28;      0;           0;   32;   Flag_Table; Geostationary sounder satellite channels used
+  0;    2;     29;      0;           0;    8;   Flag_Table; Geostationary sounder satellite channels used
+  0;    2;     30;      0;           0;    3;   Code_Table; Method of current measurement (k5)
+  0;    2;     31;      0;           0;    5;   Code_Table; Duration and time of current measurement
+  0;    2;     32;      0;           0;    2;   Code_Table; Indicator for digitization (k1)
+  0;    2;     33;      0;           0;    3;   Code_Table; Method of salinity/depth measurement (k2)
+  0;    2;     34;      0;           0;    5;   Code_Table; Drogue type (id)
+  0;    2;     35;      0;           0;    9;            m; Cable length (ZdZdZd)
+  0;    2;     36;      0;           0;    2;   Code_Table; Buoy type (Ip or Vi...Vi)
+  0;    2;     38;      0;           0;    4;   Code_Table; Sea surface temperature method indicator
+  0;    2;     39;      0;           0;    4;   Code_Table; Wet bulb temperature method indicator
+  0;    2;     40;      0;           0;    4;   Code_Table; Method of removing velocity and motion
+  0;    2;     41;      0;           0;    6;   Code_Table; Method for estimating reports related to synoptic features
+  0;    2;     42;      0;           0;    6;   Code_Table; Method of report construction (Qn)
+  0;    2;     43;      0;           0;    6;   Code_Table; Precision of latitude/longitude report (At or QL)
+  0;    2;     47;      0;           0;    4;   Code_Table; Method of removing ship velocity
+  0;    2;     51;      0;           0;    4;   Code_Table; Indicator to specify observing method for extreme temperatures
+  0;    2;     61;      0;           0;    3;   Code_Table; Aircraft navigation system (s1)
+  0;    2;     62;      0;           0;    4;   Code_Table; Type of aircraft data relay system
+  0;    2;     63;      2;      -18000;   16;          deg; Aircraft roll angle
+  0;    2;     70;      0;           0;    4;   Code_Table; Original specification of latitude/longitude
+  0;    2;    101;      0;           0;    4;   Code_Table; Type of antenna
+  0;    2;    102;      0;           0;    8;            m; Antenna height above tower
+  0;    2;    103;      0;           0;    2;   Flag_Table; Radome
+  0;    2;    104;      0;           0;    4;   Code_Table; Antenna polarisation
+  0;    2;    105;      0;           0;    6;           dB; Maximum antenna gain
+  0;    2;    106;      1;           0;    6;          deg; 3-dB bandwidth
+  0;    2;    107;      0;           0;    6;           dB; Sidelobe suppression
+  0;    2;    108;      0;           0;    6;           dB; Crosspol discrimination (on axis)
+  0;    2;    109;      2;           0;   12;        deg/s; Antenna speed (azimuth)
+  0;    2;    110;      2;           0;   12;        deg/s; Antenna speed (elevation)
+  0;    2;    111;      1;           0;   10;          deg; Radar incidence angle
+  0;    2;    112;      1;           0;   12;          deg; Radar azimuth angle
+  0;    2;    113;      0;           0;    4;      Numeric; Number of azimuth looks
+  0;    2;    114;      0;           0;   15;         m**2; Antenna effective surface area
+  0;    2;    121;     -8;           0;    7;           Hz; Mean frequency
+  0;    2;    122;     -6;        -128;    8;           Hz; Frequency agility range
+  0;    2;    123;     -4;           0;    7;            W; Peak power
+  0;    2;    124;     -1;           0;    7;            W; Average power
+  0;    2;    125;     -1;           0;    8;           Hz; Pulse repetition frequency
+  0;    2;    126;      7;           0;    6;            s; Pulse width
+  0;    2;    127;     -6;           0;    7;           Hz; Receiver intermediate frequency
+  0;    2;    128;     -5;           0;    6;           Hz; Intermediate frequency bandwidth
+  0;    2;    129;      0;        -150;    5;           dB; Minimum detectable signal
+  0;    2;    130;      0;           0;    7;           dB; Dynamic range
+  0;    2;    131;      0;           0;    2;   Flag_Table; Sensitivity time control
+  0;    2;    132;      2;           0;    6;          deg; Azimuth pointing accuracy
+  0;    2;    133;      2;           0;    6;          deg; Elevation pointing accuracy
+  0;    2;    134;      2;           0;   16;          deg; Antenna beam azimuth
+  0;    2;    135;      2;       -9000;   15;          deg; Antenna elevation
+  0;    2;    141;      0;           0;   24;    CCITT_IA5; Measurement type serial number/identifier
+  0;    2;    142;      0;           0;    8;   Code_Table; Ozone instrument
+  0;    2;    143;      0;           0;    7;      Numeric; Instrument type
+  0;    2;    190;      0;           0;    8;   Code_Table; U, v quality indicator
+  0;    2;    191;      0;           0;    4;   Code_Table; W quality indicator
+  0;    2;    194;      0;           0;    8;   Code_Table; Spectral calculation method
+  0;    2;    199;      0;           0;    4;      Numeric; grp_pos_ind
+  0;    2;    203;      0;           0;    3;   Code_Table; Method of determining direction of moving platform
+  0;    2;    204;      0;           0;    3;   Code_Table; Method of determining speed of moving platform
+  0;    2;    205;      0;           0;    3;   Code_Table; Ozone flag
+  0;    2;    206;      0;           0;    4;   Code_Table; Algorithm identifier
+  0;    2;    207;      0;           0;    5;   Code_Table; Equation identifier
+  0;    2;    208;      0;           0;    2;   Code_Table; Type of method for measuring pressure
+  0;    2;    209;      0;           0;   10;   Code_Table; Xbt instrument type (IxIxIx)
+  0;    2;    210;      0;           0;    7;   Code_Table; Recorder type (XRXR)
+  0;    2;    211;      0;           0;    8;   Flag_Table; Sensor status flag
+  0;    2;    212;      0;           0;    2;   Flag_Table; Maintenance Check flag
+  0;    4;      1;      0;           0;   12;           yr; Year (4-digit)
+  0;    4;      2;      0;           0;    4;           mo; Month
+  0;    4;      3;      0;           0;    6;          day; Day
+  0;    4;      4;      0;           0;    5;           hr; Hour
+  0;    4;      5;      0;           0;    6;          min; Minute
+  0;    4;      6;      0;           0;    6;            s; Second
+  0;    4;     11;      0;       -1024;   11;           yr; Time increment - year
+  0;    4;     12;      0;       -1024;   11;           mo; Time increment - month
+  0;    4;     13;      0;       -1024;   11;          day; Time increment - day
+  0;    4;     14;      0;       -1024;   11;           hr; Time increment - hour
+  0;    4;     15;      0;       -2048;   12;          min; Time increment - minutes
+  0;    4;     16;      0;       -4096;   13;            s; Time increment - seconds
+  0;    4;     21;      0;       -1024;   11;           yr; Time period or displacement - year
+  0;    4;     22;      0;       -1024;   11;           mo; Time period or displacement - month
+  0;    4;     23;      0;       -1024;   11;          day; Time period or displacement - month
+  0;    4;     24;      0;       -2048;   12;           hr; Time period or displacement - hour
+  0;    4;     25;      0;       -2048;   12;          min; Time period or displacement - minutes
+  0;    4;     26;      0;       -4096;   13;            s; Time period or displacement - seconds
+  0;    4;     31;      0;           0;    8;           hr; Duration of time relative to following value (TT)
+  0;    4;     41;      0;       -1440;   12;          min; Time difference, UTC - LMT
+  0;    4;     43;      0;           0;    9;          day; Day of the year
+  0;    4;     44;      0;           0;    3;   Code_Table; Day of the week (Y)
+  0;    4;     53;      0;           0;    6;      Numeric; Number of days with precipitation equal or more than 1 mm
+  0;    4;     70;      0;           0;    8;      Numeric; Sample number
+  0;    4;    192;      0;           0;    4;   Code_Table; Precipitation time period (tR)
+  0;    4;    193;      0;           0;   31;   Code_Table; Last time that this observation record was updated
+  0;    4;    200;      0;           0;   12;           yr; Time of receipt - year
+  0;    4;    201;      0;           0;    4;           mo; Time of receipt - month
+  0;    4;    202;      0;           0;    6;          day; Time of receipt - day
+  0;    4;    203;      0;           0;    5;           hr; Time of receipt - hour
+  0;    4;    204;      0;           0;    6;          min; Time of receipt - minute
+  0;    4;    206;      3;           0;   27;            s; GMT seconds
+  0;    5;      1;      5;    -9000000;   25;          deg; Latitude (high accuracy)
+  0;    5;      2;      2;       -9000;   15;          deg; Latitude (coarse accuracy) (La...La)
+  0;    5;      3;      2;       -9000;   15;          deg; Alternate latitude
+  0;    5;     11;      5;    -9000000;   25;          deg; Latitude increment (high accuracy)
+  0;    5;     12;      2;       -9000;   15;          deg; Latitude increment (coarse accuracy)
+  0;    5;     21;      2;           0;   16;     deg_true; Bearing or azimuth
+  0;    5;     22;      2;           0;   16;     deg_true; Solar azimuth
+  0;    5;     30;      0;           0;   12;          deg; Direction (spectral)
+  0;    5;     31;      0;           0;   12;      Numeric; Row number
+  0;    5;     33;     -1;           0;   16;            m; Pixel size on horizontal - 1
+  0;    5;     40;      0;           0;   24;      Numeric; Orbit number
+  0;    5;     41;      0;           0;    8;      Numeric; Scan line number
+  0;    5;     42;      0;           0;    6;      Numeric; Channel number
+  0;    5;     43;      0;           0;    8;      Numeric; Field of view number
+  0;    5;     50;      5;           0;   17;      Numeric; Sigma level
+  0;    5;     52;      0;           0;    5;      Numeric; Channel number increment
+  0;    5;     53;      0;           0;    5;      Numeric; Field of view number increment
+  0;    5;    192;      0;           0;    3;      Numeric; Image line number
+  0;    5;    193;      0;           0;    4;      Numeric; Image sample number
+  0;    5;    194;      0;           0;   14;      Numeric; Orbit number
+  0;    5;    196;      0;           0;   16;      Numeric; Orbit number
+  0;    5;    197;      0;           0;    8;      Numeric; Frame number
+  0;    5;    199;      0;           0;   20;      Numeric; Orbit number
+  0;    6;      1;      5;   -18000000;   26;          deg; Longtiude (high accuracy)
+  0;    6;      2;      2;      -18000;   16;          deg; Longtiude (coarse accuracy) (Lo...Lo)
+  0;    6;      3;      2;      -18000;   16;          deg; Alternate longtiude
+  0;    6;     11;      5;   -18000000;   26;          deg; Longtiude increment (high accuracy)
+  0;    6;     12;      2;      -18000;   16;          deg; Longtiude increment (coarse accuracy)
+  0;    6;     21;     -1;           0;   13;            m; Distance
+  0;    6;     30;      5;           0;   13;        rad/m; Wavenumber (spectral)
+  0;    6;     31;      0;           0;   12;      Numeric; Column number
+  0;    6;     33;     -1;           0;   16;            m; Pixel size on horizontal - 2
+  0;    7;      1;      0;        -400;   15;            m; Height of station (hohohoho)
+  0;    7;      2;     -1;         -40;   16;            m; Height or altitude (hahaha, hIhIhI, HmHmHm, HH, tnu2, or tnu3)
+  0;    7;      3;     -1;        -400;   17;    m**2/s**2; Geopotential
+  0;    7;      4;     -1;           0;   14;           Pa; Pressure (Pa...Pa, Paob...Paob, Po...Po, PtPtPt, or PAPA)
+  0;    7;      5;      0;        -400;   12;            m; Height increment
+  0;    7;      6;      0;           0;   15;            m; Height above station
+  0;    7;      7;      0;       -1000;   17;            m; Geopotential height
+  0;    7;     21;      2;       -9000;   15;          deg; Elevation
+  0;    7;     22;      2;       -9000;   15;          deg; Solar elevation
+  0;    7;     61;      2;           0;   14;            m; Depth below land surface
+  0;    7;     62;      1;           0;   17;            m; Depth below sea surface
+  0;    7;    190;      0;           0;   12;            m; Height increment
+  0;    7;    192;      2;           0;   13;          deg; Local zenith angle
+  0;    7;    196;      0;           0;    4;   Code_Table; Station height precision
+  0;    7;    197;      1;           0;   11;          deg; Solar zenith angle
+  0;    7;    198;      2;       -6000;   14;          deg; Satellite zenith angle
+  0;    7;    199;      1;           0;   11;          deg; Solar azimuth angle
+  0;    7;    223;      2;           0;   14;          deg; Solar zenith angle
+  0;    7;    224;      1;           0;   14;            m; Surface elevation
+  0;    8;      0;      0;           0;    4;   Code_Table; Vertical significance (forecast soundings)
+  0;    8;      1;      0;           0;    7;   Flag_Table; Vertical sounding significance
+  0;    8;      2;      0;           0;    6;   Code_Table; Vertical significance (surface observations)
+  0;    8;      3;      0;           0;    6;   Code_Table; Vertical significance (satellite observations)
+  0;    8;      4;      0;           0;    3;   Code_Table; Phase of aircraft flight (ipipip)
+  0;    8;      5;      0;           0;    4;   Code_Table; Surface synoptic features significance
+  0;    8;     11;      0;           0;    6;   Code_Table; Horizontal significance
+  0;    8;     12;      0;           0;    2;   Code_Table; land/sea qualifier
+  0;    8;     13;      0;           0;    2;   Code_Table; Day/night qualifier
+  0;    8;     21;      0;           0;    5;   Code_Table; Time significance
+  0;    8;     22;      0;           0;   16;      Numeric; Total number (with respect to accumulation or average)
+  0;    8;     24;      0;           0;    8;   Code_Table; Type of difference
+  0;    8;     31;      0;           0;    8;    CCITT_IA5; Data category
+  0;    8;     32;      0;           0;   14;   Code_Table; Data significance for simulated forecast
+  0;    8;     33;      0;           0;    3;   Code_Table; Data significance for corrected forecast
+  0;    8;     34;      0;           0;    3;   Code_Table; Data significance for simulated retrievals
+  0;    8;     35;      0;           0;    3;   Code_Table; Data significance for corrected retrievals
+  0;    8;     36;      0;           0;    3;   Code_Table; Data significance for simulated analysis
+  0;    8;     37;      0;           0;    3;   Code_Table; Data significance for corrected analysis
+  0;    8;     38;      0;           0;    3;   Code_Table; Data significance for sigma level data
+  0;    8;     51;      0;           0;    3;   Code_Table; Qualifier for number of missing values in calculation of statistic
+  0;    8;     52;      0;           0;    5;   Code_Table; Condition for which number of days of occurrence follows
+  0;    8;     53;      0;           0;    2;   Code_Table; Day of occurrence qualifier
+  0;    8;     70;      0;           0;    8;   Code_Table; Surface Type Code ID
+  0;    8;    194;      0;           0;    4;   Code_Table; Flight condition (fc)
+  0;   10;      1;      0;        -400;   15;            m; Height of land surface
+  0;   10;      2;     -1;         -40;   16;            m; Height (HHH)
+  0;   10;      3;     -1;        -400;   17;    m**2/s**2; Geopotential
+  0;   10;      4;     -1;           0;   14;           Pa; Pressure
+  0;   10;      7;      0;       -1000;   17;            m; Geopotential height
+  0;   10;     50;      2;           0;   16;            m; Standard deviation altitude
+  0;   10;     51;     -1;           0;   14;           Pa; Pressure reduced to mean sea level (PPPP)
+  0;   10;     52;     -1;           0;   14;           Pa; Altimeter setting (QNH) (PH...PH)
+  0;   10;     60;     -1;       -1024;   11;           Pa; Pressure change (ppp)
+  0;   10;     61;     -1;        -500;   10;           Pa; 3 hour pressure change
+  0;   10;     62;     -1;       -1000;   11;           Pa; 24 hour pressure change
+  0;   10;     63;      0;           0;    4;   Code_Table; Characteristic of pressure tendency (a, w, or w'w')
+  0;   10;    103;      0;           0;    4;   Code_Table; Geopotential thickness QC ID
+  0;   10;    197;      0;           0;    4;   Code_Table; Index pertaining to geopotential height (j)
+  0;   10;    199;      0;       -1024;   16;            m; Geopotential height difference
+  0;   10;    200;      0;       -1024;   16;            m; Geopotental height correction
+  0;   10;    201;      0;           0;   14;   Code_Table; Pressure tendency QC ID
+  0;   10;    203;      0;           0;    4;   Code_Table; Geopotential height quality control flag
+  0;   10;    213;      0;       -1024;   16;            m; Geopotential height
+  0;   10;    224;      0;           0;    4;   Code_Table; Station level pressure QC ID
+  0;   10;    251;      0;           0;    4;   Code_Table; Mean sea level pressure QC ID
+  0;   11;      1;      0;           0;    9;     deg_true; Wind direction (dd, dodo>dndn, dmagdmag)
+  0;   11;      2;      1;           0;   12;          m/s; Wind speed (ff, fff, or fofofo>fnfnfn)
+  0;   11;      3;      1;       -4096;   13;          m/s; U-component
+  0;   11;      4;      1;       -4096;   13;          m/s; V-component
+  0;   11;      5;      1;        -512;   10;         Pa/s; W-component
+  0;   11;      6;      2;       -4096;   13;          m/s; W-component
+  0;   11;     11;      0;           0;    9;     deg_true; Wind direction at 10 m
+  0;   11;     12;      1;           0;   12;          m/s; Wind speed at 10 m
+  0;   11;     13;      0;           0;    9;     deg_true; Wind direction at 5 m
+  0;   11;     14;      1;           0;   12;          m/s; Wind speed at 5 m
+  0;   11;     21;      9;      -65536;   17;          1/s; Relative vorticity
+  0;   11;     22;      9;      -65536;   17;          1/s; Divergence
+  0;   11;     23;     -2;      -65536;   17;       m**2/s; Velocity potential
+  0;   11;     31;      0;           0;    4;   Code_Table; Degree of turbulence (B...B or BA)
+  0;   11;     32;     -1;         -40;   16;            m; Height of base of turbulence (BabBabBab or B1B1B1)
+  0;   11;     33;     -1;         -40;   16;            m; Height of top of turbulence (BatBatBat or B1B1B1)
+  0;   11;     34;      1;       -1024;   11;          m/s; Vertical gust velocity
+  0;   11;     35;      2;       -8192;   14;       m/s**2; Vertical gust acceleration
+  0;   11;     36;      1;           0;   10;          m/s; Maximum derived equivalent vertical gust
+  0;   11;     41;      1;           0;   12;          m/s; Maximum wind speed (gusts) (fm...fm)
+  0;   11;     42;      1;           0;   12;          m/s; Maximum wind speed (10 minute mean wind)
+  0;   11;     43;      1;           0;   12;          m/s; Surface - 5000 feet mean LYR wind speed (dmdm)
+  0;   11;     44;      0;           0;    9;     deg_true; Surface - 5000 feet mean LYR wind direction
+  0;   11;     45;      0;           0;    9;     deg_true; Maximum wind (gust) direction
+  0;   11;     50;      1;           0;   12;          m/s; Standard deviation horizontal wind speed
+  0;   11;     51;      1;           0;    8;          m/s; Standard deviation vertical wind component
+  0;   11;     61;      1;           0;   12;          m/s; Absolute wind shear (1 kilometer layer below)
+  0;   11;     62;      1;           0;   12;          m/s; Absolute wind shear (1 kilometer layer above)
+  0;   11;    195;      0;           0;    2;   Code_Table; Wind type at flight altitude (dt)
+  0;   11;    200;      0;           0;    4;   Code_Table; Wind QC ID
+  0;   11;    203;      1;       -4096;   13;          m/s; Wind u-component difference
+  0;   11;    204;      1;       -4096;   13;          m/s; Wind v-component difference
+  0;   11;    205;      0;           0;    4;   Code_Table; Turbulence (B) (WMO code table 0300)
+  0;   11;    206;      0;           0;    2;   Code_Table; Flight level wind method (da)
+  0;   11;    207;      0;           0;    2;   Code_Table; Extreme wind speed ID
+  0;   11;    213;      1;       -4096;   13;          m/s; Wind u-component correction
+  0;   11;    214;      1;       -4096;   13;          m/s; Wind v-component correction
+  0;   11;    244;      0;           0;   16;     deg_true; Direction of wind
+  0;   11;    245;      2;           0;   16;          m/s; wnd_spd
+  0;   11;    246;      1;           0;    8;          m/s; Ocean surface wind speed
+  0;   12;      1;      1;           0;   12;        deg_K; Temperature/dry bulb temperature (Ta, TsTsTs, TtTt, or TxTxTx)
+  0;   12;      2;      1;           0;   12;        deg_K; Wet bulb temperature (TbTbTb)
+  0;   12;      3;      1;           0;   12;        deg_K; Dewpoint (TdTdTd or T'dT'd)
+  0;   12;      4;      1;           0;   12;        deg_K; Dry bulb temperature at 2 meters (Tao>Tan, ToTo>tnTn, or TT)
+  0;   12;      5;      1;           0;   12;        deg_K; Wet bulb temperature at 2 meters
+  0;   12;      6;      1;           0;   12;        deg_K; Dewpoint temperature at 2 meters
+  0;   12;      7;      1;           0;   12;        deg_K; Virtual temperature
+  0;   12;     11;      1;           0;   12;        deg_K; Maximum temperature
+  0;   12;     12;      1;           0;   12;        deg_K; Minimum temperature (TnTnTn)
+  0;   12;     13;      1;           0;   12;        deg_K; Ground minimum temperature past 12 hours
+  0;   12;     14;      1;           0;   12;        deg_K; Maximum temperature at 2 meters, past 12 hours
+  0;   12;     15;      1;           0;   12;        deg_K; Minimum temperature at 2 meters, past 12 hours
+  0;   12;     16;      1;           0;   12;        deg_K; Maximum temperature at 2 meters, past 24 hours
+  0;   12;     17;      1;           0;   12;        deg_K; Minimum temperature at 2 meters, past 24 hours
+  0;   12;     20;      2;       -2000;   12;    deg_K/day; Radiative heating profile
+  0;   12;     30;      1;           0;   12;        deg_K; Soil temperature (ToTo)
+  0;   12;     40;     -3;       -2048;   12;       W/m**2; Sensible heat flux
+  0;   12;     48;      0;        -200;    8;        deg_K; Land/snow surface temperature
+  0;   12;     51;      1;           0;   10;        deg_K; Standard deviation temperature
+  0;   12;     52;      1;           0;   12;        deg_K; Highest daily mean temperature
+  0;   12;     53;      1;           0;   12;        deg_K; Lowest daily mean temperature
+  0;   12;     61;      1;           0;   12;        deg_K; Skin temperature
+  0;   12;     62;      1;           0;   12;        deg_K; Equivalent black body temperature
+  0;   12;     63;      1;           0;   12;        deg_K; Brightness temperature
+  0;   12;     70;      2;           0;   16;        deg_K; Vertical polarization 19GHz brightness temperature
+  0;   12;     71;      2;           0;   16;        deg_K; Horizontal polarization 19GHz brightness temperature
+  0;   12;     72;      2;           0;   16;        deg_K; Vertical polarization 22GHz brightness temperature
+  0;   12;     73;      2;           0;   16;        deg_K; Vertical polarization 37GHz brightness temperature
+  0;   12;     74;      2;           0;   16;        deg_K; Horizontal polarization 37GHz brightness temperature
+  0;   12;     75;      2;           0;   16;        deg_K; Vertical polarization 85GHz brightness temperature
+  0;   12;     76;      2;           0;   16;        deg_K; Horizontal polarization 85GHz brightness temperature
+  0;   12;    192;      0;           0;    4;   Code_Table; Wet bulb temperature indicator
+  0;   12;    193;      2;           0;   16;        deg_K; SSU brightness temperature
+  0;   12;    194;      2;           0;   16;        deg_K; Dewpoint
+  0;   12;    195;      0;           0;    4;   Code_Table; Dewpoint, aircraft altitude, air temperature indicator (id)
+  0;   12;    196;      2;           0;   16;        deg_K; Dewpoint difference
+  0;   12;    201;      0;           0;    4;   Code_Table; Air temperature QC ID
+  0;   12;    213;      0;           0;    4;   Code_Table; Dewpoint QC ID
+  0;   12;    215;      0;           0;    2;   Code_Table; Temperature precision flag
+  0;   12;    220;      2;           0;   16;        deg_K; HIRS brightness temperature
+  0;   12;    221;      2;           0;   16;        deg_K; MSU brightness temperature
+  0;   13;      1;      5;           0;   14;        kg/kg; Specific humidity
+  0;   13;      2;      5;           0;   14;        kg/kg; Mixing ratio
+  0;   13;      3;      0;           0;    7;      percent; Relative humidity (U1>Un or U...U)
+  0;   13;      4;     -1;           0;   10;           Pa; Vapor pressure
+  0;   13;      5;      3;           0;    7;      kg/m**3; Vapor density (p1p1p1)
+  0;   13;      6;     -1;         -40;   16;            m; Mixing heights
+  0;   13;     11;      1;          -1;   14;      kg/m**2; Total precipitation/total water equivalent (Aw or R...R)
+  0;   13;     12;      2;          -2;   12;            m; Depth of fresh snow
+  0;   13;     13;      2;          -2;   16;            m; Total snow depth (sss)
+  0;   13;     14;      4;           0;   12;    kg/m**2/s; Rainfall/water equivalent of snow (average rate)
+  0;   13;     15;      7;           0;   12;          m/s; Snowfall (averaged rate)
+  0;   13;     16;      0;           0;    7;      kg/m**2; Precipitable water (www)
+  0;   13;     19;      1;          -1;   14;      kg/m**2; Total precipitation past 1 hour
+  0;   13;     20;      1;          -1;   14;      kg/m**2; Total precipitation past 3 hours
+  0;   13;     21;      1;          -1;   14;      kg/m**2; Total precipitation past 6 hours
+  0;   13;     22;      1;          -1;   14;      kg/m**2; Total precipitation past 12 hours
+  0;   13;     23;      1;          -1;   14;      kg/m**2; Total precipitation past 24 hours (R24...R24)
+  0;   13;     31;      0;           0;    7;      kg/m**2; Evapotranspiration
+  0;   13;     32;      1;           0;    8;      kg/m**2; Evaporation/evapotranspiration
+  0;   13;     40;     -3;       -2048;   12;       W/m**2; Latent heat flux
+  0;   13;     41;      0;           0;    4;   Code_Table; Pasquill-Gifford stability category
+  0;   13;     42;      0;         -20;    6;        deg_K; Parcel lifted index (to 500 hPa)
+  0;   13;     43;      0;         -20;    6;        deg_K; Best lifted index (to 500 hPa)
+  0;   13;     51;      0;           0;    4;   Code_Table; Frequency group, precipitation
+  0;   13;     52;      1;          -1;   14;      kg/m**2; Highest daily amount of precipiation
+  0;   13;     71;      1;           0;    7;      kg/m**2; Liquid water
+  0;   13;     75;      0;           0;    8;      percent; Land snow cloud
+  0;   13;     76;      2;           0;    6;            m; Snow-water equivalent
+  0;   13;    176;      0;           0;    7;   Code_Table; Precipitable water precision flag
+  0;   13;    192;      0;           0;    4;   Code_Table; Precipitation identifier (iR)
+  0;   13;    193;      0;           0;   10;   Code_Table; Precipitation amount
+  0;   13;    194;      3;           0;   16;         g/kg; First guess mixing ratios
+  0;   13;    197;      0;           0;    3;   Code_Table; Rain indicator
+  0;   13;    203;      0;           0;    4;   Code_Table; Relative hunidity QC ID
+  0;   13;    217;      0;           0;    8;      Numeric; Precipitation flag (SSM/T)
+  0;   13;    218;      2;           0;   11;    kg/(m**2); Cloud water
+  0;   13;    219;      2;           0;   10;           cm; Total precipitable water
+  0;   13;    220;      1;           0;    9;        mm/hr; Rain rate
+  0;   13;    221;      2;           0;   14;    kg/(m**2); Cloud Liquid Water
+  0;   14;      1;     -3;       -2048;   12;       J/m**2; Longwave radiation, integrated over 24 hours (FLFLFL)
+  0;   14;      3;     -3;       -2048;   12;       J/m**2; Shortwave radiation, integrated over 24 hours (FiFiFi)
+  0;   14;      4;     -3;       -2048;   12;       J/m**2; Shortwave radiation, integrated over period specified (FsFsFs)
+  0;   14;     11;     -3;       -2048;   12;       J/m**2; Net longwave radiation, integrated over 24 hours
+  0;   14;     12;     -3;       -2048;   12;       J/m**2; Net longwave radiation, integrated over period specified
+  0;   14;     13;     -3;       -2048;   12;       J/m**2; Net shortwave radiation, integrated over 24 hours
+  0;   14;     14;     -3;       -2048;   12;       J/m**2; Net shortwave radiation, integrated over period specified
+  0;   14;     15;     -4;      -16384;   15;       J/m**2; Net radiation, integrated over 24 hours
+  0;   14;     16;     -4;      -16384;   15;       J/m**2; Net radiation, integrated over period specified
+  0;   14;     17;     -3;       -2048;   12;       W/m**2; Instantaneous long wave radiation
+  0;   14;     18;     -3;       -2048;   12;       W/m**2; Instantaneous short wave radiation
+  0;   14;     19;      0;           0;    7;      percent; Surface albedo
+  0;   14;     20;     -4;           0;   15;       J/m**2; Global solar radiation, integrated over 24 hours
+  0;   14;     21;     -4;           0;   15;       J/m**2; Global radiation, integrated over period specified
+  0;   14;     22;     -4;           0;   15;       J/m**2; Diffuse solar radiation, integrated over 24 hours
+  0;   14;     23;     -4;           0;   15;       J/m**2; Diffuse solar radiation, integratedi over period specified
+  0;   14;     24;     -4;           0;   15;       J/m**2; Direct solar radiation, integrated over 24 hours
+  0;   14;     25;     -4;           0;   15;       J/m**2; Direct solar radiation, integrated over period specified
+  0;   14;     31;      0;           0;   11;          min; Total sunshine
+  0;   14;     32;      0;           0;   10;           hr; Total sunshine
+  0;   14;     33;      0;           0;    9;      percent; Total sunshine (precentage)
+  0;   14;     41;      0;           0;    7;      percent; Short wave albedo
+  0;   14;     42;      0;           0;    7;      percent; Bi-directional reflectance
+  0;   15;      1;      0;           0;   10;  dobson_unit; Ozone
+  0;   15;      2;      2;           0;   10;      Numeric; Air-mass (slant path at 22 km)
+  0;   19;      1;      0;           0;    6;   Code_Table; Type of synoptic features
+  0;   19;      2;     -2;           0;   12;            m; Effective radius of feature
+  0;   19;      3;      0;           0;    8;          m/s; Wind speed threshold
+  0;   19;      4;     -2;           0;   12;            m; Effective radius of feature with respect to wind speeds above threshold
+  0;   19;      5;      0;           0;    9;     deg_true; Direction of motion of features (dsds)
+  0;   19;      6;      2;           0;   14;          m/s; Speed of motion of features
+  0;   19;      7;     -3;           0;   12;            m; Effective radius of features
+  0;   19;      8;      0;           0;    3;   Code_Table; Vertical extent of circulation
+  0;   19;      9;     -3;           0;   12;            m; Effective radiation with respect to FFF above threshold
+  0;   20;      1;     -1;           0;   13;            m; Horizontal visibility (Dv, Vi, V...V, or VxVxVxVx)
+  0;   20;      2;     -1;           0;    7;            m; Vertical visibility
+  0;   20;      3;      0;           0;    9;   Code_Table; Present weather (ww or w'w')
+  0;   20;      4;      0;           0;    5;   Code_Table; Past weather (1) (Wa1Wa2 or W1W2)
+  0;   20;      5;      0;           0;    5;   Code_Table; Past weather (2) (wawa)
+  0;   20;      9;     -1;         -40;   11;            m; Ceiling
+  0;   20;     10;      0;           0;    7;      percent; Cloud cover (total) (N, NcNc, or Ns...Ns)
+  0;   20;     11;      0;           0;    4;   Code_Table; Cloud amount (N or Ns...Ns)
+  0;   20;     12;      0;           0;    6;   Code_Table; Cloud type (C, Ct, CH, CL, or CM)
+  0;   20;     13;     -1;         -40;   11;            m; Height of base of cloud (h, hshs, hshshs, or H'H')
+  0;   20;     14;     -1;         -40;   11;            m; Height of top of cloud (HfHfHf or HtHt)
+  0;   20;     15;     -1;           0;   14;           Pa; Pressure at the base of cloud
+  0;   20;     16;     -1;           0;   14;           Pa; Pressure at the top of cloud (PcPcPc)
+  0;   20;     17;      0;           0;    4;   Code_Table; Cloud top description
+  0;   20;     18;     -1;          40;   11;            m; Low estimated height of cloud top
+  0;   20;     19;     -1;          40;   11;            m; High estimated height of cloud top (H1>Hn)
+  0;   20;     21;      0;           0;    4;   Code_Table; Middle cloud amount
+  0;   20;     22;      0;           0;    4;   Code_Table; High cloud amount
+  0;   20;     23;      0;           0;    7;      percent; Satellite sensed effective cloud amount
+  0;   20;     30;      0;           0;    4;   Code_Table; Total ice concentration
+  0;   20;     31;      2;           0;    7;            m; Ice deposit (thickness) (EsEs)
+  0;   20;     32;      0;           0;    3;   Code_Table; Rate of ice accretion (Rs)
+  0;   20;     33;      0;           0;    4;   Flag_Table; Cause of ice accretion (Is)
+  0;   20;     34;      0;           0;    5;   Code_Table; Sea ice concentration (Ci)
+  0;   20;     35;      0;           0;    4;   Code_Table; Amount and type of ice (zii...zii)
+  0;   20;     36;      0;           0;    5;   Code_Table; Ice situation
+  0;   20;     37;      0;           0;    5;   Code_Table; Ice development (bi)
+  0;   20;     38;      0;           0;   12;     deg_true; Bearing of ice edge
+  0;   20;     39;     -1;           0;   13;            m; Ice distance
+  0;   20;     41;      0;           0;    4;   Code_Table; Rate of icing (Ir)
+  0;   20;     49;      0;           0;   10;   Code_Table; Type of stability measure
+  0;   20;     50;      0;           0;   10;      Numeric; Value of stability
+  0;   20;     51;      0;           0;    7;      percent; Amount of low clouds
+  0;   20;     52;      0;           0;    7;      percent; Amount of middle clouds
+  0;   20;     53;      0;           0;    7;      percent; Amount of high clouds
+  0;   20;     61;      0;           0;   12;            m; Runway visual range (RVR) (VR...VR)
+  0;   20;     62;      0;           0;    5;   Code_Table; State of the ground (with or without snow) (E')
+  0;   20;     63;      0;           0;   10;   Code_Table; Special phenomena
+  0;   20;     71;      0;           0;    2;   Code_Table; Ice age code ID
+  0;   20;     72;      0;           0;    2;   Code_Table; Ice edge code ID
+  0;   20;    196;      0;           0;    8;    CCITT_IA5; Runway visibility tendency
+  0;   20;    197;      0;           0;    2;   Flag_Table; Landing wind shear indicator
+  0;   20;    199;      0;           0;    8;     deg_true; Visibility direction
+  0;   20;    205;      0;           0;   24;    CCITT_IA5; Cloud significant convection
+  0;   20;    206;      0;           0;   64;    CCITT_IA5; Significant present weather conditions
+  0;   20;    207;      0;           0;    4;   Code_Table; Pressure and altitude significance
+  0;   20;    208;      0;           0;    4;   Code_Table; Significant weather changes (Ws)
+  0;   20;    209;      0;           0;    4;   Code_Table; Distance of weather changes (Ss)
+  0;   20;    210;      0;           0;    4;   Code_Table; Distant weather (Wd)
+  0;   20;    211;      0;           0;    4;   Code_Table; Bearing of distant weather (dw)
+  0;   20;    213;      0;           0;    4;   Code_Table; Icing and contrail types (It)
+  0;   20;    216;      0;           0;    7;   Code_Table; Altitude of layer base where icing occurred (hihi)
+  0;   20;    219;      0;           0;    4;   Code_Table; Distance to center or line midpoint
+  0;   20;    220;      0;           0;    4;   Code_Table; Orientation of ellipse (Sr)
+  0;   20;    221;     -3;           0;   16;            m; Echo width or diameter (Ew)
+  0;   20;    222;     -3;           0;   16;            m; Echo axis length (El)
+  0;   20;    223;      0;           0;    8;   Code_Table; Echo character (ce)
+  0;   20;    224;      0;           0;    4;   Code_Table; Intensity of echo (Ie)
+  0;   20;    225;      0;           0;    3;   Code_Table; In flight horizontal visibility (Vi)
+  0;   20;    236;      0;           0;    8;    CCITT_IA5; Cloud base height
+  0;   20;    237;      0;           0;    7;   Code_Table; Horizontal visbility
+  0;   20;    240;      0;           0;    4;   Code_Table; Present weather (w)
+  0;   20;    242;      0;           0;    5;   Code_Table; Bearing of ice edge
+  0;   20;    244;      0;           0;    4;   Code_Table; cloud base height
+  0;   20;    245;      0;           0;  640;    CCITT_IA5; Remarks in plain language
+  0;   20;    246;      0;           0;    7;      percent; Ice coverage
+  0;   20;    247;      0;           0; 1656;    CCITT_IA5; Ice plain language text remarks
+  0;   20;    248;      0;           0;    7;   Code_Table; Height of base of cloud (hshs)
+  0;   20;    249;      0;           0;    7;   Code_Table; Height of top of cloud (HtHt)
+  0;   20;    254;      0;           0;    8;    CCITT_IA5; Extreme value indicator
+  0;   20;    255;      0;           0; 2040;    CCITT_IA5; Plain language text remarks
+  0;   21;      1;      0;         -64;    7;           dB; Horizontal reflectivity
+  0;   21;      2;      0;         -64;    7;           dB; Vertical reflectivity
+  0;   21;      3;      1;          -5;    7;           dB; Differential reflectivity
+  0;   21;      5;      0;         -65;    6;           dB; Linear depolarization ratio
+  0;   21;      6;      0;         -65;    6;           dB; Circular depolarization ratio
+  0;   21;     11;      0;        -128;    8;          m/s; Doppler mean velocity in X direction
+  0;   21;     12;      0;        -128;    8;          m/s; Doppler mean velocity in Y direction
+  0;   21;     13;      0;        -128;    8;          m/s; Doppler mean velocity in Z direction
+  0;   21;     14;      1;       -4096;   13;          m/s; Doppler mean velocity (radiational)
+  0;   21;     17;      1;       -4096;    8;          m/s; Doppler velocity spectral width
+  0;   21;     21;     -3;           0;    4;            m; Echo tops
+  0;   21;     30;      0;         -32;    8;           dB; Signal to noise ratio
+  0;   21;     31;      0;           0;    7;      kg/m**2; Vertical integrated liquid water content
+  0;   21;     36;      7;           0;   12;          m/s; Radar rainfall intensity
+  0;   21;     41;     -2;           0;    8;            m; Bright band height
+  0;   21;     51;      0;        -256;    8;           dB; Signal power above 1 MW
+  0;   21;    192;      0;           0;   14;            m; Heave sensor spectral peak length
+  0;   21;    193;      1;           0;   14;            s; Heave sensor spectral peak period
+  0;   21;    194;      2;           0;   14;      percent; AVHRR channel average
+  0;   21;    195;      2;           0;   14;      percent; Space view channel standard deviation
+  0;   21;    196;      2;           0;   15;        deg_K; Algorithm identifier
+  0;   21;    197;      2;           0;   15;        deg_K; AVHRR channel average
+  0;   21;    198;      2;       -5000;   13;           dB; Backscatter
+  0;   21;    199;      1;           0;   10;      percent; Noise figure percentage
+  0;   22;      1;      0;           0;    9;     deg_true; Direction of waves (dddd, da1da1, or d1d1>dndn)
+  0;   22;      2;      0;           0;    9;     deg_true; Direction of wind waves
+  0;   22;      3;      0;           0;    9;     deg_true; Direction of swell waves (dw1dw1 or dw2dw2)
+  0;   22;      4;      0;           0;    9;     deg_true; Direction of current (dodo>dndn or DcDc))
+  0;   22;     11;      0;           0;    6;            s; Period of waves (D'D'D'D', PaPaPaPa, or PwPw)
+  0;   22;     12;      0;           0;    6;            s; Period of wind waves
+  0;   22;     13;      0;           0;    6;            s; Period of swell waves (Pw1Pw1 or Pw2Pw2)
+  0;   22;     21;      1;           0;   10;            m; Height of waves (D'D'D'D' or HsHsHsHs)
+  0;   22;     22;      1;           0;   10;            m; Height of wind waves (HwHw)
+  0;   22;     23;      1;           0;   10;            m; Height of swell waves (Hw1Hw1 or Hw2Hw2)
+  0;   22;     25;      2;           0;   10;            m; Standard deviation wave
+  0;   22;     31;      2;           0;   13;          m/s; Speed of current (cococo>cncncn or VcVc)
+  0;   22;     41;      1;           0;   12;        deg_K; Sea surface temperature (15 day running mean)
+  0;   22;     42;      1;           0;   12;        deg_K; Sea temperature (T1T1T1>TnTnTn)
+  0;   22;     43;      2;           0;   15;        deg_K; Sea temperature (ToToToTo>TnTnTnTn)
+  0;   22;     44;      1;           0;   14;          m/s; Sound velocity
+  0;   22;     50;      2;           0;    8;        deg_K; Standard deviation sea surface temperature
+  0;   22;     61;      0;           0;    4;   Code_Table; State of sea
+  0;   22;     62;      2;           0;   14;          ppt; Salinity (SoSoSoSo>SnSnSnSn)
+  0;   22;     63;      0;           0;   14;            m; Total water depth (hhh or ZdZdZdZd)
+  0;   22;    105;     -1;           0;    6;     deg_true; Direction of waves (da2da2)
+  0;   22;    143;      2;           0;   13;        deg_K; Sea temperature
+  0;   22;    192;      0;           0;   14;            m; Wave length
+  0;   22;    193;      2;           0;   14;            m; Slope sensor significant wave height
+  0;   22;    194;      0;           0;   14;            m; Slope sensor spectral peak length
+  0;   22;    195;      1;           0;   14;            s; Slope sensor spectral peak period
+  0;   22;    196;      1;           0;   14;            s; Slope sensor mean wave period
+  0;   22;    197;      0;           0;   14;            m; Slope sensor mean wave length
+  0;   22;    198;      0;           0;    7;     deg_true; Wave directional spread
+  0;   22;    199;      1;           0;   14;            s; Time sample interval
+  0;   22;    200;      0;           0;   14;            m; Distance sample interval
+  0;   22;    201;      1;           0;   14;            s; Recorded wave duration
+  0;   22;    202;      0;           0;   14;            m; Recorded wave length
+  0;   22;    203;      0;           0;    7;      Numeric; Count of bands described
+  0;   22;    204;      0;           0;    4;   Code_Table; Wave expiration
+  0;   22;    205;      3;           0;   20; m**2/(Hz*rad); Wave spectra
+  0;   22;    206;      4;           0;   10;      Numeric; Drag coefficient
+  0;   22;    207;      2;           0;   16;            m; Maximum wave height
+  0;   22;    208;      2;           0;   16;            m; Significant wave height
+  0;   22;    209;      0;           0;    7;   Code_Table; directional spread
+  0;   22;    211;      0;           0;    8;   Code_Table; Bogus water mass classification
+  0;   22;    212;      0;           0;    8;   Code_Table; Discriminant water mass classification
+  0;   22;    213;      1;           0;   10;      percent; Classification probability
+  0;   22;    214;      0;           0;   10;      m**2/Hz; Heave sensor spectral density frequency
+  0;   22;    215;      0;           0;   10;         m**3; Heave sensor spectral density number
+  0;   22;    216;      0;           0;    7;      Numeric; Heave sensor band number
+  0;   22;    217;      0;           0;    7;      percent; Heave sensor ratio
+  0;   22;    218;      0;           0;    7;      Numeric; Slope sensor band number
+  0;   22;    219;      0;           0;    7;      percent; Slope sensor ratio
+  0;   22;    220;      0;           0;    8;   Code_Table; Front number
+  0;   22;    224;     -2;           0;   14;            m; Distance to front
+  0;   22;    229;      0;           0;    7;   Code_Table; Wave direction
+  0;   22;    232;      0;           0;    4;   Code_Table; Sea surface temperature method indicator
+  0;   22;    233;      0;           0;    3;   Code_Table; Sea temperature averaging period
+  0;   22;    236;      0;           0;    8;   Code_Table; Swell wave direction
+  0;   22;    237;     -2;           0;   14;            m; Significant wave height
+  0;   22;    238;     -2;           0;   14;            m; Maximum wave height
+  0;   22;    239;      0;           0;    6;      Numeric; Wave spectra direction count
+  0;   22;    240;      0;           0;    6;      Numeric; Wave spectra frequency count
+  0;   22;    241;      3;      -32768;   16;      Nt/m**2; Wave stress u-component
+  0;   22;    242;      3;      -32768;   16;      Nt/m**2; Wave stress v-component
+  0;   22;    243;      0;           0;    7;      percent; Whitecap probability
+  0;   22;    244;      0;           0;    7;   Code_Table; Estimated wave direction of spectral wave
+  0;   22;    245;      2;           0;   16;        deg_K; Surface temperature
+  0;   22;    246;      3;      -32768;   16;      Nt/m**2; Wind stress u-component
+  0;   22;    247;      3;      -32768;   16;      Nt/m**2; Wind stress v-component
+  0;   22;    248;      0;           0;   16;     deg_true; Wind wave direction
+  0;   22;    249;      2;           0;   16;            m; Height of wind wave
+  0;   22;    250;      1;           0;   16;            s; Period of wind waves
+  0;   22;    251;      0;           0;    6;      Numeric; Wave spectra direction
+  0;   22;    252;      0;           0;    6;      Numeric; Wave spectra frequency
+  0;   22;    253;      0;           0;   16;     deg_true; Direction of swell waves
+  0;   22;    254;      2;           0;   16;            m; Height of swell waves
+  0;   22;    255;      1;           0;   16;            s; Period of swell waves
+  0;   23;      1;      0;           0;    3;   Code_Table; Accident early notification - article applicable
+  0;   23;      2;      0;           0;    5;   Code_Table; Activity or facility involved in incident
+  0;   23;      3;      0;           0;    3;   Code_Table; Type of release
+  0;   23;      4;      0;           0;    3;   Code_Table; Countermeasures taken near border
+  0;   23;      5;      0;           0;    2;   Code_Table; Cause of incident
+  0;   23;      6;      0;           0;    3;   Code_Table; Incident situation
+  0;   23;      7;      0;           0;    3;   Code_Table; Characteristic of release
+  0;   23;      8;      0;           0;    2;   Code_Table; State of current release
+  0;   23;      9;      0;           0;    2;   Code_Table; State of expected release
+  0;   23;     16;      0;           0;    2;   Code_Table; Possibility of significant chemical toxic health effect
+  0;   23;     17;      6;           0;   20;       m**3/s; Flow discharge of major recipient
+  0;   23;     18;      0;           0;    3;   Code_Table; release behavior over time
+  0;   23;     19;      0;      -15000;   17;            m; Actual release height
+  0;   23;     21;      0;      -15000;   17;            m; Effective release height
+  0;   23;     22;      0;           0;   24;            m; Distance of relative point or site of incident
+  0;   23;     23;      1;           0;   12;          m/s; Main transport speed in atmosphere
+  0;   23;     24;      2;           0;   13;          m/s; Main transport speed in water
+  0;   23;     25;      2;           0;   13;          m/s; Main transport speed in ground water
+  0;   23;     27;      0;           0;    9;     deg_true; Main transport direction in atmosphere
+  0;   23;     28;      0;           0;    9;     deg_true; Main transport direction in water
+  0;   23;     29;      0;           0;    9;     deg_true; Main transport direction in ground water
+  0;   23;     31;      0;           0;    2;   Code_Table; Possibility that plume will encounter precip
+  0;   23;     32;      0;           0;    2;   Code_Table; Plume will encounter change in wind direction and/or speed flag
+  0;   24;      1;    -11;           0;   28;           Bq; Estimate of radioactivity released up to specified time
+  0;   24;      2;    -11;           0;   28;           Bq; Estimated maximum potential release
+  0;   24;      3;      0;           0;    5;   Code_Table; Composition of release
+  0;   24;      4;      0;           0;   16;    CCITT_IA5; Element name
+  0;   24;      5;      0;           0;    9;      Numeric; Isotope mass
+  0;   24;     11;      2;           0;   32;          mSv; Dose
+  0;   24;     12;      2;           0;   32;          mSv; Trajectory dose (defined location and expected time of arrival)
+  0;   24;     13;      2;           0;   32;          mSv; Gamma dose in air along the main transport path
+  0;   24;     21;      2;           0;   32;      Bq/m**3; Air concentration (named isotope type including gross beta)
+  0;   24;     22;      2;           0;   32;         Bq/l; Concentration in precipitation (of named isotope type)
+  0;   25;      1;     -1;           0;    6;            m; Range gate length
+  0;   25;      2;      0;           0;    4;      Numeric; Number of gates averaged
+  0;   25;      3;      0;           0;    8;      Numeric; Number of integrated pulses
+  0;   25;      4;      0;           0;    2;   Code_Table; Echo processing
+  0;   25;      5;      0;           0;    2;   Code_Table; Echo integration
+  0;   25;      6;      0;           0;    3;   Code_Table; Z to R conversion
+  0;   25;      7;      0;           0;   12;      Numeric; Z to R conversion factor
+  0;   25;      8;      2;           0;    9;      Numeric; Z to R conversion exponent
+  0;   25;      9;      0;           0;    4;   Flag_Table; Calibration method
+  0;   25;     10;      0;           0;    4;   Code_Table; Clutter treatment
+  0;   25;     11;      0;           0;    2;   Code_Table; Ground occultation correction (screening)
+  0;   25;     12;      0;           0;    2;   Code_Table; Range attenuation correction
+  0;   25;     13;      0;           0;    2;   Flag_Table; Bright band correction
+  0;   25;     15;      0;           0;    2;   Flag_Table; Radome attenuation correction
+  0;   25;     16;      5;           0;    6;         dB/m; Clear air attenuation correction
+  0;   25;     17;      0;           0;    2;   Flag_Table; Precipitation attenuation correction
+  0;   25;     18;      7;           0;    6;      Numeric; A to Z law for attenuation factor
+  0;   25;     19;      2;           0;    7;      Numeric; A to Z law for attenuation exponent
+  0;   25;     20;      0;           0;    2;   Code_Table; Mean speed estimation
+  0;   25;     21;      0;           0;    8;   Flag_Table; Wind computation enhancement
+  0;   25;     30;      0;           0;    2;   Code_Table; SST usage
+  0;   25;     31;      0;           0;    2;   Code_Table; 15 day SST availability
+  0;   25;     32;      0;           0;    2;   Code_Table; NOAA wind profiler high/low mode data
+  0;   25;     33;      0;           0;    2;   Code_Table; NOAA wind profiler submode
+  0;   25;     34;      0;           0;    4;   Code_Table; NOAA wind profiler Q/C test results
+  0;   25;     35;      0;           0;    3;   Code_Table; First guess adjustment
+  0;   25;     36;      3;       -5000;   14;      Numeric; NSTAR average value
+  0;   25;     37;      0;           0;    2;   Code_Table; HIRS-8 surface air temperature
+  0;   25;     38;      0;           0;    3;   Code_Table; TOVS filter flags
+  0;   25;     41;      0;           0;    3;   Code_Table; Method of determining direction of moving platform
+  0;   25;     42;      0;           0;    3;   Code_Table; Method of determining speed of moving platform
+  0;   25;    192;      0;           0;    8;   Code_Table; Type of correction
+  0;   25;    193;      0;           0;    3;   Code_Table; Land/sea flag
+  0;   25;    194;      0;           0;    2;   Code_Table; Day/night flag
+  0;   25;    195;      0;           0;    6;      Numeric; Surface model pressure
+  0;   25;    196;      0;           0;   16;      Numeric; Scan line count
+  0;   25;    197;      0;           0;    5;      Numeric; Box counter
+  0;   25;    198;      0;           0;    3;      Numeric; Minibox counter
+  0;   25;    199;      0;           0;    3;   Code_Table; Water vapor flag
+  0;   25;    200;      0;           0;    3;   Code_Table; TOVS retrieval low 20
+  0;   25;    201;      0;           0;    3;   Code_Table; TOVS retrieval temps high 20
+  0;   25;    202;      0;           0;    2;   Code_Table; TOVS super adiabatic flag
+  0;   25;    203;      0;           0;    2;   Code_Table; TOVS skin temperature flag
+  0;   25;    204;      0;           0;    2;   Code_Table; Stratospheric sounding unit flag
+  0;   25;    205;      0;           0;    4;   Code_Table; Latitude zones
+  0;   25;    206;      0;           0;    4;   Code_Table; TOVS instrument combinations
+  0;   25;    208;      0;           0;    8;   Code_Table; TARM flag
+  0;   25;    209;      0;           0;    4;   Code_Table; DMSP flag
+  0;   25;    211;      0;           0;   17;      Numeric; B-scan start time
+  0;   25;    212;      0;           0;    7;      Numeric; Counter (1-64)
+  0;   25;    213;      0;           0;    5;   Code_Table; Calculated surface type
+  0;   25;    214;      0;           0;    3;   Code_Table; Season flag
+  0;   25;    215;      0;        -127;    8;      Numeric; Missing packet counter
+  0;   25;    216;      0;           0;    3;   Code_Table; Observation Quality Code
+  0;   26;      1;      1;           0;   12;           hr; Principle time of daily reading in UTC of maximum temperature
+  0;   26;      2;      1;           0;   12;           hr; Principle time of daily reading in UTC of minimum temperature
+  0;   27;      1;      5;    -9000000;   25;          deg; Latitude (high accuracy)
+  0;   27;      2;      2;       -9000;   15;          deg; Latitude (coarse accuracy)
+  0;   27;      3;      2;       -9000;   15;          deg; Alternate latitude
+  0;   27;     20;      0;           0;   16;      Numeric; Satellite location counter
+  0;   27;     21;      0;           0;   16;      Numeric; Satellite sub-location dimensions
+  0;   28;      1;      5;   -18000000;   26;          deg; Longtiude (high accuracy)
+  0;   28;      2;      2;      -18000;   16;          deg; Longtiude (coarse accuracy)
+  0;   28;      3;      2;      -18000;   16;          deg; Alternate longtiude
+  0;   29;      1;      0;           0;    3;   Code_Table; Projection type
+  0;   29;      2;      0;           0;    2;   Code_Table; Coordinate grid type (Wr)
+  0;   30;      1;      0;           0;    4;      Numeric; Pixel value (4 bits)
+  0;   30;     21;      0;           0;   12;      Numeric; Number of pixels per row
+  0;   30;     22;      0;           0;   12;      Numeric; Number of pixels per column
+  0;   30;     31;      0;           0;    4;   Code_Table; Picture type
+  0;   30;     32;      0;           0;   16;   Flag_Table; Combined picture
+  0;   31;      0;      0;           0;    1;   Flag_Table; Delayed descriptor replication switch (1 bit)
+  0;   31;      1;      0;           0;    8;      Numeric; Delayed descriptor replication factor (255 or less)
+  0;   31;      2;      0;           0;   16;      Numeric; Extended delayed descriptor replication factor (65536 or less)
+  0;   31;     11;      0;           0;    8;      Numeric; Delayed descriptor and data replication factor
+  0;   31;     12;      0;           0;   16;      Numeric; Extended delayed descriptor and data replication factor
+  0;   31;     21;      0;           0;    6;   Code_Table; Associated field significance
+  0;   31;    192;      0;           0;    8;   Code_Table; Associated QC indicator
+  0;   31;    193;      0;           0;    8;   Code_Table; QC description identifier, indicates why a value is bad
+  0;   31;    194;      2;           0;    7;      Numeric; Associated correlation
+  0;   31;    195;      2;           0;    7;      Numeric; Associated probability of error
+  0;   31;    196;      0;           0;   13;   Flag_Table; UWI product confidence flag
+  0;   31;    197;      0;           0;   12;      Numeric; Solution probability
+  0;   31;    201;      0;           0;   10;      Numeric; Delayed replication factor (1023 or less)
+  0;   31;    211;      0;           0;    3;      Numeric; Delayed replication factor (15 or less)
+  0;   31;    221;      0;           0;    5;      Numeric; Delayed replication count (31 or less)
+  0;   31;    231;      0;           0;    6;      Numeric; Delayed replication factor (63 or less)
+  0;   31;    241;      0;           0;    4;      Numeric; Delayed replication factor (15 or less)
+  0;   48;      1;      0;           0;  128;    CCITT_IA5; Classification
+  0;   48;      2;      0;           0;  128;    CCITT_IA5; Classification modifier
+  0;   48;      3;      0;           0;  552;    CCITT_IA5; Release as
+  0;   48;      4;      0;           0;   12;           yr; Declassification - year
+  0;   48;      5;      0;           0;    4;           mo; Declassification - month
+  0;   48;      6;      0;           0;    6;          day; Declassification - day
+  0;   48;      7;      0;           0;  552;    CCITT_IA5; Release not
+  0;   48;      8;      0;           0;   64;    CCITT_IA5; Sender of original observation data
+  0;   48;      9;      0;           0;   80;    CCITT_IA5; Declassification instructions
+  0;   48;     10;      0;           0;   12;           yr; Send - year
+  0;   48;     11;      0;           0;    4;           mo; Send - month
+  0;   48;     12;      0;           0;    6;          day; Send - day
+  0;   48;     13;      0;           0;    4;           hr; Send - hour
+  0;   48;     14;      0;           0;    6;          min; Send - minutes
+  0;   48;     15;      0;           0;  552;    CCITT_IA5; Release to information
+  0;   48;     16;      0;           0;    5;           hr; Send - hour
+  0;   48;     17;      0;           0; 1104;    CCITT_IA5; Release to
+  0;   48;     18;      0;           0;  552;    CCITT_IA5; Release not
+  0;   48;     19;      0;           0;  552;    CCITT_IA5; Declassification instructions
+  0;   48;     20;      0;           0;  552;    CCITT_IA5; Classification modifier
+  0;   48;     21;      0;           0;  552;    CCITT_IA5; Sender of observational data
+  0;   48;     22;      0;           0;  160;    CCITT_IA5; Classification
+  0;   48;     27;      0;           0;   12;           yr; Receipt - year
+  0;   48;     28;      0;           0;    4;           mo; Receipt - month
+  0;   48;     29;      0;           0;    6;          day; Receipt - day
+  0;   48;     30;      0;           0;    5;           hr; Receipt - hour
+  0;   48;     31;      0;           0;    6;          min; Receipt - minutes
+  0;   48;     32;      0;           0;   48;    CCITT_IA5; Bulletin header update or correction indicator
+  0;   48;     33;      0;           0;   24;    CCITT_IA5; Receiving circuit
+  0;   48;     34;      0;           0;    6;      Numeric; Near-duplicate combination count
+  0;   50;      1;      0;           0;    2;   Code_Table; Quality of measurement of pressure, sst,
+  0;   50;      2;      0;           0;    2;   Code_Table; Quality of buoy satellite transmission (QN)
+  0;   50;      3;      0;           0;    4;   Code_Table; IGOSS quality codes (Qd, Qd1, Qd2, Q1, Qt)
+  0;   50;      6;      0;           0;    3;   Code_Table; Location quality codes (QL)
+  0;   50;     10;      2;           0;   15;        deg_K; GDEM temperature
+  0;   50;     14;      2;           0;   15;        deg_K; Feature model temperature
+  0;   50;     18;      0;           0;   16;      Numeric; Reliability
+  0;   50;     33;      0;           0;    8;      Numeric; Count of boundary points
+  0;   50;     34;      3;           0;   16;      Numeric; Frequency ratio
+  0;   50;     35;      0;           0;   12;            s; Time step of data (time increment)
+  0;   50;     42;      2;           0;   12;      Numeric; Mean wave direction
+  0;   50;     43;      3;           0;   12;      Numeric; Mean wave frequency
+  0;   50;     44;      4;           0;   12;      Numeric; First frequency
+  0;   50;    100;      0;           0;   12;           yr; Analysis DTG - year
+  0;   50;    101;      0;           0;    4;           mo; Analysis DTG - month
+  0;   50;    102;      0;           0;    6;          day; Analysis DTG - day
+  0;   50;    103;      0;           0;    5;           hr; Analysis DTG - hour
+  0;   50;    104;      0;           0;    6;      Numeric; Last observed sea depth
+  0;   51;      3;      0;           0;    5;   Flag_Table; Processing status
+  0;   51;      6;      0;           0;    6;      Numeric; Combination count
+  0;   51;      7;      0;           0;    2;   Code_Table; Quality control process status
diff --git a/data/tables/B3L-058000-005000-B b/data/tables/B3L-058000-005000-B
new file mode 100644
index 0000000..e437880
--- /dev/null
+++ b/data/tables/B3L-058000-005000-B
@@ -0,0 +1,908 @@
+#
+# B2L-058-001-B.001 - Local BUFR Table B for center 058 (FNMOC),
+# Minor Local Version 1
+#
+#					Data
+#F	X	Y	Scale	RefVal	Width	Units	Element Name
+  0;    0;      1;      0;           0;   24;    CCITT_IA5; Table A: entry
+  0;    0;      2;      0;           0;  256;    CCITT_IA5; Table A: data category description, line 1
+  0;    0;      3;      0;           0;  256;    CCITT_IA5; Table A: data category description, line 2
+  0;    0;      5;      0;           0;   24;    CCITT_IA5; BUFR edition number
+  0;    0;     10;      0;           0;    8;    CCITT_IA5; F descriptor to be added or defined
+  0;    0;     11;      0;           0;   16;    CCITT_IA5; X descriptor to be added or defined
+  0;    0;     12;      0;           0;   24;    CCITT_IA5; Y descriptor to be added or defined
+  0;    0;     13;      0;           0;  256;    CCITT_IA5; Element name, line 1
+  0;    0;     14;      0;           0;  256;    CCITT_IA5; Element name, line 2
+  0;    0;     15;      0;           0;  192;    CCITT_IA5; Units name
+  0;    0;     16;      0;           0;    8;    CCITT_IA5; Units scale sign
+  0;    0;     17;      0;           0;   24;    CCITT_IA5; Units scale (u)
+  0;    0;     18;      0;           0;    8;    CCITT_IA5; Units reference sign
+  0;    0;     19;      0;           0;   80;    CCITT_IA5; Units reference value
+  0;    0;     20;      0;           0;   24;    CCITT_IA5; Element data width
+  0;    0;     30;      0;           0;   40;    CCITT_IA5; Descriptor defining sequence
+  0;    1;      1;      0;           0;    7;      Numeric; WMO block number (II)
+  0;    1;      2;      0;           0;   10;      Numeric; WMO station number (iii)
+  0;    1;      3;      0;           0;    3;      Numeric; WMO region number
+  0;    1;      4;      0;           0;    3;      Numeric; WMO region sub-area
+  0;    1;      5;      0;           0;   17;      Numeric; Buoy/platform identifier
+  0;    1;      6;      0;           0;   64;    CCITT_IA5; Aircraft identifier (flight number) (Ia...Ia)
+  0;    1;      7;      0;           0;   10;   Code_Table; Satellite identifier (I1I2I2)
+  0;    1;      8;      0;           0;   64;    CCITT_IA5; Aircraft registration number (tail number)
+  0;    1;      9;      0;           0;   64;    CCITT_IA5; Type of commerical aircraft
+  0;    1;     10;      0;           0;   64;    CCITT_IA5; Stationary buoy platform identifier
+  0;    1;     11;      0;           0;   72;    CCITT_IA5; Ship or mobile land station identifier (D...D)
+  0;    1;     12;      0;           0;    9;     deg_true; Direction of motion of moving observing platform (dBdB)
+  0;    1;     13;      0;           0;   10;          m/s; Speed of motion of moving observing platform
+  0;    1;     14;      2;           0;   10;          m/s; Platform drift speed (high precision) (VBVB)
+  0;    1;     15;      0;           0;  160;    CCITT_IA5; Station or site name
+  0;    1;     20;      0;           0;    4;      Numeric; WMO Region sub-area
+  0;    1;     21;      0;           0;   14;      Numeric; Synoptic feature identifier
+  0;    1;     25;      0;           0;   24;    CCITT_IA5; Storm identifier
+  0;    1;     26;      0;           0;   64;    CCITT_IA5; WMO storm name
+  0;    1;     31;      0;           0;   16;   Code_Table; Generating center
+  0;    1;     32;      0;           0;    8;   Code_Table; Generating application
+  0;    1;     33;      0;           0;    8;   Code_Table; Generating center
+  0;    1;     34;      0;           0;    8;   Code_Table; Generating sub-center
+  0;    1;     41;      5; -1073741824;   31;          m/s; Absolute platform velocity - first component
+  0;    1;     42;      5; -1073741824;   31;          m/s; Absolute platform velocity - second component
+  0;    1;     43;      5; -1073741824;   31;          m/s; Absolute platform velocity - third component
+  0;    1;     60;      0;           0;   64;    CCITT_IA5; Aircraft reporting point (Beacon identifier
+  0;    1;     63;      0;           0;   64;    CCITT_IA5; ICAO location indicator (CCCC)
+  0;    1;     64;      0;           0;   32;    CCITT_IA5; Runway designator
+  0;    1;     75;      0;           0;   40;    CCITT_IA5; Tide station identification
+  0;    1;    192;      0;           0;   24;    CCITT_IA5; Receiving circuit
+  0;    1;    193;      0;           0;    4;   Code_Table; global octant
+  0;    1;    194;      0;           0;    4;      Numeric; Beam position
+  0;    1;    195;      0;           0;    4;      Numeric; Decimal point value (dp)
+  0;    1;    196;      0;           0;   64;    CCITT_IA5; Observation number
+  0;    1;    197;      0;           0;    6;      Numeric; Runway number
+  0;    1;    198;      0;           0;   10;   Code_Table; Marsden square number
+  0;    1;    199;      0;           0;   64;    CCITT_IA5; nature of mission
+  0;    1;    200;      0;           0;    2;   Code_Table; Radar Capability indicator (XXX)
+  0;    1;    201;      0;           0;    8;   Code_Table; Country or agency that operates the satellite
+  0;    1;    203;      0;           0;   16;    CCITT_IA5; Satellite name
+  0;    1;    204;      0;           0;   16;    CCITT_IA5; Satellite series
+  0;    1;    206;      0;           0;   32;    CCITT_IA5; TOVS generating center name
+  0;    1;    207;      0;           0;   72;    CCITT_IA5; File name
+  0;    1;    208;      0;           0;    4;   Code_Table; Satellite data type
+  0;    1;    209;      0;           0;    8;   Code_Table; Observation type for MCSST
+  0;    1;    210;      0;           0;    7;   Code_Table; Observation source
+  0;    1;    211;      0;           0;    5;      Numeric; Beam position
+  0;    1;    212;      0;           0;   24;      Numeric; Data processing block number
+  0;    1;    213;      0;           0;    3;   Code_Table; Tip source type identifier
+  0;    1;    214;      0;           0;   32;    CCITT_IA5; Header originator
+  0;    1;    215;      0;           0;   48;    CCITT_IA5; Bulletin header update or correction indicator
+  0;    1;    216;      0;           0;   14;      Numeric; Engineering status
+  0;    1;    217;      0;           0;    5;      Numeric; Satellite number
+  0;    1;    218;      0;           0;  176;    CCITT_IA5; Sequence (report) type
+  0;    1;    219;      0;           0;   40;    CCITT_IA5; Mission number
+  0;    1;    220;      0;           0;    7;      Numeric; Observation number
+  0;    1;    221;      0;           0;    8;   Code_Table; Surface type
+  0;    1;    222;      0;           0;   32;    CCITT_IA5; Report modifier
+  0;    1;    223;      0;           0;    3;   Code_Table; Runway parallel indicator
+  0;    1;    224;      0;           0;    5;   Code_Table; Terrain code identifier
+  0;    2;      1;      0;           0;    2;   Code_Table; Type of station (ix)
+  0;    2;      2;      0;           0;    4;   Flag_Table; Type of instrumentation for wind measurement (ewew)
+  0;    2;      3;      0;           0;    4;   Code_Table; Type of measuring instrumentation used (a4, I3, or I4)
+  0;    2;      4;      0;           0;    4;   Code_Table; Type of instrumentation for evaporation measur
+  0;    2;      5;      2;           0;    7;        deg_K; Precision of temperature observed (s3)
+  0;    2;     11;      0;           0;    8;   Code_Table; Radiosonde type (rara)
+  0;    2;     12;      0;           0;    4;   Code_Table; Radiosonde computational method
+  0;    2;     13;      0;           0;    4;   Code_Table; Solar and infrared radiation correction (Sr)
+  0;    2;     14;      0;           0;    7;   Code_Table; Tracking technique/status of system (sasa)
+  0;    2;     15;      0;           0;    4;   Code_Table; Radiosonde completeness
+  0;    2;     20;      0;           0;    9;   Code_Table; satellite classification
+  0;    2;     21;      0;           0;    9;   Flag_Table; Satellite instrumentation data used in processing
+  0;    2;     22;      0;           0;    8;   Flag_Table; Satellite data processing technique used
+  0;    2;     23;      0;           0;    4;   Code_Table; Cloud motion computational method
+  0;    2;     24;      0;           0;    4;   Code_Table; Integrated mean humidity computational method
+  0;    2;     25;      0;           0;   25;   Flag_Table; Satellite channel(s) used in computation
+  0;    2;     26;      2;           0;   12;            m; Cross track resolution
+  0;    2;     27;      2;           0;   12;            m; Along track resolution
+  0;    2;     28;      0;           0;   18;            m; segment size at nadir in X direction
+  0;    2;     29;      0;           0;   18;            m; segment size at nadir in Y direction
+  0;    2;     30;      0;           0;    3;   Code_Table; Method of current measurement (k5)
+  0;    2;     31;      0;           0;    5;   Code_Table; Duration and time of current measurement
+  0;    2;     32;      0;           0;    2;   Code_Table; Indicator for digitization (k1)
+  0;    2;     33;      0;           0;    3;   Code_Table; Method of salinity/depth measurement (k2)
+  0;    2;     34;      0;           0;    5;   Code_Table; Drogue type (id)
+  0;    2;     35;      0;           0;    9;            m; Cable length (ZdZdZd)
+  0;    2;     36;      0;           0;    2;   Code_Table; Buoy type (Ip or Vi...Vi)
+  0;    2;     37;      0;           0;    2;   Code_Table; Method of tidal observation
+  0;    2;     38;      0;           0;    4;   Code_Table; Sea surface temperature method indicator
+  0;    2;     39;      0;           0;    3;   Code_Table; Wet bulb temperature method indicator
+  0;    2;     40;      0;           0;    4;   Code_Table; Method of removing velocity and motion
+  0;    2;     41;      0;           0;    6;   Code_Table; Method for estimating reports related to synoptic features
+  0;    2;     44;      0;           0;    4;   Code_Table; Spectral calculation method (Im)
+  0;    2;     45;      0;           0;    4;   Code_Table; Platform type (Ip)
+  0;    2;     46;      0;           0;    4;   Code_Table; Wave measurement instrument (no symbol letters)
+  0;    2;     48;      0;           0;    4;   Code_Table; Satellite sensor indicator
+  0;    2;     49;      0;           0;    8;   Code_Table; Geostationary satellite data-processing technique used
+  0;    2;     50;      0;           0;   20;   Flag_Table; Geostationary sounder satellite channels used
+  0;    2;     51;      0;           0;    4;   Code_Table; Indicator to specify observing method for extreme temperatures
+  0;    2;     52;      0;           0;    6;   Flag_Table; Geostationary imager satellite channels used
+  0;    2;     53;      0;           0;    4;   Code_Table; GOES-I/M brightness temperature characteristics
+  0;    2;     54;      0;           0;    4;   Code_Table; GOES-I/M soundings parameter characteristics
+  0;    2;     55;      0;           0;    4;   Code_Table; Geostationary_soundings statistical parameters
+  0;    2;     56;      0;           0;    4;   Code_Table; Geostationary soundings accuracy statistics
+  0;    2;     57;      0;           0;    4;   Code_Table; Origin of first guess information for GOES-I/M soundings
+  0;    2;     58;      0;           0;    4;   Code_Table; Valid times of first guess information for GOES-I/M sounding
+  0;    2;     59;      0;           0;    4;   Code_Table; Origin of analysis information for GOES-I/M soundings
+  0;    2;     60;      0;           0;    4;   Code_Table; Origin of surface information for GOES-I/M soundings
+  0;    2;     61;      0;           0;    3;   Code_Table; Aircraft navigation system (s1)
+  0;    2;     62;      0;           0;    4;   Code_Table; Type of aircraft data relay system
+  0;    2;     63;      2;      -18000;   16;          deg; Aircraft roll angle
+  0;    2;     64;      0;           0;    2;   Code_Table; Roll angle quality
+  0;    2;     65;      0;           0;   40;    CCITT_IA5; ACARS ground receiving station
+  0;    2;     70;      0;           0;    4;   Code_Table; Original specification of latitude/longitude
+  0;    2;    100;      1;           0;   12;           db; Radar constant
+  0;    2;    101;      0;           0;    4;   Code_Table; Type of antenna
+  0;    2;    102;      0;           0;    8;            m; Antenna height above tower
+  0;    2;    103;      0;           0;    2;   Flag_Table; Radome
+  0;    2;    104;      0;           0;    4;   Code_Table; Antenna polarisation
+  0;    2;    105;      0;           0;    6;           dB; Maximum antenna gain
+  0;    2;    106;      1;           0;    6;          deg; 3-dB bandwidth
+  0;    2;    107;      0;           0;    6;           dB; Sidelobe suppression
+  0;    2;    108;      0;           0;    6;           dB; Crosspol discrimination (on axis)
+  0;    2;    109;      2;           0;   12;        deg/s; Antenna speed (azimuth)
+  0;    2;    110;      2;           0;   12;        deg/s; Antenna speed (elevation)
+  0;    2;    111;      1;           0;   10;          deg; Radar incidence angle
+  0;    2;    112;      1;           0;   12;          deg; Radar azimuth angle
+  0;    2;    113;      0;           0;    4;      Numeric; Number of azimuth looks
+  0;    2;    114;      0;           0;   15;         m**2; Antenna effective surface area
+  0;    2;    121;     -8;           0;    7;           Hz; Mean frequency
+  0;    2;    122;     -6;        -128;    8;           Hz; Frequency agility range
+  0;    2;    123;     -4;           0;    7;            W; Peak power
+  0;    2;    124;     -1;           0;    7;            W; Average power
+  0;    2;    125;     -1;           0;    8;           Hz; Pulse repetition frequency
+  0;    2;    126;      7;           0;    6;            s; Pulse width
+  0;    2;    127;     -6;           0;    7;           Hz; Receiver intermediate frequency
+  0;    2;    128;     -5;           0;    6;           Hz; Intermediate frequency bandwidth
+  0;    2;    129;      0;        -150;    5;           dB; Minimum detectable signal
+  0;    2;    130;      0;           0;    7;           dB; Dynamic range
+  0;    2;    131;      0;           0;    2;   Flag_Table; Sensitivity time control
+  0;    2;    132;      2;           0;    6;          deg; Azimuth pointing accuracy
+  0;    2;    133;      2;           0;    6;          deg; Elevation pointing accuracy
+  0;    2;    134;      2;           0;   16;          deg; Antenna beam azimuth
+  0;    2;    135;      2;       -9000;   15;          deg; Antenna elevation
+  0;    2;    136;     -3;           0;   16;            m; Range processed by range attenuation correction
+  0;    2;    140;      0;           0;    9;          deg; Satellite radar beam azimuth angle
+  0;    2;    141;      0;           0;   24;    CCITT_IA5; Measurement type serial number/identifier
+  0;    2;    142;      0;           0;   32;    CCITT_IA5; Ozone instrument
+  0;    2;    143;      0;           0;    7;   Code_Table; Instrument type
+  0;    2;    145;      0;           0;    4;   code_table; Wave length setting for Dobson instruments
+  0;    2;    146;      0;           0;    4;   code_table; Source conditions for Dobson instruments
+  0;    2;    152;      0;           0;   31;   flag_table; satellite instrument used in data processing
+  0;    2;    153;     -8;           0;   26;           Hz; satellite channel centre frequency
+  0;    2;    154;     -8;           0;   26;           Hz; satellite channel band width
+  0;    2;    163;      0;           0;    4;   code_table; height assignment method
+  0;    2;    164;      0;           0;    3;   code_table; tracer correlation method0	2	167	0	0	4	code_table	radiance computational method
+  0;    2;    167;      0;           0;    4;   code_table; radiance computational method
+  0;    2;    190;      0;           0;    8;   Code_Table; U, v quality indicator
+  0;    2;    191;      0;           0;    4;   Code_Table; W quality indicator
+  0;    2;    192;      0;           0;    2;   code_table; Wind units source ID
+  0;    2;    193;      0;           0;   20;      numeric; satellite channels used in computation
+  0;    2;    194;      0;           0;   15;      numeric; satellite channels used in computation
+  0;    2;    195;      0;           0;    4;   code_table; Reason for no report OR ground equipment used (a1)
+  0;    2;    196;      0;           0;    7;   code_table; Type of thermodynamic sensing equipment (eTeT)
+  0;    2;    197;      0;           0;    3;   code_table; Correction technique (cT, cw)
+  0;    2;    198;      0;           0;    4;   code_table; Data reduction method (mr)
+  0;    2;    199;      0;           0;    4;      Numeric; grp_pos_ind
+  0;    2;    200;      0;           0;    3;   code_table; Indicator for frequency or wave number (Ia)
+  0;    2;    201;      0;           0;    3;   code_table; Type of rocket motor (rm)
+  0;    2;    202;      0;           0;    7;   code_table; Type of wind sensing equipment (ewew)
+  0;    2;    203;      0;           0;    3;   Code_Table; Method of determining direction of moving platform
+  0;    2;    204;      0;           0;    3;   Code_Table; Method of determining speed of moving platform
+  0;    2;    205;      0;           0;    3;   Code_Table; Ozone flag
+  0;    2;    206;      0;           0;    4;   Code_Table; Algorithm identifier
+  0;    2;    207;      0;           0;    5;   Code_Table; Equation identifier
+  0;    2;    208;      0;           0;    2;   Code_Table; Type of method for measuring pressure
+  0;    2;    209;      0;           0;   10;   Code_Table; Xbt instrument type (IxIxIx)
+  0;    2;    210;      0;           0;    7;   Code_Table; Recorder type (XRXR)
+  0;    2;    211;      0;           0;    8;   Flag_Table; Sensor status flag
+  0;    2;    212;      0;           0;    2;   Flag_Table; Maintenance Check flag
+  0;    2;    213;      0;           0;    5;      numeric; satellite channels used in computation
+  0;    4;      1;      0;           0;   12;           yr; Year (4-digit)
+  0;    4;      2;      0;           0;    4;           mo; Month
+  0;    4;      3;      0;           0;    6;          day; Day
+  0;    4;      4;      0;           0;    5;           hr; Hour
+  0;    4;      5;      0;           0;    6;          min; Minute
+  0;    4;      6;      0;           0;    6;            s; Second
+  0;    4;     11;      0;       -1024;   11;           yr; Time increment - year
+  0;    4;     12;      0;       -1024;   11;           mo; Time increment - month
+  0;    4;     13;      0;       -1024;   11;          day; Time increment - day
+  0;    4;     14;      0;       -1024;   11;           hr; Time increment - hour
+  0;    4;     15;      0;       -2048;   12;          min; Time increment - minutes
+  0;    4;     16;      0;       -4096;   13;            s; Time increment - seconds
+  0;    4;     21;      0;       -1024;   11;           yr; Time period or displacement - year
+  0;    4;     22;      0;       -1024;   11;           mo; Time period or displacement - month
+  0;    4;     23;      0;       -1024;   11;          day; Time period or displacement - month
+  0;    4;     24;      0;       -2048;   12;           hr; Time period or displacement - hour
+  0;    4;     25;      0;       -2048;   12;          min; Time period or displacement - minutes
+  0;    4;     26;      0;       -4096;   13;            s; Time period or displacement - seconds
+  0;    4;     31;      0;           0;    8;           hr; Duration of time relative to following value (TT)
+  0;    4;     32;      0;           0;    6;          min; Duration of time relating to following value
+  0;    4;     41;      0;       -1440;   12;          min; Time difference, UTC - LMT
+  0;    4;     43;      0;           0;    9;          day; Day of the year
+  0;    4;     44;      0;           0;    3;   Code_Table; Day of the week (Y)
+  0;    4;     53;      0;           0;    6;      Numeric; Number of days with precipitation equal or more than 1 mm
+  0;    4;    192;      0;           0;    4;   Code_Table; Precipitation time period (tR)
+  0;    4;    193;      0;           0;   31;   Code_Table; Last time that this observation record was updated
+  0;    4;    200;      0;           0;   12;           yr; Time of receipt - year
+  0;    4;    201;      0;           0;    4;           mo; Time of receipt - month
+  0;    4;    202;      0;           0;    6;          day; Time of receipt - day
+  0;    4;    203;      0;           0;    5;           hr; Time of receipt - hour
+  0;    4;    204;      0;           0;    6;          min; Time of receipt - minute
+  0;    4;    206;      3;           0;   27;            s; GMT seconds
+  0;    5;      1;      5;    -9000000;   25;          deg; Latitude (high accuracy)
+  0;    5;      2;      2;       -9000;   15;          deg; Latitude (coarse accuracy) (La...La)
+  0;    5;     11;      5;    -9000000;   25;          deg; Latitude increment (high accuracy)
+  0;    5;     12;      2;       -9000;   15;          deg; Latitude increment (coarse accuracy)
+  0;    5;     21;      2;           0;   16;     deg_true; Bearing or azimuth
+  0;    5;     22;      2;           0;   16;     deg_true; Solar azimuth
+  0;    5;     30;      0;           0;   12;          deg; Direction (spectral)
+  0;    5;     31;      0;           0;   12;      Numeric; Row number
+  0;    5;     33;     -1;           0;   16;            m; Pixel size on horizontal - 1
+  0;    5;     40;      0;           0;   24;      Numeric; Orbit number
+  0;    5;     41;      0;           0;    8;      Numeric; Scan line number
+  0;    5;     42;      0;           0;    6;      Numeric; Channel number
+  0;    5;     43;      0;           0;    8;      Numeric; Field of view number
+  0;    5;     52;      0;           0;    5;      Numeric; Channel number increment
+  0;    5;     53;      0;           0;    5;      Numeric; Field of view number increment
+  0;    5;    192;      0;           0;    3;      Numeric; Image line number
+  0;    5;    193;      0;           0;    4;      Numeric; Image sample number
+  0;    5;    194;      0;           0;   14;      Numeric; Orbit number
+  0;    5;    195;      6;   -90000000;   28;          deg; six decimal pt latitude
+  0;    5;    196;      0;           0;   16;      Numeric; Orbit number
+  0;    5;    197;      0;           0;    8;      Numeric; Frame number
+  0;    5;    199;      0;           0;   20;      Numeric; Orbit number
+  0;    6;      1;      5;   -18000000;   26;          deg; Longtiude (high accuracy)
+  0;    6;      2;      2;      -18000;   16;          deg; Longtiude (coarse accuracy) (Lo...Lo)
+  0;    6;      3;      2;      -18000;   16;          deg; Alternate longtiude
+  0;    6;     11;      5;   -18000000;   26;          deg; Longtiude increment (high accuracy)
+  0;    6;     12;      2;      -18000;   16;          deg; Longtiude increment (coarse accuracy)
+  0;    6;     21;     -1;           0;   13;            m; Distance
+  0;    6;     30;      5;           0;   13;        rad/m; Wavenumber (spectral)
+  0;    6;     31;      0;           0;   12;      Numeric; Column number
+  0;    6;     33;     -1;           0;   16;            m; Pixel size on horizontal - 2
+  0;    6;    192;      6;  -180000000;   29;          deg; six decimal pt longitude
+  0;    7;      1;      0;        -400;   15;            m; Height of station (hohohoho)
+  0;    7;      2;     -1;         -40;   16;            m; Height or altitude (hahaha, hIhIhI, HmHmHm, HH, tnu2, or tnu3)
+  0;    7;      3;     -1;        -400;   17;    m**2/s**2; Geopotential
+  0;    7;      4;     -1;           0;   14;           Pa; Pressure (Pa...Pa, Paob...Paob, Po...Po, PtPtPt, or PAPA)
+  0;    7;      5;      0;        -400;   12;            m; Height increment
+  0;    7;      6;      0;           0;   15;            m; Height above station
+  0;    7;      7;      0;       -1000;   17;            m; Geopotential height
+  0;    7;     21;      2;       -9000;   15;          deg; Elevation
+  0;    7;     22;      2;       -9000;   15;          deg; Solar elevation
+  0;    7;     61;      2;           0;   14;            m; Depth below land surface
+  0;    7;     62;      1;           0;   17;            m; Depth below sea surface
+  0;    7;    190;      0;           0;   12;            m; Height increment
+  0;    7;    192;      2;           0;   13;          deg; Local zenith angle
+  0;    7;    196;      0;           0;    4;   Code_Table; Station height precision
+  0;    7;    197;      1;           0;   11;          deg; Solar zenith angle
+  0;    7;    198;      2;       -6000;   14;          deg; Satellite zenith angle
+  0;    7;    199;      1;           0;   11;          deg; Solar azimuth angle
+  0;    7;    200;      2;           0;   17;           Pa; Geopotential height
+  0;    7;    223;      2;           0;   14;          deg; Solar zenith angle
+  0;    7;    224;      1;           0;   14;            m; Surface elevation
+  0;    8;      1;      0;           0;    7;   Flag_Table; Vertical sounding significance
+  0;    8;      2;      0;           0;    6;   Code_Table; Vertical significance (surface observations)
+  0;    8;      3;      0;           0;    6;   Code_Table; Vertical significance (satellite observations)
+  0;    8;      4;      0;           0;    3;   Code_Table; Phase of aircraft flight (ipipip)
+  0;    8;      5;      0;           0;    4;   Code_Table; Surface synoptic features significance
+  0;    8;     11;      0;           0;    6;   Code_Table; Horizontal significance
+  0;    8;     12;      0;           0;    2;   Code_Table; land/sea qualifier
+  0;    8;     13;      0;           0;    2;   Code_Table; Day/night qualifier
+  0;    8;     14;      0;           0;    4;   code_table; Qualification for runway visual range
+  0;    8;     16;      0;           0;    3;   code_table; Change indicator of a trend-type forecast or an aerodrome forecast
+  0;    8;     17;      0;           0;    2;   code_table; Qualifier of the time when the forecast change is expected
+  0;    8;     20;      0;           0;   16;      numeric; Qualification for runway visual range
+  0;    8;     21;      0;           0;    5;   Code_Table; Time significance
+  0;    8;     22;      0;           0;   16;      Numeric; Total number (with respect to accumulation or average)
+  0;    8;     23;      0;           0;    6;   code_table; First order statistics
+  0;    8;     24;      0;           0;    6;   code_table; Difference statistics
+  0;    8;     25;      0;           0;    4;   code_table; Time difference qualifier
+  0;    8;     30;      0;           0;   13;      numeric; Manual on Codes (Volume I.1, Section C) Code table from which data are derived
+  0;    8;     51;      0;           0;    3;   Code_Table; Qualifier for number of missing values in calculation of statistic
+  0;    8;     52;      0;           0;    5;   Code_Table; Condition for which number of days of occurrence follows
+  0;    8;     53;      0;           0;    2;   Code_Table; Day of occurrence qualifier
+  0;    8;    194;      0;           0;    4;   Code_Table; Flight condition (fc)
+  0;   10;      1;      0;        -400;   15;            m; Height of land surface
+  0;   10;      2;     -1;         -40;   16;            m; Height (HHH)
+  0;   10;      3;     -1;        -400;   17;    m**2/s**2; Geopotential
+  0;   10;      4;     -1;           0;   14;           Pa; Pressure
+  0;   10;      7;      0;       -1000;   17;            m; Geopotential height
+  0;   10;      8;      0;      -10000;   20;    m**2/s**2; Geopotential
+  0;   10;     31;      2; -1073741824;   31;    deg_K*m/s; In direction of the North Pole, distance from the Earth's center
+  0;   10;     50;      2;           0;   16;            m; Standard deviation altitude
+  0;   10;     51;     -1;           0;   14;           Pa; Pressure reduced to mean sea level (PPPP)
+  0;   10;     52;     -1;           0;   14;           Pa; Altimeter setting (QNH) (PH...PH)
+  0;   10;     60;     -1;       -1024;   11;           Pa; Pressure change (ppp)
+  0;   10;     61;     -1;        -500;   10;           Pa; 3 hour pressure change
+  0;   10;     62;     -1;       -1000;   11;           Pa; 24 hour pressure change
+  0;   10;     63;      0;           0;    4;   Code_Table; Characteristic of pressure tendency (a, w, or w'w')
+  0;   10;     70;      0;        -400;   16;            m; Indicated aircraft altitude
+  0;   10;    197;      0;           0;    4;   Code_Table; Index pertaining to geopotential height (j)
+  0;   10;    199;      0;       -1024;   16;            m; Geopotential height difference
+  0;   10;    200;      0;       -1024;   16;            m; Geopotental height correction
+  0;   10;    201;      0;           0;   14;   Code_Table; Pressure tendency QC ID
+  0;   10;    203;      0;           0;    4;   Code_Table; Geopotential height quality control flag
+  0;   10;    213;      0;       -1024;   16;            m; Geopotential height
+  0;   10;    224;      0;           0;    4;   Code_Table; Station level pressure QC ID
+  0;   10;    251;      0;           0;    4;   Code_Table; Mean sea level pressure QC ID
+  0;   11;      1;      0;           0;    9;     deg_true; Wind direction (dd, dodo>dndn, dmagdmag)
+  0;   11;      2;      1;           0;   12;          m/s; Wind speed (ff, fff, or fofofo>fnfnfn)
+  0;   11;      3;      1;       -4096;   13;          m/s; U-component
+  0;   11;      4;      1;       -4096;   13;          m/s; V-component
+  0;   11;      5;      1;        -512;   10;         Pa/s; W-component
+  0;   11;      6;      2;       -4096;   13;          m/s; W-component
+  0;   11;     11;      0;           0;    9;     deg_true; Wind direction at 10 m
+  0;   11;     12;      1;           0;   12;          m/s; Wind speed at 10 m
+  0;   11;     13;      0;           0;    9;     deg_true; Wind direction at 5 m
+  0;   11;     14;      1;           0;   12;          m/s; Wind speed at 5 m
+  0;   11;     16;      0;           0;    9;     deg_true; Extreme counterclockwise wind direction of a variable wind
+  0;   11;     17;      0;           0;    9;     deg_true; Extreme clockwise wind direction of a variable wind
+  0;   11;     21;      9;      -65536;   17;          1/s; Relative vorticity
+  0;   11;     22;      9;      -65536;   17;          1/s; Divergence
+  0;   11;     23;     -2;      -65536;   17;       m**2/s; Velocity potential
+  0;   11;     31;      0;           0;    4;   Code_Table; Degree of turbulence (B...B or BA)
+  0;   11;     32;     -1;         -40;   16;            m; Height of base of turbulence (BabBabBab or B1B1B1)
+  0;   11;     33;     -1;         -40;   16;            m; Height of top of turbulence (BatBatBat or B1B1B1)
+  0;   11;     34;      1;       -1024;   11;          m/s; Vertical gust velocity
+  0;   11;     35;      2;       -8192;   14;       m/s**2; Vertical gust acceleration
+  0;   11;     36;      1;           0;   10;          m/s; Maximum derived equivalent vertical gust
+  0;   11;     41;      1;           0;   12;          m/s; Maximum wind speed (gusts) (fm...fm)
+  0;   11;     42;      1;           0;   12;          m/s; Maximum wind speed (10 minute mean wind)
+  0;   11;     43;      0;           0;    9;     deg_true; Maximum wind gust direction
+  0;   11;     44;      0;           0;    9;     deg_true; Surface - 5000 feet mean LYR wind direction
+  0;   11;     45;      1;           0;   12;          m/s; Mean wind speed for surface -- 1500 m (5000 ft)	m/s
+  0;   11;     49;      0;           0;    9;     deg_true; Standard deviation of wind direction
+  0;   11;     50;      1;           0;   12;          m/s; Standard deviation horizontal wind speed
+  0;   11;     51;      1;           0;    8;          m/s; Standard deviation vertical wind component
+  0;   11;     61;      1;           0;   12;          m/s; Absolute wind shear (1 kilometer layer below)
+  0;   11;     62;      1;           0;   12;          m/s; Absolute wind shear (1 kilometer layer above)
+  0;   11;     70;      0;           0;   32;    character; Designator of the runway affected by wind shear (including ALL)
+  0;   11;     71;      3;        -128;   14;    m**2/s**2; Turbulent vertical momentum flux
+  0;   11;     72;      3;        -128;   11;         km/s; Turbulent vertical buoyancy flux
+  0;   11;     73;      2;       -1024;   13;    m**2/s**2; Turbulent kinetic energy
+  0;   11;     74;      2;       -1024;   10;    m**2/s**2; Dissipitation energy
+  0;   11;     75;      2;           0;    8;   (m**2/3)/s; Mean turbulence intensity
+  0;   11;     76;      2;           0;    8;   (m**2/3)/s; Peak turbulence intensity
+  0;   11;    195;      0;           0;    2;   Code_Table; Wind type at flight altitude (dt)
+  0;   11;    200;      0;           0;    4;   Code_Table; Wind QC ID
+  0;   11;    203;      1;       -4096;   13;          m/s; Wind u-component difference
+  0;   11;    204;      1;       -4096;   13;          m/s; Wind v-component difference
+  0;   11;    205;      0;           0;    4;   Code_Table; Turbulence (B) (WMO code table 0300)
+  0;   11;    206;      0;           0;    2;   Code_Table; Flight level wind method (da)
+  0;   11;    207;      0;           0;    2;   Code_Table; Extreme wind speed ID
+  0;   11;    213;      1;       -4096;   13;          m/s; Wind u-component correction
+  0;   11;    214;      1;       -4096;   13;          m/s; Wind v-component correction
+  0;   11;    244;      0;           0;   16;     deg_true; Direction of wind
+  0;   11;    245;      2;           0;   16;          m/s; wnd_spd
+  0;   11;    246;      1;           0;    8;          m/s; Ocean surface wind speed
+  0;   12;      1;      1;           0;   12;        deg_K; Temperature/dry bulb temperature (Ta, TsTsTs, TtTt, or TxTxTx)
+  0;   12;      2;      1;           0;   12;        deg_K; Wet bulb temperature (TbTbTb)
+  0;   12;      3;      1;           0;   12;        deg_K; Dewpoint (TdTdTd or T'dT'd)
+  0;   12;      4;      1;           0;   12;        deg_K; Dry bulb temperature at 2 meters (Tao>Tan, ToTo>tnTn, or TT)
+  0;   12;      5;      1;           0;   12;        deg_K; Wet bulb temperature at 2 meters
+  0;   12;      6;      1;           0;   12;        deg_K; Dewpoint temperature at 2 meters
+  0;   12;      7;      1;           0;   12;        deg_K; Virtual temperature
+  0;   12;     11;      1;           0;   12;        deg_K; Maximum temperature
+  0;   12;     12;      1;           0;   12;        deg_K; Minimum temperature (TnTnTn)
+  0;   12;     13;      1;           0;   12;        deg_K; Ground minimum temperature past 12 hours
+  0;   12;     14;      1;           0;   12;        deg_K; Maximum temperature at 2 meters, past 12 hours
+  0;   12;     15;      1;           0;   12;        deg_K; Minimum temperature at 2 meters, past 12 hours
+  0;   12;     16;      1;           0;   12;        deg_K; Maximum temperature at 2 meters, past 24 hours
+  0;   12;     17;      1;           0;   12;        deg_K; Minimum temperature at 2 meters, past 24 hours
+  0;   12;     30;      1;           0;   12;        deg_K; Soil temperature (ToTo)
+  0;   12;     51;      1;           0;   10;        deg_K; Standard deviation temperature
+  0;   12;     52;      1;           0;   12;        deg_K; Highest daily mean temperature
+  0;   12;     53;      1;           0;   12;        deg_K; Lowest daily mean temperature
+  0;   12;     61;      1;           0;   12;        deg_K; Skin temperature
+  0;   12;     62;      1;           0;   12;        deg_K; Equivalent black body temperature
+  0;   12;     63;      1;           0;   12;        deg_K; Brightness temperature
+  0;   12;     70;      2;           0;   16;        deg_K; Vertical polarization 19GHz brightness temperature
+  0;   12;     71;      1;           0;   12;        deg_K; Coldest cluster temperaturee
+  0;   12;     72;      2;           0;   16;        deg_K; Vertical polarization 22GHz brightness temperature
+  0;   12;     73;      2;           0;   16;        deg_K; Vertical polarization 37GHz brightness temperature
+  0;   12;     74;      2;           0;   16;        deg_K; Horizontal polarization 37GHz brightness temperature
+  0;   12;     75;      2;           0;   16;        deg_K; Vertical polarization 85GHz brightness temperature
+  0;   12;     76;      2;           0;   16;        deg_K; Horizontal polarization 85GHz brightness temperature
+  0;   12;    192;      0;           0;    4;   Code_Table; Wet bulb temperature indicator
+  0;   12;    193;      2;           0;   16;        deg_K; SSU brightness temperature
+  0;   12;    194;      2;           0;   16;        deg_K; Dewpoint
+  0;   12;    195;      0;           0;    4;   Code_Table; Dewpoint, aircraft altitude, air temperature indicator (id)
+  0;   12;    196;      2;           0;   16;        deg_K; Dewpoint difference
+  0;   12;    201;      0;           0;    4;   Code_Table; Air temperature QC ID
+  0;   12;    213;      0;           0;    4;   Code_Table; Dewpoint QC ID
+  0;   12;    215;      0;           0;    2;   Code_Table; Temperature precision flag
+  0;   12;    220;      2;           0;   16;        deg_K; HIRS brightness temperature
+  0;   12;    221;      2;           0;   16;        deg_K; MSU brightness temperature
+  0;   13;      1;      5;           0;   14;        kg/kg; Specific humidity
+  0;   13;      2;      5;           0;   14;        kg/kg; Mixing ratio
+  0;   13;      3;      0;           0;    7;      percent; Relative humidity (U1>Un or U...U)
+  0;   13;      4;     -1;           0;   10;           Pa; Vapor pressure
+  0;   13;      5;      3;           0;    7;      kg/m**3; Vapor density (p1p1p1)
+  0;   13;      6;     -1;         -40;   16;            m; Mixing heights
+  0;   13;     11;      1;          -1;   14;      kg/m**2; Total precipitation/total water equivalent (Aw or R...R)
+  0;   13;     12;      2;          -2;   12;            m; Depth of fresh snow
+  0;   13;     13;      2;          -2;   16;            m; Total snow depth (sss)
+  0;   13;     14;      4;           0;   12;    kg/m**2/s; Rainfall/water equivalent of snow (average rate)
+  0;   13;     15;      7;           0;   12;          m/s; Snowfall (averaged rate)
+  0;   13;     16;      0;           0;    7;      kg/m**2; Precipitable water (www)
+  0;   13;     19;      1;          -1;   14;      kg/m**2; Total precipitation past 1 hour
+  0;   13;     20;      1;          -1;   14;      kg/m**2; Total precipitation past 3 hours
+  0;   13;     21;      1;          -1;   14;      kg/m**2; Total precipitation past 6 hours
+  0;   13;     22;      1;          -1;   14;      kg/m**2; Total precipitation past 12 hours
+  0;   13;     23;      1;          -1;   14;      kg/m**2; Total precipitation past 24 hours (R24...R24)
+  0;   13;     31;      0;           0;    7;      kg/m**2; Evapotranspiration
+  0;   13;     32;      1;           0;    8;      kg/m**2; Evaporation/evapotranspiration
+  0;   13;     33;      1;           0;   10;      kg/m**2; Evaporation/evapotranspiration
+  0;   13;     38;      0;           0;    2;   code_table; Superadiabatic indicator
+  0;   13;     39;      0;           0;    3;   code_table; Terrain type (ice/snow)
+  0;   13;     41;      0;           0;    4;   Code_Table; Pasquill-Gifford stability category
+  0;   13;     42;      0;         -20;    6;        deg_K; Parcel lifted index (to 500 hPa)
+  0;   13;     43;      0;         -20;    6;        deg_K; Best lifted index (to 500 hPa)
+  0;   13;     51;      0;           0;    4;   Code_Table; Frequency group, precipitation
+  0;   13;     52;      1;          -1;   14;      kg/m**2; Highest daily amount of precipiation
+  0;   13;     71;      1;           0;    7;      kg/m**2; Liquid water
+  0;   13;     75;      0;           0;    8;      percent; Land snow cloud
+  0;   13;     76;      2;           0;    6;            m; Snow-water equivalent
+  0;   13;    192;      0;           0;    4;   Code_Table; Precipitation identifier (iR)
+  0;   13;    193;      0;           0;   10;   Code_Table; Precipitation amount
+  0;   13;    194;      3;           0;   16;         g/kg; First guess mixing ratios
+  0;   13;    195;      0;           0;   10;      kg/m**3; 0	Density (p1p1p1)
+  0;   13;    196;      0;           0;    7;           mm; Soil moisture
+  0;   13;    197;      0;           0;    3;   Code_Table; Rain indicator
+  0;   13;    198;      2;           0;   11;           cm; Total precipatable water
+  0;   13;    199;      0;           0;    2;      numeric; prcp_ind_id
+  0;   13;    203;      0;           0;    4;   Code_Table; Relative hunidity QC ID
+  0;   13;    217;      0;           0;    8;      Numeric; Precipitation flag (SSM/T)
+  0;   13;    218;      2;           0;   11;    kg/(m**2); Cloud water
+  0;   13;    219;      1;           0;   10;    kg/(m**2); Ocean water vapo
+  0;   13;    220;      1;           0;    9;        mm/hr; Rain rate
+  0;   13;    221;      2;           0;   14;    kg/(m**2); Cloud Liquid Water
+  0;   14;      1;     -3;       -2048;   12;       J/m**2; Longwave radiation, integrated over 24 hours (FLFLFL)
+  0;   14;      3;     -3;       -2048;   12;       J/m**2; Shortwave radiation, integrated over 24 hours (FiFiFi)
+  0;   14;      4;     -3;       -2048;   12;       J/m**2; Shortwave radiation, integrated over period specified (FsFsFs)
+  0;   14;     11;     -3;       -2048;   12;       J/m**2; Net longwave radiation, integrated over 24 hours
+  0;   14;     12;     -3;       -2048;   12;       J/m**2; Net longwave radiation, integrated over period specified
+  0;   14;     13;     -3;       -2048;   12;       J/m**2; Net shortwave radiation, integrated over 24 hours
+  0;   14;     14;     -3;       -2048;   12;       J/m**2; Net shortwave radiation, integrated over period specified
+  0;   14;     15;     -4;      -16384;   15;       J/m**2; Net radiation, integrated over 24 hours
+  0;   14;     16;     -4;      -16384;   15;       J/m**2; Net radiation, integrated over period specified
+  0;   14;     17;     -3;       -2048;   12;       W/m**2; Instantaneous long wave radiation
+  0;   14;     18;     -3;       -2048;   12;       W/m**2; Instantaneous short wave radiation
+  0;   14;     19;      0;           0;    7;      percent; Surface albedo
+  0;   14;     20;     -4;           0;   15;       J/m**2; Global solar radiation, integrated over 24 hours
+  0;   14;     21;     -4;           0;   15;       J/m**2; Global radiation, integrated over period specified
+  0;   14;     22;     -4;           0;   15;       J/m**2; Diffuse solar radiation, integrated over 24 hours
+  0;   14;     23;     -4;           0;   15;       J/m**2; Diffuse solar radiation, integratedi over period specified
+  0;   14;     24;     -4;           0;   15;       J/m**2; Direct solar radiation, integrated over 24 hours
+  0;   14;     25;     -4;           0;   15;       J/m**2; Direct solar radiation, integrated over period specified
+  0;   14;     26;      0;           0;    7;      percent; Albedo at top of clouds
+  0;   14;     31;      0;           0;   11;          min; Total sunshine
+  0;   14;     32;      0;           0;   10;           hr; Total sunshine
+  0;   14;     33;      0;           0;    9;      percent; Total sunshine (precentage)
+  0;   14;     41;      0;           0;    7;      percent; Short wave albedo
+  0;   14;     42;      0;           0;    7;      percent; Bi-directional reflectance
+  0;   15;      1;      0;           0;   10;  dobson_unit; Ozone
+  0;   15;      2;      2;           0;   10;      Numeric; Air-mass (slant path at 22 km)
+  0;   15;     11;      3;       14000;   13;  log(1/m**2); Log 10 of integrated electron density
+  0;   15;     15;      0;           0;   31;      numeric; Maximum spectral composition before normalization
+  0;   19;      1;      0;           0;    6;   Code_Table; Type of synoptic features
+  0;   19;      2;     -2;           0;   12;            m; Effective radius of feature
+  0;   19;      3;      0;           0;    8;          m/s; Wind speed threshold
+  0;   19;      4;     -2;           0;   12;            m; Effective radius of feature with respect to wind speeds above threshold
+  0;   19;      5;      0;           0;    9;     deg_true; Direction of motion of features (dsds)
+  0;   19;      6;      2;           0;   14;          m/s; Speed of motion of features
+  0;   19;      7;     -3;           0;   12;            m; Effective radius of features
+  0;   19;      8;      0;           0;    3;   Code_Table; Vertical extent of circulation
+  0;   19;      9;     -3;           0;   12;            m; Effective radiation with respect to FFF above threshold
+  0;   20;      1;     -1;           0;   13;            m; Horizontal visibility (Dv, Vi, V...V, or VxVxVxVx)
+  0;   20;      2;     -1;           0;    7;            m; Vertical visibility
+  0;   20;      3;      0;           0;    9;   Code_Table; Present weather (ww or w'w')
+  0;   20;      4;      0;           0;    5;   Code_Table; Past weather (1) (Wa1Wa2 or W1W2)
+  0;   20;      5;      0;           0;    5;   Code_Table; Past weather (2) (wawa)
+  0;   20;      9;      0;           0;    4;   Code_Table; General Weather Indicator
+  0;   20;     10;      0;           0;    7;      percent; Cloud cover (total) (N, NcNc, or Ns...Ns)
+  0;   20;     11;      0;           0;    4;   Code_Table; Cloud amount (N or Ns...Ns)
+  0;   20;     12;      0;           0;    6;   Code_Table; Cloud type (C, Ct, CH, CL, or CM)
+  0;   20;     13;     -1;         -40;   11;            m; Height of base of cloud (h, hshs, hshshs, or H'H')
+  0;   20;     14;     -1;         -40;   11;            m; Height of top of cloud (HfHfHf or HtHt)
+  0;   20;     15;     -1;           0;   14;           Pa; Pressure at the base of cloud
+  0;   20;     16;     -1;           0;   14;           Pa; Pressure at the top of cloud (PcPcPc)
+  0;   20;     17;      0;           0;    4;   Code_Table; Cloud top description
+  0;   20;     18;      0;           0;    2;   Code_Table; Tendency of runway visual range	code_table
+  0;   20;     19;      0;           0;   72;    character; Significant present or forecast weather	character
+  0;   20;     20;      0;           0;   32;    character; Significant recent weather phenomena
+  0;   20;     31;      2;           0;    7;            m; Ice deposit (thickness) (EsEs)
+  0;   20;     32;      0;           0;    3;   Code_Table; Rate of ice accretion (Rs)
+  0;   20;     33;      0;           0;    4;   Flag_Table; Cause of ice accretion (Is)
+  0;   20;     34;      0;           0;    5;   Code_Table; Sea ice concentration (Ci)
+  0;   20;     35;      0;           0;    4;   Code_Table; Amount and type of ice (zii...zii)
+  0;   20;     36;      0;           0;    5;   Code_Table; Ice situation
+  0;   20;     37;      0;           0;    5;   Code_Table; Ice development (bi)
+  0;   20;     38;      0;           0;   12;     deg_true; Bearing of ice edge
+  0;   20;     39;     -1;           0;   13;            m; Ice distance
+  0;   20;     41;      0;           0;    4;   Code_Table; Rate of icing (Ir)
+  0;   20;     51;      0;           0;    7;      percent; Amount of low clouds
+  0;   20;     52;      0;           0;    7;      percent; Amount of middle clouds
+  0;   20;     53;      0;           0;    7;      percent; Amount of high clouds
+  0;   20;     61;      0;           0;   12;            m; Runway visual range (RVR) (VR...VR)
+  0;   20;     62;      0;           0;    5;   Code_Table; State of the ground (with or without snow) (E')
+  0;   20;     63;      0;           0;   10;   Code_Table; Special phenomena
+  0;   20;    192;      0;           0; 2040;    character; Remark
+  0;   20;    193;      0;           0; 1024;    character; 128 char plain language text remark
+  0;   20;    194;      0;           0;   11;      kg/m**2; cloud liquid water
+  0;   20;    196;      0;           0;    8;    CCITT_IA5; Runway visibility tendency
+  0;   20;    197;      0;           0;    2;   Flag_Table; Landing wind shear indicator
+  0;   20;    199;      0;           0;    9;     deg_true; Visibility direction
+  0;   20;    205;      0;           0;   24;    CCITT_IA5; Cloud significant convection
+  0;   20;    206;      0;           0;   64;    CCITT_IA5; Significant present weather conditions
+  0;   20;    207;      0;           0;    4;   Code_Table; Pressure and altitude significance
+  0;   20;    208;      0;           0;    4;   Code_Table; Significant weather changes (Ws)
+  0;   20;    209;      0;           0;    4;   Code_Table; Distance of weather changes (Ss)
+  0;   20;    210;      0;           0;    4;   Code_Table; Distant weather (Wd)
+  0;   20;    211;      0;           0;    4;   Code_Table; Bearing of distant weather (dw)
+  0;   20;    213;      0;           0;    4;   Code_Table; Icing and contrail types (It)
+  0;   20;    216;      0;           0;    7;   Code_Table; Altitude of layer base where icing occurred (hihi)
+  0;   20;    219;      0;           0;    4;   Code_Table; Distance to center or line midpoint
+  0;   20;    220;      0;           0;    4;   Code_Table; Orientation of ellipse (Sr)
+  0;   20;    221;     -3;           0;   16;            m; Echo width or diameter (Ew)
+  0;   20;    222;     -3;           0;   16;            m; Echo axis length (El)
+  0;   20;    223;      0;           0;    8;   Code_Table; Echo character (ce)
+  0;   20;    224;      0;           0;    4;   Code_Table; Intensity of echo (Ie)
+  0;   20;    225;      0;           0;    3;   Code_Table; In flight horizontal visibility (Vi)
+  0;   20;    236;      0;           0;    8;    CCITT_IA5; Cloud base height
+  0;   20;    237;      0;           0;    7;   Code_Table; Horizontal visbility
+  0;   20;    240;      0;           0;    4;   Code_Table; Present weather (w)
+  0;   20;    242;      0;           0;    5;   Code_Table; Bearing of ice edge
+  0;   20;    244;      0;           0;    4;   Code_Table; cloud base height
+  0;   20;    245;      0;           0;  640;    CCITT_IA5; Remarks in plain language
+  0;   20;    246;      0;           0;    7;      percent; Ice coverage
+  0;   20;    247;      0;           0; 1656;    CCITT_IA5; Ice plain language text remarks
+  0;   20;    248;      0;           0;    2;   Code_Table; Ice age identifier
+  0;   20;    249;      0;           0;    2;   Code_Table; Ice edge identifier
+  0;   20;    254;      0;           0;    8;    CCITT_IA5; Extreme value indicator
+  0;   20;    255;      0;           0; 2040;    CCITT_IA5; Plain language text remarks
+  0;   21;      1;      0;         -64;    7;           dB; Horizontal reflectivity
+  0;   21;      2;      0;         -64;    7;           dB; Vertical reflectivity
+  0;   21;      3;      1;          -5;    7;           dB; Differential reflectivity
+  0;   21;      5;      0;         -65;    6;           dB; Linear depolarization ratio
+  0;   21;      6;      0;         -65;    6;           dB; Circular depolarization ratio
+  0;   21;     11;      0;        -128;    8;          m/s; Doppler mean velocity in X direction
+  0;   21;     12;      0;        -128;    8;          m/s; Doppler mean velocity in Y direction
+  0;   21;     13;      0;        -128;    8;          m/s; Doppler mean velocity in Z direction
+  0;   21;     14;      1;       -4096;   13;          m/s; Doppler mean velocity (radiational)
+  0;   21;     17;      1;       -4096;    8;          m/s; Doppler velocity spectral width
+  0;   21;     21;     -3;           0;    4;            m; Echo tops
+  0;   21;     30;      0;         -32;    8;           dB; Signal to noise ratio
+  0;   21;     31;      0;           0;    7;      kg/m**2; Vertical integrated liquid water content
+  0;   21;     36;      7;           0;   12;          m/s; Radar rainfall intensity
+  0;   21;     41;     -2;           0;    8;            m; Bright band height
+  0;   21;     51;      0;        -256;    8;           dB; Signal power above 1 MW
+  0;   21;     62;      2;       -5000;   13;           dB; Backscatter
+  0;   21;     63;      1;           0;   10;      percent; Radiometric resolution (noise value)
+  0;   21;     64;      0;           0;    8;      numeric; Clutter noise estimate
+  0;   21;     65;      0;        -127;    8;      numeric; Missing packet counter
+  0;   21;     66;      0;           0;   12;   flag_table; Wave scatterometer product confidence
+  0;   21;     67;      0;           0;   13;   flag_table; Wind product confidence data
+  0;   21;     68;      0;           0;    8;   flag_table; Radar altimeter product confidence data
+  0;   21;     69;      0;           0;   10;   flag_table; SST product confidence data
+  0;   21;     71;      0;           0;   16;      numeric; Peakiness
+  0;   21;     72;      0;           0;    4;   flag_table; Satellite altimeter calibration status
+  0;   21;     73;      0;           0;    9;   flag_table; Satellite altimeter instrument mode
+  0;   21;     75;      0;           0;    8;      numeric; Spectral intensity
+  0;   21;     76;      0;           0;    3;   code_table; Representation of intensities
+  0;   21;     77;      3;           0;   14;            m; Altitude correction (ionosphere)
+  0;   21;     78;      3;           0;    9;            m; Altitude correction (dry troposphere)
+  0;   21;     79;      3;        2000;   10;            m; Altitude correction (wet troposphere)
+  0;   21;     80;      3;           0;   11;            m; Altitude correction (calibration constant)
+  0;   21;     81;      3;           0;   10;            m; Open loop correction (height-time loop)
+  0;   21;     82;      3;       -3000;   14;           dB; Open loop correction (auto gain control)
+  0;   21;     85;      0;           0;    4;      numeric; ATSR sea surface temperature across-track band number
+  0;   21;    192;      0;           0;   14;            m; Heave sensor spectral peak length
+  0;   21;    193;      1;           0;   14;            s; Heave sensor spectral peak period
+  0;   21;    194;      2;           0;   14;      percent; AVHRR channel average
+  0;   21;    195;      2;           0;   14;      percent; Space view channel standard deviation
+  0;   21;    196;      2;           0;   15;        deg_K; Algorithm identifier
+  0;   21;    197;      2;           0;   15;        deg_K; AVHRR channel average
+  0;   21;    198;      2;       -5000;   13;           dB; Backscatter
+  0;   21;    199;      1;           0;   10;      percent; Noise figure percentage
+  0;   21;    200;      3;           0;   12;            m; aerosol_optical_depth
+  0;   22;      1;      0;           0;    9;     deg_true; Direction of waves (dddd, da1da1, or d1d1>dndn)
+  0;   22;      2;      0;           0;    9;     deg_true; Direction of wind waves
+  0;   22;      3;      0;           0;    9;     deg_true; Direction of swell waves (dw1dw1 or dw2dw2)
+  0;   22;      4;      0;           0;    9;     deg_true; Direction of current (dodo>dndn or DcDc))
+  0;   22;     11;      0;           0;    6;            s; Period of waves (D'D'D'D', PaPaPaPa, or PwPw)
+  0;   22;     12;      0;           0;    6;            s; Period of wind waves
+  0;   22;     13;      0;           0;    6;            s; Period of swell waves (Pw1Pw1 or Pw2Pw2)
+  0;   22;     21;      1;           0;   10;            m; Height of waves (D'D'D'D' or HsHsHsHs)
+  0;   22;     22;      1;           0;   10;            m; Height of wind waves (HwHw)
+  0;   22;     23;      1;           0;   10;            m; Height of swell waves (Hw1Hw1 or Hw2Hw2)
+  0;   22;     25;      2;           0;   10;            m; Standard deviation wave
+  0;   22;     26;      2;           0;   10;            m; Standard deviation of significant wave height
+  0;   22;     31;      2;           0;   13;          m/s; Speed of current (cococo>cncncn or VcVc)
+  0;   22;     37;      3;      -10000;   15;            m; Tidal elevation with respect to national land datum
+  0;   22;     38;      3;      -10000;   15;            m; Tidal elevation with respect to local chart datum
+  0;   22;     39;      3;       -5000;   12;            m; Meteorological residual tidal elevation (surge or offset
+  0;   22;     40;      3;       -5000;   14;            m; Meteorological residual tidal elevation (surge or offset)
+  0;   22;     41;      1;           0;   12;        deg_K; Sea surface temperature (15 day running mean)
+  0;   22;     42;      1;           0;   12;        deg_K; Sea temperature (T1T1T1>TnTnTn)
+  0;   22;     43;      2;           0;   15;        deg_K; Sea temperature (ToToToTo>TnTnTnTn)
+  0;   22;     44;      1;           0;   14;          m/s; Sound velocity
+  0;   22;     50;      2;           0;    8;        deg_K; Standard deviation sea surface temperature
+  0;   22;     61;      0;           0;    4;   Code_Table; State of sea
+  0;   22;     62;      2;           0;   14;          ppt; Salinity (SoSoSoSo>SnSnSnSn)
+  0;   22;     63;      0;           0;   14;            m; Total water depth (hhh or ZdZdZdZd)
+  0;   22;     67;      0;           0;   10;   code_table; Instrument type for water temperature profile measurement
+  0;   22;     68;      0;           0;    7;   code_table; Water temperature profile recorder types
+  0;   22;     70;      2;           0;   13;            m; Significant wave height (D'..D', Hm..Hm, Hs..Hs, or Hse..Hse)
+  0;   22;     71;      1;           0;    9;            s; Spectral peak wave period (Psp..Psp or Pw..Pw)
+  0;   22;     72;      0;           0;   13;            m; Spectral peak wave length (Pa..Pa, Pp..Pp, Psa..Psa, or Psp..Psp)
+  0;   22;     73;      2;           0;   13;            m; Maximum wave height (D'..D', Hm..Hm, Hs..Hs, or Hse..Hse)
+  0;   22;     74;      1;           0;    9;            s; Average wave period (D'..D', Pa..Pa, Pp..Pp, Pp..Pp, Psa..Psa, Psp..Psp, or Pw..Pw)
+  0;   22;     75;      0;           0;   13;            m; Average wave length (Pa..Pa, Pp..Pp, Psa..Psa, Psp..Psp, or Pw..Pw)
+  0;   22;     76;      0;           0;    9;     deg_true; Direction from which dominant waves are comming (dddd)
+  0;   22;     77;      0;           0;    9;          deg; Directional spread of dominant wave (dsds)
+  0;   22;     78;      0;           0;   12;            s; Duration of wave record (D'D'D'D')
+  0;   22;     79;      0;           0;   16;            m; Length of wave record (D'D'D'D')
+  0;   22;     80;      3;           0;   10;           Hz; Waveband central frequency (f1f1f1 ... fnfnfn)
+  0;   22;     81;      5;           0;   13;          1/m; Waveband central wave number (f1f1f1 ... fnfnfn)
+  0;   22;     82;      2;           0;   20;        m**2s; Sensor spectral density frequency (Cm..Cm or Csm..Csm)
+  0;   22;     83;      2;           0;   20;         m**3; Sensor spectral density number (Cm..Cm or Csm..Csm)
+  0;   22;     84;      0;           0;    7;      numeric; Sensor band number (nmnm or nsmmsm)
+  0;   22;     85;      0;           0;    7;      percent; Sensor ratio (c1c1..cnc or csncsnn)
+  0;   22;     86;      0;           0;    9;     deg_true; Mean direction from which waves are coming (dddd)
+  0;   22;     87;      0;           0;    9;     deg_true; Principal direction from which waves are coming (dddd)
+  0;   22;     88;      2;           0;    7;      numeric; First normalized polar coefficient (r1r1 or r2r2)
+  0;   22;     89;      2;           0;    7;      numeric; Second normalized polar coefficient (r1r1 or r2r2)
+  0;   22;     90;      2;           0;   20;        m**2s; Non-directional spectral estimate by wave frequency
+  0;   22;     91;      2;           0;   20;         m**3; Non-directional spectral estimate by wave number
+  0;   22;     92;      2;           0;   20;    m**2s/rad; Directional spectral estimate by wave frequency
+  0;   22;     93;      2;           0;   20;         m**4; Directional spectral estimate by wave number
+  0;   22;     94;      0;           0;    7;      numeric; Total number of wave bands described (BTBT)
+  0;   22;     95;      0;           0;    8;          deg; Directional spread of individual waves
+  0;   22;     96;      3;           0;    4;          1/s; Spectral band width
+  0;   22;    120;      0;           0;    5;   code_table; Tide station automated water level check
+  0;   22;    121;      0;           0;    5;   code_table; Tide station manual water level check
+  0;   22;    122;      0;           0;    5;   code_table; Tide station automated meteorological data check
+  0;   22;    123;      0;           0;    5;   code_table; Tide station manual meteorological data check
+  0;   22;    192;      6;   -10000000;   25;           cm; corrected sea sfc ht
+  0;   22;    194;      0;           0;    4;   code_table; Wave spectra exponent (x)
+  0;   22;    196;      0;           0;    7;      numeric; Number of wave bands affected by the center frequency (or center wave number) (BB)
+  0;   22;    200;      0;           0;   14;            m; Distance sample interval
+  0;   22;    203;      3;           0;   10;           Hz; Frequency increment (fdfdfd)
+  0;   22;    204;      5;           0;   13;          1/m; Wave number increment (fdfdfd)
+  0;   22;    205;      3;           0;   20; m**2/(Hz*rad); Wave spectra
+  0;   22;    206;      4;           0;   10;      Numeric; Drag coefficient
+  0;   22;    207;      2;           0;   16;            m; Maximum wave height
+  0;   22;    208;      2;           0;   16;            m; Significant wave height
+  0;   22;    209;      0;           0;    7;   Code_Table; directional spread
+  0;   22;    211;      0;           0;    8;   Code_Table; Bogus water mass classification
+  0;   22;    212;      0;           0;    8;   Code_Table; Discriminant water mass classification
+  0;   22;    213;      1;           0;   10;      percent; Classification probability
+  0;   22;    218;      0;           0;    7;      Numeric; Slope sensor band number
+  0;   22;    219;      0;           0;    7;      percent; Slope sensor ratio
+  0;   22;    220;      0;           0;    8;   Code_Table; Front number
+  0;   22;    224;     -2;           0;   14;            m; Distance to front
+  0;   22;    232;      0;           0;    4;   Code_Table; Sea surface temperature method indicator
+  0;   22;    233;      0;           0;    3;   Code_Table; Sea temperature averaging period
+  0;   22;    236;      0;           0;    8;   Code_Table; Swell wave direction
+  0;   22;    237;     -2;           0;   14;            m; Significant wave height
+  0;   22;    238;     -2;           0;   14;            m; Maximum wave height
+  0;   22;    239;      0;           0;    6;      Numeric; Wave spectra direction count
+  0;   22;    240;      0;           0;    6;      Numeric; Wave spectra frequency count
+  0;   22;    241;      3;      -32768;   16;      Nt/m**2; Wave stress u-component
+  0;   22;    242;      3;      -32768;   16;      Nt/m**2; Wave stress v-component
+  0;   22;    243;      0;           0;    7;      percent; Whitecap probability
+  0;   22;    245;      2;           0;   16;        deg_K; Surface temperature
+  0;   22;    246;      3;      -32768;   16;      Nt/m**2; Wind stress u-component
+  0;   22;    247;      3;      -32768;   16;      Nt/m**2; Wind stress v-component
+  0;   22;    248;      0;           0;   16;     deg_true; Wind wave direction
+  0;   22;    249;      2;           0;   16;            m; Height of wind wave
+  0;   22;    250;      1;           0;   16;            s; Period of wind waves
+  0;   22;    251;      0;           0;    6;      Numeric; Wave spectra direction
+  0;   22;    252;      0;           0;    6;      Numeric; Wave spectra frequency
+  0;   22;    253;      0;           0;   16;     deg_true; Direction of swell waves
+  0;   22;    254;      2;           0;   16;            m; Height of swell waves
+  0;   22;    255;      1;           0;   16;            s; Period of swell waves
+  0;   23;      1;      0;           0;    3;   Code_Table; Accident early notification - article applicable
+  0;   23;      2;      0;           0;    5;   Code_Table; Activity or facility involved in incident
+  0;   23;      3;      0;           0;    3;   Code_Table; Type of release
+  0;   23;      4;      0;           0;    3;   Code_Table; Countermeasures taken near border
+  0;   23;      5;      0;           0;    2;   Code_Table; Cause of incident
+  0;   23;      6;      0;           0;    3;   Code_Table; Incident situation
+  0;   23;      7;      0;           0;    3;   Code_Table; Characteristic of release
+  0;   23;      8;      0;           0;    2;   Code_Table; State of current release
+  0;   23;      9;      0;           0;    2;   Code_Table; State of expected release
+  0;   23;     16;      0;           0;    2;   Code_Table; Possibility of significant chemical toxic health effect
+  0;   23;     17;      6;           0;   20;       m**3/s; Flow discharge of major recipient
+  0;   23;     18;      0;           0;    3;   Code_Table; release behavior over time
+  0;   23;     19;      0;      -15000;   17;            m; Actual release height
+  0;   23;     21;      0;      -15000;   17;            m; Effective release height
+  0;   23;     22;      0;           0;   24;            m; Distance of relative point or site of incident
+  0;   23;     23;      1;           0;   12;          m/s; Main transport speed in atmosphere
+  0;   23;     24;      2;           0;   13;          m/s; Main transport speed in water
+  0;   23;     25;      2;           0;   13;          m/s; Main transport speed in ground water
+  0;   23;     27;      0;           0;    9;     deg_true; Main transport direction in atmosphere
+  0;   23;     28;      0;           0;    9;     deg_true; Main transport direction in water
+  0;   23;     29;      0;           0;    9;     deg_true; Main transport direction in ground water
+  0;   23;     31;      0;           0;    2;   Code_Table; Possibility that plume will encounter precip
+  0;   23;     32;      0;           0;    2;   Code_Table; Plume will encounter change in wind direction and/or speed flag
+  0;   24;      1;    -11;           0;   28;           Bq; Estimate of radioactivity released up to specified time
+  0;   24;      2;    -11;           0;   28;           Bq; Estimated maximum potential release
+  0;   24;      3;      0;           0;    5;   Code_Table; Composition of release
+  0;   24;      4;      0;           0;   16;    CCITT_IA5; Element name
+  0;   24;      5;      0;           0;    9;      Numeric; Isotope mass
+  0;   24;     11;      2;           0;   32;          mSv; Dose
+  0;   24;     12;      2;           0;   32;          mSv; Trajectory dose (defined location and expected time of arrival)
+  0;   24;     13;      2;           0;   32;          mSv; Gamma dose in air along the main transport path
+  0;   24;     21;      2;           0;   32;      Bq/m**3; Air concentration (named isotope type including gross beta)
+  0;   24;     22;      2;           0;   32;         Bq/l; Concentration in precipitation (of named isotope type)
+  0;   25;      1;     -1;           0;    6;            m; Range gate length
+  0;   25;      2;      0;           0;    4;      Numeric; Number of gates averaged
+  0;   25;      3;      0;           0;    8;      Numeric; Number of integrated pulses
+  0;   25;      4;      0;           0;    2;   Code_Table; Echo processing
+  0;   25;      5;      0;           0;    2;   Code_Table; Echo integration
+  0;   25;      6;      0;           0;    3;   Code_Table; Z to R conversion
+  0;   25;      7;      0;           0;   12;      Numeric; Z to R conversion factor
+  0;   25;      8;      2;           0;    9;      Numeric; Z to R conversion exponent
+  0;   25;      9;      0;           0;    4;   Flag_Table; Calibration method
+  0;   25;     10;      0;           0;    4;   Code_Table; Clutter treatment
+  0;   25;     11;      0;           0;    2;   Code_Table; Ground occultation correction (screening)
+  0;   25;     12;      0;           0;    2;   Code_Table; Range attenuation correction
+  0;   25;     13;      0;           0;    2;   Flag_Table; Bright band correction
+  0;   25;     15;      0;           0;    2;   Flag_Table; Radome attenuation correction
+  0;   25;     16;      5;           0;    6;         dB/m; Clear air attenuation correction
+  0;   25;     17;      0;           0;    2;   Flag_Table; Precipitation attenuation correction
+  0;   25;     18;      7;           0;    6;      Numeric; A to Z law for attenuation factor
+  0;   25;     19;      2;           0;    7;      Numeric; A to Z law for attenuation exponent
+  0;   25;     20;      0;           0;    2;   Code_Table; Mean speed estimation
+  0;   25;     21;      0;           0;    8;   Flag_Table; Wind computation enhancement
+  0;   25;     30;      0;           0;    2;   Code_Table; SST usage
+  0;   25;     32;      0;           0;    2;   Code_Table; NOAA wind profiler high/low mode data
+  0;   25;     33;      0;           0;    2;   Code_Table; NOAA wind profiler submode
+  0;   25;     34;      0;           0;    4;   Code_Table; NOAA wind profiler Q/C test results
+  0;   25;     40;      0;           0;    4;   code_table; CO2 wind product derivation
+  0;   25;     41;      0;           0;    3;   Code_Table; Method of determining direction of moving platform
+  0;   25;     42;      0;           0;    3;   Code_Table; Method of determining speed of moving platform
+  0;   25;     43;      4;           0;   15;            s; Time sample interval (SSSS)
+  0;   25;     44;      2;           0;   14;            m; Distance sample interval (SSSS)
+  0;   25;     45;      0;           0;   21;   flag_table; HIRS channel combination
+  0;   25;     46;      0;           0;    5;   flag_table; MSU channel combination
+  0;   25;     47;      0;           0;    4;   flag_table; SSU channel combination
+  0;   25;     48;      0;           0;   16;   flag_table; AMSU-A channel combination
+  0;   25;     49;      0;           0;    6;   flag_table; AMSU-B channel combination
+  0;   25;     51;      0;           0;    7;   flag_table; AVHRR channel combination
+  0;   25;     53;      0;           0;   12;   flag_table; Observation quality
+  0;   25;     60;      0;           0;   14;      numeric; Software identification
+  0;   25;    192;      0;           0;    8;   Code_Table; Type of correction
+  0;   25;    193;      0;           0;    3;   Code_Table; Land/sea flag
+  0;   25;    194;      0;           0;    2;   Code_Table; Day/night flag
+  0;   25;    195;      0;           0;    6;      Numeric; Surface model pressure
+  0;   25;    196;      0;           0;   16;      Numeric; Scan line count
+  0;   25;    197;      0;           0;    5;      Numeric; Box counter
+  0;   25;    198;      0;           0;    3;      Numeric; Minibox counter
+  0;   25;    199;      0;           0;    3;   Code_Table; Water vapor flag
+  0;   25;    200;      0;           0;    3;   Code_Table; TOVS retrieval low 20
+  0;   25;    201;      0;           0;    3;   Code_Table; TOVS retrieval temps high 20
+  0;   25;    202;      0;           0;    2;   Code_Table; TOVS super adiabatic flag
+  0;   25;    203;      0;           0;    2;   Code_Table; TOVS skin temperature flag
+  0;   25;    204;      0;           0;    2;   Code_Table; Stratospheric sounding unit flag
+  0;   25;    205;      0;           0;    4;   Code_Table; Latitude zones
+  0;   25;    206;      0;           0;    4;   Code_Table; TOVS instrument combinations
+  0;   25;    207;      0;           0;    6;      numeric; HIRS scan position number
+  0;   25;    208;      0;           0;    8;   Code_Table; TARM flag
+  0;   25;    209;      0;           0;    4;   Code_Table; DMSP flag
+  0;   25;    211;      0;           0;   17;      Numeric; B-scan start time
+  0;   25;    212;      0;           0;    7;      Numeric; Counter (1-64)
+  0;   25;    213;      0;           0;    5;   Code_Table; Calculated surface type
+  0;   25;    214;      0;           0;    3;   Code_Table; Season flag
+  0;   25;    215;      0;        -127;    8;      Numeric; Missing packet counter
+  0;   25;    216;      0;           0;    3;   Code_Table; Observation Quality Code
+  0;   26;      1;      1;           0;   12;           hr; Principle time of daily reading in UTC of maximum temperature
+  0;   26;      2;      1;           0;   12;           hr; Principle time of daily reading in UTC of minimum temperature
+  0;   26;      3;      0;       -1440;   12;          min; Time difference
+  0;   27;      1;      5;    -9000000;   25;          deg; Latitude (high accuracy)
+  0;   27;      2;      2;       -9000;   15;          deg; Latitude (coarse accuracy)
+  0;   27;      3;      2;       -9000;   15;          deg; Alternate latitude
+  0;   27;     20;      0;           0;   16;      Numeric; Satellite location counter
+  0;   27;     21;      0;           0;   16;      Numeric; Satellite sub-location dimensions
+  0;   27;     31;      2; -1073741824;   31;            m; In direction of 0 degrees longitude, distance from the Earth's center
+  0;   28;      1;      5;   -18000000;   26;          deg; Longtiude (high accuracy)
+  0;   28;      2;      2;      -18000;   16;          deg; Longtiude (coarse accuracy)
+  0;   28;      3;      2;      -18000;   16;          deg; Alternate longtiude
+  0;   28;     31;      2; -1073741824;   31;            m; In direction 90 degrees East, distance from the Earth's center
+  0;   29;      1;      0;           0;    3;   Code_Table; Projection type
+  0;   29;      2;      0;           0;    3;   Code_Table; Coordinate grid type (Wr)
+  0;   30;      1;      0;           0;    4;      Numeric; Pixel value (4 bits)
+  0;   30;      2;      0;           0;    8;      numeric; Pixel value (8 bits)
+  0;   30;      4;      0;           0;   16;      numeric; Pixel value (16 bits)
+  0;   30;     21;      0;           0;   12;      Numeric; Number of pixels per row
+  0;   30;     22;      0;           0;   12;      Numeric; Number of pixels per column
+  0;   30;     31;      0;           0;    4;   Code_Table; Picture type
+  0;   30;     32;      0;           0;   16;   Flag_Table; Combined picture
+  0;   31;      0;      0;           0;    1;   Flag_Table; Delayed descriptor replication switch (1 bit)
+  0;   31;      1;      0;           0;    8;      Numeric; Delayed descriptor replication factor (255 or less)
+  0;   31;      2;      0;           0;   16;      Numeric; Extended delayed descriptor replication factor (65536 or less)
+  0;   31;     11;      0;           0;    8;      Numeric; Delayed descriptor and data replication factor
+  0;   31;     12;      0;           0;   16;      Numeric; Extended delayed descriptor and data replication factor
+  0;   31;     21;      0;           0;    6;   Code_Table; Associated field significance
+  0;   31;     31;      0;           0;    1;   flag_table; Data present indicator
+  0;   31;    192;      0;           0;    8;   Code_Table; Associated QC indicator
+  0;   31;    193;      0;           0;    8;   Code_Table; QC description identifier, indicates why a value is bad
+  0;   31;    194;      2;           0;    7;      Numeric; Associated correlation
+  0;   31;    195;      2;           0;    7;      Numeric; Associated probability of error
+  0;   31;    196;      0;           0;   13;   Flag_Table; UWI product confidence flag
+  0;   31;    197;      0;           0;   12;      Numeric; Solution probability
+  0;   31;    201;      0;           0;   10;      Numeric; Delayed replication factor (1023 or less)
+  0;   31;    211;      0;           0;    3;      Numeric; Delayed replication factor (15 or less)
+  0;   31;    221;      0;           0;    5;      Numeric; Delayed replication count (31 or less)
+  0;   31;    231;      0;           0;    6;      Numeric; Delayed replication factor (63 or less)
+  0;   31;    241;      0;           0;    4;      Numeric; Delayed replication factor (15 or less)
+  0;   33;      2;      0;           0;    2;   code_table; Quality information
+  0;   33;      3;      0;           0;    3;   code_table; Quality information
+  0;   33;      7;      0;           0;    7;      percent; Per cent confidence
+  0;   33;     20;      0;           0;    3;   code_table; Quality control indication of following value
+  0;   33;     21;      0;           0;    2;   code_table; Quality of following value
+  0;   33;     22;      0;           0;    2;   code_table; Quality of buoy satellite transmission
+  0;   33;     23;      0;           0;    2;   code_table; Quality of buoy location
+  0;   33;     24;      0;           0;    4;   code_table; Station elevation quality mark (for mobile stations)
+  0;   33;     25;      0;           0;    3;   code_table; ACARS interpolated values table
+  0;   33;     26;      0;           0;    6;   code_table; Mixing ratio quality
+  0;   33;     35;      0;           0;    4;   code_table; manual/automatic quality control
+  0;   33;     36;      0;           0;    7;      percent; nominal confidence threshold wind dir
+  0;   48;      1;      0;           0;  128;    CCITT_IA5; Classification
+  0;   48;      2;      0;           0;  128;    CCITT_IA5; Classification modifier
+  0;   48;      3;      0;           0;  552;    CCITT_IA5; Release as
+  0;   48;      4;      0;           0;   12;           yr; Declassification - year
+  0;   48;      5;      0;           0;    4;           mo; Declassification - month
+  0;   48;      6;      0;           0;    6;          day; Declassification - day
+  0;   48;      7;      0;           0;  552;    CCITT_IA5; Release not
+  0;   48;      8;      0;           0;   64;    CCITT_IA5; Sender of original observation data
+  0;   48;      9;      0;           0;   80;    CCITT_IA5; Declassification instructions
+  0;   48;     10;      0;           0;   12;           yr; Send - year
+  0;   48;     11;      0;           0;    4;           mo; Send - month
+  0;   48;     12;      0;           0;    6;          day; Send - day
+  0;   48;     13;      0;           0;    4;           hr; Send - hour
+  0;   48;     14;      0;           0;    6;          min; Send - minutes
+  0;   48;     15;      0;           0;  552;    CCITT_IA5; Release to information
+  0;   48;     16;      0;           0;    5;           hr; Send - hour
+  0;   48;     17;      0;           0; 1104;    CCITT_IA5; Release to
+  0;   48;     18;      0;           0;  552;    CCITT_IA5; Release not
+  0;   48;     19;      0;           0;  552;    CCITT_IA5; Declassification instructions
+  0;   48;     20;      0;           0;  552;    CCITT_IA5; Classification modifier
+  0;   48;     21;      0;           0;  552;    CCITT_IA5; Sender of observational data
+  0;   48;     22;      0;           0;  160;    CCITT_IA5; Classification
+  0;   48;     27;      0;           0;   12;           yr; Receipt - year
+  0;   48;     28;      0;           0;    4;           mo; Receipt - month
+  0;   48;     29;      0;           0;    6;          day; Receipt - day
+  0;   48;     30;      0;           0;    5;           hr; Receipt - hour
+  0;   48;     31;      0;           0;    6;          min; Receipt - minutes
+  0;   48;     32;      0;           0;   48;    CCITT_IA5; Bulletin header update or correction indicator
+  0;   48;     33;      0;           0;   24;    CCITT_IA5; Receiving circuit
+  0;   48;     34;      0;           0;    6;      Numeric; Near-duplicate combination count
+  0;   50;      1;      0;           0;    2;   Code_Table; Quality of measurement of pressure, sst, air temperature, and housekeeping parameters (Qp, Q2, QTW, Q4)
+  0;   50;      2;      0;           0;    2;   Code_Table; Quality of buoy satellite transmission (QN)
+  0;   50;      3;      0;           0;    4;   Code_Table; IGOSS quality codes (Qd, Qd1, Qd2, Q1, Qt)
+  0;   50;      6;      0;           0;    3;   Code_Table; Location quality codes (QL)
+  0;   50;     10;      2;           0;   15;        deg_K; GDEM temperature
+  0;   50;     14;      2;           0;   15;        deg_K; Feature model temperature
+  0;   50;     18;      0;           0;   16;      Numeric; Reliability
+  0;   50;     33;      0;           0;    8;      Numeric; Count of boundary points
+  0;   50;     34;      3;           0;   16;      Numeric; Frequency ratio
+  0;   50;     35;      0;           0;   12;            s; Time step of data (time increment)
+  0;   50;     42;      2;           0;   12;      Numeric; Mean wave direction
+  0;   50;     43;      3;           0;   12;      Numeric; Mean wave frequency
+  0;   50;     44;      4;           0;   12;      Numeric; First frequency
+  0;   50;    100;      0;           0;   12;           yr; Analysis DTG - year
+  0;   50;    101;      0;           0;    4;           mo; Analysis DTG - month
+  0;   50;    102;      0;           0;    6;          day; Analysis DTG - day
+  0;   50;    103;      0;           0;    5;           hr; Analysis DTG - hour
+  0;   50;    104;      0;           0;    6;      Numeric; Last observed sea depth
+  0;   51;      3;      0;           0;    5;   Flag_Table; Processing status
+  0;   51;      6;      0;           0;    6;      Numeric; Combination count
+  0;   51;      7;      0;           0;    2;   Code_Table; Quality control process status
diff --git a/data/tables/B3L-098-001-B b/data/tables/B3L-098-001-B
new file mode 100644
index 0000000..b96a0d6
--- /dev/null
+++ b/data/tables/B3L-098-001-B
@@ -0,0 +1,81 @@
+  0;    0;      1;      0;           0;   24;     CCITTIA5; TABLE A: ENTRY
+  0;    0;      2;      0;           0;  256;     CCITTIA5; TABLE A: DATA CATEGORY DESCRIPTION, LINE 1
+  0;    0;      3;      0;           0;  256;     CCITTIA5; TABLE A: DATA CATEGORY DESCRIPTION, LINE 2
+  0;    0;      5;      0;           0;   24;     CCITTIA5; BUFR EDITION NUMBER
+  0;    0;     10;      0;           0;    8;     CCITTIA5; F DESCRIPTOR TO BE ADDED OR DEFINED
+  0;    0;     11;      0;           0;   16;     CCITTIA5; X DESCRIPTOR TO BE ADDED OR DEFINED
+  0;    0;     12;      0;           0;   24;     CCITTIA5; Y DESCRIPTOR TO BE ADDED OR DEFINED
+  0;    0;     13;      0;           0;  256;     CCITTIA5; ELEMENT NAME, LINE 1
+  0;    0;     14;      0;           0;  256;     CCITTIA5; ELEMENT NAME, LINE 2
+  0;    0;     15;      0;           0;  192;     CCITTIA5; UNITS NAME
+  0;    0;     16;      0;           0;    8;     CCITTIA5; UNITS SCALE SIGN
+  0;    0;     17;      0;           0;   24;     CCITTIA5; UNITS SCALE
+  0;    0;     18;      0;           0;    8;     CCITTIA5; UNITS REFERENCE SIGN
+  0;    0;     19;      0;           0;   80;     CCITTIA5; UNITS REFERENCE VALUE
+  0;    0;     20;      0;           0;   24;     CCITTIA5; ELEMENT DATA WIDTH
+  0;    0;     30;      0;           0;   48;     CCITTIA5; DESCRIPTOR DEFINING SEQUENCE
+  0;    1;      1;      0;           0;    7;      NUMERIC; WMO BLOCK NUMBER
+  0;    1;      2;      0;           0;   10;      NUMERIC; WMO STATION NUMBER
+  0;    1;      3;      0;           0;    3;      NUMERIC; WMO REGION NUMBER/GEOGRAPHICAL AREA
+  0;    1;      4;      0;           0;    3;      NUMERIC; WMO REGION SUB-AREA
+  0;    1;      5;      0;           0;   17;      NUMERIC; BUOY/PLATFORM IDENTIFIER
+  0;    1;      6;      0;           0;   64;     CCITTIA5; AIRCRAFT FLIGHT NUMBER
+  0;    1;      7;      0;           0;   10;         CODE; TABLE   	SATELLITE IDENTIFIER
+  0;    1;      8;      0;           0;   64;     CCITTIA5; AIRCRAFT REGISTRATION NUMBER
+  0;    1;      9;      0;           0;   64;     CCITTIA5; TYPE OF COMMERCIAL AIRCRAFT
+  0;    1;     10;      0;           0;   64;     CCITTIA5; STATIONARY BUOY PLATFORM IDENTIFIER(C-MAN BUOYS)
+  0;    1;     11;      0;           0;   72;     CCITTIA5; SHIP'S CALL SIGN
+  0;    1;     12;      0;           0;    9;       DEGREE; TRUE  	DIRECTION OF MOTION OF MOVING OBSERVING PLATFORM
+  0;    1;     13;      0;           0;   10;          M/S; SPEED OF MOTION OF MOVING OBSERVING PLATFORM
+  0;    1;     14;      2;           0;   10;          M/S; PLATFORM DRIFT SPEED(HIGH PRECISION
+  0;    1;     21;      0;           0;   14;      NUMERIC; SYNOPTIC FEATURE IDENTIFIER
+  0;    1;     25;      0;           0;   24;     CCITTIA5; STORM IDENTIFIER
+  0;    1;     26;      0;           0;   64;     CCITTIA5; WMO STORM NAME
+  0;    1;     31;      0;           0;   16;         CODE; TABLE   	GENERATING CENTRE
+  0;    1;     32;      0;           0;    8;         CODE; TABLE   	GENERATING APPLICATION
+  0;    1;     63;      0;           0;   64;     CCITTIA5; ICAO LOCATION INDICATOR
+  0;    1;    192;      0;           0;    8;         CODE; TABLE   	MODEL VERSION NUMBER
+  0;    1;    193;      0;           0;    4;         CODE; TABLE   	SIGMA_0 SIMULATION METHOD
+  0;    1;    194;      0;           0;   72;     CCITTIA5; CARRIER BALLOON/AIRCRAFT IDENTIFIER
+  0;    1;    195;      0;           0;   72;     CCITTIA5; MOBIL LAND STATION IDENTIFIER
+  0;    1;    196;      0;           0;   72;     CCITTIA5; CONSTANT LEVEL BALLOON IDENTIFIER
+  0;    1;    197;      0;           0;   10;         CODE; TABLE   	RTP - PLATFORM TYPE
+  0;    1;    198;      0;           0;   10;         CODE; TABLE   	ITP - DECK ID
+  0;    1;    199;      0;           0;    4;         CODE; TABLE   	DUP - DUPLICATE STATUS
+  0;    1;    201;      0;           0;    8;         CODE; TABLE   	GENERATING APPLICATION
+  0;    1;    205;      0;           0;   10;         CODE; TABLE   	SATELLITE IDENTIFIER
+  0;    1;    208;      5; -1073741824;   31;          M/S; VELOCITY OF PLATFORM, X
+  0;    1;    209;      5; -1073741824;   31;          M/S; VELOCITY OF PLATFORM, Y
+  0;    1;    210;      5; -1073741824;   31;          M/S; VELOCITY OF PLATFORM, Z
+  0;    2;      1;      0;           0;    2;         CODE; TABLE   	TYPE OF STATION
+  0;    2;      2;      0;           0;    4;         FLAG; TABLE   	TYPE OF INSTRUMENTATION FOR WIND MEASUREMENT
+  0;    2;      3;      0;           0;    4;         CODE; TABLE   	TYPE OF MEASURING EQUIPMENT USED
+  0;    2;      4;      0;           0;    4;         CODE; TABLE   	TYPE OF INSTRUMENTATION FOR EVAPORATION MEASUEMENT
+  0;    2;      5;      2;           0;    7;            K; PRECISION OF TEMPERATURE OBSERVATION
+  0;    2;     11;      0;           0;    8;         CODE; TABLE   	RADIOSONDE TYPE
+  0;    2;     12;      0;           0;    4;         CODE; TABLE   	RADIOSONDE COMPUTATIONAL METHOD
+  0;    2;     13;      0;           0;    4;         CODE; TABLE   	SOLAR AND INFRARED RADIATION CORRECTION
+  0;    2;     14;      0;           0;    7;         CODE; TABLE   	TRACKING TECHNIQUE/STATUS OF SYSTEM USED
+  0;    2;     15;      0;           0;    4;         CODE; TABLE   	RADIOSONDE COMPLETENESS
+  0;    2;     21;      0;           0;    9;         FLAG; TABLE   	SATELLITE INSTRUMENT DATA USED IN PROCESSING
+  0;    2;     22;      0;           0;    8;         FLAG; TABLE   	SATELLITE DATA PROCESSING TECHNIQUE USED
+  0;    2;     23;      0;           0;    4;         CODE; TABLE   	SATELLITE DERIVED WIND COMPUTATION METHOD
+  0;    2;     24;      0;           0;    4;         CODE; TABLE   	INTEGRATED MEAN HUMIDITY COMPUTATIONAL METHOD
+  0;    2;     25;      0;           0;   25;         FLAG; TABLE   	SATELLITE CHANNEL(S) USED IN COMPUTATION
+  0;    2;     26;      2;           0;   12;            M; CROSS TRACK RESOLUTION
+  0;    2;     27;      2;           0;   12;            M; ALONG TRACK RESOLUTION
+  0;    2;     30;      0;           0;    3;         CODE; TABLE   	METHOD OF CURRENT MEASUREMENT
+  0;    2;     31;      0;           0;    5;         CODE; TABLE   	DURATION AND TIME OF CURRENT MEASUREMENT
+  0;    2;     32;      0;           0;    2;         CODE; TABLE   	INDICATOR FOR DIGITIZATION
+  0;    2;     33;      0;           0;    3;         CODE; TABLE   	METHOD OF SALINITY/DEPTH MEASUREMENT
+  0;    2;     34;      0;           0;    5;         CODE; TABLE   	DROGUE TYPE
+  0;    2;     35;      0;           0;    9;            M; CABLE LENGTH
+  0;    2;     36;      0;           0;    2;         CODE; TABLE   	BUOY TYPE
+  0;    2;     37;      0;           0;    3;         CODE; TABLE   	METHOD OF TIDAL OBSERVATION
+  0;    2;     38;      0;           0;    4;         CODE; TABLE   	METHOD OF SEA-SURFACE TEMPERATURE MEASUREMENT
+  0;    2;     39;      0;           0;    3;         CODE; TABLE   	METHOD OF WET-BULB TEMPERATURE MEASUREMENT
+  0;    2;     40;      0;           0;    4;         CODE; TABLE   	METHOD OF REMOVING VELOCITY AND MOTION OF PLATFORM FROM CURRENT
+  0;    2;     41;      0;           0;    6;         CODE; TABLE   	METHOD FOR ESTIMATING REPORTS RELATED TO SYNOPTIC FEATURES
+  0;    2;     51;      0;           0;    4;         CODE; TABLE   	INDICATOR TO SPECIFY OBSERVING METHOD FOR EXTREME TEMPERATURES
+  0;    2;     61;      0;           0;    3;         CODE; TABLE   	AIRCRAFT NAVIGATIONAL SYSTEM
+  0;    2;     62;      0;           0;    4;         CODE; TABLE   	TYPE OF AIRCRAFT DATA RELAY SYST
diff --git a/data/tables/B3L-098-001-D b/data/tables/B3L-098-001-D
new file mode 100644
index 0000000..96700b4
--- /dev/null
+++ b/data/tables/B3L-098-001-D
@@ -0,0 +1,1274 @@
+3     0    2
+      0   0    2
+      0   0    3
+     -1
+3     0    3
+      0   0   10
+      0   0   11
+      0   0   12
+     -1
+3     0    4
+      3   0    3
+      0   0   13
+      0   0   14
+      0   0   15
+      0   0   16
+      0   0   17
+      0   0   18
+      0   0   19
+      0   0   20
+     -1
+3     0   10
+      3   0    3
+      1   1    0
+      0  31    1
+      0   0   30
+     -1
+3     1    1
+      0   1    1
+      0   1    2
+     -1
+3     1    2
+      0   1    3
+      0   1    4
+      0   1    5
+     -1
+3     1    3
+      0   1   11
+      0   1   12
+      0   1   13
+     -1
+3     1   11
+      0   4    1
+      0   4    2
+      0   4    3
+     -1
+3     1   12
+      0   4    4
+      0   4    5
+     -1
+3     1   13
+      0   4    4
+      0   4    5
+      0   4    6
+     -1
+3     1   21
+      0   5    1
+      0   6    1
+     -1
+3     1   22
+      0   5    1
+      0   6    1
+      0   7    1
+     -1
+3     1   23
+      0   5    2
+      0   6    2
+     -1
+3     1   24
+      0   5    2
+      0   6    2
+      0   7    1
+     -1
+3     1   25
+      3   1   23
+      0   4    3
+      3   1   12
+     -1
+3     1   26
+      3   1   21
+      0   4    3
+      0   4    3
+      0   4    4
+      0   4    4
+      0   4    5
+      0   4    5
+     -1
+3     1   31
+      3   1    1
+      0   2    1
+      3   1   11
+      3   1   12
+      3   1   22
+     -1
+3     1   32
+      3   1    1
+      0   2    1
+      3   1   11
+      3   1   12
+      3   1   24
+     -1
+3     1   33
+      0   1    5
+      0   2    1
+      3   1   11
+      3   1   12
+      3   1   21
+     -1
+3     1   34
+      0   1    5
+      0   2    1
+      3   1   11
+      3   1   12
+      3   1   23
+     -1
+3     1   35
+      0   1    5
+      0   1   12
+      0   1   13
+      0   2    1
+      3   1   11
+      3   1   12
+      3   1   23
+     -1
+3     1   36
+      3   1    3
+      0   2    1
+      3   1   11
+      3   1   12
+      3   1   23
+     -1
+3     1   37
+      3   1    1
+      0   2   11
+      0   2   12
+      3   1   11
+      3   1   12
+      3   1   22
+     -1
+3     1   38
+      3   1    1
+      0   2   11
+      0   2   12
+      3   1   11
+      3   1   12
+      3   1   24
+     -1
+3     1   39
+      3   1    3
+      0   2   11
+      0   2   12
+      3   1   11
+      3   1   12
+      3   1   23
+     -1
+3     1   40
+      3   1    3
+      0   2   11
+      0   2   12
+      3   1   11
+      3   1   12
+      3   1   24
+     -1
+3     1   41
+      0   1    7
+      0   2   21
+      0   2   22
+      3   1   11
+      3   1   12
+     -1
+3     1   42
+      3   1   41
+      3   1   21
+     -1
+3     1   43
+      0   1    7
+      0   2   23
+      3   1   11
+      3   1   13
+      3   1   21
+     -1
+3     1   44
+      0   1    7
+      0   2   24
+      3   1   11
+      3   1   13
+      3   1   21
+     -1
+3     1   51
+      0   1    6
+      0   2   61
+      3   1   11
+      3   1   12
+      3   1   21
+      0   8    4
+     -1
+3     1   62
+      1   1    0
+      0  31    1
+      3   1    1
+     -1
+3     1  194
+      0   1  194
+      0   1   12
+      0   1   13
+      0   2   11
+      0   2   12
+      3   1   11
+      3   1   12
+      3   1   23
+      0   7    1
+     -1
+3     1  195
+      0   1  195
+      0   1   12
+      0   1   13
+      0   2   11
+      0   2   12
+      3   1   11
+      3   1   12
+      3   1   23
+      0   7    1
+     -1
+3     1  196
+      3   1    3
+      0   2   11
+      0   2   12
+      3   1   11
+      3   1   12
+      3   1   23
+      0   7    1
+     -1
+3     1  200
+      0   1   32
+      0  33  194
+     -1
+3     1  201
+      1   1    3
+      0  33  193
+     -1
+3     1  202
+      0   1   31
+      0   1   32
+     -1
+3     1  237
+      0   1    7
+      0   1   12
+      0   2   21
+      3   1   11
+      0   4    4
+      0   4    5
+      2   1  138
+      2   2  131
+      0   4    6
+      2   1    0
+      2   2    0
+      3   1   23
+     -1
+3     1  238
+      0   2  104
+      0   2  121
+      0   2  113
+      0   2   26
+      0   2   27
+      0   2  111
+      0   2  192
+      2   2  127
+      0   1   13
+      2   2  126
+      0   7    1
+      2   2    0
+      0  25   10
+      0  21  194
+     -1
+3     1  239
+      0   2  111
+      0   2  112
+      0  21  192
+      0  21  193
+      0  21  195
+     -1
+3     1  240
+      2   1  131
+      2   2  129
+      0  22   21
+      2   1    0
+      2   2    0
+     -1
+3     1  241
+      2   1  141
+      2   2  130
+      0   7    1
+      2   1    0
+      2   2    0
+     -1
+3     1  242
+      0  21  207
+      0  21  208
+      0  21  209
+      0  21  210
+      0  21  211
+      0  21  212
+     -1
+3     2    1
+      0  10    4
+      0  10   51
+      0  10   61
+      0  10   63
+     -1
+3     2    2
+      0  10    4
+      0   7    4
+      0  10    3
+      0  10   61
+      0  10   63
+     -1
+3     2    3
+      0  11   11
+      0  11   12
+      0  12    4
+      0  12    6
+      0  13    3
+      0  20    1
+      0  20    3
+      0  20    4
+      0  20    5
+     -1
+3     2    4
+      0  20   10
+      0   8    2
+      0  20   11
+      0  20   13
+      0  20   12
+      0  20   12
+      0  20   12
+     -1
+3     2    5
+      0   8    2
+      0  20   11
+      0  20   12
+      0  20   13
+     -1
+3     2   11
+      3   2    1
+      3   2    3
+      3   2    4
+     -1
+3     2   12
+      3   2    2
+      3   2    3
+      3   2    4
+     -1
+3     2   21
+      0  22    1
+      0  22   11
+      0  22   21
+     -1
+3     2   22
+      0  22    2
+      0  22   12
+      0  22   22
+     -1
+3     2   23
+      0  22    3
+      0  22   13
+      0  22   23
+     -1
+3     2   24
+      3   2   22
+      1   1    2
+      3   2   23
+     -1
+3     2   51
+      0  10    4
+      0  10   51
+      0   7    4
+      0  10    3
+      0  12    4
+      0  12   51
+      0  12   16
+      0  12   17
+      0  13    4
+      1   2    4
+      0   8   51
+      0   8   20
+     -1
+3     2  205
+      2   1  131
+      2   2  129
+      0  22   21
+      2   1    0
+      2   2    0
+     -1
+3     2  206
+      3   2  205
+      2   1  130
+      2   2  129
+      0  22   11
+      2   1    0
+      2   2    0
+      0  22    1
+      0  11    1
+      0  11    2
+     -1
+3     3    1
+      0   7    3
+      0  11    1
+      0  11    2
+     -1
+3     3    2
+      0   7    4
+      0  11    1
+      0  11    2
+     -1
+3     3    3
+      0   7    4
+      0  10    3
+      0  12    1
+      0  12    3
+     -1
+3     3    4
+      0   7    4
+      0  10    3
+      0  12    1
+      0  12    3
+      0  11    1
+      0  11    2
+     -1
+3     3   11
+      0   7    3
+      0   8    1
+      0  11    1
+      0  11    2
+     -1
+3     3   12
+      0   7    4
+      0   8    1
+      0  11    1
+      0  11    2
+     -1
+3     3   13
+      0   7    4
+      0   8    1
+      0  10    3
+      0  12    1
+      0  13    3
+      0  11    1
+      0  11    2
+     -1
+3     3   14
+      0   7    4
+      0   8    1
+      0  10    3
+      0  12    1
+      0  12    3
+      0  11    1
+      0  11    2
+     -1
+3     3   21
+      0   7    4
+      0   7    4
+      2   4    7
+      0  31   21
+     -1
+3     3   22
+      3   3   21
+      0  10    3
+      2   4    0
+     -1
+3     3   23
+      3   3   21
+      0  12    1
+      2   4    0
+     -1
+3     3   24
+      3   3   21
+      0  13   16
+      2   4    0
+     -1
+3     3   25
+      0   2   25
+      2   4    7
+      0  31   21
+      0  12   63
+      2   4    0
+     -1
+3     3   26
+      0   7    4
+      0   8    3
+      2   4    7
+      0  31   21
+      0  12    1
+      2   4    0
+     -1
+3     3   27
+      0   7    4
+      2   4    7
+      0  31   21
+      0  10    3
+      2   4    0
+     -1
+3     3   31
+      0   7    4
+      0   8    3
+      0   7   21
+      0   7   22
+      0   8   12
+      0  12   61
+     -1
+3     3   32
+      0  20   11
+      0  20   16
+     -1
+3     4    1
+      0   8    3
+      0  10    4
+      0  12    1
+      0  11    1
+      0  11    2
+     -1
+3     4    2
+      0   8    3
+      0  10    4
+      0  11    1
+      0  11    2
+     -1
+3     4    3
+      0   8    3
+      0  12    1
+     -1
+3     4    4
+      0   8    3
+      0  10    4
+      0  20   10
+      0  12    1
+     -1
+3     4    5
+      0   2   24
+      0   7    4
+      0   7    4
+      0  13    3
+     -1
+3     4    6
+      0  14    1
+      0  14    1
+      0  14    3
+     -1
+3     4  228
+      0   5  217
+      0   6  217
+      0   7  217
+     -1
+3     4  229
+      0   1  208
+      0   1  209
+      0   1  210
+     -1
+3     6    1
+      0   2   32
+      1   2    0
+      0  31    1
+      0   7   62
+      0  22   42
+     -1
+3     6    2
+      0   2   31
+      0  22    4
+      0  22   31
+     -1
+3     6    3
+      0   2    2
+      0  11   11
+      0  11   12
+      0  12    4
+     -1
+3     6    4
+      0   2   32
+      0   2   33
+      1   3    0
+      0  31    1
+      0   7   62
+      0  22   43
+      0  22   62
+     -1
+3     6    5
+      0   2   31
+      1   3    0
+      0  31    1
+      0   7   62
+      0  22    4
+      0  22   31
+     -1
+3     6    6
+      3   6    3
+      3   6    2
+      0  22   63
+     -1
+3     6    7
+      0   1   12
+      0   1   14
+      3   6    8
+      0   4   24
+      0  27    3
+      0  28    3
+     -1
+3     6    8
+      0   2   34
+      0   2   35
+      0   2   36
+     -1
+3     7    1
+      3   1   31
+      3   2   11
+     -1
+3     7    2
+      3   1   32
+      3   2   11
+     -1
+3     7    3
+      3   7    1
+      1   1    0
+      0  31    1
+      3   2    5
+     -1
+3     7    4
+      3   7    2
+      1   1    0
+      0  31    1
+      3   2    5
+     -1
+3     7    5
+      3   7    1
+      1   1    4
+      3   2    5
+     -1
+3     7    6
+      3   7    2
+      1   1    4
+      3   2    5
+     -1
+3     7    7
+      3   1   31
+      3   2   12
+     -1
+3     7    8
+      3   1   32
+      3   2   12
+     -1
+3     8    1
+      3   1   33
+      3   2   11
+      0  22   42
+     -1
+3     8    2
+      3   1   34
+      3   2   11
+      0  22   42
+     -1
+3     8    3
+      3   1   35
+      3   2   11
+      0  22   42
+     -1
+3     8    4
+      3   1   36
+      3   2   11
+      0  22   42
+     -1
+3     8    5
+      3   8    4
+      3   2   24
+     -1
+3     8    6
+      0  10    4
+      0  10   61
+      0  10   63
+      0  11    1
+      0  11    2
+      0  12    4
+      0  13    3
+      0  22   42
+     -1
+3     9    1
+      3   1   37
+      1   1    0
+      0  31    1
+      3   3   11
+     -1
+3     9    2
+      3   1   38
+      1   1    0
+      0  31    1
+      3   3   11
+     -1
+3     9    3
+      3   1   37
+      1   1    0
+      0  31    1
+      3   3   12
+     -1
+3     9    4
+      3   1   38
+      1   1    0
+      0  31    1
+      3   3   12
+     -1
+3     9    5
+      3   1   37
+      3   2    4
+      1   1    0
+      0  31    1
+      3   3   13
+     -1
+3     9    6
+      3   1   38
+      3   2    4
+      1   1    0
+      0  31    1
+      3   3   13
+     -1
+3     9    7
+      3   1   37
+      3   2    4
+      1   1    0
+      0  31    1
+      3   3   14
+     -1
+3     9    8
+      3   1   38
+      3   2    4
+      1   1    0
+      0  31    1
+      3   3   14
+     -1
+3     9   11
+      3   1   39
+      1   1    0
+      0  31    1
+      3   3   11
+     -1
+3     9   12
+      3   1   39
+      1   1    0
+      0  31    1
+      3   3   12
+     -1
+3     9   13
+      3   1   39
+      3   2    4
+      1   1    0
+      0  31    1
+      3   3   13
+     -1
+3     9   14
+      3   1   39
+      3   2    4
+      1   1    0
+      0  31    1
+      3   3   14
+     -1
+3     9   15
+      3   1   40
+      1   1    0
+      0  31    1
+      3   3   11
+     -1
+3     9   16
+      3   1   40
+      1   1    0
+      0  31    1
+      3   3   12
+     -1
+3     9   17
+      3   1   40
+      3   2    4
+      1   1    0
+      0  31    1
+      3   3   13
+     -1
+3     9   18
+      3   1   31
+      3   2    4
+      1   1    0
+      0  31    1
+      3   3   14
+     -1
+3     9   19
+      3   1   31
+      0   2    3
+      1   1    0
+      0  31    1
+      3   3   11
+     -1
+3     9   20
+      3   1   31
+      0   2    3
+      1   4    0
+      0  31    1
+      0   7    3
+      0  11    3
+      0  11    4
+      0  11    5
+     -1
+3     9  194
+      3   1  194
+      3   2    4
+      1   1    0
+      0  31    1
+      3   3   14
+     -1
+3     9  195
+      3   1  195
+      3   2    4
+      1   1    0
+      0  31    1
+      3   3   14
+     -1
+3     9  196
+      3   1  196
+      3   2    4
+      1   1    0
+      0  31    1
+      3   3   14
+     -1
+3    10    1
+      3   1   42
+      3   3   31
+      3   3   32
+      1   1   26
+      3   3   25
+     -1
+3    10    2
+      3   1   42
+      3   3   31
+      3   3   32
+      1   1    9
+      3   3   23
+     -1
+3    10    3
+      3   1   42
+      3   3   31
+      3   3   32
+      1   1    6
+      3   3   23
+     -1
+3    10    4
+      3   1   42
+      3   3   31
+      3   3   32
+      1   1    3
+      3   3   24
+     -1
+3    11    1
+      3   1   51
+      0   7    2
+      0  12    1
+      0  11    1
+      0  11    2
+      0  11   31
+      0  11   32
+      0  11   33
+      0  20   41
+     -1
+3    12    1
+      3   1   43
+      3   4    1
+     -1
+3    12    2
+      3   1   43
+      3   4    2
+     -1
+3    12    3
+      3   1   42
+      3   4    3
+     -1
+3    12    4
+      3   1   42
+      3   4    4
+     -1
+3    12    5
+      3   1   42
+      0  20   14
+     -1
+3    12    6
+      3   1   44
+      3   4    5
+     -1
+3    12    7
+      3   1   42
+      3   4    6
+     -1
+3    12   10
+      0   1    7
+      0   5   40
+      0   2   21
+      0   5   41
+      0   4    1
+      0   4   43
+     -1
+3    12   11
+      2   2  131
+      2   1  149
+      0   4    6
+      2   1    0
+      2   2  126
+      0  10    2
+      2   2    0
+      0   5   43
+      0   5   53
+     -1
+3    12   12
+      2   2  129
+      2   1  132
+      1   1   19
+      0  12   63
+      2   1    0
+      2   2    0
+     -1
+3    12   13
+      0   5   33
+      2   2  129
+      2   1  135
+      0  12   63
+      2   1    0
+      2   2    0
+     -1
+3    12   14
+      3  12   10
+      3  12   11
+      1   5   56
+      3   1   23
+      0   5   42
+      0   5   52
+      3  12   12
+      3  12   13
+     -1
+3    12   15
+      1   9   11
+      3   1   23
+      0   5   42
+      0   5   52
+      2   2  129
+      2   1  132
+      1   1    4
+      0  12   63
+      2   2    0
+      2   1    0
+     -1
+3    12   16
+      3  12   10
+      3  12   11
+      3  12   15
+     -1
+3    12   17
+      1   9    8
+      3   1   23
+      0   5   42
+      0   5   52
+      2   2  129
+      2   1  132
+      1   1    3
+      0  12   63
+      2   2    0
+      2   1    0
+     -1
+3    12   18
+      3  12   10
+      3  12   11
+      3  12   18
+     -1
+3    12  200
+      3   1  237
+      3   1  238
+      0  29    2
+      0  21  206
+      1   4   12
+      0   6  232
+      1   2   12
+      0   5  232
+      0  21  205
+      0  21  196
+     -1
+3    12  201
+      3   1  237
+      1   1    3
+      3   1  239
+      0  11   12
+      0  11   11
+      0  21  197
+     -1
+3    12  202
+      3   1  237
+      0   8   22
+      0  11   12
+      0  11   50
+      3   1  240
+      0  22  243
+      3   1  241
+      0  10   50
+      0  21  198
+      0  21  201
+      0  21  202
+      0  21  203
+      3   1  242
+     -1
+3    12  203
+      3   1  237
+      0   8   22
+      0  12   61
+      0  22   50
+      0  21  204
+      0  21  199
+      0  21  214
+      0  21  215
+     -1
+3    12  204
+      3  12  201
+      0   1   31
+      0  11   12
+      0  11   11
+      0  21  200
+      0  21  213
+      0   4    4
+      0   8   21
+      0   4   24
+      0  55    3
+      0  11   12
+      0  11   11
+     -1
+3    12  207
+      3  12  202
+      3   1  202
+      0  33  191
+     -1
+3    12  208
+      3   1  202
+      0   8   22
+      0   8   21
+      3   1   11
+      3   1   13
+      3   1   23
+      3   2  205
+      0  11    2
+      0   1    7
+      0   2   21
+      3   1   11
+      3   1   13
+      3   1   23
+      0   1   32
+      0   1  192
+      3   2  205
+      0  11    2
+     -1
+3    12  209
+      3   1  202
+      0   1  192
+      3   1   11
+      3   1   13
+      3   1   23
+      3   2  206
+      1   4    0
+      0  22  192
+      1   2    0
+      0   5  232
+      0  22  191
+     -1
+3    12  210
+      3  12  202
+      0  21  192
+      0  15  202
+      3   1   11
+      0   4    4
+      0   4    5
+      2   1  138
+      2   2  131
+      0   4    6
+      2   1    0
+      2   2    0
+      3   4  228
+      3   4  229
+     -1
+3    13    9
+      0  21    1
+      1   1    0
+      0  31    1
+      0  21    1
+     -1
+3    13   10
+      0  21   36
+      1   1    0
+      0  31    1
+      0  21   36
+     -1
+3    13   31
+      0   6    2
+      0   6   12
+      1   1    0
+      0  31    2
+      0  30    1
+     -1
+3    13   32
+      0   5    2
+      0   5   12
+      1   1    0
+      0  31    2
+      3  13   31
+     -1
+3    13   41
+      0   6    2
+      1  10    0
+      0  31    1
+      1   4    0
+      0  31    1
+      0   6   12
+      1   1    0
+      0  31   12
+      0  30    1
+      0   6   12
+      1   1    0
+      0  31    1
+      0  30    1
+     -1
+3    13   42
+      0   5    2
+      0   5   12
+      1   1    0
+      0  31    2
+      3  13   41
+     -1
+3    13   43
+      0   6    2
+      0   5    2
+      0   5   12
+      1  12    0
+      0  31    1
+      1  10    0
+      0  31    1
+      1   4    0
+      0  31    1
+      0   6   12
+      1   1    0
+      0  31   11
+      0  30    1
+      1   1    0
+      0  31    1
+      0  30    1
+     -1
+3    15    1
+      0   1   11
+      3   1   11
+      3   1   12
+      3   1   23
+      3   6    1
+     -1
+3    15    2
+      0   1   11
+      3   1   11
+      3   1   12
+      3   1   23
+      3   6    4
+     -1
+3    16    1
+      3   1   11
+      0   4    4
+      3   1   23
+      0   1   21
+      0   2   41
+      0  19    1
+      0  10   51
+      0  19    2
+      0  19    3
+      0  19    4
+     -1
+3    18    1
+      3   1   25
+      0  24   11
+     -1
+3    18    3
+      3   1   26
+      0  24    5
+      0  24    4
+      0  24   21
+     -1
+3    18    4
+      3   1   25
+      0   4   23
+      0  13   11
+      0  24    5
+      0  24    4
+      0  24   22
+     -1
+3    21    1
+      0   2  101
+      0   2  114
+      0   2  105
+      0   2  106
+      0   2  107
+      0   2  121
+     -1
+3    21    3
+      0  21   51
+      0  21   14
+      0  21   17
+      0  25   30
+     -1
+3    21    4
+      3   1   31
+      0   2    3
+      1   1    0
+      0  31    1
+      3  21    3
+     -1
+3    21    5
+      0  25    4
+      0   2  121
+      0   2  122
+      0   2  123
+      0   2  124
+      0   2  125
+      0   2  126
+      0   2  127
+      0   2  128
+      0   2  129
+      0   2  130
+      0   2  131
+     -1
+3    21    6
+      0  25    1
+      0  25    2
+      0  25    3
+      0  25    5
+     -1
+3    21    7
+      0  25    9
+      0  25   10
+      0  25   11
+      0  25   12
+      0  25   13
+      0  25   15
+      0  25   16
+      0  25   17
+     -1
+3    21    8
+      0  25    6
+      0  25    7
+      0  25    8
+     -1
+3    21    9
+      0  25   18
+      0  25   19
+     -1
+3    21   10
+      0   2  101
+      0   7    2
+      0   2  102
+      0   2  103
+      0   2  104
+      0   2  105
+      0   2  106
+      0   2  107
+      0   2  108
+      0   2  109
+      0   2  110
+      0   2  132
+      0   2  133
+     -1
+3    21   11
+      0  30   31
+      0  30   32
+      0  29    2
+     -1
+3    21   12
+      1   1    0
+      0  31    1
+      0   2  135
diff --git a/data/tables/B3L-128-001-B b/data/tables/B3L-128-001-B
new file mode 100644
index 0000000..fa991ab
--- /dev/null
+++ b/data/tables/B3L-128-001-B
@@ -0,0 +1,7 @@
+#
+# LOCAL BUFR Table B - Classification of Elements
+#
+# sccs keywords: @(#)Table_B.txt	1.1 05/07/97
+#					Data
+  0;   12;    194;      1;           0;   12;        deg_K; Dry bulb temperature at 2 meters
+  0;    1;    194;      0;           0;   72;    CCITT_IA5; test Ship or mobile land station identifier
diff --git a/data/tables/B3L-160000-000001-B b/data/tables/B3L-160000-000001-B
new file mode 100644
index 0000000..29cae15
--- /dev/null
+++ b/data/tables/B3L-160000-000001-B
@@ -0,0 +1,52 @@
+#
+# BUFR Table B - Local table for ECMWF encode/decode of 
+# High Density Winds from GOES, ref. IPD-1008 release 3 Version 1
+#
+#					Data
+#F	X	Y	Scale	RefVal	Width	Units	Element Name
+
+  0;    1;      7;      0;           0;   10;   Code_Table; Satellite identifier
+  0;    1;     31;      0;           0;   16;   Code_Table; Identification of originating/generating center
+  0;    1;     32;      0;           0;    8;   Code_Table; Generating application
+
+  0;    2;     23;      0;           0;    4;   Code_Table; Satellite derived wind computation method
+  0;    2;     57;      0;           0;    4;   Code_Table; Origin of first guess information for GOES-I/M soundings
+
+  0;    2;    196;      0;           0;    9;   Code_Table; Satellite Classification
+  0;    2;    197;      8;           0;   26;           Hz; Satellite Channel Center Frequency
+  0;    2;    198;      8;           0;   26;           Hz; Satellite Channel Band Width
+  0;    2;    221;      0;           0;   18;            M; Segment Size At Nadir In X Direction
+  0;    2;    222;      0;           0;   18;            M; Segment Size At Nadir In Y Direction
+  0;    2;    231;      0;           0;    4;   Code_Table; Height Assignment Method
+  0;    2;    232;      0;           0;    3;   Code_Table; Tracer Correlation Method
+  0;    2;    252;      0;           0;   31;   Flag_Table; Satellite Instrument Data Used In Processing
+
+  0;    4;      1;      0;           0;   12;         Year; Year
+  0;    4;      2;      0;           0;    4;           mo; Month
+  0;    4;      3;      0;           0;    6;          Day; Day
+  0;    4;      4;      0;           0;    5;           hr; Hour
+  0;    4;      5;      0;           0;    6;          min; Minute
+  0;    4;      6;      0;           0;    6;            s; Second
+  0;    4;     24;      0;       -2048;   12;           hr; Time period or displacement
+
+  0;    5;      1;      5;    -9000000;   25;          deg; Latitude (high accuracy)
+
+  0;    6;      1;      5;   -18000000;   26;          deg; Longitude (high accuracy)
+
+  0;    7;      4;     -1;           0;   14;           Pa; Pressure
+  0;    7;     24;      2;       -9000;   15;          deg; Satellite zenith angle
+
+  0;    8;     12;      0;           0;    2;   Code_Table; land/sea qualifier
+  0;    8;     21;      0;           0;    5;   Code_Table; Time significance
+
+  0;   11;      1;      0;           0;    9;     deg_true; Wind direction
+  0;   11;      2;      1;           0;   12;          m/s; Wind speed
+
+  0;   12;      1;      1;           0;   12;        deg_K; Temperature/dry bulb temperature
+  0;   12;    193;      1;           0;   12;        deg_K; Coldest Cluster Temperature
+
+
+  0;   31;     31;      0;           0;    1;   Flag_Table; Data present indicator
+
+  0;   33;      7;      0;           0;    7;      Percent; Per cent confidence
+
diff --git a/data/tables/B3L-160000-000001-B-forHDGOES b/data/tables/B3L-160000-000001-B-forHDGOES
new file mode 100644
index 0000000..00fc1f1
--- /dev/null
+++ b/data/tables/B3L-160000-000001-B-forHDGOES
@@ -0,0 +1,52 @@
+#
+# BUFR Table B - Local table for ECMWF encode/decode of 
+# High Density Winds from GOES, ref. IPD-1008 release 3 Version 1
+#
+#					Data
+#F	X	Y	Scale	RefVal	Width	Units	Element Name
+
+0	1	7	0	0	10	Code_Table	Satellite identifier
+0	1	31	0	0	16	Code_Table	Identification of originating/generating center
+0	1	32	0	0	8	Code_Table	Generating application
+
+0	2	23	0	0	4	Code_Table	Satellite derived wind computation method
+0	2	57	0	0	4	Code_Table	Origin of first guess information for GOES-I/M soundings
+
+0	2	196	0	0	9	Code_Table	Satellite Classification
+0	2	197	8	0	26	Hz	Satellite Channel Center Frequency
+0	2	198	8	0	26	Hz	Satellite Channel Band Width
+0	2	221	0	0	18	M	Segment Size At Nadir In X Direction
+0	2	222	0	0	18	M	Segment Size At Nadir In Y Direction
+0	2	231	0	0	4	Code_Table	Height Assignment Method
+0	2	232	0	0	3	Code_Table	Tracer Correlation Method
+0	2	252	0	0	31	Flag_Table	Satellite Instrument Data Used In Processing
+
+0	4	1	0	0	12	Year	Year
+0	4	2	0	0	4	mo	Month
+0	4	3	0	0	6	Day	Day
+0	4	4	0	0	5	hr	Hour
+0	4	5	0	0	6	min	Minute
+0	4	6	0	0	6	s	Second
+0	4	24	0	-2048	12	hr	Time period or displacement
+
+0	5	1	5	-9000000	25	deg	Latitude (high accuracy)
+
+0	6	1	5	-18000000	26	deg	Longitude (high accuracy)
+
+0	7	4	-1	0	14	Pa	Pressure
+0	7	24	2	-9000	15	deg	Satellite zenith angle
+
+0	8	12	0	0	2	Code_Table	land/sea qualifier
+0	8	21	0	0	5	Code_Table	Time significance
+
+0	11	1	0	0	9	deg_true	Wind direction
+0	11	2	1	0	12	m/s	Wind speed
+
+0	12	1	1	0	12	deg_K	Temperature/dry bulb temperature
+0	12	193	1	0	12	deg_K	Coldest Cluster Temperature
+
+
+0	31	31	0	0	1	Flag_Table	Data present indicator
+
+0	33	7	0	0	7	Percent	Per cent confidence 
+
diff --git a/data/tables/B3L-160000-000001-D b/data/tables/B3L-160000-000001-D
new file mode 100644
index 0000000..9d1b703
--- /dev/null
+++ b/data/tables/B3L-160000-000001-D
@@ -0,0 +1,83 @@
+#
+# BUFR Table D (Lists of High Density Wind Sequences)
+#
+# Descriptor sequences are terminated with -1
+#
+# Sequences do not need to appear in any order.  Sequence A
+# which includes sequence B, may appear before sequence B
+# is defined.
+#
+3	10	195
+	3	1	250
+	3	3	250
+	3	4	250
+	-1
+
+3	1	250
+	3	1	193
+	3	1	11
+	3	1	13
+	3	1	21
+	-1
+
+3	1	193
+	0	1	7
+	0	1	31
+	0	2	196
+	0	2	221
+	0	2	222
+	-1
+
+3	1	11
+	0	4	1
+	0	4	2
+	0	4	3
+	-1
+
+3	1	13
+	0	4	4
+	0	4	5
+	0	4	6
+	-1
+
+3	1	21
+	0	5	1
+	0	6	1
+	-1
+
+3	3	250
+	0	2	252
+	0	2	23
+	0	7	4
+	0	11	1
+	0	11	2
+	0	2	197
+	0	2	198
+	0	12	193
+	-1
+
+3	4	250
+	0	2	231
+	0	2	232
+	0	8	12
+	0	7	24
+	0	2	57
+	0	8	21
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	8	21
+	0	4	24
+	1	10	4
+	0	8	21
+	0	4	4
+	0	4	5
+	0	4	6
+	0	11	1
+	0	11	2
+	1	30	10
+	0	2	231
+	0	7	4
+	0	12	1
+	-1
diff --git a/data/tables/B3L-160000-000001-D-forHDGOES b/data/tables/B3L-160000-000001-D-forHDGOES
new file mode 100644
index 0000000..9d1b703
--- /dev/null
+++ b/data/tables/B3L-160000-000001-D-forHDGOES
@@ -0,0 +1,83 @@
+#
+# BUFR Table D (Lists of High Density Wind Sequences)
+#
+# Descriptor sequences are terminated with -1
+#
+# Sequences do not need to appear in any order.  Sequence A
+# which includes sequence B, may appear before sequence B
+# is defined.
+#
+3	10	195
+	3	1	250
+	3	3	250
+	3	4	250
+	-1
+
+3	1	250
+	3	1	193
+	3	1	11
+	3	1	13
+	3	1	21
+	-1
+
+3	1	193
+	0	1	7
+	0	1	31
+	0	2	196
+	0	2	221
+	0	2	222
+	-1
+
+3	1	11
+	0	4	1
+	0	4	2
+	0	4	3
+	-1
+
+3	1	13
+	0	4	4
+	0	4	5
+	0	4	6
+	-1
+
+3	1	21
+	0	5	1
+	0	6	1
+	-1
+
+3	3	250
+	0	2	252
+	0	2	23
+	0	7	4
+	0	11	1
+	0	11	2
+	0	2	197
+	0	2	198
+	0	12	193
+	-1
+
+3	4	250
+	0	2	231
+	0	2	232
+	0	8	12
+	0	7	24
+	0	2	57
+	0	8	21
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	8	21
+	0	4	24
+	1	10	4
+	0	8	21
+	0	4	4
+	0	4	5
+	0	4	6
+	0	11	1
+	0	11	2
+	1	30	10
+	0	2	231
+	0	7	4
+	0	12	1
+	-1
diff --git a/data/tables/B3L-160000-006001-B b/data/tables/B3L-160000-006001-B
new file mode 100644
index 0000000..614790b
--- /dev/null
+++ b/data/tables/B3L-160000-006001-B
@@ -0,0 +1,814 @@
+#
+# BUFR Table B - Classification of Elements (edited by Mr. Spurlin last on April 12, 2001)
+#
+#						Data
+#F	X	Y	Scale	RefVal		Width	Units		Element Name
+  0;    0;      1;      0;           0;   24;    CCITT_IA5; Table A: entry
+  0;    0;      2;      0;           0;  256;    CCITT_IA5; Table A: data category description, line 1
+  0;    0;      3;      0;           0;  256;    CCITT_IA5; Table A: data category description, line 2
+  0;    0;      5;      0;           0;   24;    CCITT_IA5; BUFR edition number
+  0;    0;     10;      0;           0;    8;    CCITT_IA5; F descriptor to be added or defined
+  0;    0;     11;      0;           0;   16;    CCITT_IA5; X descriptor to be added or defined
+  0;    0;     12;      0;           0;   24;    CCITT_IA5; Y descriptor to be added or defined
+  0;    0;     13;      0;           0;  256;    CCITT_IA5; Element name, line 1
+  0;    0;     14;      0;           0;  256;    CCITT_IA5; Element name, line 2
+  0;    0;     15;      0;           0;  192;    CCITT_IA5; Units name
+  0;    0;     16;      0;           0;    8;    CCITT_IA5; Units scale sign
+  0;    0;     17;      0;           0;   24;    CCITT_IA5; Units scale
+  0;    0;     18;      0;           0;    8;    CCITT_IA5; Units reference sign
+  0;    0;     19;      0;           0;   80;    CCITT_IA5; Units reference value
+  0;    0;     20;      0;           0;   24;    CCITT_IA5; Element data width
+  0;    0;     30;      0;           0;   48;    CCITT_IA5; Descriptor defining sequence
+
+  0;    1;      1;      0;           0;    7;      Numeric; WMO block number
+  0;    1;      2;      0;           0;   10;      Numeric; WMO station number
+  0;    1;      3;      0;           0;    3;   Code_Table; WMO region number
+  0;    1;      4;      0;           0;    3;      Numeric; WMO region sub-area
+  0;    1;      5;      0;           0;   17;      Numeric; Buoy/platform identifier
+  0;    1;      6;      0;           0;   64;    CCITT_IA5; Aircraft identifier (flight number)
+  0;    1;      7;      0;           0;   10;   Code_Table; Satellite identifier
+  0;    1;      8;      0;           0;   64;    CCITT_IA5; Aircraft registration number (tail number)
+  0;    1;      9;      0;           0;   64;    CCITT_IA5; Type of commerical aircraft
+  0;    1;     10;      0;           0;   64;    CCITT_IA5; Stationary buoy platform identifier
+  0;    1;     11;      0;           0;   72;    CCITT_IA5; Ship or mobile land station identifier
+  0;    1;     12;      0;           0;    9;     deg_true; Direction of motion of moving observing platform
+  0;    1;     13;      0;           0;   10;          m/s; Speed of motion of moving observing platform
+  0;    1;     14;      2;           0;   10;          m/s; Platform drift speed (high precision)
+  0;    1;     15;      0;           0;  160;    CCITT_IA5; Station or site name
+  0;    1;     18;      0;           0;   40;    CCITT_IA5; Short station or site name
+  0;    1;     20;      0;           0;    4;      Numeric; WMO Region sub-area
+  0;    1;     21;      0;           0;   14;      Numeric; Synoptic feature identifier
+  0;    1;     22;      0;           0;  224;    CCITT_IA5; Name of feature
+  0;    1;     25;      0;           0;   24;    CCITT_IA5; Storm identifier
+  0;    1;     26;      0;           0;   64;    CCITT_IA5; WMO storm name
+  0;    1;     31;      0;           0;   16;   Code_Table; Identification of originating/generating center
+  0;    1;     32;      0;           0;    8;   Code_Table; Generating application
+  0;    1;     33;      0;           0;    8;   Code_Table; Identification of originating/generating center
+  0;    1;     34;      0;           0;    8;   Code_Table; Identification of originating/generating sub-center
+  0;    1;     41;      5; -1073741824;   31;          m/s; Absolute platform velocity - first component
+  0;    1;     42;      5; -1073741824;   31;          m/s; Absolute platform velocity - second component
+  0;    1;     43;      5; -1073741824;   31;          m/s; Absolute platform velocity - third component
+  0;    1;     50;      0;           0;   17;      Numeric; Platform transmitter ID number
+  0;    1;     51;      0;           0;   96;    CCITT_IA5; Platform transmitter ID nubmer
+  0;    1;     60;      0;           0;   64;    CCITT_IA5; Aircraft reporting point (Beacon identifier)
+  0;    1;     62;      0;           0;   32;    CCITT_IA5; Aircraft reporting point (Beacon idnetifier)
+  0;    1;     63;      0;           0;   64;    CCITT_IA5; ICAO location indicator
+  0;    1;     64;      0;           0;   32;    CCITT_IA5; Runway designator
+  0;    1;     75;      0;           0;   40;    CCITT_IA5; Ride station identification
+
+  0;    2;      1;      0;           0;    2;   Code_Table; Type of station
+  0;    2;      2;      0;           0;    4;   Flag_Table; Type of instrumentation for wind measurement
+  0;    2;      3;      0;           0;    4;   Code_Table; Type of measuring instrumentation used
+  0;    2;      4;      0;           0;    4;   Code_Table; Type of instrumentation for evaporation measurement or type of crop for which evapotranspiration is reported
+  0;    2;      5;      2;           0;    7;        deg_K; Precision of temperature observed
+  0;    2;     11;      0;           0;    8;   Code_Table; Radiosonde type
+  0;    2;     12;      0;           0;    4;   Code_Table; Radiosonde computational method
+  0;    2;     13;      0;           0;    4;   Code_Table; Solar and infrared radiation correction
+  0;    2;     14;      0;           0;    7;   Code_Table; Tracking technique/status of system
+  0;    2;     15;      0;           0;    4;   Code_Table; Radiosonde completeness
+  0;    2;     19;      0;           0;   11;   Code_Table; Satellite instruments
+  0;    2;     20;      0;           0;    9;   Code_Table; Satellite classification
+  0;    2;     21;      0;           0;    9;   Flag_Table; Satellite instrumentation data used in processing
+  0;    2;     22;      0;           0;    8;   Flag_Table; Satellite data processing technique used
+  0;    2;     23;      0;           0;    4;   Code_Table; Satellite derived wind computation method
+  0;    2;     24;      0;           0;    4;   Code_Table; Integrated mean humidity computational method
+  0;    2;     25;      0;           0;   25;   Flag_Table; Satellite channel(s) used in computation
+  0;    2;     26;      2;           0;   12;            m; Cross track resolution
+  0;    2;     27;      2;           0;   12;            m; Along track resolution
+  0;    2;     28;      0;           0;   18;            m; Segment size at nadir in X direction
+  0;    2;     29;      0;           0;   18;            m; Segment size at nadir in Y direction
+  0;    2;     30;      0;           0;    3;   Code_Table; Method of current measurement
+  0;    2;     31;      0;           0;    5;   Code_Table; Duration and time of current measurement
+  0;    2;     32;      0;           0;    2;   Code_Table; Indicator for digitization
+  0;    2;     33;      0;           0;    3;   Code_Table; Method of salinity/depth measurement
+  0;    2;     34;      0;           0;    5;   Code_Table; Drogue type
+  0;    2;     35;      0;           0;    9;            m; Cable length
+  0;    2;     36;      0;           0;    2;   Code_Table; Buoy type
+  0;    2;     37;      0;           0;    3;   Code_Table; Method of tidal observation
+  0;    2;     38;      0;           0;    4;   Code_Table; Method of sea-surface temperature measurement
+  0;    2;     39;      0;           0;    3;   Code_Table; Method of wet-buld temperature measurement
+  0;    2;     40;      0;           0;    4;   Code_Table; Method of removing velocity and motion of platform from current
+  0;    2;     41;      0;           0;    6;   Code_Table; Method for estimating reports related to synoptic features
+  0;    2;     44;      0;           0;    4;   Code_Table; Inicator for method of calculating spectral wave data
+  0;    2;     45;      0;           0;    4;   Code_Table; Indicator for type of platform
+  0;    2;     46;      0;           0;    4;   Code_Table; Wave measurement instrumentation
+  0;    2;     48;      0;           0;    4;   Code_Table; Satellite sensor indicator
+  0;    2;     49;      0;           0;    8;   Flag_Table; Geostationary satellite data-processing technique used
+  0;    2;     50;      0;           0;   20;   Flag_Table; Geostationary sounder satellite channels used
+  0;    2;     51;      0;           0;    4;   Code_Table; Indicator ro specify observing method for extreme temperatures
+  0;    2;     52;      0;           0;    6;   Flag_Table; Geostationary imager satellite channels used
+  0;    2;     53;      0;           0;    4;   Code_Table; GOES-I/M  brightness temperature characteristics
+  0;    2;     54;      0;           0;    4;   Code_Table; GOES-I/M  soundings parameter characteristics
+  0;    2;     55;      0;           0;    4;   Code_Table; Geostationary soundings statistical parameters
+  0;    2;     56;      0;           0;    4;   Code_Table; Geostationary soundings accuracy statistics
+  0;    2;     57;      0;           0;    4;   Code_Table; Origin of first guess information for GOES-I/M soundings
+  0;    2;     58;      0;           0;    4;   Code_Table; Valid times of first guess information for GOES-I/M soundings
+  0;    2;     59;      0;           0;    4;   Code_Table; Origin of analysis information for GOES-I/M soundings
+  0;    2;     60;      0;           0;    4;   Code_Table; Origin of surface information for GOES-I/M soundings
+  0;    2;     61;      0;           0;    3;   Code_Table; Aircraft navigation system
+  0;    2;     62;      0;           0;    4;   Code_Table; Type of aircraft data relay system
+  0;    2;     63;      2;      -18000;   16;          deg; Aircraft roll angle
+  0;    2;     64;      0;           0;    2;   Code_Table; Aircraft roll angle quality
+  0;    2;     65;      0;           0;   40;    CCITT_IA5; ACARS ground receiving station
+  0;    2;     70;      0;           0;    4;   Code_Table; Original specification of latitude/longitude
+  0;    2;     91;      0;           4;   10;            A; Entry sensor 4/20 mA
+  0;    2;    100;      1;           0;   12;           dB; Radar constant
+  0;    2;    101;      0;           0;    4;   Code_Table; Type of antenna
+  0;    2;    102;      0;           0;    8;            m; Antenna height above tower
+  0;    2;    103;      0;           0;    2;   Flag_Table; Radome
+  0;    2;    104;      0;           0;    4;   Code_Table; Antenna polarisation
+  0;    2;    105;      0;           0;    6;           dB; Maximum antenna gain
+  0;    2;    106;      1;           0;    6;          deg; 3-dB bandwidth
+  0;    2;    107;      0;           0;    6;           dB; Sidelobe suppression
+  0;    2;    108;      0;           0;    6;           dB; Crosspol discrimination (on axis)
+  0;    2;    109;      2;           0;   12;        deg/s; Antenna speed (azimuth)
+  0;    2;    110;      2;           0;   12;        deg/s; Antenna speed (elevation)
+  0;    2;    111;      1;           0;   10;          deg; Radar incidence angle
+  0;    2;    112;      1;           0;   12;          deg; Radar azimuth angle
+  0;    2;    113;      0;           0;    4;      Numeric; Number of azimuth looks
+  0;    2;    114;      0;           0;   15;         m**2; Antenna effective surface area
+  0;    2;    121;     -8;           0;    7;           Hz; Mean frequency
+  0;    2;    122;     -6;        -128;    8;           Hz; Frequency agility range
+  0;    2;    123;     -4;           0;    7;            W; Peak power
+  0;    2;    124;     -1;           0;    7;            W; Average power
+  0;    2;    125;     -1;           0;    8;           Hz; Pulse repetition frequency
+  0;    2;    126;      7;           0;    6;            s; Pulse width
+  0;    2;    127;     -6;           0;    7;           Hz; Receiver intermediate frequency
+  0;    2;    128;     -5;           0;    6;           Hz; Intermediate frequency bandwidth
+  0;    2;    129;      0;        -150;    5;           dB; Minimum detectable signal
+  0;    2;    130;      0;           0;    7;           dB; Dynamic range
+  0;    2;    131;      0;           0;    2;   Flag_Table; Sensitivity time control
+  0;    2;    132;      2;           0;    6;          deg; Azimuth pointing accuracy
+  0;    2;    133;      2;           0;    6;          deg; Elevation pointing accuracy
+  0;    2;    134;      2;           0;   16;          deg; Antenna beam azimuth
+  0;    2;    135;      2;       -9000;   15;          deg; Antenna elevation
+  0;    2;    136;     -3;           0;   16;            m; Range processed by range attenuation correction
+  0;    2;    140;      0;           0;    9;          deg; Satellite radar beam azimuth
+  0;    2;    141;      0;           0;   24;    CCITT_IA5; Measurement type
+  0;    2;    142;      0;           0;   32;    CCITT_IA5; Ozone instrument serial number/identification
+  0;    2;    143;      0;           0;    7;   Code_Table; Ozone instrument type
+  0;    2;    144;      0;           0;    4;   Code_Table; Light source type for Brewer spectrophotometer
+  0;    2;    145;      0;           0;    4;   Code_Table; Wave length setting for Dobson instruments
+  0;    2;    146;      0;           0;    4;   Code_Table; Source conditions for Dobson instruments
+  0;    2;    148;      0;           0;    5;   Code_Table; Data collection and/or location system
+  0;    2;    149;      0;           0;    6;   Code_Table; Type of data buoy
+  0;    2;    150;      0;           0;    6;   Code_Table; TOVS/ATOVS/AVHRR instrumentation channel number
+  0;    2;    151;      0;           0;    4;   Code_Table; Radiometer identifier
+  0;    2;    152;      0;           0;   31;   Flag_Table; Satellite instrument used in data processing
+  0;    2;    153;     -8;           0;   26;           Hz; Satellite channel center frequency
+  0;    2;    154;     -8;           0;   26;           Hz; Satellite channel band width
+  0;    2;    163;      0;           0;    4;   Code_Table; Height assignment method
+  0;    2;    164;      0;           0;    3;   Code_Table; Tracer correlation method
+  0;    2;    166;      0;           0;    4;   Code_Table; Radiance type
+  0;    2;    167;      0;           0;    4;   Code_Table; Radiance computational method
+  0;    2;    168;     -3;           0;   16;           Pa; Hydrostatic pressure of lower end of cable (thermistor string)
+  0;    2;    169;      0;           0;    4;   Code_Table; Anemometer type
+  0;    2;    172;      0;           0;    8;   Code_Table; Product type for retrieved atmospheric gases
+  0;    2;    196;      0;           0;    9;   Code_Table; Satellite Classification
+  0;    2;    197;     -8;           0;   26;           Hz; Satellite Channel Center Frequency
+  0;    2;    198;     -8;           0;   26;           Hz; Satellite Channel Band Width
+  0;    2;    221;      0;           0;   18;            M; Segment Size At Nadir In X Direction
+  0;    2;    222;      0;           0;   18;            M; Segment Size At Nadir In Y Direction
+  0;    2;    231;      0;           0;    4;   Code_Table; Height Assignment Method
+  0;    2;    232;      0;           0;    3;   Code_Table; Tracer Correlation Method
+  0;    2;    252;      0;           0;   31;   Flag_Table; Satellite Instrument Data Used In Processing
+  0;    4;      1;      0;           0;   12;         Year; Year
+  0;    4;      2;      0;           0;    4;           mo; Month
+  0;    4;      3;      0;           0;    6;          Day; Day
+  0;    4;      4;      0;           0;    5;           hr; Hour
+  0;    4;      5;      0;           0;    6;          min; Minute
+  0;    4;      6;      0;           0;    6;            s; Second
+  0;    4;     11;      0;       -1024;   11;         Year; Time increment
+  0;    4;     12;      0;       -1024;   11;           mo; Time increment
+  0;    4;     13;      0;       -1024;   11;         Days; Time increment
+  0;    4;     14;      0;       -1024;   11;           hr; Time increment
+  0;    4;     15;      0;       -2048;   12;          min; Time increment
+  0;    4;     16;      0;       -4096;   13;            s; Time increment
+  0;    4;     17;      0;       -1440;   12;          min; Reference time period for accumulated or extreme data
+  0;    4;     21;      0;       -1024;   11;         Year; Time period or displacement
+  0;    4;     22;      0;       -1024;   11;           mo; Time period or displacement
+  0;    4;     23;      0;       -1024;   11;         Days; Time period or displacement
+  0;    4;     24;      0;       -2048;   12;           hr; Time period or displacement
+  0;    4;     25;      0;       -2048;   12;          min; Time period or displacement
+  0;    4;     26;      0;       -4096;   13;            s; Time period or displacement
+  0;    4;     31;      0;           0;    8;           hr; Duration of time relative to following value
+  0;    4;     32;      0;           0;    6;       Minute; Duration of time relating to following value
+  0;    4;     41;      0;       -1440;   12;       Minute; Time Difference, UTC-LMT
+  0;    4;     43;      0;           0;    9;          Day; Day of the year
+  0;    4;     53;      0;           0;    6;      Numeric; Number of days with precipition equal to or more than 1mm
+  0;    4;     65;      0;        -128;    8;          min; Short time increment
+  0;    4;     73;      0;        -128;    8;          Day; Short time period or displacement
+  0;    4;     74;      0;        -128;    8;         Hour; Short time period or displacement
+  0;    4;     75;      0;        -128;    8;       Minute; Short time period or displacement
+  0;    4;    192;      0;           0;    3;   Code_Table; Season
+  0;    5;      1;      5;    -9000000;   25;          deg; Latitude (high accuracy)
+  0;    5;      2;      2;       -9000;   15;          deg; Latitude (coarse accuracy)
+  0;    5;     11;      5;    -9000000;   25;          deg; Latitude increment (high accuracy)
+  0;    5;     12;      2;       -9000;   15;          deg; Latitude increment (coarse accuracy)
+  0;    5;     21;      2;           0;   16;     deg_true; Bearing or azimuth
+  0;    5;     22;      2;           0;   16;     deg_true; Solar azimuth
+  0;    5;     30;      0;           0;   12;          deg; Direction (spectral)
+  0;    5;     31;      0;           0;   12;      Numeric; Row number
+  0;    5;     33;     -1;           0;   16;            m; Pixel size on horizontal - 1
+  0;    5;     34;      0;           0;   11;      Numeric; Along Track row number
+  0;    5;     40;      0;           0;   24;      Numeric; Orbit number
+  0;    5;     41;      0;           0;    8;      Numeric; Scan line number
+  0;    5;     42;      0;           0;    6;      Numeric; Channel number
+  0;    5;     43;      0;           0;    8;      Numeric; Field of view number
+  0;    5;     52;      0;           0;    5;      Numeric; Channel number increment
+  0;    5;     53;      0;           0;    5;      Numeric; Field of view number increment
+
+  0;    6;      1;      5;   -18000000;   26;          deg; Longitude (high accuracy)
+  0;    6;      2;      2;      -18000;   16;          deg; Longitude (coarse accuracy)
+  0;    6;     11;      5;   -18000000;   26;          deg; Longitude increment (high accuracy)
+  0;    6;     12;      2;      -18000;   16;          deg; Longitude increment (coarse accuracy)
+  0;    6;     21;     -1;           0;   13;            m; Distance
+  0;    6;     30;      5;           0;   13;        rad/m; Wavenumber (spectral)
+  0;    6;     31;      0;           0;   12;      Numeric; Column number
+  0;    6;     33;     -1;           0;   16;            m; Pixel size on horizontal - 2
+  0;    6;     34;      0;           0;    7;      Numeric; Cross-track cell number
+  0;    6;     40;      0;           0;   13;            m; Radius of confidence
+
+  0;    7;      1;      0;        -400;   15;            m; Height of station
+  0;    7;      2;     -1;         -40;   16;            m; Height or altitude
+  0;    7;      3;     -1;        -400;   17;    m**2/s**2; Geopotential
+  0;    7;      4;     -1;           0;   14;           Pa; Pressure
+  0;    7;      5;      0;        -400;   12;            m; Height increment
+  0;    7;      6;      0;           0;   15;            m; Height above station
+  0;    7;      7;      0;       -1000;   17;            m; Height
+  0;    7;      8;      0;      -10000;   20;    m**2/s**2; Geopotential
+  0;    7;      9;      0;       -1000;   17;          gpm; Geopotential height
+  0;    7;     21;      2;       -9000;   15;          deg; Elevation
+  0;    7;     22;      2;       -9000;   15;          deg; Solar elevation
+  0;    7;     24;      2;       -9000;   15;          deg; Satellite zenith angle
+  0;    7;     25;      2;       -9000;   15;          deg; Solar zenith angle
+  0;    7;     61;      2;           0;   14;            m; Depth below land surface
+  0;    7;     62;      1;           0;   17;            m; Depth below sea/water surface
+  0;    7;     64;      0;           0;    4;            m; Height above station (sensor height artificially corrected)
+  0;    7;     70;      0;           0;   10;            m; Drogue depth
+
+  0;    8;      1;      0;           0;    7;   Flag_Table; Vertical sounding significance
+  0;    8;      2;      0;           0;    6;   Code_Table; Vertical significance (surface observations)
+  0;    8;      3;      0;           0;    6;   Code_Table; Vertical significance (satellite observations)
+  0;    8;      4;      0;           0;    3;   Code_Table; Phase of aircraft flight
+  0;    8;      5;      0;           0;    4;   Code_Table; Meteorological attribute significance
+  0;    8;      6;      0;           0;    9;   Flag_Table; Ozone vertical sounding significance
+  0;    8;      7;      0;           0;    4;   Code_Table; Dimensional significance
+  0;    8;      8;      0;           0;    9;   Flag_Table; Radiation vertical sounding significance
+  0;    8;     11;      0;           0;    6;   Code_Table; Meteorological feature
+  0;    8;     12;      0;           0;    2;   Code_Table; land/sea qualifier
+  0;    8;     13;      0;           0;    2;   Code_Table; Day/night qualifier
+  0;    8;     14;      0;           0;    4;   Code_Table; Qualification for runway visual range
+  0;    8;     16;      0;           0;    3;   Code_Table; Change indicator of a trend-type forecast or an aerodrome forecast
+  0;    8;     17;      0;           0;    2;   Code_Table; Qualifier of the time when the forecast change is expected
+  0;    8;     18;      0;           0;   17;   Flag_Table; SEAWINDS land/ice surface type
+  0;    8;     20;      0;           0;   16;      Numeric; Total number of missing entities (with respect to accumulation or average)
+  0;    8;     21;      0;           0;    5;   Code_Table; Time significance
+  0;    8;     22;      0;           0;   16;      Numeric; Total number (with respect to accumulation or average)
+  0;    8;     23;      0;           0;    6;   Code_Table; First order statistics
+  0;    8;     24;      0;           0;    6;   Code_Table; Difference statistics
+  0;    8;     25;      0;           0;    4;   Code_Table; Time difference qualifier
+  0;    8;     30;      0;           0;   13;      Numeric; Manual on Codes Volume I.1 Section C table identifier
+  0;    8;     31;      0;           0;    8;      Numeric; Data category CREX table A
+  0;    8;     35;      0;           0;    3;   Code_Table; Type of monitoring exercise
+  0;    8;     36;      0;           0;    3;   Code_Table; Type of center or station performing monitoring
+  0;    8;     51;      0;           0;    3;   Code_Table; Qualifier for number of missing values in calculation of statistic
+  0;    8;     52;      0;           0;    5;   Code_Table; Condition for which number of days of occurrence follows
+  0;    8;     53;      0;           0;    2;   Code_Table; Day of occurance qualifier
+  0;    8;     60;      0;           0;    4;   Code_Table; Sample scanning mode significance
+  0;    8;     70;      0;           0;    4;   Code_Table; TOVS/ATOVS product qualifier
+  0;    8;     72;      0;           0;    3;   Code_table; Pixel(s) type
+
+  0;   10;      1;      0;        -400;   15;            m; Height of land surface
+  0;   10;      2;     -1;         -40;   16;            m; Height
+  0;   10;      3;     -1;        -400;   17;    m**2/s**2; Geopotential
+  0;   10;      4;     -1;           0;   14;           Pa; Pressure
+  0;   10;      7;      0;       -1000;   17;            m; Height
+  0;   10;      8;      0;      -10000;   20;    m**2/s**2; Geopotential
+  0;   10;      9;      0;       -1000;   17;          gpm; Geopotential height
+  0;   10;     10;     -1;           0;   14;           Pa; Minimum pressure reduced to mean sea level
+  0;   10;     11;     -1;           0;   14;           Pa; Maximum pressure reduced to mean sea level
+  0;   10;     31;      2; -1073741824;   31;            m; In direction of the North Pole, distance from the Earth's centre
+  0;   10;     40;      0;           0;   10;      Numeric; Number of retrieved layer
+  0;   10;     50;      2;           0;   16;            m; Standard deviation altitude
+  0;   10;     51;     -1;           0;   14;           Pa; Pressure reduced to mean sea level
+  0;   10;     52;     -1;           0;   14;           Pa; Altimeter setting (QNH)
+  0;   10;     60;     -1;       -1024;   11;           Pa; Pressure change
+  0;   10;     61;     -1;        -500;   10;           Pa; 3 hour pressure change
+  0;   10;     62;     -1;       -1000;   11;           Pa; 24 hour pressure change
+  0;   10;     63;      0;           0;    4;   Code_Table; Characteristic of pressure tendency
+  0;   10;     70;      0;        -400;   16;            m; Indicated aircraft altitude
+  0;   11;      1;      0;           0;    9;     deg_true; Wind direction
+  0;   11;      2;      1;           0;   12;          m/s; Wind speed
+  0;   11;      3;      1;       -4096;   13;          m/s; U-component
+  0;   11;      4;      1;       -4096;   13;          m/s; V-component
+  0;   11;      5;      1;        -512;   10;         Pa/s; W-component
+  0;   11;      6;      2;       -4096;   13;          m/s; W-component
+  0;   11;     10;      0;           0;    9;          deg; true	Wind direction associated with wind speed which follows
+  0;   11;     11;      0;           0;    9;     deg_true; Wind direction at 10 m
+  0;   11;     12;      1;           0;   12;          m/s; Wind speed at 10 m
+  0;   11;     13;      0;           0;    9;     deg_true; Wind direction at 5 m
+  0;   11;     14;      1;           0;   12;          m/s; Wind speed at 5 m
+  0;   11;     16;      0;           0;    9;     deg_true; Extreme counterclockwise wind direction of a variable wind
+  0;   11;     17;      0;           0;    9;     deg_true; Extreme clockwise wind direction of a variable wind
+  0;   11;     19;      0;           0;    7;      Percent; Steadiness of wind
+  0;   11;     21;      9;      -65536;   17;          1/s; Relative vorticity
+  0;   11;     22;      9;      -65536;   17;          1/s; Divergence
+  0;   11;     23;     -2;      -65536;   17;       m**2/s; Velocity potential
+  0;   11;     31;      0;           0;    4;   Code_Table; Degree of turbulence
+  0;   11;     32;     -1;         -40;   16;            m; Height of base of turbulence
+  0;   11;     33;     -1;         -40;   16;            m; Height of top of turbulence
+  0;   11;     34;      1;       -1024;   11;          m/s; Vertical gust velocity
+  0;   11;     35;      2;       -8192;   14;       m/s**2; Vertical gust acceleration
+  0;   11;     36;      1;           0;   10;          m/s; Maximum derived equivalent vertical gust speed
+  0;   11;     37;      0;           0;    6;   Code_Table; Turbulence Index
+  0;   11;     38;      0;           0;    5;   Code_Table; Time of occurrence of Peak Eddy Dissipation Rate
+  0;   11;     40;      1;           0;   12;          m/s; Maximum wind speed (mean wind)
+  0;   11;     41;      1;           0;   12;          m/s; Maximum wind speed (gusts)
+  0;   11;     42;      1;           0;   12;          m/s; Maximum wind speed (10 minute mean wind)
+  0;   11;     43;      0;           0;    9;     deg_true; Maximum wind gust direction
+  0;   11;     44;      0;           0;    9;     deg_true; Mean wind direction for surface - 1500m (5000 feet)
+  0;   11;     45;      1;           0;   12;          m/s; Mean wind speed for surface - 1500m (5000 feet)
+  0;   11;     46;      1;           0;   12;          m/s; Maximum instantaneous wind speed
+  0;   11;     47;      1;           0;   12;          m/s; Maximum instantaneous wind speed over 10 minutes
+  0;   11;     49;      0;           0;    9;     deg_true; Standard deviation of wind direction
+  0;   11;     50;      1;           0;   12;          m/s; Standard deviation horizontal wind speed
+  0;   11;     51;      1;           0;    8;          m/s; Standard deviation vertical wind speed
+  0;   11;     52;      2;           0;   13;          m/s; Formal uncertainty in wind speed
+  0;   11;     53;      2;           0;   15;          deg; true	Formal uncertainty in wind direction
+  0;   11;     61;      1;           0;   12;          m/s; Absolute wind shear in 1 kilometer layer below
+  0;   11;     62;      1;           0;   12;          m/s; Absolute wind shear in1 kilometer layer above
+  0;   11;     70;      0;           0;   32;    CCITT_IA5; Designator of the runway affected by wind shear
+  0;   11;     71;      3;        -128;   14;    m**2/s**2; Turbulent vertical momentum flux
+  0;   11;     72;      3;        -128;   11;            K; m/s		Turbulent vertical buoyancy flux
+  0;   11;     73;      2;       -1024;   13;    m**2/s**2; Turbulent kinetic energy
+  0;   11;     74;      2;       -1024;   10;    m**2/s**2; Dissipation energy
+  0;   11;     75;      2;           0;    8;   m**(2/3)/s; Mean turbulence intensity
+  0;   11;     76;      2;           0;    8;   m**(2/3)/s; Peak turbulence intensity
+  0;   11;     81;      2;           0;   16;          deg; true	Model wind direction at 10m
+  0;   11;     82;      2;           0;   14;          m/s; Model wind speed at 10 m
+
+  0;   12;      1;      1;           0;   12;        deg_K; Temperature/dry bulb temperature
+  0;   12;      2;      1;           0;   12;        deg_K; Wet bulb temperature
+  0;   12;      3;      1;           0;   12;        deg_K; Dewpoint temperature
+  0;   12;      4;      1;           0;   12;        deg_K; Dry bulb temperature at 2 meters
+  0;   12;      5;      1;           0;   12;        deg_K; Wet bulb temperature at 2 meters
+  0;   12;      6;      1;           0;   12;        deg_K; Dewpoint temperature at 2 meters
+  0;   12;      7;      1;           0;   12;        deg_K; Virtual temperature
+  0;   12;     11;      1;           0;   12;        deg_K; Maximum temperature
+  0;   12;     12;      1;           0;   12;        deg_K; Minimum temperature
+  0;   12;     13;      1;           0;   12;        deg_K; Ground minimum temperature past 12 hours
+  0;   12;     14;      1;           0;   12;        deg_K; Maximum temperature at 2 meters, past 12 hours
+  0;   12;     15;      1;           0;   12;        deg_K; Minimum temperature at 2 meters, past 12 hours
+  0;   12;     16;      1;           0;   12;        deg_K; Maximum temperature at 2 meters, past 24 hours
+  0;   12;     17;      1;           0;   12;        deg_K; Minimum temperature at 2 meters, past 24 hours
+  0;   12;     21;      2;           0;   16;          deg; K		Maximum temperature at 2m
+  0;   12;     22;      2;           0;   16;          deg; K		Minimum temperature at 2m
+  0;   12;     30;      1;           0;   12;        deg_K; Soil temperature
+  0;   12;     51;      1;           0;   10;        deg_K; Standard deviation of temperature
+  0;   12;     52;      1;           0;   12;        deg_K; Highest daily mean temperature
+  0;   12;     53;      1;           0;   12;        deg_K; Lowest daily mean temperature
+  0;   12;     61;      1;           0;   12;        deg_K; Skin temperature
+  0;   12;     62;      1;           0;   12;        deg_K; Equivalent black body temperature
+  0;   12;     63;      1;           0;   12;        deg_K; Brightness temperature
+  0;   12;     64;      1;           0;   12;        deg_K; Instrument temperature
+  0;   12;     65;      1;           0;   12;          deg; K		Standard deviation brightness temperature
+  0;   12;     71;      1;           0;   12;        deg_K; Coldest cluster temperature
+  0;   12;     72;      6;           0;   31;    W/m**2/sr; Radiance
+  0;   12;     75;     -3;           0;   16;            W; m-3 sr-1	Spectral radiance
+  0;   12;     76;      3;           0;   16;            W; m-2 sr-1	Radiance
+  0;   12;    101;      2;           0;   16;        deg_K; Temperature/dry-bulb temperature
+  0;   12;    102;      2;           0;   16;        deg_K; Wet-bulb temperature
+  0;   12;    103;      2;           0;   16;        deg_K; Dew-point temperature
+  0;   12;    104;      2;           0;   16;        deg_K; Dry-bulb temperature at 2m
+  0;   12;    105;      2;           0;   16;        deg_K; Web-bulb temperature at 2m
+  0;   12;    106;      2;           0;   16;        deg_K; Dew-point temperature at 2m
+  0;   12;    107;      2;           0;   16;        deg_K; Virtual temperature
+  0;   12;    111;      2;           0;   16;        deg_K; Maximum temperature, at height and over period specified
+  0;   12;    112;      2;           0;   16;        deg_K; Minimum temperature, at height and over period specified
+  0;   12;    113;      2;           0;   16;        deg_K; Ground minimum temperature, past 12 hours
+  0;   12;    114;      2;           0;   16;        deg_K; Maximum temperature at 2m, past 12 hours
+  0;   12;    115;      2;           0;   16;        deg_K; Minimum temperature at 2m, past 12 hours
+  0;   12;    116;      2;           0;   16;        deg_K; Maximum temperature at 2m, past 24 hours
+  0;   12;    117;      2;           0;   16;        deg_K; Minimum temperature at 2m, past 24 hours
+  0;   12;    130;      2;           0;   16;        deg_K; Soil temperature
+  0;   12;    152;      2;           0;   16;        deg_K; Highest daily mean temperature
+  0;   12;    153;      2;           0;   16;        deg_K; Lowest daily mean temperature
+  0;   12;    161;      2;           0;   16;        deg_K; Skin temperature
+  0;   12;    162;      2;           0;   16;        deg_K; Equivalent black body temperature
+  0;   12;    163;      2;           0;   16;        deg_K; Brightness temperature
+  0;   12;    164;      2;           0;   16;        deg_K; Instrument temperature
+  0;   12;    171;      2;           0;   16;        deg_K; Coldest cluster temperature
+  0;   12;    193;      1;           0;   12;        deg_K; Coldest Cluster Temperature
+
+
+  0;   13;      1;      5;           0;   14;        kg/kg; Specific humidity
+  0;   13;      2;      5;           0;   14;        kg/kg; Mixing ratio
+  0;   13;      3;      0;           0;    7;      percent; Relative humidity
+  0;   13;      4;     -1;           0;   10;           Pa; Vapor pressure
+  0;   13;      5;      3;           0;    7;      kg/m**3; Vapor density
+  0;   13;      6;     -1;         -40;   16;            m; Mixing heights
+  0;   13;      7;      0;           0;    7;      percent; Minimum relative humidity
+  0;   13;      8;      0;           0;    7;      percent; Maximum relative humidity
+  0;   13;     11;      1;          -1;   14;      kg/m**2; Total precipitation/total water equivalent
+  0;   13;     12;      2;          -2;   12;            m; Depth of fresh snow
+  0;   13;     13;      2;          -2;   16;            m; Total snow depth
+  0;   13;     14;      4;           0;   12;    kg/m**2/s; Rainfall/water equivalent of snow (average rate)
+  0;   13;     15;      7;           0;   12;          m/s; Snowfall (averaged rate)
+  0;   13;     16;      0;           0;    7;      kg/m**2; Precipitable water
+  0;   13;     19;      1;          -1;   14;      kg/m**2; Total precipitation past 1 hour
+  0;   13;     20;      1;          -1;   14;      kg/m**2; Total precipitation past 3 hours
+  0;   13;     21;      1;          -1;   14;      kg/m**2; Total precipitation past 6 hours
+  0;   13;     22;      1;          -1;   14;      kg/m**2; Total precipitation past 12 hours
+  0;   13;     23;      1;          -1;   14;      kg/m**2; Total precipitation past 24 hours
+  0;   13;     31;      0;           0;    7;      kg/m**2; Evapotranspiration
+  0;   13;     32;      1;           0;    8;      kg/m**2; Evaporation/evapotranspiration
+  0;   13;     33;      1;           0;   10;      kg/m**2; Evaporation/evapotranspiration
+  0;   13;     38;      0;           0;    2;   Code_Table; Superadiabatic indicator
+  0;   13;     39;      0;           0;    3;   Code_Table; Terrain type (ice/snow)
+  0;   13;     41;      0;           0;    4;   Code_Table; Pasquill-Gifford stability category
+  0;   13;     42;      0;         -20;    6;        deg_K; Parcel lifted index (to 500 hPa)
+  0;   13;     43;      0;         -20;    6;        deg_K; Best lifted index (to 500 hPa)
+  0;   13;     51;      0;           0;    4;   Code_Table; Frequency group, precipition
+  0;   13;     52;      1;          -1;   14;      kg/m**2; Highest daily amount of precipition
+  0;   13;     55;      4;           0;    8;    KG/M**2*S; INTENSITY OF PRECIPITATION
+  0;   13;     60;      1;         -10;   17;           kg; m-2		Total accumulated precipitation
+  0;   13;     71;      2;           0;   14;            m; Upstream water level
+  0;   13;     72;      2;           0;   14;            m; Downstream water level
+  0;   13;     73;      2;           0;   14;            m; Maximum water level
+  0;   13;     80;      1;           0;   10;           pH; unit		Water pH
+  0;   13;     81;      3;           0;   14;      Siemens; m-1	Water conductivity
+  0;   13;     82;      1;           0;   12;          deg; K		Water temperature
+  0;   13;     83;      6;           0;   15;           Kg; m-3		Dissolved oxygen
+  0;   13;     84;      0;           0;   14;        Lumen; Turbidity
+  0;   13;     85;      3;           0;   14;            V; Oxydation Reduction Potential (ORP)
+
+  0;   14;      1;     -3;       -2048;   12;  Joules/m**2; Longwave radiation, integrated over 24 hours
+  0;   14;      2;     -3;       -2048;   12;  Joules/m**2; Longwave radiation, integrated over period specified
+  0;   14;      3;     -3;       -2048;   12;  Joules/m**2; Shortwave radiation, integrated over 24 hours
+  0;   14;      4;     -3;       -2048;   12;  Joules/m**2; Shortwave radiation, integrated over period specified
+  0;   14;     11;     -3;       -2048;   12;  Joules/m**2; Net longwave radiation, integrated over 24 hours
+  0;   14;     12;     -3;       -2048;   12;  Joules/m**2; Net longwave radiation, integrated over period specified
+  0;   14;     13;     -3;       -2048;   12;  Joules/m**2; Net shortwave radiation, integrated over 24 hours
+  0;   14;     14;     -3;       -2048;   12;  Joules/m**2; Net shortwave radiation, integrated over period specified
+  0;   14;     15;     -4;      -16384;   15;  Joules/m**2; Net radiation, integrated over 24 hours
+  0;   14;     16;     -4;      -16384;   15;  Joules/m**2; Net radiation, integrated over period specified
+  0;   14;     17;     -3;       -2048;   12;       W/m**2; Instantaneous long wave radiation
+  0;   14;     18;     -3;       -2048;   12;       W/m**2; Instantaneous short wave radiation
+  0;   14;     19;      0;           0;    7;      percent; Surface albedo
+  0;   14;     20;     -4;           0;   15;  Joules/m**2; Global solar radiation, integrated over 24 hours
+  0;   14;     21;     -4;           0;   15;  Joules/m**2; Global radiation, integrated over period specified
+  0;   14;     22;     -4;           0;   15;  Joules/m**2; Diffuse solar radiation, integrated over 24 hours
+  0;   14;     23;     -4;           0;   15;  Joules/m**2; Diffuse solar radiation, integratedi over period specified
+  0;   14;     24;     -4;           0;   15;  Joules/m**2; Direct solar radiation, integrated over 24 hours
+  0;   14;     25;     -4;           0;   15;  Joules/m**2; Direct solar radiation, integrated over period specified
+  0;   14;     26;      0;           0;    7;      percent; Albedo at the top of clouds
+  0;   14;     27;      0;           0;    7;      percent; Albedo
+  0;   14;     28;     -2;           0;   16;       J/m**2; Global solar radiation (high accuracy, integrated over period specified
+  0;   14;     29;     -2;           0;   16;       J/m**2; Diffuse solar radiation (high accuracy, integrated over period specified
+  0;   14;     30;     -2;           0;   16;       J/m**2; Direct solar radiation (high accuracy, integrated over period specified
+  0;   14;     31;      0;           0;   11;          min; Total sunshine
+  0;   14;     32;      0;           0;   10;           hr; Total sunshine
+  0;   14;     33;      0;           0;    9;      percent; Total sunshine
+  0;   14;     34;      0;           0;   11;          min; Sunshine of period specified
+  0;   14;     42;      0;           0;    7;      percent; Bi-directional reflectance
+  0;   14;     45;      0;           0;   11; W/m**2/sr/cm; Channel radiance
+  0;   14;     51;     -3;           0;   14;       j/m**2; Direct solar radiation integrated over last hour
+
+  0;   15;      1;      0;           0;   10;       Dobson; units	Ozone
+  0;   15;      2;      2;           0;   10;      Numeric; Air mass (slant path at 22km)
+  0;   15;      3;      4;           0;    9;       Pascal; Measured ozone partial pressure
+  0;   15;      4;      3;           0;   11;      Numeric; Ozone sounding correction factor
+  0;   15;      5;      0;           0;   10;           DU; Ozone p
+  0;   15;     11;      3;       14000;   13;  log(1/m**2); Log 10 of integrated electron density
+  0;   15;     15;      0;           0;   31;      Numeric; Maximum image spectral composition before normalization
+  0;   15;     20;      8;           0;   21;      kg/m**2; Integrated Ozone density
+
+  0;   19;      1;      0;           0;    6;   Code_Table; Type of synoptic features
+  0;   19;      2;     -2;           0;   12;            m; Effective radius of feature
+  0;   19;      3;      0;           0;    8;          m/s; Wind speed threshold
+  0;   19;      4;     -2;           0;   12;            m; Effective radius of feature with respect to wind speeds above threshold
+  0;   19;      5;      0;           0;    9;     deg_true; Direction of motion of features
+  0;   19;      6;      2;           0;   14;          m/s; Speed of motion of features
+  0;   19;      7;     -3;           0;   12;            m; Effective radius of features
+  0;   19;      8;      0;           0;    3;   Code_Table; Vertical extent of circulation
+  0;   19;      9;     -3;           0;   12;            m; Effective radius with respect to wind speed above threshold (large storms)
+  0;   19;     10;      0;           0;    4;   Code_Table; Method for tracking the center of synoptic feature
+
+  0;   20;      1;     -1;           0;   13;            m; Horizontal visibility
+  0;   20;      2;     -1;           0;    7;            m; Vertical visibility
+  0;   20;      3;      0;           0;    9;   Code_Table; Present weather
+  0;   20;      4;      0;           0;    5;   Code_Table; Past weather (1)
+  0;   20;      5;      0;           0;    5;   Code_Table; Past weather (2)
+  0;   20;      8;      0;           0;    5;   Code_Table; Cloud distribution for aviation
+  0;   20;      9;      0;           0;    4;   Code_Table; General Weather Indicator
+  0;   20;     10;      0;           0;    7;      percent; Cloud cover (total)
+  0;   20;     11;      0;           0;    4;   Code_Table; Cloud amount
+  0;   20;     12;      0;           0;    6;   Code_Table; Cloud type
+  0;   20;     13;     -1;         -40;   11;            m; Height of base of cloud
+  0;   20;     14;     -1;         -40;   11;            m; Height of top of cloud
+  0;   20;     15;     -1;           0;   14;           Pa; Pressure at the base of cloud
+  0;   20;     16;     -1;           0;   14;           Pa; Pressure at the top of cloud
+  0;   20;     17;      0;           0;    4;   Code_Table; Cloud top description
+  0;   20;     18;      0;           0;    2;   Code_Table; Tendency of runway visual range
+  0;   20;     19;      0;           0;   72;    CCITT_IA5; Significant present or forecast weather
+  0;   20;     20;      0;           0;   32;    CCITT_IA5; Significant recent weather phenomena
+  0;   20;     31;      2;           0;    7;            m; Ice deposit (thickness)
+  0;   20;     32;      0;           0;    3;   Code_Table; Rate of ice accretion
+  0;   20;     33;      0;           0;    4;   Flag_Table; Cause of ice accretion
+  0;   20;     34;      0;           0;    5;   Code_Table; Sea ice concentration
+  0;   20;     35;      0;           0;    4;   Code_Table; Amount and type of ice
+  0;   20;     36;      0;           0;    5;   Code_Table; Ice situation
+  0;   20;     37;      0;           0;    5;   Code_Table; Ice development
+  0;   20;     38;      0;           0;   12;     deg_true; Bearing of ice edge
+  0;   20;     39;     -1;           0;   13;            m; Ice distance
+  0;   20;     41;      0;           0;    4;   Code_Table; Airframe icing
+  0;   20;     51;      0;           0;    7;      percent; Amount of low clouds
+  0;   20;     52;      0;           0;    7;      percent; Amount of middle clouds
+  0;   20;     53;      0;           0;    7;      percent; Amount of high clouds
+  0;   20;     61;      0;           0;   12;            m; Runway visual range (RVR)
+  0;   20;     62;      0;           0;    5;   Code_Table; State of the ground(with or without snow)
+  0;   20;     63;      0;           0;   10;   Code_Table; Special phenomena
+  0;   20;     70;      0;           0;    7;      Numeric; Minimum number of atmospherics
+  0;   20;     71;      0;           0;    4;   Code_Table; Accuracy of fix and rate of atmospherics
+  0;   20;     81;      0;           0;    7;      percent; Cloud amount in segment
+  0;   20;     82;      0;           0;    7;      percent; Amount segment cloud free
+  0;   20;     90;      0;           0;    4;   Code_Table; Special clouds
+
+  0;   21;      1;      0;         -64;    7;           dB; Horizontal reflectivity
+  0;   21;      2;      0;         -64;    7;           dB; Vertical reflectivity
+  0;   21;      3;      1;          -5;    7;           dB; Differential reflectivity
+  0;   21;      5;      0;         -65;    6;           dB; Circular depolarization ratio
+  0;   21;      6;      0;         -65;    6;           dB; Circular depolarization ratio
+  0;   21;     11;      0;        -128;    8;          m/s; Doppler mean velocity in X direction
+  0;   21;     12;      0;        -128;    8;          m/s; Doppler mean velocity in Y direction
+  0;   21;     13;      0;        -128;    8;          m/s; Doppler mean velocity in Z direction
+  0;   21;     14;      1;       -4096;   13;          m/s; Doppler mean velocity (radiational)
+  0;   21;     17;      1;           0;    8;          m/s; Doppler velocity spectral width
+  0;   21;     21;     -3;           0;    4;            m; Echo tops
+  0;   21;     30;      0;         -32;    8;           dB; Signal to noise ratio
+  0;   21;     31;      0;           0;    7;      kg/m**2; Vertical integrated liquid water content
+  0;   21;     36;      7;           0;   12;          m/s; Radar rainfall intensity
+  0;   21;     41;     -2;           0;    8;            m; Bright band height
+  0;   21;     51;      0;        -256;    8;           dB; Signal power above 1 MW
+  0;   21;     62;      2;       -5000;   13;     Decibels; Backscatter
+  0;   21;     63;      1;           0;   10;      Percent; Radiometric resolution (noise value)
+  0;   21;     64;      0;           0;    8;      Numeric; Clutter noise estimate
+  0;   21;     65;      0;        -127;    8;      Numeric; Missing packet counter
+  0;   21;     66;      0;           0;   12;   Flag_Table; Wave scatterometer product confidence
+  0;   21;     67;      0;           0;   13;   Flag_Table; Wind product confidence data
+  0;   21;     68;      0;           0;    8;   Flag_Table; Radar altimeter product confidence data
+  0;   21;     69;      0;           0;   10;   Flag_Table; SST product confidence data
+  0;   21;     70;      0;           0;   23;   Flag_Table; SST product confidence data (SADIST-2)
+  0;   21;     71;      0;           0;   16;      Numeric; Peakiness
+  0;   21;     72;      0;           0;    4;   Flag_Table; Satellite altimeter calibration status
+  0;   21;     73;      0;           0;    9;   Flag_Table; Satellite altimeter instrument mode
+  0;   21;     75;      0;           0;    8;      Numeric; Spectral intensity
+  0;   21;     76;      0;           0;    3;   Code_Table; Representation of intensities
+  0;   21;     77;      3;           0;   14;            m; Altitude correction (ionosphere)
+  0;   21;     78;      3;           0;    9;            m; Altitude correction (dry troposphere)
+  0;   21;     79;      3;        2000;   10;            m; Altitude correction (wet troposphere)
+  0;   21;     80;      3;           0;   11;            m; Altitude correction (calibration constant)
+  0;   21;     81;      3;           0;   10;            m; Open loop correction (height-time loop)
+  0;   21;     82;      3;       -3000;   14;     Decibels; Open loop correction (auto gain control)
+  0;   21;     85;      0;       -3000;    4;      Numeric; ATSR sea surface temperature across-track band number
+  0;   21;     91;      0;        -100;    8;           dB; Radar signal Doppler spectrum 0th moment
+  0;   21;     92;      0;        -100;    8;           dB; RASS signal Doppler spectrum 0th moment, referring to RASS signal
+  0;   21;    101;      0;           0;    3;      Numeric; Number of vector ambiguities
+  0;   21;    102;      0;           0;    3;      Numeric; Index of selected wind vector
+  0;   21;    103;      0;           0;    5;      Numeric; Total number of sigma-0 measurements
+  0;   21;    104;      3;      -30000;   15;      Numeric; Likelihood computed for solution
+  0;   21;    105;      2;      -10000;   14;           dB; Normalized radar cross-section
+  0;   21;    106;      3;           0;   14;      Numeric; Kp variance coefficient (Alpha)
+  0;   21;    107;      8;           0;   16;      Numeric; Kp variance coefficient (Beta)
+  0;   21;    109;      0;           0;   17;         Flag; table	SEAWINDS wind vector cell quality
+  0;   21;    110;      0;           0;    6;      Numeric; Number of inner-beam Sigma-0 (forward of satellite)
+  0;   21;    111;      0;           0;    6;      Numeric; Number of outer-beam Sigma-0 (forward of satellite)
+  0;   21;    112;      0;           0;    6;      Numeric; Number of inner-beam Sigma-0 (aft of satellite)
+  0;   21;    113;      0;           0;    6;      Numeric; Number of outer-beam Sigma-0 (aft of satellite)
+  0;   21;    114;      3;     -140000;   18;           dB; Kp variance coefficent (Gamma)
+  0;   21;    115;      0;           0;   17;         Flag; table	SEAWINDS sigma-0 quality
+  0;   21;    116;      0;           0;   17;         Flag; table	SEAWINDS sigma-0 mode
+  0;   21;    117;      2;           0;   16;      Numeric; Sigma-0 variance quality control
+  0;   21;    118;      2;      -10000;   14;           dB; Attenuation correction on sigma-0
+  0;   21;    119;      0;           0;    6;         Code; table	Wind scatterometer geophysical model function
+  0;   21;    120;      3;           0;   10;      Numeric; Probability of rain
+  0;   21;    121;      0;           0;    8;      Numeric; SEAWINDS NOF* rain index
+  0;   21;    122;      2;      -10000;   14;           dB; Attenuation correction of sigma-0 (from tB)
+  0;   21;    123;      2;      -30000;   15;           dB; SEAWINDS normalized radar cross section
+
+
+  0;   22;      1;      0;           0;    9;     deg_true; Direction of waves
+  0;   22;      2;      0;           0;    9;     deg_true; Direction of wind waves
+  0;   22;      3;      0;           0;    9;     deg_true; Direction of swell waves
+  0;   22;      4;      0;           0;    9;     deg_true; Direction of current waves
+  0;   22;     11;      0;           0;    6;            s; Period of waves
+  0;   22;     12;      0;           0;    6;            s; Period of wind waves
+  0;   22;     13;      0;           0;    6;            s; Period of swell waves
+  0;   22;     21;      1;           0;   10;            m; Height of waves
+  0;   22;     22;      1;           0;   10;            m; Height of wind waves
+  0;   22;     23;      1;           0;   10;            m; Height of swell waves
+  0;   22;     25;      2;           0;   10;            m; Standard deviation wave height
+  0;   22;     26;      2;           0;   10;            m; Standard deviation of significant wave height
+  0;   22;     31;      2;           0;   13;          m/s; Speed of current
+  0;   22;     35;      2;           0;   14;            m; Tidal elevation with respect to local chart datum
+  0;   22;     36;      2;           0;   14;            m; Meteorological residual tida elevation (surge or offset)
+  0;   22;     37;      3;      -10000;   15;            m; Tidal elevation with respect to national chart datum
+  0;   22;     38;      3;      -10000;   15;            m; Tidal elevation with respect to local chart datum
+  0;   22;     39;      3;       -5000;   12;            m; Meteorological residual tidal elevation (surge or offset)
+  0;   22;     40;      3;       -5000;   14;            m; Meteorological residual tidal elevation (surge or offset)
+  0;   22;     41;      1;           0;   12;        deg_K; Sea surface temperature (15 day running mean)
+  0;   22;     42;      1;           0;   12;        deg_K; Sea/water temperature
+  0;   22;     43;      2;           0;   15;        deg_K; Sea/water temperature
+  0;   22;     44;      1;           0;   14;          m/s; Sound velocity
+  0;   22;     50;      2;           0;    8;            K; Standard deviation sea surface temperature
+  0;   22;     61;      0;           0;    4;   Code_Table; State of sea
+  0;   22;     62;      2;           0;   14;          ppt; Salinity
+  0;   22;     63;      0;           0;   14;            m; Total water depth
+  0;   22;     67;      0;           0;   10;   Code_Table; Instrument type for water temperature profile measurement
+  0;   22;     68;      0;           0;    7;   Code_Table; Water temperature profile recorder types
+  0;   22;     70;      2;           0;   13;            m; Significant wave height
+  0;   22;     71;      1;           0;    9;            s; Spectral peak wave period
+  0;   22;     72;      0;           0;   13;            m; Spectral peak wave length
+  0;   22;     73;      2;           0;   13;            m; Maximum wave height
+  0;   22;     74;      1;           0;    9;            s; Average wave period
+  0;   22;     75;      0;           0;   13;            m; Average wave length
+  0;   22;     76;      0;           0;    9;  Degree_True; Direction from which dominant waves are coming
+  0;   22;     77;      0;           0;    9;       Degree; Directional spred of dominant wave
+  0;   22;     78;      0;           0;   12;            s; Duration of wave record
+  0;   22;     79;      0;           0;   16;            m; Length of wave record
+  0;   22;     80;      3;           0;   10;           Hz; Waveband central frequency
+  0;   22;     81;      5;           0;   13;        m**-1; Waveband central wave number
+  0;   22;     82;      2;           0;   20;       m**2/s; Maximum non-directional spectral wave density
+  0;   22;     83;      2;           0;   20;         m**3; Maximum non-directional spectral wave number
+  0;   22;     84;      0;           0;    7;      Numeric; Band containing maximum non-directional spectral wave density
+  0;   22;     85;      0;           0;    7;      Numeric; Spectral wave density ratio
+  0;   22;     86;      0;           0;    9;  Degree_True; Mean direction from which waves are coming
+  0;   22;     87;      0;           0;    9;  Degree_True; Principal direction from which waves are coming
+  0;   22;     88;      2;           0;    7;      Numeric; First normalized polar coordinate from Fourier coefficients
+  0;   22;     89;      2;           0;    7;      Numeric; Second normalized polar coordinate from Fourier coefficients
+  0;   22;     90;      2;           0;   20;       m**2/s; Non-directional spectral estimate by wave frequency
+  0;   22;     91;      2;           0;   20;         m**3; Non-directional spectral estimate by wave number
+  0;   22;     92;      2;           0;   20; m**2/rad**-1/s; Directional spectral estimate by wave frequency
+  0;   22;     93;      2;           0;   20;         m**4; Directional spectral estimate by wave number
+  0;   22;     94;      0;           0;    7;      Numeric; Total number of wave bands
+  0;   22;     95;      0;           0;    8;       Degree; Directional spread of individual waves
+  0;   22;     96;      3;           0;    4;        s**-1; Spectral band width
+  0;   22;     97;      0;           0;   14;            m; Mean wavelength > 731 m of image spectrum at low wave numbers
+  0;   22;     98;      0;           0;   14;            m; Wavelength spread (wavelength > 731 m) at low wave numbers
+  0;   22;     99;      0;           0;    9;     deg_true; Mean direction at low wave numbers (wavelength > 731 m)
+  0;   22;    100;      0;           0;    9;       Degree; Direction spread at low wave numbers (wavelength > 731 m)
+  0;   22;    101;      0;           0;   31;     Numberic; Total energy (wavelength > 731 m) at low wave numbers
+  0;   22;    120;      0;           0;    5;   Code_Table; Tide station automated water level check
+  0;   22;    121;      0;           0;    5;   Code_Table; Tide station manual water level check
+  0;   22;    122;      0;           0;    5;   Code_Table; Tide station automated Meteorological data check
+  0;   22;    123;      0;           0;    5;   Code_Table; Tide station manual Meteorological data check
+  0;   22;    141;      2;           0;   15;   Code_Table; Sea-surface temperature (15-day running mean)
+
+  0;   23;      1;      0;           0;    3;   Code_Table; Accident early notification - article applicable
+  0;   23;      2;      0;           0;    5;   Code_Table; Activity or facility involved in incident
+  0;   23;      3;      0;           0;    3;   Code_Table; Type of release
+  0;   23;      4;      0;           0;    3;   Code_Table; Countermeasures taken near border
+  0;   23;      5;      0;           0;    2;   Code_Table; Cause of incident
+  0;   23;      6;      0;           0;    3;   Code_Table; Incident situation
+  0;   23;      7;      0;           0;    3;   Code_Table; Characteristic of release
+  0;   23;      8;      0;           0;    2;   Code_Table; State of current release
+  0;   23;      9;      0;           0;    2;   Code_Table; State of expected release
+  0;   23;     16;      0;           0;    2;   Code_Table; Possibility of significant chemical toxic health effect
+  0;   23;     17;      6;           0;   20;       m**3/s; Flow discharge of major recipient
+  0;   23;     18;      0;           0;    3;   Code_Table; release behavior over time
+  0;   23;     19;      0;      -15000;   17;            m; Actual release height
+  0;   23;     21;      0;      -15000;   17;            m; Effective release height
+  0;   23;     22;      0;           0;   24;            m; Distance of relative point or site of incident
+  0;   23;     23;      1;           0;   12;          m/s; Main transport speed in atmosphere
+  0;   23;     24;      2;           0;   13;          m/s; Main transport speed in water
+  0;   23;     25;      2;           0;   13;          m/s; Main transport speed in ground water
+  0;   23;     27;      0;           0;    9;     deg_true; Main transport direction in atmosphere
+  0;   23;     28;      0;           0;    9;     deg_true; Main transport direction in water
+  0;   23;     29;      0;           0;    9;     deg_true; Main transport direction in ground water
+  0;   23;     31;      0;           0;    2;   Code_Table; Possibility that plume will encounter precipitation cwin state in which incident occurred
+  0;   23;     32;      0;           0;    2;   Code_Table; Plume will encounter ichange in wind direction and/or speed flag
+
+  0;   24;      1;    -11;           0;   28;           Bq; Estimate of radiatioactivity released up to specified time
+  0;   24;      2;    -11;           0;   28;           Bq; Estimated maximum potential release
+  0;   24;      3;      0;           0;    5;   Code_Table; Composition of release
+  0;   24;      4;      0;           0;   16;    CCITT_IA5; Element name
+  0;   24;      5;      0;           0;    9;      Numeric; Isotope mass
+  0;   24;     11;      2;           0;   32;          mSv; Dose
+  0;   24;     12;      2;           0;   32;          mSv; Trajectory dose (defined location and expected time of arrival)
+  0;   24;     13;      2;           0;   32;          mSv; Gamma dose in air along the main transport path (defined location and time period
+  0;   24;     21;      2;           0;   32;      Bq/m**3; Air concentration (named isotope type including gross beta)
+  0;   24;     22;      2;           0;   32;         Bq/l; Concentration in precipitation (of named isotope type)
+  0;   24;     23;      1;           0;   14;    pulse/sec; Pulse rate of beta radiation
+  0;   24;     24;      1;           0;   14;    pulse/sec; Pulse rate of beta radiation
+
+  0;   25;      1;     -1;           0;    6;            m; Range gate length
+  0;   25;      2;      0;           0;    4;      Numeric; Number of gates averaged
+  0;   25;      3;      0;           0;    8;      Numeric; Number of integrated pulses
+  0;   25;      4;      0;           0;    2;   Code_Table; Echo processing
+  0;   25;      5;      0;           0;    2;   Code_Table; Echo integration
+  0;   25;      6;      0;           0;    3;   Code_Table; Z to R conversion
+  0;   25;      7;      0;           0;   12;      Numeric; Z to R conversion factor
+  0;   25;      8;      2;           0;    9;      Numeric; Z to R conversion exponent
+  0;   25;      9;      0;           0;    4;   Flag_Table; Calibration method
+  0;   25;     10;      0;           0;    4;   Code_Table; Clutter treatment
+  0;   25;     11;      0;           0;    2;   Code_Table; Ground occultation correction (screening)
+  0;   25;     12;      0;           0;    2;   Code_Table; Range attenuation correction
+  0;   25;     13;      0;           0;    2;   Flag_Table; Bright band correction
+  0;   25;     14;      0;           0;   12;      Numeric; Azimuth clutter cut-off
+  0;   25;     15;      0;           0;    2;   Flag_Table; Radome attenuation correction
+  0;   25;     16;      5;           0;    6;         dB/m; Clear air attenuation correction
+  0;   25;     17;      0;           0;    2;   Flag_Table; Precipitation attenuation correction
+  0;   25;     18;      7;           0;    6;      Numeric; A to Z law for attenuation factor
+  0;   25;     19;      2;           0;    7;      Numeric; A to Z law for attenuation exponent
+  0;   25;     20;      0;           0;    2;   Code_Table; Mean speed estimation
+  0;   25;     21;      0;           0;    8;   Flag_Table; Wind computation enhancement
+  0;   25;     30;      0;           0;    2;   Code_Table; SST usage
+  0;   25;     32;      0;           0;    2;   Code_Table; NOAA wind profiler high/low mode data
+  0;   25;     33;      0;           0;    2;   Code_Table; NOAA wind profiler submode
+  0;   25;     34;      0;           0;    4;   Code_Table; NOAA wind profiler Q/C test results
+  0;   25;     40;      0;           0;    4;   Code_Table; CO2 wind product derivation
+  0;   25;     41;      0;           0;    2;   Code_Table; Moving platform direction reporting method
+  0;   25;     42;      0;           0;    2;   Code_Table; Moving platform speed reporting method
+  0;   25;     43;      4;           0;   15;            s; Wave sampling interval (time)
+  0;   25;     44;      2;           0;   14;            m; Wave sampling interval (space)
+  0;   25;     45;      0;           0;   21;   Flag_Table; HIRS channel combination
+  0;   25;     46;      0;           0;    5;   Flag_Table; MSU channel combination
+  0;   25;     47;      0;           0;    4;   Flag_Table; SSU channel combination
+  0;   25;     48;      0;           0;   16;   Flag_Table; AMSU-A channel combination
+  0;   25;     49;      0;           0;    6;   Flag_Table; AMSU-B channel combination
+  0;   25;     50;      0;           0;    7;   Flag_Table; AVHRR channel combination
+  0;   25;     51;      0;           0;   12;   Flag_Table; Observation quality
+  0;   25;     53;      0;           0;   12;   Flag_Table; Observation quality
+  0;   25;     60;      0;           0;   14;      Numeric; Software identification
+  0;   25;     70;      0;           0;    4;      Numeric; Major frame count
+  0;   25;     71;      0;           0;    5;      Numeric; Frame count
+  0;   25;     75;      0;           0;    5;      Numeric; Satellite antenna corrections version number
+  0;   25;     76;      8;           0;   30;        Log/m; Log-10 of (Temperature-radiance central wavenumber) for ATOVS
+  0;   25;     77;      5;     -100000;   18;      Numeric; Bandwidth correction coefficient 1 for ATOVS
+  0;   25;     78;      5;           0;   17;      Numeric; Bandwidth correction coefficient 2 for ATOVS
+  0;   25;     79;      4;           0;   24;       W/m**2; Albedo-radiance solar filtered irradiance for ATOVS
+  0;   25;     80;     10;           0;   14;            m; Albedo-radiance equivalent filter width for ATOVS
+  0;   25;     85;      0;           0;    7;      Numeric; Fraction of clear pixels in HIRS FOV
+  0;   25;     86;      0;           0;    2;         Code; table	Depth correction indicator
+  0;   25;     91;      3;      -18192;   13;           dB; Structure constant of the refraction index (cn2)
+  0;   25;     92;      2;       28000;   14;            m; s-1		Acoustic propagation velocity
+  0;   25;     93;      0;           0;    8;         Flag; table	RASS computation correction
+
+
+  0;   26;      1;      1;           0;   12;         Hour; Principal time of daily reading in UTC of maximum temperature
+  0;   26;      2;      1;           0;   12;         Hour; Principal time of daily reading in UTC of minimum temperature
+  0;   26;      3;      0;       -1440;   12;       Minute; Time difference
+  0;   26;     10;      0;           0;   26;   Flag_Table; Hours included
+
+  0;   27;      1;      5;    -9000000;   25;          deg; Latitude (high accuracy)
+  0;   27;      2;      2;       -9000;   15;          deg; Latitude (coarse accuracy)
+  0;   27;      3;      2;       -9000;   15;          deg; Alternate latitude
+  0;   27;     20;      0;           0;   16;      Numeric; Satellite locationon counter
+  0;   27;     21;      0;           0;   16;      Numeric; Satellite sub-locationon dimensions
+  0;   27;     31;      2; -1073741824;   31;            m; In direction of 0 degrees longitude, distance from the Earth's centre
+
+  0;   28;      1;      5;   -18000000;   26;          deg; Longitude (high accuracy)
+  0;   28;      2;      2;      -18000;   16;          deg; Longitude (coarse accuracy)
+  0;   28;      3;      2;      -18000;   16;          deg; Alternate longtiude
+  0;   28;     31;      2; -1073741824;   31;            m; In direction of 90 degrees East, distance from the Earth's centre
+
+  0;   29;      1;      0;           0;    3;   Code_Table; Projection type
+  0;   29;      2;      0;           0;    3;   Code_Table; Coordinate grid type
+
+  0;   30;      1;      0;           0;    4;      Numeric; Pixel value (4 bits)
+  0;   30;      2;      0;           0;    8;      Numeric; Pixel value (8 bits)
+  0;   30;      4;      0;           0;   16;      Numeric; Pixel value (16 bits)
+  0;   30;     21;      0;           0;   12;      Numeric; Number of pixels per row
+  0;   30;     22;      0;           0;   12;      Numeric; Number of pixels per column
+  0;   30;     31;      0;           0;    4;   Code_Table; Picture type
+  0;   30;     32;      0;           0;   16;   Flag_Table; Combined picture
+
+  0;   31;      0;      0;           0;    1;      Numeric; Short delayed descriptor replication factor
+  0;   31;      1;      0;           0;    8;      Numeric; Delayed descriptor replication factor
+  0;   31;      2;      0;           0;   16;      Numeric; Extended delayed descriptor replication factor
+  0;   31;     11;      0;           0;    8;      Numeric; Delayed descriptor and data repetion factor
+  0;   31;     12;      0;           0;   16;      Numeric; Extended delayed descriptor and data repitition factor
+  0;   31;     21;      0;           0;    6;   Code_Table; Associated field significance
+  0;   31;     31;      0;           0;    1;   Flag_Table; Data present indicator
+
+  0;   33;      2;      0;           0;    2;   Code_Table; Quality information
+  0;   33;      3;      0;           0;    3;   Code_Table; Quality information
+  0;   33;      7;      0;           0;    7;      Percent; Per cent confidence
+  0;   33;     20;      0;           0;    3;   Code_Table; Quality control indication of following value
+  0;   33;     21;      0;           0;    2;   Code_Table; Quality of following value
+  0;   33;     22;      0;           0;    2;   Code_Table; Quality of buoy satellite transmission
+  0;   33;     23;      0;           0;    2;   Code_Table; Quality of buoy location
+  0;   33;     24;      0;           0;    4;   Code_Table; Station elevation quality mark (for mobile stations)
+  0;   33;     25;      0;           0;    3;   Code_Table; ACARS interpolated values
+  0;   33;     26;      0;           0;    6;   Code_Table; Mixing ratio quality
+  0;   33;     27;      0;           0;    3;   Code_Table; Location quality class (range of radius of 66% confidence)
+  0;   33;     30;      0;           0;   24;   Flag_Table; Scan line status flags for ATOVS
+  0;   33;     31;      0;           0;   24;   Flag_Table; Scan line quality flags for ATOVS
+  0;   33;     32;      0;           0;   24;   Flag_Table; Channel quality flags for ATOVS
+  0;   33;     33;      0;           0;   24;   Flag_Table; Field of view quality flags for ATOVS
+  0;   33;     35;      0;           0;    4;   Code_Table; Manual/automatic quality control
+  0;   33;     36;      0;           0;    7;      Percent; Nominal confidence threshold
+  0;   33;     37;      0;           0;   20;   Flag_Table; Wind correlation error
+  0;   33;     40;      0;           0;    7;      percent; Confidence interval
+  0;   33;     41;      0;           0;    2;   Code_Table; Attribute of following value
diff --git a/data/tables/B3L-160000-006001-B.txt b/data/tables/B3L-160000-006001-B.txt
new file mode 100644
index 0000000..ea6d1ce
--- /dev/null
+++ b/data/tables/B3L-160000-006001-B.txt
@@ -0,0 +1,817 @@
+#
+# BUFR Table B - Classification of Elements (edited by Mr. Spurlin last on April 12, 2001)
+#
+#						Data
+#F	X	Y	Scale	RefVal		Width	Units		Element Name
+0	0	1	0	0		24	CCITT_IA5	Table A: entry
+0	0	2	0	0		256	CCITT_IA5	Table A: data category description, line 1
+0	0	3	0	0		256	CCITT_IA5	Table A: data category description, line 2
+0	0	5	0	0		24	CCITT_IA5	BUFR edition number
+0	0	10	0	0		8	CCITT_IA5	F descriptor to be added or defined
+0	0	11	0	0		16	CCITT_IA5	X descriptor to be added or defined
+0	0	12	0	0		24	CCITT_IA5	Y descriptor to be added or defined
+0	0	13	0	0		256	CCITT_IA5	Element name, line 1
+0	0	14	0	0		256	CCITT_IA5	Element name, line 2
+0	0	15	0	0		192	CCITT_IA5	Units name
+0	0	16	0	0		8	CCITT_IA5	Units scale sign
+0	0	17	0	0		24	CCITT_IA5	Units scale
+0	0	18	0	0		8	CCITT_IA5	Units reference sign
+0	0	19	0	0		80	CCITT_IA5	Units reference value
+0	0	20	0	0		24	CCITT_IA5	Element data width
+0	0	30	0	0		48	CCITT_IA5	Descriptor defining sequence
+
+0	1	1	0	0		7	Numeric		WMO block number
+0	1	2	0	0		10	Numeric		WMO station number
+0	1	3	0	0		3	Code_Table	WMO region number
+0	1	4	0	0		3	Numeric		WMO region sub-area
+0	1	5	0	0		17	Numeric		Buoy/platform identifier
+0	1	6	0	0		64	CCITT_IA5	Aircraft identifier (flight number)
+0	1	7	0	0		10	Code_Table	Satellite identifier
+0	1	8	0	0		64	CCITT_IA5	Aircraft registration number (tail number)
+0	1	9	0	0		64	CCITT_IA5	Type of commerical aircraft
+0	1	10	0	0		64	CCITT_IA5	Stationary buoy platform identifier
+0	1	11	0	0		72	CCITT_IA5	Ship or mobile land station identifier
+0	1	12	0	0		9	deg_true	Direction of motion of moving observing platform
+0	1	13	0	0		10	m/s		Speed of motion of moving observing platform
+0	1	14	2	0		10	m/s		Platform drift speed (high precision)
+0	1	15	0	0		160	CCITT_IA5	Station or site name
+0	1	18	0	0		40	CCITT_IA5	Short station or site name
+0	1	20	0	0		4	Numeric		WMO Region sub-area
+0	1	21	0	0		14	Numeric		Synoptic feature identifier
+0	1	22	0	0		224	CCITT_IA5	Name of feature
+0	1	25	0	0		24	CCITT_IA5	Storm identifier
+0	1	26	0	0		64	CCITT_IA5	WMO storm name
+0	1	31	0	0		16	Code_Table	Identification of originating/generating center
+0	1	32	0	0		8	Code_Table	Generating application
+0	1	33	0	0		8	Code_Table	Identification of originating/generating center 
+0	1	34	0	0		8	Code_Table	Identification of originating/generating sub-center
+0	1	41	5	-1073741824	31	m/s		Absolute platform velocity - first component
+0	1	42	5	-1073741824	31	m/s		Absolute platform velocity - second component
+0	1	43	5	-1073741824	31	m/s		Absolute platform velocity - third component
+0	1	50	0	0		17	Numeric		Platform transmitter ID number
+0	1	51	0	0		96	CCITT_IA5	Platform transmitter ID nubmer
+0	1	60	0	0		64	CCITT_IA5	Aircraft reporting point (Beacon identifier)
+0	1	62	0	0		32	CCITT_IA5	Aircraft reporting point (Beacon idnetifier)
+0	1	63	0	0		64	CCITT_IA5	ICAO location indicator
+0	1	64	0	0		32	CCITT_IA5	Runway designator
+0	1	75	0	0		40	CCITT_IA5	Ride station identification
+
+0	2	1	0	0		2	Code_Table	Type of station
+0	2	2	0	0		4	Flag_Table	Type of instrumentation for wind measurement
+0	2	3	0	0		4	Code_Table	Type of measuring instrumentation used
+0	2	4	0	0		4	Code_Table	Type of instrumentation for evaporation measurement or type of crop for which evapotranspiration is reported
+0	2	5	2	0		7	deg_K		Precision of temperature observed
+0	2	11	0	0		8	Code_Table	Radiosonde type
+0	2	12	0	0		4	Code_Table	Radiosonde computational method
+0	2	13	0	0		4	Code_Table	Solar and infrared radiation correction
+0	2	14	0	0		7	Code_Table	Tracking technique/status of system
+0	2	15	0	0		4	Code_Table	Radiosonde completeness
+0	2	19	0	0		11	Code_Table	Satellite instruments
+0	2	20	0	0		9	Code_Table	Satellite classification
+0	2	21	0	0		9	Flag_Table	Satellite instrumentation data used in processing
+0	2	22	0	0		8	Flag_Table	Satellite data processing technique used
+0	2	23	0	0		4	Code_Table	Satellite derived wind computation method
+0	2	24	0	0		4	Code_Table	Integrated mean humidity computational method
+0	2	25	0	0		25	Flag_Table	Satellite channel(s) used in computation
+0	2	26	2	0		12	m		Cross track resolution
+0	2	27	2	0		12	m		Along track resolution
+0	2	28	0	0		18	m		Segment size at nadir in X direction
+0	2	29	0	0		18	m		Segment size at nadir in Y direction
+0	2	30	0	0		3	Code_Table	Method of current measurement
+0	2	31	0	0		5	Code_Table	Duration and time of current measurement
+0	2	32	0	0		2	Code_Table	Indicator for digitization
+0	2	33	0	0		3	Code_Table	Method of salinity/depth measurement
+0	2	34	0	0		5	Code_Table	Drogue type
+0	2	35	0	0		9	m		Cable length
+0	2	36	0	0		2	Code_Table	Buoy type
+0	2	37	0	0		3	Code_Table	Method of tidal observation
+0	2	38	0	0		4	Code_Table	Method of sea-surface temperature measurement
+0	2	39	0	0		3	Code_Table	Method of wet-buld temperature measurement
+0	2	40	0	0		4	Code_Table	Method of removing velocity and motion of platform from current
+0	2	41	0	0		6	Code_Table	Method for estimating reports related to synoptic features
+0	2	44	0	0		4	Code_Table	Inicator for method of calculating spectral wave data
+0	2	45	0	0		4	Code_Table	Indicator for type of platform
+0	2	46	0	0		4	Code_Table	Wave measurement instrumentation
+0	2	48	0	0		4	Code_Table	Satellite sensor indicator
+0	2	49	0	0		8	Flag_Table	Geostationary satellite data-processing technique used
+0	2	50	0	0		20	Flag_Table	Geostationary sounder satellite channels used
+0	2	51	0	0		4	Code_Table	Indicator ro specify observing method for extreme temperatures
+0	2	52	0	0		6	Flag_Table	Geostationary imager satellite channels used
+0	2	53	0	0		4	Code_Table	GOES-I/M  brightness temperature characteristics
+0	2	54	0	0		4	Code_Table	GOES-I/M  soundings parameter characteristics
+0	2	55	0	0		4	Code_Table	Geostationary soundings statistical parameters
+0	2	56	0	0		4	Code_Table	Geostationary soundings accuracy statistics
+0	2	57	0	0		4	Code_Table	Origin of first guess information for GOES-I/M soundings
+0	2	58	0	0		4	Code_Table	Valid times of first guess information for GOES-I/M soundings
+0	2	59	0	0		4	Code_Table	Origin of analysis information for GOES-I/M soundings
+0	2	60	0	0		4	Code_Table	Origin of surface information for GOES-I/M soundings
+0	2	61	0	0		3	Code_Table	Aircraft navigation system
+0	2	62	0	0		4	Code_Table	Type of aircraft data relay system
+0	2	63	2	-18000		16	deg		Aircraft roll angle
+0	2	64	0	0		2	Code_Table	Aircraft roll angle quality
+0	2	65	0	0		40	CCITT_IA5	ACARS ground receiving station
+0	2	70	0	0		4	Code_Table	Original specification of latitude/longitude
+0	2	91	0	4		10	A		Entry sensor 4/20 mA
+0	2	100	1	0		12	dB		Radar constant
+0	2	101	0	0		4	Code_Table	Type of antenna
+0	2	102	0	0		8	m		Antenna height above tower
+0	2	103	0	0		2	Flag_Table	Radome
+0	2	104	0	0		4	Code_Table	Antenna polarisation
+0	2	105	0	0		6	dB		Maximum antenna gain
+0	2	106	1	0		6	deg		3-dB bandwidth
+0	2	107	0	0		6	dB		Sidelobe suppression
+0	2	108	0	0		6	dB		Crosspol discrimination (on axis)
+0	2	109	2	0		12	deg/s		Antenna speed (azimuth)
+0	2	110	2	0		12	deg/s		Antenna speed (elevation)
+0	2	111	1	0		10	deg		Radar incidence angle
+0	2	112	1	0		12	deg		Radar azimuth angle
+0	2	113	0	0		4	Numeric		Number of azimuth looks
+0	2	114	0	0		15	m**2		Antenna effective surface area
+0	2	121	-8	0		7	Hz		Mean frequency
+0	2	122	-6	-128		8	Hz		Frequency agility range
+0	2	123	-4	0		7	W		Peak power
+0	2	124	-1	0		7	W		Average power
+0	2	125	-1	0		8	Hz		Pulse repetition frequency
+0	2	126	7	0		6	s		Pulse width
+0	2	127	-6	0		7	Hz		Receiver intermediate frequency
+0	2	128	-5	0		6	Hz		Intermediate frequency bandwidth
+0	2	129	0	-150		5	dB		Minimum detectable signal
+0	2	130	0	0		7	dB		Dynamic range
+0	2	131	0	0		2	Flag_Table	Sensitivity time control
+0	2	132	2	0		6	deg		Azimuth pointing accuracy
+0	2	133	2	0		6	deg		Elevation pointing accuracy
+0	2	134	2	0		16	deg		Antenna beam azimuth
+0	2	135	2	-9000		15	deg		Antenna elevation
+0	2	136	-3	0		16	m		Range processed by range attenuation correction
+0	2	140	0	0		9	deg		Satellite radar beam azimuth
+0	2	141	0	0		24	CCITT_IA5	Measurement type
+0	2	142	0	0		32	CCITT_IA5	Ozone instrument serial number/identification
+0	2	143	0	0		7	Code_Table	Ozone instrument type
+0	2	144	0	0		4	Code_Table	Light source type for Brewer spectrophotometer
+0	2	145	0	0		4	Code_Table	Wave length setting for Dobson instruments
+0	2	146	0	0		4	Code_Table	Source conditions for Dobson instruments
+0	2	148	0	0		5	Code_Table	Data collection and/or location system
+0	2	149	0	0		6	Code_Table	Type of data buoy
+0	2	150	0	0		6	Code_Table	TOVS/ATOVS/AVHRR instrumentation channel number
+0	2	151	0	0		4	Code_Table	Radiometer identifier
+0	2	152	0	0		31	Flag_Table	Satellite instrument used in data processing
+0	2	153	-8	0		26	Hz		Satellite channel center frequency
+0	2	154	-8	0		26	Hz		Satellite channel band width
+0	2	163	0	0		4	Code_Table	Height assignment method
+0	2	164	0	0		3	Code_Table	Tracer correlation method
+0	2	166	0	0		4	Code_Table	Radiance type
+0	2	167	0	0		4	Code_Table	Radiance computational method
+0	2	168	-3	0		16	Pa		Hydrostatic pressure of lower end of cable (thermistor string)
+0	2	169	0	0		4	Code_Table	Anemometer type
+0	2	172	0	0		8	Code_Table	Product type for retrieved atmospheric gases
+0	2	196	0	0		9	Code_Table	Satellite Classification
+0	2	197	8	0		26	Hz		Satellite Channel Center Frequency
+0	2	198	8	0		26	Hz		Satellite Channel Band Width
+0	2	221	0	0		18	M		Segment Size At Nadir In X Direction
+0	2	222	0	0		18	M		Segment Size At Nadir In Y Direction
+0	2	231	0	0		4	Code_Table	Height Assignment Method
+0	2	232	0	0		3	Code_Table	Tracer Correlation Method
+0	2	252	0	0		31	Flag_Table	Satellite Instrument Data Used In Processing
+	
+0	4	1	0	0		12	Year		Year
+0	4	2	0	0		4	mo		Month
+0	4	3	0	0		6	Day		Day
+0	4	4	0	0		5	hr		Hour
+0	4	5	0	0		6	min		Minute
+0	4	6	0	0		6	s		Second
+0	4	11	0	-1024		11	Year		Time increment
+0	4	12	0	-1024		11	mo		Time increment
+0	4	13	0	-1024		11	Days		Time increment
+0	4	14	0	-1024		11	hr		Time increment
+0	4	15	0	-2048		12	min		Time increment
+0	4	16	0	-4096		13	s		Time increment
+0	4	17	0	-1440		12	min		Reference time period for accumulated or extreme data
+0	4	21	0	-1024		11	Year		Time period or displacement
+0	4	22	0	-1024		11	mo		Time period or displacement
+0	4	23	0	-1024		11	Days		Time period or displacement
+0	4	24	0	-2048		12	hr		Time period or displacement
+0	4	25	0	-2048		12	min		Time period or displacement
+0	4	26	0	-4096		13	s		Time period or displacement
+0	4	31	0	0		8	hr		Duration of time relative to following value
+0	4	32	0	0		6	Minute		Duration of time relating to following value
+0	4	41	0	-1440		12	Minute		Time Difference, UTC-LMT
+0	4	43	0	0		9	Day		Day of the year
+0	4	53	0	0		6	Numeric		Number of days with precipition equal to or more than 1mm
+0	4	65	0	-128		8	min		Short time increment
+0	4	73	0	-128		8	Day		Short time period or displacement
+0	4	74	0	-128		8	Hour		Short time period or displacement
+0	4	75	0	-128		8	Minute		Short time period or displacement
+0	4	192	0	0		3	Code_Table	Season
+	
+0	5	1	5	-9000000	25	deg		Latitude (high accuracy)
+0	5	2	2	-9000		15	deg		Latitude (coarse accuracy)
+0	5	11	5	-9000000	25	deg		Latitude increment (high accuracy)
+0	5	12	2	-9000		15	deg		Latitude increment (coarse accuracy)
+0	5	21	2	0		16	deg_true	Bearing or azimuth
+0	5	22	2	0		16	deg_true	Solar azimuth
+0	5	30	0	0		12	deg		Direction (spectral)
+0	5	31	0	0		12	Numeric		Row number
+0	5	33	-1	0		16	m		Pixel size on horizontal - 1
+0	5	34	0	0		11	Numeric		Along Track row number
+0	5	40	0	0		24	Numeric		Orbit number
+0	5	41	0	0		8	Numeric		Scan line number
+0	5	42	0	0		6	Numeric		Channel number
+0	5	43	0	0		8	Numeric		Field of view number
+0	5	52	0	0		5	Numeric		Channel number increment
+0	5	53	0	0		5	Numeric		Field of view number increment
+
+0	6	1	5	-18000000	26	deg		Longitude (high accuracy)
+0	6	2	2	-18000		16	deg		Longitude (coarse accuracy)
+0	6	11	5	-18000000	26	deg		Longitude increment (high accuracy)
+0	6	12	2	-18000		16	deg		Longitude increment (coarse accuracy)
+0	6	21	-1	0		13	m		Distance
+0	6	30	5	0		13	rad/m		Wavenumber (spectral)
+0	6	31	0	0		12	Numeric		Column number
+0	6	33	-1	0		16	m		Pixel size on horizontal - 2
+0	6	34	0	0		7	Numeric		Cross-track cell number
+0	6	40	0	0		13	m		Radius of confidence
+
+0	7	1	0	-400		15	m		Height of station
+0	7	2	-1	-40		16	m		Height or altitude
+0	7	3	-1	-400		17	m**2/s**2	Geopotential
+0	7	4	-1	0		14	Pa		Pressure
+0	7	5	0	-400		12	m		Height increment
+0	7	6	0	0		15	m		Height above station
+0	7	7	0	-1000		17	m		Height
+0	7	8	0	-10000		20	m**2/s**2	Geopotential
+0	7	9	0	-1000		17	gpm		Geopotential height
+0	7	21	2	-9000		15	deg		Elevation
+0	7	22	2	-9000		15	deg		Solar elevation
+0	7	24	2	-9000		15	deg		Satellite zenith angle
+0	7	25	2	-9000		15	deg		Solar zenith angle
+0	7	61	2	0		14	m		Depth below land surface
+0	7	62	1	0		17	m		Depth below sea/water surface
+0	7	64	0	0		4	m		Height above station (sensor height artificially corrected)
+0	7	70	0	0		10	m		Drogue depth
+
+0	8	1	0	0		7	Flag_Table	Vertical sounding significance
+0	8	2	0	0		6	Code_Table	Vertical significance (surface observations)
+0	8	3	0	0		6	Code_Table	Vertical significance (satellite observations)
+0	8	4	0	0		3	Code_Table	Phase of aircraft flight
+0	8	5	0	0		4	Code_Table	Meteorological attribute significance
+0	8	6	0	0		9	Flag_Table	Ozone vertical sounding significance
+0	8	7	0	0		4	Code_Table	Dimensional significance
+0	8	8	0	0		9	Flag_Table	Radiation vertical sounding significance
+0	8	11	0	0		6	Code_Table	Meteorological feature
+0	8	12	0	0		2	Code_Table	land/sea qualifier
+0	8	13	0	0		2	Code_Table	Day/night qualifier
+0	8	14	0	0		4	Code_Table	Qualification for runway visual range
+0	8	16	0	0		3	Code_Table	Change indicator of a trend-type forecast or an aerodrome forecast
+0	8	17	0	0		2	Code_Table	Qualifier of the time when the forecast change is expected
+0	8	18	0	0		17	Flag_Table	SEAWINDS land/ice surface type
+0	8	20	0	0		16	Numeric		Total number of missing entities (with respect to accumulation or average)
+0	8	21	0	0		5	Code_Table	Time significance
+0	8	22	0	0		16	Numeric		Total number (with respect to accumulation or average)
+0	8	23	0	0		6	Code_Table	First order statistics
+0	8	24	0	0		6	Code_Table	Difference statistics
+0	8	25	0	0		4	Code_Table	Time difference qualifier
+0	8	30	0	0		13	Numeric		Manual on Codes Volume I.1 Section C table identifier
+0	8	31	0	0		8	Numeric		Data category CREX table A
+0	8	35	0	0		3	Code_Table	Type of monitoring exercise
+0	8	36	0	0		3	Code_Table	Type of center or station performing monitoring
+0	8	51	0	0		3	Code_Table	Qualifier for number of missing values in calculation of statistic
+0	8	52	0	0		5	Code_Table	Condition for which number of days of occurrence follows
+0	8	53	0	0		2	Code_Table	Day of occurance qualifier
+0	8	60	0	0		4	Code_Table	Sample scanning mode significance
+0	8	70	0	0		4	Code_Table	TOVS/ATOVS product qualifier
+0	8	72	0	0		3	Code_table	Pixel(s) type
+
+0	10	1	0	-400		15	m		Height of land surface
+0	10	2	-1	-40		16	m		Height
+0	10	3	-1	-400		17	m**2/s**2	Geopotential
+0	10	4	-1	0		14	Pa		Pressure
+0	10	7	0	-1000		17	m		Height
+0	10	8	0	-10000		20	m**2/s**2	Geopotential
+0	10	9	0	-1000		17	gpm		Geopotential height
+0	10	10	-1	0		14	Pa		Minimum pressure reduced to mean sea level
+0	10	11	-1	0		14	Pa		Maximum pressure reduced to mean sea level
+0	10	31	2	-1073741824	31	m		In direction of the North Pole, distance from the Earth's centre
+0	10	40	0	0		10	Numeric		Number of retrieved layer
+0	10	50	2	0		16	m		Standard deviation altitude
+0	10	51	-1	0		14	Pa		Pressure reduced to mean sea level
+0	10	52	-1	0		14	Pa		Altimeter setting (QNH)
+0	10	60	-1	-1024		11	Pa		Pressure change
+0	10	61	-1	-500		10	Pa		3 hour pressure change
+0	10	62	-1	-1000		11	Pa		24 hour pressure change
+0	10	63	0	0		4	Code_Table	Characteristic of pressure tendency
+0	10	70	0	-400		16	m		Indicated aircraft altitude
+	
+0	11	1	0	0		9	deg_true	Wind direction
+0	11	2	1	0		12	m/s		Wind speed
+0	11	3	1	-4096		13	m/s		U-component
+0	11	4	1	-4096		13	m/s		V-component
+0	11	5	1	-512		10	Pa/s		W-component
+0	11	6	2	-4096		13	m/s		W-component
+0	11	10	0	0		9	deg true	Wind direction associated with wind speed which follows
+0	11	11	0	0		9	deg_true	Wind direction at 10 m
+0	11	12	1	0		12	m/s		Wind speed at 10 m
+0	11	13	0	0		9	deg_true	Wind direction at 5 m
+0	11	14	1	0		12	m/s		Wind speed at 5 m
+0	11	16	0	0		9	deg_true	Extreme counterclockwise wind direction of a variable wind
+0	11	17	0	0		9	deg_true	Extreme clockwise wind direction of a variable wind
+0	11	19	0	0		7	Percent		Steadiness of wind
+0	11	21	9	-65536		17	1/s		Relative vorticity
+0	11	22	9	-65536		17	1/s		Divergence
+0	11	23	-2	-65536		17	m**2/s		Velocity potential
+0	11	31	0	0		4	Code_Table	Degree of turbulence
+0	11	32	-1	-40		16	m		Height of base of turbulence
+0	11	33	-1	-40		16	m		Height of top of turbulence
+0	11	34	1	-1024		11	m/s		Vertical gust velocity
+0	11	35	2	-8192		14	m/s**2		Vertical gust acceleration
+0	11	36	1	0		10	m/s		Maximum derived equivalent vertical gust speed
+0	11	37	0	0		6	Code_Table	Turbulence Index
+0	11	38	0	0		5	Code_Table	Time of occurrence of Peak Eddy Dissipation Rate
+0	11	40	1	0		12	m/s		Maximum wind speed (mean wind)
+0	11	41	1	0		12	m/s		Maximum wind speed (gusts)
+0	11	42	1	0		12	m/s		Maximum wind speed (10 minute mean wind)
+0	11	43	0	0		9	deg_true	Maximum wind gust direction
+0	11	44	0	0		9	deg_true	Mean wind direction for surface - 1500m (5000 feet)
+0	11	45	1	0		12	m/s		Mean wind speed for surface - 1500m (5000 feet)
+0	11	46	1	0		12	m/s		Maximum instantaneous wind speed
+0	11	47	1	0		12	m/s		Maximum instantaneous wind speed over 10 minutes
+0	11	49	0	0		9	deg_true	Standard deviation of wind direction
+0	11	50	1	0		12	m/s		Standard deviation horizontal wind speed
+0	11	51	1	0		8	m/s		Standard deviation vertical wind speed
+0	11	52	2	0		13	m/s		Formal uncertainty in wind speed
+0	11	53	2	0		15	deg true	Formal uncertainty in wind direction
+0	11	61	1	0		12	m/s		Absolute wind shear in 1 kilometer layer below
+0	11	62	1	0		12	m/s		Absolute wind shear in1 kilometer layer above
+0	11	70	0	0		32	CCITT_IA5	Designator of the runway affected by wind shear
+0	11	71	3	-128		14	m**2/s**2	Turbulent vertical momentum flux
+0	11	72	3	-128		11	K m/s		Turbulent vertical buoyancy flux
+0	11	73	2	-1024		13	m**2/s**2	Turbulent kinetic energy
+0	11	74	2	-1024		10	m**2/s**2	Dissipation energy
+0	11	75	2	0		8	m**(2/3)/s	Mean turbulence intensity
+0	11	76	2	0		8	m**(2/3)/s	Peak turbulence intensity
+0	11	81	2	0		16	deg true	Model wind direction at 10m
+0	11	82	2	0		14	m/s		Model wind speed at 10 m
+
+0	12	1	1	0		12	deg_K		Temperature/dry bulb temperature
+0	12	2	1	0		12	deg_K		Wet bulb temperature
+0	12	3	1	0		12	deg_K		Dewpoint temperature
+0	12	4	1	0		12	deg_K		Dry bulb temperature at 2 meters
+0	12	5	1	0		12	deg_K		Wet bulb temperature at 2 meters
+0	12	6	1	0		12	deg_K		Dewpoint temperature at 2 meters
+0	12	7	1	0		12	deg_K		Virtual temperature
+0	12	11	1	0		12	deg_K		Maximum temperature
+0	12	12	1	0		12	deg_K		Minimum temperature
+0	12	13	1	0		12	deg_K		Ground minimum temperature past 12 hours
+0	12	14	1	0		12	deg_K		Maximum temperature at 2 meters, past 12 hours
+0	12	15	1	0		12	deg_K		Minimum temperature at 2 meters, past 12 hours
+0	12	16	1	0		12	deg_K		Maximum temperature at 2 meters, past 24 hours
+0	12	17	1	0		12	deg_K		Minimum temperature at 2 meters, past 24 hours
+0	12	21	2	0		16	deg K		Maximum temperature at 2m
+0	12	22	2	0		16	deg K		Minimum temperature at 2m
+0	12	30	1	0		12	deg_K		Soil temperature
+0	12	51	1	0		10	deg_K		Standard deviation of temperature
+0	12	52	1	0		12	deg_K		Highest daily mean temperature
+0	12	53	1	0		12	deg_K		Lowest daily mean temperature
+0	12	61	1	0		12	deg_K		Skin temperature
+0	12	62	1	0		12	deg_K		Equivalent black body temperature
+0	12	63	1	0		12	deg_K		Brightness temperature
+0	12	64	1	0		12	deg_K		Instrument temperature
+0	12	65	1	0		12	deg K		Standard deviation brightness temperature
+0	12	71	1	0		12	deg_K		Coldest cluster temperature
+0	12	72	6	0		31	W/m**2/sr	Radiance
+0	12	075	-3	0		16	W m-3 sr-1	Spectral radiance
+0	12	076	3	0		16	W m-2 sr-1	Radiance
+0	12	101	2	0		16	deg_K		Temperature/dry-bulb temperature
+0	12	102	2	0		16	deg_K		Wet-bulb temperature
+0	12	103	2	0		16	deg_K		Dew-point temperature
+0	12	104	2	0		16	deg_K		Dry-bulb temperature at 2m
+0	12	105	2	0		16	deg_K		Web-bulb temperature at 2m
+0	12	106	2	0		16	deg_K		Dew-point temperature at 2m
+0	12	107	2	0		16	deg_K		Virtual temperature
+0	12	111	2	0		16	deg_K		Maximum temperature, at height and over period specified
+0	12	112	2	0		16	deg_K		Minimum temperature, at height and over period specified
+0	12	113	2	0		16	deg_K		Ground minimum temperature, past 12 hours
+0	12	114	2	0		16	deg_K		Maximum temperature at 2m, past 12 hours
+0	12	115	2	0		16	deg_K		Minimum temperature at 2m, past 12 hours
+0	12	116	2	0		16	deg_K		Maximum temperature at 2m, past 24 hours
+0	12	117	2	0		16	deg_K		Minimum temperature at 2m, past 24 hours
+0	12	130	2	0		16	deg_K		Soil temperature
+0	12	152	2	0		16	deg_K		Highest daily mean temperature
+0	12	153	2	0		16	deg_K		Lowest daily mean temperature
+0	12	161	2	0		16	deg_K		Skin temperature
+0	12	162	2	0		16	deg_K		Equivalent black body temperature
+0	12	163	2	0		16	deg_K		Brightness temperature
+0	12	164	2	0		16	deg_K		Instrument temperature
+0	12	171	2	0		16	deg_K		Coldest cluster temperature
+0	12	193	1	0		12	deg_K		Coldest Cluster Temperature
+
+
+0	13	1	5	0		14	kg/kg		Specific humidity
+0	13	2	5	0		14	kg/kg		Mixing ratio
+0	13	3	0	0		7	percent		Relative humidity
+0	13	4	-1	0		10	Pa		Vapor pressure
+0	13	5	3	0		7	kg/m**3		Vapor density
+0	13	6	-1	-40		16	m		Mixing heights
+0	13	7	0	0		7	percent		Minimum relative humidity
+0	13	8	0	0		7	percent		Maximum relative humidity
+0	13	11	1	-1		14	kg/m**2		Total precipitation/total water equivalent
+0	13	12	2	-2		12	m		Depth of fresh snow
+0	13	13	2	-2		16	m		Total snow depth
+0	13	14	4	0		12	kg/m**2/s	Rainfall/water equivalent of snow (average rate)
+0	13	15	7	0		12	m/s		Snowfall (averaged rate)
+0	13	16	0	0		7	kg/m**2		Precipitable water
+0	13	19	1	-1		14	kg/m**2		Total precipitation past 1 hour
+0	13	20	1	-1		14	kg/m**2		Total precipitation past 3 hours
+0	13	21	1	-1		14	kg/m**2		Total precipitation past 6 hours
+0	13	22	1	-1		14	kg/m**2		Total precipitation past 12 hours
+0	13	23	1	-1		14	kg/m**2		Total precipitation past 24 hours
+0	13	31	0	0		7	kg/m**2		Evapotranspiration
+0	13	32	1	0		8	kg/m**2		Evaporation/evapotranspiration
+0	13	33	1	0		10	kg/m**2		Evaporation/evapotranspiration
+0	13	38	0	0		2	Code_Table	Superadiabatic indicator
+0	13	39	0	0		3	Code_Table	Terrain type (ice/snow)
+0	13	41	0	0		4	Code_Table	Pasquill-Gifford stability category
+0	13	42	0	-20		6	deg_K		Parcel lifted index (to 500 hPa)
+0	13	43	0	-20		6	deg_K		Best lifted index (to 500 hPa)
+0	13	51	0	0		4	Code_Table	Frequency group, precipition
+0	13	52	1	-1		14	kg/m**2		Highest daily amount of precipition
+0	13	55	4	0		8	KG/M**2*S	INTENSITY OF PRECIPITATION
+0	13	60	1	-10		17	kg m-2		Total accumulated precipitation
+0	13	71	2	0		14	m		Upstream water level
+0	13	72	2	0		14	m		Downstream water level
+0	13	73	2	0		14	m		Maximum water level
+0	13	80	1	0		10	pH unit		Water pH
+0	13	81	3	0		14	Siemens m-1	Water conductivity
+0	13	82	1	0		12	deg K		Water temperature
+0	13	83	6	0		15	Kg m-3		Dissolved oxygen
+0	13	84	0	0		14	Lumen		Turbidity
+0	13	85	3	0		14	V		Oxydation Reduction Potential (ORP)
+
+0	14	1	-3	-2048		12	Joules/m**2	Longwave radiation, integrated over 24 hours
+0	14	2	-3	-2048		12	Joules/m**2	Longwave radiation, integrated over period specified
+0	14	3	-3	-2048		12	Joules/m**2	Shortwave radiation, integrated over 24 hours
+0	14	4	-3	-2048		12	Joules/m**2	Shortwave radiation, integrated over period specified
+0	14	11	-3	-2048		12	Joules/m**2	Net longwave radiation, integrated over 24 hours
+0	14	12	-3	-2048		12	Joules/m**2	Net longwave radiation, integrated over period specified
+0	14	13	-3	-2048		12	Joules/m**2	Net shortwave radiation, integrated over 24 hours
+0	14	14	-3	-2048		12	Joules/m**2	Net shortwave radiation, integrated over period specified
+0	14	15	-4	-16384		15	Joules/m**2	Net radiation, integrated over 24 hours
+0	14	16	-4	-16384		15	Joules/m**2	Net radiation, integrated over period specified
+0	14	17	-3	-2048		12	W/m**2		Instantaneous long wave radiation
+0	14	18	-3	-2048		12	W/m**2		Instantaneous short wave radiation
+0	14	19	0	0		7	percent		Surface albedo
+0	14	20	-4	0		15	Joules/m**2	Global solar radiation, integrated over 24 hours
+0	14	21	-4	0		15	Joules/m**2	Global radiation, integrated over period specified
+0	14	22	-4	0		15	Joules/m**2	Diffuse solar radiation, integrated over 24 hours
+0	14	23	-4	0		15	Joules/m**2	Diffuse solar radiation, integratedi over period specified
+0	14	24	-4	0		15	Joules/m**2	Direct solar radiation, integrated over 24 hours
+0	14	25	-4	0		15	Joules/m**2	Direct solar radiation, integrated over period specified
+0	14	26	0	0		7	percent		Albedo at the top of clouds
+0	14	27	0	0		7	percent		Albedo
+0	14	28	-2	0		16	J/m**2		Global solar radiation (high accuracy, integrated over period specified
+0	14	29	-2	0		16	J/m**2		Diffuse solar radiation (high accuracy, integrated over period specified
+0	14	30	-2	0		16	J/m**2		Direct solar radiation (high accuracy, integrated over period specified
+0	14	31	0	0		11	min		Total sunshine
+0	14	32	0	0		10	hr		Total sunshine
+0	14	33	0	0		9	percent		Total sunshine
+0	14	34	0	0		11	min		Sunshine of period specified
+0	14	42	0	0		7	percent		Bi-directional reflectance
+0	14	45	0	0		11	W/m**2/sr/cm	Channel radiance
+0	14	51	-3	0		14	j/m**2		Direct solar radiation integrated over last hour
+
+0	15	1	0	0		10	Dobson units	Ozone
+0	15	2	2	0		10	Numeric		Air mass (slant path at 22km)
+0	15	3	4	0		9	Pascal		Measured ozone partial pressure
+0	15	4	3	0		11	Numeric		Ozone sounding correction factor
+0	15	5	0	0		10	DU		Ozone p
+0	15	11	3	14000		13	log(1/m**2)	Log 10 of integrated electron density
+0	15	15	0	0		31	Numeric		Maximum image spectral composition before normalization
+0	15	20	8	0		21	kg/m**2		Integrated Ozone density
+
+0	19	1	0	0		6	Code_Table	Type of synoptic features
+0	19	2	-2	0		12	m		Effective radius of feature
+0	19	3	0	0		8	m/s		Wind speed threshold
+0	19	4	-2	0		12	m		Effective radius of feature with respect to wind speeds above threshold
+0	19	5	0	0		9	deg_true	Direction of motion of features
+0	19	6	2	0		14	m/s		Speed of motion of features
+0	19	7	-3	0		12	m		Effective radius of features
+0	19	8	0	0		3	Code_Table	Vertical extent of circulation
+0	19	9	-3	0		12	m		Effective radius with respect to wind speed above threshold (large storms)
+0	19	10	0	0		4	Code_Table	Method for tracking the center of synoptic feature
+
+0	20	1	-1	0		13	m		Horizontal visibility
+0	20	2	-1	0		7	m		Vertical visibility
+0	20	3	0	0		9	Code_Table	Present weather
+0	20	4	0	0		5	Code_Table	Past weather (1)
+0	20	5	0	0		5	Code_Table	Past weather (2)
+0	20	8	0	0		5	Code_Table	Cloud distribution for aviation
+0	20	9	0	0		4	Code_Table	General Weather Indicator
+0	20	10	0	0		7	percent		Cloud cover (total)
+0	20	11	0	0		4	Code_Table	Cloud amount
+0	20	12	0	0		6	Code_Table	Cloud type
+0	20	13	-1	-40		11	m		Height of base of cloud
+0	20	14	-1	-40		11	m		Height of top of cloud
+0	20	15	-1	0		14	Pa		Pressure at the base of cloud
+0	20	16	-1	0		14	Pa		Pressure at the top of cloud
+0	20	17	0	0		4	Code_Table	Cloud top description
+0	20	18	0	0		2	Code_Table	Tendency of runway visual range
+0	20	19	0	0		72	CCITT_IA5	Significant present or forecast weather
+0	20	20	0	0		32	CCITT_IA5	Significant recent weather phenomena
+0	20	31	2	0		7	m		Ice deposit (thickness)
+0	20	32	0	0		3	Code_Table	Rate of ice accretion
+0	20	33	0	0		4	Flag_Table	Cause of ice accretion
+0	20	34	0	0		5	Code_Table	Sea ice concentration
+0	20	35	0	0		4	Code_Table	Amount and type of ice
+0	20	36	0	0		5	Code_Table	Ice situation
+0	20	37	0	0		5	Code_Table	Ice development
+0	20	38	0	0		12	deg_true	Bearing of ice edge
+0	20	39	-1	0		13	m		Ice distance
+0	20	41	0	0		4	Code_Table	Airframe icing
+0	20	51	0	0		7	percent		Amount of low clouds
+0	20	52	0	0		7	percent		Amount of middle clouds
+0	20	53	0	0		7	percent		Amount of high clouds
+0	20	61	0	0		12	m		Runway visual range (RVR)
+0	20	62	0	0		5	Code_Table	State of the ground(with or without snow)
+0	20	63	0	0		10	Code_Table	Special phenomena
+0	20	70	0	0		7	Numeric		Minimum number of atmospherics
+0	20	71	0	0		4	Code_Table	Accuracy of fix and rate of atmospherics
+0	20	81	0	0		7	percent		Cloud amount in segment
+0	20	82	0	0		7	percent		Amount segment cloud free
+0	20	90	0	0		4	Code_Table	Special clouds
+
+0	21	1	0	-64		7	dB		Horizontal reflectivity
+0	21	2	0	-64		7	dB		Vertical reflectivity
+0	21	3	1	-5		7	dB		Differential reflectivity
+0	21	5	0	-65		6	dB		Circular depolarization ratio
+0	21	6	0	-65		6	dB		Circular depolarization ratio
+0	21	11	0	-128		8	m/s		Doppler mean velocity in X direction
+0	21	12	0	-128		8	m/s		Doppler mean velocity in Y direction
+0	21	13	0	-128		8	m/s		Doppler mean velocity in Z direction
+0	21	14	1	-4096		13	m/s		Doppler mean velocity (radiational)
+0	21	17	1	0		8	m/s		Doppler velocity spectral width
+0	21	21	-3	0		4	m		Echo tops
+0	21	30	0	-32		8	dB		Signal to noise ratio
+0	21	31	0	0		7	kg/m**2		Vertical integrated liquid water content
+0	21	36	7	0		12	m/s		Radar rainfall intensity
+0	21	41	-2	0		8	m		Bright band height
+0	21	51	0	-256		8	dB		Signal power above 1 MW
+0	21	62	2	-5000		13	Decibels	Backscatter
+0	21	63	1	0		10	Percent		Radiometric resolution (noise value)
+0	21	64	0	0		8	Numeric		Clutter noise estimate
+0	21	65	0	-127		8	Numeric		Missing packet counter
+0	21	66	0	0		12	Flag_Table	Wave scatterometer product confidence
+0	21	67	0	0		13	Flag_Table	Wind product confidence data 
+0	21	68	0	0		8	Flag_Table	Radar altimeter product confidence data 
+0	21	69	0	0		10	Flag_Table	SST product confidence data 
+0	21	70	0	0		23	Flag_Table	SST product confidence data (SADIST-2)
+0	21	71	0	0		16	Numeric		Peakiness 
+0	21	72	0	0		4	Flag_Table	Satellite altimeter calibration status 
+0	21	73	0	0		9	Flag_Table	Satellite altimeter instrument mode 
+0	21	75	0	0		8	Numeric		Spectral intensity
+0	21	76	0	0		3	Code_Table	Representation of intensities
+0	21	77	3	0		14	m		Altitude correction (ionosphere)
+0	21	78	3	0		9	m		Altitude correction (dry troposphere)
+0	21	79	3	2000		10	m		Altitude correction (wet troposphere)
+0	21	80	3	0		11	m		Altitude correction (calibration constant)
+0	21	81	3	0		10	m		Open loop correction (height-time loop)
+0	21	82	3	-3000		14	Decibels	Open loop correction (auto gain control)
+0	21	85	0	-3000		4	Numeric		ATSR sea surface temperature across-track band number
+0	21	91	0	-100		8	dB		Radar signal Doppler spectrum 0th moment
+0	21	092	0	-100		8	dB		RASS signal Doppler spectrum 0th moment, referring to RASS signal
+0	21	101	0	0		3	Numeric		Number of vector ambiguities
+0	21	102	0	0		3	Numeric		Index of selected wind vector
+0	21	103	0	0		5	Numeric		Total number of sigma-0 measurements
+0	21	104	3	-30000		15	Numeric		Likelihood computed for solution
+0	21	105	2	-10000		14	dB		Normalized radar cross-section
+0	21	106	3	0		14	Numeric		Kp variance coefficient (Alpha)
+0	21	107	8	0		16	Numeric		Kp variance coefficient (Beta)
+0	21	109	0	0		17	Flag table	SEAWINDS wind vector cell quality
+0	21	110	0	0		6	Numeric		Number of inner-beam Sigma-0 (forward of satellite)
+0	21	111	0	0		6	Numeric		Number of outer-beam Sigma-0 (forward of satellite)
+0	21	112	0	0		6	Numeric		Number of inner-beam Sigma-0 (aft of satellite)
+0	21	113	0	0		6	Numeric		Number of outer-beam Sigma-0 (aft of satellite)
+0	21	114	3	-140000		18	dB		Kp variance coefficent (Gamma)
+0	21	115	0	0		17	Flag table	SEAWINDS sigma-0 quality
+0	21	116	0	0		17	Flag table	SEAWINDS sigma-0 mode
+0	21	117	2	0		16	Numeric		Sigma-0 variance quality control
+0	21	118	2	-10000		14	dB		Attenuation correction on sigma-0
+0	21	119	0	0		6	Code table	Wind scatterometer geophysical model function
+0	21	120	3	0		10	Numeric		Probability of rain
+0	21	121	0	0		8	Numeric		SEAWINDS NOF* rain index
+0	21	122	2	-10000		14	dB		Attenuation correction of sigma-0 (from tB)
+0	21	123	2	-30000		15	dB		SEAWINDS normalized radar cross section
+
+
+0	22	1	0	0		9	deg_true	Direction of waves
+0	22	2	0	0		9	deg_true	Direction of wind waves
+0	22	3	0	0		9	deg_true	Direction of swell waves
+0	22	4	0	0		9	deg_true	Direction of current waves
+0	22	11	0	0		6	s		Period of waves
+0	22	12	0	0		6	s		Period of wind waves
+0	22	13	0	0		6	s		Period of swell waves
+0	22	21	1	0		10	m		Height of waves
+0	22	22	1	0		10	m		Height of wind waves
+0	22	23	1	0		10	m		Height of swell waves
+0	22	25	2	0		10	m		Standard deviation wave height
+0	22	26	2	0		10	m		Standard deviation of significant wave height
+0	22	31	2	0		13	m/s		Speed of current
+0	22	35	2	0		14	m		Tidal elevation with respect to local chart datum
+0	22	36	2	0		14	m		Meteorological residual tida elevation (surge or offset)
+0	22	37	3	-10000		15	m		Tidal elevation with respect to national chart datum
+0	22	38	3	-10000		15	m		Tidal elevation with respect to local chart datum
+0	22	39	3	-5000		12	m		Meteorological residual tidal elevation (surge or offset)
+0	22	40	3	-5000		14	m		Meteorological residual tidal elevation (surge or offset)
+0	22	41	1	0		12	deg_K		Sea surface temperature (15 day running mean)
+0	22	42	1	0		12	deg_K		Sea/water temperature
+0	22	43	2	0		15	deg_K		Sea/water temperature
+0	22	44	1	0		14	m/s		Sound velocity
+0	22	50	2	0		8	K		Standard deviation sea surface temperature
+0	22	61	0	0		4	Code_Table	State of sea
+0	22	62	2	0		14	ppt		Salinity
+0	22	63	0	0		14	m		Total water depth
+0	22	67	0	0		10	Code_Table	Instrument type for water temperature profile measurement
+0	22	68	0	0		7	Code_Table	Water temperature profile recorder types
+0	22	70	2	0		13	m		Significant wave height
+0	22	71	1	0		9	s		Spectral peak wave period
+0	22	72	0	0		13	m		Spectral peak wave length
+0	22	73	2	0		13	m		Maximum wave height
+0	22	74	1	0		9	s		Average wave period
+0	22	75	0	0		13	m		Average wave length
+0	22	76	0	0		9	Degree_True	Direction from which dominant waves are coming
+0	22	77	0	0		9	Degree		Directional spred of dominant wave
+0	22	78	0	0		12	s		Duration of wave record
+0	22	79	0	0		16	m		Length of wave record
+0	22	80	3	0		10	Hz		Waveband central frequency
+0	22	81	5	0		13	m**-1		Waveband central wave number
+0	22	82	2	0		20	m**2/s		Maximum non-directional spectral wave density
+0	22	83	2	0		20	m**3		Maximum non-directional spectral wave number
+0	22	84	0	0		7	Numeric		Band containing maximum non-directional spectral wave density
+0	22	85	0	0		7	Numeric		Spectral wave density ratio
+0	22	86	0	0		9	Degree_True	Mean direction from which waves are coming
+0	22	87	0	0		9	Degree_True	Principal direction from which waves are coming
+0	22	88	2	0		7	Numeric		First normalized polar coordinate from Fourier coefficients
+0	22	89	2	0		7	Numeric		Second normalized polar coordinate from Fourier coefficients
+0	22	90	2	0		20	m**2/s		Non-directional spectral estimate by wave frequency
+0	22	91	2	0		20	m**3		Non-directional spectral estimate by wave number
+0	22	92	2	0		20	m**2/rad**-1/s	Directional spectral estimate by wave frequency
+0	22	93	2	0		20	m**4		Directional spectral estimate by wave number
+0	22	94	0	0		7	Numeric		Total number of wave bands
+0	22	95	0	0		8	Degree		Directional spread of individual waves
+0	22	96	3	0		4	s**-1		Spectral band width 
+0	22	97	0	0		14	m		Mean wavelength > 731 m of image spectrum at low wave numbers
+0	22	98	0	0		14	m		Wavelength spread (wavelength > 731 m) at low wave numbers
+0	22	99	0	0		9	deg_true	Mean direction at low wave numbers (wavelength > 731 m)
+0	22	100	0	0		9	Degree		Direction spread at low wave numbers (wavelength > 731 m)
+0	22	101	0	0		31	Numberic	Total energy (wavelength > 731 m) at low wave numbers
+0	22	120	0	0		5	Code_Table	Tide station automated water level check
+0	22	121	0	0		5	Code_Table	Tide station manual water level check
+0	22	122	0	0		5	Code_Table	Tide station automated Meteorological data check
+0	22	123	0	0		5	Code_Table	Tide station manual Meteorological data check
+0	22	141	2	0		15	Code_Table	Sea-surface temperature (15-day running mean)
+
+0	23	1	0	0		3	Code_Table	Accident early notification - article applicable
+0	23	2	0	0		5	Code_Table	Activity or facility involved in incident
+0	23	3	0	0		3	Code_Table	Type of release
+0	23	4	0	0		3	Code_Table	Countermeasures taken near border
+0	23	5	0	0		2	Code_Table	Cause of incident
+0	23	6	0	0		3	Code_Table	Incident situation
+0	23	7	0	0		3	Code_Table	Characteristic of release
+0	23	8	0	0		2	Code_Table	State of current release
+0	23	9	0	0		2	Code_Table	State of expected release
+0	23	16	0	0		2	Code_Table	Possibility of significant chemical toxic health effect
+0	23	17	6	0		20	m**3/s		Flow discharge of major recipient
+0	23	18	0	0		3	Code_Table	release behavior over time
+0	23	19	0	-15000		17	m		Actual release height
+0	23	21	0	-15000		17	m		Effective release height
+0	23	22	0	0		24	m		Distance of relative point or site of incident
+0	23	23	1	0		12	m/s		Main transport speed in atmosphere
+0	23	24	2	0		13	m/s		Main transport speed in water
+0	23	25	2	0		13	m/s		Main transport speed in ground water
+0	23	27	0	0		9	deg_true	Main transport direction in atmosphere
+0	23	28	0	0		9	deg_true	Main transport direction in water
+0	23	29	0	0		9	deg_true	Main transport direction in ground water
+0	23	31	0	0		2	Code_Table	Possibility that plume will encounter precipitation cwin state in which incident occurred
+0	23	32	0	0		2	Code_Table	Plume will encounter ichange in wind direction and/or speed flag
+
+0	24	1	-11	0		28	Bq		Estimate of radiatioactivity released up to specified time
+0	24	2	-11	0		28	Bq		Estimated maximum potential release
+0	24	3	0	0		5	Code_Table	Composition of release
+0	24	4	0	0		16	CCITT_IA5	Element name
+0	24	5	0	0		9	Numeric		Isotope mass
+0	24	11	2	0		32	mSv		Dose
+0	24	12	2	0		32	mSv		Trajectory dose (defined location and expected time of arrival)
+0	24	13	2	0		32	mSv		Gamma dose in air along the main transport path (defined location and time period
+0	24	21	2	0		32	Bq/m**3		Air concentration (named isotope type including gross beta)
+0	24	22	2	0		32	Bq/l		Concentration in precipitation (of named isotope type)
+0	24	23	1	0		14	pulse/sec	Pulse rate of beta radiation
+0	24	24	1	0		14	pulse/sec	Pulse rate of beta radiation
+
+0	25	1	-1	0		6	m		Range gate length
+0	25	2	0	0		4	Numeric		Number of gates averaged
+0	25	3	0	0		8	Numeric		Number of integrated pulses
+0	25	4	0	0		2	Code_Table	Echo processing
+0	25	5	0	0		2	Code_Table	Echo integration
+0	25	6	0	0		3	Code_Table	Z to R conversion
+0	25	7	0	0		12	Numeric		Z to R conversion factor
+0	25	8	2	0		9	Numeric		Z to R conversion exponent
+0	25	9	0	0		4	Flag_Table	Calibration method
+0	25	10	0	0		4	Code_Table	Clutter treatment
+0	25	11	0	0		2	Code_Table	Ground occultation correction (screening)
+0	25	12	0	0		2	Code_Table	Range attenuation correction
+0	25	13	0	0		2	Flag_Table	Bright band correction
+0	25	14	0	0		12	Numeric		Azimuth clutter cut-off
+0	25	15	0	0		2	Flag_Table	Radome attenuation correction
+0	25	16	5	0		6	dB/m		Clear air attenuation correction
+0	25	17	0	0		2	Flag_Table	Precipitation attenuation correction
+0	25	18	7	0		6	Numeric		A to Z law for attenuation factor
+0	25	19	2	0		7	Numeric		A to Z law for attenuation exponent
+0	25	20	0	0		2	Code_Table	Mean speed estimation
+0	25	21	0	0		8	Flag_Table	Wind computation enhancement
+0	25	30	0	0		2	Code_Table	SST usage
+0	25	32	0	0		2	Code_Table	NOAA wind profiler high/low mode data
+0	25	33	0	0		2	Code_Table	NOAA wind profiler submode
+0	25	34	0	0		4	Code_Table	NOAA wind profiler Q/C test results
+0	25	40	0	0		4	Code_Table	CO2 wind product derivation
+0	25	41	0	0		2	Code_Table	Moving platform direction reporting method
+0	25	42	0	0		2	Code_Table	Moving platform speed reporting method
+0	25	43	4	0		15	s		Wave sampling interval (time)
+0	25	44	2	0		14	m		Wave sampling interval (space)
+0	25	45	0	0		21	Flag_Table	HIRS channel combination 
+0	25	46	0	0		5	Flag_Table	MSU channel combination 
+0	25	47	0	0		4	Flag_Table	SSU channel combination 
+0	25	48	0	0		16	Flag_Table	AMSU-A channel combination 
+0	25	49	0	0		6	Flag_Table	AMSU-B channel combination 
+0	25	50	0	0		7	Flag_Table	AVHRR channel combination 
+0	25	51	0	0		12	Flag_Table	Observation quality
+0	25	53	0	0		12	Flag_Table	Observation quality
+0	25	60	0	0		14	Numeric		Software identification 
+0	25	70	0	0		4	Numeric		Major frame count 
+0	25	71	0	0		5	Numeric		Frame count 
+0	25	75	0	0		5	Numeric		Satellite antenna corrections version number 
+0	25	76	8	0		30	Log/m		Log-10 of (Temperature-radiance central wavenumber) for ATOVS 
+0	25	77	5	-100000		18	Numeric		Bandwidth correction coefficient 1 for ATOVS 
+0	25	78	5	0		17	Numeric		Bandwidth correction coefficient 2 for ATOVS 
+0	25	79	4	0		24	W/m**2		Albedo-radiance solar filtered irradiance for ATOVS 
+0	25	80	10	0		14	m		Albedo-radiance equivalent filter width for ATOVS 
+0	25	85	0	0		7	Numeric		Fraction of clear pixels in HIRS FOV 
+0	25	86	0	0		2	Code table	Depth correction indicator
+0	25	91	3	-18192		13	dB		Structure constant of the refraction index (cn2)
+0	25	92	2	28000		14	m s-1		Acoustic propagation velocity
+0	25	93	0	0		8	Flag table	RASS computation correction
+
+
+0	26	1	1	0		12	Hour		Principal time of daily reading in UTC of maximum temperature
+0	26	2	1	0		12	Hour		Principal time of daily reading in UTC of minimum temperature
+0	26	3	0	-1440		12	Minute		Time difference
+0	26	10	0	0		26	Flag_Table	Hours included
+
+0	27	1	5	-9000000	25	deg		Latitude (high accuracy)
+0	27	2	2	-9000		15	deg		Latitude (coarse accuracy)
+0	27	3	2	-9000		15	deg		Alternate latitude
+0	27	20	0	0		16	Numeric		Satellite locationon counter
+0	27	21	0	0		16	Numeric		Satellite sub-locationon dimensions
+0	27	31	2	-1073741824	31	m		In direction of 0 degrees longitude, distance from the Earth's centre
+
+0	28	1	5	-18000000	26	deg		Longitude (high accuracy)
+0	28	2	2	-18000		16	deg		Longitude (coarse accuracy)
+0	28	3	2	-18000		16	deg		Alternate longtiude
+0	28	31	2	-1073741824	31	m		In direction of 90 degrees East, distance from the Earth's centre
+
+0	29	1	0	0		3	Code_Table	Projection type
+0	29	2	0	0		3	Code_Table	Coordinate grid type
+
+0	30	1	0	0		4	Numeric		Pixel value (4 bits)
+0	30	2	0	0		8	Numeric		Pixel value (8 bits)
+0	30	4	0	0		16	Numeric		Pixel value (16 bits)
+0	30	21	0	0		12	Numeric		Number of pixels per row
+0	30	22	0	0		12	Numeric		Number of pixels per column
+0	30	31	0	0		4	Code_Table	Picture type
+0	30	32	0	0		16	Flag_Table	Combined picture
+
+0	31	0	0	0		1	Numeric		Short delayed descriptor replication factor
+0	31	1	0	0		8	Numeric		Delayed descriptor replication factor
+0	31	2	0	0		16	Numeric		Extended delayed descriptor replication factor
+0	31	11	0	0		8	Numeric		Delayed descriptor and data repetion factor
+0	31	12	0	0		16	Numeric		Extended delayed descriptor and data repitition factor
+0	31	21	0	0		6	Code_Table	Associated field significance
+0	31	31	0	0		1	Flag_Table	Data present indicator
+
+0	33	2	0	0		2	Code_Table	Quality information
+0	33	3	0	0		3	Code_Table	Quality information
+0	33	7	0	0		7	Percent		Per cent confidence 
+0	33	20	0	0		3	Code_Table	Quality control indication of following value
+0	33	21	0	0		2	Code_Table	Quality of following value
+0	33	22	0	0		2	Code_Table	Quality of buoy satellite transmission
+0	33	23	0	0		2	Code_Table	Quality of buoy location 
+0	33	24	0	0		4	Code_Table	Station elevation quality mark (for mobile stations)
+0	33	25	0	0		3	Code_Table	ACARS interpolated values
+0	33	26	0	0		6	Code_Table	Mixing ratio quality
+0	33	27	0	0		3	Code_Table	Location quality class (range of radius of 66% confidence)
+0	33	30	0	0		24	Flag_Table	Scan line status flags for ATOVS
+0	33	31	0	0		24	Flag_Table	Scan line quality flags for ATOVS
+0	33	32	0	0		24	Flag_Table	Channel quality flags for ATOVS
+0	33	33	0	0		24	Flag_Table	Field of view quality flags for ATOVS
+0	33	35	0	0		4	Code_Table	Manual/automatic quality control
+0	33	36	0	0		7	Percent		Nominal confidence threshold
+0	33	37	0	0		20	Flag_Table	Wind correlation error
+0	33	40	0	0		7	percent		Confidence interval
+0	33	41	0	0		2	Code_Table	Attribute of following value
diff --git a/data/tables/B3L-160000-006001-D b/data/tables/B3L-160000-006001-D
new file mode 100644
index 0000000..a38be22
--- /dev/null
+++ b/data/tables/B3L-160000-006001-D
@@ -0,0 +1,2673 @@
+#
+# BUFR Table D (Lists of Common Sequences)
+#
+# Descriptor sequences are terminated with -1
+#
+# Sequences do not need to appear in any order.  Sequence A
+# which includes sequence B, may appear before sequence B
+# is defined.
+#
+3	0	2
+	0	0	2
+	0	0	3
+	-1
+
+3	0	3
+	0	0	10
+	0	0	11
+	0	0	12
+	-1
+
+3	0	4
+	3	0	3
+	0	0	13
+	0	0	14
+	0	0	15
+	0	0	16
+	0	0	17
+	0	0	18
+	0	0	19
+	0	0	20
+	-1
+
+3	0	10
+	3	0	3
+	1	1	0
+	0	31	1
+	0	0	30
+	-1
+
+3	1	1
+	0	1	1
+	0	1	2
+	-1
+
+3	1	2
+	0	1	3
+	0	1	4
+	0	1	5
+	-1
+
+3	1	3
+	0	1	11
+	0	1	12
+	0	1	13
+	-1
+
+3	1	11
+	0	4	1
+	0	4	2
+	0	4	3
+	-1
+
+3	1	12
+	0	4	4
+	0	4	5
+	-1
+
+3	1	13
+	0	4	4
+	0	4	5
+	0	4	6
+	-1
+
+3	1	21
+	0	5	1
+	0	6	1
+	-1
+
+3	1	22
+	0	5	1
+	0	6	1
+	0	7	1
+	-1
+
+3	1	23
+	0	5	2
+	0	6	2
+	-1
+
+3	1	24
+	0	5	2
+	0	6	2
+	0	7	1
+	-1
+
+3	1	25
+	3	1	23
+	0	4	3
+	3	1	12
+	-1
+
+3	1	26
+	3	1	21
+	0	4	3
+	0	4	3
+	0	4	4
+	0	4	4
+	0	4	5
+	0	4	5
+	-1
+
+3	1	31
+	3	1	1
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	22
+	-1
+
+3	1	32
+	3	1	1
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	24
+	-1
+
+3	1	33
+	0	1	5
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	21
+	-1
+
+3	1	34
+	0	1	5
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	35
+	0	1	5
+	0	1	12
+	0	1	13
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	36
+	3	1	3
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	37
+	3	1	1
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	22
+	-1
+
+3	1	38
+	3	1	1
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	24
+	-1
+
+3	1	39
+	3	1	3
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	40
+	3	1	3
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	24
+	-1
+
+3	1	41
+	0	1	7
+	0	2	21
+	0	2	22
+	3	1	11
+	3	1	12
+	-1
+
+3	1	42
+	3	1	41
+	3	1	21
+	-1
+
+3	1	43
+	0	1	7
+	0	2	23
+	3	1	11
+	3	1	13
+	3	1	21
+	-1
+
+3	1	44
+	0	1	7
+	0	2	24
+	3	1	11
+	3	1	13
+	3	1	21
+	-1
+
+3	1	45
+	3	1	11
+	3	1	12
+	2	1	138
+	2	2	131
+	0	4	6
+	2	01	0
+	2	2	0
+	3	4	30
+	3	4	31
+	-1
+
+3	1	46
+	0	1	7
+	0	1	12
+	0	2	48
+	0	21	119
+	0	25	60
+	2	2	124
+	0	2	26
+	0	2	27
+	2	2	0
+	0	5	40
+	-1
+
+3	1	47
+	0	1	7
+	0	25	60
+	0	1	33
+	0	1	34
+	0	1	12
+	3	1	45
+	0	2	21
+	3	1	11
+	3	1	12
+	2	1	138
+	2	2	131
+	0	4	6
+	2	1	0
+	2	2	0
+	3	1	23
+	-1 
+
+3	1	48
+	0	2	104
+	0	2	121
+	0	2	113
+	0	2	26
+	0	2	27
+	0	2	111
+	0	2	140
+	2	2	127
+	0	1	13
+	2	2	126
+	0	7	1
+	2	2	0
+	0	25	10
+	0	21	64
+	-1
+
+3	1	49
+	0	2	111
+	0	2	112
+	0	21	62
+	0	21	63
+	0	21	65
+	-1
+
+3	1	51
+	0	1	6
+	0	2	61
+	3	1	11
+	3	1	12
+	3	1	21
+	0	8	4
+	-1
+
+3	1	55
+	0	1	5
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	21
+	0	1	12
+	0	1	14
+	-1
+
+3	1	62
+	1	1	0
+	0	31	1
+	3	1	1
+	-1
+
+3	1	65
+	0	1	6
+	0	1	8
+	0	2	1
+	0	2	2
+	0	2	5
+	0	2	62
+	0	2	70
+	0	2	65
+	-1
+
+3	1	66
+	3	1	11
+	3	1	13
+	3	1	23
+	0	7	4
+	0	2	64
+	0	8	4
+	-1
+
+3	1	71
+	0	1	7
+	0	1	31
+	0	1	20
+	0	1	28
+	0	1	29
+	-1
+
+3	1	72
+	3	1	71
+	3	1	11
+	3	1	13
+	3	1	21
+	-1
+
+3	1	193
+	0	1	7
+	0	1	31
+	0	2	196
+	0	2	221
+	0	2	222
+	-1
+
+3	1	194
+	0	1	194
+	0	1	12
+	0	1	13
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	23
+	0	7	1
+	-1
+
+ 3	1	195
+	0	1	195
+	0	1	12
+	0	1	13
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	23
+	0	7	1
+	-1
+
+ 3	1	196
+	3	1	3
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	23
+	0	7	1
+	-1
+
+ 3	1	197
+	0	1	6
+	0	1	8
+	0	2	61
+	0	2	62
+	0	2	2
+	0	2	5
+	0	2	70
+	0	2	63
+	0	2	1
+	-1
+
+ 3	1	200
+	0	1	32
+	0	33	194
+	-1
+
+ 3	1	201
+	1	1	3
+	0	33	193
+	-1
+
+ 3	1	202
+	0	1	31
+	0	1	32
+	-1
+
+ 3	1	237
+	0	1	7
+	0	1	12
+	0	2	21
+	3	1	11
+	0	4	4
+	0	4	5
+	2	1	138
+	2	2	131
+	0	4	6
+	2	1	0
+	2	2	0
+	3	1	23
+	-1
+
+ 3	1	238
+	0	2	104
+	0	2	121
+	0	2	113
+	0	2	26
+	0	2	27
+	0	2	111
+	0	2	192
+	2	2	127
+	0	1	13
+	2	2	126
+	0	7	001
+	2	2	0
+	0	25	10
+	0	21	194
+	-1
+
+ 3	1	239
+	0	2	111
+	0	2	112
+	0	21	192
+	0	21	193
+	0	21	195
+	-1
+
+ 3	1	240
+	2	1	131
+	2	2	129
+	0	22	21
+	2	1	0
+	2	2	0
+	-1
+
+ 3	1	241
+	2	1	141
+	2	2	130
+	0	7	1
+	2	1	0
+	2	2	0
+	-1
+
+ 3	1	242
+	0	21	207
+	0	21	208
+	0	21	209
+	0	21	210
+	0	21	211
+	0	21	212
+	-1
+
+ 3	1	250
+	3	1	193
+	3	1	11
+	3	1	13
+	3	1	21
+	-1
+
+3	2	1
+	0	10	4
+	0	10	51
+	0	10	61
+	0	10	63
+	-1
+
+3	2	2
+	0	10	4
+	0	7	4
+	0	10	3
+	0	10	61
+	0	10	63
+	-1
+
+3	2	3
+	0	11	11
+	0	11	12
+	0	12	4
+	0	12	6
+	0	13	3
+	0	20	1
+	0	20	3
+	0	20	4
+	0	20	5
+	-1
+
+3	2	4
+	0	20	10
+	0	8	2
+	0	20	11
+	0	20	13
+	0	20	12
+	0	20	12
+	0	20	12
+	-1
+
+3	2	5
+	0	8	2
+	0	20	11
+	0	20	12
+	0	20	13
+	-1
+
+3	2	6
+	0	10	4
+	0	10	51
+	0	10	62
+	0	10	63
+	-1
+
+3	2	11
+	3	2	1
+	3	2	3
+	3	2	4
+	-1
+
+3	2	12
+	3	2	2
+	3	2	3
+	3	2	4
+	-1
+
+3	2	13
+	3	2	6
+	3	2	3
+	1	1	0
+	0	31	1
+	3	2	5
+	-1
+
+3	2	21
+	0	22	1
+	0	22	11
+	0	22	21
+	-1
+
+3	2	22
+	0	22	2
+	0	22	12
+	0	22	22
+	-1
+
+3	2	23
+	0	22	3
+	0	22	13
+	0	22	23
+	-1
+
+3	2	24
+	3	2	22
+	1	1	2
+	3	2	23
+	-1
+
+3	2	51
+	0	10	4
+	0	10	51
+	0	7	4
+	0	10	3
+	0	12	4
+	0	12	51
+	0	12	16
+	0	12	17
+	0	13	4
+	1	2	4
+	0	8	51
+	0	8	20
+	-1
+
+3	2	205
+	2	1	131
+	2	2	129
+	0	22	21
+	2	1	0
+	2	2	0
+	-1
+
+3	2	206
+	3	2	205
+	2	1	130
+	2	2	129
+	0	22	11
+	2	1	0
+	2	2	0
+	0	22	1
+	0	11	1
+	0	11	2
+	-1
+
+3	2	207
+	0	22	193
+	0	22	194
+	0	22	195
+	0	22	196
+	0	22	197
+	-1
+
+3	2	250
+	1	2	0
+	0	31	1
+	0	20	193
+	0	20	194
+	0	20	12
+	-1
+
+3	3	1
+	0	7	3
+	0	11	1
+	0	11	2
+	-1
+
+3	3	2
+	0	7	4
+	0	11	1
+	0	11	2
+	-1
+
+3	3	3
+	0	7	4
+	0	10	3
+	0	12	1
+	0	12	3
+	-1
+
+3	3	4
+	0	7	4
+	0	10	3
+	0	12	1
+	0	12	3
+	0	11	1
+	0	11	2
+	-1
+
+3	3	11
+	0	7	3
+	0	8	1
+	0	11	1
+	0	11	2
+	-1
+
+3	3	12
+	0	7	4
+	0	8	1
+	0	11	1
+	0	11	2
+	-1
+
+3	3	13
+	0	7	4
+	0	8	1
+	0	10	3
+	0	12	1
+	0	13	3
+	0	11	1
+	0	11	2
+	-1
+
+3	3	14
+	0	7	4
+	0	8	1
+	0	10	3
+	0	12	1
+	0	12	3
+	0	11	1
+	0	11	2
+	-1
+
+3	3	21
+	0	7	4
+	0	7	4
+	2	4	7
+	0	31	21
+	-1
+
+3	3	22
+	3	3	21
+	0	10	3
+	2	4	0
+	-1
+
+3	3	23
+	3	3	21
+	0	12	1
+	2	4	0
+	-1
+
+3	3	24
+	3	3	21
+	0	13	16
+	2	4	0
+	-1
+
+3	3	25
+	0	2	25
+	2	4	7
+	0	31	21
+	0	12	63
+	2	4	0
+	-1
+
+3	3	26
+	0	7	4
+	0	8	3
+	2	4	7
+	0	31	21
+	0	12	1
+	2	4	0
+	-1
+
+3	3	27
+	0	7	4
+	2	4	7
+	0	31	21
+	0	10	3
+	2	4	0
+	-1
+
+3	3	31
+	0	7	4
+	0	8	3
+	0	7	21
+	0	7	22
+	0	8	12
+	0	12	61
+	-1
+
+3	3	32
+	0	20	11
+	0	20	16
+	-1
+
+3	3	33
+	0	20	10
+	0	20	16
+	-1
+
+3	3	41
+	0	2	152
+	0	2	23
+	0	7	4
+	0	11	1
+	0	11	2
+	0	2	153
+	0	2	154
+	0	12	71
+	-1
+
+3	3	249
+	0	2	252
+	1	4	0
+	0	31	1
+	0	2	199
+	0	7	4
+	0	7	4
+	0	13	3
+	-1
+
+3	3	250
+	0	2	252
+	0	2	23
+	0	7	4
+	0	11	1
+	0	11	2
+	0	2	197
+	0	2	198
+	0	12	193
+	-1
+
+3	3	251
+	0	2	252
+	1	5	0
+	0	31	1
+	0	2	254
+	0	2	251
+	0	2	197
+	0	2	198
+	0	12	63
+	-1
+
+3	3	252
+	0	2	252
+	1	5	0
+	0	31	1
+	0	2	254
+	0	2	251
+	0	2	197
+	0	2	198
+	0	12	194
+	-1
+
+3	4	1
+	0	8	3
+	0	10	4
+	0	12	1
+	0	11	1
+	0	11	2
+	-1
+
+3	4	2
+	0	8	3
+	0	10	4
+	0	11	1
+	0	11	2
+	-1
+
+3	4	3
+	0	8	3
+	0	12	1
+	-1
+
+3	4	4
+	0	8	3
+	0	10	4
+	0	20	10
+	0	12	1
+	-1
+
+3	4	5
+	0	2	24
+	0	7	4
+	0	7	4
+	0	13	3
+	-1
+
+3	4	6
+	0	14	1
+	0	14	1
+	0	14	3
+	-1
+
+3	4	11
+	0	2	163
+	0	2	164
+	0	8	12
+	0	7	24
+	0	2	167
+	0	8	21
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	8	21
+	0	4	24
+	1	10	4
+	0	8	21
+	0	4	4
+	0	4	5
+	0	4	6
+	0	8	21
+	0	4	4
+	0	4	5
+	0	4	6
+	0	11	1
+	0	11	2
+	1	3	10
+	0	2	163
+	0	7	4
+	0	12	1
+	-1
+
+3	4	30
+	0	27	31
+	0	28	31
+	0	10	31
+	-1
+
+3	4	31
+	0	1	41
+	0	1	42
+	0	1	43
+	-1
+
+3	4	32
+	0	2	151
+	0	2	154
+	0	20	81
+	0	20	82
+	0	20	12
+	-1
+
+3	4	33
+	0	2	152
+	0	2	166
+	0	2	167
+	0	2	153
+	0	2	154
+	0	12	75
+	0	12	76
+	0	12	63
+	-1
+
+3	4	34
+	1	2	4
+	0	27	1
+	0	28	1
+	0	7	22
+	0	5	43
+	0	20	10
+	0	20	16
+	0	33	3
+	0	10	40
+	-1
+
+3	4	228
+	0	5	217
+	0	6	217
+	0	7	217
+	-1
+
+3	4	229
+	0	1	208
+	0	1	209
+	0	1	210
+	-1
+
+3	4	250
+	0	2	231
+	0	2	232
+	0	8	12
+	0	7	24
+	0	2	57
+	0	8	21
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	8	21
+	0	4	24
+	1	10	4
+	0	8	21
+	0	4	4
+	0	4	5
+	0	4	6
+	0	8	21
+	0	4	4
+	0	4	5
+	0	4	6
+	0	11	1
+	0	11	2
+	1	3	10
+	0	2	231
+	0	7	4
+	0	12	1
+	-1
+
+3	6	1
+	0	2	32
+	1	2	0
+	0	31	1
+	0	7	62
+	0	22	42
+	-1
+
+3	6	2
+	0	2	31
+	0	22	4
+	0	22	31
+	-1
+
+3	6	3
+	0	2	2
+	0	11	11
+	0	11	12
+	0	12	4
+	-1
+
+3	6	4
+	0	2	32
+	0	2	33
+	1	3	0
+	0	31	1
+	0	7	62
+	0	22	43
+	0	22	62
+	-1
+
+3	6	5
+	0	2	31
+	1	3	0
+	0	31	1
+	0	7	62
+	0	22	4
+	0	22	31
+	-1
+
+3	6	6
+	3	6	3
+	3	6	2
+	0	22	63
+	-1
+
+3	6	7
+	0	1	12
+	0	1	14
+	3	6	8
+	0	4	24
+	0	27	3
+	0	28	3
+	-1
+
+3	6	8
+	0	2	34
+	0	2	35
+	0	2	36
+	-1
+
+3	6	20
+	3	6	24
+	1	2	6
+	0	22	38
+	0	22	39
+	-1
+
+3	6	21
+	0	1	75
+	3	1	11
+	3	1	12
+	0	22	122
+	0	22	123
+	0	12	1
+	3	3	2
+	-1
+
+3	6	22
+	0	1	75
+	3	1	11
+	3	1	12
+	0	22	38
+	0	22	39
+	-1
+
+3	6	23
+	0	1	15
+	3	1	23
+	3	1	11
+	3	1	12
+	0	22	38
+	0	22	39
+	0	22	120
+	0	22	121
+	-1
+
+3	6	24
+	0	1	75
+	3	1	11
+	3	1	12
+	0	22	42
+	0	22	120
+	0	22	121
+	0	4	25
+	0	4	15
+	-1
+
+3	7	1
+	3	1	31
+	3	2	11
+	-1
+
+3	7	2
+	3	1	32
+	3	2	11
+	-1
+
+3	7	3
+	3	7	1
+	1	1	0
+	0	31	1
+	3	2	5
+	-1
+
+3	7	4
+	3	7	2
+	1	1	0
+	0	31	1
+	3	2	5
+	-1
+
+3	7	5
+	3	7	1
+	1	1	4
+	3	2	5
+	-1
+
+3	7	6
+	3	7	2
+	1	1	4
+	3	2	5
+	-1
+
+3	7	7
+	3	1	31
+	3	2	12
+	-1
+
+3	7	8
+	3	1	32
+	3	2	12
+	-1
+
+3	7	9
+	3	1	31
+	3	2	13
+	-1
+
+3	7	11
+	0	1	63
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	24
+	0	7	6
+	0	11	1
+	0	11	16
+	0	11	17
+	0	11	2
+	0	11	41
+	0	7	6
+	0	12	1
+	0	12	3
+	0	10	52
+	0	20	9
+	-1
+
+3	7	12
+	1	3	0
+	0	31	1
+	0	8	23
+	0	5	21
+	0	20	1
+	-1
+
+3	7	13
+	1	6	0
+	0	31	1
+	0	1	64
+	0	8	14
+	0	20	61
+	0	8	14
+	0	20	61
+	0	20	18
+	-1
+
+3	7	14
+	1	1	0
+	0	31	1
+	0	20	19
+	-1
+
+3	7	15
+	1	1	0
+	0	31	1
+	3	2	5
+	0	8	2
+	0	20	11
+	0	20	12
+	0	20	13
+	0	20	2
+	-1
+
+3	7	16
+	1	1	0
+	0	31	1
+	0	20	20
+	-1
+
+3	7	17
+	1	1	0
+	0	31	1
+	0	11	70
+	-1
+
+3	7	18
+	0	8	16
+	1	2	0
+	0	31	1
+	0	8	17
+	3	1	12
+	1	4	0
+	0	31	1
+	0	7	6
+	0	11	1
+	0	11	2
+	0	11	41
+	0	20	9
+	1	1	0
+	0	31	1
+	0	20	1
+	3	7	14
+	-1
+
+3	7	20
+	3	7	11
+	3	7	14
+	3	7	16
+	-1
+
+3	7	21
+	3	7	11
+	3	7	12
+	3	7	13
+	3	7	14
+	3	7	15
+	3	7	16
+	3	7	17
+	3	7	18
+	3	7	15
+	-1
+
+3	8	1
+	3	1	33
+	3	2	11
+	0	22	42
+	-1
+
+3	8	2
+	3	1	34
+	3	2	11
+	0	22	42
+	-1
+
+3	8	3
+	3	1	35
+	3	2	11
+	0	22	42
+	-1
+
+3	8	4
+	3	1	36
+	3	2	11
+	0	22	42
+	-1
+
+3	8	5
+	3	8	4
+	3	2	24
+	-1
+
+3	8	6
+	0	10	4
+	0	10	61
+	0	10	63
+	0	11	1
+	0	11	2
+	0	12	4
+	0	13	3
+	0	22	42
+	-1
+
+3	8	7
+	3	1	55
+	3	2	11
+	0	7	62
+	0	22	42
+	-1
+
+3	9	1
+	3	1	37
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	2
+	3	1	38
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	3
+	3	1	37
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	4
+	3	1	38
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	5
+	3	1	37
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	6
+	3	1	38
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	7
+	3	1	37
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	8
+	3	1	38
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	11
+	3	1	39
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	12
+	3	1	39
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	13
+	3	1	39
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	14
+	3	1	39
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	15
+	3	1	40
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	16
+	3	1	40
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	17
+	3	1	40
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	18
+	3	1	40
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	19
+	3	1	31
+	0	2	3
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	20
+	3	1	31
+	0	2	3
+	1	4	0
+	0	31	1
+	0	7	3
+	0	11	3
+	0	11	4
+	0	11	5
+	-1
+
+3	9	194
+	3	1	194
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	195
+	3	1	195
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	196
+	3	1	196
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	10	1
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	26
+	3	3	25
+	-1
+
+3	10	2
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	9
+	3	3	23
+	-1
+
+3	10	3
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	6
+	3	3	23
+	-1
+
+3	10	4
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	3
+	3	3	24
+	-1
+
+3	10	5
+	3	1	42
+	3	3	31
+	3	3	33
+	1	1	0
+	0	31	1
+	3	03	25
+	-1
+
+3	10	6
+	3	1	42
+	3	3	31
+	3	3	33
+	1	1	0
+	0	31	1
+	3	3	23
+	-1
+
+3	10	7
+	3	1	42
+	3	3	31
+	3	3	33
+	1	1	0
+	0	31	1
+	3	3	24
+	-1
+
+3	10	8
+	3	10	11
+	1	1	19
+	3	10	12
+	0	2	150
+	0	25	79
+	0	25	80
+	0	33	32
+	0	14	45
+	-1
+
+3	10	9
+	3	10	11
+	1	1	15
+	3	10	12
+	-1
+
+3	10	10
+	3	10	11
+	1	1	5
+	3	10	12
+	-1
+
+3	10	11
+	0	8	70
+	0	1	33
+	0	1	34
+	0	8	70
+	0	1	33
+	0	1	34
+	0	1	7
+	0	2	48
+	0	5	40
+	0	25	75
+	2	1	133
+	0	5	41
+	2	1	0
+	0	5	43
+	0	25	70
+	0	33	30
+	0	33	31
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	4	5
+	2	2	131
+	2	1	138
+	0	4	6
+	2	1	0
+	2	2	0
+	0	5	1
+	0	6	1
+	2	2	126
+	0	7	1
+	2	2	0
+	0	7	24
+	0	5	21
+	0	7	25
+	0	5	22
+	0	33	33
+	0	2	151
+	0	12	64
+	0	2	151
+	0	12	64
+	0	2	151
+	0	12	64
+	0	2	151
+	0	12	64
+	0	2	151
+	0	12	64
+	-1
+
+3	10	12
+	0	2	150
+	0	25	76
+	0	25	77
+	0	25	78
+	0	33	32
+	2	1	132
+	2	2	129
+	0	12	63
+	2	2	0
+	2	1	0
+	-1
+
+3	10	13
+	0	1	7
+	0	5	40
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	4	5
+	0	4	6
+	0	5	1
+	0	6	1
+	0	7	25
+	0	5	43
+	0	25	85
+	2	1	131
+	2	2	129
+	0	2	150
+	0	8	23
+	0	8	72
+	0	14	27
+	0	8	72
+	0	14	27
+	0	2	150
+	0	8	23
+	0	8	72
+	0	14	27
+	0	8	72
+	0	14	27
+	0	2	150
+	0	8	23
+	0	8	72
+	0	14	27
+	0	8	72
+	0	14	27
+	2	2	0
+	2	1	0
+	2	1	132
+	2	2	129
+	0	2	150
+	0	8	23
+	0	8	72
+	0	12	63
+	0	8	72
+	0	12	63
+	0	2	150
+	0	8	23
+	0	8	72
+	0	12	63
+	0	8	72
+	0	12	63
+	0	8	23
+	0	8	72
+	0	12	63
+	0	8	72
+	0	12	63
+	0	2	150
+	0	8	23
+	0	8	72
+	0	12	63
+	0	8	72
+	0	12	63
+	2	2	0
+	2	1	0
+	-1
+
+3	10	14
+	3	1	72
+	3	3	41
+	3	4	11
+	-1
+
+3	10	15
+	3	1	72
+	0	7	24
+	0	10	2
+	3	3	41
+	1	1	3
+	3	4	32
+	0	2	152
+	0	2	24
+	0	7	4
+	0	7	4
+	0	13	3
+	1	1	3
+	3	4	33
+	-1
+
+3	10	16
+	3	1	72
+	0	7	24
+	0	10	2
+	3	3	41
+	1	1	12
+	3	4	32
+	0	2	152
+	0	2	24
+	0	7	4
+	0	7	4
+	0	13	3
+	1	1	12
+	3	4	33
+	-1
+
+3	10	20
+	3	10	22
+	3	1	11
+	3	1	13
+	3	1	21
+	3	4	34
+	3	10	21
+	-1
+
+3	10	21
+	1	8	0
+	0	31	1
+	2	1	131
+	2	2	129
+	0	7	4
+	0	7	4
+	2	2	0
+	2	1	0
+	0	15	20
+	0	10	2
+	-1
+
+3	10	22
+	0	1	7
+	0	2	19
+	0	1	33
+	0	2	172
+	-1
+
+3	10	193
+	3	1	250
+	3	3	250
+	3	2	250
+	3	3	249
+	3	3	251
+	-1
+
+3	10	194
+	3	1	250
+	3	3	250
+	3	2	250
+	3	3	249
+	3	3	252
+	-1
+
+3	10	195
+	3	1	250
+	3	3	250
+	3	4	250
+	-1
+
+3	10	196
+	3	1	250
+	3	3	249
+	3	3	251
+	-1
+
+3	11	1
+	3	1	51
+	0	7	2
+	0	12	1
+	0	11	1
+	0	11	2
+	0	11	31
+	0	11	32
+	0	11	33
+	0	20	41
+	-1
+
+3	11	2
+	3	1	65
+	3	1	66
+	3	11	3
+	3	11	4
+	-1
+
+3	11	3
+	0	10	70
+	0	11	1
+	0	11	2
+	0	12	1
+	0	13	2
+	-1
+
+3	11	4
+	1	1	0
+	0	31	0
+	0	11	34
+	1	1	0
+	0	31	0
+	0	11	35
+	1	1	0
+	0	31	0
+	0	11	75
+	1	1	0
+	0	31	0
+	0	11	76
+	1	1	0
+	0	31	0
+	0	33	25
+	1	1	0
+	0	31	0
+	0	33	26
+	-1
+
+3	11	193
+	3	1	197
+	3	1	011
+	3	1	012
+	3	1	023
+	0	8	004
+	0	7	004
+	0	8	021
+	0	11	001
+	0	11	002
+	0	11	031
+	0	11	034
+	0	11	035
+	0	12	001
+	0	12	003
+	0	13	003
+	0	20	041
+	-1
+
+3	12	1
+	3	1	43
+	3	4	1
+	-1
+
+3	12	2
+	3	1	43
+	3	4	2
+	-1
+
+3	12	3
+	3	1	42
+	3	4	3
+	-1
+
+3	12	4
+	3	1	42
+	3	4	4
+	-1
+
+3	12	5
+	3	1	42
+	0	20	14
+	-1
+
+3	12	6
+	3	1	44
+	3	4	5
+	-1
+
+3	12	7
+	3	1	42
+	3	4	6
+	-1
+
+3	12	10
+	0	1	7
+	0	5	40
+	0	2	21
+	0	5	41
+	0	4	1
+	0	4	43
+	-1
+
+3	12	11
+	2	2	131
+	2	1	149
+	0	4	6
+	2	1	0
+	2	2	126
+	0	10	2
+	2	2	0
+	0	5	43
+	0	5	53
+	-1
+
+3	12	12
+	2	2	129
+	2	1	132
+	1	1	19
+	0	12	63
+	2	1	0
+	2	2	0
+	-1
+
+3	12	13
+	0	5	42
+	2	2	129
+	2	1	135
+	0	12	63
+	2	1	0
+	2	2	0
+	-1
+
+3	12	14
+	3	12	10
+	3	12	11
+	1	5	56
+	3	1	23
+	0	5	42
+	0	5	52
+	3	12	12
+	3	12	13
+	-1
+
+3	12	15
+	1	9	11
+	3	1	23
+	0	5	42
+	0	5	52
+	2	2	129
+	2	1	132
+	1	1	4
+	0	12	63
+	2	2	0
+	2	1	0
+	-1
+
+3	12	16
+	3	12	10
+	3	12	11
+	3	12	15
+	-1
+
+3	12	17
+	1	9	8
+	3	1	23
+	0	5	42
+	0	5	52
+	2	2	129
+	2	1	132
+	1	1	3
+	0	12	63
+	2	2	0
+	2	1	0
+	-1
+
+3	12	18
+	3	12	10
+	3	12	11
+	3	12	17
+	-1
+
+3	12	19
+	3	1	47
+	3	1	48
+	0	15	15
+	0	29	2
+	0	21	76
+	1	6	12
+	2	1	129
+	0	6	30
+	2	1	0
+	1	2	12
+	0	5	30
+	0	21	75
+	0	21	66
+	-1
+
+3	12	20
+	3	1	47
+	3	1	48
+	0	15	15
+	0	29	2
+	0	21	76
+	1	4	12
+	0	6	30
+	1	2	12
+	0	5	30
+	0	21	75
+	0	21	66
+	-1
+
+3	12	21
+	3	1	47
+	1	1	3
+	3	1	49
+	0	11	12
+	0	11	11
+	0	21	67
+	-1
+
+3	12	22
+	3	1	47
+	0	8	22
+	0	11	12
+	0	11	50
+	0	22	70
+	0	22	26
+	3	12	41
+	0	10	50
+	0	21	68
+	0	21	71
+	0	21	72
+	0	21	73
+	3	12	42
+	0	21	62
+	0	15	11
+	-1
+
+3	12	23
+	3	1	47
+	1	3	3
+	0	8	22
+	0	12	61
+	0	22	50
+	0	21	69
+	0	21	85
+	-1
+
+3	12	24
+	3	12	20
+	0	8	60
+	0	8	22
+	0	8	60
+	0	8	22
+	0	25	14
+	0	22	101
+	0	22	97
+	0	22	98
+	0	22	99
+	0	22	100
+	-1
+
+3	12	25
+	3	12	19
+	0	8	60
+	0	8	22
+	0	8	60
+	0	8	22
+	0	25	14
+	0	22	101
+	0	22	97
+	0	22	98
+	0	22	99
+	0	22	100
+	-1
+
+3	12	26
+	3	1	46
+	3	1	11
+	3	1	13
+	3	10	23
+	3	12	31
+	1	1	4
+	3	12	30
+	0	21	110
+	3	1	23
+	3	21	27
+	0	21	111
+	3	1	23
+	3	21	27
+	0	21	111
+	3	1	23
+	3	21	27
+	0	21	113
+	3	1	23
+	3	21	27
+	-1
+
+3	12	27
+	3	1	47
+	1	5	9
+	3	1	23
+	0	7	21
+	0	12	61
+	0	7	21
+	0	12	61
+	0	21	85
+	0	21	70
+	-1
+
+3	12	28
+	3	1	46
+	3	1	11
+	3	1	13
+	3	1	23
+	0	8	25
+	2	1	136
+	0	4	6
+	2	1	0
+	3	12	31
+	3	12	32
+	1	1	4
+	3	12	30
+	1	1	2
+	3	12	33
+	0	21	110
+	3	1	23
+	3	21	28
+	0	21	111
+	3	1	23
+	3	21	28
+	0	21	112
+	3	1	23
+	3	21	28
+	0	21	113
+	3	1	23
+	3	21	28
+	-1
+
+3	12	30
+	2	1	130
+	2	2	129
+	0	11	12
+	2	2	0
+	2	1	0
+	0	11	52
+	2	1	135
+	2	2	130
+	0	11	11
+	2	2	0
+	2	1	0
+	0	11	53
+	0	21	104
+	-1
+
+3	12	31
+	0	5	34
+	0	6	34
+	0	21	109
+	0	11	81
+	0	11	82
+	0	21	101
+	0	21	102
+	0	21	103
+	-1
+
+3	12	32
+	0	21	120
+	0	21	121
+	0	13	55
+	0	21	122
+	-1
+
+3	12	33
+	0	2	104
+	0	8	22
+	0	12	63
+	0	12	65
+	-1
+
+3	12	41
+	2	1	141
+	2	2	130
+	0	7	1
+	2	1	00
+	2	2	00
+	-1
+
+3	12	42
+	0	21	77
+	0	21	78
+	0	21	79
+	0	21	80
+	0	21	81
+	0	21	82
+	-1
+
+3	13	9
+	0	21	1
+	1	1	0
+	0	31	1
+	0	21	1
+	-1
+
+3	13	10
+	0	21	36
+	1	1	0
+	0	31	1
+	0	21	36
+	-1
+
+3	13	31
+	0	6	2
+	0	6	12
+	1	1	0
+	0	31	2
+	0	30	1
+	-1
+
+3	13	32
+	0	5	2
+	0	5	12
+	1	1	0
+	0	31	2
+	3	13	31
+	-1
+
+3	13	41
+	0	6	2
+	1	10	0
+	0	31	1
+	1	4	0
+	0	31	1
+	0	6	12
+	1	1	0
+	0	31	12
+	0	30	1
+	0	6	12
+	1	1	0
+	0	31	1
+	0	30	1
+	-1
+
+3	13	42
+	0	5	2
+	0	5	12
+	1	1	0
+	0	31	2
+	3	13	41
+	-1
+
+3	13	43
+	0	6	2
+	0	5	2
+	0	5	12
+	1	12	0
+	0	31	1
+	1	10	0
+	0	31	1
+	1	04	0
+	0	31	1
+	0	6	12
+	1	1	0
+	0	31	11
+	0	30	1
+	1	1	0
+	0	31	1
+	0	30	1
+	-1
+	
+3	15	1
+	0	1	11
+	3	1	11
+	3	1	12
+	3	1	23
+	3	6	1
+	-1
+
+3	15	2
+	0	1	11
+	3	1	11
+	3	1	12
+	3	1	23
+	3	6	4
+	-1
+
+3	16	1
+	3	1	11
+	0	4	4
+	3	1	23
+	0	1	21
+	0	2	41
+	0	19	1
+	0	10	51
+	0	19	2
+	0	19	3
+	0	19	4
+	-1
+
+3	16	2
+	0	8	21
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	4	5
+	0	1	33
+	0	8	21
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	4	5
+	0	7	2
+	0	7	2
+	-1
+
+3	16	3
+	1	10	0
+	0	31	1
+	0	8	11
+	0	8	7
+	1	4	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	10	2
+	0	11	2
+	0	8	7
+	0	8	11
+	-1
+
+3	16	4
+	1	11	0
+	0	31	1
+	0	8	11
+	0	8	7
+	0	7	2
+	0	7	2
+	1	2	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	11	31
+	0	8	7
+	0	8	11
+	-1
+
+3	16	5
+	1	8	0
+	0	31	1
+	0	8	5
+	0	8	7
+	0	5	2
+	0	6	2
+	0	1	26
+	0	19	1
+	0	8	7
+	0	8	5
+	-1
+
+3	16	6
+	1	12	0
+	0	31	1
+	0	8	11
+	0	8	7
+	0	7	2
+	0	7	2
+	1	2	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	20	11
+	0	20	12
+	0	8	7
+	0	8	11
+	-1
+
+3	16	7
+	1	10	0
+	0	31	1
+	0	8	11
+	0	8	7
+	1	4	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	19	5
+	0	19	6
+	0	8	7
+	0	8	11
+	-1
+
+3	16	8
+	1	11	0
+	0	31	1
+	0	8	1
+	0	8	7
+	0	8	23
+	1	3	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	10	2
+	0	8	23
+	0	8	7
+	0	8	1
+	-1
+
+3	16	9
+	1	11	0
+	0	31	1
+	0	8	11
+	0	8	7
+	0	7	2
+	0	7	2
+	1	2	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	20	41
+	0	8	7
+	0	8	11
+	-1
+
+3	16	10
+	1	7	0
+	0	31	1
+	0	8	11
+	0	8	7
+	0	1	22
+	0	5	2
+	0	6	2
+	0	8	7
+	0	8	11
+	-1
+
+3	16	11
+	1	16	0
+	0	31	1
+	0	8	11
+	0	1	22
+	0	8	7
+	1	2	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	8	21
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	4	5
+	0	20	90
+	0	8	21
+	0	8	7
+	0	8	11
+	-1
+
+3	18	1
+	3	1	25
+	0	24	11
+	-1
+
+3	18	3
+	3	1	26
+	0	24	5
+	0	24	4
+	0	24	21
+	-1
+
+3	18	4
+	3	1	25
+	0	4	23
+	0	13	11
+	0	24	5
+	0	24	4
+	0	24	22
+	-1
+
+3	21	1
+	0	2	101
+	0	2	114
+	0	2	105
+	0	2	106
+	0	2	107
+	0	2	121
+	-1
+
+3	21	3
+	0	21	51
+	0	21	14
+	0	21	17
+	0	21	30
+	-1
+
+3	21	4
+	3	1	31
+	0	2	3
+	1	1	0
+	0	31	1
+	3	21	3
+	-1
+
+3	21	5
+	0	25	4
+	0	2	121
+	0	2	122
+	0	2	123
+	0	2	124
+	0	2	125
+	0	2	126
+	0	2	127
+	0	2	128
+	0	2	129
+	0	2	130
+	0	2	131
+	-1
+
+3	21	6
+	0	25	1
+	0	25	2
+	0	25	3
+	0	25	5
+	-1
+
+3	21	7
+	0	25	9
+	0	25	10
+	0	25	11
+	0	25	12
+	0	25	13
+	0	25	15
+	0	25	16
+	0	25	17
+	-1
+
+3	21	8
+	0	25	6
+	0	25	7
+	0	25	8
+	-1
+
+3	21	9
+	0	25	18
+	0	25	19
+	-1
+
+3	21	10
+	0	2	101
+	0	7	2
+	0	2	102
+	0	2	103
+	0	2	104
+	0	2	105
+	0	2	106
+	0	2	107
+	0	2	108
+	0	2	109
+	0	2	110
+	0	2	132
+	0	2	133
+	-1
+
+3	21	11
+	0	30	31
+	0	30	32
+	0	29	2
+	-1
+
+3	21	12
+	1	1	0
+	0	31	1
+	0	2	135
+	-1
+
+3	21	21	
+	0	2	3
+	0	2	101
+	2	1	130
+	0	2	106
+	2	1	0
+	2	1	132
+	2	2	130
+	0	2	121
+	2	2	0
+	2	1	0
+	2	1	133
+	2	2	129
+	0	25	1
+	2	2	0
+	2	1	0
+	-1
+
+3	21	22
+	0	10	7
+	2	4	1
+	0	31	21
+	0	11	1
+	2	4	0
+	0	11	2
+	2	4	1
+	0	31	21
+	0	11	6
+	2	4	0
+	0	21	30
+	-1		
+
+3	21	23
+	0	7	7
+	0	21	91
+	0	21	30
+	2	2	129
+	0	21	14
+	2	1	129
+	0	21	17
+	2	2	0
+	2	1	0
+	-1		
+
+3	21	24
+	0	7	7
+	2	4	1
+	0	31	21
+	0	12	7
+	0	11	6
+	2	4	0
+	0	21	30
+	-1		
+
+3	21	025
+	0	07	7
+	0	21	91
+	0	21	30
+	2	02	129
+	0	21	14
+	2	01	129
+	0	21	17
+	2	02	0
+	2	01	0
+	0	21	92
+	0	21	30
+	0	25	92
+	2	01	129
+	2	02	129
+	0	21	17
+	2	02	0
+	2	01	0
+	-1		
+
+3	21	26
+	0	10	7
+	2	4	1
+	0	31	21
+	0	12	7
+	0	25	91
+	0	11	71
+	0	11	72
+	0	11	73
+	0	11	74
+	2	4	0
+	-1
+
+3	21	27
+	0	21	118
+	2	2	129
+	2	1	132
+	0	2	112
+	2	1	0
+	2	1	131
+	0	2	111
+	2	1	0
+	2	2	0
+	0	2	104
+	0	21	105
+	0	21	106
+	0	21	107
+	0	21	114
+	0	21	115
+	0	21	116
+	0	8	18
+	0	21	117
+	-1
+
+3	21	28
+	0	21	118
+	2	2	129
+	2	1	132
+	0	2	112
+	2	1	0
+	2	1	131
+	0	2	111
+	2	1	0
+	2	2	0
+	0	2	104
+	0	21	123
+	0	21	106
+	0	21	107
+	0	21	114
+	0	21	115
+	0	21	116
+	0	8	18
+	0	21	117
+	-1
+
diff --git a/data/tables/B3L-160000-006001-D.txt b/data/tables/B3L-160000-006001-D.txt
new file mode 100644
index 0000000..954cc33
--- /dev/null
+++ b/data/tables/B3L-160000-006001-D.txt
@@ -0,0 +1,2673 @@
+#
+# BUFR Table D (Lists of Common Sequences)
+#
+# Descriptor sequences are terminated with -1
+#
+# Sequences do not need to appear in any order.  Sequence A
+# which includes sequence B, may appear before sequence B
+# is defined.
+#
+3	0	2
+	0	0	2
+	0	0	3
+	-1
+
+3	0	3
+	0	0	10
+	0	0	11
+	0	0	12
+	-1
+
+3	0	4
+	3	0	3
+	0	0	13
+	0	0	14
+	0	0	15
+	0	0	16
+	0	0	17
+	0	0	18
+	0	0	19
+	0	0	20
+	-1
+
+3	0	10
+	3	0	3
+	1	1	0
+	0	31	1
+	0	0	30
+	-1
+
+3	1	1
+	0	1	1
+	0	1	2
+	-1
+
+3	1	2
+	0	1	3
+	0	1	4
+	0	1	5
+	-1
+
+3	1	3
+	0	1	11
+	0	1	12
+	0	1	13
+	-1
+
+3	1	11
+	0	4	1
+	0	4	2
+	0	4	3
+	-1
+
+3	1	12
+	0	4	4
+	0	4	5
+	-1
+
+3	1	13
+	0	4	4
+	0	4	5
+	0	4	6
+	-1
+
+3	1	21
+	0	5	1
+	0	6	1
+	-1
+
+3	1	22
+	0	5	1
+	0	6	1
+	0	7	1
+	-1
+
+3	1	23
+	0	5	2
+	0	6	2
+	-1
+
+3	1	24
+	0	5	2
+	0	6	2
+	0	7	1
+	-1
+
+3	1	25
+	3	1	23
+	0	4	3
+	3	1	12
+	-1
+
+3	1	26
+	3	1	21
+	0	4	3
+	0	4	3
+	0	4	4
+	0	4	4
+	0	4	5
+	0	4	5
+	-1
+
+3	1	31
+	3	1	1
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	22
+	-1
+
+3	1	32
+	3	1	1
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	24
+	-1
+
+3	1	33
+	0	1	5
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	21
+	-1
+
+3	1	34
+	0	1	5
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	35
+	0	1	5
+	0	1	12
+	0	1	13
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	36
+	3	1	3
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	37
+	3	1	1
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	22
+	-1
+
+3	1	38
+	3	1	1
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	24
+	-1
+
+3	1	39
+	3	1	3
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	40
+	3	1	3
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	24
+	-1
+
+3	1	41
+	0	1	7
+	0	2	21
+	0	2	22
+	3	1	11
+	3	1	12
+	-1
+
+3	1	42
+	3	1	41
+	3	1	21
+	-1
+
+3	1	43
+	0	1	7
+	0	2	23
+	3	1	11
+	3	1	13
+	3	1	21
+	-1
+
+3	1	44
+	0	1	7
+	0	2	24
+	3	1	11
+	3	1	13
+	3	1	21
+	-1
+
+3	1	45
+	3	1	11
+	3	1	12
+	2	1	138
+	2	2	131
+	0	4	6
+	2	01	0
+	2	2	0
+	3	4	30
+	3	4	31
+	-1
+
+3	1	46
+	0	1	7
+	0	1	12
+	0	2	48
+	0	21	119
+	0	25	60
+	2	2	124
+	0	2	26
+	0	2	27
+	2	2	0
+	0	5	40
+	-1
+
+3	1	47
+	0	1	7
+	0	25	60
+	0	1	33
+	0	1	34
+	0	1	12
+	3	1	45
+	0	2	21
+	3	1	11
+	3	1	12
+	2	1	138
+	2	2	131
+	0	4	6
+	2	1	0
+	2	2	0
+	3	1	23
+	-1 
+
+3	1	48
+	0	2	104
+	0	2	121
+	0	2	113
+	0	2	26
+	0	2	27
+	0	2	111
+	0	2	140
+	2	2	127
+	0	1	13
+	2	2	126
+	0	7	1
+	2	2	0
+	0	25	10
+	0	21	64
+	-1
+
+3	1	49
+	0	2	111
+	0	2	112
+	0	21	62
+	0	21	63
+	0	21	65
+	-1
+
+3	1	51
+	0	1	6
+	0	2	61
+	3	1	11
+	3	1	12
+	3	1	21
+	0	8	4
+	-1
+
+3	1	55
+	0	1	5
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	21
+	0	1	12
+	0	1	14
+	-1
+
+3	1	62
+	1	1	0
+	0	31	1
+	3	1	1
+	-1
+
+3	1	65
+	0	1	6
+	0	1	8
+	0	2	1
+	0	2	2
+	0	2	5
+	0	2	62
+	0	2	70
+	0	2	65
+	-1
+
+3	1	66
+	3	1	11
+	3	1	13
+	3	1	23
+	0	7	4
+	0	2	64
+	0	8	4
+	-1
+
+3	1	71
+	0	1	7
+	0	1	31
+	0	1	20
+	0	1	28
+	0	1	29
+	-1
+
+3	1	72
+	3	1	71
+	3	1	11
+	3	1	13
+	3	1	21
+	-1
+
+3	1	193
+	0	1	7
+	0	1	31
+	0	2	196
+	0	2	221
+	0	2	222
+	-1
+
+3	1	194
+	0	1	194
+	0	1	12
+	0	1	13
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	23
+	0	7	1
+	-1
+
+ 3	1	195
+	0	1	195
+	0	1	12
+	0	1	13
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	23
+	0	7	1
+	-1
+
+ 3	1	196
+	3	1	3
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	23
+	0	7	1
+	-1
+
+ 3	1	197
+	0	1	6
+	0	1	8
+	0	2	61
+	0	2	62
+	0	2	2
+	0	2	5
+	0	2	70
+	0	2	63
+	0	2	1
+	-1
+
+ 3	1	200
+	0	1	32
+	0	33	194
+	-1
+
+ 3	1	201
+	1	1	3
+	0	33	193
+	-1
+
+ 3	1	202
+	0	1	31
+	0	1	32
+	-1
+
+ 3	1	237
+	0	1	7
+	0	1	12
+	0	2	21
+	3	1	11
+	0	4	4
+	0	4	5
+	2	1	138
+	2	2	131
+	0	4	6
+	2	1	0
+	2	2	0
+	3	1	23
+	-1
+
+ 3	1	238
+	0	2	104
+	0	2	121
+	0	2	113
+	0	2	26
+	0	2	27
+	0	2	111
+	0	2	192
+	2	2	127
+	0	1	13
+	2	2	126
+	0	7	001
+	2	2	0
+	0	25	10
+	0	21	194
+	-1
+
+ 3	1	239
+	0	2	111
+	0	2	112
+	0	21	192
+	0	21	193
+	0	21	195
+	-1
+
+ 3	1	240
+	2	1	131
+	2	2	129
+	0	22	21
+	2	1	0
+	2	2	0
+	-1
+
+ 3	1	241
+	2	1	141
+	2	2	130
+	0	7	1
+	2	1	0
+	2	2	0
+	-1
+
+ 3	1	242
+	0	21	207
+	0	21	208
+	0	21	209
+	0	21	210
+	0	21	211
+	0	21	212
+	-1
+
+ 3	1	250
+	3	1	193
+	3	1	11
+	3	1	13
+	3	1	21
+	-1
+
+3	2	1
+	0	10	4
+	0	10	51
+	0	10	61
+	0	10	63
+	-1
+
+3	2	2
+	0	10	4
+	0	7	4
+	0	10	3
+	0	10	61
+	0	10	63
+	-1
+
+3	2	3
+	0	11	11
+	0	11	12
+	0	12	4
+	0	12	6
+	0	13	3
+	0	20	1
+	0	20	3
+	0	20	4
+	0	20	5
+	-1
+
+3	2	4
+	0	20	10
+	0	8	2
+	0	20	11
+	0	20	13
+	0	20	12
+	0	20	12
+	0	20	12
+	-1
+
+3	2	5
+	0	8	2
+	0	20	11
+	0	20	12
+	0	20	13
+	-1
+
+3	2	6
+	0	10	4
+	0	10	51
+	0	10	62
+	0	10	63
+	-1
+
+3	2	11
+	3	2	1
+	3	2	3
+	3	2	4
+	-1
+
+3	2	12
+	3	2	2
+	3	2	3
+	3	2	4
+	-1
+
+3	2	13
+	3	2	6
+	3	2	3
+	1	1	0
+	0	31	1
+	3	2	5
+	-1
+
+3	2	21
+	0	22	1
+	0	22	11
+	0	22	21
+	-1
+
+3	2	22
+	0	22	2
+	0	22	12
+	0	22	22
+	-1
+
+3	2	23
+	0	22	3
+	0	22	13
+	0	22	23
+	-1
+
+3	2	24
+	3	2	22
+	1	1	2
+	3	2	23
+	-1
+
+3	2	51
+	0	10	4
+	0	10	51
+	0	7	4
+	0	10	3
+	0	12	4
+	0	12	51
+	0	12	16
+	0	12	17
+	0	13	4
+	1	2	4
+	0	8	51
+	0	8	20
+	-1
+
+3	2	205
+	2	1	131
+	2	2	129
+	0	22	21
+	2	1	0
+	2	2	0
+	-1
+
+3	2	206
+	3	2	205
+	2	1	130
+	2	2	129
+	0	22	11
+	2	1	0
+	2	2	0
+	0	22	1
+	0	11	1
+	0	11	2
+	-1
+
+3	2	207
+	0	22	193
+	0	22	194
+	0	22	195
+	0	22	196
+	0	22	197
+	-1
+
+3	2	250
+	1	2	0
+	0	31	1
+	0	20	193
+	0	20	194
+	0	20	12
+	-1
+
+3	3	1
+	0	7	3
+	0	11	1
+	0	11	2
+	-1
+
+3	3	2
+	0	7	4
+	0	11	1
+	0	11	2
+	-1
+
+3	3	3
+	0	7	4
+	0	10	3
+	0	12	1
+	0	12	3
+	-1
+
+3	3	4
+	0	7	4
+	0	10	3
+	0	12	1
+	0	12	3
+	0	11	1
+	0	11	2
+	-1
+
+3	3	11
+	0	7	3
+	0	8	1
+	0	11	1
+	0	11	2
+	-1
+
+3	3	12
+	0	7	4
+	0	8	1
+	0	11	1
+	0	11	2
+	-1
+
+3	3	13
+	0	7	4
+	0	8	1
+	0	10	3
+	0	12	1
+	0	13	3
+	0	11	1
+	0	11	2
+	-1
+
+3	3	14
+	0	7	4
+	0	8	1
+	0	10	3
+	0	12	1
+	0	12	3
+	0	11	1
+	0	11	2
+	-1
+
+3	3	21
+	0	7	4
+	0	7	4
+	2	4	7
+	0	31	21
+	-1
+
+3	3	22
+	3	3	21
+	0	10	3
+	2	4	0
+	-1
+
+3	3	23
+	3	3	21
+	0	12	1
+	2	4	0
+	-1
+
+3	3	24
+	3	3	21
+	0	13	16
+	2	4	0
+	-1
+
+3	3	25
+	0	2	25
+	2	4	7
+	0	31	21
+	0	12	63
+	2	4	0
+	-1
+
+3	3	26
+	0	7	4
+	0	8	3
+	2	4	7
+	0	31	21
+	0	12	1
+	2	4	0
+	-1
+
+3	3	27
+	0	7	4
+	2	4	7
+	0	31	21
+	0	10	3
+	2	4	0
+	-1
+
+3	3	31
+	0	7	4
+	0	8	3
+	0	7	21
+	0	7	22
+	0	8	12
+	0	12	61
+	-1
+
+3	3	32
+	0	20	11
+	0	20	16
+	-1
+
+3	3	33
+	0	20	10
+	0	20	16
+	-1
+
+3	3	41
+	0	2	152
+	0	2	23
+	0	7	4
+	0	11	1
+	0	11	2
+	0	2	153
+	0	2	154
+	0	12	71
+	-1
+
+3	3	249
+	0	2	252
+	1	4	0
+	0	31	1
+	0	2	199
+	0	7	4
+	0	7	4
+	0	13	3
+	-1
+
+3	3	250
+	0	2	252
+	0	2	23
+	0	7	4
+	0	11	1
+	0	11	2
+	0	2	197
+	0	2	198
+	0	12	193
+	-1
+
+3	3	251
+	0	2	252
+	1	5	0
+	0	31	1
+	0	2	254
+	0	2	251
+	0	2	197
+	0	2	198
+	0	12	63
+	-1
+
+3	3	252
+	0	2	252
+	1	5	0
+	0	31	1
+	0	2	254
+	0	2	251
+	0	2	197
+	0	2	198
+	0	12	194
+	-1
+
+3	4	1
+	0	8	3
+	0	10	4
+	0	12	1
+	0	11	1
+	0	11	2
+	-1
+
+3	4	2
+	0	8	3
+	0	10	4
+	0	11	1
+	0	11	2
+	-1
+
+3	4	3
+	0	8	3
+	0	12	1
+	-1
+
+3	4	4
+	0	8	3
+	0	10	4
+	0	20	10
+	0	12	1
+	-1
+
+3	4	5
+	0	2	24
+	0	7	4
+	0	7	4
+	0	13	3
+	-1
+
+3	4	6
+	0	14	1
+	0	14	1
+	0	14	3
+	-1
+
+3	4	11
+	0	2	163
+	0	2	164
+	0	8	12
+	0	7	24
+	0	2	167
+	0	8	21
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	8	21
+	0	4	24
+	1	10	4
+	0	8	21
+	0	4	4
+	0	4	5
+	0	4	6
+	0	8	21
+	0	4	4
+	0	4	5
+	0	4	6
+	0	11	1
+	0	11	2
+	1	3	10
+	0	2	163
+	0	7	4
+	0	12	1
+	-1
+
+3	4	30
+	0	27	31
+	0	28	31
+	0	10	31
+	-1
+
+3	4	31
+	0	1	41
+	0	1	42
+	0	1	43
+	-1
+
+3	4	32
+	0	2	151
+	0	2	154
+	0	20	81
+	0	20	82
+	0	20	12
+	-1
+
+3	4	33
+	0	2	152
+	0	2	166
+	0	2	167
+	0	2	153
+	0	2	154
+	0	12	75
+	0	12	76
+	0	12	63
+	-1
+
+3	4	34
+	1	2	4
+	0	27	1
+	0	28	1
+	0	7	22
+	0	5	43
+	0	20	10
+	0	20	16
+	0	33	3
+	0	10	40
+	-1
+
+3	4	228
+	0	5	217
+	0	6	217
+	0	7	217
+	-1
+
+3	4	229
+	0	1	208
+	0	1	209
+	0	1	210
+	-1
+
+3	4	250
+	0	2	231
+	0	2	232
+	0	8	12
+	0	7	24
+	0	2	57
+	0	8	21
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	8	21
+	0	4	24
+	1	10	4
+	0	8	21
+	0	4	4
+	0	4	5
+	0	4	6
+	0	8	1
+	0	4	4
+	0	4	5
+	0	4	6
+	0	11	1
+	0	11	2
+	1	3	10
+	0	2	231
+	0	7	4
+	0	12	1
+	-1
+
+3	6	1
+	0	2	32
+	1	2	0
+	0	31	1
+	0	7	62
+	0	22	42
+	-1
+
+3	6	2
+	0	2	31
+	0	22	4
+	0	22	31
+	-1
+
+3	6	3
+	0	2	2
+	0	11	11
+	0	11	12
+	0	12	4
+	-1
+
+3	6	4
+	0	2	32
+	0	2	33
+	1	3	0
+	0	31	1
+	0	7	62
+	0	22	43
+	0	22	62
+	-1
+
+3	6	5
+	0	2	31
+	1	3	0
+	0	31	1
+	0	7	62
+	0	22	4
+	0	22	31
+	-1
+
+3	6	6
+	3	6	3
+	3	6	2
+	0	22	63
+	-1
+
+3	6	7
+	0	1	12
+	0	1	14
+	3	6	8
+	0	4	24
+	0	27	3
+	0	28	3
+	-1
+
+3	6	8
+	0	2	34
+	0	2	35
+	0	2	36
+	-1
+
+3	6	20
+	3	6	24
+	1	2	6
+	0	22	38
+	0	22	39
+	-1
+
+3	6	21
+	0	1	75
+	3	1	11
+	3	1	12
+	0	22	122
+	0	22	123
+	0	12	1
+	3	3	2
+	-1
+
+3	6	22
+	0	1	75
+	3	1	11
+	3	1	12
+	0	22	38
+	0	22	39
+	-1
+
+3	6	23
+	0	1	15
+	3	1	23
+	3	1	11
+	3	1	12
+	0	22	38
+	0	22	39
+	0	22	120
+	0	22	121
+	-1
+
+3	6	24
+	0	1	75
+	3	1	11
+	3	1	12
+	0	22	42
+	0	22	120
+	0	22	121
+	0	4	25
+	0	4	15
+	-1
+
+3	7	1
+	3	1	31
+	3	2	11
+	-1
+
+3	7	2
+	3	1	32
+	3	2	11
+	-1
+
+3	7	3
+	3	7	1
+	1	1	0
+	0	31	1
+	3	2	5
+	-1
+
+3	7	4
+	3	7	2
+	1	1	0
+	0	31	1
+	3	2	5
+	-1
+
+3	7	5
+	3	7	1
+	1	1	4
+	3	2	5
+	-1
+
+3	7	6
+	3	7	2
+	1	1	4
+	3	2	5
+	-1
+
+3	7	7
+	3	1	31
+	3	2	12
+	-1
+
+3	7	8
+	3	1	32
+	3	2	12
+	-1
+
+3	7	9
+	3	1	31
+	3	2	13
+	-1
+
+3	7	11
+	0	1	63
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	24
+	0	7	6
+	0	11	1
+	0	11	16
+	0	11	17
+	0	11	2
+	0	11	41
+	0	7	6
+	0	12	1
+	0	12	3
+	0	10	52
+	0	20	9
+	-1
+
+3	7	12
+	1	3	0
+	0	31	1
+	0	8	23
+	0	5	21
+	0	20	1
+	-1
+
+3	7	13
+	1	6	0
+	0	31	1
+	0	1	64
+	0	8	14
+	0	20	61
+	0	8	14
+	0	20	61
+	0	20	18
+	-1
+
+3	7	14
+	1	1	0
+	0	31	1
+	0	20	19
+	-1
+
+3	7	15
+	1	1	0
+	0	31	1
+	3	2	5
+	0	8	2
+	0	20	11
+	0	20	12
+	0	20	13
+	0	20	2
+	-1
+
+3	7	16
+	1	1	0
+	0	31	1
+	0	20	20
+	-1
+
+3	7	17
+	1	1	0
+	0	31	1
+	0	11	70
+	-1
+
+3	7	18
+	0	8	16
+	1	2	0
+	0	31	1
+	0	8	17
+	3	1	12
+	1	4	0
+	0	31	1
+	0	7	6
+	0	11	1
+	0	11	2
+	0	11	41
+	0	20	9
+	1	1	0
+	0	31	1
+	0	20	1
+	3	7	14
+	-1
+
+3	7	20
+	3	7	11
+	3	7	14
+	3	7	16
+	-1
+
+3	7	21
+	3	7	11
+	3	7	12
+	3	7	13
+	3	7	14
+	3	7	15
+	3	7	16
+	3	7	17
+	3	7	18
+	3	7	15
+	-1
+
+3	8	1
+	3	1	33
+	3	2	11
+	0	22	42
+	-1
+
+3	8	2
+	3	1	34
+	3	2	11
+	0	22	42
+	-1
+
+3	8	3
+	3	1	35
+	3	2	11
+	0	22	42
+	-1
+
+3	8	4
+	3	1	36
+	3	2	11
+	0	22	42
+	-1
+
+3	8	5
+	3	8	4
+	3	2	24
+	-1
+
+3	8	6
+	0	10	4
+	0	10	61
+	0	10	63
+	0	11	1
+	0	11	2
+	0	12	4
+	0	13	3
+	0	22	42
+	-1
+
+3	8	7
+	3	1	55
+	3	2	11
+	0	7	62
+	0	22	42
+	-1
+
+3	9	1
+	3	1	37
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	2
+	3	1	38
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	3
+	3	1	37
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	4
+	3	1	38
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	5
+	3	1	37
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	6
+	3	1	38
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	7
+	3	1	37
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	8
+	3	1	38
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	11
+	3	1	39
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	12
+	3	1	39
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	13
+	3	1	39
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	14
+	3	1	39
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	15
+	3	1	40
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	16
+	3	1	40
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	17
+	3	1	40
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	18
+	3	1	40
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	19
+	3	1	31
+	0	2	3
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	20
+	3	1	31
+	0	2	3
+	1	4	0
+	0	31	1
+	0	7	3
+	0	11	3
+	0	11	4
+	0	11	5
+	-1
+
+3	9	194
+	3	1	194
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	195
+	3	1	195
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	196
+	3	1	196
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	10	1
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	26
+	3	3	25
+	-1
+
+3	10	2
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	9
+	3	3	23
+	-1
+
+3	10	3
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	6
+	3	3	23
+	-1
+
+3	10	4
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	3
+	3	3	24
+	-1
+
+3	10	5
+	3	1	42
+	3	3	31
+	3	3	33
+	1	1	0
+	0	31	1
+	3	03	25
+	-1
+
+3	10	6
+	3	1	42
+	3	3	31
+	3	3	33
+	1	1	0
+	0	31	1
+	3	3	23
+	-1
+
+3	10	7
+	3	1	42
+	3	3	31
+	3	3	33
+	1	1	0
+	0	31	1
+	3	3	24
+	-1
+
+3	10	8
+	3	10	11
+	1	1	19
+	3	10	12
+	0	2	150
+	0	25	79
+	0	25	80
+	0	33	32
+	0	14	45
+	-1
+
+3	10	9
+	3	10	11
+	1	1	15
+	3	10	12
+	-1
+
+3	10	10
+	3	10	11
+	1	1	5
+	3	10	12
+	-1
+
+3	10	11
+	0	8	70
+	0	1	33
+	0	1	34
+	0	8	70
+	0	1	33
+	0	1	34
+	0	1	7
+	0	2	48
+	0	5	40
+	0	25	75
+	2	1	133
+	0	5	41
+	2	1	0
+	0	5	43
+	0	25	70
+	0	33	30
+	0	33	31
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	4	5
+	2	2	131
+	2	1	138
+	0	4	6
+	2	1	0
+	2	2	0
+	0	5	1
+	0	6	1
+	2	2	126
+	0	7	1
+	2	2	0
+	0	7	24
+	0	5	21
+	0	7	25
+	0	5	22
+	0	33	33
+	0	2	151
+	0	12	64
+	0	2	151
+	0	12	64
+	0	2	151
+	0	12	64
+	0	2	151
+	0	12	64
+	0	2	151
+	0	12	64
+	-1
+
+3	10	12
+	0	2	150
+	0	25	76
+	0	25	77
+	0	25	78
+	0	33	32
+	2	1	132
+	2	2	129
+	0	12	63
+	2	2	0
+	2	1	0
+	-1
+
+3	10	13
+	0	1	7
+	0	5	40
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	4	5
+	0	4	6
+	0	5	1
+	0	6	1
+	0	7	25
+	0	5	43
+	0	25	85
+	2	1	131
+	2	2	129
+	0	2	150
+	0	8	23
+	0	8	72
+	0	14	27
+	0	8	72
+	0	14	27
+	0	2	150
+	0	8	23
+	0	8	72
+	0	14	27
+	0	8	72
+	0	14	27
+	0	2	150
+	0	8	23
+	0	8	72
+	0	14	27
+	0	8	72
+	0	14	27
+	2	2	0
+	2	1	0
+	2	1	132
+	2	2	129
+	0	2	150
+	0	8	23
+	0	8	72
+	0	12	63
+	0	8	72
+	0	12	63
+	0	2	150
+	0	8	23
+	0	8	72
+	0	12	63
+	0	8	72
+	0	12	63
+	0	8	23
+	0	8	72
+	0	12	63
+	0	8	72
+	0	12	63
+	0	2	150
+	0	8	23
+	0	8	72
+	0	12	63
+	0	8	72
+	0	12	63
+	2	2	0
+	2	1	0
+	-1
+
+3	10	14
+	3	1	72
+	3	3	41
+	3	4	11
+	-1
+
+3	10	15
+	3	1	72
+	0	7	24
+	0	10	2
+	3	3	41
+	1	1	3
+	3	4	32
+	0	2	152
+	0	2	24
+	0	7	4
+	0	7	4
+	0	13	3
+	1	1	3
+	3	4	33
+	-1
+
+3	10	16
+	3	1	72
+	0	7	24
+	0	10	2
+	3	3	41
+	1	1	12
+	3	4	32
+	0	2	152
+	0	2	24
+	0	7	4
+	0	7	4
+	0	13	3
+	1	1	12
+	3	4	33
+	-1
+
+3	10	20
+	3	10	22
+	3	1	11
+	3	1	13
+	3	1	21
+	3	4	34
+	3	10	21
+	-1
+
+3	10	21
+	1	8	0
+	0	31	1
+	2	1	131
+	2	2	129
+	0	7	4
+	0	7	4
+	2	2	0
+	2	1	0
+	0	15	20
+	0	10	2
+	-1
+
+3	10	22
+	0	1	7
+	0	2	19
+	0	1	33
+	0	2	172
+	-1
+
+3	10	193
+	3	1	250
+	3	3	250
+	3	2	250
+	3	3	249
+	3	3	251
+	-1
+
+3	10	194
+	3	1	250
+	3	3	250
+	3	2	250
+	3	3	249
+	3	3	252
+	-1
+
+3	10	195
+	3	1	250
+	3	3	250
+	3	4	250
+	-1
+
+3	10	196
+	3	1	250
+	3	3	249
+	3	3	251
+	-1
+
+3	11	1
+	3	1	51
+	0	7	2
+	0	12	1
+	0	11	1
+	0	11	2
+	0	11	31
+	0	11	32
+	0	11	33
+	0	20	41
+	-1
+
+3	11	2
+	3	1	65
+	3	1	66
+	3	11	3
+	3	11	4
+	-1
+
+3	11	3
+	0	10	70
+	0	11	1
+	0	11	2
+	0	12	1
+	0	13	2
+	-1
+
+3	11	4
+	1	1	0
+	0	31	0
+	0	11	34
+	1	1	0
+	0	31	0
+	0	11	35
+	1	1	0
+	0	31	0
+	0	11	75
+	1	1	0
+	0	31	0
+	0	11	76
+	1	1	0
+	0	31	0
+	0	33	25
+	1	1	0
+	0	31	0
+	0	33	26
+	-1
+
+3	11	193
+	3	1	197
+	3	1	011
+	3	1	012
+	3	1	023
+	0	8	004
+	0	7	004
+	0	8	021
+	0	11	001
+	0	11	002
+	0	11	031
+	0	11	034
+	0	11	035
+	0	12	001
+	0	12	003
+	0	13	003
+	0	20	041
+	-1
+
+3	12	1
+	3	1	43
+	3	4	1
+	-1
+
+3	12	2
+	3	1	43
+	3	4	2
+	-1
+
+3	12	3
+	3	1	42
+	3	4	3
+	-1
+
+3	12	4
+	3	1	42
+	3	4	4
+	-1
+
+3	12	5
+	3	1	42
+	0	20	14
+	-1
+
+3	12	6
+	3	1	44
+	3	4	5
+	-1
+
+3	12	7
+	3	1	42
+	3	4	6
+	-1
+
+3	12	10
+	0	1	7
+	0	5	40
+	0	2	21
+	0	5	41
+	0	4	1
+	0	4	43
+	-1
+
+3	12	11
+	2	2	131
+	2	1	149
+	0	4	6
+	2	1	0
+	2	2	126
+	0	10	2
+	2	2	0
+	0	5	43
+	0	5	53
+	-1
+
+3	12	12
+	2	2	129
+	2	1	132
+	1	1	19
+	0	12	63
+	2	1	0
+	2	2	0
+	-1
+
+3	12	13
+	0	5	42
+	2	2	129
+	2	1	135
+	0	12	63
+	2	1	0
+	2	2	0
+	-1
+
+3	12	14
+	3	12	10
+	3	12	11
+	1	5	56
+	3	1	23
+	0	5	42
+	0	5	52
+	3	12	12
+	3	12	13
+	-1
+
+3	12	15
+	1	9	11
+	3	1	23
+	0	5	42
+	0	5	52
+	2	2	129
+	2	1	132
+	1	1	4
+	0	12	63
+	2	2	0
+	2	1	0
+	-1
+
+3	12	16
+	3	12	10
+	3	12	11
+	3	12	15
+	-1
+
+3	12	17
+	1	9	8
+	3	1	23
+	0	5	42
+	0	5	52
+	2	2	129
+	2	1	132
+	1	1	3
+	0	12	63
+	2	2	0
+	2	1	0
+	-1
+
+3	12	18
+	3	12	10
+	3	12	11
+	3	12	17
+	-1
+
+3	12	19
+	3	1	47
+	3	1	48
+	0	15	15
+	0	29	2
+	0	21	76
+	1	6	12
+	2	1	129
+	0	6	30
+	2	1	0
+	1	2	12
+	0	5	30
+	0	21	75
+	0	21	66
+	-1
+
+3	12	20
+	3	1	47
+	3	1	48
+	0	15	15
+	0	29	2
+	0	21	76
+	1	4	12
+	0	6	30
+	1	2	12
+	0	5	30
+	0	21	75
+	0	21	66
+	-1
+
+3	12	21
+	3	1	47
+	1	1	3
+	3	1	49
+	0	11	12
+	0	11	11
+	0	21	67
+	-1
+
+3	12	22
+	3	1	47
+	0	8	22
+	0	11	12
+	0	11	50
+	0	22	70
+	0	22	26
+	3	12	41
+	0	10	50
+	0	21	68
+	0	21	71
+	0	21	72
+	0	21	73
+	3	12	42
+	0	21	62
+	0	15	11
+	-1
+
+3	12	23
+	3	1	47
+	1	3	3
+	0	8	22
+	0	12	61
+	0	22	50
+	0	21	69
+	0	21	85
+	-1
+
+3	12	24
+	3	12	20
+	0	8	60
+	0	8	22
+	0	8	60
+	0	8	22
+	0	25	14
+	0	22	101
+	0	22	97
+	0	22	98
+	0	22	99
+	0	22	100
+	-1
+
+3	12	25
+	3	12	19
+	0	8	60
+	0	8	22
+	0	8	60
+	0	8	22
+	0	25	14
+	0	22	101
+	0	22	97
+	0	22	98
+	0	22	99
+	0	22	100
+	-1
+
+3	12	26
+	3	1	46
+	3	1	11
+	3	1	13
+	3	10	23
+	3	12	31
+	1	1	4
+	3	12	30
+	0	21	110
+	3	1	23
+	3	21	27
+	0	21	111
+	3	1	23
+	3	21	27
+	0	21	111
+	3	1	23
+	3	21	27
+	0	21	113
+	3	1	23
+	3	21	27
+	-1
+
+3	12	27
+	3	1	47
+	1	5	9
+	3	1	23
+	0	7	21
+	0	12	61
+	0	7	21
+	0	12	61
+	0	21	85
+	0	21	70
+	-1
+
+3	12	28
+	3	1	46
+	3	1	11
+	3	1	13
+	3	1	23
+	0	8	25
+	2	1	136
+	0	4	6
+	2	1	0
+	3	12	31
+	3	12	32
+	1	1	4
+	3	12	30
+	1	1	2
+	3	12	33
+	0	21	110
+	3	1	23
+	3	21	28
+	0	21	111
+	3	1	23
+	3	21	28
+	0	21	112
+	3	1	23
+	3	21	28
+	0	21	113
+	3	1	23
+	3	21	28
+	-1
+
+3	12	30
+	2	1	130
+	2	2	129
+	0	11	12
+	2	2	0
+	2	1	0
+	0	11	52
+	2	1	135
+	2	2	130
+	0	11	11
+	2	2	0
+	2	1	0
+	0	11	53
+	0	21	104
+	-1
+
+3	12	31
+	0	5	34
+	0	6	34
+	0	21	109
+	0	11	81
+	0	11	82
+	0	21	101
+	0	21	102
+	0	21	103
+	-1
+
+3	12	32
+	0	21	120
+	0	21	121
+	0	13	55
+	0	21	122
+	-1
+
+3	12	33
+	0	2	104
+	0	8	22
+	0	12	63
+	0	12	65
+	-1
+
+3	12	41
+	2	1	141
+	2	2	130
+	0	7	1
+	2	1	00
+	2	2	00
+	-1
+
+3	12	42
+	0	21	77
+	0	21	78
+	0	21	79
+	0	21	80
+	0	21	81
+	0	21	82
+	-1
+
+3	13	9
+	0	21	1
+	1	1	0
+	0	31	1
+	0	21	1
+	-1
+
+3	13	10
+	0	21	36
+	1	1	0
+	0	31	1
+	0	21	36
+	-1
+
+3	13	31
+	0	6	2
+	0	6	12
+	1	1	0
+	0	31	2
+	0	30	1
+	-1
+
+3	13	32
+	0	5	2
+	0	5	12
+	1	1	0
+	0	31	2
+	3	13	31
+	-1
+
+3	13	41
+	0	6	2
+	1	10	0
+	0	31	1
+	1	4	0
+	0	31	1
+	0	6	12
+	1	1	0
+	0	31	12
+	0	30	1
+	0	6	12
+	1	1	0
+	0	31	1
+	0	30	1
+	-1
+
+3	13	42
+	0	5	2
+	0	5	12
+	1	1	0
+	0	31	2
+	3	13	41
+	-1
+
+3	13	43
+	0	6	2
+	0	5	2
+	0	5	12
+	1	12	0
+	0	31	1
+	1	10	0
+	0	31	1
+	1	04	0
+	0	31	1
+	0	6	12
+	1	1	0
+	0	31	11
+	0	30	1
+	1	1	0
+	0	31	1
+	0	30	1
+	-1
+	
+3	15	1
+	0	1	11
+	3	1	11
+	3	1	12
+	3	1	23
+	3	6	1
+	-1
+
+3	15	2
+	0	1	11
+	3	1	11
+	3	1	12
+	3	1	23
+	3	6	4
+	-1
+
+3	16	1
+	3	1	11
+	0	4	4
+	3	1	23
+	0	1	21
+	0	2	41
+	0	19	1
+	0	10	51
+	0	19	2
+	0	19	3
+	0	19	4
+	-1
+
+3	16	2
+	0	8	21
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	4	5
+	0	1	33
+	0	8	21
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	4	5
+	0	7	2
+	0	7	2
+	-1
+
+3	16	3
+	1	10	0
+	0	31	1
+	0	8	11
+	0	8	7
+	1	4	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	10	2
+	0	11	2
+	0	8	7
+	0	8	11
+	-1
+
+3	16	4
+	1	11	0
+	0	31	1
+	0	8	11
+	0	8	7
+	0	7	2
+	0	7	2
+	1	2	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	11	31
+	0	8	7
+	0	8	11
+	-1
+
+3	16	5
+	1	8	0
+	0	31	1
+	0	8	5
+	0	8	7
+	0	5	2
+	0	6	2
+	0	1	26
+	0	19	1
+	0	8	7
+	0	8	5
+	-1
+
+3	16	6
+	1	12	0
+	0	31	1
+	0	8	11
+	0	8	7
+	0	7	2
+	0	7	2
+	1	2	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	20	11
+	0	20	12
+	0	8	7
+	0	8	11
+	-1
+
+3	16	7
+	1	10	0
+	0	31	1
+	0	8	11
+	0	8	7
+	1	4	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	19	5
+	0	19	6
+	0	8	7
+	0	8	11
+	-1
+
+3	16	8
+	1	11	0
+	0	31	1
+	0	8	1
+	0	8	7
+	0	8	23
+	1	3	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	10	2
+	0	8	23
+	0	8	7
+	0	8	1
+	-1
+
+3	16	9
+	1	11	0
+	0	31	1
+	0	8	11
+	0	8	7
+	0	7	2
+	0	7	2
+	1	2	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	20	41
+	0	8	7
+	0	8	11
+	-1
+
+3	16	10
+	1	7	0
+	0	31	1
+	0	8	11
+	0	8	7
+	0	1	22
+	0	5	2
+	0	6	2
+	0	8	7
+	0	8	11
+	-1
+
+3	16	11
+	1	16	0
+	0	31	1
+	0	8	11
+	0	1	22
+	0	8	7
+	1	2	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	8	21
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	4	5
+	0	20	90
+	0	8	21
+	0	8	7
+	0	8	11
+	-1
+
+3	18	1
+	3	1	25
+	0	24	11
+	-1
+
+3	18	3
+	3	1	26
+	0	24	5
+	0	24	4
+	0	24	21
+	-1
+
+3	18	4
+	3	1	25
+	0	4	23
+	0	13	11
+	0	24	5
+	0	24	4
+	0	24	22
+	-1
+
+3	21	1
+	0	2	101
+	0	2	114
+	0	2	105
+	0	2	106
+	0	2	107
+	0	2	121
+	-1
+
+3	21	3
+	0	21	51
+	0	21	14
+	0	21	17
+	0	21	30
+	-1
+
+3	21	4
+	3	1	31
+	0	2	3
+	1	1	0
+	0	31	1
+	3	21	3
+	-1
+
+3	21	5
+	0	25	4
+	0	2	121
+	0	2	122
+	0	2	123
+	0	2	124
+	0	2	125
+	0	2	126
+	0	2	127
+	0	2	128
+	0	2	129
+	0	2	130
+	0	2	131
+	-1
+
+3	21	6
+	0	25	1
+	0	25	2
+	0	25	3
+	0	25	5
+	-1
+
+3	21	7
+	0	25	9
+	0	25	10
+	0	25	11
+	0	25	12
+	0	25	13
+	0	25	15
+	0	25	16
+	0	25	17
+	-1
+
+3	21	8
+	0	25	6
+	0	25	7
+	0	25	8
+	-1
+
+3	21	9
+	0	25	18
+	0	25	19
+	-1
+
+3	21	10
+	0	2	101
+	0	7	2
+	0	2	102
+	0	2	103
+	0	2	104
+	0	2	105
+	0	2	106
+	0	2	107
+	0	2	108
+	0	2	109
+	0	2	110
+	0	2	132
+	0	2	133
+	-1
+
+3	21	11
+	0	30	31
+	0	30	32
+	0	29	2
+	-1
+
+3	21	12
+	1	1	0
+	0	31	1
+	0	2	135
+	-1
+
+3	21	21	
+	0	2	3
+	0	2	101
+	2	1	130
+	0	2	106
+	2	1	0
+	2	1	132
+	2	2	130
+	0	2	121
+	2	2	0
+	2	1	0
+	2	1	133
+	2	2	129
+	0	25	1
+	2	2	0
+	2	1	0
+	-1
+
+3	21	22
+	0	10	7
+	2	4	1
+	0	31	21
+	0	11	1
+	2	4	0
+	0	11	2
+	2	4	1
+	0	31	21
+	0	11	6
+	2	4	0
+	0	21	30
+	-1		
+
+3	21	23
+	0	7	7
+	0	21	91
+	0	21	30
+	2	2	129
+	0	21	14
+	2	1	129
+	0	21	17
+	2	2	0
+	2	1	0
+	-1		
+
+3	21	24
+	0	7	7
+	2	4	1
+	0	31	21
+	0	12	7
+	0	11	6
+	2	4	0
+	0	21	30
+	-1		
+
+3	21	025
+	0	07	7
+	0	21	91
+	0	21	30
+	2	02	129
+	0	21	14
+	2	01	129
+	0	21	17
+	2	02	0
+	2	01	0
+	0	21	92
+	0	21	30
+	0	25	92
+	2	01	129
+	2	02	129
+	0	21	17
+	2	02	0
+	2	01	0
+	-1		
+
+3	21	26
+	0	10	7
+	2	4	1
+	0	31	21
+	0	12	7
+	0	25	91
+	0	11	71
+	0	11	72
+	0	11	73
+	0	11	74
+	2	4	0
+	-1
+
+3	21	27
+	0	21	118
+	2	2	129
+	2	1	132
+	0	2	112
+	2	1	0
+	2	1	131
+	0	2	111
+	2	1	0
+	2	2	0
+	0	2	104
+	0	21	105
+	0	21	106
+	0	21	107
+	0	21	114
+	0	21	115
+	0	21	116
+	0	8	18
+	0	21	117
+	-1
+
+3	21	28
+	0	21	118
+	2	2	129
+	2	1	132
+	0	2	112
+	2	1	0
+	2	1	131
+	0	2	111
+	2	1	0
+	2	2	0
+	0	2	104
+	0	21	123
+	0	21	106
+	0	21	107
+	0	21	114
+	0	21	115
+	0	21	116
+	0	8	18
+	0	21	117
+	-1
+
diff --git a/data/tables/B3L-200-001-B b/data/tables/B3L-200-001-B
new file mode 100644
index 0000000..0a89760
--- /dev/null
+++ b/data/tables/B3L-200-001-B
@@ -0,0 +1,28 @@
+#
+#       BUFR Table B - Classification of elements specific to RSA
+#
+#
+#F	X	Y	Scale	RefVal	Data Width	Units		Element Name
+############################################################################################
+
+#                                PROFILER DATA
+  0;    1;    192;      0;           0;   32;      Numeric; Platform ID
+  0;    1;    193;      0;           0;  248;    CCITT_IA5; Platform Name
+  0;    4;    192;      0;           0;   16;      Numeric; Report Duration
+  0;   33;    192;      0;           0;    8;      Numeric; Accuracy
+
+#                                   LLP DATA
+  0;   20;    192;      0;           0;    5;      Numeric; Maximum Mulitplicity
+  0;   20;    193;      1;        -200;   12;      Numeric; Strength
+  0;   20;    194;      0;           0;  100;    CCITT_IA5; Condition
+
+#                                  RTAMPS DATA
+  0;    1;    194;      0;           0;   48;    CCITT_IA5; Mission Name
+  0;    4;    193;      2;           0;   21;            s; Sample Time
+  0;   10;    192;      2;           0;   24;            m; Geopotential Height
+  0;   11;    192;      2;           0;   18;          m/s; Velocity of Sound
+  0;   13;    192;      1;           0;   10;            %; Relative Humidity
+  0;   13;    193;      5;           0;   14;      kg/m**3; Absolute Humidity
+  0;   13;    194;      5;           0;   19;      kg/m**3; Density of Air
+  0;   21;    192;      2;           0;   19;      numeric; Microwave Index of Refraction
+  0;   21;    193;      2;           0;   19;      numeric; Optical Index of Refraction
diff --git a/data/tables/B3M-000-003-0 b/data/tables/B3M-000-003-0
new file mode 100644
index 0000000..b68ae8b
--- /dev/null
+++ b/data/tables/B3M-000-003-0
@@ -0,0 +1,308 @@
+##############################################################################
+# BUFR Table 0
+#
+#
+# Notes
+# -----
+#
+# * This table comes from GRIB Code Table 0 (Identification of center)
+#
+# * A value of 1 in the first column indicates a center that uses minor
+#   version numbers with local tables.  Since minor local table version
+#   numbers are stored in Section 1, Octet 18, the value in the first
+#   column must not be set if a center uses Section 1, Octet 18 for other
+#   purposes (i.e., ECMWF).
+#
+#
+##############################################################################
+
+0	  0	RESERVED
+
+# 1-9: WMCs
+
+0	  1	Melbourne
+0	  2	Melbourne
+0	  3	Melbourne
+0	  4	Moscow
+0	  5	Moscow
+0	  6	Moscow
+0	  7	US Weather Service - National Meteorological Center (NMC)
+0	  8	US National Weather Service Telecommunications Gateway (NWSTG)
+0	  9	Reserved for USA
+
+# 10-25: Centers in Region I
+
+0	 10	Cairo (RSMC/RAFC)
+0	 11	Cairo (RSMC/RAFC)
+0	 12	Dakar (RSMC/RAFC)
+0	 13	Dakar (RSMC/RAFC)
+0	 14	Nairobi (RSMC/RAFC)
+0	 15	Nairobi (RSMC/RAFC)
+0	 16	Antananarivo (RSMC)
+0	 17	Antananarivo (RSMC)
+0	 18	Tunis-Casablanca (RSMC/RAFC)
+0	 19	Tunis-Casablanca (RSMC/RAFC)
+0	 20	Las Palmas (RAFC)
+0	 21	Algiers (RSMC)
+0	 22	Lagos (RSMC)
+0	 23	Lagos (RSMC)
+0	 24	Reserved for other centers in Region I
+0	 25	Reserved for other centers in Region I
+
+# 26-40 Centers in Region II
+
+0	 26	Khabarovsk (RSMC)
+0	 27	Khabarovsk (RSMC)
+0	 28	New Delhi (RSMC/RAFC)
+0	 29	New Delhi (RSMC/RAFC)
+0	 30	Novosibirsk (RSMC)
+0	 31	Novosibirsk (RSMC)
+0	 32	Tashkent (RSMC)
+0	 33	Tashkent (RSMC)
+0	 34	Tokyo (RSMC), Japan Meteorological Agency
+0	 35	Tokyo (RSMC/RAFC)
+0	 36	Bangkok (RAFC)
+0	 37	Ulan Bator
+0	 38	Beijing (RSMC)
+0	 39	Beijing (RSMC)
+0	 40	Reserved for other centers in Region II
+
+# 41-50: Centers in Region III
+
+0	 41	Buenos Aires (RSMC/RAFC)
+0	 42	Buenos Aires (RSMC/RAFC)
+0	 43	Brasilia (RSMC/RAFC)
+0	 44	Brasilia (RSMC/RAFC)
+0	 45	Santiago
+0	 46	Brazilian Space Agency - INPE
+0	 47	Reserved for other centers in Region III
+0	 48	Reserved for other centers in Region III
+0	 49	Reserved for other centers in Region III
+0	 50	Reserved for other centers in Region III
+
+# 51-63: Centers in Region IV
+
+0	 51	Miami (RSMC/RAFC)
+0	 52	Miami (RSMC), National Hurricane Center
+0	 53	Montreal (RSMC)
+0	 54	Montreal (RSMC)
+0	 55	San Francisco
+0	 56	RESERVED
+0	 57	US Air Force - Air Force Global Weather Central (AFGWC)
+1	 58	Fleet Numerical Oceanography Center (FNOC), Monterey, CA, USA
+0	 59	The NOAA Forecast Systems Laboratory, Boulder, CO, USA
+0	 60	Reserved for other centers in Region IV
+0	 61	Reserved for other centers in Region IV
+0	 62	Reserved for other centers in Region IV
+0	 63	Reserved for other centers in Region IV
+
+# 64-73: Centers in Region V
+
+0	 64	Honolulu (RAFC)
+0	 65	Darwin (RSMC/RAFC)
+0	 66	Darwin (RSMC/RAFC)
+0	 67	Melbourne (RSMC)
+0	 68	RESERVED
+0	 69	Wellington (RSMC/RAFC)
+0	 70	Wellington (RSMC/RAFC)
+0	 71	Reserved for other centers in Region V
+0	 72	Reserved for other centers in Region V
+0	 73	Reserved for other centers in Region V
+
+# 74-98: Centers in Region VI
+
+0	 74	UK Meteorological Office - Bracknell
+0	 75	UK Meteorological Office - Bracknell
+0	 76	Moscow (RSMC/RAFC)
+0	 77	RESERVED
+0	 78	Offenbach (RSMC)
+0	 79	Offenbach (RSMC)
+0	 80	Rome (RSMC/RAFC)
+0	 81	Rome (RSMC/RAFC)
+0	 82	Norrkoping (RSMC)
+0	 83	Norrkoping (RSMC)
+0	 84	Paris (RAFC)
+0	 85	Toulouse
+0	 86	Helsinki
+0	 87	Belgrade
+0	 88	Oslo
+0	 89	Prague
+0	 90	Episkopi
+0	 91	Ankara
+0	 92	Francfort/Main (RAFC)
+0	 93	London (WAFC)
+0	 94	Copenhagen
+0	 95	Rota
+0	 96	Athens
+0	 97	European Space Agency (ESA)
+
+# ECMWF (Center 98) does not support minor local table version numbers
+# so DO NOT set the first value to 1.
+
+0	 98	European Center for Medium Range Weather Forecasts (ECMWF)(RSMC)
+0	 99	De Bilt
+
+# 100-127: RESERVED
+
+0	100	RESERVED
+0	101	RESERVED
+0	102	RESERVED
+0	103	RESERVED
+0	104	RESERVED
+0	105	RESERVED
+0	106	RESERVED
+0	107	RESERVED
+0	108	RESERVED
+0	109	RESERVED
+0	110	RESERVED
+0	111	RESERVED
+0	112	RESERVED
+0	113	RESERVED
+0	114	RESERVED
+0	115	RESERVED
+0	116	RESERVED
+0	117	RESERVED
+0	118	RESERVED
+0	119	RESERVED
+0	120	RESERVED
+0	121	RESERVED
+0	122	RESERVED
+0	123	RESERVED
+0	124	RESERVED
+0	125	RESERVED
+0	126	RESERVED
+0	127	RESERVED
+
+# 128-254: NATIONAL USE
+
+1	128	Naval Research Laboratory (NRL), Monterey CA
+0	129	CAST
+0	130	AFCCC
+0	131	PL
+0	132	ARL
+0	133	WES
+0	134	NATIONAL USE
+0	135	NATIONAL USE
+0	136	NATIONAL USE
+0	137	NATIONAL USE
+0	138	NATIONAL USE
+0	139	NATIONAL USE
+0	140	NATIONAL USE
+0	141	NATIONAL USE
+0	142	NATIONAL USE
+0	143	NATIONAL USE
+0	144	NATIONAL USE
+0	145	NATIONAL USE
+0	146	NATIONAL USE
+0	147	NATIONAL USE
+0	148	NATIONAL USE
+0	149	NATIONAL USE
+0	150	NATIONAL USE
+0	151	NATIONAL USE
+0	152	NATIONAL USE
+0	153	NATIONAL USE
+0	154	NATIONAL USE
+0	155	NATIONAL USE
+0	156	NATIONAL USE
+0	157	NATIONAL USE
+0	158	NATIONAL USE
+0	159	NATIONAL USE
+0	160	NATIONAL USE
+0	161	NATIONAL USE
+0	162	NATIONAL USE
+0	163	NATIONAL USE
+0	164	NATIONAL USE
+0	165	NATIONAL USE
+0	166	NATIONAL USE
+0	167	NATIONAL USE
+0	168	NATIONAL USE
+0	169	NATIONAL USE
+0	170	NATIONAL USE
+0	171	NATIONAL USE
+0	172	NATIONAL USE
+0	173	NATIONAL USE
+0	174	NATIONAL USE
+0	175	NATIONAL USE
+0	176	NATIONAL USE
+0	177	NATIONAL USE
+0	178	NATIONAL USE
+0	179	NATIONAL USE
+0	180	NATIONAL USE
+0	181	NATIONAL USE
+0	182	NATIONAL USE
+0	183	NATIONAL USE
+0	184	NATIONAL USE
+0	185	NATIONAL USE
+0	186	NATIONAL USE
+0	187	NATIONAL USE
+0	188	NATIONAL USE
+0	189	NATIONAL USE
+0	190	NATIONAL USE
+0	191	NATIONAL USE
+0	192	NATIONAL USE
+0	193	NATIONAL USE
+0	194	NATIONAL USE
+0	195	NATIONAL USE
+0	196	NATIONAL USE
+0	197	NATIONAL USE
+0	198	NATIONAL USE
+0	199	NATIONAL USE
+0	200	NATIONAL USE
+0	201	NATIONAL USE
+0	202	NATIONAL USE
+0	203	NATIONAL USE
+0	204	NATIONAL USE
+0	205	NATIONAL USE
+0	206	NATIONAL USE
+0	207	NATIONAL USE
+0	208	NATIONAL USE
+0	209	NATIONAL USE
+0	210	NATIONAL USE
+0	211	NATIONAL USE
+0	212	NATIONAL USE
+0	213	NATIONAL USE
+0	214	NATIONAL USE
+0	215	NATIONAL USE
+0	216	NATIONAL USE
+0	217	NATIONAL USE
+0	218	NATIONAL USE
+0	219	NATIONAL USE
+0	220	NATIONAL USE
+0	221	NATIONAL USE
+0	222	NATIONAL USE
+0	223	NATIONAL USE
+0	224	NATIONAL USE
+0	225	NATIONAL USE
+0	226	NATIONAL USE
+0	227	NATIONAL USE
+0	228	NATIONAL USE
+0	229	NATIONAL USE
+0	230	NATIONAL USE
+0	231	NATIONAL USE
+0	232	NATIONAL USE
+0	233	NATIONAL USE
+0	234	NATIONAL USE
+0	235	NATIONAL USE
+0	236	NATIONAL USE
+0	237	NATIONAL USE
+0	238	NATIONAL USE
+0	239	NATIONAL USE
+0	240	NATIONAL USE
+0	241	NATIONAL USE
+0	242	NATIONAL USE
+0	243	NATIONAL USE
+0	244	NATIONAL USE
+0	245	NATIONAL USE
+0	246	NATIONAL USE
+0	247	NATIONAL USE
+0	248	NATIONAL USE
+0	249	NATIONAL USE
+0	250	NATIONAL USE
+0	251	NATIONAL USE
+0	252	NATIONAL USE
+0	253	NATIONAL USE
+0	254	NATIONAL USE
+
+# 255: Used to indicate missing or unknown center
+
+0	255	MISSING VALUE
diff --git a/data/tables/B3M-000-004-0 b/data/tables/B3M-000-004-0
new file mode 100644
index 0000000..b68ae8b
--- /dev/null
+++ b/data/tables/B3M-000-004-0
@@ -0,0 +1,308 @@
+##############################################################################
+# BUFR Table 0
+#
+#
+# Notes
+# -----
+#
+# * This table comes from GRIB Code Table 0 (Identification of center)
+#
+# * A value of 1 in the first column indicates a center that uses minor
+#   version numbers with local tables.  Since minor local table version
+#   numbers are stored in Section 1, Octet 18, the value in the first
+#   column must not be set if a center uses Section 1, Octet 18 for other
+#   purposes (i.e., ECMWF).
+#
+#
+##############################################################################
+
+0	  0	RESERVED
+
+# 1-9: WMCs
+
+0	  1	Melbourne
+0	  2	Melbourne
+0	  3	Melbourne
+0	  4	Moscow
+0	  5	Moscow
+0	  6	Moscow
+0	  7	US Weather Service - National Meteorological Center (NMC)
+0	  8	US National Weather Service Telecommunications Gateway (NWSTG)
+0	  9	Reserved for USA
+
+# 10-25: Centers in Region I
+
+0	 10	Cairo (RSMC/RAFC)
+0	 11	Cairo (RSMC/RAFC)
+0	 12	Dakar (RSMC/RAFC)
+0	 13	Dakar (RSMC/RAFC)
+0	 14	Nairobi (RSMC/RAFC)
+0	 15	Nairobi (RSMC/RAFC)
+0	 16	Antananarivo (RSMC)
+0	 17	Antananarivo (RSMC)
+0	 18	Tunis-Casablanca (RSMC/RAFC)
+0	 19	Tunis-Casablanca (RSMC/RAFC)
+0	 20	Las Palmas (RAFC)
+0	 21	Algiers (RSMC)
+0	 22	Lagos (RSMC)
+0	 23	Lagos (RSMC)
+0	 24	Reserved for other centers in Region I
+0	 25	Reserved for other centers in Region I
+
+# 26-40 Centers in Region II
+
+0	 26	Khabarovsk (RSMC)
+0	 27	Khabarovsk (RSMC)
+0	 28	New Delhi (RSMC/RAFC)
+0	 29	New Delhi (RSMC/RAFC)
+0	 30	Novosibirsk (RSMC)
+0	 31	Novosibirsk (RSMC)
+0	 32	Tashkent (RSMC)
+0	 33	Tashkent (RSMC)
+0	 34	Tokyo (RSMC), Japan Meteorological Agency
+0	 35	Tokyo (RSMC/RAFC)
+0	 36	Bangkok (RAFC)
+0	 37	Ulan Bator
+0	 38	Beijing (RSMC)
+0	 39	Beijing (RSMC)
+0	 40	Reserved for other centers in Region II
+
+# 41-50: Centers in Region III
+
+0	 41	Buenos Aires (RSMC/RAFC)
+0	 42	Buenos Aires (RSMC/RAFC)
+0	 43	Brasilia (RSMC/RAFC)
+0	 44	Brasilia (RSMC/RAFC)
+0	 45	Santiago
+0	 46	Brazilian Space Agency - INPE
+0	 47	Reserved for other centers in Region III
+0	 48	Reserved for other centers in Region III
+0	 49	Reserved for other centers in Region III
+0	 50	Reserved for other centers in Region III
+
+# 51-63: Centers in Region IV
+
+0	 51	Miami (RSMC/RAFC)
+0	 52	Miami (RSMC), National Hurricane Center
+0	 53	Montreal (RSMC)
+0	 54	Montreal (RSMC)
+0	 55	San Francisco
+0	 56	RESERVED
+0	 57	US Air Force - Air Force Global Weather Central (AFGWC)
+1	 58	Fleet Numerical Oceanography Center (FNOC), Monterey, CA, USA
+0	 59	The NOAA Forecast Systems Laboratory, Boulder, CO, USA
+0	 60	Reserved for other centers in Region IV
+0	 61	Reserved for other centers in Region IV
+0	 62	Reserved for other centers in Region IV
+0	 63	Reserved for other centers in Region IV
+
+# 64-73: Centers in Region V
+
+0	 64	Honolulu (RAFC)
+0	 65	Darwin (RSMC/RAFC)
+0	 66	Darwin (RSMC/RAFC)
+0	 67	Melbourne (RSMC)
+0	 68	RESERVED
+0	 69	Wellington (RSMC/RAFC)
+0	 70	Wellington (RSMC/RAFC)
+0	 71	Reserved for other centers in Region V
+0	 72	Reserved for other centers in Region V
+0	 73	Reserved for other centers in Region V
+
+# 74-98: Centers in Region VI
+
+0	 74	UK Meteorological Office - Bracknell
+0	 75	UK Meteorological Office - Bracknell
+0	 76	Moscow (RSMC/RAFC)
+0	 77	RESERVED
+0	 78	Offenbach (RSMC)
+0	 79	Offenbach (RSMC)
+0	 80	Rome (RSMC/RAFC)
+0	 81	Rome (RSMC/RAFC)
+0	 82	Norrkoping (RSMC)
+0	 83	Norrkoping (RSMC)
+0	 84	Paris (RAFC)
+0	 85	Toulouse
+0	 86	Helsinki
+0	 87	Belgrade
+0	 88	Oslo
+0	 89	Prague
+0	 90	Episkopi
+0	 91	Ankara
+0	 92	Francfort/Main (RAFC)
+0	 93	London (WAFC)
+0	 94	Copenhagen
+0	 95	Rota
+0	 96	Athens
+0	 97	European Space Agency (ESA)
+
+# ECMWF (Center 98) does not support minor local table version numbers
+# so DO NOT set the first value to 1.
+
+0	 98	European Center for Medium Range Weather Forecasts (ECMWF)(RSMC)
+0	 99	De Bilt
+
+# 100-127: RESERVED
+
+0	100	RESERVED
+0	101	RESERVED
+0	102	RESERVED
+0	103	RESERVED
+0	104	RESERVED
+0	105	RESERVED
+0	106	RESERVED
+0	107	RESERVED
+0	108	RESERVED
+0	109	RESERVED
+0	110	RESERVED
+0	111	RESERVED
+0	112	RESERVED
+0	113	RESERVED
+0	114	RESERVED
+0	115	RESERVED
+0	116	RESERVED
+0	117	RESERVED
+0	118	RESERVED
+0	119	RESERVED
+0	120	RESERVED
+0	121	RESERVED
+0	122	RESERVED
+0	123	RESERVED
+0	124	RESERVED
+0	125	RESERVED
+0	126	RESERVED
+0	127	RESERVED
+
+# 128-254: NATIONAL USE
+
+1	128	Naval Research Laboratory (NRL), Monterey CA
+0	129	CAST
+0	130	AFCCC
+0	131	PL
+0	132	ARL
+0	133	WES
+0	134	NATIONAL USE
+0	135	NATIONAL USE
+0	136	NATIONAL USE
+0	137	NATIONAL USE
+0	138	NATIONAL USE
+0	139	NATIONAL USE
+0	140	NATIONAL USE
+0	141	NATIONAL USE
+0	142	NATIONAL USE
+0	143	NATIONAL USE
+0	144	NATIONAL USE
+0	145	NATIONAL USE
+0	146	NATIONAL USE
+0	147	NATIONAL USE
+0	148	NATIONAL USE
+0	149	NATIONAL USE
+0	150	NATIONAL USE
+0	151	NATIONAL USE
+0	152	NATIONAL USE
+0	153	NATIONAL USE
+0	154	NATIONAL USE
+0	155	NATIONAL USE
+0	156	NATIONAL USE
+0	157	NATIONAL USE
+0	158	NATIONAL USE
+0	159	NATIONAL USE
+0	160	NATIONAL USE
+0	161	NATIONAL USE
+0	162	NATIONAL USE
+0	163	NATIONAL USE
+0	164	NATIONAL USE
+0	165	NATIONAL USE
+0	166	NATIONAL USE
+0	167	NATIONAL USE
+0	168	NATIONAL USE
+0	169	NATIONAL USE
+0	170	NATIONAL USE
+0	171	NATIONAL USE
+0	172	NATIONAL USE
+0	173	NATIONAL USE
+0	174	NATIONAL USE
+0	175	NATIONAL USE
+0	176	NATIONAL USE
+0	177	NATIONAL USE
+0	178	NATIONAL USE
+0	179	NATIONAL USE
+0	180	NATIONAL USE
+0	181	NATIONAL USE
+0	182	NATIONAL USE
+0	183	NATIONAL USE
+0	184	NATIONAL USE
+0	185	NATIONAL USE
+0	186	NATIONAL USE
+0	187	NATIONAL USE
+0	188	NATIONAL USE
+0	189	NATIONAL USE
+0	190	NATIONAL USE
+0	191	NATIONAL USE
+0	192	NATIONAL USE
+0	193	NATIONAL USE
+0	194	NATIONAL USE
+0	195	NATIONAL USE
+0	196	NATIONAL USE
+0	197	NATIONAL USE
+0	198	NATIONAL USE
+0	199	NATIONAL USE
+0	200	NATIONAL USE
+0	201	NATIONAL USE
+0	202	NATIONAL USE
+0	203	NATIONAL USE
+0	204	NATIONAL USE
+0	205	NATIONAL USE
+0	206	NATIONAL USE
+0	207	NATIONAL USE
+0	208	NATIONAL USE
+0	209	NATIONAL USE
+0	210	NATIONAL USE
+0	211	NATIONAL USE
+0	212	NATIONAL USE
+0	213	NATIONAL USE
+0	214	NATIONAL USE
+0	215	NATIONAL USE
+0	216	NATIONAL USE
+0	217	NATIONAL USE
+0	218	NATIONAL USE
+0	219	NATIONAL USE
+0	220	NATIONAL USE
+0	221	NATIONAL USE
+0	222	NATIONAL USE
+0	223	NATIONAL USE
+0	224	NATIONAL USE
+0	225	NATIONAL USE
+0	226	NATIONAL USE
+0	227	NATIONAL USE
+0	228	NATIONAL USE
+0	229	NATIONAL USE
+0	230	NATIONAL USE
+0	231	NATIONAL USE
+0	232	NATIONAL USE
+0	233	NATIONAL USE
+0	234	NATIONAL USE
+0	235	NATIONAL USE
+0	236	NATIONAL USE
+0	237	NATIONAL USE
+0	238	NATIONAL USE
+0	239	NATIONAL USE
+0	240	NATIONAL USE
+0	241	NATIONAL USE
+0	242	NATIONAL USE
+0	243	NATIONAL USE
+0	244	NATIONAL USE
+0	245	NATIONAL USE
+0	246	NATIONAL USE
+0	247	NATIONAL USE
+0	248	NATIONAL USE
+0	249	NATIONAL USE
+0	250	NATIONAL USE
+0	251	NATIONAL USE
+0	252	NATIONAL USE
+0	253	NATIONAL USE
+0	254	NATIONAL USE
+
+# 255: Used to indicate missing or unknown center
+
+0	255	MISSING VALUE
diff --git a/data/tables/B3M-000-004-A b/data/tables/B3M-000-004-A
new file mode 100644
index 0000000..2a5d7db
--- /dev/null
+++ b/data/tables/B3M-000-004-A
@@ -0,0 +1,259 @@
+#
+# BUFR Table A - Data Category
+#
+  0	Surface data - land
+  1	Surface data - sea
+  2	Vertical soundings (other than satellite)
+  3	Vertical soundings (satellite)
+  4	Single level upper-air data (other than satellite)
+  5	Single level upper-air data (satellite)
+  6	Radar data
+  7	Synoptic features
+  8	Physical/chemical constituents
+  9	Dispersal and transport
+ 10	Radiological data
+ 11	BUFR tables, complete replacement or update
+ 12	Surface data (satellite)
+ 13	RESERVED
+ 14	RESERVED
+ 15	RESERVED
+ 16	RESERVED
+ 17	RESERVED
+ 18	RESERVED
+ 19	RESERVED
+ 20	Status information
+ 21	Radiances (satellite measured)
+ 22	RESERVED
+ 23	RESERVED
+ 24	RESERVED
+ 25	RESERVED
+ 26	RESERVED
+ 27	RESERVED
+ 28	RESERVED
+ 29	RESERVED
+ 30	RESERVED
+ 31	Oceanographic data
+ 32	RESERVED
+ 33	RESERVED
+ 34	RESERVED
+ 35	RESERVED
+ 36	RESERVED
+ 37	RESERVED
+ 38	RESERVED
+ 39	RESERVED
+ 40	RESERVED
+ 41	RESERVED
+ 42	RESERVED
+ 43	RESERVED
+ 44	RESERVED
+ 45	RESERVED
+ 46	RESERVED
+ 47	RESERVED
+ 48	RESERVED
+ 49	RESERVED
+ 50	RESERVED
+ 51	RESERVED
+ 52	RESERVED
+ 53	RESERVED
+ 54	RESERVED
+ 55	RESERVED
+ 56	RESERVED
+ 57	RESERVED
+ 58	RESERVED
+ 59	RESERVED
+ 60	RESERVED
+ 61	RESERVED
+ 62	RESERVED
+ 63	RESERVED
+ 64	RESERVED
+ 65	RESERVED
+ 66	RESERVED
+ 67	RESERVED
+ 68	RESERVED
+ 69	RESERVED
+ 70	RESERVED
+ 71	RESERVED
+ 72	RESERVED
+ 73	RESERVED
+ 74	RESERVED
+ 75	RESERVED
+ 76	RESERVED
+ 77	RESERVED
+ 78	RESERVED
+ 79	RESERVED
+ 80	RESERVED
+ 81	RESERVED
+ 82	RESERVED
+ 83	RESERVED
+ 84	RESERVED
+ 85	RESERVED
+ 86	RESERVED
+ 87	RESERVED
+ 88	RESERVED
+ 89	RESERVED
+ 90	RESERVED
+ 91	RESERVED
+ 92	RESERVED
+ 93	RESERVED
+ 94	RESERVED
+ 95	RESERVED
+ 96	RESERVED
+ 97	RESERVED
+ 98	RESERVED
+ 99	RESERVED
+100	RESERVED
+101	Image data
+102	RESERVED
+103	RESERVED
+104	RESERVED
+105	RESERVED
+106	RESERVED
+107	RESERVED
+108	RESERVED
+109	RESERVED
+110	RESERVED
+111	RESERVED
+112	RESERVED
+113	RESERVED
+114	RESERVED
+115	RESERVED
+116	RESERVED
+117	RESERVED
+118	RESERVED
+119	RESERVED
+120	RESERVED
+121	RESERVED
+122	RESERVED
+123	RESERVED
+124	RESERVED
+125	RESERVED
+126	RESERVED
+127	RESERVED
+128	RESERVED
+129	RESERVED
+130	RESERVED
+131	RESERVED
+132	RESERVED
+133	RESERVED
+134	RESERVED
+135	RESERVED
+136	RESERVED
+137	RESERVED
+138	RESERVED
+139	RESERVED
+140	RESERVED
+141	RESERVED
+142	RESERVED
+143	RESERVED
+144	RESERVED
+145	RESERVED
+146	RESERVED
+147	RESERVED
+148	RESERVED
+149	RESERVED
+150	RESERVED
+151	RESERVED
+152	RESERVED
+153	RESERVED
+154	RESERVED
+155	RESERVED
+156	RESERVED
+157	RESERVED
+158	RESERVED
+159	RESERVED
+160	RESERVED
+161	RESERVED
+162	RESERVED
+163	RESERVED
+164	RESERVED
+165	RESERVED
+166	RESERVED
+167	RESERVED
+168	RESERVED
+169	RESERVED
+170	RESERVED
+171	RESERVED
+172	RESERVED
+173	RESERVED
+174	RESERVED
+175	RESERVED
+176	RESERVED
+177	RESERVED
+178	RESERVED
+179	RESERVED
+180	RESERVED
+181	RESERVED
+182	RESERVED
+183	RESERVED
+184	RESERVED
+185	RESERVED
+186	RESERVED
+187	RESERVED
+188	RESERVED
+189	RESERVED
+190	RESERVED
+191	RESERVED
+192	RESERVED
+193	RESERVED
+194	RESERVED
+195	RESERVED
+196	RESERVED
+197	RESERVED
+198	RESERVED
+199	RESERVED
+200	RESERVED
+201	RESERVED
+202	RESERVED
+203	RESERVED
+204	RESERVED
+205	RESERVED
+206	RESERVED
+207	RESERVED
+208	RESERVED
+209	RESERVED
+210	RESERVED
+211	RESERVED
+212	RESERVED
+213	RESERVED
+214	RESERVED
+215	RESERVED
+216	RESERVED
+217	RESERVED
+218	RESERVED
+219	RESERVED
+220	RESERVED
+221	RESERVED
+222	RESERVED
+223	RESERVED
+224	RESERVED
+225	RESERVED
+226	RESERVED
+227	RESERVED
+228	RESERVED
+229	RESERVED
+230	RESERVED
+231	RESERVED
+232	RESERVED
+233	RESERVED
+234	RESERVED
+235	RESERVED
+236	RESERVED
+237	RESERVED
+238	RESERVED
+239	RESERVED
+240	FOR EXPERIMENTAL USE
+241	FOR EXPERIMENTAL USE
+242	FOR EXPERIMENTAL USE
+243	FOR EXPERIMENTAL USE
+244	FOR EXPERIMENTAL USE
+245	FOR EXPERIMENTAL USE
+246	FOR EXPERIMENTAL USE
+247	FOR EXPERIMENTAL USE
+248	FOR EXPERIMENTAL USE
+249	FOR EXPERIMENTAL USE
+250	FOR EXPERIMENTAL USE
+251	FOR EXPERIMENTAL USE
+252	FOR EXPERIMENTAL USE
+253	FOR EXPERIMENTAL USE
+254	FOR EXPERIMENTAL USE
+255	Indicator for local use, with sub-category
diff --git a/data/tables/B3M-000-004-B b/data/tables/B3M-000-004-B
new file mode 100644
index 0000000..5edb008
--- /dev/null
+++ b/data/tables/B3M-000-004-B
@@ -0,0 +1,635 @@
+#
+# BUFR Table B - Classification of Elements
+#
+#					Data
+#F	X	Y	Scale	RefVal	Width	Units	Element Name
+  0;    0;      1;      0;           0;   24;    CCITT_IA5; Table A: entry
+  0;    0;      2;      0;           0;  256;    CCITT_IA5; Table A: data category description, line 1
+  0;    0;      3;      0;           0;  256;    CCITT_IA5; Table A: data category description, line 2
+  0;    0;      5;      0;           0;   24;    CCITT_IA5; BUFR edition number
+  0;    0;     10;      0;           0;    8;    CCITT_IA5; F descriptor to be added or defined
+  0;    0;     11;      0;           0;   16;    CCITT_IA5; X descriptor to be added or defined
+  0;    0;     12;      0;           0;   24;    CCITT_IA5; Y descriptor to be added or defined
+  0;    0;     13;      0;           0;  256;    CCITT_IA5; Element name, line 1
+  0;    0;     14;      0;           0;  256;    CCITT_IA5; Element name, line 2
+  0;    0;     15;      0;           0;  192;    CCITT_IA5; Units name
+  0;    0;     16;      0;           0;    8;    CCITT_IA5; Units scale sign
+  0;    0;     17;      0;           0;   24;    CCITT_IA5; Units scale
+  0;    0;     18;      0;           0;    8;    CCITT_IA5; Units reference sign
+  0;    0;     19;      0;           0;   80;    CCITT_IA5; Units reference value
+  0;    0;     20;      0;           0;   24;    CCITT_IA5; Element data width
+  0;    0;     30;      0;           0;   48;    CCITT_IA5; Descriptor defining sequence
+
+  0;    1;      1;      0;           0;    7;      Numeric; WMO block number
+  0;    1;      2;      0;           0;   10;      Numeric; WMO station number
+  0;    1;      3;      0;           0;    3;      Numeric; WMO region number
+  0;    1;      4;      0;           0;    3;      Numeric; WMO region sub-area
+  0;    1;      5;      0;           0;   17;      Numeric; Buoy/platform identifier
+  0;    1;      6;      0;           0;   64;    CCITT_IA5; Aircraft identifier (flight number)
+  0;    1;      7;      0;           0;   10;   Code_Table; Satellite identifier
+  0;    1;      8;      0;           0;   64;    CCITT_IA5; Aircraft registration number (tail number)
+  0;    1;      9;      0;           0;   64;    CCITT_IA5; Type of commerical aircraft
+  0;    1;     10;      0;           0;   64;    CCITT_IA5; Stationary buoy platform identifier
+  0;    1;     11;      0;           0;   72;    CCITT_IA5; Ship or mobile land station identifier
+  0;    1;     12;      0;           0;    9;     deg_true; Direction of motion of moving observing platform
+  0;    1;     13;      0;           0;   10;          m/s; Speed of motion of moving observing platform
+  0;    1;     14;      2;           0;   10;          m/s; Platform drift speed (high precision)
+  0;    1;     15;      0;           0;  160;    CCITT_IA5; Station or site name
+  0;    1;     20;      0;           0;    4;      Numeric; WMO Region sub-area
+  0;    1;     21;      0;           0;   14;      Numeric; Synoptic feature identifier
+  0;    1;     22;      0;           0;  224;    CCITT_IA5; Name of feature
+  0;    1;     25;      0;           0;   24;    CCITT_IA5; Storm identifier
+  0;    1;     26;      0;           0;   64;    CCITT_IA5; WMO storm name
+  0;    1;     31;      0;           0;   16;   Code_Table; Identification of originating/generating center
+  0;    1;     32;      0;           0;    8;   Code_Table; Generating application
+  0;    1;     33;      0;           0;    8;   Code_Table; Identification of originating/generating center
+  0;    1;     34;      0;           0;    8;   Code_Table; Identification of originating/generating sub-center
+  0;    1;     41;      5; -1073741824;   31;          m/s; Absolute platform velocity - first component
+  0;    1;     42;      5; -1073741824;   31;          m/s; Absolute platform velocity - second component
+  0;    1;     43;      5; -1073741824;   31;          m/s; Absolute platform velocity - third component
+  0;    1;     60;      0;           0;   64;    CCITT_IA5; Aircraft reporting point (Beacon identifier)
+  0;    1;     63;      0;           0;   64;    CCITT_IA5; ICAO location indicator
+  0;    1;     64;      0;           0;   32;    CCITT_IA5; Runway designator
+  0;    1;     75;      0;           0;   40;    CCITT_IA5; Ride station identification
+
+  0;    2;      1;      0;           0;    2;   Code_Table; Type of station
+  0;    2;      2;      0;           0;    4;   Flag_Table; Type of instrumentation for wind measurement
+  0;    2;      3;      0;           0;    4;   Code_Table; Type of measuring instrumentation used
+  0;    2;      4;      0;           0;    4;   Code_Table; Type of instrumentation for evaporation measurement or type of crop for which evapotranspiration is reported
+  0;    2;      5;      2;           0;    7;          deg; Precision of temperature observed
+  0;    2;     11;      0;           0;    8;   Code_Table; Radiosonde type
+  0;    2;     12;      0;           0;    4;   Code_Table; Radiosonde computational method
+  0;    2;     13;      0;           0;    4;   Code_Table; Solar and infrared radiation correction
+  0;    2;     14;      0;           0;    7;   Code_Table; Tracking technique/status of system
+  0;    2;     15;      0;           0;    4;   Code_Table; Radiosonde completeness
+  0;    2;     21;      0;           0;    9;   Flag_Table; Satellite instrumentation data used in processing
+  0;    2;     22;      0;           0;    8;   Flag_Table; Satellite data processing technique used
+  0;    2;     23;      0;           0;    4;   Code_Table; Satellite derived wind computation method
+  0;    2;     24;      0;           0;    4;   Code_Table; Integrated mean humidity computational method
+  0;    2;     25;      0;           0;   25;   Flag_Table; Satellite channel(s) used in computation
+  0;    2;     26;      2;           0;   12;            m; Cross track resolution
+  0;    2;     27;      2;           0;   12;            m; Along track resolution
+  0;    2;     30;      0;           0;    3;   Code_Table; Method of current measurement
+  0;    2;     31;      0;           0;    5;   Code_Table; Duration and time of current measurement
+  0;    2;     32;      0;           0;    2;   Code_Table; Indicator for digitization
+  0;    2;     33;      0;           0;    3;   Code_Table; Method of salinity/depth measurement
+  0;    2;     34;      0;           0;    5;   Code_Table; Drogue type
+  0;    2;     35;      0;           0;    9;            m; Cable length
+  0;    2;     36;      0;           0;    2;   Code_Table; Buoy type
+  0;    2;     37;      0;           0;    3;   Code_Table; Method of tidal observation
+  0;    2;     38;      0;           0;    4;   Code_Table; Method of sea-surface temperature measurement
+  0;    2;     39;      0;           0;    3;   Code_Table; Method of wet-buld temperature measurement
+  0;    2;     40;      0;           0;    4;   Code_Table; Method of removing velocity and motion of platform from current
+  0;    2;     41;      0;           0;    6;   Code_Table; Method for estimating reports related to synoptic features
+  0;    2;     42;      0;           0;    6;   Code_Table; Method of report construction
+  0;    2;     43;      0;           0;    6;   Code_Table; Precision of latitude/longitude report
+  0;    2;     44;      0;           0;    4;   Code_Table; Inicator for method of calculating spectral wave data
+  0;    2;     45;      0;           0;    4;   Code_Table; Indicator for type of platform
+  0;    2;     46;      0;           0;    4;   Code_Table; Wave measurement instrumentation
+  0;    2;     48;      0;           0;    4;   Code_Table; Satellite sensor indicator
+  0;    2;     49;      0;           0;    8;   Flag_Table; Geostationary satellite data-processing technique used
+  0;    2;     50;      0;           0;   20;   Flag_Table; Geostationary sounder satellite channels used
+  0;    2;     51;      0;           0;    4;   Code_Table; Indicator ro specify observing method for extreme temperatures
+  0;    2;     52;      0;           0;    6;   Flag_Table; Geostationary imager satellite channels used
+  0;    2;     53;      0;           0;    4;   Code_Table; GOES-I/M  brightness temperature characteristics
+  0;    2;     54;      0;           0;    4;   Code_Table; GOES-I/M  soundings parameter characteristics
+  0;    2;     55;      0;           0;    4;   Code_Table; Geostationary soundings statistical parameters
+  0;    2;     56;      0;           0;    4;   Code_Table; Geostationary soundings accuracy statistics
+  0;    2;     57;      0;           0;    4;   Code_Table; Origin of first guess information for GOES-I/M soundings
+  0;    2;     58;      0;           0;    4;   Code_Table; Valid times of first guess information for GOES-I/M soundings
+  0;    2;     59;      0;           0;    4;   Code_Table; Origin of analysis information for GOES-I/M soundings
+  0;    2;     60;      0;           0;    4;   Code_Table; Origin of surface information for GOES-I/M soundings
+  0;    2;     61;      0;           0;    3;   Code_Table; Aircraft navigation system
+  0;    2;     62;      0;           0;    4;   Code_Table; Type of aircraft data relay system
+  0;    2;     63;      2;      -18000;   16;          deg; Aircraft roll angle
+  0;    2;     64;      0;           0;    2;   Code_Table; Aircraft roll angle quality
+  0;    2;     65;      0;           0;   40;    CCITT_IA5; ACARS ground receiving station
+  0;    2;     70;      0;           0;    4;   Code_Table; Original specification of latitude/longitude
+  0;    2;    100;      1;           0;   12;           dB; Radar constant
+  0;    2;    101;      0;           0;    4;   Code_Table; Type of antenna
+  0;    2;    102;      0;           0;    8;            m; Antenna height above tower
+  0;    2;    103;      0;           0;    2;   Flag_Table; Radome
+  0;    2;    104;      0;           0;    4;   Code_Table; Antenna polarisation
+  0;    2;    105;      0;           0;    6;           dB; Maximum antenna gain
+  0;    2;    106;      1;           0;    6;          deg; 3-dB bandwidth
+  0;    2;    107;      0;           0;    6;           dB; Sidelobe suppression
+  0;    2;    108;      0;           0;    6;           dB; Crosspol discrimination (on axis)
+  0;    2;    109;      2;           0;   12;        deg/s; Antenna speed (azimuth)
+  0;    2;    110;      2;           0;   12;        deg/s; Antenna speed (elevation)
+  0;    2;    111;      1;           0;   10;          deg; Radar incidence angle
+  0;    2;    112;      1;           0;   12;          deg; Radar azimuth angle
+  0;    2;    113;      0;           0;    4;      Numeric; Number of azimuth looks
+  0;    2;    114;      0;           0;   15;         m**2; Antenna effective surface area
+  0;    2;    121;     -8;           0;    7;           Hz; Mean frequency
+  0;    2;    122;     -6;        -128;    8;           Hz; Frequency agility range
+  0;    2;    123;     -4;           0;    7;            W; Peak power
+  0;    2;    124;     -1;           0;    7;            W; Average power
+  0;    2;    125;     -1;           0;    8;           Hz; Pulse repetition frequency
+  0;    2;    126;      7;           0;    6;            s; Pulse width
+  0;    2;    127;     -6;           0;    7;           Hz; Receiver intermediate frequency
+  0;    2;    128;     -5;           0;    6;           Hz; Intermediate frequency bandwidth
+  0;    2;    129;      0;        -150;    5;           dB; Minimum detectable signal
+  0;    2;    130;      0;           0;    7;           dB; Dynamic range
+  0;    2;    131;      0;           0;    2;   Flag_Table; Sensitivity time control
+  0;    2;    132;      2;           0;    6;          deg; Azimuth pointing accuracy
+  0;    2;    133;      2;           0;    6;          deg; Elevation pointing accuracy
+  0;    2;    134;      2;           0;   16;          deg; Antenna beam azimuth
+  0;    2;    135;      2;       -9000;   15;          deg; Antenna elevation
+  0;    2;    136;     -3;           0;   16;            m; Range processed by range attenuation correction
+  0;    2;    140;      2;           0;    9;          deg; Satellite radar beam azimuth
+  0;    2;    141;      0;           0;   24;    CCITT_IA5; Measurement type
+  0;    2;    142;      0;           0;   32;    CCITT_IA5; Ozone instrument serial number/identification
+  0;    2;    143;      0;           0;    7;   Code_Table; Ozone instrument type
+  0;    2;    144;      0;           0;    4;   Code_Table; Light source type for Brewer spectrophotometer
+  0;    2;    145;      0;           0;    4;   Code_Table; Wave length setting for Dobson instruments
+  0;    2;    146;      0;           0;    4;   Code_Table; Source conditions for Dobson instruments
+
+  0;    4;      1;      0;           0;   12;         Year; Year
+  0;    4;      2;      0;           0;    4;           mo; Month
+  0;    4;      3;      0;           0;    6;          Day; Day
+  0;    4;      4;      0;           0;    5;           hr; Hour
+  0;    4;      5;      0;           0;    6;          min; Minute
+  0;    4;      6;      0;           0;    6;            s; Second
+  0;    4;     11;      0;       -1024;   11;         Year; Time increment
+  0;    4;     12;      0;       -1024;   11;           mo; Time increment
+  0;    4;     13;      0;       -1024;   11;         Days; Time increment
+  0;    4;     14;      0;       -1024;   11;           hr; Time increment
+  0;    4;     15;      0;       -2048;   12;          min; Time increment
+  0;    4;     16;      0;       -4096;   13;            s; Time increment
+  0;    4;     21;      0;       -1024;   11;         Year; Time period or displacement
+  0;    4;     22;      0;       -1024;   11;           mo; Time period or displacement
+  0;    4;     23;      0;       -1024;   11;         Days; Time period or displacement
+  0;    4;     24;      0;       -2048;   12;           hr; Time period or displacement
+  0;    4;     25;      0;       -2048;   12;          min; Time period or displacement
+  0;    4;     26;      0;       -4096;   13;            s; Time period or displacement
+  0;    4;     31;      0;           0;    8;           hr; Duration of time relative to followinG value
+  0;    4;     32;      0;           0;    6;       Minute; Duration of time relating to following value
+  0;    4;     41;      0;       -1440;   12;       Minute; Time Difference, UTC-LMT
+  0;    4;     43;      0;           0;    9;          Day; Day of the year
+  0;    4;     53;      0;           0;    6;      Numeric; Number of days with precipition equal to or more than 1mm
+  0;    4;    192;      0;           0;    3;   Code_Table; Season
+
+  0;    5;      1;      5;    -9000000;   25;          deg; Latitude (high accuracy)
+  0;    5;      2;      2;       -9000;   15;          deg; Latitude (coarse accuracy)
+  0;    5;     11;      5;    -9000000;   25;          deg; Latitude increment (high accuracy)
+  0;    5;     12;      2;       -9000;   15;          deg; Latitude increment (coarse accuracy)
+  0;    5;     21;      2;           0;   16;     deg_true; Bearing or azimuth
+  0;    5;     22;      2;           0;   16;     deg_true; Solar azimuth
+  0;    5;     30;      0;           0;   12;          deg; Direction (spectral)
+  0;    5;     31;      0;           0;   12;      Numeric; Row number
+  0;    5;     33;     -1;           0;   16;            m; Pixel size on horizontal - 1
+  0;    5;     40;      0;           0;   24;      Numeric; Orbit number
+  0;    5;     41;      0;           0;    8;      Numeric; Scan line number
+  0;    5;     42;      0;           0;    6;      Numeric; Channel number
+  0;    5;     43;      0;           0;    8;      Numeric; Field of view number
+  0;    5;     52;      0;           0;    5;      Numeric; Channel number increment
+  0;    5;     53;      0;           0;    5;      Numeric; Field of view number increment
+
+  0;    6;      1;      5;   -18000000;   26;          deg; Longitude (high accuracy)
+  0;    6;      2;      2;      -18000;   16;          deg; Longitude (coarse accuracy)
+  0;    6;     11;      5;   -18000000;   26;          deg; Longitude increment (high accuracy)
+  0;    6;     12;      2;      -18000;   16;          deg; Longitude increment (coarse accuracy)
+  0;    6;     21;     -1;           0;   13;            m; Distance
+  0;    6;     30;      5;           0;   13;        rad/m; Wavenumber (spectral)
+  0;    6;     31;      0;           0;   12;      Numeric; Column number
+  0;    6;     33;     -1;           0;   16;            m; Pixel size on horizontal - 2
+
+  0;    7;      1;      0;        -400;   15;            m; Height of station
+  0;    7;      2;     -1;         -40;   16;            m; Height or altitude
+  0;    7;      3;     -1;        -400;   17;    m**2/s**2; Geopotential
+  0;    7;      4;     -1;           0;   14;           Pa; Pressure
+  0;    7;      5;      0;        -400;   12;            m; Height increment
+  0;    7;      6;      0;           0;   15;            m; Height above station
+  0;    7;      7;      0;       -1000;   17;            m; Height
+  0;    7;      8;      0;      -10000;   20;    m**2/s**2; Geopotential
+  0;    7;     21;      2;       -9000;   15;          deg; Elevation
+  0;    7;     22;      2;       -9000;   15;          deg; Solar elevation
+  0;    7;     24;      2;       -9000;   15;          deg; Satellite zenith angle
+  0;    7;     61;      2;           0;   14;            m; Depth below land surface
+  0;    7;     62;      1;           0;   17;            m; Depth below sea/water surface
+  0;    7;    190;      0;           0;   12;            m; Height increment
+
+  0;    8;      1;      0;           0;    7;   Flag_Table; Vertical sounding significance
+  0;    8;      2;      0;           0;    6;   Code_Table; Vertical significance (surface observations)
+  0;    8;      3;      0;           0;    6;   Code_Table; Vertical significance (satellite observations)
+  0;    8;      4;      0;           0;    3;   Code_Table; Phase of aircraft flight
+  0;    8;      5;      0;           0;    4;   Code_Table; Meteorological attribute significance
+  0;    8;      7;      0;           0;    4;   Code_Table; Dimensional significance
+  0;    8;     11;      0;           0;    6;   Code_Table; Meteorological feature
+  0;    8;     12;      0;           0;    2;   Code_Table; land/sea qualifier
+  0;    8;     13;      0;           0;    2;   Code_Table; Day/night qualifier
+  0;    8;     14;      0;           0;    4;   Code_Table; Qualification for runway visual range
+  0;    8;     16;      0;           0;    3;   Code_Table; Change indicator of a trend-type forecast or an aerodrome forecast
+  0;    8;     17;      0;           0;    2;   Code_Table; Qualifier of the time when the forecast change is expected
+  0;    8;     20;      0;           0;   16;      Numeric; Total number of missing entities (with respect to accumulation or average)
+  0;    8;     21;      0;           0;    5;   Code_Table; Time significance
+  0;    8;     22;      0;           0;   16;      Numeric; Total number (with respect to accumulation or average)
+  0;    8;     23;      0;           0;    6;   Code_Table; First order statistics
+  0;    8;     24;      0;           0;    6;   Code_Table; Difference statistics
+  0;    8;     25;      0;           0;    4;   Code_Table; Time difference qualifier
+  0;    8;     30;      0;           0;   13;      Numeric; Manual on Codes
+  0;    8;     51;      0;           0;    3;   Code_Table; Qualifier for number of missing values in calculation of statistic
+  0;    8;     52;      0;           0;    5;   Code_Table; Condition for which number of days of occurance follows
+  0;    8;     53;      0;           0;    2;   Code_Table; Day of occurance qualifier
+  0;    8;     60;      0;           0;    4;   Code_Table; Sample scanning mode significance
+
+  0;   10;      1;      0;        -400;   15;            m; Height of land surface
+  0;   10;      2;     -1;         -40;   16;            m; Height
+  0;   10;      3;     -1;        -400;   17;    m**2/s**2; Geopotential
+  0;   10;      4;     -1;           0;   14;           Pa; Pressure
+  0;   10;      7;      0;       -1000;   17;            m; Height
+  0;   10;      8;      0;      -10000;   20;    m**2/s**2; Geopotential
+  0;   10;     31;      2; -1073741824;   31;            m; In direction of the North Pole, distance from the Earth's centre
+  0;   10;     50;      2;           0;   16;            m; Standard deviation altitude
+  0;   10;     51;     -1;           0;   14;           Pa; Pressure reduced to mean sea level
+  0;   10;     52;     -1;           0;   14;           Pa; Altimeter setting (QNH)
+  0;   10;     60;     -1;       -1024;   11;           Pa; Pressure change
+  0;   10;     61;     -1;        -500;   10;           Pa; 3 hour pressure change
+  0;   10;     62;     -1;       -1000;   11;           Pa; 24 hour pressure change
+  0;   10;     63;      0;           0;    4;   Code_Table; Characteristic of pressure tendency
+  0;   10;     70;      0;        -400;   16;            m; Indicated aircraft altitude
+
+  0;   11;      1;      0;           0;    9;     deg_true; Wind direction
+  0;   11;      2;      1;           0;   12;          m/s; Wind speed
+  0;   11;      3;      1;       -4096;   13;          m/s; U-component
+  0;   11;      4;      1;       -4096;   13;          m/s; V-component
+  0;   11;      5;      1;        -512;   10;         Pa/s; W-component
+  0;   11;      6;      2;       -4096;   13;          m/s; W-component
+  0;   11;     11;      0;           0;    9;     deg_true; Wind direction at 10 m
+  0;   11;     12;      1;           0;   12;          m/s; Wind speed at 10 m
+  0;   11;     13;      0;           0;    9;     deg_true; Wind direction at 5 m
+  0;   11;     14;      1;           0;   12;          m/s; Wind speed at 5 m
+  0;   11;     16;      0;           0;    9;     deg_true; Extreme counterclockwise wind direction of a variable wind
+  0;   11;     17;      0;           0;    9;     deg_true; Extreme clockwise wind direction of a variable wind
+  0;   11;     21;      9;      -65536;   17;        s**-1; Relative vorticity
+  0;   11;     22;      9;      -65536;   17;        s**-1; Divergence
+  0;   11;     23;     -2;      -65536;   17;       m**2/s; Velocity potential
+  0;   11;     31;      0;           0;    4;   Code_Table; Degree of turbulence
+  0;   11;     32;     -1;         -40;   16;            m; Height of base of turbulence
+  0;   11;     33;     -1;         -40;   16;            m; Height of top of turbulence
+  0;   11;     34;      1;       -1024;   11;          m/s; Vertical gust velocity
+  0;   11;     35;      2;       -8192;   14;       m/s**2; Vertical gust acceleration
+  0;   11;     36;      1;           0;   10;          m/s; Maximum derived equivalent vertical gust speed
+  0;   11;     41;      1;           0;   12;          m/s; Maximum wind speed (gusts)
+  0;   11;     42;      1;           0;   12;          m/s; Maximum wind speed (10 minute mean wind)
+  0;   11;     43;      0;           0;    9;     deg_true; Maximum wind gust direction
+  0;   11;     44;      0;           0;    9;     deg_true; Mean wind direction for surface - 1500m
+  0;   11;     45;      1;           0;   12;          m/s; Mean wind speed for surface - 1500m
+  0;   11;     49;      0;           0;    9;     deg_true; Standard deviation of wind direction
+  0;   11;     50;      1;           0;   12;          m/s; Standard deviation horizontal wind speed
+  0;   11;     51;      1;           0;    8;          m/s; Standard deviation vertical wind speed
+  0;   11;     61;      1;           0;   12;          m/s; Absolute wind shear in 1 kilometer layer below
+  0;   11;     62;      1;           0;   12;          m/s; Absolute wind shear in1 kilometer layer above
+  0;   11;     70;      0;           0;   32; CCITT_IA5Designator; of the runway affected by wind shear
+  0;   11;     71;      3;        -128;   14;   m**2/s**-2; Turbulent vertical momemtum flux
+  0;   11;     72;      3;        -128;   11;            K; m/s**-2	Turbulent vertical buouancy flux
+  0;   11;     73;      2;       -1024;   13;   m**2/s**-2; Turbulent kinetic energy
+  0;   11;     74;      2;       -1024;   10;   m**2/s**-2; Dissipation energy
+  0;   11;     75;      2;           0;    8; m**(2/3)/s**-1; Mean turbulence intensity
+  0;   11;     76;      2;           0;    8; m**(2/3)/s**-1; Peak turbulence intensity
+
+  0;   12;      1;      1;           0;   12;        deg_K; Temperature/dry bulb temperature
+  0;   12;      2;      1;           0;   12;        deg_K; Wet bulb temperature
+  0;   12;      3;      1;           0;   12;        deg_K; Dewpoint temperature
+  0;   12;      4;      1;           0;   12;        deg_K; Dry bulb temperature at 2 meters
+  0;   12;      5;      1;           0;   12;        deg_K; Wet bulb temperature at 2 meters
+  0;   12;      6;      1;           0;   12;        deg_K; Dewpoint temperature at 2 meters
+  0;   12;      7;      1;           0;   12;        deg_K; Virtual temperature
+  0;   12;     11;      1;           0;   12;        deg_K; Maximum temperature
+  0;   12;     12;      1;           0;   12;        deg_K; Minimum temperature
+  0;   12;     13;      1;           0;   12;        deg_K; Ground minimum temperature past 12 hours
+  0;   12;     14;      1;           0;   12;        deg_K; Maximum temperature at 2 meters, past 12 hours
+  0;   12;     15;      1;           0;   12;        deg_K; Minimum temperature at 2 meters, past 12 hours
+  0;   12;     16;      1;           0;   12;        deg_K; Maximum temperature at 2 meters, past 24 hours
+  0;   12;     17;      1;           0;   12;        deg_K; Minimum temperature at 2 meters, past 24 hours
+  0;   12;     30;      1;           0;   12;        deg_K; Soil temperature
+  0;   12;     51;      1;           0;   10;        deg_K; Standard deviation of temperature
+  0;   12;     52;      1;           0;   12;        deg_K; Highest daily mean temperature
+  0;   12;     53;      1;           0;   12;        deg_K; Lowest daily mean temperature
+  0;   12;     61;      1;           0;   12;        deg_K; Skin temperature
+  0;   12;     62;      1;           0;   12;        deg_K; Equivalent black body temperature
+  0;   12;     63;      1;           0;   12;        deg_K; Brightness temperature
+
+  0;   13;      1;      5;           0;   14;        kg/kg; Specific humidity
+  0;   13;      2;      5;           0;   14;        kg/kg; Mixing ratio
+  0;   13;      3;      0;           0;    7;      percent; Relative humidity
+  0;   13;      4;     -1;           0;   10;           Pa; Vapor pressure
+  0;   13;      5;      3;           0;    7;      kg/m**3; Vapor density
+  0;   13;      6;     -1;         -40;   16;            m; Mixing heights
+  0;   13;     11;      4;          -1;   14;      kg/m**2; Total precipitation/total water equivalent
+  0;   13;     12;      2;          -2;   12;            m; Depth of fresh snow
+  0;   13;     13;      2;          -2;   16;            m; Total snow depth
+  0;   13;     14;      4;           0;   12;    kg/m**2/s; Rainfall/water equivalent of snow (average rate)
+  0;   13;     15;      7;           0;   12;          m/s; Snowfall (averaged rate)
+  0;   13;     16;      0;           0;    7;      kg/m**2; Precipitable water
+  0;   13;     19;      1;          -1;   14;      kg/m**2; Total precipitation past 1 hour
+  0;   13;     20;      1;          -1;   14;      kg/m**2; Total precipitation past 3 hours
+  0;   13;     21;      1;          -1;   14;      kg/m**2; Total precipitation past 6 hours
+  0;   13;     22;      1;          -1;   14;      kg/m**2; Total precipitation past 12 hours
+  0;   13;     23;      1;          -1;   14;      kg/m**2; Total precipitation past 24 hours
+  0;   13;     31;      0;           0;    7;      kg/m**2; Evapotranspiration
+  0;   13;     32;      1;           0;    8;      kg/m**2; Evaporation/evapotranspiration
+  0;   13;     33;      1;           0;   10;      kg/m**2; Evaporation/evapotranspiration
+  0;   13;     38;      0;           0;    2;   Code_Table; Superadiabatic indicator
+  0;   13;     39;      0;           0;    3;   Code_Table; Terrain type (ice/snow)
+  0;   13;     41;      0;           0;    4;   Code_Table; Pasquill-Gifford stability category
+  0;   13;     42;      0;         -20;    6;        deg_K; Parcel lifted index (to 500 hPa)
+  0;   13;     43;      0;         -20;    6;        deg_K; Best lifted index (to 500 hPa)
+  0;   13;     51;      0;           0;    4;   Code_Table; Frequency group, precipition
+  0;   13;     52;      1;          -1;   14;      kg/m**2; Highest daily amount of precipition
+
+  0;   14;      1;     -3;       -2048;   12;  Joules/m**2; Longwave radiation, integrated over 24 hours
+  0;   14;      2;     -3;       -2048;   12;  Joules/m**2; Longwave radiation, integrated over period specified
+  0;   14;      3;     -3;       -2048;   12;  Joules/m**2; Shortwave radiation, integrated over 24 hours
+  0;   14;      4;     -3;       -2048;   12;  Joules/m**2; Shortwave radiation, integrated over period specified
+  0;   14;     11;     -3;       -2048;   12;  Joules/m**2; Net longwave radiation, integrated over 24 hours
+  0;   14;     12;     -3;       -2048;   12;  Joules/m**2; Net longwave radiation, integrated over period specified
+  0;   14;     13;     -3;       -2048;   12;  Joules/m**2; Net shortwave radiation, integrated over 24 hours
+  0;   14;     14;     -3;       -2048;   12;  Joules/m**2; Net shortwave radiation, integrated over period specified
+  0;   14;     15;     -4;      -16384;   15;  Joules/m**2; Net radiation, integrated over 24 hours
+  0;   14;     16;     -4;      -16384;   15;  Joules/m**2; Net radiation, integrated over period specified
+  0;   14;     17;     -3;       -2048;   12;       W/m**2; Instantaneous long wave radiation
+  0;   14;     18;     -3;       -2048;   12;       W/m**2; Instantaneous short wave radiation
+  0;   14;     19;      0;           0;    7;      percent; Surface albedo
+  0;   14;     20;     -4;           0;   15;  Joules/m**2; Global solar radiation, integrated over 24 hours
+  0;   14;     21;     -4;           0;   15;  Joules/m**2; Global radiation, integrated over period specified
+  0;   14;     22;     -4;           0;   15;  Joules/m**2; Diffuse solar radiation, integrated over 24 hours
+  0;   14;     23;     -4;           0;   15;  Joules/m**2; Diffuse solar radiation, integratedi over period specified
+  0;   14;     24;     -4;           0;   15;  Joules/m**2; Direct solar radiation, integrated over 24 hours
+  0;   14;     25;     -4;           0;   15;  Joules/m**2; Direct solar radiation, integrated over period specified
+  0;   14;     26;      0;           0;    7;      percent; Albedo at the top of clouds
+  0;   14;     31;      0;           0;   11;          min; Total sunshine
+  0;   14;     32;      0;           0;   10;           hr; Total sunshine
+  0;   14;     33;      0;           0;    9;      percent; Total sunshine
+  0;   14;     42;      0;           0;    7;      percent; Bi-directional reflectance
+
+  0;   15;      1;      0;           0;   10;       Dobson; units	Ozone
+  0;   15;      2;      2;           0;   10;      Numeric; Air mass (slant path at 22km)
+  0;   15;     11;      3;       14000;   13;  log(1/m**2); Log 10 of integrated electron density
+  0;   15;     15;      0;           0;   31;      Numeric; Maximum image spectral composition before normalization
+
+  0;   19;      1;      0;           0;    6;   Code_Table; Type of synoptic features
+  0;   19;      2;     -2;           0;   12;            m; Effective radius of feature
+  0;   19;      3;      0;           0;    8;          m/s; Wind speed threshold
+  0;   19;      4;     -2;           0;   12;            m; Effective radius of feature with respect to wind speeds above threshold
+  0;   19;      5;      0;           0;    9;     deg_true; Direction of motion of features
+  0;   19;      6;      2;           0;   14;          m/s; Speed of motion of features
+  0;   19;      7;     -3;           0;   12;            m; Effective radius of features
+  0;   19;      8;      0;           0;    3;   Code_Table; Vertical extent of circulation
+  0;   19;      9;     -3;           0;   12;            m; Effective radius with respect to wind speed above threshold (large storms)
+
+  0;   20;      1;     -1;           0;   13;            m; Horizontal visibility
+  0;   20;      2;     -1;           0;    7;            m; Vertical visibility
+  0;   20;      3;      0;           0;    9;   Code_Table; Present weather
+  0;   20;      4;      0;           0;    5;   Code_Table; Past weather (1)
+  0;   20;      5;      0;           0;    5;   Code_Table; Past weather (2)
+  0;   20;      9;      0;           0;    4;   Code_Table; General Weather Indicator
+  0;   20;     10;      0;           0;    7;      percent; Cloud cover (total)
+  0;   20;     11;      0;           0;    4;   Code_Table; Cloud amount
+  0;   20;     12;      0;           0;    6;   Code_Table; Cloud type
+  0;   20;     13;     -1;         -40;   11;            m; Height of base of cloud
+  0;   20;     14;     -1;         -40;   11;            m; Height of top of cloud
+  0;   20;     15;     -1;           0;   14;           Pa; Pressure at the base of cloud
+  0;   20;     16;     -1;           0;   14;           Pa; Pressure at the top of cloud
+  0;   20;     17;      0;           0;    4;   Code_Table; Cloud top description
+  0;   20;     18;      0;           0;    2;   Code_Table; Tendency of runway visual range
+  0;   20;     19;      0;           0;   72;    CCITT_IA5; Significant present or forecast weather
+  0;   20;     20;      0;           0;   32;    CCITT_IA5; Significant recent weather phenomena
+  0;   20;     31;      2;           0;    7;            m; Ice deposit (thickness)
+  0;   20;     32;      0;           0;    3;   Code_Table; Rate of ice accretion
+  0;   20;     33;      0;           0;    4;   Flag_Table; Cause of ice accretion
+  0;   20;     34;      0;           0;    5;   Code_Table; Sea ice concentration
+  0;   20;     35;      0;           0;    4;   Code_Table; Amount and type of ice
+  0;   20;     36;      0;           0;    5;   Code_Table; Ice situation
+  0;   20;     37;      0;           0;    5;   Code_Table; Ice development
+  0;   20;     38;      0;           0;   12;     deg_true; Bearing of ice edge
+  0;   20;     39;     -1;           0;   13;            m; Ice distance
+  0;   20;     41;      0;           0;    4;   Code_Table; Airframe icing
+  0;   20;     51;      0;           0;    7;      percent; Amount of low clouds
+  0;   20;     52;      0;           0;    7;      percent; Amount of middle clouds
+  0;   20;     53;      0;           0;    7;      percent; Amount of high clouds
+  0;   20;     61;      0;           0;   12;            m; Runway visual range (RVR)
+  0;   20;     62;      0;           0;    5;   Code_Table; State of the ground(with or without snow)
+  0;   20;     63;      0;           0;   10;   Code_Table; Special phenomena
+  0;   20;     90;      0;           0;    4;   Code_Table; Special clouds
+  0;   21;      1;      0;         -64;    7;           dB; Horizontal reflectivity
+  0;   21;      2;      0;         -64;    7;           dB; Vertical reflectivity
+  0;   21;      3;      1;          -5;    7;           dB; Differential reflectivity
+  0;   21;      5;      0;         -65;    6;           dB; Linear depolarization ratio
+  0;   21;      6;      0;         -65;    6;           dB; Circular depolarization ratio
+  0;   21;     11;      0;        -128;    8;          m/s; Doppler mean velocity in X direction
+  0;   21;     12;      0;        -128;    8;          m/s; Doppler mean velocity in Y direction
+  0;   21;     13;      0;        -128;    8;          m/s; Doppler mean velocity in Z direction
+  0;   21;     14;      1;       -4096;   13;          m/s; Doppler mean velocity (radiational)
+  0;   21;     17;      1;           0;    8;          m/s; Doppler velocity spectral width
+  0;   21;     21;     -3;           0;    4;            m; Echo tops
+  0;   21;     30;      0;         -32;    8;           dB; Signal to noise ratio
+  0;   21;     31;      0;           0;    7;      kg/m**2; Vertical integrated liquid water content
+  0;   21;     36;      7;           0;   12;          m/s; Radar rainfall intensity
+  0;   21;     41;     -2;           0;    8;            m; Bright band height
+  0;   21;     51;      0;        -256;    8;           dB; Signal power above 1 MW
+  0;   21;     62;      2;       -5000;   13;     Decibels; Backscatter
+  0;   21;     63;      1;           0;   10;      Percent; Radiometric resolution (noise value)
+  0;   21;     64;      0;           0;    8;      Numeric; Clutter noise estimate
+  0;   21;     65;      0;        -127;    8;      Numeric; Missing packet counter
+  0;   21;     66;      0;           0;   12;   Flag_Table; Wave scatterometer product confidence
+  0;   21;     67;      0;           0;   13;   Flag_Table; Wind product confidence data
+  0;   21;     68;      0;           0;    8;   Flag_Table; Radar altimeter product confidence data
+  0;   21;     69;      0;           0;   10;   Flag_Table; SST product confidence data
+  0;   21;     71;      0;           0;   16;      Numeric; Peakiness
+  0;   21;     72;      0;           0;    4;   Flag_Table; Satellite altimeter calibration status
+  0;   21;     73;      0;           0;    9;   Flag_Table; Satellite altimeter instrument mode
+  0;   21;     75;      0;           0;    8;      Numeric; Spectral intensity
+  0;   21;     76;      0;           0;    3;   Code_Table; Representation of intensities
+  0;   21;     77;      3;           0;   14;            m; Altitude correction (ionosphere)
+  0;   21;     78;      3;           0;    9;            m; Altitude correction (dry troposphere)
+  0;   21;     79;      3;        2000;   10;            m; Altitude correction (wet troposphere)
+  0;   21;     80;      3;           0;   11;            m; Altitude correction (calibration constant)
+  0;   21;     81;      3;           0;   10;            m; Open loop correction (height-time loop)
+  0;   21;     82;      3;       -3000;   14;     Decibels; Open loop correction (auto gain control)
+  0;   21;     85;      0;       -3000;    4;      Numeric; ATSR sea surface temperature across-track band number
+
+  0;   22;      1;      0;           0;    9;     deg_true; Direction of waves
+  0;   22;      2;      0;           0;    9;     deg_true; Direction of wind waves
+  0;   22;      3;      0;           0;    9;     deg_true; Direction of swell waves
+  0;   22;      4;      0;           0;    9;     deg_true; Direction of current waves
+  0;   22;     11;      0;           0;    6;            s; Period of waves
+  0;   22;     12;      0;           0;    6;            s; Period of wind waves
+  0;   22;     13;      0;           0;    6;            s; Period of swell waves
+  0;   22;     21;      1;           0;   10;            m; Height of waves
+  0;   22;     22;      1;           0;   10;            m; Height of wind waves
+  0;   22;     23;      1;           0;   10;            m; Height of swell waves
+  0;   22;     25;      2;           0;   10;            m; Standard deviation wave
+  0;   22;     26;      2;           0;   10;            m; Standard deviation of significant wave height
+  0;   22;     31;      2;           0;   13;          m/s; Speed of current
+  0;   22;     37;      3;      -10000;   15;            m; Tidal elevation with respect to national chart datum
+  0;   22;     38;      3;      -10000;   15;            m; Tidal elevation with respect to local chart datum
+  0;   22;     39;      3;       -5000;   12;            m; Meteorological residual tidal elevation (surge or offset)
+  0;   22;     40;      3;       -5000;   14;            m; Meteorological residual tidal elevation (surge or offset)
+  0;   22;     41;      1;           0;   12;        deg_K; Sea surface temperature (15 day running mean)
+  0;   22;     42;      1;           0;   12;        deg_K; Sea/water temperature
+  0;   22;     43;      2;           0;   15;        deg_K; Sea/water temperature
+  0;   22;     44;      1;           0;   14;          m/s; Sound velocity
+  0;   22;     50;      2;           0;    8;            K; Standard deviation sea surface temperature
+  0;   22;     61;      0;           0;    4;   Code_Table; State of sea
+  0;   22;     62;      2;           0;   14;          ppt; Salinity
+  0;   22;     63;      0;           0;   14;            m; Total water depth
+  0;   22;     67;      0;           0;   10;   Code_Table; Instrument type for water temperature profile measurement
+  0;   22;     68;      0;           0;    7;   Code_Table; Water temperature profile recorder types
+  0;   22;     70;      2;           0;   13;            m; Significant wave height
+  0;   22;     71;      1;           0;    9;            s; Spectral peak wave period
+  0;   22;     72;      0;           0;   13;            m; Spectral peak wave length
+  0;   22;     73;      2;           0;   13;            m; Maximum wave height
+  0;   22;     74;      1;           0;    9;            s; Average wave period
+  0;   22;     75;      0;           0;   13;            m; Average wave length
+  0;   22;     76;      0;           0;    9;  Degree_True; Direction from which dominant waves are coming
+  0;   22;     77;      0;           0;    9;       Degree; Directional spred of dominant wave
+  0;   22;     78;      0;           0;   12;            s; Duration of wave record
+  0;   22;     79;      0;           0;   16;            m; Length of wave record
+  0;   22;     80;      3;           0;   10;           Hz; Waveband central frequency
+  0;   22;     81;      5;           0;   13;        m**-1; Waveband central wave number
+  0;   22;     82;      2;           0;   20;       m**2/s; Maximum non-directional spectral wave density
+  0;   22;     83;      2;           0;   20;         m**3; Maximum non-directional spectral wave number
+  0;   22;     84;      0;           0;    7;      Numeric; Band containing maximum non-directional spectral wave density
+  0;   22;     85;      0;           0;    7;      Numeric; Spectral wave density ratio
+  0;   22;     86;      0;           0;    9;  Degree_True; Mean direction from which waves are coming
+  0;   22;     87;      0;           0;    9;  Degree_True; Principal direction from which waves are coming
+  0;   22;     88;      2;           0;    7;      Numeric; First normalized polar coordinate from Fourier coefficients
+  0;   22;     89;      2;           0;    7;      Numeric; Second normalized polar coordinate from Fourier coefficients
+  0;   22;     90;      2;           0;   20;       m**2/s; Non-directional spectral estimate by wave frequency
+  0;   22;     91;      2;           0;   20;         m**3; Non-directional spectral estimate by wave number
+  0;   22;     92;      2;           0;   20; m**2/rad**-1/s; Directional spectral estimate by wave frequency
+  0;   22;     93;      2;           0;   20;         m**4; Directional spectral estimate by wave number
+  0;   22;     94;      0;           0;    7;      Numeric; Total number of wave bands
+  0;   22;     95;      0;           0;    8;       Degree; Directional spread of individual waves
+  0;   22;     96;      3;           0;    4;        s**-1; Spectral band width
+  0;   22;     97;      0;           0;   14;            m; Mean wavelength > 731 m of image spectrum at low wave numbers
+  0;   22;     98;      0;           0;   14;            m; Wavelength spread (wavelength > 731 m) at low wave numbers
+  0;   22;     99;      0;           0;    9;     deg_true; Mean direction at low wave numbers (wavelength > 731 m)
+  0;   22;    100;      0;           0;    9;       Degree; Direction spread at low wave numbers (wavelength > 731 m)
+  0;   22;    101;      0;           0;   31;     Numberic; Total energy (wavelength > 731 m) at low wave numbers
+  0;   22;    120;      0;           0;    5;   Code_Table; Tide station automated water level check
+  0;   22;    121;      0;           0;    5;   Code_Table; Tide station manual water level check
+  0;   22;    122;      0;           0;    5;   Code_Table; Tide station automated Meteorological data check
+  0;   22;    123;      0;           0;    5;   Code_Table; Tide station manual Meteorological data check
+
+  0;   23;      1;      0;           0;    3;   Code_Table; Accident early notification - article applicable
+  0;   23;      2;      0;           0;    5;   Code_Table; Activity or facility involved in incident
+  0;   23;      3;      0;           0;    3;   Code_Table; Type of release
+  0;   23;      4;      0;           0;    3;   Code_Table; Countermeasures taken near border
+  0;   23;      5;      0;           0;    2;   Code_Table; Cause of incident
+  0;   23;      6;      0;           0;    3;   Code_Table; Incident situation
+  0;   23;      7;      0;           0;    3;   Code_Table; Characteristic of release
+  0;   23;      8;      0;           0;    2;   Code_Table; State of current release
+  0;   23;      9;      0;           0;    2;   Code_Table; State of expected release
+  0;   23;     16;      0;           0;    2;   Code_Table; Possibility of significant chemical toxic health effect
+  0;   23;     17;      6;           0;   20;       m**3/s; Flow discharge of major recipient
+  0;   23;     18;      0;           0;    3;   Code_Table; release behavior over time
+  0;   23;     19;      0;      -15000;   17;            m; Actual release height
+  0;   23;     21;      0;      -15000;   17;            m; Effective release height
+  0;   23;     22;      0;           0;   24;            m; Distance of relative point or site of incident
+  0;   23;     23;      1;           0;   12;          m/s; Main transport speed in atmosphere
+  0;   23;     24;      2;           0;   13;          m/s; Main transport speed in water
+  0;   23;     25;      2;           0;   13;          m/s; Main transport speed in ground water
+  0;   23;     27;      0;           0;    9;     deg_true; Main transport direction in atmosphere
+  0;   23;     28;      0;           0;    9;     deg_true; Main transport direction in water
+  0;   23;     29;      0;           0;    9;     deg_true; Main transport direction in ground water
+  0;   23;     31;      0;           0;    2;   Code_Table; Possibility that plume will encounter precipitation cwin state in which incident occurred
+  0;   23;     32;      0;           0;    2;   Code_Table; Plume will encounter ichange in wind direction and/or speed flag
+
+  0;   24;      1;     -1;           0;   28;           Bq; Estimate of radiatioactivity released up to specified time
+  0;   24;      2;     -1;           0;   28;           Bq; Estimated maximum potential release
+  0;   24;      3;      0;           0;    5;   Code_Table; Composition of release
+  0;   24;      4;      0;           0;   16;    CCITT_IA5; Element name
+  0;   24;      5;      0;           0;    9;      Numeric; Isotope mass
+  0;   24;     11;      2;           0;   32;          mSv; Dose
+  0;   24;     12;      2;           0;   32;          mSv; Trajectory dose (defined location and expected time of arrival)
+  0;   24;     13;      2;           0;   32;          mSv; Gamma dose in air along the main transport path (defined location and time period
+  0;   24;     21;      2;           0;   32;      Bq/m**3; Air concentration (named isotope type including gross beta)
+  0;   24;     22;      2;           0;   32;         Bq/l; Concentration in precipitation (of named isotope type)
+
+  0;   25;      1;     -1;           0;    6;            m; Range gate length
+  0;   25;      2;      0;           0;    4;      Numeric; Number of gates averaged
+  0;   25;      3;      0;           0;    8;      Numeric; Number of integrated pulses
+  0;   25;      4;      0;           0;    2;   Code_Table; Echo processing
+  0;   25;      5;      0;           0;    2;   Code_Table; Echo integration
+  0;   25;      6;      0;           0;    3;   Code_Table; Z to R conversion
+  0;   25;      7;      0;           0;   12;      Numeric; Z to R conversion factor
+  0;   25;      8;      2;           0;    9;      Numeric; Z to R conversion exponent
+  0;   25;      9;      0;           0;    4;   Flag_Table; Calibration method
+  0;   25;     10;      0;           0;    4;   Code_Table; Clutter treatment
+  0;   25;     11;      0;           0;    2;   Code_Table; Ground occultation correction (screening)
+  0;   25;     12;      0;           0;    2;   Code_Table; Range attenuation correction
+  0;   25;     13;      0;           0;    2;   Flag_Table; Bright band correction
+  0;   25;     14;      0;           0;   12;      Numeric; Azimuth clutter cut-off
+  0;   25;     15;      0;           0;    2;   Flag_Table; Radome attenuation correction
+  0;   25;     16;      5;           0;    6;         dB/m; Clear air attenuation correction
+  0;   25;     17;      0;           0;    2;   Flag_Table; Precipitation attenuation correction
+  0;   25;     18;      7;           0;    6;      Numeric; A to Z law for attenuation factor
+  0;   25;     19;      2;           0;    7;      Numeric; A to Z law for attenuation exponent
+  0;   25;     20;      0;           0;    2;   Code_Table; Mean speed estimation
+  0;   25;     21;      0;           0;    8;   Flag_Table; Wind computation enhancement
+  0;   25;     30;      0;           0;    2;   Code_Table; SST usage
+  0;   25;     32;      0;           0;    2;   Code_Table; NOAA wind profiler high/low mode data
+  0;   25;     33;      0;           0;    2;   Code_Table; NOAA wind profiler submode
+  0;   25;     34;      0;           0;    4;   Code_Table; NOAA wind profiler Q/C test results
+  0;   25;     40;      0;           0;    4;   Code_Table; CO2 wind product derivation
+  0;   25;     41;      0;           0;    2;   Code_Table; Moving platform direction reporting method
+  0;   25;     42;      0;           0;    2;   Code_Table; Moving platform speed reporting method
+  0;   25;     43;      4;           0;   15;            s; Wave sampling interval (time)
+  0;   25;     44;      2;           0;   14;            m; Wave sampling interval (space)
+  0;   25;     45;      0;           0;   21;   Flag_Table; HIRS channel combination
+  0;   25;     46;      0;           0;    5;   Flag_Table; MSU channel combination
+  0;   25;     47;      0;           0;    4;   Flag_Table; SSU channel combination
+  0;   25;     48;      0;           0;   16;   Flag_Table; AMSU-A channel combination
+  0;   25;     49;      0;           0;    6;   Flag_Table; AMSU-B channel combination
+  0;   25;     50;      0;           0;    7;   Flag_Table; AVHRR channel combination
+  0;   25;     51;      0;           0;   12;   Flag_Table; Observation quality
+  0;   25;     60;      0;           0;   14;      Numeric; Software identification
+
+  0;   26;      1;      1;           0;   12;         Hour; Principal time of daily reading in UTC of maximum temperature
+  0;   26;      2;      1;           0;   12;         Hour; Principal time of daily reading in UTC of minimum temperature
+  0;   26;      3;      0;       -1440;   12;       Minute; Time difference
+
+  0;   27;      1;      5;    -9000000;   25;          deg; Latitude (high accuracy)
+  0;   27;      2;      2;       -9000;   15;          deg; Latitude (coarse accuracy)
+  0;   27;      3;      2;       -9000;   15;          deg; Alternate latitude
+  0;   27;     20;      0;           0;   16;      Numeric; Satellite locationon counter
+  0;   27;     21;      0;           0;   16;      Numeric; Satellite sub-locationon dimensions
+  0;   27;     31;      2; -1073741824;   31;            m; In direction of 0 degrees longitude, distance from the Earth's centre
+
+  0;   28;      1;      5;   -18000000;   26;          deg; Longitude (high accuracy)
+  0;   28;      2;      2;      -18000;   16;          deg; Longitude (coarse accuracy)
+  0;   28;      3;      2;      -18000;   16;          deg; Alternate longtiude
+  0;   28;     31;      2; -1073741824;   31;            m; In direction of 90 degrees East, distance from the Earth's centre
+
+  0;   29;      1;      0;           0;    3;   Code_Table; Projection type
+  0;   29;      2;      0;           0;    2;   Code_Table; Coordinate grid type
+
+  0;   30;      1;      0;           0;    4;      Numeric; Pixel value (4 bits)
+  0;   30;      2;      0;           0;    8;      Numeric; Pixel value (8 bits)
+  0;   30;      4;      0;           0;   16;      Numeric; Pixel value (16 bits)
+  0;   30;     21;      0;           0;   12;      Numeric; Number of pixels per row
+  0;   30;     22;      0;           0;   12;      Numeric; Number of pixels per column
+  0;   30;     31;      0;           0;    4;   Code_Table; Picture type
+  0;   30;     32;      0;           0;   16;   Flag_Table; Combined picture
+
+  0;   31;      0;      0;           0;    1;      Numeric; Short delayed descriptor replication factor
+  0;   31;      1;      0;           0;    8;      Numeric; Delayed descriptor replication factor
+  0;   31;      2;      0;           0;   16;      Numeric; Extended delayed descriptor replication factor
+  0;   31;     11;      0;           0;    8;      Numeric; Delayed descriptor and data repetion factor
+  0;   31;     12;      0;           0;   16;      Numeric; Extended delayed descriptor and data repitition factor
+  0;   31;     21;      0;           0;    6;   Code_Table; Associated field significance
+  0;   31;     31;      0;           0;    1;   Flag_Table; Data present indicator
+
+  0;   33;      2;      0;           0;    2;   Code_Table; Quality information
+  0;   33;      3;      0;           0;    3;   Code_Table; Quality information
+  0;   33;      7;      0;           0;    7;      Percent; Per cent confidence
+  0;   33;     20;      0;           0;    3;   Code_Table; Quality control indication of following value
+  0;   33;     21;      0;           0;    2;   Code_Table; Quality of following value
+  0;   33;     22;      0;           0;    2;   Code_Table; Quality of buoy satellite transmission
+  0;   33;     23;      0;           0;    2;   Code_Table; Quality of buoy location
+  0;   33;     24;      0;           0;    4;   Code_Table; Station elevation quality mark (for mobile stations)
+  0;   33;     25;      0;           0;    3;   Code_Table; ACARS interpolated values
+  0;   33;     26;      0;           0;    6;   Code_Table; Mixing ratio quality
+  0;   33;     27;      0;           0;    3;   Code_Table; Location quality class
diff --git a/data/tables/B3M-000-004-D b/data/tables/B3M-000-004-D
new file mode 100644
index 0000000..3ccc79e
--- /dev/null
+++ b/data/tables/B3M-000-004-D
@@ -0,0 +1,1760 @@
+#
+# BUFR Table D (Lists of Common Sequences)
+#
+# Descriptor sequences are terminated with -1
+#
+# Sequences do not need to appear in any order.  Sequence A
+# which includes sequence B, may appear before sequence B
+# is defined.
+#
+3	0	2
+	0	0	2
+	0	0	3
+	-1
+
+3	0	3
+	0	0	10
+	0	0	11
+	0	0	12
+	-1
+
+3	0	4
+	3	0	3
+	0	0	13
+	0	0	14
+	0	0	15
+	0	0	16
+	0	0	17
+	0	0	18
+	0	0	19
+	0	0	20
+	-1
+
+3	0	10
+	3	0	3
+	1	1	0
+	0	31	1
+	0	0	30
+	-1
+
+3	1	1
+	0	1	1
+	0	1	2
+	-1
+
+3	1	2
+	0	1	3
+	0	1	4
+	0	1	5
+	-1
+
+3	1	3
+	0	1	11
+	0	1	12
+	0	1	13
+	-1
+
+3	1	11
+	0	4	1
+	0	4	2
+	0	4	3
+	-1
+
+3	1	12
+	0	4	4
+	0	4	5
+	-1
+
+3	1	13
+	0	4	4
+	0	4	5
+	0	4	6
+	-1
+
+3	1	21
+	0	5	1
+	0	6	1
+	-1
+
+3	1	22
+	0	5	1
+	0	6	1
+	0	7	1
+	-1
+
+3	1	23
+	0	5	2
+	0	6	2
+	-1
+
+3	1	24
+	0	5	2
+	0	6	2
+	0	7	1
+	-1
+
+3	1	25
+	3	1	23
+	0	4	3
+	3	1	12
+	-1
+
+3	1	26
+	3	1	21
+	0	4	3
+	0	4	3
+	0	4	4
+	0	4	4
+	0	4	5
+	0	4	5
+	-1
+
+3	1	31
+	3	1	1
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	22
+	-1
+
+3	1	32
+	3	1	1
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	24
+	-1
+
+3	1	33
+	0	1	5
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	21
+	-1
+
+3	1	34
+	0	1	5
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	35
+	0	1	5
+	0	1	12
+	0	1	13
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	36
+	3	1	3
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	37
+	3	1	1
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	22
+	-1
+
+3	1	38
+	3	1	1
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	24
+	-1
+
+3	1	39
+	3	1	3
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	40
+	3	1	3
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	24
+	-1
+
+3	1	41
+	0	1	7
+	0	2	21
+	0	2	22
+	3	1	11
+	3	1	12
+	-1
+
+3	1	42
+	3	1	41
+	3	1	21
+	-1
+
+3	1	43
+	0	1	7
+	0	2	23
+	3	1	11
+	3	1	13
+	3	1	21
+	-1
+
+3	1	44
+	0	1	7
+	0	2	24
+	3	1	11
+	3	1	13
+	3	1	21
+	-1
+
+3	1	45
+	3	1	11
+	3	1	12
+	2	1	138
+	2	2	131
+	0	4	6
+	2	01	0
+	2	2	0
+	3	4	30
+	3	4	31
+	-1
+
+3	1	47
+	0	1	7
+	0	25	60
+	0	1	33
+	0	1	34
+	0	1	12
+	3	1	45
+	0	2	21
+	3	1	11
+	3	1	12
+	2	1	138
+	2	2	131
+	0	4	6
+	2	1	0
+	2	2	0
+	3	1	23
+	-1 
+
+3	1	48
+	0	2	104
+	0	2	121
+	0	2	113
+	0	2	26
+	0	2	27
+	0	2	111
+	0	2	140
+	2	2	127
+	0	1	13
+	2	2	126
+	0	7	1
+	2	2	0
+	0	25	10
+	0	21	64
+	-1
+
+3	1	49
+	0	2	111
+	0	2	112
+	0	21	62
+	0	21	63
+	0	21	64
+	-1
+
+3	1	51
+	0	1	6
+	0	2	61
+	3	1	11
+	3	1	12
+	3	1	21
+	0	8	4
+	-1
+
+3	1	55
+	0	1	5
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	21
+	0	1	12
+	0	1	14
+	-1
+
+3	1	62
+	1	1	0
+	0	31	1
+	3	1	1
+	-1
+
+3	1	65
+	0	1	6
+	0	1	8
+	0	2	1
+	0	2	2
+	0	2	5
+	0	2	62
+	0	2	70
+	0	2	65
+	-1
+
+3	1	66
+	3	1	11
+	3	1	13
+	3	1	23
+	0	7	4
+	0	2	64
+	0	8	4
+	-1
+
+3	2	1
+	0	10	4
+	0	10	51
+	0	10	61
+	0	10	63
+	-1
+
+3	2	2
+	0	10	4
+	0	7	4
+	0	10	3
+	0	10	61
+	0	10	63
+	-1
+
+3	2	3
+	0	11	11
+	0	11	12
+	0	12	4
+	0	12	6
+	0	13	3
+	0	20	1
+	0	20	3
+	0	20	4
+	0	20	5
+	-1
+
+3	2	4
+	0	20	10
+	0	8	2
+	0	20	11
+	0	20	13
+	0	20	12
+	0	20	12
+	0	20	12
+	-1
+
+3	2	5
+	0	8	2
+	0	20	11
+	0	20	12
+	0	20	13
+	-1
+
+3	2	6
+	0	10	4
+	0	10	51
+	0	10	62
+	0	10	63
+	-1
+
+3	2	11
+	3	2	1
+	3	2	3
+	3	2	4
+	-1
+
+3	2	12
+	3	2	2
+	3	2	3
+	3	2	4
+	-1
+
+3	2	13
+	3	2	6
+	3	2	3
+	1	1	0
+	0	31	1
+	3	2	05
+	-1
+
+3	2	21
+	0	22	1
+	0	22	11
+	0	22	21
+	-1
+
+3	2	22
+	0	22	2
+	0	22	12
+	0	22	22
+	-1
+
+3	2	23
+	0	22	3
+	0	22	13
+	0	22	23
+	-1
+
+3	2	24
+	3	2	22
+	1	1	2
+	3	2	23
+	-1
+
+3	2	51
+	0	10	4
+	0	10	51
+	0	7	4
+	0	10	3
+	0	12	4
+	0	12	51
+	0	12	16
+	0	12	17
+	0	13	4
+	1	2	4
+	0	8	51
+	0	8	20
+	-1
+
+3	3	1
+	0	7	3
+	0	11	1
+	0	11	22
+	-1
+
+3	3	2
+	0	7	4
+	0	11	1
+	0	11	2
+	-1
+
+3	3	3
+	0	7	4
+	0	10	3
+	0	12	1
+	0	12	3
+	-1
+
+3	3	4
+	0	7	4
+	0	10	3
+	0	12	1
+	0	12	3
+	0	11	1
+	0	11	2
+	-1
+
+3	3	11
+	0	7	3
+	0	8	1
+	0	11	1
+	0	11	2
+	-1
+
+3	3	12
+	0	7	4
+	0	8	1
+	0	11	1
+	0	11	2
+	-1
+
+3	3	13
+	0	7	4
+	0	8	1
+	0	10	3
+	0	12	1
+	0	13	3
+	0	11	1
+	0	11	2
+	-1
+
+3	3	14
+	0	7	4
+	0	8	1
+	0	10	3
+	0	12	1
+	0	12	3
+	0	11	1
+	0	11	2
+	-1
+
+3	3	21
+	0	7	4
+	0	7	4
+	2	4	7
+	0	31	21
+	-1
+
+3	3	22
+	3	3	21
+	0	10	3
+	2	4	0
+	-1
+
+3	3	23
+	3	3	21
+	0	12	1
+	2	4	0
+	-1
+
+3	3	24
+	3	3	21
+	0	13	16
+	2	4	0
+	-1
+
+3	3	25
+	0	2	25
+	2	4	7
+	0	31	21
+	0	12	63
+	2	4	0
+	-1
+
+3	3	26
+	0	7	4
+	0	8	3
+	2	4	7
+	0	31	21
+	0	12	1
+	2	4	0
+	-1
+
+3	3	27
+	0	7	4
+	2	4	7
+	0	31	21
+	0	10	3
+	2	4	0
+	-1
+
+3	3	31
+	0	7	4
+	0	8	3
+	0	7	21
+	0	7	22
+	0	8	12
+	0	12	61
+	-1
+
+3	3	32
+	0	20	11
+	0	20	16
+	-1
+
+3	3	33
+	0	20	10
+	0	20	16
+	-1
+
+3	4	1
+	0	8	3
+	0	10	4
+	0	12	1
+	0	11	1
+	0	11	2
+	-1
+
+3	4	2
+	0	8	3
+	0	10	4
+	0	11	1
+	0	11	2
+	-1
+
+3	4	3
+	0	8	3
+	0	12	1
+	-1
+
+3	4	4
+	0	8	3
+	0	10	4
+	0	20	10
+	0	12	1
+	-1
+
+3	4	5
+	0	2	24
+	0	7	4
+	0	7	4
+	0	13	3
+	-1
+
+3	4	6
+	0	14	1
+	0	14	1
+	0	14	3
+	-1
+
+3	4	30
+	0	27	31
+	0	28	31
+	0	10	31
+	-1
+
+3	4	31
+	0	1	41
+	0	1	42
+	0	1	43
+	-1
+
+3	6	1
+	0	2	32
+	1	2	0
+	0	31	1
+	0	7	62
+	0	22	42
+	-1
+
+3	6	2
+	0	2	31
+	0	22	4
+	0	22	31
+	-1
+
+3	6	3
+	0	2	2
+	0	11	11
+	0	11	12
+	0	12	4
+	-1
+
+3	6	4
+	0	2	32
+	0	2	33
+	1	3	0
+	0	31	1
+	0	7	62
+	0	22	43
+	0	22	62
+	-1
+
+3	6	5
+	0	2	31
+	1	3	0
+	0	31	1
+	0	7	62
+	0	22	4
+	0	22	31
+	-1
+
+3	6	6
+	3	6	3
+	3	6	2
+	0	22	63
+	-1
+
+3	6	7
+	0	1	12
+	0	1	14
+	3	6	8
+	0	4	24
+	0	27	3
+	0	28	3
+	-1
+
+3	6	8
+	0	2	34
+	0	2	35
+	0	2	36
+	-1
+
+3	6	20
+	3	6	24
+	1	2	6
+	0	22	38
+	0	22	39
+	-1
+
+3	6	21
+	0	1	75
+	3	1	11
+	3	1	12
+	0	22	122
+	0	22	123
+	0	12	1
+	3	3	2
+	-1
+
+3	6	22
+	0	1	75
+	3	1	11
+	3	1	12
+	0	22	38
+	0	22	39
+	-1
+
+3	6	23
+	0	1	15
+	3	1	23
+	3	1	11
+	3	1	12
+	0	22	38
+	0	22	39
+	0	22	120
+	0	22	121
+	-1
+
+3	6	24
+	0	1	75
+	3	1	11
+	3	1	12
+	0	22	42
+	0	22	120
+	0	22	121
+	0	4	25
+	0	4	15
+	-1
+
+3	7	1
+	3	1	31
+	3	2	11
+	-1
+
+3	7	2
+	3	1	32
+	3	2	11
+	-1
+
+3	7	3
+	3	7	1
+	1	1	0
+	0	31	1
+	3	2	5
+	-1
+
+3	7	4
+	3	7	2
+	1	1	0
+	0	31	1
+	3	2	5
+	-1
+
+3	7	5
+	3	7	1
+	1	1	4
+	3	2	5
+	-1
+
+3	7	6
+	3	7	2
+	1	1	4
+	3	2	5
+	-1
+
+3	7	7
+	3	1	31
+	3	2	12
+	-1
+
+3	7	8
+	3	1	32
+	3	2	12
+	-1
+
+3	7	9
+	3	1	31
+	3	2	13
+	-1
+
+3	7	11
+	0	1	63
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	24
+	0	7	6
+	0	11	1
+	0	11	16
+	0	11	17
+	0	11	2
+	0	11	42
+	0	7	6
+	0	12	1
+	0	12	3
+	0	10	52
+	0	20	9
+	-1
+
+3	7	12
+	1	3	0
+	0	31	1
+	0	8	23
+	0	5	21
+	0	20	1
+	-1
+
+3	7	13
+	1	6	0
+	0	31	1
+	0	1	64
+	0	8	14
+	0	20	61
+	0	8	14
+	0	20	61
+	0	20	18
+	-1
+
+3	7	14
+	1	1	0
+	0	31	1
+	0	20	19
+	-1
+
+3	7	15
+	1	1	0
+	0	31	1
+	3	2	5
+	0	8	2
+	0	20	11
+	0	20	12
+	0	20	13
+	0	20	2
+	-1
+
+3	7	16
+	1	1	0
+	0	31	1
+	0	20	20
+	-1
+
+3	7	17
+	1	1	0
+	0	31	1
+	0	11	70
+	-1
+
+3	7	18
+	0	8	16
+	1	2	0
+	0	31	1
+	0	8	17
+	3	1	12
+	1	4	0
+	0	31	1
+	0	7	6
+	0	11	1
+	0	11	2
+	0	11	41
+	0	20	9
+	1	1	0
+	0	31	1
+	0	20	1
+	1	1	0
+	0	31	1
+	0	20	19
+	-1
+
+3	7	20
+	3	7	11
+	3	7	14
+	3	7	16
+	-1
+
+3	7	21
+	3	7	11
+	3	7	12
+	3	7	13
+	3	7	14
+	3	7	15
+	3	7	16
+	3	7	17
+	3	7	18
+	3	7	15
+	-1
+
+3	8	1
+	3	1	33
+	3	2	11
+	0	22	42
+	-1
+
+3	8	2
+	3	1	34
+	3	2	11
+	0	22	42
+	-1
+
+3	8	3
+	3	1	35
+	3	2	11
+	0	22	42
+	-1
+
+3	8	4
+	3	1	36
+	3	2	11
+	0	22	42
+	-1
+
+3	8	5
+	3	8	4
+	3	2	24
+	-1
+
+3	8	6
+	0	10	4
+	0	10	61
+	0	10	63
+	0	11	1
+	0	11	2
+	0	12	4
+	0	13	3
+	0	22	42
+	-1
+
+3	8	7
+	3	1	55
+	3	2	11
+	0	7	62
+	0	22	42
+	-1
+
+3	9	1
+	3	1	37
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	2
+	3	1	38
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	3
+	3	1	37
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	4
+	3	1	38
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	5
+	3	1	37
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	6
+	3	1	38
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	7
+	3	1	37
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	8
+	3	1	38
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	11
+	3	1	39
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	12
+	3	1	39
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	13
+	3	1	39
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	14
+	3	1	39
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	15
+	3	1	40
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	16
+	3	1	40
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	17
+	3	1	40
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	18
+	3	1	40
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	19
+	3	1	31
+	0	2	3
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	20
+	3	1	31
+	0	2	3
+	1	4	0
+	0	31	1
+	0	7	3
+	0	11	3
+	0	11	4
+	0	11	5
+	-1
+
+3	10	1
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	26
+	3	3	25
+	-1
+
+3	10	2
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	9
+	3	3	23
+	-1
+
+3	10	3
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	6
+	3	3	23
+	-1
+
+3	10	4
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	3
+	3	3	24
+	-1
+
+3	10	5
+	3	1	42
+	3	3	31
+	3	3	33
+	1	1	0
+	0	31	1
+	3	03	25
+	-1
+
+3	10	6
+	3	1	42
+	3	3	31
+	3	3	33
+	1	1	0
+	0	31	1
+	3	3	23
+	-1
+
+3	10	7
+	3	1	42
+	3	3	31
+	3	3	33
+	1	1	0
+	0	31	1
+	3	3	24
+	-1
+
+3	11	1
+	3	1	51
+	0	7	2
+	0	12	1
+	0	11	1
+	0	11	2
+	0	11	31
+	0	11	32
+	0	11	33
+	0	20	41
+	-1
+
+3	11	2
+	3	1	65
+	3	1	66
+	3	11	3
+	3	11	4
+	-1
+
+3	11	3
+	0	10	70
+	0	11	1
+	0	11	2
+	0	12	1
+	0	13	2
+	-1
+
+3	11	4
+	1	1	0
+	0	31	0
+	0	11	34
+	1	1	0
+	0	31	0
+	0	11	35
+	1	1	0
+	0	31	0
+	0	11	75
+	1	1	0
+	0	31	0
+	0	11	76
+	1	1	0
+	0	31	0
+	0	33	25
+	1	1	0
+	0	31	0
+	0	33	26
+	-1
+
+3	12	1
+	3	1	43
+	3	4	1
+	-1
+
+3	12	2
+	3	1	43
+	3	4	2
+	-1
+
+3	12	3
+	3	1	42
+	3	4	3
+	-1
+
+3	12	4
+	3	1	42
+	3	4	4
+	-1
+
+3	12	5
+	3	1	42
+	0	20	14
+	-1
+
+3	12	6
+	3	1	44
+	3	4	5
+	-1
+
+3	12	7
+	3	1	42
+	3	4	6
+	-1
+
+3	12	10
+	0	1	7
+	0	5	40
+	0	2	21
+	0	5	41
+	0	4	1
+	0	4	43
+	-1
+
+3	12	11
+	2	2	131
+	2	1	149
+	0	4	6
+	2	1	0
+	1	2	32
+	0	10	2
+	2	2	0
+	0	5	43
+	0	5	53
+	-1
+
+3	12	12
+	2	2	129
+	2	1	132
+	1	1	19
+	0	12	63
+	2	1	0
+	2	2	0
+	-1
+
+3	12	13
+	0	5	42
+	2	2	129
+	2	1	135
+	0	12	63
+	2	1	0
+	2	2	0
+	-1
+
+3	12	14
+	3	12	10
+	3	12	11
+	1	5	56
+	3	1	23
+	0	5	42
+	0	5	52
+	3	12	12
+	3	12	13
+	-1
+
+3	12	15
+	1	9	11
+	3	1	23
+	0	5	42
+	0	5	52
+	2	2	129
+	2	1	132
+	1	1	4
+	0	12	63
+	2	2	0
+	2	1	0
+	-1
+
+3	12	16
+	3	12	10
+	3	12	11
+	3	12	15
+	-1
+
+3	12	17
+	1	9	8
+	3	1	23
+	0	5	42
+	0	5	52
+	2	2	129
+	2	1	132
+	1	1	3
+	0	12	63
+	2	2	0
+	2	1	0
+	-1
+
+3	12	18
+	3	12	10
+	3	12	11
+	3	12	17
+	-1
+
+3	12	20
+	3	1	47
+	3	1	48
+	0	15	15
+	0	29	2
+	0	21	76
+	1	4	12
+	0	6	30
+	1	2	12
+	0	5	30
+	0	21	75
+	0	21	66
+	-1
+
+3	12	21
+	3	1	47
+	1	1	3
+	3	1	49
+	0	11	12
+	0	11	11
+	0	21	67
+	-1
+
+3	12	22
+	3	1	47
+	0	8	22
+	0	11	12
+	0	11	50
+	0	22	70
+	0	22	26
+	3	12	41
+	0	10	50
+	0	21	68
+	0	21	71
+	0	21	72
+	0	21	73
+	3	12	42
+	0	21	62
+	0	15	11
+	-1
+
+3	12	23
+	3	1	47
+	1	3	3
+	0	8	22
+	0	12	61
+	0	22	50
+	0	21	69
+	0	21	85
+	-1
+
+3	12	24
+	3	12	20
+	0	8	60
+	0	8	22
+	0	8	60
+	0	8	22
+	0	25	14
+	0	22	101
+	0	22	97
+	0	22	98
+	0	22	99
+	0	22	100
+
+3	12	41
+	2	1	141
+	2	2	130
+	0	7	1
+	2	1	00
+	2	2	00
+	-1
+
+3	12	42
+	0	21	77
+	0	21	78
+	0	21	79
+	0	21	80
+	0	21	81
+	0	21	82
+	-1
+
+3	13	9
+	0	21	1
+	1	1	0
+	0	31	1
+	0	21	1
+	-1
+
+3	13	10
+	0	21	36
+	1	1	0
+	0	31	1
+	0	21	36
+	-1
+
+3	13	31
+	0	6	2
+	0	6	12
+	1	1	0
+	0	31	2
+	0	30	1
+	-1
+
+3	13	32
+	0	5	2
+	0	5	12
+	1	1	0
+	0	31	2
+	3	13	31
+	-1
+
+3	13	41
+	0	6	2
+	1	10	0
+	0	31	1
+	1	4	0
+	0	31	1
+	0	6	12
+	1	1	0
+	0	31	12
+	0	30	1
+	0	6	12
+	1	1	0
+	0	31	1
+	0	30	1
+	-1
+
+3	13	42
+	0	5	2
+	0	5	12
+	1	1	0
+	0	31	2
+	3	13	41
+	-1
+
+3	13	43
+	0	6	2
+	0	5	2
+	0	5	12
+	1	12	0
+	0	31	1
+	1	10	0
+	0	31	1
+	1	04	0
+	0	31	1
+	0	6	12
+	1	1	0
+	0	31	11
+	0	30	1
+	1	1	0
+	0	31	1
+	0	30	1
+	-1
+	
+3	15	1
+	0	1	11
+	3	1	11
+	3	1	12
+	3	1	23
+	3	6	1
+	-1
+
+3	15	2
+	0	1	11
+	3	1	11
+	3	1	12
+	3	1	23
+	3	6	4
+	-1
+
+3	16	1
+	3	1	11
+	0	4	4
+	3	1	23
+	0	1	21
+	0	2	41
+	0	19	1
+	0	10	51
+	0	19	2
+	0	19	3
+	0	19	4
+	-1
+
+3	16	2
+	0	8	21
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	4	5
+	0	1	33
+	0	8	21
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	4	5
+	0	7	2
+	0	7	2
+	-1
+
+3	16	3
+	1	10	0
+	0	31	1
+	0	8	11
+	0	8	7
+	1	4	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	10	2
+	0	11	2
+	0	8	7
+	0	8	11
+	-1
+
+3	16	4
+	1	11	0
+	0	31	1
+	0	8	11
+	0	8	7
+	0	7	2
+	0	7	2
+	1	2	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	11	31
+	0	8	7
+	0	8	11
+	-1
+
+3	16	5
+	1	8	0
+	0	31	1
+	0	8	5
+	0	8	7
+	0	5	2
+	0	6	2
+	0	1	26
+	0	19	1
+	0	8	7
+	0	8	5
+	-1
+
+3	16	6
+	1	12	0
+	0	31	1
+	0	8	11
+	0	8	7
+	0	7	2
+	0	7	2
+	1	2	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	20	11
+	0	20	12
+	0	8	7
+	0	8	11
+	-1
+
+3	16	7
+	1	10	0
+	0	31	1
+	0	8	11
+	0	8	7
+	1	4	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	19	5
+	0	19	6
+	0	8	7
+	0	8	11
+	-1
+
+3	16	8
+	1	11	0
+	0	31	1
+	0	8	1
+	0	8	7
+	0	8	23
+	1	3	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	10	2
+	0	8	23
+	0	8	7
+	0	8	1
+	-1
+
+3	16	9
+	1	11	0
+	0	31	1
+	0	8	11
+	0	8	7
+	0	7	2
+	0	7	2
+	1	2	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	20	41
+	0	8	7
+	0	8	11
+	-1
+
+3	16	10
+	1	7	0
+	0	31	1
+	0	8	11
+	0	8	7
+	0	1	22
+	0	5	2
+	0	6	2
+	0	8	7
+	0	8	11
+	-1
+
+3	16	11
+	1	16	0
+	0	31	1
+	0	8	11
+	0	1	22
+	0	8	7
+	0	1	2
+	0	31	1
+	0	5	2
+	0	6	2
+	0	8	21
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	4	5
+	0	20	90
+	0	8	21
+	0	8	7
+	0	8	11
+	-1
+
+3	18	1
+	3	1	25
+	0	24	11
+	-1
+
+3	18	3
+	3	1	26
+	0	24	5
+	0	24	4
+	0	24	21
+	-1
+
+3	18	4
+	3	1	25
+	0	4	23
+	0	13	11
+	0	24	5
+	0	24	4
+	0	24	22
+	-1
+
+3	21	1
+	0	2	101
+	0	2	114
+	0	2	105
+	0	2	106
+	0	2	107
+	0	2	121
+	-1
+
+3	21	3
+	0	21	51
+	0	21	14
+	0	21	17
+	0	21	30
+	-1
+
+3	21	4
+	3	1	31
+	0	2	3
+	1	1	0
+	0	31	1
+	3	21	3
+	-1
+
+3	21	5
+	0	25	4
+	0	2	121
+	0	2	122
+	0	2	123
+	0	2	124
+	0	2	125
+	0	2	126
+	0	2	127
+	0	2	128
+	0	2	129
+	0	2	130
+	0	2	131
+	-1
+
+3	21	6
+	0	25	1
+	0	25	2
+	0	25	3
+	0	25	5
+	-1
+
+3	21	7
+	0	25	9
+	0	25	10
+	0	25	11
+	0	25	12
+	0	25	13
+	0	25	15
+	0	25	16
+	0	25	17
+	-1
+
+3	21	8
+	0	25	6
+	0	25	7
+	0	25	8
+	-1
+
+3	21	9
+	0	25	18
+	0	25	19
+	-1
+
+3	21	10
+	0	2	101
+	0	7	2
+	0	2	102
+	0	2	103
+	0	2	104
+	0	2	105
+	0	2	106
+	0	2	107
+	0	2	108
+	0	2	109
+	0	2	110
+	0	2	132
+	0	2	133
+	-1
+
+3	21	11
+	0	30	31
+	0	30	32
+	0	29	2
+	-1
+
+3	21	12
+	1	1	0
+	0	31	1
+	0	2	135
+	0	2	135
+	-1
diff --git a/data/tables/B3M-000-005-0 b/data/tables/B3M-000-005-0
new file mode 100644
index 0000000..b68ae8b
--- /dev/null
+++ b/data/tables/B3M-000-005-0
@@ -0,0 +1,308 @@
+##############################################################################
+# BUFR Table 0
+#
+#
+# Notes
+# -----
+#
+# * This table comes from GRIB Code Table 0 (Identification of center)
+#
+# * A value of 1 in the first column indicates a center that uses minor
+#   version numbers with local tables.  Since minor local table version
+#   numbers are stored in Section 1, Octet 18, the value in the first
+#   column must not be set if a center uses Section 1, Octet 18 for other
+#   purposes (i.e., ECMWF).
+#
+#
+##############################################################################
+
+0	  0	RESERVED
+
+# 1-9: WMCs
+
+0	  1	Melbourne
+0	  2	Melbourne
+0	  3	Melbourne
+0	  4	Moscow
+0	  5	Moscow
+0	  6	Moscow
+0	  7	US Weather Service - National Meteorological Center (NMC)
+0	  8	US National Weather Service Telecommunications Gateway (NWSTG)
+0	  9	Reserved for USA
+
+# 10-25: Centers in Region I
+
+0	 10	Cairo (RSMC/RAFC)
+0	 11	Cairo (RSMC/RAFC)
+0	 12	Dakar (RSMC/RAFC)
+0	 13	Dakar (RSMC/RAFC)
+0	 14	Nairobi (RSMC/RAFC)
+0	 15	Nairobi (RSMC/RAFC)
+0	 16	Antananarivo (RSMC)
+0	 17	Antananarivo (RSMC)
+0	 18	Tunis-Casablanca (RSMC/RAFC)
+0	 19	Tunis-Casablanca (RSMC/RAFC)
+0	 20	Las Palmas (RAFC)
+0	 21	Algiers (RSMC)
+0	 22	Lagos (RSMC)
+0	 23	Lagos (RSMC)
+0	 24	Reserved for other centers in Region I
+0	 25	Reserved for other centers in Region I
+
+# 26-40 Centers in Region II
+
+0	 26	Khabarovsk (RSMC)
+0	 27	Khabarovsk (RSMC)
+0	 28	New Delhi (RSMC/RAFC)
+0	 29	New Delhi (RSMC/RAFC)
+0	 30	Novosibirsk (RSMC)
+0	 31	Novosibirsk (RSMC)
+0	 32	Tashkent (RSMC)
+0	 33	Tashkent (RSMC)
+0	 34	Tokyo (RSMC), Japan Meteorological Agency
+0	 35	Tokyo (RSMC/RAFC)
+0	 36	Bangkok (RAFC)
+0	 37	Ulan Bator
+0	 38	Beijing (RSMC)
+0	 39	Beijing (RSMC)
+0	 40	Reserved for other centers in Region II
+
+# 41-50: Centers in Region III
+
+0	 41	Buenos Aires (RSMC/RAFC)
+0	 42	Buenos Aires (RSMC/RAFC)
+0	 43	Brasilia (RSMC/RAFC)
+0	 44	Brasilia (RSMC/RAFC)
+0	 45	Santiago
+0	 46	Brazilian Space Agency - INPE
+0	 47	Reserved for other centers in Region III
+0	 48	Reserved for other centers in Region III
+0	 49	Reserved for other centers in Region III
+0	 50	Reserved for other centers in Region III
+
+# 51-63: Centers in Region IV
+
+0	 51	Miami (RSMC/RAFC)
+0	 52	Miami (RSMC), National Hurricane Center
+0	 53	Montreal (RSMC)
+0	 54	Montreal (RSMC)
+0	 55	San Francisco
+0	 56	RESERVED
+0	 57	US Air Force - Air Force Global Weather Central (AFGWC)
+1	 58	Fleet Numerical Oceanography Center (FNOC), Monterey, CA, USA
+0	 59	The NOAA Forecast Systems Laboratory, Boulder, CO, USA
+0	 60	Reserved for other centers in Region IV
+0	 61	Reserved for other centers in Region IV
+0	 62	Reserved for other centers in Region IV
+0	 63	Reserved for other centers in Region IV
+
+# 64-73: Centers in Region V
+
+0	 64	Honolulu (RAFC)
+0	 65	Darwin (RSMC/RAFC)
+0	 66	Darwin (RSMC/RAFC)
+0	 67	Melbourne (RSMC)
+0	 68	RESERVED
+0	 69	Wellington (RSMC/RAFC)
+0	 70	Wellington (RSMC/RAFC)
+0	 71	Reserved for other centers in Region V
+0	 72	Reserved for other centers in Region V
+0	 73	Reserved for other centers in Region V
+
+# 74-98: Centers in Region VI
+
+0	 74	UK Meteorological Office - Bracknell
+0	 75	UK Meteorological Office - Bracknell
+0	 76	Moscow (RSMC/RAFC)
+0	 77	RESERVED
+0	 78	Offenbach (RSMC)
+0	 79	Offenbach (RSMC)
+0	 80	Rome (RSMC/RAFC)
+0	 81	Rome (RSMC/RAFC)
+0	 82	Norrkoping (RSMC)
+0	 83	Norrkoping (RSMC)
+0	 84	Paris (RAFC)
+0	 85	Toulouse
+0	 86	Helsinki
+0	 87	Belgrade
+0	 88	Oslo
+0	 89	Prague
+0	 90	Episkopi
+0	 91	Ankara
+0	 92	Francfort/Main (RAFC)
+0	 93	London (WAFC)
+0	 94	Copenhagen
+0	 95	Rota
+0	 96	Athens
+0	 97	European Space Agency (ESA)
+
+# ECMWF (Center 98) does not support minor local table version numbers
+# so DO NOT set the first value to 1.
+
+0	 98	European Center for Medium Range Weather Forecasts (ECMWF)(RSMC)
+0	 99	De Bilt
+
+# 100-127: RESERVED
+
+0	100	RESERVED
+0	101	RESERVED
+0	102	RESERVED
+0	103	RESERVED
+0	104	RESERVED
+0	105	RESERVED
+0	106	RESERVED
+0	107	RESERVED
+0	108	RESERVED
+0	109	RESERVED
+0	110	RESERVED
+0	111	RESERVED
+0	112	RESERVED
+0	113	RESERVED
+0	114	RESERVED
+0	115	RESERVED
+0	116	RESERVED
+0	117	RESERVED
+0	118	RESERVED
+0	119	RESERVED
+0	120	RESERVED
+0	121	RESERVED
+0	122	RESERVED
+0	123	RESERVED
+0	124	RESERVED
+0	125	RESERVED
+0	126	RESERVED
+0	127	RESERVED
+
+# 128-254: NATIONAL USE
+
+1	128	Naval Research Laboratory (NRL), Monterey CA
+0	129	CAST
+0	130	AFCCC
+0	131	PL
+0	132	ARL
+0	133	WES
+0	134	NATIONAL USE
+0	135	NATIONAL USE
+0	136	NATIONAL USE
+0	137	NATIONAL USE
+0	138	NATIONAL USE
+0	139	NATIONAL USE
+0	140	NATIONAL USE
+0	141	NATIONAL USE
+0	142	NATIONAL USE
+0	143	NATIONAL USE
+0	144	NATIONAL USE
+0	145	NATIONAL USE
+0	146	NATIONAL USE
+0	147	NATIONAL USE
+0	148	NATIONAL USE
+0	149	NATIONAL USE
+0	150	NATIONAL USE
+0	151	NATIONAL USE
+0	152	NATIONAL USE
+0	153	NATIONAL USE
+0	154	NATIONAL USE
+0	155	NATIONAL USE
+0	156	NATIONAL USE
+0	157	NATIONAL USE
+0	158	NATIONAL USE
+0	159	NATIONAL USE
+0	160	NATIONAL USE
+0	161	NATIONAL USE
+0	162	NATIONAL USE
+0	163	NATIONAL USE
+0	164	NATIONAL USE
+0	165	NATIONAL USE
+0	166	NATIONAL USE
+0	167	NATIONAL USE
+0	168	NATIONAL USE
+0	169	NATIONAL USE
+0	170	NATIONAL USE
+0	171	NATIONAL USE
+0	172	NATIONAL USE
+0	173	NATIONAL USE
+0	174	NATIONAL USE
+0	175	NATIONAL USE
+0	176	NATIONAL USE
+0	177	NATIONAL USE
+0	178	NATIONAL USE
+0	179	NATIONAL USE
+0	180	NATIONAL USE
+0	181	NATIONAL USE
+0	182	NATIONAL USE
+0	183	NATIONAL USE
+0	184	NATIONAL USE
+0	185	NATIONAL USE
+0	186	NATIONAL USE
+0	187	NATIONAL USE
+0	188	NATIONAL USE
+0	189	NATIONAL USE
+0	190	NATIONAL USE
+0	191	NATIONAL USE
+0	192	NATIONAL USE
+0	193	NATIONAL USE
+0	194	NATIONAL USE
+0	195	NATIONAL USE
+0	196	NATIONAL USE
+0	197	NATIONAL USE
+0	198	NATIONAL USE
+0	199	NATIONAL USE
+0	200	NATIONAL USE
+0	201	NATIONAL USE
+0	202	NATIONAL USE
+0	203	NATIONAL USE
+0	204	NATIONAL USE
+0	205	NATIONAL USE
+0	206	NATIONAL USE
+0	207	NATIONAL USE
+0	208	NATIONAL USE
+0	209	NATIONAL USE
+0	210	NATIONAL USE
+0	211	NATIONAL USE
+0	212	NATIONAL USE
+0	213	NATIONAL USE
+0	214	NATIONAL USE
+0	215	NATIONAL USE
+0	216	NATIONAL USE
+0	217	NATIONAL USE
+0	218	NATIONAL USE
+0	219	NATIONAL USE
+0	220	NATIONAL USE
+0	221	NATIONAL USE
+0	222	NATIONAL USE
+0	223	NATIONAL USE
+0	224	NATIONAL USE
+0	225	NATIONAL USE
+0	226	NATIONAL USE
+0	227	NATIONAL USE
+0	228	NATIONAL USE
+0	229	NATIONAL USE
+0	230	NATIONAL USE
+0	231	NATIONAL USE
+0	232	NATIONAL USE
+0	233	NATIONAL USE
+0	234	NATIONAL USE
+0	235	NATIONAL USE
+0	236	NATIONAL USE
+0	237	NATIONAL USE
+0	238	NATIONAL USE
+0	239	NATIONAL USE
+0	240	NATIONAL USE
+0	241	NATIONAL USE
+0	242	NATIONAL USE
+0	243	NATIONAL USE
+0	244	NATIONAL USE
+0	245	NATIONAL USE
+0	246	NATIONAL USE
+0	247	NATIONAL USE
+0	248	NATIONAL USE
+0	249	NATIONAL USE
+0	250	NATIONAL USE
+0	251	NATIONAL USE
+0	252	NATIONAL USE
+0	253	NATIONAL USE
+0	254	NATIONAL USE
+
+# 255: Used to indicate missing or unknown center
+
+0	255	MISSING VALUE
diff --git a/data/tables/B3M-000-005-A b/data/tables/B3M-000-005-A
new file mode 100644
index 0000000..2a5d7db
--- /dev/null
+++ b/data/tables/B3M-000-005-A
@@ -0,0 +1,259 @@
+#
+# BUFR Table A - Data Category
+#
+  0	Surface data - land
+  1	Surface data - sea
+  2	Vertical soundings (other than satellite)
+  3	Vertical soundings (satellite)
+  4	Single level upper-air data (other than satellite)
+  5	Single level upper-air data (satellite)
+  6	Radar data
+  7	Synoptic features
+  8	Physical/chemical constituents
+  9	Dispersal and transport
+ 10	Radiological data
+ 11	BUFR tables, complete replacement or update
+ 12	Surface data (satellite)
+ 13	RESERVED
+ 14	RESERVED
+ 15	RESERVED
+ 16	RESERVED
+ 17	RESERVED
+ 18	RESERVED
+ 19	RESERVED
+ 20	Status information
+ 21	Radiances (satellite measured)
+ 22	RESERVED
+ 23	RESERVED
+ 24	RESERVED
+ 25	RESERVED
+ 26	RESERVED
+ 27	RESERVED
+ 28	RESERVED
+ 29	RESERVED
+ 30	RESERVED
+ 31	Oceanographic data
+ 32	RESERVED
+ 33	RESERVED
+ 34	RESERVED
+ 35	RESERVED
+ 36	RESERVED
+ 37	RESERVED
+ 38	RESERVED
+ 39	RESERVED
+ 40	RESERVED
+ 41	RESERVED
+ 42	RESERVED
+ 43	RESERVED
+ 44	RESERVED
+ 45	RESERVED
+ 46	RESERVED
+ 47	RESERVED
+ 48	RESERVED
+ 49	RESERVED
+ 50	RESERVED
+ 51	RESERVED
+ 52	RESERVED
+ 53	RESERVED
+ 54	RESERVED
+ 55	RESERVED
+ 56	RESERVED
+ 57	RESERVED
+ 58	RESERVED
+ 59	RESERVED
+ 60	RESERVED
+ 61	RESERVED
+ 62	RESERVED
+ 63	RESERVED
+ 64	RESERVED
+ 65	RESERVED
+ 66	RESERVED
+ 67	RESERVED
+ 68	RESERVED
+ 69	RESERVED
+ 70	RESERVED
+ 71	RESERVED
+ 72	RESERVED
+ 73	RESERVED
+ 74	RESERVED
+ 75	RESERVED
+ 76	RESERVED
+ 77	RESERVED
+ 78	RESERVED
+ 79	RESERVED
+ 80	RESERVED
+ 81	RESERVED
+ 82	RESERVED
+ 83	RESERVED
+ 84	RESERVED
+ 85	RESERVED
+ 86	RESERVED
+ 87	RESERVED
+ 88	RESERVED
+ 89	RESERVED
+ 90	RESERVED
+ 91	RESERVED
+ 92	RESERVED
+ 93	RESERVED
+ 94	RESERVED
+ 95	RESERVED
+ 96	RESERVED
+ 97	RESERVED
+ 98	RESERVED
+ 99	RESERVED
+100	RESERVED
+101	Image data
+102	RESERVED
+103	RESERVED
+104	RESERVED
+105	RESERVED
+106	RESERVED
+107	RESERVED
+108	RESERVED
+109	RESERVED
+110	RESERVED
+111	RESERVED
+112	RESERVED
+113	RESERVED
+114	RESERVED
+115	RESERVED
+116	RESERVED
+117	RESERVED
+118	RESERVED
+119	RESERVED
+120	RESERVED
+121	RESERVED
+122	RESERVED
+123	RESERVED
+124	RESERVED
+125	RESERVED
+126	RESERVED
+127	RESERVED
+128	RESERVED
+129	RESERVED
+130	RESERVED
+131	RESERVED
+132	RESERVED
+133	RESERVED
+134	RESERVED
+135	RESERVED
+136	RESERVED
+137	RESERVED
+138	RESERVED
+139	RESERVED
+140	RESERVED
+141	RESERVED
+142	RESERVED
+143	RESERVED
+144	RESERVED
+145	RESERVED
+146	RESERVED
+147	RESERVED
+148	RESERVED
+149	RESERVED
+150	RESERVED
+151	RESERVED
+152	RESERVED
+153	RESERVED
+154	RESERVED
+155	RESERVED
+156	RESERVED
+157	RESERVED
+158	RESERVED
+159	RESERVED
+160	RESERVED
+161	RESERVED
+162	RESERVED
+163	RESERVED
+164	RESERVED
+165	RESERVED
+166	RESERVED
+167	RESERVED
+168	RESERVED
+169	RESERVED
+170	RESERVED
+171	RESERVED
+172	RESERVED
+173	RESERVED
+174	RESERVED
+175	RESERVED
+176	RESERVED
+177	RESERVED
+178	RESERVED
+179	RESERVED
+180	RESERVED
+181	RESERVED
+182	RESERVED
+183	RESERVED
+184	RESERVED
+185	RESERVED
+186	RESERVED
+187	RESERVED
+188	RESERVED
+189	RESERVED
+190	RESERVED
+191	RESERVED
+192	RESERVED
+193	RESERVED
+194	RESERVED
+195	RESERVED
+196	RESERVED
+197	RESERVED
+198	RESERVED
+199	RESERVED
+200	RESERVED
+201	RESERVED
+202	RESERVED
+203	RESERVED
+204	RESERVED
+205	RESERVED
+206	RESERVED
+207	RESERVED
+208	RESERVED
+209	RESERVED
+210	RESERVED
+211	RESERVED
+212	RESERVED
+213	RESERVED
+214	RESERVED
+215	RESERVED
+216	RESERVED
+217	RESERVED
+218	RESERVED
+219	RESERVED
+220	RESERVED
+221	RESERVED
+222	RESERVED
+223	RESERVED
+224	RESERVED
+225	RESERVED
+226	RESERVED
+227	RESERVED
+228	RESERVED
+229	RESERVED
+230	RESERVED
+231	RESERVED
+232	RESERVED
+233	RESERVED
+234	RESERVED
+235	RESERVED
+236	RESERVED
+237	RESERVED
+238	RESERVED
+239	RESERVED
+240	FOR EXPERIMENTAL USE
+241	FOR EXPERIMENTAL USE
+242	FOR EXPERIMENTAL USE
+243	FOR EXPERIMENTAL USE
+244	FOR EXPERIMENTAL USE
+245	FOR EXPERIMENTAL USE
+246	FOR EXPERIMENTAL USE
+247	FOR EXPERIMENTAL USE
+248	FOR EXPERIMENTAL USE
+249	FOR EXPERIMENTAL USE
+250	FOR EXPERIMENTAL USE
+251	FOR EXPERIMENTAL USE
+252	FOR EXPERIMENTAL USE
+253	FOR EXPERIMENTAL USE
+254	FOR EXPERIMENTAL USE
+255	Indicator for local use, with sub-category
diff --git a/data/tables/B3M-000-005-B b/data/tables/B3M-000-005-B
new file mode 100644
index 0000000..5edb008
--- /dev/null
+++ b/data/tables/B3M-000-005-B
@@ -0,0 +1,635 @@
+#
+# BUFR Table B - Classification of Elements
+#
+#					Data
+#F	X	Y	Scale	RefVal	Width	Units	Element Name
+  0;    0;      1;      0;           0;   24;    CCITT_IA5; Table A: entry
+  0;    0;      2;      0;           0;  256;    CCITT_IA5; Table A: data category description, line 1
+  0;    0;      3;      0;           0;  256;    CCITT_IA5; Table A: data category description, line 2
+  0;    0;      5;      0;           0;   24;    CCITT_IA5; BUFR edition number
+  0;    0;     10;      0;           0;    8;    CCITT_IA5; F descriptor to be added or defined
+  0;    0;     11;      0;           0;   16;    CCITT_IA5; X descriptor to be added or defined
+  0;    0;     12;      0;           0;   24;    CCITT_IA5; Y descriptor to be added or defined
+  0;    0;     13;      0;           0;  256;    CCITT_IA5; Element name, line 1
+  0;    0;     14;      0;           0;  256;    CCITT_IA5; Element name, line 2
+  0;    0;     15;      0;           0;  192;    CCITT_IA5; Units name
+  0;    0;     16;      0;           0;    8;    CCITT_IA5; Units scale sign
+  0;    0;     17;      0;           0;   24;    CCITT_IA5; Units scale
+  0;    0;     18;      0;           0;    8;    CCITT_IA5; Units reference sign
+  0;    0;     19;      0;           0;   80;    CCITT_IA5; Units reference value
+  0;    0;     20;      0;           0;   24;    CCITT_IA5; Element data width
+  0;    0;     30;      0;           0;   48;    CCITT_IA5; Descriptor defining sequence
+
+  0;    1;      1;      0;           0;    7;      Numeric; WMO block number
+  0;    1;      2;      0;           0;   10;      Numeric; WMO station number
+  0;    1;      3;      0;           0;    3;      Numeric; WMO region number
+  0;    1;      4;      0;           0;    3;      Numeric; WMO region sub-area
+  0;    1;      5;      0;           0;   17;      Numeric; Buoy/platform identifier
+  0;    1;      6;      0;           0;   64;    CCITT_IA5; Aircraft identifier (flight number)
+  0;    1;      7;      0;           0;   10;   Code_Table; Satellite identifier
+  0;    1;      8;      0;           0;   64;    CCITT_IA5; Aircraft registration number (tail number)
+  0;    1;      9;      0;           0;   64;    CCITT_IA5; Type of commerical aircraft
+  0;    1;     10;      0;           0;   64;    CCITT_IA5; Stationary buoy platform identifier
+  0;    1;     11;      0;           0;   72;    CCITT_IA5; Ship or mobile land station identifier
+  0;    1;     12;      0;           0;    9;     deg_true; Direction of motion of moving observing platform
+  0;    1;     13;      0;           0;   10;          m/s; Speed of motion of moving observing platform
+  0;    1;     14;      2;           0;   10;          m/s; Platform drift speed (high precision)
+  0;    1;     15;      0;           0;  160;    CCITT_IA5; Station or site name
+  0;    1;     20;      0;           0;    4;      Numeric; WMO Region sub-area
+  0;    1;     21;      0;           0;   14;      Numeric; Synoptic feature identifier
+  0;    1;     22;      0;           0;  224;    CCITT_IA5; Name of feature
+  0;    1;     25;      0;           0;   24;    CCITT_IA5; Storm identifier
+  0;    1;     26;      0;           0;   64;    CCITT_IA5; WMO storm name
+  0;    1;     31;      0;           0;   16;   Code_Table; Identification of originating/generating center
+  0;    1;     32;      0;           0;    8;   Code_Table; Generating application
+  0;    1;     33;      0;           0;    8;   Code_Table; Identification of originating/generating center
+  0;    1;     34;      0;           0;    8;   Code_Table; Identification of originating/generating sub-center
+  0;    1;     41;      5; -1073741824;   31;          m/s; Absolute platform velocity - first component
+  0;    1;     42;      5; -1073741824;   31;          m/s; Absolute platform velocity - second component
+  0;    1;     43;      5; -1073741824;   31;          m/s; Absolute platform velocity - third component
+  0;    1;     60;      0;           0;   64;    CCITT_IA5; Aircraft reporting point (Beacon identifier)
+  0;    1;     63;      0;           0;   64;    CCITT_IA5; ICAO location indicator
+  0;    1;     64;      0;           0;   32;    CCITT_IA5; Runway designator
+  0;    1;     75;      0;           0;   40;    CCITT_IA5; Ride station identification
+
+  0;    2;      1;      0;           0;    2;   Code_Table; Type of station
+  0;    2;      2;      0;           0;    4;   Flag_Table; Type of instrumentation for wind measurement
+  0;    2;      3;      0;           0;    4;   Code_Table; Type of measuring instrumentation used
+  0;    2;      4;      0;           0;    4;   Code_Table; Type of instrumentation for evaporation measurement or type of crop for which evapotranspiration is reported
+  0;    2;      5;      2;           0;    7;          deg; Precision of temperature observed
+  0;    2;     11;      0;           0;    8;   Code_Table; Radiosonde type
+  0;    2;     12;      0;           0;    4;   Code_Table; Radiosonde computational method
+  0;    2;     13;      0;           0;    4;   Code_Table; Solar and infrared radiation correction
+  0;    2;     14;      0;           0;    7;   Code_Table; Tracking technique/status of system
+  0;    2;     15;      0;           0;    4;   Code_Table; Radiosonde completeness
+  0;    2;     21;      0;           0;    9;   Flag_Table; Satellite instrumentation data used in processing
+  0;    2;     22;      0;           0;    8;   Flag_Table; Satellite data processing technique used
+  0;    2;     23;      0;           0;    4;   Code_Table; Satellite derived wind computation method
+  0;    2;     24;      0;           0;    4;   Code_Table; Integrated mean humidity computational method
+  0;    2;     25;      0;           0;   25;   Flag_Table; Satellite channel(s) used in computation
+  0;    2;     26;      2;           0;   12;            m; Cross track resolution
+  0;    2;     27;      2;           0;   12;            m; Along track resolution
+  0;    2;     30;      0;           0;    3;   Code_Table; Method of current measurement
+  0;    2;     31;      0;           0;    5;   Code_Table; Duration and time of current measurement
+  0;    2;     32;      0;           0;    2;   Code_Table; Indicator for digitization
+  0;    2;     33;      0;           0;    3;   Code_Table; Method of salinity/depth measurement
+  0;    2;     34;      0;           0;    5;   Code_Table; Drogue type
+  0;    2;     35;      0;           0;    9;            m; Cable length
+  0;    2;     36;      0;           0;    2;   Code_Table; Buoy type
+  0;    2;     37;      0;           0;    3;   Code_Table; Method of tidal observation
+  0;    2;     38;      0;           0;    4;   Code_Table; Method of sea-surface temperature measurement
+  0;    2;     39;      0;           0;    3;   Code_Table; Method of wet-buld temperature measurement
+  0;    2;     40;      0;           0;    4;   Code_Table; Method of removing velocity and motion of platform from current
+  0;    2;     41;      0;           0;    6;   Code_Table; Method for estimating reports related to synoptic features
+  0;    2;     42;      0;           0;    6;   Code_Table; Method of report construction
+  0;    2;     43;      0;           0;    6;   Code_Table; Precision of latitude/longitude report
+  0;    2;     44;      0;           0;    4;   Code_Table; Inicator for method of calculating spectral wave data
+  0;    2;     45;      0;           0;    4;   Code_Table; Indicator for type of platform
+  0;    2;     46;      0;           0;    4;   Code_Table; Wave measurement instrumentation
+  0;    2;     48;      0;           0;    4;   Code_Table; Satellite sensor indicator
+  0;    2;     49;      0;           0;    8;   Flag_Table; Geostationary satellite data-processing technique used
+  0;    2;     50;      0;           0;   20;   Flag_Table; Geostationary sounder satellite channels used
+  0;    2;     51;      0;           0;    4;   Code_Table; Indicator ro specify observing method for extreme temperatures
+  0;    2;     52;      0;           0;    6;   Flag_Table; Geostationary imager satellite channels used
+  0;    2;     53;      0;           0;    4;   Code_Table; GOES-I/M  brightness temperature characteristics
+  0;    2;     54;      0;           0;    4;   Code_Table; GOES-I/M  soundings parameter characteristics
+  0;    2;     55;      0;           0;    4;   Code_Table; Geostationary soundings statistical parameters
+  0;    2;     56;      0;           0;    4;   Code_Table; Geostationary soundings accuracy statistics
+  0;    2;     57;      0;           0;    4;   Code_Table; Origin of first guess information for GOES-I/M soundings
+  0;    2;     58;      0;           0;    4;   Code_Table; Valid times of first guess information for GOES-I/M soundings
+  0;    2;     59;      0;           0;    4;   Code_Table; Origin of analysis information for GOES-I/M soundings
+  0;    2;     60;      0;           0;    4;   Code_Table; Origin of surface information for GOES-I/M soundings
+  0;    2;     61;      0;           0;    3;   Code_Table; Aircraft navigation system
+  0;    2;     62;      0;           0;    4;   Code_Table; Type of aircraft data relay system
+  0;    2;     63;      2;      -18000;   16;          deg; Aircraft roll angle
+  0;    2;     64;      0;           0;    2;   Code_Table; Aircraft roll angle quality
+  0;    2;     65;      0;           0;   40;    CCITT_IA5; ACARS ground receiving station
+  0;    2;     70;      0;           0;    4;   Code_Table; Original specification of latitude/longitude
+  0;    2;    100;      1;           0;   12;           dB; Radar constant
+  0;    2;    101;      0;           0;    4;   Code_Table; Type of antenna
+  0;    2;    102;      0;           0;    8;            m; Antenna height above tower
+  0;    2;    103;      0;           0;    2;   Flag_Table; Radome
+  0;    2;    104;      0;           0;    4;   Code_Table; Antenna polarisation
+  0;    2;    105;      0;           0;    6;           dB; Maximum antenna gain
+  0;    2;    106;      1;           0;    6;          deg; 3-dB bandwidth
+  0;    2;    107;      0;           0;    6;           dB; Sidelobe suppression
+  0;    2;    108;      0;           0;    6;           dB; Crosspol discrimination (on axis)
+  0;    2;    109;      2;           0;   12;        deg/s; Antenna speed (azimuth)
+  0;    2;    110;      2;           0;   12;        deg/s; Antenna speed (elevation)
+  0;    2;    111;      1;           0;   10;          deg; Radar incidence angle
+  0;    2;    112;      1;           0;   12;          deg; Radar azimuth angle
+  0;    2;    113;      0;           0;    4;      Numeric; Number of azimuth looks
+  0;    2;    114;      0;           0;   15;         m**2; Antenna effective surface area
+  0;    2;    121;     -8;           0;    7;           Hz; Mean frequency
+  0;    2;    122;     -6;        -128;    8;           Hz; Frequency agility range
+  0;    2;    123;     -4;           0;    7;            W; Peak power
+  0;    2;    124;     -1;           0;    7;            W; Average power
+  0;    2;    125;     -1;           0;    8;           Hz; Pulse repetition frequency
+  0;    2;    126;      7;           0;    6;            s; Pulse width
+  0;    2;    127;     -6;           0;    7;           Hz; Receiver intermediate frequency
+  0;    2;    128;     -5;           0;    6;           Hz; Intermediate frequency bandwidth
+  0;    2;    129;      0;        -150;    5;           dB; Minimum detectable signal
+  0;    2;    130;      0;           0;    7;           dB; Dynamic range
+  0;    2;    131;      0;           0;    2;   Flag_Table; Sensitivity time control
+  0;    2;    132;      2;           0;    6;          deg; Azimuth pointing accuracy
+  0;    2;    133;      2;           0;    6;          deg; Elevation pointing accuracy
+  0;    2;    134;      2;           0;   16;          deg; Antenna beam azimuth
+  0;    2;    135;      2;       -9000;   15;          deg; Antenna elevation
+  0;    2;    136;     -3;           0;   16;            m; Range processed by range attenuation correction
+  0;    2;    140;      2;           0;    9;          deg; Satellite radar beam azimuth
+  0;    2;    141;      0;           0;   24;    CCITT_IA5; Measurement type
+  0;    2;    142;      0;           0;   32;    CCITT_IA5; Ozone instrument serial number/identification
+  0;    2;    143;      0;           0;    7;   Code_Table; Ozone instrument type
+  0;    2;    144;      0;           0;    4;   Code_Table; Light source type for Brewer spectrophotometer
+  0;    2;    145;      0;           0;    4;   Code_Table; Wave length setting for Dobson instruments
+  0;    2;    146;      0;           0;    4;   Code_Table; Source conditions for Dobson instruments
+
+  0;    4;      1;      0;           0;   12;         Year; Year
+  0;    4;      2;      0;           0;    4;           mo; Month
+  0;    4;      3;      0;           0;    6;          Day; Day
+  0;    4;      4;      0;           0;    5;           hr; Hour
+  0;    4;      5;      0;           0;    6;          min; Minute
+  0;    4;      6;      0;           0;    6;            s; Second
+  0;    4;     11;      0;       -1024;   11;         Year; Time increment
+  0;    4;     12;      0;       -1024;   11;           mo; Time increment
+  0;    4;     13;      0;       -1024;   11;         Days; Time increment
+  0;    4;     14;      0;       -1024;   11;           hr; Time increment
+  0;    4;     15;      0;       -2048;   12;          min; Time increment
+  0;    4;     16;      0;       -4096;   13;            s; Time increment
+  0;    4;     21;      0;       -1024;   11;         Year; Time period or displacement
+  0;    4;     22;      0;       -1024;   11;           mo; Time period or displacement
+  0;    4;     23;      0;       -1024;   11;         Days; Time period or displacement
+  0;    4;     24;      0;       -2048;   12;           hr; Time period or displacement
+  0;    4;     25;      0;       -2048;   12;          min; Time period or displacement
+  0;    4;     26;      0;       -4096;   13;            s; Time period or displacement
+  0;    4;     31;      0;           0;    8;           hr; Duration of time relative to followinG value
+  0;    4;     32;      0;           0;    6;       Minute; Duration of time relating to following value
+  0;    4;     41;      0;       -1440;   12;       Minute; Time Difference, UTC-LMT
+  0;    4;     43;      0;           0;    9;          Day; Day of the year
+  0;    4;     53;      0;           0;    6;      Numeric; Number of days with precipition equal to or more than 1mm
+  0;    4;    192;      0;           0;    3;   Code_Table; Season
+
+  0;    5;      1;      5;    -9000000;   25;          deg; Latitude (high accuracy)
+  0;    5;      2;      2;       -9000;   15;          deg; Latitude (coarse accuracy)
+  0;    5;     11;      5;    -9000000;   25;          deg; Latitude increment (high accuracy)
+  0;    5;     12;      2;       -9000;   15;          deg; Latitude increment (coarse accuracy)
+  0;    5;     21;      2;           0;   16;     deg_true; Bearing or azimuth
+  0;    5;     22;      2;           0;   16;     deg_true; Solar azimuth
+  0;    5;     30;      0;           0;   12;          deg; Direction (spectral)
+  0;    5;     31;      0;           0;   12;      Numeric; Row number
+  0;    5;     33;     -1;           0;   16;            m; Pixel size on horizontal - 1
+  0;    5;     40;      0;           0;   24;      Numeric; Orbit number
+  0;    5;     41;      0;           0;    8;      Numeric; Scan line number
+  0;    5;     42;      0;           0;    6;      Numeric; Channel number
+  0;    5;     43;      0;           0;    8;      Numeric; Field of view number
+  0;    5;     52;      0;           0;    5;      Numeric; Channel number increment
+  0;    5;     53;      0;           0;    5;      Numeric; Field of view number increment
+
+  0;    6;      1;      5;   -18000000;   26;          deg; Longitude (high accuracy)
+  0;    6;      2;      2;      -18000;   16;          deg; Longitude (coarse accuracy)
+  0;    6;     11;      5;   -18000000;   26;          deg; Longitude increment (high accuracy)
+  0;    6;     12;      2;      -18000;   16;          deg; Longitude increment (coarse accuracy)
+  0;    6;     21;     -1;           0;   13;            m; Distance
+  0;    6;     30;      5;           0;   13;        rad/m; Wavenumber (spectral)
+  0;    6;     31;      0;           0;   12;      Numeric; Column number
+  0;    6;     33;     -1;           0;   16;            m; Pixel size on horizontal - 2
+
+  0;    7;      1;      0;        -400;   15;            m; Height of station
+  0;    7;      2;     -1;         -40;   16;            m; Height or altitude
+  0;    7;      3;     -1;        -400;   17;    m**2/s**2; Geopotential
+  0;    7;      4;     -1;           0;   14;           Pa; Pressure
+  0;    7;      5;      0;        -400;   12;            m; Height increment
+  0;    7;      6;      0;           0;   15;            m; Height above station
+  0;    7;      7;      0;       -1000;   17;            m; Height
+  0;    7;      8;      0;      -10000;   20;    m**2/s**2; Geopotential
+  0;    7;     21;      2;       -9000;   15;          deg; Elevation
+  0;    7;     22;      2;       -9000;   15;          deg; Solar elevation
+  0;    7;     24;      2;       -9000;   15;          deg; Satellite zenith angle
+  0;    7;     61;      2;           0;   14;            m; Depth below land surface
+  0;    7;     62;      1;           0;   17;            m; Depth below sea/water surface
+  0;    7;    190;      0;           0;   12;            m; Height increment
+
+  0;    8;      1;      0;           0;    7;   Flag_Table; Vertical sounding significance
+  0;    8;      2;      0;           0;    6;   Code_Table; Vertical significance (surface observations)
+  0;    8;      3;      0;           0;    6;   Code_Table; Vertical significance (satellite observations)
+  0;    8;      4;      0;           0;    3;   Code_Table; Phase of aircraft flight
+  0;    8;      5;      0;           0;    4;   Code_Table; Meteorological attribute significance
+  0;    8;      7;      0;           0;    4;   Code_Table; Dimensional significance
+  0;    8;     11;      0;           0;    6;   Code_Table; Meteorological feature
+  0;    8;     12;      0;           0;    2;   Code_Table; land/sea qualifier
+  0;    8;     13;      0;           0;    2;   Code_Table; Day/night qualifier
+  0;    8;     14;      0;           0;    4;   Code_Table; Qualification for runway visual range
+  0;    8;     16;      0;           0;    3;   Code_Table; Change indicator of a trend-type forecast or an aerodrome forecast
+  0;    8;     17;      0;           0;    2;   Code_Table; Qualifier of the time when the forecast change is expected
+  0;    8;     20;      0;           0;   16;      Numeric; Total number of missing entities (with respect to accumulation or average)
+  0;    8;     21;      0;           0;    5;   Code_Table; Time significance
+  0;    8;     22;      0;           0;   16;      Numeric; Total number (with respect to accumulation or average)
+  0;    8;     23;      0;           0;    6;   Code_Table; First order statistics
+  0;    8;     24;      0;           0;    6;   Code_Table; Difference statistics
+  0;    8;     25;      0;           0;    4;   Code_Table; Time difference qualifier
+  0;    8;     30;      0;           0;   13;      Numeric; Manual on Codes
+  0;    8;     51;      0;           0;    3;   Code_Table; Qualifier for number of missing values in calculation of statistic
+  0;    8;     52;      0;           0;    5;   Code_Table; Condition for which number of days of occurance follows
+  0;    8;     53;      0;           0;    2;   Code_Table; Day of occurance qualifier
+  0;    8;     60;      0;           0;    4;   Code_Table; Sample scanning mode significance
+
+  0;   10;      1;      0;        -400;   15;            m; Height of land surface
+  0;   10;      2;     -1;         -40;   16;            m; Height
+  0;   10;      3;     -1;        -400;   17;    m**2/s**2; Geopotential
+  0;   10;      4;     -1;           0;   14;           Pa; Pressure
+  0;   10;      7;      0;       -1000;   17;            m; Height
+  0;   10;      8;      0;      -10000;   20;    m**2/s**2; Geopotential
+  0;   10;     31;      2; -1073741824;   31;            m; In direction of the North Pole, distance from the Earth's centre
+  0;   10;     50;      2;           0;   16;            m; Standard deviation altitude
+  0;   10;     51;     -1;           0;   14;           Pa; Pressure reduced to mean sea level
+  0;   10;     52;     -1;           0;   14;           Pa; Altimeter setting (QNH)
+  0;   10;     60;     -1;       -1024;   11;           Pa; Pressure change
+  0;   10;     61;     -1;        -500;   10;           Pa; 3 hour pressure change
+  0;   10;     62;     -1;       -1000;   11;           Pa; 24 hour pressure change
+  0;   10;     63;      0;           0;    4;   Code_Table; Characteristic of pressure tendency
+  0;   10;     70;      0;        -400;   16;            m; Indicated aircraft altitude
+
+  0;   11;      1;      0;           0;    9;     deg_true; Wind direction
+  0;   11;      2;      1;           0;   12;          m/s; Wind speed
+  0;   11;      3;      1;       -4096;   13;          m/s; U-component
+  0;   11;      4;      1;       -4096;   13;          m/s; V-component
+  0;   11;      5;      1;        -512;   10;         Pa/s; W-component
+  0;   11;      6;      2;       -4096;   13;          m/s; W-component
+  0;   11;     11;      0;           0;    9;     deg_true; Wind direction at 10 m
+  0;   11;     12;      1;           0;   12;          m/s; Wind speed at 10 m
+  0;   11;     13;      0;           0;    9;     deg_true; Wind direction at 5 m
+  0;   11;     14;      1;           0;   12;          m/s; Wind speed at 5 m
+  0;   11;     16;      0;           0;    9;     deg_true; Extreme counterclockwise wind direction of a variable wind
+  0;   11;     17;      0;           0;    9;     deg_true; Extreme clockwise wind direction of a variable wind
+  0;   11;     21;      9;      -65536;   17;        s**-1; Relative vorticity
+  0;   11;     22;      9;      -65536;   17;        s**-1; Divergence
+  0;   11;     23;     -2;      -65536;   17;       m**2/s; Velocity potential
+  0;   11;     31;      0;           0;    4;   Code_Table; Degree of turbulence
+  0;   11;     32;     -1;         -40;   16;            m; Height of base of turbulence
+  0;   11;     33;     -1;         -40;   16;            m; Height of top of turbulence
+  0;   11;     34;      1;       -1024;   11;          m/s; Vertical gust velocity
+  0;   11;     35;      2;       -8192;   14;       m/s**2; Vertical gust acceleration
+  0;   11;     36;      1;           0;   10;          m/s; Maximum derived equivalent vertical gust speed
+  0;   11;     41;      1;           0;   12;          m/s; Maximum wind speed (gusts)
+  0;   11;     42;      1;           0;   12;          m/s; Maximum wind speed (10 minute mean wind)
+  0;   11;     43;      0;           0;    9;     deg_true; Maximum wind gust direction
+  0;   11;     44;      0;           0;    9;     deg_true; Mean wind direction for surface - 1500m
+  0;   11;     45;      1;           0;   12;          m/s; Mean wind speed for surface - 1500m
+  0;   11;     49;      0;           0;    9;     deg_true; Standard deviation of wind direction
+  0;   11;     50;      1;           0;   12;          m/s; Standard deviation horizontal wind speed
+  0;   11;     51;      1;           0;    8;          m/s; Standard deviation vertical wind speed
+  0;   11;     61;      1;           0;   12;          m/s; Absolute wind shear in 1 kilometer layer below
+  0;   11;     62;      1;           0;   12;          m/s; Absolute wind shear in1 kilometer layer above
+  0;   11;     70;      0;           0;   32; CCITT_IA5Designator; of the runway affected by wind shear
+  0;   11;     71;      3;        -128;   14;   m**2/s**-2; Turbulent vertical momemtum flux
+  0;   11;     72;      3;        -128;   11;            K; m/s**-2	Turbulent vertical buouancy flux
+  0;   11;     73;      2;       -1024;   13;   m**2/s**-2; Turbulent kinetic energy
+  0;   11;     74;      2;       -1024;   10;   m**2/s**-2; Dissipation energy
+  0;   11;     75;      2;           0;    8; m**(2/3)/s**-1; Mean turbulence intensity
+  0;   11;     76;      2;           0;    8; m**(2/3)/s**-1; Peak turbulence intensity
+
+  0;   12;      1;      1;           0;   12;        deg_K; Temperature/dry bulb temperature
+  0;   12;      2;      1;           0;   12;        deg_K; Wet bulb temperature
+  0;   12;      3;      1;           0;   12;        deg_K; Dewpoint temperature
+  0;   12;      4;      1;           0;   12;        deg_K; Dry bulb temperature at 2 meters
+  0;   12;      5;      1;           0;   12;        deg_K; Wet bulb temperature at 2 meters
+  0;   12;      6;      1;           0;   12;        deg_K; Dewpoint temperature at 2 meters
+  0;   12;      7;      1;           0;   12;        deg_K; Virtual temperature
+  0;   12;     11;      1;           0;   12;        deg_K; Maximum temperature
+  0;   12;     12;      1;           0;   12;        deg_K; Minimum temperature
+  0;   12;     13;      1;           0;   12;        deg_K; Ground minimum temperature past 12 hours
+  0;   12;     14;      1;           0;   12;        deg_K; Maximum temperature at 2 meters, past 12 hours
+  0;   12;     15;      1;           0;   12;        deg_K; Minimum temperature at 2 meters, past 12 hours
+  0;   12;     16;      1;           0;   12;        deg_K; Maximum temperature at 2 meters, past 24 hours
+  0;   12;     17;      1;           0;   12;        deg_K; Minimum temperature at 2 meters, past 24 hours
+  0;   12;     30;      1;           0;   12;        deg_K; Soil temperature
+  0;   12;     51;      1;           0;   10;        deg_K; Standard deviation of temperature
+  0;   12;     52;      1;           0;   12;        deg_K; Highest daily mean temperature
+  0;   12;     53;      1;           0;   12;        deg_K; Lowest daily mean temperature
+  0;   12;     61;      1;           0;   12;        deg_K; Skin temperature
+  0;   12;     62;      1;           0;   12;        deg_K; Equivalent black body temperature
+  0;   12;     63;      1;           0;   12;        deg_K; Brightness temperature
+
+  0;   13;      1;      5;           0;   14;        kg/kg; Specific humidity
+  0;   13;      2;      5;           0;   14;        kg/kg; Mixing ratio
+  0;   13;      3;      0;           0;    7;      percent; Relative humidity
+  0;   13;      4;     -1;           0;   10;           Pa; Vapor pressure
+  0;   13;      5;      3;           0;    7;      kg/m**3; Vapor density
+  0;   13;      6;     -1;         -40;   16;            m; Mixing heights
+  0;   13;     11;      4;          -1;   14;      kg/m**2; Total precipitation/total water equivalent
+  0;   13;     12;      2;          -2;   12;            m; Depth of fresh snow
+  0;   13;     13;      2;          -2;   16;            m; Total snow depth
+  0;   13;     14;      4;           0;   12;    kg/m**2/s; Rainfall/water equivalent of snow (average rate)
+  0;   13;     15;      7;           0;   12;          m/s; Snowfall (averaged rate)
+  0;   13;     16;      0;           0;    7;      kg/m**2; Precipitable water
+  0;   13;     19;      1;          -1;   14;      kg/m**2; Total precipitation past 1 hour
+  0;   13;     20;      1;          -1;   14;      kg/m**2; Total precipitation past 3 hours
+  0;   13;     21;      1;          -1;   14;      kg/m**2; Total precipitation past 6 hours
+  0;   13;     22;      1;          -1;   14;      kg/m**2; Total precipitation past 12 hours
+  0;   13;     23;      1;          -1;   14;      kg/m**2; Total precipitation past 24 hours
+  0;   13;     31;      0;           0;    7;      kg/m**2; Evapotranspiration
+  0;   13;     32;      1;           0;    8;      kg/m**2; Evaporation/evapotranspiration
+  0;   13;     33;      1;           0;   10;      kg/m**2; Evaporation/evapotranspiration
+  0;   13;     38;      0;           0;    2;   Code_Table; Superadiabatic indicator
+  0;   13;     39;      0;           0;    3;   Code_Table; Terrain type (ice/snow)
+  0;   13;     41;      0;           0;    4;   Code_Table; Pasquill-Gifford stability category
+  0;   13;     42;      0;         -20;    6;        deg_K; Parcel lifted index (to 500 hPa)
+  0;   13;     43;      0;         -20;    6;        deg_K; Best lifted index (to 500 hPa)
+  0;   13;     51;      0;           0;    4;   Code_Table; Frequency group, precipition
+  0;   13;     52;      1;          -1;   14;      kg/m**2; Highest daily amount of precipition
+
+  0;   14;      1;     -3;       -2048;   12;  Joules/m**2; Longwave radiation, integrated over 24 hours
+  0;   14;      2;     -3;       -2048;   12;  Joules/m**2; Longwave radiation, integrated over period specified
+  0;   14;      3;     -3;       -2048;   12;  Joules/m**2; Shortwave radiation, integrated over 24 hours
+  0;   14;      4;     -3;       -2048;   12;  Joules/m**2; Shortwave radiation, integrated over period specified
+  0;   14;     11;     -3;       -2048;   12;  Joules/m**2; Net longwave radiation, integrated over 24 hours
+  0;   14;     12;     -3;       -2048;   12;  Joules/m**2; Net longwave radiation, integrated over period specified
+  0;   14;     13;     -3;       -2048;   12;  Joules/m**2; Net shortwave radiation, integrated over 24 hours
+  0;   14;     14;     -3;       -2048;   12;  Joules/m**2; Net shortwave radiation, integrated over period specified
+  0;   14;     15;     -4;      -16384;   15;  Joules/m**2; Net radiation, integrated over 24 hours
+  0;   14;     16;     -4;      -16384;   15;  Joules/m**2; Net radiation, integrated over period specified
+  0;   14;     17;     -3;       -2048;   12;       W/m**2; Instantaneous long wave radiation
+  0;   14;     18;     -3;       -2048;   12;       W/m**2; Instantaneous short wave radiation
+  0;   14;     19;      0;           0;    7;      percent; Surface albedo
+  0;   14;     20;     -4;           0;   15;  Joules/m**2; Global solar radiation, integrated over 24 hours
+  0;   14;     21;     -4;           0;   15;  Joules/m**2; Global radiation, integrated over period specified
+  0;   14;     22;     -4;           0;   15;  Joules/m**2; Diffuse solar radiation, integrated over 24 hours
+  0;   14;     23;     -4;           0;   15;  Joules/m**2; Diffuse solar radiation, integratedi over period specified
+  0;   14;     24;     -4;           0;   15;  Joules/m**2; Direct solar radiation, integrated over 24 hours
+  0;   14;     25;     -4;           0;   15;  Joules/m**2; Direct solar radiation, integrated over period specified
+  0;   14;     26;      0;           0;    7;      percent; Albedo at the top of clouds
+  0;   14;     31;      0;           0;   11;          min; Total sunshine
+  0;   14;     32;      0;           0;   10;           hr; Total sunshine
+  0;   14;     33;      0;           0;    9;      percent; Total sunshine
+  0;   14;     42;      0;           0;    7;      percent; Bi-directional reflectance
+
+  0;   15;      1;      0;           0;   10;       Dobson; units	Ozone
+  0;   15;      2;      2;           0;   10;      Numeric; Air mass (slant path at 22km)
+  0;   15;     11;      3;       14000;   13;  log(1/m**2); Log 10 of integrated electron density
+  0;   15;     15;      0;           0;   31;      Numeric; Maximum image spectral composition before normalization
+
+  0;   19;      1;      0;           0;    6;   Code_Table; Type of synoptic features
+  0;   19;      2;     -2;           0;   12;            m; Effective radius of feature
+  0;   19;      3;      0;           0;    8;          m/s; Wind speed threshold
+  0;   19;      4;     -2;           0;   12;            m; Effective radius of feature with respect to wind speeds above threshold
+  0;   19;      5;      0;           0;    9;     deg_true; Direction of motion of features
+  0;   19;      6;      2;           0;   14;          m/s; Speed of motion of features
+  0;   19;      7;     -3;           0;   12;            m; Effective radius of features
+  0;   19;      8;      0;           0;    3;   Code_Table; Vertical extent of circulation
+  0;   19;      9;     -3;           0;   12;            m; Effective radius with respect to wind speed above threshold (large storms)
+
+  0;   20;      1;     -1;           0;   13;            m; Horizontal visibility
+  0;   20;      2;     -1;           0;    7;            m; Vertical visibility
+  0;   20;      3;      0;           0;    9;   Code_Table; Present weather
+  0;   20;      4;      0;           0;    5;   Code_Table; Past weather (1)
+  0;   20;      5;      0;           0;    5;   Code_Table; Past weather (2)
+  0;   20;      9;      0;           0;    4;   Code_Table; General Weather Indicator
+  0;   20;     10;      0;           0;    7;      percent; Cloud cover (total)
+  0;   20;     11;      0;           0;    4;   Code_Table; Cloud amount
+  0;   20;     12;      0;           0;    6;   Code_Table; Cloud type
+  0;   20;     13;     -1;         -40;   11;            m; Height of base of cloud
+  0;   20;     14;     -1;         -40;   11;            m; Height of top of cloud
+  0;   20;     15;     -1;           0;   14;           Pa; Pressure at the base of cloud
+  0;   20;     16;     -1;           0;   14;           Pa; Pressure at the top of cloud
+  0;   20;     17;      0;           0;    4;   Code_Table; Cloud top description
+  0;   20;     18;      0;           0;    2;   Code_Table; Tendency of runway visual range
+  0;   20;     19;      0;           0;   72;    CCITT_IA5; Significant present or forecast weather
+  0;   20;     20;      0;           0;   32;    CCITT_IA5; Significant recent weather phenomena
+  0;   20;     31;      2;           0;    7;            m; Ice deposit (thickness)
+  0;   20;     32;      0;           0;    3;   Code_Table; Rate of ice accretion
+  0;   20;     33;      0;           0;    4;   Flag_Table; Cause of ice accretion
+  0;   20;     34;      0;           0;    5;   Code_Table; Sea ice concentration
+  0;   20;     35;      0;           0;    4;   Code_Table; Amount and type of ice
+  0;   20;     36;      0;           0;    5;   Code_Table; Ice situation
+  0;   20;     37;      0;           0;    5;   Code_Table; Ice development
+  0;   20;     38;      0;           0;   12;     deg_true; Bearing of ice edge
+  0;   20;     39;     -1;           0;   13;            m; Ice distance
+  0;   20;     41;      0;           0;    4;   Code_Table; Airframe icing
+  0;   20;     51;      0;           0;    7;      percent; Amount of low clouds
+  0;   20;     52;      0;           0;    7;      percent; Amount of middle clouds
+  0;   20;     53;      0;           0;    7;      percent; Amount of high clouds
+  0;   20;     61;      0;           0;   12;            m; Runway visual range (RVR)
+  0;   20;     62;      0;           0;    5;   Code_Table; State of the ground(with or without snow)
+  0;   20;     63;      0;           0;   10;   Code_Table; Special phenomena
+  0;   20;     90;      0;           0;    4;   Code_Table; Special clouds
+  0;   21;      1;      0;         -64;    7;           dB; Horizontal reflectivity
+  0;   21;      2;      0;         -64;    7;           dB; Vertical reflectivity
+  0;   21;      3;      1;          -5;    7;           dB; Differential reflectivity
+  0;   21;      5;      0;         -65;    6;           dB; Linear depolarization ratio
+  0;   21;      6;      0;         -65;    6;           dB; Circular depolarization ratio
+  0;   21;     11;      0;        -128;    8;          m/s; Doppler mean velocity in X direction
+  0;   21;     12;      0;        -128;    8;          m/s; Doppler mean velocity in Y direction
+  0;   21;     13;      0;        -128;    8;          m/s; Doppler mean velocity in Z direction
+  0;   21;     14;      1;       -4096;   13;          m/s; Doppler mean velocity (radiational)
+  0;   21;     17;      1;           0;    8;          m/s; Doppler velocity spectral width
+  0;   21;     21;     -3;           0;    4;            m; Echo tops
+  0;   21;     30;      0;         -32;    8;           dB; Signal to noise ratio
+  0;   21;     31;      0;           0;    7;      kg/m**2; Vertical integrated liquid water content
+  0;   21;     36;      7;           0;   12;          m/s; Radar rainfall intensity
+  0;   21;     41;     -2;           0;    8;            m; Bright band height
+  0;   21;     51;      0;        -256;    8;           dB; Signal power above 1 MW
+  0;   21;     62;      2;       -5000;   13;     Decibels; Backscatter
+  0;   21;     63;      1;           0;   10;      Percent; Radiometric resolution (noise value)
+  0;   21;     64;      0;           0;    8;      Numeric; Clutter noise estimate
+  0;   21;     65;      0;        -127;    8;      Numeric; Missing packet counter
+  0;   21;     66;      0;           0;   12;   Flag_Table; Wave scatterometer product confidence
+  0;   21;     67;      0;           0;   13;   Flag_Table; Wind product confidence data
+  0;   21;     68;      0;           0;    8;   Flag_Table; Radar altimeter product confidence data
+  0;   21;     69;      0;           0;   10;   Flag_Table; SST product confidence data
+  0;   21;     71;      0;           0;   16;      Numeric; Peakiness
+  0;   21;     72;      0;           0;    4;   Flag_Table; Satellite altimeter calibration status
+  0;   21;     73;      0;           0;    9;   Flag_Table; Satellite altimeter instrument mode
+  0;   21;     75;      0;           0;    8;      Numeric; Spectral intensity
+  0;   21;     76;      0;           0;    3;   Code_Table; Representation of intensities
+  0;   21;     77;      3;           0;   14;            m; Altitude correction (ionosphere)
+  0;   21;     78;      3;           0;    9;            m; Altitude correction (dry troposphere)
+  0;   21;     79;      3;        2000;   10;            m; Altitude correction (wet troposphere)
+  0;   21;     80;      3;           0;   11;            m; Altitude correction (calibration constant)
+  0;   21;     81;      3;           0;   10;            m; Open loop correction (height-time loop)
+  0;   21;     82;      3;       -3000;   14;     Decibels; Open loop correction (auto gain control)
+  0;   21;     85;      0;       -3000;    4;      Numeric; ATSR sea surface temperature across-track band number
+
+  0;   22;      1;      0;           0;    9;     deg_true; Direction of waves
+  0;   22;      2;      0;           0;    9;     deg_true; Direction of wind waves
+  0;   22;      3;      0;           0;    9;     deg_true; Direction of swell waves
+  0;   22;      4;      0;           0;    9;     deg_true; Direction of current waves
+  0;   22;     11;      0;           0;    6;            s; Period of waves
+  0;   22;     12;      0;           0;    6;            s; Period of wind waves
+  0;   22;     13;      0;           0;    6;            s; Period of swell waves
+  0;   22;     21;      1;           0;   10;            m; Height of waves
+  0;   22;     22;      1;           0;   10;            m; Height of wind waves
+  0;   22;     23;      1;           0;   10;            m; Height of swell waves
+  0;   22;     25;      2;           0;   10;            m; Standard deviation wave
+  0;   22;     26;      2;           0;   10;            m; Standard deviation of significant wave height
+  0;   22;     31;      2;           0;   13;          m/s; Speed of current
+  0;   22;     37;      3;      -10000;   15;            m; Tidal elevation with respect to national chart datum
+  0;   22;     38;      3;      -10000;   15;            m; Tidal elevation with respect to local chart datum
+  0;   22;     39;      3;       -5000;   12;            m; Meteorological residual tidal elevation (surge or offset)
+  0;   22;     40;      3;       -5000;   14;            m; Meteorological residual tidal elevation (surge or offset)
+  0;   22;     41;      1;           0;   12;        deg_K; Sea surface temperature (15 day running mean)
+  0;   22;     42;      1;           0;   12;        deg_K; Sea/water temperature
+  0;   22;     43;      2;           0;   15;        deg_K; Sea/water temperature
+  0;   22;     44;      1;           0;   14;          m/s; Sound velocity
+  0;   22;     50;      2;           0;    8;            K; Standard deviation sea surface temperature
+  0;   22;     61;      0;           0;    4;   Code_Table; State of sea
+  0;   22;     62;      2;           0;   14;          ppt; Salinity
+  0;   22;     63;      0;           0;   14;            m; Total water depth
+  0;   22;     67;      0;           0;   10;   Code_Table; Instrument type for water temperature profile measurement
+  0;   22;     68;      0;           0;    7;   Code_Table; Water temperature profile recorder types
+  0;   22;     70;      2;           0;   13;            m; Significant wave height
+  0;   22;     71;      1;           0;    9;            s; Spectral peak wave period
+  0;   22;     72;      0;           0;   13;            m; Spectral peak wave length
+  0;   22;     73;      2;           0;   13;            m; Maximum wave height
+  0;   22;     74;      1;           0;    9;            s; Average wave period
+  0;   22;     75;      0;           0;   13;            m; Average wave length
+  0;   22;     76;      0;           0;    9;  Degree_True; Direction from which dominant waves are coming
+  0;   22;     77;      0;           0;    9;       Degree; Directional spred of dominant wave
+  0;   22;     78;      0;           0;   12;            s; Duration of wave record
+  0;   22;     79;      0;           0;   16;            m; Length of wave record
+  0;   22;     80;      3;           0;   10;           Hz; Waveband central frequency
+  0;   22;     81;      5;           0;   13;        m**-1; Waveband central wave number
+  0;   22;     82;      2;           0;   20;       m**2/s; Maximum non-directional spectral wave density
+  0;   22;     83;      2;           0;   20;         m**3; Maximum non-directional spectral wave number
+  0;   22;     84;      0;           0;    7;      Numeric; Band containing maximum non-directional spectral wave density
+  0;   22;     85;      0;           0;    7;      Numeric; Spectral wave density ratio
+  0;   22;     86;      0;           0;    9;  Degree_True; Mean direction from which waves are coming
+  0;   22;     87;      0;           0;    9;  Degree_True; Principal direction from which waves are coming
+  0;   22;     88;      2;           0;    7;      Numeric; First normalized polar coordinate from Fourier coefficients
+  0;   22;     89;      2;           0;    7;      Numeric; Second normalized polar coordinate from Fourier coefficients
+  0;   22;     90;      2;           0;   20;       m**2/s; Non-directional spectral estimate by wave frequency
+  0;   22;     91;      2;           0;   20;         m**3; Non-directional spectral estimate by wave number
+  0;   22;     92;      2;           0;   20; m**2/rad**-1/s; Directional spectral estimate by wave frequency
+  0;   22;     93;      2;           0;   20;         m**4; Directional spectral estimate by wave number
+  0;   22;     94;      0;           0;    7;      Numeric; Total number of wave bands
+  0;   22;     95;      0;           0;    8;       Degree; Directional spread of individual waves
+  0;   22;     96;      3;           0;    4;        s**-1; Spectral band width
+  0;   22;     97;      0;           0;   14;            m; Mean wavelength > 731 m of image spectrum at low wave numbers
+  0;   22;     98;      0;           0;   14;            m; Wavelength spread (wavelength > 731 m) at low wave numbers
+  0;   22;     99;      0;           0;    9;     deg_true; Mean direction at low wave numbers (wavelength > 731 m)
+  0;   22;    100;      0;           0;    9;       Degree; Direction spread at low wave numbers (wavelength > 731 m)
+  0;   22;    101;      0;           0;   31;     Numberic; Total energy (wavelength > 731 m) at low wave numbers
+  0;   22;    120;      0;           0;    5;   Code_Table; Tide station automated water level check
+  0;   22;    121;      0;           0;    5;   Code_Table; Tide station manual water level check
+  0;   22;    122;      0;           0;    5;   Code_Table; Tide station automated Meteorological data check
+  0;   22;    123;      0;           0;    5;   Code_Table; Tide station manual Meteorological data check
+
+  0;   23;      1;      0;           0;    3;   Code_Table; Accident early notification - article applicable
+  0;   23;      2;      0;           0;    5;   Code_Table; Activity or facility involved in incident
+  0;   23;      3;      0;           0;    3;   Code_Table; Type of release
+  0;   23;      4;      0;           0;    3;   Code_Table; Countermeasures taken near border
+  0;   23;      5;      0;           0;    2;   Code_Table; Cause of incident
+  0;   23;      6;      0;           0;    3;   Code_Table; Incident situation
+  0;   23;      7;      0;           0;    3;   Code_Table; Characteristic of release
+  0;   23;      8;      0;           0;    2;   Code_Table; State of current release
+  0;   23;      9;      0;           0;    2;   Code_Table; State of expected release
+  0;   23;     16;      0;           0;    2;   Code_Table; Possibility of significant chemical toxic health effect
+  0;   23;     17;      6;           0;   20;       m**3/s; Flow discharge of major recipient
+  0;   23;     18;      0;           0;    3;   Code_Table; release behavior over time
+  0;   23;     19;      0;      -15000;   17;            m; Actual release height
+  0;   23;     21;      0;      -15000;   17;            m; Effective release height
+  0;   23;     22;      0;           0;   24;            m; Distance of relative point or site of incident
+  0;   23;     23;      1;           0;   12;          m/s; Main transport speed in atmosphere
+  0;   23;     24;      2;           0;   13;          m/s; Main transport speed in water
+  0;   23;     25;      2;           0;   13;          m/s; Main transport speed in ground water
+  0;   23;     27;      0;           0;    9;     deg_true; Main transport direction in atmosphere
+  0;   23;     28;      0;           0;    9;     deg_true; Main transport direction in water
+  0;   23;     29;      0;           0;    9;     deg_true; Main transport direction in ground water
+  0;   23;     31;      0;           0;    2;   Code_Table; Possibility that plume will encounter precipitation cwin state in which incident occurred
+  0;   23;     32;      0;           0;    2;   Code_Table; Plume will encounter ichange in wind direction and/or speed flag
+
+  0;   24;      1;     -1;           0;   28;           Bq; Estimate of radiatioactivity released up to specified time
+  0;   24;      2;     -1;           0;   28;           Bq; Estimated maximum potential release
+  0;   24;      3;      0;           0;    5;   Code_Table; Composition of release
+  0;   24;      4;      0;           0;   16;    CCITT_IA5; Element name
+  0;   24;      5;      0;           0;    9;      Numeric; Isotope mass
+  0;   24;     11;      2;           0;   32;          mSv; Dose
+  0;   24;     12;      2;           0;   32;          mSv; Trajectory dose (defined location and expected time of arrival)
+  0;   24;     13;      2;           0;   32;          mSv; Gamma dose in air along the main transport path (defined location and time period
+  0;   24;     21;      2;           0;   32;      Bq/m**3; Air concentration (named isotope type including gross beta)
+  0;   24;     22;      2;           0;   32;         Bq/l; Concentration in precipitation (of named isotope type)
+
+  0;   25;      1;     -1;           0;    6;            m; Range gate length
+  0;   25;      2;      0;           0;    4;      Numeric; Number of gates averaged
+  0;   25;      3;      0;           0;    8;      Numeric; Number of integrated pulses
+  0;   25;      4;      0;           0;    2;   Code_Table; Echo processing
+  0;   25;      5;      0;           0;    2;   Code_Table; Echo integration
+  0;   25;      6;      0;           0;    3;   Code_Table; Z to R conversion
+  0;   25;      7;      0;           0;   12;      Numeric; Z to R conversion factor
+  0;   25;      8;      2;           0;    9;      Numeric; Z to R conversion exponent
+  0;   25;      9;      0;           0;    4;   Flag_Table; Calibration method
+  0;   25;     10;      0;           0;    4;   Code_Table; Clutter treatment
+  0;   25;     11;      0;           0;    2;   Code_Table; Ground occultation correction (screening)
+  0;   25;     12;      0;           0;    2;   Code_Table; Range attenuation correction
+  0;   25;     13;      0;           0;    2;   Flag_Table; Bright band correction
+  0;   25;     14;      0;           0;   12;      Numeric; Azimuth clutter cut-off
+  0;   25;     15;      0;           0;    2;   Flag_Table; Radome attenuation correction
+  0;   25;     16;      5;           0;    6;         dB/m; Clear air attenuation correction
+  0;   25;     17;      0;           0;    2;   Flag_Table; Precipitation attenuation correction
+  0;   25;     18;      7;           0;    6;      Numeric; A to Z law for attenuation factor
+  0;   25;     19;      2;           0;    7;      Numeric; A to Z law for attenuation exponent
+  0;   25;     20;      0;           0;    2;   Code_Table; Mean speed estimation
+  0;   25;     21;      0;           0;    8;   Flag_Table; Wind computation enhancement
+  0;   25;     30;      0;           0;    2;   Code_Table; SST usage
+  0;   25;     32;      0;           0;    2;   Code_Table; NOAA wind profiler high/low mode data
+  0;   25;     33;      0;           0;    2;   Code_Table; NOAA wind profiler submode
+  0;   25;     34;      0;           0;    4;   Code_Table; NOAA wind profiler Q/C test results
+  0;   25;     40;      0;           0;    4;   Code_Table; CO2 wind product derivation
+  0;   25;     41;      0;           0;    2;   Code_Table; Moving platform direction reporting method
+  0;   25;     42;      0;           0;    2;   Code_Table; Moving platform speed reporting method
+  0;   25;     43;      4;           0;   15;            s; Wave sampling interval (time)
+  0;   25;     44;      2;           0;   14;            m; Wave sampling interval (space)
+  0;   25;     45;      0;           0;   21;   Flag_Table; HIRS channel combination
+  0;   25;     46;      0;           0;    5;   Flag_Table; MSU channel combination
+  0;   25;     47;      0;           0;    4;   Flag_Table; SSU channel combination
+  0;   25;     48;      0;           0;   16;   Flag_Table; AMSU-A channel combination
+  0;   25;     49;      0;           0;    6;   Flag_Table; AMSU-B channel combination
+  0;   25;     50;      0;           0;    7;   Flag_Table; AVHRR channel combination
+  0;   25;     51;      0;           0;   12;   Flag_Table; Observation quality
+  0;   25;     60;      0;           0;   14;      Numeric; Software identification
+
+  0;   26;      1;      1;           0;   12;         Hour; Principal time of daily reading in UTC of maximum temperature
+  0;   26;      2;      1;           0;   12;         Hour; Principal time of daily reading in UTC of minimum temperature
+  0;   26;      3;      0;       -1440;   12;       Minute; Time difference
+
+  0;   27;      1;      5;    -9000000;   25;          deg; Latitude (high accuracy)
+  0;   27;      2;      2;       -9000;   15;          deg; Latitude (coarse accuracy)
+  0;   27;      3;      2;       -9000;   15;          deg; Alternate latitude
+  0;   27;     20;      0;           0;   16;      Numeric; Satellite locationon counter
+  0;   27;     21;      0;           0;   16;      Numeric; Satellite sub-locationon dimensions
+  0;   27;     31;      2; -1073741824;   31;            m; In direction of 0 degrees longitude, distance from the Earth's centre
+
+  0;   28;      1;      5;   -18000000;   26;          deg; Longitude (high accuracy)
+  0;   28;      2;      2;      -18000;   16;          deg; Longitude (coarse accuracy)
+  0;   28;      3;      2;      -18000;   16;          deg; Alternate longtiude
+  0;   28;     31;      2; -1073741824;   31;            m; In direction of 90 degrees East, distance from the Earth's centre
+
+  0;   29;      1;      0;           0;    3;   Code_Table; Projection type
+  0;   29;      2;      0;           0;    2;   Code_Table; Coordinate grid type
+
+  0;   30;      1;      0;           0;    4;      Numeric; Pixel value (4 bits)
+  0;   30;      2;      0;           0;    8;      Numeric; Pixel value (8 bits)
+  0;   30;      4;      0;           0;   16;      Numeric; Pixel value (16 bits)
+  0;   30;     21;      0;           0;   12;      Numeric; Number of pixels per row
+  0;   30;     22;      0;           0;   12;      Numeric; Number of pixels per column
+  0;   30;     31;      0;           0;    4;   Code_Table; Picture type
+  0;   30;     32;      0;           0;   16;   Flag_Table; Combined picture
+
+  0;   31;      0;      0;           0;    1;      Numeric; Short delayed descriptor replication factor
+  0;   31;      1;      0;           0;    8;      Numeric; Delayed descriptor replication factor
+  0;   31;      2;      0;           0;   16;      Numeric; Extended delayed descriptor replication factor
+  0;   31;     11;      0;           0;    8;      Numeric; Delayed descriptor and data repetion factor
+  0;   31;     12;      0;           0;   16;      Numeric; Extended delayed descriptor and data repitition factor
+  0;   31;     21;      0;           0;    6;   Code_Table; Associated field significance
+  0;   31;     31;      0;           0;    1;   Flag_Table; Data present indicator
+
+  0;   33;      2;      0;           0;    2;   Code_Table; Quality information
+  0;   33;      3;      0;           0;    3;   Code_Table; Quality information
+  0;   33;      7;      0;           0;    7;      Percent; Per cent confidence
+  0;   33;     20;      0;           0;    3;   Code_Table; Quality control indication of following value
+  0;   33;     21;      0;           0;    2;   Code_Table; Quality of following value
+  0;   33;     22;      0;           0;    2;   Code_Table; Quality of buoy satellite transmission
+  0;   33;     23;      0;           0;    2;   Code_Table; Quality of buoy location
+  0;   33;     24;      0;           0;    4;   Code_Table; Station elevation quality mark (for mobile stations)
+  0;   33;     25;      0;           0;    3;   Code_Table; ACARS interpolated values
+  0;   33;     26;      0;           0;    6;   Code_Table; Mixing ratio quality
+  0;   33;     27;      0;           0;    3;   Code_Table; Location quality class
diff --git a/data/tables/B3M-000-005-B.new b/data/tables/B3M-000-005-B.new
new file mode 100644
index 0000000..dfd09c0
--- /dev/null
+++ b/data/tables/B3M-000-005-B.new
@@ -0,0 +1,609 @@
+#
+# BUFR Table B - Classification of Elements
+#
+#					Data
+#F	X	Y	Scale	RefVal	Width	Units	Element Name
+  0;  0;   1;    0;           0;   24;   CCITT_IA5; Table A: entry
+  0;  0;   2;    0;           0;  256;   CCITT_IA5; Table A: data category description, line 1
+  0;  0;   3;    0;           0;  256;   CCITT_IA5; Table A: data category description, line 2
+  0;  0;   5;    0;           0;   24;   CCITT_IA5; BUFR edition number
+  0;  0;  10;    0;           0;    8;   CCITT_IA5; F descriptor to be added or defined
+  0;  0;  11;    0;           0;   16;   CCITT_IA5; X descriptor to be added or defined
+  0;  0;  12;    0;           0;   24;   CCITT_IA5; Y descriptor to be added or defined
+  0;  0;  13;    0;           0;  256;   CCITT_IA5; Element name, line 1
+  0;  0;  14;    0;           0;  256;   CCITT_IA5; Element name, line 2
+  0;  0;  15;    0;           0;  192;   CCITT_IA5; Units name
+  0;  0;  16;    0;           0;    8;   CCITT_IA5; Units scale sign
+  0;  0;  17;    0;           0;   24;   CCITT_IA5; Units scale
+  0;  0;  18;    0;           0;    8;   CCITT_IA5; Units reference sign
+  0;  0;  19;    0;           0;   80;   CCITT_IA5; Units reference value
+  0;  0;  20;    0;           0;   24;   CCITT_IA5; Element data width
+  0;  0;  30;    0;           0;   48;   CCITT_IA5; Descriptor defining sequence
+  0;  1;   1;    0;           0;    7;     Numeric; WMO block number
+  0;  1;   2;    0;           0;   10;     Numeric; WMO station number
+  0;  1;   3;    0;           0;    3;     Numeric; WMO region number
+  0;  1;   4;    0;           0;    3;     Numeric; WMO region sub-area
+  0;  1;   5;    0;           0;   17;     Numeric; Buoy/platform identifier
+  0;  1;   6;    0;           0;   64;   CCITT_IA5; Aircraft identifier (flight number)
+  0;  1;   7;    0;           0;   10;  Code_Table; Satellite identifier
+  0;  1;   8;    0;           0;   64;   CCITT_IA5; Aircraft registration number (tail number)
+  0;  1;   9;    0;           0;   64;   CCITT_IA5; Type of commerical aircraft
+  0;  1;  10;    0;           0;   64;   CCITT_IA5; Stationary buoy platform identifier
+  0;  1;  11;    0;           0;   72;   CCITT_IA5; Ship or mobile land station identifier
+  0;  1;  12;    0;           0;    9;    deg_true; Direction of motion of moving observing platform
+  0;  1;  13;    0;           0;   10;         m/s; Speed of motion of moving observing platform
+  0;  1;  14;    2;           0;   10;         m/s; Platform drift speed (high precision)
+  0;  1;  15;    0;           0;  160;   CCITT_IA5; Station or site name
+  0;  1;  20;    0;           0;    4;     Numeric; WMO Region sub-area
+  0;  1;  21;    0;           0;   14;     Numeric; Synoptic feature identifier
+  0;  1;  22;    0;           0;  224;   CCITT_IA5; Name of feature
+  0;  1;  25;    0;           0;   24;   CCITT_IA5; Storm identifier
+  0;  1;  26;    0;           0;   64;   CCITT_IA5; WMO storm name
+  0;  1;  31;    0;           0;   16;  Code_Table; Identification of originating/generating center
+  0;  1;  32;    0;           0;    8;  Code_Table; Generating application
+  0;  1;  33;    0;           0;    8;  Code_Table; Identification of originating/generating center
+  0;  1;  34;    0;           0;    8;  Code_Table; Identification of originating/generating sub-center
+  0;  1;  41;    5; -1073741824;   31;         m/s; Absolute platform velocity - first component
+  0;  1;  42;    5; -1073741824;   31;         m/s; Absolute platform velocity - second component
+  0;  1;  43;    5; -1073741824;   31;         m/s; Absolute platform velocity - third component
+  0;  1;  60;    0;           0;   64;   CCITT_IA5; Aircraft reporting point (Beacon identifier)
+  0;  1;  63;    0;           0;   64;   CCITT_IA5; ICAO location indicator
+  0;  1;  64;    0;           0;   32;   CCITT_IA5; Runway designator
+  0;  1;  75;    0;           0;   40;   CCITT_IA5; Ride station identification
+  0;  2;   1;    0;           0;    2;  Code_Table; Type of station
+  0;  2;   2;    0;           0;    4;  Flag_Table; Type of instrumentation for wind measurement
+  0;  2;   3;    0;           0;    4;  Code_Table; Type of measuring instrumentation used
+  0;  2;   4;    0;           0;    4;  Code_Table; Type of instrumentation for evaporation measurement or type of crop for which evapotranspiration is reported
+  0;  2;   5;    2;           0;    7;         deg; Precision of temperature observed
+  0;  2;  11;    0;           0;    8;  Code_Table; Radiosonde type
+  0;  2;  12;    0;           0;    4;  Code_Table; Radiosonde computational method
+  0;  2;  13;    0;           0;    4;  Code_Table; Solar and infrared radiation correction
+  0;  2;  14;    0;           0;    7;  Code_Table; Tracking technique/status of system
+  0;  2;  15;    0;           0;    4;  Code_Table; Radiosonde completeness
+  0;  2;  21;    0;           0;    9;  Flag_Table; Satellite instrumentation data used in processing
+  0;  2;  22;    0;           0;    8;  Flag_Table; Satellite data processing technique used
+  0;  2;  23;    0;           0;    4;  Code_Table; Satellite derived wind computation method
+  0;  2;  24;    0;           0;    4;  Code_Table; Integrated mean humidity computational method
+  0;  2;  25;    0;           0;   25;  Flag_Table; Satellite channel(s) used in computation
+  0;  2;  26;    2;           0;   12;           m; Cross track resolution
+  0;  2;  27;    2;           0;   12;           m; Along track resolution
+  0;  2;  30;    0;           0;    3;  Code_Table; Method of current measurement
+  0;  2;  31;    0;           0;    5;  Code_Table; Duration and time of current measurement
+  0;  2;  32;    0;           0;    2;  Code_Table; Indicator for digitization
+  0;  2;  33;    0;           0;    3;  Code_Table; Method of salinity/depth measurement
+  0;  2;  34;    0;           0;    5;  Code_Table; Drogue type
+  0;  2;  35;    0;           0;    9;           m; Cable length
+  0;  2;  36;    0;           0;    2;  Code_Table; Buoy type
+  0;  2;  37;    0;           0;    3;  Code_Table; Method of tidal observation
+  0;  2;  38;    0;           0;    4;  Code_Table; Method of sea-surface temperature measurement
+  0;  2;  39;    0;           0;    3;  Code_Table; Method of wet-buld temperature measurement
+  0;  2;  40;    0;           0;    4;  Code_Table; Method of removing velocity and motion of platform from current
+  0;  2;  41;    0;           0;    6;  Code_Table; Method for estimating reports related to synoptic features
+  0;  2;  42;    0;           0;    6;  Code_Table; Method of report construction
+  0;  2;  43;    0;           0;    6;  Code_Table; Precision of latitude/longitude report
+  0;  2;  44;    0;           0;    4;  Code_Table; Inicator for method of calculating spectral wave data
+  0;  2;  45;    0;           0;    4;  Code_Table; Indicator for type of platform
+  0;  2;  46;    0;           0;    4;  Code_Table; Wave measurement instrumentation
+  0;  2;  48;    0;           0;    4;  Code_Table; Satellite sensor indicator
+  0;  2;  49;    0;           0;    8;  Flag_Table; Geostationary satellite data-processing technique used
+  0;  2;  50;    0;           0;   20;  Flag_Table; Geostationary sounder satellite channels used
+  0;  2;  51;    0;           0;    4;  Code_Table; Indicator ro specify observing method for extreme temperatures
+  0;  2;  52;    0;           0;    6;  Flag_Table; Geostationary imager satellite channels used
+  0;  2;  53;    0;           0;    4;  Code_Table; GOES-I/M  brightness temperature characteristics
+  0;  2;  54;    0;           0;    4;  Code_Table; GOES-I/M  soundings parameter characteristics
+  0;  2;  55;    0;           0;    4;  Code_Table; Geostationary soundings statistical parameters
+  0;  2;  56;    0;           0;    4;  Code_Table; Geostationary soundings accuracy statistics
+  0;  2;  57;    0;           0;    4;  Code_Table; Origin of first guess information for GOES-I/M soundings
+  0;  2;  58;    0;           0;    4;  Code_Table; Valid times of first guess information for GOES-I/M soundings
+  0;  2;  59;    0;           0;    4;  Code_Table; Origin of analysis information for GOES-I/M soundings
+  0;  2;  60;    0;           0;    4;  Code_Table; Origin of surface information for GOES-I/M soundings
+  0;  2;  61;    0;           0;    3;  Code_Table; Aircraft navigation system
+  0;  2;  62;    0;           0;    4;  Code_Table; Type of aircraft data relay system
+  0;  2;  63;    2;      -18000;   16;         deg; Aircraft roll angle
+  0;  2;  64;    0;           0;    2;  Code_Table; Aircraft roll angle quality
+  0;  2;  65;    0;           0;   40;   CCITT_IA5; ACARS ground receiving station
+  0;  2;  70;    0;           0;    4;  Code_Table; Original specification of latitude/longitude
+  0;  2; 100;    1;           0;   12;          dB; Radar constant
+  0;  2; 101;    0;           0;    4;  Code_Table; Type of antenna
+  0;  2; 102;    0;           0;    8;           m; Antenna height above tower
+  0;  2; 103;    0;           0;    2;  Flag_Table; Radome
+  0;  2; 104;    0;           0;    4;  Code_Table; Antenna polarisation
+  0;  2; 105;    0;           0;    6;          dB; Maximum antenna gain
+  0;  2; 106;    1;           0;    6;         deg; 3-dB bandwidth
+  0;  2; 107;    0;           0;    6;          dB; Sidelobe suppression
+  0;  2; 108;    0;           0;    6;          dB; Crosspol discrimination (on axis)
+  0;  2; 109;    2;           0;   12;       deg/s; Antenna speed (azimuth)
+  0;  2; 110;    2;           0;   12;       deg/s; Antenna speed (elevation)
+  0;  2; 111;    1;           0;   10;         deg; Radar incidence angle
+  0;  2; 112;    1;           0;   12;         deg; Radar azimuth angle
+  0;  2; 113;    0;           0;    4;     Numeric; Number of azimuth looks
+  0;  2; 114;    0;           0;   15;        m**2; Antenna effective surface area
+  0;  2; 121;   -8;           0;    7;          Hz; Mean frequency
+  0;  2; 122;   -6;        -128;    8;          Hz; Frequency agility range
+  0;  2; 123;   -4;           0;    7;           W; Peak power
+  0;  2; 124;   -1;           0;    7;           W; Average power
+  0;  2; 125;   -1;           0;    8;          Hz; Pulse repetition frequency
+  0;  2; 126;    7;           0;    6;           s; Pulse width
+  0;  2; 127;   -6;           0;    7;          Hz; Receiver intermediate frequency
+  0;  2; 128;   -5;           0;    6;          Hz; Intermediate frequency bandwidth
+  0;  2; 129;    0;        -150;    5;          dB; Minimum detectable signal
+  0;  2; 130;    0;           0;    7;          dB; Dynamic range
+  0;  2; 131;    0;           0;    2;  Flag_Table; Sensitivity time control
+  0;  2; 132;    2;           0;    6;         deg; Azimuth pointing accuracy
+  0;  2; 133;    2;           0;    6;         deg; Elevation pointing accuracy
+  0;  2; 134;    2;           0;   16;         deg; Antenna beam azimuth
+  0;  2; 135;    2;       -9000;   15;         deg; Antenna elevation
+  0;  2; 136;   -3;           0;   16;           m; Range processed by range attenuation correction
+  0;  2; 140;    2;           0;    9;         deg; Satellite radar beam azimuth
+  0;  2; 141;    0;           0;   24;   CCITT_IA5; Measurement type
+  0;  2; 142;    0;           0;   32;   CCITT_IA5; Ozone instrument serial number/identification
+  0;  2; 143;    0;           0;    7;  Code_Table; Ozone instrument type
+  0;  2; 144;    0;           0;    4;  Code_Table; Light source type for Brewer spectrophotometer
+  0;  2; 145;    0;           0;    4;  Code_Table; Wave length setting for Dobson instruments
+  0;  2; 146;    0;           0;    4;  Code_Table; Source conditions for Dobson instruments
+  0;  4;   1;    0;           0;   12;        Year; Year
+  0;  4;   2;    0;           0;    4;          mo; Month
+  0;  4;   3;    0;           0;    6;         Day; Day
+  0;  4;   4;    0;           0;    5;          hr; Hour
+  0;  4;   5;    0;           0;    6;         min; Minute
+  0;  4;   6;    0;           0;    6;           s; Second
+  0;  4;  11;    0;       -1024;   11;        Year; Time increment
+  0;  4;  12;    0;       -1024;   11;          mo; Time increment
+  0;  4;  13;    0;       -1024;   11;        Days; Time increment
+  0;  4;  14;    0;       -1024;   11;          hr; Time increment
+  0;  4;  15;    0;       -2048;   12;         min; Time increment
+  0;  4;  16;    0;       -4096;   13;           s; Time increment
+  0;  4;  21;    0;       -1024;   11;        Year; Time period or displacement
+  0;  4;  22;    0;       -1024;   11;          mo; Time period or displacement
+  0;  4;  23;    0;       -1024;   11;        Days; Time period or displacement
+  0;  4;  24;    0;       -2048;   12;          hr; Time period or displacement
+  0;  4;  25;    0;       -2048;   12;         min; Time period or displacement
+  0;  4;  26;    0;       -4096;   13;           s; Time period or displacement
+  0;  4;  31;    0;           0;    8;          hr; Duration of time relative to followinG value
+  0;  4;  32;    0;           0;    6;      Minute; Duration of time relating to following value
+  0;  4;  41;    0;       -1440;   12;      Minute; Time Difference, UTC-LMT
+  0;  4;  43;    0;           0;    9;         Day; Day of the year
+  0;  4;  53;    0;           0;    6;     Numeric; Number of days with precipition equal to or more than 1mm
+  0;  4; 192;    0;           0;    3;  Code_Table; Season
+  0;  5;   1;    5;    -9000000;   25;         deg; Latitude (high accuracy)
+  0;  5;   2;    2;       -9000;   15;         deg; Latitude (coarse accuracy)
+  0;  5;  11;    5;    -9000000;   25;         deg; Latitude increment (high accuracy)
+  0;  5;  12;    2;       -9000;   15;         deg; Latitude increment (coarse accuracy)
+  0;  5;  21;    2;           0;   16;    deg_true; Bearing or azimuth
+  0;  5;  22;    2;           0;   16;    deg_true; Solar azimuth
+  0;  5;  30;    0;           0;   12;         deg; Direction (spectral)
+  0;  5;  31;    0;           0;   12;     Numeric; Row number
+  0;  5;  33;   -1;           0;   16;           m; Pixel size on horizontal - 1
+  0;  5;  40;    0;           0;   24;     Numeric; Orbit number
+  0;  5;  41;    0;           0;    8;     Numeric; Scan line number
+  0;  5;  42;    0;           0;    6;     Numeric; Channel number
+  0;  5;  43;    0;           0;    8;     Numeric; Field of view number
+  0;  5;  52;    0;           0;    5;     Numeric; Channel number increment
+  0;  5;  53;    0;           0;    5;     Numeric; Field of view number increment
+  0;  6;   1;    5;   -18000000;   26;         deg; Longitude (high accuracy)
+  0;  6;   2;    2;      -18000;   16;         deg; Longitude (coarse accuracy)
+  0;  6;  11;    5;   -18000000;   26;         deg; Longitude increment (high accuracy)
+  0;  6;  12;    2;      -18000;   16;         deg; Longitude increment (coarse accuracy)
+  0;  6;  21;   -1;           0;   13;           m; Distance
+  0;  6;  30;    5;           0;   13;       rad/m; Wavenumber (spectral)
+  0;  6;  31;    0;           0;   12;     Numeric; Column number
+  0;  6;  33;   -1;           0;   16;           m; Pixel size on horizontal - 2
+  0;  7;   1;    0;        -400;   15;           m; Height of station
+  0;  7;   2;   -1;         -40;   16;           m; Height or altitude
+  0;  7;   3;   -1;        -400;   17;   m**2/s**2; Geopotential
+  0;  7;   4;   -1;           0;   14;          Pa; Pressure
+  0;  7;   5;    0;        -400;   12;           m; Height increment
+  0;  7;   6;    0;           0;   15;           m; Height above station
+  0;  7;   7;    0;       -1000;   17;           m; Height
+  0;  7;   8;    0;      -10000;   20;   m**2/s**2; Geopotential
+  0;  7;  21;    2;       -9000;   15;         deg; Elevation
+  0;  7;  22;    2;       -9000;   15;         deg; Solar elevation
+  0;  7;  24;    2;       -9000;   15;         deg; Satellite zenith angle
+  0;  7;  61;    2;           0;   14;           m; Depth below land surface
+  0;  7;  62;    1;           0;   17;           m; Depth below sea/water surface
+  0;  7; 190;    0;           0;   12;           m; Height increment
+  0;  8;   1;    0;           0;    7;  Flag_Table; Vertical sounding significance
+  0;  8;   2;    0;           0;    6;  Code_Table; Vertical significance (surface observations)
+  0;  8;   3;    0;           0;    6;  Code_Table; Vertical significance (satellite observations)
+  0;  8;   4;    0;           0;    3;  Code_Table; Phase of aircraft flight
+  0;  8;   5;    0;           0;    4;  Code_Table; Meteorological attribute significance
+  0;  8;   7;    0;           0;    4;  Code_Table; Dimensional significance
+  0;  8;  11;    0;           0;    6;  Code_Table; Meteorological feature
+  0;  8;  12;    0;           0;    2;  Code_Table; land/sea qualifier
+  0;  8;  13;    0;           0;    2;  Code_Table; Day/night qualifier
+  0;  8;  14;    0;           0;    4;  Code_Table; Qualification for runway visual range
+  0;  8;  16;    0;           0;    3;  Code_Table; Change indicator of a trend-type forecast or an aerodrome forecast
+  0;  8;  17;    0;           0;    2;  Code_Table; Qualifier of the time when the forecast change is expected
+  0;  8;  20;    0;           0;   16;     Numeric; Total number of missing entities (with respect to accumulation or average)
+  0;  8;  21;    0;           0;    5;  Code_Table; Time significance
+  0;  8;  22;    0;           0;   16;     Numeric; Total number (with respect to accumulation or average)
+  0;  8;  23;    0;           0;    6;  Code_Table; First order statistics
+  0;  8;  24;    0;           0;    6;  Code_Table; Difference statistics
+  0;  8;  25;    0;           0;    4;  Code_Table; Time difference qualifier
+  0;  8;  30;    0;           0;   13;     Numeric; Manual on Codes
+  0;  8;  51;    0;           0;    3;  Code_Table; Qualifier for number of missing values in calculation of statistic
+  0;  8;  52;    0;           0;    5;  Code_Table; Condition for which number of days of occurance follows
+  0;  8;  53;    0;           0;    2;  Code_Table; Day of occurance qualifier
+  0;  8;  60;    0;           0;    4;  Code_Table; Sample scanning mode significance
+  0; 10;   1;    0;        -400;   15;           m; Height of land surface
+  0; 10;   2;   -1;         -40;   16;           m; Height
+  0; 10;   3;   -1;        -400;   17;   m**2/s**2; Geopotential
+  0; 10;   4;   -1;           0;   14;          Pa; Pressure
+  0; 10;   7;    0;       -1000;   17;           m; Height
+  0; 10;   8;    0;      -10000;   20;   m**2/s**2; Geopotential
+  0; 10;  31;    2; -1073741824;   31;           m; In direction of the North Pole, distance from the Earth's centre
+  0; 10;  50;    2;           0;   16;           m; Standard deviation altitude
+  0; 10;  51;   -1;           0;   14;          Pa; Pressure reduced to mean sea level
+  0; 10;  52;   -1;           0;   14;          Pa; Altimeter setting (QNH)
+  0; 10;  60;   -1;       -1024;   11;          Pa; Pressure change
+  0; 10;  61;   -1;        -500;   10;          Pa; 3 hour pressure change
+  0; 10;  62;   -1;       -1000;   11;          Pa; 24 hour pressure change
+  0; 10;  63;    0;           0;    4;  Code_Table; Characteristic of pressure tendency
+  0; 10;  70;    0;        -400;   16;           m; Indicated aircraft altitude
+  0; 11;   1;    0;           0;    9;    deg_true; Wind direction
+  0; 11;   2;    1;           0;   12;         m/s; Wind speed
+  0; 11;   3;    1;       -4096;   13;         m/s; U-component
+  0; 11;   4;    1;       -4096;   13;         m/s; V-component
+  0; 11;   5;    1;        -512;   10;        Pa/s; W-component
+  0; 11;   6;    2;       -4096;   13;         m/s; W-component
+  0; 11;  11;    0;           0;    9;    deg_true; Wind direction at 10 m
+  0; 11;  12;    1;           0;   12;         m/s; Wind speed at 10 m
+  0; 11;  13;    0;           0;    9;    deg_true; Wind direction at 5 m
+  0; 11;  14;    1;           0;   12;         m/s; Wind speed at 5 m
+  0; 11;  16;    0;           0;    9;    deg_true; Extreme counterclockwise wind direction of a variable wind
+  0; 11;  17;    0;           0;    9;    deg_true; Extreme clockwise wind direction of a variable wind
+  0; 11;  21;    9;      -65536;   17;       s**-1; Relative vorticity
+  0; 11;  22;    9;      -65536;   17;       s**-1; Divergence
+  0; 11;  23;   -2;      -65536;   17;      m**2/s; Velocity potential
+  0; 11;  31;    0;           0;    4;  Code_Table; Degree of turbulence
+  0; 11;  32;   -1;         -40;   16;           m; Height of base of turbulence
+  0; 11;  33;   -1;         -40;   16;           m; Height of top of turbulence
+  0; 11;  34;    1;       -1024;   11;         m/s; Vertical gust velocity
+  0; 11;  35;    2;       -8192;   14;      m/s**2; Vertical gust acceleration
+  0; 11;  36;    1;           0;   10;         m/s; Maximum derived equivalent vertical gust speed
+  0; 11;  41;    1;           0;   12;         m/s; Maximum wind speed (gusts)
+  0; 11;  42;    1;           0;   12;         m/s; Maximum wind speed (10 minute mean wind)
+  0; 11;  43;    0;           0;    9;    deg_true; Maximum wind gust direction
+  0; 11;  44;    0;           0;    9;    deg_true; Mean wind direction for surface - 1500m
+  0; 11;  45;    1;           0;   12;         m/s; Mean wind speed for surface - 1500m
+  0; 11;  49;    0;           0;    9;    deg_true; Standard deviation of wind direction
+  0; 11;  50;    1;           0;   12;         m/s; Standard deviation horizontal wind speed
+  0; 11;  51;    1;           0;    8;         m/s; Standard deviation vertical wind speed
+  0; 11;  61;    1;           0;   12;         m/s; Absolute wind shear in 1 kilometer layer below
+  0; 11;  62;    1;           0;   12;         m/s; Absolute wind shear in1 kilometer layer above
+  0; 11;  70;    0;           0;   32;CCITT_IA5Designator; of the runway affected by wind shear
+  0; 11;  71;    3;        -128;   14;  m**2/s**-2; Turbulent vertical momemtum flux
+  0; 11;  72;    3;        -128;   11;           K; m/s**-2	Turbulent vertical buouancy flux
+  0; 11;  73;    2;       -1024;   13;  m**2/s**-2; Turbulent kinetic energy
+  0; 11;  74;    2;       -1024;   10;  m**2/s**-2; Dissipation energy
+  0; 11;  75;    2;           0;    8;m**(2/3)/s**-1; Mean turbulence intensity
+  0; 11;  76;    2;           0;    8;m**(2/3)/s**-1; Peak turbulence intensity
+  0; 12;   1;    1;           0;   12;       deg_K; Temperature/dry bulb temperature
+  0; 12;   2;    1;           0;   12;       deg_K; Wet bulb temperature
+  0; 12;   3;    1;           0;   12;       deg_K; Dewpoint temperature
+  0; 12;   4;    1;           0;   12;       deg_K; Dry bulb temperature at 2 meters
+  0; 12;   5;    1;           0;   12;       deg_K; Wet bulb temperature at 2 meters
+  0; 12;   6;    1;           0;   12;       deg_K; Dewpoint temperature at 2 meters
+  0; 12;   7;    1;           0;   12;       deg_K; Virtual temperature
+  0; 12;  11;    1;           0;   12;       deg_K; Maximum temperature
+  0; 12;  12;    1;           0;   12;       deg_K; Minimum temperature
+  0; 12;  13;    1;           0;   12;       deg_K; Ground minimum temperature past 12 hours
+  0; 12;  14;    1;           0;   12;       deg_K; Maximum temperature at 2 meters, past 12 hours
+  0; 12;  15;    1;           0;   12;       deg_K; Minimum temperature at 2 meters, past 12 hours
+  0; 12;  16;    1;           0;   12;       deg_K; Maximum temperature at 2 meters, past 24 hours
+  0; 12;  17;    1;           0;   12;       deg_K; Minimum temperature at 2 meters, past 24 hours
+  0; 12;  30;    1;           0;   12;       deg_K; Soil temperature
+  0; 12;  51;    1;           0;   10;       deg_K; Standard deviation of temperature
+  0; 12;  52;    1;           0;   12;       deg_K; Highest daily mean temperature
+  0; 12;  53;    1;           0;   12;       deg_K; Lowest daily mean temperature
+  0; 12;  61;    1;           0;   12;       deg_K; Skin temperature
+  0; 12;  62;    1;           0;   12;       deg_K; Equivalent black body temperature
+  0; 12;  63;    1;           0;   12;       deg_K; Brightness temperature
+  0; 13;   1;    5;           0;   14;       kg/kg; Specific humidity
+  0; 13;   2;    5;           0;   14;       kg/kg; Mixing ratio
+  0; 13;   3;    0;           0;    7;     percent; Relative humidity
+  0; 13;   4;   -1;           0;   10;          Pa; Vapor pressure
+  0; 13;   5;    3;           0;    7;     kg/m**3; Vapor density
+  0; 13;   6;   -1;         -40;   16;           m; Mixing heights
+  0; 13;  11;    4;          -1;   14;     kg/m**2; Total precipitation/total water equivalent
+  0; 13;  12;    2;          -2;   12;           m; Depth of fresh snow
+  0; 13;  13;    2;          -2;   16;           m; Total snow depth
+  0; 13;  14;    4;           0;   12;   kg/m**2/s; Rainfall/water equivalent of snow (average rate)
+  0; 13;  15;    7;           0;   12;         m/s; Snowfall (averaged rate)
+  0; 13;  16;    0;           0;    7;     kg/m**2; Precipitable water
+  0; 13;  19;    1;          -1;   14;     kg/m**2; Total precipitation past 1 hour
+  0; 13;  20;    1;          -1;   14;     kg/m**2; Total precipitation past 3 hours
+  0; 13;  21;    1;          -1;   14;     kg/m**2; Total precipitation past 6 hours
+  0; 13;  22;    1;          -1;   14;     kg/m**2; Total precipitation past 12 hours
+  0; 13;  23;    1;          -1;   14;     kg/m**2; Total precipitation past 24 hours
+  0; 13;  31;    0;           0;    7;     kg/m**2; Evapotranspiration
+  0; 13;  32;    1;           0;    8;     kg/m**2; Evaporation/evapotranspiration
+  0; 13;  33;    1;           0;   10;     kg/m**2; Evaporation/evapotranspiration
+  0; 13;  38;    0;           0;    2;  Code_Table; Superadiabatic indicator
+  0; 13;  39;    0;           0;    3;  Code_Table; Terrain type (ice/snow)
+  0; 13;  41;    0;           0;    4;  Code_Table; Pasquill-Gifford stability category
+  0; 13;  42;    0;         -20;    6;       deg_K; Parcel lifted index (to 500 hPa)
+  0; 13;  43;    0;         -20;    6;       deg_K; Best lifted index (to 500 hPa)
+  0; 13;  51;    0;           0;    4;  Code_Table; Frequency group, precipition
+  0; 13;  52;    1;          -1;   14;     kg/m**2; Highest daily amount of precipition
+  0; 14;   1;   -3;       -2048;   12; Joules/m**2; Longwave radiation, integrated over 24 hours
+  0; 14;   2;   -3;       -2048;   12; Joules/m**2; Longwave radiation, integrated over period specified
+  0; 14;   3;   -3;       -2048;   12; Joules/m**2; Shortwave radiation, integrated over 24 hours
+  0; 14;   4;   -3;       -2048;   12; Joules/m**2; Shortwave radiation, integrated over period specified
+  0; 14;  11;   -3;       -2048;   12; Joules/m**2; Net longwave radiation, integrated over 24 hours
+  0; 14;  12;   -3;       -2048;   12; Joules/m**2; Net longwave radiation, integrated over period specified
+  0; 14;  13;   -3;       -2048;   12; Joules/m**2; Net shortwave radiation, integrated over 24 hours
+  0; 14;  14;   -3;       -2048;   12; Joules/m**2; Net shortwave radiation, integrated over period specified
+  0; 14;  15;   -4;      -16384;   15; Joules/m**2; Net radiation, integrated over 24 hours
+  0; 14;  16;   -4;      -16384;   15; Joules/m**2; Net radiation, integrated over period specified
+  0; 14;  17;   -3;       -2048;   12;      W/m**2; Instantaneous long wave radiation
+  0; 14;  18;   -3;       -2048;   12;      W/m**2; Instantaneous short wave radiation
+  0; 14;  19;    0;           0;    7;     percent; Surface albedo
+  0; 14;  20;   -4;           0;   15; Joules/m**2; Global solar radiation, integrated over 24 hours
+  0; 14;  21;   -4;           0;   15; Joules/m**2; Global radiation, integrated over period specified
+  0; 14;  22;   -4;           0;   15; Joules/m**2; Diffuse solar radiation, integrated over 24 hours
+  0; 14;  23;   -4;           0;   15; Joules/m**2; Diffuse solar radiation, integratedi over period specified
+  0; 14;  24;   -4;           0;   15; Joules/m**2; Direct solar radiation, integrated over 24 hours
+  0; 14;  25;   -4;           0;   15; Joules/m**2; Direct solar radiation, integrated over period specified
+  0; 14;  26;    0;           0;    7;     percent; Albedo at the top of clouds
+  0; 14;  31;    0;           0;   11;         min; Total sunshine
+  0; 14;  32;    0;           0;   10;          hr; Total sunshine
+  0; 14;  33;    0;           0;    9;     percent; Total sunshine
+  0; 14;  42;    0;           0;    7;     percent; Bi-directional reflectance
+  0; 15;   1;    0;           0;   10;      Dobson; units	Ozone
+  0; 15;   2;    2;           0;   10;     Numeric; Air mass (slant path at 22km)
+  0; 15;  11;    3;       14000;   13; log(1/m**2); Log 10 of integrated electron density
+  0; 15;  15;    0;           0;   31;     Numeric; Maximum image spectral composition before normalization
+  0; 19;   1;    0;           0;    6;  Code_Table; Type of synoptic features
+  0; 19;   2;   -2;           0;   12;           m; Effective radius of feature
+  0; 19;   3;    0;           0;    8;         m/s; Wind speed threshold
+  0; 19;   4;   -2;           0;   12;           m; Effective radius of feature with respect to wind speeds above threshold
+  0; 19;   5;    0;           0;    9;    deg_true; Direction of motion of features
+  0; 19;   6;    2;           0;   14;         m/s; Speed of motion of features
+  0; 19;   7;   -3;           0;   12;           m; Effective radius of features
+  0; 19;   8;    0;           0;    3;  Code_Table; Vertical extent of circulation
+  0; 19;   9;   -3;           0;   12;           m; Effective radius with respect to wind speed above threshold (large storms)
+  0; 20;   1;   -1;           0;   13;           m; Horizontal visibility
+  0; 20;   2;   -1;           0;    7;           m; Vertical visibility
+  0; 20;   3;    0;           0;    9;  Code_Table; Present weather
+  0; 20;   4;    0;           0;    5;  Code_Table; Past weather (1)
+  0; 20;   5;    0;           0;    5;  Code_Table; Past weather (2)
+  0; 20;   9;    0;           0;    4;  Code_Table; General Weather Indicator
+  0; 20;  10;    0;           0;    7;     percent; Cloud cover (total)
+  0; 20;  11;    0;           0;    4;  Code_Table; Cloud amount
+  0; 20;  12;    0;           0;    6;  Code_Table; Cloud type
+  0; 20;  13;   -1;         -40;   11;           m; Height of base of cloud
+  0; 20;  14;   -1;         -40;   11;           m; Height of top of cloud
+  0; 20;  15;   -1;           0;   14;          Pa; Pressure at the base of cloud
+  0; 20;  16;   -1;           0;   14;          Pa; Pressure at the top of cloud
+  0; 20;  17;    0;           0;    4;  Code_Table; Cloud top description
+  0; 20;  18;    0;           0;    2;  Code_Table; Tendency of runway visual range
+  0; 20;  19;    0;           0;   72;   CCITT_IA5; Significant present or forecast weather
+  0; 20;  20;    0;           0;   32;   CCITT_IA5; Significant recent weather phenomena
+  0; 20;  31;    2;           0;    7;           m; Ice deposit (thickness)
+  0; 20;  32;    0;           0;    3;  Code_Table; Rate of ice accretion
+  0; 20;  33;    0;           0;    4;  Flag_Table; Cause of ice accretion
+  0; 20;  34;    0;           0;    5;  Code_Table; Sea ice concentration
+  0; 20;  35;    0;           0;    4;  Code_Table; Amount and type of ice
+  0; 20;  36;    0;           0;    5;  Code_Table; Ice situation
+  0; 20;  37;    0;           0;    5;  Code_Table; Ice development
+  0; 20;  38;    0;           0;   12;    deg_true; Bearing of ice edge
+  0; 20;  39;   -1;           0;   13;           m; Ice distance
+  0; 20;  41;    0;           0;    4;  Code_Table; Airframe icing
+  0; 20;  51;    0;           0;    7;     percent; Amount of low clouds
+  0; 20;  52;    0;           0;    7;     percent; Amount of middle clouds
+  0; 20;  53;    0;           0;    7;     percent; Amount of high clouds
+  0; 20;  61;    0;           0;   12;           m; Runway visual range (RVR)
+  0; 20;  62;    0;           0;    5;  Code_Table; State of the ground(with or without snow)
+  0; 20;  63;    0;           0;   10;  Code_Table; Special phenomena
+  0; 20;  90;    0;           0;    4;  Code_Table; Special clouds
+  0; 21;   1;    0;         -64;    7;          dB; Horizontal reflectivity
+  0; 21;   2;    0;         -64;    7;          dB; Vertical reflectivity
+  0; 21;   3;    1;          -5;    7;          dB; Differential reflectivity
+  0; 21;   5;    0;         -65;    6;          dB; Linear depolarization ratio
+  0; 21;   6;    0;         -65;    6;          dB; Circular depolarization ratio
+  0; 21;  11;    0;        -128;    8;         m/s; Doppler mean velocity in X direction
+  0; 21;  12;    0;        -128;    8;         m/s; Doppler mean velocity in Y direction
+  0; 21;  13;    0;        -128;    8;         m/s; Doppler mean velocity in Z direction
+  0; 21;  14;    1;       -4096;   13;         m/s; Doppler mean velocity (radiational)
+  0; 21;  17;    1;           0;    8;         m/s; Doppler velocity spectral width
+  0; 21;  21;   -3;           0;    4;           m; Echo tops
+  0; 21;  30;    0;         -32;    8;          dB; Signal to noise ratio
+  0; 21;  31;    0;           0;    7;     kg/m**2; Vertical integrated liquid water content
+  0; 21;  36;    7;           0;   12;         m/s; Radar rainfall intensity
+  0; 21;  41;   -2;           0;    8;           m; Bright band height
+  0; 21;  51;    0;        -256;    8;          dB; Signal power above 1 MW
+  0; 21;  62;    2;       -5000;   13;    Decibels; Backscatter
+  0; 21;  63;    1;           0;   10;     Percent; Radiometric resolution (noise value)
+  0; 21;  64;    0;           0;    8;     Numeric; Clutter noise estimate
+  0; 21;  65;    0;        -127;    8;     Numeric; Missing packet counter
+  0; 21;  66;    0;           0;   12;  Flag_Table; Wave scatterometer product confidence
+  0; 21;  67;    0;           0;   13;  Flag_Table; Wind product confidence data
+  0; 21;  68;    0;           0;    8;  Flag_Table; Radar altimeter product confidence data
+  0; 21;  69;    0;           0;   10;  Flag_Table; SST product confidence data
+  0; 21;  71;    0;           0;   16;     Numeric; Peakiness
+  0; 21;  72;    0;           0;    4;  Flag_Table; Satellite altimeter calibration status
+  0; 21;  73;    0;           0;    9;  Flag_Table; Satellite altimeter instrument mode
+  0; 21;  75;    0;           0;    8;     Numeric; Spectral intensity
+  0; 21;  76;    0;           0;    3;  Code_Table; Representation of intensities
+  0; 21;  77;    3;           0;   14;           m; Altitude correction (ionosphere)
+  0; 21;  78;    3;           0;    9;           m; Altitude correction (dry troposphere)
+  0; 21;  79;    3;        2000;   10;           m; Altitude correction (wet troposphere)
+  0; 21;  80;    3;           0;   11;           m; Altitude correction (calibration constant)
+  0; 21;  81;    3;           0;   10;           m; Open loop correction (height-time loop)
+  0; 21;  82;    3;       -3000;   14;    Decibels; Open loop correction (auto gain control)
+  0; 21;  85;    0;       -3000;    4;     Numeric; ATSR sea surface temperature across-track band number
+  0; 22;   1;    0;           0;    9;    deg_true; Direction of waves
+  0; 22;   2;    0;           0;    9;    deg_true; Direction of wind waves
+  0; 22;   3;    0;           0;    9;    deg_true; Direction of swell waves
+  0; 22;   4;    0;           0;    9;    deg_true; Direction of current waves
+  0; 22;  11;    0;           0;    6;           s; Period of waves
+  0; 22;  12;    0;           0;    6;           s; Period of wind waves
+  0; 22;  13;    0;           0;    6;           s; Period of swell waves
+  0; 22;  21;    1;           0;   10;           m; Height of waves
+  0; 22;  22;    1;           0;   10;           m; Height of wind waves
+  0; 22;  23;    1;           0;   10;           m; Height of swell waves
+  0; 22;  25;    2;           0;   10;           m; Standard deviation wave
+  0; 22;  26;    2;           0;   10;           m; Standard deviation of significant wave height
+  0; 22;  31;    2;           0;   13;         m/s; Speed of current
+  0; 22;  37;    3;      -10000;   15;           m; Tidal elevation with respect to national chart datum
+  0; 22;  38;    3;      -10000;   15;           m; Tidal elevation with respect to local chart datum
+  0; 22;  39;    3;       -5000;   12;           m; Meteorological residual tidal elevation (surge or offset)
+  0; 22;  40;    3;       -5000;   14;           m; Meteorological residual tidal elevation (surge or offset)
+  0; 22;  41;    1;           0;   12;       deg_K; Sea surface temperature (15 day running mean)
+  0; 22;  42;    1;           0;   12;       deg_K; Sea/water temperature
+  0; 22;  43;    2;           0;   15;       deg_K; Sea/water temperature
+  0; 22;  44;    1;           0;   14;         m/s; Sound velocity
+  0; 22;  50;    2;           0;    8;           K; Standard deviation sea surface temperature
+  0; 22;  61;    0;           0;    4;  Code_Table; State of sea
+  0; 22;  62;    2;           0;   14;         ppt; Salinity
+  0; 22;  63;    0;           0;   14;           m; Total water depth
+  0; 22;  67;    0;           0;   10;  Code_Table; Instrument type for water temperature profile measurement
+  0; 22;  68;    0;           0;    7;  Code_Table; Water temperature profile recorder types
+  0; 22;  70;    2;           0;   13;           m; Significant wave height
+  0; 22;  71;    1;           0;    9;           s; Spectral peak wave period
+  0; 22;  72;    0;           0;   13;           m; Spectral peak wave length
+  0; 22;  73;    2;           0;   13;           m; Maximum wave height
+  0; 22;  74;    1;           0;    9;           s; Average wave period
+  0; 22;  75;    0;           0;   13;           m; Average wave length
+  0; 22;  76;    0;           0;    9; Degree_True; Direction from which dominant waves are coming
+  0; 22;  77;    0;           0;    9;      Degree; Directional spred of dominant wave
+  0; 22;  78;    0;           0;   12;           s; Duration of wave record
+  0; 22;  79;    0;           0;   16;           m; Length of wave record
+  0; 22;  80;    3;           0;   10;          Hz; Waveband central frequency
+  0; 22;  81;    5;           0;   13;       m**-1; Waveband central wave number
+  0; 22;  82;    2;           0;   20;      m**2/s; Maximum non-directional spectral wave density
+  0; 22;  83;    2;           0;   20;        m**3; Maximum non-directional spectral wave number
+  0; 22;  84;    0;           0;    7;     Numeric; Band containing maximum non-directional spectral wave density
+  0; 22;  85;    0;           0;    7;     Numeric; Spectral wave density ratio
+  0; 22;  86;    0;           0;    9; Degree_True; Mean direction from which waves are coming
+  0; 22;  87;    0;           0;    9; Degree_True; Principal direction from which waves are coming
+  0; 22;  88;    2;           0;    7;     Numeric; First normalized polar coordinate from Fourier coefficients
+  0; 22;  89;    2;           0;    7;     Numeric; Second normalized polar coordinate from Fourier coefficients
+  0; 22;  90;    2;           0;   20;      m**2/s; Non-directional spectral estimate by wave frequency
+  0; 22;  91;    2;           0;   20;        m**3; Non-directional spectral estimate by wave number
+  0; 22;  92;    2;           0;   20;m**2/rad**-1/s; Directional spectral estimate by wave frequency
+  0; 22;  93;    2;           0;   20;        m**4; Directional spectral estimate by wave number
+  0; 22;  94;    0;           0;    7;     Numeric; Total number of wave bands
+  0; 22;  95;    0;           0;    8;      Degree; Directional spread of individual waves
+  0; 22;  96;    3;           0;    4;       s**-1; Spectral band width
+  0; 22;  97;    0;           0;   14;           m; Mean wavelength > 731 m of image spectrum at low wave numbers
+  0; 22;  98;    0;           0;   14;           m; Wavelength spread (wavelength > 731 m) at low wave numbers
+  0; 22;  99;    0;           0;    9;    deg_true; Mean direction at low wave numbers (wavelength > 731 m)
+  0; 22; 100;    0;           0;    9;      Degree; Direction spread at low wave numbers (wavelength > 731 m)
+  0; 22; 101;    0;           0;   31;    Numberic; Total energy (wavelength > 731 m) at low wave numbers
+  0; 22; 120;    0;           0;    5;  Code_Table; Tide station automated water level check
+  0; 22; 121;    0;           0;    5;  Code_Table; Tide station manual water level check
+  0; 22; 122;    0;           0;    5;  Code_Table; Tide station automated Meteorological data check
+  0; 22; 123;    0;           0;    5;  Code_Table; Tide station manual Meteorological data check
+  0; 23;   1;    0;           0;    3;  Code_Table; Accident early notification - article applicable
+  0; 23;   2;    0;           0;    5;  Code_Table; Activity or facility involved in incident
+  0; 23;   3;    0;           0;    3;  Code_Table; Type of release
+  0; 23;   4;    0;           0;    3;  Code_Table; Countermeasures taken near border
+  0; 23;   5;    0;           0;    2;  Code_Table; Cause of incident
+  0; 23;   6;    0;           0;    3;  Code_Table; Incident situation
+  0; 23;   7;    0;           0;    3;  Code_Table; Characteristic of release
+  0; 23;   8;    0;           0;    2;  Code_Table; State of current release
+  0; 23;   9;    0;           0;    2;  Code_Table; State of expected release
+  0; 23;  16;    0;           0;    2;  Code_Table; Possibility of significant chemical toxic health effect
+  0; 23;  17;    6;           0;   20;      m**3/s; Flow discharge of major recipient
+  0; 23;  18;    0;           0;    3;  Code_Table; release behavior over time
+  0; 23;  19;    0;      -15000;   17;           m; Actual release height
+  0; 23;  21;    0;      -15000;   17;           m; Effective release height
+  0; 23;  22;    0;           0;   24;           m; Distance of relative point or site of incident
+  0; 23;  23;    1;           0;   12;         m/s; Main transport speed in atmosphere
+  0; 23;  24;    2;           0;   13;         m/s; Main transport speed in water
+  0; 23;  25;    2;           0;   13;         m/s; Main transport speed in ground water
+  0; 23;  27;    0;           0;    9;    deg_true; Main transport direction in atmosphere
+  0; 23;  28;    0;           0;    9;    deg_true; Main transport direction in water
+  0; 23;  29;    0;           0;    9;    deg_true; Main transport direction in ground water
+  0; 23;  31;    0;           0;    2;  Code_Table; Possibility that plume will encounter precipitation cwin state in which incident occurred
+  0; 23;  32;    0;           0;    2;  Code_Table; Plume will encounter ichange in wind direction and/or speed flag
+  0; 24;   1;   -1;           0;   28;          Bq; Estimate of radiatioactivity released up to specified time
+  0; 24;   2;   -1;           0;   28;          Bq; Estimated maximum potential release
+  0; 24;   3;    0;           0;    5;  Code_Table; Composition of release
+  0; 24;   4;    0;           0;   16;   CCITT_IA5; Element name
+  0; 24;   5;    0;           0;    9;     Numeric; Isotope mass
+  0; 24;  11;    2;           0;   32;         mSv; Dose
+  0; 24;  12;    2;           0;   32;         mSv; Trajectory dose (defined location and expected time of arrival)
+  0; 24;  13;    2;           0;   32;         mSv; Gamma dose in air along the main transport path (defined location and time period
+  0; 24;  21;    2;           0;   32;     Bq/m**3; Air concentration (named isotope type including gross beta)
+  0; 24;  22;    2;           0;   32;        Bq/l; Concentration in precipitation (of named isotope type)
+  0; 25;   1;   -1;           0;    6;           m; Range gate length
+  0; 25;   2;    0;           0;    4;     Numeric; Number of gates averaged
+  0; 25;   3;    0;           0;    8;     Numeric; Number of integrated pulses
+  0; 25;   4;    0;           0;    2;  Code_Table; Echo processing
+  0; 25;   5;    0;           0;    2;  Code_Table; Echo integration
+  0; 25;   6;    0;           0;    3;  Code_Table; Z to R conversion
+  0; 25;   7;    0;           0;   12;     Numeric; Z to R conversion factor
+  0; 25;   8;    2;           0;    9;     Numeric; Z to R conversion exponent
+  0; 25;   9;    0;           0;    4;  Flag_Table; Calibration method
+  0; 25;  10;    0;           0;    4;  Code_Table; Clutter treatment
+  0; 25;  11;    0;           0;    2;  Code_Table; Ground occultation correction (screening)
+  0; 25;  12;    0;           0;    2;  Code_Table; Range attenuation correction
+  0; 25;  13;    0;           0;    2;  Flag_Table; Bright band correction
+  0; 25;  14;    0;           0;   12;     Numeric; Azimuth clutter cut-off
+  0; 25;  15;    0;           0;    2;  Flag_Table; Radome attenuation correction
+  0; 25;  16;    5;           0;    6;        dB/m; Clear air attenuation correction
+  0; 25;  17;    0;           0;    2;  Flag_Table; Precipitation attenuation correction
+  0; 25;  18;    7;           0;    6;     Numeric; A to Z law for attenuation factor
+  0; 25;  19;    2;           0;    7;     Numeric; A to Z law for attenuation exponent
+  0; 25;  20;    0;           0;    2;  Code_Table; Mean speed estimation
+  0; 25;  21;    0;           0;    8;  Flag_Table; Wind computation enhancement
+  0; 25;  30;    0;           0;    2;  Code_Table; SST usage
+  0; 25;  32;    0;           0;    2;  Code_Table; NOAA wind profiler high/low mode data
+  0; 25;  33;    0;           0;    2;  Code_Table; NOAA wind profiler submode
+  0; 25;  34;    0;           0;    4;  Code_Table; NOAA wind profiler Q/C test results
+  0; 25;  40;    0;           0;    4;  Code_Table; CO2 wind product derivation
+  0; 25;  41;    0;           0;    2;  Code_Table; Moving platform direction reporting method
+  0; 25;  42;    0;           0;    2;  Code_Table; Moving platform speed reporting method
+  0; 25;  43;    4;           0;   15;           s; Wave sampling interval (time)
+  0; 25;  44;    2;           0;   14;           m; Wave sampling interval (space)
+  0; 25;  45;    0;           0;   21;  Flag_Table; HIRS channel combination
+  0; 25;  46;    0;           0;    5;  Flag_Table; MSU channel combination
+  0; 25;  47;    0;           0;    4;  Flag_Table; SSU channel combination
+  0; 25;  48;    0;           0;   16;  Flag_Table; AMSU-A channel combination
+  0; 25;  49;    0;           0;    6;  Flag_Table; AMSU-B channel combination
+  0; 25;  50;    0;           0;    7;  Flag_Table; AVHRR channel combination
+  0; 25;  51;    0;           0;   12;  Flag_Table; Observation quality
+  0; 25;  60;    0;           0;   14;     Numeric; Software identification
+  0; 26;   1;    1;           0;   12;        Hour; Principal time of daily reading in UTC of maximum temperature
+  0; 26;   2;    1;           0;   12;        Hour; Principal time of daily reading in UTC of minimum temperature
+  0; 26;   3;    0;       -1440;   12;      Minute; Time difference
+  0; 27;   1;    5;    -9000000;   25;         deg; Latitude (high accuracy)
+  0; 27;   2;    2;       -9000;   15;         deg; Latitude (coarse accuracy)
+  0; 27;   3;    2;       -9000;   15;         deg; Alternate latitude
+  0; 27;  20;    0;           0;   16;     Numeric; Satellite locationon counter
+  0; 27;  21;    0;           0;   16;     Numeric; Satellite sub-locationon dimensions
+  0; 27;  31;    2; -1073741824;   31;           m; In direction of 0 degrees longitude, distance from the Earth's centre
+  0; 28;   1;    5;   -18000000;   26;         deg; Longitude (high accuracy)
+  0; 28;   2;    2;      -18000;   16;         deg; Longitude (coarse accuracy)
+  0; 28;   3;    2;      -18000;   16;         deg; Alternate longtiude
+  0; 28;  31;    2; -1073741824;   31;           m; In direction of 90 degrees East, distance from the Earth's centre
+  0; 29;   1;    0;           0;    3;  Code_Table; Projection type
+  0; 29;   2;    0;           0;    2;  Code_Table; Coordinate grid type
+  0; 30;   1;    0;           0;    4;     Numeric; Pixel value (4 bits)
+  0; 30;   2;    0;           0;    8;     Numeric; Pixel value (8 bits)
+  0; 30;   4;    0;           0;   16;     Numeric; Pixel value (16 bits)
+  0; 30;  21;    0;           0;   12;     Numeric; Number of pixels per row
+  0; 30;  22;    0;           0;   12;     Numeric; Number of pixels per column
+  0; 30;  31;    0;           0;    4;  Code_Table; Picture type
+  0; 30;  32;    0;           0;   16;  Flag_Table; Combined picture
+  0; 31;   0;    0;           0;    1;     Numeric; Short delayed descriptor replication factor
+  0; 31;   1;    0;           0;    8;     Numeric; Delayed descriptor replication factor
+  0; 31;   2;    0;           0;   16;     Numeric; Extended delayed descriptor replication factor
+  0; 31;  11;    0;           0;    8;     Numeric; Delayed descriptor and data repetion factor
+  0; 31;  12;    0;           0;   16;     Numeric; Extended delayed descriptor and data repitition factor
+  0; 31;  21;    0;           0;    6;  Code_Table; Associated field significance
+  0; 31;  31;    0;           0;    1;  Flag_Table; Data present indicator
+  0; 33;   2;    0;           0;    2;  Code_Table; Quality information
+  0; 33;   3;    0;           0;    3;  Code_Table; Quality information
+  0; 33;   7;    0;           0;    7;     Percent; Per cent confidence
+  0; 33;  20;    0;           0;    3;  Code_Table; Quality control indication of following value
+  0; 33;  21;    0;           0;    2;  Code_Table; Quality of following value
+  0; 33;  22;    0;           0;    2;  Code_Table; Quality of buoy satellite transmission
+  0; 33;  23;    0;           0;    2;  Code_Table; Quality of buoy location
+  0; 33;  24;    0;           0;    4;  Code_Table; Station elevation quality mark (for mobile stations)
+  0; 33;  25;    0;           0;    3;  Code_Table; ACARS interpolated values
+  0; 33;  26;    0;           0;    6;  Code_Table; Mixing ratio quality
+  0; 33;  27;    0;           0;    3;  Code_Table; Location quality class
diff --git a/data/tables/B3M-000-005-D b/data/tables/B3M-000-005-D
new file mode 100644
index 0000000..3ccc79e
--- /dev/null
+++ b/data/tables/B3M-000-005-D
@@ -0,0 +1,1760 @@
+#
+# BUFR Table D (Lists of Common Sequences)
+#
+# Descriptor sequences are terminated with -1
+#
+# Sequences do not need to appear in any order.  Sequence A
+# which includes sequence B, may appear before sequence B
+# is defined.
+#
+3	0	2
+	0	0	2
+	0	0	3
+	-1
+
+3	0	3
+	0	0	10
+	0	0	11
+	0	0	12
+	-1
+
+3	0	4
+	3	0	3
+	0	0	13
+	0	0	14
+	0	0	15
+	0	0	16
+	0	0	17
+	0	0	18
+	0	0	19
+	0	0	20
+	-1
+
+3	0	10
+	3	0	3
+	1	1	0
+	0	31	1
+	0	0	30
+	-1
+
+3	1	1
+	0	1	1
+	0	1	2
+	-1
+
+3	1	2
+	0	1	3
+	0	1	4
+	0	1	5
+	-1
+
+3	1	3
+	0	1	11
+	0	1	12
+	0	1	13
+	-1
+
+3	1	11
+	0	4	1
+	0	4	2
+	0	4	3
+	-1
+
+3	1	12
+	0	4	4
+	0	4	5
+	-1
+
+3	1	13
+	0	4	4
+	0	4	5
+	0	4	6
+	-1
+
+3	1	21
+	0	5	1
+	0	6	1
+	-1
+
+3	1	22
+	0	5	1
+	0	6	1
+	0	7	1
+	-1
+
+3	1	23
+	0	5	2
+	0	6	2
+	-1
+
+3	1	24
+	0	5	2
+	0	6	2
+	0	7	1
+	-1
+
+3	1	25
+	3	1	23
+	0	4	3
+	3	1	12
+	-1
+
+3	1	26
+	3	1	21
+	0	4	3
+	0	4	3
+	0	4	4
+	0	4	4
+	0	4	5
+	0	4	5
+	-1
+
+3	1	31
+	3	1	1
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	22
+	-1
+
+3	1	32
+	3	1	1
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	24
+	-1
+
+3	1	33
+	0	1	5
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	21
+	-1
+
+3	1	34
+	0	1	5
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	35
+	0	1	5
+	0	1	12
+	0	1	13
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	36
+	3	1	3
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	37
+	3	1	1
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	22
+	-1
+
+3	1	38
+	3	1	1
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	24
+	-1
+
+3	1	39
+	3	1	3
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	40
+	3	1	3
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	24
+	-1
+
+3	1	41
+	0	1	7
+	0	2	21
+	0	2	22
+	3	1	11
+	3	1	12
+	-1
+
+3	1	42
+	3	1	41
+	3	1	21
+	-1
+
+3	1	43
+	0	1	7
+	0	2	23
+	3	1	11
+	3	1	13
+	3	1	21
+	-1
+
+3	1	44
+	0	1	7
+	0	2	24
+	3	1	11
+	3	1	13
+	3	1	21
+	-1
+
+3	1	45
+	3	1	11
+	3	1	12
+	2	1	138
+	2	2	131
+	0	4	6
+	2	01	0
+	2	2	0
+	3	4	30
+	3	4	31
+	-1
+
+3	1	47
+	0	1	7
+	0	25	60
+	0	1	33
+	0	1	34
+	0	1	12
+	3	1	45
+	0	2	21
+	3	1	11
+	3	1	12
+	2	1	138
+	2	2	131
+	0	4	6
+	2	1	0
+	2	2	0
+	3	1	23
+	-1 
+
+3	1	48
+	0	2	104
+	0	2	121
+	0	2	113
+	0	2	26
+	0	2	27
+	0	2	111
+	0	2	140
+	2	2	127
+	0	1	13
+	2	2	126
+	0	7	1
+	2	2	0
+	0	25	10
+	0	21	64
+	-1
+
+3	1	49
+	0	2	111
+	0	2	112
+	0	21	62
+	0	21	63
+	0	21	64
+	-1
+
+3	1	51
+	0	1	6
+	0	2	61
+	3	1	11
+	3	1	12
+	3	1	21
+	0	8	4
+	-1
+
+3	1	55
+	0	1	5
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	21
+	0	1	12
+	0	1	14
+	-1
+
+3	1	62
+	1	1	0
+	0	31	1
+	3	1	1
+	-1
+
+3	1	65
+	0	1	6
+	0	1	8
+	0	2	1
+	0	2	2
+	0	2	5
+	0	2	62
+	0	2	70
+	0	2	65
+	-1
+
+3	1	66
+	3	1	11
+	3	1	13
+	3	1	23
+	0	7	4
+	0	2	64
+	0	8	4
+	-1
+
+3	2	1
+	0	10	4
+	0	10	51
+	0	10	61
+	0	10	63
+	-1
+
+3	2	2
+	0	10	4
+	0	7	4
+	0	10	3
+	0	10	61
+	0	10	63
+	-1
+
+3	2	3
+	0	11	11
+	0	11	12
+	0	12	4
+	0	12	6
+	0	13	3
+	0	20	1
+	0	20	3
+	0	20	4
+	0	20	5
+	-1
+
+3	2	4
+	0	20	10
+	0	8	2
+	0	20	11
+	0	20	13
+	0	20	12
+	0	20	12
+	0	20	12
+	-1
+
+3	2	5
+	0	8	2
+	0	20	11
+	0	20	12
+	0	20	13
+	-1
+
+3	2	6
+	0	10	4
+	0	10	51
+	0	10	62
+	0	10	63
+	-1
+
+3	2	11
+	3	2	1
+	3	2	3
+	3	2	4
+	-1
+
+3	2	12
+	3	2	2
+	3	2	3
+	3	2	4
+	-1
+
+3	2	13
+	3	2	6
+	3	2	3
+	1	1	0
+	0	31	1
+	3	2	05
+	-1
+
+3	2	21
+	0	22	1
+	0	22	11
+	0	22	21
+	-1
+
+3	2	22
+	0	22	2
+	0	22	12
+	0	22	22
+	-1
+
+3	2	23
+	0	22	3
+	0	22	13
+	0	22	23
+	-1
+
+3	2	24
+	3	2	22
+	1	1	2
+	3	2	23
+	-1
+
+3	2	51
+	0	10	4
+	0	10	51
+	0	7	4
+	0	10	3
+	0	12	4
+	0	12	51
+	0	12	16
+	0	12	17
+	0	13	4
+	1	2	4
+	0	8	51
+	0	8	20
+	-1
+
+3	3	1
+	0	7	3
+	0	11	1
+	0	11	22
+	-1
+
+3	3	2
+	0	7	4
+	0	11	1
+	0	11	2
+	-1
+
+3	3	3
+	0	7	4
+	0	10	3
+	0	12	1
+	0	12	3
+	-1
+
+3	3	4
+	0	7	4
+	0	10	3
+	0	12	1
+	0	12	3
+	0	11	1
+	0	11	2
+	-1
+
+3	3	11
+	0	7	3
+	0	8	1
+	0	11	1
+	0	11	2
+	-1
+
+3	3	12
+	0	7	4
+	0	8	1
+	0	11	1
+	0	11	2
+	-1
+
+3	3	13
+	0	7	4
+	0	8	1
+	0	10	3
+	0	12	1
+	0	13	3
+	0	11	1
+	0	11	2
+	-1
+
+3	3	14
+	0	7	4
+	0	8	1
+	0	10	3
+	0	12	1
+	0	12	3
+	0	11	1
+	0	11	2
+	-1
+
+3	3	21
+	0	7	4
+	0	7	4
+	2	4	7
+	0	31	21
+	-1
+
+3	3	22
+	3	3	21
+	0	10	3
+	2	4	0
+	-1
+
+3	3	23
+	3	3	21
+	0	12	1
+	2	4	0
+	-1
+
+3	3	24
+	3	3	21
+	0	13	16
+	2	4	0
+	-1
+
+3	3	25
+	0	2	25
+	2	4	7
+	0	31	21
+	0	12	63
+	2	4	0
+	-1
+
+3	3	26
+	0	7	4
+	0	8	3
+	2	4	7
+	0	31	21
+	0	12	1
+	2	4	0
+	-1
+
+3	3	27
+	0	7	4
+	2	4	7
+	0	31	21
+	0	10	3
+	2	4	0
+	-1
+
+3	3	31
+	0	7	4
+	0	8	3
+	0	7	21
+	0	7	22
+	0	8	12
+	0	12	61
+	-1
+
+3	3	32
+	0	20	11
+	0	20	16
+	-1
+
+3	3	33
+	0	20	10
+	0	20	16
+	-1
+
+3	4	1
+	0	8	3
+	0	10	4
+	0	12	1
+	0	11	1
+	0	11	2
+	-1
+
+3	4	2
+	0	8	3
+	0	10	4
+	0	11	1
+	0	11	2
+	-1
+
+3	4	3
+	0	8	3
+	0	12	1
+	-1
+
+3	4	4
+	0	8	3
+	0	10	4
+	0	20	10
+	0	12	1
+	-1
+
+3	4	5
+	0	2	24
+	0	7	4
+	0	7	4
+	0	13	3
+	-1
+
+3	4	6
+	0	14	1
+	0	14	1
+	0	14	3
+	-1
+
+3	4	30
+	0	27	31
+	0	28	31
+	0	10	31
+	-1
+
+3	4	31
+	0	1	41
+	0	1	42
+	0	1	43
+	-1
+
+3	6	1
+	0	2	32
+	1	2	0
+	0	31	1
+	0	7	62
+	0	22	42
+	-1
+
+3	6	2
+	0	2	31
+	0	22	4
+	0	22	31
+	-1
+
+3	6	3
+	0	2	2
+	0	11	11
+	0	11	12
+	0	12	4
+	-1
+
+3	6	4
+	0	2	32
+	0	2	33
+	1	3	0
+	0	31	1
+	0	7	62
+	0	22	43
+	0	22	62
+	-1
+
+3	6	5
+	0	2	31
+	1	3	0
+	0	31	1
+	0	7	62
+	0	22	4
+	0	22	31
+	-1
+
+3	6	6
+	3	6	3
+	3	6	2
+	0	22	63
+	-1
+
+3	6	7
+	0	1	12
+	0	1	14
+	3	6	8
+	0	4	24
+	0	27	3
+	0	28	3
+	-1
+
+3	6	8
+	0	2	34
+	0	2	35
+	0	2	36
+	-1
+
+3	6	20
+	3	6	24
+	1	2	6
+	0	22	38
+	0	22	39
+	-1
+
+3	6	21
+	0	1	75
+	3	1	11
+	3	1	12
+	0	22	122
+	0	22	123
+	0	12	1
+	3	3	2
+	-1
+
+3	6	22
+	0	1	75
+	3	1	11
+	3	1	12
+	0	22	38
+	0	22	39
+	-1
+
+3	6	23
+	0	1	15
+	3	1	23
+	3	1	11
+	3	1	12
+	0	22	38
+	0	22	39
+	0	22	120
+	0	22	121
+	-1
+
+3	6	24
+	0	1	75
+	3	1	11
+	3	1	12
+	0	22	42
+	0	22	120
+	0	22	121
+	0	4	25
+	0	4	15
+	-1
+
+3	7	1
+	3	1	31
+	3	2	11
+	-1
+
+3	7	2
+	3	1	32
+	3	2	11
+	-1
+
+3	7	3
+	3	7	1
+	1	1	0
+	0	31	1
+	3	2	5
+	-1
+
+3	7	4
+	3	7	2
+	1	1	0
+	0	31	1
+	3	2	5
+	-1
+
+3	7	5
+	3	7	1
+	1	1	4
+	3	2	5
+	-1
+
+3	7	6
+	3	7	2
+	1	1	4
+	3	2	5
+	-1
+
+3	7	7
+	3	1	31
+	3	2	12
+	-1
+
+3	7	8
+	3	1	32
+	3	2	12
+	-1
+
+3	7	9
+	3	1	31
+	3	2	13
+	-1
+
+3	7	11
+	0	1	63
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	24
+	0	7	6
+	0	11	1
+	0	11	16
+	0	11	17
+	0	11	2
+	0	11	42
+	0	7	6
+	0	12	1
+	0	12	3
+	0	10	52
+	0	20	9
+	-1
+
+3	7	12
+	1	3	0
+	0	31	1
+	0	8	23
+	0	5	21
+	0	20	1
+	-1
+
+3	7	13
+	1	6	0
+	0	31	1
+	0	1	64
+	0	8	14
+	0	20	61
+	0	8	14
+	0	20	61
+	0	20	18
+	-1
+
+3	7	14
+	1	1	0
+	0	31	1
+	0	20	19
+	-1
+
+3	7	15
+	1	1	0
+	0	31	1
+	3	2	5
+	0	8	2
+	0	20	11
+	0	20	12
+	0	20	13
+	0	20	2
+	-1
+
+3	7	16
+	1	1	0
+	0	31	1
+	0	20	20
+	-1
+
+3	7	17
+	1	1	0
+	0	31	1
+	0	11	70
+	-1
+
+3	7	18
+	0	8	16
+	1	2	0
+	0	31	1
+	0	8	17
+	3	1	12
+	1	4	0
+	0	31	1
+	0	7	6
+	0	11	1
+	0	11	2
+	0	11	41
+	0	20	9
+	1	1	0
+	0	31	1
+	0	20	1
+	1	1	0
+	0	31	1
+	0	20	19
+	-1
+
+3	7	20
+	3	7	11
+	3	7	14
+	3	7	16
+	-1
+
+3	7	21
+	3	7	11
+	3	7	12
+	3	7	13
+	3	7	14
+	3	7	15
+	3	7	16
+	3	7	17
+	3	7	18
+	3	7	15
+	-1
+
+3	8	1
+	3	1	33
+	3	2	11
+	0	22	42
+	-1
+
+3	8	2
+	3	1	34
+	3	2	11
+	0	22	42
+	-1
+
+3	8	3
+	3	1	35
+	3	2	11
+	0	22	42
+	-1
+
+3	8	4
+	3	1	36
+	3	2	11
+	0	22	42
+	-1
+
+3	8	5
+	3	8	4
+	3	2	24
+	-1
+
+3	8	6
+	0	10	4
+	0	10	61
+	0	10	63
+	0	11	1
+	0	11	2
+	0	12	4
+	0	13	3
+	0	22	42
+	-1
+
+3	8	7
+	3	1	55
+	3	2	11
+	0	7	62
+	0	22	42
+	-1
+
+3	9	1
+	3	1	37
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	2
+	3	1	38
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	3
+	3	1	37
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	4
+	3	1	38
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	5
+	3	1	37
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	6
+	3	1	38
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	7
+	3	1	37
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	8
+	3	1	38
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	11
+	3	1	39
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	12
+	3	1	39
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	13
+	3	1	39
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	14
+	3	1	39
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	15
+	3	1	40
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	16
+	3	1	40
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	17
+	3	1	40
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	18
+	3	1	40
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	19
+	3	1	31
+	0	2	3
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	20
+	3	1	31
+	0	2	3
+	1	4	0
+	0	31	1
+	0	7	3
+	0	11	3
+	0	11	4
+	0	11	5
+	-1
+
+3	10	1
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	26
+	3	3	25
+	-1
+
+3	10	2
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	9
+	3	3	23
+	-1
+
+3	10	3
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	6
+	3	3	23
+	-1
+
+3	10	4
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	3
+	3	3	24
+	-1
+
+3	10	5
+	3	1	42
+	3	3	31
+	3	3	33
+	1	1	0
+	0	31	1
+	3	03	25
+	-1
+
+3	10	6
+	3	1	42
+	3	3	31
+	3	3	33
+	1	1	0
+	0	31	1
+	3	3	23
+	-1
+
+3	10	7
+	3	1	42
+	3	3	31
+	3	3	33
+	1	1	0
+	0	31	1
+	3	3	24
+	-1
+
+3	11	1
+	3	1	51
+	0	7	2
+	0	12	1
+	0	11	1
+	0	11	2
+	0	11	31
+	0	11	32
+	0	11	33
+	0	20	41
+	-1
+
+3	11	2
+	3	1	65
+	3	1	66
+	3	11	3
+	3	11	4
+	-1
+
+3	11	3
+	0	10	70
+	0	11	1
+	0	11	2
+	0	12	1
+	0	13	2
+	-1
+
+3	11	4
+	1	1	0
+	0	31	0
+	0	11	34
+	1	1	0
+	0	31	0
+	0	11	35
+	1	1	0
+	0	31	0
+	0	11	75
+	1	1	0
+	0	31	0
+	0	11	76
+	1	1	0
+	0	31	0
+	0	33	25
+	1	1	0
+	0	31	0
+	0	33	26
+	-1
+
+3	12	1
+	3	1	43
+	3	4	1
+	-1
+
+3	12	2
+	3	1	43
+	3	4	2
+	-1
+
+3	12	3
+	3	1	42
+	3	4	3
+	-1
+
+3	12	4
+	3	1	42
+	3	4	4
+	-1
+
+3	12	5
+	3	1	42
+	0	20	14
+	-1
+
+3	12	6
+	3	1	44
+	3	4	5
+	-1
+
+3	12	7
+	3	1	42
+	3	4	6
+	-1
+
+3	12	10
+	0	1	7
+	0	5	40
+	0	2	21
+	0	5	41
+	0	4	1
+	0	4	43
+	-1
+
+3	12	11
+	2	2	131
+	2	1	149
+	0	4	6
+	2	1	0
+	1	2	32
+	0	10	2
+	2	2	0
+	0	5	43
+	0	5	53
+	-1
+
+3	12	12
+	2	2	129
+	2	1	132
+	1	1	19
+	0	12	63
+	2	1	0
+	2	2	0
+	-1
+
+3	12	13
+	0	5	42
+	2	2	129
+	2	1	135
+	0	12	63
+	2	1	0
+	2	2	0
+	-1
+
+3	12	14
+	3	12	10
+	3	12	11
+	1	5	56
+	3	1	23
+	0	5	42
+	0	5	52
+	3	12	12
+	3	12	13
+	-1
+
+3	12	15
+	1	9	11
+	3	1	23
+	0	5	42
+	0	5	52
+	2	2	129
+	2	1	132
+	1	1	4
+	0	12	63
+	2	2	0
+	2	1	0
+	-1
+
+3	12	16
+	3	12	10
+	3	12	11
+	3	12	15
+	-1
+
+3	12	17
+	1	9	8
+	3	1	23
+	0	5	42
+	0	5	52
+	2	2	129
+	2	1	132
+	1	1	3
+	0	12	63
+	2	2	0
+	2	1	0
+	-1
+
+3	12	18
+	3	12	10
+	3	12	11
+	3	12	17
+	-1
+
+3	12	20
+	3	1	47
+	3	1	48
+	0	15	15
+	0	29	2
+	0	21	76
+	1	4	12
+	0	6	30
+	1	2	12
+	0	5	30
+	0	21	75
+	0	21	66
+	-1
+
+3	12	21
+	3	1	47
+	1	1	3
+	3	1	49
+	0	11	12
+	0	11	11
+	0	21	67
+	-1
+
+3	12	22
+	3	1	47
+	0	8	22
+	0	11	12
+	0	11	50
+	0	22	70
+	0	22	26
+	3	12	41
+	0	10	50
+	0	21	68
+	0	21	71
+	0	21	72
+	0	21	73
+	3	12	42
+	0	21	62
+	0	15	11
+	-1
+
+3	12	23
+	3	1	47
+	1	3	3
+	0	8	22
+	0	12	61
+	0	22	50
+	0	21	69
+	0	21	85
+	-1
+
+3	12	24
+	3	12	20
+	0	8	60
+	0	8	22
+	0	8	60
+	0	8	22
+	0	25	14
+	0	22	101
+	0	22	97
+	0	22	98
+	0	22	99
+	0	22	100
+
+3	12	41
+	2	1	141
+	2	2	130
+	0	7	1
+	2	1	00
+	2	2	00
+	-1
+
+3	12	42
+	0	21	77
+	0	21	78
+	0	21	79
+	0	21	80
+	0	21	81
+	0	21	82
+	-1
+
+3	13	9
+	0	21	1
+	1	1	0
+	0	31	1
+	0	21	1
+	-1
+
+3	13	10
+	0	21	36
+	1	1	0
+	0	31	1
+	0	21	36
+	-1
+
+3	13	31
+	0	6	2
+	0	6	12
+	1	1	0
+	0	31	2
+	0	30	1
+	-1
+
+3	13	32
+	0	5	2
+	0	5	12
+	1	1	0
+	0	31	2
+	3	13	31
+	-1
+
+3	13	41
+	0	6	2
+	1	10	0
+	0	31	1
+	1	4	0
+	0	31	1
+	0	6	12
+	1	1	0
+	0	31	12
+	0	30	1
+	0	6	12
+	1	1	0
+	0	31	1
+	0	30	1
+	-1
+
+3	13	42
+	0	5	2
+	0	5	12
+	1	1	0
+	0	31	2
+	3	13	41
+	-1
+
+3	13	43
+	0	6	2
+	0	5	2
+	0	5	12
+	1	12	0
+	0	31	1
+	1	10	0
+	0	31	1
+	1	04	0
+	0	31	1
+	0	6	12
+	1	1	0
+	0	31	11
+	0	30	1
+	1	1	0
+	0	31	1
+	0	30	1
+	-1
+	
+3	15	1
+	0	1	11
+	3	1	11
+	3	1	12
+	3	1	23
+	3	6	1
+	-1
+
+3	15	2
+	0	1	11
+	3	1	11
+	3	1	12
+	3	1	23
+	3	6	4
+	-1
+
+3	16	1
+	3	1	11
+	0	4	4
+	3	1	23
+	0	1	21
+	0	2	41
+	0	19	1
+	0	10	51
+	0	19	2
+	0	19	3
+	0	19	4
+	-1
+
+3	16	2
+	0	8	21
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	4	5
+	0	1	33
+	0	8	21
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	4	5
+	0	7	2
+	0	7	2
+	-1
+
+3	16	3
+	1	10	0
+	0	31	1
+	0	8	11
+	0	8	7
+	1	4	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	10	2
+	0	11	2
+	0	8	7
+	0	8	11
+	-1
+
+3	16	4
+	1	11	0
+	0	31	1
+	0	8	11
+	0	8	7
+	0	7	2
+	0	7	2
+	1	2	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	11	31
+	0	8	7
+	0	8	11
+	-1
+
+3	16	5
+	1	8	0
+	0	31	1
+	0	8	5
+	0	8	7
+	0	5	2
+	0	6	2
+	0	1	26
+	0	19	1
+	0	8	7
+	0	8	5
+	-1
+
+3	16	6
+	1	12	0
+	0	31	1
+	0	8	11
+	0	8	7
+	0	7	2
+	0	7	2
+	1	2	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	20	11
+	0	20	12
+	0	8	7
+	0	8	11
+	-1
+
+3	16	7
+	1	10	0
+	0	31	1
+	0	8	11
+	0	8	7
+	1	4	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	19	5
+	0	19	6
+	0	8	7
+	0	8	11
+	-1
+
+3	16	8
+	1	11	0
+	0	31	1
+	0	8	1
+	0	8	7
+	0	8	23
+	1	3	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	10	2
+	0	8	23
+	0	8	7
+	0	8	1
+	-1
+
+3	16	9
+	1	11	0
+	0	31	1
+	0	8	11
+	0	8	7
+	0	7	2
+	0	7	2
+	1	2	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	20	41
+	0	8	7
+	0	8	11
+	-1
+
+3	16	10
+	1	7	0
+	0	31	1
+	0	8	11
+	0	8	7
+	0	1	22
+	0	5	2
+	0	6	2
+	0	8	7
+	0	8	11
+	-1
+
+3	16	11
+	1	16	0
+	0	31	1
+	0	8	11
+	0	1	22
+	0	8	7
+	0	1	2
+	0	31	1
+	0	5	2
+	0	6	2
+	0	8	21
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	4	5
+	0	20	90
+	0	8	21
+	0	8	7
+	0	8	11
+	-1
+
+3	18	1
+	3	1	25
+	0	24	11
+	-1
+
+3	18	3
+	3	1	26
+	0	24	5
+	0	24	4
+	0	24	21
+	-1
+
+3	18	4
+	3	1	25
+	0	4	23
+	0	13	11
+	0	24	5
+	0	24	4
+	0	24	22
+	-1
+
+3	21	1
+	0	2	101
+	0	2	114
+	0	2	105
+	0	2	106
+	0	2	107
+	0	2	121
+	-1
+
+3	21	3
+	0	21	51
+	0	21	14
+	0	21	17
+	0	21	30
+	-1
+
+3	21	4
+	3	1	31
+	0	2	3
+	1	1	0
+	0	31	1
+	3	21	3
+	-1
+
+3	21	5
+	0	25	4
+	0	2	121
+	0	2	122
+	0	2	123
+	0	2	124
+	0	2	125
+	0	2	126
+	0	2	127
+	0	2	128
+	0	2	129
+	0	2	130
+	0	2	131
+	-1
+
+3	21	6
+	0	25	1
+	0	25	2
+	0	25	3
+	0	25	5
+	-1
+
+3	21	7
+	0	25	9
+	0	25	10
+	0	25	11
+	0	25	12
+	0	25	13
+	0	25	15
+	0	25	16
+	0	25	17
+	-1
+
+3	21	8
+	0	25	6
+	0	25	7
+	0	25	8
+	-1
+
+3	21	9
+	0	25	18
+	0	25	19
+	-1
+
+3	21	10
+	0	2	101
+	0	7	2
+	0	2	102
+	0	2	103
+	0	2	104
+	0	2	105
+	0	2	106
+	0	2	107
+	0	2	108
+	0	2	109
+	0	2	110
+	0	2	132
+	0	2	133
+	-1
+
+3	21	11
+	0	30	31
+	0	30	32
+	0	29	2
+	-1
+
+3	21	12
+	1	1	0
+	0	31	1
+	0	2	135
+	0	2	135
+	-1
diff --git a/data/tables/B3M-000-006-0 b/data/tables/B3M-000-006-0
new file mode 100644
index 0000000..e4045cc
--- /dev/null
+++ b/data/tables/B3M-000-006-0
@@ -0,0 +1,308 @@
+##############################################################################
+# BUFR Table 0
+#
+#
+# Notes
+# -----
+#
+# * This table comes from GRIB Code Table 0 (Identification of center)
+#
+# * A value of 1 in the first column indicates a center that uses minor
+#   version numbers with local tables.  Since minor local table version
+#   numbers are stored in Section 1, Octet 18, the value in the first
+#   column must not be set if a center uses Section 1, Octet 18 for other
+#   purposes (i.e., ECMWF).
+#
+#
+##############################################################################
+
+0	  0	RESERVED
+
+# 1-9: WMCs
+
+0	  1	Melbourne
+0	  2	Melbourne
+0	  3	Melbourne
+0	  4	Moscow
+0	  5	Moscow
+0	  6	Moscow
+0	  7	US Weather Service - National Meteorological Center (NMC)
+0	  8	US National Weather Service Telecommunications Gateway (NWSTG)
+0	  9	Reserved for USA
+
+# 10-25: Centers in Region I
+
+0	 10	Cairo (RSMC/RAFC)
+0	 11	Cairo (RSMC/RAFC)
+0	 12	Dakar (RSMC/RAFC)
+0	 13	Dakar (RSMC/RAFC)
+0	 14	Nairobi (RSMC/RAFC)
+0	 15	Nairobi (RSMC/RAFC)
+0	 16	Antananarivo (RSMC)
+0	 17	Antananarivo (RSMC)
+0	 18	Tunis-Casablanca (RSMC/RAFC)
+0	 19	Tunis-Casablanca (RSMC/RAFC)
+0	 20	Las Palmas (RAFC)
+0	 21	Algiers (RSMC)
+0	 22	Lagos (RSMC)
+0	 23	Lagos (RSMC)
+0	 24	Reserved for other centers in Region I
+0	 25	Reserved for other centers in Region I
+
+# 26-40 Centers in Region II
+
+0	 26	Khabarovsk (RSMC)
+0	 27	Khabarovsk (RSMC)
+0	 28	New Delhi (RSMC/RAFC)
+0	 29	New Delhi (RSMC/RAFC)
+0	 30	Novosibirsk (RSMC)
+0	 31	Novosibirsk (RSMC)
+0	 32	Tashkent (RSMC)
+0	 33	Tashkent (RSMC)
+0	 34	Tokyo (RSMC), Japan Meteorological Agency
+0	 35	Tokyo (RSMC/RAFC)
+0	 36	Bangkok (RAFC)
+0	 37	Ulan Bator
+0	 38	Beijing (RSMC)
+0	 39	Beijing (RSMC)
+0	 40	Reserved for other centers in Region II
+
+# 41-50: Centers in Region III
+
+0	 41	Buenos Aires (RSMC/RAFC)
+0	 42	Buenos Aires (RSMC/RAFC)
+0	 43	Brasilia (RSMC/RAFC)
+0	 44	Brasilia (RSMC/RAFC)
+0	 45	Santiago
+0	 46	Brazilian Space Agency - INPE
+0	 47	Reserved for other centers in Region III
+0	 48	Reserved for other centers in Region III
+0	 49	Reserved for other centers in Region III
+0	 50	Reserved for other centers in Region III
+
+# 51-63: Centers in Region IV
+
+0	 51	Miami (RSMC/RAFC)
+0	 52	Miami (RSMC), National Hurricane Center
+0	 53	Montreal (RSMC)
+0	 54	Montreal (RSMC)
+0	 55	San Francisco
+0	 56	RESERVED
+0	 57	US Air Force - Air Force Global Weather Central (AFGWC)
+1	 58	Fleet Numerical Oceanography Center (FNOC), Monterey, CA, USA
+0	 59	The NOAA Forecast Systems Laboratory, Boulder, CO, USA
+0	 60	Reserved for other centers in Region IV
+0	 61	Reserved for other centers in Region IV
+0	 62	Reserved for other centers in Region IV
+0	 63	Reserved for other centers in Region IV
+
+# 64-73: Centers in Region V
+
+0	 64	Honolulu (RAFC)
+0	 65	Darwin (RSMC/RAFC)
+0	 66	Darwin (RSMC/RAFC)
+0	 67	Melbourne (RSMC)
+0	 68	RESERVED
+0	 69	Wellington (RSMC/RAFC)
+0	 70	Wellington (RSMC/RAFC)
+0	 71	Reserved for other centers in Region V
+0	 72	Reserved for other centers in Region V
+0	 73	Reserved for other centers in Region V
+
+# 74-98: Centers in Region VI
+
+0	 74	UK Meteorological Office - Bracknell
+0	 75	UK Meteorological Office - Bracknell
+0	 76	Moscow (RSMC/RAFC)
+0	 77	RESERVED
+0	 78	Offenbach (RSMC)
+0	 79	Offenbach (RSMC)
+0	 80	Rome (RSMC/RAFC)
+0	 81	Rome (RSMC/RAFC)
+0	 82	Norrkoping (RSMC)
+0	 83	Norrkoping (RSMC)
+0	 84	Paris (RAFC)
+0	 85	Toulouse
+0	 86	Helsinki
+0	 87	Belgrade
+0	 88	Oslo
+0	 89	Prague
+0	 90	Episkopi
+0	 91	Ankara
+0	 92	Francfort/Main (RAFC)
+0	 93	London (WAFC)
+0	 94	Copenhagen
+0	 95	Rota
+0	 96	Athens
+0	 97	European Space Agency (ESA)
+
+# ECMWF (Center 98) does not support minor local table version numbers
+# so DO NOT set the first value to 1.
+
+0	 98	European Center for Medium Range Weather Forecasts (ECMWF)(RSMC)
+0	 99	De Bilt
+
+# 100-127: RESERVED
+
+0	100	RESERVED
+0	101	RESERVED
+0	102	RESERVED
+0	103	RESERVED
+0	104	RESERVED
+0	105	RESERVED
+0	106	RESERVED
+0	107	RESERVED
+0	108	RESERVED
+0	109	RESERVED
+0	110	RESERVED
+0	111	RESERVED
+0	112	RESERVED
+0	113	RESERVED
+0	114	RESERVED
+0	115	RESERVED
+0	116	RESERVED
+0	117	RESERVED
+0	118	RESERVED
+0	119	RESERVED
+0	120	RESERVED
+0	121	RESERVED
+0	122	RESERVED
+0	123	RESERVED
+0	124	RESERVED
+0	125	RESERVED
+0	126	RESERVED
+0	127	RESERVED
+
+# 128-254: NATIONAL USE
+
+1	128	Naval Research Laboratory (NRL), Monterey CA
+0	129	CAST
+0	130	AFCCC
+0	131	PL
+0	132	ARL
+0	133	WES
+0	134	NATIONAL USE
+0	135	NATIONAL USE
+0	136	NATIONAL USE
+0	137	NATIONAL USE
+0	138	NATIONAL USE
+0	139	NATIONAL USE
+0	140	NATIONAL USE
+0	141	NATIONAL USE
+0	142	NATIONAL USE
+0	143	NATIONAL USE
+0	144	NATIONAL USE
+0	145	NATIONAL USE
+0	146	NATIONAL USE
+0	147	NATIONAL USE
+0	148	NATIONAL USE
+0	149	NATIONAL USE
+0	150	NATIONAL USE
+0	151	NATIONAL USE
+0	152	NATIONAL USE
+0	153	NATIONAL USE
+0	154	NATIONAL USE
+0	155	NATIONAL USE
+0	156	NATIONAL USE
+0	157	NATIONAL USE
+0	158	NATIONAL USE
+0	159	NATIONAL USE
+0	160	NATIONAL USE
+0	161	NATIONAL USE
+0	162	NATIONAL USE
+0	163	NATIONAL USE
+0	164	NATIONAL USE
+0	165	NATIONAL USE
+0	166	NATIONAL USE
+0	167	NATIONAL USE
+0	168	NATIONAL USE
+0	169	NATIONAL USE
+0	170	NATIONAL USE
+0	171	NATIONAL USE
+0	172	NATIONAL USE
+0	173	NATIONAL USE
+0	174	NATIONAL USE
+0	175	NATIONAL USE
+0	176	NATIONAL USE
+0	177	NATIONAL USE
+0	178	NATIONAL USE
+0	179	NATIONAL USE
+0	180	NATIONAL USE
+0	181	NATIONAL USE
+0	182	NATIONAL USE
+0	183	NATIONAL USE
+0	184	NATIONAL USE
+0	185	NATIONAL USE
+0	186	NATIONAL USE
+0	187	NATIONAL USE
+0	188	NATIONAL USE
+0	189	NATIONAL USE
+0	190	NATIONAL USE
+0	191	NATIONAL USE
+0	192	NATIONAL USE
+0	193	NATIONAL USE
+0	194	NATIONAL USE
+0	195	NATIONAL USE
+0	196	NATIONAL USE
+0	197	NATIONAL USE
+0	198	NATIONAL USE
+0	199	NATIONAL USE
+0	200	NATIONAL USE
+0	201	NATIONAL USE
+0	202	NATIONAL USE
+0	203	NATIONAL USE
+0	204	NATIONAL USE
+0	205	NATIONAL USE
+0	206	NATIONAL USE
+0	207	NATIONAL USE
+0	208	NATIONAL USE
+0	209	NATIONAL USE
+0	210	NATIONAL USE
+0	211	NATIONAL USE
+0	212	NATIONAL USE
+0	213	NATIONAL USE
+0	214	NATIONAL USE
+0	215	NATIONAL USE
+0	216	NATIONAL USE
+0	217	NATIONAL USE
+0	218	NATIONAL USE
+0	219	NATIONAL USE
+0	220	NATIONAL USE
+0	221	NATIONAL USE
+0	222	NATIONAL USE
+0	223	NATIONAL USE
+0	224	NATIONAL USE
+0	225	NATIONAL USE
+0	226	NATIONAL USE
+0	227	NATIONAL USE
+0	228	NATIONAL USE
+0	229	NATIONAL USE
+0	230	NATIONAL USE
+0	231	NATIONAL USE
+0	232	NATIONAL USE
+0	233	NATIONAL USE
+0	234	NATIONAL USE
+0	235	NATIONAL USE
+0	236	NATIONAL USE
+0	237	NATIONAL USE
+0	238	NATIONAL USE
+0	239	NATIONAL USE
+0	240	NATIONAL USE
+0	241	NATIONAL USE
+0	242	NATIONAL USE
+0	243	NATIONAL USE
+0	244	NATIONAL USE
+0	245	NATIONAL USE
+0	246	NATIONAL USE
+0	247	NATIONAL USE
+0	248	NATIONAL USE
+0	249	NATIONAL USE
+0	250	NATIONAL USE
+0	251	NATIONAL USE
+0	252	NATIONAL USE
+0	253	NATIONAL USE
+0	254	NATIONAL USE
+
+# 255: Used to indicate missing or unknown center
+
+0	255	MISSING VALUE
diff --git a/data/tables/B3M-000-006-A b/data/tables/B3M-000-006-A
new file mode 100644
index 0000000..5a7f993
--- /dev/null
+++ b/data/tables/B3M-000-006-A
@@ -0,0 +1,259 @@
+#
+# BUFR Table A - Data Category
+#
+  0	Surface data - land
+  1	Surface data - sea
+  2	Vertical soundings (other than satellite)
+  3	Vertical soundings (satellite)
+  4	Single level upper-air data (other than satellite)
+  5	Single level upper-air data (satellite)
+  6	Radar data
+  7	Synoptic features
+  8	Physical/chemical constituents
+  9	Dispersal and transport
+ 10	Radiological data
+ 11	BUFR tables, complete replacement or update
+ 12	Surface data (satellite)
+ 13	RESERVED
+ 14	RESERVED
+ 15	RESERVED
+ 16	RESERVED
+ 17	RESERVED
+ 18	RESERVED
+ 19	RESERVED
+ 20	Status information
+ 21	Radiances (satellite measured)
+ 22	RESERVED
+ 23	RESERVED
+ 24	RESERVED
+ 25	RESERVED
+ 26	RESERVED
+ 27	RESERVED
+ 28	RESERVED
+ 29	RESERVED
+ 30	RESERVED
+ 31	Oceanographic data
+ 32	RESERVED
+ 33	RESERVED
+ 34	RESERVED
+ 35	RESERVED
+ 36	RESERVED
+ 37	RESERVED
+ 38	RESERVED
+ 39	RESERVED
+ 40	RESERVED
+ 41	RESERVED
+ 42	RESERVED
+ 43	RESERVED
+ 44	RESERVED
+ 45	RESERVED
+ 46	RESERVED
+ 47	RESERVED
+ 48	RESERVED
+ 49	RESERVED
+ 50	RESERVED
+ 51	RESERVED
+ 52	RESERVED
+ 53	RESERVED
+ 54	RESERVED
+ 55	RESERVED
+ 56	RESERVED
+ 57	RESERVED
+ 58	RESERVED
+ 59	RESERVED
+ 60	RESERVED
+ 61	RESERVED
+ 62	RESERVED
+ 63	RESERVED
+ 64	RESERVED
+ 65	RESERVED
+ 66	RESERVED
+ 67	RESERVED
+ 68	RESERVED
+ 69	RESERVED
+ 70	RESERVED
+ 71	RESERVED
+ 72	RESERVED
+ 73	RESERVED
+ 74	RESERVED
+ 75	RESERVED
+ 76	RESERVED
+ 77	RESERVED
+ 78	RESERVED
+ 79	RESERVED
+ 80	RESERVED
+ 81	RESERVED
+ 82	RESERVED
+ 83	RESERVED
+ 84	RESERVED
+ 85	RESERVED
+ 86	RESERVED
+ 87	RESERVED
+ 88	RESERVED
+ 89	RESERVED
+ 90	RESERVED
+ 91	RESERVED
+ 92	RESERVED
+ 93	RESERVED
+ 94	RESERVED
+ 95	RESERVED
+ 96	RESERVED
+ 97	RESERVED
+ 98	RESERVED
+ 99	RESERVED
+100	RESERVED
+101	Image data
+102	RESERVED
+103	RESERVED
+104	RESERVED
+105	RESERVED
+106	RESERVED
+107	RESERVED
+108	RESERVED
+109	RESERVED
+110	RESERVED
+111	RESERVED
+112	RESERVED
+113	RESERVED
+114	RESERVED
+115	RESERVED
+116	RESERVED
+117	RESERVED
+118	RESERVED
+119	RESERVED
+120	RESERVED
+121	RESERVED
+122	RESERVED
+123	RESERVED
+124	RESERVED
+125	RESERVED
+126	RESERVED
+127	RESERVED
+128	RESERVED
+129	RESERVED
+130	RESERVED
+131	RESERVED
+132	RESERVED
+133	RESERVED
+134	RESERVED
+135	RESERVED
+136	RESERVED
+137	RESERVED
+138	RESERVED
+139	RESERVED
+140	RESERVED
+141	RESERVED
+142	RESERVED
+143	RESERVED
+144	RESERVED
+145	RESERVED
+146	RESERVED
+147	RESERVED
+148	RESERVED
+149	RESERVED
+150	RESERVED
+151	RESERVED
+152	RESERVED
+153	RESERVED
+154	RESERVED
+155	RESERVED
+156	RESERVED
+157	RESERVED
+158	RESERVED
+159	RESERVED
+160	RESERVED
+161	RESERVED
+162	RESERVED
+163	RESERVED
+164	RESERVED
+165	RESERVED
+166	RESERVED
+167	RESERVED
+168	RESERVED
+169	RESERVED
+170	RESERVED
+171	RESERVED
+172	RESERVED
+173	RESERVED
+174	RESERVED
+175	RESERVED
+176	RESERVED
+177	RESERVED
+178	RESERVED
+179	RESERVED
+180	RESERVED
+181	RESERVED
+182	RESERVED
+183	RESERVED
+184	RESERVED
+185	RESERVED
+186	RESERVED
+187	RESERVED
+188	RESERVED
+189	RESERVED
+190	RESERVED
+191	RESERVED
+192	RESERVED
+193	RESERVED
+194	RESERVED
+195	RESERVED
+196	RESERVED
+197	RESERVED
+198	RESERVED
+199	RESERVED
+200	RESERVED
+201	RESERVED
+202	RESERVED
+203	RESERVED
+204	RESERVED
+205	RESERVED
+206	RESERVED
+207	RESERVED
+208	RESERVED
+209	RESERVED
+210	RESERVED
+211	RESERVED
+212	RESERVED
+213	RESERVED
+214	RESERVED
+215	RESERVED
+216	RESERVED
+217	RESERVED
+218	RESERVED
+219	RESERVED
+220	RESERVED
+221	RESERVED
+222	RESERVED
+223	RESERVED
+224	RESERVED
+225	RESERVED
+226	RESERVED
+227	RESERVED
+228	RESERVED
+229	RESERVED
+230	RESERVED
+231	RESERVED
+232	RESERVED
+233	RESERVED
+234	RESERVED
+235	RESERVED
+236	RESERVED
+237	RESERVED
+238	RESERVED
+239	RESERVED
+240	FOR EXPERIMENTAL USE
+241	FOR EXPERIMENTAL USE
+242	FOR EXPERIMENTAL USE
+243	FOR EXPERIMENTAL USE
+244	FOR EXPERIMENTAL USE
+245	FOR EXPERIMENTAL USE
+246	FOR EXPERIMENTAL USE
+247	FOR EXPERIMENTAL USE
+248	FOR EXPERIMENTAL USE
+249	FOR EXPERIMENTAL USE
+250	FOR EXPERIMENTAL USE
+251	FOR EXPERIMENTAL USE
+252	FOR EXPERIMENTAL USE
+253	FOR EXPERIMENTAL USE
+254	FOR EXPERIMENTAL USE
+255	Indicator for local use, with sub-category
diff --git a/data/tables/B3M-000-006-B b/data/tables/B3M-000-006-B
new file mode 100644
index 0000000..785bfa4
--- /dev/null
+++ b/data/tables/B3M-000-006-B
@@ -0,0 +1,648 @@
+#
+# BUFR Table B - Classification of Elements
+#
+#					Data
+#F	X	Y	Scale	RefVal	Width	Units	Element Name
+  0;    0;      1;      0;           0;   24;    CCITT_IA5; Table A: entry
+  0;    0;      2;      0;           0;  256;    CCITT_IA5; Table A: data category description, line 1
+  0;    0;      3;      0;           0;  256;    CCITT_IA5; Table A: data category description, line 2
+  0;    0;      5;      0;           0;   24;    CCITT_IA5; BUFR edition number
+  0;    0;     10;      0;           0;    8;    CCITT_IA5; F descriptor to be added or defined
+  0;    0;     11;      0;           0;   16;    CCITT_IA5; X descriptor to be added or defined
+  0;    0;     12;      0;           0;   24;    CCITT_IA5; Y descriptor to be added or defined
+  0;    0;     13;      0;           0;  256;    CCITT_IA5; Element name, line 1
+  0;    0;     14;      0;           0;  256;    CCITT_IA5; Element name, line 2
+  0;    0;     15;      0;           0;  192;    CCITT_IA5; Units name
+  0;    0;     16;      0;           0;    8;    CCITT_IA5; Units scale sign
+  0;    0;     17;      0;           0;   24;    CCITT_IA5; Units scale
+  0;    0;     18;      0;           0;    8;    CCITT_IA5; Units reference sign
+  0;    0;     19;      0;           0;   80;    CCITT_IA5; Units reference value
+  0;    0;     20;      0;           0;   24;    CCITT_IA5; Element data width
+  0;    0;     30;      0;           0;   48;    CCITT_IA5; Descriptor defining sequence
+  0;    1;      1;      0;           0;    7;      Numeric; WMO block number
+  0;    1;      2;      0;           0;   10;      Numeric; WMO station number
+  0;    1;      3;      0;           0;    3;   Code_Table; WMO region number
+  0;    1;      4;      0;           0;    3;      Numeric; WMO region sub-area
+  0;    1;      5;      0;           0;   17;      Numeric; Buoy/platform identifier
+  0;    1;      6;      0;           0;   64;    CCITT_IA5; Aircraft identifier (flight number)
+  0;    1;      7;      0;           0;   10;   Code_Table; Satellite identifier
+  0;    1;      8;      0;           0;   64;    CCITT_IA5; Aircraft registration number (tail number)
+  0;    1;      9;      0;           0;   64;    CCITT_IA5; Type of commerical aircraft
+  0;    1;     10;      0;           0;   64;    CCITT_IA5; Stationary buoy platform identifier
+  0;    1;     11;      0;           0;   72;    CCITT_IA5; Ship or mobile land station identifier
+  0;    1;     12;      0;           0;    9;     deg_true; Direction of motion of moving observing platform
+  0;    1;     13;      0;           0;   10;          m/s; Speed of motion of moving observing platform
+  0;    1;     14;      2;           0;   10;          m/s; Platform drift speed (high precision)
+  0;    1;     15;      0;           0;  160;    CCITT_IA5; Station or site name
+  0;    1;     20;      0;           0;    4;      Numeric; WMO Region sub-area
+  0;    1;     21;      0;           0;   14;      Numeric; Synoptic feature identifier
+  0;    1;     22;      0;           0;  224;    CCITT_IA5; Name of feature
+  0;    1;     25;      0;           0;   24;    CCITT_IA5; Storm identifier
+  0;    1;     26;      0;           0;   64;    CCITT_IA5; WMO storm name
+  0;    1;     31;      0;           0;   16;   Code_Table; Identification of originating/generating center
+  0;    1;     32;      0;           0;    8;   Code_Table; Generating application
+  0;    1;     33;      0;           0;    8;   Code_Table; Identification of originating/generating center
+  0;    1;     34;      0;           0;    8;   Code_Table; Identification of originating/generating sub-center
+  0;    1;     41;      5; -1073741824;   31;          m/s; Absolute platform velocity - first component
+  0;    1;     42;      5; -1073741824;   31;          m/s; Absolute platform velocity - second component
+  0;    1;     43;      5; -1073741824;   31;          m/s; Absolute platform velocity - third component
+  0;    1;     60;      0;           0;   64;    CCITT_IA5; Aircraft reporting point (Beacon identifier)
+  0;    1;     63;      0;           0;   64;    CCITT_IA5; ICAO location indicator
+  0;    1;     64;      0;           0;   32;    CCITT_IA5; Runway designator
+  0;    1;     75;      0;           0;   40;    CCITT_IA5; Ride station identification
+  0;    2;      1;      0;           0;    2;   Code_Table; Type of station
+  0;    2;      2;      0;           0;    4;   Flag_Table; Type of instrumentation for wind measurement
+  0;    2;      3;      0;           0;    4;   Code_Table; Type of measuring instrumentation used
+  0;    2;      4;      0;           0;    4;   Code_Table; Type of instrumentation for evaporation measurement or type of crop for which evapotranspiration is reported
+  0;    2;      5;      2;           0;    7;        deg_K; Precision of temperature observed
+  0;    2;     11;      0;           0;    8;   Code_Table; Radiosonde type
+  0;    2;     12;      0;           0;    4;   Code_Table; Radiosonde computational method
+  0;    2;     13;      0;           0;    4;   Code_Table; Solar and infrared radiation correction
+  0;    2;     14;      0;           0;    7;   Code_Table; Tracking technique/status of system
+  0;    2;     15;      0;           0;    4;   Code_Table; Radiosonde completeness
+  0;    2;     20;      0;           0;    9;   Code_Table; Satellite classification
+  0;    2;     21;      0;           0;    9;   Flag_Table; Satellite instrumentation data used in processing
+  0;    2;     22;      0;           0;    8;   Flag_Table; Satellite data processing technique used
+  0;    2;     23;      0;           0;    4;   Code_Table; Satellite derived wind computation method
+  0;    2;     24;      0;           0;    4;   Code_Table; Integrated mean humidity computational method
+  0;    2;     25;      0;           0;   25;   Flag_Table; Satellite channel(s) used in computation
+  0;    2;     26;      2;           0;   12;            m; Cross track resolution
+  0;    2;     27;      2;           0;   12;            m; Along track resolution
+  0;    2;     28;      0;           0;   18;            m; Segment size at nadir in X direction
+  0;    2;     29;      0;           0;   18;            m; Segment size at nadir in Y direction
+  0;    2;     30;      0;           0;    3;   Code_Table; Method of current measurement
+  0;    2;     31;      0;           0;    5;   Code_Table; Duration and time of current measurement
+  0;    2;     32;      0;           0;    2;   Code_Table; Indicator for digitization
+  0;    2;     33;      0;           0;    3;   Code_Table; Method of salinity/depth measurement
+  0;    2;     34;      0;           0;    5;   Code_Table; Drogue type
+  0;    2;     35;      0;           0;    9;            m; Cable length
+  0;    2;     36;      0;           0;    2;   Code_Table; Buoy type
+  0;    2;     37;      0;           0;    3;   Code_Table; Method of tidal observation
+  0;    2;     38;      0;           0;    4;   Code_Table; Method of sea-surface temperature measurement
+  0;    2;     39;      0;           0;    3;   Code_Table; Method of wet-buld temperature measurement
+  0;    2;     40;      0;           0;    4;   Code_Table; Method of removing velocity and motion of platform from current
+  0;    2;     41;      0;           0;    6;   Code_Table; Method for estimating reports related to synoptic features
+  0;    2;     44;      0;           0;    4;   Code_Table; Inicator for method of calculating spectral wave data
+  0;    2;     45;      0;           0;    4;   Code_Table; Indicator for type of platform
+  0;    2;     46;      0;           0;    4;   Code_Table; Wave measurement instrumentation
+  0;    2;     48;      0;           0;    4;   Code_Table; Satellite sensor indicator
+  0;    2;     49;      0;           0;    8;   Flag_Table; Geostationary satellite data-processing technique used
+  0;    2;     50;      0;           0;   20;   Flag_Table; Geostationary sounder satellite channels used
+  0;    2;     51;      0;           0;    4;   Code_Table; Indicator ro specify observing method for extreme temperatures
+  0;    2;     52;      0;           0;    6;   Flag_Table; Geostationary imager satellite channels used
+  0;    2;     53;      0;           0;    4;   Code_Table; GOES-I/M  brightness temperature characteristics
+  0;    2;     54;      0;           0;    4;   Code_Table; GOES-I/M  soundings parameter characteristics
+  0;    2;     55;      0;           0;    4;   Code_Table; Geostationary soundings statistical parameters
+  0;    2;     56;      0;           0;    4;   Code_Table; Geostationary soundings accuracy statistics
+  0;    2;     57;      0;           0;    4;   Code_Table; Origin of first guess information for GOES-I/M soundings
+  0;    2;     58;      0;           0;    4;   Code_Table; Valid times of first guess information for GOES-I/M soundings
+  0;    2;     59;      0;           0;    4;   Code_Table; Origin of analysis information for GOES-I/M soundings
+  0;    2;     60;      0;           0;    4;   Code_Table; Origin of surface information for GOES-I/M soundings
+  0;    2;     61;      0;           0;    3;   Code_Table; Aircraft navigation system
+  0;    2;     62;      0;           0;    4;   Code_Table; Type of aircraft data relay system
+  0;    2;     63;      2;      -18000;   16;          deg; Aircraft roll angle
+  0;    2;     64;      0;           0;    2;   Code_Table; Aircraft roll angle quality
+  0;    2;     65;      0;           0;   40;    CCITT_IA5; ACARS ground receiving station
+  0;    2;     70;      0;           0;    4;   Code_Table; Original specification of latitude/longitude
+  0;    2;    100;      1;           0;   12;           dB; Radar constant
+  0;    2;    101;      0;           0;    4;   Code_Table; Type of antenna
+  0;    2;    102;      0;           0;    8;            m; Antenna height above tower
+  0;    2;    103;      0;           0;    2;   Flag_Table; Radome
+  0;    2;    104;      0;           0;    4;   Code_Table; Antenna polarisation
+  0;    2;    105;      0;           0;    6;           dB; Maximum antenna gain
+  0;    2;    106;      1;           0;    6;          deg; 3-dB bandwidth
+  0;    2;    107;      0;           0;    6;           dB; Sidelobe suppression
+  0;    2;    108;      0;           0;    6;           dB; Crosspol discrimination (on axis)
+  0;    2;    109;      2;           0;   12;        deg/s; Antenna speed (azimuth)
+  0;    2;    110;      2;           0;   12;        deg/s; Antenna speed (elevation)
+  0;    2;    111;      1;           0;   10;          deg; Radar incidence angle
+  0;    2;    112;      1;           0;   12;          deg; Radar azimuth angle
+  0;    2;    113;      0;           0;    4;      Numeric; Number of azimuth looks
+  0;    2;    114;      0;           0;   15;         m**2; Antenna effective surface area
+  0;    2;    121;     -8;           0;    7;           Hz; Mean frequency
+  0;    2;    122;     -6;        -128;    8;           Hz; Frequency agility range
+  0;    2;    123;     -4;           0;    7;            W; Peak power
+  0;    2;    124;     -1;           0;    7;            W; Average power
+  0;    2;    125;     -1;           0;    8;           Hz; Pulse repetition frequency
+  0;    2;    126;      7;           0;    6;            s; Pulse width
+  0;    2;    127;     -6;           0;    7;           Hz; Receiver intermediate frequency
+  0;    2;    128;     -5;           0;    6;           Hz; Intermediate frequency bandwidth
+  0;    2;    129;      0;        -150;    5;           dB; Minimum detectable signal
+  0;    2;    130;      0;           0;    7;           dB; Dynamic range
+  0;    2;    131;      0;           0;    2;   Flag_Table; Sensitivity time control
+  0;    2;    132;      2;           0;    6;          deg; Azimuth pointing accuracy
+  0;    2;    133;      2;           0;    6;          deg; Elevation pointing accuracy
+  0;    2;    134;      2;           0;   16;          deg; Antenna beam azimuth
+  0;    2;    135;      2;       -9000;   15;          deg; Antenna elevation
+  0;    2;    136;     -3;           0;   16;            m; Range processed by range attenuation correction
+  0;    2;    140;      0;           0;    9;          deg; Satellite radar beam azimuth
+  0;    2;    141;      0;           0;   24;    CCITT_IA5; Measurement type
+  0;    2;    142;      0;           0;   32;    CCITT_IA5; Ozone instrument serial number/identification
+  0;    2;    143;      0;           0;    7;   Code_Table; Ozone instrument type
+  0;    2;    144;      0;           0;    4;   Code_Table; Light source type for Brewer spectrophotometer
+  0;    2;    145;      0;           0;    4;   Code_Table; Wave length setting for Dobson instruments
+  0;    2;    146;      0;           0;    4;   Code_Table; Source conditions for Dobson instruments
+  0;    2;    150;      0;           0;    6;   Code_Table; TOVS/ATOVS/AVHRR instrumentation channel number
+  0;    2;    151;      0;           0;    4;   Code_Table; Radiometer identifier
+  0;    2;    152;      0;           0;   31;   Flag_Table; Satellite instrument used in data processing
+  0;    2;    153;     -8;           0;   26;           Hz; Satellite channel center frequency
+  0;    2;    154;     -8;           0;   26;           Hz; Satellite channel band width
+  0;    2;    163;      0;           0;    4;   Code_Table; Height assignment method
+  0;    2;    164;      0;           0;    3;   Code_Table; Tracer correlation method
+  0;    2;    166;      0;           0;    4;   Code_Table; Radiance type
+  0;    2;    167;      0;           0;    4;   Code_Table; Radiance computational method
+  0;    4;      1;      0;           0;   12;         Year; Year
+  0;    4;      2;      0;           0;    4;           mo; Month
+  0;    4;      3;      0;           0;    6;          Day; Day
+  0;    4;      4;      0;           0;    5;           hr; Hour
+  0;    4;      5;      0;           0;    6;          min; Minute
+  0;    4;      6;      0;           0;    6;            s; Second
+  0;    4;     11;      0;       -1024;   11;         Year; Time increment
+  0;    4;     12;      0;       -1024;   11;           mo; Time increment
+  0;    4;     13;      0;       -1024;   11;         Days; Time increment
+  0;    4;     14;      0;       -1024;   11;           hr; Time increment
+  0;    4;     15;      0;       -2048;   12;          min; Time increment
+  0;    4;     16;      0;       -4096;   13;            s; Time increment
+  0;    4;     21;      0;       -1024;   11;         Year; Time period or displacement
+  0;    4;     22;      0;       -1024;   11;           mo; Time period or displacement
+  0;    4;     23;      0;       -1024;   11;         Days; Time period or displacement
+  0;    4;     24;      0;       -2048;   12;           hr; Time period or displacement
+  0;    4;     25;      0;       -2048;   12;          min; Time period or displacement
+  0;    4;     26;      0;       -4096;   13;            s; Time period or displacement
+  0;    4;     31;      0;           0;    8;           hr; Duration of time relative to following value
+  0;    4;     32;      0;           0;    6;       Minute; Duration of time relating to following value
+  0;    4;     41;      0;       -1440;   12;       Minute; Time Difference, UTC-LMT
+  0;    4;     43;      0;           0;    9;          Day; Day of the year
+  0;    4;     53;      0;           0;    6;      Numeric; Number of days with precipition equal to or more than 1mm
+  0;    4;    192;      0;           0;    3;   Code_Table; Season
+  0;    5;      1;      5;    -9000000;   25;          deg; Latitude (high accuracy)
+  0;    5;      2;      2;       -9000;   15;          deg; Latitude (coarse accuracy)
+  0;    5;     11;      5;    -9000000;   25;          deg; Latitude increment (high accuracy)
+  0;    5;     12;      2;       -9000;   15;          deg; Latitude increment (coarse accuracy)
+  0;    5;     21;      2;           0;   16;     deg_true; Bearing or azimuth
+  0;    5;     22;      2;           0;   16;     deg_true; Solar azimuth
+  0;    5;     30;      0;           0;   12;          deg; Direction (spectral)
+  0;    5;     31;      0;           0;   12;      Numeric; Row number
+  0;    5;     33;     -1;           0;   16;            m; Pixel size on horizontal - 1
+  0;    5;     40;      0;           0;   24;      Numeric; Orbit number
+  0;    5;     41;      0;           0;    8;      Numeric; Scan line number
+  0;    5;     42;      0;           0;    6;      Numeric; Channel number
+  0;    5;     43;      0;           0;    8;      Numeric; Field of view number
+  0;    5;     52;      0;           0;    5;      Numeric; Channel number increment
+  0;    5;     53;      0;           0;    5;      Numeric; Field of view number increment
+  0;    6;      1;      5;   -18000000;   26;          deg; Longitude (high accuracy)
+  0;    6;      2;      2;      -18000;   16;          deg; Longitude (coarse accuracy)
+  0;    6;     11;      5;   -18000000;   26;          deg; Longitude increment (high accuracy)
+  0;    6;     12;      2;      -18000;   16;          deg; Longitude increment (coarse accuracy)
+  0;    6;     21;     -1;           0;   13;            m; Distance
+  0;    6;     30;      5;           0;   13;        rad/m; Wavenumber (spectral)
+  0;    6;     31;      0;           0;   12;      Numeric; Column number
+  0;    6;     33;     -1;           0;   16;            m; Pixel size on horizontal - 2
+  0;    7;      1;      0;        -400;   15;            m; Height of station
+  0;    7;      2;     -1;         -40;   16;            m; Height or altitude
+  0;    7;      3;     -1;        -400;   17;    m**2/s**2; Geopotential
+  0;    7;      4;     -1;           0;   14;           Pa; Pressure
+  0;    7;      5;      0;        -400;   12;            m; Height increment
+  0;    7;      6;      0;           0;   15;            m; Height above station
+  0;    7;      7;      0;       -1000;   17;            m; Height
+  0;    7;      8;      0;      -10000;   20;    m**2/s**2; Geopotential
+  0;    7;     21;      2;       -9000;   15;          deg; Elevation
+  0;    7;     22;      2;       -9000;   15;          deg; Solar elevation
+  0;    7;     24;      2;       -9000;   15;          deg; Satellite zenith angle
+  0;    7;     25;      2;       -9000;   15;          deg; Solar zenith angle
+  0;    7;     61;      2;           0;   14;            m; Depth below land surface
+  0;    7;     62;      1;           0;   17;            m; Depth below sea/water surface
+  0;    8;      1;      0;           0;    7;   Flag_Table; Vertical sounding significance
+  0;    8;      2;      0;           0;    6;   Code_Table; Vertical significance (surface observations)
+  0;    8;      3;      0;           0;    6;   Code_Table; Vertical significance (satellite observations)
+  0;    8;      4;      0;           0;    3;   Code_Table; Phase of aircraft flight
+  0;    8;      5;      0;           0;    4;   Code_Table; Meteorological attribute significance
+  0;    8;      7;      0;           0;    4;   Code_Table; Dimensional significance
+  0;    8;     11;      0;           0;    6;   Code_Table; Meteorological feature
+  0;    8;     12;      0;           0;    2;   Code_Table; land/sea qualifier
+  0;    8;     13;      0;           0;    2;   Code_Table; Day/night qualifier
+  0;    8;     14;      0;           0;    4;   Code_Table; Qualification for runway visual range
+  0;    8;     16;      0;           0;    3;   Code_Table; Change indicator of a trend-type forecast or an aerodrome forecast
+  0;    8;     17;      0;           0;    2;   Code_Table; Qualifier of the time when the forecast change is expected
+  0;    8;     20;      0;           0;   16;      Numeric; Total number of missing entities (with respect to accumulation or average)
+  0;    8;     21;      0;           0;    5;   Code_Table; Time significance
+  0;    8;     22;      0;           0;   16;      Numeric; Total number (with respect to accumulation or average)
+  0;    8;     23;      0;           0;    6;   Code_Table; First order statistics
+  0;    8;     24;      0;           0;    6;   Code_Table; Difference statistics
+  0;    8;     25;      0;           0;    4;   Code_Table; Time difference qualifier
+  0;    8;     30;      0;           0;   13;      Numeric; Manual on Codes
+  0;    8;     51;      0;           0;    3;   Code_Table; Qualifier for number of missing values in calculation of statistic
+  0;    8;     52;      0;           0;    5;   Code_Table; Condition for which number of days of occurance follows
+  0;    8;     53;      0;           0;    2;   Code_Table; Day of occurance qualifier
+  0;    8;     60;      0;           0;    4;   Code_Table; Sample scanning mode significance
+  0;    8;     70;      0;           0;    4;   Code_Table; TOVS/ATOVS product qualifier
+  0;    8;     72;      0;           0;    3;   Code_table; Pixel(s) type
+  0;   10;      1;      0;        -400;   15;            m; Height of land surface
+  0;   10;      2;     -1;         -40;   16;            m; Height
+  0;   10;      3;     -1;        -400;   17;    m**2/s**2; Geopotential
+  0;   10;      4;     -1;           0;   14;           Pa; Pressure
+  0;   10;      7;      0;       -1000;   17;            m; Height
+  0;   10;      8;      0;      -10000;   20;    m**2/s**2; Geopotential
+  0;   10;     31;      2; -1073741824;   31;            m; In direction of the North Pole, distance from the Earth's centre
+  0;   10;     50;      2;           0;   16;            m; Standard deviation altitude
+  0;   10;     51;     -1;           0;   14;           Pa; Pressure reduced to mean sea level
+  0;   10;     52;     -1;           0;   14;           Pa; Altimeter setting (QNH)
+  0;   10;     60;     -1;       -1024;   11;           Pa; Pressure change
+  0;   10;     61;     -1;        -500;   10;           Pa; 3 hour pressure change
+  0;   10;     62;     -1;       -1000;   11;           Pa; 24 hour pressure change
+  0;   10;     63;      0;           0;    4;   Code_Table; Characteristic of pressure tendency
+  0;   10;     70;      0;        -400;   16;            m; Indicated aircraft altitude
+  0;   11;      1;      0;           0;    9;     deg_true; Wind direction
+  0;   11;      2;      1;           0;   12;          m/s; Wind speed
+  0;   11;      3;      1;       -4096;   13;          m/s; U-component
+  0;   11;      4;      1;       -4096;   13;          m/s; V-component
+  0;   11;      5;      1;        -512;   10;         Pa/s; W-component
+  0;   11;      6;      2;       -4096;   13;          m/s; W-component
+  0;   11;     11;      0;           0;    9;     deg_true; Wind direction at 10 m
+  0;   11;     12;      1;           0;   12;          m/s; Wind speed at 10 m
+  0;   11;     13;      0;           0;    9;     deg_true; Wind direction at 5 m
+  0;   11;     14;      1;           0;   12;          m/s; Wind speed at 5 m
+  0;   11;     16;      0;           0;    9;     deg_true; Extreme counterclockwise wind direction of a variable wind
+  0;   11;     17;      0;           0;    9;     deg_true; Extreme clockwise wind direction of a variable wind
+  0;   11;     19;      0;           0;    7;      Percent; Steadiness of wind
+  0;   11;     21;      9;      -65536;   17;          1/s; Relative vorticity
+  0;   11;     22;      9;      -65536;   17;          1/s; Divergence
+  0;   11;     23;     -2;      -65536;   17;       m**2/s; Velocity potential
+  0;   11;     31;      0;           0;    4;   Code_Table; Degree of turbulence
+  0;   11;     32;     -1;         -40;   16;            m; Height of base of turbulence
+  0;   11;     33;     -1;         -40;   16;            m; Height of top of turbulence
+  0;   11;     34;      1;       -1024;   11;          m/s; Vertical gust velocity
+  0;   11;     35;      2;       -8192;   14;       m/s**2; Vertical gust acceleration
+  0;   11;     36;      1;           0;   10;          m/s; Maximum derived equivalent vertical gust speed
+  0;   11;     41;      1;           0;   12;          m/s; Maximum wind speed (gusts)
+  0;   11;     42;      1;           0;   12;          m/s; Maximum wind speed (10 minute mean wind)
+  0;   11;     43;      0;           0;    9;     deg_true; Maximum wind gust direction
+  0;   11;     44;      0;           0;    9;     deg_true; Mean wind direction for surface - 1500m (5000 feet)
+  0;   11;     45;      1;           0;   12;          m/s; Mean wind speed for surface - 1500m (5000 feet)
+  0;   11;     49;      0;           0;    9;     deg_true; Standard deviation of wind direction
+  0;   11;     50;      1;           0;   12;          m/s; Standard deviation horizontal wind speed
+  0;   11;     51;      1;           0;    8;          m/s; Standard deviation vertical wind speed
+  0;   11;     61;      1;           0;   12;          m/s; Absolute wind shear in 1 kilometer layer below
+  0;   11;     62;      1;           0;   12;          m/s; Absolute wind shear in1 kilometer layer above
+  0;   11;     70;      0;           0;   32; CCITT_IA5Designator; of the runway affected by wind shear
+  0;   11;     71;      3;        -128;   14;    m**2/s**2; Turbulent vertical momemtum flux
+  0;   11;     72;      3;        -128;   11;            K; m/s	Turbulent vertical buouancy flux
+  0;   11;     73;      2;       -1024;   13;    m**2/s**2; Turbulent kinetic energy
+  0;   11;     74;      2;       -1024;   10;    m**2/s**2; Dissipation energy
+  0;   11;     75;      2;           0;    8;   m**(2/3)/s; Mean turbulence intensity
+  0;   11;     76;      2;           0;    8;   m**(2/3)/s; Peak turbulence intensity
+  0;   12;      1;      1;           0;   12;        deg_K; Temperature/dry bulb temperature
+  0;   12;      2;      1;           0;   12;        deg_K; Wet bulb temperature
+  0;   12;      3;      1;           0;   12;        deg_K; Dewpoint temperature
+  0;   12;      4;      1;           0;   12;        deg_K; Dry bulb temperature at 2 meters
+  0;   12;      5;      1;           0;   12;        deg_K; Wet bulb temperature at 2 meters
+  0;   12;      6;      1;           0;   12;        deg_K; Dewpoint temperature at 2 meters
+  0;   12;      7;      1;           0;   12;        deg_K; Virtual temperature
+  0;   12;     11;      1;           0;   12;        deg_K; Maximum temperature
+  0;   12;     12;      1;           0;   12;        deg_K; Minimum temperature
+  0;   12;     13;      1;           0;   12;        deg_K; Ground minimum temperature past 12 hours
+  0;   12;     14;      1;           0;   12;        deg_K; Maximum temperature at 2 meters, past 12 hours
+  0;   12;     15;      1;           0;   12;        deg_K; Minimum temperature at 2 meters, past 12 hours
+  0;   12;     16;      1;           0;   12;        deg_K; Maximum temperature at 2 meters, past 24 hours
+  0;   12;     17;      1;           0;   12;        deg_K; Minimum temperature at 2 meters, past 24 hours
+  0;   12;     30;      1;           0;   12;        deg_K; Soil temperature
+  0;   12;     51;      1;           0;   10;        deg_K; Standard deviation of temperature
+  0;   12;     52;      1;           0;   12;        deg_K; Highest daily mean temperature
+  0;   12;     53;      1;           0;   12;        deg_K; Lowest daily mean temperature
+  0;   12;     61;      1;           0;   12;        deg_K; Skin temperature
+  0;   12;     62;      1;           0;   12;        deg_K; Equivalent black body temperature
+  0;   12;     63;      1;           0;   12;        deg_K; Brightness temperature
+  0;   12;     64;      1;           0;   12;        deg_K; Instrument temperature
+  0;   12;     71;      1;           0;   12;        deg_K; Coldest cluster temperature
+  0;   12;     72;      6;           0;   31;    W/m**2/sr; Radiance
+  0;   13;      1;      5;           0;   14;        kg/kg; Specific humidity
+  0;   13;      2;      5;           0;   14;        kg/kg; Mixing ratio
+  0;   13;      3;      0;           0;    7;      percent; Relative humidity
+  0;   13;      4;     -1;           0;   10;           Pa; Vapor pressure
+  0;   13;      5;      3;           0;    7;      kg/m**3; Vapor density
+  0;   13;      6;     -1;         -40;   16;            m; Mixing heights
+  0;   13;     11;      1;          -1;   14;      kg/m**2; Total precipitation/total water equivalent
+  0;   13;     12;      2;          -2;   12;            m; Depth of fresh snow
+  0;   13;     13;      2;          -2;   16;            m; Total snow depth
+  0;   13;     14;      4;           0;   12;    kg/m**2/s; Rainfall/water equivalent of snow (average rate)
+  0;   13;     15;      7;           0;   12;          m/s; Snowfall (averaged rate)
+  0;   13;     16;      0;           0;    7;      kg/m**2; Precipitable water
+  0;   13;     19;      1;          -1;   14;      kg/m**2; Total precipitation past 1 hour
+  0;   13;     20;      1;          -1;   14;      kg/m**2; Total precipitation past 3 hours
+  0;   13;     21;      1;          -1;   14;      kg/m**2; Total precipitation past 6 hours
+  0;   13;     22;      1;          -1;   14;      kg/m**2; Total precipitation past 12 hours
+  0;   13;     23;      1;          -1;   14;      kg/m**2; Total precipitation past 24 hours
+  0;   13;     31;      0;           0;    7;      kg/m**2; Evapotranspiration
+  0;   13;     32;      1;           0;    8;      kg/m**2; Evaporation/evapotranspiration
+  0;   13;     33;      1;           0;   10;      kg/m**2; Evaporation/evapotranspiration
+  0;   13;     38;      0;           0;    2;   Code_Table; Superadiabatic indicator
+  0;   13;     39;      0;           0;    3;   Code_Table; Terrain type (ice/snow)
+  0;   13;     41;      0;           0;    4;   Code_Table; Pasquill-Gifford stability category
+  0;   13;     42;      0;         -20;    6;        deg_K; Parcel lifted index (to 500 hPa)
+  0;   13;     43;      0;         -20;    6;        deg_K; Best lifted index (to 500 hPa)
+  0;   13;     51;      0;           0;    4;   Code_Table; Frequency group, precipition
+  0;   13;     52;      1;          -1;   14;      kg/m**2; Highest daily amount of precipition
+  0;   14;      1;     -3;       -2048;   12;  Joules/m**2; Longwave radiation, integrated over 24 hours
+  0;   14;      2;     -3;       -2048;   12;  Joules/m**2; Longwave radiation, integrated over period specified
+  0;   14;      3;     -3;       -2048;   12;  Joules/m**2; Shortwave radiation, integrated over 24 hours
+  0;   14;      4;     -3;       -2048;   12;  Joules/m**2; Shortwave radiation, integrated over period specified
+  0;   14;     11;     -3;       -2048;   12;  Joules/m**2; Net longwave radiation, integrated over 24 hours
+  0;   14;     12;     -3;       -2048;   12;  Joules/m**2; Net longwave radiation, integrated over period specified
+  0;   14;     13;     -3;       -2048;   12;  Joules/m**2; Net shortwave radiation, integrated over 24 hours
+  0;   14;     14;     -3;       -2048;   12;  Joules/m**2; Net shortwave radiation, integrated over period specified
+  0;   14;     15;     -4;      -16384;   15;  Joules/m**2; Net radiation, integrated over 24 hours
+  0;   14;     16;     -4;      -16384;   15;  Joules/m**2; Net radiation, integrated over period specified
+  0;   14;     17;     -3;       -2048;   12;       W/m**2; Instantaneous long wave radiation
+  0;   14;     18;     -3;       -2048;   12;       W/m**2; Instantaneous short wave radiation
+  0;   14;     19;      0;           0;    7;      percent; Surface albedo
+  0;   14;     20;     -4;           0;   15;  Joules/m**2; Global solar radiation, integrated over 24 hours
+  0;   14;     21;     -4;           0;   15;  Joules/m**2; Global radiation, integrated over period specified
+  0;   14;     22;     -4;           0;   15;  Joules/m**2; Diffuse solar radiation, integrated over 24 hours
+  0;   14;     23;     -4;           0;   15;  Joules/m**2; Diffuse solar radiation, integratedi over period specified
+  0;   14;     24;     -4;           0;   15;  Joules/m**2; Direct solar radiation, integrated over 24 hours
+  0;   14;     25;     -4;           0;   15;  Joules/m**2; Direct solar radiation, integrated over period specified
+  0;   14;     26;      0;           0;    7;      percent; Albedo at the top of clouds
+  0;   14;     27;      0;           0;    7;      percent; Albedo
+  0;   14;     31;      0;           0;   11;          min; Total sunshine
+  0;   14;     32;      0;           0;   10;           hr; Total sunshine
+  0;   14;     33;      0;           0;    9;      percent; Total sunshine
+  0;   14;     42;      0;           0;    7;      percent; Bi-directional reflectance
+  0;   14;     45;      0;           0;   11; W/m**2/sr/cm; Channel radiance
+  0;   15;      1;      0;           0;   10;       Dobson; units	Ozone
+  0;   15;      2;      2;           0;   10;      Numeric; Air mass (slant path at 22km)
+  0;   15;     11;      3;       14000;   13;  log(1/m**2); Log 10 of integrated electron density
+  0;   15;     15;      0;           0;   31;      Numeric; Maximum image spectral composition before normalization
+  0;   19;      1;      0;           0;    6;   Code_Table; Type of synoptic features
+  0;   19;      2;     -2;           0;   12;            m; Effective radius of feature
+  0;   19;      3;      0;           0;    8;          m/s; Wind speed threshold
+  0;   19;      4;     -2;           0;   12;            m; Effective radius of feature with respect to wind speeds above threshold
+  0;   19;      5;      0;           0;    9;     deg_true; Direction of motion of features
+  0;   19;      6;      2;           0;   14;          m/s; Speed of motion of features
+  0;   19;      7;     -3;           0;   12;            m; Effective radius of features
+  0;   19;      8;      0;           0;    3;   Code_Table; Vertical extent of circulation
+  0;   19;      9;     -3;           0;   12;            m; Effective radius with respect to wind speed above threshold (large storms)
+  0;   20;      1;     -1;           0;   13;            m; Horizontal visibility
+  0;   20;      2;     -1;           0;    7;            m; Vertical visibility
+  0;   20;      3;      0;           0;    9;   Code_Table; Present weather
+  0;   20;      4;      0;           0;    5;   Code_Table; Past weather (1)
+  0;   20;      5;      0;           0;    5;   Code_Table; Past weather (2)
+  0;   20;      8;      0;           0;    5;   Code_Table; Cloud distribution for aviation
+  0;   20;      9;      0;           0;    4;   Code_Table; General Weather Indicator
+  0;   20;     10;      0;           0;    7;      percent; Cloud cover (total)
+  0;   20;     11;      0;           0;    4;   Code_Table; Cloud amount
+  0;   20;     12;      0;           0;    6;   Code_Table; Cloud type
+  0;   20;     13;     -1;         -40;   11;            m; Height of base of cloud
+  0;   20;     14;     -1;         -40;   11;            m; Height of top of cloud
+  0;   20;     15;     -1;           0;   14;           Pa; Pressure at the base of cloud
+  0;   20;     16;     -1;           0;   14;           Pa; Pressure at the top of cloud
+  0;   20;     17;      0;           0;    4;   Code_Table; Cloud top description
+  0;   20;     18;      0;           0;    2;   Code_Table; Tendency of runway visual range
+  0;   20;     19;      0;           0;   72;    CCITT_IA5; Significant present or forecast weather
+  0;   20;     20;      0;           0;   32;    CCITT_IA5; Significant recent weather phenomena
+  0;   20;     31;      2;           0;    7;            m; Ice deposit (thickness)
+  0;   20;     32;      0;           0;    3;   Code_Table; Rate of ice accretion
+  0;   20;     33;      0;           0;    4;   Flag_Table; Cause of ice accretion
+  0;   20;     34;      0;           0;    5;   Code_Table; Sea ice concentration
+  0;   20;     35;      0;           0;    4;   Code_Table; Amount and type of ice
+  0;   20;     36;      0;           0;    5;   Code_Table; Ice situation
+  0;   20;     37;      0;           0;    5;   Code_Table; Ice development
+  0;   20;     38;      0;           0;   12;     deg_true; Bearing of ice edge
+  0;   20;     39;     -1;           0;   13;            m; Ice distance
+  0;   20;     41;      0;           0;    4;   Code_Table; Airframe icing
+  0;   20;     51;      0;           0;    7;      percent; Amount of low clouds
+  0;   20;     52;      0;           0;    7;      percent; Amount of middle clouds
+  0;   20;     53;      0;           0;    7;      percent; Amount of high clouds
+  0;   20;     61;      0;           0;   12;            m; Runway visual range (RVR)
+  0;   20;     62;      0;           0;    5;   Code_Table; State of the ground(with or without snow)
+  0;   20;     63;      0;           0;   10;   Code_Table; Special phenomena
+  0;   20;     81;      0;           0;    7;      percent; Cloud amount in segment
+  0;   20;     82;      0;           0;    7;      percent; Amount segment cloud free
+  0;   20;     90;      0;           0;    4;   Code_Table; Special clouds
+  0;   21;      1;      0;         -64;    7;           dB; Horizontal reflectivity
+  0;   21;      2;      0;         -64;    7;           dB; Vertical reflectivity
+  0;   21;      3;      1;          -5;    7;           dB; Differential reflectivity
+  0;   21;      5;      0;         -65;    6;           dB; Linear depolarization ratio
+  0;   21;      6;      0;         -65;    6;           dB; Circular depolarization ratio
+  0;   21;     11;      0;        -128;    8;          m/s; Doppler mean velocity in X direction
+  0;   21;     12;      0;        -128;    8;          m/s; Doppler mean velocity in Y direction
+  0;   21;     13;      0;        -128;    8;          m/s; Doppler mean velocity in Z direction
+  0;   21;     14;      1;       -4096;   13;          m/s; Doppler mean velocity (radiational)
+  0;   21;     17;      1;           0;    8;          m/s; Doppler velocity spectral width
+  0;   21;     21;     -3;           0;    4;            m; Echo tops
+  0;   21;     30;      0;         -32;    8;           dB; Signal to noise ratio
+  0;   21;     31;      0;           0;    7;      kg/m**2; Vertical integrated liquid water content
+  0;   21;     36;      7;           0;   12;          m/s; Radar rainfall intensity
+  0;   21;     41;     -2;           0;    8;            m; Bright band height
+  0;   21;     51;      0;        -256;    8;           dB; Signal power above 1 MW
+  0;   21;     62;      2;       -5000;   13;     Decibels; Backscatter
+  0;   21;     63;      1;           0;   10;      Percent; Radiometric resolution (noise value)
+  0;   21;     64;      0;           0;    8;      Numeric; Clutter noise estimate
+  0;   21;     65;      0;        -127;    8;      Numeric; Missing packet counter
+  0;   21;     66;      0;           0;   12;   Flag_Table; Wave scatterometer product confidence
+  0;   21;     67;      0;           0;   13;   Flag_Table; Wind product confidence data
+  0;   21;     68;      0;           0;    8;   Flag_Table; Radar altimeter product confidence data
+  0;   21;     69;      0;           0;   10;   Flag_Table; SST product confidence data
+  0;   21;     71;      0;           0;   16;      Numeric; Peakiness
+  0;   21;     72;      0;           0;    4;   Flag_Table; Satellite altimeter calibration status
+  0;   21;     73;      0;           0;    9;   Flag_Table; Satellite altimeter instrument mode
+  0;   21;     75;      0;           0;    8;      Numeric; Spectral intensity
+  0;   21;     76;      0;           0;    3;   Code_Table; Representation of intensities
+  0;   21;     77;      3;           0;   14;            m; Altitude correction (ionosphere)
+  0;   21;     78;      3;           0;    9;            m; Altitude correction (dry troposphere)
+  0;   21;     79;      3;        2000;   10;            m; Altitude correction (wet troposphere)
+  0;   21;     80;      3;           0;   11;            m; Altitude correction (calibration constant)
+  0;   21;     81;      3;           0;   10;            m; Open loop correction (height-time loop)
+  0;   21;     82;      3;       -3000;   14;     Decibels; Open loop correction (auto gain control)
+  0;   21;     85;      0;       -3000;    4;      Numeric; ATSR sea surface temperature across-track band number
+  0;   22;      1;      0;           0;    9;     deg_true; Direction of waves
+  0;   22;      2;      0;           0;    9;     deg_true; Direction of wind waves
+  0;   22;      3;      0;           0;    9;     deg_true; Direction of swell waves
+  0;   22;      4;      0;           0;    9;     deg_true; Direction of current waves
+  0;   22;     11;      0;           0;    6;            s; Period of waves
+  0;   22;     12;      0;           0;    6;            s; Period of wind waves
+  0;   22;     13;      0;           0;    6;            s; Period of swell waves
+  0;   22;     21;      1;           0;   10;            m; Height of waves
+  0;   22;     22;      1;           0;   10;            m; Height of wind waves
+  0;   22;     23;      1;           0;   10;            m; Height of swell waves
+  0;   22;     25;      2;           0;   10;            m; Standard deviation wave height
+  0;   22;     26;      2;           0;   10;            m; Standard deviation of significant wave height
+  0;   22;     31;      2;           0;   13;          m/s; Speed of current
+  0;   22;     37;      3;      -10000;   15;            m; Tidal elevation with respect to national chart datum
+  0;   22;     38;      3;      -10000;   15;            m; Tidal elevation with respect to local chart datum
+  0;   22;     39;      3;       -5000;   12;            m; Meteorological residual tidal elevation (surge or offset)
+  0;   22;     40;      3;       -5000;   14;            m; Meteorological residual tidal elevation (surge or offset)
+  0;   22;     41;      1;           0;   12;        deg_K; Sea surface temperature (15 day running mean)
+  0;   22;     42;      1;           0;   12;        deg_K; Sea/water temperature
+  0;   22;     43;      2;           0;   15;        deg_K; Sea/water temperature
+  0;   22;     44;      1;           0;   14;          m/s; Sound velocity
+  0;   22;     50;      2;           0;    8;            K; Standard deviation sea surface temperature
+  0;   22;     61;      0;           0;    4;   Code_Table; State of sea
+  0;   22;     62;      2;           0;   14;          ppt; Salinity
+  0;   22;     63;      0;           0;   14;            m; Total water depth
+  0;   22;     67;      0;           0;   10;   Code_Table; Instrument type for water temperature profile measurement
+  0;   22;     68;      0;           0;    7;   Code_Table; Water temperature profile recorder types
+  0;   22;     70;      2;           0;   13;            m; Significant wave height
+  0;   22;     71;      1;           0;    9;            s; Spectral peak wave period
+  0;   22;     72;      0;           0;   13;            m; Spectral peak wave length
+  0;   22;     73;      2;           0;   13;            m; Maximum wave height
+  0;   22;     74;      1;           0;    9;            s; Average wave period
+  0;   22;     75;      0;           0;   13;            m; Average wave length
+  0;   22;     76;      0;           0;    9;  Degree_True; Direction from which dominant waves are coming
+  0;   22;     77;      0;           0;    9;       Degree; Directional spred of dominant wave
+  0;   22;     78;      0;           0;   12;            s; Duration of wave record
+  0;   22;     79;      0;           0;   16;            m; Length of wave record
+  0;   22;     80;      3;           0;   10;           Hz; Waveband central frequency
+  0;   22;     81;      5;           0;   13;        m**-1; Waveband central wave number
+  0;   22;     82;      2;           0;   20;       m**2/s; Maximum non-directional spectral wave density
+  0;   22;     83;      2;           0;   20;         m**3; Maximum non-directional spectral wave number
+  0;   22;     84;      0;           0;    7;      Numeric; Band containing maximum non-directional spectral wave density
+  0;   22;     85;      0;           0;    7;      Numeric; Spectral wave density ratio
+  0;   22;     86;      0;           0;    9;  Degree_True; Mean direction from which waves are coming
+  0;   22;     87;      0;           0;    9;  Degree_True; Principal direction from which waves are coming
+  0;   22;     88;      2;           0;    7;      Numeric; First normalized polar coordinate from Fourier coefficients
+  0;   22;     89;      2;           0;    7;      Numeric; Second normalized polar coordinate from Fourier coefficients
+  0;   22;     90;      2;           0;   20;       m**2/s; Non-directional spectral estimate by wave frequency
+  0;   22;     91;      2;           0;   20;         m**3; Non-directional spectral estimate by wave number
+  0;   22;     92;      2;           0;   20; m**2/rad**-1/s; Directional spectral estimate by wave frequency
+  0;   22;     93;      2;           0;   20;         m**4; Directional spectral estimate by wave number
+  0;   22;     94;      0;           0;    7;      Numeric; Total number of wave bands
+  0;   22;     95;      0;           0;    8;       Degree; Directional spread of individual waves
+  0;   22;     96;      3;           0;    4;        s**-1; Spectral band width
+  0;   22;     97;      0;           0;   14;            m; Mean wavelength > 731 m of image spectrum at low wave numbers
+  0;   22;     98;      0;           0;   14;            m; Wavelength spread (wavelength > 731 m) at low wave numbers
+  0;   22;     99;      0;           0;    9;     deg_true; Mean direction at low wave numbers (wavelength > 731 m)
+  0;   22;    100;      0;           0;    9;       Degree; Direction spread at low wave numbers (wavelength > 731 m)
+  0;   22;    101;      0;           0;   31;     Numberic; Total energy (wavelength > 731 m) at low wave numbers
+  0;   22;    120;      0;           0;    5;   Code_Table; Tide station automated water level check
+  0;   22;    121;      0;           0;    5;   Code_Table; Tide station manual water level check
+  0;   22;    122;      0;           0;    5;   Code_Table; Tide station automated Meteorological data check
+  0;   22;    123;      0;           0;    5;   Code_Table; Tide station manual Meteorological data check
+  0;   23;      1;      0;           0;    3;   Code_Table; Accident early notification - article applicable
+  0;   23;      2;      0;           0;    5;   Code_Table; Activity or facility involved in incident
+  0;   23;      3;      0;           0;    3;   Code_Table; Type of release
+  0;   23;      4;      0;           0;    3;   Code_Table; Countermeasures taken near border
+  0;   23;      5;      0;           0;    2;   Code_Table; Cause of incident
+  0;   23;      6;      0;           0;    3;   Code_Table; Incident situation
+  0;   23;      7;      0;           0;    3;   Code_Table; Characteristic of release
+  0;   23;      8;      0;           0;    2;   Code_Table; State of current release
+  0;   23;      9;      0;           0;    2;   Code_Table; State of expected release
+  0;   23;     16;      0;           0;    2;   Code_Table; Possibility of significant chemical toxic health effect
+  0;   23;     17;      6;           0;   20;       m**3/s; Flow discharge of major recipient
+  0;   23;     18;      0;           0;    3;   Code_Table; release behavior over time
+  0;   23;     19;      0;      -15000;   17;            m; Actual release height
+  0;   23;     21;      0;      -15000;   17;            m; Effective release height
+  0;   23;     22;      0;           0;   24;            m; Distance of relative point or site of incident
+  0;   23;     23;      1;           0;   12;          m/s; Main transport speed in atmosphere
+  0;   23;     24;      2;           0;   13;          m/s; Main transport speed in water
+  0;   23;     25;      2;           0;   13;          m/s; Main transport speed in ground water
+  0;   23;     27;      0;           0;    9;     deg_true; Main transport direction in atmosphere
+  0;   23;     28;      0;           0;    9;     deg_true; Main transport direction in water
+  0;   23;     29;      0;           0;    9;     deg_true; Main transport direction in ground water
+  0;   23;     31;      0;           0;    2;   Code_Table; Possibility that plume will encounter precipitation cwin state in which incident occurred
+  0;   23;     32;      0;           0;    2;   Code_Table; Plume will encounter ichange in wind direction and/or speed flag
+  0;   24;      1;    -11;           0;   28;           Bq; Estimate of radiatioactivity released up to specified time
+  0;   24;      2;    -11;           0;   28;           Bq; Estimated maximum potential release
+  0;   24;      3;      0;           0;    5;   Code_Table; Composition of release
+  0;   24;      4;      0;           0;   16;    CCITT_IA5; Element name
+  0;   24;      5;      0;           0;    9;      Numeric; Isotope mass
+  0;   24;     11;      2;           0;   32;          mSv; Dose
+  0;   24;     12;      2;           0;   32;          mSv; Trajectory dose (defined location and expected time of arrival)
+  0;   24;     13;      2;           0;   32;          mSv; Gamma dose in air along the main transport path (defined location and time period
+  0;   24;     21;      2;           0;   32;      Bq/m**3; Air concentration (named isotope type including gross beta)
+  0;   24;     22;      2;           0;   32;         Bq/l; Concentration in precipitation (of named isotope type)
+  0;   25;      1;     -1;           0;    6;            m; Range gate length
+  0;   25;      2;      0;           0;    4;      Numeric; Number of gates averaged
+  0;   25;      3;      0;           0;    8;      Numeric; Number of integrated pulses
+  0;   25;      4;      0;           0;    2;   Code_Table; Echo processing
+  0;   25;      5;      0;           0;    2;   Code_Table; Echo integration
+  0;   25;      6;      0;           0;    3;   Code_Table; Z to R conversion
+  0;   25;      7;      0;           0;   12;      Numeric; Z to R conversion factor
+  0;   25;      8;      2;           0;    9;      Numeric; Z to R conversion exponent
+  0;   25;      9;      0;           0;    4;   Flag_Table; Calibration method
+  0;   25;     10;      0;           0;    4;   Code_Table; Clutter treatment
+  0;   25;     11;      0;           0;    2;   Code_Table; Ground occultation correction (screening)
+  0;   25;     12;      0;           0;    2;   Code_Table; Range attenuation correction
+  0;   25;     13;      0;           0;    2;   Flag_Table; Bright band correction
+  0;   25;     14;      0;           0;   12;      Numeric; Azimuth clutter cut-off
+  0;   25;     15;      0;           0;    2;   Flag_Table; Radome attenuation correction
+  0;   25;     16;      5;           0;    6;         dB/m; Clear air attenuation correction
+  0;   25;     17;      0;           0;    2;   Flag_Table; Precipitation attenuation correction
+  0;   25;     18;      7;           0;    6;      Numeric; A to Z law for attenuation factor
+  0;   25;     19;      2;           0;    7;      Numeric; A to Z law for attenuation exponent
+  0;   25;     20;      0;           0;    2;   Code_Table; Mean speed estimation
+  0;   25;     21;      0;           0;    8;   Flag_Table; Wind computation enhancement
+  0;   25;     30;      0;           0;    2;   Code_Table; SST usage
+  0;   25;     32;      0;           0;    2;   Code_Table; NOAA wind profiler high/low mode data
+  0;   25;     33;      0;           0;    2;   Code_Table; NOAA wind profiler submode
+  0;   25;     34;      0;           0;    4;   Code_Table; NOAA wind profiler Q/C test results
+  0;   25;     40;      0;           0;    4;   Code_Table; CO2 wind product derivation
+  0;   25;     41;      0;           0;    2;   Code_Table; Moving platform direction reporting method
+  0;   25;     42;      0;           0;    2;   Code_Table; Moving platform speed reporting method
+  0;   25;     43;      4;           0;   15;            s; Wave sampling interval (time)
+  0;   25;     44;      2;           0;   14;            m; Wave sampling interval (space)
+  0;   25;     45;      0;           0;   21;   Flag_Table; HIRS channel combination
+  0;   25;     46;      0;           0;    5;   Flag_Table; MSU channel combination
+  0;   25;     47;      0;           0;    4;   Flag_Table; SSU channel combination
+  0;   25;     48;      0;           0;   16;   Flag_Table; AMSU-A channel combination
+  0;   25;     49;      0;           0;    6;   Flag_Table; AMSU-B channel combination
+  0;   25;     50;      0;           0;    7;   Flag_Table; AVHRR channel combination
+  0;   25;     51;      0;           0;   12;   Flag_Table; Observation quality
+  0;   25;     53;      0;           0;   12;   Flag_Table; Observation quality
+  0;   25;     60;      0;           0;   14;      Numeric; Software identification
+  0;   25;     70;      0;           0;    4;      Numeric; Major frame count
+  0;   25;     71;      0;           0;    5;      Numeric; Frame count
+  0;   25;     75;      0;           0;    5;      Numeric; Satellite antenna corrections version number
+  0;   25;     76;      8;           0;   30;        Log/m; Log-10 of (Temperature-radiance central wavenumber) for ATOVS
+  0;   25;     77;      5;     -100000;   18;      Numeric; Bandwidth correction coefficient 1 for ATOVS
+  0;   25;     78;      5;           0;   17;      Numeric; Bandwidth correction coefficient 2 for ATOVS
+  0;   25;     79;      4;           0;   24;       W/m**2; Albedo-radiance solar filtered irradiance for ATOVS
+  0;   25;     80;     10;           0;   14;            m; Albedo-radiance equivalent filter width for ATOVS
+  0;   25;     85;      0;           0;    7;      Numeric; Fraction of clear pixels in HIRS FOV
+  0;   26;      1;      1;           0;   12;         Hour; Principal time of daily reading in UTC of maximum temperature
+  0;   26;      2;      1;           0;   12;         Hour; Principal time of daily reading in UTC of minimum temperature
+  0;   26;      3;      0;       -1440;   12;       Minute; Time difference
+  0;   26;     10;      0;           0;   26;   Flag_Table; Hours included
+  0;   27;      1;      5;    -9000000;   25;          deg; Latitude (high accuracy)
+  0;   27;      2;      2;       -9000;   15;          deg; Latitude (coarse accuracy)
+  0;   27;      3;      2;       -9000;   15;          deg; Alternate latitude
+  0;   27;     20;      0;           0;   16;      Numeric; Satellite locationon counter
+  0;   27;     21;      0;           0;   16;      Numeric; Satellite sub-locationon dimensions
+  0;   27;     31;      2; -1073741824;   31;            m; In direction of 0 degrees longitude, distance from the Earth's centre
+  0;   28;      1;      5;   -18000000;   26;          deg; Longitude (high accuracy)
+  0;   28;      2;      2;      -18000;   16;          deg; Longitude (coarse accuracy)
+  0;   28;      3;      2;      -18000;   16;          deg; Alternate longtiude
+  0;   28;     31;      2; -1073741824;   31;            m; In direction of 90 degrees East, distance from the Earth's centre
+  0;   29;      1;      0;           0;    3;   Code_Table; Projection type
+  0;   29;      2;      0;           0;    3;   Code_Table; Coordinate grid type
+  0;   30;      1;      0;           0;    4;      Numeric; Pixel value (4 bits)
+  0;   30;      2;      0;           0;    8;      Numeric; Pixel value (8 bits)
+  0;   30;      4;      0;           0;   16;      Numeric; Pixel value (16 bits)
+  0;   30;     21;      0;           0;   12;      Numeric; Number of pixels per row
+  0;   30;     22;      0;           0;   12;      Numeric; Number of pixels per column
+  0;   30;     31;      0;           0;    4;   Code_Table; Picture type
+  0;   30;     32;      0;           0;   16;   Flag_Table; Combined picture
+  0;   31;      0;      0;           0;    1;      Numeric; Short delayed descriptor replication factor
+  0;   31;      1;      0;           0;    8;      Numeric; Delayed descriptor replication factor
+  0;   31;      2;      0;           0;   16;      Numeric; Extended delayed descriptor replication factor
+  0;   31;     11;      0;           0;    8;      Numeric; Delayed descriptor and data repetion factor
+  0;   31;     12;      0;           0;   16;      Numeric; Extended delayed descriptor and data repitition factor
+  0;   31;     21;      0;           0;    6;   Code_Table; Associated field significance
+  0;   31;     31;      0;           0;    1;   Flag_Table; Data present indicator
+  0;   33;      2;      0;           0;    2;   Code_Table; Quality information
+  0;   33;      3;      0;           0;    3;   Code_Table; Quality information
+  0;   33;      7;      0;           0;    7;      Percent; Per cent confidence
+  0;   33;     20;      0;           0;    3;   Code_Table; Quality control indication of following value
+  0;   33;     21;      0;           0;    2;   Code_Table; Quality of following value
+  0;   33;     22;      0;           0;    2;   Code_Table; Quality of buoy satellite transmission
+  0;   33;     23;      0;           0;    2;   Code_Table; Quality of buoy location
+  0;   33;     24;      0;           0;    4;   Code_Table; Station elevation quality mark (for mobile stations)
+  0;   33;     25;      0;           0;    3;   Code_Table; ACARS interpolated values
+  0;   33;     26;      0;           0;    6;   Code_Table; Mixing ratio quality
+  0;   33;     27;      0;           0;    3;   Code_Table; Location quality class (range of radius of 66% confidence)
+  0;   33;     30;      0;           0;   24;   Flag_Table; Scan line status flags for ATOVS
+  0;   33;     31;      0;           0;   24;   Flag_Table; Scan line quality flags for ATOVS
+  0;   33;     32;      0;           0;   24;   Flag_Table; Channel quality flags for ATOVS
+  0;   33;     33;      0;           0;   24;   Flag_Table; Field of view quality flags for ATOVS
+  0;   33;     35;      0;           0;    4;   Code_Table; Manual/automatic quality control
+  0;   33;     36;      0;           0;    7;      Percent; Nominal confidence threshold
+  0;   33;     37;      0;           0;   20;   Flag_Table; Wind correlation error
diff --git a/data/tables/B3M-000-006-D b/data/tables/B3M-000-006-D
new file mode 100644
index 0000000..8e21b9a
--- /dev/null
+++ b/data/tables/B3M-000-006-D
@@ -0,0 +1,2001 @@
+#
+# BUFR Table D (Lists of Common Sequences)
+#
+# Descriptor sequences are terminated with -1
+#
+# Sequences do not need to appear in any order.  Sequence A
+# which includes sequence B, may appear before sequence B
+# is defined.
+#
+3	0	2
+	0	0	2
+	0	0	3
+	-1
+
+3	0	3
+	0	0	10
+	0	0	11
+	0	0	12
+	-1
+
+3	0	4
+	3	0	3
+	0	0	13
+	0	0	14
+	0	0	15
+	0	0	16
+	0	0	17
+	0	0	18
+	0	0	19
+	0	0	20
+	-1
+
+3	0	10
+	3	0	3
+	1	1	0
+	0	31	1
+	0	0	30
+	-1
+
+3	1	1
+	0	1	1
+	0	1	2
+	-1
+
+3	1	2
+	0	1	3
+	0	1	4
+	0	1	5
+	-1
+
+3	1	3
+	0	1	11
+	0	1	12
+	0	1	13
+	-1
+
+3	1	11
+	0	4	1
+	0	4	2
+	0	4	3
+	-1
+
+3	1	12
+	0	4	4
+	0	4	5
+	-1
+
+3	1	13
+	0	4	4
+	0	4	5
+	0	4	6
+	-1
+
+3	1	21
+	0	5	1
+	0	6	1
+	-1
+
+3	1	22
+	0	5	1
+	0	6	1
+	0	7	1
+	-1
+
+3	1	23
+	0	5	2
+	0	6	2
+	-1
+
+3	1	24
+	0	5	2
+	0	6	2
+	0	7	1
+	-1
+
+3	1	25
+	3	1	23
+	0	4	3
+	3	1	12
+	-1
+
+3	1	26
+	3	1	21
+	0	4	3
+	0	4	3
+	0	4	4
+	0	4	4
+	0	4	5
+	0	4	5
+	-1
+
+3	1	31
+	3	1	1
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	22
+	-1
+
+3	1	32
+	3	1	1
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	24
+	-1
+
+3	1	33
+	0	1	5
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	21
+	-1
+
+3	1	34
+	0	1	5
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	35
+	0	1	5
+	0	1	12
+	0	1	13
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	36
+	3	1	3
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	37
+	3	1	1
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	22
+	-1
+
+3	1	38
+	3	1	1
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	24
+	-1
+
+3	1	39
+	3	1	3
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	23
+	-1
+
+3	1	40
+	3	1	3
+	0	2	11
+	0	2	12
+	3	1	11
+	3	1	12
+	3	1	24
+	-1
+
+3	1	41
+	0	1	7
+	0	2	21
+	0	2	22
+	3	1	11
+	3	1	12
+	-1
+
+3	1	42
+	3	1	41
+	3	1	21
+	-1
+
+3	1	43
+	0	1	7
+	0	2	23
+	3	1	11
+	3	1	13
+	3	1	21
+	-1
+
+3	1	44
+	0	1	7
+	0	2	24
+	3	1	11
+	3	1	13
+	3	1	21
+	-1
+
+3	1	45
+	3	1	11
+	3	1	12
+	2	1	138
+	2	2	131
+	0	4	6
+	2	01	0
+	2	2	0
+	3	4	30
+	3	4	31
+	-1
+
+3	1	47
+	0	1	7
+	0	25	60
+	0	1	33
+	0	1	34
+	0	1	12
+	3	1	45
+	0	2	21
+	3	1	11
+	3	1	12
+	2	1	138
+	2	2	131
+	0	4	6
+	2	1	0
+	2	2	0
+	3	1	23
+	-1 
+
+3	1	48
+	0	2	104
+	0	2	121
+	0	2	113
+	0	2	26
+	0	2	27
+	0	2	111
+	0	2	140
+	2	2	127
+	0	1	13
+	2	2	126
+	0	7	1
+	2	2	0
+	0	25	10
+	0	21	64
+	-1
+
+3	1	49
+	0	2	111
+	0	2	112
+	0	21	62
+	0	21	63
+	0	21	65
+	-1
+
+3	1	51
+	0	1	6
+	0	2	61
+	3	1	11
+	3	1	12
+	3	1	21
+	0	8	4
+	-1
+
+3	1	55
+	0	1	5
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	21
+	0	1	12
+	0	1	14
+	-1
+
+3	1	62
+	1	1	0
+	0	31	1
+	3	1	1
+	-1
+
+3	1	65
+	0	1	6
+	0	1	8
+	0	2	1
+	0	2	2
+	0	2	5
+	0	2	62
+	0	2	70
+	0	2	65
+	-1
+
+3	1	66
+	3	1	11
+	3	1	13
+	3	1	23
+	0	7	4
+	0	2	64
+	0	8	4
+	-1
+
+3	1	71
+	0	1	7
+	0	1	31
+	0	1	20
+	0	1	28
+	0	1	29
+	-1
+
+3	1	72
+	3	1	71
+	3	1	11
+	3	1	13
+	3	1	21
+	-1
+
+3	2	1
+	0	10	4
+	0	10	51
+	0	10	61
+	0	10	63
+	-1
+
+3	2	2
+	0	10	4
+	0	7	4
+	0	10	3
+	0	10	61
+	0	10	63
+	-1
+
+3	2	3
+	0	11	11
+	0	11	12
+	0	12	4
+	0	12	6
+	0	13	3
+	0	20	1
+	0	20	3
+	0	20	4
+	0	20	5
+	-1
+
+3	2	4
+	0	20	10
+	0	8	2
+	0	20	11
+	0	20	13
+	0	20	12
+	0	20	12
+	0	20	12
+	-1
+
+3	2	5
+	0	8	2
+	0	20	11
+	0	20	12
+	0	20	13
+	-1
+
+3	2	6
+	0	10	4
+	0	10	51
+	0	10	62
+	0	10	63
+	-1
+
+3	2	11
+	3	2	1
+	3	2	3
+	3	2	4
+	-1
+
+3	2	12
+	3	2	2
+	3	2	3
+	3	2	4
+	-1
+
+3	2	13
+	3	2	6
+	3	2	3
+	1	1	0
+	0	31	1
+	3	2	5
+	-1
+
+3	2	21
+	0	22	1
+	0	22	11
+	0	22	21
+	-1
+
+3	2	22
+	0	22	2
+	0	22	12
+	0	22	22
+	-1
+
+3	2	23
+	0	22	3
+	0	22	13
+	0	22	23
+	-1
+
+3	2	24
+	3	2	22
+	1	1	2
+	3	2	23
+	-1
+
+3	2	51
+	0	10	4
+	0	10	51
+	0	7	4
+	0	10	3
+	0	12	4
+	0	12	51
+	0	12	16
+	0	12	17
+	0	13	4
+	1	2	4
+	0	8	51
+	0	8	20
+	-1
+
+3	3	1
+	0	7	3
+	0	11	1
+	0	11	2
+	-1
+
+3	3	2
+	0	7	4
+	0	11	1
+	0	11	2
+	-1
+
+3	3	3
+	0	7	4
+	0	10	3
+	0	12	1
+	0	12	3
+	-1
+
+3	3	4
+	0	7	4
+	0	10	3
+	0	12	1
+	0	12	3
+	0	11	1
+	0	11	2
+	-1
+
+3	3	11
+	0	7	3
+	0	8	1
+	0	11	1
+	0	11	2
+	-1
+
+3	3	12
+	0	7	4
+	0	8	1
+	0	11	1
+	0	11	2
+	-1
+
+3	3	13
+	0	7	4
+	0	8	1
+	0	10	3
+	0	12	1
+	0	13	3
+	0	11	1
+	0	11	2
+	-1
+
+3	3	14
+	0	7	4
+	0	8	1
+	0	10	3
+	0	12	1
+	0	12	3
+	0	11	1
+	0	11	2
+	-1
+
+3	3	21
+	0	7	4
+	0	7	4
+	2	4	7
+	0	31	21
+	-1
+
+3	3	22
+	3	3	21
+	0	10	3
+	2	4	0
+	-1
+
+3	3	23
+	3	3	21
+	0	12	1
+	2	4	0
+	-1
+
+3	3	24
+	3	3	21
+	0	13	16
+	2	4	0
+	-1
+
+3	3	25
+	0	2	25
+	2	4	7
+	0	31	21
+	0	12	63
+	2	4	0
+	-1
+
+3	3	26
+	0	7	4
+	0	8	3
+	2	4	7
+	0	31	21
+	0	12	1
+	2	4	0
+	-1
+
+3	3	27
+	0	7	4
+	2	4	7
+	0	31	21
+	0	10	3
+	2	4	0
+	-1
+
+3	3	31
+	0	7	4
+	0	8	3
+	0	7	21
+	0	7	22
+	0	8	12
+	0	12	61
+	-1
+
+3	3	32
+	0	20	11
+	0	20	16
+	-1
+
+3	3	33
+	0	20	10
+	0	20	16
+	-1
+
+3	3	41
+	0	2	152
+	0	2	23
+	0	7	4
+	0	11	1
+	0	11	2
+	0	2	153
+	0	2	154
+	0	12	71
+	-1
+
+3	4	1
+	0	8	3
+	0	10	4
+	0	12	1
+	0	11	1
+	0	11	2
+	-1
+
+3	4	2
+	0	8	3
+	0	10	4
+	0	11	1
+	0	11	2
+	-1
+
+3	4	3
+	0	8	3
+	0	12	1
+	-1
+
+3	4	4
+	0	8	3
+	0	10	4
+	0	20	10
+	0	12	1
+	-1
+
+3	4	5
+	0	2	24
+	0	7	4
+	0	7	4
+	0	13	3
+	-1
+
+3	4	6
+	0	14	1
+	0	14	1
+	0	14	3
+	-1
+
+3	4	11
+	0	2	163
+	0	2	164
+	0	8	12
+	0	7	24
+	0	2	167
+	0	8	21
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	8	21
+	0	4	24
+	1	10	4
+	0	8	21
+	0	4	4
+	0	4	5
+	0	4	6
+	0	8	21
+	0	4	4
+	0	4	5
+	0	4	6
+	0	11	1
+	0	11	2
+	1	3	10
+	0	2	163
+	0	7	4
+	0	12	1
+	-1
+
+3	4	30
+	0	27	31
+	0	28	31
+	0	10	31
+	-1
+
+3	4	31
+	0	1	41
+	0	1	42
+	0	1	43
+	-1
+
+3	6	1
+	0	2	32
+	1	2	0
+	0	31	1
+	0	7	62
+	0	22	42
+	-1
+
+3	6	2
+	0	2	31
+	0	22	4
+	0	22	31
+	-1
+
+3	6	3
+	0	2	2
+	0	11	11
+	0	11	12
+	0	12	4
+	-1
+
+3	6	4
+	0	2	32
+	0	2	33
+	1	3	0
+	0	31	1
+	0	7	62
+	0	22	43
+	0	22	62
+	-1
+
+3	6	5
+	0	2	31
+	1	3	0
+	0	31	1
+	0	7	62
+	0	22	4
+	0	22	31
+	-1
+
+3	6	6
+	3	6	3
+	3	6	2
+	0	22	63
+	-1
+
+3	6	7
+	0	1	12
+	0	1	14
+	3	6	8
+	0	4	24
+	0	27	3
+	0	28	3
+	-1
+
+3	6	8
+	0	2	34
+	0	2	35
+	0	2	36
+	-1
+
+3	6	20
+	3	6	24
+	1	2	6
+	0	22	38
+	0	22	39
+	-1
+
+3	6	21
+	0	1	75
+	3	1	11
+	3	1	12
+	0	22	122
+	0	22	123
+	0	12	1
+	3	3	2
+	-1
+
+3	6	22
+	0	1	75
+	3	1	11
+	3	1	12
+	0	22	38
+	0	22	39
+	-1
+
+3	6	23
+	0	1	15
+	3	1	23
+	3	1	11
+	3	1	12
+	0	22	38
+	0	22	39
+	0	22	120
+	0	22	121
+	-1
+
+3	6	24
+	0	1	75
+	3	1	11
+	3	1	12
+	0	22	42
+	0	22	120
+	0	22	121
+	0	4	25
+	0	4	15
+	-1
+
+3	7	1
+	3	1	31
+	3	2	11
+	-1
+
+3	7	2
+	3	1	32
+	3	2	11
+	-1
+
+3	7	3
+	3	7	1
+	1	1	0
+	0	31	1
+	3	2	5
+	-1
+
+3	7	4
+	3	7	2
+	1	1	0
+	0	31	1
+	3	2	5
+	-1
+
+3	7	5
+	3	7	1
+	1	1	4
+	3	2	5
+	-1
+
+3	7	6
+	3	7	2
+	1	1	4
+	3	2	5
+	-1
+
+3	7	7
+	3	1	31
+	3	2	12
+	-1
+
+3	7	8
+	3	1	32
+	3	2	12
+	-1
+
+3	7	9
+	3	1	31
+	3	2	13
+	-1
+
+3	7	11
+	0	1	63
+	0	2	1
+	3	1	11
+	3	1	12
+	3	1	24
+	0	7	6
+	0	11	1
+	0	11	16
+	0	11	17
+	0	11	2
+	0	11	41
+	0	7	6
+	0	12	1
+	0	12	3
+	0	10	52
+	0	20	9
+	-1
+
+3	7	12
+	1	3	0
+	0	31	1
+	0	8	23
+	0	5	21
+	0	20	1
+	-1
+
+3	7	13
+	1	6	0
+	0	31	1
+	0	1	64
+	0	8	14
+	0	20	61
+	0	8	14
+	0	20	61
+	0	20	18
+	-1
+
+3	7	14
+	1	1	0
+	0	31	1
+	0	20	19
+	-1
+
+3	7	15
+	1	1	0
+	0	31	1
+	3	2	5
+	0	8	2
+	0	20	11
+	0	20	12
+	0	20	13
+	0	20	2
+	-1
+
+3	7	16
+	1	1	0
+	0	31	1
+	0	20	20
+	-1
+
+3	7	17
+	1	1	0
+	0	31	1
+	0	11	70
+	-1
+
+3	7	18
+	0	8	16
+	1	2	0
+	0	31	1
+	0	8	17
+	3	1	12
+	1	4	0
+	0	31	1
+	0	7	6
+	0	11	1
+	0	11	2
+	0	11	41
+	0	20	9
+	1	1	0
+	0	31	1
+	0	20	1
+	3	7	14
+	-1
+
+3	7	20
+	3	7	11
+	3	7	14
+	3	7	16
+	-1
+
+3	7	21
+	3	7	11
+	3	7	12
+	3	7	13
+	3	7	14
+	3	7	15
+	3	7	16
+	3	7	17
+	3	7	18
+	3	7	15
+	-1
+
+3	8	1
+	3	1	33
+	3	2	11
+	0	22	42
+	-1
+
+3	8	2
+	3	1	34
+	3	2	11
+	0	22	42
+	-1
+
+3	8	3
+	3	1	35
+	3	2	11
+	0	22	42
+	-1
+
+3	8	4
+	3	1	36
+	3	2	11
+	0	22	42
+	-1
+
+3	8	5
+	3	8	4
+	3	2	24
+	-1
+
+3	8	6
+	0	10	4
+	0	10	61
+	0	10	63
+	0	11	1
+	0	11	2
+	0	12	4
+	0	13	3
+	0	22	42
+	-1
+
+3	8	7
+	3	1	55
+	3	2	11
+	0	7	62
+	0	22	42
+	-1
+
+3	9	1
+	3	1	37
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	2
+	3	1	38
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	3
+	3	1	37
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	4
+	3	1	38
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	5
+	3	1	37
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	6
+	3	1	38
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	7
+	3	1	37
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	8
+	3	1	38
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	11
+	3	1	39
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	12
+	3	1	39
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	13
+	3	1	39
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	14
+	3	1	39
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	15
+	3	1	40
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	16
+	3	1	40
+	1	1	0
+	0	31	1
+	3	3	12
+	-1
+
+3	9	17
+	3	1	40
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	13
+	-1
+
+3	9	18
+	3	1	40
+	3	2	4
+	1	1	0
+	0	31	1
+	3	3	14
+	-1
+
+3	9	19
+	3	1	31
+	0	2	3
+	1	1	0
+	0	31	1
+	3	3	11
+	-1
+
+3	9	20
+	3	1	31
+	0	2	3
+	1	4	0
+	0	31	1
+	0	7	3
+	0	11	3
+	0	11	4
+	0	11	5
+	-1
+
+3	10	1
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	26
+	3	3	25
+	-1
+
+3	10	2
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	9
+	3	3	23
+	-1
+
+3	10	3
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	6
+	3	3	23
+	-1
+
+3	10	4
+	3	1	42
+	3	3	31
+	3	3	32
+	1	1	3
+	3	3	24
+	-1
+
+3	10	5
+	3	1	42
+	3	3	31
+	3	3	33
+	1	1	0
+	0	31	1
+	3	03	25
+	-1
+
+3	10	6
+	3	1	42
+	3	3	31
+	3	3	33
+	1	1	0
+	0	31	1
+	3	3	23
+	-1
+
+3	10	7
+	3	1	42
+	3	3	31
+	3	3	33
+	1	1	0
+	0	31	1
+	3	3	24
+	-1
+
+3	10	8
+	3	10	11
+	1	1	19
+	3	10	12
+	0	2	150
+	0	25	79
+	0	25	80
+	0	33	32
+	0	14	45
+	-1
+
+3	10	9
+	3	10	11
+	1	1	15
+	3	10	12
+	-1
+
+3	10	10
+	3	10	11
+	1	1	5
+	3	10	12
+	-1
+
+3	10	11
+	0	8	70
+	0	1	33
+	0	1	34
+	0	8	70
+	0	1	33
+	0	1	34
+	0	1	7
+	0	2	48
+	0	5	40
+	0	25	75
+	2	1	133
+	0	5	41
+	2	1	0
+	0	5	43
+	0	25	70
+	0	33	30
+	0	33	31
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	4	5
+	2	2	131
+	2	1	138
+	0	4	6
+	2	1	0
+	2	2	0
+	0	5	1
+	0	6	1
+	2	2	126
+	0	7	1
+	2	2	0
+	0	7	24
+	0	5	21
+	0	7	25
+	0	5	22
+	0	33	33
+	0	2	151
+	0	12	64
+	0	2	151
+	0	12	64
+	0	2	151
+	0	12	64
+	0	2	151
+	0	12	64
+	0	2	151
+	0	12	64
+	-1
+
+3	10	12
+	0	2	150
+	0	25	76
+	0	25	77
+	0	25	78
+	0	33	32
+	2	1	132
+	2	2	129
+	0	12	63
+	2	2	0
+	2	1	0
+	-1
+
+3	10	13
+	0	1	7
+	0	5	40
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	4	5
+	0	4	6
+	0	5	1
+	0	6	1
+	0	7	25
+	0	5	43
+	0	25	85
+	2	1	131
+	2	2	129
+	0	2	150
+	0	8	23
+	0	8	72
+	0	14	27
+	0	8	72
+	0	14	27
+	0	2	150
+	0	8	23
+	0	8	72
+	0	14	27
+	0	8	72
+	0	14	27
+	0	2	150
+	0	8	23
+	0	8	72
+	0	14	27
+	0	8	72
+	0	14	27
+	2	2	0
+	2	1	0
+	2	1	132
+	2	2	129
+	0	2	150
+	0	8	23
+	0	8	72
+	0	12	63
+	0	8	72
+	0	12	63
+	0	2	150
+	0	8	23
+	0	8	72
+	0	12	63
+	0	8	72
+	0	12	63
+	0	8	23
+	0	8	72
+	0	12	63
+	0	8	72
+	0	12	63
+	0	2	150
+	0	8	23
+	0	8	72
+	0	12	63
+	0	8	72
+	0	12	63
+	2	2	0
+	2	1	0
+	-1
+
+3	10	14
+	3	1	72
+	3	3	41
+	3	4	11
+	-1
+
+3	11	1
+	3	1	51
+	0	7	2
+	0	12	1
+	0	11	1
+	0	11	2
+	0	11	31
+	0	11	32
+	0	11	33
+	0	20	41
+	-1
+
+3	11	2
+	3	1	65
+	3	1	66
+	3	11	3
+	3	11	4
+	-1
+
+3	11	3
+	0	10	70
+	0	11	1
+	0	11	2
+	0	12	1
+	0	13	2
+	-1
+
+3	11	4
+	1	1	0
+	0	31	0
+	0	11	34
+	1	1	0
+	0	31	0
+	0	11	35
+	1	1	0
+	0	31	0
+	0	11	75
+	1	1	0
+	0	31	0
+	0	11	76
+	1	1	0
+	0	31	0
+	0	33	25
+	1	1	0
+	0	31	0
+	0	33	26
+	-1
+
+3	12	1
+	3	1	43
+	3	4	1
+	-1
+
+3	12	2
+	3	1	43
+	3	4	2
+	-1
+
+3	12	3
+	3	1	42
+	3	4	3
+	-1
+
+3	12	4
+	3	1	42
+	3	4	4
+	-1
+
+3	12	5
+	3	1	42
+	0	20	14
+	-1
+
+3	12	6
+	3	1	44
+	3	4	5
+	-1
+
+3	12	7
+	3	1	42
+	3	4	6
+	-1
+
+3	12	10
+	0	1	7
+	0	5	40
+	0	2	21
+	0	5	41
+	0	4	1
+	0	4	43
+	-1
+
+3	12	11
+	2	2	131
+	2	1	149
+	0	4	6
+	2	1	0
+	2	2	126
+	0	10	2
+	2	2	0
+	0	5	43
+	0	5	53
+	-1
+
+3	12	12
+	2	2	129
+	2	1	132
+	1	1	19
+	0	12	63
+	2	1	0
+	2	2	0
+	-1
+
+3	12	13
+	0	5	42
+	2	2	129
+	2	1	135
+	0	12	63
+	2	1	0
+	2	2	0
+	-1
+
+3	12	14
+	3	12	10
+	3	12	11
+	1	5	56
+	3	1	23
+	0	5	42
+	0	5	52
+	3	12	12
+	3	12	13
+	-1
+
+3	12	15
+	1	9	11
+	3	1	23
+	0	5	42
+	0	5	52
+	2	2	129
+	2	1	132
+	1	1	4
+	0	12	63
+	2	2	0
+	2	1	0
+	-1
+
+3	12	16
+	3	12	10
+	3	12	11
+	3	12	15
+	-1
+
+3	12	17
+	1	9	8
+	3	1	23
+	0	5	42
+	0	5	52
+	2	2	129
+	2	1	132
+	1	1	3
+	0	12	63
+	2	2	0
+	2	1	0
+	-1
+
+3	12	18
+	3	12	10
+	3	12	11
+	3	12	17
+	-1
+
+3	12	19
+	3	1	47
+	3	1	48
+	0	15	15
+	0	29	2
+	0	21	76
+	1	6	12
+	2	1	129
+	0	6	30
+	2	1	0
+	1	2	12
+	0	5	30
+	0	21	75
+	0	21	66
+	-1
+
+3	12	20
+	3	1	47
+	3	1	48
+	0	15	15
+	0	29	2
+	0	21	76
+	1	4	12
+	0	6	30
+	1	2	12
+	0	5	30
+	0	21	75
+	0	21	66
+	-1
+
+3	12	21
+	3	1	47
+	1	1	3
+	3	1	49
+	0	11	12
+	0	11	11
+	0	21	67
+	-1
+
+3	12	22
+	3	1	47
+	0	8	22
+	0	11	12
+	0	11	50
+	0	22	70
+	0	22	26
+	3	12	41
+	0	10	50
+	0	21	68
+	0	21	71
+	0	21	72
+	0	21	73
+	3	12	42
+	0	21	62
+	0	15	11
+	-1
+
+3	12	23
+	3	1	47
+	1	3	3
+	0	8	22
+	0	12	61
+	0	22	50
+	0	21	69
+	0	21	85
+	-1
+
+3	12	24
+	3	12	20
+	0	8	60
+	0	8	22
+	0	8	60
+	0	8	22
+	0	25	14
+	0	22	101
+	0	22	97
+	0	22	98
+	0	22	99
+	0	22	100
+	-1
+
+3	12	25
+	3	12	19
+	0	8	60
+	0	8	22
+	0	8	60
+	0	8	22
+	0	25	14
+	0	22	101
+	0	22	97
+	0	22	98
+	0	22	99
+	0	22	100
+	-1
+
+3	12	41
+	2	1	141
+	2	2	130
+	0	7	1
+	2	1	00
+	2	2	00
+	-1
+
+3	12	42
+	0	21	77
+	0	21	78
+	0	21	79
+	0	21	80
+	0	21	81
+	0	21	82
+	-1
+
+3	13	9
+	0	21	1
+	1	1	0
+	0	31	1
+	0	21	1
+	-1
+
+3	13	10
+	0	21	36
+	1	1	0
+	0	31	1
+	0	21	36
+	-1
+
+3	13	31
+	0	6	2
+	0	6	12
+	1	1	0
+	0	31	2
+	0	30	1
+	-1
+
+3	13	32
+	0	5	2
+	0	5	12
+	1	1	0
+	0	31	2
+	3	13	31
+	-1
+
+3	13	41
+	0	6	2
+	1	10	0
+	0	31	1
+	1	4	0
+	0	31	1
+	0	6	12
+	1	1	0
+	0	31	12
+	0	30	1
+	0	6	12
+	1	1	0
+	0	31	1
+	0	30	1
+	-1
+
+3	13	42
+	0	5	2
+	0	5	12
+	1	1	0
+	0	31	2
+	3	13	41
+	-1
+
+3	13	43
+	0	6	2
+	0	5	2
+	0	5	12
+	1	12	0
+	0	31	1
+	1	10	0
+	0	31	1
+	1	04	0
+	0	31	1
+	0	6	12
+	1	1	0
+	0	31	11
+	0	30	1
+	1	1	0
+	0	31	1
+	0	30	1
+	-1
+	
+3	15	1
+	0	1	11
+	3	1	11
+	3	1	12
+	3	1	23
+	3	6	1
+	-1
+
+3	15	2
+	0	1	11
+	3	1	11
+	3	1	12
+	3	1	23
+	3	6	4
+	-1
+
+3	16	1
+	3	1	11
+	0	4	4
+	3	1	23
+	0	1	21
+	0	2	41
+	0	19	1
+	0	10	51
+	0	19	2
+	0	19	3
+	0	19	4
+	-1
+
+3	16	2
+	0	8	21
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	4	5
+	0	1	33
+	0	8	21
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	4	5
+	0	7	2
+	0	7	2
+	-1
+
+3	16	3
+	1	10	0
+	0	31	1
+	0	8	11
+	0	8	7
+	1	4	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	10	2
+	0	11	2
+	0	8	7
+	0	8	11
+	-1
+
+3	16	4
+	1	11	0
+	0	31	1
+	0	8	11
+	0	8	7
+	0	7	2
+	0	7	2
+	1	2	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	11	31
+	0	8	7
+	0	8	11
+	-1
+
+3	16	5
+	1	8	0
+	0	31	1
+	0	8	5
+	0	8	7
+	0	5	2
+	0	6	2
+	0	1	26
+	0	19	1
+	0	8	7
+	0	8	5
+	-1
+
+3	16	6
+	1	12	0
+	0	31	1
+	0	8	11
+	0	8	7
+	0	7	2
+	0	7	2
+	1	2	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	20	11
+	0	20	12
+	0	8	7
+	0	8	11
+	-1
+
+3	16	7
+	1	10	0
+	0	31	1
+	0	8	11
+	0	8	7
+	1	4	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	19	5
+	0	19	6
+	0	8	7
+	0	8	11
+	-1
+
+3	16	8
+	1	11	0
+	0	31	1
+	0	8	1
+	0	8	7
+	0	8	23
+	1	3	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	10	2
+	0	8	23
+	0	8	7
+	0	8	1
+	-1
+
+3	16	9
+	1	11	0
+	0	31	1
+	0	8	11
+	0	8	7
+	0	7	2
+	0	7	2
+	1	2	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	20	41
+	0	8	7
+	0	8	11
+	-1
+
+3	16	10
+	1	7	0
+	0	31	1
+	0	8	11
+	0	8	7
+	0	1	22
+	0	5	2
+	0	6	2
+	0	8	7
+	0	8	11
+	-1
+
+3	16	11
+	1	16	0
+	0	31	1
+	0	8	11
+	0	1	22
+	0	8	7
+	1	2	0
+	0	31	1
+	0	5	2
+	0	6	2
+	0	8	21
+	0	4	1
+	0	4	2
+	0	4	3
+	0	4	4
+	0	4	5
+	0	20	90
+	0	8	21
+	0	8	7
+	0	8	11
+	-1
+
+3	18	1
+	3	1	25
+	0	24	11
+	-1
+
+3	18	3
+	3	1	26
+	0	24	5
+	0	24	4
+	0	24	21
+	-1
+
+3	18	4
+	3	1	25
+	0	4	23
+	0	13	11
+	0	24	5
+	0	24	4
+	0	24	22
+	-1
+
+3	21	1
+	0	2	101
+	0	2	114
+	0	2	105
+	0	2	106
+	0	2	107
+	0	2	121
+	-1
+
+3	21	3
+	0	21	51
+	0	21	14
+	0	21	17
+	0	21	30
+	-1
+
+3	21	4
+	3	1	31
+	0	2	3
+	1	1	0
+	0	31	1
+	3	21	3
+	-1
+
+3	21	5
+	0	25	4
+	0	2	121
+	0	2	122
+	0	2	123
+	0	2	124
+	0	2	125
+	0	2	126
+	0	2	127
+	0	2	128
+	0	2	129
+	0	2	130
+	0	2	131
+	-1
+
+3	21	6
+	0	25	1
+	0	25	2
+	0	25	3
+	0	25	5
+	-1
+
+3	21	7
+	0	25	9
+	0	25	10
+	0	25	11
+	0	25	12
+	0	25	13
+	0	25	15
+	0	25	16
+	0	25	17
+	-1
+
+3	21	8
+	0	25	6
+	0	25	7
+	0	25	8
+	-1
+
+3	21	9
+	0	25	18
+	0	25	19
+	-1
+
+3	21	10
+	0	2	101
+	0	7	2
+	0	2	102
+	0	2	103
+	0	2	104
+	0	2	105
+	0	2	106
+	0	2	107
+	0	2	108
+	0	2	109
+	0	2	110
+	0	2	132
+	0	2	133
+	-1
+
+3	21	11
+	0	30	31
+	0	30	32
+	0	29	2
+	-1
+
+3	21	12
+	1	1	0
+	0	31	1
+	0	2	135
+	-1
diff --git a/data/tables/B3M-000-007-0 b/data/tables/B3M-000-007-0
new file mode 100644
index 0000000..51af964
--- /dev/null
+++ b/data/tables/B3M-000-007-0
@@ -0,0 +1,115 @@
+##############################################################################
+# BUFR Table 0
+#
+#
+# Notes
+# -----
+#
+# * This table comes from GRIB Code Table 0 (Identification of center)
+#
+# * A value of 1 in the first column indicates a center that uses minor
+#   version numbers with local tables.  Since minor local table version
+#   numbers are stored in Section 1, Octet 18, the value in the first
+#   column must not be set if a center uses Section 1, Octet 18 for other
+#   purposes (i.e., ECMWF).
+#
+#
+##############################################################################		
+		
+#01-09: WMCs		
+0	1	Melbourne
+0	2	Melbourne
+0	3	Melbourne
+0	4	Moscow
+0	5	Moscow
+0	6	Moscow
+0	7	"US National Weather Service, National Centres for Environmental Prediction(NCEP)"
+0	8	US National Weather Service TelecommunicationsGateway (NWSTG)
+0	9	US National Weather Service - Other
+#10-25: Centres in Region I		
+0	10	Cairo (RSMC/RAFC)
+0	11	Cairo (RSMC/RAFC)
+0	12	Dakar (RSMC/RAFC)
+0	13	Dakar (RSMC/RAFC)
+0	14	Nairobi (RSMC/RAFC)
+0	15	Nairobi (RSMC/RAFC)
+0	18	Tunis Casablanca (RSMC)
+0	19	Tunis Casablanca (RSMC)
+0	20	Las Palmas (RAFC)
+0	21	Algiers (RSMC)
+0	24	Pretoria (RSMC)
+0	25	La R�union (RSMC)
+#26-40: Centres in Region II		
+0	26	Khabarovsk (RSMC)
+0	27	Khabarovsk (RSMC)
+0	28	New Delhi (RSMC/RAFC)
+0	29	New Delhi (RSMC/RAFC)
+0	30	Novosibirsk (RSMC)
+0	31	Novosibirsk (RSMC)
+0	32	Tashkent (RSMC)
+0	33	Jeddah (RSMC)
+0	34	"Tokyo (RSMC), Japan Meteorological Agency"
+0	35	"Tokyo (RSMC), Japan Meteorological Agency"
+0	36	Bangkok
+0	37	Ulan Bator
+0	38	Beijing (RSMC)
+0	39	Beijing (RSMC)
+0	40	Seoul
+#41-50: Centres in Region III		
+0	41	Buenos Aires (RSMC/RAFC)
+0	42	Buenos Aires (RSMC/RAFC)
+0	43	Brasilia (RSMC/RAFC)
+0	44	Brasilia (RSMC/RAFC)
+0	45	Santiago
+0	46	Brazilian Space Agency � INPE
+#51-63: Centres in Region IV		
+0	51	Miami (RSMC/RAFC)
+0	52	"Miami RSMC, National Hurricane Center"
+0	53	Montreal (RSMC)
+0	54	Montreal (RSMC)
+0	55	San Francisco
+0	57	U.S. Air Force Air Force Global Weather Central 
+0	58	"Fleet Numerical Meteorology and Oceanography Center, Monterey, CA"
+0	59	"The NOAA Forecast Systems Laboratory, Boulder, CO, USA"
+0	60	United States National Centre for Atmospheric Research (NCAR)
+#64-73: Centres in Region V		
+0	64	Honolulu
+0	65	Darwin (RSMC)
+0	66	Darwin (RSMC)
+0	67	Melbourne (RSMC)
+0	69	Wellington (RSMC/RAFC)
+0	70	Wellington (RSMC/RAFC)
+0	71	Nadi (RSMC)
+#74-99: Centres in Region VI		
+0	74	UK Meteorological Office � Bracknell (RSMC)
+0	75	UK Meteorological Office � Bracknell (RSMC)
+0	76	Moscow (RSMC/RAFC)
+0	78	Offenbach (RSMC)
+0	79	Offenbach (RSMC)
+0	80	Rome (RSMC)
+0	81	Rome (RSMC)
+0	82	Norrk�ping
+0	83	Norrk�ping
+0	85	Toulouse (RSMC)
+0	86	Helsinki
+0	87	Belgrade
+0	88	Oslo
+0	89	Prague
+0	90	Episkopi
+0	91	Ankara
+0	92	Frankfurt/Main (RAFC)
+0	93	London (WAFC)
+0	94	Copenhagen
+0	95	Rota
+0	96	Athens
+0	97	European Space Agency (ESA)
+0	98	"ECMWF, RSMC"
+0	99	De Bilt
+0	110	Hong-Kong
+0	160	US NOAA/NESDIS
+0	210	Frascati (ESA/ESRIN)
+0	211	Lanion
+0	212	Lisboa
+0	213	Reykjavik
+0	254	EUMETSAT Operation Centre
+0	255	Missing value
diff --git a/data/tables/B3M-000-007-A b/data/tables/B3M-000-007-A
new file mode 100644
index 0000000..5a7f993
--- /dev/null
+++ b/data/tables/B3M-000-007-A
@@ -0,0 +1,259 @@
+#
+# BUFR Table A - Data Category
+#
+  0	Surface data - land
+  1	Surface data - sea
+  2	Vertical soundings (other than satellite)
+  3	Vertical soundings (satellite)
+  4	Single level upper-air data (other than satellite)
+  5	Single level upper-air data (satellite)
+  6	Radar data
+  7	Synoptic features
+  8	Physical/chemical constituents
+  9	Dispersal and transport
+ 10	Radiological data
+ 11	BUFR tables, complete replacement or update
+ 12	Surface data (satellite)
+ 13	RESERVED
+ 14	RESERVED
+ 15	RESERVED
+ 16	RESERVED
+ 17	RESERVED
+ 18	RESERVED
+ 19	RESERVED
+ 20	Status information
+ 21	Radiances (satellite measured)
+ 22	RESERVED
+ 23	RESERVED
+ 24	RESERVED
+ 25	RESERVED
+ 26	RESERVED
+ 27	RESERVED
+ 28	RESERVED
+ 29	RESERVED
+ 30	RESERVED
+ 31	Oceanographic data
+ 32	RESERVED
+ 33	RESERVED
+ 34	RESERVED
+ 35	RESERVED
+ 36	RESERVED
+ 37	RESERVED
+ 38	RESERVED
+ 39	RESERVED
+ 40	RESERVED
+ 41	RESERVED
+ 42	RESERVED
+ 43	RESERVED
+ 44	RESERVED
+ 45	RESERVED
+ 46	RESERVED
+ 47	RESERVED
+ 48	RESERVED
+ 49	RESERVED
+ 50	RESERVED
+ 51	RESERVED
+ 52	RESERVED
+ 53	RESERVED
+ 54	RESERVED
+ 55	RESERVED
+ 56	RESERVED
+ 57	RESERVED
+ 58	RESERVED
+ 59	RESERVED
+ 60	RESERVED
+ 61	RESERVED
+ 62	RESERVED
+ 63	RESERVED
+ 64	RESERVED
+ 65	RESERVED
+ 66	RESERVED
+ 67	RESERVED
+ 68	RESERVED
+ 69	RESERVED
+ 70	RESERVED
+ 71	RESERVED
+ 72	RESERVED
+ 73	RESERVED
+ 74	RESERVED
+ 75	RESERVED
+ 76	RESERVED
+ 77	RESERVED
+ 78	RESERVED
+ 79	RESERVED
+ 80	RESERVED
+ 81	RESERVED
+ 82	RESERVED
+ 83	RESERVED
+ 84	RESERVED
+ 85	RESERVED
+ 86	RESERVED
+ 87	RESERVED
+ 88	RESERVED
+ 89	RESERVED
+ 90	RESERVED
+ 91	RESERVED
+ 92	RESERVED
+ 93	RESERVED
+ 94	RESERVED
+ 95	RESERVED
+ 96	RESERVED
+ 97	RESERVED
+ 98	RESERVED
+ 99	RESERVED
+100	RESERVED
+101	Image data
+102	RESERVED
+103	RESERVED
+104	RESERVED
+105	RESERVED
+106	RESERVED
+107	RESERVED
+108	RESERVED
+109	RESERVED
+110	RESERVED
+111	RESERVED
+112	RESERVED
+113	RESERVED
+114	RESERVED
+115	RESERVED
+116	RESERVED
+117	RESERVED
+118	RESERVED
+119	RESERVED
+120	RESERVED
+121	RESERVED
+122	RESERVED
+123	RESERVED
+124	RESERVED
+125	RESERVED
+126	RESERVED
+127	RESERVED
+128	RESERVED
+129	RESERVED
+130	RESERVED
+131	RESERVED
+132	RESERVED
+133	RESERVED
+134	RESERVED
+135	RESERVED
+136	RESERVED
+137	RESERVED
+138	RESERVED
+139	RESERVED
+140	RESERVED
+141	RESERVED
+142	RESERVED
+143	RESERVED
+144	RESERVED
+145	RESERVED
+146	RESERVED
+147	RESERVED
+148	RESERVED
+149	RESERVED
+150	RESERVED
+151	RESERVED
+152	RESERVED
+153	RESERVED
+154	RESERVED
+155	RESERVED
+156	RESERVED
+157	RESERVED
+158	RESERVED
+159	RESERVED
+160	RESERVED
+161	RESERVED
+162	RESERVED
+163	RESERVED
+164	RESERVED
+165	RESERVED
+166	RESERVED
+167	RESERVED
+168	RESERVED
+169	RESERVED
+170	RESERVED
+171	RESERVED
+172	RESERVED
+173	RESERVED
+174	RESERVED
+175	RESERVED
+176	RESERVED
+177	RESERVED
+178	RESERVED
+179	RESERVED
+180	RESERVED
+181	RESERVED
+182	RESERVED
+183	RESERVED
+184	RESERVED
+185	RESERVED
+186	RESERVED
+187	RESERVED
+188	RESERVED
+189	RESERVED
+190	RESERVED
+191	RESERVED
+192	RESERVED
+193	RESERVED
+194	RESERVED
+195	RESERVED
+196	RESERVED
+197	RESERVED
+198	RESERVED
+199	RESERVED
+200	RESERVED
+201	RESERVED
+202	RESERVED
+203	RESERVED
+204	RESERVED
+205	RESERVED
+206	RESERVED
+207	RESERVED
+208	RESERVED
+209	RESERVED
+210	RESERVED
+211	RESERVED
+212	RESERVED
+213	RESERVED
+214	RESERVED
+215	RESERVED
+216	RESERVED
+217	RESERVED
+218	RESERVED
+219	RESERVED
+220	RESERVED
+221	RESERVED
+222	RESERVED
+223	RESERVED
+224	RESERVED
+225	RESERVED
+226	RESERVED
+227	RESERVED
+228	RESERVED
+229	RESERVED
+230	RESERVED
+231	RESERVED
+232	RESERVED
+233	RESERVED
+234	RESERVED
+235	RESERVED
+236	RESERVED
+237	RESERVED
+238	RESERVED
+239	RESERVED
+240	FOR EXPERIMENTAL USE
+241	FOR EXPERIMENTAL USE
+242	FOR EXPERIMENTAL USE
+243	FOR EXPERIMENTAL USE
+244	FOR EXPERIMENTAL USE
+245	FOR EXPERIMENTAL USE
+246	FOR EXPERIMENTAL USE
+247	FOR EXPERIMENTAL USE
+248	FOR EXPERIMENTAL USE
+249	FOR EXPERIMENTAL USE
+250	FOR EXPERIMENTAL USE
+251	FOR EXPERIMENTAL USE
+252	FOR EXPERIMENTAL USE
+253	FOR EXPERIMENTAL USE
+254	FOR EXPERIMENTAL USE
+255	Indicator for local use, with sub-category
diff --git a/data/tables/B3M-000-007-B b/data/tables/B3M-000-007-B
new file mode 100644
index 0000000..4173980
--- /dev/null
+++ b/data/tables/B3M-000-007-B
@@ -0,0 +1,682 @@
+#
+# WMO source file name = BufrTabB.txt
+# Master Table B Version 7
+#
+#                   Reference    Bit
+# F   X    Y Scale    Value     Width     Units     Comments
+#--------------------------------------------------------------
+# Class 00 - BUFR table entries
+  0;  0;   1;    0;           0;   24;   CCITT_IA5; Table A:  entry
+  0;  0;   2;    0;           0;  256;   CCITT_IA5; "Table A:  data category description, line 1"
+  0;  0;   3;    0;           0;  256;   CCITT_IA5; "Table A:  data category description, line 2"
+  0;  0;   5;    0;           0;   24;   CCITT_IA5; BUFR edition number
+  0;  0;  10;    0;           0;    8;   CCITT_IA5; F descriptor to be added or defined
+  0;  0;  11;    0;           0;   16;   CCITT_IA5; X descriptor to be added or defined
+  0;  0;  12;    0;           0;   24;   CCITT_IA5; Y descriptor to be added or defined
+  0;  0;  13;    0;           0;  256;   CCITT_IA5; "Element name, line 1"
+  0;  0;  14;    0;           0;  256;   CCITT_IA5; "Element name, line 2"
+  0;  0;  15;    0;           0;  192;   CCITT_IA5; Units name
+  0;  0;  16;    0;           0;    8;   CCITT_IA5; Units scale sign
+  0;  0;  17;    0;           0;   24;   CCITT_IA5; Units scale
+  0;  0;  18;    0;           0;    8;   CCITT_IA5; Units reference sign
+  0;  0;  19;    0;           0;   80;   CCITT_IA5; Units reference value
+  0;  0;  20;    0;           0;   24;   CCITT_IA5; Element data width
+  0;  0;  30;    0;           0;   48;   CCITT_IA5; Descriptor defining sequence
+# Class 01 - Identification
+  0;  1;   1;    0;           0;    7;     Numeric; WMO block number
+  0;  1;   2;    0;           0;   10;     Numeric; WMO station number
+  0;  1;   3;    0;           0;    3;  Code_Table; WMO Region number/geographical area
+  0;  1;   4;    0;           0;    3;     Numeric; WMO Region sub-area (see Note 9)
+  0;  1;   5;    0;           0;   17;     Numeric; Buoy/platform identifier
+  0;  1;   6;    0;           0;   64;   CCITT_IA5; Aircraft flight number
+  0;  1;   7;    0;           0;   10;  Code_Table; Satellite identifier
+  0;  1;   8;    0;           0;   64;   CCITT_IA5; Aircraft registration number
+  0;  1;   9;    0;           0;   64;   CCITT_IA5; Type of commercial aircraft
+  0;  1;  10;    0;           0;   64;   CCITT_IA5; Stationary buoy platform identifier; e.g. C-MAN buoys
+  0;  1;  11;    0;           0;   72;   CCITT_IA5; Ship or mobile land station identifier
+  0;  1;  12;    0;           0;    9; Degree_true; Direction of motion of moving observing platform
+  0;  1;  13;    0;           0;   10;       m s�1; Speed of motion of moving observing platform
+  0;  1;  14;    2;           0;   10;       m s�1; Platform drift speed (high precision)
+  0;  1;  15;    0;           0;  160;   CCITT_IA5; Station or site name
+  0;  1;  20;    0;           0;    4;     Numeric; WMO Region sub-area
+  0;  1;  21;    0;           0;   14;     Numeric; Synoptic feature identifier
+  0;  1;  22;    0;           0;  224;   CCITT_IA5; Name of feature (see Note 11)
+  0;  1;  25;    0;           0;   24;   CCITT_IA5; Storm identifier
+  0;  1;  26;    0;           0;   64;   CCITT_IA5; WMO storm name
+  0;  1;  31;    0;           0;   16;  Code_Table; Identification of originating/generating centre (see Note 10)
+  0;  1;  32;    0;           0;    8;generating centre  ; Generating application
+  0;  1;  33;    0;           0;    8;  Code_Table; Identification of originating/generating centre
+  0;  1;  34;    0;           0;    8;  Code_Table; Identification of originating/generating sub-centre
+  0;  1;  41;    5; -1073741824;   31;       m s-1; Absolute platform velocity - first component (see Note 6)
+  0;  1;  42;    5; -1073741824;   31;       m s-1; Absolute platform velocity - second component (see Note 6)
+  0;  1;  43;    5; -1073741824;   31;       m s-1; Absolute platform velocity - third component (see Note 6)
+  0;  1;  60;    0;           0;   64;   CCITT_IA5; Aircraft reporting point (Beacon identifier)
+  0;  1;  63;    0;           0;   64;   CCITT_IA5; ICAO location indicator
+  0;  1;  64;    0;           0;   32;   CCITT_IA5; Runway designator
+  0;  1;  75;    0;           0;   40;   CCITT_IA5; Tide station identification
+# Class 02 - Instrumentation
+  0;  2;   1;    0;           0;    2;  Code_Table; Type of station
+  0;  2;   2;    0;           0;    4;  Flag_Table; Type of instrumentation for wind measurement
+  0;  2;   3;    0;           0;    4;  Code_Table; Type of measuring equipment used
+  0;  2;   4;    0;           0;    4;  Code_Table; Type of instrumentation for evaporation measurement or type of crop for which evapotranspiration is reported
+  0;  2;   5;    2;           0;    7;           K; Precision of temperature observation
+  0;  2;  11;    0;           0;    8;  Code_Table; Radiosonde type
+  0;  2;  12;    0;           0;    4;  Code_Table; Radiosonde computational method
+  0;  2;  13;    0;           0;    4;  Code_Table; Solar and infrared radiation correction
+  0;  2;  14;    0;           0;    7;  Code_Table; Tracking technique/status of system used
+  0;  2;  15;    0;           0;    4;  Code_Table; Radiosonde completeness
+  0;  2;  20;    0;           0;    9;  Code_Table; Satellite classification
+  0;  2;  21;    0;           0;    9;  Flag_Table; Satellite instrument data used in processing*
+  0;  2;  22;    0;           0;    8;  Flag_Table; Satellite data-processing technique used
+  0;  2;  23;    0;           0;    4;  Code_Table; Satellite derived wind computation method
+  0;  2;  24;    0;           0;    4;  Code_Table; Integrated mean humidity computational method
+  0;  2;  25;    0;           0;   25;  Flag_Table; Satellite channel(s) used in computation
+  0;  2;  26;    2;           0;   12;           m; Cross track resolution
+  0;  2;  27;    2;           0;   12;           m; Along track resolution
+  0;  2;  28;    0;           0;   18;           m; Segment size at nadir in X direction
+  0;  2;  29;    0;           0;   18;           m; Segment size at nadir in Y direction
+  0;  2;  30;    0;           0;    3;  Code_Table; Method of current measurement
+  0;  2;  31;    0;           0;    5;  Code_Table; Duration and time of current measurement
+  0;  2;  32;    0;           0;    2;  Code_Table; Indicator for digitization
+  0;  2;  33;    0;           0;    3;  Code_Table; Method of salinity/depth measurement
+  0;  2;  34;    0;           0;    5;  Code_Table; Drogue type
+  0;  2;  35;    0;           0;    9;           m; Cable length
+  0;  2;  36;    0;           0;    2;  Code_Table; Buoy type
+  0;  2;  37;    0;           0;    3;  Code_Table; Method of tidal observation
+  0;  2;  38;    0;           0;    4;  Code_Table; Method of sea-surface temperature measurement
+  0;  2;  39;    0;           0;    3;  Code_Table; Method of wet-bulb temperature measurement
+  0;  2;  40;    0;           0;    4;  Code_Table; Method of removing velocity and motion of platform from current
+  0;  2;  41;    0;           0;    6;  Code_Table; Method for estimating reports related to synoptic features
+  0;  2;  44;    0;           0;    4;  Code_Table; Indicator for method of calculating spectral wave data
+  0;  2;  45;    0;           0;    4;  Code_Table; Indicator for type of platform
+  0;  2;  46;    0;           0;    4;  Code_Table; Wave measurement instrumentation
+  0;  2;  48;    0;           0;    4;  Code_Table; Satellite sensor indicator
+  0;  2;  49;    0;           0;    8;  Flag_Table; Geostationary satellite data-processing technique used
+  0;  2;  50;    0;           0;   20;  Flag_Table; Geostationary sounder satellite channels used
+  0;  2;  51;    0;           0;    4;  Code_Table; Indicator to specify observing method for extreme temperatures
+  0;  2;  52;    0;           0;    6;  Flag_Table; Geostationary imager satellite channels used
+  0;  2;  53;    0;           0;    4;  Code_Table; GOES-I/M brightness temperature characteristics
+  0;  2;  54;    0;           0;    4;  Code_Table; GOES-I/M soundings parameter characteristics
+  0;  2;  55;    0;           0;    4;  Code_Table; Geostationary soundings statistical parameters
+  0;  2;  56;    0;           0;    4;  Code_Table; Geostationary soundings accuracy statistics
+  0;  2;  57;    0;           0;    4;  Code_Table; Origin of first guess information for GOES-I/M soundings
+  0;  2;  58;    0;           0;    4;  Code_Table; Valid times of first guess information for GOES-I/M soundings
+  0;  2;  59;    0;           0;    4;  Code_Table; Origin of analysis information for GOES-I/M soundings
+  0;  2;  60;    0;           0;    4;  Code_Table; Origin of surface information for GOES-I/M soundings
+  0;  2;  61;    0;           0;    3;  Code_Table; Aircraft navigational system
+  0;  2;  62;    0;           0;    4;  Code_Table; Type of aircraft data relay system
+  0;  2;  63;    2;      -18000;   16;      Degree; Aircraft roll angle
+  0;  2;  64;    0;           0;    2;  Code_Table; Aircraft roll angle quality
+  0;  2;  65;    0;           0;   40;   CCITT_IA5; ACARS ground receiving station
+  0;  2;  70;    0;           0;    4;  Code_Table; Original specification of latitude/longitude
+  0;  2; 100;    1;           0;   12;          dB; Radar constant*
+  0;  2; 101;    0;           0;    4;  Code_Table; Type of antenna
+  0;  2; 102;    0;           0;    8;           m; Antenna height above tower base
+  0;  2; 103;    0;           0;    2;  Flag_Table; Radome
+  0;  2; 104;    0;           0;    4;  Code_Table; Antenna polarisation
+  0;  2; 105;    0;           0;    6;          dB; Maximum antenna gain
+  0;  2; 106;    1;           0;    6;      Degree; 3-dB beamwidth
+  0;  2; 107;    0;           0;    6;          dB; Sidelobe suppression
+  0;  2; 108;    0;           0;    6;          dB; Crosspol discrimination (on axis)
+  0;  2; 109;    2;           0;   12;  Degree s-1; Antenna speed (azimuth)
+  0;  2; 110;    2;           0;   12;  Degree s-1; Antenna speed (elevation)
+  0;  2; 111;    1;           0;   10;      Degree; Radar incidence angle
+  0;  2; 112;    1;           0;   12;      Degree; Radar look angle
+  0;  2; 113;    0;           0;    4;     Numeric; Number of azimuth looks
+  0;  2; 114;    0;           0;   15;          m2; Antenna effective surface area
+  0;  2; 121;   -8;           0;    7;          Hz; Mean frequency
+  0;  2; 122;   -6;        -128;    8;          Hz; Frequency agility range
+  0;  2; 123;   -4;           0;    7;           W; Peak power
+  0;  2; 124;   -1;           0;    7;           W; Average power
+  0;  2; 125;   -1;           0;    8;          Hz; Pulse repetition frequency
+  0;  2; 126;    7;           0;    6;           s; Pulse width
+  0;  2; 127;   -6;           0;    7;          Hz; Receiver intermediate frequency
+  0;  2; 128;   -5;           0;    6;          Hz; Intermediate frequency bandwidth
+  0;  2; 129;    0;        -150;    5;          dB; Minimum detectable signal
+  0;  2; 130;    0;           0;    7;          dB; Dynamic range
+  0;  2; 131;    0;           0;    2;  Flag_Table; Sensitivity time control (STC)
+  0;  2; 132;    2;           0;    6;      Degree; Azimuth pointing accuracy
+  0;  2; 133;    2;           0;    6;      Degree; Elevation pointing accuracy
+  0;  2; 134;    2;           0;   16;      Degree; Antenna beam azimuth
+  0;  2; 135;    2;       -9000;   15;      Degree; Antenna elevation
+  0;  2; 136;   -3;           0;   16;           m; Range processed by range attenuation correction
+  0;  2; 140;    0;           0;    9;      Degree; Satellite radar beam azimuth angle
+  0;  2; 141;    0;           0;   24;   CCITT_IA5; Measurement type
+  0;  2; 142;    0;           0;   32;   CCITT_IA5; Ozone instrument serial number/ identification
+  0;  2; 143;    0;           0;    7;  Code_Table; Ozone instrument type
+  0;  2; 144;    0;           0;    4;  Code_Table; Light source type for Brewer spectro photometer
+  0;  2; 145;    0;           0;    4;  Code_Table; Wave length setting for Dobson instruments
+  0;  2; 146;    0;           0;    4;  Code_Table; Source conditions for Dobson instruments
+  0;  2; 150;    0;           0;    6;  Code_Table; TOVS/ATOVS/AVHRR instrumentation channel number
+  0;  2; 151;    0;           0;    4;  Code_Table; Radiometer identifier
+  0;  2; 152;    0;           0;   31;  Flag_Table; Satellite instrument used in data processing
+  0;  2; 153;   -8;           0;   26;          Hz; Satellite channel centre frequency
+  0;  2; 154;   -8;           0;   26;          Hz; Satellite channel band width
+  0;  2; 163;    0;           0;    4;  Code_Table; Height assignment method
+  0;  2; 164;    0;           0;    3;  Code_Table; Tracer correlation method
+  0;  2; 166;    0;           0;    4;  Code_Table; Radiance type
+  0;  2; 167;    0;           0;    4;  Code_Table; Radiance computational method
+# Class 04 - Location (time)
+  0;  4;   1;    0;           0;   12;        Year; Year
+  0;  4;   2;    0;           0;    4;       Month; Month
+  0;  4;   3;    0;           0;    6;         Day; Day
+  0;  4;   4;    0;           0;    5;        Hour; Hour
+  0;  4;   5;    0;           0;    6;      Minute; Minute
+  0;  4;   6;    0;           0;    6;      Second; Second
+  0;  4;  11;    0;       -1024;   11;        Year; Time increment
+  0;  4;  12;    0;       -1024;   11;       Month; Time increment
+  0;  4;  13;    0;       -1024;   11;         Day; Time increment
+  0;  4;  14;    0;       -1024;   11;        Hour; Time increment
+  0;  4;  15;    0;       -2048;   12;      Minute; Time increment
+  0;  4;  16;    0;       -4096;   13;      Second; Time increment
+  0;  4;  21;    0;       -1024;   11;        Year; Time period or displacement
+  0;  4;  22;    0;       -1024;   11;       Month; Time period or displacement
+  0;  4;  23;    0;       -1024;   11;         Day; Time period or displacement
+  0;  4;  24;    0;       -2048;   12;        Hour; Time period or displacement
+  0;  4;  25;    0;       -2048;   12;      Minute; Time period or displacement
+  0;  4;  26;    0;       -4096;   13;      Second; Time period or displacement
+  0;  4;  31;    0;           0;    8;        Hour; Duration of time relating to following value
+  0;  4;  32;    0;           0;    6;      Minute; Duration of time relating to following value
+  0;  4;  41;    0;       -1440;   12;      Minute; "Time difference, UTC -LMT (see Note 6)"
+  0;  4;  43;    0;           0;    9;         Day; Day of the year
+  0;  4;  53;    0;           0;    6;     Numeric; Number of days with precipitation equal to or more than 1 mm
+# Class 05 - Location (horizontal -1)
+  0;  5;   1;    5;    -9000000;   25;      Degree; Latitude (high accuracy)
+  0;  5;   2;    2;       -9000;   15;      Degree; Latitude (coarse accuracy)
+  0;  5;  11;    5;    -9000000;   25;      Degree; Latitude increment (high accuracy)
+  0;  5;  12;    2;       -9000;   15;      Degree; Latitude increment (coarse accuracy)
+  0;  5;  21;    2;           0;   16; Degree_true; Bearing or azimuth
+  0;  5;  22;    2;           0;   16; Degree_true; Solar azimuth
+  0;  5;  30;    0;           0;   12;      Degree; Direction (spectral)
+  0;  5;  31;    0;           0;   12;     Numeric; Row number
+  0;  5;  33;   -1;           0;   16;           m; Pixel size on horizontal - 1
+  0;  5;  40;    0;           0;   24;     Numeric; Orbit number
+  0;  5;  41;    0;           0;    8;     Numeric; Scan line number
+  0;  5;  42;    0;           0;    6;     Numeric; Channel number
+  0;  5;  43;    0;           0;    8;     Numeric; Field of view number
+  0;  5;  52;    0;           0;    5;     Numeric; Channel number increment
+  0;  5;  53;    0;           0;    5;     Numeric; Field of view number increment
+# Class 06 - Location (horizontal - 2)
+  0;  6;   1;    5;   -18000000;   26;      Degree; Longitude (high accuracy)
+  0;  6;   2;    2;      -18000;   16;      Degree; Longitude (coarse accuracy)
+  0;  6;  11;    5;   -18000000;   26;      Degree; Longitude increment (high accuracy)
+  0;  6;  12;    2;      -18000;   16;      Degree; Longitude increment (coarse accuracy)
+  0;  6;  21;   -1;           0;   13;           m; Distance
+  0;  6;  30;    5;           0;   13;     rad m-1; Wave number (spectral)
+  0;  6;  31;    0;           0;   12;     Numeric; Column number
+  0;  6;  33;   -1;           0;   16;           m; Pixel size on horizontal - 2
+# Class 07 - Location (vertical)
+  0;  7;   1;    0;        -400;   15;           m; Height of station
+  0;  7;   2;   -1;         -40;   16;           m; Height or altitude
+  0;  7;   3;   -1;        -400;   17;      m2 s-2; Geopotential
+  0;  7;   4;   -1;           0;   14;          Pa; Pressure
+  0;  7;   5;    0;        -400;   12;           m; Height increment
+  0;  7;   6;    0;           0;   15;           m; Height above station
+  0;  7;   7;    0;       -1000;   17;           m; Height
+  0;  7;   8;    0;      -10000;   20;      m2 s-2; Geopotential
+  0;  7;  21;    2;       -9000;   15;      Degree; Elevation
+  0;  7;  22;    2;       -9000;   15;      Degree; Solar elevation
+  0;  7;  24;    2;       -9000;   15;      Degree; Satellite zenith angle
+  0;  7;  25;    2;       -9000;   15;      Degree; Solar zenith angle
+  0;  7;  61;    2;           0;   14;           m; Depth below land surface
+  0;  7;  62;    1;           0;   17;           m; Depth below sea/water surface
+# Class 08 - Significance qualifiers
+  0;  8;   1;    0;           0;    7;  Flag_Table; Vertical sounding significance
+  0;  8;   2;    0;           0;    6;  Code_Table; Vertical significance (surface observations)
+  0;  8;   3;    0;           0;    6;  Code_Table; Vertical significance (satellite observations)
+  0;  8;   4;    0;           0;    3;  Code_Table; Phase of aircraft flight
+  0;  8;   5;    0;           0;    4;  Code_Table; Meteorological attribute significance
+  0;  8;   7;    0;           0;    4;  Code_Table; Dimensional significance
+  0;  8;  11;    0;           0;    6;  Code_Table; Meteorological feature
+  0;  8;  12;    0;           0;    2;  Code_Table; Land/sea qualifier
+  0;  8;  13;    0;           0;    2;  Code_Table; Day/night qualifier
+  0;  8;  14;    0;           0;    4;  Code_Table; Qualifier for runway visual range
+  0;  8;  16;    0;           0;    3;  Code_Table; Change qualifier of a trend-type forecast or an aerodrome forecast
+  0;  8;  17;    0;           0;    2;  Code_Table; Qualifier of the time when the forecast change is expected
+  0;  8;  20;    0;           0;   16;     Numeric; Total number of missing entities (with respect to accumulation or average)
+  0;  8;  21;    0;           0;    5;  Code_Table; Time significance
+  0;  8;  22;    0;           0;   16;     Numeric; Total number (with respect to accumulation or average)
+  0;  8;  23;    0;           0;    6;  Code_Table; First order statistics
+  0;  8;  24;    0;           0;    6;  Code_Table; Difference statistics
+  0;  8;  25;    0;           0;    4;  Code_Table; Time difference qualifier
+  0;  8;  30;    0;           0;   13;     Numeric; "Manual on Codes (Volume I.1, Section C) Code table from which data are derived"
+  0;  8;  51;    0;           0;    3;  Code_Table; Qualifier for number of missing values in calculation of statistic
+  0;  8;  52;    0;           0;    5;  Code_Table; Condition for which number of days of occurrence follows
+  0;  8;  53;    0;           0;    2;  Code_Table; Day of occurrence qualifier
+  0;  8;  60;    0;           0;    4;  Code_Table; Sample scanning mode significance
+  0;  8;  70;    0;           0;    4;  Code_Table; TOVS/ATOVS product qualifier
+  0;  8;  72;    0;           0;    3;  Code_Table; Pixel(s) type
+# Class 10 - Non-coordinate location (vertical)
+  0; 10;   1;    0;        -400;   15;           m; Height of land surface
+  0; 10;   2;   -1;         -40;   16;           m; Height
+  0; 10;   3;   -1;        -400;   17;      m2 s-2; Geopotential
+  0; 10;   4;   -1;           0;   14;          Pa; Pressure
+  0; 10;   7;    0;       -1000;   17;           m; Height
+  0; 10;   8;    0;      -10000;   20;      m2 s-2; Geopotential
+  0; 10;  31;    2; -1073741824;   31;           m; "In direction of the North Pole, distance from the Earth�s centre"
+  0; 10;  50;    2;           0;   16;           m; Standard deviation altitude
+  0; 10;  51;   -1;           0;   14;          Pa; Pressure reduced to mean sea level
+  0; 10;  52;   -1;           0;   14;          Pa; Altimeter setting (QNH)
+  0; 10;  60;   -1;       -1024;   11;          Pa; Pressure change
+  0; 10;  61;   -1;        -500;   10;          Pa; 3-hour pressure change
+  0; 10;  62;   -1;       -1000;   11;          Pa; 24-hour pressure change
+  0; 10;  63;    0;           0;    4;  Code_Table; Characteristic of pressure tendency
+  0; 10;  70;    0;        -400;   16;           m; Indicated aircraft altitude
+# Class 11 - Wind and turbulence
+  0; 11;   1;    0;           0;    9; Degree_true; Wind direction
+  0; 11;   2;    1;           0;   12;       m s-1; Wind speed
+  0; 11;   3;    1;       -4096;   13;       m s-1; u-component
+  0; 11;   4;    1;       -4096;   13;       m s-1; v-component
+  0; 11;   5;    1;        -512;   10;      Pa s-1; w-component
+  0; 11;   6;    2;       -4096;   13;       m s-1; w-component
+  0; 11;  11;    0;           0;    9; Degree_true; Wind direction at 10 m
+  0; 11;  12;    1;           0;   12;       m s-1; Wind speed at 10 m
+  0; 11;  13;    0;           0;    9; Degree_true; Wind direction at 5 m
+  0; 11;  14;    1;           0;   12;       m s-1; Wind speed at 5 m
+  0; 11;  16;    0;           0;    9; Degree_true; Extreme counterclockwise wind direction of a variable wind
+  0; 11;  17;    0;           0;    9; Degree_true; Extreme clockwise wind direction of a variable wind
+  0; 11;  19;    0;           0;    7;           %; Steadiness of wind*
+  0; 11;  21;    9;      -65536;   17;         s-1; Relative vorticity
+  0; 11;  22;    9;      -65536;   17;         s-1; Divergence
+  0; 11;  23;   -2;      -65536;   17;      m2 s-1; Velocity potential
+  0; 11;  31;    0;           0;    4;  Code_Table; Degree of turbulence
+  0; 11;  32;   -1;         -40;   16;           m; Height of base of turbulence
+  0; 11;  33;   -1;         -40;   16;           m; Height of top of turbulence
+  0; 11;  34;    1;       -1024;   11;       m s-1; Vertical gust velocity
+  0; 11;  35;    2;       -8192;   14;       m s-2; Vertical gust acceleration
+  0; 11;  36;    1;           0;   10;       m s-1; Maximum derived equivalent vertical gust speed
+  0; 11;  41;    1;           0;   12;       m s-1; Maximum wind speed (gusts)
+  0; 11;  42;    1;           0;   12;       m s-1; Maximum wind speed (10-min mean wind)
+  0; 11;  43;    0;           0;    9; Degree_true; Maximum wind gust direction
+  0; 11;  44;    0;           0;    9; Degree_true; Mean wind direction for surface - 1500 m (5000 feet)
+  0; 11;  45;    1;           0;   12;       m s-1; Mean wind speed for surface - 1500 m (5000 feet)
+  0; 11;  49;    0;           0;    9; Degree_true; Standard deviation of wind direction
+  0; 11;  50;    1;           0;   12;       m s-1; Standard deviation of horizontal wind speed
+  0; 11;  51;    1;           0;    8;       m s-1; Standard deviation of vertical wind speed
+  0; 11;  61;    1;           0;   12;       m s-1; Absolute wind shear in 1 km layer below
+  0; 11;  62;    1;           0;   12;       m s-1; Absolute wind shear in 1 km layer above
+  0; 11;  70;    0;           0;   32;   CCITT_IA5; Designator of the runway affected by wind shear (including ALL)
+  0; 11;  71;    3;        -128;   14;      m2 s-2; Turbulent vertical momentum flux
+  0; 11;  72;    3;        -128;   11;     K m s-1; Turbulent vertical buoyancy flux
+  0; 11;  73;    2;       -1024;   13;      m2 s-2; Turbulent kinetic energy
+  0; 11;  74;    2;       -1024;   10;      m2 s-2; Dissipation energy
+  0; 11;  75;    2;           0;    8;    m2/3 s-1; Mean turbulence intensity (eddy dissipation rate)
+  0; 11;  76;    2;           0;    8;    m2/3 s-1; Peak turbulence intensity (eddy dissipation rate)
+# Class 12 - Temperature
+  0; 12;   1;    1;           0;   12;           K; Temperature/dry-bulb temperature
+  0; 12;   2;    1;           0;   12;           K; Wet-bulb temperature
+  0; 12;   3;    1;           0;   12;           K; Dew-point temperature
+  0; 12;   4;    1;           0;   12;           K; Dry-bulb temperature at 2 m
+  0; 12;   5;    1;           0;   12;           K; Wet-bulb temperature at 2 m
+  0; 12;   6;    1;           0;   12;           K; Dew-point temperature at 2 m
+  0; 12;   7;    1;           0;   12;           K; Virtual temperature
+  0; 12;  11;    1;           0;   12;           K; "Maximum temperature, at height and over period specified"
+  0; 12;  12;    1;           0;   12;           K; "Minimum temperature, at height and over period specified"
+  0; 12;  13;    1;           0;   12;           K; "Ground minimum temperature, past 12 hours"
+  0; 12;  14;    1;           0;   12;           K; "Maximum temperature at 2 m, past 12 hours"
+  0; 12;  15;    1;           0;   12;           K; "Minimum temperature at 2 m, past 12 hours"
+  0; 12;  16;    1;           0;   12;           K; "Maximum temperature at 2 m, past 24 hours"
+  0; 12;  17;    1;           0;   12;           K; "Minimum temperature at 2 m, past 24 hours"
+  0; 12;  30;    1;           0;   12;           K; Soil temperature
+  0; 12;  51;    1;           0;   10;           K; Standard deviation temperature
+  0; 12;  52;    1;           0;   12;           K; Highest daily mean temperature
+  0; 12;  53;    1;           0;   12;           K; Lowest daily mean temperature
+  0; 12;  61;    1;           0;   12;           K; Skin temperature
+  0; 12;  62;    1;           0;   12;           K; Equivalent black body temperature
+  0; 12;  63;    1;           0;   12;           K; Brightness temperature
+  0; 12;  64;    1;           0;   12;           K; Instrument temperature
+  0; 12;  71;    1;           0;   12;           K; Coldest cluster temperature
+  0; 12;  72;    6;           0;   31;  W m-2 sr-1; Radiance
+# Class 13 - Hygrographic and hydrological elements
+  0; 13;   1;    5;           0;   14;     kg kg-1; Specific humidity
+  0; 13;   2;    5;           0;   14;     kg kg-1; Mixing ratio
+  0; 13;   3;    0;           0;    7;           %; Relative humidity
+  0; 13;   4;   -1;           0;   10;          Pa; Vapour pressure
+  0; 13;   5;    3;           0;    7;      kg m-3; Vapour density
+  0; 13;   6;   -1;         -40;   16;           m; Mixing heights
+  0; 13;  11;    1;          -1;   14;      kg m-2; Total precipitation/total water equivalent
+  0; 13;  12;    2;          -2;   12;           m; Depth of fresh snow
+  0; 13;  13;    2;          -2;   16;           m; Total snow depth
+  0; 13;  14;    4;           0;   12;  kg m-2 s-1; Rainfall/water equivalent of snow (averaged rate)
+  0; 13;  15;    7;           0;   12;       m s-1; Snowfall  (averaged rate)
+  0; 13;  16;    0;           0;    7;      kg m-2; Precipitable water
+  0; 13;  19;    1;          -1;   14;      kg m-2; Total precipitation past 1 hour
+  0; 13;  20;    1;          -1;   14;      kg m-2; Total precipitation past 3 hours
+  0; 13;  21;    1;          -1;   14;      kg m-2; Total precipitation past 6 hours
+  0; 13;  22;    1;          -1;   14;      kg m-2; Total precipitation past 12 hours
+  0; 13;  23;    1;          -1;   14;      kg m-2; Total precipitation past 24 hours
+  0; 13;  31;    0;           0;    7;      kg m-2; Evapotranspiration
+  0; 13;  32;    1;           0;    8;      kg m-2; Evaporation/evapotranspiration
+  0; 13;  33;    1;           0;   10;      kg m-2; Evaporation/evapotranspiration
+  0; 13;  38;    0;           0;    2;  Code_Table; Superadiabatic indicator
+  0; 13;  39;    0;           0;    3;  Code_Table; Terrain type (ice/snow)
+  0; 13;  41;    0;           0;    4;  Code_Table; Pasquill-Gifford stability category
+  0; 13;  42;    0;         -20;    6;           K; Parcel lifted index (to 500 hPa)
+  0; 13;  43;    0;         -20;    6;           K; Best lifted index (to 500 hPa)
+  0; 13;  51;    0;           0;    4;  Code_Table; "Frequency group, precipitation"
+  0; 13;  52;    1;          -1;   14;      kg m-2; Highest daily amount of precipitation
+# Class 14 - Radiation and radiance
+  0; 14;   1;   -3;       -2048;   12;       J m-2; "Long-wave radiation, integrated over 24 hours"
+  0; 14;   2;   -3;       -2048;   12;       J m-2; "Long-wave radiation, integrated over period specified"
+  0; 14;   3;   -3;       -2048;   12;       J m-2; "Short-wave radiation, integrated over 24 hours"
+  0; 14;   4;   -3;       -2048;   12;       J m-2; "Short-wave radiation, integrated over period specified"
+  0; 14;  11;   -3;       -2048;   12;       J m-2; "Net long-wave radiation, integrated over 24 hours"
+  0; 14;  12;   -3;       -2048;   12;       J m-2; "Net long-wave radiation, integrated over period specified"
+  0; 14;  13;   -3;       -2048;   12;       J m-2; "Net short-wave radiation, integrated over 24 hours"
+  0; 14;  14;   -3;       -2048;   12;       J m-2; "Net short-wave radiation, integrated over period specified"
+  0; 14;  15;   -4;      -16384;   15;       J m-2; "Net radiation, integrated over 24 hours"
+  0; 14;  16;   -4;      -16384;   15;       J m-2; "Net radiation, integrated over period specified"
+  0; 14;  17;   -3;       -2048;   12;       W m-2; Instantaneous long-wave radiation
+  0; 14;  18;   -3;       -2048;   12;       W m-2; Instantaneous short-wave radiation
+  0; 14;  19;    0;           0;    7;           %; Surface albedo
+  0; 14;  20;   -4;           0;   15;       J m-2; "Global solar radiation, integrated over 24 hours"
+  0; 14;  21;   -4;           0;   15;       J m-2; "Global radiation, integrated over period specified"
+  0; 14;  22;   -4;           0;   15;       J m-2; "Diffuse solar radiation, integrated over 24 hours"
+  0; 14;  23;   -4;           0;   15;       J m-2; "Diffuse solar radiation, integrated over period specified"
+  0; 14;  24;   -4;           0;   15;       J m-2; "Direct solar radiation, integrated over 24 hours"
+  0; 14;  25;   -4;           0;   15;       J m-2; "Direct solar radiation, integrated over period specified"
+  0; 14;  26;    0;           0;    7;           %; Albedo at the top of clouds
+  0; 14;  27;    0;           0;    7;           %; Albedo
+  0; 14;  31;    0;           0;   11;      Minute; Total sunshine
+  0; 14;  32;    0;           0;   10;        Hour; Total sunshine
+  0; 14;  33;    0;           0;    9;           %; Total sunshine
+  0; 14;  42;    0;           0;    7;           %; Bidirectional reflectance
+  0; 14;  45;    0;           0;   11;Wm-2 sr-1 cm-1; Channel radiance
+# Class 15 - Physical/chemical constituents
+  0; 15;   1;    0;           0;   10;      Dobson; Ozone
+  0; 15;   2;    2;           0;   10;     Numeric; Air mass (slant path at 22 km)
+  0; 15;  11;    3;       14000;   13;  log (1/m2); Log 10 of integrated electron density
+  0; 15;  15;    0;           0;   31;     Numeric; Maximum image spectral component before normalization
+# Class 19 - Synoptic features
+  0; 19;   1;    0;           0;    6;  Code_Table; Type of synoptic feature
+  0; 19;   2;   -2;           0;   12;           m; Effective radius of feature
+  0; 19;   3;    0;           0;    8;       m s-1; Wind speed threshold
+  0; 19;   4;   -2;           0;   12;           m; Effective radius with respect to wind speeds above threshold
+  0; 19;   5;    0;           0;    9; Degree_true; Direction of motion of feature
+  0; 19;   6;    2;           0;   14;       m s-1; Speed of motion of feature
+  0; 19;   7;   -3;           0;   12;           m; Effective radius of feature
+  0; 19;   8;    0;           0;    3;  Code_Table; Vertical extent of circulation
+  0; 19;   9;   -3;           0;   12;           m; Effective radius with respect to wind speeds above threshold (large storms)
+# Class 20 - Observed phenomena
+  0; 20;   1;   -1;           0;   13;           m; Horizontal visibility
+  0; 20;   2;   -1;           0;    7;           m; Vertical visibility
+  0; 20;   3;    0;           0;    9;  Code_Table; Present weather
+  0; 20;   4;    0;           0;    5;  Code_Table; Past weather (1)
+  0; 20;   5;    0;           0;    5;  Code_Table; Past weather (2)
+  0; 20;   8;    0;           0;    5;  Code_Table; Cloud distribution for aviation
+  0; 20;   9;    0;           0;    4;  Code_Table; General Weather Indicator (TAF/METAR)
+  0; 20;  10;    0;           0;    7;           %; Cloud cover (total)
+  0; 20;  11;    0;           0;    4;  Code_Table; Cloud amount
+  0; 20;  12;    0;           0;    6;  Code_Table; Cloud type
+  0; 20;  13;   -1;         -40;   11;           m; Height of base of cloud
+  0; 20;  14;   -1;         -40;   11;           m; Height of top of cloud
+  0; 20;  15;   -1;           0;   14;          Pa; Pressure at base of cloud
+  0; 20;  16;   -1;           0;   14;          Pa; Pressure at top of cloud
+  0; 20;  17;    0;           0;    4;  Code_Table; Cloud top description
+  0; 20;  18;    0;           0;    2;  Code_Table; Tendency of runway visual range
+  0; 20;  19;    0;           0;   72;   CCITT_IA5; Significant present or forecast weather
+  0; 20;  20;    0;           0;   32;   CCITT_IA5; Significant recent weather phenomena
+  0; 20;  31;    2;           0;    7;           m; Ice deposit (thickness)
+  0; 20;  32;    0;           0;    3;  Code_Table; Rate of ice accretion
+  0; 20;  33;    0;           0;    4;  Flag_Table; Cause of ice accretion
+  0; 20;  34;    0;           0;    5;  Code_Table; Sea ice concentration
+  0; 20;  35;    0;           0;    4;  Code_Table; Amount and type of ice
+  0; 20;  36;    0;           0;    5;  Code_Table; Ice situation
+  0; 20;  37;    0;           0;    5;  Code_Table; Ice development
+  0; 20;  38;    0;           0;   12; Degree_true; Bearing of ice edge
+  0; 20;  39;   -1;           0;   13;           m; Ice distance
+  0; 20;  41;    0;           0;    4;  Code_Table; Airframe icing
+  0; 20;  51;    0;           0;    7;           %; Amount of low clouds
+  0; 20;  52;    0;           0;    7;           %; Amount of middle clouds
+  0; 20;  53;    0;           0;    7;           %; Amount of high clouds
+  0; 20;  61;    0;           0;   12;           m; Runway visual range (RVR)
+  0; 20;  62;    0;           0;    5;  Code_Table; State of the ground (with or without snow)
+  0; 20;  63;    0;           0;   10;  Code_Table; Special phenomena
+  0; 20;  81;    0;           0;    7;           %; Cloud amount in segment
+  0; 20;  82;    0;           0;    7;           %; Amount segment cloud free
+  0; 20;  90;    0;           0;    4;  Code_Table; Special clouds
+# Class 21 - Radar data
+  0; 21;   1;    0;         -64;    7;          dB; Horizontal reflectivity
+  0; 21;   2;    0;         -64;    7;          dB; Vertical reflectivity
+  0; 21;   3;    1;          -5;    7;          dB; Differential reflectivity
+  0; 21;   5;    0;         -65;    6;          dB; Linear depolarisation ratio 
+  0; 21;   6;    0;         -65;    6;          dB; Circular depolarisation ratio 
+  0; 21;  11;    0;        -128;    8;       m s-1; Doppler mean velocity in X-direction
+  0; 21;  12;    0;        -128;    8;       m s-1; Doppler mean velocity in Y-direction
+  0; 21;  13;    0;        -128;    8;       m s-1; Doppler mean velocity in Z-direction
+  0; 21;  14;    1;       -4096;   13;       m s-1; Doppler mean velocity (radial)
+  0; 21;  17;    1;           0;    8;       m s-1; Doppler velocity spectral width
+  0; 21;  21;   -3;           0;    4;           m; Echo tops 
+  0; 21;  30;    0;         -32;    8;          dB; Signal to noise ratio
+  0; 21;  31;    0;           0;    7;      kg m-2; Vertically integrated liquid-water content
+  0; 21;  36;    7;           0;   12;       m s-1; Radar rainfall intensity 
+  0; 21;  41;   -2;           0;    8;           m; Bright-band height 
+  0; 21;  51;    0;        -256;    8;          dB; Signal power above 1 mW
+  0; 21;  62;    2;       -5000;   13;          dB; Backscatter
+  0; 21;  63;    1;           0;   10;           %; Radiometric resolution (noise value)
+  0; 21;  64;    0;           0;    8;     Numeric; Clutter noise estimate
+  0; 21;  65;    0;        -127;    8;     Numeric; Missing packet counter
+  0; 21;  66;    0;           0;   12;  Flag_Table; Wave scatterometer product confidence data
+  0; 21;  67;    0;           0;   13;  Flag_Table; Wind product confidence data
+  0; 21;  68;    0;           0;    8;  Flag_Table; Radar altimeter product confidence data
+  0; 21;  69;    0;           0;   10;  Flag_Table; SST product confidence data
+  0; 21;  71;    0;           0;   16;     Numeric; Peakiness
+  0; 21;  72;    0;           0;    4;  Flag_Table; Satellite altimeter calibration status
+  0; 21;  73;    0;           0;    9;  Flag_Table; Satellite altimeter instrument mode
+  0; 21;  75;    0;           0;    8;     Numeric; Image spectrum intensity
+  0; 21;  76;    0;           0;    3;  Code_Table; Representation of intensities
+  0; 21;  77;    3;           0;   14;           m; Altitude correction (ionosphere)
+  0; 21;  78;    3;           0;    9;           m; Altitude correction (dry troposphere)
+  0; 21;  79;    3;        2000;   10;           m; Altitude correction (wet troposphere)
+  0; 21;  80;    3;           0;   11;           m; Altitude correction (calibration constant)
+  0; 21;  81;    3;           0;   10;           m; Open loop correction (height-time loop)
+  0; 21;  82;    3;       -3000;   14;          dB; Open loop correction (auto gain control)
+  0; 21;  85;    0;           0;    4;     Numeric; ATSR sea surface temperature across- track band number
+# Class 22 - Oceanographic elements
+  0; 22;   1;    0;           0;    9; Degree_true; Direction of waves 
+  0; 22;   2;    0;           0;    9; Degree_true; Direction of wind waves 
+  0; 22;   3;    0;           0;    9; Degree_true; Direction of swell waves 
+  0; 22;   4;    0;           0;    9; Degree_true; Direction of current 
+  0; 22;  11;    0;           0;    6;           s; Period of waves 
+  0; 22;  12;    0;           0;    6;           s; Period of wind waves 
+  0; 22;  13;    0;           0;    6;           s; Period of swell waves 
+  0; 22;  21;    1;           0;   10;           m; Height of waves 
+  0; 22;  22;    1;           0;   10;           m; Height of wind waves 
+  0; 22;  23;    1;           0;   10;           m; Height of swell waves 
+  0; 22;  25;    2;           0;   10;           m; Standard deviation wave height
+  0; 22;  26;    2;           0;   10;           m; Standard deviation of significant wave height
+  0; 22;  31;    2;           0;   13;       m s-1; Speed of current 
+  0; 22;  37;    3;      -10000;   15;           m; Tidal elevation with respect to national land datum
+  0; 22;  38;    3;      -10000;   15;           m; Tidal elevation with respect to local chart datum
+  0; 22;  39;    3;       -5000;   12;           m; Meteorological residual tidal elevation (surge or offset)
+  0; 22;  40;    3;       -5000;   14;           m; Meteorological residual tidal elevation (surge or offset)
+  0; 22;  41;    1;           0;   12;           K; Sea-surface temperature (15-day running mean)
+  0; 22;  42;    1;           0;   12;           K; Sea/water temperature
+  0; 22;  43;    2;           0;   15;           K; Sea/water temperature
+  0; 22;  44;    1;           0;   14;       m s-1; Sound velocity 
+  0; 22;  50;    2;           0;    8;           K; Standard deviation sea-surface temperature
+  0; 22;  61;    0;           0;    4;  Code_Table; State of the sea 
+  0; 22;  62;    2;           0;   14;Part per thousand; Salinity
+  0; 22;  63;    0;           0;   14;           m; Total water depth 
+  0; 22;  67;    0;           0;   10;  Code_Table; Instrument type for water temperature profile measurement
+  0; 22;  68;    0;           0;    7;  Code_Table; Water temperature profile recorder types
+  0; 22;  70;    2;           0;   13;           m; Significant wave height
+  0; 22;  71;    1;           0;    9;           s; Spectral peak wave period
+  0; 22;  72;    0;           0;   13;           m; Spectral peak wave length
+  0; 22;  73;    2;           0;   13;           m; Maximum wave height
+  0; 22;  74;    1;           0;    9;           s; Average wave period
+  0; 22;  75;    0;           0;   13;           m; Average wave length
+  0; 22;  76;    0;           0;    9; Degree_true; Direction from which dominant waves are coming
+  0; 22;  77;    0;           0;    9;      Degree; Directional spread of dominant wave
+  0; 22;  78;    0;           0;   12;           s; Duration of wave record
+  0; 22;  79;    0;           0;   16;           m; Length of wave record
+  0; 22;  80;    3;           0;   10;          Hz; Waveband central frequency
+  0; 22;  81;    5;           0;   13;         m-1; Waveband central wave number
+  0; 22;  82;    2;           0;   20;        m2 s; Maximum non-directional spectral wave density
+  0; 22;  83;    2;           0;   20;          m3; Maximum non-directional spectral wave number
+  0; 22;  84;    0;           0;    7;     Numeric; Band containing maximum non- directional spectral wave density
+  0; 22;  85;    0;           0;    7;     Numeric; Spectral wave density ratio
+  0; 22;  86;    0;           0;    9; Degree_true; Mean direction from which waves are coming
+  0; 22;  87;    0;           0;    9; Degree_true; Principal direction from which waves are coming
+  0; 22;  88;    2;           0;    7;     Numeric; First normalized polar coordinate from Fourier coefficients
+  0; 22;  89;    2;           0;    7;     Numeric; Second normalized polar coordinate from Fourier coefficients
+  0; 22;  90;    2;           0;   20;        m2 s; Non-directional spectral estimate by wave frequency
+  0; 22;  91;    2;           0;   20;          m3; Non-directional spectral estimate by wave number
+  0; 22;  92;    2;           0;   20;  m2 rad-1 s; Directional spectral estimate by wave frequency
+  0; 22;  93;    2;           0;   20;          m4; Directional spectral estimate by wave number
+  0; 22;  94;    0;           0;    7;     Numeric; Total number of wave bands
+  0; 22;  95;    0;           0;    8;      Degree; Directional spread of individual waves
+  0; 22;  96;    3;           0;    4;         s-1; Spectral band width
+  0; 22;  97;    0;           0;   14;           m; Mean wavelength > 731 m of image spectrum at low wave numbers
+  0; 22;  98;    0;           0;   14;           m; Wavelength spread (wavelength > 731 m) at low wave numbers
+  0; 22;  99;    0;           0;    9; Degree_true; Mean direction at low wave numbers (wavelength > 731 m)
+  0; 22; 100;    0;           0;    9;      Degree; Direction spread at low wave numbers(wavelength > 731 m)
+  0; 22; 101;    0;           0;   31;     Numeric; Total energy (wavelength > 731m) at low wave numbers
+  0; 22; 120;    0;           0;    5;  Code_Table; Tide station automated water level check
+  0; 22; 121;    0;           0;    5;  Code_Table; Tide station manual water level check
+  0; 22; 122;    0;           0;    5;  Code_Table; Tide station automated meteorological data check
+  0; 22; 123;    0;           0;    5;  Code_Table; Tide station manual meteorological data check
+# Class 23 - Dispersal and transport
+  0; 23;   1;    0;           0;    3;  Code_Table; Accident early notification � article applicable
+  0; 23;   2;    0;           0;    5;  Code_Table; Activity or facility involved in incident
+  0; 23;   3;    0;           0;    3;  Code_Table; Type of release 
+  0; 23;   4;    0;           0;    3;  Code_Table; Countermeasures taken near border
+  0; 23;   5;    0;           0;    2;  Code_Table; Cause of incident 
+  0; 23;   6;    0;           0;    3;  Code_Table; Incident situation 
+  0; 23;   7;    0;           0;    3;  Code_Table; Characteristics of release
+  0; 23;   8;    0;           0;    2;  Code_Table; State of current release 
+  0; 23;   9;    0;           0;    2;  Code_Table; State of expected release 
+  0; 23;  16;    0;           0;    2;  Code_Table; Possibility of significant chemical toxic health effect
+  0; 23;  17;    6;           0;   20;     m3 s-1 ; Flow discharge of major recipient
+  0; 23;  18;    0;           0;    3;  Code_Table; Release behaviour over time
+  0; 23;  19;    0;      -15000;   17;           m; Actual release height
+  0; 23;  21;    0;      -15000;   17;           m; Effective release height
+  0; 23;  22;    0;           0;   24;           m; Distance of release point or site of incident
+  0; 23;  23;    1;           0;   12;     m s-1  ; Main transport speed in the atmosphere
+  0; 23;  24;    2;           0;   13;     m s-1  ; Main transport speed in water
+  0; 23;  25;    2;           0;   13;     m s-1  ; Main transport speed in ground water
+  0; 23;  27;    0;           0;    9; Degree_true; Main transport direction in the atmosphere
+  0; 23;  28;    0;           0;    9; Degree_true; Main transport direction in water
+  0; 23;  29;    0;           0;    9; Degree_true; Main transport direction in ground water
+  0; 23;  31;    0;           0;    2;  Code_Table; Possibility that plume will encounter precipitation in State in which incident occurred
+  0; 23;  32;    0;           0;    2;  Code_Table; Plume will encounter change in wind direction and/or speed flag
+# Class 24 - Radiological elements
+  0; 24;   1;  -11;           0;   28;         Bq*; Estimate of amount of radioactivity released up to specified time
+  0; 24;   2;  -11;           0;   28;          Bq; Estimated maximum potential release
+  0; 24;   3;    0;           0;    5;  Code_Table; Composition of release
+  0; 24;   4;    0;           0;   16;   CCITT_IA5; Element name
+  0; 24;   5;    0;           0;    9;     Numeric; Isotope mass
+  0; 24;  11;    2;           0;   32;     mSv*/**; Dose
+  0; 24;  12;    2;           0;   32;         mSv; Trajectory dose (defined location and expected time of arrival)
+  0; 24;  13;    2;           0;   32;         mSv; Gamma dose in air along the main transport path (defined location and time period)
+  0; 24;  21;    2;           0;   32;      Bq m-3; Air concentration (of named isotope type including gross beta)
+  0; 24;  22;    2;           0;   32;      Bq 1-1; Concentration in precipitation (of named isotope type)
+# Class 25 - Processing information
+  0; 25;   1;   -1;           0;    6;           m; Range-gate length
+  0; 25;   2;    0;           0;    4;     Numeric; Number of gates averaged
+  0; 25;   3;    0;           0;    8;     Numeric; Number of integrated pulses
+  0; 25;   4;    0;           0;    2;  Code_Table; Echo processing
+  0; 25;   5;    0;           0;    2;  Code_Table; Echo integration
+  0; 25;   6;    0;           0;    3;  Code_Table; Z to R conversion
+  0; 25;   7;    0;           0;   12;     Numeric; Z to R conversion factor
+  0; 25;   8;    2;           0;    9;     Numeric; Z to R conversion exponent
+  0; 25;   9;    0;           0;    4;  Flag_Table; Calibration method
+  0; 25;  10;    0;           0;    4;  Code_Table; Clutter treatment
+  0; 25;  11;    0;           0;    2;  Code_Table; Ground occultation correction (screening)
+  0; 25;  12;    0;           0;    2;  Code_Table; Range attenuation correction
+  0; 25;  13;    0;           0;    2;  Flag_Table; Bright-band correction
+  0; 25;  14;    0;           0;   12;     Numeric; Azimuth clutter cut-off (see Note)
+  0; 25;  15;    0;           0;    2;  Flag_Table; Radome attenuation correction
+  0; 25;  16;    5;           0;    6;      dB m-1; Clear-air attenuation correction
+  0; 25;  17;    0;           0;    2;  Flag_Table; Precipitation attenuation correction
+  0; 25;  18;    7;           0;    6;     Numeric; A to Z law for attenuation factor
+  0; 25;  19;    2;           0;    7;     Numeric; A to Z law for attenuation exponent
+  0; 25;  20;    0;           0;    2;  Code_Table; Mean speed estimation
+  0; 25;  21;    0;           0;    8;  Flag_Table; Wind computation enhancement
+  0; 25;  30;    0;           0;    2;  Code_Table; Running mean sea-surface temperature usage
+  0; 25;  32;    0;           0;    2;  Code_Table; Wind profiler mode information*
+  0; 25;  33;    0;           0;    2;  Code_Table; Wind profiler submode information*
+  0; 25;  34;    0;           0;    4;  Flag_Table; Wind profiler quality control test results* 
+  0; 25;  40;    0;           0;    4;  Code_Table; CO2 wind product derivation
+  0; 25;  41;    0;           0;    2;  Code_Table; Moving platform direction reporting method
+  0; 25;  42;    0;           0;    2;  Code_Table; Moving platform speed reporting method
+  0; 25;  43;    4;           0;   15;           s; Wave sampling interval (time)
+  0; 25;  44;    2;           0;   14;           m; Wave sampling interval (space)
+  0; 25;  45;    0;           0;   21;  Flag_Table; HIRS channel combination
+  0; 25;  46;    0;           0;    5;  Flag_Table; MSU channel combination
+  0; 25;  47;    0;           0;    4;  Flag_Table; SSU channel combination
+  0; 25;  48;    0;           0;   16;  Flag_Table; AMSU-A channel combination
+  0; 25;  49;    0;           0;    6;  Flag_Table; AMSU-B channel combination
+  0; 25;  51;    0;           0;    7;  Flag_Table; AVHRR channel combination
+  0; 25;  53;    0;           0;   12;  Flag_Table; Observation quality
+  0; 25;  60;    0;           0;   14;     Numeric; Software identification
+  0; 25;  70;    0;           0;    4;     Numeric; Major frame count
+  0; 25;  71;    0;           0;    5;     Numeric; Frame count
+  0; 25;  75;    0;           0;    5;     Numeric; Satellite antenna corrections version number
+  0; 25;  76;    8;           0;   30;     Log m-1; Log-10 of (Temperature-radiance central wavenumber) for ATOVS
+  0; 25;  77;    5;     -100000;   18;     Numeric; Bandwidth correction coefficient 1 for ATOVS
+  0; 25;  78;    5;           0;   17;     Numeric; Bandwidth correction coefficient 2 for ATOVS
+  0; 25;  79;    4;           0;   24;       W m-2; Albedo-radiance solar filtered irradiance for ATOVS
+  0; 25;  80;   10;           0;   14;           m; Albedo-radiance equivalent filter width for ATOVS
+  0; 25;  85;    0;           0;    7;     Numeric; Fraction of clear pixels in HIRS FOV
+# Class 26 - Non-coordinate location (time)
+  0; 26;   1;    1;           0;   12;        Hour; Principal time of daily reading in UTC of maximum temperature
+  0; 26;   2;    1;           0;   12;        Hour; Principal time of daily reading in UTC of minimum temperature
+  0; 26;   3;    0;       -1440;   12;      Minute; Time difference
+  0; 26;  10;    0;           0;   26;  Flag_Table; Hours included
+# Class 27 - Non-coordinate location (horizontal - 1)
+  0; 27;   1;    5;    -9000000;   25;      Degree; Latitude (high accuracy)
+  0; 27;   2;    2;       -9000;   15;      Degree; Latitude (coarse accuracy)
+  0; 27;   3;    2;       -9000;   15;      Degree; Alternate latitude
+  0; 27;  20;    0;           0;   16;     Numeric; Satellite location counter
+  0; 27;  21;    0;           0;   16;     Numeric; Satellite sublocation dimension
+  0; 27;  31;    2; -1073741824;   31;           m; "In direction of 0 degrees longitude, distance from the Earth�s centre"
+# Class 28 - Non-coordinate location (horizontal - 2)
+  0; 28;   1;    5;   -18000000;   26;      Degree; Longitude (high accuracy)
+  0; 28;   2;    2;      -18000;   16;      Degree; Longitude (coarse accuracy)
+  0; 28;   3;    2;      -18000;   16;      Degree; Alternate longitude
+  0; 28;  31;    2; -1073741824;   31;           m; "In direction 90 degrees East, distance from the Earth�s centre"
+# Class 29 - Map data
+  0; 29;   1;    0;           0;    3;  Code_Table; Projection type
+  0; 29;   2;    0;           0;    3;  Code_Table; Coordinate grid type
+# Class 30 - Image
+  0; 30;   1;    0;           0;    4;     Numeric; Pixel value (4 bits)
+  0; 30;   2;    0;           0;    8;     Numeric; Pixel value (8 bits)
+  0; 30;   4;    0;           0;   16;     Numeric; Pixel value (16 bits)
+  0; 30;  21;    0;           0;   12;     Numeric; Number of pixels per row
+  0; 30;  22;    0;           0;   12;     Numeric; Number of pixels per column
+  0; 30;  31;    0;           0;    4;  Code_Table; Picture type
+  0; 30;  32;    0;           0;   16;  Flag_Table; Combination with other data
+# Class 31 - Data description operator qualifiers
+  0; 31;   0;    0;           0;    1;     Numeric; Short delayed descriptor replication factor
+  0; 31;   1;    0;           0;    8;     Numeric; Delayed descriptor replication factor
+  0; 31;   2;    0;           0;   16;     Numeric; Extended delayed descriptor replication factor
+  0; 31;  11;    0;           0;    8;     Numeric; Delayed descriptor and data repetition factor
+  0; 31;  12;    0;           0;   16;     Numeric; Extended delayed descriptor and data repetition factor
+  0; 31;  21;    0;           0;    6;  Code_Table; Associated field significance
+  0; 31;  31;    0;           0;    1;  Flag_Table; Data present indicator
+# Class 33 - Quality information
+  0; 33;   1;    
+;           0;    1;           
+; Reserved
+  0; 33;   2;    0;           0;    2;  Code_Table; Quality information
+  0; 33;   3;    0;           0;    3;  Code_Table; Quality information
+  0; 33;   4;    
+;           0;    3;           
+; Reserved
+  0; 33;   7;    0;           0;    7;           %; Per cent confidence
+  0; 33;  20;    0;           0;    3;  Code_Table; Quality control indication of following value
+  0; 33;  21;    0;           0;    2;  Code_Table; Quality of following value
+  0; 33;  22;    0;           0;    2;  Code_Table; Quality of buoy satellite transmission
+  0; 33;  23;    0;           0;    2;  Code_Table; Quality of buoy location
+  0; 33;  24;    0;           0;    4;  Code_Table; Station elevation quality mark (for mobile stations)
+  0; 33;  25;    0;           0;    3;  Code_Table; ACARS interpolated values
+  0; 33;  26;    0;           0;    6;  Code_Table; Mixing ratio quality
+  0; 33;  27;    0;           0;    3;  Code_Table; Location quality class (range of radius of 66 % confidence)
+  0; 33;  30;    0;           0;   24;  Flag_Table; Scan line status flags for ATOVS
+  0; 33;  31;    0;           0;   24;  Flag_Table; Scan line quality flags for ATOVS
+  0; 33;  32;    0;           0;   24;  Flag_Table; Channel quality flags for ATOVS
+  0; 33;  33;    0;           0;   24;  Flag_Table; Field of view quality flags for ATOVS
+  0; 33;  35;    0;           0;    4;  Code_Table; Manual/automatic quality control
+  0; 33;  36;    0;           0;    7;           %; Nominal confidence threshold
+  0; 33;  37;    0;           0;   20;  Flag_Table; Wind correlation error
diff --git a/data/tables/B3M-000-007-D b/data/tables/B3M-000-007-D
new file mode 100644
index 0000000..55c71e0
--- /dev/null
+++ b/data/tables/B3M-000-007-D
@@ -0,0 +1,1933 @@
+#
+# WMO source file name = BufrTabD.txt
+# Master Table D Version 7
+#
+#-----------------------------------------------------
+# F X Y --> Table D descriptor being defined
+#      F X Y --> 
+#      F X Y --> descriptors defining sequence for
+#      F X Y --> corresponding Table D descriptor
+#      -1 --> end of sequence designator
+#------------------------------------------------------
+#  Category 00 - BUFR table entries sequences
+  3   0   2
+      0   0   2  "Table A category, line 1"
+      0   0   3  "Table A category, line 2"
+     -1
+  3   0   3
+      0   0  10  "F,  part descriptor"
+      0   0  11  "X,  part descriptor"
+      0   0  12  "Y,  part descriptor"
+     -1
+  3   0   4
+      3   0   3
+      0   0  13  "Element name, line 1"
+      0   0  14  "Element name, line 2"
+      0   0  15  Units name
+      0   0  16  Units scale sign
+      0   0  17  Units scale
+      0   0  18  Units reference sign
+      0   0  19  Units reference value
+      0   0  20  Element data width
+     -1
+  3   0  10
+      3   0   3  Table D descriptor to be defined
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Delayed descriptor replication factor
+      0   0  30  Descriptor defining sequence
+     -1
+#  Category 01 - Location and Identification sequences
+  3   1   1
+      0   1   1  WMO block number
+      0   1   2  WMO station number
+     -1
+  3   1   2
+      0   1   3  WMO Region number
+      0   1   4  WMO Region sub-area
+      0   1   5  Buoy/platform identifier
+     -1
+  3   1   3
+      0   1  11  Ship's call sign
+      0   1  12  Direction of motion of moving observing platform
+      0   1  13  Speed of motion of moving observing platform
+     -1
+  3   1  11
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+     -1
+  3   1  12
+      0   4   4  Hour
+      0   4   5  Minute
+     -1
+  3   1  13
+      0   4   4  Hour
+      0   4   5  Minute
+      0   4   6  Second
+     -1
+  3   1  21
+      0   5   1  Latitude - high accuracy
+      0   6   1  Longitude - high accuracy
+     -1
+  3   1  22
+      0   5   1  Latitude - high accuracy
+      0   6   1  Longitude - high accuracy
+      0   7   1  Height of station
+     -1
+  3   1  23
+      0   5   2  Latitude
+      0   6   2  Longitude
+     -1
+  3   1  24
+      0   5   2  Latitude
+      0   6   2  Longitude
+      0   7   1  Height of station
+     -1
+  3   1  25
+      3   1  23  Latitude and longitude (coarse accuracy)
+      0   4   3  Day
+      3   1  12  Time
+     -1
+  3   1  26
+      3   1  21  Latitude and longitude (high accuracy)
+      0   4   3
+      0   4   3  (Time period in days)
+      0   4   4
+      0   4   4  (Time period in hours)
+      0   4   5
+      0   4   5  (Time period in minutes)
+     -1
+  3   1  31
+      3   1   1  WMO block and station number
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  22  "Latitude and longitude (high  accuracy), height of station"
+     -1
+  3   1  32
+      3   1   1  WMO block and station number
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  24  "Latitude and longitude (coarse accuracy), height of station"
+     -1
+#  (Buoy/platform � fixed)
+  3   1  33
+      0   1   5  Buoy/platform identifier
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  21  Latitude and longitude (high accuracy)
+     -1
+#  (Buoy/platform � fixed)
+  3   1  34
+      0   1   5  Buoy/platform identifier
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+     -1
+#  (Buoy/platform � moving)
+  3   1  35
+      0   1   5  Buoy/platform identifier
+      0   1  12  Direction of motion of moving observing platform
+      0   1  13  Speed of motion of moving observing platform
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+     -1
+#  (Ship)
+  3   1  36
+      3   1   3  Ship's call sign and motion
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+     -1
+#  (Land station for vertical soundings)
+  3   1  37
+      3   1   1  WMO block and station number
+      0   2  11  Radiosonde type
+      0   2  12  Radiosonde computational method
+      3   1  11  Date
+      3   1  12  Time
+      3   1  22  "Latitude and longitude (high accuracy), height of station"
+     -1
+#  (Land station for vertical soundings)
+  3   1  38
+      3   1   1  WMO block and station number
+      0   2  11  Radiosonde type
+      0   2  12  Radiosonde computational method
+      3   1  11  Date
+      3   1  12  Time
+      3   1  24  "Latitude and longitude (coarse accuracy), height of station"
+     -1
+#  (Ship for vertical soundings)
+  3   1  39
+      3   1   3  Ship's call sign and motion
+      0   2  11  Radiosonde type
+      0   2  12  Radiosonde computational method
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+     -1
+#  (Buoy/platform � fixed)
+  3   1  33
+      0   1   5  Buoy/platform identifier
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  21  Latitude and longitude (high accuracy)
+     -1
+#  (Buoy/platform � fixed)
+  3   1  34
+      0   1   5  Buoy/platform identifier
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+     -1
+#  (Buoy/platform � moving)
+  3   1035*
+      0   1   5  Buoy/platform identifier
+      0   1  12  Direction of motion of moving observing platform
+      0   1  13  Speed of motion of moving observing platform
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+     -1
+#  (Ship)
+  3   1  36
+      3   1   3  Ship's call sign and motion
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+     -1
+#  (Land station for vertical soundings)
+  3   1  37
+      3   1   1  WMO block and station number
+      0   2  11  Radiosonde type
+      0   2  12  Radiosonde computational method
+      3   1  11  Date
+      3   1  12  Time
+      3   1  22  "Latitude and longitude (high accuracy), height of station"
+     -1
+#  (Land station for vertical soundings)
+  3   1  38
+      3   1   1  WMO block and station number
+      0   2  11  Radiosonde type
+      0   2  12  Radiosonde computational method
+      3   1  11  Date
+      3   1  12  Time
+      3   1  24  "Latitude and longitude (coarse accuracy), height of station"
+     -1
+#  (Ship for vertical soundings)
+  3   1  39
+      3   1   3  Ship's call sign and motion
+      0   2  11  Radiosonde type
+      0   2  12  Radiosonde computational method
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+     -1
+#  (Radar parameters)
+  3   1  48
+      0   2 104  Antenna polarization
+      0   2 121  Mean frequency
+      0   2 113  Number of azimuth looks
+      0   2  26  Cross-track resolution
+      0   2  27  Along-track resolution
+      0   2 111  Radar incidence angle
+      0   2 140  Satellite radar beam azimuth angle
+      2   2 127  Change scale to �1
+      0   1  13  Radar platform velocity
+      2   2 126  Change scale to �2
+      0   7   1  Radar platform altitude
+      2   2   0  Change scale to Table B
+      0  25  10  Clutter treatment
+      0  21  64  Clutter noise estimate
+     -1
+#  (Radar beam data)
+  3   1  49
+      0   2 111  Radar incidence angle
+      0   2 112  Radar look angle
+      0  21  62  Backscatter
+      0  21  63  Radiometric resolution (Noise value)
+      0  21  65  Missing packet counter
+     -1
+  3   1  51
+      0   1   6  Aircraft identifier
+      0   2  61  Navigational system
+      3   1  11  Date
+      3   1  12  Time
+      3   1  21  "Latitude, longitude"
+      0   8   4  Phase of aircraft flight
+     -1
+  3   1  55
+      0   1   5  Buoy/platform identifier
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  21  Latitude and longitude (high accuracy)
+      0   1  12  Direction of motion of moving observing platform
+      0   1  14  Platform drift speed (high precision)
+     -1
+#  (Radar location(s))
+  3   1  62
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   1   1  WMO block and station number
+     -1
+#  (ACARS identification)
+  3   1  65
+      0   1   6  Aircraft flight number (see Note)
+      0   1   8  Aircraft registration number (see Note)
+      0   2   1  Type of station
+      0   2   2  Type of instrumentation for wind measurement
+      0   2   5  Precision of temperature observation
+      0   2  62  Type of aircraft data relay system
+      0   2  70  Original specification of latitude/longitude
+      0   2  65  ACARS ground receiving station
+     -1
+#  (ACARS location)
+  3   1  66
+      3   1  11  "Year, month, day"
+      3   1  13  "Hour, minute, second"
+      3   1  23  Latitude and longitude (coarse accuracy)
+      0   7   4  Pressure
+      0   2  64  Aircraft roll angle quality
+      0   8   4  Phase of aircraft flight
+     -1
+#  (Satellite identifier/Generating resolution)
+  3   1  71
+      0   1   7  Satellite identifier
+      0   1  31  Generating centre
+      0   2  20  Satellite classification
+      0   2  28  Segment size at nadir in X direction
+      0   2  29  Segment size at nadir in Y direction
+     -1
+#  (Satellite identification)
+  3   1  72
+      3   1  71  "Satellite identification, Generation resolution"
+      3   1  11  Date
+      3   1  13  Time
+      3   1  21  "Latitude, longitude"
+     -1
+#  Category 02 - Meteorological sequences common to surface data
+  3   2   1
+      0  10   4  Pressure (at station level)
+      0  10  51  Pressure reduced to mean sea level
+      0  10  61  3-hour pressure change
+      0  10  63  Characteristic of pressure tendency
+     -1
+#  (High altitude station)
+  3   2   2
+      0  10   4  Pressure (at station level)
+      0   7   4  Pressure level
+      0  10   3  Geopotential of pressure level
+      0  10  61  3-hour pressure change
+      0  10  63  Characteristic of pressure tendency
+     -1
+  3   2   3
+      0  11  11  Wind direction (10 m)
+      0  11  12  Wind speed (10 m)
+      0  12   4  Temperature (2 m)
+      0  12   6  Dew point (2 m)
+      0  13   3  Relative humidity
+      0  20   1  Horizontal visibility
+      0  20   3  Present weather
+      0  20   4  Past weather (1)
+      0  20   5  Past weather (2)
+     -1
+#  (General cloud information)
+  3   2   4
+      0  20  10  Cloud cover (total)
+      0   8   2  Vertical significance
+      0  20  11  Cloud amount
+      0  20  13  Height of base of cloud
+      0  20  12  Cloud type
+      0  20  12  Cloud type
+      0  20  12  Cloud type
+     -1
+  3   2   5
+      0   8   2  Vertical significance
+      0  20  11  Cloud amount
+      0  20  12  Cloud type
+      0  20  13  Height of base of cloud
+     -1
+  3   2   6
+      0  10   4  Pressure (at station level)
+      0  10  51  Pressure reduced to mean sea level
+      0  10  62  24-hour pressure change
+      0  10  63  Characteristic of pressure tendency
+     -1
+#  (Low altitude station)
+  3   2  11
+      3   2   1  Pressure and pressure change
+      3   2   3  "Wind, temperature, humidity, visibility, weather"
+      3   2   4  Significant cloud layer
+     -1
+#  (High altitude station)
+  3   2  12
+      3   2   2  Pressure and pressure change
+      3   2   3  "Wind, temperature, humidity, visibility, weather"
+      3   2   4  Significant cloud information
+     -1
+  3   2  13
+      3   2   6  Pressure and pressure change
+      3   2   3  "Wind, temperature, humidity, visibility, weather"
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Delayed descriptor replication factor
+      3   2   5  Cloud layer information
+     -1
+  3   2  21
+      0  22   1  Direction of waves
+      0  22  11  Period of waves
+      0  22  21  Height of waves
+     -1
+  3   2  22
+      0  22   2  Direction of wind waves
+      0  22  12  Period of wind waves
+      0  22  22  Height of wind waves
+     -1
+  3   2  23
+      0  22   3  Direction of swell waves
+      0  22  13  Period of swell waves
+      0  22  23  Height of swell waves
+     -1
+  3   2  24
+      3   2  22  Wind waves
+      1   1   2  Replicate 1 descriptor 2 times
+      3   2  23  Swell waves (2 systems of swell)
+     -1
+  3   2  51
+      0  10   4  Pressure
+      0  10  51  Pressure reduced to mean sea level
+      0   7   4  Pressure (vertical location)
+      0  10   3  Geopotential
+      0  12   4  Dry-bulb temperature at 2 m
+      0  12  51  Standard deviation temperature
+      0  12  16  "Maximum temperature at 2 m, past 24 hours"
+      0  12  17  "Minimum temperature at 2 m, past 24 hours"
+      0  13   4  Vapour pressure
+      1   2   4  Replicate 2 descriptors 4 times
+      0   8  51  Qualifier for number of missing values in calculation of statistic
+      0   8  20  Total number of missing entities (with respect to accumulation or average)
+     -1
+#  Category 03 - Meteorological sequences common to vertical soundings data
+  3   3   1
+      0   7   3  Geopotential
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3   2
+      0   7   4  Pressure
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3   3
+      0   7   4  Pressure
+      0  10   3  Geopotential
+      0  12   1  Temperature
+      0  12   3  Dew point
+     -1
+  3   3   4
+      0   7   4  Pressure
+      0  10   3  Geopotential
+      0  12   1  Temperature
+      0  12   3  Dew point
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3  11
+      0   7   3  Geopotential
+      0   8   1  Vertical sounding significance
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3  12
+      0   7   4  Pressure
+      0   8   1  Vertical sounding significance
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3  13
+      0   7   4  Pressure
+      0   8   1  Vertical sounding significance
+      0  10   3  Geopotential
+      0  12   1  Temperature
+      0  13   3  Relative humidity
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3  14
+      0   7   4  Pressure
+      0   8   1  Vertical sounding significance
+      0  10   3  Geopotential
+      0  12   1  Temperature
+      0  12   3  Dew point
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3  21
+      0   7   4  Pressure (1)
+      0   7   4  Pressure (2)     defines layer
+      2   4   7  Add associated field of 7 bits
+      0  31  21  Additional field significance
+     -1
+  3   3  22
+      3   3  21  "Layer, quality"
+      0  10   3  Geopotential (layer mean thickness)
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  23
+      3   3  21  "Layer, quality"
+      0  12   1  Temperature (layer mean)
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  24
+      3   3  21  "Layer, quality"
+      0  13  16  Precipitation water
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  25
+      0   2  25  Satellite channel
+      2   4   7  Add associated field of 7 bits
+      0  31  21  Additional field significance
+      0  12  63  Brightness temperature
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  26
+      0   7   4  Pressure
+      0   8   3  Vertical significance
+      2   4   7  Add associated field of 7 bits
+      0  31  21  Additional field significance
+      0  12   1  Temperature
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  27
+      0   7   4  Pressure
+      2   4   7  Add associated field of 7 bits
+      0  31  21  Additional field significance
+      0  10   3  Geopotential
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  31
+      0   7   4  Pressure
+      0   8   3  Vertical significance (base of sounding)
+      0   7  21  Elevation (local zenith)
+      0   7  22  Solar elevation (solar zenith)
+      0   8  12  Land/sea qualifier
+      0  12  61  Skin temperature
+     -1
+  3   3  32
+      0  20  11  Cloud amount
+      0  20  16  Pressure at top of cloud
+     -1
+  3   3  33
+      0  20  10  Cloud cover (total)
+      0  20  16  Pressure at the top of cloud
+     -1
+#  (Wind sequence)
+  3   3  41
+      0   2 152  Geostationary satellite instrument used
+      0   2  23  Cloud motion computational method
+      0   7   4  Pressure
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+      0   2 153  Satellite channel centre frequency
+      0   2 154  Satellite channel band width
+      0  12  71  Coldest cluster T
+     -1
+#  Category 04 - Meteorological sequences common to satellite observations
+  3   4   1
+      0   8   3  Vertical significance
+      0  10   4  Pressure
+      0  12   1  Temperature
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   4   2
+      0   8   3  Vertical significance
+      0  10   4  Pressure
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   4   3
+      0   8   3  Vertical significance
+      0  12   1  Temperature
+     -1
+  3   4   4
+      0   8   3  Vertical significance
+      0  10   4  Pressure
+      0  20  10  Cloud cover (total)
+      0  12   1  Temperature
+     -1
+  3   4   5
+      0   2  24  Integrated mean humidity computational method
+      0   7   4  Pressure(1)
+      0   7   4  Pressure (2)    defines layer
+      0  13   3  Relative humidity
+     -1
+  3   4   6
+      0  14   1  Outgoing long-wave radiation
+      0  14   1  Incoming long-wave radiation
+      0  14   3  Outgoing short-wave radiation
+     -1
+#  (GOES-I/M info)
+  3   4  11
+      0   2 163  Height assignment method
+      0   2 164  Tracer correlation method
+      0   8  12  Land/sea qualifier
+      0   7  24  Satellite zenith angle
+      0   2 167  Origin of first guess information
+      0   8  21  Time significance
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+      0   4   4  Hour
+      0   8  21  Time significance
+      0   4  24  Time period or displacement
+      1  10   4  Replicate 10 descriptors 4 times
+      0   8  21  Time significance
+      0   4   4  Hour
+      0   4   5  Minute
+      0   4   6  Second
+      0   8  21  Time significance
+      0   4   4  Hour
+      0   4   5  Minute
+      0   4   6  Second
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+      1   3  10  Replicate 3 descriptors 10 times
+      0   2 163  Height assignment method
+      0   7   4  Pressure
+      0  12   1  Temperature
+     -1
+#  (Location of platform)
+  3   4  30
+      0  27  31  "In direction of 0 degree longitude, distance from the Earth�s centre"
+      0  28  31  "In direction of 90 degrees East longitude, distance from the Earth�s centre"
+      0  10  31  "In direction of North Pole, distance from Earth�s centre"
+     -1
+#  (Speed of platform)
+  3   4  31
+      0   1  41  Absolute platform velocity � first component
+      0   1  42  Absolute platform velocity � second component
+      0   1  43  Absolute platform velocity � third component
+     -1
+#  Category 06 - Meteorological or oceanographic sequences common to oceanographic observations
+  3   6   1
+      0   2  32  Indicator for digitization
+      1   2   0  Delayed replication of 2 descriptors
+      0  31   1  Replication factor
+      0   7  62  Depth below sea surface
+      0  22  42  Subsurface sea temperature
+     -1
+  3   6   2
+      0   2  31  Method of current measurement
+      0  22   4  Direction of current
+      0  22  31  Speed of current
+     -1
+  3   6   3
+      0   2   2  Wind instrumentation
+      0  11  11  Wind direction (10 m)
+      0  11  12  Wind speed (10 m)
+      0  12   4  Dry-bulb temperature (2 m)
+     -1
+  3   6   4
+      0   2  32  Indicator for digitization
+      0   2  33  Method of salinity/depth measurement
+      1   3   0  Delayed replication of 3 descriptors
+      0  31   1  Replication factor
+      0   7  62  Depth below sea surface
+      0  22  43  Subsurface sea temperature
+      0  22  62  Salinity
+     -1
+  3   6   5
+      0   2  31  Method of current measurement
+      1   3   0  Delayed replication of 3 descriptors
+      0  31   1  Replication factor
+      0   7  62  Depth below sea surface
+      0  22   4  Direction of current
+      0  22  31  Speed of current
+     -1
+#  (Under water sounding (optional) parameters)
+  3   6   6
+      3   6   3  Surface wind and temperature
+      3   6   2  Current
+      0  22  63  Total water depth
+     -1
+#  (Buoy spare block parameters)
+  3   6   7
+      0   1  12  Direction of motion of moving observing platform
+      0   1  14  Platform drift speed (high precision)
+      3   6   8  Buoy instrumentation
+      0   4  24  Time period
+      0  27   3  Alternate latitude
+      0  28   3  Alternate longitude
+     -1
+#  (Buoy instrumentation parameters)
+  3   6   8
+      0   2  34  Drogue type
+      0   2  35  Cable length
+      0   2  36  Buoy type
+     -1
+  3   6  20
+      3   6od or displacement, time increment"  "Tide station identification, date/time, water temperature, tide station tide data status, time period or displacement, time increment"
+      1   2   6  Replicate 2 descriptors 6 times
+      0  22  38  Tidal elevation with respect to local chart datum
+      0  22  39  Meteorological residual tidal elevation
+     -1
+  3   6  21
+      0   1  75  Tide station alphanumeric identification
+      3   1  11  "Year, month, day"
+      3   1  12  "Hour, minute"
+      0  22 122  Tide station automated meteorological data check
+      0  22 123  Tide station manual meteorological data check
+      0  12   1  Air temperature
+      3   3   2  "Pressure, wind direction, wind speed"
+     -1
+  3   6  22
+      0   1  75  Tide station alphanumeric identification
+      3   1  11  "Year, month, day"
+      3   1  12  "Hour, minute"
+      0  22  38  Tidal elevation with respect to local chart datum
+      0  22  39  Meteorological residual tidal elevation
+     -1
+  3   6  23
+      0   1  15  Station or site name
+      3   1  23  "Latitude, longitude"
+      3   1  11  "Year, month, day"
+      3   1  12  "Hour, minute"
+      0  22  38  Tidal level with respect to local chart datum
+      0  22  39  Meteorological residual tidal elevation
+      0  22 120  Tide station automated water level check
+      0  22 121  Tide station manual water level check
+     -1
+  3   6  24
+      0   1  75  Tide station alphanumeric identification
+      3   1  11  "Year, month, day"
+      3   1  12  "Hour, minute"
+      0  22  42  Sea/water temperature
+      0  22 120  Tide station automated water level check
+      0  22 121  Tide station manual water level check
+      0   4  25  Time period or displacement
+      0   4  15  Time increment
+     -1
+#  Category 07 - Surface report sequences (land)
+#  (Low altitude station)
+  3   7   1
+      3   1  31  "Identification, type, date/time, position (high accuracy), height"
+      3   2  11  Basic surface report
+     -1
+#  (Low altitude station)
+  3   7   2
+      3   1  32  "Identification, type, date/time, position (coarse accuracy), height"
+      3   2  11  Basic surface report
+     -1
+#  (Low altitude station)
+  3   7   3
+      3   7   1  Location (high accuracy) and basic report
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   2   5  Cloud layer information
+     -1
+#  (Low altitude station)
+  3   7   4
+      3   7   2  Location (coarse accuracy) and basic report
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   2   5  Cloud layer information
+     -1
+#  (Low altitude station)
+  3   7   5
+      3   7   1  Location (high accuracy) and basic report
+      1   1   4  Replicate 1 descriptor 4 times
+      3   2   5  Cloud layer information (4 layers)
+     -1
+#  (Low altitude station)
+  3   7   6
+      3   7   2  Location (coarse accuracy) and basic report
+      1   1   4  Replicate 1 descriptor 4 times
+      3   2   5  Cloud layer information (4 layers)
+     -1
+#  (High altitude station)
+  3   7   7
+      3   1  31  "Identification, type, date/time, position (high accuracy), height"
+      3   2  12  Basic surface report
+     -1
+#  (High altitude station)
+  3   7   8
+      3   1  32  "Identification, type, date/time, position (coarse accuracy), height"
+      3   2  12  Basic surface report
+     -1
+  3   7   9
+      3   1  31  "Identification, type, date/time, position (high accuracy), height"
+      3   2  13  Basic surface report
+     -1
+#  (Main part of data for representation of METAR/SPECI code in BUFR)
+  3   7  11
+      0   1  63  ICAO location indicator -CCCC
+      0   2   1  Type of station -(AUTO)
+      3   1  11  "Year, month, day (YY)"
+      3   1  12  "GG, gg"
+      3   1  24  "Latitude-longitude (coarse accuracy), height of station"
+      0   7   6  Height above station (= height of an anemometer)
+      0  11   1  Wind direction - ddd
+      0  11  16  Extreme counterclockwise wind direction of a variable wind - dndndn
+      0  11  17  Extreme clockwise wind direction of a variable wind - dxdxdx
+      0  11   2  Wind speed - ff
+      0  11  41  Maximum wind speed (gusts) - fmfm
+      0   7   6  Height above station (= height of a thermometer)
+      0  12   1  Temperature - T�T�
+      0  12   3  Dew-point temperature - T�dT�d
+      0  10  52  Altimeter setting (QNH) - PHPHPHPH
+      0  20   9  General Weather Indicator TAF/METAR
+     -1
+#  (DvVVVV)
+  3   7  12
+      1   3   0  Delayed replication of 3 descriptors
+      0  31   1  Number of replication (up to 3)
+      0   8  23  First order statistics
+      0   5  21  Direction of visibility observed - Dv
+      0  20   1  Horizontal visibility - VVVV
+     -1
+#  (DRDRVRVRVRVR)
+  3   7  13
+      1   6   0  Delayed replication of 6 descriptors
+      0  31   1  Number of replication (up to 4)
+      0   1  64  Runway designator - DRDR
+      0   8  14  Qualification for runway visual range
+      0  20  61  Runway visual range - VRVRVRVR
+      0   8  14  Qualification for runway visual range
+      0  20  61  Runway visual range - VRVRVRVR
+      0  20  18  Tendency of runway visual range - i
+     -1
+#  (w�w�)
+  3   7  14
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Number of replication (up to 3)
+      0  20  19  Significant present weather - w�w�
+     -1
+#  (Clouds group(s))
+  3   7  15
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Number of replication
+      3   2   5  (sequence descriptor)
+      0   8   2  Vertical significance (surface observation)
+      0  20  11  "Cloud amount (FEW, SCT, BKN and OVC) - NsNsNs"
+      0  20  12  Cloud type - CC
+      0  20  13  Height of base of cloud - hshshs
+      0  20   2  Vertical visibility - VVhshshs
+     -1
+#  (REw�w�)
+  3   7  16
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Number of replication (up to 3)
+      0  20  20  Significant recent weather phenomena - REw�w�
+     -1
+#  (Wind shear on runways(s))
+  3   7  17
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Number of replication
+      0  11  70  Runway designator of the runway affected by wind shear (including ALL) - WS RWYDRDR
+     -1
+#  (Trend-type landing forecast)
+  3   7  18
+      0   8  16  Change qualifier of a trend-type - TTTTT
+      1   2   0  Delayed replication of 2 descriptors
+      0  31   1  Number of replication (up to 2)
+      0   8  17  Qualifier of the time when the forecast - TT+G638
+      3   1  12  "GG, gg"
+      1   4   0  Delayed replication of 4 descriptor
+      0  31   1  Number of replication (up to 1)
+      0   7   6  Height above station
+      0  11   1  Wind direction - ddd
+      0  11   2  Wind speed - ff
+      0  11  41  Maximum wind speed (gusts) - fmfm
+      0  20   9  General Weather Indicator
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Number of replication (up to 1)
+      0  20   1  Horizontal visibility -  VVVV
+      3   7  14  w�w�
+     -1
+#  (Short METAR/SPECI)
+  3   7  20
+      3   7  11  Main part of data
+      3   7  14  w�w�
+      3   7  16  REw�w�
+     -1
+#  (Total sequence for representation of METAR/SPECI code in BUFR)
+  3   7  21
+      3   7  11  Main part of data
+      3   7  12  DvVVVV
+      3   7  13  DRDRVRVRVRVR
+      3   7  14  w�w�
+      3   7  15  Clouds group(s)
+      3   7  16  REw�w�
+      3   7  17  Wind shear on runway(s)
+      3   7  18  Trend-type landing forecast
+      3   7  15  Clouds group(s)
+     -1
+#  Category 08 - Surface report sequences (sea)
+#  (Buoy/platform � fixed)
+  3   8   1
+      3   1  33  "Identification, type, date/time, position (high accuracy)"
+      3   2  11  Basic surface report
+      0  22  42  Sea-surface temperature
+     -1
+#  (Buoy/platform � fixed)
+  3   8   2
+      3   1  34  "Identification, type, date/time, position (coarse accuracy)"
+      3   2  11  Basic surface report
+      0  22  42  Sea-surface temperature
+     -1
+#  (Buoy/platform � moving)
+  3   8   3
+      3   1  35  "Identification, movement, type, date/time, position (coarse accuracy)"
+      3   2  11  Basic surface report
+      0  22  42  Sea-surface temperature
+     -1
+#  (Ship)
+  3   8   4
+      3   1  36  "Identification, movement, type, date/time, position (coarse accuracy)"
+      3   2  11  Basic surface report
+      0  22  42  Sea-surface temperature
+     -1
+  3   8   5
+      3   8   4  Basic ship report
+      3   2  24  Wind waves and swell waves
+     -1
+#  (Buoy Section 1 optional parameters)
+  3   8   6
+      0  10   4  Pressure
+      0  10  61  3-hour pressure change
+      0  10  63  Characteristic of pressure tendency
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+      0  12   4  Dry-bulb temperature at 2 m
+      0  13   3  Relative humidity
+      0  22  42  Sea temperature
+     -1
+  3   8   7
+      3   1  55  "Identification, movement type, date/time, position (high accuracy)"
+      3   2  11  Basic surface report
+      0   7  62  Depth below sea/water surface
+      0  22  42  Sea/water temperature
+     -1
+#  Category 09 - Vertical sounding sequences (conventional data)
+#  (Vertical wind profile)
+  3   9   1
+      3   1  37  "Identification, etc. (land station, high accuracy position)"
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  11  Winds at heights
+     -1
+#  (Vertical wind profile)
+  3   9   2
+      3   1  38  "Identification, etc. (land station, coarse accuracy position)"
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  11  Winds at heights
+     -1
+#  (Vertical wind profile)
+  3   9   3
+      3   1  37  "Identification, etc. (land station, high accuracy position)"
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  12  Winds at pressure levels
+     -1
+#  (Vertical wind profile)
+  3   9   4
+      3   1  38  "Identification, etc. (land station, coarse accuracy position)"
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  12  Winds at pressure levels
+     -1
+#  (Vertical sounding with relative humidity)
+  3   9   5
+      3   1  37  "Identification, etc. (land station, high accuracy position)"
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  13  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical sounding with relative humidity)
+  3   9   6
+      3   1  38  "Identification, etc. (land station, coarse  accuracy position)"
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  13  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical sounding with dew-point data)
+  3   9   7
+      3   1  37  "Identification, etc. (land station, high accuracy position)"
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  14  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical sounding with dew-point data)
+  3   9   8
+      3   1  38  "Identification, etc. (land station, coarse accuracy position)"
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  14  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical wind profile)
+  3   9  11
+      3   1  39  "Ship's identification, etc."
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  11  Winds at heights
+     -1
+#  (Vertical wind profile)
+  3   9  12
+      3   1  39  "Ship's identification, etc."
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  12  Winds at pressure levels
+     -1
+#  (Vertical sounding with relative humidity)
+  3   9  13
+      3   1  39  "Ship's identification, etc."
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  13  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical sounding with dew-point data)
+  3   9  14
+      3   1  39  "Ship's identification, etc."
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  14  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical wind profile)
+  3   9  15
+      3   1  40  "Ship's identification, etc."
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  11  Winds at heights
+     -1
+#  (Vertical wind profile)
+  3   9  16
+      3   1  40  "Ship's identification, etc."
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  12  Winds at pressure levels
+     -1
+#  (Vertical sounding with relative humidity)
+  3   9  17
+      3   1  40  "Ship's identification, etc."
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  13  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical sounding with dew-point data)
+  3   9  18
+      3   1  40  "Ship's identification, etc."
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  14  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Wind profiler � wind data sounding)
+  3   9  19
+      3   1  31  "Identification, etc."
+      0   2   3  Type of measuring equipment used
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  11  Winds at heights
+     -1
+#  (Wind profiler � Cartesian coordinates)
+  3   9  20
+      3   1  31  "Identification, etc."
+      0   2   3  Type of measuring equipment used
+      1   4   0  Delayed replication of 4 descriptors
+      0  31   1  Replication factor
+      0   7   3  Geopotential
+      0  11   3  u-component
+      0  11   4  v-component
+      0  11   5  w-component
+     -1
+#  Category 10 - Vertical sounding sequences (satellite data)
+#  (Satellite � brightness temperature)
+  3  10   1
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  32  Cloud
+      1   1  26  Replicate 1 descriptor 26 times
+      3   3  25  Satellite channel and brightness temperature
+     -1
+#  (Satellite � low level)
+  3  10   2
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  32  Cloud
+      1   1   9  Replicate 1 descriptor 9 times
+      3   3  23  Layer mean temperature
+     -1
+#  (Satellite � high level)
+  3  10   3
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  32  Cloud
+      1   1   6  Replicate 1 descriptor 6 times
+      3   3  23  Layer mean temperature
+     -1
+#  (Satellite � precipitable water)
+  3  10   4
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  32  Cloud
+      1   1   3  Replicate 1 descriptor 3 times
+      3   3  24  Precipitable water
+     -1
+  3  10   5
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  33  Cloud
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Delayed descriptor replication factor
+      3   3  25  Satellite channel and brightness temperature
+     -1
+  3  10   6
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  33  Cloud
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Delayed descriptor replication factor
+      3   3  23  Layer mean temperature
+     -1
+  3  10   7
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  33  Cloud
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Delayed descriptor replication factor
+      3   3  24  Precipitable water
+     -1
+#  (ATOVS HIRS report)
+  3  10   8
+      3  10  11  ATOVS field of view variables
+      1   1  19  Replicate 1 descriptor 19 times
+      3  10  12  ATOVS channel variables
+      0   2 150  TOVS/ATOVS/AVHRR instrumentation channel number
+      0  25  79  Albedo-radiance solar filtered irradiance for ATOVS
+      0  25  80  Albedo-radiance equivalent filter width for ATOVS
+      0  33  32  Channel quality flags for ATOVS
+      0  14  45  Channel radiance
+     -1
+#  (ATOVS AMSU-A report)
+  3  10   9
+      3  10  11  ATOVS field of view variables
+      1   1  15  Replicate 1 descriptor 15 times
+      3  10  12  ATOVS channel variables
+     -1
+#  (ATOVS AMSU-B report)
+  3  10  10
+      3  10  11  ATOVS field of view variables
+      1   1   5  Replicate 1 descriptor 5 times
+      3  10  12  ATOVS channel variables
+     -1
+#  (ATOVS field of view variables)
+  3  10  11
+      0   8  70  TOVS/ATOVS product qualifier
+      0   1  33  Identification of originating/generating centre
+      0   1  34  Identification of originating/generating centre
+      0   8  70  TOVS/ATOVS product qualifier
+      0   1  33  Identification of originating/generating centre
+      0   1  34  Identification of originating/generating centre
+      0   1   7  Satellite identification
+      0   2  48  Satellite sensor indicator
+      0   5  40  Orbit number
+      0  25  75  Satellite antenna corrections version number
+      2   1 133  Change width
+      0   5  41  Scan line number
+      2   1   0  Change width
+      0   5  43  Field of view number
+      0  25  70  Major frame count
+      0  33  30  Scan line status flags for ATOVS
+      0  33  31  Scan line quality flags for ATOVS
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+      0   4   4  Hour
+      0   4   5  Minute
+      2   2 131  Change scale
+      2   1 138  Change width
+      0   4   6  Second
+      2   1   0  Change width
+      2   2   0  Change scale
+      0   5   1  Latitude
+      0   6   1  Longitude
+      2   2 126  Change scale
+      0   7   1  Height of station
+      2   2   0  Change scale
+      0   7  24  Satellite zenith angle
+      0   5  21  Satellite azimuth
+      0   7  25  Solar zenith angle
+      0   5  22  Solar azimuth
+      0  33  33  Field of view quality flags for ATOVS
+      0   2 151  Radiometer identifier
+      0  12  64  Instrument temperature
+      0   2 151  Radiometer identifier
+      0  12  64  Instrument temperature
+      0   2 151  Radiometer identifier
+      0  12  64  Instrument temperature
+      0   2 151  Radiometer identifier
+      0  12  64  Instrument temperature
+      0   2 151  Radiometer identifier
+      0  12  64  Instrument temperature
+     -1
+#  (ATOVS channel variables)
+  3  10  12
+      0   2 150  TOVS/ATOVS/AVHRR instrumentation channel number
+      0  25  76  Log�10 of (temperature-radiance central wavenumber) for ATOVS
+      0  25  77  Bandwidth correction coefficient 1 for ATOVS
+      0  25  78  Bandwidth correction coefficient 2 for ATOVS
+      0  33  32  Channel quality flags for ATOVS
+      2   1 132  Change width
+      2   2 129  Change scale
+      0  12  63  Brightness temperature
+      2   2   0  Change scale
+      2   1   0  Change width
+     -1
+#  (AVHRR (GAC) report)
+  3  10  13
+      0   1   7  Satellite ID
+      0   5  40  Orbit number
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+      0   4   4  Hour
+      0   4   5  Minute
+      0   4   6  Second
+      0   5   1  Latitude
+      0   6   1  Longitude
+      0   7  25  Solar zenith angle
+      0   5  43  Field of view number
+      0  25  85  Fraction of clear pixels in HIRS field of view
+      2   1 131  Change width
+      2   2 129  Change scale
+      0   2 150  TOVS/ATOVS/AVHRR instrumentation channel number
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  14  27  Albedo
+      0   8  72  Pixel(s) type
+      0  14  27  Albedo
+      0   2 150  TOVS/ATOVS/AVHRR instrumentation channel number
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  14  27  Albedo
+      0   8  72  Pixel(s) type
+      0  14  27  Albedo
+      0   2 150  ATOVS/AVHRR instrumentation channel number
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  14  27  Albedo
+      0   8  72  Pixel(s) type
+      0  14  27  Albedo
+      2   2   0  Change scale
+      2   1   0  Change width
+      2   1 132  Change width
+      2   2 129  Change scale
+      0   2 150  ATOVS/AVHRR instrumentation channel number
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   2 150  ATOVS/AVHRR instrumentation channel number
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   2 150  ATOVS/AVHRR instrumentation channel number
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      2   2   0  Change scale
+      2   1   0  Change width
+     -1
+#  (Satellite � geostationnary wind data)
+  3  10  14
+      3   1  72  "Satellite identification, date, time, latitude, longitude"
+      3   3  41  Wind sequence
+      3   4  11  GOES-I/M information
+     -1
+#  Category 11 - Single level report sequences (conventional data)
+#  (Aircraft reports)
+  3  11   1
+      3   1  51  "ASDAR aircraft identifier, navigational system, date/time, position, phase of aircraft flight"
+      0   7   2  Altitude
+      0  12   1  Temperature
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+      0  11  31  Degree of turbulence
+      0  11  32  Height of base of turbulence
+      0  11  33  Height of top of turbulence
+      0  20  41  Airframe icing
+     -1
+#  (ACARS reports)
+  3  11   2
+      3   1  65  ACARS identification
+      3   1  66  ACARS location
+      3  11   3  ACARS standard reported variables
+      3  11   4  ACARS supplementary reported variables
+     -1
+#  (ACARS standard reported variables)
+  3  11   3
+      0  10  70  Indicated aircraft altitude
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+      0  12   1  Temperature/dry-bulb temperature
+      0  13   2  Mixing ratio
+     -1
+#  (ACARS supplementary reported variables)
+  3  11   4
+      1   1   0  Delayed replication of one descriptor
+      0  31   0  Short delayed descriptor replication factor
+      0  11  34  Vertical gust velocity
+      1   1   0  Delayed replication of one descriptor
+      0  31   0  Short delayed descriptor replication factor
+      0  11  35  Vertical gust acceleration
+      1   1   0  Delayed replication of one descriptor
+      0  31   0  Short delayed descriptor replication factor
+      0  11  75  Mean turbulence intensity (eddy dissipation rate)
+      1   1   0  Delayed replication of one descriptor
+      0  31   0  Short delayed descriptor replication factor
+      0  11  76  Peak turbulence intensity (eddy dissipation rate)
+      1   1   0  Delayed replication of one descriptor
+      0  31   0  Short delayed descriptor replication factor
+      0  33  25  ACARS interpolated values
+      1   1   0  Delayed replication of one descriptor
+      0  31   0  Short delayed descriptor replication factor
+      0  33  26  Mixing ratio quality
+     -1
+#  Category 12 - Single level report sequences (satellite data)
+  3  12   1
+      3   1  43  "Satellite identifier, instrumentation, location, date/time"
+      3   4   1  "Cloud top pressure, temperature, wind"
+     -1
+  3  12   2
+      3   1  43  "Satellite identifier, instrumentation, location, date/time"
+      3   4   2  "Cloud top pressure, wind"
+     -1
+  3  12   3
+      3   1  42  "Satellite identifier, instrumentation, location, date/time"
+      3   4   3  Surface temperature
+     -1
+  3  12   4
+      3   1  42  "Satellite identifier, instrumentation, location, date/time"
+      3   4   4  Cloud cover
+     -1
+  3  12   5
+      3   1  42  "Satellite identifier, instrumentation, location, date/time"
+      0  20  14  Height of top of cloud
+     -1
+  3  12   6
+      3   1  44  "Satellite identifier, instrumentation, location, date/time"
+      3   4   5  Layer mean relative humidity
+     -1
+  3  12   7
+      3   1  42  "Satellite identifier, instrumentation, location, date/time"
+      3   4   6  Radiation
+     -1
+#  "(Orbital information, Part I)"
+  3  12  10
+      0   1   7  Satellite identifier
+      0   5  40  Orbit number
+      0   2  21  Satellite instrumentation
+      0   5  41  Scan line number
+      0   4   1  Year
+      0   4  43  Day of year
+     -1
+#  "(Orbital information, Part II)"
+  3  12  11
+      2   2 131  Change scale
+      2   1 149  Change width
+      0   4   6  Second
+      2   1   0  Change width
+      2   2 126  Change scale
+      0  10   2  Height
+      2   2   0  Change scale
+      0   5  43  Field of view number
+      0   5  53  Field of view number increment
+     -1
+#  (HIRS brightness temperatures � channels 1�19)
+  3  12  12
+      2   2 129  Change scale
+      2   1 132  Change width
+      1   1  19  Replicate 1 descriptor 19 times
+      0  12  63  Brightness temperature
+      2   1   0  Change width
+      2   2   0  Change scale
+     -1
+#  (HIRS brightness temperatures � channel 20)
+  3  12  13
+      0   5  42  Channel number
+      2   2 129  Change scale
+      2   1 135  Change width
+      0  12  63  Brightness temperature
+      2   1   0  Change width
+      2   2   0  Change scale
+     -1
+#  (HIRS satellite data)
+  3  12  14
+      3  12  10  "Orbital information, Part I"
+      3  12  11  "Orbital information, Part II"
+      1   5  56  Replicate 5 descriptors 56 times
+      3   1  23  Latitude and longitude (coarse accuracy)
+      0   5  42  Channel number
+      0   5  52  Channel number increment
+      3  12  12  HIRS brightness temperatures � channels 1�19
+      3  12  13  HIRS brightness temperature � channel 20
+     -1
+#  (MSU brightness temperatures � channels 1�4)
+  3  12  15
+      1   9  11  Replicate 9 descriptors 11 times
+      3   1  23  Latitude and longitude (coarse accuracy)
+      0   5  42  Channel number
+      0   5  52  Channel number increment
+      2   2 129  Change scale
+      2   1 132  Change width
+      1   1   4  Replicate 1 descriptor 4 times
+      0  12  63  Brightness temperature
+      2   2   0  Change scale
+      2   1   0  Change width
+     -1
+#  (MSU satellite data)
+  3  12  16
+      3  12  10  "Orbital information, Part I"
+      3  12  11  "Orbital information, Part II"
+      3  12  15  MSU brightness temperatures � channels 1�4
+     -1
+#  (SSU brightness temperatures � channels 1�3)
+  3  12  17
+      1   9   8  Replicate 9 descriptors 8 times
+      3   1  23  Latitude and longitude (coarse accuracy)
+      0   5  42  Channel number
+      0   5  52  Channel number increment
+      2   2 129  Change scale
+      2   1 132  Change width
+      1   1   3  Replicate 1 descriptor 3 times
+      0  12  63  Brightness temperature
+      2   2   0  Change scale
+      2   1   0  Change width
+     -1
+#  (SSU satellite data)
+  3  12  18
+      3  12  10  "Orbital information, Part I"
+      3  12  11  "Orbital information, Part II"
+      3  12  17  SSU brightness temperatures � channels 1�3
+     -1
+#  (Wave scatterometer product with width change for wave number (spectral))
+  3  12  19
+      3   1  47  Product header
+      3   1  48  Radar parameters
+      0  15  15  Maximum spectrum composition before normalisation
+      0  29   2  Coordinate grid type
+      0  21  76  Representation of intensities
+      1   6  12  Repeat next 6 descriptors 12 times
+      2   1 129  Change width to 14 bits
+      0   6  30  Wave number (spectral)
+      2   1   0  Change width to Table B
+      1   2  12  Repeat next 2 descriptors 12 times
+      0   5  30  Direction (spectral)
+      0  21  75  Image spectrum intensity
+      0  21  66  Wave scatterometer product confidence data
+     -1
+#  (Wave scatterometer product)
+  3  12  20
+      3   1  47  Product header
+      3   1  48  Radar parameters
+      0  15  15  Maximum spectrum composition before normalization
+      0  29   2  Coordinate grid type
+      0  21  76  Representation of intensities
+      1   4  12  Repeat next 4 descriptors 12 times
+      0   6  30  Wave number (spectral)
+      1   2  12  Repeat next 2 descriptors 12 times
+      0   5  30  Direction (spectral)
+      0  21  75  Spectral intensity
+      0  21  66  Wave scatterometer product confidence data
+     -1
+#  (Wind scatterometer product)
+  3  12  21
+      3   1  47  Product header
+      1   1   3  Repeat 1 descriptor 3 times
+      3   1  49  Radar beam data
+      0  11  12  Wind speed at 10 m
+      0  11  11  Wind direction at 10 m
+      0  21  67  Wind product confidence data
+     -1
+#  (Radar altimeter product)
+  3  12  22
+      3   1  47  Product header
+      0   8  22  Number in average
+      0  11  12  Wind speed
+      0  11  50  Standard deviation of horizontal wind speed
+      0  22  70  Significant wave height
+      0  22  26  Standard deviation of significant wave height
+      3  12  41  Altitude
+      0  10  50  Standard deviation of altitude
+      0  21  68  Radar altimeter product confidence data
+      0  21  71  Peakiness
+      0  21  72  Altimeter calibration status
+      0  21  73  Altimeter instrument mode
+      3  12  42  Altitude corrections
+      0  21  62  Backscatter
+      0  15  11  Log 10 of integrated electron density
+     -1
+#  (ATSR sea surface temperature product)
+  3  12  23
+      3   1  47  Product header
+      1   3   3  Repeat 3 descriptors 3 times
+      0   8  22  Number in average
+      0  12  61  Skin temperature
+      0  22  50  Standard deviation of sea surface temperature
+      0  21  69  SST product confidence data
+      0  21  85  ATSR sea surface temperature across-track band number
+     -1
+#  (Wave scatterometer product enhanced)
+  3  12  24
+      3  12  20  (Wave scatterometer product)
+      0   8  60  Sample scanning mode significance � range
+      0   8  22  Number in sample
+      0   8  60  Sample scanning mode signification � horizontal
+      0   8  22  Number in sample
+      0  25  14  Azimuth clutter cut-off
+      0  22 101  Total energy (wavelength > 731 m)
+      0  22  97  Mean wavelength of image spectrum
+      0  22  98  Wavelength spread (wavelength > 731 m)
+      0  22  99  Mean direction (wavelength > 731 m)
+      0  22 100  Direction spread (wavelength > 731 m)
+     -1
+#  (Wave scatterometer enhanced product (with change of width for wave number (spectral))
+  3  12  25
+      3  12  19  Wave scatterometer product with width change for wave number (spectral)
+      0   8  60  Sample scanning mode significance � range
+      0   8  22  Number in sample
+      0   8  60  Sample scanning mode significance � horizontal
+      0   8  22  Number in sample
+      0  25  14  Azimuth clutter cut-off
+      0  22 101  Total energy (wavelength > 731 m)
+      0  22  97  Mean wavelength of image spectrum
+      0  22  98  Wavelength spread (wavelength > 731 m)
+      0  22  99  Mean direction (wavelength > 731 m)
+      0  22 100  Direction spread (wavelength > 731 m)
+     -1
+#  (Altitude)
+  3  12  41
+      2   1 141  Change width to 28 bits
+      2   2 130  Change scale to 2
+      0   7   1  Altitude
+      2   1   0  Change width back to Table B
+      2   2   0  Change scale back to Table B
+     -1
+#  (Altitude corrections)
+  3  12  42
+      0  21  77  "Altitude correction, ionosphere"
+      0  21  78  "Altitude correction, dry troposphere"
+      0  21  79  "Altitude correction, wet troposphere"
+      0  21  80  "Altitude correction, calibration constant"
+      0  21  81  Open loop height-time loop calibration correction
+      0  21  82  Open loop automatic gain control calibration correction
+     -1
+#  Category 13 - Sequences common to image data
+#  (Radar reflectivity values)
+  3  13   9
+      0  21   1  Horizontal reflectivity
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      0  21   1  Horizontal reflectivity
+     -1
+#  (Radar rainfall intensities)
+  3  13  10
+      0  21  36  Radar rainfall intensity
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      0  21  36  Radar rainfall intensity
+     -1
+#  (Non run-length encoded row for Pixel value (4 bits))
+  3  13  31
+      0   6   2  First longitude location minus one increment
+      0   6  12  Longitude increment
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   2  Extended replication factor
+      0  30   1  Pixel value (4 bits)
+     -1
+#  (Non run-length encoded picture data for Pixel value (4 bits))
+  3  13  32
+      0   5   2  First latitude location minus one increment
+      0   5  12  Latitude increment (signed value so cannot cross pole)
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   2  Extended replication factor
+      3  13  31  Non run-length encoded row
+     -1
+#  (Run-length encoded row for Pixel value (4 bits))
+  3  13  41
+      0   6   2  First longitude location minus one increment
+      1  10   0  Delayed replication of 10 descriptors
+      0  31   1  Replication factor
+      1   4   0  Delayed replication of 4 descriptors
+      0  31   1  Replication factor
+      0   6  12  Longitude increment
+      1   1   0  Delayed replication of 1 descriptor
+      0  31  12  Repetition factor
+      0  30   1  Pixel value (4 bits)
+      0   6  12  Longitude increment
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      0  30   1  Pixel value (4 bits)
+     -1
+#  (Run-length encoded picture data for Pixel value (4 bits))
+  3  13  42
+      0   5   2  First latitude location minus one increment
+      0   5  12  Latitude increment (signed value so cannot cross pole)
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   2  Extended replication factor
+      3  13  41  Run-length encoded row
+     -1
+#  "(Run-length encoded picture data for Pixel value (4 bits), regular grid)"
+  3  13  43
+      0   6   2  First longitude location minus one increment
+      0   5   2  First latitude location minus one increment
+      0   5  12  Latitude increment
+      1  12   0  Delayed replication of 12 descriptors
+      0  31   1  Replication factor
+      1  10   0  Delayed replication of 10 descriptors
+      0  31   1  Replication factor
+      1   4   0  Delayed replication of 4 descriptors
+      0  31   1  Replication factor
+      0   6  12  Longitude increment
+      1   1   0  Delayed replication of 1 descriptor
+      0  31  11  Repetition factor
+      0  30   1  Pixel value (4 bits)
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      0  30   1  Pixel value (4 bits)
+     -1
+#  Category 15 - Oceanographic report sequences
+#  (Typically reported underwater sounding without optional fields)
+  3  15   1
+      0   1  11  Ship's call sign
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+      3   6   1  "Depth, temperature"
+     -1
+#  (Typically reported underwater sounding without optional fields)
+  3  15   2
+      0   1  11  Ship's call sign
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+      3   6   4  "Depth, temperature, salinity"
+     -1
+#  Category 16 - Synoptic feature sequences
+  3  16   1
+      3   1  11  "Year, month, day"
+      0   4   4  Hour
+      3   1  23  Latitude and longitude (coarse accuracy)
+      0   1  21  Synoptic feature identifier
+      0   2  41  Method for estimating reports related to synoptic features
+      0  19   1  Type of synoptic feature
+      0  10  51  Pressure reduced to mean sea level
+      0  19   2  Effective radius of feature
+      0  19   3  Wind speed threshold (15 m s�1 typically)
+      0  19   4  Effective radius with respect to wind speeds above threshold
+     -1
+#  (Header)
+  3  16   2
+      0   8  21  Data time (analysis)
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+      0   4   4  Hour
+      0   4   5  Minute
+      0   1  33  Originating/generating centre
+      0   8  21  Validity time (fcst)
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+      0   4   4  Hour
+      0   4   5  Minute
+      0   7   2  Flight level (altitude) (base of chart layer)
+      0   7   2  Flight level (altitude) (top of chart layer)
+     -1
+#  (Jet stream)
+  3  16   3
+      1  10   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature (jet stream value)
+      0   8   7  Dimensional significance (value for line)
+      1   4   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0  10   2  Flight level (altitude)
+      0  11   2  Wind speed
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  (Turbulence)
+  3  16   4
+      1  11   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature (value for turbulence)
+      0   8   7  Dimensional significance (value for area)
+      0   7   2  Flight level (altitude) (base of layer)
+      0   7   2  Flight level (altitude) (top of layer)
+      1   2   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0  11  31  Degree of turbulence
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  (Storm)
+  3  16   5
+      1   8   0  Delayed replication
+      0  31   1  Replication
+      0   8   5  Meteorological attribute significance (storm centre)
+      0   8   7  Dimensional significance (value for point)
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0   1  26  WMO storm name (use �unknown� for a sandstorm)
+      0  19   1  Synoptic features (value for type of storm)
+      0   8   7  Dimensional significance (cancel)
+      0   8   5  Meteorological attribute significance (cancel/end of object)
+     -1
+#  (Cloud)
+  3  16   6
+      1  12   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature (value for cloud)
+      0   8   7  Dimensional significance (value for area)
+      0   7   2  Flight level (altitude) (base of layer)
+      0   7   2  Flight level (altitude) (top of layer)
+      1   2   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0  20  11  Cloud amount
+      0  20  12  Cloud type
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  (Front)
+  3  16   7
+      1  10   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature (value for type of front)
+      0   8   7  Dimensional significance (value for line)
+      1   4   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0  19   5  Direction of feature
+      0  19   6  Speed of feature
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  (Tropopause)
+  3  16   8
+      1  11   0  Delayed replication
+      0  31   1  Replication
+      0   8   1  Vertical significance (bit 3 set for tropopause)
+      0   8   7  Dimensional significance (value for point)
+      0   8  23  Statistic (type of tropopause value)
+      1   3   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0  10   2  Height/altitude
+      0   8  23  Statistic (cancel)
+      0   8   7  Dimensional significance (cancel)
+      0   8   1  Vertical significance (cancel/end of object)
+     -1
+#  (Airframe icing area)
+  3  16   9
+      1  11   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature (value for airframe icing)
+      0   8   7  Dimensional significance (value for area)
+      0   7   2  Flight level (altitude) (base of layer)
+      0   7   2  Flight level (altitude) (top of layer)
+      1   2   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0  20  41  Airframe icing (type of airframe icing)
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  (Name of feature)
+  3  16  10
+      1   7   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature
+      0   8   7  Dimensional significance (value for point)
+      0   1  22  Name of feature
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  (Volcano erupting)
+  3  16  11
+      1  16   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature (value for special clouds)
+      0   1  22  Name of feature (volcano name)
+      0   8   7  Dimensional significance (value for point)
+      1   2   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0   8  21  Time significance (eruption starting time)
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+      0   4   4  Hour
+      0   4   5  Minute
+      0  20  90  Special clouds (clouds from volcanic eruptions)
+      0   8  21  Time significance (cancel)
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  Category 18 - Radiological report sequences
+  3  18   1
+      3   1  25  "Latitude and longitude (coarse accuracy), day and time"
+      0  24  11  Dose
+     -1
+  3  18   3
+      3   1  26  "Latitude and longitude (high accuracy), time periods in days," hours and minutes
+      0  24   5  Isotope mass
+      0  24   4  Element name
+      0  24  21  Air concentration
+     -1
+  3  18   4
+      3   1  25  "Latitude and longitude (coarse accuracy), day and time"
+      0   4  23  Time period or displacement
+      0  13  11  Total precipitation/total water equivalent
+      0  24   5  Isotope mass
+      0  24   4  Element name
+      0  24  22  Concentration in precipitation
+     -1
+#  Category 21 - Radar report sequences
+#  (Wind profiler � antenna characteristics)
+  3  21   1
+      0   2 101  Type of antenna
+      0   2 114  Antenna effective surface area
+      0   2 105  Maximum antenna gain
+      0   2 106  3-dB beamwidth
+      0   2 107  Sidelobe suppression
+      0   2 121  Mean frequency
+     -1
+#  (Wind profiler � moment data)
+  3  21   3
+      0  21  51  Signal power above 1 mW
+      0  21  14  Doppler mean velocity (radial)
+      0  21  17  Doppler velocity spectral width
+      0  21  30  Signal to noise ratio
+     -1
+#  (Wind profiler � moment data sounding)
+  3  21   4
+      3   1  31  "Identification, type, date/time, position (high accuracy), height"
+      0   2   3  Type of measuring equipment used
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3  21   3  Wind profiler � moment data
+     -1
+#  (Transmitter-receiver characteristics)
+  3  21   5
+      0  25   4  Echo processing
+      0   2 121  Mean frequency
+      0   2 122  Frequency agility range
+      0   2 123  Peak power
+      0   2 124  Average power
+      0   2 125  Pulse repetition frequency
+      0   2 126  Pulse width
+      0   2 127  Receiver intermediate frequency
+      0   2 128  Intermediate frequency bandwidth
+      0   2 129  Minimum detectable signal
+      0   2 130  Dynamic range
+      0   2 131  Sensitivity time control
+     -1
+#  (Integration characteristics)
+  3  21   6
+      0  25   1  Range-gate length
+      0  25   2  Number of gates averaged
+      0  25   3  Number of integrated pulses
+      0  25   5  Echo integration
+     -1
+#  (Corrections)
+  3  21   7
+      0  25   9  Calibration method
+      0  25  10  Clutter treatment
+      0  25  11  Ground occultation correction
+      0  25  12  Range attenuation correction
+      0  25  13  Bright-band correction
+      0  25  15  Radome attenuation correction
+      0  25  16  Clear-air attenuation correction
+      0  25  17  Precipitation attenuation correction
+     -1
+#  (Z to R conversion)
+  3  21   8
+      0  25   6  Z to R conversion
+      0  25   7  Z to R conversion factor
+      0  25   8  Z to R conversion exponent
+     -1
+#  (A to Z law)
+  3  21   9
+      0  25  18  A to Z law for attenuation factor
+      0  25  19  A to Z law for attenuation exponent
+     -1
+#  (Antenna characteristics)
+  3  21  10
+      0   2 101  Type of antenna
+      0   7   2  Altitude of the tower base
+      0   2 102  Antenna height above tower base
+      0   2 103  Radome
+      0   2 104  Antenna polarisation
+      0   2 105  Maximum antenna gain
+      0   2 106  3-dB beamwidth
+      0   2 107  Sidelobe suppression
+      0   2 108  Crosspol discrimination (on axis)
+      0   2 109  Antenna speed (azimuth)
+      0   2 110  Antenna speed (elevation)
+      0   2 132  Azimuth pointing accuracy
+      0   2 133  Elevation pointing accuracy
+     -1
+#  (General characteristics)
+  3  21  11
+      0  30  31  Picture type
+      0  30  32  Combination with other data
+      0  29   2  Coordinate grid type
+     -1
+#  (Antenna elevations)
+  3  21  12
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      0   2 135  Antenna elevation
+     -1
diff --git a/data/tables/B3M-000-008-0 b/data/tables/B3M-000-008-0
new file mode 100644
index 0000000..51af964
--- /dev/null
+++ b/data/tables/B3M-000-008-0
@@ -0,0 +1,115 @@
+##############################################################################
+# BUFR Table 0
+#
+#
+# Notes
+# -----
+#
+# * This table comes from GRIB Code Table 0 (Identification of center)
+#
+# * A value of 1 in the first column indicates a center that uses minor
+#   version numbers with local tables.  Since minor local table version
+#   numbers are stored in Section 1, Octet 18, the value in the first
+#   column must not be set if a center uses Section 1, Octet 18 for other
+#   purposes (i.e., ECMWF).
+#
+#
+##############################################################################		
+		
+#01-09: WMCs		
+0	1	Melbourne
+0	2	Melbourne
+0	3	Melbourne
+0	4	Moscow
+0	5	Moscow
+0	6	Moscow
+0	7	"US National Weather Service, National Centres for Environmental Prediction(NCEP)"
+0	8	US National Weather Service TelecommunicationsGateway (NWSTG)
+0	9	US National Weather Service - Other
+#10-25: Centres in Region I		
+0	10	Cairo (RSMC/RAFC)
+0	11	Cairo (RSMC/RAFC)
+0	12	Dakar (RSMC/RAFC)
+0	13	Dakar (RSMC/RAFC)
+0	14	Nairobi (RSMC/RAFC)
+0	15	Nairobi (RSMC/RAFC)
+0	18	Tunis Casablanca (RSMC)
+0	19	Tunis Casablanca (RSMC)
+0	20	Las Palmas (RAFC)
+0	21	Algiers (RSMC)
+0	24	Pretoria (RSMC)
+0	25	La R�union (RSMC)
+#26-40: Centres in Region II		
+0	26	Khabarovsk (RSMC)
+0	27	Khabarovsk (RSMC)
+0	28	New Delhi (RSMC/RAFC)
+0	29	New Delhi (RSMC/RAFC)
+0	30	Novosibirsk (RSMC)
+0	31	Novosibirsk (RSMC)
+0	32	Tashkent (RSMC)
+0	33	Jeddah (RSMC)
+0	34	"Tokyo (RSMC), Japan Meteorological Agency"
+0	35	"Tokyo (RSMC), Japan Meteorological Agency"
+0	36	Bangkok
+0	37	Ulan Bator
+0	38	Beijing (RSMC)
+0	39	Beijing (RSMC)
+0	40	Seoul
+#41-50: Centres in Region III		
+0	41	Buenos Aires (RSMC/RAFC)
+0	42	Buenos Aires (RSMC/RAFC)
+0	43	Brasilia (RSMC/RAFC)
+0	44	Brasilia (RSMC/RAFC)
+0	45	Santiago
+0	46	Brazilian Space Agency � INPE
+#51-63: Centres in Region IV		
+0	51	Miami (RSMC/RAFC)
+0	52	"Miami RSMC, National Hurricane Center"
+0	53	Montreal (RSMC)
+0	54	Montreal (RSMC)
+0	55	San Francisco
+0	57	U.S. Air Force Air Force Global Weather Central 
+0	58	"Fleet Numerical Meteorology and Oceanography Center, Monterey, CA"
+0	59	"The NOAA Forecast Systems Laboratory, Boulder, CO, USA"
+0	60	United States National Centre for Atmospheric Research (NCAR)
+#64-73: Centres in Region V		
+0	64	Honolulu
+0	65	Darwin (RSMC)
+0	66	Darwin (RSMC)
+0	67	Melbourne (RSMC)
+0	69	Wellington (RSMC/RAFC)
+0	70	Wellington (RSMC/RAFC)
+0	71	Nadi (RSMC)
+#74-99: Centres in Region VI		
+0	74	UK Meteorological Office � Bracknell (RSMC)
+0	75	UK Meteorological Office � Bracknell (RSMC)
+0	76	Moscow (RSMC/RAFC)
+0	78	Offenbach (RSMC)
+0	79	Offenbach (RSMC)
+0	80	Rome (RSMC)
+0	81	Rome (RSMC)
+0	82	Norrk�ping
+0	83	Norrk�ping
+0	85	Toulouse (RSMC)
+0	86	Helsinki
+0	87	Belgrade
+0	88	Oslo
+0	89	Prague
+0	90	Episkopi
+0	91	Ankara
+0	92	Frankfurt/Main (RAFC)
+0	93	London (WAFC)
+0	94	Copenhagen
+0	95	Rota
+0	96	Athens
+0	97	European Space Agency (ESA)
+0	98	"ECMWF, RSMC"
+0	99	De Bilt
+0	110	Hong-Kong
+0	160	US NOAA/NESDIS
+0	210	Frascati (ESA/ESRIN)
+0	211	Lanion
+0	212	Lisboa
+0	213	Reykjavik
+0	254	EUMETSAT Operation Centre
+0	255	Missing value
diff --git a/data/tables/B3M-000-008-A b/data/tables/B3M-000-008-A
new file mode 100644
index 0000000..5a7f993
--- /dev/null
+++ b/data/tables/B3M-000-008-A
@@ -0,0 +1,259 @@
+#
+# BUFR Table A - Data Category
+#
+  0	Surface data - land
+  1	Surface data - sea
+  2	Vertical soundings (other than satellite)
+  3	Vertical soundings (satellite)
+  4	Single level upper-air data (other than satellite)
+  5	Single level upper-air data (satellite)
+  6	Radar data
+  7	Synoptic features
+  8	Physical/chemical constituents
+  9	Dispersal and transport
+ 10	Radiological data
+ 11	BUFR tables, complete replacement or update
+ 12	Surface data (satellite)
+ 13	RESERVED
+ 14	RESERVED
+ 15	RESERVED
+ 16	RESERVED
+ 17	RESERVED
+ 18	RESERVED
+ 19	RESERVED
+ 20	Status information
+ 21	Radiances (satellite measured)
+ 22	RESERVED
+ 23	RESERVED
+ 24	RESERVED
+ 25	RESERVED
+ 26	RESERVED
+ 27	RESERVED
+ 28	RESERVED
+ 29	RESERVED
+ 30	RESERVED
+ 31	Oceanographic data
+ 32	RESERVED
+ 33	RESERVED
+ 34	RESERVED
+ 35	RESERVED
+ 36	RESERVED
+ 37	RESERVED
+ 38	RESERVED
+ 39	RESERVED
+ 40	RESERVED
+ 41	RESERVED
+ 42	RESERVED
+ 43	RESERVED
+ 44	RESERVED
+ 45	RESERVED
+ 46	RESERVED
+ 47	RESERVED
+ 48	RESERVED
+ 49	RESERVED
+ 50	RESERVED
+ 51	RESERVED
+ 52	RESERVED
+ 53	RESERVED
+ 54	RESERVED
+ 55	RESERVED
+ 56	RESERVED
+ 57	RESERVED
+ 58	RESERVED
+ 59	RESERVED
+ 60	RESERVED
+ 61	RESERVED
+ 62	RESERVED
+ 63	RESERVED
+ 64	RESERVED
+ 65	RESERVED
+ 66	RESERVED
+ 67	RESERVED
+ 68	RESERVED
+ 69	RESERVED
+ 70	RESERVED
+ 71	RESERVED
+ 72	RESERVED
+ 73	RESERVED
+ 74	RESERVED
+ 75	RESERVED
+ 76	RESERVED
+ 77	RESERVED
+ 78	RESERVED
+ 79	RESERVED
+ 80	RESERVED
+ 81	RESERVED
+ 82	RESERVED
+ 83	RESERVED
+ 84	RESERVED
+ 85	RESERVED
+ 86	RESERVED
+ 87	RESERVED
+ 88	RESERVED
+ 89	RESERVED
+ 90	RESERVED
+ 91	RESERVED
+ 92	RESERVED
+ 93	RESERVED
+ 94	RESERVED
+ 95	RESERVED
+ 96	RESERVED
+ 97	RESERVED
+ 98	RESERVED
+ 99	RESERVED
+100	RESERVED
+101	Image data
+102	RESERVED
+103	RESERVED
+104	RESERVED
+105	RESERVED
+106	RESERVED
+107	RESERVED
+108	RESERVED
+109	RESERVED
+110	RESERVED
+111	RESERVED
+112	RESERVED
+113	RESERVED
+114	RESERVED
+115	RESERVED
+116	RESERVED
+117	RESERVED
+118	RESERVED
+119	RESERVED
+120	RESERVED
+121	RESERVED
+122	RESERVED
+123	RESERVED
+124	RESERVED
+125	RESERVED
+126	RESERVED
+127	RESERVED
+128	RESERVED
+129	RESERVED
+130	RESERVED
+131	RESERVED
+132	RESERVED
+133	RESERVED
+134	RESERVED
+135	RESERVED
+136	RESERVED
+137	RESERVED
+138	RESERVED
+139	RESERVED
+140	RESERVED
+141	RESERVED
+142	RESERVED
+143	RESERVED
+144	RESERVED
+145	RESERVED
+146	RESERVED
+147	RESERVED
+148	RESERVED
+149	RESERVED
+150	RESERVED
+151	RESERVED
+152	RESERVED
+153	RESERVED
+154	RESERVED
+155	RESERVED
+156	RESERVED
+157	RESERVED
+158	RESERVED
+159	RESERVED
+160	RESERVED
+161	RESERVED
+162	RESERVED
+163	RESERVED
+164	RESERVED
+165	RESERVED
+166	RESERVED
+167	RESERVED
+168	RESERVED
+169	RESERVED
+170	RESERVED
+171	RESERVED
+172	RESERVED
+173	RESERVED
+174	RESERVED
+175	RESERVED
+176	RESERVED
+177	RESERVED
+178	RESERVED
+179	RESERVED
+180	RESERVED
+181	RESERVED
+182	RESERVED
+183	RESERVED
+184	RESERVED
+185	RESERVED
+186	RESERVED
+187	RESERVED
+188	RESERVED
+189	RESERVED
+190	RESERVED
+191	RESERVED
+192	RESERVED
+193	RESERVED
+194	RESERVED
+195	RESERVED
+196	RESERVED
+197	RESERVED
+198	RESERVED
+199	RESERVED
+200	RESERVED
+201	RESERVED
+202	RESERVED
+203	RESERVED
+204	RESERVED
+205	RESERVED
+206	RESERVED
+207	RESERVED
+208	RESERVED
+209	RESERVED
+210	RESERVED
+211	RESERVED
+212	RESERVED
+213	RESERVED
+214	RESERVED
+215	RESERVED
+216	RESERVED
+217	RESERVED
+218	RESERVED
+219	RESERVED
+220	RESERVED
+221	RESERVED
+222	RESERVED
+223	RESERVED
+224	RESERVED
+225	RESERVED
+226	RESERVED
+227	RESERVED
+228	RESERVED
+229	RESERVED
+230	RESERVED
+231	RESERVED
+232	RESERVED
+233	RESERVED
+234	RESERVED
+235	RESERVED
+236	RESERVED
+237	RESERVED
+238	RESERVED
+239	RESERVED
+240	FOR EXPERIMENTAL USE
+241	FOR EXPERIMENTAL USE
+242	FOR EXPERIMENTAL USE
+243	FOR EXPERIMENTAL USE
+244	FOR EXPERIMENTAL USE
+245	FOR EXPERIMENTAL USE
+246	FOR EXPERIMENTAL USE
+247	FOR EXPERIMENTAL USE
+248	FOR EXPERIMENTAL USE
+249	FOR EXPERIMENTAL USE
+250	FOR EXPERIMENTAL USE
+251	FOR EXPERIMENTAL USE
+252	FOR EXPERIMENTAL USE
+253	FOR EXPERIMENTAL USE
+254	FOR EXPERIMENTAL USE
+255	Indicator for local use, with sub-category
diff --git a/data/tables/B3M-000-008-B b/data/tables/B3M-000-008-B
new file mode 100644
index 0000000..418a536
--- /dev/null
+++ b/data/tables/B3M-000-008-B
@@ -0,0 +1,765 @@
+#
+# WMO source file name = BufrTabB-5-2000.txt
+# Master Table B Version 8
+#
+#                   Reference    Bit
+# F   X    Y Scale    Value     Width     Units     Comments
+#--------------------------------------------------------------
+# Class 00 - BUFR table entries
+  0;  0;   1;    0;           0;   24;   CCITT_IA5; Table A:  entry
+  0;  0;   2;    0;           0;  256;   CCITT_IA5; "Table A:  data category description, line 1"
+  0;  0;   3;    0;           0;  256;   CCITT_IA5; "Table A:  data category description, line 2"
+  0;  0;   5;    0;           0;   24;   CCITT_IA5; BUFR edition number
+  0;  0;  10;    0;           0;    8;   CCITT_IA5; F descriptor to be added or defined
+  0;  0;  11;    0;           0;   16;   CCITT_IA5; X descriptor to be added or defined
+  0;  0;  12;    0;           0;   24;   CCITT_IA5; Y descriptor to be added or defined
+  0;  0;  13;    0;           0;  256;   CCITT_IA5; "Element name, line 1"
+  0;  0;  14;    0;           0;  256;   CCITT_IA5; "Element name, line 2"
+  0;  0;  15;    0;           0;  192;   CCITT_IA5; Units name
+  0;  0;  16;    0;           0;    8;   CCITT_IA5; Units scale sign
+  0;  0;  17;    0;           0;   24;   CCITT_IA5; Units scale
+  0;  0;  18;    0;           0;    8;   CCITT_IA5; Units reference sign
+  0;  0;  19;    0;           0;   80;   CCITT_IA5; Units reference value
+  0;  0;  20;    0;           0;   24;   CCITT_IA5; Element data width
+  0;  0;  30;    0;           0;   48;   CCITT_IA5; Descriptor defining sequence
+# Class 01 - Identification
+  0;  1;   1;    0;           0;    7;     Numeric; WMO block number
+  0;  1;   2;    0;           0;   10;     Numeric; WMO station number
+  0;  1;   3;    0;           0;    3;  Code_Table; WMO Region number/geographical area
+  0;  1;   4;    0;           0;    3;     Numeric; WMO Region sub-area (see Note 9)
+  0;  1;   5;    0;           0;   17;     Numeric; Buoy/platform identifier
+  0;  1;   6;    0;           0;   64;   CCITT_IA5; Aircraft flight number
+  0;  1;   7;    0;           0;   10;  Code_Table; Satellite identifier
+  0;  1;   8;    0;           0;   64;   CCITT_IA5; Aircraft registration number
+  0;  1;   9;    0;           0;   64;   CCITT_IA5; Type of commercial aircraft
+  0;  1;  10;    0;           0;   64;   CCITT_IA5; Stationary buoy platform identifier; e.g. C-MAN buoys
+  0;  1;  11;    0;           0;   72;   CCITT_IA5; Ship or mobile land station identifier
+  0;  1;  12;    0;           0;    9; Degree_true; Direction of motion of moving observing platform
+  0;  1;  13;    0;           0;   10;       m s�1; Speed of motion of moving observing platform
+  0;  1;  14;    2;           0;   10;       m s�1; Platform drift speed (high precision)
+  0;  1;  15;    0;           0;  160;   CCITT_IA5; Station or site name
+  0;  1;  18;    0;           0;   40;   CCITT_IA5; Short station or site name
+  0;  1;  20;    0;           0;    4;     Numeric; WMO Region sub-area
+  0;  1;  21;    0;           0;   14;     Numeric; Synoptic feature identifier
+  0;  1;  22;    0;           0;  224;   CCITT_IA5; Name of feature (see Note 11)
+  0;  1;  25;    0;           0;   24;   CCITT_IA5; Storm identifier
+  0;  1;  26;    0;           0;   64;   CCITT_IA5; WMO storm name*
+  0;  1;  27;    0;           0;   80;   CCITT_IA5; WMO long storm name
+  0;  1;  31;    0;           0;   16;  Code_Table; Identification of originating/generating centre (see Note 10)
+  0;  1;  32;    0;           0;    8;  Code_Table; Generating application
+  0;  1;  33;    0;           0;    8;  Code_Table; Identification of originating/generating centre
+  0;  1;  34;    0;           0;    8;  Code_Table; Identification of originating/generating sub-centre
+  0;  1;  41;    5; -1073741824;   31;       m s-1; Absolute platform velocity - first component (see Note 6)
+  0;  1;  42;    5; -1073741824;   31;       m s-1; Absolute platform velocity - second component (see Note 6)
+  0;  1;  43;    5; -1073741824;   31;       m s-1; Absolute platform velocity - third component (see Note 6)
+  0;  1;  50;    0;           0;   17;     Numeric; Platform transmitter ID number
+  0;  1;  51;    0;           0;   96;   CCITT_IA5; Platform transmitter ID number
+  0;  1;  60;    0;           0;   64;   CCITT_IA5; Aircraft reporting point (Beacon identifier)
+  0;  1;  62;    0;           0;   32;   CCITT_IA5; Short ICAO location indicator
+  0;  1;  63;    0;           0;   64;   CCITT_IA5; ICAO location indicator
+  0;  1;  64;    0;           0;   32;   CCITT_IA5; Runway designator
+  0;  1;  75;    0;           0;   40;   CCITT_IA5; Tide station identification
+# Class 02 - Instrumentation
+  0;  2;   1;    0;           0;    2;  Code_Table; Type of station
+  0;  2;   2;    0;           0;    4;  Flag_Table; Type of instrumentation for wind measurement
+  0;  2;   3;    0;           0;    4;  Code_Table; Type of measuring equipment used
+  0;  2;   4;    0;           0;    4;  Code_Table; Type of instrumentation for evaporation measurement or type of crop for which evapotranspiration is reported
+  0;  2;   5;    2;           0;    7;           K; Precision of temperature observation
+  0;  2;  11;    0;           0;    8;  Code_Table; Radiosonde type
+  0;  2;  12;    0;           0;    4;  Code_Table; Radiosonde computational method
+  0;  2;  13;    0;           0;    4;  Code_Table; Solar and infrared radiation correction
+  0;  2;  14;    0;           0;    7;  Code_Table; Tracking technique/status of system used
+  0;  2;  15;    0;           0;    4;  Code_Table; Radiosonde completeness
+  0;  2;  19;    0;           0;   11;  Code_Table; Satellite instruments
+  0;  2;  20;    0;           0;    9;  Code_Table; Satellite classification
+  0;  2;  21;    0;           0;    9;  Flag_Table; Satellite instrument data used in processing*
+  0;  2;  22;    0;           0;    8;  Flag_Table; Satellite data-processing technique used
+  0;  2;  23;    0;           0;    4;  Code_Table; Satellite derived wind computation method
+  0;  2;  24;    0;           0;    4;  Code_Table; Integrated mean humidity computational method
+  0;  2;  25;    0;           0;   25;  Flag_Table; Satellite channel(s) used in computation
+  0;  2;  26;    2;           0;   12;           m; Cross track resolution
+  0;  2;  27;    2;           0;   12;           m; Along track resolution
+  0;  2;  28;    0;           0;   18;           m; Segment size at nadir in X direction
+  0;  2;  29;    0;           0;   18;           m; Segment size at nadir in Y direction
+  0;  2;  30;    0;           0;    3;  Code_Table; Method of current measurement
+  0;  2;  31;    0;           0;    5;  Code_Table; Duration and time of current measurement
+  0;  2;  32;    0;           0;    2;  Code_Table; Indicator for digitization
+  0;  2;  33;    0;           0;    3;  Code_Table; Method of salinity/depth measurement
+  0;  2;  34;    0;           0;    5;  Code_Table; Drogue type
+  0;  2;  35;    0;           0;    9;           m; Cable length
+  0;  2;  36;    0;           0;    2;  Code_Table; Buoy type
+  0;  2;  37;    0;           0;    3;  Code_Table; Method of tidal observation
+  0;  2;  38;    0;           0;    4;  Code_Table; Method of sea-surface temperature measurement
+  0;  2;  39;    0;           0;    3;  Code_Table; Method of wet-bulb temperature measurement
+  0;  2;  40;    0;           0;    4;  Code_Table; Method of removing velocity and motion of platform from current
+  0;  2;  41;    0;           0;    6;  Code_Table; Method for estimating reports related to synoptic features
+  0;  2;  44;    0;           0;    4;  Code_Table; Indicator for method of calculating spectral wave data
+  0;  2;  45;    0;           0;    4;  Code_Table; Indicator for type of platform
+  0;  2;  46;    0;           0;    4;  Code_Table; Wave measurement instrumentation
+  0;  2;  48;    0;           0;    4;  Code_Table; Satellite sensor indicator
+  0;  2;  49;    0;           0;    8;  Flag_Table; Geostationary satellite data-processing technique used
+  0;  2;  50;    0;           0;   20;  Flag_Table; Geostationary sounder satellite channels used
+  0;  2;  51;    0;           0;    4;  Code_Table; Indicator to specify observing method for extreme temperatures
+  0;  2;  52;    0;           0;    6;  Flag_Table; Geostationary imager satellite channels used
+  0;  2;  53;    0;           0;    4;  Code_Table; GOES-I/M brightness temperature characteristics
+  0;  2;  54;    0;           0;    4;  Code_Table; GOES-I/M soundings parameter characteristics
+  0;  2;  55;    0;           0;    4;  Code_Table; Geostationary soundings statistical parameters
+  0;  2;  56;    0;           0;    4;  Code_Table; Geostationary soundings accuracy statistics
+  0;  2;  57;    0;           0;    4;  Code_Table; Origin of first guess information for GOES-I/M soundings
+  0;  2;  58;    0;           0;    4;  Valid times of first guess information for GOES-I/M soundings
+  0;  2;  59;    0;           0;    4;  Code_Table; Origin of analysis information for GOES-I/M soundings
+  0;  2;  60;    0;           0;    4;  Code_Table; Origin of surface information for GOES-I/M soundings
+  0;  2;  61;    0;           0;    3;  Code_Table; Aircraft navigational system
+  0;  2;  62;    0;           0;    4;  Code_Table; Type of aircraft data relay system
+  0;  2;  63;    2;      -18000;   16;      Degree; Aircraft roll angle
+  0;  2;  64;    0;           0;    2;  Code_Table; Aircraft roll angle quality
+  0;  2;  65;    0;           0;   40;   CCITT_IA5; ACARS ground receiving station
+  0;  2;  70;    0;           0;    4;  Code_Table; Original specification of latitude/longitude
+  0;  2;  91;    0;           4;   10;           A; Entry sensor 4/20 mA
+  0;  2; 100;    1;           0;   12;          dB; Radar constant*
+  0;  2; 101;    0;           0;    4;  Code_Table; Type of antenna
+  0;  2; 102;    0;           0;    8;           m; Antenna height above tower base
+  0;  2; 103;    0;           0;    2;  Flag_Table; Radome
+  0;  2; 104;    0;           0;    4;  Code_Table; Antenna polarisation
+  0;  2; 105;    0;           0;    6;          dB; Maximum antenna gain
+  0;  2; 106;    1;           0;    6;      Degree; 3-dB beamwidth
+  0;  2; 107;    0;           0;    6;          dB; Sidelobe suppression
+  0;  2; 108;    0;           0;    6;          dB; Crosspol discrimination (on axis)
+  0;  2; 109;    2;           0;   12;  Degree s-1; Antenna speed (azimuth)
+  0;  2; 110;    2;           0;   12;  Degree s-1; Antenna speed (elevation)
+  0;  2; 111;    1;           0;   10;      Degree; Radar incidence angle
+  0;  2; 112;    1;           0;   12;      Degree; Radar look angle
+  0;  2; 113;    0;           0;    4;     Numeric; Number of azimuth looks
+  0;  2; 114;    0;           0;   15;          m2; Antenna effective surface area
+  0;  2; 121;   -8;           0;    7;          Hz; Mean frequency
+  0;  2; 122;   -6;        -128;    8;          Hz; Frequency agility range
+  0;  2; 123;   -4;           0;    7;           W; Peak power
+  0;  2; 124;   -1;           0;    7;           W; Average power
+  0;  2; 125;   -1;           0;    8;          Hz; Pulse repetition frequency
+  0;  2; 126;    7;           0;    6;           s; Pulse width
+  0;  2; 127;   -6;           0;    7;          Hz; Receiver intermediate frequency
+  0;  2; 128;   -5;           0;    6;          Hz; Intermediate frequency bandwidth
+  0;  2; 129;    0;        -150;    5;          dB; Minimum detectable signal
+  0;  2; 130;    0;           0;    7;          dB; Dynamic range
+  0;  2; 131;    0;           0;    2;  Flag_Table; Sensitivity time control (STC)
+  0;  2; 132;    2;           0;    6;      Degree; Azimuth pointing accuracy
+  0;  2; 133;    2;           0;    6;      Degree; Elevation pointing accuracy
+  0;  2; 134;    2;           0;   16;      Degree; Antenna beam azimuth
+  0;  2; 135;    2;       -9000;   15;      Degree; Antenna elevation
+  0;  2; 136;   -3;           0;   16;           m; Range processed by range attenuation correction
+  0;  2; 140;    0;           0;    9;      Degree; Satellite radar beam azimuth angle
+  0;  2; 141;    0;           0;   24;   CCITT_IA5; Measurement type
+  0;  2; 142;    0;           0;   32;   CCITT_IA5; Ozone instrument serial number/ identification
+  0;  2; 143;    0;           0;    7;  Code_Table; Ozone instrument type
+  0;  2; 144;    0;           0;    4;  Code_Table; Light source type for Brewer spectro photometer
+  0;  2; 145;    0;           0;    4;  Code_Table; Wave length setting for Dobson instruments
+  0;  2; 146;    0;           0;    4;  Code_Table; Source conditions for Dobson instruments
+  0;  2; 148;    0;           0;    5;  Code_Table; Data collection and/or location system
+  0;  2; 149;    0;           0;    6;  Code_Table; Type of data buoy
+  0;  2; 150;    0;           0;    6;  Code_Table; TOVS/ATOVS/AVHRR instrumentation channel number
+  0;  2; 151;    0;           0;    4;  Code_Table; Radiometer identifier
+  0;  2; 152;    0;           0;   31;  Flag_Table; Satellite instrument used in data processing(6)
+  0;  2; 153;   -8;           0;   26;          Hz; Satellite channel centre frequency
+  0;  2; 154;   -8;           0;   26;          Hz; Satellite channel band width
+  0;  2; 163;    0;           0;    4;  Code_Table; Height assignment method
+  0;  2; 164;    0;           0;    3;  Code_Table; Tracer correlation method
+  0;  2; 166;    0;           0;    4;  Code_Table; Radiance type
+  0;  2; 167;    0;           0;    4;  Code_Table; Radiance computational method
+  0;  2; 168;   -3;           0;   16;          Pa; Hydrostatic pressure of lower end of cable (thermistor string)
+  0;  2; 169;    0;           0;    4;  Code_Table; Anemometer type
+# Class 04 - Location (time)
+  0;  4;   1;    0;           0;   12;        Year; Year
+  0;  4;   2;    0;           0;    4;       Month; Month
+  0;  4;   3;    0;           0;    6;         Day; Day
+  0;  4;   4;    0;           0;    5;        Hour; Hour
+  0;  4;   5;    0;           0;    6;      Minute; Minute
+  0;  4;   6;    0;           0;    6;      Second; Second
+  0;  4;  11;    0;       -1024;   11;        Year; Time increment
+  0;  4;  12;    0;       -1024;   11;       Month; Time increment
+  0;  4;  13;    0;       -1024;   11;         Day; Time increment
+  0;  4;  14;    0;       -1024;   11;        Hour; Time increment
+  0;  4;  15;    0;       -2048;   12;      Minute; Time increment
+  0;  4;  16;    0;       -4096;   13;      Second; Time increment
+  0;  4;  21;    0;       -1024;   11;        Year; Time period or displacement
+  0;  4;  22;    0;       -1024;   11;       Month; Time period or displacement
+  0;  4;  23;    0;       -1024;   11;         Day; Time period or displacement
+  0;  4;  24;    0;       -2048;   12;        Hour; Time period or displacement
+  0;  4;  25;    0;       -2048;   12;      Minute; Time period or displacement
+  0;  4;  26;    0;       -4096;   13;      Second; Time period or displacement
+  0;  4;  31;    0;           0;    8;        Hour; Duration of time relating to following value
+  0;  4;  32;    0;           0;    6;      Minute; Duration of time relating to following value
+  0;  4;  41;    0;       -1440;   12;      Minute; "Time difference, UTC -LMT (see Note 6)"
+  0;  4;  43;    0;           0;    9;         Day; Day of the year
+  0;  4;  53;    0;           0;    6;     Numeric; Number of days with precipitation equal to or more than 1 mm
+  0;  4;  65;    0;        -128;    8;      Minute; Short time increment
+  0;  4;  73;    0;        -128;    8;         Day; Short time period or displacement
+  0;  4;  74;    0;        -128;    8;        Hour; Short time period or displacement
+  0;  4;  75;    0;        -128;    8;      Minute; Short time period or displacement
+# Class 05 - Location (horizontal -1)
+  0;  5;   1;    5;    -9000000;   25;      Degree; Latitude (high accuracy)
+  0;  5;   2;    2;       -9000;   15;      Degree; Latitude (coarse accuracy)
+  0;  5;  11;    5;    -9000000;   25;      Degree; Latitude increment (high accuracy)
+  0;  5;  12;    2;       -9000;   15;      Degree; Latitude increment (coarse accuracy)
+  0;  5;  21;    2;           0;   16; Degree_true; Bearing or azimuth
+  0;  5;  22;    2;           0;   16; Degree_true; Solar azimuth
+  0;  5;  30;    0;           0;   12;      Degree; Direction (spectral)
+  0;  5;  31;    0;           0;   12;     Numeric; Row number
+  0;  5;  33;   -1;           0;   16;           m; Pixel size on horizontal - 1
+  0;  5;  34;    0;           0;   11;     Numeric; Along track row number
+  0;  5;  40;    0;           0;   24;     Numeric; Orbit number
+  0;  5;  41;    0;           0;    8;     Numeric; Scan line number
+  0;  5;  42;    0;           0;    6;     Numeric; Channel number
+  0;  5;  43;    0;           0;    8;     Numeric; Field of view number
+  0;  5;  52;    0;           0;    5;     Numeric; Channel number increment
+  0;  5;  53;    0;           0;    5;     Numeric; Field of view number increment
+# Class 06 - Location (horizontal - 2)
+  0;  6;   1;    5;   -18000000;   26;      Degree; Longitude (high accuracy)
+  0;  6;   2;    2;      -18000;   16;      Degree; Longitude (coarse accuracy)
+  0;  6;  11;    5;   -18000000;   26;      Degree; Longitude increment (high accuracy)
+  0;  6;  12;    2;      -18000;   16;      Degree; Longitude increment (coarse accuracy)
+  0;  6;  21;   -1;           0;   13;           m; Distance
+  0;  6;  30;    5;           0;   13;     rad m-1; Wave number (spectral)
+  0;  6;  31;    0;           0;   12;     Numeric; Column number
+  0;  6;  33;   -1;           0;   16;           m; Pixel size on horizontal - 2
+  0;  6;  34;    0;           0;    7;     Numeric; Cross-track cell number
+  0;  6;  40;    0;           0;   13;           m; Radius of confidence
+# Class 07 - Location (vertical)
+  0;  7;   1;    0;        -400;   15;           m; Height of station
+  0;  7;   2;   -1;         -40;   16;           m; Height or altitude
+  0;  7;   3;   -1;        -400;   17;      m2 s-2; Geopotential
+  0;  7;   4;   -1;           0;   14;          Pa; Pressure
+  0;  7;   5;    0;        -400;   12;           m; Height increment
+  0;  7;   6;    0;           0;   15;           m; Height above station
+  0;  7;   7;    0;       -1000;   17;           m; Height
+  0;  7;   8;    0;      -10000;   20;      m2 s-2; Geopotential
+  0;  7;   9;    0;           0;   17;         gpm; Geopotential height
+  0;  7;  21;    2;       -9000;   15;      Degree; Elevation (see Note 1)
+  0;  7;  21;    2;       -9000;   15;      Degree; Elevation
+  0;  7;  22;    2;       -9000;   15;      Degree; Solar elevation
+  0;  7;  24;    2;       -9000;   15;      Degree; Satellite zenith angle
+  0;  7;  25;    2;       -9000;   15;      Degree; Solar zenith angle
+  0;  7;  61;    2;           0;   14;           m; Depth below land surface
+  0;  7;  62;    1;           0;   17;           m; Depth below sea/water surface
+  0;  7;  64;    0;           0;    4;           m; Height above station (sensor height artificially corrected) (see Note 2)
+  0;  7;  70;    0;           0;   10;           m; Drogue depth
+# Class 08 - Significance qualifiers
+  0;  8;   1;    0;           0;    7;  Flag_Table; Vertical sounding significance
+  0;  8;   2;    0;           0;    6;  Code_Table; Vertical significance (surface observations)
+  0;  8;   3;    0;           0;    6;  Code_Table; Vertical significance (satellite observations)
+  0;  8;   4;    0;           0;    3;  Code_Table; Phase of aircraft flight
+  0;  8;   5;    0;           0;    4;  Code_Table; Meteorological attribute significance
+  0;  8;   6;    0;           0;    9;  Flag_Table; Ozone vertical sounding significance
+  0;  8;   7;    0;           0;    4;  Code_Table; Dimensional significance
+  0;  8;   8;    0;           0;    9;  Flag_Table; Radiation vertical sounding significance
+  0;  8;  11;    0;           0;    6;  Code_Table; Meteorological feature
+  0;  8;  12;    0;           0;    2;  Code_Table; Land/sea qualifier
+  0;  8;  13;    0;           0;    2;  Code_Table; Day/night qualifier
+  0;  8;  14;    0;           0;    4;  Code_Table; Qualifier for runway visual range
+  0;  8;  16;    0;           0;    3;  Code_Table; Change qualifier of a trend-type forecast or an aerodrome forecast
+  0;  8;  17;    0;           0;    2;  Code_Table; Qualifier of the time when the forecast change is expected
+  0;  8;  18;    0;           0;   17;  Flag_Table; SEAWINDS land/ice surface type
+  0;  8;  20;    0;           0;   16;     Numeric; Total number of missing entities (with respect to accumulation or average)
+  0;  8;  21;    0;           0;    5;  Code_Table; Time significance
+  0;  8;  22;    0;           0;   16;     Numeric; Total number (with respect to accumulation or average)
+  0;  8;  23;    0;           0;    6;  Code_Table; First order statistics
+  0;  8;  24;    0;           0;    6;  Code_Table; Difference statistics
+  0;  8;  25;    0;           0;    4;  Code_Table; Time difference qualifier
+  0;  8;  30;    0;           0;   13;     Numeric; "Manual on Codes (Volume I.1, Section C) Code table from which data are derived"
+  0;  8;  31;    0;           0;    8;     Numeric; Data category CREX table A
+  0;  8;  35;    0;           0;    3;  Code_Table; Type of monitoring exercise
+  0;  8;  36;    0;           0;    3;  Code_Table; Type of centre or station performing monitoring
+  0;  8;  51;    0;           0;    3;  Code_Table; Qualifier for number of missing values in calculation of statistic
+  0;  8;  52;    0;           0;    5;  Code_Table; Condition for which number of days of occurrence follows
+  0;  8;  53;    0;           0;    2;  Code_Table; Day of occurrence qualifier
+  0;  8;  60;    0;           0;    4;  Code_Table; Sample scanning mode significance
+  0;  8;  70;    0;           0;    4;  Code_Table; TOVS/ATOVS product qualifier
+  0;  8;  72;    0;           0;    3;  Code_Table; Pixel(s) type
+# Class 10 - Non-coordinate location (vertical)
+  0; 10;   1;    0;        -400;   15;           m; Height of land surface
+  0; 10;   2;   -1;         -40;   16;           m; Height
+  0; 10;   3;   -1;        -400;   17;      m2 s-2; Geopotential
+  0; 10;   4;   -1;           0;   14;          Pa; Pressure
+  0; 10;   7;    0;       -1000;   17;           m; Height
+  0; 10;   8;    0;      -10000;   20;      m2 s-2; Geopotential
+  0; 10;   9;    0;           0;   17;         gpm; Geopotential height
+  0; 10;  31;    2; -1073741824;   31;           m; "In direction of the North Pole, distance from the Earth�s centre"
+  0; 10;  50;    2;           0;   16;           m; Standard deviation altitude
+  0; 10;  51;   -1;           0;   14;          Pa; Pressure reduced to mean sea level
+  0; 10;  52;   -1;           0;   14;          Pa; Altimeter setting (QNH)
+  0; 10;  60;   -1;       -1024;   11;          Pa; Pressure change
+  0; 10;  61;   -1;        -500;   10;          Pa; 3-hour pressure change
+  0; 10;  62;   -1;       -1000;   11;          Pa; 24-hour pressure change
+  0; 10;  63;    0;           0;    4;  Code_Table; Characteristic of pressure tendency
+  0; 10;  70;    0;        -400;   16;           m; Indicated aircraft altitude
+# Class 11 - Wind and turbulence
+  0; 11;   1;    0;           0;    9; Degree_true; Wind direction
+  0; 11;   2;    1;           0;   12;       m s-1; Wind speed
+  0; 11;   3;    1;       -4096;   13;       m s-1; u-component
+  0; 11;   4;    1;       -4096;   13;       m s-1; v-component
+  0; 11;   5;    1;        -512;   10;      Pa s-1; w-component
+  0; 11;   6;    2;       -4096;   13;       m s-1; w-component
+  0; 11;  11;    0;           0;    9; Degree_true; Wind direction at 10 m
+  0; 11;  12;    1;           0;   12;       m s-1; Wind speed at 10 m
+  0; 11;  13;    0;           0;    9; Degree_true; Wind direction at 5 m
+  0; 11;  14;    1;           0;   12;       m s-1; Wind speed at 5 m
+  0; 11;  16;    0;           0;    9; Degree_true; Extreme counterclockwise wind direction of a variable wind
+  0; 11;  17;    0;           0;    9; Degree_true; Extreme clockwise wind direction of a variable wind
+  0; 11;  19;    0;           0;    7;           %; Steadiness of wind*
+  0; 11;  21;    9;      -65536;   17;         s-1; Relative vorticity
+  0; 11;  22;    9;      -65536;   17;         s-1; Divergence
+  0; 11;  23;   -2;      -65536;   17;      m2 s-1; Velocity potential
+  0; 11;  31;    0;           0;    4;  Code_Table; Degree of turbulence
+  0; 11;  32;   -1;         -40;   16;           m; Height of base of turbulence
+  0; 11;  33;   -1;         -40;   16;           m; Height of top of turbulence
+  0; 11;  34;    1;       -1024;   11;       m s-1; Vertical gust velocity
+  0; 11;  35;    2;       -8192;   14;       m s-2; Vertical gust acceleration
+  0; 11;  36;    1;           0;   10;       m s-1; Maximum derived equivalent vertical gust speed
+  0; 11;  40;    1;           0;   12;       m s-1; Maximum wind speed (mean wind)
+  0; 11;  41;    1;           0;   12;       m s-1; Maximum wind speed (gusts)
+  0; 11;  42;    1;           0;   12;       m s-1; Maximum wind speed (10-min mean wind)
+  0; 11;  43;    0;           0;    9; Degree_true; Maximum wind gust direction
+  0; 11;  44;    0;           0;    9; Degree_true; Mean wind direction for surface - 1500 m (5000 feet)
+  0; 11;  45;    1;           0;   12;       m s-1; Mean wind speed for surface - 1500 m (5000 feet)
+  0; 11;  49;    0;           0;    9; Degree_true; Standard deviation of wind direction
+  0; 11;  50;    1;           0;   12;       m s-1; Standard deviation of horizontal wind speed
+  0; 11;  51;    1;           0;    8;       m s-1; Standard deviation of vertical wind speed
+  0; 11;  52;    2;           0;   14;       m s-1; Formal uncertainty in wind speed
+  0; 11;  53;    2;           0;   15; Degree_true; Formal uncertainty in wind direction
+  0; 11;  61;    1;           0;   12;       m s-1; Absolute wind shear in 1 km layer below
+  0; 11;  62;    1;           0;   12;       m s-1; Absolute wind shear in 1 km layer above
+  0; 11;  70;    0;           0;   32;   CCITT_IA5; Designator of the runway affected by wind shear (including ALL)
+  0; 11;  71;    3;        -128;   14;      m2 s-2; Turbulent vertical momentum flux
+  0; 11;  72;    3;        -128;   11;     K m s-1; Turbulent vertical buoyancy flux
+  0; 11;  73;    2;       -1024;   13;      m2 s-2; Turbulent kinetic energy
+  0; 11;  74;    2;       -1024;   10;      m2 s-2; Dissipation energy
+  0; 11;  75;    2;           0;    8;    m2/3 s-1; Mean turbulence intensity (eddy dissipation rate)
+  0; 11;  76;    2;           0;    8;    m2/3 s-1; Peak turbulence intensity (eddy dissipation rate)
+  0; 11;  81;    2;           0;   16; Degree_true; Model wind direction at 10m
+  0; 11;  82;    2;           0;   13;       m s-1; Model wind speed at 10m
+# Class 12 - Temperature
+  0; 12;   1;    1;           0;   12;           K; Temperature/dry-bulb temperature
+  0; 12;   2;    1;           0;   12;           K; Wet-bulb temperature
+  0; 12;   3;    1;           0;   12;           K; Dew-point temperature
+  0; 12;   4;    1;           0;   12;           K; Dry-bulb temperature at 2 m
+  0; 12;   5;    1;           0;   12;           K; Wet-bulb temperature at 2 m
+  0; 12;   6;    1;           0;   12;           K; Dew-point temperature at 2 m
+  0; 12;   7;    1;           0;   12;           K; Virtual temperature
+  0; 12;  11;    1;           0;   12;           K; "Maximum temperature, at height and over period specified"
+  0; 12;  12;    1;           0;   12;           K; "Minimum temperature, at height and over period specified"
+  0; 12;  13;    1;           0;   12;           K; "Ground minimum temperature, past 12 hours"
+  0; 12;  14;    1;           0;   12;           K; "Maximum temperature at 2 m, past 12 hours"
+  0; 12;  15;    1;           0;   12;           K; "Minimum temperature at 2 m, past 12 hours"
+  0; 12;  16;    1;           0;   12;           K; "Maximum temperature at 2 m, past 24 hours"
+  0; 12;  17;    1;           0;   12;           K; "Minimum temperature at 2 m, past 24 hours"
+  0; 12;  30;    1;           0;   12;           K; Soil temperature
+  0; 12;  51;    1;           0;   10;           K; Standard deviation temperature
+  0; 12;  52;    1;           0;   12;           K; Highest daily mean temperature
+  0; 12;  53;    1;           0;   12;           K; Lowest daily mean temperature
+  0; 12;  61;    1;           0;   12;           K; Skin temperature
+  0; 12;  62;    1;           0;   12;           K; Equivalent black body temperature
+  0; 12;  63;    1;           0;   12;           K; Brightness temperature
+  0; 12;  64;    1;           0;   12;           K; Instrument temperature
+  0; 12;  71;    1;           0;   12;           K; Coldest cluster temperature
+  0; 12;  72;    6;           0;   31;  W m-2 sr-1; Radiance
+  0; 12;  75;   -3;           0;   16;  W m-3 sr-1; Spectral radiance
+  0; 12;  76;    3;           0;   16;  W m-2 sr-1; Radiance
+# Class 13 - Hygrographic and hydrological elements
+  0; 13;   1;    5;           0;   14;     kg kg-1; Specific humidity
+  0; 13;   2;    5;           0;   14;     kg kg-1; Mixing ratio
+  0; 13;   3;    0;           0;    7;           %; Relative humidity
+  0; 13;   4;   -1;           0;   10;          Pa; Vapour pressure
+  0; 13;   5;    3;           0;    7;      kg m-3; Vapour density
+  0; 13;   6;   -1;         -40;   16;           m; Mixing heights
+  0; 13;  11;    1;          -1;   14;      kg m-2; Total precipitation/total water equivalent
+  0; 13;  12;    2;          -2;   12;           m; Depth of fresh snow
+  0; 13;  13;    2;          -2;   16;           m; Total snow depth
+  0; 13;  14;    4;           0;   12;  kg m-2 s-1; Rainfall/water equivalent of snow (averaged rate)
+  0; 13;  15;    7;           0;   12;       m s-1; Snowfall  (averaged rate)
+  0; 13;  16;    0;           0;    7;      kg m-2; Precipitable water
+  0; 13;  19;    1;          -1;   14;      kg m-2; Total precipitation past 1 hour
+  0; 13;  20;    1;          -1;   14;      kg m-2; Total precipitation past 3 hours
+  0; 13;  21;    1;          -1;   14;      kg m-2; Total precipitation past 6 hours
+  0; 13;  22;    1;          -1;   14;      kg m-2; Total precipitation past 12 hours
+  0; 13;  23;    1;          -1;   14;      kg m-2; Total precipitation past 24 hours
+  0; 13;  31;    0;           0;    7;      kg m-2; Evapotranspiration
+  0; 13;  32;    1;           0;    8;      kg m-2; Evaporation/evapotranspiration
+  0; 13;  33;    1;           0;   10;      kg m-2; Evaporation/evapotranspiration
+  0; 13;  38;    0;           0;    2;  Code_Table; Superadiabatic indicator
+  0; 13;  39;    0;           0;    3;  Code_Table; Terrain type (ice/snow)
+  0; 13;  41;    0;           0;    4;  Code_Table; Pasquill-Gifford stability category
+  0; 13;  42;    0;         -20;    6;           K; Parcel lifted index (to 500 hPa)
+  0; 13;  43;    0;         -20;    6;           K; Best lifted index (to 500 hPa)
+  0; 13;  51;    0;           0;    4;  Code_Table; "Frequency group, precipitation"
+  0; 13;  52;    1;          -1;   14;      kg m-2; Highest daily amount of precipitation
+  0; 13;  60;    1;         -10;   17;      kg m-2; Total accumulated precipitation
+  0; 13;  71;    2;           0;   14;           m; Upstream water level
+  0; 13;  72;    2;           0;   14;           m; Downstream water level
+  0; 13;  73;    2;           0;   14;           m; Maximum water level
+  0; 13;  80;    1;           0;   10;     pH unit; Water pH
+  0; 13;  81;    3;           0;   14; Siemens m-1; Water conductivity
+  0; 13;  82;    1;           0;   12;           K; Water temperature
+  0; 13;  83;    6;           0;   15;      Kg m-3; Dissolved oxygen
+  0; 13;  84;    0;           0;   14;       Lumen; Turbidity
+  0; 13;  85;    3;           0;   14;           V; Oxydation Reduction Potential (ORP)
+# Class 14 - Radiation and radiance
+  0; 14;   1;   -3;       -2048;   12;       J m-2; "Long-wave radiation, integrated over 24 hours"
+  0; 14;   2;   -3;       -2048;   12;       J m-2; "Long-wave radiation, integrated over period specified"
+  0; 14;   3;   -3;       -2048;   12;       J m-2; "Short-wave radiation, integrated over 24 hours"
+  0; 14;   4;   -3;       -2048;   12;       J m-2; "Short-wave radiation, integrated over period specified"
+  0; 14;  11;   -3;       -2048;   12;       J m-2; "Net long-wave radiation, integrated over 24 hours"
+  0; 14;  12;   -3;       -2048;   12;       J m-2; "Net long-wave radiation, integrated over period specified"
+  0; 14;  13;   -3;       -2048;   12;       J m-2; "Net short-wave radiation, integrated over 24 hours"
+  0; 14;  14;   -3;       -2048;   12;       J m-2; "Net short-wave radiation, integrated over period specified"
+  0; 14;  15;   -4;      -16384;   15;       J m-2; "Net radiation, integrated over 24 hours"
+  0; 14;  16;   -4;      -16384;   15;       J m-2; "Net radiation, integrated over period specified"
+  0; 14;  17;   -3;       -2048;   12;       W m-2; Instantaneous long-wave radiation
+  0; 14;  18;   -3;       -2048;   12;       W m-2; Instantaneous short-wave radiation
+  0; 14;  19;    0;           0;    7;           %; Surface albedo
+  0; 14;  20;   -4;           0;   15;       J m-2; "Global solar radiation, integrated over 24 hours"
+  0; 14;  21;   -4;           0;   15;       J m-2; "Global radiation, integrated over period specified"
+  0; 14;  22;   -4;           0;   15;       J m-2; "Diffuse solar radiation, integrated over 24 hours"
+  0; 14;  23;   -4;           0;   15;       J m-2; "Diffuse solar radiation, integrated over period specified"
+  0; 14;  24;   -4;           0;   15;       J m-2; "Direct solar radiation, integrated over 24 hours"
+  0; 14;  25;   -4;           0;   15;       J m-2; "Direct solar radiation, integrated over period specified"
+  0; 14;  26;    0;           0;    7;           %; Albedo at the top of clouds
+  0; 14;  27;    0;           0;    7;           %; Albedo
+  0; 14;  31;    0;           0;   11;      Minute; Total sunshine
+  0; 14;  32;    0;           0;   10;        Hour; Total sunshine
+  0; 14;  33;    0;           0;    9;           %; Total sunshine
+  0; 14;  42;    0;           0;    7;           %; Bidirectional reflectance
+  0; 14;  45;    0;           0;   11;Wm-2 sr-1 cm-1; Channel radiance
+  0; 14;  51;   -3;           0;   14;       J m-2; Direct solar radiation integrated over last hour
+# Class 15 - Physical/chemical constituents
+  0; 15;   1;    0;           0;   10;      Dobson; Ozone
+  0; 15;   2;    2;           0;   10;     Numeric; Air mass (slant path at 22 km)
+  0; 15;   3;    4;           0;    9;      Pascal; Measured ozone partial pressure (sounding)
+  0; 15;   4;    3;           0;   11;     Numeric; Ozone sounding correction factor
+  0; 15;   5;    0;           0;   10;          DU; Ozone p
+  0; 15;  11;    3;       14000;   13;  log (1/m2); Log 10 of integrated electron density
+  0; 15;  15;    0;           0;   31;     Numeric; Maximum image spectral component before normalization
+# Class 19 - Synoptic features
+  0; 19;   1;    0;           0;    6;  Code_Table; Type of synoptic feature
+  0; 19;   2;   -2;           0;   12;           m; Effective radius of feature
+  0; 19;   3;    0;           0;    8;       m s-1; Wind speed threshold
+  0; 19;   4;   -2;           0;   12;           m; Effective radius with respect to wind speeds above threshold
+  0; 19;   5;    0;           0;    9; Degree_true; Direction of motion of feature
+  0; 19;   6;    2;           0;   14;       m s-1; Speed of motion of feature
+  0; 19;   7;   -3;           0;   12;           m; Effective radius of feature
+  0; 19;   8;    0;           0;    3;  Code_Table; Vertical extent of circulation
+  0; 19;   9;   -3;           0;   12;           m; Effective radius with respect to wind speeds above threshold (large storms)
+  0; 19;  10;    0;           0;    4;  Code_Table; Method for tracking the centre of synoptic feature
+# Class 20 - Observed phenomena
+  0; 20;   1;   -1;           0;   13;           m; Horizontal visibility
+  0; 20;   2;   -1;           0;    7;           m; Vertical visibility
+  0; 20;   3;    0;           0;    9;  Code_Table; Present weather
+  0; 20;   4;    0;           0;    5;  Code_Table; Past weather (1)
+  0; 20;   5;    0;           0;    5;  Code_Table; Past weather (2)
+  0; 20;   8;    0;           0;    5;  Code_Table; Cloud distribution for aviation
+  0; 20;   9;    0;           0;    4;  Code_Table; General Weather Indicator (TAF/METAR)
+  0; 20;  10;    0;           0;    7;           %; Cloud cover (total)
+  0; 20;  11;    0;           0;    4;  Code_Table; Cloud amount
+  0; 20;  12;    0;           0;    6;  Code_Table; Cloud type
+  0; 20;  13;   -1;         -40;   11;           m; Height of base of cloud
+  0; 20;  14;   -1;         -40;   11;           m; Height of top of cloud
+  0; 20;  15;   -1;           0;   14;          Pa; Pressure at base of cloud
+  0; 20;  16;   -1;           0;   14;          Pa; Pressure at top of cloud
+  0; 20;  17;    0;           0;    4;  Code_Table; Cloud top description
+  0; 20;  18;    0;           0;    2;  Code_Table; Tendency of runway visual range
+  0; 20;  19;    0;           0;   72;   CCITT_IA5; Significant present or forecast weather
+  0; 20;  20;    0;           0;   32;   CCITT_IA5; Significant recent weather phenomena
+  0; 20;  31;    2;           0;    7;           m; Ice deposit (thickness)
+  0; 20;  32;    0;           0;    3;  Code_Table; Rate of ice accretion
+  0; 20;  33;    0;           0;    4;  Flag_Table; Cause of ice accretion
+  0; 20;  34;    0;           0;    5;  Code_Table; Sea ice concentration
+  0; 20;  35;    0;           0;    4;  Code_Table; Amount and type of ice
+  0; 20;  36;    0;           0;    5;  Code_Table; Ice situation
+  0; 20;  37;    0;           0;    5;  Code_Table; Ice development
+  0; 20;  38;    0;           0;   12; Degree_true; Bearing of ice edge
+  0; 20;  39;   -1;           0;   13;           m; Ice distance
+  0; 20;  41;    0;           0;    4;  Code_Table; Airframe icing
+  0; 20;  51;    0;           0;    7;           %; Amount of low clouds
+  0; 20;  52;    0;           0;    7;           %; Amount of middle clouds
+  0; 20;  53;    0;           0;    7;           %; Amount of high clouds
+  0; 20;  61;    0;           0;   12;           m; Runway visual range (RVR)
+  0; 20;  62;    0;           0;    5;  Code_Table; State of the ground (with or without snow)
+  0; 20;  63;    0;           0;   10;  Code_Table; Special phenomena
+  0; 20;  70;    0;           0;    7;     Numeric; Minimum number of atmospherics
+  0; 20;  71;    0;           0;    4;  Code_Table; Accuracy of fix and rate of atmospherics
+  0; 20;  81;    0;           0;    7;           %; Cloud amount in segment
+  0; 20;  82;    0;           0;    7;           %; Amount segment cloud free
+  0; 20;  90;    0;           0;    4;  Code_Table; Special clouds
+# Class 21 - Radar data
+  0; 21;   1;    0;         -64;    7;          dB; Horizontal reflectivity
+  0; 21;   2;    0;         -64;    7;          dB; Vertical reflectivity
+  0; 21;   3;    1;          -5;    7;          dB; Differential reflectivity
+  0; 21;   5;    0;         -65;    6;          dB; Linear depolarisation ratio 
+  0; 21;   6;    0;         -65;    6;          dB; Circular depolarisation ratio 
+  0; 21;  11;    0;        -128;    8;       m s-1; Doppler mean velocity in X-direction
+  0; 21;  12;    0;        -128;    8;       m s-1; Doppler mean velocity in Y-direction
+  0; 21;  13;    0;        -128;    8;       m s-1; Doppler mean velocity in Z-direction
+  0; 21;  14;    1;       -4096;   13;       m s-1; Doppler mean velocity (radial)
+  0; 21;  17;    1;           0;    8;       m s-1; Doppler velocity spectral width
+  0; 21;  21;   -3;           0;    4;           m; Echo tops 
+  0; 21;  30;    0;         -32;    8;          dB; Signal to noise ratio
+  0; 21;  31;    0;           0;    7;      kg m-2; Vertically integrated liquid-water content
+  0; 21;  36;    7;           0;   12;       m s-1; Radar rainfall intensity 
+  0; 21;  41;   -2;           0;    8;           m; Bright-band height 
+  0; 21;  51;    0;        -256;    8;          dB; Signal power above 1 mW
+  0; 21;  62;    2;       -5000;   13;    Decibels; Backscatter
+  0; 21;  63;    1;           0;   10;           %; Radiometric resolution (noise value)
+  0; 21;  64;    0;           0;    8;     Numeric; Clutter noise estimate
+  0; 21;  65;    0;        -127;    8;     Numeric; Missing packet counter
+  0; 21;  66;    0;           0;   12;  Flag_Table; Wave scatterometer product confidence data
+  0; 21;  67;    0;           0;   13;  Flag_Table; Wind product confidence data
+  0; 21;  68;    0;           0;    8;  Flag_Table; Radar altimeter product confidence data
+  0; 21;  69;    0;           0;   10;  Flag_Table; SST product confidence data
+  0; 21;  71;    0;           0;   16;     Numeric; Peakiness
+  0; 21;  72;    0;           0;    4;  Flag_Table; Satellite altimeter calibration status
+  0; 21;  73;    0;           0;    9;  Flag_Table; Satelllite altimeter instrument mode
+  0; 21;  75;    0;           0;    8;     Numeric; Image spectrum intensity
+  0; 21;  76;    0;           0;    3;  Code_Table; Representation of intensities
+  0; 21;  77;    3;           0;   14;           m; Altitude correction (ionosphere)
+  0; 21;  78;    3;           0;    9;           m; Altitude correction (dry troposphere)
+  0; 21;  79;    3;        2000;   10;           m; Altitude correction (wet troposphere)
+  0; 21;  80;    3;           0;   11;           m; Altitude correction (calibration constant)
+  0; 21;  81;    3;           0;   10;           m; Open loop correction (height-time loop)
+  0; 21;  82;    3;       -3000;   14;    Decibels; Open loop correction (auto gain control)
+  0; 21;  85;    0;           0;    4;     Numeric; ATSR sea surface temperature across- track band number
+  0; 21; 101;    0;           0;    3;     Numeric; Number of vector ambiguities
+  0; 21; 102;    0;           0;    3;     Numeric; Index of selected wind vector
+  0; 21; 103;    0;           0;    5;     Numeric; Total number of sigma-0 measurements
+  0; 21; 104;    3;      -30000;   15;     Numeric; Likelihood computed for solution
+  0; 21; 105;    2;      -10000;   14;          dB; Normalized radar cross-section
+  0; 21; 106;    3;           0;   14;     Numeric; Kp variance coefficient (Alpha)
+  0; 21; 107;    8;           0;   16;     Numeric; Kp variance coefficient (Beta)
+  0; 21; 109;    0;           0;   17;  Flag_Table; SEAWINDS wind vector cell quality
+  0; 21; 110;    0;           0;    6;     Numeric; Number of inner-beam Sigma-0 (forward of satellite)
+  0; 21; 111;    0;           0;    6;     Numeric; Number of outer-beam Sigma-0 (forward of satellite)
+  0; 21; 112;    0;           0;    6;     Numeric; Number of inner-beam Sigma-0 (aft of satellite)
+  0; 21; 113;    0;           0;    6;     Numeric; Number of outer-beam Sigma-0 (aft of satellite)
+  0; 21; 114;    3;     -140000;   18;          dB; Kp variance coefficent (Gamma)
+  0; 21; 115;    0;           0;   17;  Flag_Table; SEAWINDS sigma-0 quality
+  0; 21; 116;    0;           0;   17;  Flag_Table; SEAWINDS sigma-0 mode
+  0; 21; 117;    2;           0;   16;     Numeric; Sigma-0 variance quality control
+  0; 21; 118;    2;      -10000;   14;          dB; Attenuation correction on sigma-0
+  0; 21; 119;    0;           0;    6;  Code_Table; Wind scatterometer geophysical model function
+# Class 22 - Oceanographic elements
+  0; 22;   1;    0;           0;    9; Degree_true; Direction of waves 
+  0; 22;   2;    0;           0;    9; Degree_true; Direction of wind waves 
+  0; 22;   3;    0;           0;    9; Degree_true; Direction of swell waves 
+  0; 22;   4;    0;           0;    9; Degree_true; Direction of current 
+  0; 22;  11;    0;           0;    6;           s; Period of waves 
+  0; 22;  12;    0;           0;    6;           s; Period of wind waves 
+  0; 22;  13;    0;           0;    6;           s; Period of swell waves 
+  0; 22;  21;    1;           0;   10;           m; Height of waves 
+  0; 22;  22;    1;           0;   10;           m; Height of wind waves 
+  0; 22;  23;    1;           0;   10;           m; Height of swell waves 
+  0; 22;  25;    2;           0;   10;           m; Standard deviation wave height
+  0; 22;  26;    2;           0;   10;           m; Standard deviation of significant wave height
+  0; 22;  31;    2;           0;   13;       m s-1; Speed of current 
+  0; 22;  35;    2;           0;   14;           m; Tidal elevation with respect to local chart datum
+  0; 22;  36;    2;           0;   14;           m; Meteorological residual tidal elevation (surge or offset)
+  0; 22;  37;    3;      -10000;   15;           m; Tidal elevation with respect to national land datum
+  0; 22;  38;    3;      -10000;   15;           m; Tidal elevation with respect to local chart datum
+  0; 22;  39;    3;       -5000;   12;           m; Meteorological residual tidal elevation (surge or offset)
+  0; 22;  40;    3;       -5000;   14;           m; Meteorological residual tidal elevation (surge or offset)
+  0; 22;  41;    1;           0;   12;           K; Sea-surface temperature (15-day running mean)
+  0; 22;  42;    1;           0;   12;           K; Sea/water temperature
+  0; 22;  43;    2;           0;   15;           K; Sea/water temperature
+  0; 22;  44;    1;           0;   14;       m s-1; Sound velocity 
+  0; 22;  50;    2;           0;    8;           K; Standard deviation sea-surface temperature
+  0; 22;  61;    0;           0;    4;  Code_Table; State of the sea 
+  0; 22;  62;    2;           0;   14;Part per thousand; Salinity
+  0; 22;  63;    0;           0;   14;           m; Total water depth 
+  0; 22;  67;    0;           0;   10;  Code_Table; Instrument type for water temperature profile measurement
+  0; 22;  68;    0;           0;    7;  Code_Table; Water temperature profile recorder types
+  0; 22;  70;    2;           0;   13;           m; Significant wave height
+  0; 22;  71;    1;           0;    9;           s; Spectral peak wave period
+  0; 22;  72;    0;           0;   13;           m; Spectral peak wave length
+  0; 22;  73;    2;           0;   13;           m; Maximum wave height
+  0; 22;  74;    1;           0;    9;           s; Average wave period
+  0; 22;  75;    0;           0;   13;           m; Average wave length
+  0; 22;  76;    0;           0;    9; Degree_true; Direction from which dominant waves are coming
+  0; 22;  77;    0;           0;    9;      Degree; Directional spread of dominant wave
+  0; 22;  78;    0;           0;   12;           s; Duration of wave record
+  0; 22;  79;    0;           0;   16;           m; Length of wave record
+  0; 22;  80;    3;           0;   10;          Hz; Waveband central frequency
+  0; 22;  81;    5;           0;   13;         m-1; Waveband central wave number
+  0; 22;  82;    2;           0;   20;        m2 s; Maximum non-directional spectral wave density
+  0; 22;  83;    2;           0;   20;          m3; Maximum non-directional spectral wave number
+  0; 22;  84;    0;           0;    7;     Numeric; Band containing maximum non- directional spectral wave density
+  0; 22;  85;    0;           0;    7;     Numeric; Spectral wave density ratio
+  0; 22;  86;    0;           0;    9; Degree_true; Mean direction from which waves are coming
+  0; 22;  87;    0;           0;    9; Degree_true; Principal direction from which waves are coming
+  0; 22;  88;    2;           0;    7;     Numeric; First normalized polar coordinate from Fourier coefficients
+  0; 22;  89;    2;           0;    7;     Numeric; Second normalized polar coordinate from Fourier coefficients
+  0; 22;  90;    2;           0;   20;        m2 s; Non-directional spectral estimate by wave frequency
+  0; 22;  91;    2;           0;   20;          m3; Non-directional spectral estimate by wave number
+  0; 22;  92;    2;           0;   20;  m2 rad-1 s; Directional spectral estimate by wave frequency
+  0; 22;  93;    2;           0;   20;          m4; Directional spectral estimate by wave number
+  0; 22;  94;    0;           0;    7;     Numeric; Total number of wave bands
+  0; 22;  95;    0;           0;    8;      Degree; Directional spread of individual waves
+  0; 22;  96;    3;           0;    4;         s-1; Spectral band width
+  0; 22;  97;    0;           0;   14;           m; Mean wavelength > 731 m of image spectrum at low wave numbers
+  0; 22;  98;    0;           0;   14;           m; Wavelength spread (wavelength > 731 m) at low wave numbers
+  0; 22;  99;    0;           0;    9; Degree_true; Mean direction at low wave numbers (wavelength > 731 m)
+  0; 22; 100;    0;           0;    9;      Degree; Direction spread at low wave numbers(wavelength > 731 m)
+  0; 22; 101;    0;           0;   31;     Numeric; Total energy (wavelength > 731m) at low wave numbers
+  0; 22; 120;    0;           0;    5;  Code_Table; Tide station automated water level check
+  0; 22; 121;    0;           0;    5;  Code_Table; Tide station manual water level check
+  0; 22; 122;    0;           0;    5;  Code_Table; Tide station automated meteorological data check
+  0; 22; 123;    0;           0;    5;  Code_Table; Tide station manual meteorological data check
+# Class 23 - Dispersal and transport
+  0; 23;   1;    0;           0;    3;  Code_Table; Accident early notification � article applicable
+  0; 23;   2;    0;           0;    5;  Code_Table; Activity or facility involved in incident
+  0; 23;   3;    0;           0;    3;  Code_Table; Type of release 
+  0; 23;   4;    0;           0;    3;  Code_Table; Countermeasures taken near border
+  0; 23;   5;    0;           0;    2;  Code_Table; Cause of incident 
+  0; 23;   6;    0;           0;    3;  Code_Table; Incident situation 
+  0; 23;   7;    0;           0;    3;  Code_Table; Characteristics of release
+  0; 23;   8;    0;           0;    2;  Code_Table; State of current release 
+  0; 23;   9;    0;           0;    2;  Code_Table; State of expected release 
+  0; 23;  16;    0;           0;    2;  Code_Table; Possibility of significant chemical toxic health effect
+  0; 23;  17;    6;           0;   20;     m3 s-1 ; Flow discharge of major recipient
+  0; 23;  18;    0;           0;    3;  Code_Table; Release behaviour over time
+  0; 23;  19;    0;      -15000;   17;           m; Actual release height
+  0; 23;  21;    0;      -15000;   17;           m; Effective release height
+  0; 23;  22;    0;           0;   24;           m; Distance of release point or site of incident
+  0; 23;  23;    1;           0;   12;     m s-1  ; Main transport speed in the atmosphere
+  0; 23;  24;    2;           0;   13;     m s-1  ; Main transport speed in water
+  0; 23;  25;    2;           0;   13;     m s-1  ; Main transport speed in ground water
+  0; 23;  27;    0;           0;    9; Degree_true; Main transport direction in the atmosphere
+  0; 23;  28;    0;           0;    9; Degree_true; Main transport direction in water
+  0; 23;  29;    0;           0;    9; Degree_true; Main transport direction in ground water
+  0; 23;  31;    0;           0;    2;  Code_Table; Possibility that plume will encounter precipitation in State in which incident occurred
+  0; 23;  32;    0;           0;    2;  Code_Table; Plume will encounter change in wind direction and/or speed flag
+# Class 24 - Radiological elements
+  0; 24;   1;  -11;           0;   28;         Bq*; Estimate of amount of radioactivity released up to specified time
+  0; 24;   2;  -11;           0;   28;          Bq; Estimated maximum potential release
+  0; 24;   3;    0;           0;    5;  Code_Table; Composition of release
+  0; 24;   4;    0;           0;   16;   CCITT_IA5; Element name
+  0; 24;   5;    0;           0;    9;     Numeric; Isotope mass
+  0; 24;  11;    2;           0;   32;     mSv*/**; Dose
+  0; 24;  12;    2;           0;   32;         mSv; Trajectory dose (defined location and expected time of arrival)
+  0; 24;  13;    2;           0;   32;         mSv; Gamma dose in air along the main transport path (defined location and time period)
+  0; 24;  21;    2;           0;   32;      Bq m-3; Air concentration (of named isotope type including gross beta)
+  0; 24;  22;    2;           0;   32;      Bq 1-1; Concentration in precipitation (of names isotope type)
+  0; 24;  23;    1;           0;   14;         s-1; Pulse rate of beta radiation
+  0; 24;  24;    1;           0;   14;         s-1; Pulse rate of gamma radiation
+# Class 25 - Processing information
+  0; 25;   1;   -1;           0;    6;           m; Range-gate length
+  0; 25;   2;    0;           0;    4;     Numeric; Number of gates averaged
+  0; 25;   3;    0;           0;    8;     Numeric; Number of integrated pulses
+  0; 25;   4;    0;           0;    2;  Code_Table; Echo processing
+  0; 25;   5;    0;           0;    2;  Code_Table; Echo integration
+  0; 25;   6;    0;           0;    3;  Code_Table; Z to R conversion
+  0; 25;   7;    0;           0;   12;     Numeric; Z to R conversion factor
+  0; 25;   8;    2;           0;    9;     Numeric; Z to R conversion exponent
+  0; 25;   9;    0;           0;    4;  Flag_Table; Calibration method
+  0; 25;  10;    0;           0;    4;  Code_Table; Clutter treatment
+  0; 25;  11;    0;           0;    2;  Code_Table; Ground occultation correction (screening)
+  0; 25;  12;    0;           0;    2;  Code_Table; Range attenuation correction
+  0; 25;  13;    0;           0;    2;  Flag_Table; Bright-band correction
+  0; 25;  14;    0;           0;   12;     Numeric; Azimuth clutter cut-off (see Note)
+  0; 25;  15;    0;           0;    2;  Flag_Table; Radome attenuation correction
+  0; 25;  16;    5;           0;    6;      dB m-1; Clear-air attenuation correction
+  0; 25;  17;    0;           0;    2;  Flag_Table; Precipitation attenuation correction
+  0; 25;  18;    7;           0;    6;     Numeric; A to Z law for attenuation factor
+  0; 25;  19;    2;           0;    7;     Numeric; A to Z law for attenuation exponent
+  0; 25;  20;    0;           0;    2;  Code_Table; Mean speed estimation
+  0; 25;  21;    0;           0;    8;  Flag_Table; Wind computation enhancement
+  0; 25;  30;    0;           0;    2;  Code_Table; Running mean sea-surface temperature usage
+  0; 25;  32;    0;           0;    2;  Code_Table; Wind profiler mode information*
+  0; 25;  33;    0;           0;    2;  Code_Table; Wind profiler submode information*
+  0; 25;  34;    0;           0;    4;  Flag_Table; Wind profiler quality control test results* 
+  0; 25;  36;    0;           0;    4;  Code_Table; Atmospherics location method
+  0; 25;  40;    0;           0;    4;  Code_Table; CO2 wind product derivation
+  0; 25;  41;    0;           0;    2;  Code_Table; Moving platform direction reporting method
+  0; 25;  42;    0;           0;    2;  Code_Table; Moving platform speed reporting method
+  0; 25;  43;    4;           0;   15;           s; Wave sampling interval (time)
+  0; 25;  44;    2;           0;   14;           m; Wave sampling interval (space)
+  0; 25;  45;    0;           0;   21;  Flag_Table; HIRS channel combination
+  0; 25;  46;    0;           0;    5;  Flag_Table; MSU channel combination
+  0; 25;  47;    0;           0;    4;  Flag_Table; SSU channel combination
+  0; 25;  48;    0;           0;   16;  Flag_Table; AMSU-A channel combination
+  0; 25;  49;    0;           0;    6;  Flag_Table; AMSU-B channel combination
+  0; 25;  51;    0;           0;    7;  Flag_Table; AVHRR channel combination
+  0; 25;  53;    0;           0;   12;  Flag_Table; Observation quality
+  0; 25;  60;    0;           0;   14;     Numeric; Software identification
+  0; 25;  70;    0;           0;    4;     Numeric; Major frame count
+  0; 25;  71;    0;           0;    5;     Numeric; Frame count
+  0; 25;  75;    0;           0;    5;     Numeric; Satellite antenna corrections version number
+  0; 25;  76;    8;           0;   30;     Log m-1; Log-10 of (Temperature-radiance central wavenumber) for ATOVS
+  0; 25;  77;    5;     -100000;   18;     Numeric; Bandwidth correction coefficient 1 for ATOVS
+  0; 25;  78;    5;           0;   17;     Numeric; Bandwidth correction coefficient 2 for ATOVS
+  0; 25;  79;    4;           0;   24;       W m-2; Albedo-radiance solar filtered irradiance for ATOVS
+  0; 25;  80;   10;           0;   14;           m; Albedo-radiance equivalent filter width for ATOVS
+  0; 25;  85;    0;           0;    7;     Numeric; Fraction of clear pixels in HIRS FOV
+  0; 25;  86;    0;           0;    2;  Code_Table; Depth correction indicator
+# Class 26 - Non-coordinate location (time)
+  0; 26;   1;    1;           0;   12;        Hour; Principal time of daily reading in UTC of maximum temperature
+  0; 26;   2;    1;           0;   12;        Hour; Principal time of daily reading in UTC of minimum temperature
+  0; 26;   3;    0;       -1440;   12;      Minute; Time difference
+  0; 26;  10;    0;           0;   26;  Flag_Table; Hours included
+# Class 27 - Non-coordinate location (horizontal - 1)
+  0; 27;   1;    5;    -9000000;   25;      Degree; Latitude (high accuracy)
+  0; 27;   2;    2;       -9000;   15;      Degree; Latitude (coarse accuracy)
+  0; 27;   3;    2;       -9000;   15;      Degree; Alternate latitude
+  0; 27;  20;    0;           0;   16;     Numeric; Satellite location counter
+  0; 27;  21;    0;           0;   16;     Numeric; Satellite sublocation dimension
+  0; 27;  31;    2; -1073741824;   31;           m; "In direction of 0 degrees longitude, distance from the Earth�s centre"
+# Class 28 - Non-coordinate location (horizontal - 2)
+  0; 28;   1;    5;   -18000000;   26;      Degree; Longitude (high accuracy)
+  0; 28;   2;    2;      -18000;   16;      Degree; Longitude (coarse accuracy)
+  0; 28;   3;    2;      -18000;   16;      Degree; Alternate longitude
+  0; 28;  31;    2; -1073741824;   31;           m; "In direction 90 degrees East, distance from the Earth�s centre"
+# Class 29 - Map data
+  0; 29;   1;    0;           0;    3;  Code_Table; Projection type
+  0; 29;   2;    0;           0;    3;  Code_Table; Coordinate grid type
+# Class 30 - Image
+  0; 30;   1;    0;           0;    4;     Numeric; Pixel value (4 bits)
+  0; 30;   2;    0;           0;    8;     Numeric; Pixel value (8 bits)
+  0; 30;   4;    0;           0;   16;     Numeric; Pixel value (16 bits)
+  0; 30;  21;    0;           0;   12;     Numeric; Number of pixels per row
+  0; 30;  22;    0;           0;   12;     Numeric; Number of pixels per column
+  0; 30;  31;    0;           0;    4;  Code_Table; Picture type
+  0; 30;  32;    0;           0;   16;  Flag_Table; Combination with other data
+# Class 31 - Data description operator qualifiers
+  0; 31;   0;    0;           0;    1;     Numeric; Short delayed descriptor replication factor
+  0; 31;   1;    0;           0;    8;     Numeric; Delayed descriptor replication factor
+  0; 31;   2;    0;           0;   16;     Numeric; Extended delayed descriptor replication factor
+  0; 31;  11;    0;           0;    8;     Numeric; Delayed descriptor and data repetition factor
+  0; 31;  12;    0;           0;   16;     Numeric; Extended delayed descriptor and data repetition factor
+  0; 31;  21;    0;           0;    6;  Code_Table; Associated field significance
+  0; 31;  31;    0;           0;    1;  Flag_Table; Data present indicator
+# Class 33 - Quality information
+  0; 33;   2;    0;           0;    2;  Code_Table; Quality information
+  0; 33;   3;    0;           0;    3;  Code_Table; Quality information
+  0; 33;   7;    0;           0;    7;           %; Per cent confidence
+  0; 33;  20;    0;           0;    3;  Code_Table; Quality control indication of following value
+  0; 33;  21;    0;           0;    2;  Code_Table; Quality of following value
+  0; 33;  22;    0;           0;    2;  Code_Table; Quality of buoy satellite transmission
+  0; 33;  23;    0;           0;    2;  Code_Table; Quality of buoy location
+  0; 33;  24;    0;           0;    4;  Code_Table; Station elevation quality mark (for mobile stations)
+  0; 33;  25;    0;           0;    3;  Code_Table; ACARS interpolated values
+  0; 33;  26;    0;           0;    6;  Code_Table; Mixing ratio quality
+  0; 33;  27;    0;           0;    3;  Code_Table; Location quality class (range of radius of 66 % confidence)
+  0; 33;  30;    0;           0;   24;  Flag_Table; Scan line status flags for ATOVS
+  0; 33;  31;    0;           0;   24;  Flag_Table; Scan line quality flags for ATOVS
+  0; 33;  32;    0;           0;   24;  Flag_Table; Channel quality flags for ATOVS
+  0; 33;  33;    0;           0;   24;  Flag_Table; Field of view quality flags for ATOVS
+  0; 33;  35;    0;           0;    4;  Code_Table; Manual/automatic quality control
+  0; 33;  36;    0;           0;    7;           %; Nominal confidence threshold
+  0; 33;  37;    0;           0;   20;  Flag_Table; Wind correlation error
+  0; 33;  40;    0;           0;    7;           %; Confidence interval
+# Class 35 - Data monitoring information
+  0; 35;   0;    0;           0;   10;  Code_Table; FM regional code number
+  0; 35;   1;    0;           0;    3;  Code_Table; Time-frame for monitoring
+  0; 35;  11;    0;           0;   14;     Numeric; Number of reports actually received
+  0; 35;  21;    0;           0;   48;   Character; Bulletin being monitored (TTAAii)
+  0; 35;  22;    0;           0;   48;   Character; Bulletin being monitored (YYGGgg)
+  0; 35;  30;    0;           0;    4;  Code_Table; Discrepancies in the availability of expected data
+  0; 35;  31;    0;           0;    7;  Code_Table; Qualifier on monitoring results
+  0; 35;  32;    0;           0;    4;  Code_Table; Cause of missing data
+  0; 35;  33;    0;           0;    7;  Code_Table; Observation and collection deficiencies
+  0; 35;  34;    0;           0;    3;  Code_Table; Statistical trends for availability of data (during the survey period(s))
diff --git a/data/tables/B3M-000-008-D b/data/tables/B3M-000-008-D
new file mode 100644
index 0000000..53fbe64
--- /dev/null
+++ b/data/tables/B3M-000-008-D
@@ -0,0 +1,2061 @@
+#
+# WMO source file name = BufrTabD-5-2000.txt
+# Master Table D Version 8
+#
+#-----------------------------------------------------
+# F X Y --> Table D descriptor being defined
+#      F X Y --> 
+#      F X Y --> descriptors defining sequence for
+#      F X Y --> corresponding Table D descriptor
+#      -1 --> end of sequence designator
+#------------------------------------------------------
+#  Category 00 - BUFR table entries sequences
+  3   0   2
+      0   0   2  "Table A category, line 1"
+      0   0   3  "Table A category, line 2"
+     -1
+  3   0   3
+      0   0  10  "F,  part descriptor"
+      0   0  11  "X,  part descriptor"
+      0   0  12  "Y,  part descriptor"
+     -1
+  3   0   4
+      3   0   3
+      0   0  13  "Element name, line 1"
+      0   0  14  "Element name, line 2"
+      0   0  15  Units name
+      0   0  16  Units scale sign
+      0   0  17  Units scale
+      0   0  18  Units reference sign
+      0   0  19  Units reference value
+      0   0  20  Element data width
+     -1
+  3   0  10
+      3   0   3  Table D descriptor to be defined
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Delayed descriptor replication factor
+      0   0  30  Descriptor defining sequence
+     -1
+#  Category 01 - Location and Identification sequences
+  3   1   1
+      0   1   1  WMO block number
+      0   1   2  WMO station number
+     -1
+  3   1   2
+      0   1   3  WMO Region number
+      0   1   4  WMO Region sub-area
+      0   1   5  Buoy/platform identifier
+     -1
+  3   1   3
+      0   1  11  Ship's call sign
+      0   1  12  Direction of motion of moving observing platform
+      0   1  13  Speed of motion of moving observing platform
+     -1
+  3   1  11
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+     -1
+  3   1  12
+      0   4   4  Hour
+      0   4   5  Minute
+     -1
+  3   1  13
+      0   4   4  Hour
+      0   4   5  Minute
+      0   4   6  Second
+     -1
+  3   1  21
+      0   5   1  Latitude - high accuracy
+      0   6   1  Longitude - high accuracy
+     -1
+  3   1  22
+      0   5   1  Latitude - high accuracy
+      0   6   1  Longitude - high accuracy
+      0   7   1  Height of station
+     -1
+  3   1  23
+      0   5   2  Latitude - coarse accuracy
+      0   6   2  Longitude - coarse accuracy
+     -1
+  3   1  24
+      0   5   2  Latitude - coarse accuracy
+      0   6   2  Longitude - coarse accuracy
+      0   7   1  Height of station
+     -1
+  3   1  25
+      3   1  23  Latitude and longitude (coarse accuracy)
+      0   4   3  Day
+      3   1  12  Time
+     -1
+  3   1  26
+      3   1  21  Latitude and longitude (high accuracy)
+      0   4   3
+      0   4   3  (Time period in days)
+      0   4   4
+      0   4   4  (Time period in hours)
+      0   4   5
+      0   4   5  (Time period in minutes)
+     -1
+  3   1  31
+      3   1   1  WMO block and station number
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  22  "Latitude and longitude (high  accuracy), height of station"
+     -1
+  3   1  32
+      3   1   1  WMO block and station number
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  24  "Latitude and longitude (coarse accuracy), height of station"
+     -1
+#  (Buoy/platform � fixed)
+  3   1  33
+      0   1   5  Buoy/platform identifier
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  21  Latitude and longitude (high accuracy)
+     -1
+#  (Buoy/platform � fixed)
+  3   1  34
+      0   1   5  Buoy/platform identifier
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+     -1
+#  (Buoy/platform � moving)
+  3   1  35
+      0   1   5  Buoy/platform identifier
+      0   1  12  Direction of motion of moving observing platform
+      0   1  13  Speed of motion of moving observing platform
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+     -1
+#  (Ship)
+  3   1  36
+      3   1   3  Ship's call sign and motion
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+     -1
+#  (Land station for vertical soundings)
+  3   1  37
+      3   1   1  WMO block and station number
+      0   2  11  Radiosonde type
+      0   2  12  Radiosonde computational method
+      3   1  11  Date
+      3   1  12  Time
+      3   1  22  "Latitude and longitude (high accuracy), height of station"
+     -1
+#  (Land station for vertical soundings)
+  3   1  38
+      3   1   1  WMO block and station number
+      0   2  11  Radiosonde type
+      0   2  12  Radiosonde computational method
+      3   1  11  Date
+      3   1  12  Time
+      3   1  24  "Latitude and longitude (coarse accuracy), height of station"
+     -1
+#  (Ship for vertical soundings)
+  3   1  39
+      3   1   3  Ship's call sign and motion
+      0   2  11  Radiosonde type
+      0   2  12  Radiosonde computational method
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+     -1
+  3   1  40
+      3   1   3  Ship's call sign and motion
+      0   2  11  Radiosonde type
+      0   2  12  Radiosonde computational method
+      3   1  11  Date
+      3   1  12  Time
+      3   1  24  "Latitude and longitude (coarse accuracy), height of station"
+     -1
+  3   1  41
+      0   1   7  Satellite identifier
+      0   2  21  Satellite instrument data used in processing
+      0   2  22  Satellite data processing technique used
+      3   1  11  Date
+      3   1  12  Time
+     -1
+  3   1  42
+      3   1  41  "Satellite identifier, data used, and data processing technique; date/time"
+      3   1  21  "Latitude, longitude"
+     -1
+  3   1  43
+      0   1   7  Satellite identifier
+      0   2  23  Cloud motion computational method
+      3   1  11  Date
+      3   1  13  Time
+      3   1  21  "Latitude, longitude"
+     -1
+  3   1  44
+      0   1   7  Satellite identifier
+      0   2  24  Integrated mean humidity computational method
+      3   1  11  Date
+      3   1  13  Time
+      3   1  21  "Latitude, longitude"
+     -1
+#  (Satellite location and velocity)
+  3   1  45
+      3   1  11  "Year, month, day"
+      3   1  12  "Time (hour, minute)"
+      2   1 138  Change width to 16 bits
+      2   2 131  Change scale to 3
+      0   4   6  Second
+      2   1   0  Change width back to Table B
+      2   2   0  Change scale back to Table B
+      3   4  30  Location relative to the Earth�s centre
+      3   4  31  Velocity relative to the Earth�s centre
+     -1
+  3   1  46
+      0   1   7  Satellite identifier
+      0   1  12  Direction of motion of moving observing platform
+      0   2  48  Satellite sensor indicator
+      0  21 119  Wind scatterometer geophysical model function
+      0  25  60  Software identification
+      2   2 124  Change scale
+      0   2  26  Cross-track resolution
+      0   2  27  Along-tract resolution
+      2   2   0  Change scale back to Table B
+      0   5  40  Orbit number
+     -1
+#  (ERS product header)
+  3   1  47
+      0   1   7  Satellite identifier
+      0  25  60  Software identification
+      0   1  33  Originating/generating centre
+      0   1  34  Originating/generating sub-centre
+      0   1  12  Direction of motion of moving observation platform
+      3   1  45  Satellite location and velocity
+      0   2  21  Satellite instrument data used in processing
+      3   1  11  "Date (year, month, day)"
+      3   1  12  "Time (hour, minute)"
+      2   1 138  Change bit width to 16 bits
+      2   2 131  Change scale to 3
+      0   4   6  Second
+      2   1   0  Change width back to Table B
+      2   2   0  Change scale back to Table B
+      3   1  23  "Location (latitude, longitude)"
+     -1
+#  (Radar parameters)
+  3   1  48
+      0   2 104  Antenna polarization
+      0   2 121  Mean frequency
+      0   2 113  Number of azimuth looks
+      0   2  26  Cross-track resolution
+      0   2  27  Along-track resolution
+      0   2 111  Radar incidence angle
+      0   2 140  Satellite radar beam azimuth angle
+      2   2 127  Change scale to �1
+      0   1  13  Radar platform velocity
+      2   2 126  Change scale to �2
+      0   7   1  Radar platform altitude
+      2   2   0  Change scale to Table B
+      0  25  10  Clutter treatment
+      0  21  64  Clutter noise estimate
+     -1
+#  (Radar beam data)
+  3   1  49
+      0   2 111  Radar incidence angle
+      0   2 112  Radar look angle
+      0  21  62  Backscatter
+      0  21  63  Radiometric resolution (Noise value)
+      0  21  65  Missing packet counter
+     -1
+  3   1  51
+      0   1   6  Aircraft identifier
+      0   2  61  Navigational system
+      3   1  11  Date
+      3   1  12  Time
+      3   1  21  "Latitude, longitude"
+      0   8   4  Phase of aircraft flight
+     -1
+  3   1  55
+      0   1   5  Buoy/platform identifier
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  21  Latitude and longitude (high accuracy)
+      0   1  12  Direction of motion of moving observing platform
+      0   1  14  Platform drift speed (high precision)
+     -1
+#  (Radar location(s))
+  3   1  62
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   1   1  WMO block and station number
+     -1
+#  (ACARS identification)
+  3   1  65
+      0   1   6  Aircraft flight number (see Note)
+      0   1   8  Aircraft registration number (see Note)
+      0   2   1  Type of station
+      0   2   2  Type of instrumentation for wind measurement
+      0   2   5  Precision of temperature observation
+      0   2  62  Type of aircraft data relay system
+      0   2  70  Original specification of latitude/longitude
+      0   2  65  ACARS ground receiving station
+     -1
+#  (ACARS location)
+  3   1  66
+      3   1  11  "Year, month, day"
+      3   1  13  "Hour, minute, second"
+      3   1  23  Latitude and longitude (coarse accuracy)
+      0   7   4  Pressure
+      0   2  64  Aircraft roll angle quality
+      0   8   4  Phase of aircraft flight
+     -1
+#  (Satellite identifier/Generating resolution)
+  3   1  71
+      0   1   7  Satellite identifier
+      0   1  31  Generating centre
+      0   2  20  Satellite classification
+      0   2  28  Segment size at nadir in X direction
+      0   2  29  Segment size at nadir in Y direction
+     -1
+#  (Satellite identification)
+  3   1  72
+      3   1  71  "Satellite identification, Generation resolution"
+      3   1  11  Date
+      3   1  13  Time
+      3   1  21  "Latitude, longitude"
+     -1
+#  Category 02 - Meteorological sequences common to surface data
+  3   2   1
+      0  10   4  Pressure (at station level)
+      0  10  51  Pressure reduced to mean sea level
+      0  10  61  3-hour pressure change
+      0  10  63  Characteristic of pressure tendency
+     -1
+#  (High altitude station)
+  3   2   2
+      0  10   4  Pressure (at station level)
+      0   7   4  Pressure level
+      0  10   3  Geopotential of pressure level
+      0  10  61  3-hour pressure change
+      0  10  63  Characteristic of pressure tendency
+     -1
+  3   2   3
+      0  11  11  Wind direction (10 m)
+      0  11  12  Wind speed (10 m)
+      0  12   4  Temperature (2 m)
+      0  12   6  Dew point (2 m)
+      0  13   3  Relative humidity
+      0  20   1  Horizontal visibility
+      0  20   3  Present weather
+      0  20   4  Past weather (1)
+      0  20   5  Past weather (2)
+     -1
+#  (General cloud information)
+  3   2   4
+      0  20  10  Cloud cover (total)
+      0   8   2  Vertical significance
+      0  20  11  Cloud amount
+      0  20  13  Height of base of cloud
+      0  20  12  Cloud type
+      0  20  12  Cloud type
+      0  20  12  Cloud type
+     -1
+  3   2   5
+      0   8   2  Vertical significance
+      0  20  11  Cloud amount
+      0  20  12  Cloud type
+      0  20  13  Height of base of cloud
+     -1
+  3   2   6
+      0  10   4  Pressure (at station level)
+      0  10  51  Pressure reduced to mean sea level
+      0  10  62  24-hour pressure change
+      0  10  63  Characteristic of pressure tendency
+     -1
+#  (Low altitude station)
+  3   2  11
+      3   2   1  Pressure and pressure change
+      3   2   3  "Wind, temperature, humidity, visibility, weather"
+      3   2   4  Significant cloud layer
+     -1
+#  (High altitude station)
+  3   2  12
+      3   2   2  Pressure and pressure change
+      3   2   3  "Wind, temperature, humidity, visibility, weather"
+      3   2   4  Significant cloud information
+     -1
+  3   2  13
+      3   2   6  Pressure and pressure change
+      3   2   3  "Wind, temperature, humidity, visibility, weather"
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Delayed descriptor replication factor
+      3   2   5  Cloud layer information
+     -1
+  3   2  21
+      0  22   1  Direction of waves
+      0  22  11  Period of waves
+      0  22  21  Height of waves
+     -1
+  3   2  22
+      0  22   2  Direction of wind waves
+      0  22  12  Period of wind waves
+      0  22  22  Height of wind waves
+     -1
+  3   2  23
+      0  22   3  Direction of swell waves
+      0  22  13  Period of swell waves
+      0  22  23  Height of swell waves
+     -1
+  3   2  24
+      3   2  22  Wind waves
+      1   1   2  Replicate 1 descriptor 2 times
+      3   2  23  Swell waves (2 systems of swell)
+     -1
+  3   2  51
+      0  10   4  Pressure
+      0  10  51  Pressure reduced to mean sea level
+      0   7   4  Pressure (vertical location)
+      0  10   3  Geopotential
+      0  12   4  Dry-bulb temperature at 2 m
+      0  12  51  Standard deviation temperature
+      0  12  16  "Maximum temperature at 2 m, past 24 hours"
+      0  12  17  "Minimum temperature at 2 m, past 24 hours"
+      0  13   4  Vapour pressure
+      1   2   4  Replicate 2 descriptors 4 times
+      0   8  51  Qualifier for number of missing values in calculation of statistic
+      0   8  20  Total number of missing entities (with respect to accumulation or average)
+     -1
+#  Category 03 - Meteorological sequences common to vertical soundings data
+  3   3   1
+      0   7   3  Geopotential
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3   2
+      0   7   4  Pressure
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3   3
+      0   7   4  Pressure
+      0  10   3  Geopotential
+      0  12   1  Temperature
+      0  12   3  Dew point
+     -1
+  3   3   4
+      0   7   4  Pressure
+      0  10   3  Geopotential
+      0  12   1  Temperature
+      0  12   3  Dew point
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3  11
+      0   7   3  Geopotential
+      0   8   1  Vertical sounding significance
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3  12
+      0   7   4  Pressure
+      0   8   1  Vertical sounding significance
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3  13
+      0   7   4  Pressure
+      0   8   1  Vertical sounding significance
+      0  10   3  Geopotential
+      0  12   1  Temperature
+      0  13   3  Relative humidity
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3  14
+      0   7   4  Pressure
+      0   8   1  Vertical sounding significance
+      0  10   3  Geopotential
+      0  12   1  Temperature
+      0  12   3  Dew point
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3  21
+      0   7   4  Pressure (1)
+      0   7   4  Pressure (2)     defines layer
+      2   4   7  Add associated field of 7 bits
+      0  31  21  Additional field significance
+     -1
+  3   3  22
+      3   3  21  "Layer, quality"
+      0  10   3  Geopotential (layer mean thickness)
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  23
+      3   3  21  "Layer, quality"
+      0  12   1  Temperature (layer mean)
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  24
+      3   3  21  "Layer, quality"
+      0  13  16  Precipitation water
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  25
+      0   2  25  Satellite channel
+      2   4   7  Add associated field of 7 bits
+      0  31  21  Additional field significance
+      0  12  63  Brightness temperature
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  26
+      0   7   4  Pressure
+      0   8   3  Vertical significance
+      2   4   7  Add associated field of 7 bits
+      0  31  21  Additional field significance
+      0  12   1  Temperature
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  27
+      0   7   4  Pressure
+      2   4   7  Add associated field of 7 bits
+      0  31  21  Additional field significance
+      0  10   3  Geopotential
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  31
+      0   7   4  Pressure
+      0   8   3  Vertical significance (base of sounding)
+      0   7  21  Elevation (local zenith)
+      0   7  22  Solar elevation (solar zenith)
+      0   8  12  Land/sea qualifier
+      0  12  61  Skin temperature
+     -1
+  3   3  32
+      0  20  11  Cloud amount
+      0  20  16  Pressure at top of cloud
+     -1
+  3   3  33
+      0  20  10  Cloud cover (total)
+      0  20  16  Pressure at the top of cloud
+     -1
+#  (Wind sequence)
+  3   3  41
+      0   2 152  Geostationary satellite instrument used
+      0   2  23  Cloud motion computational method
+      0   7   4  Pressure
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+      0   2 153  Satellite channel centre frequency
+      0   2 154  Satellite channel band width
+      0  12  71  Coldest cluster T
+     -1
+#  Category 04 - Meteorological sequences common to satellite observations
+  3   4   1
+      0   8   3  Vertical significance
+      0  10   4  Pressure
+      0  12   1  Temperature
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   4   2
+      0   8   3  Vertical significance
+      0  10   4  Pressure
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   4   3
+      0   8   3  Vertical significance
+      0  12   1  Temperature
+     -1
+  3   4   4
+      0   8   3  Vertical significance
+      0  10   4  Pressure
+      0  20  10  Cloud cover (total)
+      0  12   1  Temperature
+     -1
+  3   4   5
+      0   2  24  Integrated mean humidity computational method
+      0   7   4  Pressure(1)
+      0   7   4  Pressure (2)    defines layer
+      0  13   3  Relative humidity
+     -1
+  3   4   6
+      0  14   1  Outgoing long-wave radiation
+      0  14   1  Incoming long-wave radiation
+      0  14   3  Outgoing short-wave radiation
+     -1
+#  (GOES-I/M info)
+  3   4  11
+      0   2 163  Height assignment method
+      0   2 164  Tracer correlation method
+      0   8  12  Land/sea qualifier
+      0   7  24  Satellite zenith angle
+      0   2  57  Origin of first guess information
+      0   8  21  Time significance
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+      0   4   4  Hour
+      0   8  21  Time significance
+      0   4  24  Time period or displacement
+      1  10   4  Replicate 10 descriptors 4 times
+      0   8  21  Time significance
+      0   4   4  Hour
+      0   4   5  Minute
+      0   4   6  Second
+      0   8  21  Time significance
+      0   4   4  Hour
+      0   4   5  Minute
+      0   4   6  Second
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+      1   3  10  Replicate 3 descriptors 10 times
+      0   2 163  Height assignment method
+      0   7   4  Pressure
+      0  12   1  Temperature
+     -1
+#  (Location of platform)
+  3   4  30
+      0  27  31  "In direction of 0 degree longitude, distance from the Earth�s centre"
+      0  28  31  "In direction of 90 degrees East longitude, distance from the Earth�s centre"
+      0  10  31  "In direction of North Pole, distance from Earth�s centre"
+     -1
+#  (Speed of platform)
+  3   4  31
+      0   1  41  Absolute platform velocity � first component
+      0   1  42  Absolute platform velocity � second component
+      0   1  43  Absolute platform velocity � third component
+     -1
+#  (Cloud fraction)
+  3   4  32
+      0   2 153  Satellite channel centre frequency
+      0   2 154  Satellite channel band width
+      0  20  81  Cloud amount in segment
+      0  20  82  Amount segment cloud free
+      0  20  12  Cloud type
+     -1
+#  (Clear sky radiance)
+  3   4  33
+      0   2 152  Satellite instrument used in data processing
+      0   2 166  Radiance type
+      0   2 167  Radiance computational method
+      0   2 153  Satellite channel centre frequency
+      0   2 154  Satellite channel band width
+      0  12  75  Spectral radiance
+      0  12  76  Radiance
+      0  12  63  Brightness temperature
+     -1
+#  Category 06 - Meteorological or oceanographic sequences common to oceanographic observations
+  3   6   1
+      0   2  32  Indicator for digitization
+      1   2   0  Delayed replication of 2 descriptors
+      0  31   1  Replication factor
+      0   7  62  Depth below sea surface
+      0  22  42  Subsurface sea temperature
+     -1
+  3   6   2
+      0   2  31  Method of current measurement
+      0  22   4  Direction of current
+      0  22  31  Speed of current
+     -1
+  3   6   3
+      0   2   2  Wind instrumentation
+      0  11  11  Wind direction (10 m)
+      0  11  12  Wind speed (10 m)
+      0  12   4  Dry-bulb temperature (2 m)
+     -1
+  3   6   4
+      0   2  32  Indicator for digitization
+      0   2  33  Method of salinity/depth measurement
+      1   3   0  Delayed replication of 3 descriptors
+      0  31   1  Replication factor
+      0   7  62  Depth below sea surface
+      0  22  43  Subsurface sea temperature
+      0  22  62  Salinity
+     -1
+  3   6   5
+      0   2  31  Method of current measurement
+      1   3   0  Delayed replication of 3 descriptors
+      0  31   1  Replication factor
+      0   7  62  Depth below sea surface
+      0  22   4  Direction of current
+      0  22  31  Speed of current
+     -1
+#  (Under water sounding (optional) parameters)
+  3   6   6
+      3   6   3  Surface wind and temperature
+      3   6   2  Current
+      0  22  63  Total water depth
+     -1
+#  (Buoy spare block parameters)
+  3   6   7
+      0   1  12  Direction of motion of moving observing platform
+      0   1  14  Platform drift speed (high precision)
+      3   6   8  Buoy instrumentation
+      0   4  24  Time period
+      0  27   3  Alternate latitude
+      0  28   3  Alternate longitude
+     -1
+#  (Buoy instrumentation parameters)
+  3   6   8
+      0   2  34  Drogue type
+      0   2  35  Cable length
+      0   2  36  Buoy type
+     -1
+  3   6  20
+      3   6od or displacement, time increment"  "Tide station identification, date/time, water temperature, tide station tide data status, time period or displacement, time increment"
+      1   2   6  Replicate 2 descriptors 6 times
+      0  22  38  Tidal elevation with respect to local chart datum
+      0  22  39  Meteorological residual tidal elevation
+     -1
+  3   6  21
+      0   1  75  Tide station alphanumeric identification
+      3   1  11  "Year, month, day"
+      3   1  12  "Hour, minute"
+      0  22 122  Tide station automated meteorological data check
+      0  22 123  Tide station manual meteorological data check
+      0  12   1  Air temperature
+      3   3   2  "Pressure, wind direction, wind speed"
+     -1
+  3   6  22
+      0   1  75  Tide station alphanumeric identification
+      3   1  11  "Year, month, day"
+      3   1  12  "Hour, minute"
+      0  22  38  Tidal elevation with respect to local chart datum
+      0  22  39  Meteorological residual tidal elevation
+     -1
+  3   6  23
+      0   1  15  Station or site name
+      3   1  23  "Latitude, longitude"
+      3   1  11  "Year, month, day"
+      3   1  12  "Hour, minute"
+      0  22  38  Tidal level with respect to local chart datum
+      0  22  39  Meteorological residual tidal elevation
+      0  22 120  Tide station automated water level check
+      0  22 121  Tide station manual water level check
+     -1
+  3   6  24
+      0   1  75  Tide station alphanumeric identification
+      3   1  11  "Year, month, day"
+      3   1  12  "Hour, minute"
+      0  22  42  Sea/water temperature
+      0  22 120  Tide station automated water level check
+      0  22 121  Tide station manual water level check
+      0   4  25  Time period or displacement
+      0   4  15  Time increment
+     -1
+#  Category 07 - Surface report sequences (land)
+#  (Low altitude station)
+  3   7   1
+      3   1  31  "Identification, type, date/time, position (high accuracy), height"
+      3   2  11  Basic surface report
+     -1
+#  (Low altitude station)
+  3   7   2
+      3   1  32  "Identification, type, date/time, position (coarse accuracy), height"
+      3   2  11  Basic surface report
+     -1
+#  (Low altitude station)
+  3   7   3
+      3   7   1  Location (high accuracy) and basic report
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   2   5  Cloud layer information
+     -1
+#  (Low altitude station)
+  3   7   4
+      3   7   2  Location (coarse accuracy) and basic report
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   2   5  Cloud layer information
+     -1
+#  (Low altitude station)
+  3   7   5
+      3   7   1  Location (high accuracy) and basic report
+      1   1   4  Replicate 1 descriptor 4 times
+      3   2   5  Cloud layer information (4 layers)
+     -1
+#  (Low altitude station)
+  3   7   6
+      3   7   2  Location (coarse accuracy) and basic report
+      1   1   4  Replicate 1 descriptor 4 times
+      3   2   5  Cloud layer information (4 layers)
+     -1
+#  (High altitude station)
+  3   7   7
+      3   1  31  "Identification, type, date/time, position (high accuracy), height"
+      3   2  12  Basic surface report
+     -1
+#  (High altitude station)
+  3   7   8
+      3   1  32  "Identification, type, date/time, position (coarse accuracy), height"
+      3   2  12  Basic surface report
+     -1
+  3   7   9
+      3   1  31  "Identification, type, date/time, position (high accuracy), height"
+      3   2  13  Basic surface report
+     -1
+#  (Main part of data for representation of METAR/SPECI code in BUFR)
+  3   7  11
+      0   1  63  ICAO location indicator - CCCC
+      0   2   1  Type of station - (AUTO)
+      3   1  11  "Year, month, day (YY)"
+      3   1  12  "GG, gg"
+      3   1  24  "Latitude-longitude (coarse accuracy), height of station"
+      0   7   6  Height above station (= height of an anemometer)
+      0  11   1  Wind direction - ddd
+      0  11  16  Extreme counterclockwise wind direction of a variable wind -dndndn
+      0  11  17  Extreme clockwise wind direction of a variable wind - dxdxdx
+      0  11   2  Wind speed - ff
+      0  11  41  Maximum wind speed (gusts) - fmfm
+      0   7   6  Height above station (= height of a thermometer)
+      0  12   1  Temperature - T�T�
+      0  12   3  Dew-point temperature - T�dT�d
+      0  10  52  Altimeter setting (QNH) - PhPhPhPh
+      0  20   9  General Weather Indicator TAF/METAR
+     -1
+#  (DvVVVV)
+  3   7  12
+      1   3   0  Delayed replication of 3 descriptors
+      0  31   1  Number of replication (up to 3)
+      0   8  23  First order statistics
+      0   5  21  Direction of visibility observed - Dv
+      0  20   1  Horizontal visibility - WW
+     -1
+#  (DRDRVRVRVRVR)
+  3   7  13
+      1   6   0  Delayed replication of 6 descriptors
+      0  31   1  Number of replication (up to 4)
+      0   1  64  Runway designator -
+      0   8  14  Qualification for runway visual range
+      0  20  61  Runway visual range - VrVrVrVr
+      0   8  14  Qualification for runway visual range
+      0  20  61  Runway visual range - VrVrVrVr
+      0  20  18  Tendency of runway visual range
+     -1
+#  (w�w�)
+  3   7  14
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Number of replication (up to 3)
+      0  20  19  Significant present weather - w�w�
+     -1
+#  (Clouds group(s))
+  3   7  15
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Number of replication
+      3   2   5  "(NsNsNs, CC, hshshs)"
+      0  20   2  Vertical visibility - VVhshshs
+     -1
+#  (REw�w�)
+  3   7  16
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Number of replication (up to 3)
+      0  20  20  Significant recent weather phenomena - REw�w�
+     -1
+#  (Wind shear on runways(s))
+  3   7  17
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Number of replication
+      0  11  70  Runway designator of the runway affected by wind shear (including ALL) - WS RWYDrDr
+     -1
+#  (Trend-type landing forecast)
+  3   7  18
+      0   8  16  Change qualifier of a trend-type - TTTTT
+      1   2   0  Delayed replication of 2 descriptors
+      0  31   1  Number of replication (up to 2)
+      0   8  17  Qualifier of the time when the forecast - TT
+      3   1  12  "GG, gg"
+      1   4   0  Delayed replication of 4 descriptor
+      0  31   1  Number of replication (up to 1)
+      0   7   6  Height above station
+      0  11   1  Wind direction - ddd
+      0  11   2  Wind speed - ff
+      0  11  41  Maximum wind speed (gusts) - fmfm
+      0  20   9  General Weather Indicator
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Number of replication (up to 1)
+      0  20   1  Horizontal visibility - WW
+      3   7  14  w�w�
+     -1
+#  (Short METAR/SPECI)
+  3   7  20
+      3   7  11  Main part of data
+      3   7  14  w�w�
+      3   7  16  REw�w�
+     -1
+#  (Total sequence for representation of METAR/SPECI code in BUFR)
+  3   7  21
+      3   7  11  Main part of data
+      3   7  12  DvVVVV
+      3   7  13  DRDRVRVRVRVR
+      3   7  14  w�w�
+      3   7  15  Clouds group(s)
+      3   7  16  REw�w�
+      3   7  17  Wind shear on runway(s)
+      3   7  18  Trend-type landing forecast
+      3   7  15  Clouds group(s)
+     -1
+#  Category 08 - Surface report sequences (sea)
+#  (Buoy/platform � fixed)
+  3   8   1
+      3   1  33  "Identification, type, date/time, position (high accuracy)"
+      3   2  11  Basic surface report
+      0  22  42  Sea-surface temperature
+     -1
+#  (Buoy/platform � fixed)
+  3   8   2
+      3   1  34  "Identification, type, date/time, position (coarse accuracy)"
+      3   2  11  Basic surface report
+      0  22  42  Sea-surface temperature
+     -1
+#  (Buoy/platform � moving)
+  3   8   3
+      3   1  35  "Identification, movement, type, date/time, position (coarse accuracy)"
+      3   2  11  Basic surface report
+      0  22  42  Sea-surface temperature
+     -1
+#  (Ship)
+  3   8   4
+      3   1  36  "Identification, movement, type, date/time, position (coarse accuracy)"
+      3   2  11  Basic surface report
+      0  22  42  Sea-surface temperature
+     -1
+  3   8   5
+      3   8   4  Basic ship report
+      3   2  24  Wind waves and swell waves
+     -1
+#  (Buoy Section 1 optional parameters)
+  3   8   6
+      0  10   4  Pressure
+      0  10  61  3-hour pressure change
+      0  10  63  Characteristic of pressure tendency
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+      0  12   4  Dry-bulb temperature at 2 m
+      0  13   3  Relative humidity
+      0  22  42  Sea temperature
+     -1
+  3   8   7
+      3   1  55  "Identification, movement type, date/time, position (high accuracy)"
+      3   2  11  Basic surface report
+      0   7  62  Depth below sea/water surface
+      0  22  42  Sea/water temperature
+     -1
+#  Category 09 - Vertical sounding sequences (conventional data)
+#  (Vertical wind profile)
+  3   9   1
+      3   1  37  "Identification, etc. (land station, high accuracy position)"
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  11  Winds at heights
+     -1
+#  (Vertical wind profile)
+  3   9   2
+      3   1  38  "Identification, etc. (land station, coarse accuracy position)"
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  11  Winds at heights
+     -1
+#  (Vertical wind profile)
+  3   9   3
+      3   1  37  "Identification, etc. (land station, high accuracy position)"
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  12  Winds at pressure levels
+     -1
+#  (Vertical wind profile)
+  3   9   4
+      3   1  38  "Identification, etc. (land station, coarse accuracy position)"
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  12  Winds at pressure levels
+     -1
+#  (Vertical sounding with relative humidity)
+  3   9   5
+      3   1  37  "Identification, etc. (land station, high accuracy position)"
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  13  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical sounding with relative humidity)
+  3   9   6
+      3   1  38  "Identification, etc. (land station, coarse  accuracy position)"
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  13  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical sounding with dew-point data)
+  3   9   7
+      3   1  37  "Identification, etc. (land station, high accuracy position)"
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  14  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical sounding with dew-point data)
+  3   9   8
+      3   1  38  "Identification, etc. (land station, coarse accuracy position)"
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  14  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical wind profile)
+  3   9  11
+      3   1  39  "Ship's identification, etc."
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  11  Winds at heights
+     -1
+#  (Vertical wind profile)
+  3   9  12
+      3   1  39  "Ship's identification, etc."
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  12  Winds at pressure levels
+     -1
+#  (Vertical sounding with relative humidity)
+  3   9  13
+      3   1  39  "Ship's identification, etc."
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  13  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical sounding with dew-point data)
+  3   9  14
+      3   1  39  "Ship's identification, etc."
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  14  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical wind profile)
+  3   9  15
+      3   1  40  "Ship's identification, etc."
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  11  Winds at heights
+     -1
+#  (Vertical wind profile)
+  3   9  16
+      3   1  40  "Ship's identification, etc."
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  12  Winds at pressure levels
+     -1
+#  (Vertical sounding with relative humidity)
+  3   9  17
+      3   1  40  "Ship's identification, etc."
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  13  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical sounding with dew-point data)
+  3   9  18
+      3   1  40  "Ship's identification, etc."
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  14  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Wind profiler � wind data sounding)
+  3   9  19
+      3   1  31  "Identification, etc."
+      0   2   3  Type of measuring equipment used
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  11  Winds at heights
+     -1
+#  (Wind profiler � Cartesian coordinates)
+  3   9  20
+      3   1  31  "Identification, etc."
+      0   2   3  Type of measuring equipment used
+      1   4   0  Delayed replication of 4 descriptors
+      0  31   1  Replication factor
+      0   7   3  Geopotential
+      0  11   3  u-component
+      0  11   4  v-component
+      0  11   5  w-component
+     -1
+#  Category 10 - Vertical sounding sequences (satellite data)
+#  (Satellite � brightness temperature)
+  3  10   1
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  32  Cloud
+      1   1  26  Replicate 1 descriptor 26 times
+      3   3  25  Satellite channel and brightness temperature
+     -1
+#  (Satellite � low level)
+  3  10   2
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  32  Cloud
+      1   1   9  Replicate 1 descriptor 9 times
+      3   3  23  Layer mean temperature
+     -1
+#  (Satellite � high level)
+  3  10   3
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  32  Cloud
+      1   1   6  Replicate 1 descriptor 6 times
+      3   3  23  Layer mean temperature
+     -1
+#  (Satellite � precipitable water)
+  3  10   4
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  32  Cloud
+      1   1   3  Replicate 1 descriptor 3 times
+      3   3  24  Precipitable water
+     -1
+  3  10   5
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  33  Cloud
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Delayed descriptor replication factor
+      3   3  25  Satellite channel and brightness temperature
+     -1
+  3  10   6
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  33  Cloud
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Delayed descriptor replication factor
+      3   3  23  Layer mean temperature
+     -1
+  3  10   7
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  33  Cloud
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Delayed descriptor replication factor
+      3   3  24  Precipitable water
+     -1
+#  (ATOVS HIRS report)
+  3  10   8
+      3  10  11  ATOVS field of view variables
+      1   1  19  Replicate 1 descriptor 19 times
+      3  10  12  ATOVS channel variables
+      0   2 150  TOVS/ATOVS/AVHRR instrumentation channel number
+      0  25  79  Albedo-radiance solar filtered irradiance for ATOVS
+      0  25  80  Albedo-radiance equivalent filter width for ATOVS
+      0  33  32  Channel quality flags for ATOVS
+      0  14  45  Channel radiance
+     -1
+#  (ATOVS AMSU-A report)
+  3  10   9
+      3  10  11  ATOVS field of view variables
+      1   1  15  Replicate 1 descriptor 15 times
+      3  10  12  ATOVS channel variables
+     -1
+#  (ATOVS AMSU-B report)
+  3  10  10
+      3  10  11  ATOVS field of view variables
+      1   1   5  Replicate 1 descriptor 5 times
+      3  10  12  ATOVS channel variables
+     -1
+#  (ATOVS field of view variables)
+  3  10  11
+      0   8  70  TOVS/ATOVS product qualifier
+      0   1  33  Identification of originating/generating centre
+      0   1  34  Identification of originating/generating centre
+      0   8  70  TOVS/ATOVS product qualifier
+      0   1  33  Identification of originating/generating centre
+      0   1  34  Identification of originating/generating centre
+      0   1   7  Satellite identification
+      0   2  48  Satellite sensor indicator
+      0   5  40  Orbit number
+      0  25  75  Satellite antenna corrections version number
+      2   1 133  Change width
+      0   5  41  Scan line number
+      2   1   0  Change width
+      0   5  43  Field of view number
+      0  25  70  Major frame count
+      0  33  30  Scan line status flags for ATOVS
+      0  33  31  Scan line quality flags for ATOVS
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+      0   4   4  Hour
+      0   4   5  Minute
+      2   2 131  Change scale
+      2   1 138  Change width
+      0   4   6  Second
+      2   1   0  Change width
+      2   2   0  Change scale
+      0   5   1  Latitude
+      0   6   1  Longitude
+      2   2 126  Change scale
+      0   7   1  Height of station
+      2   2   0  Change scale
+      0   7  24  Satellite zenith angle
+      0   5  21  Satellite azimuth
+      0   7  25  Solar zenith angle
+      0   5  22  Solar azimuth
+      0  33  33  Field of view quality flags for ATOVS
+      0   2 151  Radiometer identifier
+      0  12  64  Instrument temperature
+      0   2 151  Radiometer identifier
+      0  12  64  Instrument temperature
+      0   2 151  Radiometer identifier
+      0  12  64  Instrument temperature
+      0   2 151  Radiometer identifier
+      0  12  64  Instrument temperature
+     -1
+#  (ATOVS channel variables)
+  3  10  12
+      0   2 150  TOVS/ATOVS/AVHRR instrumentation channel number
+      0  25  76  Log�10 of (temperature-radiance central wavenumber) for ATOVS
+      0  25  77  Bandwidth correction coefficient 1 for ATOVS
+      0  25  78  Bandwidth correction coefficient 2 for ATOVS
+      0  33  32  Channel quality flags for ATOVS
+      2   1 132  Change width
+      2   2 129  Change scale
+      0  12  63  Brightness temperature
+      2   2   0  Change scale
+      2   1   0  Change width
+     -1
+#  (AVHRR (GAC) report)
+  3  10  13
+      0   1   7  Satellite ID
+      0   5  40  Orbit number
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+      0   4   4  Hour
+      0   4   5  Minute
+      0   4   6  Second
+      0   5   1  Latitude
+      0   6   1  Longitude
+      0   7  25  Solar zenith angle
+      0   5  43  Field of view number
+      0  25  85  Fraction of clear pixels in HIRS field of view
+      2   1 131  Change width
+      2   2 129  Change scale
+      0   2 150  TOVS/ATOVS/AVHRR instrumentation channel number
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  14  27  Albedo
+      0   8  72  Pixel(s) type
+      0  14  27  Albedo
+      0   2 150  TOVS/ATOVS/AVHRR instrumentation channel number
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  14  27  Albedo
+      0   8  72  Pixel(s) type
+      0  14  27  Albedo
+      0   2 150  ATOVS/AVHRR instrumentation channel number
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  14  27  Albedo
+      0   8  72  Pixel(s) type
+      0  14  27  Albedo
+      2   2   0  Change scale
+      2   1   0  Change width
+      2   1 132  Change width
+      2   2 129  Change scale
+      0   2 150  ATOVS/AVHRR instrumentation channel number
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   2 150  ATOVS/AVHRR instrumentation channel number
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   2 150  ATOVS/AVHRR instrumentation channel number
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      2   2   0  Change scale
+      2   1   0  Change width
+     -1
+#  (Satellite � geostationnary wind data)
+  3  10  14
+      3   1  72  "Satellite identification, date, time, latitude, longitude"
+      3   3  41  Wind sequence
+      3   4  11  GOES-I/M information
+     -1
+#  (Meteosat radiace data)
+  3  10  15
+      3   1  72  Satellite identification
+      0   7  24  Satellite zenith angle
+      0  10   2  Height
+      3   3  41  Wind sequence
+      1   1   3  Replicate next descriptor 3 times
+      3   4  32  Cloud fraction
+      0   2 152  Satellite instrument used in data processing
+      0   2  24  Integrated mean humidity computational method
+      0   7   4  Pressure
+      0   7   4  Pressure
+      0  13   3  Relative humidity
+      1   1   3  Replicate next descriptor 3 times
+      3   4  33  Clear sky radiance
+     -1
+#  (Meteosat Second Generation (MSG) radiance data)
+  3  10  16
+      3   1  72  Satellite identification
+      0   7  24  Satellite zenith angle
+      0  10   2  Height
+      3   3  41  Wind sequence
+      1   1  12  Replicate next descriptor 12 times
+      3   4  32  Cloud fraction
+      0   2 152  Satellite instrument used in data processing
+      0   2  24  Integrated mean humidity computational method
+      0   7   4  Pressure
+      0   7   4  Pressure
+      0  13   3  Relative humidity
+      1   1  12  Replicate next descriptor 12 times
+      3   4  33  Clear sky radiance
+     -1
+#  Category 11 - Single level report sequences (conventional data)
+#  (Aircraft reports)
+  3  11   1
+      3   1  51  "ASDAR aircraft identifier, navigational system, date/time, position, phase of aircraft flight"
+      0   7   2  Altitude
+      0  12   1  Temperature
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+      0  11  31  Degree of turbulence
+      0  11  32  Height of base of turbulence
+      0  11  33  Height of top of turbulence
+      0  20  41  Airframe icing
+     -1
+#  (ACARS reports)
+  3  11   2
+      3   1  65  ACARS identification
+      3   1  66  ACARS location
+      3  11   3  ACARS standard reported variables
+      3  11   4  ACARS supplementary reported variables
+     -1
+#  (ACARS standard reported variables)
+  3  11   3
+      0  10  70  Indicated aircraft altitude
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+      0  12   1  Temperature/dry-bulb temperature
+      0  13   2  Mixing ratio
+     -1
+#  (ACARS supplementary reported variables)
+  3  11   4
+      1   1   0  Delayed replication of one descriptor
+      0  31   0  Short delayed descriptor replication factor
+      0  11  34  Vertical gust velocity
+      1   1   0  Delayed replication of one descriptor
+      0  31   0  Short delayed descriptor replication factor
+      0  11  35  Vertical gust acceleration
+      1   1   0  Delayed replication of one descriptor
+      0  31   0  Short delayed descriptor replication factor
+      0  11  75  Mean turbulence intensity (eddy dissipation rate)
+      1   1   0  Delayed replication of one descriptor
+      0  31   0  Short delayed descriptor replication factor
+      0  11  76  Peak turbulence intensity (eddy dissipation rate)
+      1   1   0  Delayed replication of one descriptor
+      0  31   0  Short delayed descriptor replication factor
+      0  33  25  ACARS interpolated values
+      1   1   0  Delayed replication of one descriptor
+      0  31   0  Short delayed descriptor replication factor
+      0  33  26  Mixing ratio quality
+     -1
+#  Category 12 - Single level report sequences (satellite data)
+  3  12   1
+      3   1  43  "Satellite identifier, instrumentation, location, date/time"
+      3   4   1  "Cloud top pressure, temperature, wind"
+     -1
+  3  12   2
+      3   1  43  "Satellite identifier, instrumentation, location, date/time"
+      3   4   2  "Cloud top pressure, wind"
+     -1
+  3  12   3
+      3   1  42  "Satellite identifier, instrumentation, location, date/time"
+      3   4   3  Surface temperature
+     -1
+  3  12   4
+      3   1  42  "Satellite identifier, instrumentation, location, date/time"
+      3   4   4  Cloud cover
+     -1
+  3  12   5
+      3   1  42  "Satellite identifier, instrumentation, location, date/time"
+      0  20  14  Height of top of cloud
+     -1
+  3  12   6
+      3   1  44  "Satellite identifier, instrumentation, location, date/time"
+      3   4   5  Layer mean relative humidity
+     -1
+  3  12   7
+      3   1  42  "Satellite identifier, instrumentation, location, date/time"
+      3   4   6  Radiation
+     -1
+#  "(Orbital information, Part I)"
+  3  12  10
+      0   1   7  Satellite identifier
+      0   5  40  Orbit number
+      0   2  21  Satellite instrumentation
+      0   5  41  Scan line number
+      0   4   1  Year
+      0   4  43  Day of year
+     -1
+#  "(Orbital information, Part II)"
+  3  12  11
+      2   2 131  Change scale
+      2   1 149  Change width
+      0   4   6  Second
+      2   1   0  Change width
+      2   2 126  Change scale
+      0  10   2  Height
+      2   2   0  Change scale
+      0   5  43  Field of view number
+      0   5  53  Field of view number increment
+     -1
+#  (HIRS brightness temperatures � channels 1�19)
+  3  12  12
+      2   2 129  Change scale
+      2   1 132  Change width
+      1   1  19  Replicate 1 descriptor 19 times
+      0  12  63  Brightness temperature
+      2   1   0  Change width
+      2   2   0  Change scale
+     -1
+#  (HIRS brightness temperatures � channel 20)
+  3  12  13
+      0   5  42  Channel number
+      2   2 129  Change scale
+      2   1 135  Change width
+      0  12  63  Brightness temperature
+      2   1   0  Change width
+      2   2   0  Change scale
+     -1
+#  (HIRS satellite data)
+  3  12  14
+      3  12  10  "Orbital information, Part I"
+      3  12  11  "Orbital information, Part II"
+      1   5  56  Replicate 5 descriptors 56 times
+      3   1  23  Latitude and longitude (coarse accuracy)
+      0   5  42  Channel number
+      0   5  52  Channel number increment
+      3  12  12  HIRS brightness temperatures � channels 1�19
+      3  12  13  HIRS brightness temperature � channel 20
+     -1
+#  (MSU brightness temperatures � channels 1�4)
+  3  12  15
+      1   9  11  Replicate 9 descriptors 11 times
+      3   1  23  Latitude and longitude (coarse accuracy)
+      0   5  42  Channel number
+      0   5  52  Channel number increment
+      2   2 129  Change scale
+      2   1 132  Change width
+      1   1   4  Replicate 1 descriptor 4 times
+      0  12  63  Brightness temperature
+      2   2   0  Change scale
+      2   1   0  Change width
+     -1
+#  (MSU satellite data)
+  3  12  16
+      3  12  10  "Orbital information, Part I"
+      3  12  11  "Orbital information, Part II"
+      3  12  15  MSU brightness temperatures � channels 1�4
+     -1
+#  (SSU brightness temperatures � channels 1�3)
+  3  12  17
+      1   9   8  Replicate 9 descriptors 8 times
+      3   1  23  Latitude and longitude (coarse accuracy)
+      0   5  42  Channel number
+      0   5  52  Channel number increment
+      2   2 129  Change scale
+      2   1 132  Change width
+      1   1   3  Replicate 1 descriptor 3 times
+      0  12  63  Brightness temperature
+      2   2   0  Change scale
+      2   1   0  Change width
+     -1
+#  (SSU satellite data)
+  3  12  18
+      3  12  10  "Orbital information, Part I"
+      3  12  11  "Orbital information, Part II"
+      3  12  17  SSU brightness temperatures � channels 1�3
+     -1
+#  (Wave scatterometer product with width change for wave number (spectral))
+  3  12  19
+      3   1  47  Product header
+      3   1  48  Radar parameters
+      0  15  15  Maximum spectrum composition before normalisation
+      0  29   2  Coordinate grid type
+      0  21  76  Representation of intensities
+      1   6  12  Repeat next 6 descriptors 12 times
+      2   1 129  Change width to 14 bits
+      0   6  30  Wave number (spectral)
+      2   1   0  Change width to Table B
+      1   2  12  Repeat next 2 descriptors 12 times
+      0   5  30  Direction (spectral)
+      0  21  75  Image spectrum intensity
+      0  21  66  Wave scatterometer product confidence data
+     -1
+#  (Wave scatterometer product)
+  3  12  20
+      3   1  47  Product header
+      3   1  48  Radar parameters
+      0  15  15  Maximum spectrum composition before normalization
+      0  29   2  Coordinate grid type
+      0  21  76  Representation of intensities
+      1   4  12  Repeat next 4 descriptors 12 times
+      0   6  30  Wave number (spectral)
+      1   2  12  Repeat next 2 descriptors 12 times
+      0   5  30  Direction (spectral)
+      0  21  75  Spectral intensity
+      0  21  66  Wave scatterometer product confidence data
+     -1
+#  (Wind scatterometer product)
+  3  12  21
+      3   1  47  Product header
+      1   1   3  Repeat 1 descriptor 3 times
+      3   1  49  Radar beam data
+      0  11  12  Wind speed at 10 m
+      0  11  11  Wind direction at 10 m
+      0  21  67  Wind product confidence data
+     -1
+#  (Radar altimeter product)
+  3  12  22
+      3   1  47  Product header
+      0   8  22  Number in average
+      0  11  12  Wind speed
+      0  11  50  Standard deviation of horizontal wind speed
+      0  22  70  Significant wave height
+      0  22  26  Standard deviation of significant wave height
+      3  12  41  Altitude
+      0  10  50  Standard deviation of altitude
+      0  21  68  Radar altimeter product confidence data
+      0  21  71  Peakiness
+      0  21  72  Altimeter calibration status
+      0  21  73  Altimeter instrument mode
+      3  12  42  Altitude corrections
+      0  21  62  Backscatter
+      0  15  11  Log 10 of integrated electron density
+     -1
+#  (ATSR sea surface temperature product)
+  3  12  23
+      3   1  47  Product header
+      1   3   3  Repeat 3 descriptors 3 times
+      0   8  22  Number in average
+      0  12  61  Skin temperature
+      0  22  50  Standard deviation of sea surface temperature
+      0  21  69  SST product confidence data
+      0  21  85  ATSR sea surface temperature across-track band number
+     -1
+#  (Wave scatterometer product enhanced)
+  3  12  24
+      3  12  20  (Wave scatterometer product)
+      0   8  60  Sample scanning mode significance � range
+      0   8  22  Number in sample
+      0   8  60  Sample scanning mode signification � horizontal
+      0   8  22  Number in sample
+      0  25  14  Azimuth clutter cut-off
+      0  22 101  Total energy (wavelength > 731 m)
+      0  22  97  Mean wavelength of image spectrum
+      0  22  98  Wavelength spread (wavelength > 731 m)
+      0  22  99  Mean direction (wavelength > 731 m)
+      0  22 100  Direction spread (wavelength > 731 m)
+     -1
+#  (Wave scatterometer enhanced product (with change of width for wave number (spectral))
+  3  12  25
+      3  12  19  Wave scatterometer product with width change for wave number (spectral)
+      0   8  60  Sample scanning mode significance � range
+      0   8  22  Number in sample
+      0   8  60  Sample scanning mode significance � horizontal
+      0   8  22  Number in sample
+      0  25  14  Azimuth clutter cut-off
+      0  22 101  Total energy (wavelength > 731 m)
+      0  22  97  Mean wavelength of image spectrum
+      0  22  98  Wavelength spread (wavelength > 731 m)
+      0  22  99  Mean direction (wavelength > 731 m)
+      0  22 100  Direction spread (wavelength > 731 m)
+     -1
+#  (Quikscat data)
+  3  12  26
+      3   1  46
+      3   1  11  Data
+      3   1  13  Time
+      3   1  23  Location
+      3  12  31
+      1   1   4  Replicate 1 descriptor 4 times
+      3  12  30
+      0  21 110  Number of inner-beam sigma-0 (forward of satellite)
+      3   1  23  Location
+      3  21  27
+      0  21 111  Number of outer-beam sigma-0 (forward of satellite)
+      3   1  23  Location
+      3  21  27
+      0  21 112  Number of inner-beam sigma-0 (aft of satellite)
+      3   1  23  Location
+      3  21  27
+      0  21 113  Number of outer-beam sigma-0 (aft of satellite)
+      3   1  23  Location
+      3  21  27
+     -1
+  3  12  30
+      2   1 130  Change data width
+      2   2 129  Change scale
+      0  11  12  Wind speed at 10 m
+      2   2   0  Change scale back to Table B
+      2   1   0  Change data width to Table B
+      0  11  52  Formal uncertainty in wind speed
+      2   1 135  Change data width
+      2   2 130  Change scale
+      0  11  11  Wind direction at 10 m
+      2   2   0  Change scale back to Table B
+      2   1   0  Change data width to Table B
+      0  11  53  Formal uncertainty in wind speed
+      0  21 104  Likelihood computed for solution
+     -1
+  3  12  31
+      0   5  34  Along-track row number
+      0   6  34  Cross-track cell number
+      0  21 109  SEAWINDS wind vector cell quality
+      0  11  81  Model wind direction at 10 m
+      0  11  82  Model wind speed at 10 m
+      0  21 101  Number of vector ambiguities
+      0  21 102  Index of selected wind vector
+      0  21 103  Total number of sigma-0 measurements
+     -1
+#  (Altitude)
+  3  12  41
+      2   1 141  Change width to 28 bits
+      2   2 130  Change scale to 2
+      0   7   1  Altitude
+      2   1   0  Change width back to Table B
+      2   2   0  Change scale back to Table B
+     -1
+#  (Altitude corrections)
+  3  12  42
+      0  21  77  "Altitude correction, ionosphere"
+      0  21  78  "Altitude correction, dry troposphere"
+      0  21  79  "Altitude correction, wet troposphere"
+      0  21  80  "Altitude correction, calibration constant"
+      0  21  81  Open loop height-time loop calibration correction
+      0  21  82  Open loop automatic gain control calibration correction
+     -1
+#  Category 13 - Sequences common to image data
+#  (Radar reflectivity values)
+  3  13   9
+      0  21   1  Horizontal reflectivity
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      0  21   1  Horizontal reflectivity
+     -1
+#  (Radar rainfall intensities)
+  3  13  10
+      0  21  36  Radar rainfall intensity
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      0  21  36  Radar rainfall intensity
+     -1
+#  (Non run-length encoded row for Pixel value (4 bits))
+  3  13  31
+      0   6   2  First longitude location minus one increment
+      0   6  12  Longitude increment
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   2  Extended replication factor
+      0  30   1  Pixel value (4 bits)
+     -1
+#  (Non run-length encoded picture data for Pixel value (4 bits))
+  3  13  32
+      0   5   2  First latitude location minus one increment
+      0   5  12  Latitude increment (signed value so cannot cross pole)
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   2  Extended replication factor
+      3  13  31  Non run-length encoded row
+     -1
+#  (Run-length encoded row for Pixel value (4 bits))
+  3  13  41
+      0   6   2  First longitude location minus one increment
+      1  10   0  Delayed replication of 10 descriptors
+      0  31   1  Replication factor
+      1   4   0  Delayed replication of 4 descriptors
+      0  31   1  Replication factor
+      0   6  12  Longitude increment
+      1   1   0  Delayed replication of 1 descriptor
+      0  31  12  Repetition factor
+      0  30   1  Pixel value (4 bits)
+      0   6  12  Longitude increment
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      0  30   1  Pixel value (4 bits)
+     -1
+#  (Run-length encoded picture data for Pixel value (4 bits))
+  3  13  42
+      0   5   2  First latitude location minus one increment
+      0   5  12  Latitude increment (signed value so cannot cross pole)
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   2  Extended replication factor
+      3  13  41  Run-length encoded row
+     -1
+#  "(Run-length encoded picture data for Pixel value (4 bits), regular grid)"
+  3  13  43
+      0   6   2  First longitude location minus one increment
+      0   5   2  First latitude location minus one increment
+      0   5  12  Latitude increment
+      1  12   0  Delayed replication of 12 descriptors
+      0  31   1  Replication factor
+      1  10   0  Delayed replication of 10 descriptors
+      0  31   1  Replication factor
+      1   4   0  Delayed replication of 4 descriptors
+      0  31   1  Replication factor
+      0   6  12  Longitude increment
+      1   1   0  Delayed replication of 1 descriptor
+      0  31  11  Repetition factor
+      0  30   1  Pixel value (4 bits)
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      0  30   1  Pixel value (4 bits)
+     -1
+#  Category 15 - Oceanographic report sequences
+#  (Typically reported underwater sounding without optional fields)
+  3  15   1
+      0   1  11  Ship's call sign
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+      3   6   1  "Depth, temperature"
+     -1
+#  (Typically reported underwater sounding without optional fields)
+  3  15   2
+      0   1  11  Ship's call sign
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+      3   6   4  "Depth, temperature, salinity"
+     -1
+#  Category 16 - Synoptic feature sequences
+  3  16   1
+      3   1  11  "Year, month, day"
+      0   4   4  Hour
+      3   1  23  Latitude and longitude (coarse accuracy)
+      0   1  21  Synoptic feature identifier
+      0   2  41  Method for estimating reports related to synoptic features
+      0  19   1  Type of synoptic feature
+      0  10  51  Pressure reduced to mean sea level
+      0  19   2  Effective radius of feature
+      0  19   3  Wind speed threshold (15 m s�1 typically)
+      0  19   4  Effective radius with respect to wind speeds above threshold
+     -1
+#  (Header)
+  3  16   2
+      0   8  21  Data time (analysis)
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+      0   4   4  Hour
+      0   4   5  Minute
+      0   1  33  Originating/generating centre
+      0   8  21  Validity time (fcst)
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+      0   4   4  Hour
+      0   4   5  Minute
+      0   7   2  Flight level (altitude) (base of chart layer)
+      0   7   2  Flight level (altitude) (top of chart layer)
+     -1
+#  (Jet stream)
+  3  16   3
+      1  10   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature (jet stream value)
+      0   8   7  Dimensional significance (value for line)
+      1   4   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0  10   2  Flight level (altitude)
+      0  11   2  Wind speed
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  (Turbulence)
+  3  16   4
+      1  11   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature (value for turbulence)
+      0   8   7  Dimensional significance (value for area)
+      0   7   2  Flight level (altitude) (base of layer)
+      0   7   2  Flight level (altitude) (top of layer)
+      1   2   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0  11  31  Degree of turbulence
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  (Storm)
+  3  16   5
+      1   8   0  Delayed replication
+      0  31   1  Replication
+      0   8   5  Meteorological attribute significance (storm centre)
+      0   8   7  Dimensional significance (value for point)
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0   1  26  WMO storm name (use �unknown� for a sandstorm)
+      0  19   1  Synoptic features (value for type of storm)
+      0   8   7  Dimensional significance (cancel)
+      0   8   5  Meteorological attribute significance (cancel/end of object)
+     -1
+#  (Cloud)
+  3  16   6
+      1  12   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature (value for cloud)
+      0   8   7  Dimensional significance (value for area)
+      0   7   2  Flight level (altitude) (base of layer)
+      0   7   2  Flight level (altitude) (top of layer)
+      1   2   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0  20  11  Cloud amount
+      0  20  12  Cloud type
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  (Front)
+  3  16   7
+      1  10   0  Delayed replication
+      0  31   1  Replication
+      0   8011+F1456  Meteorological feature (value for type of front)
+      0   8   7  Dimensional significance (value for line)
+      1   4   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0  19   5  Direction of feature
+      0  19   6  Speed of feature
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  (Tropopause)
+  3  16   8
+      1  11   0  Delayed replication
+      0  31   1  Replication
+      0   8   1  Vertical significance (bit 3 set for tropopause)
+      0   8   7  Dimensional significance (value for point)
+      0   8  23  Statistic (type of tropopause value)
+      1   3   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0  10   2  Height/altitude
+      0   8  23  Statistic (cancel)
+      0   8   7  Dimensional significance (cancel)
+      0   8   1  Vertical significance (cancel/end of object)
+     -1
+#  (Airframe icing area)
+  3  16   9
+      1  11   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature (value for airframe icing)
+      0   8   7  Dimensional significance (value for area)
+      0   7   2  Flight level (altitude) (base of layer)
+      0   7   2  Flight level (altitude) (top of layer)
+      1   2   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0  20  41  Airframe icing (type of airframe icing)
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  (Name of feature)
+  3  16  10
+      1   7   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature
+      0   8   7  Dimensional significance (value for point)
+      0   1  22  Name of feature
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  (Volcano erupting)
+  3  16  11
+      1  16   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature (value for special clouds)
+      0   1  22  Name of feature (volcano name)
+      0   8   7  Dimensional significance (value for point)
+      1   2   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0   8  21  Time significance (eruption starting time)
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+      0   4   4  Hour
+      0   4   5  Minute
+      0  20  90  Special clouds (clouds from volcanic eruptions)
+      0   8  21  Time significance (cancel)
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  Category 18 - Radiological report sequences
+  3  18   1
+      3   1  25  "Latitude and longitude (coarse accuracy), day and time"
+      0  24  11  Dose
+     -1
+  3  18   3
+      3   1  26  "Latitude and longitude (high accuracy), time periods in days,"
+     -1
+#  hours and minutes
+      0  24   5  Isotope mass
+      0  24   4  Element name
+      0  24  21  Air concentration
+     -1
+  3  18   4
+      3   1  25  "Latitude and longitude (coarse accuracy), day and time"
+      0   4  23  Time period or displacement
+      0  13  11  Total precipitation/total water equivalent
+      0  24   5  Isotope mass
+      0  24   4  Element name
+      0  24  22  Concentration in precipitation
+     -1
+#  Category 21 - Radar report sequences
+#  (Wind profiler � antenna characteristics)
+  3  21   1
+      0   2 101  Type of antenna
+      0   2 114  Antenna effective surface area
+      0   2 105  Maximum antenna gain
+      0   2 106  3-dB beamwidth
+      0   2 107  Sidelobe suppression
+      0   2 121  Mean frequency
+     -1
+#  (Wind profiler � moment data)
+  3  21   3
+      0  21  51  Signal power above 1 mW
+      0  21  14  Doppler mean velocity (radial)
+      0  21  17  Doppler velocity spectral width
+      0  21  30  Signal to noise ratio
+     -1
+#  (Wind profiler � moment data sounding)
+  3  21   4
+      3   1  31  "Identification, type, date/time, position (high accuracy), height"
+      0   2   3  Type of measuring equipment used
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3  21   3  Wind profiler � moment data
+     -1
+#  (Transmitter-receiver characteristics)
+  3  21   5
+      0  25   4  Echo processing
+      0   2 121  Mean frequency
+      0   2 122  Frequency agility range
+      0   2 123  Peak power
+      0   2 124  Average power
+      0   2 125  Pulse repetition frequency
+      0   2 126  Pulse width
+      0   2 127  Receiver intermediate frequency
+      0   2 128  Intermediate frequency bandwidth
+      0   2 129  Minimum detectable signal
+      0   2 130  Dynamic range
+      0   2 131  Sensitivity time control
+     -1
+#  (Integration characteristics)
+  3  21   6
+      0  25   1  Range-gate length
+      0  25   2  Number of gates averaged
+      0  25   3  Number of integrated pulses
+      0  25   5  Echo integration
+     -1
+#  (Corrections)
+  3  21   7
+      0  25   9  Calibration method
+      0  25  10  Clutter treatment
+      0  25  11  Ground occultation correction
+      0  25  12  Range attenuation correction
+      0  25  13  Bright-band correction
+      0  25  15  Radome attenuation correction
+      0  25  16  Clear-air attenuation correction
+      0  25  17  Precipitation attenuation correction
+     -1
+#  (Z to R conversion)
+  3  21   8
+      0  25   6  Z to R conversion
+      0  25   7  Z to R conversion factor
+      0  25   8  Z to R conversion exponent
+     -1
+#  (A to Z law)
+  3  21   9
+      0  25  18  A to Z law for attenuation factor
+      0  25  19  A to Z law for attenuation exponent
+     -1
+#  (Antenna characteristics)
+  3  21  10
+      0   2 101  Type of antenna
+      0   7   2  Altitude of the tower base
+      0   2 102  Antenna height above tower base
+      0   2 103  Radome
+      0   2 104  Antenna polarisation
+      0   2 105  Maximum antenna gain
+      0   2 106  3-dB beamwidth
+      0   2 107  Sidelobe suppression
+      0   2 108  Crosspol discrimination (on axis)
+      0   2 109  Antenna speed (azimuth)
+      0   2 110  Antenna speed (elevation)
+      0   2 132  Azimuth pointing accuracy
+      0   2 133  Elevation pointing accuracy
+     -1
+#  (General characteristics)
+  3  21  11
+      0  30  31  Picture type
+      0  30  32  Combination with other data
+      0  29   2  Coordinate grid type
+     -1
+#  (Antenna elevations)
+  3  21  12
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      0   2 135  Antenna elevation
+     -1
+  3  21  27
+      0  21 118  Attenuation correction on sigma-0
+      2   2 129  Change scale
+      2   1 132  Change data width
+      0   2 112  Radar look angle
+      2   1   0  Change data width to Table B
+      2   1 131  Change data width
+      0   2 111  Radar incidence angle
+      2   1   0  Change data width to Table B
+      2   2   0  Change scale back to Table B
+      0   2 104  Antenna polarization
+      0  21 105  Normalized radar cross-section
+      0  21 106  Kp variance coefficient (alpha)
+      0  21 107  Kp variance coefficient (beta)
+      0  21 114  Kp variance coefficient (gamma)
+      0  21 115  SEAWINDS sigma-0 quality
+      0  21 116  SEAWINDS sigma-0 mode
+      0   8  18  SEAWINDS land/ice surface type
+      0  21 117  Sigma-0 variance quality control
+     -1
diff --git a/data/tables/B3M-000-009-0 b/data/tables/B3M-000-009-0
new file mode 100644
index 0000000..51af964
--- /dev/null
+++ b/data/tables/B3M-000-009-0
@@ -0,0 +1,115 @@
+##############################################################################
+# BUFR Table 0
+#
+#
+# Notes
+# -----
+#
+# * This table comes from GRIB Code Table 0 (Identification of center)
+#
+# * A value of 1 in the first column indicates a center that uses minor
+#   version numbers with local tables.  Since minor local table version
+#   numbers are stored in Section 1, Octet 18, the value in the first
+#   column must not be set if a center uses Section 1, Octet 18 for other
+#   purposes (i.e., ECMWF).
+#
+#
+##############################################################################		
+		
+#01-09: WMCs		
+0	1	Melbourne
+0	2	Melbourne
+0	3	Melbourne
+0	4	Moscow
+0	5	Moscow
+0	6	Moscow
+0	7	"US National Weather Service, National Centres for Environmental Prediction(NCEP)"
+0	8	US National Weather Service TelecommunicationsGateway (NWSTG)
+0	9	US National Weather Service - Other
+#10-25: Centres in Region I		
+0	10	Cairo (RSMC/RAFC)
+0	11	Cairo (RSMC/RAFC)
+0	12	Dakar (RSMC/RAFC)
+0	13	Dakar (RSMC/RAFC)
+0	14	Nairobi (RSMC/RAFC)
+0	15	Nairobi (RSMC/RAFC)
+0	18	Tunis Casablanca (RSMC)
+0	19	Tunis Casablanca (RSMC)
+0	20	Las Palmas (RAFC)
+0	21	Algiers (RSMC)
+0	24	Pretoria (RSMC)
+0	25	La R�union (RSMC)
+#26-40: Centres in Region II		
+0	26	Khabarovsk (RSMC)
+0	27	Khabarovsk (RSMC)
+0	28	New Delhi (RSMC/RAFC)
+0	29	New Delhi (RSMC/RAFC)
+0	30	Novosibirsk (RSMC)
+0	31	Novosibirsk (RSMC)
+0	32	Tashkent (RSMC)
+0	33	Jeddah (RSMC)
+0	34	"Tokyo (RSMC), Japan Meteorological Agency"
+0	35	"Tokyo (RSMC), Japan Meteorological Agency"
+0	36	Bangkok
+0	37	Ulan Bator
+0	38	Beijing (RSMC)
+0	39	Beijing (RSMC)
+0	40	Seoul
+#41-50: Centres in Region III		
+0	41	Buenos Aires (RSMC/RAFC)
+0	42	Buenos Aires (RSMC/RAFC)
+0	43	Brasilia (RSMC/RAFC)
+0	44	Brasilia (RSMC/RAFC)
+0	45	Santiago
+0	46	Brazilian Space Agency � INPE
+#51-63: Centres in Region IV		
+0	51	Miami (RSMC/RAFC)
+0	52	"Miami RSMC, National Hurricane Center"
+0	53	Montreal (RSMC)
+0	54	Montreal (RSMC)
+0	55	San Francisco
+0	57	U.S. Air Force Air Force Global Weather Central 
+0	58	"Fleet Numerical Meteorology and Oceanography Center, Monterey, CA"
+0	59	"The NOAA Forecast Systems Laboratory, Boulder, CO, USA"
+0	60	United States National Centre for Atmospheric Research (NCAR)
+#64-73: Centres in Region V		
+0	64	Honolulu
+0	65	Darwin (RSMC)
+0	66	Darwin (RSMC)
+0	67	Melbourne (RSMC)
+0	69	Wellington (RSMC/RAFC)
+0	70	Wellington (RSMC/RAFC)
+0	71	Nadi (RSMC)
+#74-99: Centres in Region VI		
+0	74	UK Meteorological Office � Bracknell (RSMC)
+0	75	UK Meteorological Office � Bracknell (RSMC)
+0	76	Moscow (RSMC/RAFC)
+0	78	Offenbach (RSMC)
+0	79	Offenbach (RSMC)
+0	80	Rome (RSMC)
+0	81	Rome (RSMC)
+0	82	Norrk�ping
+0	83	Norrk�ping
+0	85	Toulouse (RSMC)
+0	86	Helsinki
+0	87	Belgrade
+0	88	Oslo
+0	89	Prague
+0	90	Episkopi
+0	91	Ankara
+0	92	Frankfurt/Main (RAFC)
+0	93	London (WAFC)
+0	94	Copenhagen
+0	95	Rota
+0	96	Athens
+0	97	European Space Agency (ESA)
+0	98	"ECMWF, RSMC"
+0	99	De Bilt
+0	110	Hong-Kong
+0	160	US NOAA/NESDIS
+0	210	Frascati (ESA/ESRIN)
+0	211	Lanion
+0	212	Lisboa
+0	213	Reykjavik
+0	254	EUMETSAT Operation Centre
+0	255	Missing value
diff --git a/data/tables/B3M-000-009-A b/data/tables/B3M-000-009-A
new file mode 100644
index 0000000..5a7f993
--- /dev/null
+++ b/data/tables/B3M-000-009-A
@@ -0,0 +1,259 @@
+#
+# BUFR Table A - Data Category
+#
+  0	Surface data - land
+  1	Surface data - sea
+  2	Vertical soundings (other than satellite)
+  3	Vertical soundings (satellite)
+  4	Single level upper-air data (other than satellite)
+  5	Single level upper-air data (satellite)
+  6	Radar data
+  7	Synoptic features
+  8	Physical/chemical constituents
+  9	Dispersal and transport
+ 10	Radiological data
+ 11	BUFR tables, complete replacement or update
+ 12	Surface data (satellite)
+ 13	RESERVED
+ 14	RESERVED
+ 15	RESERVED
+ 16	RESERVED
+ 17	RESERVED
+ 18	RESERVED
+ 19	RESERVED
+ 20	Status information
+ 21	Radiances (satellite measured)
+ 22	RESERVED
+ 23	RESERVED
+ 24	RESERVED
+ 25	RESERVED
+ 26	RESERVED
+ 27	RESERVED
+ 28	RESERVED
+ 29	RESERVED
+ 30	RESERVED
+ 31	Oceanographic data
+ 32	RESERVED
+ 33	RESERVED
+ 34	RESERVED
+ 35	RESERVED
+ 36	RESERVED
+ 37	RESERVED
+ 38	RESERVED
+ 39	RESERVED
+ 40	RESERVED
+ 41	RESERVED
+ 42	RESERVED
+ 43	RESERVED
+ 44	RESERVED
+ 45	RESERVED
+ 46	RESERVED
+ 47	RESERVED
+ 48	RESERVED
+ 49	RESERVED
+ 50	RESERVED
+ 51	RESERVED
+ 52	RESERVED
+ 53	RESERVED
+ 54	RESERVED
+ 55	RESERVED
+ 56	RESERVED
+ 57	RESERVED
+ 58	RESERVED
+ 59	RESERVED
+ 60	RESERVED
+ 61	RESERVED
+ 62	RESERVED
+ 63	RESERVED
+ 64	RESERVED
+ 65	RESERVED
+ 66	RESERVED
+ 67	RESERVED
+ 68	RESERVED
+ 69	RESERVED
+ 70	RESERVED
+ 71	RESERVED
+ 72	RESERVED
+ 73	RESERVED
+ 74	RESERVED
+ 75	RESERVED
+ 76	RESERVED
+ 77	RESERVED
+ 78	RESERVED
+ 79	RESERVED
+ 80	RESERVED
+ 81	RESERVED
+ 82	RESERVED
+ 83	RESERVED
+ 84	RESERVED
+ 85	RESERVED
+ 86	RESERVED
+ 87	RESERVED
+ 88	RESERVED
+ 89	RESERVED
+ 90	RESERVED
+ 91	RESERVED
+ 92	RESERVED
+ 93	RESERVED
+ 94	RESERVED
+ 95	RESERVED
+ 96	RESERVED
+ 97	RESERVED
+ 98	RESERVED
+ 99	RESERVED
+100	RESERVED
+101	Image data
+102	RESERVED
+103	RESERVED
+104	RESERVED
+105	RESERVED
+106	RESERVED
+107	RESERVED
+108	RESERVED
+109	RESERVED
+110	RESERVED
+111	RESERVED
+112	RESERVED
+113	RESERVED
+114	RESERVED
+115	RESERVED
+116	RESERVED
+117	RESERVED
+118	RESERVED
+119	RESERVED
+120	RESERVED
+121	RESERVED
+122	RESERVED
+123	RESERVED
+124	RESERVED
+125	RESERVED
+126	RESERVED
+127	RESERVED
+128	RESERVED
+129	RESERVED
+130	RESERVED
+131	RESERVED
+132	RESERVED
+133	RESERVED
+134	RESERVED
+135	RESERVED
+136	RESERVED
+137	RESERVED
+138	RESERVED
+139	RESERVED
+140	RESERVED
+141	RESERVED
+142	RESERVED
+143	RESERVED
+144	RESERVED
+145	RESERVED
+146	RESERVED
+147	RESERVED
+148	RESERVED
+149	RESERVED
+150	RESERVED
+151	RESERVED
+152	RESERVED
+153	RESERVED
+154	RESERVED
+155	RESERVED
+156	RESERVED
+157	RESERVED
+158	RESERVED
+159	RESERVED
+160	RESERVED
+161	RESERVED
+162	RESERVED
+163	RESERVED
+164	RESERVED
+165	RESERVED
+166	RESERVED
+167	RESERVED
+168	RESERVED
+169	RESERVED
+170	RESERVED
+171	RESERVED
+172	RESERVED
+173	RESERVED
+174	RESERVED
+175	RESERVED
+176	RESERVED
+177	RESERVED
+178	RESERVED
+179	RESERVED
+180	RESERVED
+181	RESERVED
+182	RESERVED
+183	RESERVED
+184	RESERVED
+185	RESERVED
+186	RESERVED
+187	RESERVED
+188	RESERVED
+189	RESERVED
+190	RESERVED
+191	RESERVED
+192	RESERVED
+193	RESERVED
+194	RESERVED
+195	RESERVED
+196	RESERVED
+197	RESERVED
+198	RESERVED
+199	RESERVED
+200	RESERVED
+201	RESERVED
+202	RESERVED
+203	RESERVED
+204	RESERVED
+205	RESERVED
+206	RESERVED
+207	RESERVED
+208	RESERVED
+209	RESERVED
+210	RESERVED
+211	RESERVED
+212	RESERVED
+213	RESERVED
+214	RESERVED
+215	RESERVED
+216	RESERVED
+217	RESERVED
+218	RESERVED
+219	RESERVED
+220	RESERVED
+221	RESERVED
+222	RESERVED
+223	RESERVED
+224	RESERVED
+225	RESERVED
+226	RESERVED
+227	RESERVED
+228	RESERVED
+229	RESERVED
+230	RESERVED
+231	RESERVED
+232	RESERVED
+233	RESERVED
+234	RESERVED
+235	RESERVED
+236	RESERVED
+237	RESERVED
+238	RESERVED
+239	RESERVED
+240	FOR EXPERIMENTAL USE
+241	FOR EXPERIMENTAL USE
+242	FOR EXPERIMENTAL USE
+243	FOR EXPERIMENTAL USE
+244	FOR EXPERIMENTAL USE
+245	FOR EXPERIMENTAL USE
+246	FOR EXPERIMENTAL USE
+247	FOR EXPERIMENTAL USE
+248	FOR EXPERIMENTAL USE
+249	FOR EXPERIMENTAL USE
+250	FOR EXPERIMENTAL USE
+251	FOR EXPERIMENTAL USE
+252	FOR EXPERIMENTAL USE
+253	FOR EXPERIMENTAL USE
+254	FOR EXPERIMENTAL USE
+255	Indicator for local use, with sub-category
diff --git a/data/tables/B3M-000-009-B b/data/tables/B3M-000-009-B
new file mode 100644
index 0000000..71c94e3
--- /dev/null
+++ b/data/tables/B3M-000-009-B
@@ -0,0 +1,819 @@
+#
+# WMO source file name = BufrTabB-11-2000.txt 
+# Master Table B Version 9 
+# 
+#                   Reference    Bit 
+# F   X    Y Scale    Value     Width     Units     Comments 
+#-------------------------------------------------------------- 
+# Class 00 - BUFR table entries 
+  0;  0;   1;    0;           0;   24;   CCITT_IA5; Table A:  entry 
+  0;  0;   2;    0;           0;  256;   CCITT_IA5; "Table A:  data category description, line 1" 
+  0;  0;   3;    0;           0;  256;   CCITT_IA5; "Table A:  data category description, line 2" 
+  0;  0;   5;    0;           0;   24;   CCITT_IA5; BUFR edition number 
+  0;  0;  10;    0;           0;    8;   CCITT_IA5; F descriptor to be added or defined 
+  0;  0;  11;    0;           0;   16;   CCITT_IA5; X descriptor to be added or defined 
+  0;  0;  12;    0;           0;   24;   CCITT_IA5; Y descriptor to be added or defined 
+  0;  0;  13;    0;           0;  256;   CCITT_IA5; "Element name, line 1" 
+  0;  0;  14;    0;           0;  256;   CCITT_IA5; "Element name, line 2" 
+  0;  0;  15;    0;           0;  192;   CCITT_IA5; Units name 
+  0;  0;  16;    0;           0;    8;   CCITT_IA5; Units scale sign 
+  0;  0;  17;    0;           0;   24;   CCITT_IA5; Units scale 
+  0;  0;  18;    0;           0;    8;   CCITT_IA5; Units reference sign 
+  0;  0;  19;    0;           0;   80;   CCITT_IA5; Units reference value 
+  0;  0;  20;    0;           0;   24;   CCITT_IA5; Element data width 
+  0;  0;  30;    0;           0;   48;   CCITT_IA5; Descriptor defining sequence 
+# Class 01 - Identification 
+  0;  1;   1;    0;           0;    7;     Numeric; WMO block number 
+  0;  1;   2;    0;           0;   10;     Numeric; WMO station number 
+  0;  1;   3;    0;           0;    3;  Code_Table; WMO Region number/geographical area 
+  0;  1;   4;    0;           0;    3;     Numeric; WMO Region sub-area (see Note 9) 
+  0;  1;   5;    0;           0;   17;     Numeric; Buoy/platform identifier 
+  0;  1;   6;    0;           0;   64;   CCITT_IA5; Aircraft flight number 
+  0;  1;   7;    0;           0;   10;  Code_Table; Satellite identifier 
+  0;  1;   8;    0;           0;   64;   CCITT_IA5; Aircraft registration number 
+  0;  1;   9;    0;           0;   64;   CCITT_IA5; Type of commercial aircraft 
+  0;  1;  10;    0;           0;   64;   CCITT_IA5; Stationary buoy platform identifier; e.g. C-MAN buoys 
+  0;  1;  11;    0;           0;   72;   CCITT_IA5; Ship or mobile land station identifier 
+  0;  1;  12;    0;           0;    9; Degree_true; Direction of motion of moving observing platform 
+  0;  1;  13;    0;           0;   10;       m s�1; Speed of motion of moving observing platform 
+  0;  1;  14;    2;           0;   10;       m s�1; Platform drift speed (high precision) 
+  0;  1;  15;    0;           0;  160;   CCITT_IA5; Station or site name 
+  0;  1;  18;    0;           0;   40;   CCITT_IA5; Short station or site name 
+  0;  1;  20;    0;           0;    4;     Numeric; WMO Region sub-area 
+  0;  1;  21;    0;           0;   14;     Numeric; Synoptic feature identifier 
+  0;  1;  22;    0;           0;  224;   CCITT_IA5; Name of feature (see Note 11) 
+  0;  1;  25;    0;           0;   24;   CCITT_IA5; Storm identifier 
+  0;  1;  26;    0;           0;   64;   CCITT_IA5; WMO storm name* 
+  0;  1;  27;    0;           0;   80;   CCITT_IA5; WMO long storm name 
+  0;  1;  31;    0;           0;   16;  Code_Table; Identification of originating/generating centre (see Note 10) 
+  0;  1;  32;    0;           0;    8;from originating cen; Generating application 
+  0;  1;  33;    0;           0;    8;  Code_Table; Identification of originating/generating centre 
+  0;  1;  34;    0;           0;    8;  Code_Table; Identification of originating/generating sub-centre 
+  0;  1;  41;    5; -1073741824;   31;       m s-1; Absolute platform velocity - first component (see Note 6) 
+  0;  1;  42;    5; -1073741824;   31;       m s-1; Absolute platform velocity - second component (see Note 6) 
+  0;  1;  43;    5; -1073741824;   31;       m s-1; Absolute platform velocity - third component (see Note 6) 
+  0;  1;  50;    0;           0;   17;     Numeric; Platform transmitter ID number 
+  0;  1;  51;    0;           0;   96;   CCITT_IA5; Platform transmitter ID number 
+  0;  1;  60;    0;           0;   64;   CCITT_IA5; Aircraft reporting point (Beacon identifier) 
+  0;  1;  62;    0;           0;   32;   CCITT_IA5; Short ICAO location indicator 
+  0;  1;  63;    0;           0;   64;   CCITT_IA5; ICAO location indicator 
+  0;  1;  64;    0;           0;   32;   CCITT_IA5; Runway designator 
+  0;  1;  75;    0;           0;   40;   CCITT_IA5; Tide station identification 
+# Class 02 - Instrumentation 
+  0;  2;   1;    0;           0;    2;  Code_Table; Type of station 
+  0;  2;   2;    0;           0;    4;  Flag_Table; Type of instrumentation for wind measurement 
+  0;  2;   3;    0;           0;    4;  Code_Table; Type of measuring equipment used 
+  0;  2;   4;    0;           0;    4;  Code_Table; Type of instrumentation for evaporation measurement or type of crop for which evapotranspiration is reported 
+  0;  2;   5;    2;           0;    7;           K; Precision of temperature observation 
+  0;  2;  11;    0;           0;    8;  Code_Table; Radiosonde type 
+  0;  2;  12;    0;           0;    4;  Code_Table; Radiosonde computational method 
+  0;  2;  13;    0;           0;    4;  Code_Table; Solar and infrared radiation correction 
+  0;  2;  14;    0;           0;    7;  Code_Table; Tracking technique/status of system used 
+  0;  2;  15;    0;           0;    4;  Code_Table; Radiosonde completeness 
+  0;  2;  19;    0;           0;   11;  Code_Table; Satellite instruments 
+  0;  2;  20;    0;           0;    9;  Code_Table; Satellite classification 
+  0;  2;  21;    0;           0;    9;  Flag_Table; Satellite instrument data used in processing* 
+  0;  2;  22;    0;           0;    8;  Flag_Table; Satellite data-processing technique used 
+  0;  2;  23;    0;           0;    4;  Code_Table; Satellite derived wind computation method 
+  0;  2;  24;    0;           0;    4;  Code_Table; Integrated mean humidity computational method 
+  0;  2;  25;    0;           0;   25;  Flag_Table; Satellite channel(s) used in computation 
+  0;  2;  26;    2;           0;   12;           m; Cross track resolution 
+  0;  2;  27;    2;           0;   12;           m; Along track resolution 
+  0;  2;  28;    0;           0;   18;           m; Segment size at nadir in X direction 
+  0;  2;  29;    0;           0;   18;           m; Segment size at nadir in Y direction 
+  0;  2;  30;    0;           0;    3;  Code_Table; Method of current measurement 
+  0;  2;  31;    0;           0;    5;  Code_Table; Duration and time of current measurement 
+  0;  2;  32;    0;           0;    2;  Code_Table; Indicator for digitization 
+  0;  2;  33;    0;           0;    3;  Code_Table; Method of salinity/depth measurement 
+  0;  2;  34;    0;           0;    5;  Code_Table; Drogue type 
+  0;  2;  35;    0;           0;    9;           m; Cable length 
+  0;  2;  36;    0;           0;    2;  Code_Table; Buoy type 
+  0;  2;  37;    0;           0;    3;  Code_Table; Method of tidal observation 
+  0;  2;  38;    0;           0;    4;  Code_Table; Method of sea-surface temperature measurement 
+  0;  2;  39;    0;           0;    3;  Code_Table; Method of wet-bulb temperature measurement 
+  0;  2;  40;    0;           0;    4;  Code_Table; Method of removing velocity and motion of platform from current 
+  0;  2;  41;    0;           0;    6;  Code_Table; Method for estimating reports related to synoptic features 
+  0;  2;  44;    0;           0;    4;  Code_Table; Indicator for method of calculating spectral wave data 
+  0;  2;  45;    0;           0;    4;  Code_Table; Indicator for type of platform 
+  0;  2;  46;    0;           0;    4;  Code_Table; Wave measurement instrumentation 
+  0;  2;  48;    0;           0;    4;  Code_Table; Satellite sensor indicator 
+  0;  2;  49;    0;           0;    8;  Flag_Table; Geostationary satellite data-processing technique used 
+  0;  2;  50;    0;           0;   20;  Flag_Table; Geostationary sounder satellite channels used 
+  0;  2;  51;    0;           0;    4;  Code_Table; Indicator to specify observing method for extreme temperatures 
+  0;  2;  52;    0;           0;    6;  Flag_Table; Geostationary imager satellite channels used 
+  0;  2;  53;    0;           0;    4;  Code_Table; GOES-I/M brightness temperature characteristics 
+  0;  2;  54;    0;           0;    4;  Code_Table; GOES-I/M soundings parameter characteristics 
+  0;  2;  55;    0;           0;    4;  Code_Table; Geostationary soundings statistical parameters 
+  0;  2;  56;    0;           0;    4;  Code_Table; Geostationary soundings accuracy statistics 
+  0;  2;  57;    0;           0;    4;  Code_Table; Origin of first guess information for GOES-I/M soundings 
+  0;  2;  58;    0;           0;    4;  Valid times of first guess information for GOES-I/M soundings 
+  0;  2;  59;    0;           0;    4;  Code_Table; Origin of analysis information for GOES-I/M soundings 
+  0;  2;  60;    0;           0;    4;  Code_Table; Origin of surface information for GOES-I/M soundings 
+  0;  2;  61;    0;           0;    3;  Code_Table; Aircraft navigational system 
+  0;  2;  62;    0;           0;    4;  Code_Table; Type of aircraft data relay system 
+  0;  2;  63;    2;      -18000;   16;      Degree; Aircraft roll angle 
+  0;  2;  64;    0;           0;    2;  Code_Table; Aircraft roll angle quality 
+  0;  2;  65;    0;           0;   40;   CCITT_IA5; ACARS ground receiving station 
+  0;  2;  70;    0;           0;    4;  Code_Table; Original specification of latitude/longitude 
+  0;  2;  91;    0;           4;   10;           A; Entry sensor 4/20 mA 
+  0;  2; 100;    1;           0;   12;          dB; Radar constant* 
+  0;  2; 101;    0;           0;    4;  Code_Table; Type of antenna 
+  0;  2; 102;    0;           0;    8;           m; Antenna height above tower base 
+  0;  2; 103;    0;           0;    2;  Flag_Table; Radome 
+  0;  2; 104;    0;           0;    4;  Code_Table; Antenna polarisation 
+  0;  2; 105;    0;           0;    6;          dB; Maximum antenna gain 
+  0;  2; 106;    1;           0;    6;      Degree; 3-dB beamwidth 
+  0;  2; 107;    0;           0;    6;          dB; Sidelobe suppression 
+  0;  2; 108;    0;           0;    6;          dB; Crosspol discrimination (on axis) 
+  0;  2; 109;    2;           0;   12;  Degree s-1; Antenna speed (azimuth) 
+  0;  2; 110;    2;           0;   12;  Degree s-1; Antenna speed (elevation) 
+  0;  2; 111;    1;           0;   10;      Degree; Radar incidence angle 
+  0;  2; 112;    1;           0;   12;      Degree; Radar look angle 
+  0;  2; 113;    0;           0;    4;     Numeric; Number of azimuth looks 
+  0;  2; 114;    0;           0;   15;          m2; Antenna effective surface area 
+  0;  2; 121;   -8;           0;    7;          Hz; Mean frequency 
+  0;  2; 122;   -6;        -128;    8;          Hz; Frequency agility range 
+  0;  2; 123;   -4;           0;    7;           W; Peak power 
+  0;  2; 124;   -1;           0;    7;           W; Average power 
+  0;  2; 125;   -1;           0;    8;          Hz; Pulse repetition frequency 
+  0;  2; 126;    7;           0;    6;           s; Pulse width 
+  0;  2; 127;   -6;           0;    7;          Hz; Receiver intermediate frequency 
+  0;  2; 128;   -5;           0;    6;          Hz; Intermediate frequency bandwidth 
+  0;  2; 129;    0;        -150;    5;          dB; Minimum detectable signal 
+  0;  2; 130;    0;           0;    7;          dB; Dynamic range 
+  0;  2; 131;    0;           0;    2;  Flag_Table; Sensitivity time control (STC) 
+  0;  2; 132;    2;           0;    6;      Degree; Azimuth pointing accuracy 
+  0;  2; 133;    2;           0;    6;      Degree; Elevation pointing accuracy 
+  0;  2; 134;    2;           0;   16;      Degree; Antenna beam azimuth 
+  0;  2; 135;    2;       -9000;   15;      Degree; Antenna elevation 
+  0;  2; 136;   -3;           0;   16;           m; Range processed by range attenuation correction 
+  0;  2; 140;    0;           0;    9;      Degree; Satellite radar beam azimuth angle 
+  0;  2; 141;    0;           0;   24;   CCITT_IA5; Measurement type 
+  0;  2; 142;    0;           0;   32;   CCITT_IA5; Ozone instrument serial number/ identification 
+  0;  2; 143;    0;           0;    7;  Code_Table; Ozone instrument type 
+  0;  2; 144;    0;           0;    4;  Code_Table; Light source type for Brewer spectro photometer 
+  0;  2; 145;    0;           0;    4;  Code_Table; Wave length setting for Dobson instruments 
+  0;  2; 146;    0;           0;    4;  Code_Table; Source conditions for Dobson instruments 
+  0;  2; 148;    0;           0;    5;  Code_Table; Data collection and/or location system 
+  0;  2; 149;    0;           0;    6;  Code_Table; Type of data buoy 
+  0;  2; 150;    0;           0;    6;  Code_Table; TOVS/ATOVS/AVHRR instrumentation channel number 
+  0;  2; 151;    0;           0;    4;  Code_Table; Radiometer identifier 
+  0;  2; 152;    0;           0;   31;  Flag_Table; Satellite instrument used in data processing(6) 
+  0;  2; 153;   -8;           0;   26;          Hz; Satellite channel centre frequency 
+  0;  2; 154;   -8;           0;   26;          Hz; Satellite channel band width 
+  0;  2; 163;    0;           0;    4;  Code_Table; Height assignment method 
+  0;  2; 164;    0;           0;    3;  Code_Table; Tracer correlation method 
+  0;  2; 166;    0;           0;    4;  Code_Table; Radiance type 
+  0;  2; 167;    0;           0;    4;  Code_Table; Radiance computational method 
+  0;  2; 168;   -3;           0;   16;          Pa; Hydrostatic pressure of lower end of cable (thermistor string) 
+  0;  2; 169;    0;           0;    4;  Code_Table; Anemometer type 
+  0;  2; 172;    0;           0;    8;  Code_Table; Product type for retrieved atmospheric gases 
+# Class 04 - Location (time) 
+  0;  4;   1;    0;           0;   12;        Year; Year 
+  0;  4;   2;    0;           0;    4;       Month; Month 
+  0;  4;   3;    0;           0;    6;         Day; Day 
+  0;  4;   4;    0;           0;    5;        Hour; Hour 
+  0;  4;   5;    0;           0;    6;      Minute; Minute 
+  0;  4;   6;    0;           0;    6;      Second; Second 
+  0;  4;  11;    0;       -1024;   11;        Year; Time increment 
+  0;  4;  12;    0;       -1024;   11;       Month; Time increment 
+  0;  4;  13;    0;       -1024;   11;         Day; Time increment 
+  0;  4;  14;    0;       -1024;   11;        Hour; Time increment 
+  0;  4;  15;    0;       -2048;   12;      Minute; Time increment 
+  0;  4;  16;    0;       -4096;   13;      Second; Time increment 
+  0;  4;  17;    0;       -1440;   12;      Minute; Reference time period for accumulated or extreme data 
+  0;  4;  21;    0;       -1024;   11;        Year; Time period or displacement 
+  0;  4;  22;    0;       -1024;   11;       Month; Time period or displacement 
+  0;  4;  23;    0;       -1024;   11;         Day; Time period or displacement 
+  0;  4;  24;    0;       -2048;   12;        Hour; Time period or displacement 
+  0;  4;  25;    0;       -2048;   12;      Minute; Time period or displacement 
+  0;  4;  26;    0;       -4096;   13;      Second; Time period or displacement 
+  0;  4;  31;    0;           0;    8;        Hour; Duration of time relating to following value 
+  0;  4;  32;    0;           0;    6;      Minute; Duration of time relating to following value 
+  0;  4;  41;    0;       -1440;   12;      Minute; "Time difference, UTC -LMT (see Note 6)" 
+  0;  4;  43;    0;           0;    9;         Day; Day of the year 
+  0;  4;  53;    0;           0;    6;     Numeric; Number of days with precipitation equal to or more than 1 mm 
+  0;  4;  65;    0;        -128;    8;      Minute; Short time increment 
+  0;  4;  73;    0;        -128;    8;         Day; Short time period or displacement 
+  0;  4;  74;    0;        -128;    8;        Hour; Short time period or displacement 
+  0;  4;  75;    0;        -128;    8;      Minute; Short time period or displacement 
+# Class 05 - Location (horizontal -1) 
+  0;  5;   1;    5;    -9000000;   25;      Degree; Latitude (high accuracy) 
+  0;  5;   2;    2;       -9000;   15;      Degree; Latitude (coarse accuracy) 
+  0;  5;  11;    5;    -9000000;   25;      Degree; Latitude increment (high accuracy) 
+  0;  5;  12;    2;       -9000;   15;      Degree; Latitude increment (coarse accuracy) 
+  0;  5;  21;    2;           0;   16; Degree_true; Bearing or azimuth 
+  0;  5;  22;    2;           0;   16; Degree_true; Solar azimuth 
+  0;  5;  30;    0;           0;   12;      Degree; Direction (spectral) 
+  0;  5;  31;    0;           0;   12;     Numeric; Row number 
+  0;  5;  33;   -1;           0;   16;           m; Pixel size on horizontal - 1 
+  0;  5;  34;    0;           0;   11;     Numeric; Along track row number 
+  0;  5;  40;    0;           0;   24;     Numeric; Orbit number 
+  0;  5;  41;    0;           0;    8;     Numeric; Scan line number 
+  0;  5;  42;    0;           0;    6;     Numeric; Channel number 
+  0;  5;  43;    0;           0;    8;     Numeric; Field of view number 
+  0;  5;  52;    0;           0;    5;     Numeric; Channel number increment 
+  0;  5;  53;    0;           0;    5;     Numeric; Field of view number increment 
+# Class 06 - Location (horizontal - 2) 
+  0;  6;   1;    5;   -18000000;   26;      Degree; Longitude (high accuracy) 
+  0;  6;   2;    2;      -18000;   16;      Degree; Longitude (coarse accuracy) 
+  0;  6;  11;    5;   -18000000;   26;      Degree; Longitude increment (high accuracy) 
+  0;  6;  12;    2;      -18000;   16;      Degree; Longitude increment (coarse accuracy) 
+  0;  6;  21;   -1;           0;   13;           m; Distance 
+  0;  6;  30;    5;           0;   13;     rad m-1; Wave number (spectral) 
+  0;  6;  31;    0;           0;   12;     Numeric; Column number 
+  0;  6;  33;   -1;           0;   16;           m; Pixel size on horizontal - 2 
+  0;  6;  34;    0;           0;    7;     Numeric; Cross-track cell number 
+  0;  6;  40;    0;           0;   13;           m; Radius of confidence 
+# Class 07 - Location (vertical) 
+  0;  7;   1;    0;        -400;   15;           m; Height of station 
+  0;  7;   2;   -1;         -40;   16;           m; Height or altitude 
+  0;  7;   3;   -1;        -400;   17;      m2 s-2; Geopotential 
+  0;  7;   4;   -1;           0;   14;          Pa; Pressure 
+  0;  7;   5;    0;        -400;   12;           m; Height increment 
+  0;  7;   6;    0;           0;   15;           m; Height above station 
+  0;  7;   7;    0;       -1000;   17;           m; Height 
+  0;  7;   8;    0;      -10000;   20;      m2 s-2; Geopotential 
+  0;  7;   9;    0;       -1000;   17;         gpm; Geopotential height 
+  0;  7;  21;    2;       -9000;   15;      Degree; Elevation (see Note 1) 
+  0;  7;  21;    2;       -9000;   15;      Degree; Elevation 
+  0;  7;  22;    2;       -9000;   15;      Degree; Solar elevation 
+  0;  7;  24;    2;       -9000;   15;      Degree; Satellite zenith angle 
+  0;  7;  25;    2;       -9000;   15;      Degree; Solar zenith angle 
+  0;  7;  61;    2;           0;   14;           m; Depth below land surface 
+  0;  7;  62;    1;           0;   17;           m; Depth below sea/water surface 
+  0;  7;  64;    0;           0;    4;           m; Height above station (sensor height artificially corrected) (see Note 2) 
+  0;  7;  70;    0;           0;   10;           m; Drogue depth 
+# Class 08 - Significance qualifiers 
+  0;  8;   1;    0;           0;    7;  Flag_Table; Vertical sounding significance 
+  0;  8;   2;    0;           0;    6;  Code_Table; Vertical significance (surface observations) 
+  0;  8;   3;    0;           0;    6;  Code_Table; Vertical significance (satellite observations) 
+  0;  8;   4;    0;           0;    3;  Code_Table; Phase of aircraft flight 
+  0;  8;   5;    0;           0;    4;  Code_Table; Meteorological attribute significance 
+  0;  8;   6;    0;           0;    9;  Flag_Table; Ozone vertical sounding significance 
+  0;  8;   7;    0;           0;    4;  Code_Table; Dimensional significance 
+  0;  8;   8;    0;           0;    9;  Flag_Table; Radiation vertical sounding significance 
+  0;  8;  11;    0;           0;    6;  Code_Table; Meteorological feature 
+  0;  8;  12;    0;           0;    2;  Code_Table; Land/sea qualifier 
+  0;  8;  13;    0;           0;    2;  Code_Table; Day/night qualifier 
+  0;  8;  14;    0;           0;    4;  Code_Table; Qualifier for runway visual range 
+  0;  8;  16;    0;           0;    3;  Code_Table; Change qualifier of a trend-type forecast or an aerodrome forecast 
+  0;  8;  17;    0;           0;    2;  Code_Table; Qualifier of the time when the forecast change is expected 
+  0;  8;  18;    0;           0;   17;  Flag_Table; SEAWINDS land/ice surface type 
+  0;  8;  20;    0;           0;   16;     Numeric; Total number of missing entities (with respect to accumulation or average) 
+  0;  8;  21;    0;           0;    5;  Code_Table; Time significance 
+  0;  8;  22;    0;           0;   16;     Numeric; Total number (with respect to accumulation or average) 
+  0;  8;  23;    0;           0;    6;  Code_Table; First order statistics 
+  0;  8;  24;    0;           0;    6;  Code_Table; Difference statistics 
+  0;  8;  25;    0;           0;    4;  Code_Table; Time difference qualifier 
+  0;  8;  30;    0;           0;   13;     Numeric; "Manual on Codes (Volume I.1, Section C) Code table from which data are derived" 
+  0;  8;  31;    0;           0;    8;     Numeric; Data category CREX table A 
+  0;  8;  35;    0;           0;    3;  Code_Table; Type of monitoring exercise 
+  0;  8;  36;    0;           0;    3;  Code_Table; Type of centre or station performing monitoring 
+  0;  8;  51;    0;           0;    3;  Code_Table; Qualifier for number of missing values in calculation of statistic 
+  0;  8;  52;    0;           0;    5;  Code_Table; Condition for which number of days of occurrence follows 
+  0;  8;  53;    0;           0;    2;  Code_Table; Day of occurrence qualifier 
+  0;  8;  60;    0;           0;    4;  Code_Table; Sample scanning mode significance 
+  0;  8;  70;    0;           0;    4;  Code_Table; TOVS/ATOVS product qualifier 
+  0;  8;  72;    0;           0;    3;  Code_Table; Pixel(s) type 
+# Class 10 - Non-coordinate location (vertical) 
+  0; 10;   1;    0;        -400;   15;           m; Height of land surface 
+  0; 10;   2;   -1;         -40;   16;           m; Height 
+  0; 10;   3;   -1;        -400;   17;      m2 s-2; Geopotential 
+  0; 10;   4;   -1;           0;   14;          Pa; Pressure 
+  0; 10;   7;    0;       -1000;   17;           m; Height 
+  0; 10;   8;    0;      -10000;   20;      m2 s-2; Geopotential 
+  0; 10;   9;    0;       -1000;   17;         gpm; Geopotential height 
+  0; 10;  10;   -1;           0;   14;          Pa; Minimum pressure reduced to mean sea level 
+  0; 10;  11;   -1;           0;   14;          Pa; Maximum pressure reduced to mean sea level 
+  0; 10;  31;    2; -1073741824;   31;           m; "In direction of the North Pole, distance from the Earth�s centre" 
+  0; 10;  40;    0;           0;   10;     Numeric; Number of retrieved layers 
+  0; 10;  50;    2;           0;   16;           m; Standard deviation altitude 
+  0; 10;  51;   -1;           0;   14;          Pa; Pressure reduced to mean sea level 
+  0; 10;  52;   -1;           0;   14;          Pa; Altimeter setting (QNH) 
+  0; 10;  60;   -1;       -1024;   11;          Pa; Pressure change 
+  0; 10;  61;   -1;        -500;   10;          Pa; 3-hour pressure change 
+  0; 10;  62;   -1;       -1000;   11;          Pa; 24-hour pressure change 
+  0; 10;  63;    0;           0;    4;  Code_Table; Characteristic of pressure tendency 
+  0; 10;  70;    0;        -400;   16;           m; Indicated aircraft altitude 
+# Class 11 - Wind and turbulence 
+  0; 11;   1;    0;           0;    9; Degree_true; Wind direction 
+  0; 11;   2;    1;           0;   12;       m s-1; Wind speed 
+  0; 11;   3;    1;       -4096;   13;       m s-1; u-component 
+  0; 11;   4;    1;       -4096;   13;       m s-1; v-component 
+  0; 11;   5;    1;        -512;   10;      Pa s-1; w-component 
+  0; 11;   6;    2;       -4096;   13;       m s-1; w-component 
+  0; 11;  10;    0;           0;    9; Degree_true; Wind direction associated with wind speed which follows 
+  0; 11;  11;    0;           0;    9; Degree_true; Wind direction at 10 m 
+  0; 11;  12;    1;           0;   12;       m s-1; Wind speed at 10 m 
+  0; 11;  13;    0;           0;    9; Degree_true; Wind direction at 5 m 
+  0; 11;  14;    1;           0;   12;       m s-1; Wind speed at 5 m 
+  0; 11;  16;    0;           0;    9; Degree_true; Extreme counterclockwise wind direction of a variable wind 
+  0; 11;  17;    0;           0;    9; Degree_true; Extreme clockwise wind direction of a variable wind 
+  0; 11;  19;    0;           0;    7;           %; Steadiness of wind* 
+  0; 11;  21;    9;      -65536;   17;         s-1; Relative vorticity 
+  0; 11;  22;    9;      -65536;   17;         s-1; Divergence 
+  0; 11;  23;   -2;      -65536;   17;      m2 s-1; Velocity potential 
+  0; 11;  31;    0;           0;    4;  Code_Table; Degree of turbulence 
+  0; 11;  32;   -1;         -40;   16;           m; Height of base of turbulence 
+  0; 11;  33;   -1;         -40;   16;           m; Height of top of turbulence 
+  0; 11;  34;    1;       -1024;   11;       m s-1; Vertical gust velocity 
+  0; 11;  35;    2;       -8192;   14;       m s-2; Vertical gust acceleration 
+  0; 11;  36;    1;           0;   10;       m s-1; Maximum derived equivalent vertical gust speed 
+  0; 11;  37;    0;           0;    6;  Code_Table; Turbulence Index 
+  0; 11;  38;    0;           0;    5;  Code_Table; Time of occurrence of Peak Eddy Dissipation Rate 
+  0; 11;  40;    1;           0;   12;       m s-1; Maximum wind speed (mean wind) 
+  0; 11;  41;    1;           0;   12;       m s-1; Maximum wind speed (gusts) 
+  0; 11;  42;    1;           0;   12;       m s-1; Maximum wind speed (10-min mean wind) 
+  0; 11;  43;    0;           0;    9; Degree_true; Maximum wind gust direction 
+  0; 11;  44;    0;           0;    9; Degree_true; Mean wind direction for surface - 1500 m (5000 feet) 
+  0; 11;  45;    1;           0;   12;       m s-1; Mean wind speed for surface - 1500 m (5000 feet) 
+  0; 11;  46;    1;           0;   12;       m s-1; Maximum instantaneous wind speed 
+  0; 11;  47;    1;           0;   12;       m s-1; Maximum instantaneous wind speed over 10 minutes 
+  0; 11;  49;    0;           0;    9; Degree_true; Standard deviation of wind direction 
+  0; 11;  50;    1;           0;   12;       m s-1; Standard deviation of horizontal wind speed 
+  0; 11;  51;    1;           0;    8;       m s-1; Standard deviation of vertical wind speed 
+  0; 11;  52;    2;           0;   13;       m s-1; Formal uncertainty in wind speed 
+  0; 11;  53;    2;           0;   15; Degree_true; Formal uncertainty in wind direction 
+  0; 11;  61;    1;           0;   12;       m s-1; Absolute wind shear in 1 km layer below 
+  0; 11;  62;    1;           0;   12;       m s-1; Absolute wind shear in 1 km layer above 
+  0; 11;  70;    0;           0;   32;   CCITT_IA5; Designator of the runway affected by wind shear (including ALL) 
+  0; 11;  71;    3;        -128;   14;      m2 s-2; Turbulent vertical momentum flux 
+  0; 11;  72;    3;        -128;   11;     K m s-1; Turbulent vertical buoyancy flux 
+  0; 11;  73;    2;       -1024;   13;      m2 s-2; Turbulent kinetic energy 
+  0; 11;  74;    2;       -1024;   10;      m2 s-2; Dissipation energy 
+  0; 11;  75;    2;           0;    8;    m2/3 s-1; Mean turbulence intensity (eddy dissipation rate) 
+  0; 11;  76;    2;           0;    8;    m2/3 s-1; Peak turbulence intensity (eddy dissipation rate) 
+  0; 11;  81;    2;           0;   16; Degree_true; Model wind direction at 10m 
+  0; 11;  82;    2;           0;   14;       m s-1; Model wind speed at 10m 
+# Class 12 - Temperature 
+  0; 12;   1;    1;           0;   12;           K; Temperature/dry-bulb temperature 
+  0; 12;   2;    1;           0;   12;           K; Wet-bulb temperature 
+  0; 12;   3;    1;           0;   12;           K; Dew-point temperature 
+  0; 12;   4;    1;           0;   12;           K; Dry-bulb temperature at 2 m 
+  0; 12;   5;    1;           0;   12;           K; Wet-bulb temperature at 2 m 
+  0; 12;   6;    1;           0;   12;           K; Dew-point temperature at 2 m 
+  0; 12;   7;    1;           0;   12;           K; Virtual temperature 
+  0; 12;  11;    1;           0;   12;           K; "Maximum temperature, at height and over period specified" 
+  0; 12;  12;    1;           0;   12;           K; "Minimum temperature, at height and over period specified" 
+  0; 12;  13;    1;           0;   12;           K; "Ground minimum temperature, past 12 hours" 
+  0; 12;  14;    1;           0;   12;           K; "Maximum temperature at 2 m, past 12 hours" 
+  0; 12;  15;    1;           0;   12;           K; "Minimum temperature at 2 m, past 12 hours" 
+  0; 12;  16;    1;           0;   12;           K; "Maximum temperature at 2 m, past 24 hours" 
+  0; 12;  17;    1;           0;   12;           K; "Minimum temperature at 2 m, past 24 hours" 
+  0; 12;  21;    2;           0;   16;           K; Maximum temperature at 2m 
+  0; 12;  22;    2;           0;   16;           K; Minimum temperature at 2m 
+  0; 12;  30;    1;           0;   12;           K; Soil temperature 
+  0; 12;  51;    1;           0;   10;           K; Standard deviation temperature 
+  0; 12;  52;    1;           0;   12;           K; Highest daily mean temperature 
+  0; 12;  53;    1;           0;   12;           K; Lowest daily mean temperature 
+  0; 12;  61;    1;           0;   12;           K; Skin temperature 
+  0; 12;  62;    1;           0;   12;           K; Equivalent black body temperature 
+  0; 12;  63;    1;           0;   12;           K; Brightness temperature 
+  0; 12;  64;    1;           0;   12;           K; Instrument temperature 
+  0; 12;  65;    1;           0;   12;           K; Standard deviation brightness temperature 
+  0; 12;  71;    1;           0;   12;           K; Coldest cluster temperature 
+  0; 12;  72;    6;           0;   31;  W m-2 sr-1; Radiance 
+  0; 12;  75;   -3;           0;   16;  W m-3 sr-1; Spectral radiance 
+  0; 12;  76;    3;           0;   16;  W m-2 sr-1; Radiance 
+  0; 12; 101;    2;           0;   16;           K; Temperature/dry-bulb temperature 
+  0; 12; 102;    2;           0;   16;           K; Wet-bulb temperature 
+  0; 12; 103;    2;           0;   16;           K; Dew-point temperature 
+  0; 12; 104;    2;           0;   16;           K; Dry-bulb temperature at 2m 
+  0; 12; 105;    2;           0;   16;           K; Web-bulb temperature at 2m 
+  0; 12; 106;    2;           0;   16;           K; Dew-point temperature at 2m 
+  0; 12; 107;    2;           0;   16;           K; Virtual temperature 
+  0; 12; 111;    2;           0;   16;           K; "Maximum temperature, at height and over period specified" 
+  0; 12; 112;    2;           0;   16;           K; "Minimum temperature, at height and over period specified" 
+  0; 12; 113;    2;           0;   16;           K; "Ground minimum temperature, past 12 hours" 
+  0; 12; 114;    2;           0;   16;           K; "Maximum temperature at 2m, past 12 hours" 
+  0; 12; 115;    2;           0;   16;           K; "Minimum temperature at 2m, past 12 hours" 
+  0; 12; 116;    2;           0;   16;           K; "Maximum temperature at 2m, past 24 hours" 
+  0; 12; 117;    2;           0;   16;           K; "Minimum temperature at 2m, past 24 hours" 
+  0; 12; 130;    2;           0;   16;           K; Soil temperature 
+  0; 12; 152;    2;           0;   16;           K; Highest daily mean temperature 
+  0; 12; 153;    2;           0;   16;           K; Lowest daily mean temperature 
+  0; 12; 161;    2;           0;   16;           K; Skin temperature 
+  0; 12; 162;    2;           0;   16;           K; Equivalent black body temperature 
+  0; 12; 163;    2;           0;   16;           K; Brightness temperature 
+  0; 12; 164;    2;           0;   16;           K; Instrument temperature 
+  0; 12; 171;    2;           0;   16;           K; Coldest cluster temperature 
+# Class 13 - Hygrographic and hydrological elements 
+  0; 13;   1;    5;           0;   14;     kg kg-1; Specific humidity 
+  0; 13;   2;    5;           0;   14;     kg kg-1; Mixing ratio 
+  0; 13;   3;    0;           0;    7;           %; Relative humidity 
+  0; 13;   4;   -1;           0;   10;          Pa; Vapour pressure 
+  0; 13;   5;    3;           0;    7;      kg m-3; Vapour density 
+  0; 13;   6;   -1;         -40;   16;           m; Mixing heights 
+  0; 13;   7;    0;           0;    7;           %; Minimum relative humidity 
+  0; 13;   8;    0;           0;    7;           %; Maximum relative humidity 
+  0; 13;  11;    1;          -1;   14;      kg m-2; Total precipitation/total water equivalent 
+  0; 13;  12;    2;          -2;   12;           m; Depth of fresh snow 
+  0; 13;  13;    2;          -2;   16;           m; Total snow depth 
+  0; 13;  14;    4;           0;   12;  kg m-2 s-1; Rainfall/water equivalent of snow (averaged rate) 
+  0; 13;  15;    7;           0;   12;       m s-1; Snowfall  (averaged rate) 
+  0; 13;  16;    0;           0;    7;      kg m-2; Precipitable water 
+  0; 13;  19;    1;          -1;   14;      kg m-2; Total precipitation past 1 hour 
+  0; 13;  20;    1;          -1;   14;      kg m-2; Total precipitation past 3 hours 
+  0; 13;  21;    1;          -1;   14;      kg m-2; Total precipitation past 6 hours 
+  0; 13;  22;    1;          -1;   14;      kg m-2; Total precipitation past 12 hours 
+  0; 13;  23;    1;          -1;   14;      kg m-2; Total precipitation past 24 hours 
+  0; 13;  31;    0;           0;    7;      kg m-2; Evapotranspiration 
+  0; 13;  32;    1;           0;    8;      kg m-2; Evaporation/evapotranspiration 
+  0; 13;  33;    1;           0;   10;      kg m-2; Evaporation/evapotranspiration 
+  0; 13;  38;    0;           0;    2;  Code_Table; Superadiabatic indicator 
+  0; 13;  39;    0;           0;    3;  Code_Table; Terrain type (ice/snow) 
+  0; 13;  41;    0;           0;    4;  Code_Table; Pasquill-Gifford stability category 
+  0; 13;  42;    0;         -20;    6;           K; Parcel lifted index (to 500 hPa) 
+  0; 13;  43;    0;         -20;    6;           K; Best lifted index (to 500 hPa) 
+  0; 13;  51;    0;           0;    4;  Code_Table; "Frequency group, precipitation" 
+  0; 13;  52;    1;          -1;   14;      kg m-2; Highest daily amount of precipitation 
+  0; 13;  60;    1;         -10;   17;      kg m-2; Total accumulated precipitation 
+  0; 13;  71;    2;           0;   14;           m; Upstream water level 
+  0; 13;  72;    2;           0;   14;           m; Downstream water level 
+  0; 13;  73;    2;           0;   14;           m; Maximum water level 
+  0; 13;  80;    1;           0;   10;     pH unit; Water pH 
+  0; 13;  81;    3;           0;   14; Siemens m-1; Water conductivity 
+  0; 13;  82;    1;           0;   12;           K; Water temperature 
+  0; 13;  83;    6;           0;   15;      Kg m-3; Dissolved oxygen 
+  0; 13;  84;    0;           0;   14;       Lumen; Turbidity 
+  0; 13;  85;    3;           0;   14;           V; Oxydation Reduction Potential (ORP) 
+# Class 14 - Radiation and radiance 
+  0; 14;   1;   -3;       -2048;   12;       J m-2; "Long-wave radiation, integrated over 24 hours" 
+  0; 14;   2;   -3;       -2048;   12;       J m-2; "Long-wave radiation, integrated over period specified" 
+  0; 14;   3;   -3;       -2048;   12;       J m-2; "Short-wave radiation, integrated over 24 hours" 
+  0; 14;   4;   -3;       -2048;   12;       J m-2; "Short-wave radiation, integrated over period specified" 
+  0; 14;  11;   -3;       -2048;   12;       J m-2; "Net long-wave radiation, integrated over 24 hours" 
+  0; 14;  12;   -3;       -2048;   12;       J m-2; "Net long-wave radiation, integrated over period specified" 
+  0; 14;  13;   -3;       -2048;   12;       J m-2; "Net short-wave radiation, integrated over 24 hours" 
+  0; 14;  14;   -3;       -2048;   12;       J m-2; "Net short-wave radiation, integrated over period specified" 
+  0; 14;  15;   -4;      -16384;   15;       J m-2; "Net radiation, integrated over 24 hours" 
+  0; 14;  16;   -4;      -16384;   15;       J m-2; "Net radiation, integrated over period specified" 
+  0; 14;  17;   -3;       -2048;   12;       W m-2; Instantaneous long-wave radiation 
+  0; 14;  18;   -3;       -2048;   12;       W m-2; Instantaneous short-wave radiation 
+  0; 14;  19;    0;           0;    7;           %; Surface albedo 
+  0; 14;  20;   -4;           0;   15;       J m-2; "Global solar radiation, integrated over 24 hours" 
+  0; 14;  21;   -4;           0;   15;       J m-2; "Global radiation, integrated over period specified" 
+  0; 14;  22;   -4;           0;   15;       J m-2; "Diffuse solar radiation, integrated over 24 hours" 
+  0; 14;  23;   -4;           0;   15;       J m-2; "Diffuse solar radiation, integrated over period specified" 
+  0; 14;  24;   -4;           0;   15;       J m-2; "Direct solar radiation, integrated over 24 hours" 
+  0; 14;  25;   -4;           0;   15;       J m-2; "Direct solar radiation, integrated over period specified" 
+  0; 14;  26;    0;           0;    7;           %; Albedo at the top of clouds 
+  0; 14;  27;    0;           0;    7;           %; Albedo 
+  0; 14;  28;   -2;           0;   16;       J m-2; "Global solar radiation (high accuracy), integrated over period specified" 
+  0; 14;  29;   -2;           0;   16;       J m-2; "Diffuse solar radiation (high accuracy), integrated over period specified" 
+  0; 14;  30;   -2;           0;   16;       J m-2; "Direct solar radiation (high accuracy), integrated over period specified" 
+  0; 14;  31;    0;           0;   11;      Minute; Total sunshine 
+  0; 14;  32;    0;           0;   10;        Hour; Total sunshine 
+  0; 14;  33;    0;           0;    9;           %; Total sunshine 
+  0; 14;  34;    0;           0;   11;      Minute; Sunshine over period specified 
+  0; 14;  42;    0;           0;    7;           %; Bidirectional reflectance 
+  0; 14;  45;    0;           0;   11;Wm-2 sr-1 cm-1; Channel radiance 
+  0; 14;  51;   -3;           0;   14;       J m-2; Direct solar radiation integrated over last hour 
+# Class 15 - Physical/chemical constituents 
+  0; 15;   1;    0;           0;   10;      Dobson; Ozone 
+  0; 15;   2;    2;           0;   10;     Numeric; Air mass (slant path at 22 km) 
+  0; 15;   3;    4;           0;    9;      Pascal; Measured ozone partial pressure (sounding) 
+  0; 15;   4;    3;           0;   11;     Numeric; Ozone sounding correction factor 
+  0; 15;   5;    0;           0;   10;          DU; Ozone p 
+  0; 15;  11;    3;       14000;   13;  log (1/m2); Log 10 of integrated electron density 
+  0; 15;  15;    0;           0;   31;     Numeric; Maximum image spectral component before normalization 
+  0; 15;  20;    8;           0;   21;      kg m-2; Integrated 03 density 
+# Class 19 - Synoptic features 
+  0; 19;   1;    0;           0;    6;  Code_Table; Type of synoptic feature 
+  0; 19;   2;   -2;           0;   12;           m; Effective radius of feature 
+  0; 19;   3;    0;           0;    8;       m s-1; Wind speed threshold 
+  0; 19;   4;   -2;           0;   12;           m; Effective radius with respect to wind speeds above threshold 
+  0; 19;   5;    0;           0;    9; Degree_true; Direction of motion of feature 
+  0; 19;   6;    2;           0;   14;       m s-1; Speed of motion of feature 
+  0; 19;   7;   -3;           0;   12;           m; Effective radius of feature 
+  0; 19;   8;    0;           0;    3;  Code_Table; Vertical extent of circulation 
+  0; 19;   9;   -3;           0;   12;           m; Effective radius with respect to wind speeds above threshold (large storms) 
+  0; 19;  10;    0;           0;    4;  Code_Table; Method for tracking the centre of synoptic feature 
+# Class 20 - Observed phenomena 
+  0; 20;   1;   -1;           0;   13;           m; Horizontal visibility 
+  0; 20;   2;   -1;           0;    7;           m; Vertical visibility 
+  0; 20;   3;    0;           0;    9;  Code_Table; Present weather 
+  0; 20;   4;    0;           0;    5;  Code_Table; Past weather (1) 
+  0; 20;   5;    0;           0;    5;  Code_Table; Past weather (2) 
+  0; 20;   8;    0;           0;    5;  Code_Table; Cloud distribution for aviation 
+  0; 20;   9;    0;           0;    4;  Code_Table; General Weather Indicator (TAF/METAR) 
+  0; 20;  10;    0;           0;    7;           %; Cloud cover (total) 
+  0; 20;  11;    0;           0;    4;  Code_Table; Cloud amount 
+  0; 20;  12;    0;           0;    6;  Code_Table; Cloud type 
+  0; 20;  13;   -1;         -40;   11;           m; Height of base of cloud 
+  0; 20;  14;   -1;         -40;   11;           m; Height of top of cloud 
+  0; 20;  15;   -1;           0;   14;          Pa; Pressure at base of cloud 
+  0; 20;  16;   -1;           0;   14;          Pa; Pressure at top of cloud 
+  0; 20;  17;    0;           0;    4;  Code_Table; Cloud top description 
+  0; 20;  18;    0;           0;    2;  Code_Table; Tendency of runway visual range 
+  0; 20;  19;    0;           0;   72;   CCITT_IA5; Significant present or forecast weather 
+  0; 20;  20;    0;           0;   32;   CCITT_IA5; Significant recent weather phenomena 
+  0; 20;  31;    2;           0;    7;           m; Ice deposit (thickness) 
+  0; 20;  32;    0;           0;    3;  Code_Table; Rate of ice accretion 
+  0; 20;  33;    0;           0;    4;  Flag_Table; Cause of ice accretion 
+  0; 20;  34;    0;           0;    5;  Code_Table; Sea ice concentration 
+  0; 20;  35;    0;           0;    4;  Code_Table; Amount and type of ice 
+  0; 20;  36;    0;           0;    5;  Code_Table; Ice situation 
+  0; 20;  37;    0;           0;    5;  Code_Table; Ice development 
+  0; 20;  38;    0;           0;   12; Degree_true; Bearing of ice edge 
+  0; 20;  39;   -1;           0;   13;           m; Ice distance 
+  0; 20;  41;    0;           0;    4;  Code_Table; Airframe icing 
+  0; 20;  51;    0;           0;    7;           %; Amount of low clouds 
+  0; 20;  52;    0;           0;    7;           %; Amount of middle clouds 
+  0; 20;  53;    0;           0;    7;           %; Amount of high clouds 
+  0; 20;  61;    0;           0;   12;           m; Runway visual range (RVR) 
+  0; 20;  62;    0;           0;    5;  Code_Table; State of the ground (with or without snow) 
+  0; 20;  63;    0;           0;   10;  Code_Table; Special phenomena 
+  0; 20;  70;    0;           0;    7;     Numeric; Minimum number of atmospherics 
+  0; 20;  71;    0;           0;    4;  Code_Table; Accuracy of fix and rate of atmospherics 
+  0; 20;  81;    0;           0;    7;           %; Cloud amount in segment 
+  0; 20;  82;    0;           0;    7;           %; Amount segment cloud free 
+  0; 20;  90;    0;           0;    4;  Code_Table; Special clouds 
+# Class 21 - Radar data 
+  0; 21;   1;    0;         -64;    7;          dB; Horizontal reflectivity 
+  0; 21;   2;    0;         -64;    7;          dB; Vertical reflectivity 
+  0; 21;   3;    1;          -5;    7;          dB; Differential reflectivity 
+  0; 21;   5;    0;         -65;    6;          dB; Linear depolarisation ratio  
+  0; 21;   6;    0;         -65;    6;          dB; Circular depolarisation ratio  
+  0; 21;  11;    0;        -128;    8;       m s-1; Doppler mean velocity in X-direction 
+  0; 21;  12;    0;        -128;    8;       m s-1; Doppler mean velocity in Y-direction 
+  0; 21;  13;    0;        -128;    8;       m s-1; Doppler mean velocity in Z-direction 
+  0; 21;  14;    1;       -4096;   13;       m s-1; Doppler mean velocity (radial) 
+  0; 21;  17;    1;           0;    8;       m s-1; Doppler velocity spectral width 
+  0; 21;  21;   -3;           0;    4;           m; Echo tops  
+  0; 21;  30;    0;         -32;    8;          dB; Signal to noise ratio 
+  0; 21;  31;    0;           0;    7;      kg m-2; Vertically integrated liquid-water content 
+  0; 21;  36;    7;           0;   12;       m s-1; Radar rainfall intensity  
+  0; 21;  41;   -2;           0;    8;           m; Bright-band height  
+  0; 21;  51;    0;        -256;    8;          dB; Signal power above 1 mW 
+  0; 21;  62;    2;       -5000;   13;    Decibels; Backscatter 
+  0; 21;  63;    1;           0;   10;           %; Radiometric resolution (noise value) 
+  0; 21;  64;    0;           0;    8;     Numeric; Clutter noise estimate 
+  0; 21;  65;    0;        -127;    8;     Numeric; Missing packet counter 
+  0; 21;  66;    0;           0;   12;  Flag_Table; Wave scatterometer product confidence data 
+  0; 21;  67;    0;           0;   13;  Flag_Table; Wind product confidence data 
+  0; 21;  68;    0;           0;    8;  Flag_Table; Radar altimeter product confidence data 
+  0; 21;  69;    0;           0;   10;  Flag_Table; SST product confidence data 
+  0; 21;  70;    0;           0;   23;  Flag_Table; SST product confidence data (SADIST-2) 
+  0; 21;  71;    0;           0;   16;     Numeric; Peakiness 
+  0; 21;  72;    0;           0;    4;  Flag_Table; Satellite altimeter calibration status 
+  0; 21;  73;    0;           0;    9;  Flag_Table; Satelllite altimeter instrument mode 
+  0; 21;  75;    0;           0;    8;     Numeric; Image spectrum intensity 
+  0; 21;  76;    0;           0;    3;  Code_Table; Representation of intensities 
+  0; 21;  77;    3;           0;   14;           m; Altitude correction (ionosphere) 
+  0; 21;  78;    3;           0;    9;           m; Altitude correction (dry troposphere) 
+  0; 21;  79;    3;        2000;   10;           m; Altitude correction (wet troposphere) 
+  0; 21;  80;    3;           0;   11;           m; Altitude correction (calibration constant) 
+  0; 21;  81;    3;           0;   10;           m; Open loop correction (height-time loop) 
+  0; 21;  82;    3;       -3000;   14;    Decibels; Open loop correction (auto gain control) 
+  0; 21;  85;    0;           0;    4;     Numeric; ATSR sea surface temperature across- track band number 
+  0; 21;  91;    0;        -100;    8;          dB; Radar signal Doppler spectrum 0th moment 
+  0; 21;  92;    0;        -100;    8;          dB; "RASS signal Doppler spectrum 0th moment, referring to RASS signal" 
+  0; 21; 101;    0;           0;    3;     Numeric; Number of vector ambiguities 
+  0; 21; 102;    0;           0;    3;     Numeric; Index of selected wind vector 
+  0; 21; 103;    0;           0;    5;     Numeric; Total number of sigma-0 measurements 
+  0; 21; 104;    3;      -30000;   15;     Numeric; Likelihood computed for solution 
+  0; 21; 105;    2;      -10000;   14;          dB; Normalized radar cross-section 
+  0; 21; 106;    3;           0;   14;     Numeric; Kp variance coefficient (Alpha) 
+  0; 21; 107;    8;           0;   16;     Numeric; Kp variance coefficient (Beta) 
+  0; 21; 109;    0;           0;   17;  Flag_Table; SEAWINDS wind vector cell quality 
+  0; 21; 110;    0;           0;    6;     Numeric; Number of inner-beam Sigma-0 (forward of satellite) 
+  0; 21; 111;    0;           0;    6;     Numeric; Number of outer-beam Sigma-0 (forward of satellite) 
+  0; 21; 112;    0;           0;    6;     Numeric; Number of inner-beam Sigma-0 (aft of satellite) 
+  0; 21; 113;    0;           0;    6;     Numeric; Number of outer-beam Sigma-0 (aft of satellite) 
+  0; 21; 114;    3;     -140000;   18;          dB; Kp variance coefficent (Gamma) 
+  0; 21; 115;    0;           0;   17;  Flag_Table; SEAWINDS sigma-0 quality 
+  0; 21; 116;    0;           0;   17;  Flag_Table; SEAWINDS sigma-0 mode 
+  0; 21; 117;    2;           0;   16;     Numeric; Sigma-0 variance quality control 
+  0; 21; 118;    2;      -10000;   14;          dB; Attenuation correction on sigma-0 
+  0; 21; 119;    0;           0;    6;  Code_Table; Wind scatterometer geophysical model function 
+  0; 21; 120;    3;           0;   10;     Numeric; Probability of rain 
+  0; 21; 121;    0;           0;    8;     Numeric; SEAWINDS NOF* rain index 
+  0; 21; 122;    2;      -10000;   14;          dB; Attenuation correction of sigma-0 (from tB) 
+  0; 21; 123;    2;      -30000;   15;          dB; SEAWINDS normalized radar cross section 
+# Class 22 - Oceanographic elements 
+  0; 22;   1;    0;           0;    9; Degree_true; Direction of waves  
+  0; 22;   2;    0;           0;    9; Degree_true; Direction of wind waves  
+  0; 22;   3;    0;           0;    9; Degree_true; Direction of swell waves  
+  0; 22;   4;    0;           0;    9; Degree_true; Direction of current  
+  0; 22;  11;    0;           0;    6;           s; Period of waves  
+  0; 22;  12;    0;           0;    6;           s; Period of wind waves  
+  0; 22;  13;    0;           0;    6;           s; Period of swell waves  
+  0; 22;  21;    1;           0;   10;           m; Height of waves  
+  0; 22;  22;    1;           0;   10;           m; Height of wind waves  
+  0; 22;  23;    1;           0;   10;           m; Height of swell waves  
+  0; 22;  25;    2;           0;   10;           m; Standard deviation wave height 
+  0; 22;  26;    2;           0;   10;           m; Standard deviation of significant wave height 
+  0; 22;  31;    2;           0;   13;       m s-1; Speed of current  
+  0; 22;  35;    2;           0;   14;           m; Tidal elevation with respect to local chart datum 
+  0; 22;  36;    2;           0;   14;           m; Meteorological residual tidal elevation (surge or offset) 
+  0; 22;  37;    3;      -10000;   15;           m; Tidal elevation with respect to national land datum 
+  0; 22;  38;    3;      -10000;   15;           m; Tidal elevation with respect to local chart datum 
+  0; 22;  39;    3;       -5000;   12;           m; Meteorological residual tidal elevation (surge or offset) 
+  0; 22;  40;    3;       -5000;   14;           m; Meteorological residual tidal elevation (surge or offset) 
+  0; 22;  41;    1;           0;   12;           K; Sea-surface temperature (15-day running mean) 
+  0; 22;  42;    1;           0;   12;           K; Sea/water temperature 
+  0; 22;  43;    2;           0;   15;           K; Sea/water temperature 
+  0; 22;  44;    1;           0;   14;       m s-1; Sound velocity  
+  0; 22;  50;    2;           0;    8;           K; Standard deviation sea-surface temperature 
+  0; 22;  61;    0;           0;    4;  Code_Table; State of the sea  
+  0; 22;  62;    2;           0;   14;Part per thousand; Salinity 
+  0; 22;  63;    0;           0;   14;           m; Total water depth  
+  0; 22;  67;    0;           0;   10;  Code_Table; Instrument type for water temperature profile measurement 
+  0; 22;  68;    0;           0;    7;  Code_Table; Water temperature profile recorder types 
+  0; 22;  70;    2;           0;   13;           m; Significant wave height 
+  0; 22;  71;    1;           0;    9;           s; Spectral peak wave period 
+  0; 22;  72;    0;           0;   13;           m; Spectral peak wave length 
+  0; 22;  73;    2;           0;   13;           m; Maximum wave height 
+  0; 22;  74;    1;           0;    9;           s; Average wave period 
+  0; 22;  75;    0;           0;   13;           m; Average wave length 
+  0; 22;  76;    0;           0;    9; Degree_true; Direction from which dominant waves are coming 
+  0; 22;  77;    0;           0;    9;      Degree; Directional spread of dominant wave 
+  0; 22;  78;    0;           0;   12;           s; Duration of wave record 
+  0; 22;  79;    0;           0;   16;           m; Length of wave record 
+  0; 22;  80;    3;           0;   10;          Hz; Waveband central frequency 
+  0; 22;  81;    5;           0;   13;         m-1; Waveband central wave number 
+  0; 22;  82;    2;           0;   20;        m2 s; Maximum non-directional spectral wave density 
+  0; 22;  83;    2;           0;   20;          m3; Maximum non-directional spectral wave number 
+  0; 22;  84;    0;           0;    7;     Numeric; Band containing maximum non- directional spectral wave density 
+  0; 22;  85;    0;           0;    7;     Numeric; Spectral wave density ratio 
+  0; 22;  86;    0;           0;    9; Degree_true; Mean direction from which waves are coming 
+  0; 22;  87;    0;           0;    9; Degree_true; Principal direction from which waves are coming 
+  0; 22;  88;    2;           0;    7;     Numeric; First normalized polar coordinate from Fourier coefficients 
+  0; 22;  89;    2;           0;    7;     Numeric; Second normalized polar coordinate from Fourier coefficients 
+  0; 22;  90;    2;           0;   20;        m2 s; Non-directional spectral estimate by wave frequency 
+  0; 22;  91;    2;           0;   20;          m3; Non-directional spectral estimate by wave number 
+  0; 22;  92;    2;           0;   20;  m2 rad-1 s; Directional spectral estimate by wave frequency 
+  0; 22;  93;    2;           0;   20;          m4; Directional spectral estimate by wave number 
+  0; 22;  94;    0;           0;    7;     Numeric; Total number of wave bands 
+  0; 22;  95;    0;           0;    8;      Degree; Directional spread of individual waves 
+  0; 22;  96;    3;           0;    4;         s-1; Spectral band width 
+  0; 22;  97;    0;           0;   14;           m; Mean wavelength > 731 m of image spectrum at low wave numbers 
+  0; 22;  98;    0;           0;   14;           m; Wavelength spread (wavelength > 731 m) at low wave numbers 
+  0; 22;  99;    0;           0;    9; Degree_true; Mean direction at low wave numbers (wavelength > 731 m) 
+  0; 22; 100;    0;           0;    9;      Degree; Direction spread at low wave numbers(wavelength > 731 m) 
+  0; 22; 101;    0;           0;   31;     Numeric; Total energy (wavelength > 731m) at low wave numbers 
+  0; 22; 120;    0;           0;    5;  Code_Table; Tide station automated water level check 
+  0; 22; 121;    0;           0;    5;  Code_Table; Tide station manual water level check 
+  0; 22; 122;    0;           0;    5;  Code_Table; Tide station automated meteorological data check 
+  0; 22; 123;    0;           0;    5;  Code_Table; Tide station manual meteorological data check 
+  0; 22; 141;    2;           0;   15;           K; Sea-surface temperature (15-day running mean) 
+# Class 23 - Dispersal and transport 
+  0; 23;   1;    0;           0;    3;  Code_Table; Accident early notification � article applicable 
+  0; 23;   2;    0;           0;    5;  Code_Table; Activity or facility involved in incident 
+  0; 23;   3;    0;           0;    3;  Code_Table; Type of release  
+  0; 23;   4;    0;           0;    3;  Code_Table; Countermeasures taken near border 
+  0; 23;   5;    0;           0;    2;  Code_Table; Cause of incident  
+  0; 23;   6;    0;           0;    3;  Code_Table; Incident situation  
+  0; 23;   7;    0;           0;    3;  Code_Table; Characteristics of release 
+  0; 23;   8;    0;           0;    2;  Code_Table; State of current release  
+  0; 23;   9;    0;           0;    2;  Code_Table; State of expected release  
+  0; 23;  16;    0;           0;    2;  Code_Table; Possibility of significant chemical toxic health effect 
+  0; 23;  17;    6;           0;   20;     m3 s-1 ; Flow discharge of major recipient 
+  0; 23;  18;    0;           0;    3;  Code_Table; Release behaviour over time 
+  0; 23;  19;    0;      -15000;   17;           m; Actual release height 
+  0; 23;  21;    0;      -15000;   17;           m; Effective release height 
+  0; 23;  22;    0;           0;   24;           m; Distance of release point or site of incident 
+  0; 23;  23;    1;           0;   12;     m s-1  ; Main transport speed in the atmosphere 
+  0; 23;  24;    2;           0;   13;     m s-1  ; Main transport speed in water 
+  0; 23;  25;    2;           0;   13;     m s-1  ; Main transport speed in ground water 
+  0; 23;  27;    0;           0;    9; Degree_true; Main transport direction in the atmosphere 
+  0; 23;  28;    0;           0;    9; Degree_true; Main transport direction in water 
+  0; 23;  29;    0;           0;    9; Degree_true; Main transport direction in ground water 
+  0; 23;  31;    0;           0;    2;  Code_Table; Possibility that plume will encounter precipitation in State in which incident occurred 
+  0; 23;  32;    0;           0;    2;  Code_Table; Plume will encounter change in wind direction and/or speed flag 
+# Class 24 - Radiological elements 
+  0; 24;   1;  -11;           0;   28;         Bq*; Estimate of amount of radioactivity released up to specified time 
+  0; 24;   2;  -11;           0;   28;          Bq; Estimated maximum potential release 
+  0; 24;   3;    0;           0;    5;  Code_Table; Composition of release 
+  0; 24;   4;    0;           0;   16;   CCITT_IA5; Element name 
+  0; 24;   5;    0;           0;    9;     Numeric; Isotope mass 
+  0; 24;  11;    2;           0;   32;     mSv*/**; Dose 
+  0; 24;  12;    2;           0;   32;         mSv; Trajectory dose (defined location and expected time of arrival) 
+  0; 24;  13;    2;           0;   32;         mSv; Gamma dose in air along the main transport path (defined location and time period) 
+  0; 24;  21;    2;           0;   32;      Bq m-3; Air concentration (of named isotope type including gross beta) 
+  0; 24;  22;    2;           0;   32;      Bq 1-1; Concentration in precipitation (of names isotope type) 
+  0; 24;  23;    1;           0;   14;         s-1; Pulse rate of beta radiation 
+  0; 24;  24;    1;           0;   14;         s-1; Pulse rate of gamma radiation 
+# Class 25 - Processing information 
+  0; 25;   1;   -1;           0;    6;           m; Range-gate length 
+  0; 25;   2;    0;           0;    4;     Numeric; Number of gates averaged 
+  0; 25;   3;    0;           0;    8;     Numeric; Number of integrated pulses 
+  0; 25;   4;    0;           0;    2;  Code_Table; Echo processing 
+  0; 25;   5;    0;           0;    2;  Code_Table; Echo integration 
+  0; 25;   6;    0;           0;    3;  Code_Table; Z to R conversion 
+  0; 25;   7;    0;           0;   12;     Numeric; Z to R conversion factor 
+  0; 25;   8;    2;           0;    9;     Numeric; Z to R conversion exponent 
+  0; 25;   9;    0;           0;    4;  Flag_Table; Calibration method 
+  0; 25;  10;    0;           0;    4;  Code_Table; Clutter treatment 
+  0; 25;  11;    0;           0;    2;  Code_Table; Ground occultation correction (screening) 
+  0; 25;  12;    0;           0;    2;  Code_Table; Range attenuation correction 
+  0; 25;  13;    0;           0;    2;  Flag_Table; Bright-band correction 
+  0; 25;  14;    0;           0;   12;     Numeric; Azimuth clutter cut-off (see Note) 
+  0; 25;  15;    0;           0;    2;  Flag_Table; Radome attenuation correction 
+  0; 25;  16;    5;           0;    6;      dB m-1; Clear-air attenuation correction 
+  0; 25;  17;    0;           0;    2;  Flag_Table; Precipitation attenuation correction 
+  0; 25;  18;    7;           0;    6;     Numeric; A to Z law for attenuation factor 
+  0; 25;  19;    2;           0;    7;     Numeric; A to Z law for attenuation exponent 
+  0; 25;  20;    0;           0;    2;  Code_Table; Mean speed estimation 
+  0; 25;  21;    0;           0;    8;  Flag_Table; Wind computation enhancement 
+  0; 25;  30;    0;           0;    2;  Code_Table; Running mean sea-surface temperature usage 
+  0; 25;  32;    0;           0;    2;  Code_Table; Wind profiler mode information* 
+  0; 25;  33;    0;           0;    2;  Code_Table; Wind profiler submode information* 
+  0; 25;  34;    0;           0;    4;  Flag_Table; Wind profiler quality control test results*  
+  0; 25;  36;    0;           0;    4;  Code_Table; Atmospherics location method 
+  0; 25;  40;    0;           0;    4;  Code_Table; CO2 wind product derivation 
+  0; 25;  41;    0;           0;    2;  Code_Table; Moving platform direction reporting method 
+  0; 25;  42;    0;           0;    2;  Code_Table; Moving platform speed reporting method 
+  0; 25;  43;    4;           0;   15;           s; Wave sampling interval (time) 
+  0; 25;  44;    2;           0;   14;           m; Wave sampling interval (space) 
+  0; 25;  45;    0;           0;   21;  Flag_Table; HIRS channel combination 
+  0; 25;  46;    0;           0;    5;  Flag_Table; MSU channel combination 
+  0; 25;  47;    0;           0;    4;  Flag_Table; SSU channel combination 
+  0; 25;  48;    0;           0;   16;  Flag_Table; AMSU-A channel combination 
+  0; 25;  49;    0;           0;    6;  Flag_Table; AMSU-B channel combination 
+  0; 25;  51;    0;           0;    7;  Flag_Table; AVHRR channel combination 
+  0; 25;  53;    0;           0;   12;  Flag_Table; Observation quality 
+  0; 25;  60;    0;           0;   14;     Numeric; Software identification 
+  0; 25;  70;    0;           0;    4;     Numeric; Major frame count 
+  0; 25;  71;    0;           0;    5;     Numeric; Frame count 
+  0; 25;  75;    0;           0;    5;     Numeric; Satellite antenna corrections version number 
+  0; 25;  76;    8;           0;   30;     Log m-1; Log-10 of (Temperature-radiance central wavenumber) for ATOVS 
+  0; 25;  77;    5;     -100000;   18;     Numeric; Bandwidth correction coefficient 1 for ATOVS 
+  0; 25;  78;    5;           0;   17;     Numeric; Bandwidth correction coefficient 2 for ATOVS 
+  0; 25;  79;    4;           0;   24;       W m-2; Albedo-radiance solar filtered irradiance for ATOVS 
+  0; 25;  80;   10;           0;   14;           m; Albedo-radiance equivalent filter width for ATOVS 
+  0; 25;  85;    0;           0;    7;     Numeric; Fraction of clear pixels in HIRS FOV 
+  0; 25;  86;    0;           0;    2;  Code_Table; Depth correction indicator 
+  0; 25;  91;    3;      -18192;   13;          dB; Structure constant of the refraction index (cn2) 
+  0; 25;  92;    2;       28000;   14;       m s-1; Acoustic propagation velocity 
+  0; 25;  93;    0;           0;    8;  Flag_Table; RASS computation correction 
+# Class 26 - Non-coordinate location (time) 
+  0; 26;   1;    1;           0;   12;        Hour; Principal time of daily reading in UTC of maximum temperature 
+  0; 26;   2;    1;           0;   12;        Hour; Principal time of daily reading in UTC of minimum temperature 
+  0; 26;   3;    0;       -1440;   12;      Minute; Time difference 
+  0; 26;  10;    0;           0;   26;  Flag_Table; Hours included 
+# Class 27 - Non-coordinate location (horizontal - 1) 
+  0; 27;   1;    5;    -9000000;   25;      Degree; Latitude (high accuracy) 
+  0; 27;   2;    2;       -9000;   15;      Degree; Latitude (coarse accuracy) 
+  0; 27;   3;    2;       -9000;   15;      Degree; Alternate latitude 
+  0; 27;  20;    0;           0;   16;     Numeric; Satellite location counter 
+  0; 27;  21;    0;           0;   16;     Numeric; Satellite sublocation dimension 
+  0; 27;  31;    2; -1073741824;   31;           m; "In direction of 0 degrees longitude, distance from the Earth�s centre" 
+# Class 28 - Non-coordinate location (horizontal - 2) 
+  0; 28;   1;    5;   -18000000;   26;      Degree; Longitude (high accuracy) 
+  0; 28;   2;    2;      -18000;   16;      Degree; Longitude (coarse accuracy) 
+  0; 28;   3;    2;      -18000;   16;      Degree; Alternate longitude 
+  0; 28;  31;    2; -1073741824;   31;           m; "In direction 90 degrees East, distance from the Earth�s centre" 
+# Class 29 - Map data 
+  0; 29;   1;    0;           0;    3;  Code_Table; Projection type 
+  0; 29;   2;    0;           0;    3;  Code_Table; Coordinate grid type 
+# Class 30 - Image 
+  0; 30;   1;    0;           0;    4;     Numeric; Pixel value (4 bits) 
+  0; 30;   2;    0;           0;    8;     Numeric; Pixel value (8 bits) 
+  0; 30;   4;    0;           0;   16;     Numeric; Pixel value (16 bits) 
+  0; 30;  21;    0;           0;   12;     Numeric; Number of pixels per row 
+  0; 30;  22;    0;           0;   12;     Numeric; Number of pixels per column 
+  0; 30;  31;    0;           0;    4;  Code_Table; Picture type 
+  0; 30;  32;    0;           0;   16;  Flag_Table; Combination with other data 
+# Class 31 - Data description operator qualifiers 
+  0; 31;   0;    0;           0;    1;     Numeric; Short delayed descriptor replication factor 
+  0; 31;   1;    0;           0;    8;     Numeric; Delayed descriptor replication factor 
+  0; 31;   2;    0;           0;   16;     Numeric; Extended delayed descriptor replication factor 
+  0; 31;  11;    0;           0;    8;     Numeric; Delayed descriptor and data repetition factor 
+  0; 31;  12;    0;           0;   16;     Numeric; Extended delayed descriptor and data repetition factor 
+  0; 31;  21;    0;           0;    6;  Code_Table; Associated field significance 
+  0; 31;  31;    0;           0;    1;  Flag_Table; Data present indicator 
+# Class 33 - Quality information 
+  0; 33;   2;    0;           0;    2;  Code_Table; Quality information 
+  0; 33;   3;    0;           0;    3;  Code_Table; Quality information 
+  0; 33;   7;    0;           0;    7;           %; Per cent confidence 
+  0; 33;  20;    0;           0;    3;  Code_Table; Quality control indication of following value 
+  0; 33;  21;    0;           0;    2;  Code_Table; Quality of following value 
+  0; 33;  22;    0;           0;    2;  Code_Table; Quality of buoy satellite transmission 
+  0; 33;  23;    0;           0;    2;  Code_Table; Quality of buoy location 
+  0; 33;  24;    0;           0;    4;  Code_Table; Station elevation quality mark (for mobile stations) 
+  0; 33;  25;    0;           0;    3;  Code_Table; ACARS interpolated values 
+  0; 33;  26;    0;           0;    6;  Code_Table; Moisture quality 
+  0; 33;  27;    0;           0;    3;  Code_Table; Location quality class (range of radius of 66 % confidence) 
+  0; 33;  30;    0;           0;   24;  Flag_Table; Scan line status flags for ATOVS 
+  0; 33;  31;    0;           0;   24;  Flag_Table; Scan line quality flags for ATOVS 
+  0; 33;  32;    0;           0;   24;  Flag_Table; Channel quality flags for ATOVS 
+  0; 33;  33;    0;           0;   24;  Flag_Table; Field of view quality flags for ATOVS 
+  0; 33;  35;    0;           0;    4;  Code_Table; Manual/automatic quality control 
+  0; 33;  36;    0;           0;    7;           %; Nominal confidence threshold 
+  0; 33;  37;    0;           0;   20;  Flag_Table; Wind correlation error 
+  0; 33;  40;    0;           0;    7;           %; Confidence interval 
+  0; 33;  41;    0;           0;    2;  Code_Table; Attribute of following value 
+# Class 35 - Data monitoring information 
+  0; 35;   0;    0;           0;   10;  Code_Table; FM and regional code number 
+  0; 35;   1;    0;           0;    3;  Code_Table; Time-frame for monitoring 
+  0; 35;  11;    0;           0;   14;     Numeric; Number of reports actually received 
+  0; 35;  21;    0;           0;   48;   Character; Bulletin being monitored (TTAAii) 
+  0; 35;  22;    0;           0;   48;   Character; Bulletin being monitored (YYGGgg) 
+  0; 35;  30;    0;           0;    4;  Code_Table; Discrepancies in the availability of expected data 
+  0; 35;  31;    0;           0;    7;  Code_Table; Qualifier on monitoring results 
+  0; 35;  32;    0;           0;    4;  Code_Table; Cause of missing data 
+  0; 35;  33;    0;           0;    7;  Code_Table; Observation and collection deficiencies 
+  0; 35;  34;    0;           0;    3;  Code_Table; Statistical trends for availability of data (during the survey period(s)) 
diff --git a/data/tables/B3M-000-009-D b/data/tables/B3M-000-009-D
new file mode 100644
index 0000000..8f1f849
--- /dev/null
+++ b/data/tables/B3M-000-009-D
@@ -0,0 +1,2226 @@
+#
+# WMO source file name = BufrTabD-11-2000.txt
+# Master Table D Version 9
+#
+#-----------------------------------------------------
+# F X Y --> Table D descriptor being defined
+#      F X Y --> 
+#      F X Y --> descriptors defining sequence for
+#      F X Y --> corresponding Table D descriptor
+#      -1 --> end of sequence designator
+#------------------------------------------------------
+#  Category 00 - BUFR table entries sequences
+  3   0   2
+      0   0   2  "Table A category, line 1"
+      0   0   3  "Table A category, line 2"
+     -1
+  3   0   3
+      0   0  10  "F,  part descriptor"
+      0   0  11  "X,  part descriptor"
+      0   0  12  "Y,  part descriptor"
+     -1
+  3   0   4
+      3   0   3
+      0   0  13  "Element name, line 1"
+      0   0  14  "Element name, line 2"
+      0   0  15  Units name
+      0   0  16  Units scale sign
+      0   0  17  Units scale
+      0   0  18  Units reference sign
+      0   0  19  Units reference value
+      0   0  20  Element data width
+     -1
+  3   0  10
+      3   0   3  Table D descriptor to be defined
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Delayed descriptor replication factor
+      0   0  30  Descriptor defining sequence
+     -1
+#  Category 01 - Location and Identification sequences
+  3   1   1
+      0   1   1  WMO block number
+      0   1   2  WMO station number
+     -1
+  3   1   2
+      0   1   3  WMO Region number
+      0   1   4  WMO Region sub-area
+      0   1   5  Buoy/platform identifier
+     -1
+  3   1   3
+      0   1  11  Ship's call sign
+      0   1  12  Direction of motion of moving observing platform
+      0   1  13  Speed of motion of moving observing platform
+     -1
+  3   1  11
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+     -1
+  3   1  12
+      0   4   4  Hour
+      0   4   5  Minute
+     -1
+  3   1  13
+      0   4   4  Hour
+      0   4   5  Minute
+      0   4   6  Second
+     -1
+  3   1  21
+      0   5   1  Latitude  - high accuracy
+      0   6   1  Longitude - high accuracy
+     -1
+  3   1  22
+      0   5   1  Latitude - high accuracy
+      0   6   1  Longitude - high accuracy
+      0   7   1  Height of station
+     -1
+  3   1  23
+      0   5   2  Latitude - coarse accuracy
+      0   6   2  Longitude - coarse accuracy
+     -1
+  3   1  24
+      0   5   2  Latitude - coarse accuracy
+      0   6   2   - coarse accuracy
+      0   7   1  Height of station
+     -1
+  3   1  25
+      3   1  23  Latitude and longitude (coarse accuracy)
+      0   4   3  Day
+      3   1  12  Time
+     -1
+  3   1  26
+      3   1  21  Latitude and longitude (high accuracy)
+      0   4   3
+      0   4   3  (Time period in days)
+      0   4   4
+      0   4   4  (Time period in hours)
+      0   4   5
+      0   4   5  (Time period in minutes)
+     -1
+  3   1  31
+      3   1   1  WMO block and station number
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  22  "Latitude and longitude (high  accuracy), height of station"
+     -1
+  3   1  32
+      3   1   1  WMO block and station number
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  24  "Latitude and longitude (coarse accuracy), height of station"
+     -1
+#  (Buoy/platform � fixed)
+  3   1  33
+      0   1   5  Buoy/platform identifier
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  21  Latitude and longitude (high accuracy)
+     -1
+#  (Buoy/platform � fixed)
+  3   1  34
+      0   1   5  Buoy/platform identifier
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+     -1
+#  (Buoy/platform � moving)
+  3   1  35
+      0   1   5  Buoy/platform identifier
+      0   1  12  Direction of motion of moving observing platform
+      0   1  13  Speed of motion of moving observing platform
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+     -1
+#  (Ship)
+  3   1  36
+      3   1   3  Ship's call sign and motion
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+     -1
+#  (Land station for vertical soundings)
+  3   1  37
+      3   1   1  WMO block and station number
+      0   2  11  Radiosonde type
+      0   2  12  Radiosonde computational method
+      3   1  11  Date
+      3   1  12  Time
+      3   1  22  "Latitude and longitude (high accuracy), height of station"
+     -1
+#  (Land station for vertical soundings)
+  3   1  38
+      3   1   1  WMO block and station number
+      0   2  11  Radiosonde type
+      0   2  12  Radiosonde computational method
+      3   1  11  Date
+      3   1  12  Time
+      3   1  24  "Latitude and longitude (coarse accuracy), height of station"
+     -1
+#  (Ship for vertical soundings)
+  3   1  39
+      3   1   3  Ship's call sign and motion
+      0   2  11  Radiosonde type
+      0   2  12  Radiosonde computational method
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+     -1
+  3   1  40
+      3   1   3  Ship's call sign and motion
+      0   2  11  Radiosonde type
+      0   2  12  Radiosonde computational method
+      3   1  11  Date
+      3   1  12  Time
+      3   1  24  "Latitude and longitude (coarse accuracy), height of station"
+     -1
+  3   1  41
+      0   1   7  Satellite identifier
+      0   2  21  Satellite instrument data used in processing
+      0   2  22  Satellite data processing technique used
+      3   1  11  Date
+      3   1  12  Time
+     -1
+  3   1  42
+      3   1  41  "Satellite identifier, data used, and data processing technique; date/time"
+      3   1  21  "Latitude, longitude"
+     -1
+  3   1  43
+      0   1   7  Satellite identifier
+      0   2  23  Cloud motion computational method
+      3   1  11  Date
+      3   1  13  Time
+      3   1  21  "Latitude, longitude"
+     -1
+  3   1  44
+      0   1   7  Satellite identifier
+      0   2  24  Integrated mean humidity computational method
+      3   1  11  Date
+      3   1  13  Time
+      3   1  21  "Latitude, longitude"
+     -1
+#  (Satellite location and velocity)
+  3   1  45
+      3   1  11  "Year, month, day"
+      3   1  12  "Time (hour, minute)"
+      2   1 138  Change width to 16 bits
+      2   2 131  Change scale to 3
+      0   4   6  Second
+      2   1   0  Change width back to Table B
+      2   2   0  Change scale back to Table B
+      3   4  30  Location relative to the Earth�s centre
+      3   4  31  Velocity relative to the Earth�s centre
+     -1
+  3   1  46
+      0   1   7  Satellite identifier
+      0   1  12  Direction of motion of moving observing platform
+      0   2  48  Satellite sensor indicator
+      0  21 119  Wind scatterometer geophysical model function
+      0  25  60  Software identification
+      2   2 124  Change scale
+      0   2  26  Cross-track resolution
+      0   2  27  Along-tract resolution
+      2   2   0  Change scale back to Table B
+      0   5  40  Orbit number
+     -1
+#  (ERS product header)
+  3   1  47
+      0   1   7  Satellite identifier
+      0  25  60  Software identification
+      0   1  33  Originating/generating centre
+      0   1  34  Originating/generating sub-centre
+      0   1  12  Direction of motion of moving observation platform
+      3   1  45  Satellite location and velocity
+      0   2  21  Satellite instrument data used in processing
+      3   1  11  "Date (year, month, day)"
+      3   1  12  "Time (hour, minute)"
+      2   1 138  Change bit width to 16 bits
+      2   2 131  Change scale to 3
+      0   4   6  Second
+      2   1   0  Change width back to Table B
+      2   2   0  Change scale back to Table B
+      3   1  23  "Location (latitude, longitude)"
+     -1
+#  (Radar parameters)
+  3   1  48
+      0   2 104  Antenna polarization
+      0   2 121  Mean frequency
+      0   2 113  Number of azimuth looks
+      0   2  26  Cross-track resolution
+      0   2  27  Along-track resolution
+      0   2 111  Radar incidence angle
+      0   2 140  Satellite radar beam azimuth angle
+      2   2 127  Change scale to �1
+      0   1  13  Radar platform velocity
+      2   2 126  Change scale to �2
+      0   7   1  Radar platform altitude
+      2   2   0  Change scale to Table B
+      0  25  10  Clutter treatment
+      0  21  64  Clutter noise estimate
+     -1
+#  (Radar beam data)
+  3   1  49
+      0   2 111  Radar incidence angle
+      0   2 112  Radar look angle
+      0  21  62  Backscatter
+      0  21  63  Radiometric resolution (Noise value)
+      0  21  65  Missing packet counter
+     -1
+  3   1  51
+      0   1   6  Aircraft identifier
+      0   2  61  Navigational system
+      3   1  11  Date
+      3   1  12  Time
+      3   1  21  "Latitude, longitude"
+      0   8   4  Phase of aircraft flight
+     -1
+  3   1  55
+      0   1   5  Buoy/platform identifier
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  21  Latitude and longitude (high accuracy)
+      0   1  12  Direction of motion of moving observing platform
+      0   1  14  Platform drift speed (high precision)
+     -1
+#  (Radar location(s))
+  3   1  62
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   1   1  WMO block and station number
+     -1
+#  (ACARS identification)
+  3   1  65
+      0   1   6  Aircraft flight number (see Note)
+      0   1   8  Aircraft registration number (see Note)
+      0   2   1  Type of station
+      0   2   2  Type of instrumentation for wind measurement
+      0   2   5  Precision of temperature observation
+      0   2  62  Type of aircraft data relay system
+      0   2  70  Original specification of latitude/longitude
+      0   2  65  ACARS ground receiving station
+     -1
+#  (ACARS location)
+  3   1  66
+      3   1  11  "Year, month, day"
+      3   1  13  "Hour, minute, second"
+      3   1  23  Latitude and longitude (coarse accuracy)
+      0   7   4  Pressure
+      0   2  64  Aircraft roll angle quality
+      0   8   4  Phase of aircraft flight
+     -1
+#  (Satellite identifier/Generating resolution)
+  3   1  71
+      0   1   7  Satellite identifier
+      0   1  31  Generating centre
+      0   2  20  Satellite classification
+      0   2  28  Segment size at nadir in X direction
+      0   2  29  Segment size at nadir in Y direction
+     -1
+#  (Satellite identification)
+  3   1  72
+      3   1  71  "Satellite identification, Generation resolution"
+      3   1  11  Date
+      3   1  13  Time
+      3   1  21  "Latitude, longitude"
+     -1
+#  Category 02 - Meteorological sequences common to surface data
+  3   2   1
+      0  10   4  Pressure (at station level)
+      0  10  51  Pressure reduced to mean sea level
+      0  10  61  3-hour pressure change
+      0  10  63  Characteristic of pressure tendency
+     -1
+#  (High altitude station)
+  3   2   2
+      0  10   4  Pressure (at station level)
+      0   7   4  Pressure level
+      0  10   3  Geopotential of pressure level
+      0  10  61  3-hour pressure change
+      0  10  63  Characteristic of pressure tendency
+     -1
+  3   2   3
+      0  11  11  Wind direction (10 m)
+      0  11  12  Wind speed (10 m)
+      0  12   4  Temperature (2 m)
+      0  12   6  Dew point (2 m)
+      0  13   3  Relative humidity
+      0  20   1  Horizontal visibility
+      0  20   3  Present weather
+      0  20   4  Past weather (1)
+      0  20   5  Past weather (2)
+     -1
+#  (General cloud information)
+  3   2   4
+      0  20  10  Cloud cover (total)
+      0   8   2  Vertical significance
+      0  20  11  Cloud amount
+      0  20  13  Height of base of cloud
+      0  20  12  Cloud type
+      0  20  12  Cloud type
+      0  20  12  Cloud type
+     -1
+  3   2   5
+      0   8   2  Vertical significance
+      0  20  11  Cloud amount
+      0  20  12  Cloud type
+      0  20  13  Height of base of cloud
+     -1
+  3   2   6
+      0  10   4  Pressure (at station level)
+      0  10  51  Pressure reduced to mean sea level
+      0  10  62  24-hour pressure change
+      0  10  63  Characteristic of pressure tendency
+     -1
+#  (Low altitude station)
+  3   2  11
+      3   2   1  Pressure and pressure change
+      3   2   3  "Wind, temperature, humidity, visibility, weather"
+      3   2   4  Significant cloud layer
+     -1
+#  (High altitude station)
+  3   2  12
+      3   2   2  Pressure and pressure change
+      3   2   3  "Wind, temperature, humidity, visibility, weather"
+      3   2   4  Significant cloud information
+     -1
+  3   2  13
+      3   2   6  Pressure and pressure change
+      3   2   3  "Wind, temperature, humidity, visibility, weather"
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Delayed descriptor replication factor
+      3   2   5  Cloud layer information
+     -1
+  3   2  21
+      0  22   1  Direction of waves
+      0  22  11  Period of waves
+      0  22  21  Height of waves
+     -1
+  3   2  22
+      0  22   2  Direction of wind waves
+      0  22  12  Period of wind waves
+      0  22  22  Height of wind waves
+     -1
+  3   2  23
+      0  22   3  Direction of swell waves
+      0  22  13  Period of swell waves
+      0  22  23  Height of swell waves
+     -1
+  3   2  24
+      3   2  22  Wind waves
+      1   1   2  Replicate 1 descriptor 2 times
+      3   2  23  Swell waves (2 systems of swell)
+     -1
+  3   2  51
+      0  10   4  Pressure
+      0  10  51  Pressure reduced to mean sea level
+      0   7   4  Pressure (vertical location)
+      0  10   3  Geopotential
+      0  12   4  Dry-bulb temperature at 2 m
+      0  12  51  Standard deviation temperature
+      0  12  16  "Maximum temperature at 2 m, past 24 hours"
+      0  12  17  "Minimum temperature at 2 m, past 24 hours"
+      0  13   4  Vapour pressure
+      1   2   4  Replicate 2 descriptors 4 times
+      0   8  51  Qualifier for number of missing values in calculation of statistic
+      0   8  20  Total number of missing entities (with respect to accumulation or average)
+     -1
+#  Category 03 - Meteorological sequences common to vertical soundings data
+  3   3   1
+      0   7   3  Geopotential
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3   2
+      0   7   4  Pressure
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3   3
+      0   7   4  Pressure
+      0  10   3  Geopotential
+      0  12   1  Temperature
+      0  12   3  Dew point
+     -1
+  3   3   4
+      0   7   4  Pressure
+      0  10   3  Geopotential
+      0  12   1  Temperature
+      0  12   3  Dew point
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3  11
+      0   7   3  Geopotential
+      0   8   1  Vertical sounding significance
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3  12
+      0   7   4  Pressure
+      0   8   1  Vertical sounding significance
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3  13
+      0   7   4  Pressure
+      0   8   1  Vertical sounding significance
+      0  10   3  Geopotential
+      0  12   1  Temperature
+      0  13   3  Relative humidity
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3  14
+      0   7   4  Pressure
+      0   8   1  Vertical sounding significance
+      0  10   3  Geopotential
+      0  12   1  Temperature
+      0  12   3  Dew point
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3  21
+      0   7   4  Pressure (1)
+      0   7   4  Pressure (2)     defines layer
+      2   4   7  Add associated field of 7 bits
+      0  31  21  Additional field significance
+     -1
+  3   3  22
+      3   3  21  "Layer, quality"
+      0  10   3  Geopotential (layer mean thickness)
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  23
+      3   3  21  "Layer, quality"
+      0  12   1  Temperature (layer mean)
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  24
+      3   3  21  "Layer, quality"
+      0  13  16  Precipitation water
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  25
+      0   2  25  Satellite channel
+      2   4   7  Add associated field of 7 bits
+      0  31  21  Additional field significance
+      0  12  63  Brightness temperature
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  26
+      0   7   4  Pressure
+      0   8   3  Vertical significance
+      2   4   7  Add associated field of 7 bits
+      0  31  21  Additional field significance
+      0  12   1  Temperature
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  27
+      0   7   4  Pressure
+      2   4   7  Add associated field of 7 bits
+      0  31  21  Additional field significance
+      0  10   3  Geopotential
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  31
+      0   7   4  Pressure
+      0   8   3  Vertical significance (base of sounding)
+      0   7  21  Elevation (local zenith)
+      0   7  22  Solar elevation (solar zenith)
+      0   8  12  Land/sea qualifier
+      0  12  61  Skin temperature
+     -1
+  3   3  32
+      0  20  11  Cloud amount
+      0  20  16  Pressure at top of cloud
+     -1
+  3   3  33
+      0  20  10  Cloud cover (total)
+      0  20  16  Pressure at the top of cloud
+     -1
+#  (Wind sequence)
+  3   3  41
+      0   2 152  Geostationary satellite instrument used
+      0   2  23  Cloud motion computational method
+      0   7   4  Pressure
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+      0   2 153  Satellite channel centre frequency
+      0   2 154  Satellite channel band width
+      0  12  71  Coldest cluster T
+     -1
+#  Category 04 - Meteorological sequences common to satellite observations
+  3   4   1
+      0   8   3  Vertical significance
+      0  10   4  Pressure
+      0  12   1  Temperature
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   4   2
+      0   8   3  Vertical significance
+      0  10   4  Pressure
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   4   3
+      0   8   3  Vertical significance
+      0  12   1  Temperature
+     -1
+  3   4   4
+      0   8   3  Vertical significance
+      0  10   4  Pressure
+      0  20  10  Cloud cover (total)
+      0  12   1  Temperature
+     -1
+  3   4   5
+      0   2  24  Integrated mean humidity computational method
+      0   7   4  Pressure(1)
+      0   7   4  Pressure (2)    defines layer
+      0  13   3  Relative humidity
+     -1
+  3   4   6
+      0  14   1  Outgoing long-wave radiation
+      0  14   1  Incoming long-wave radiation
+      0  14   3  Outgoing short-wave radiation
+     -1
+#  (GOES-I/M info)
+  3   4  11
+      0   2 163  Height assignment method
+      0   2 164  Tracer correlation method
+      0   8  12  Land/sea qualifier
+      0   7  24  Satellite zenith angle
+      0   2  57  Origin of first guess information
+      0   8  21  Time significance
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+      0   4   4  Hour
+      0   8  21  Time significance
+      0   4  24  Time period or displacement
+      1  10   4  Replicate 10 descriptors 4 times
+      0   8  21  Time significance
+      0   4   4  Hour
+      0   4   5  Minute
+      0   4   6  Second
+      0   8  21  Time significance
+      0   4   4  Hour
+      0   4   5  Minute
+      0   4   6  Second
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+      1   3  10  Replicate 3 descriptors 10 times
+      0   2 163  Height assignment method
+      0   7   4  Pressure
+      0  12   1  Temperature
+     -1
+#  (Location of platform)
+  3   4  30
+      0  27  31  "In direction of 0 degree longitude, distance from the Earth�s centre"
+      0  28  31  "In direction of 90 degrees East longitude, distance from the Earth�s centre"
+      0  10  31  "In direction of North Pole, distance from Earth�s centre"
+     -1
+#  (Speed of platform)
+  3   4  31
+      0   1  41  Absolute platform velocity � first component
+      0   1  42  Absolute platform velocity � second component
+      0   1  43  Absolute platform velocity � third component
+     -1
+#  (Cloud fraction)
+  3   4  32
+      0   2 153  Satellite channel centre frequency
+      0   2 154  Satellite channel band width
+      0  20  81  Cloud amount in segment
+      0  20  82  Amount segment cloud free
+      0  20  12  Cloud type
+     -1
+#  (Clear sky radiance)
+  3   4  33
+      0   2 152  Satellite instrument used in data processing
+      0   2 166  Radiance type
+      0   2 167  Radiance computational method
+      0   2 153  Satellite channel centre frequency
+      0   2 154  Satellite channel band width
+      0  12  75  Spectral radiance
+      0  12  76  Radiance
+      0  12  63  Brightness temperature
+     -1
+#  0
+  3   4  34
+      1   2   4  Replicating next two descriptors 4 times
+      0  27   1  Latitude (high accuracy)
+      0  28   1  Longitude (high accuracy)
+      0   7  22  Solar elevation
+      0   5  43  Field of view number
+      0  20  10  Cloud cover (total)
+      0  20  16  Pressure at top of cloud
+      0  33   3  Quality information table
+      0  10  40  Number of retrieved layers
+     -1
+#  Category 06 - Meteorological or oceanographic sequences common to oceanographic observations
+  3   6   1
+      0   2  32  Indicator for digitization
+      1   2   0  Delayed replication of 2 descriptors
+      0  31   1  Replication factor
+      0   7  62  Depth below sea surface
+      0  22  42  Subsurface sea temperature
+     -1
+  3   6   2
+      0   2  31  Method of current measurement
+      0  22   4  Direction of current
+      0  22  31  Speed of current
+     -1
+  3   6   3
+      0   2   2  Wind instrumentation
+      0  11  11  Wind direction (10 m)
+      0  11  12  Wind speed (10 m)
+      0  12   4  Dry-bulb temperature (2 m)
+     -1
+  3   6   4
+      0   2  32  Indicator for digitization
+      0   2  33  Method of salinity/depth measurement
+      1   3   0  Delayed replication of 3 descriptors
+      0  31   1  Replication factor
+      0   7  62  Depth below sea surface
+      0  22  43  Subsurface sea temperature
+      0  22  62  Salinity
+     -1
+  3   6   5
+      0   2  31  Method of current measurement
+      1   3   0  Delayed replication of 3 descriptors
+      0  31   1  Replication factor
+      0   7  62  Depth below sea surface
+      0  22   4  Direction of current
+      0  22  31  Speed of current
+     -1
+#  (Under water sounding (optional) parameters)
+  3   6   6
+      3   6   3  Surface wind and temperature
+      3   6   2  Current
+      0  22  63  Total water depth
+     -1
+#  (Buoy spare block parameters)
+  3   6   7
+      0   1  12  Direction of motion of moving observing platform
+      0   1  14  Platform drift speed (high precision)
+      3   6   8  Buoy instrumentation
+      0   4  24  Time period
+      0  27   3  Alternate latitude
+      0  28   3  Alternate longitude
+     -1
+#  (Buoy instrumentation parameters)
+  3   6   8
+      0   2  34  Drogue type
+      0   2  35  Cable length
+      0   2  36  Buoy type
+     -1
+  3   6  23
+      0   1  15  Station or site name
+      3   1  23  "Latitude, longitude"
+      3   1  11  "Year, month, day"
+      3   1  12  "Hour, minute"
+      0  22  38  Tidal level with respect to local chart datum
+      0  22  39  Meteorological residual tidal elevation
+      0  22 120  Tide station automated water level check
+      0  22 121  Tide station manual water level check
+     -1
+#  Category 07 - Surface report sequences (land)
+#  (Low altitude station)
+  3   7   1
+      3   1  31  "Identification, type, date/time, position (high accuracy), height"
+      3   2  11  Basic surface report
+     -1
+#  (Low altitude station)
+  3   7   2
+      3   1  32  "Identification, type, date/time, position (coarse accuracy), height"
+      3   2  11  Basic surface report
+     -1
+#  (Low altitude station)
+  3   7   3
+      3   7   1  Location (high accuracy) and basic report
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   2   5  Cloud layer information
+     -1
+#  (Low altitude station)
+  3   7   4
+      3   7   2  Location (coarse accuracy) and basic report
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   2   5  Cloud layer information
+     -1
+#  (Low altitude station)
+  3   7   5
+      3   7   1  Location (high accuracy) and basic report
+      1   1   4  Replicate 1 descriptor 4 times
+      3   2   5  Cloud layer information (4 layers)
+     -1
+#  (Low altitude station)
+  3   7   6
+      3   7   2  Location (coarse accuracy) and basic report
+      1   1   4  Replicate 1 descriptor 4 times
+      3   2   5  Cloud layer information (4 layers)
+     -1
+#  (High altitude station)
+  3   7   7
+      3   1  31  "Identification, type, date/time, position (high accuracy), height"
+      3   2  12  Basic surface report
+     -1
+#  (High altitude station)
+  3   7   8
+      3   1  32  "Identification, type, date/time, position (coarse accuracy), height"
+      3   2  12  Basic surface report
+     -1
+  3   7   9
+      3   1  31  "Identification, type, date/time, position (high accuracy), height"
+      3   2  13  Basic surface report
+     -1
+#  (Main part of data for representation of METAR/SPECI code in BUFR)
+  3   7  11
+      0   1  63  ICAO location indicator - CCCC
+      0   2   1  Type of station -(AUTO)
+      3   1  11  "Year, month, day (YY)"
+      3   1  12  "GG, gg"
+      3   1  24  "Latitude-longitude (coarse accuracy), height of station"
+      0   7   6  Height above station (= height of an anemometer)
+      0  11   1  Wind direction - ddd
+      0  11  16  Extreme counterclockwise wind direction of a variable wind - dndndn
+      0  11  17  Extreme clockwise wind direction of a variable wind - dxdxdx
+      0  11   2  Wind speed - ff
+      0  11  41  Maximum wind speed (gusts) - fmfm
+      0   7   6  Height above station (= height of a thermometer)
+      0  12   1  Temperature - T�T�
+      0  12   3  Dew-point temperature - T�dT�d
+      0  10  52  Altimeter setting (QNH) - PHPHPHPH
+      0  20   9  General Weather Indicator TAF/METAR
+     -1
+#  (DvVVVV)
+  3   7  12
+      1   3   0  Delayed replication of 3 descriptors
+      0  31   1  Number of replication (up to 3)
+      0   8  23  First order statistics
+      0   5  21  Direction of visibility observed - Dv
+      0  20   1  Horizontal visibility - WW
+     -1
+#  (DRDRVRVRVRVR)
+  3   7  13
+      1   6   0  Delayed replication of 6 descriptors
+      0  31   1  Number of replication (up to 4)
+      0   1  64  Runway designator - DrDr
+      0   8  14  Qualification for runway visual range
+      0  20  61  Runway visual range - VrVrVrVr
+      0   8  14  Qualification for runway visual range
+      0  20  61  Runway visual range - VrVrVrVr
+      0  20  18  Tendency of runway visual range
+     -1
+#  (w�w�)
+  3   7  14
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Number of replication (up to 3)
+      0  20  19  Significant present weather - w�w�
+     -1
+#  (Clouds group(s))
+  3   7  15
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Number of replication
+      3   2   5  "(NsNsNs, CC, hshshs)"
+      0  20   2  Vertical visibility - VVhshshs
+     -1
+#  (REw�w�)
+  3   7  16
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Number of replication (up to 3)
+      0  20  20  Significant recent weather phenomena - REw�w�
+     -1
+#  (Wind shear on runways(s))
+  3   7  17
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Number of replication
+      0  11  70  Runway designator of the runway affected by wind shear (including ALL) - WS WYDRDR
+     -1
+#  (Trend-type landing forecast)
+  3   7  18
+      0   8  16  Change qualifier of a trend-type - TTTTT
+      1   2   0  Delayed replication of 2 descriptors
+      0  31   1  Number of replication (up to 2)
+      0   8  17  Qualifier of the time when the forecast - TT
+      3   1  12  "GG, gg"
+      1   4   0  Delayed replication of 4 descriptor
+      0  31   1  Number of replication (up to 1)
+      0   7   6  Height above station
+      0  11   1  Wind direction - ddd
+      0  11   2  Wind speed - ff
+      0  11  41  Maximum wind speed (gusts) - fmfm
+      0  20   9  General Weather Indicator
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Number of replication (up to 1)
+      0  20   1  Horizontal visibility - WW
+      3   7  14  w�w�
+     -1
+#  (Short METAR/SPECI)
+  3   7  20
+      3   7  11  Main part of data
+      3   7  14  w�w�
+      3   7  16  REw�w�
+     -1
+#  (Total sequence for representation of METAR/SPECI code in BUFR)
+  3   7  21
+      3   7  11  Main part of data
+      3   7  12  DvVVVV
+      3   7  13  DRDRVRVRVRVR
+      3   7  14  w�w�
+      3   7  15  Clouds group(s)
+      3   7  16  REw�w�
+      3   7  17  Wind shear on runway(s)
+      3   7  18  Trend-type landing forecast
+      3   7  15  Clouds group(s)
+     -1
+#  Category 08 - Surface report sequences (sea)
+#  (Buoy/platform � fixed)
+  3   8   1
+      3   1  33  "Identification, type, date/time, position (high accuracy)"
+      3   2  11  Basic surface report
+      0  22  42  Sea-surface temperature
+     -1
+#  (Buoy/platform � fixed)
+  3   8   2
+      3   1  34  "Identification, type, date/time, position (coarse accuracy)"
+      3   2  11  Basic surface report
+      0  22  42  Sea-surface temperature
+     -1
+#  (Buoy/platform � moving)
+  3   8   3
+      3   1  35  "Identification, movement, type, date/time, position (coarse accuracy)"
+      3   2  11  Basic surface report
+      0  22  42  Sea-surface temperature
+     -1
+#  (Ship)
+  3   8   4
+      3   1  36  "Identification, movement, type, date/time, position (coarse accuracy)"
+      3   2  11  Basic surface report
+      0  22  42  Sea-surface temperature
+     -1
+  3   8   5
+      3   8   4  Basic ship report
+      3   2  24  Wind waves and swell waves
+     -1
+#  (Buoy Section 1 optional parameters)
+  3   8   6
+      0  10   4  Pressure
+      0  10  61  3-hour pressure change
+      0  10  63  Characteristic of pressure tendency
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+      0  12   4  Dry-bulb temperature at 2 m
+      0  13   3  Relative humidity
+      0  22  42  Sea temperature
+     -1
+  3   8   7
+      3   1  55  "Identification, movement type, date/time, position (high accuracy)"
+      3   2  11  Basic surface report
+      0   7  62  Depth below sea/water surface
+      0  22  42  Sea/water temperature
+     -1
+#  Category 09 - Vertical sounding sequences (conventional data)
+#  (Vertical wind profile)
+  3   9   1
+      3   1  37  "Identification, etc. (land station, high accuracy position)"
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  11  Winds at heights
+     -1
+#  (Vertical wind profile)
+  3   9   2
+      3   1  38  "Identification, etc. (land station, coarse accuracy position)"
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  11  Winds at heights
+     -1
+#  (Vertical wind profile)
+  3   9   3
+      3   1  37  "Identification, etc. (land station, high accuracy position)"
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  12  Winds at pressure levels
+     -1
+#  (Vertical wind profile)
+  3   9   4
+      3   1  38  "Identification, etc. (land station, coarse accuracy position)"
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  12  Winds at pressure levels
+     -1
+#  (Vertical sounding with relative humidity)
+  3   9   5
+      3   1  37  "Identification, etc. (land station, high accuracy position)"
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  13  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical sounding with relative humidity)
+  3   9   6
+      3   1  38  "Identification, etc. (land station, coarse  accuracy position)"
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  13  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical sounding with dew-point data)
+  3   9   7
+      3   1  37  "Identification, etc. (land station, high accuracy position)"
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  14  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical sounding with dew-point data)
+  3   9   8
+      3   1  38  "Identification, etc. (land station, coarse accuracy position)"
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  14  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical wind profile)
+  3   9  11
+      3   1  39  "Ship's identification, etc."
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  11  Winds at heights
+     -1
+#  (Vertical wind profile)
+  3   9  12
+      3   1  39  "Ship's identification, etc."
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  12  Winds at pressure levels
+     -1
+#  (Vertical sounding with relative humidity)
+  3   9  13
+      3   1  39  "Ship's identification, etc."
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  13  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical sounding with dew-point data)
+  3   9  14
+      3   1  39  "Ship's identification, etc."
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  14  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical wind profile)
+  3   9  15
+      3   1  40  "Ship's identification, etc."
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  11  Winds at heights
+     -1
+#  (Vertical wind profile)
+  3   9  16
+      3   1  40  "Ship's identification, etc."
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  12  Winds at pressure levels
+     -1
+#  (Vertical sounding with relative humidity)
+  3   9  17
+      3   1  40  "Ship's identification, etc."
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  13  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical sounding with dew-point data)
+  3   9  18
+      3   1  40  "Ship's identification, etc."
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  14  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Wind profiler � wind data sounding)
+  3   9  19
+      3   1  31  "Identification, etc."
+      0   2   3  Type of measuring equipment used
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  11  Winds at heights
+     -1
+#  (Wind profiler � Cartesian coordinates)
+  3   9  20
+      3   1  31  "Identification, etc."
+      0   2   3  Type of measuring equipment used
+      1   4   0  Delayed replication of 4 descriptors
+      0  31   1  Replication factor
+      0   7   3  Geopotential
+      0  11   3  u-component
+      0  11   4  v-component
+      0  11   5  w-component
+     -1
+#  Category 10 - Vertical sounding sequences (satellite data)
+#  (Satellite � brightness temperature)
+  3  10   1
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  32  Cloud
+      1   1  26  Replicate 1 descriptor 26 times
+      3   3  25  Satellite channel and brightness temperature
+     -1
+#  (Satellite � low level)
+  3  10   2
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  32  Cloud
+      1   1   9  Replicate 1 descriptor 9 times
+      3   3  23  Layer mean temperature
+     -1
+#  (Satellite � high level)
+  3  10   3
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  32  Cloud
+      1   1   6  Replicate 1 descriptor 6 times
+      3   3  23  Layer mean temperature
+     -1
+#  (Satellite � precipitable water)
+  3  10   4
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  32  Cloud
+      1   1   3  Replicate 1 descriptor 3 times
+      3   3  24  Precipitable water
+     -1
+  3  10   5
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  33  Cloud
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Delayed descriptor replication factor
+      3   3  25  Satellite channel and brightness temperature
+     -1
+  3  10   6
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  33  Cloud
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Delayed descriptor replication factor
+      3   3  23  Layer mean temperature
+     -1
+  3  10   7
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  33  Cloud
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Delayed descriptor replication factor
+      3   3  24  Precipitable water
+     -1
+#  (ATOVS HIRS report)
+  3  10   8
+      3  10  11  ATOVS field of view variables
+      1   1  19  Replicate 1 descriptor 19 times
+      3  10  12  ATOVS channel variables
+      0   2 150  TOVS/ATOVS/AVHRR instrumentation channel number
+      0  25  79  Albedo-radiance solar filtered irradiance for ATOVS
+      0  25  80  Albedo-radiance equivalent filter width for ATOVS
+      0  33  32  Channel quality flags for ATOVS
+      0  14  45  Channel radiance
+     -1
+#  (ATOVS AMSU-A report)
+  3  10   9
+      3  10  11  ATOVS field of view variables
+      1   1  15  Replicate 1 descriptor 15 times
+      3  10  12  ATOVS channel variables
+     -1
+#  (ATOVS AMSU-B report)
+  3  10  10
+      3  10  11  ATOVS field of view variables
+      1   1   5  Replicate 1 descriptor 5 times
+      3  10  12  ATOVS channel variables
+     -1
+#  (ATOVS field of view variables)
+  3  10  11
+      0   8  70  TOVS/ATOVS product qualifier
+      0   1  33  Identification of originating/generating centre
+      0   1  34  Identification of originating/generating centre
+      0   8  70  TOVS/ATOVS product qualifier
+      0   1  33  Identification of originating/generating centre
+      0   1  34  Identification of originating/generating centre
+      0   1   7  Satellite identification
+      0   2  48  Satellite sensor indicator
+      0   5  40  Orbit number
+      0  25  75  Satellite antenna corrections version number
+      2   1 133  Change width
+      0   5  41  Scan line number
+      2   1   0  Change width
+      0   5  43  Field of view number
+      0  25  70  Major frame count
+      0  33  30  Scan line status flags for ATOVS
+      0  33  31  Scan line quality flags for ATOVS
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+      0   4   4  Hour
+      0   4   5  Minute
+      2   2 131  Change scale
+      2   1 138  Change width
+      0   4   6  Second
+      2   1   0  Change width
+      2   2   0  Change scale
+      0   5   1  Latitude
+      0   6   1  Longitude
+      2   2 126  Change scale
+      0   7   1  Height of station
+      2   2   0  Change scale
+      0   7  24  Satellite zenith angle
+      0   5  21  Satellite azimuth
+      0   7  25  Solar zenith angle
+      0   5  22  Solar azimuth
+      0  33  33  Field of view quality flags for ATOVS
+      0   2 151  Radiometer identifier
+      0  12  64  Instrument temperature
+      0   2 151  Radiometer identifier
+      0  12  64  Instrument temperature
+      0   2 151  Radiometer identifier
+      0  12  64  Instrument temperature
+      0   2 151  Radiometer identifier
+      0  12  64  Instrument temperature
+     -1
+#  (ATOVS channel variables)
+  3  10  12
+      0   2 150  TOVS/ATOVS/AVHRR instrumentation channel number
+      0  25  76  Log�10 of (temperature-radiance central wavenumber) for ATOVS
+      0  25  77  Bandwidth correction coefficient 1 for ATOVS
+      0  25  78  Bandwidth correction coefficient 2 for ATOVS
+      0  33  32  Channel quality flags for ATOVS
+      2   1 132  Change width
+      2   2 129  Change scale
+      0  12  63  Brightness temperature
+      2   2   0  Change scale
+      2   1   0  Change width
+     -1
+#  (AVHRR (GAC) report)
+  3  10  13
+      0   1   7  Satellite ID
+      0   5  40  Orbit number
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+      0   4   4  Hour
+      0   4   5  Minute
+      0   4   6  Second
+      0   5   1  Latitude
+      0   6   1  Longitude
+      0   7  25  Solar zenith angle
+      0   5  43  Field of view number
+      0  25  85  Fraction of clear pixels in HIRS field of view
+      2   1 131  Change width
+      2   2 129  Change scale
+      0   2 150  TOVS/ATOVS/AVHRR instrumentation channel number
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  14  27  Albedo
+      0   8  72  Pixel(s) type
+      0  14  27  Albedo
+      0   2 150  TOVS/ATOVS/AVHRR instrumentation channel number
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  14  27  Albedo
+      0   8  72  Pixel(s) type
+      0  14  27  Albedo
+      0   2 150  ATOVS/AVHRR instrumentation channel number
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  14  27  Albedo
+      0   8  72  Pixel(s) type
+      0  14  27  Albedo
+      2   2   0  Change scale
+      2   1   0  Change width
+      2   1 132  Change width
+      2   2 129  Change scale
+      0   2 150  ATOVS/AVHRR instrumentation channel number
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   2 150  ATOVS/AVHRR instrumentation channel number
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   2 150  ATOVS/AVHRR instrumentation channel number
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      2   2   0  Change scale
+      2   1   0  Change width
+     -1
+#  (Satellite � geostationnary wind data)
+  3  10  14
+      3   1  72  "Satellite identification, date, time, latitude, longitude"
+      3   3  41  Wind sequence
+      3   4  11  GOES-I/M information
+     -1
+#  (Meteosat radiace data)
+  3  10  15
+      3   1  72  Satellite identification
+      0   7  24  Satellite zenith angle
+      0  10   2  Height
+      3   3  41  Wind sequence
+      1   1   3  Replicate next descriptor 3 times
+      3   4  32  Cloud fraction
+      0   2 152  Satellite instrument used in data processing
+      0   2  24  Integrated mean humidity computational method
+      0   7   4  Pressure
+      0   7   4  Pressure
+      0  13   3  Relative humidity
+      1   1   3  Replicate next descriptor 3 times
+      3   4  33  Clear sky radiance
+     -1
+#  (Meteosat Second Generation (MSG) radiance data)
+  3  10  16
+      3   1  72  Satellite identification
+      0   7  24  Satellite zenith angle
+      0  10   2  Height
+      3   3  41  Wind sequence
+      1   1  12  Replicate next descriptor 12 times
+      3   4  32  Cloud fraction
+      0   2 152  Satellite instrument used in data processing
+      0   2  24  Integrated mean humidity computational method
+      0   7   4  Pressure
+      0   7   4  Pressure
+      0  13   3  Relative humidity
+      1   1  12  Replicate next descriptor 12 times
+      3   4  33  Clear sky radiance
+     -1
+#  (Retrieved ozone data)
+  3  10  20
+      3  10  22
+      3   1  11  "Year, month, day"
+      3   1  13  "Hour, minute, second"
+      3   1  21  "Lat., long. (high accuracy)"
+      3   4  34
+      3  10  21
+     -1
+  3  10  21
+      1   8   0  Delayed replication of 8 next descriptors
+      0  31   1  Delayed descriptor replication factor
+      2   1 131  Change data width
+      2   2 129  Change scale
+      0   7   4  Pressure
+      0   7   4  Pressure
+      2   2   0  Change scale to Table B
+      2   1   0  Change data width to Table B
+      0  15  20  Integrated 03 density
+      0  10   2  Height
+     -1
+  3  10  22
+      0   1   7  Satellite identifier
+      0   2  19  Satellite instrument used
+      0   1  33  Identification of originating/generating centre
+      0   2 172  Product type for retrieved atmospheric gases
+     -1
+#  Category 11 - Single level report sequences (conventional data)
+#  (Aircraft reports)
+  3  11   1
+      3   1  51  "ASDAR aircraft identifier, navigational system, date/time, position, phase of aircraft flight"
+      0   7   2  Altitude
+      0  12   1  Temperature
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+      0  11  31  Degree of turbulence
+      0  11  32  Height of base of turbulence
+      0  11  33  Height of top of turbulence
+      0  20  41  Airframe icing
+     -1
+#  (ACARS reports)
+  3  11   2
+      3   1  65  ACARS identification
+      3   1  66  ACARS location
+      3  11   3  ACARS standard reported variables
+      3  11   4  ACARS supplementary reported variables
+     -1
+#  (ACARS standard reported variables)
+  3  11   3
+      0  10  70  Indicated aircraft altitude
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+      0  12   1  Temperature/dry-bulb temperature
+      0  13   2  Mixing ratio
+     -1
+#  (ACARS supplementary reported variables)
+  3  11   4
+      1   1   0  Delayed replication of one descriptor
+      0  31   0  Short delayed descriptor replication factor
+      0  11  34  Vertical gust velocity
+      1   1   0  Delayed replication of one descriptor
+      0  31   0  Short delayed descriptor replication factor
+      0  11  35  Vertical gust acceleration
+      1   1   0  Delayed replication of one descriptor
+      0  31   0  Short delayed descriptor replication factor
+      0  11  75  Mean turbulence intensity (eddy dissipation rate)
+      1   1   0  Delayed replication of one descriptor
+      0  31   0  Short delayed descriptor replication factor
+      0  11  76  Peak turbulence intensity (eddy dissipation rate)
+      1   1   0  Delayed replication of one descriptor
+      0  31   0  Short delayed descriptor replication factor
+      0  33  25  ACARS interpolated values
+      1   1   0  Delayed replication of one descriptor
+      0  31   0  Short delayed descriptor replication factor
+      0  33  26  Mixing ratio quality
+     -1
+#  Category 12 - Single level report sequences (satellite data)
+  3  12   1
+      3   1  43  "Satellite identifier, instrumentation, location, date/time"
+      3   4   1  "Cloud top pressure, temperature, wind"
+     -1
+  3  12   2
+      3   1  43  "Satellite identifier, instrumentation, location, date/time"
+      3   4   2  "Cloud top pressure, wind"
+     -1
+  3  12   3
+      3   1  42  "Satellite identifier, instrumentation, location, date/time"
+      3   4   3  Surface temperature
+     -1
+  3  12   4
+      3   1  42  "Satellite identifier, instrumentation, location, date/time"
+      3   4   4  Cloud cover
+     -1
+  3  12   5
+      3   1  42  "Satellite identifier, instrumentation, location, date/time"
+      0  20  14  Height of top of cloud
+     -1
+  3  12   6
+      3   1  44  "Satellite identifier, instrumentation, location, date/time"
+      3   4   5  Layer mean relative humidity
+     -1
+  3  12   7
+      3   1  42  "Satellite identifier, instrumentation, location, date/time"
+      3   4   6  Radiation
+     -1
+#  "(Orbital information, Part I)"
+  3  12  10
+      0   1   7  Satellite identifier
+      0   5  40  Orbit number
+      0   2  21  Satellite instrumentation
+      0   5  41  Scan line number
+      0   4   1  Year
+      0   4  43  Day of year
+     -1
+#  "(Orbital information, Part II)"
+  3  12  11
+      2   2 131  Change scale
+      2   1 149  Change width
+      0   4   6  Second
+      2   1   0  Change width
+      2   2 126  Change scale
+      0  10   2  Height
+      2   2   0  Change scale
+      0   5  43  Field of view number
+      0   5  53  Field of view number increment
+     -1
+#  (HIRS brightness temperatures � channels 1�19)
+  3  12  12
+      2   2 129  Change scale
+      2   1 132  Change width
+      1   1  19  Replicate 1 descriptor 19 times
+      0  12  63  Brightness temperature
+      2   1   0  Change width
+      2   2   0  Change scale
+     -1
+#  (HIRS brightness temperatures � channel 20)
+  3  12  13
+      0   5  42  Channel number
+      2   2 129  Change scale
+      2   1 135  Change width
+      0  12  63  Brightness temperature
+      2   1   0  Change width
+      2   2   0  Change scale
+     -1
+#  (HIRS satellite data)
+  3  12  14
+      3  12  10  "Orbital information, Part I"
+      3  12  11  "Orbital information, Part II"
+      1   5  56  Replicate 5 descriptors 56 times
+      3   1  23  Latitude and longitude (coarse accuracy)
+      0   5  42  Channel number
+      0   5  52  Channel number increment
+      3  12  12  HIRS brightness temperatures � channels 1�19
+      3  12  13  HIRS brightness temperature � channel 20
+     -1
+#  (MSU brightness temperatures � channels 1�4)
+  3  12  15
+      1   9  11  Replicate 9 descriptors 11 times
+      3   1  23  Latitude and longitude (coarse accuracy)
+      0   5  42  Channel number
+      0   5  52  Channel number increment
+      2   2 129  Change scale
+      2   1 132  Change width
+      1   1   4  Replicate 1 descriptor 4 times
+      0  12  63  Brightness temperature
+      2   2   0  Change scale
+      2   1   0  Change width
+     -1
+#  (MSU satellite data)
+  3  12  16
+      3  12  10  "Orbital information, Part I"
+      3  12  11  "Orbital information, Part II"
+      3  12  15  MSU brightness temperatures � channels 1�4
+     -1
+#  (SSU brightness temperatures � channels 1�3)
+  3  12  17
+      1   9   8  Replicate 9 descriptors 8 times
+      3   1  23  Latitude and longitude (coarse accuracy)
+      0   5  42  Channel number
+      0   5  52  Channel number increment
+      2   2 129  Change scale
+      2   1 132  Change width
+      1   1   3  Replicate 1 descriptor 3 times
+      0  12  63  Brightness temperature
+      2   2   0  Change scale
+      2   1   0  Change width
+     -1
+#  (SSU satellite data)
+  3  12  18
+      3  12  10  "Orbital information, Part I"
+      3  12  11  "Orbital information, Part II"
+      3  12  17  SSU brightness temperatures � channels 1�3
+     -1
+#  (Wave scatterometer product with width change for wave number (spectral))
+  3  12  19
+      3   1  47  Product header
+      3   1  48  Radar parameters
+      0  15  15  Maximum spectrum composition before normalisation
+      0  29   2  Coordinate grid type
+      0  21  76  Representation of intensities
+      1   6  12  Repeat next 6 descriptors 12 times
+      2   1 129  Change width to 14 bits
+      0   6  30  Wave number (spectral)
+      2   1   0  Change width to Table B
+      1   2  12  Repeat next 2 descriptors 12 times
+      0   5  30  Direction (spectral)
+      0  21  75  Image spectrum intensity
+      0  21  66  Wave scatterometer product confidence data
+     -1
+#  (Wave scatterometer product)
+  3  12  20
+      3   1  47  Product header
+      3   1  48  Radar parameters
+      0  15  15  Maximum spectrum composition before normalization
+      0  29   2  Coordinate grid type
+      0  21  76  Representation of intensities
+      1   4  12  Repeat next 4 descriptors 12 times
+      0   6  30  Wave number (spectral)
+      1   2  12  Repeat next 2 descriptors 12 times
+      0   5  30  Direction (spectral)
+      0  21  75  Spectral intensity
+      0  21  66  Wave scatterometer product confidence data
+     -1
+#  (Wind scatterometer product)
+  3  12  21
+      3   1  47  Product header
+      1   1   3  Repeat 1 descriptor 3 times
+      3   1  49  Radar beam data
+      0  11  12  Wind speed at 10 m
+      0  11  11  Wind direction at 10 m
+      0  21  67  Wind product confidence data
+     -1
+#  (Radar altimeter product)
+  3  12  22
+      3   1  47  Product header
+      0   8  22  Number in average
+      0  11  12  Wind speed
+      0  11  50  Standard deviation of horizontal wind speed
+      0  22  70  Significant wave height
+      0  22  26  Standard deviation of significant wave height
+      3  12  41  Altitude
+      0  10  50  Standard deviation of altitude
+      0  21  68  Radar altimeter product confidence data
+      0  21  71  Peakiness
+      0  21  72  Altimeter calibration status
+      0  21  73  Altimeter instrument mode
+      3  12  42  Altitude corrections
+      0  21  62  Backscatter
+      0  15  11  Log 10 of integrated electron density
+     -1
+#  (ATSR sea surface temperature product)
+  3  12  23
+      3   1  47  Product header
+      1   3   3  Repeat 3 descriptors 3 times
+      0   8  22  Number in average
+      0  12  61  Skin temperature
+      0  22  50  Standard deviation of sea surface temperature
+      0  21  69  SST product confidence data
+      0  21  85  ATSR sea surface temperature across-track band number
+     -1
+#  (Wave scatterometer product enhanced)
+  3  12  24
+      3  12  20  (Wave scatterometer product)
+      0   8  60  Sample scanning mode significance � range
+      0   8  22  Number in sample
+      0   8  60  Sample scanning mode signification � horizontal
+      0   8  22  Number in sample
+      0  25  14  Azimuth clutter cut-off
+      0  22 101  Total energy (wavelength > 731 m)
+      0  22  97  Mean wavelength of image spectrum
+      0  22  98  Wavelength spread (wavelength > 731 m)
+      0  22  99  Mean direction (wavelength > 731 m)
+      0  22 100  Direction spread (wavelength > 731 m)
+     -1
+#  (Wave scatterometer enhanced product (with change of width for wave number (spectral))
+  3  12  25
+      3  12  19  Wave scatterometer product with width change for wave
+      0   8  60  Sample scanning mode significance � range
+      0   8  22  Number in sample
+      0   8  60  Sample scanning mode significance � horizontal
+      0   8  22  Number in sample
+      0  25  14  Azimuth clutter cut-off
+      0  22 101  Total energy (wavelength > 731 m)
+      0  22  97  Mean wavelength of image spectrum
+      0  22  98  Wavelength spread (wavelength > 731 m)
+      0  22  99  Mean direction (wavelength > 731 m)
+      0  22 100  Direction spread (wavelength > 731 m)
+     -1
+#  (QUIKSCAT data)
+  3  12  26
+      3   1  46
+      3   1  11  Data
+      3   1  13  Time
+      3   1  23  Location
+      3  12  31
+      1   1   4  Replicate 1 descriptor 4 times
+      3  12  30
+      0  21 110  Number of inner-beam sigma-0 (forward of satellite)
+      3   1  23  Location
+      3  21  27
+      0  21 111  Number of outer-beam sigma-0 (forward of satellite)
+      3   1  23  Location
+      3  21  27
+      0  21 112  Number of inner-beam sigma-0 (aft of satellite)
+      3   1  23  Location
+      3  21  27
+      0  21 113  Number of outer-beam sigma-0 (aft of satellite)
+      3   1  23  Location
+      3  21  27
+     -1
+#  (ATSR SST Product (SADIST-2))
+  3  12  27
+      3   1  47  ERS product header
+      1   5   9  Repeat next 5 descriptors 9 times
+      3   1  23  Location (coarse Latitude + Longitude) of 10-arcmin cell
+      0   7  21  Elevation: Incidence angle Nadir view [set to zero]
+      0  12  61  Skin temperature: SST [Nadir-only view]
+      0   7  21  Elevation: Incidence angle Dual view [set to 'missing']
+      0  12  61  Skin temperature: SST [Dual view]
+      0  21  85  ATSR SST across-track band number [0-9]
+      0  21  70  SST product confidence data (SADIST-2) [23-bit flag]
+     -1
+#  (SEAWINDS QUIKSCAT data)
+  3  12  28
+      3   1  46
+      3   1  11
+      3   1  13
+      3   1  23
+      0   8  25  Time difference qualifier
+      2   1 136  Change data width
+      0   4   6  Second
+      2   1   0  Change data width back to Table B
+      3  12  31
+      3  12  32
+      1   1   4  Next descriptor replicated four times
+      3  12  30
+      1   1   2  Next descriptor replicated two times
+      3  12  33
+      0  21 110  Number of inner-beam sigma-0 (forward of satellite)
+      3   1  23
+      3  21  28
+      0  21 111  Number of outer-beam sigma-0 (forward of satellite)
+      3   1  23
+      3  21  28
+      0  21 112  Number of inner-beam sigma-0 (aft of satellite)
+      3   1  23
+      3  21  28
+      0  21 113  Number of outer-beam sigma-0 (aft of satellite)
+      3   1  23
+      3  21  28
+     -1
+  3  12  30
+      2   1 130  Change data width
+      2   2 129  Change scale
+      0  11  12  Wind speed at 10 m
+      2   2   0  Change scale back to Table B
+      2   1   0  Change data width to Table B
+      0  11  52  Formal uncertainty in wind speed
+      2   1 135  Change data width
+      2   2 130  Change scale
+      0  11  11  Wind direction at 10 m
+      2   2   0  Change scale back to Table B
+      2   1   0  Change data width to Table B
+      0  11  53  Formal uncertainty in wind direction
+      0  21 104  Likelihood computed for solution
+     -1
+  3  12  31
+      0   5  34  Along-track row number
+      0   6  34  Cross-track cell number
+      0  21 109  SEAWINDS wind vector cell quality
+      0  11  81  Model wind direction at 10 m
+      0  11  82  Model wind speed at 10 m
+      0  21 101  Number of vector ambiguities
+      0  21 102  Index of selected wind vector
+      0  21 103  Total number of sigma-0 measurements
+     -1
+  3  12  32
+      0  21 120  Probability of rain
+      0  21 121  SEAWINDS NOF rain index
+      0  13  55  Intensity of precipitation
+      0  21 122  Attenuation correction on sigma-0 (from tB)
+     -1
+  3  12  33
+      0   2 104  Antenna polarisation
+      0   8  22  Total number (with respect to accumulation)
+      0  12  63  Brightness temperature
+      0  12  65  Standard deviation brightness temperature
+     -1
+#  (Altitude)
+  3  12  41
+      2   1 141  Change width to 28 bits
+      2   2 130  Change scale to 2
+      0   7   1  Altitude
+      2   1   0  Change width back to Table B
+      2   2   0  Change scale back to Table B
+     -1
+#  (Altitude corrections)
+  3  12  42
+      0  21  77  "Altitude correction, ionosphere"
+      0  21  78  "Altitude correction, dry troposphere"
+      0  21  79  "Altitude correction, wet troposphere"
+      0  21  80  "Altitude correction, calibration constant"
+      0  21  81  Open loop height-time loop calibration correction
+      0  21  82  Open loop automatic gain control calibration correction
+     -1
+#  Category 13 - Sequences common to image data
+#  (Radar reflectivity values)
+  3  13   9
+      0  21   1  Horizontal reflectivity
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      0  21   1  Horizontal reflectivity
+     -1
+#  (Radar rainfall intensities)
+  3  13  10
+      0  21  36  Radar rainfall intensity
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      0  21  36  Radar rainfall intensity
+     -1
+#  (Non run-length encoded row for Pixel value (4 bits))
+  3  13  31
+      0   6   2  First longitude location minus one increment
+      0   6  12  Longitude increment
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   2  Extended replication factor
+      0  30   1  Pixel value (4 bits)
+     -1
+#  (Non run-length encoded picture data for Pixel value (4 bits))
+  3  13  32
+      0   5   2  First latitude location minus one increment
+      0   5  12  Latitude increment (signed value so cannot cross pole)
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   2  Extended replication factor
+      3  13  31  Non run-length encoded row
+     -1
+#  (Run-length encoded row for Pixel value (4 bits))
+  3  13  41
+      0   6   2  First longitude location minus one increment
+      1  10   0  Delayed replication of 10 descriptors
+      0  31   1  Replication factor
+      1   4   0  Delayed replication of 4 descriptors
+      0  31   1  Replication factor
+      0   6  12  Longitude increment
+      1   1   0  Delayed replication of 1 descriptor
+      0  31  12  Repetition factor
+      0  30   1  Pixel value (4 bits)
+      0   6  12  Longitude increment
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      0  30   1  Pixel value (4 bits)
+     -1
+#  (Run-length encoded picture data for Pixel value (4 bits))
+  3  13  42
+      0   5   2  First latitude location minus one increment
+      0   5  12  Latitude increment (signed value so cannot cross pole)
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   2  Extended replication factor
+      3  13  41  Run-length encoded row
+     -1
+#  "(Run-length encoded picture data for Pixel value (4 bits), regular grid)"
+  3  13  43
+      0   6   2  First longitude location minus one increment
+      0   5   2  First latitude location minus one increment
+      0   5  12  Latitude increment
+      1  12   0  Delayed replication of 12 descriptors
+      0  31   1  Replication factor
+      1  10   0  Delayed replication of 10 descriptors
+      0  31   1  Replication factor
+      1   4   0  Delayed replication of 4 descriptors
+      0  31   1  Replication factor
+      0   6  12  Longitude increment
+      1   1   0  Delayed replication of 1 descriptor
+      0  31  11  Repetition factor
+      0  30   1  Pixel value (4 bits)
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      0  30   1  Pixel value (4 bits)
+     -1
+#  Category 15 - Oceanographic report sequences
+#  (Typically reported underwater sounding without optional fields)
+  3  15   1
+      0   1  11  Ship's call sign
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+      3   6   1  "Depth, temperature"
+     -1
+#  (Typically reported underwater sounding without optional fields)
+  3  15   2
+      0   1  11  Ship's call sign
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+      3   6   4  "Depth, temperature, salinity"
+     -1
+#  Category 16 - Synoptic feature sequences
+  3  16   1
+      3   1  11  "Year, month, day"
+      0   4   4  Hour
+      3   1  23  Latitude and longitude (coarse accuracy)
+      0   1  21  Synoptic feature identifier
+      0   2  41  Method for estimating reports related to synoptic features
+      0  19   1  Type of synoptic feature
+      0  10  51  Pressure reduced to mean sea level
+      0  19   2  Effective radius of feature
+      0  19   3  Wind speed threshold (15 m s�1 typically)
+      0  19   4  Effective radius with respect to wind speeds above threshold
+     -1
+#  (Header)
+  3  16   2
+      0   8  21  Data time (analysis)
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+      0   4   4  Hour
+      0   4   5  Minute
+      0   1  33  Originating/generating centre
+      0   8  21  Validity time (fcst)
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+      0   4   4  Hour
+      0   4   5  Minute
+      0   7   2  Flight level (altitude) (base of chart layer)
+      0   7   2  Flight level (altitude) (top of chart layer)
+     -1
+#  (Jet stream)
+  3  16   3
+      1  10   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature (jet stream value)
+      0   8   7  Dimensional significance (value for line)
+      1   4   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0  10   2  Flight level (altitude)
+      0  11   2  Wind speed
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  (Turbulence)
+  3  16   4
+      1  11   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature (value for turbulence)
+      0   8   7  Dimensional significance (value for area)
+      0   7   2  Flight level (altitude) (base of layer)
+      0   7   2  Flight level (altitude) (top of layer)
+      1   2   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0  11  31  Degree of turbulence
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  (Storm)
+  3  16   5
+      1   8   0  Delayed replication
+      0  31   1  Replication
+      0   8   5  Meteorological attribute significance (storm centre)
+      0   8   7  Dimensional significance (value for point)
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0   1  26  WMO storm name (use �unknown� for a sandstorm)
+      0  19   1  Synoptic features (value for type of storm)
+      0   8   7  Dimensional significance (cancel)
+      0   8   5  Meteorological attribute significance (cancel/end of object)
+     -1
+#  (Cloud)
+  3  16   6
+      1  12   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature (value for cloud)
+      0   8   7  Dimensional significance (value for area)
+      0   7   2  Flight level (altitude) (base of layer)
+      0   7   2  Flight level (altitude) (top of layer)
+      1   2   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0  20  11  Cloud amount
+      0  20  12  Cloud type
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  (Front)
+  3  16   7
+      1  10   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature (value for type of front)
+      0   8   7  Dimensional significance (value for line)
+      1   4   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0  19   5  Direction of feature
+      0  19   6  Speed of feature
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  (Tropopause)
+  3  16   8
+      1  11   0  Delayed replication
+      0  31   1  Replication
+      0   8   1  Vertical significance (bit 3 set for tropopause)
+      0   8   7  Dimensional significance (value for point)
+      0   8  23  Statistic (type of tropopause value)
+      1   3   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0  10   2  Height/altitude
+      0   8  23  Statistic (cancel)
+      0   8   7  Dimensional significance (cancel)
+      0   8   1  Vertical significance (cancel/end of object)
+     -1
+#  (Airframe icing area)
+  3  16   9
+      1  11   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature (value for airframe icing)
+      0   8   7  Dimensional significance (value for area)
+      0   7   2  Flight level (altitude) (base of layer)
+      0   7   2  Flight level (altitude) (top of layer)
+      1   2   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0  20  41  Airframe icing (type of airframe icing)
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  (Name of feature)
+  3  16  10
+      1   7   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature
+      0   8   7  Dimensional significance (value for point)
+      0   1  22  Name of feature
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  (Volcano erupting)
+  3  16  11
+      1  16   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature (value for special clouds)
+      0   1  22  Name of feature (volcano name)
+      0   8   7  Dimensional significance (value for point)
+      1   2   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0   8  21  Time significance (eruption starting time)
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+      0   4   4  Hour
+      0   4   5  Minute
+      0  20  90  Special clouds (clouds from volcanic eruptions)
+      0   8  21  Time significance (cancel)
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  Category 18 - Radiological report sequences
+  3  18   1
+      3   1  25  "Latitude and longitude (coarse accuracy), day and time"
+      0  24  11  Dose
+     -1
+  3  18   3
+      3   1  26  "Latitude and longitude (high accuracy), time periods in days,"
+      0  24   5  Isotope mass
+      0  24   4  Element name
+      0  24  21  Air concentration
+     -1
+  3  18   4
+      3   1  25  "Latitude and longitude (coarse accuracy), day and time"
+      0   4  23  Time period or displacement
+      0  13  11  Total precipitation/total water equivalent
+      0  24   5  Isotope mass
+      0  24   4  Element name
+      0  24  22  Concentration in precipitation
+     -1
+#  Category 21 - Radar report sequences
+#  (Wind profiler � antenna characteristics)
+  3  21   1
+      0   2 101  Type of antenna
+      0   2 114  Antenna effective surface area
+      0   2 105  Maximum antenna gain
+      0   2 106  3-dB beamwidth
+      0   2 107  Sidelobe suppression
+      0   2 121  Mean frequency
+     -1
+#  (Wind profiler � moment data)
+  3  21   3
+      0  21  51  Signal power above 1 mW
+      0  21  14  Doppler mean velocity (radial)
+      0  21  17  Doppler velocity spectral width
+      0  21  30  Signal to noise ratio
+     -1
+#  (Wind profiler � moment data sounding)
+  3  21   4
+      3   1  31  "Identification, type, date/time, position (high accuracy), height"
+      0   2   3  Type of measuring equipment used
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3  21   3  Wind profiler � moment data
+     -1
+#  (Transmitter-receiver characteristics)
+  3  21   5
+      0  25   4  Echo processing
+      0   2 121  Mean frequency
+      0   2 122  Frequency agility range
+      0   2 123  Peak power
+      0   2 124  Average power
+      0   2 125  Pulse repetition frequency
+      0   2 126  Pulse width
+      0   2 127  Receiver intermediate frequency
+      0   2 128  Intermediate frequency bandwidth
+      0   2 129  Minimum detectable signal
+      0   2 130  Dynamic range
+      0   2 131  Sensitivity time control
+     -1
+#  (Integration characteristics)
+  3  21   6
+      0  25   1  Range-gate length
+      0  25   2  Number of gates averaged
+      0  25   3  Number of integrated pulses
+      0  25   5  Echo integration
+     -1
+#  (Corrections)
+  3  21   7
+      0  25   9  Calibration method
+      0  25  10  Clutter treatment
+      0  25  11  Ground occultation correction
+      0  25  12  Range attenuation correction
+      0  25  13  Bright-band correction
+      0  25  15  Radome attenuation correction
+      0  25  16  Clear-air attenuation correction
+      0  25  17  Precipitation attenuation correction
+     -1
+#  (Z to R conversion)
+  3  21   8
+      0  25   6  Z to R conversion
+      0  25   7  Z to R conversion factor
+      0  25   8  Z to R conversion exponent
+     -1
+#  (A to Z law)
+  3  21   9
+      0  25  18  A to Z law for attenuation factor
+      0  25  19  A to Z law for attenuation exponent
+     -1
+#  (Antenna characteristics)
+  3  21  10
+      0   2 101  Type of antenna
+      0   7   2  Altitude of the tower base
+      0   2 102  Antenna height above tower base
+      0   2 103  Radome
+      0   2 104  Antenna polarisation
+      0   2 105  Maximum antenna gain
+      0   2 106  3-dB beamwidth
+      0   2 107  Sidelobe suppression
+      0   2 108  Crosspol discrimination (on axis)
+      0   2 109  Antenna speed (azimuth)
+      0   2 110  Antenna speed (elevation)
+      0   2 132  Azimuth pointing accuracy
+      0   2 133  Elevation pointing accuracy
+     -1
+#  (General characteristics)
+  3  21  11
+      0  30  31  Picture type
+      0  30  32  Combination with other data
+      0  29   2  Coordinate grid type
+     -1
+#  (Antenna elevations)
+  3  21  12
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      0   2 135  Antenna elevation
+     -1
+#  (Basic information (System/site header) on Wind profiler/RASS)
+  3  21  21
+      0   2   3  Type of measuring equipment used
+      0   2 101  Type of antenna
+      2   1 130  Change width to 8 bits
+      0   2 106  3-dB beam width
+      2   1   0  Change width to table B
+      2   1 132  Change width to 11 bits
+      2   2 130  Change scale to -6
+      0   2 121  Mean frequency
+      2   2   0  Change scale to table B
+      2   1   0  Change width to table B
+      2   1 133  Change width to 11 bits
+      2   2 129  Change scale to 0
+      0  25   1  Range-gate length
+      2   2   0  Change scale to table B
+      2   1   0  Change width to table B
+     -1
+#  (Wind profiler: Processed-data winds)
+  3  21  22
+      0  10   7  Height
+      2   4   1  Add associated field of 1 bit in length
+      0  31  21  Associated field significance
+      0  11   1  Wind direction
+      2   4   0  Cancel add associated field
+      0  11   2  Wind speed
+      2   4   1  Add associated field of 1 bit in length
+      0  31  21  Associated field significance
+      0  11   6  w-component
+      2   4   0  Cancel add associated field
+      0  21  30  Signal to noise ratio
+     -1
+#  Wind profiler: Raw-data winds)
+  3  21  23
+      0   7   7  Height
+      0  21  91  Radar signal Doppler spectrum 0th moment
+      0  21  30  Signal to noise ratio
+      2   2 129  Change scale to 2
+      0  21  14  Doppler mean velocity (radial)
+      2   1 129  Change width to 9 bits
+      0  21  17  Doppler velocity spectral width
+      2   2   0  Change scale to table B
+      2   1   0  Change width to table B
+     -1
+#  (RASS-Mode: Processed-data RASS)
+  3  21  24
+      0   7   7  Height
+      2   4   1  Add associated field of 1 bit in length
+      0  31  21  Associated field significance
+      0  12   7  Virtual temperature
+      0  11   6  w-component
+      2   4   0  Cancel add associated field
+      0  21  30  Signal to noise ratio
+     -1
+#  (RASS-Mode: Raw-data RASS)
+  3  21  25
+      0   7   7  Height
+      0  21  91  Radar signal Doppler spectrum 0th moment
+      0  21  30  Signal to noise ratio
+      2   2 129  Change scale to 2
+      0  21  14  Doppler mean velocity (radial)
+      2   1 129  Change width to 9 bits
+      0  21  17  Doppler velocity spectral width
+      2   2   0  Change scale to table B
+      2   1   0  Change width to table B
+      0  21  92  "RASS signal Doppler spectrum 0th moment, referring to RASS signal"
+      0  21  30  "Signal to noise ratio, referring to RASS signal "
+      0  25  92  Acoustic propagation velocity
+      2   1 129  Change width to 9 bits
+      2   2 129  Change scale to 2
+      0  21  17  "Doppler velocity spectral width, referring to RASS signal"
+      2   2   0  Change scale to table B
+      2   1   0  Change width to table B
+     -1
+#  (RASS data - fluxes)
+  3  21  26
+      0  10   7  Height
+      2   4   1  Add associated field of 1 bit in length
+      0  31  21  Associated field significance
+      0  12   7  Virtual temperature
+      0  25  91  Structure constant of the refraction index (Cn2)
+      0  11  71  Turbulent vertical momentum flux
+      0  11  72  Turbulent vertical buoyancy flux
+      0  11  73  Turbulent kinetic energy
+      0  11  74  Dissipation energy
+      2   4   0  Cancel add associated field
+     -1
+  3  21  27
+      0  21 118  Attenuation correction on sigma-0
+      2   2 129  Change scale
+      2   1 132  Change data width
+      0   2 112  Radar look angle
+      2   1   0  Change data width to Table B
+      2   1 131  Change data width
+      0   2 111  Radar incidence angle
+      2   1   0  Change data width to Table B
+      2   2   0  Change scale back to Table B
+      0   2 104  Antenna polarization
+      0  21 105  Normalized radar cross-section
+      0  21 106  Kp variance coefficient (alpha)
+      0  21 107  Kp variance coefficient (beta)
+      0  21 114  Kp variance coefficient (gamma)
+      0  21 115  SEAWINDS sigma-0 quality
+      0  21 116  SEAWINDS sigma-0 mode
+      0   8  18  SEAWINDS land/ice surface type
+      0  21 117  Sigma-0 variance quality control
+     -1
+  3  21  28
+      0  21 118  Attenuation correction on sigma-0
+      2   2 129  Change scale
+      2   1 132  Change data width
+      0   2 112  Radar look angle
+      2   1   0  Data width back to Table B
+      2   1 131  Change data width
+      0   2 111  Radar incidence angle
+      2   1   0  Data width back to Table B
+      2   2   0  Scale back  to table B
+      0   2 104  Antenna polarization
+      0  21 123  SEAWINDS normalized radar cross section
+      0  21 106  Kp variance coefficient (alpha)
+      0  21 107  Kp variance coefficient (beta)
+      0  21 114  Kp variance coefficient (gamma)
+      0  21 115  SEAWINDS sigma-0 quality flag
+      0  21 116  SEAWINDS sigma-0 mode flag
+      0   8  18  SEAWINDS land/ice surface flag
+      0  21 117  Sigma-0 variance quality control
+     -1
diff --git a/data/tables/B3M-000-010-0 b/data/tables/B3M-000-010-0
new file mode 100644
index 0000000..3b94b71
--- /dev/null
+++ b/data/tables/B3M-000-010-0
@@ -0,0 +1,121 @@
+##############################################################################
+# BUFR Table 0
+#
+#
+# Notes
+# -----
+#
+# * This table comes from GRIB Code Table 0 (Identification of center)
+#
+# * A value of 1 in the first column indicates a center that uses minor
+#   version numbers with local tables.  Since minor local table version
+#   numbers are stored in Section 1, Octet 18, the value in the first
+#   column must not be set if a center uses Section 1, Octet 18 for other
+#   purposes (i.e., ECMWF).
+#
+#
+##############################################################################		
+		
+		
+#01-09: WMCs		
+0	1	Melbourne
+0	2	Melbourne
+0	3	Melbourne
+0	4	Moscow
+0	5	Moscow
+0	6	Moscow
+0	7	"US National Weather Service, National Centres for Environmental Prediction(NCEP)"
+0	8	US National Weather Service TelecommunicationsGateway (NWSTG)
+0	9	US National Weather Service - Other
+#10-25: Centres in Region I		
+0	10	Cairo (RSMC/RAFC)
+0	11	Cairo (RSMC/RAFC)
+0	12	Dakar (RSMC/RAFC)
+0	13	Dakar (RSMC/RAFC)
+0	14	Nairobi (RSMC/RAFC)
+0	15	Nairobi (RSMC/RAFC)
+0	18	Tunis Casablanca (RSMC)
+0	19	Tunis Casablanca (RSMC)
+0	20	Las Palmas (RAFC)
+0	21	Algiers (RSMC)
+0	24	Pretoria (RSMC)
+0	25	La R�union (RSMC)
+#26-40: Centres in Region II		
+0	26	Khabarovsk (RSMC)
+0	27	Khabarovsk (RSMC)
+0	28	New Delhi (RSMC/RAFC)
+0	29	New Delhi (RSMC/RAFC)
+0	30	Novosibirsk (RSMC)
+0	31	Novosibirsk (RSMC)
+0	32	Tashkent (RSMC)
+0	33	Jeddah (RSMC)
+0	34	"Tokyo (RSMC), Japan Meteorological Agency"
+0	35	"Tokyo (RSMC), Japan Meteorological Agency"
+0	36	Bangkok
+0	37	Ulan Bator
+0	38	Beijing (RSMC)
+0	39	Beijing (RSMC)
+0	40	Seoul
+#41-50: Centres in Region III		
+0	41	Buenos Aires (RSMC/RAFC)
+0	42	Buenos Aires (RSMC/RAFC)
+0	43	Brasilia (RSMC/RAFC)
+0	44	Brasilia (RSMC/RAFC)
+0	45	Santiago
+0	46	Brazilian Space Agency � INPE
+#51-63: Centres in Region IV		
+0	51	Miami (RSMC/RAFC)
+0	52	"Miami RSMC, National Hurricane Center"
+0	53	Montreal (RSMC)
+0	54	Montreal (RSMC)
+0	55	San Francisco
+0	57	U.S. Air Force Air Force Global Weather Central 
+0	58	"Fleet Numerical Meteorology and Oceanography Center, Monterey, CA"
+0	59	"The NOAA Forecast Systems Laboratory, Boulder, CO, USA"
+0	60	United States National Centre for Atmospheric Research (NCAR)
+0	61	Service ARGOS - Landover
+#64-73: Centres in Region V		
+0	64	Honolulu
+0	65	Darwin (RSMC)
+0	66	Darwin (RSMC)
+0	67	Melbourne (RSMC)
+0	69	Wellington (RSMC/RAFC)
+0	70	Wellington (RSMC/RAFC)
+0	71	Nadi (RSMC)
+#74-99: Centres in Region VI		
+0	74	UK Meteorological Office � Bracknell (RSMC)
+0	75	UK Meteorological Office � Bracknell (RSMC)
+0	76	Moscow (RSMC/RAFC)
+0	78	Offenbach (RSMC)
+0	79	Offenbach (RSMC)
+0	80	Rome (RSMC)
+0	81	Rome (RSMC)
+0	82	Norrk�ping
+0	83	Norrk�ping
+0	84	Toulouse (RSMC)
+0	85	Toulouse (RSMC)
+0	86	Helsinki
+0	87	Belgrade
+0	88	Oslo
+0	89	Prague
+0	90	Episkopi
+0	91	Ankara
+0	92	Frankfurt/Main (RAFC)
+0	93	London (WAFC)
+0	94	Copenhagen
+0	95	Rota
+0	96	Athens
+0	97	European Space Agency (ESA)
+0	98	"ECMWF, RSMC"
+0	99	De Bilt
+0	110	Hong-Kong
+0	160	US NOAA/NESDIS
+0	210	Frascati (ESA/ESRIN)
+0	211	Lanion
+0	212	Lisboa
+0	213	Reykjavik
+0	214	Reykjavik
+0	215	Madrid
+0	216	Z�rich
+0	254	EUMETSAT Operation Centre
+0	255	Missing value
diff --git a/data/tables/B3M-000-010-A b/data/tables/B3M-000-010-A
new file mode 100644
index 0000000..5a7f993
--- /dev/null
+++ b/data/tables/B3M-000-010-A
@@ -0,0 +1,259 @@
+#
+# BUFR Table A - Data Category
+#
+  0	Surface data - land
+  1	Surface data - sea
+  2	Vertical soundings (other than satellite)
+  3	Vertical soundings (satellite)
+  4	Single level upper-air data (other than satellite)
+  5	Single level upper-air data (satellite)
+  6	Radar data
+  7	Synoptic features
+  8	Physical/chemical constituents
+  9	Dispersal and transport
+ 10	Radiological data
+ 11	BUFR tables, complete replacement or update
+ 12	Surface data (satellite)
+ 13	RESERVED
+ 14	RESERVED
+ 15	RESERVED
+ 16	RESERVED
+ 17	RESERVED
+ 18	RESERVED
+ 19	RESERVED
+ 20	Status information
+ 21	Radiances (satellite measured)
+ 22	RESERVED
+ 23	RESERVED
+ 24	RESERVED
+ 25	RESERVED
+ 26	RESERVED
+ 27	RESERVED
+ 28	RESERVED
+ 29	RESERVED
+ 30	RESERVED
+ 31	Oceanographic data
+ 32	RESERVED
+ 33	RESERVED
+ 34	RESERVED
+ 35	RESERVED
+ 36	RESERVED
+ 37	RESERVED
+ 38	RESERVED
+ 39	RESERVED
+ 40	RESERVED
+ 41	RESERVED
+ 42	RESERVED
+ 43	RESERVED
+ 44	RESERVED
+ 45	RESERVED
+ 46	RESERVED
+ 47	RESERVED
+ 48	RESERVED
+ 49	RESERVED
+ 50	RESERVED
+ 51	RESERVED
+ 52	RESERVED
+ 53	RESERVED
+ 54	RESERVED
+ 55	RESERVED
+ 56	RESERVED
+ 57	RESERVED
+ 58	RESERVED
+ 59	RESERVED
+ 60	RESERVED
+ 61	RESERVED
+ 62	RESERVED
+ 63	RESERVED
+ 64	RESERVED
+ 65	RESERVED
+ 66	RESERVED
+ 67	RESERVED
+ 68	RESERVED
+ 69	RESERVED
+ 70	RESERVED
+ 71	RESERVED
+ 72	RESERVED
+ 73	RESERVED
+ 74	RESERVED
+ 75	RESERVED
+ 76	RESERVED
+ 77	RESERVED
+ 78	RESERVED
+ 79	RESERVED
+ 80	RESERVED
+ 81	RESERVED
+ 82	RESERVED
+ 83	RESERVED
+ 84	RESERVED
+ 85	RESERVED
+ 86	RESERVED
+ 87	RESERVED
+ 88	RESERVED
+ 89	RESERVED
+ 90	RESERVED
+ 91	RESERVED
+ 92	RESERVED
+ 93	RESERVED
+ 94	RESERVED
+ 95	RESERVED
+ 96	RESERVED
+ 97	RESERVED
+ 98	RESERVED
+ 99	RESERVED
+100	RESERVED
+101	Image data
+102	RESERVED
+103	RESERVED
+104	RESERVED
+105	RESERVED
+106	RESERVED
+107	RESERVED
+108	RESERVED
+109	RESERVED
+110	RESERVED
+111	RESERVED
+112	RESERVED
+113	RESERVED
+114	RESERVED
+115	RESERVED
+116	RESERVED
+117	RESERVED
+118	RESERVED
+119	RESERVED
+120	RESERVED
+121	RESERVED
+122	RESERVED
+123	RESERVED
+124	RESERVED
+125	RESERVED
+126	RESERVED
+127	RESERVED
+128	RESERVED
+129	RESERVED
+130	RESERVED
+131	RESERVED
+132	RESERVED
+133	RESERVED
+134	RESERVED
+135	RESERVED
+136	RESERVED
+137	RESERVED
+138	RESERVED
+139	RESERVED
+140	RESERVED
+141	RESERVED
+142	RESERVED
+143	RESERVED
+144	RESERVED
+145	RESERVED
+146	RESERVED
+147	RESERVED
+148	RESERVED
+149	RESERVED
+150	RESERVED
+151	RESERVED
+152	RESERVED
+153	RESERVED
+154	RESERVED
+155	RESERVED
+156	RESERVED
+157	RESERVED
+158	RESERVED
+159	RESERVED
+160	RESERVED
+161	RESERVED
+162	RESERVED
+163	RESERVED
+164	RESERVED
+165	RESERVED
+166	RESERVED
+167	RESERVED
+168	RESERVED
+169	RESERVED
+170	RESERVED
+171	RESERVED
+172	RESERVED
+173	RESERVED
+174	RESERVED
+175	RESERVED
+176	RESERVED
+177	RESERVED
+178	RESERVED
+179	RESERVED
+180	RESERVED
+181	RESERVED
+182	RESERVED
+183	RESERVED
+184	RESERVED
+185	RESERVED
+186	RESERVED
+187	RESERVED
+188	RESERVED
+189	RESERVED
+190	RESERVED
+191	RESERVED
+192	RESERVED
+193	RESERVED
+194	RESERVED
+195	RESERVED
+196	RESERVED
+197	RESERVED
+198	RESERVED
+199	RESERVED
+200	RESERVED
+201	RESERVED
+202	RESERVED
+203	RESERVED
+204	RESERVED
+205	RESERVED
+206	RESERVED
+207	RESERVED
+208	RESERVED
+209	RESERVED
+210	RESERVED
+211	RESERVED
+212	RESERVED
+213	RESERVED
+214	RESERVED
+215	RESERVED
+216	RESERVED
+217	RESERVED
+218	RESERVED
+219	RESERVED
+220	RESERVED
+221	RESERVED
+222	RESERVED
+223	RESERVED
+224	RESERVED
+225	RESERVED
+226	RESERVED
+227	RESERVED
+228	RESERVED
+229	RESERVED
+230	RESERVED
+231	RESERVED
+232	RESERVED
+233	RESERVED
+234	RESERVED
+235	RESERVED
+236	RESERVED
+237	RESERVED
+238	RESERVED
+239	RESERVED
+240	FOR EXPERIMENTAL USE
+241	FOR EXPERIMENTAL USE
+242	FOR EXPERIMENTAL USE
+243	FOR EXPERIMENTAL USE
+244	FOR EXPERIMENTAL USE
+245	FOR EXPERIMENTAL USE
+246	FOR EXPERIMENTAL USE
+247	FOR EXPERIMENTAL USE
+248	FOR EXPERIMENTAL USE
+249	FOR EXPERIMENTAL USE
+250	FOR EXPERIMENTAL USE
+251	FOR EXPERIMENTAL USE
+252	FOR EXPERIMENTAL USE
+253	FOR EXPERIMENTAL USE
+254	FOR EXPERIMENTAL USE
+255	Indicator for local use, with sub-category
diff --git a/data/tables/B3M-000-010-B b/data/tables/B3M-000-010-B
new file mode 100644
index 0000000..fa04d66
--- /dev/null
+++ b/data/tables/B3M-000-010-B
@@ -0,0 +1,848 @@
+#
+# WMO source file name = BufrTabB-11-2001.txt
+# Master Table B Version 10
+#
+#                   Reference    Bit
+# F   X    Y Scale    Value     Width     Units     Comments
+#--------------------------------------------------------------
+# Class 00 - BUFR/CREX(*) table entries
+  0;  0;   1;    0;           0;   24;   CCITT_IA5; Table A:  entry
+  0;  0;   2;    0;           0;  256;   CCITT_IA5; "Table A:  data category description, line 1"
+  0;  0;   3;    0;           0;  256;   CCITT_IA5; "Table A:  data category description, line 2"
+  0;  0;   5;    0;           0;   24;   CCITT_IA5; BUFR/CREX edition number
+  0;  0;  10;    0;           0;    8;   CCITT_IA5; F descriptor to be added or defined
+  0;  0;  11;    0;           0;   16;   CCITT_IA5; X descriptor to be added or defined
+  0;  0;  12;    0;           0;   24;   CCITT_IA5; Y descriptor to be added or defined
+  0;  0;  13;    0;           0;  256;   CCITT_IA5; "Element name, line 1"
+  0;  0;  14;    0;           0;  256;   CCITT_IA5; "Element name, line 2"
+  0;  0;  15;    0;           0;  192;   CCITT_IA5; Units name
+  0;  0;  16;    0;           0;    8;   CCITT_IA5; Units scale sign
+  0;  0;  17;    0;           0;   24;   CCITT_IA5; Units scale
+  0;  0;  18;    0;           0;    8;   CCITT_IA5; Units reference sign
+  0;  0;  19;    0;           0;   80;   CCITT_IA5; Units reference value
+  0;  0;  20;    0;           0;   24;   CCITT_IA5; Element data width
+  0;  0;  30;    0;           0;   48;   CCITT_IA5; Descriptor defining sequence
+# Class 01 - Identification
+  0;  1;   1;    0;           0;    7;     Numeric; WMO block number
+  0;  1;   2;    0;           0;   10;     Numeric; WMO station number
+  0;  1;   3;    0;           0;    3;  Code_Table; WMO Region number/geographical area
+  0;  1;   4;    0;           0;    3;     Numeric; WMO Region sub-area (see Note 9)
+  0;  1;   5;    0;           0;   17;     Numeric; Buoy/platform identifier
+  0;  1;   6;    0;           0;   64;   CCITT_IA5; Aircraft flight number
+  0;  1;   7;    0;           0;   10;  Code_Table; Satellite identifier
+  0;  1;   8;    0;           0;   64;   CCITT_IA5; Aircraft registration number
+  0;  1;   9;    0;           0;   64;   CCITT_IA5; Type of commercial aircraft
+  0;  1;  10;    0;           0;   64;   CCITT_IA5; Stationary buoy platform identifier; e.g. C-MAN buoys
+  0;  1;  11;    0;           0;   72;   CCITT_IA5; Ship or mobile land station identifier
+  0;  1;  12;    0;           0;    9; Degree_true; Direction of motion of moving observing platform
+  0;  1;  13;    0;           0;   10;       m s�1; Speed of motion of moving observing platform
+  0;  1;  14;    2;           0;   10;       m s�1; Platform drift speed (high precision)
+  0;  1;  15;    0;           0;  160;   CCITT_IA5; Station or site name
+  0;  1;  18;    0;           0;   40;   CCITT_IA5; Short station or site name
+  0;  1;  19;    0;           0;  256;   CCITT_IA5; Long Station or site name
+  0;  1;  20;    0;           0;    4;     Numeric; WMO Region sub-area
+  0;  1;  21;    0;           0;   14;     Numeric; Synoptic feature identifier
+  0;  1;  22;    0;           0;  224;   CCITT_IA5; Name of feature (see Note 11)
+  0;  1;  25;    0;           0;   24;   CCITT_IA5; Storm identifier
+  0;  1;  26;    0;           0;   64;   CCITT_IA5; WMO storm name*
+  0;  1;  27;    0;           0;   80;   CCITT_IA5; WMO long storm name
+  0;  1;  31;    0;           0;   16;  Code_Table; Identification of originating/generating centre (see Note 10)
+  0;  1;  32;    0;           0;    8;  Code_Table; Generating application
+  0;  1;  33;    0;           0;    8;  Code_Table; Identification of originating/generating centre
+  0;  1;  34;    0;           0;    8;  Code_Table; Identification of originating/generating sub-centre
+  0;  1;  36;    0;           0;   20;  Code_Table; Agency in charge of operating the Observing platform
+  0;  1;  41;    5; -1073741824;   31;       m s-1; Absolute platform velocity - first component (see Note 6)
+  0;  1;  42;    5; -1073741824;   31;       m s-1; Absolute platform velocity - second component (see Note 6)
+  0;  1;  43;    5; -1073741824;   31;       m s-1; Absolute platform velocity - third component (see Note 6)
+  0;  1;  50;    0;           0;   17;     Numeric; Platform transmitter ID number
+  0;  1;  51;    0;           0;   96;   CCITT_IA5; Platform transmitter ID number
+  0;  1;  60;    0;           0;   64;   CCITT_IA5; Aircraft reporting point (Beacon identifier)
+  0;  1;  62;    0;           0;   32;   CCITT_IA5; Short ICAO location indicator
+  0;  1;  63;    0;           0;   64;   CCITT_IA5; ICAO location indicator
+  0;  1;  64;    0;           0;   32;   CCITT_IA5; Runway designator
+  0;  1;  75;    0;           0;   40;   CCITT_IA5; Tide station identification
+  0;  1;  80;    0;           0;   32;   CCITT_IA5; Ship line number according to SOOP
+  0;  1;  85;    0;           0;  160;   CCITT_IA5; Observing platform manufacturer's model
+  0;  1;  86;    0;           0;  256;   CCITT_IA5; Observing platform manufacturer's serial number
+# Class 02 - Instrumentation
+  0;  2;   1;    0;           0;    2;  Code_Table; Type of station
+  0;  2;   2;    0;           0;    4;  Flag_Table; Type of instrumentation for wind measurement
+  0;  2;   3;    0;           0;    4;  Code_Table; Type of measuring equipment used
+  0;  2;   4;    0;           0;    4;  Code_Table; Type of instrumentation for evaporation measurement or type of crop for which evapotranspiration is reported
+  0;  2;   5;    2;           0;    7;           K; Precision of temperature observation
+  0;  2;  11;    0;           0;    8;  Code_Table; Radiosonde type
+  0;  2;  12;    0;           0;    4;  Code_Table; Radiosonde computational method
+  0;  2;  13;    0;           0;    4;  Code_Table; Solar and infrared radiation correction
+  0;  2;  14;    0;           0;    7;  Code_Table; Tracking technique/status of system used
+  0;  2;  15;    0;           0;    4;  Code_Table; Radiosonde completeness
+  0;  2;  19;    0;           0;   11;  Code_Table; Satellite instruments
+  0;  2;  20;    0;           0;    9;  Code_Table; Satellite classification
+  0;  2;  21;    0;           0;    9;  Flag_Table; Satellite instrument data used in processing*
+  0;  2;  22;    0;           0;    8;  Flag_Table; Satellite data-processing technique used
+  0;  2;  23;    0;           0;    4;  Code_Table; Satellite derived wind computation method
+  0;  2;  24;    0;           0;    4;  Code_Table; Integrated mean humidity computational method
+  0;  2;  25;    0;           0;   25;  Flag_Table; Satellite channel(s) used in computation
+  0;  2;  26;    2;           0;   12;           m; Cross track resolution
+  0;  2;  27;    2;           0;   12;           m; Along track resolution
+  0;  2;  28;    0;           0;   18;           m; Segment size at nadir in X direction
+  0;  2;  29;    0;           0;   18;           m; Segment size at nadir in Y direction
+  0;  2;  30;    0;           0;    3;  Code_Table; Method of current measurement
+  0;  2;  31;    0;           0;    5;  Code_Table; Duration and time of current measurement
+  0;  2;  32;    0;           0;    2;  Code_Table; Indicator for digitization
+  0;  2;  33;    0;           0;    3;  Code_Table; Method of salinity/depth measurement
+  0;  2;  34;    0;           0;    5;  Code_Table; Drogue type
+  0;  2;  35;    0;           0;    9;           m; Cable length
+  0;  2;  36;    0;           0;    2;  Code_Table; Buoy type
+  0;  2;  37;    0;           0;    3;  Code_Table; Method of tidal observation
+  0;  2;  38;    0;           0;    4;  Code_Table; Method of sea-surface temperature measurement
+  0;  2;  39;    0;           0;    3;  Code_Table; Method of wet-bulb temperature measurement
+  0;  2;  40;    0;           0;    4;  Code_Table; Method of removing velocity and motion of platform from current
+  0;  2;  41;    0;           0;    6;  Code_Table; Method for estimating reports related to synoptic features
+  0;  2;  44;    0;           0;    4;  Code_Table; Indicator for method of calculating spectral wave data
+  0;  2;  45;    0;           0;    4;  Code_Table; Indicator for type of platform
+  0;  2;  46;    0;           0;    4;  Code_Table; Wave measurement instrumentation
+  0;  2;  48;    0;           0;    4;  Code_Table; Satellite sensor indicator
+  0;  2;  49;    0;           0;    8;  Flag_Table; Geostationary satellite data-processing technique used
+  0;  2;  50;    0;           0;   20;  Flag_Table; Geostationary sounder satellite channels used
+  0;  2;  51;    0;           0;    4;  Code_Table; Indicator to specify observing method for extreme temperatures
+  0;  2;  52;    0;           0;    6;  Flag_Table; Geostationary imager satellite channels used
+  0;  2;  53;    0;           0;    4;  Code_Table; GOES-I/M brightness temperature characteristics
+  0;  2;  54;    0;           0;    4;  Code_Table; GOES-I/M soundings parameter characteristics
+  0;  2;  55;    0;           0;    4;  Code_Table; Geostationary soundings statistical parameters
+  0;  2;  56;    0;           0;    4;  Code_Table; Geostationary soundings accuracy statistics
+  0;  2;  57;    0;           0;    4;  Code_Table; Origin of first guess information for GOES-I/M soundings
+  0;  2;  58;    0;           0;    4;  Code_Table; Valid times of first guess information for GOES-I/M soundings
+  0;  2;  59;    0;           0;    4;  Code_Table; Origin of analysis information for GOES-I/M soundings
+  0;  2;  60;    0;           0;    4;  Code_Table; Origin of surface information for GOES-I/M soundings
+  0;  2;  61;    0;           0;    3;  Code_Table; Aircraft navigational system
+  0;  2;  62;    0;           0;    4;  Code_Table; Type of aircraft data relay system
+  0;  2;  63;    2;      -18000;   16;      Degree; Aircraft roll angle
+  0;  2;  64;    0;           0;    2;  Code_Table; Aircraft roll angle quality
+  0;  2;  65;    0;           0;   40;   CCITT_IA5; ACARS ground receiving station
+  0;  2;  70;    0;           0;    4;  Code_Table; Original specification of latitude/longitude
+  0;  2;  91;    0;           4;   10;           A; Entry sensor 4/20 mA
+  0;  2; 100;    1;           0;   12;          dB; Radar constant*
+  0;  2; 101;    0;           0;    4;  Code_Table; Type of antenna
+  0;  2; 102;    0;           0;    8;           m; Antenna height above tower base
+  0;  2; 103;    0;           0;    2;  Flag_Table; Radome
+  0;  2; 104;    0;           0;    4;  Code_Table; Antenna polarisation
+  0;  2; 105;    0;           0;    6;          dB; Maximum antenna gain
+  0;  2; 106;    1;           0;    6;      Degree; 3-dB beamwidth
+  0;  2; 107;    0;           0;    6;          dB; Sidelobe suppression
+  0;  2; 108;    0;           0;    6;          dB; Crosspol discrimination (on axis)
+  0;  2; 109;    2;           0;   12;  Degree s-1; Antenna speed (azimuth)
+  0;  2; 110;    2;           0;   12;  Degree s-1; Antenna speed (elevation)
+  0;  2; 111;    1;           0;   10;      Degree; Radar incidence angle
+  0;  2; 112;    1;           0;   12;      Degree; Radar look angle
+  0;  2; 113;    0;           0;    4;     Numeric; Number of azimuth looks
+  0;  2; 114;    0;           0;   15;          m2; Antenna effective surface area
+  0;  2; 121;   -8;           0;    7;          Hz; Mean frequency
+  0;  2; 122;   -6;        -128;    8;          Hz; Frequency agility range
+  0;  2; 123;   -4;           0;    7;           W; Peak power
+  0;  2; 124;   -1;           0;    7;           W; Average power
+  0;  2; 125;   -1;           0;    8;          Hz; Pulse repetition frequency
+  0;  2; 126;    7;           0;    6;           s; Pulse width
+  0;  2; 127;   -6;           0;    7;          Hz; Receiver intermediate frequency
+  0;  2; 128;   -5;           0;    6;          Hz; Intermediate frequency bandwidth
+  0;  2; 129;    0;        -150;    5;          dB; Minimum detectable signal
+  0;  2; 130;    0;           0;    7;          dB; Dynamic range
+  0;  2; 131;    0;           0;    2;  Flag_Table; Sensitivity time control (STC)
+  0;  2; 132;    2;           0;    6;      Degree; Azimuth pointing accuracy
+  0;  2; 133;    2;           0;    6;      Degree; Elevation pointing accuracy
+  0;  2; 134;    2;           0;   16;      Degree; Antenna beam azimuth
+  0;  2; 135;    2;       -9000;   15;      Degree; Antenna elevation
+  0;  2; 136;   -3;           0;   16;           m; Range processed by range attenuation correction
+  0;  2; 140;    0;           0;    9;      Degree; Satellite radar beam azimuth angle
+  0;  2; 141;    0;           0;   24;   CCITT_IA5; Measurement type
+  0;  2; 142;    0;           0;   32;   CCITT_IA5; Ozone instrument serial number/ identification
+  0;  2; 143;    0;           0;    7;  Code_Table; Ozone instrument type
+  0;  2; 144;    0;           0;    4;  Code_Table; Light source type for Brewer spectro photometer
+  0;  2; 145;    0;           0;    4;  Code_Table; Wave length setting for Dobson instruments
+  0;  2; 146;    0;           0;    4;  Code_Table; Source conditions for Dobson instruments
+  0;  2; 148;    0;           0;    5;  Code_Table; Data collection and/or location system
+  0;  2; 149;    0;           0;    6;  Code_Table; Type of data buoy
+  0;  2; 150;    0;           0;    6;  Code_Table; TOVS/ATOVS/AVHRR instrumentation channel number
+  0;  2; 151;    0;           0;   11;  Code_Table; Radiometer identifier
+  0;  2; 152;    0;           0;   31;  Flag_Table; Satellite instrument used in data processing(6)
+  0;  2; 153;   -8;           0;   26;          Hz; Satellite channel centre frequency
+  0;  2; 154;   -8;           0;   26;          Hz; Satellite channel band width
+  0;  2; 163;    0;           0;    4;  Code_Table; Height assignment method
+  0;  2; 164;    0;           0;    3;  Code_Table; Tracer correlation method
+  0;  2; 166;    0;           0;    4;  Code_Table; Radiance type
+  0;  2; 167;    0;           0;    4;  Code_Table; Radiance computational method
+  0;  2; 168;   -3;           0;   16;          Pa; Hydrostatic pressure of lower end of cable (thermistor string)
+  0;  2; 169;    0;           0;    4;  Code_Table; Anemometer type
+  0;  2; 172;    0;           0;    8;  Code_Table; Product type for retrieved atmospheric gases
+  0;  2; 190;    0;           0;    7;           %; Lagrangian drifter submergence (% time submerged)
+# Class 04 - Location (time)
+  0;  4;   1;    0;           0;   12;        Year; Year
+  0;  4;   2;    0;           0;    4;       Month; Month
+  0;  4;   3;    0;           0;    6;         Day; Day
+  0;  4;   4;    0;           0;    5;        Hour; Hour
+  0;  4;   5;    0;           0;    6;      Minute; Minute
+  0;  4;   6;    0;           0;    6;      Second; Second
+  0;  4;  11;    0;       -1024;   11;        Year; Time increment
+  0;  4;  12;    0;       -1024;   11;       Month; Time increment
+  0;  4;  13;    0;       -1024;   11;         Day; Time increment
+  0;  4;  14;    0;       -1024;   11;        Hour; Time increment
+  0;  4;  15;    0;       -2048;   12;      Minute; Time increment
+  0;  4;  16;    0;       -4096;   13;      Second; Time increment
+  0;  4;  17;    0;       -1440;   12;      Minute; Reference time period for accumulated or extreme data
+  0;  4;  21;    0;       -1024;   11;        Year; Time period or displacement
+  0;  4;  22;    0;       -1024;   11;       Month; Time period or displacement
+  0;  4;  23;    0;       -1024;   11;         Day; Time period or displacement
+  0;  4;  24;    0;       -2048;   12;        Hour; Time period or displacement
+  0;  4;  25;    0;       -2048;   12;      Minute; Time period or displacement
+  0;  4;  26;    0;       -4096;   13;      Second; Time period or displacement
+  0;  4;  31;    0;           0;    8;        Hour; Duration of time relating to following value
+  0;  4;  32;    0;           0;    6;      Minute; Duration of time relating to following value
+  0;  4;  41;    0;       -1440;   12;      Minute; "Time difference, UTC -LMT (see Note 6)"
+  0;  4;  43;    0;           0;    9;         Day; Day of the year
+  0;  4;  53;    0;           0;    6;     Numeric; Number of days with precipitation equal to or more than 1 mm
+  0;  4;  65;    0;        -128;    8;      Minute; Short time increment
+  0;  4;  73;    0;        -128;    8;         Day; Short time period or displacement
+  0;  4;  74;    0;        -128;    8;        Hour; Short time period or displacement
+  0;  4;  75;    0;        -128;    8;      Minute; Short time period or displacement
+# Class 05 - Location (horizontal -1)
+  0;  5;   1;    5;    -9000000;   25;      Degree; Latitude (high accuracy)
+  0;  5;   2;    2;       -9000;   15;      Degree; Latitude (coarse accuracy)
+  0;  5;  11;    5;    -9000000;   25;      Degree; Latitude increment (high accuracy)
+  0;  5;  12;    2;       -9000;   15;      Degree; Latitude increment (coarse accuracy)
+  0;  5;  21;    2;           0;   16; Degree_true; Bearing or azimuth
+  0;  5;  22;    2;           0;   16; Degree_true; Solar azimuth
+  0;  5;  30;    0;           0;   12;      Degree; Direction (spectral)
+  0;  5;  31;    0;           0;   12;     Numeric; Row number
+  0;  5;  33;   -1;           0;   16;           m; Pixel size on horizontal - 1
+  0;  5;  34;    0;           0;   11;     Numeric; Along track row number
+  0;  5;  36;    0;           0;    7;     Numeric; Ship transect number according to SOOP
+  0;  5;  40;    0;           0;   24;     Numeric; Orbit number
+  0;  5;  41;    0;           0;    8;     Numeric; Scan line number
+  0;  5;  42;    0;           0;    6;     Numeric; Channel number
+  0;  5;  43;    0;           0;    8;     Numeric; Field of view number
+  0;  5;  52;    0;           0;    5;     Numeric; Channel number increment
+  0;  5;  53;    0;           0;    5;     Numeric; Field of view number increment
+# Class 06 - Location (horizontal - 2)
+  0;  6;   1;    5;   -18000000;   26;      Degree; Longitude (high accuracy)
+  0;  6;   2;    2;      -18000;   16;      Degree; Longitude (coarse accuracy)
+  0;  6;  11;    5;   -18000000;   26;      Degree; Longitude increment (high accuracy)
+  0;  6;  12;    2;      -18000;   16;      Degree; Longitude increment (coarse accuracy)
+  0;  6;  21;   -1;           0;   13;           m; Distance
+  0;  6;  30;    5;           0;   13;     rad m-1; Wave number (spectral)
+  0;  6;  31;    0;           0;   12;     Numeric; Column number
+  0;  6;  33;   -1;           0;   16;           m; Pixel size on horizontal - 2
+  0;  6;  34;    0;           0;    7;     Numeric; Cross-track cell number
+  0;  6;  40;    0;           0;   13;           m; Radius of confidence
+# Class 07 - Location (vertical
+  0;  7;   1;    0;        -400;   15;           m; Height of station
+  0;  7;   2;   -1;         -40;   16;           m; Height or altitude
+  0;  7;   3;   -1;        -400;   17;      m2 s-2; Geopotential
+  0;  7;   4;   -1;           0;   14;          Pa; Pressure
+  0;  7;   5;    0;        -400;   12;           m; Height increment
+  0;  7;   6;    0;           0;   15;           m; Height above station
+  0;  7;   7;    0;       -1000;   17;           m; Height
+  0;  7;   8;    0;      -10000;   20;      m2 s-2; Geopotential
+  0;  7;   9;    0;       -1000;   17;         gpm; Geopotential height
+  0;  7;  21;    2;       -9000;   15;      Degree; Elevation (see Note 1)
+  0;  7;  22;    2;       -9000;   15;      Degree; Solar elevation
+  0;  7;  24;    2;       -9000;   15;      Degree; Satellite zenith angle
+  0;  7;  25;    2;       -9000;   15;      Degree; Solar zenith angle
+  0;  7;  61;    2;           0;   14;           m; Depth below land surface
+  0;  7;  62;    1;           0;   17;           m; Depth below sea/water surface
+  0;  7;  64;    0;           0;    4;           m; Height above station (sensor height artificially corrected) (see Note 2)
+  0;  7;  70;    0;           0;   10;           m; Drogue depth
+# Class 08 - Significance qualifiers
+  0;  8;   1;    0;           0;    7;  Flag_Table; Vertical sounding significance
+  0;  8;   2;    0;           0;    6;  Code_Table; Vertical significance (surface observations)
+  0;  8;   3;    0;           0;    6;  Code_Table; Vertical significance (satellite observations)
+  0;  8;   4;    0;           0;    3;  Code_Table; Phase of aircraft flight
+  0;  8;   5;    0;           0;    4;  Code_Table; Meteorological attribute significance
+  0;  8;   6;    0;           0;    9;  Flag_Table; Ozone vertical sounding significance
+  0;  8;   7;    0;           0;    4;  Code_Table; Dimensional significance
+  0;  8;   8;    0;           0;    9;  Flag_Table; Radiation vertical sounding significance
+  0;  8;  11;    0;           0;    6;  Code_Table; Meteorological feature
+  0;  8;  12;    0;           0;    2;  Code_Table; Land/sea qualifier
+  0;  8;  13;    0;           0;    2;  Code_Table; Day/night qualifier
+  0;  8;  14;    0;           0;    4;  Code_Table; Qualifier for runway visual range
+  0;  8;  16;    0;           0;    3;  Code_Table; Change qualifier of a trend-type forecast or an aerodrome forecast
+  0;  8;  17;    0;           0;    2;  Code_Table; Qualifier of the time when the forecast change is expected
+  0;  8;  18;    0;           0;   17;  Flag_Table; SEAWINDS land/ice surface type
+  0;  8;  20;    0;           0;   16;     Numeric; Total number of missing entities (with respect to accumulation or average)
+  0;  8;  21;    0;           0;    5;  Code_Table; Time significance
+  0;  8;  22;    0;           0;   16;     Numeric; Total number (with respect to accumulation or average)
+  0;  8;  23;    0;           0;    6;  Code_Table; First order statistics
+  0;  8;  24;    0;           0;    6;  Code_Table; Difference statistics
+  0;  8;  25;    0;           0;    4;  Code_Table; Time difference qualifier
+  0;  8;  30;    0;           0;   13;     Numeric; "Manual on Codes (Volume I.1, Section C) Code table from which data are derived"
+  0;  8;  31;    0;           0;    8;     Numeric; Data category CREX table A
+  0;  8;  33;    0;           0;    7;  Code_Table; Method of derivation of percentage confidence
+  0;  8;  35;    0;           0;    3;  Code_Table; Type of monitoring exercise
+  0;  8;  36;    0;           0;    3;  Code_Table; Type of centre or station performing monitoring
+  0;  8;  51;    0;           0;    3;  Code_Table; Qualifier for number of missing values in calculation of statistic
+  0;  8;  52;    0;           0;    5;  Code_Table; Condition for which number of days of occurrence follows
+  0;  8;  53;    0;           0;    2;  Code_Table; Day of occurrence qualifier
+  0;  8;  60;    0;           0;    4;  Code_Table; Sample scanning mode significance
+  0;  8;  70;    0;           0;    4;  Code_Table; TOVS/ATOVS product qualifier
+  0;  8;  72;    0;           0;    3;  Code_Table; Pixel(s) type
+  0;  8;  75;    0;           0;    2;  Code_Table; Ascending/Descending Orbit Qualifier
+# Class 10 - Non-coordinate location (vertical)
+  0; 10;   1;    0;        -400;   15;           m; Height of land surface
+  0; 10;   2;   -1;         -40;   16;           m; Height
+  0; 10;   3;   -1;        -400;   17;      m2 s-2; Geopotential
+  0; 10;   4;   -1;           0;   14;          Pa; Pressure
+  0; 10;   7;    0;       -1000;   17;           m; Height
+  0; 10;   8;    0;      -10000;   20;      m2 s-2; Geopotential
+  0; 10;   9;    0;       -1000;   17;         gpm; Geopotential height
+  0; 10;  10;   -1;           0;   14;          Pa; Minimum pressure reduced to mean sea level
+  0; 10;  11;   -1;           0;   14;          Pa; Maximum pressure reduced to mean sea level
+  0; 10;  31;    2; -1073741824;   31;           m; "In direction of the North Pole, distance from the Earth�s centre"
+  0; 10;  40;    0;           0;   10;     Numeric; Number of retrieved layers
+  0; 10;  50;    2;           0;   16;           m; Standard deviation altitude
+  0; 10;  51;   -1;           0;   14;          Pa; Pressure reduced to mean sea level
+  0; 10;  52;   -1;           0;   14;          Pa; Altimeter setting (QNH)
+  0; 10;  60;   -1;       -1024;   11;          Pa; Pressure change
+  0; 10;  61;   -1;        -500;   10;          Pa; 3-hour pressure change
+  0; 10;  62;   -1;       -1000;   11;          Pa; 24-hour pressure change
+  0; 10;  63;    0;           0;    4;  Code_Table; Characteristic of pressure tendency
+  0; 10;  70;    0;        -400;   16;           m; Indicated aircraft altitude
+# Class 11 - Wind and turbulence
+  0; 11;   1;    0;           0;    9; Degree_true; Wind direction
+  0; 11;   2;    1;           0;   12;       m s-1; Wind speed
+  0; 11;   3;    1;       -4096;   13;       m s-1; u-component
+  0; 11;   4;    1;       -4096;   13;       m s-1; v-component
+  0; 11;   5;    1;        -512;   10;      Pa s-1; w-component
+  0; 11;   6;    2;       -4096;   13;       m s-1; w-component
+  0; 11;  10;    0;           0;    9; Degree_true; Wind direction associated with wind speed which follows
+  0; 11;  11;    0;           0;    9; Degree_true; Wind direction at 10 m
+  0; 11;  12;    1;           0;   12;       m s-1; Wind speed at 10 m
+  0; 11;  13;    0;           0;    9; Degree_true; Wind direction at 5 m
+  0; 11;  14;    1;           0;   12;       m s-1; Wind speed at 5 m
+  0; 11;  16;    0;           0;    9; Degree_true; Extreme counterclockwise wind direction of a variable wind
+  0; 11;  17;    0;           0;    9; Degree_true; Extreme clockwise wind direction of a variable wind
+  0; 11;  19;    0;           0;    7;           %; Steadiness of wind (6)
+  0; 11;  21;    9;      -65536;   17;         s-1; Relative vorticity
+  0; 11;  22;    9;      -65536;   17;         s-1; Divergence
+  0; 11;  23;   -2;      -65536;   17;      m2 s-1; Velocity potential
+  0; 11;  31;    0;           0;    4;  Code_Table; Degree of turbulence
+  0; 11;  32;   -1;         -40;   16;           m; Height of base of turbulence
+  0; 11;  33;   -1;         -40;   16;           m; Height of top of turbulence
+  0; 11;  34;    1;       -1024;   11;       m s-1; Vertical gust velocity
+  0; 11;  35;    2;       -8192;   14;       m s-2; Vertical gust acceleration
+  0; 11;  36;    1;           0;   10;       m s-1; Maximum derived equivalent vertical gust speed
+  0; 11;  37;    0;           0;    6;  Code_Table; Turbulence Index
+  0; 11;  38;    0;           0;    5;  Code_Table; Time of occurrence of Peak Eddy Dissipation Rate
+  0; 11;  40;    1;           0;   12;       m s-1; Maximum wind speed (mean wind)
+  0; 11;  41;    1;           0;   12;       m s-1; Maximum wind speed (gusts)
+  0; 11;  42;    1;           0;   12;       m s-1; Maximum wind speed (10-min mean wind)
+  0; 11;  43;    0;           0;    9; Degree_true; Maximum wind gust direction
+  0; 11;  44;    0;           0;    9; Degree_true; Mean wind direction for surface - 1500 m (5000 feet)
+  0; 11;  45;    1;           0;   12;       m s-1; Mean wind speed for surface - 1500 m (5000 feet)
+  0; 11;  46;    1;           0;   12;       m s-1; Maximum instantaneous wind speed
+  0; 11;  47;    1;           0;   12;       m s-1; Maximum instantaneous wind speed over 10 minutes
+  0; 11;  49;    0;           0;    9; Degree_true; Standard deviation of wind direction
+  0; 11;  50;    1;           0;   12;       m s-1; Standard deviation of horizontal wind speed
+  0; 11;  51;    1;           0;    8;       m s-1; Standard deviation of vertical wind speed
+  0; 11;  52;    2;           0;   13;       m s-1; Formal uncertainty in wind speed
+  0; 11;  53;    2;           0;   15; Degree_true; Formal uncertainty in wind direction
+  0; 11;  61;    1;           0;   12;       m s-1; Absolute wind shear in 1 km layer below
+  0; 11;  62;    1;           0;   12;       m s-1; Absolute wind shear in 1 km layer above
+  0; 11;  70;    0;           0;   32;   CCITT_IA5; Designator of the runway affected by wind shear (including ALL)
+  0; 11;  71;    3;        -128;   14;      m2 s-2; Turbulent vertical momentum flux
+  0; 11;  72;    3;        -128;   11;     K m s-1; Turbulent vertical buoyancy flux
+  0; 11;  73;    2;       -1024;   13;      m2 s-2; Turbulent kinetic energy
+  0; 11;  74;    2;       -1024;   10;      m2 s-2; Dissipation energy
+  0; 11;  75;    2;           0;    8;    m2/3 s-1; Mean turbulence intensity (eddy dissipation rate)
+  0; 11;  76;    2;           0;    8;    m2/3 s-1; Peak turbulence intensity (eddy dissipation rate)
+  0; 11;  81;    2;           0;   16; Degree_true; Model wind direction at 10m
+  0; 11;  82;    2;           0;   14;       m s-1; Model wind speed at 10m
+# Class 12 - Temperature
+  0; 12;   1;    1;           0;   12;           K; Temperature/dry-bulb temperature
+  0; 12;   2;    1;           0;   12;           K; Wet-bulb temperature
+  0; 12;   3;    1;           0;   12;           K; Dew-point temperature
+  0; 12;   4;    1;           0;   12;           K; Dry-bulb temperature at 2 m
+  0; 12;   5;    1;           0;   12;           K; Wet-bulb temperature at 2 m
+  0; 12;   6;    1;           0;   12;           K; Dew-point temperature at 2 m
+  0; 12;   7;    1;           0;   12;           K; Virtual temperature
+  0; 12;  11;    1;           0;   12;           K; "Maximum temperature, at height and over period specified"
+  0; 12;  12;    1;           0;   12;           K; "Minimum temperature, at height and over period specified"
+  0; 12;  13;    1;           0;   12;           K; "Ground minimum temperature, past 12 hours"
+  0; 12;  14;    1;           0;   12;           K; "Maximum temperature at 2 m, past 12 hours"
+  0; 12;  15;    1;           0;   12;           K; "Minimum temperature at 2 m, past 12 hours"
+  0; 12;  16;    1;           0;   12;           K; "Maximum temperature at 2 m, past 24 hours"
+  0; 12;  17;    1;           0;   12;           K; "Minimum temperature at 2 m, past 24 hours"
+  0; 12;  21;    2;           0;   16;           K; Maximum temperature at 2m
+  0; 12;  22;    2;           0;   16;           K; Minimum temperature at 2m
+  0; 12;  30;    1;           0;   12;           K; Soil temperature
+  0; 12;  51;    1;           0;   10;           K; Standard deviation temperature
+  0; 12;  52;    1;           0;   12;           K; Highest daily mean temperature
+  0; 12;  53;    1;           0;   12;           K; Lowest daily mean temperature
+  0; 12;  61;    1;           0;   12;           K; Skin temperature
+  0; 12;  62;    1;           0;   12;           K; Equivalent black body temperature
+  0; 12;  63;    1;           0;   12;           K; Brightness temperature
+  0; 12;  64;    1;           0;   12;           K; Instrument temperature
+  0; 12;  65;    1;           0;   12;           K; Standard deviation brightness temperature
+  0; 12;  71;    1;           0;   12;           K; Coldest cluster temperature
+  0; 12;  72;    6;           0;   31;  W m-2 sr-1; Radiance
+  0; 12;  75;   -3;           0;   16;  W m-3 sr-1; Spectral radiance
+  0; 12;  76;    3;           0;   16;  W m-2 sr-1; Radiance
+  0; 12; 101;    2;           0;   16;           K; Temperature/dry-bulb temperature
+  0; 12; 102;    2;           0;   16;           K; Wet-bulb temperature
+  0; 12; 103;    2;           0;   16;           K; Dew-point temperature
+  0; 12; 104;    2;           0;   16;           K; Dry-bulb temperature at 2m
+  0; 12; 105;    2;           0;   16;           K; Web-bulb temperature at 2m
+  0; 12; 106;    2;           0;   16;           K; Dew-point temperature at 2m
+  0; 12; 107;    2;           0;   16;           K; Virtual temperature
+  0; 12; 111;    2;           0;   16;           K; "Maximum temperature, at height and over period specified "
+  0; 12; 112;    2;           0;   16;           K; "Minimum temperature, at height and over period specified"
+  0; 12; 113;    2;           0;   16;           K; "Ground minimum temperature, past 12 hours"
+  0; 12; 114;    2;           0;   16;           K; "Maximum temperature at 2m, past 12 hours"
+  0; 12; 115;    2;           0;   16;           K; "Minimum temperature at 2m, past 12 hours"
+  0; 12; 116;    2;           0;   16;           K; "Maximum temperature at 2m, past 24 hours"
+  0; 12; 117;    2;           0;   16;           K; "Minimum temperature at 2m, past 24 hours"
+  0; 12; 130;    2;           0;   16;           K; Soil temperature
+  0; 12; 152;    2;           0;   16;           K; Highest daily mean temperature
+  0; 12; 153;    2;           0;   16;           K; Lowest daily mean temperature
+  0; 12; 161;    2;           0;   16;           K; Skin temperature
+  0; 12; 162;    2;           0;   16;           K; Equivalent black body temperature
+  0; 12; 163;    2;           0;   16;           K; Brightness temperature
+  0; 12; 164;    2;           0;   16;           K; Instrument temperature
+  0; 12; 171;    2;           0;   16;           K; Coldest cluster temperature
+# Class 13 - Hygrographic and hydrological elements
+  0; 13;   1;    5;           0;   14;     kg kg-1; Specific humidity
+  0; 13;   2;    5;           0;   14;     kg kg-1; Mixing ratio
+  0; 13;   3;    0;           0;    7;           %; Relative humidity
+  0; 13;   4;   -1;           0;   10;          Pa; Vapour pressure
+  0; 13;   5;    3;           0;    7;      kg m-3; Vapour density
+  0; 13;   6;   -1;         -40;   16;           m; Mixing heights
+  0; 13;   7;    0;           0;    7;           %; Minimum relative humidity
+  0; 13;   8;    0;           0;    7;           %; Maximum relative humidity
+  0; 13;  11;    1;          -1;   14;      kg m-2; Total precipitation/total water equivalent
+  0; 13;  12;    2;          -2;   12;           m; Depth of fresh snow
+  0; 13;  13;    2;          -2;   16;           m; Total snow depth
+  0; 13;  14;    4;           0;   12;  kg m-2 s-1; Rainfall/water equivalent of snow (averaged rate)
+  0; 13;  15;    7;           0;   12;       m s-1; Snowfall  (averaged rate)
+  0; 13;  16;    0;           0;    7;      kg m-2; Precipitable water
+  0; 13;  19;    1;          -1;   14;      kg m-2; Total precipitation past 1 hour
+  0; 13;  20;    1;          -1;   14;      kg m-2; Total precipitation past 3 hours
+  0; 13;  21;    1;          -1;   14;      kg m-2; Total precipitation past 6 hours
+  0; 13;  22;    1;          -1;   14;      kg m-2; Total precipitation past 12 hours
+  0; 13;  23;    1;          -1;   14;      kg m-2; Total precipitation past 24 hours
+  0; 13;  31;    0;           0;    7;      kg m-2; Evapotranspiration
+  0; 13;  32;    1;           0;    8;      kg m-2; Evaporation/evapotranspiration
+  0; 13;  33;    1;           0;   10;      kg m-2; Evaporation/evapotranspiration
+  0; 13;  38;    0;           0;    2;  Code_Table; Superadiabatic indicator
+  0; 13;  39;    0;           0;    3;  Code_Table; Terrain type (ice/snow)
+  0; 13;  41;    0;           0;    4;  Code_Table; Pasquill-Gifford stability category
+  0; 13;  42;    0;         -20;    6;           K; Parcel lifted index (to 500 hPa)
+  0; 13;  43;    0;         -20;    6;           K; Best lifted index (to 500 hPa)
+  0; 13;  51;    0;           0;    4;  Code_Table; "Frequency group, precipitation"
+  0; 13;  52;    1;          -1;   14;      kg m-2; Highest daily amount of precipitation
+  0; 13;  55;    4;           0;    8;  Kg m-2 s-1; Intensity of precipitation
+  0; 13;  58;    4;           0;    7;           m; Size of precipitating element
+  0; 13;  59;    0;           0;    7;     Numeric; Number of flashes (thunderstorm)
+  0; 13;  60;    1;         -10;   17;      kg m-2; Total accumulated precipitation
+  0; 13;  71;    2;           0;   14;           m; Upstream water level
+  0; 13;  72;    2;           0;   14;           m; Downstream water level
+  0; 13;  73;    2;           0;   14;           m; Maximum water level
+  0; 13;  80;    1;           0;   10;     pH unit; Water pH
+  0; 13;  81;    3;           0;   14; Siemens m-1; Water conductivity
+  0; 13;  82;    1;           0;   12;           K; Water temperature
+  0; 13;  83;    6;           0;   15;      Kg m-3; Dissolved oxygen
+  0; 13;  84;    0;           0;   14;       Lumen; Turbidity
+  0; 13;  85;    3;           0;   14;           V; Oxydation Reduction Potential (ORP)
+# Class 14 - Radiation and radiance
+  0; 14;   1;   -3;       -2048;   12;       J m-2; "Long-wave radiation, integrated over 24 hours"
+  0; 14;   2;   -3;       -2048;   12;       J m-2; "Long-wave radiation, integrated over period specified"
+  0; 14;   3;   -3;       -2048;   12;       J m-2; "Short-wave radiation, integrated over 24 hours"
+  0; 14;   4;   -3;       -2048;   12;       J m-2; "Short-wave radiation, integrated over period specified"
+  0; 14;  11;   -3;       -2048;   12;       J m-2; "Net long-wave radiation, integrated over 24 hours"
+  0; 14;  12;   -3;       -2048;   12;       J m-2; "Net long-wave radiation, integrated over period specified"
+  0; 14;  13;   -3;       -2048;   12;       J m-2; "Net short-wave radiation, integrated over 24 hours"
+  0; 14;  14;   -3;       -2048;   12;       J m-2; "Net short-wave radiation, integrated over period specified"
+  0; 14;  15;   -4;      -16384;   15;       J m-2; "Net radiation, integrated over 24 hours"
+  0; 14;  16;   -4;      -16384;   15;       J m-2; "Net radiation, integrated over period specified"
+  0; 14;  17;   -3;       -2048;   12;       W m-2; Instantaneous long-wave radiation
+  0; 14;  18;   -3;       -2048;   12;       W m-2; Instantaneous short-wave radiation
+  0; 14;  19;    0;           0;    7;           %; Surface albedo
+  0; 14;  20;   -4;           0;   15;       J m-2; "Global solar radiation, integrated over 24 hours"
+  0; 14;  21;   -4;           0;   15;       J m-2; "Global radiation, integrated over period specified"
+  0; 14;  22;   -4;           0;   15;       J m-2; "Diffuse solar radiation, integrated over 24 hours"
+  0; 14;  23;   -4;           0;   15;       J m-2; "Diffuse solar radiation, integrated over period specified"
+  0; 14;  24;   -4;           0;   15;       J m-2; "Direct solar radiation, integrated over 24 hours"
+  0; 14;  25;   -4;           0;   15;       J m-2; "Direct solar radiation, integrated over period specified"
+  0; 14;  26;    0;           0;    7;           %; Albedo at the top of clouds
+  0; 14;  27;    0;           0;    7;           %; Albedo
+  0; 14;  28;   -2;           0;   16;       J m-2; "Global solar radiation (high accuracy), integrated over period specified"
+  0; 14;  29;   -2;           0;   16;       J m-2; "Diffuse solar radiation (high accuracy), integrated over period specified"
+  0; 14;  30;   -2;           0;   16;       J m-2; "Direct solar radiation (high accuracy), integrated over period specified"
+  0; 14;  31;    0;           0;   11;      Minute; Total sunshine
+  0; 14;  32;    0;           0;   10;        Hour; Total sunshine
+  0; 14;  33;    0;           0;    9;           %; Total sunshine
+  0; 14;  34;    0;           0;   11;      Minute; Sunshine over period specified
+  0; 14;  42;    0;           0;    7;           %; Bi-directional reflectance
+  0; 14;  45;    0;           0;   11;Wm-2 sr-1 cm-1; Channel radiance
+  0; 14;  51;   -3;           0;   14;       J m-2; Direct solar radiation integrated over last hour
+# Class 15 - Physical/chemical constituents
+  0; 15;   1;    0;           0;   10;      Dobson; Ozone
+  0; 15;   2;    2;           0;   10;     Numeric; Air mass (slant path at 22 km)
+  0; 15;   3;    4;           0;    9;      Pascal; Measured ozone partial pressure (sounding)
+  0; 15;   4;    3;           0;   11;     Numeric; Ozone sounding correction factor
+  0; 15;   5;    0;           0;   10;          DU; Ozone p
+  0; 15;  11;    3;       14000;   13;  log (1/m2); Log 10 of integrated electron density
+  0; 15;  15;    0;           0;   31;     Numeric; Maximum image spectral component before normalization
+  0; 15;  20;    8;           0;   21;      kg m-2; Integrated 03 density
+# Class 19 - Synoptic features
+  0; 19;   1;    0;           0;    6;  Code_Table; Type of synoptic feature
+  0; 19;   2;   -2;           0;   12;           m; Effective radius of feature
+  0; 19;   3;    0;           0;    8;       m s-1; Wind speed threshold
+  0; 19;   4;   -2;           0;   12;           m; Effective radius with respect to wind speeds above threshold
+  0; 19;   5;    0;           0;    9; Degree_true; Direction of motion of feature
+  0; 19;   6;    2;           0;   14;       m s-1; Speed of motion of feature
+  0; 19;   7;   -3;           0;   12;           m; Effective radius of feature
+  0; 19;   8;    0;           0;    3;  Code_Table; Vertical extent of circulation
+  0; 19;   9;   -3;           0;   12;           m; Effective radius with respect to wind speeds above threshold (large storms)
+  0; 19;  10;    0;           0;    4;  Code_Table; Method for tracking the centre of synoptic feature
+# Class 20 - Observed phenomena
+  0; 20;   1;   -1;           0;   13;           m; Horizontal visibility
+  0; 20;   2;   -1;           0;    7;           m; Vertical visibility
+  0; 20;   3;    0;           0;    9;  Code_Table; Present weather (see note 1)
+  0; 20;   4;    0;           0;    5;  Code_Table; Past weather (1) (see note 2)
+  0; 20;   5;    0;           0;    5;  Code_Table; Past weather (2) (see note 2)
+  0; 20;   8;    0;           0;    5;  Code_Table; Cloud distribution for aviation
+  0; 20;   9;    0;           0;    4;  Code_Table; General Weather Indicator (TAF/METAR)
+  0; 20;  10;    0;           0;    7;           %; Cloud cover (total)
+  0; 20;  11;    0;           0;    4;  Code_Table; Cloud amount
+  0; 20;  12;    0;           0;    6;  Code_Table; Cloud type
+  0; 20;  13;   -1;         -40;   11;           m; Height of base of cloud
+  0; 20;  14;   -1;         -40;   11;           m; Height of top of cloud
+  0; 20;  15;   -1;           0;   14;          Pa; Pressure at base of cloud
+  0; 20;  16;   -1;           0;   14;          Pa; Pressure at top of cloud
+  0; 20;  17;    0;           0;    4;  Code_Table; Cloud top description
+  0; 20;  18;    0;           0;    2;  Code_Table; Tendency of runway visual range
+  0; 20;  19;    0;           0;   72;   CCITT_IA5; Significant present or forecast weather
+  0; 20;  20;    0;           0;   32;   CCITT_IA5; Significant recent weather phenomena
+  0; 20;  21;    0;           0;   30;  Flag_Table; Type of precipitation
+  0; 20;  22;    0;           0;    4;  Code_Table; Character of precipitation
+  0; 20;  23;    0;           0;   18;  Flag_Table; Other weather phenomena
+  0; 20;  24;    0;           0;    3;  Code_Table; Intensity of phenomena
+  0; 20;  25;    0;           0;   21;  Flag_Table; Obscuration
+  0; 20;  26;    0;           0;    4;  Code_Table; Character of obscuration
+  0; 20;  27;    0;           0;    9;  Flag_Table; Phenomena occurrence
+  0; 20;  31;    2;           0;    7;           m; Ice deposit (thickness)
+  0; 20;  32;    0;           0;    3;  Code_Table; Rate of ice accretion
+  0; 20;  33;    0;           0;    4;  Flag_Table; Cause of ice accretion
+  0; 20;  34;    0;           0;    5;  Code_Table; Sea ice concentration
+  0; 20;  35;    0;           0;    4;  Code_Table; Amount and type of ice
+  0; 20;  36;    0;           0;    5;  Code_Table; Ice situation
+  0; 20;  37;    0;           0;    5;  Code_Table; Ice development
+  0; 20;  38;    0;           0;   12; Degree_true; Bearing of ice edge (see note 3)
+  0; 20;  39;   -1;           0;   13;           m; Ice distance
+  0; 20;  41;    0;           0;    4;  Code_Table; Airframe icing
+  0; 20;  51;    0;           0;    7;           %; Amount of low clouds
+  0; 20;  52;    0;           0;    7;           %; Amount of middle clouds
+  0; 20;  53;    0;           0;    7;           %; Amount of high clouds
+  0; 20;  61;    0;           0;   12;           m; Runway visual range (RVR)
+  0; 20;  62;    0;           0;    5;  Code_Table; State of the ground (with or without snow)
+  0; 20;  63;    0;           0;   10;  Code_Table; Special phenomena
+  0; 20;  70;    0;           0;    7;     Numeric; Minimum number of atmospherics
+  0; 20;  71;    0;           0;    4;  Code_Table; Accuracy of fix and rate of atmospherics
+  0; 20;  81;    0;           0;    7;           %; Cloud amount in segment
+  0; 20;  82;    0;           0;    7;           %; Amount segment cloud free
+  0; 20;  90;    0;           0;    4;  Code_Table; Special clouds
+# Class 21 - Radar data
+  0; 21;   1;    0;         -64;    7;          dB; Horizontal reflectivity
+  0; 21;   2;    0;         -64;    7;          dB; Vertical reflectivity
+  0; 21;   3;    1;          -5;    7;          dB; Differential reflectivity
+  0; 21;   5;    0;         -65;    6;          dB; Linear depolarisation ratio 
+  0; 21;   6;    0;         -65;    6;          dB; Circular depolarisation ratio 
+  0; 21;  11;    0;        -128;    8;       m s-1; Doppler mean velocity in X-direction
+  0; 21;  12;    0;        -128;    8;       m s-1; Doppler mean velocity in Y-direction
+  0; 21;  13;    0;        -128;    8;       m s-1; Doppler mean velocity in Z-direction
+  0; 21;  14;    1;       -4096;   13;       m s-1; Doppler mean velocity (radial)
+  0; 21;  17;    1;           0;    8;       m s-1; Doppler velocity spectral width
+  0; 21;  21;   -3;           0;    4;           m; Echo tops 
+  0; 21;  30;    0;         -32;    8;          dB; Signal to noise ratio
+  0; 21;  31;    0;           0;    7;      kg m-2; Vertically integrated liquid-water content
+  0; 21;  36;    7;           0;   12;       m s-1; Radar rainfall intensity 
+  0; 21;  41;   -2;           0;    8;           m; Bright-band height 
+  0; 21;  51;    0;        -256;    8;          dB; Signal power above 1 mW
+  0; 21;  62;    2;       -5000;   13;    Decibels; Backscatter
+  0; 21;  63;    1;           0;   10;           %; Radiometric resolution (noise value)
+  0; 21;  64;    0;           0;    8;     Numeric; Clutter noise estimate
+  0; 21;  65;    0;        -127;    8;     Numeric; Missing packet counter
+  0; 21;  66;    0;           0;   12;  Flag_Table; Wave scatterometer product confidence data
+  0; 21;  67;    0;           0;   13;  Flag_Table; Wind product confidence data
+  0; 21;  68;    0;           0;    8;  Flag_Table; Radar altimeter product confidence data
+  0; 21;  69;    0;           0;   10;  Flag_Table; SST product confidence data
+  0; 21;  70;    0;           0;   23;  Flag_Table; SST product confidence data (SADIST-2)
+  0; 21;  71;    0;           0;   16;     Numeric; Peakiness
+  0; 21;  72;    0;           0;    4;  Flag_Table; Satellite altimeter calibration status
+  0; 21;  73;    0;           0;    9;  Flag_Table; Satelllite altimeter instrument mode
+  0; 21;  75;    0;           0;    8;     Numeric; Image spectrum intensity
+  0; 21;  76;    0;           0;    3;  Code_Table; Representation of intensities
+  0; 21;  77;    3;           0;   14;           m; Altitude correction (ionosphere)
+  0; 21;  78;    3;           0;    9;           m; Altitude correction (dry troposphere)
+  0; 21;  79;    3;        2000;   10;           m; Altitude correction (wet troposphere)
+  0; 21;  80;    3;           0;   11;           m; Altitude correction (calibration constant)
+  0; 21;  81;    3;           0;   10;           m; Open loop correction (height-time loop)
+  0; 21;  82;    3;       -3000;   14;          dB; Open loop correction (auto gain control)
+  0; 21;  85;    0;           0;    4;     Numeric; ATSR sea surface temperature across- track band number
+  0; 21;  91;    0;        -100;    8;          dB; Radar signal Doppler spectrum 0th moment
+  0; 21;  92;    0;        -100;    8;          dB; "RASS signal Doppler spectrum 0th moment, referring to RASS signal"
+  0; 21; 101;    0;           0;    3;     Numeric; Number of vector ambiguities
+  0; 21; 102;    0;           0;    3;     Numeric; Index of selected wind vector
+  0; 21; 103;    0;           0;    5;     Numeric; Total number of sigma-0 measurements
+  0; 21; 104;    3;      -30000;   15;     Numeric; Likelihood computed for solution
+  0; 21; 105;    2;      -10000;   14;          dB; Normalized radar cross-section
+  0; 21; 106;    3;           0;   14;     Numeric; Kp variance coefficient (Alpha)
+  0; 21; 107;    8;           0;   16;     Numeric; Kp variance coefficient (Beta)
+  0; 21; 109;    0;           0;   17;  Flag_Table; SEAWINDS wind vector cell quality
+  0; 21; 110;    0;           0;    6;     Numeric; Number of inner-beam Sigma-0 (forward of satellite)
+  0; 21; 111;    0;           0;    6;     Numeric; Number of outer-beam Sigma-0 (forward of satellite)
+  0; 21; 112;    0;           0;    6;     Numeric; Number of inner-beam Sigma-0 (aft of satellite)
+  0; 21; 113;    0;           0;    6;     Numeric; Number of outer-beam Sigma-0 (aft of satellite)
+  0; 21; 114;    3;     -140000;   18;          dB; Kp variance coefficent (Gamma)
+  0; 21; 115;    0;           0;   17;  Flag_Table; SEAWINDS sigma-0 quality
+  0; 21; 116;    0;           0;   17;  Flag_Table; SEAWINDS sigma-0 mode
+  0; 21; 117;    2;           0;   16;     Numeric; Sigma-0 variance quality control
+  0; 21; 118;    2;      -10000;   14;          dB; Attenuation correction on sigma-0
+  0; 21; 119;    0;           0;    6;  Code_Table; Wind scatterometer geophysical model function
+  0; 21; 120;    3;           0;   10;     Numeric; Probability of rain
+  0; 21; 121;    0;           0;    8;     Numeric; SEAWINDS NOF* rain index
+  0; 21; 122;    2;      -10000;   14;          dB; Attenuation correction of sigma-0 (from tB)
+  0; 21; 123;    2;      -30000;   15;          dB; SEAWINDS normalized radar cross section
+# Class 22 - Oceanographic elements
+  0; 22;   1;    0;           0;    9; Degree_true; Direction of waves 
+  0; 22;   2;    0;           0;    9; Degree_true; Direction of wind waves 
+  0; 22;   3;    0;           0;    9; Degree_true; Direction of swell waves 
+  0; 22;   4;    0;           0;    9; Degree_true; Direction of current 
+  0; 22;  11;    0;           0;    6;           s; Period of waves 
+  0; 22;  12;    0;           0;    6;           s; Period of wind waves 
+  0; 22;  13;    0;           0;    6;           s; Period of swell waves 
+  0; 22;  21;    1;           0;   10;           m; Height of waves 
+  0; 22;  22;    1;           0;   10;           m; Height of wind waves 
+  0; 22;  23;    1;           0;   10;           m; Height of swell waves 
+  0; 22;  25;    2;           0;   10;           m; Standard deviation wave height
+  0; 22;  26;    2;           0;   10;           m; Standard deviation of significant wave height
+  0; 22;  31;    2;           0;   13;       m s-1; Speed of current 
+  0; 22;  35;    2;           0;   14;           m; Tidal elevation with respect to local chart datum
+  0; 22;  36;    2;           0;   14;           m; Meteorological residual tidal elevation (surge or offset)
+  0; 22;  37;    3;      -10000;   15;           m; Tidal elevation with respect to national land datum
+  0; 22;  38;    3;      -10000;   15;           m; Tidal elevation with respect to local chart datum
+  0; 22;  39;    3;       -5000;   12;           m; Meteorological residual tidal elevation (surge or offset)
+  0; 22;  40;    3;       -5000;   14;           m; Meteorological residual tidal elevation (surge or offset)
+  0; 22;  41;    1;           0;   12;           K; Sea-surface temperature (15-day running mean)
+  0; 22;  42;    1;           0;   12;           K; Sea/water temperature
+  0; 22;  43;    2;           0;   15;           K; Sea/water temperature
+  0; 22;  44;    1;           0;   14;       m s-1; Sound velocity 
+  0; 22;  45;    3;           0;   19;           K; Sea/water temperature
+  0; 22;  50;    2;           0;    8;           K; Standard deviation sea-surface temperature
+  0; 22;  55;    0;           0;   10;     Numeric; Float cycle number
+  0; 22;  56;    0;           0;    2;  Code_Table; Direction of profile
+  0; 22;  61;    0;           0;    4;  Code_Table; State of the sea 
+  0; 22;  62;    2;           0;   14;Part per thousand; Salinity
+  0; 22;  63;    0;           0;   14;           m; Total water depth 
+  0; 22;  64;    3;           0;   17;Part per thousand; Salinity
+  0; 22;  65;   -3;           0;   17;          Pa; Water pressure
+  0; 22;  66;    6;           0;   26;       S m-1; Water conductivity
+  0; 22;  67;    0;           0;   10;  Code_Table; Instrument type for water temperature profile measurement
+  0; 22;  68;    0;           0;    7;  Code_Table; Water temperature profile recorder types
+  0; 22;  70;    2;           0;   13;           m; Significant wave height
+  0; 22;  71;    1;           0;    9;           s; Spectral peak wave period
+  0; 22;  72;    0;           0;   13;           m; Spectral peak wave length
+  0; 22;  73;    2;           0;   13;           m; Maximum wave height
+  0; 22;  74;    1;           0;    9;           s; Average wave period
+  0; 22;  75;    0;           0;   13;           m; Average wave length
+  0; 22;  76;    0;           0;    9; Degree_true; Direction from which dominant waves are coming
+  0; 22;  77;    0;           0;    9;      Degree; Directional spread of dominant wave
+  0; 22;  78;    0;           0;   12;           s; Duration of wave record
+  0; 22;  79;    0;           0;   16;           m; Length of wave record
+  0; 22;  80;    3;           0;   10;          Hz; Waveband central frequency
+  0; 22;  81;    5;           0;   13;         m-1; Waveband central wave number
+  0; 22;  82;    2;           0;   20;        m2 s; Maximum non-directional spectral wave density
+  0; 22;  83;    2;           0;   20;          m3; Maximum non-directional spectral wave number
+  0; 22;  84;    0;           0;    7;     Numeric; Band containing maximum non- directional spectral wave density
+  0; 22;  85;    0;           0;    7;     Numeric; Spectral wave density ratio
+  0; 22;  86;    0;           0;    9; Degree_true; Mean direction from which waves are coming
+  0; 22;  87;    0;           0;    9; Degree_true; Principal direction from which waves are coming
+  0; 22;  88;    2;           0;    7;     Numeric; First normalized polar coordinate from Fourier coefficients
+  0; 22;  89;    2;           0;    7;     Numeric; Second normalized polar coordinate from Fourier coefficients
+  0; 22;  90;    2;           0;   20;        m2 s; Non-directional spectral estimate by wave frequency
+  0; 22;  91;    2;           0;   20;          m3; Non-directional spectral estimate by wave number
+  0; 22;  92;    2;           0;   20;  m2 rad-1 s; Directional spectral estimate by wave frequency
+  0; 22;  93;    2;           0;   20;          m4; Directional spectral estimate by wave number
+  0; 22;  94;    0;           0;    7;     Numeric; Total number of wave bands
+  0; 22;  95;    0;           0;    8;      Degree; Directional spread of individual waves
+  0; 22;  96;    3;           0;    4;         s-1; Spectral band width
+  0; 22;  97;    0;           0;   14;           m; Mean wavelength > 731 m of image spectrum at low wave numbers
+  0; 22;  98;    0;           0;   14;           m; Wavelength spread (wavelength > 731 m) at low wave numbers
+  0; 22;  99;    0;           0;    9; Degree_true; Mean direction at low wave numbers (wavelength > 731 m)
+  0; 22; 100;    0;           0;    9;      Degree; Direction spread at low wave numbers(wavelength > 731 m)
+  0; 22; 101;    0;           0;   31;     Numeric; Total energy (wavelength > 731m) at low wave numbers
+  0; 22; 120;    0;           0;    5;  Code_Table; Tide station automated water level check
+  0; 22; 121;    0;           0;    5;  Code_Table; Tide station manual water level check
+  0; 22; 122;    0;           0;    5;  Code_Table; Tide station automated meteorological data check
+  0; 22; 123;    0;           0;    5;  Code_Table; Tide station manual meteorological data check
+  0; 22; 141;    2;           0;   15;           K; Sea-surface temperature (15-day running mean)
+# Class 23 - Dispersal and transport
+  0; 23;   1;    0;           0;    3;  Code_Table; Accident early notification � article applicable
+  0; 23;   2;    0;           0;    5;  Code_Table; Activity or facility involved in incident
+  0; 23;   3;    0;           0;    3;  Code_Table; Type of release 
+  0; 23;   4;    0;           0;    3;  Code_Table; Countermeasures taken near border
+  0; 23;   5;    0;           0;    2;  Code_Table; Cause of incident 
+  0; 23;   6;    0;           0;    3;  Code_Table; Incident situation 
+  0; 23;   7;    0;           0;    3;  Code_Table; Characteristics of release
+  0; 23;   8;    0;           0;    2;  Code_Table; State of current release 
+  0; 23;   9;    0;           0;    2;  Code_Table; State of expected release 
+  0; 23;  16;    0;           0;    2;  Code_Table; Possibility of significant chemical toxic health effect
+  0; 23;  17;    6;           0;   20;     m3 s-1 ; Flow discharge of major recipient
+  0; 23;  18;    0;           0;    3;  Code_Table; Release behaviour over time
+  0; 23;  19;    0;      -15000;   17;           m; Actual release height
+  0; 23;  21;    0;      -15000;   17;           m; Effective release height
+  0; 23;  22;    0;           0;   24;           m; Distance of release point or site of incident
+  0; 23;  23;    1;           0;   12;     m s-1  ; Main transport speed in the atmosphere
+  0; 23;  24;    2;           0;   13;     m s-1  ; Main transport speed in water
+  0; 23;  25;    2;           0;   13;     m s-1  ; Main transport speed in ground water
+  0; 23;  27;    0;           0;    9; Degree_true; Main transport direction in the atmosphere
+  0; 23;  28;    0;           0;    9; Degree_true; Main transport direction in water
+  0; 23;  29;    0;           0;    9; Degree_true; Main transport direction in ground water
+  0; 23;  31;    0;           0;    2;  Code_Table; Possibility that plume will encounter precipitation in State in which incident occurred
+  0; 23;  32;    0;           0;    2;  Code_Table; Plume will encounter change in wind direction and/or speed flag
+# Class 24 - Radiological elements
+  0; 24;   1;  -11;           0;   28;         Bq*; Estimate of amount of radioactivity released up to specified time
+  0; 24;   2;  -11;           0;   28;          Bq; Estimated maximum potential release
+  0; 24;   3;    0;           0;    5;  Code_Table; Composition of release
+  0; 24;   4;    0;           0;   16;   CCITT_IA5; Element name
+  0; 24;   5;    0;           0;    9;     Numeric; Isotope mass
+  0; 24;  11;    2;           0;   32;     mSv*/**; Dose
+  0; 24;  12;    2;           0;   32;         mSv; Trajectory dose (defined location and expected time of arrival)
+  0; 24;  13;    2;           0;   32;         mSv; Gamma dose in air along the main transport path (defined location and time period)
+  0; 24;  21;    2;           0;   32;      Bq m-3; Air concentration (of named isotope type including gross beta)
+  0; 24;  22;    2;           0;   32;      Bq 1-1; Concentration in precipitation (of names isotope type)
+  0; 24;  23;    1;           0;   14;         s-1; Pulse rate of beta radiation
+  0; 24;  24;    1;           0;   14;         s-1; Pulse rate of gamma radiation
+# Class 25 - Processing information
+  0; 25;   1;   -1;           0;    6;           m; Range-gate length
+  0; 25;   2;    0;           0;    4;     Numeric; Number of gates averaged
+  0; 25;   3;    0;           0;    8;     Numeric; Number of integrated pulses
+  0; 25;   4;    0;           0;    2;  Code_Table; Echo processing
+  0; 25;   5;    0;           0;    2;  Code_Table; Echo integration
+  0; 25;   6;    0;           0;    3;  Code_Table; Z to R conversion
+  0; 25;   7;    0;           0;   12;     Numeric; Z to R conversion factor
+  0; 25;   8;    2;           0;    9;     Numeric; Z to R conversion exponent
+  0; 25;   9;    0;           0;    4;  Flag_Table; Calibration method
+  0; 25;  10;    0;           0;    4;  Code_Table; Clutter treatment
+  0; 25;  11;    0;           0;    2;  Code_Table; Ground occultation correction (screening)
+  0; 25;  12;    0;           0;    2;  Code_Table; Range attenuation correction
+  0; 25;  13;    0;           0;    2;  Flag_Table; Bright-band correction
+  0; 25;  14;    0;           0;   12;     Numeric; Azimuth clutter cut-off (see Note)
+  0; 25;  15;    0;           0;    2;  Flag_Table; Radome attenuation correction
+  0; 25;  16;    5;           0;    6;      dB m-1; Clear-air attenuation correction
+  0; 25;  17;    0;           0;    2;  Flag_Table; Precipitation attenuation correction
+  0; 25;  18;    7;           0;    6;     Numeric; A to Z law for attenuation factor
+  0; 25;  19;    2;           0;    7;     Numeric; A to Z law for attenuation exponent
+  0; 25;  20;    0;           0;    2;  Code_Table; Mean speed estimation
+  0; 25;  21;    0;           0;    8;  Flag_Table; Wind computation enhancement
+  0; 25;  25;    1;           0;    9;           V; Battery voltage
+  0; 25;  30;    0;           0;    2;  Code_Table; Running mean sea-surface temperature usage
+  0; 25;  32;    0;           0;    2;  Code_Table; Wind profiler mode information*
+  0; 25;  33;    0;           0;    2;  Code_Table; Wind profiler submode information*
+  0; 25;  34;    0;           0;    4;  Flag_Table; Wind profiler quality control test results* 
+  0; 25;  36;    0;           0;    4;  Code_Table; Atmospherics location method
+  0; 25;  40;    0;           0;    4;  Code_Table; CO2 wind product derivation
+  0; 25;  41;    0;           0;    2;  Code_Table; Moving platform direction reporting method
+  0; 25;  42;    0;           0;    2;  Code_Table; Moving platform speed reporting method
+  0; 25;  43;    4;           0;   15;           s; Wave sampling interval (time)
+  0; 25;  44;    2;           0;   14;           m; Wave sampling interval (space)
+  0; 25;  45;    0;           0;   21;  Flag_Table; HIRS channel combination
+  0; 25;  46;    0;           0;    5;  Flag_Table; MSU channel combination
+  0; 25;  47;    0;           0;    4;  Flag_Table; SSU channel combination
+  0; 25;  48;    0;           0;   16;  Flag_Table; AMSU-A channel combination
+  0; 25;  49;    0;           0;    6;  Flag_Table; AMSU-B channel combination
+  0; 25;  51;    0;           0;    7;  Flag_Table; AVHRR channel combination
+  0; 25;  53;    0;           0;   12;  Flag_Table; Observation quality
+  0; 25;  60;    0;           0;   14;     Numeric; Software identification
+  0; 25;  70;    0;           0;    4;     Numeric; Major frame count
+  0; 25;  71;    0;           0;    5;     Numeric; Frame count
+  0; 25;  75;    0;           0;    5;     Numeric; Satellite antenna corrections version number
+  0; 25;  76;    8;           0;   30;     Log m-1; Log-10 of (Temperature-radiance central wavenumber) for ATOVS
+  0; 25;  77;    5;     -100000;   18;     Numeric; Bandwidth correction coefficient 1 for ATOVS
+  0; 25;  78;    5;           0;   17;     Numeric; Bandwidth correction coefficient 2 for ATOVS
+  0; 25;  79;    4;           0;   24;       W m-2; Albedo-radiance solar filtered irradiance for ATOVS
+  0; 25;  80;   10;           0;   14;           m; Albedo-radiance equivalent filter width for ATOVS
+  0; 25;  85;    0;           0;    7;     Numeric; Fraction of clear pixels in HIRS FOV
+  0; 25;  86;    0;           0;    2;  Code_Table; Depth correction indicator
+  0; 25;  91;    3;      -18192;   13;          dB; Structure constant of the refraction index (cn2)
+  0; 25;  92;    2;       28000;   14;       m s-1; Acoustic propagation velocity
+  0; 25;  93;    0;           0;    8;  Flag_Table; RASS computation correction
+  0; 25; 100;    5;           0;   20;     Numeric; XBT/XCTD fall rate equation coefficient a
+  0; 25; 101;    5;     -500000;   21;     Numeric; XBT/XCTD fall rate equation coefficient b
+# Class 26 - Non-coordinate location (time)
+  0; 26;   1;    1;           0;   12;        Hour; Principal time of daily reading in UTC of maximum temperature
+  0; 26;   2;    1;           0;   12;        Hour; Principal time of daily reading in UTC of minimum temperature
+  0; 26;   3;    0;       -1440;   12;      Minute; Time difference
+  0; 26;  10;    0;           0;   26;  Flag_Table; Hours included
+# Class 27 - Non-coordinate location (horizontal - 1
+  0; 27;   1;    5;    -9000000;   25;      Degree; Latitude (high accuracy)
+  0; 27;   2;    2;       -9000;   15;      Degree; Latitude (coarse accuracy)
+  0; 27;   3;    2;       -9000;   15;      Degree; Alternate latitude (coarse accuracy)
+  0; 27;   4;    5;    -9000000;   25;      Degree; Alternate latitude (high accuracy)
+  0; 27;  20;    0;           0;   16;     Numeric; Satellite location counter
+  0; 27;  21;    0;           0;   16;     Numeric; Satellite sublocation dimension
+  0; 27;  31;    2; -1073741824;   31;           m; "In direction of 0 degrees longitude, distance from the Earth�s centre"
+# Class 28 - Non-coordinate location (horizontal - 2)
+  0; 28;   1;    5;   -18000000;   26;      Degree; Longitude (high accuracy)
+  0; 28;   2;    2;      -18000;   16;      Degree; Longitude (coarse accuracy)
+  0; 28;   3;    2;      -18000;   16;      Degree; Alternate longitude (coarse accuracy)
+  0; 28;   4;    5;   -18000000;   26;      Degree; Alternate longitude (high accuracy)
+  0; 28;  31;    2; -1073741824;   31;           m; "In direction 90 degrees East, distance from the Earth�s centre"
+# Class 29 - Map data
+  0; 29;   1;    0;           0;    3;  Code_Table; Projection type
+  0; 29;   2;    0;           0;    3;  Code_Table; Co-ordinate grid type
+# Class 30 - Image
+  0; 30;   1;    0;           0;    4;     Numeric; Pixel value (4 bits)
+  0; 30;   2;    0;           0;    8;     Numeric; Pixel value (8 bits)
+  0; 30;   4;    0;           0;   16;     Numeric; Pixel value (16 bits)
+  0; 30;  21;    0;           0;   12;     Numeric; Number of pixels per row
+  0; 30;  22;    0;           0;   12;     Numeric; Number of pixels per column
+  0; 30;  31;    0;           0;    4;  Code_Table; Picture type
+  0; 30;  32;    0;           0;   16;  Flag_Table; Combination with other data
+# Class 31 - Data description operator qualifiers (this class does not exist in CREX
+  0; 31;   0;    0;           0;    1;     Numeric; Short delayed descriptor replication factor
+  0; 31;   1;    0;           0;    8;     Numeric; Delayed descriptor replication factor
+  0; 31;   2;    0;           0;   16;     Numeric; Extended delayed descriptor replication factor
+  0; 31;  11;    0;           0;    8;     Numeric; Delayed descriptor and data repetition factor
+  0; 31;  12;    0;           0;   16;     Numeric; Extended delayed descriptor and data repetition factor
+  0; 31;  21;    0;           0;    6;  Code_Table; Associated field significance
+  0; 31;  31;    0;           0;    1;  Flag_Table; Data present indicator
+# Class 33 - Quality information
+  0; 33;   2;    0;           0;    2;  Code_Table; Quality information
+  0; 33;   3;    0;           0;    3;  Code_Table; Quality information
+  0; 33;   7;    0;           0;    7;           %; Per cent confidence
+  0; 33;  20;    0;           0;    3;  Code_Table; Quality control indication of following value
+  0; 33;  21;    0;           0;    2;  Code_Table; Quality of following value
+  0; 33;  22;    0;           0;    2;  Code_Table; Quality of buoy satellite transmission
+  0; 33;  23;    0;           0;    2;  Code_Table; Quality of buoy location
+  0; 33;  24;    0;           0;    4;  Code_Table; Station elevation quality mark (for mobile stations)
+  0; 33;  25;    0;           0;    3;  Code_Table; ACARS interpolated values
+  0; 33;  26;    0;           0;    6;  Code_Table; Moisture quality
+  0; 33;  27;    0;           0;    3;  Code_Table; Location quality class (range of radius of 66 % confidence)
+  0; 33;  30;    0;           0;   24;  Flag_Table; Scan line status flags for ATOVS
+  0; 33;  31;    0;           0;   24;  Flag_Table; Scan line quality flags for ATOVS
+  0; 33;  32;    0;           0;   24;  Flag_Table; Channel quality flags for ATOVS
+  0; 33;  33;    0;           0;   24;  Flag_Table; Field of view quality flags for ATOVS
+  0; 33;  35;    0;           0;    4;  Code_Table; Manual/automatic quality control
+  0; 33;  36;    0;           0;    7;           %; Nominal confidence threshold
+  0; 33;  37;    0;           0;   20;  Flag_Table; Wind correlation error
+  0; 33;  40;    0;           0;    7;           %; Confidence interval
+  0; 33;  41;    0;           0;    2;  Code_Table; Attribute of following value
+# Class 35 - Data monitoring information
+  0; 35;   0;    0;           0;   10;  Code_Table; FM and regional code number
+  0; 35;   1;    0;           0;    3;  Code_Table; Time-frame for monitoring
+  0; 35;  11;    0;           0;   14;     Numeric; Number of reports actually received
+  0; 35;  21;    0;           0;   48;   Character; Bulletin being monitored (TTAAii)
+  0; 35;  22;    0;           0;   48;   Character; Bulletin being monitored (YYGGgg)
+  0; 35;  30;    0;           0;    4;  Code_Table; Discrepancies in the availability of expected data
+  0; 35;  31;    0;           0;    7;  Code_Table; Qualifier on monitoring results
+  0; 35;  32;    0;           0;    4;  Code_Table; Cause of missing data
+  0; 35;  33;    0;           0;    7;  Code_Table; Observation and collection deficiencies
+  0; 35;  34;    0;           0;    3;  Code_Table; Statistical trends for availability of data (during the survey period(s))
diff --git a/data/tables/B3M-000-010-D b/data/tables/B3M-000-010-D
new file mode 100644
index 0000000..377d666
--- /dev/null
+++ b/data/tables/B3M-000-010-D
@@ -0,0 +1,2397 @@
+#
+# WMO source file name = BufrTabD-11-2001.txt
+# Master Table D Version 10
+#
+#-----------------------------------------------------
+# F X Y --> Table D descriptor being defined
+#      F X Y --> 
+#      F X Y --> descriptors defining sequence for
+#      F X Y --> corresponding Table D descriptor
+#      -1 --> end of sequence designator
+#------------------------------------------------------
+#  Category 00 - BUFR table entries sequences
+  3   0   2
+      0   0   2  "Table A category, line 1"
+      0   0   3  "Table A category, line 2"
+     -1
+  3   0   3
+      0   0  10  "F,  part descriptor"
+      0   0  11  "X,  part descriptor"
+      0   0  12  "Y,  part descriptor"
+     -1
+  3   0   4
+      3   0   3
+      0   0  13  "Element name, line 1"
+      0   0  14  "Element name, line 2"
+      0   0  15  Units name
+      0   0  16  Units scale sign
+      0   0  17  Units scale
+      0   0  18  Units reference sign
+      0   0  19  Units reference value
+      0   0  20  Element data width
+     -1
+  3   0  10
+      3   0   3  Table D descriptor to be defined
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Delayed descriptor replication factor
+      0   0  30  Descriptor defining sequence
+     -1
+#  Category 01 - Location and Identification sequences
+  3   1   1
+      0   1   1  WMO block number
+      0   1   2  WMO station number
+     -1
+  3   1   2
+      0   1   3  WMO Region number
+      0   1   4  WMO Region sub-area
+      0   1   5  Buoy/platform identifier
+     -1
+  3   1   3
+      0   1  11  Ship's call sign
+      0   1  12  Direction of motion of moving observing platform
+      0   1  13  Speed of motion of moving observing platform
+     -1
+  3   1  11
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+     -1
+  3   1  12
+      0   4   4  Hour
+      0   4   5  Minute
+     -1
+  3   1  13
+      0   4   4  Hour
+      0   4   5  Minute
+      0   4   6  Second
+     -1
+  3   1  21
+      0   5   1  Latitude- high accuracy
+      0   6   1  Longitude - high accuracy
+     -1
+  3   1  22
+      0   5   1  Latitude- high accuracy
+      0   6   1  Longitude- high accuracy
+      0   7   1  Height of station
+     -1
+  3   1  23
+      0   5   2  Latitude- coarse accuracy
+      0   6   2  Longitude- coarse accuracy
+     -1
+  3   1  24
+      0   5   2  Latitude- coarse accuracy
+      0   6   2  Longitude - coarse accuracy
+      0   7   1  Height of station
+     -1
+  3   1  25
+      3   1  23  Latitude and longitude (coarse accuracy)
+      0   4   3  Day
+      3   1  12  Time
+     -1
+  3   1  26
+      3   1  21  Latitude and longitude (high accuracy)
+      0   4   3
+      0   4   3  (Time period in days)
+      0   4   4
+      0   4   4  (Time period in hours)
+      0   4   5
+      0   4   5  (Time period in minutes)
+     -1
+  3   1  31
+      3   1   1  WMO block and station number
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  22  "Latitude and longitude (high  accuracy), height of station"
+     -1
+  3   1  32
+      3   1   1  WMO block and station number
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  24  "Latitude and longitude (coarse accuracy), height of station"
+     -1
+#  (Buoy/platform � fixed)
+  3   1  33
+      0   1   5  Buoy/platform identifier
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  21  Latitude and longitude (high accuracy)
+     -1
+#  (Buoy/platform � fixed)
+  3   1  34
+      0   1   5  Buoy/platform identifier
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+     -1
+#  (Buoy/platform � moving)
+  3   1  35
+      0   1   5  Buoy/platform identifier
+      0   1  12  Direction of motion of moving observing platform
+      0   1  13  Speed of motion of moving observing platform
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+     -1
+#  (Ship)
+  3   1  36
+      3   1   3  Ship's call sign and motion
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+     -1
+#  (Land station for vertical soundings)
+  3   1  37
+      3   1   1  WMO block and station number
+      0   2  11  Radiosonde type
+      0   2  12  Radiosonde computational method
+      3   1  11  Date
+      3   1  12  Time
+      3   1  22  "Latitude and longitude (high accuracy), height of station"
+     -1
+#  (Land station for vertical soundings)
+  3   1  38
+      3   1   1  WMO block and station number
+      0   2  11  Radiosonde type
+      0   2  12  Radiosonde computational method
+      3   1  11  Date
+      3   1  12  Time
+      3   1  24  "Latitude and longitude (coarse accuracy), height of station"
+     -1
+#  (Ship for vertical soundings)
+  3   1  39
+      3   1   3  Ship's call sign and motion
+      0   2  11  Radiosonde type
+      0   2  12  Radiosonde computational method
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+     -1
+  3   1  40
+      3   1   3  Ship's call sign and motion
+      0   2  11  Radiosonde type
+      0   2  12  Radiosonde computational method
+      3   1  11  Date
+      3   1  12  Time
+      3   1  24  "Latitude and longitude (coarse accuracy), height of station"
+     -1
+  3   1  41
+      0   1   7  Satellite identifier
+      0   2  21  Satellite instrument data used in processing
+      0   2  22  Satellite data processing technique used
+      3   1  11  Date
+      3   1  12  Time
+     -1
+  3   1  42
+      3   1  41  "Satellite identifier, data used, and data processing technique; date/time"
+      3   1  21  "Latitude, longitude"
+     -1
+  3   1  43
+      0   1   7  Satellite identifier
+      0   2  23  Cloud motion computational method
+      3   1  11  Date
+      3   1  13  Time
+      3   1  21  "Latitude, longitude"
+     -1
+  3   1  44
+      0   1   7  Satellite identifier
+      0   2  24  Integrated mean humidity computational method
+      3   1  11  Date
+      3   1  13  Time
+      3   1  21  "Latitude, longitude"
+     -1
+#  (Satellite location and velocity)
+  3   1  45
+      3   1  11  "Year, month, day"
+      3   1  12  "Time (hour, minute)"
+      2   1 138  Change width to 16 bits
+      2   2 131  Change scale to 3
+      0   4   6  Second
+      2   1   0  Change width back to Table B
+      2   2   0  Change scale back to Table B
+      3   4  30  Location relative to the Earth�s centre
+      3   4  31  Velocity relative to the Earth�s centre
+     -1
+  3   1  46
+      0   1   7  Satellite identifier
+      0   1  12  Direction of motion of moving observing platform
+      0   2  48  Satellite sensor indicator
+      0  21 119  Wind scatterometer geophysical model function
+      0  25  60  Software identification
+      2   2 124  Change scale
+      0   2  26  Cross-track resolution
+      0   2  27  Along-tract resolution
+      2   2   0  Change scale back to Table B
+      0   5  40  Orbit number
+     -1
+#  (ERS product header)
+  3   1  47
+      0   1   7  Satellite identifier
+      0  25  60  Software identification
+      0   1  33  Originating/generating centre
+      0   1  34  Originating/generating sub-centre
+      0   1  12  Direction of motion of moving observation platform
+      3   1  45  Satellite location and velocity
+      0   2  21  Satellite instrument data used in processing
+      3   1  11  "Date (year, month, day)"
+      3   1  12  "Time (hour, minute)"
+      2   1 138  Change bit width to 16 bits
+      2   2 131  Change scale to 3
+      0   4   6  Second
+      2   1   0  Change width back to Table B
+      2   2   0  Change scale back to Table B
+      3   1  23  "Location (latitude, longitude)"
+     -1
+#  (Radar parameters)
+  3   1  48
+      0   2 104  Antenna polarization
+      0   2 121  Mean frequency
+      0   2 113  Number of azimuth looks
+      0   2  26  Cross-track resolution
+      0   2  27  Along-track resolution
+      0   2 111  Radar incidence angle
+      0   2 140  Satellite radar beam azimuth angle
+      2   2 127  Change scale to �1
+      0   1  13  Radar platform velocity
+      2   2 126  Change scale to �2
+      0   7   1  Radar platform altitude
+      2   2   0  Change scale to Table B
+      0  25  10  Clutter treatment
+      0  21  64  Clutter noise estimate
+     -1
+#  (Radar beam data)
+  3   1  49
+      0   2 111  Radar incidence angle
+      0   2 112  Radar look angle
+      0  21  62  Backscatter
+      0  21  63  Radiometric resolution (Noise value)
+      0  21  65  Missing packet counter
+     -1
+  3   1  51
+      0   1   6  Aircraft identifier
+      0   2  61  Navigational system
+      3   1  11  Date
+      3   1  12  Time
+      3   1  21  "Latitude, longitude"
+      0   8   4  Phase of aircraft flight
+     -1
+  3   1  55
+      0   1   5  Buoy/platform identifier
+      0   2   1  Type of station
+      3   1  11  Date
+      3   1  12  Time
+      3   1  21  Latitude and longitude (high accuracy)
+      0   1  12  Direction of motion of moving observing platform
+      0   1  14  Platform drift speed (high precision)
+     -1
+#  (Radar location(s))
+  3   1  62
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   1   1  WMO block and station number
+     -1
+#  (ACARS identification)
+  3   1  65
+      0   1   6  Aircraft flight number (see Note)
+      0   1   8  Aircraft registration number (see Note)
+      0   2   1  Type of station
+      0   2   2  Type of instrumentation for wind measurement
+      0   2   5  Precision of temperature observation
+      0   2  62  Type of aircraft data relay system
+      0   2  70  Original specification of latitude/longitude
+      0   2  65  ACARS ground receiving station
+     -1
+#  (ACARS location)
+  3   1  66
+      3   1  11  "Year, month, day"
+      3   1  13  "Hour, minute, second"
+      3   1  23  Latitude and longitude (coarse accuracy)
+      0   7   4  Pressure
+      0   2  64  Aircraft roll angle quality
+      0   8   4  Phase of aircraft flight
+     -1
+#  (Satellite identifier/Generating resolution)
+  3   1  71
+      0   1   7  Satellite identifier
+      0   1  31  Generating centre
+      0   2  20  Satellite classification
+      0   2  28  Segment size at nadir in X direction
+      0   2  29  Segment size at nadir in Y direction
+     -1
+#  (Satellite identification)
+  3   1  72
+      3   1  71  "Satellite identification, Generation resolution"
+      3   1  11  Date
+      3   1  13  Time
+      3   1  21  "Latitude, longitude"
+     -1
+#  Category 02 - Meteorological sequences common to surface data
+  3   2   1
+      0  10   4  Pressure (at station level)
+      0  10  51  Pressure reduced to mean sea level
+      0  10  61  3-hour pressure change
+      0  10  63  Characteristic of pressure tendency
+     -1
+#  (High altitude station)
+  3   2   2
+      0  10   4  Pressure (at station level)
+      0   7   4  Pressure level
+      0  10   3  Geopotential of pressure level
+      0  10  61  3-hour pressure change
+      0  10  63  Characteristic of pressure tendency
+     -1
+  3   2   3
+      0  11  11  Wind direction (10 m)
+      0  11  12  Wind speed (10 m)
+      0  12   4  Temperature (2 m)
+      0  12   6  Dew point (2 m)
+      0  13   3  Relative humidity
+      0  20   1  Horizontal visibility
+      0  20   3  Present weather
+      0  20   4  Past weather (1)
+      0  20   5  Past weather (2)
+     -1
+#  (General cloud information)
+  3   2   4
+      0  20  10  Cloud cover (total)
+      0   8   2  Vertical significance
+      0  20  11  Cloud amount
+      0  20  13  Height of base of cloud
+      0  20  12  Cloud type
+      0  20  12  Cloud type
+      0  20  12  Cloud type
+     -1
+  3   2   5
+      0   8   2  Vertical significance
+      0  20  11  Cloud amount
+      0  20  12  Cloud type
+      0  20  13  Height of base of cloud
+     -1
+  3   2   6
+      0  10   4  Pressure (at station level)
+      0  10  51  Pressure reduced to mean sea level
+      0  10  62  24-hour pressure change
+      0  10  63  Characteristic of pressure tendency
+     -1
+#  (Low altitude station)
+  3   2  11
+      3   2   1  Pressure and pressure change
+      3   2   3  "Wind, temperature, humidity, visibility, weather"
+      3   2   4  Significant cloud layer
+     -1
+#  (High altitude station)
+  3   2  12
+      3   2   2  Pressure and pressure change
+      3   2   3  "Wind, temperature, humidity, visibility, weather"
+      3   2   4  Significant cloud information
+     -1
+  3   2  13
+      3   2   6  Pressure and pressure change
+      3   2   3  "Wind, temperature, humidity, visibility, weather"
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Delayed descriptor replication factor
+      3   2   5  Cloud layer information
+     -1
+  3   2  21
+      0  22   1  Direction of waves
+      0  22  11  Period of waves
+      0  22  21  Height of waves
+     -1
+  3   2  22
+      0  22   2  Direction of wind waves
+      0  22  12  Period of wind waves
+      0  22  22  Height of wind waves
+     -1
+  3   2  23
+      0  22   3  Direction of swell waves
+      0  22  13  Period of swell waves
+      0  22  23  Height of swell waves
+     -1
+  3   2  24
+      3   2  22  Wind waves
+      1   1   2  Replicate 1 descriptor 2 times
+      3   2  23  Swell waves (2 systems of swell)
+     -1
+  3   2  51
+      0  10   4  Pressure
+      0  10  51  Pressure reduced to mean sea level
+      0   7   4  Pressure (vertical location)
+      0  10   3  Geopotential
+      0  12   4  Dry-bulb temperature at 2 m
+      0  12  51  Standard deviation temperature
+      0  12  16  "Maximum temperature at 2 m, past 24 hours"
+      0  12  17  "Minimum temperature at 2 m, past 24 hours"
+      0  13   4  Vapour pressure
+      1   2   4  Replicate 2 descriptors 4 times
+      0   8  51  Qualifier for number of missing values in calculation of statistic
+      0   8  20  Total number of missing entities (with respect to accumulation or average)
+     -1
+#  Category 03 - Meteorological sequences common to vertical soundings data
+  3   3   1
+      0   7   3  Geopotential
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3   2
+      0   7   4  Pressure
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3   3
+      0   7   4  Pressure
+      0  10   3  Geopotential
+      0  12   1  Temperature
+      0  12   3  Dew point
+     -1
+  3   3   4
+      0   7   4  Pressure
+      0  10   3  Geopotential
+      0  12   1  Temperature
+      0  12   3  Dew point
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3  11
+      0   7   3  Geopotential
+      0   8   1  Vertical sounding significance
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3  12
+      0   7   4  Pressure
+      0   8   1  Vertical sounding significance
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3  13
+      0   7   4  Pressure
+      0   8   1  Vertical sounding significance
+      0  10   3  Geopotential
+      0  12   1  Temperature
+      0  13   3  Relative humidity
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3  14
+      0   7   4  Pressure
+      0   8   1  Vertical sounding significance
+      0  10   3  Geopotential
+      0  12   1  Temperature
+      0  12   3  Dew point
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   3  21
+      0   7   4  Pressure (1)
+      0   7   4  Pressure (2)     defines layer
+      2   4   7  Add associated field of 7 bits
+      0  31  21  Additional field significance
+     -1
+  3   3  22
+      3   3  21  "Layer, quality"
+      0  10   3  Geopotential (layer mean thickness)
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  23
+      3   3  21  "Layer, quality"
+      0  12   1  Temperature (layer mean)
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  24
+      3   3  21  "Layer, quality"
+      0  13  16  Precipitation water
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  25
+      0   2  25  Satellite channel
+      2   4   7  Add associated field of 7 bits
+      0  31  21  Additional field significance
+      0  12  63  Brightness temperature
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  26
+      0   7   4  Pressure
+      0   8   3  Vertical significance
+      2   4   7  Add associated field of 7 bits
+      0  31  21  Additional field significance
+      0  12   1  Temperature
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  27
+      0   7   4  Pressure
+      2   4   7  Add associated field of 7 bits
+      0  31  21  Additional field significance
+      0  10   3  Geopotential
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  31
+      0   7   4  Pressure
+      0   8   3  Vertical significance (base of sounding)
+      0   7  21  Elevation (local zenith)
+      0   7  22  Solar elevation (solar zenith)
+      0   8  12  Land/sea qualifier
+      0  12  61  Skin temperature
+     -1
+  3   3  32
+      0  20  11  Cloud amount
+      0  20  16  Pressure at top of cloud
+     -1
+  3   3  33
+      0  20  10  Cloud cover (total)
+      0  20  16  Pressure at the top of cloud
+     -1
+#  (Wind sequence)
+  3   3  41
+      0   2 152  Geostationary satellite instrument used
+      0   2  23  Cloud motion computational method
+      0   7   4  Pressure
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+      0   2 153  Satellite channel centre frequency
+      0   2 154  Satellite channel band width
+      0  12  71  Coldest cluster T
+     -1
+  3   3  23
+      3   3  21  "Layer, quality"
+      0  12   1  Temperature (layer mean)
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  24
+      3   3  21  "Layer, quality"
+      0  13  16  Precipitation water
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  25
+      0   2  25  Satellite channel
+      2   4   7  Add associated field of 7 bits
+      0  31  21  Additional field significance
+      0  12  63  Brightness temperature
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  26
+      0   7   4  Pressure
+      0   8   3  Vertical significance
+      2   4   7  Add associated field of 7 bits
+      0  31  21  Additional field significance
+      0  12   1  Temperature
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  27
+      0   7   4  Pressure
+      2   4   7  Add associated field of 7 bits
+      0  31  21  Additional field significance
+      0  10   3  Geopotential
+      2   4   0  Cancel the added associated field
+     -1
+  3   3  31
+      0   7   4  Pressure
+      0   8   3  Vertical significance (base of sounding)
+      0   7  21  Elevation (local zenith)
+      0   7  22  Solar elevation (solar zenith)
+      0   8  12  Land/sea qualifier
+      0  12  61  Skin temperature
+     -1
+  3   3  32
+      0  20  11  Cloud amount
+      0  20  16  Pressure at top of cloud
+     -1
+  3   3  33
+      0  20  10  Cloud cover (total)
+      0  20  16  Pressure at the top of cloud
+     -1
+#  (Wind sequence)
+  3   3  41
+      0   2 152  Geostationary satellite instrument used
+      0   2  23  Cloud motion computational method
+      0   7   4  Pressure
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+      0   2 153  Satellite channel centre frequency
+      0   2 154  Satellite channel band width
+      0  12  71  Coldest cluster T
+     -1
+#  Category 04 - Meteorological sequences common to satellite observations
+  3   4   1
+      0   8   3  Vertical significance
+      0  10   4  Pressure
+      0  12   1  Temperature
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   4   2
+      0   8   3  Vertical significance
+      0  10   4  Pressure
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+     -1
+  3   4   3
+      0   8   3  Vertical significance
+      0  12   1  Temperature
+     -1
+  3   4   4
+      0   8   3  Vertical significance
+      0  10   4  Pressure
+      0  20  10  Cloud cover (total)
+      0  12   1  Temperature
+     -1
+  3   4   5
+      0   2  24  Integrated mean humidity computational method
+      0   7   4  Pressure(1)
+      0   7   4  Pressure (2)    defines layer
+      0  13   3  Relative humidity
+     -1
+  3   4   6
+      0  14   1  Outgoing long-wave radiation
+      0  14   1  Incoming long-wave radiation
+      0  14   3  Outgoing short-wave radiation
+     -1
+#  (GOES-I/M info)
+  3   4  11
+      0   2 163  Height assignment method
+      0   2 164  Tracer correlation method
+      0   8  12  Land/sea qualifier
+      0   7  24  Satellite zenith angle
+      0   2  57  Origin of first guess information
+      0   8  21  Time significance
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+      0   4   4  Hour
+      0   8  21  Time significance
+      0   4  24  Time period or displacement
+      1  10   4  Replicate 10 descriptors 4 times
+      0   8  21  Time significance
+      0   4   4  Hour
+      0   4   5  Minute
+      0   4   6  Second
+      0   8  21  Time significance
+      0   4   4  Hour
+      0   4   5  Minute
+      0   4   6  Second
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+      1   3  10  Replicate 3 descriptors 10 times
+      0   2 163  Height assignment method
+      0   7   4  Pressure
+      0  12   1  Temperature
+     -1
+#  (Location of platform)
+  3   4  30
+      0  27  31  "In direction of 0 degree longitude, distance from the Earth�s centre"
+      0  28  31  "In direction of 90 degrees East longitude, distance from the Earth�s centre"
+      0  10  31  "In direction of North Pole, distance from Earth�s centre"
+     -1
+#  (Speed of platform)
+  3   4  31
+      0   1  41  Absolute platform velocity � first component
+      0   1  42  Absolute platform velocity � second component
+      0   1  43  Absolute platform velocity � third component
+     -1
+#  (Cloud fraction)
+  3   4  32
+      0   2 153  Satellite channel centre frequency
+      0   2 154  Satellite channel band width
+      0  20  81  Cloud amount in segment
+      0  20  82  Amount segment cloud free
+      0  20  12  Cloud type
+     -1
+#  (Clear sky radiance)
+  3   4  33
+      0   2 152  Satellite instrument used in data processing
+      0   2 166  Radiance type
+      0   2 167  Radiance computational method
+      0   2 153  Satellite channel centre frequency
+      0   2 154  Satellite channel band width
+      0  12  75  Spectral radiance
+      0  12  76  Radiance
+      0  12  63  Brightness temperature
+     -1
+#  0
+  3   4  34
+      1   2   4  Replicating next two descriptors 4 times
+      0  27   1  Latitude (high accuracy)
+      0  28   1  Longitude (high accuracy)
+      0   7  22  Solar elevation
+      0   5  43  Field of view number
+      0  20  10  Cloud cover (total)
+      0  20  16  Pressure at top of cloud
+      0  33   3  Quality information table
+      0  10  40  Number of retrieved layers
+     -1
+#  Category 05 - Meteorological or hydrological sequences common to hydrological observations
+#  (SADC-HYCOS measurement array definition)
+  3   5   3
+      3   1  12  "Hour, minute of first single measurement minus increment"
+      0   4  65  Short time increment - time interval between measuremens
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   5   1  Single measurement
+     -1
+#  3
+#  (MEDHYCOS measurement)
+  3   5   6
+      0  13  72  Downstream water level
+      0  13  82  Water temperature
+      0  13  19  Precipitation last hour
+      0  12   1  Air temperature
+      0  13  73  Maximum water height observed
+      0  13  60  Total accumulated precipitation
+     -1
+#  0
+#  (MEDHYCOS report)
+  3   5   7
+      3   1  29  Identification
+      3   1  12  "Hour, minute (time of first measurement)"
+      0   4  65  Short time increment - time interval between measurements
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   5   6  Single measurement
+     -1
+#  3
+#  (AOCHYCOS - Chad measurement)
+  3   5   8
+      3   5   6  Same as MEDHYCOS type measurement
+      0  12  30  Soil temperature at -50 cm
+     -1
+#  0
+#  (AOCHYCOS-Chad report)
+  3   5   9
+      3   1  29  Identification
+      3   1  12  "Hour, minute (time of first measurement)"
+      0   4  65  Short time increment - time interval between measurements
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   5   8  Single measurement
+     -1
+#  3
+#  (MEDHYCOS report type 2)
+  3   5  11
+      3   1  29  Identification
+      3   1  12  "Hour, minute (time of first measurement)"
+      0   4  65  Short time increment - time interval between measurements
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   5  10  Single measurement
+     -1
+#  3
+#  (MEDHYCOS report with meteorology and water quality data)
+  3   5  18
+      3   1  29  Identification
+      3   1  12  "Hour, minute (time) of first measurement"
+      0   4  65  Hour increment
+      1   3   0  Delayed replications of 3 descriptors
+      0  31   1  Replication factor
+      3   5   8  Same as AOCHYCOS type measurement
+      3   5  16  Meteorological parameters associated to hydrological data
+      3   5  17  Water quality measurement
+     -1
+#  Category 06 - Meteorological or oceanographic sequences common to oceanographic observations
+  3   6   1
+      0   2  32  Indicator for digitization
+      1   2   0  Delayed replication of 2 descriptors
+      0  31   1  Replication factor
+      0   7  62  Depth below sea surface
+      0  22  42  Subsurface sea temperature
+     -1
+  3   6   2
+      0   2  31  Method of current measurement
+      0  22   4  Direction of current
+      0  22  31  Speed of current
+     -1
+  3   6   3
+      0   2   2  Wind instrumentation
+      0  11  11  Wind direction (10 m)
+      0  11  12  Wind speed (10 m)
+      0  12   4  Dry-bulb temperature (2 m)
+     -1
+  3   6   4
+      0   2  32  Indicator for digitization
+      0   2  33  Method of salinity/depth measurement
+      1   3   0  Delayed replication of 3 descriptors
+      0  31   1  Replication factor
+      0   7  62  Depth below sea surface
+      0  22  43  Subsurface sea temperature
+      0  22  62  Salinity
+     -1
+  3   6   5
+      0   2  31  Method of current measurement
+      1   3   0  Delayed replication of 3 descriptors
+      0  31   1  Replication factor
+      0   7  62  Depth below sea surface
+      0  22   4  Direction of current
+      0  22  31  Speed of current
+     -1
+#  (Under water sounding (optional) parameters)
+  3   6   6
+      3   6   3  Surface wind and temperature
+      3   6   2  Current
+      0  22  63  Total water depth
+     -1
+#  (Buoy spare block parameters)
+  3   6   7
+      0   1  12  Direction of motion of moving observing platform
+      0   1  14  Platform drift speed (high precision)
+      3   6   8  Buoy instrumentation
+      0   4  24  Time period
+      0  27   3  Alternate latitude
+      0  28   3  Alternate longitude
+     -1
+#  (Buoy instrumentation parameters)
+  3   6   8
+      0   2  34  Drogue type
+      0   2  35  Cable length
+      0   2  36  Buoy type
+     -1
+  3   6  23
+      0   1  15  Station or site name
+      3   1  23  "Latitude, longitude"
+      3   1  11  "Year, month, day"
+      3   1  12  "Hour, minute"
+      0  22  38  Tidal level with respect to local chart datum
+      0  22  39  Meteorological residual tidal elevation
+      0  22 120  Tide station automated water level check
+      0  22 121  Tide station manual water level check
+     -1
+#  Category 07 - Surface report sequences (land)
+#  (Low altitude station)
+  3   7   1
+      3   1  31  "Identification, type, date/time, position (high accuracy), height"
+      3   2  11  Basic surface report
+     -1
+#  (Low altitude station)
+  3   7   2
+      3   1  32  "Identification, type, date/time, position (coarse accuracy), height"
+      3   2  11  Basic surface report
+     -1
+#  (Low altitude station)
+  3   7   3
+      3   7   1  Location (high accuracy) and basic report
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   2   5  Cloud layer information
+     -1
+#  (Low altitude station)
+  3   7   4
+      3   7   2  Location (coarse accuracy) and basic report
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   2   5  Cloud layer information
+     -1
+#  (Low altitude station)
+  3   7   5
+      3   7   1  Location (high accuracy) and basic report
+      1   1   4  Replicate 1 descriptor 4 times
+      3   2   5  Cloud layer information (4 layers)
+     -1
+#  (Low altitude station)
+  3   7   6
+      3   7   2  Location (coarse accuracy) and basic report
+      1   1   4  Replicate 1 descriptor 4 times
+      3   2   5  Cloud layer information (4 layers)
+     -1
+#  (High altitude station)
+  3   7   7
+      3   1  31  "Identification, type, date/time, position (high accuracy), height"
+      3   2  12  Basic surface report
+     -1
+#  (High altitude station)
+  3   7   8
+      3   1  32  "Identification, type, date/time, position (coarse accuracy), height"
+      3   2  12  Basic surface report
+     -1
+  3   7   9
+      3   1  31  "Identification, type, date/time, position (high accuracy), height"
+      3   2  13  Basic surface report
+     -1
+#  (Main part of data for representation of METAR/SPECI code in BUFR)
+  3   7  11
+      0   1  63  ICAO location indicator
+      0   2   1  Type of station
+      3   1  11  "Year, month, day (YY)"
+      3   1  12  "GG, gg"
+      3   1  24  "Latitude-longitude (coarse accuracy), height of station"
+      0   7   6  Height above station (= height of an anemometer)
+      0  11   1  Wind direction
+      0  11  16  Extreme counterclockwise wind direction of a variable wind
+      0  11  17  Extreme clockwise wind direction of a variable wind
+      0  11   2  Wind speed
+      0  11  41  Maximum wind speed (gusts)
+      0   7   6  Height above station (= height of a thermometer)
+      0  12   1  Temperature
+      0  12   3  Dew-point temperature
+      0  10  52  Altimeter setting (QNH)
+      0  20   9  General Weather Indicator TAF/METAR
+     -1
+#  (DvVVVV)
+  3   7  12
+      1   3   0  Delayed replication of 3 descriptors
+      0  31   1  Number of replication (up to 3)
+      0   8  23  First order statistics
+      0   5  21  Direction of visibility observed
+      0  20   1  Horizontal visibility
+     -1
+#  (DRDRVRVRVRVR)
+  3   7  13
+      1   6   0  Delayed replication of 6 descriptors
+      0  31   1  Number of replication (up to 4)
+      0   1  64  Runway designator
+      0   8  14  Qualification for runway visual range
+      0  20  61  Runway visual range
+      0   8  14  Qualification for runway visual range
+      0  20  61  Runway visual range
+      0  20  18  Tendency of runway visual range
+     -1
+#  (w�w�)
+  3   7  14
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Number of replication (up to 3)
+      0  20  19  Significant present weather
+     -1
+#  (Clouds group(s))
+  3   7  15
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Number of replication
+      3   2   5  "(NsNsNs, CC, hshshs)"
+      0  20   2  Vertical visibility
+     -1
+#  (REw�w�)
+  3   7  16
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Number of replication (up to 3)
+      0  20  20  Significant recent weather phenomena
+     -1
+#  (Wind shear on runways(s))
+  3   7  17
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Number of replication
+      0  11  70  Runway designator of the runway affected by wind shear (including ALL)
+     -1
+#  (Trend-type landing forecast)
+  3   7  18
+      0   8  16  Change qualifier of a trend-type
+      1   2   0  Delayed replication of 2 descriptors
+      0  31   1  Number of replication (up to 2)
+      0   8  17  Qualifier of the time when the forecast
+      3   1  12  "GG, gg"
+      1   4   0  Delayed replication of 4 descriptor
+      0  31   1  Number of replication (up to 1)
+      0   7   6  Height above station
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+      0  11  41  Maximum wind speed (gusts)
+      0  20   9  General Weather Indicator
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Number of replication (up to 1)
+      0  20   1  Horizontal visibility
+      3   7  14  w�w�
+     -1
+#  (Short METAR/SPECI)
+  3   7  20
+      3   7  11  Main part of data
+      3   7  14  w�w�
+      3   7  16  REw�w�
+     -1
+#  (Total sequence for representation of METAR/SPECI code in BUFR)
+  3   7  21
+      3   7  11  Main part of data
+      3   7  12  DvVVVV
+      3   7  13  DRDRVRVRVRVR
+      3   7  14  w�w�
+      3   7  15  Clouds group(s)
+      3   7  16  REw�w�
+      3   7  17  Wind shear on runway(s)
+      3   7  18  Trend-type landing forecast
+      3   7  15  Clouds group(s)
+     -1
+#  Category 08 - Surface report sequences (sea)
+#  (Buoy/platform � fixed)
+  3   8   1
+      3   1  33  "Identification, type, date/time, position (high accuracy)"
+      3   2  11  Basic surface report
+      0  22  42  Sea-surface temperature
+     -1
+#  (Buoy/platform � fixed)
+  3   8   2
+      3   1  34  "Identification, type, date/time, position (coarse accuracy)"
+      3   2  11  Basic surface report
+      0  22  42  Sea-surface temperature
+     -1
+#  (Buoy/platform � moving)
+  3   8   3
+      3   1  35  "Identification, movement, type, date/time, position (coarse accuracy)"
+      3   2  11  Basic surface report
+      0  22  42  Sea-surface temperature
+     -1
+#  (Ship)
+  3   8   4
+      3   1  36  "Identification, movement, type, date/time, position (coarse accuracy)"
+      3   2  11  Basic surface report
+      0  22  42  Sea-surface temperature
+     -1
+  3   8   5
+      3   8   4  Basic ship report
+      3   2  24  Wind waves and swell waves
+     -1
+#  (Buoy Section 1 optional parameters)
+  3   8   6
+      0  10   4  Pressure
+      0  10  61  3-hour pressure change
+      0  10  63  Characteristic of pressure tendency
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+      0  12   4  Dry-bulb temperature at 2 m
+      0  13   3  Relative humidity
+      0  22  42  Sea temperature
+     -1
+  3   8   7
+      3   1  55  "Identification, movement type, date/time, position (high accuracy)"
+      3   2  11  Basic surface report
+      0   7  62  Depth below sea/water surface
+      0  22  42  Sea/water temperature
+     -1
+#  Category 09 - Vertical sounding sequences (conventional data)
+#  (Vertical wind profile)
+  3   9   1
+      3   1  37  "Identification, etc. (land station, high accuracy position)"
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  11  Winds at heights
+     -1
+#  (Vertical wind profile)
+  3   9   2
+      3   1  38  "Identification, etc. (land station, coarse accuracy position)"
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  11  Winds at heights
+     -1
+#  (Vertical wind profile)
+  3   9   3
+      3   1  37  "Identification, etc. (land station, high accuracy position)"
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  12  Winds at pressure levels
+     -1
+#  (Vertical wind profile)
+  3   9   4
+      3   1  38  "Identification, etc. (land station, coarse accuracy position)"
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  12  Winds at pressure levels
+     -1
+#  (Vertical sounding with relative humidity)
+  3   9   5
+      3   1  37  "Identification, etc. (land station, high accuracy position)"
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  13  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical sounding with relative humidity)
+  3   9   6
+      3   1  38  "Identification, etc. (land station, coarse  accuracy position)"
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  13  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical sounding with dew-point data)
+  3   9   7
+      3   1  37  "Identification, etc. (land station, high accuracy position)"
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  14  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical sounding with dew-point data)
+  3   9   8
+      3   1  38  "Identification, etc. (land station, coarse accuracy position)"
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  14  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical wind profile)
+  3   9  11
+      3   1  39  "Ship's identification, etc."
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  11  Winds at heights
+     -1
+#  (Vertical wind profile)
+  3   9  12
+      3   1  39  "Ship's identification, etc."
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  12  Winds at pressure levels
+     -1
+#  (Vertical sounding with relative humidity)
+  3   9  13
+      3   1  39  "Ship's identification, etc."
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  13  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical sounding with dew-point data)
+  3   9  14
+      3   1  39  "Ship's identification, etc."
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  14  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical wind profile)
+  3   9  15
+      3   1  40  "Ship's identification, etc."
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  11  Winds at heights
+     -1
+#  (Vertical wind profile)
+  3   9  16
+      3   1  40  "Ship's identification, etc."
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  12  Winds at pressure levels
+     -1
+#  (Vertical sounding with relative humidity)
+  3   9  17
+      3   1  40  "Ship's identification, etc."
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  13  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Vertical sounding with dew-point data)
+  3   9  18
+      3   1  40  "Ship's identification, etc."
+      3   2   4  Significant cloud information
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  14  "Pressure, geopotential, temperature and wind data"
+     -1
+#  (Wind profiler � wind data sounding)
+  3   9  19
+      3   1  31  "Identification, etc."
+      0   2   3  Type of measuring equipment used
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3   3  11  Winds at heights
+     -1
+#  (Wind profiler � Cartesian coordinates)
+  3   9  20
+      3   1  31  "Identification, etc."
+      0   2   3  Type of measuring equipment used
+      1   4   0  Delayed replication of 4 descriptors
+      0  31   1  Replication factor
+      0   7   3  Geopotential
+      0  11   3  u-component
+      0  11   4  v-component
+      0  11   5  w-component
+     -1
+#  (Ozone sonde flight data)
+  3   9  30
+      0  15   4  Ozone sounding correction factor
+      0  15   5  Ozone p
+      1   4   0  Delayed replication of 4 descriptors
+      0  31   1  Replication factor
+      0   4  15  "Time increment since launch time, if needed; in minutes"
+      0   8   6  Ozone vertical sounding significance
+      0   7   4  Pressure
+      0  15   3  Measured ozone partial pressure
+     -1
+#  Category 10 - Vertical sounding sequences (satellite data)
+#  (Satellite � brightness temperature)
+  3  10   1
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  32  Cloud
+      1   1  26  Replicate 1 descriptor 26 times
+      3   3  25  Satellite channel and brightness temperature
+     -1
+#  (Satellite � low level)
+  3  10   2
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  32  Cloud
+      1   1   9  Replicate 1 descriptor 9 times
+      3   3  23  Layer mean temperature
+     -1
+#  (Satellite � high level)
+  3  10   3
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  32  Cloud
+      1   1   6  Replicate 1 descriptor 6 times
+      3   3  23  Layer mean temperature
+     -1
+#  (Satellite � precipitable water)
+  3  10   4
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  32  Cloud
+      1   1   3  Replicate 1 descriptor 3 times
+      3   3  24  Precipitable water
+     -1
+#  3
+  3  10   5
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  33  Cloud
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Delayed descriptor replication factor
+      3   3  25  Satellite channel and brightness temperature
+     -1
+#  3
+  3  10   6
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  33  Cloud
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Delayed descriptor replication factor
+      3   3  23  Layer mean temperature
+     -1
+#  3
+  3  10   7
+      3   1  42  "Identification, method, date/time"
+      3   3  31  "Significance data, land/sea, skin temperature"
+      3   3  33  Cloud
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Delayed descriptor replication factor
+      3   3  24  Precipitable water
+     -1
+#  3
+#  3
+#  (ATOVS HIRS report)
+  3  10   8
+      3  10  11  ATOVS field of view variables
+      1   1  19  Replicate 1 descriptor 19 times
+      3  10  12  ATOVS channel variables
+      0   2 150  TOVS/ATOVS/AVHRR instrumentation channel number
+      0  25  79  Albedo-radiance solar filtered irradiance for ATOVS
+      0  25  80  Albedo-radiance equivalent filter width for ATOVS
+      0  33  32  Channel quality flags for ATOVS
+      0  14  45  Channel radiance
+     -1
+#  (ATOVS AMSU-A report)
+  3  10   9
+      3  10  11  ATOVS field of view variables
+      1   1  15  Replicate 1 descriptor 15 times
+      3  10  12  ATOVS channel variables
+     -1
+#  (ATOVS AMSU-B report)
+  3  10  10
+      3  10  11  ATOVS field of view variables
+      1   1   5  Replicate 1 descriptor 5 times
+      3  10  12  ATOVS channel variables
+     -1
+#  (ATOVS field of view variables)
+  3  10  11
+      0   8  70  TOVS/ATOVS product qualifier
+      0   1  33  Identification of originating/generating centre
+      0   1  34  Identification of originating/generating centre
+      0   8  70  TOVS/ATOVS product qualifier
+      0   1  33  Identification of originating/generating centre
+      0   1  34  Identification of originating/generating centre
+      0   1   7  Satellite identification
+      0   2  48  Satellite sensor indicator
+      0   5  40  Orbit number
+      0  25  75  Satellite antenna corrections version number
+      2   1 133  Change width
+      0   5  41  Scan line number
+      2   1   0  Change width
+      0   5  43  Field of view number
+      0  25  70  Major frame count
+      0  33  30  Scan line status flags for ATOVS
+      0  33  31  Scan line quality flags for ATOVS
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+      0   4   4  Hour
+      0   4   5  Minute
+      2   2 131  Change scale
+      2   1 138  Change width
+      0   4   6  Second
+      2   1   0  Change width
+      2   2   0  Change scale
+      0   5   1  Latitude
+      0   6   1  Longitude
+      2   2 126  Change scale
+      0   7   1  Height of station
+      2   2   0  Change scale
+      0   7  24  Satellite zenith angle
+      0   5  21  Satellite azimuth
+      0   7  25  Solar zenith angle
+      0   5  22  Solar azimuth
+      0  33  33  Field of view quality flags for ATOVS
+      0   2 151  Radiometer identifier
+      0  12  64  Instrument temperature
+      0   2 151  Radiometer identifier
+      0  12  64  Instrument temperature
+      0   2 151  Radiometer identifier
+      0  12  64  Instrument temperature
+      0   2 151  Radiometer identifier
+      0  12  64  Instrument temperature
+     -1
+#  (ATOVS channel variables)
+  3  10  12
+      0   2 150  TOVS/ATOVS/AVHRR instrumentation channel number
+      0  25  76  Log�10 of (temperature-radiance central wavenumber) for ATOVS
+      0  25  77  Bandwidth correction coefficient 1 for ATOVS
+      0  25  78  Bandwidth correction coefficient 2 for ATOVS
+      0  33  32  Channel quality flags for ATOVS
+      2   1 132  Change width
+      2   2 129  Change scale
+      0  12  63  Brightness temperature
+      2   2   0  Change scale
+      2   1   0  Change width
+     -1
+#  (AVHRR (GAC) report)
+  3  10  13
+      0   1   7  Satellite ID
+      0   5  40  Orbit number
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+      0   4   4  Hour
+      0   4   5  Minute
+      0   4   6  Second
+      0   5   1  Latitude
+      0   6   1  Longitude
+      0   7  25  Solar zenith angle
+      0   5  43  Field of view number
+      0  25  85  Fraction of clear pixels in HIRS field of view
+      2   1 131  Change width
+      2   2 129  Change scale
+      0   2 150  TOVS/ATOVS/AVHRR instrumentation channel number
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  14  27  Albedo
+      0   8  72  Pixel(s) type
+      0  14  27  Albedo
+      0   2 150  TOVS/ATOVS/AVHRR instrumentation channel number
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  14  27  Albedo
+      0   8  72  Pixel(s) type
+      0  14  27  Albedo
+      0   2 150  ATOVS/AVHRR instrumentation channel number
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  14  27  Albedo
+      0   8  72  Pixel(s) type
+      0  14  27  Albedo
+      2   2   0  Change scale
+      2   1   0  Change width
+      2   1 132  Change width
+      2   2 129  Change scale
+      0   2 150  ATOVS/AVHRR instrumentation channel number
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   2 150  ATOVS/AVHRR instrumentation channel number
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   2 150  ATOVS/AVHRR instrumentation channel number
+      0   8  23  First order statistics
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      0   8  72  Pixel(s) type
+      0  12  63  Brightness temperature
+      2   2   0  Change scale
+      2   1   0  Change width
+     -1
+#  (Satellite � geostationnary wind data)
+  3  10  14
+      3   1  72  "Satellite identification, date, time, latitude, longitude"
+      3   3  41  Wind sequence
+      3   4  11  GOES-I/M information
+     -1
+#  (Meteosat radiace data)
+  3  10  15
+      3   1  72  Satellite identification
+      0   7  24  Satellite zenith angle
+      0  10   2  Height
+      3   3  41  Wind sequence
+      1   1   3  Replicate next descriptor 3 times
+      3   4  32  Cloud fraction
+      0   2 152  Satellite instrument used in data processing
+      0   2  24  Integrated mean humidity computational method
+      0   7   4  Pressure
+      0   7   4  Pressure
+      0  13   3  Relative humidity
+      1   1   3  Replicate next descriptor 3 times
+      3   4  33  Clear sky radiance
+     -1
+#  (Meteosat Second Generation (MSG) radiance data)
+  3  10  16
+      3   1  72  Satellite identification
+      0   7  24  Satellite zenith angle
+      0  10   2  Height
+      3   3  41  Wind sequence
+      1   1  12  Replicate next descriptor 12 times
+      3   4  32  Cloud fraction
+      0   2 152  Satellite instrument used in data processing
+      0   2  24  Integrated mean humidity computational method
+      0   7   4  Pressure
+      0   7   4  Pressure
+      0  13   3  Relative humidity
+      1   1  12  Replicate next descriptor 12 times
+      3   4  33  Clear sky radiance
+     -1
+#  (Retrieved ozone data)
+  3  10  20
+      3  10  22
+      3   1  11  "Year, month, day"
+      3   1  13  "Hour, minute, second"
+      3   1  21  "Lat., long. (high accuracy)"
+      3   4  34
+      3  10  21
+     -1
+#  3
+  3  10  21
+      1   8   0  Delayed replication of 8 next descriptors
+      0  31   1  Delayed descriptor replication factor
+      2   1 131  Change data width
+      2   2 129  Change scale
+      0   7   4  Pressure
+      0   7   4  Pressure
+      2   2   0  Change scale to Table B
+      2   1   0  Change data width to Table B
+      0  15  20  Integrated 03 density
+      0  10   2  Height
+     -1
+#  0
+  3  10  22
+      0   1   7  Satellite identifier
+      0   2  19  Satellite instrument used
+      0   1  33  Identification of originating/generating centre
+      0   2 172  Product type for retrieved atmospheric gases
+     -1
+#  Category 11 - Single level report sequences (conventional data)
+#  (Aircraft reports)
+  3  11   1
+      3   1  51  "ASDAR aircraft identifier, navigational system, date/time, position, phase of aircraft flight"
+      0   7   2  Altitude
+      0  12   1  Temperature
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+      0  11  31  Degree of turbulence
+      0  11  32  Height of base of turbulence
+      0  11  33  Height of top of turbulence
+      0  20  41  Airframe icing
+     -1
+#  (ACARS reports)
+  3  11   2
+      3   1  65  ACARS identification
+      3   1  66  ACARS location
+      3  11   3  ACARS standard reported variables
+      3  11   4  ACARS supplementary reported variables
+     -1
+#  (ACARS standard reported variables)
+  3  11   3
+      0  10  70  Indicated aircraft altitude
+      0  11   1  Wind direction
+      0  11   2  Wind speed
+      0  12   1  Temperature/dry-bulb temperature
+      0  13   2  Mixing ratio
+     -1
+#  (ACARS supplementary reported variables)
+  3  11   4
+      1   1   0  Delayed replication of one descriptor
+      0  31   0  Short delayed descriptor replication factor
+      0  11  34  Vertical gust velocity
+      1   1   0  Delayed replication of one descriptor
+      0  31   0  Short delayed descriptor replication factor
+      0  11  35  Vertical gust acceleration
+      1   1   0  Delayed replication of one descriptor
+      0  31   0  Short delayed descriptor replication factor
+      0  11  75  Mean turbulence intensity (eddy dissipation rate)
+      1   1   0  Delayed replication of one descriptor
+      0  31   0  Short delayed descriptor replication factor
+      0  11  76  Peak turbulence intensity (eddy dissipation rate)
+      1   1   0  Delayed replication of one descriptor
+      0  31   0  Short delayed descriptor replication factor
+      0  33  25  ACARS interpolated values
+      1   1   0  Delayed replication of one descriptor
+      0  31   0  Short delayed descriptor replication factor
+      0  33  26  Mixing ratio quality
+     -1
+#  Category 12 - Single level report sequences (satellite data)
+  3  12   1
+      3   1  43  "Satellite identifier, instrumentation, location, date/time"
+      3   4   1  "Cloud top pressure, temperature, wind"
+     -1
+  3  12   2
+      3   1  43  "Satellite identifier, instrumentation, location, date/time"
+      3   4   2  "Cloud top pressure, wind"
+     -1
+  3  12   3
+      3   1  42  "Satellite identifier, instrumentation, location, date/time"
+      3   4   3  Surface temperature
+     -1
+  3  12   4
+      3   1  42  "Satellite identifier, instrumentation, location, date/time"
+      3   4   4  Cloud cover
+     -1
+  3  12   5
+      3   1  42  "Satellite identifier, instrumentation, location, date/time"
+      0  20  14  Height of top of cloud
+     -1
+  3  12   6
+      3   1  44  "Satellite identifier, instrumentation, location, date/time"
+      3   4   5  Layer mean relative humidity
+     -1
+  3  12   7
+      3   1  42  "Satellite identifier, instrumentation, location, date/time"
+      3   4   6  Radiation
+     -1
+#  "(Orbital information, Part I)"
+  3  12  10
+      0   1   7  Satellite identifier
+      0   5  40  Orbit number
+      0   2  21  Satellite instrumentation
+      0   5  41  Scan line number
+      0   4   1  Year
+      0   4  43  Day of year
+     -1
+#  "(Orbital information, Part II)"
+  3  12  11
+      2   2 131  Change scale
+      2   1 149  Change width
+      0   4   6  Second
+      2   1   0  Change width
+      2   2 126  Change scale
+      0  10   2  Height
+      2   2   0  Change scale
+      0   5  43  Field of view number
+      0   5  53  Field of view number increment
+     -1
+#  (HIRS brightness temperatures � channels 1�19)
+  3  12  12
+      2   2 129  Change scale
+      2   1 132  Change width
+      1   1  19  Replicate 1 descriptor 19 times
+      0  12  63  Brightness temperature
+      2   1   0  Change width
+      2   2   0  Change scale
+     -1
+#  (HIRS brightness temperatures � channel 20)
+  3  12  13
+      0   5  42  Channel number
+      2   2 129  Change scale
+      2   1 135  Change width
+      0  12  63  Brightness temperature
+      2   1   0  Change width
+      2   2   0  Change scale
+     -1
+#  (HIRS satellite data)
+  3  12  14
+      3  12  10  "Orbital information, Part I"
+      3  12  11  "Orbital information, Part II"
+      1   5  56  Replicate 5 descriptors 56 times
+      3   1  23  Latitude and longitude (coarse accuracy)
+      0   5  42  Channel number
+      0   5  52  Channel number increment
+      3  12  12  HIRS brightness temperatures � channels 1�19
+      3  12  13  HIRS brightness temperature � channel 20
+     -1
+#  (MSU brightness temperatures � channels 1�4)
+  3  12  15
+      1   9  11  Replicate 9 descriptors 11 times
+      3   1  23  Latitude and longitude (coarse accuracy)
+      0   5  42  Channel number
+      0   5  52  Channel number increment
+      2   2 129  Change scale
+      2   1 132  Change width
+      1   1   4  Replicate 1 descriptor 4 times
+      0  12  63  Brightness temperature
+      2   2   0  Change scale
+      2   1   0  Change width
+     -1
+#  (MSU satellite data)
+  3  12  16
+      3  12  10  "Orbital information, Part I"
+      3  12  11  "Orbital information, Part II"
+      3  12  15  MSU brightness temperatures � channels 1�4
+     -1
+#  (SSU brightness temperatures � channels 1�3)
+  3  12  17
+      1   9   8  Replicate 9 descriptors 8 times
+      3   1  23  Latitude and longitude (coarse accuracy)
+      0   5  42  Channel number
+      0   5  52  Channel number increment
+      2   2 129  Change scale
+      2   1 132  Change width
+      1   1   3  Replicate 1 descriptor 3 times
+      0  12  63  Brightness temperature
+      2   2   0  Change scale
+      2   1   0  Change width
+     -1
+#  (SSU satellite data)
+  3  12  18
+      3  12  10  "Orbital information, Part I"
+      3  12  11  "Orbital information, Part II"
+      3  12  17  SSU brightness temperatures � channels 1�3
+     -1
+#  (Wave scatterometer product with width change for wave number (spectral))
+  3  12  19
+      3   1  47  Product header
+      3   1  48  Radar parameters
+      0  15  15  Maximum spectrum composition before normalisation
+      0  29   2  Coordinate grid type
+      0  21  76  Representation of intensities
+      1   6  12  Repeat next 6 descriptors 12 times
+      2   1 129  Change width to 14 bits
+      0   6  30  Wave number (spectral)
+      2   1   0  Change width to Table B
+      1   2  12  Repeat next 2 descriptors 12 times
+      0   5  30  Direction (spectral)
+      0  21  75  Image spectrum intensity
+      0  21  66  Wave scatterometer product confidence data
+     -1
+#  (Wave scatterometer product)
+  3  12  20
+      3   1  47  Product header
+      3   1  48  Radar parameters
+      0  15  15  Maximum spectrum composition before normalization
+      0  29   2  Coordinate grid type
+      0  21  76  Representation of intensities
+      1   4  12  Repeat next 4 descriptors 12 times
+      0   6  30  Wave number (spectral)
+      1   2  12  Repeat next 2 descriptors 12 times
+      0   5  30  Direction (spectral)
+      0  21  75  Spectral intensity
+      0  21  66  Wave scatterometer product confidence data
+     -1
+#  (Wind scatterometer product)
+  3  12  21
+      3   1  47  Product header
+      1   1   3  Repeat 1 descriptor 3 times
+      3   1  49  Radar beam data
+      0  11  12  Wind speed at 10 m
+      0  11  11  Wind direction at 10 m
+      0  21  67  Wind product confidence data
+     -1
+#  (Radar altimeter product)
+  3  12  22
+      3   1  47  Product header
+      0   8  22  Number in average
+      0  11  12  Wind speed
+      0  11  50  Standard deviation of horizontal wind speed
+      0  22  70  Significant wave height
+      0  22  26  Standard deviation of significant wave height
+      3  12  41  Altitude
+      0  10  50  Standard deviation of altitude
+      0  21  68  Radar altimeter product confidence data
+      0  21  71  Peakiness
+      0  21  72  Altimeter calibration status
+      0  21  73  Altimeter instrument mode
+      3  12  42  Altitude corrections
+      0  21  62  Backscatter
+      0  15  11  Log 10 of integrated electron density
+     -1
+#  (ATSR sea surface temperature product)
+  3  12  23
+      3   1  47  Product header
+      1   3   3  Repeat 3 descriptors 3 times
+      0   8  22  Number in average
+      0  12  61  Skin temperature
+      0  22  50  Standard deviation of sea surface temperature
+      0  21  69  SST product confidence data
+      0  21  85  ATSR sea surface temperature across-track band number
+     -1
+#  (Wave scatterometer product enhanced)
+  3  12  24
+      3  12  20  (Wave scatterometer product)
+      0   8  60  Sample scanning mode significance � range
+      0   8  22  Number in sample
+      0   8  60  Sample scanning mode signification � horizontal
+      0   8  22  Number in sample
+      0  25  14  Azimuth clutter cut-off
+      0  22 101  Total energy (wavelength > 731 m)
+      0  22  97  Mean wavelength of image spectrum
+      0  22  98  Wavelength spread (wavelength > 731 m)
+      0  22  99  Mean direction (wavelength > 731 m)
+      0  22 100  Direction spread (wavelength > 731 m)
+     -1
+#  (Wave scatterometer enhanced product (with change of width for wave number (spectral))
+  3  12  25
+      3  12  19  Wave scatterometer product with width change for wave number (spectral)
+      0   8  60  Sample scanning mode significance � range
+      0   8  22  Number in sample
+      0   8  60  Sample scanning mode significance � horizontal
+      0   8  22  Number in sample
+      0  25  14  Azimuth clutter cut-off
+      0  22 101  Total energy (wavelength > 731 m)
+      0  22  97  Mean wavelength of image spectrum
+      0  22  98  Wavelength spread (wavelength > 731 m)
+      0  22  99  Mean direction (wavelength > 731 m)
+      0  22 100  Direction spread (wavelength > 731 m)
+     -1
+#  (QUIKSCAT data)
+  3  12  26
+      3   1  46
+      3   1  11  Data
+      3   1  13  Time
+      3   1  23  Location
+      3  12  31
+      1   1   4  Replicate 1 descriptor 4 times
+      3  12  30
+      0  21 110  Number of inner-beam sigma-0 (forward of satellite)
+      3   1  23  Location
+      3  21  27
+      0  21 111  Number of outer-beam sigma-0 (forward of satellite)
+      3   1  23  Location
+      3  21  27
+      0  21 112  Number of inner-beam sigma-0 (aft of satellite)
+      3   1  23  Location
+      3  21  27
+      0  21 113  Number of outer-beam sigma-0 (aft of satellite)
+      3   1  23  Location
+      3  21  27
+     -1
+#  (ATSR SST Product (SADIST-2))
+  3  12  27
+      3   1  47  ERS product header
+      1   5   9  Repeat next 5 descriptors 9 times
+      3   1  23  Location (coarse Latitude + Longitude) of 10-arcmin cell
+      0   7  21  Elevation: Incidence angle Nadir view [set to zero]
+      0  12  61  Skin temperature: SST [Nadir-only view]
+      0   7  21  Elevation: Incidence angle Dual view [set to 'missing']
+      0  12  61  Skin temperature: SST [Dual view]
+      0  21  85  ATSR SST across-track band number [0-9]
+      0  21  70  SST product confidence data (SADIST-2) [23-bit flag]
+     -1
+#  (SEAWINDS QUIKSCAT data)
+  3  12  28
+      3   1  46
+      3   1  11
+      3   1  13
+      3   1  23
+      0   8  25  Time difference qualifier
+      2   1 136  Change data width
+      0   4   6  Second
+      2   1   0  Change data width back to Table B
+      3  12  31
+      3  12  32
+      1   1   4  Next descriptor replicated four times
+      3  12  30
+      1   1   2  Next descriptor replicated two times
+      3  12  33
+      0  21 110  Number of inner-beam sigma-0 (forward of satellite)
+      3   1  23
+      3  21  28
+      0  21 111  Number of outer-beam sigma-0 (forward of satellite)
+      3   1  23
+      3  21  28
+      0  21 112  Number of inner-beam sigma-0 (aft of satellite)
+      3   1  23
+      3  21  28
+      0  21 113  Number of outer-beam sigma-0 (aft of satellite)
+      3   1  23
+      3  21  28
+     -1
+  3  12  30
+      2   1 130  Change data width
+      2   2 129  Change scale
+      0  11  12  Wind speed at 10 m
+      2   2   0  Change scale back to Table B
+      2   1   0  Change data width to Table B
+      0  11  52  Formal uncertainty in wind speed
+      2   1 135  Change data width
+      2   2 130  Change scale
+      0  11  11  Wind direction at 10 m
+      2   2   0  Change scale back to Table B
+      2   1   0  Change data width to Table B
+      0  11  53  Formal uncertainty in wind direction
+      0  21 104  Likelihood computed for solution
+     -1
+ 3  12  31
+      0   5  34  Along-track row number
+      0   6  34  Cross-track cell number
+      0  21 109  SEAWINDS wind vector cell quality
+      0  11  81  Model wind direction at 10 m
+      0  11  82  Model wind speed at 10 m
+      0  21 101  Number of vector ambiguities
+      0  21 102  Index of selected wind vector
+      0  21 103  Total number of sigma-0 measurements
+     -1
+  3  12  32
+      0  21 120  Probability of rain
+      0  21 121  SEAWINDS NOF rain index
+      0  13  55  Intensity of precipitation
+      0  21 122  Attenuation correction on sigma-0 (from tB)
+     -1
+ 3  12  33
+      0   2 104  Antenna polarisation
+      0   8  22  Total number (with respect to accumulation)
+      0  12  63  Brightness temperature
+      0  12  65  Standard deviation brightness temperature
+     -1
+#  (Altitude)
+  3  12  41
+      2   1 141  Change width to 28 bits
+      2   2 130  Change scale to 2
+      0   7   1  Altitude
+      2   1   0  Change width back to Table B
+      2   2   0  Change scale back to Table B
+     -1
+#  (Altitude corrections)
+  3  12  42
+      0  21  77  "Altitude correction, ionosphere"
+      0  21  78  "Altitude correction, dry troposphere"
+      0  21  79  "Altitude correction, wet troposphere"
+      0  21  80  "Altitude correction, calibration constant"
+      0  21  81  Open loop height-time loop calibration correction
+      0  21  82  Open loop automatic gain control calibration correction
+     -1
+#  Category 13 - Sequences common to image data
+#  (Radar reflectivity values)
+  3  13   9
+      0  21   1  Horizontal reflectivity
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      0  21   1  Horizontal reflectivity
+     -1
+#  (Radar rainfall intensities)
+  3  13  10
+      0  21  36  Radar rainfall intensity
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      0  21  36  Radar rainfall intensity
+     -1
+#  (Non run-length encoded row for Pixel value (4 bits))
+  3  13  31
+      0   6   2  First longitude location minus one increment
+      0   6  12  Longitude increment
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   2  Extended replication factor
+      0  30   1  Pixel value (4 bits)
+     -1
+#  (Non run-length encoded picture data for Pixel value (4 bits))
+  3  13  32
+      0   5   2  First latitude location minus one increment
+      0   5  12  Latitude increment (signed value so cannot cross pole)
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   2  Extended replication factor
+      3  13  31  Non run-length encoded row
+     -1
+#  (Run-length encoded row for Pixel value (4 bits))
+  3  13  41
+      0   6   2  First longitude location minus one increment
+      1  10   0  Delayed replication of 10 descriptors
+      0  31   1  Replication factor
+      1   4   0  Delayed replication of 4 descriptors
+      0  31   1  Replication factor
+      0   6  12  Longitude increment
+      1   1   0  Delayed replication of 1 descriptor
+      0  31  12  Repetition factor
+      0  30   1  Pixel value (4 bits)
+      0   6  12  Longitude increment
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      0  30   1  Pixel value (4 bits)
+     -1
+#  (Run-length encoded picture data for Pixel value (4 bits))
+  3  13  42
+      0   5   2  First latitude location minus one increment
+      0   5  12  Latitude increment (signed value so cannot cross pole)
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   2  Extended replication factor
+      3  13  41  Run-length encoded row
+     -1
+#  "(Run-length encoded picture data for Pixel value (4 bits), regular grid)"
+  3  13  43
+      0   6   2  First longitude location minus one increment
+      0   5   2  First latitude location minus one increment
+      0   5  12  Latitude increment
+      1  12   0  Delayed replication of 12 descriptors
+      0  31   1  Replication factor
+      1  10   0  Delayed replication of 10 descriptors
+      0  31   1  Replication factor
+      1   4   0  Delayed replication of 4 descriptors
+      0  31   1  Replication factor
+      0   6  12  Longitude increment
+      1   1   0  Delayed replication of 1 descriptor
+      0  31  11  Repetition factor
+      0  30   1  Pixel value (4 bits)
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      0  30   1  Pixel value (4 bits)
+     -1
+#  Category 15 - Oceanographic report sequences
+#  (Typically reported underwater sounding without optional fields)
+  3  15   1
+      0   1  11  Ship's call sign
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+      3   6   1  "Depth, temperature"
+     -1
+#  (Typically reported underwater sounding without optional fields)
+  3  15   2
+      0   1  11  Ship's call sign
+      3   1  11  Date
+      3   1  12  Time
+      3   1  23  Latitude and longitude (coarse accuracy)
+      3   6   4  "Depth, temperature, salinity"
+     -1
+#  Category 16 - Synoptic feature sequences
+  3  16   1
+      3   1  11  "Year, month, day"
+      0   4   4  Hour
+      3   1  23  Latitude and longitude (coarse accuracy)
+      0   1  21  Synoptic feature identifier
+      0   2  41  Method for estimating reports related to synoptic features
+      0  19   1  Type of synoptic feature
+      0  10  51  Pressure reduced to mean sea level
+      0  19   2  Effective radius of feature
+      0  19   3  Wind speed threshold (15 m s�1 typically)
+      0  19   4  Effective radius with respect to wind speeds above threshold
+     -1
+#  (Header)
+  3  16   2
+      0   8  21  Data time (analysis)
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+      0   4   4  Hour
+      0   4   5  Minute
+      0   1  33  Originating/generating centre
+      0   8  21  Validity time (fcst)
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+      0   4   4  Hour
+      0   4   5  Minute
+      0   7   2  Flight level (altitude) (base of chart layer)
+      0   7   2  Flight level (altitude) (top of chart layer)
+     -1
+#  (Jet stream)
+  3  16   3
+      1  10   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature (jet stream value)
+      0   8   7  Dimensional significance (value for line)
+      1   4   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0  10   2  Flight level (altitude)
+      0  11   2  Wind speed
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  (Turbulence)
+  3  16   4
+      1  11   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature (value for turbulence)
+      0   8   7  Dimensional significance (value for area)
+      0   7   2  Flight level (altitude) (base of layer)
+      0   7   2  Flight level (altitude) (top of layer)
+      1   2   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0  11  31  Degree of turbulence
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  (Storm)
+  3  16   5
+      1   8   0  Delayed replication
+      0  31   1  Replication
+      0   8   5  Meteorological attribute significance (storm centre)
+      0   8   7  Dimensional significance (value for point)
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0   1  26  WMO storm name (use �unknown� for a sandstorm)
+      0  19   1  Synoptic features (value for type of storm)
+      0   8   7  Dimensional significance (cancel)
+      0   8   5  Meteorological attribute significance (cancel/end of object)
+     -1
+#  (Cloud)
+  3  16   6
+      1  12   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature (value for cloud)
+      0   8   7  Dimensional significance (value for area)
+      0   7   2  Flight level (altitude) (base of layer)
+      0   7   2  Flight level (altitude) (top of layer)
+      1   2   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0  20  11  Cloud amount
+      0  20  12  Cloud type
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  (Front)
+  3  16   7
+      1  10   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature (value for type of front)
+      0   8   7  Dimensional significance (value for line)
+      1   4   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0  19   5  Direction of feature
+      0  19   6  Speed of feature
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  (Tropopause)
+  3  16   8
+      1  11   0  Delayed replication
+      0  31   1  Replication
+      0   8   1  Vertical significance (bit 3 set for tropopause)
+      0   8   7  Dimensional significance (value for point)
+      0   8  23  Statistic (type of tropopause value)
+      1   3   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0  10   2  Height/altitude
+      0   8  23  Statistic (cancel)
+      0   8   7  Dimensional significance (cancel)
+      0   8   1  Vertical significance (cancel/end of object)
+     -1
+#  (Airframe icing area)
+  3  16   9
+      1  11   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature (value for airframe icing)
+      0   8   7  Dimensional significance (value for area)
+      0   7   2  Flight level (altitude) (base of layer)
+      0   7   2  Flight level (altitude) (top of layer)
+      1   2   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0  20  41  Airframe icing (type of airframe icing)
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  (Name of feature)
+  3  16  10
+      1   7   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature
+      0   8   7  Dimensional significance (value for point)
+      0   1  22  Name of feature
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  (Volcano erupting)
+  3  16  11
+      1  16   0  Delayed replication
+      0  31   1  Replication
+      0   8  11  Meteorological feature (value for special clouds)
+      0   1  22  Name of feature (volcano name)
+      0   8   7  Dimensional significance (value for point)
+      1   2   0  Delayed replication
+      0  31   1  Replication
+      0   5   2  Latitude (coarse)
+      0   6   2  Longitude (coarse)
+      0   8  21  Time significance (eruption starting time)
+      0   4   1  Year
+      0   4   2  Month
+      0   4   3  Day
+      0   4   4  Hour
+      0   4   5  Minute
+      0  20  90  Special clouds (clouds from volcanic eruptions)
+      0   8  21  Time significance (cancel)
+      0   8   7  Dimensional significance (cancel)
+      0   8  11  Meteorological feature (cancel/end of object)
+     -1
+#  (Forecast data)
+  3  16  22
+      0   1  32  "Generating application (NWP model name, etc. code table defined by originating/generating centre)"
+      0   2  41  Method for estimating reports related to synoptic feature
+      0  19   1  Type of synoptic feature
+      0  19  10  Method for tracing of the centre of synoptic feature
+      1  18   0  Delayed replication of 18 descriptors
+      0  31   1  Replication factor
+      0   8  21  Time significance (forecast)
+      0   4  14  Time increment (hour)
+      0   8   5  Surface synoptic feature significance
+      3   1  23  "Latitude (coarse accuracy), longitude (coarse accuracy)"
+      0  19   5  Direction of motion of feature
+      0  19   6  Speed of motion of feature
+      0  10   4  Pressure
+      0  11  41  Maximum wind speed (gust: e.g. used in US)
+      0   8  21  Time significance (forecast time averaged)
+      0   4  75  Time period (minutes)
+      0  11  40  Maximum wind speed (mean wind)
+      0  19   8  Vertical extent of feature
+      1   5   4  Replicate 5 descriptors 4 times
+      0   5  21  Starting bearing or azimuth
+      0   5  21  Ending bearing or azimuth
+      1   2   2  Replicate 2 descriptors 2 times
+      0  19   3  Wind speed threshold
+      0  19   4  Effective radius with respect to wind speed above threshold
+     -1
+#  Category 18 - Radiological report sequences
+  3  18   1
+      3   1  25  "Latitude and longitude (coarse accuracy), day and time"
+      0  24  11  Dose
+     -1
+  3  18   3
+      3   1  26  "Latitude and longitude (high accuracy), time periods in days," hours and minutes
+      0  24   5  Isotope mass
+      0  24   4  Element name
+      0  24  21  Air concentration
+     -1
+  3  18   4
+      3   1  25  "Latitude and longitude (coarse accuracy), day and time"
+      0   4  23  Time period or displacement
+      0  13  11  Total precipitation/total water equivalent
+      0  24   5  Isotope mass
+      0  24   4  Element name
+      0  24  22  Concentration in precipitation
+     -1
+#  Category 21 - Radar report sequences
+#  (Wind profiler � antenna characteristics)
+  3  21   1
+      0   2 101  Type of antenna
+      0   2 114  Antenna effective surface area
+      0   2 105  Maximum antenna gain
+      0   2 106  3-dB beamwidth
+      0   2 107  Sidelobe suppression
+      0   2 121  Mean frequency
+     -1
+#  (Wind profiler � moment data)
+  3  21   3
+      0  21  51  Signal power above 1 mW
+      0  21  14  Doppler mean velocity (radial)
+      0  21  17  Doppler velocity spectral width
+      0  21  30  Signal to noise ratio
+     -1
+#  (Wind profiler � moment data sounding)
+  3  21   4
+      3   1  31  "Identification, type, date/time, position (high accuracy), height"
+      0   2   3  Type of measuring equipment used
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      3  21   3  Wind profiler � moment data
+     -1
+#  (Transmitter-receiver characteristics)
+  3  21   5
+      0  25   4  Echo processing
+      0   2 121  Mean frequency
+      0   2 122  Frequency agility range
+      0   2 123  Peak power
+      0   2 124  Average power
+      0   2 125  Pulse repetition frequency
+      0   2 126  Pulse width
+      0   2 127  Receiver intermediate frequency
+      0   2 128  Intermediate frequency bandwidth
+      0   2 129  Minimum detectable signal
+      0   2 130  Dynamic range
+      0   2 131  Sensitivity time control
+     -1
+#  (Integration characteristics)
+  3  21   6
+      0  25   1  Range-gate length
+      0  25   2  Number of gates averaged
+      0  25   3  Number of integrated pulses
+      0  25   5  Echo integration
+     -1
+#  (Corrections)
+  3  21   7
+      0  25   9  Calibration method
+      0  25  10  Clutter treatment
+      0  25  11  Ground occultation correction
+      0  25  12  Range attenuation correction
+      0  25  13  Bright-band correction
+      0  25  15  Radome attenuation correction
+      0  25  16  Clear-air attenuation correction
+      0  25  17  Precipitation attenuation correction
+     -1
+#  (Z to R conversion)
+  3  21   8
+      0  25   6  Z to R conversion
+      0  25   7  Z to R conversion factor
+      0  25   8  Z to R conversion exponent
+     -1
+#  (A to Z law)
+  3  21   9
+      0  25  18  A to Z law for attenuation factor
+      0  25  19  A to Z law for attenuation exponent
+     -1
+#  (Antenna characteristics)
+  3  21  10
+      0   2 101  Type of antenna
+      0   7   2  Altitude of the tower base
+      0   2 102  Antenna height above tower base
+      0   2 103  Radome
+      0   2 104  Antenna polarisation
+      0   2 105  Maximum antenna gain
+      0   2 106  3-dB beamwidth
+      0   2 107  Sidelobe suppression
+      0   2 108  Crosspol discrimination (on axis)
+      0   2 109  Antenna speed (azimuth)
+      0   2 110  Antenna speed (elevation)
+      0   2 132  Azimuth pointing accuracy
+      0   2 133  Elevation pointing accuracy
+     -1
+#  (General characteristics)
+  3  21  11
+      0  30  31  Picture type
+      0  30  32  Combination with other data
+      0  29   2  Coordinate grid type
+     -1
+#  (Antenna elevations)
+  3  21  12
+      1   1   0  Delayed replication of 1 descriptor
+      0  31   1  Replication factor
+      0   2 135  Antenna elevation
+     -1
+#  (Basic information (System/site header) on Wind profiler/RASS)
+  3  21  21
+      0   2   3  Type of measuring equipment used
+      0   2 101  Type of antenna
+      2   1 130  Change width to 8 bits
+      0   2 106  3-dB beam width
+      2   1   0  Change width to table B
+      2   1 132  Change width to 11 bits
+      2   2 130  Change scale to -6
+      0   2 121  Mean frequency
+      2   2   0  Change scale to table B
+      2   1   0  Change width to table B
+      2   1 133  Change width to 11 bits
+      2   2 129  Change scale to 0
+      0  25   1  Range-gate length
+      2   2   0  Change scale to table B
+      2   1   0  Change width to table B
+     -1
+#  (Wind profiler: Processed-data winds)
+  3  21  22
+      0   7   7  Height
+      2   4   1  Add associated field of 1 bit in length
+      0  31  21  Associated field significance
+      0  11   1  Wind direction
+      2   4   0  Cancel add associated field
+      0  11   2  Wind speed
+      2   4   1  Add associated field of 1 bit in length
+      0  31  21  Associated field significance
+      0  11   6  w-component
+      2   4   0  Cancel add associated field
+      0  21  30  Signal to noise ratio
+     -1
+#  Wind profiler: Raw-data winds)
+  3  21  23
+      0   7   7  Height
+      0  21  91  Radar signal Doppler spectrum 0th moment
+      0  21  30  Signal to noise ratio
+      2   2 129  Change scale to 2
+      0  21  14  Doppler mean velocity (radial)
+      2   1 129  Change width to 9 bits
+      0  21  17  Doppler velocity spectral width
+      2   2   0  Change scale to table B
+      2   1   0  Change width to table B
+     -1
+#  (RASS-Mode: Processed-data RASS)
+  3  21  24
+      0   7   7  Height
+      2   4   1  Add associated field of 1 bit in length
+      0  31  21  Associated field significance
+      0  12   7  Virtual temperature
+      0  11   6  w-component
+      2   4   0  Cancel add associated field
+      0  21  30  Signal to noise ratio
+     -1
+#  (RASS-Mode: Raw-data RASS)
+  3  21  25
+      0   7   7  Height
+      0  21  91  Radar signal Doppler spectrum 0th moment
+      0  21  30  Signal to noise ratio
+      2   2 129  Change scale to 2
+      0  21  14  Doppler mean velocity (radial)
+      2   1 129  Change width to 9 bits
+      0  21  17  Doppler velocity spectral width
+      2   2   0  Change scale to table B
+      2   1   0  Change width to table B
+      0  21  92  "RASS signal Doppler spectrum 0th moment, referring to RASS signal"
+      0  21  30  "Signal to noise ratio, referring to RASS signal "
+      0  25  92  Acoustic propagation velocity
+      2   1 129  Change width to 9 bits
+      2   2 129  Change scale to 2
+      0  21  17  "Doppler velocity spectral width, referring to RASS signal"
+      2   2   0  Change scale to table B
+      2   1   0  Change width to table B
+     -1
+#  (RASS data - fluxes)
+  3  21  26
+      0   7   7  Height
+      2   4   1  Add associated field of 1 bit in length
+      0  31  21  Associated field significance
+      0  12   7  Virtual temperature
+      0  25  91  Structure constant of the refraction index (Cn2)
+      0  11  71  Turbulent vertical momentum flux
+      0  11  72  Turbulent vertical buoyancy flux
+      0  11  73  Turbulent kinetic energy
+      0  11  74  Dissipation energy
+      2   4   0  Cancel add associated field
+     -1
+  3  21  27
+      0  21 118  Attenuation correction on sigma-0
+      2   2 129  Change scale
+      2   1 132  Change data width
+      0   2 112  Radar look angle
+      2   1   0  Change data width to Table B
+      2   1 131  Change data width
+      0   2 111  Radar incidence angle
+      2   1   0  Change data width to Table B
+      2   2   0  Change scale back to Table B
+      0   2 104  Antenna polarization
+      0  21 105  Normalized radar cross-section
+      0  21 106  Kp variance coefficient (alpha)
+      0  21 107  Kp variance coefficient (beta)
+      0  21 114  Kp variance coefficient (gamma)
+      0  21 115  SEAWINDS sigma-0 quality
+      0  21 116  SEAWINDS sigma-0 mode
+      0   8  18  SEAWINDS land/ice surface type
+      0  21 117  Sigma-0 variance quality control
+     -1
+  3  21  28
+      0  21 118  Attenuation correction on sigma-0
+      2   2 129  Change scale
+      2   1 132  Change data width
+      0   2 112  Radar look angle
+      2   1   0  Data width back to Table B
+      2   1 131  Change data width
+      0   2 111  Radar incidence angle
+      2   1   0  Data width back to Table B
+      2   2   0  Scale back  to table B
+      0   2 104  Antenna polarization
+      0  21 123  SEAWINDS normalized radar cross section
+      0  21 106  Kp variance coefficient (alpha)
+      0  21 107  Kp variance coefficient (beta)
+      0  21 114  Kp variance coefficient (gamma)
+      0  21 115  SEAWINDS sigma-0 quality flag
+      0  21 116  SEAWINDS sigma-0 mode flag
+      0   8  18  SEAWINDS land/ice surface flag
+      0  21 117  Sigma-0 variance quality control
+     -1
diff --git a/data/tables/convert.c b/data/tables/convert.c
new file mode 100644
index 0000000..81652c2
--- /dev/null
+++ b/data/tables/convert.c
@@ -0,0 +1,170 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <ctype.h>
+#define MAX_BUF 1024
+
+main (int argc, char *argv[])
+{
+    
+    int   line, i, iflag;
+    char  buf[MAX_BUF];
+    char  tokbuf[MAX_BUF];  /* copy of buf[] for strtok() to work on */
+    int   f, x, y, scale, ref, dw;
+    char  *valp;
+
+    char* units;
+    char* description;
+    char file_in[70], file_out[70];
+    FILE *fp_in, *fp_out;
+
+    if ( argc != 2 )
+    {
+      printf(" ERROR:  no arguments\n");
+      printf(" convert <filename:\n");
+      exit(-1);
+    }
+    sprintf(file_in,"%s.old",argv[1]);
+    printf(" full input file name =%s\n", file_in);
+    sprintf(file_out,"%s",argv[1]);
+    printf(" full output file name =%s\n", file_out);
+    sprintf(buf, "mv %s %s.old\n", argv[1], argv[1]);
+    system(buf);
+    
+    if( (fp_in = fopen( file_in, "r" )) == NULL )
+    {
+        sprintf( buf, "Can't open input file \"%s\"\n", file_in );
+        exit(1);
+    }
+    if( (fp_out = fopen( file_out, "w" )) == NULL )
+    {
+        sprintf( buf, "Can't open output file \"%s\"\n", file_in );
+        exit(1);
+    }
+    
+    for( line=1; fgets( buf, MAX_BUF, fp_in ) != NULL; line++ )
+    {
+        iflag = 0;
+        valp = buf;
+        if( *valp == '#')
+        {
+          fprintf(fp_out,"%s", buf);
+        } else if ( strlen(buf) == 1 ) {
+          fprintf(fp_out,"\n");
+        }else{
+          /*
+          * Since strtok() mangles the string it works on, let strtok() use
+          * a copy of buf.
+          */
+
+          strcpy( tokbuf, buf );
+
+          /*
+          * Trim trailing whitespace in 'tokbuf' (this makes it easier
+          * to get the description later on).
+          */
+
+          /*  092997  LAH: Added char cast to correct Linux warning */
+          /* 100997 LAH: Added ulong_t cast */
+          for( valp=&tokbuf[strlen(tokbuf)-1]; isspace( *valp ); valp-- )
+             *valp = (char) NULL;
+
+          /* Get F, X, and Y portion and compute table location */
+
+          if( (valp = strtok( tokbuf, " -\t" )) == NULL )
+          {
+            printf("Line %d: Missing F descriptor\n", line);
+            iflag = 1;
+          }
+          else
+            f = atoi( valp );
+
+          if (iflag == 0)
+          {
+            if( (valp = strtok( NULL, " -\t" )) == NULL )
+            {
+              printf("Line %d: Missing X descriptor\n", line);
+              iflag =1;
+           
+            }
+            else
+              x = atoi( valp );
+          }
+
+          if ( iflag == 0)
+          {
+            if( (valp = strtok( NULL, " \t" )) == NULL )
+            {
+              printf("%Line %d: Missing Y descriptor\n", line);
+              iflag = 1;
+            }
+            else
+             y = atoi( valp );
+          }
+
+          
+/* Check for descriptor duplication. */
+          if (iflag == 0 )
+          {
+      	    if( (valp = strtok( NULL, " \t" )) == NULL )
+            {
+              printf("Line %d: Missing Scale value\n", line);
+            } else
+              scale = atoi( valp );
+          }
+
+          if ( iflag == 0 )
+          {
+            if( (valp = strtok( NULL, " \t" )) == NULL )
+            {
+              printf("Line %d: Missing Reference Value\n", line );
+              iflag =1;
+            } else
+              ref = atoi( valp );
+          }
+
+          if ( iflag == 0 )
+          {
+            if( (valp = strtok( NULL, " \t" )) == NULL )
+            {
+              printf(" Line %d: Missing Data Width value\n", line );
+              iflag = 1;
+            } else
+              dw = atoi( valp );
+          }
+
+
+          if ( iflag == 0)
+          {
+            if( (units = strtok( NULL, " \t\n" )) == NULL )
+            {
+              printf("Line %d: Missing Units description\n", line );
+              iflag == 1;
+            }
+          }
+
+          /* Ignore leading whitespace. */
+
+          /*  092997  LAH: Added cast to correct Linux warning */
+          for( valp=units+strlen(units)+1; *valp != (char) NULL; valp++ )
+          {
+            /* 100997 LAH: Added ulong_t cast */
+            if( !isspace( *valp ) )
+                break;
+          }
+
+          /*  092997  LAH: Added cast to correct Linux warning */
+          if( *valp == '\n' || *valp == (char) NULL )
+            description = strdup( "???" );
+          else
+            description = strdup( valp );
+
+          if ( iflag == 0)
+          {
+            fprintf(fp_out, "%3d;%5d;%7d;%7d;%12d;%5d; %12s; %s\n",
+	            f,x,y,scale,ref,dw,units,description);
+          }
+        }
+     }
+     return 0;
+}
diff --git a/data/udunits.dat b/data/udunits.dat
new file mode 100644
index 0000000..c895056
--- /dev/null
+++ b/data/udunits.dat
@@ -0,0 +1,682 @@
+# $Id: udunits.dat,v 1.2 1995/08/29 19:15:20 steve Exp $
+#
+# The first column is the unit name.  The second column indicates whether or
+# not the unit name has a plural form (i.e. with an 's' appended).  
+# A 'P' indicates that the unit has a plural form, whereas, a 'S' indicates
+# that the unit has a singular form only.  The remainder of the line is the 
+# definition for the unit.
+#
+# '#' is the to-end-of-line comment-character.
+#
+# NB: When adding to this table, be *very* careful to distinquish between
+# the letter 'O' and the numeral zero '0'.  For example, the following two
+# entries don't do what one might otherwise expect:
+#
+#	mercury_0C		mercury_32F
+#	millimeter_Hg_0C	mm mercury_OC
+
+#
+# BASE UNITS.  These must be first and are identified by a nil definition.
+#
+ampere			P			# electric current
+bit			P			# unit of information
+candela			P			# luminous intensity
+kelvin			P			# thermodynamic temperature
+kilogram		P			# mass
+meter			P			# length
+mole			P			# amount of substance
+second			P			# time
+radian			P			# plane angle
+
+#
+# CONSTANTS
+#
+percent			S 0.01
+PI			S 3.14159265358979323846
+bakersdozen		S 13
+pair			P 2
+ten			P 10
+dozen			S 12
+score			S 20
+hundred			P 100
+thousand		P 1.0e3
+million			P 1.0e6
+
+%			S percent
+pi			S PI
+
+#
+# NB: All subsequent definitions must be given in terms of
+# earlier definitions.  Forward referencing is not permitted.
+#
+
+#
+# The following are non-base units of the fundamental quantities
+#
+
+#
+# UNITS OF ELECTRIC CURRENT
+#
+A			S ampere
+amp			P ampere
+abampere		P 10 ampere		# exact
+gilbert			P 7.957747e-1 ampere
+statampere		P 3.335640e-10 ampere
+biot			P 10 ampere
+
+#
+# UNITS OF LUMINOUS INTENSITY
+#
+cd			S candela
+candle			P candela
+
+#
+# UNITS OF THERMODYNAMIC TEMPERATURE
+#
+degree_Kelvin		P kelvin
+degree_Celsius		S kelvin @ 273.15
+degree_Rankine		P kelvin/1.8
+degree_Fahrenheit	P degree_Rankine @ 459.67
+
+#C			S degree_Celsius	# `C' means `coulomb'
+Celsius			S degree_Celsius
+celsius			S degree_Celsius
+centigrade		S degree_Celsius
+degC			S degree_Celsius
+degreeC			S degree_Celsius
+degree_C		S degree_Celsius
+degree_c		S degree_Celsius
+deg_C			S degree_Celsius
+deg_c			S degree_Celsius
+degK			S kelvin
+degreeK			S kelvin
+degree_K		S kelvin
+degree_k		S kelvin
+deg_K			S kelvin
+deg_k			S kelvin
+K			S kelvin
+Kelvin			P kelvin
+
+degF			S degree_Fahrenheit
+degreeF			S degree_Fahrenheit
+degree_F		S degree_Fahrenheit
+degree_f		S degree_Fahrenheit
+deg_F			S degree_Fahrenheit
+deg_f			S degree_Fahrenheit
+F			S degree_Fahrenheit
+Fahrenheit		P degree_Fahrenheit
+fahrenheit		P degree_Fahrenheit
+
+degR			S degree_Rankine
+degreeR			S degree_Rankine
+degree_R		S degree_Rankine
+degree_r		S degree_Rankine
+deg_R			S degree_Rankine
+deg_r			S degree_Rankine
+#R			S degree_Rankine	# `R' means `roentgen'
+Rankine			P degree_Rankine
+rankine			P degree_Rankine
+
+#
+# UNITS OF MASS
+#
+assay_ton		P 2.916667e2 kilogram
+avoirdupois_ounce	P 2.834952e-2 kilogram
+avoirdupois_pound	P 4.5359237e-1 kilogram	# exact
+carat			P 2e-4 kilogram
+grain			P 6.479891e-5 kilogram	# exact
+gram			P 1e-3 kilogram		# exact
+kg			S kilogram
+long_hundredweight	P 5.080235e1 kilogram
+metric_ton		P 1e3 kilogram		# exact
+pennyweight		P 1.555174e-3 kilogram
+short_hundredweight	P 4.535924e1 kilogram
+slug			P 14.59390 kilogram
+troy_ounce		P 3.110348e-2 kilogram
+troy_pound		P 3.732417e-1 kilogram
+atomic_mass_unit	P 1.66044e-27 kilogram
+
+tonne			P metric_ton
+apothecary_ounce	P troy_ounce
+apothecary_pound	P avoirdupois_pound
+pound			P avoirdupois_pound
+metricton		P metric_ton
+gr			S grain
+scruple			P 20 grain
+apdram			P 60 grain
+apounce			P 480 grain
+appound			P 5760 grain
+atomicmassunit		P atomic_mass_unit
+amu			P atomic_mass_unit
+
+t			S tonne
+lb			P pound
+bag			P 94 pound
+short_ton		P 2000 pound
+long_ton		P 2240 pound
+
+ton			P short_ton
+shortton		P short_ton
+longton			P long_ton
+
+#
+# UNITS OF LENGTH
+#
+angstrom		P decinanometer
+astronomical_unit	P 1.495979e11 meter
+fathom			P 1.828804 meter
+fermi			P 1e-15 meter		# exact
+m			S meter
+metre			P meter
+light_year		P 9.46055e15 meter
+micron			P 1e-6 meter		# exact
+mil			P 2.54e-5 meter		# exact
+nautical_mile		P 1.852000e3 meter	# exact
+parsec			P 3.085678e16 meter
+printers_point		P 3.514598e-4 meter	# exact
+US_statute_mile		P 1.609347e3 meter	# = intn'l mile + .000003 meter
+US_survey_foot		P 3.048006e-1 meter
+chain			P 2.011684e1 meter
+
+inch			S 2.54 cm		# exact
+printers_pica		P 12 printers_point	# exact
+astronomicalunit	P astronomical_unit
+au			S astronomical_unit
+nmile			P nautical_mile
+nmi			S nautical_mile
+
+pica			P printers_pica
+big_point		P inch/72		# exact
+inches			S inch
+foot			S 12 inch		# exact
+in			S inch
+barleycorn		P inch/3
+
+ft			S foot
+feet			S foot
+yard			P 3 foot
+furlong			P 660 foot
+international_mile	P 5280 foot		# exact
+arpentlin		P 191.835 foot
+
+yd			S yard
+rod			P 5.5 yard
+mile			P international_mile
+
+arpentcan		P 27.52 mile
+
+#
+# UNITS OF AMOUNT OF SUBSTANCE
+#
+mol			S mole
+
+#
+# UNITS OF TIME
+#
+day			P 8.64e4 second		# exact
+hour			P 3.6e3 second		# exact
+minute			P 60 second		# exact
+s			S second
+sec			P second
+shake			P 1e-8 second		# exact
+sidereal_day		P 8.616409e4 second
+sidereal_hour		P 3.590170e3 second
+sidereal_minute		P 5.983617e1 second
+sidereal_second		P 0.9972696 second
+sidereal_year		P 3.155815e7 second
+# Interval between 2 successive passages of sun through vernal equinox
+# (365.242198781 days -- see 
+# http://www.ast.cam.ac.uk/RGO/leaflets/calendar/calendar.html
+# and http://adswww.colorado.edu/adswww/astro_coord.html):
+tropical_year		P 3.15569259747e7 second
+lunar_month		P 29.530589 day
+
+common_year		P 365 day		# exact: 153600e7 seconds
+leap_year		P 366 day		# exact
+Julian_year		P 365.25 day		# exact
+Gregorian_year		P 365.2425 day		# exact
+sidereal_month		P 27.321661 day
+tropical_month		P 27.321582 day
+d			S day
+min			P minute
+hr			P hour
+h			S hour
+fortnight		P 14 day		# exact
+week			P 7 day			# exact
+
+year			P tropical_year
+
+yr			P year
+a			S year			# "anno"
+eon			P 1e9 year		# fuzzy
+month			P year/12		# on average
+
+#
+# UNITS OF PLANE ANGLE
+#
+#rad			P radian		# `rad' means `grey'
+circle			P 2 pi radian
+angular_degree		P (pi/180) radian
+
+turn			P circle
+degree			P angular_degree
+degree_north		S angular_degree
+degree_east		S angular_degree
+degree_true		S angular_degree
+arcdeg			P angular_degree
+angular_minute		P angular_degree/60
+angular_second		P angular_minute/60
+grade			P 0.9 angular_degree	# exact
+
+degrees_north		S degree_north
+degreeN			S degree_north
+degree_N		S degree_north
+degreesN		S degree_north
+degrees_N		S degree_north
+
+degrees_east		S degree_east
+degreeE			S degree_east
+degree_E		S degree_east
+degreesE		S degree_east
+degrees_E		S degree_east
+
+degree_west             S -1 degree_east
+degrees_west            S degree_west
+degreeW                 S degree_west
+degree_W                S degree_west
+degreesW                S degree_west
+degrees_W               S degree_west
+
+degrees_true		S degree_true
+degreeT			S degree_true
+degree_T		S degree_true
+degreesT		S degree_true
+degrees_T		S degree_true
+
+arcminute		P angular_minute
+arcsecond		P angular_second
+
+arcmin			P arcminute
+arcsec			P arcsecond
+
+#
+# The following are derived units with special names.  They are useful for
+# defining other derived units.
+#
+steradian		P radian2
+hertz			S 1/second
+newton			P kilogram.meter/second2
+coulomb			P ampere.second
+lumen			P candela steradian
+becquerel		P 1/second		# SI unit of activity of a 
+#						# radionuclide
+standard_free_fall	S 9.806650 meter/second2	# exact
+
+pascal			P newton/meter2
+joule			P newton.meter
+hz			S hertz
+sr			S steradian
+force			S standard_free_fall
+gravity			S standard_free_fall
+free_fall		S standard_free_fall
+lux			S lumen/meter2
+sphere			P 4 pi steradian
+
+luxes			S lux
+watt			P joule/second
+gray			P joule/kilogram	# absorbed dose. derived unit
+sievert			P joule/kilogram	# dose equivalent. derived unit
+mercury_32F		S gravity 13595.065 kg/m3
+mercury_60F		S gravity 13556.806 kg/m3
+water_39F		S gravity 999.97226 kg/m3	# actually 39.2 F
+water_60F		S gravity 999.00072 kg/m3
+g			S gravity
+
+volt			P watt/ampere
+mercury_0C		S mercury_32F
+mercury			S mercury_32F
+water			S water_39F
+
+farad			P coulomb/volt
+ohm			P volt/ampere
+siemens			S ampere/volt
+weber			P volt.second
+Hg			S mercury
+hg			S mercury
+H2O			S water
+h2o			S water
+
+tesla			P weber/meter2
+henry			P weber/ampere
+
+#
+# The following are compound units: units whose definitions consist 
+# of two or more base units.  They may now be defined in terms of the 
+# preceding units.
+#
+
+#
+# ACCELERATION
+#
+gal			P 1e-2 meter/second2	# exact
+
+#
+# Area
+#
+are			P 1e2 m2		# exact
+barn			P 1e-28 m2		# exact
+circular_mil		P 5.067075e-10 m2
+darcy			P 9.869233e-13 m2	# permeability of porous solids
+hectare			P 1e4 m2		# exact
+acre			P 4840 yard2
+
+#
+# ELECTRICITY AND MAGNETISM
+#
+abfarad			P 1e9 farad		# exact
+abhenry			P 1e-9 henry		# exact
+abmho			P 1e9 siemens		# exact
+abohm			P 1e-9 ohm		# exact
+abvolt			P 1e-8 volt		# exact
+C			S coulomb
+e			S 1.6021917e-19 coulomb	# charge of electron
+chemical_faraday	P 9.64957e4 coulomb
+physical_faraday	P 9.65219e4 coulomb
+C12_faraday		P 9.64870e4 coulomb
+gamma			P 1e-9 tesla		# exact
+gauss			S 1e-4 tesla		# exact
+H			S henry
+maxwell			P 1e-8 weber		# exact
+oersted			P 7.957747e1 ampere/meter
+S			S siemens
+statcoulomb		P 3.335640e-10 coulomb
+statfarad		P 1.112650e-12 farad
+stathenry		P 8.987554e11 henry
+statmho			P 1.112650e-12 siemens
+statohm			P 8.987554e11 ohm
+statvolt		P 2.997925e2 volt
+T			S tesla
+unit_pole		P 1.256637e-7 weber
+V			S volt
+Wb			S weber
+mho			P siemens
+Oe			S oersted
+faraday			P C12_faraday		# charge of 1 mole of 
+#						# electrons
+
+#
+# ENERGY (INCLUDES WORK)
+#
+electronvolt		P 1.60219e-19 joule
+erg			P 1e-7 joule		# exact
+IT_Btu			P 1.055056 joule	# exact
+EC_therm		P 1.05506e8 joule
+thermochemical_calorie	P 4.184000 joule	# exact
+IT_calorie		P 4.1868 joule		# exact
+J			S joule
+ton_TNT			S 4.184e9 joule
+US_therm		P 1.054804e8 joule	# exact
+watthour		P watt hour
+
+therm			P US_therm
+Wh			S watthour
+Btu			P IT_Btu
+calorie			P IT_calorie
+electron_volt		P electronvolt
+
+thm			S therm
+cal			S calorie
+eV			S electronvolt
+bev			S gigaelectron_volt
+
+#
+# FORCE
+#
+dyne			P 1e-5 newton		# exact
+pond			P 1.806650e-3 newton	# exact
+force_kilogram		S 9.806650 newton	# exact
+force_ounce		S 2.780139e-1 newton
+force_pound		S 4.4482216152605 newton# exact
+poundal			P 1.382550e-1 newton
+N			S newton
+gf			S gram force
+
+force_gram		P 1e-3 force_kilogram
+force_ton		P 2000 force_pound	# exact
+lbf			S force_pound
+ounce_force		S force_ounce
+kilogram_force		S force_kilogram
+pound_force		S force_pound
+ozf			S force_ounce
+kgf			S force_kilogram
+
+kip			P 1000 lbf
+ton_force		S force_ton
+gram_force		S force_gram
+
+#
+# HEAT
+#
+clo			P 1.55e-1 kelvin.meter2/watt
+
+#
+# LIGHT
+#
+lm			S lumen
+lx			S lux
+footcandle		P 1.076391e-1 lux
+footlambert		P 3.426259 candela/meter2
+lambert			P (1e4/PI) candela/meter2	# exact
+stilb			P 1e4 candela/meter2	# exact
+phot			P 1e4 lumen/meter2	# exact
+nit			P 1 candela/meter2	# exact
+langley			P 4.184000e4 joule/meter2	# exact
+blondel			P candela/(pi meter2)
+
+apostilb		P blondel
+nt			S nit
+ph			S phot
+sb			S stilb
+
+#
+# MASS PER UNIT LENGTH
+#
+denier			P 1.111111e-7 kilogram/meter
+tex			P 1e-6 kilogram/meter	# exact
+
+#
+# MASS PER UNIT TIME (INCLUDES FLOW)
+#
+perm_0C			S 5.72135e-11 kg/(Pa.s.m2)
+perm_23C		S 5.74525e-11 kg/(Pa.s.m2)
+
+#
+# POWER
+#
+voltampere		P volt ampere
+VA			S volt ampere
+boiler_horsepower	P 9.80950e3 watt
+shaft_horsepower	P 7.456999e2 watt
+metric_horsepower	P 7.35499 watt
+electric_horsepower	P 7.460000e2 watt	# exact
+W			S watt
+water_horsepower	P 7.46043e2 watt
+UK_horsepower		P 7.4570e2 watt
+refrigeration_ton	P 12000 Btu/hour
+
+horsepower		P shaft_horsepower
+ton_of_refrigeration	P refrigeration_ton
+
+hp			S horsepower
+
+#
+# PRESSURE OR STRESS
+#
+bar			P 1e5 pascal		# exact
+standard_atmosphere	P 1.01325e5 pascal	# exact
+technical_atmosphere	P 1 kg gravity/cm2	# exact
+inch_H2O_39F		S inch water_39F
+inch_H2O_60F		S inch water_60F
+inch_Hg_32F		S inch mercury_32F
+inch_Hg_60F		S inch mercury_60F
+millimeter_Hg_0C	S mm mercury_0C
+footH2O			S foot water
+cmHg			S cm Hg
+cmH2O			S cm water
+Pa			S pascal
+inch_Hg			S inch Hg
+inch_hg			S inch Hg
+inHg			S inch Hg
+in_Hg			S inch Hg
+in_hg			S inch Hg
+millimeter_Hg		S mm Hg
+mmHg			S mm Hg
+mm_Hg			S mm Hg
+mm_hg			S mm Hg
+torr			P mm Hg
+foot_H2O		S foot water
+ftH2O			S foot water
+psi			S 1 pound gravity/in2
+ksi			S kip/in2
+barie			P 0.1 newton/meter2
+
+at			S technical_atmosphere
+atmosphere		P standard_atmosphere
+atm			P standard_atmosphere
+barye			P barie
+
+#
+# RADIATION UNITS
+#
+Bq			S becquerel
+curie			P 3.7e10 becquerel	# exact
+rem			P 1e-2 sievert		# dose equivalent. exact
+rad			P 1e-2 gray		# absorbed dose. exact
+roentgen		P 2.58e-4 coulomb/kg	# exact
+Sv			S sievert
+Gy			S gray
+
+Ci			S curie
+R			S roentgen
+rd			S rad
+
+#
+# VELOCITY (INCLUDES SPEED)
+#
+c			S 2.997925e+8 meter/sec
+knot			P nautical_mile/hour
+
+knot_international	S knot
+international_knot	S knot
+kt			P knot
+
+#
+# VISCOSITY
+#
+poise			S 1e-1 pascal second	# absolute viscosity. 
+#						# exact
+stokes			S 1e-4 meter2/second	# exact
+rhe			S 10/(pascal second)	# exact
+
+St			S stokes
+
+#
+# VOLUME (INCLUDES CAPACITY)
+#
+acre_foot		S 1.233489e3 m3
+board_foot		S 2.359737e-3 m3
+bushel			P 3.523907e-2 m3
+UK_liquid_gallon	P 4.546092e-3 m3
+Canadian_liquid_gallon	P 4.546090e-3 m3
+US_dry_gallon		P 4.404884e-3 m3
+US_liquid_gallon	P 3.785412e-3 m3
+cc			S cm3
+liter			P 1e-3 m3		# exact. However, from 1901 to 
+#						# 1964, 1 liter = 1.000028 dm3
+stere			P 1 m3			# exact
+register_ton		P 3.831685 m3
+
+US_dry_quart		P US_dry_gallon/4
+US_dry_pint		P US_dry_gallon/8
+
+US_liquid_quart		P US_liquid_gallon/4
+US_liquid_pint		P US_liquid_gallon/8
+US_liquid_cup		P US_liquid_gallon/16
+US_liquid_gill		P US_liquid_gallon/32
+US_fluid_ounce		P US_liquid_gallon/128
+US_liquid_ounce		P US_fluid_ounce
+
+UK_liquid_quart		P UK_liquid_gallon/4
+UK_liquid_pint		P UK_liquid_gallon/8
+UK_liquid_cup		P UK_liquid_gallon/16
+UK_liquid_gill		P UK_liquid_gallon/32
+UK_fluid_ounce		P UK_liquid_gallon/160
+UK_liquid_ounce		P UK_fluid_ounce
+
+liquid_gallon		P US_liquid_gallon
+fluid_ounce		P US_fluid_ounce
+#liquid_gallon		P UK_liquid_gallon
+#fluid_ounce		P UK_fluid_ounce
+
+dry_quart		P US_dry_quart
+dry_pint		P US_dry_pint
+
+liquid_quart		P liquid_gallon/4
+liquid_pint		P liquid_gallon/8
+
+gallon			P liquid_gallon
+barrel			P 42 US_liquid_gallon	# petroleum industry definition
+quart			P liquid_quart
+pint			P liquid_pint
+cup			P liquid_gallon/16
+gill			P liquid_gallon/32
+tablespoon		P US_fluid_ounce/2
+teaspoon		P tablespoon/3
+peck			P bushel/4
+
+oz			P fluid_ounce
+floz			S fluid_ounce
+acre_feet		S acre_foot
+board_feet		S board_foot
+Tbl			P tablespoon
+Tbsp			S tablespoon
+tbsp			S tablespoon
+Tblsp			S tablespoon
+tblsp			S tablespoon
+litre			P liter
+l			S liter
+tsp			S teaspoon
+pk			S peck
+bu			S bushel
+
+fldr			S floz/8
+dram			P floz/16
+
+bbl			S barrel
+firkin			P barrel/4		# exact but barrel is vague
+pt			S pint
+dr			S dram
+
+
+#
+# COMPUTERS AND COMMUNICATION
+#
+baud			S 1/second		# exact
+b			S bit
+bps			S bit/second
+cps			S hertz
+
+Bd			S baud
+
+#
+# MISC
+#
+kayser			P 1e2/meter		# exact
+rps			S hertz
+rpm			S hertz/60
+geopotential		S gravity
+work_year		P 2056 hours
+work_month		P work_year/12
+
+gp			S geopotential
+dynamic			S geopotential
diff --git a/doc/Tutorial_Espanol.doc b/doc/Tutorial_Espanol.doc
index 7d1c923..7008cd4 100644
Binary files a/doc/Tutorial_Espanol.doc and b/doc/Tutorial_Espanol.doc differ
diff --git a/doc/ascii.html b/doc/ascii.html
new file mode 100644
index 0000000..92aed9c
--- /dev/null
+++ b/doc/ascii.html
@@ -0,0 +1,149 @@
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
+
+<html>
+<head>
+<title>Controlling Colors in GrADS</title>
+<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
+<style type="text/css">
+body {
+	background-color: #e0f0ff;
+}
+.red {
+	color: #900;
+}
+</style>
+</head>
+<body text="#000000">
+
+<h2><b>ASCII or Text Data and GrADS</b></h2>
+<p> </p>
+<p><font size=+1><b><i>Input ASCII data</i></b></font></p>
+<p>
+GrADS does not directly handle data in ASCII format -- there is no such thing as '<a href="http://iges.org/grads/gadoc/descriptorfile.html#DTYPE" target="pages">dtype</a> ascii'. ASCII data must be converted to into one of the binary data formats that are handled by GrADS. There are many ways to do this with a variety of programming/scripting languages and tools. Below is a very simple example of how you could do it using a GrADS script. 
+<p>Suppose you have an ascii file that contains a column of 100 numbers: 
+<pre>18864
+20844
+24124
+27388 
+36884
+39836
+...</pre>
+<p>Here is a how you would convert that to a binary file using GrADS. You must have a file open for this to work, any file will do.  </p>
+<pre>'open dummy.ctl'
+file = 'my_ascii_file.txt'
+datafile = 'my_binary_file.dat'
+'set gxout fwrite'
+'set fwrite -ap 'datafile
+'!/bin/rm -f 'datafile
+while (1)
+  res = read(file)
+  line1 = sublin(res,1)
+  line2 = sublin(res,2)
+  rc1 = subwrd(line1,1)
+  if (rc1); break; endif
+  val = subwrd(line2,1)
+  'd 'val
+endwhile<br>rc = close(file)
+'disable fwrite'</pre>
+The descriptor file would look like this, assuming you wanted to map your data into the X dimension:
+<pre><p>dset ^my_binary_file.dat<br>title Sample of ASCII data converted to binary
+undef -9.99e8<br>xdef 100 linear 1 1<br>ydef 1 linear 1 1<br>zdef 1 linear 1 1<br>tdef 1 linear 01jan0001 1dy<br>vars 1<br>a 0 99 ascii variable<br>endvars</pre>
+<p>
+  <font size=+1><b><i>Output Gridded Data in ASCII Format</i></b></font><p>
+1. GrADS can create 
+ascii output for any display with the '<a href="gradcomdsetgxout.html" target="pages">set gxout</a> print' option. The formatting of the output is controlled with the '<a href="gradcomdsetprnopts.html" target="pages">set prnopts</a>' command. The output is printed to the command window, but it is also stored in the internal variable 'result' inside a script, where it can be easily output to a file. Below is a simple script example to write  formatted ascii output to a file. Note that the [...]
+<pre>
+'open /data/grib/model/model.ctl'
+'set x 1 72'
+outfile = 'my_ascii_file.txt'
+'set gxout print'
+'set prnopts %7.3f 72 1'
+'d ts'
+rc = write(outfile,result)</pre>
+<p>The beginning of the file my_ascii_file.txt looks like this:</p>
+<pre>
+Printing Grid -- 3312 Values -- Undef = -9.99e+08
+258.493 258.493 258.493 258.493 258.493 258.493 258.493 258.493 258.493 258.493 258.493 <etc.>   </pre>
+
+
+<p>2. In the above example, note that the first line of the output file will contain some diagnostic information about the number of values written and the undef value. If you want to omit that line and write out just the ascii data, then use this slightly more complicated version of the script which skips over the first line of diagnostic info. Two other changes in this example are in the formatting (the output will be comma delimited for  importing into a spreadsheet) and the displayed [...]
+<pre>
+'open /data/grib/model/model.ctl'
+'set x 1 72'
+outfile='my_ascii_file.txt'
+'!/bin/rm -f 'outfile
+'set gxout print'
+'set prnopts %g, 72 0'
+'d ts-273.15'
+i=1
+while (1)
+  line = sublin(result,i)
+  if (line = ''); break; endif
+  if (i>1)
+    rc = write(outfile,line,append)
+  endif
+  i=i+1
+endwhile</pre>
+<p>Now the beginning of the output file my_ascii_file.txt looks like this:</p>
+<pre>
+-14.6567,-14.6567,-14.6567,-14.6567,-14.6567,-14.6567,-14.6567,-14.6567,-14.6567,<etc.>
+</pre>
+
+<p>3. If you want to write out the grid information along with data from more than one variable, then you must save the result from the display of each variable/expression (including longitude and latitude), parse each data point individually, construct the line of ascii output, and then write it out. Here is an example the writes out longitude, latitude, surface temperature, surface pressure, and precipitation:
+<pre>'open /data/grib/model/model.ctl'
+'set x 1 72'
+outfile='my_ascii_file.txt'
+'!/bin/rm -f 'outfile
+'set gxout print'
+fmt='%8.3f'
+numcols=72
+'set prnopts 'fmt' 'numcols' 1'
+'d lon'
+lon_data = result
+'d lat'
+lat_data = result
+'d ts'
+v1_data = result
+'d ps'
+v2_data = result
+'d p'
+v3_data = result
+i=1
+while (1)
+  lons  = sublin(lon_data,i)
+  lats  = sublin(lat_data,i)
+  line1 = sublin(v1_data,i)
+  line2 = sublin(v2_data,i)
+  line3 = sublin(v3_data,i)
+  if (lons='' | lats='' | line1='' | line2='' | line3=''); break; endif
+  if (i>1)
+    j=1
+    while (j<=numcols)
+      str = subwrd(lons,j); lon = math_format(fmt,str)
+      str = subwrd(lats,j); lat = math_format(fmt,str)
+      str = subwrd(line1,j); v1 = math_format(fmt,str)
+      str = subwrd(line2,j); v2 = math_format(fmt,str)
+      str = subwrd(line3,j); v3 = math_format(fmt,str)
+      record = lon' 'lat' 'v1' 'v2' 'v3
+      rc = write(outfile,record,append)
+      j=j+1
+    endwhile
+  endif
+  i=i+1
+endwhile
+</pre>
+<p>Now the head of the output file my_ascii_file.txt looks like this:</p>
+<pre>
+   0.000  -90.000  258.493  669.911    0.000
+   5.000  -90.000  258.493  669.911    0.000
+  10.000  -90.000  258.493  669.911    0.000
+  15.000  -90.000  258.493  669.911    0.000
+  20.000  -90.000  258.493  669.911    0.000
+  25.000  -90.000  258.493  669.911    0.000
+  30.000  -90.000  258.493  669.911    0.000
+  35.000  -90.000  258.493  669.911    0.000
+  40.000  -90.000  258.493  669.911    0.000
+</pre>
+</body>
+</html>
+
diff --git a/doc/basemap.html b/doc/basemap.html
new file mode 100644
index 0000000..8236a1f
--- /dev/null
+++ b/doc/basemap.html
@@ -0,0 +1,139 @@
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
+
+<html>
+<head>
+<title>Controlling Colors in GrADS</title>
+<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
+<style type="text/css">
+body {
+	background-color: #e0f0ff;
+}
+.red {
+	color: #900;
+}
+</style>
+</head>
+<body text="#000000">
+
+<h2><b>basemap</b>.gs</h2>
+<p>This is documentation for <a href="ftp://cola.gmu.edu/grads/scripts/basemap.gs">basemap.gs</a>, a GrADS script that overlays a land or ocean mask that exactly matches the coastal outlines of the three GrADS map files: lowres, mres, and hires. Basemap works by overlaying polygons on top of an existing display; once they are all drawn, the polygons appear as a solid region that covers the land or ocean areas. Basemap does not actually mask the data, it only masks the display of the data.<br>
+<H3>Syntax </H3>
+<code>basemap.gs L(and)/O(cean) <fill_color> <outline_color> <L(owres)/M(res)/H(ires)></code>
+<p>
+The land and ocean masks are composed of hundreds of 
+polygons that are specified in accompanying ASCII files. The ASCII files must be downloaded from the GrADS script library. Once you have downloaded these files and stored them in a convenient location, you must update your copy of basemap.gs to include the path of the location of these files. The script will not work without these files. <br>
+  <a href="ftp://cola.gmu.edu/grads/scripts/lpoly_lowres.asc">ftp://cola.gmu.edu/grads/scripts/lpoly_lowres.asc </a><br>
+  <a href="ftp://cola.gmu.edu/grads/scripts/lpoly_mres.asc">ftp://cola.gmu.edu/grads/scripts/lpoly_mres.asc</a><br>
+  <a href="ftp://cola.gmu.edu/grads/scripts/lpoly_hires.asc">ftp://cola.gmu.edu/grads/scripts/lpoly_hires.asc </a><br>
+  <a href="ftp://cola.gmu.edu/grads/scripts/opoly_lowres.asc">ftp://cola.gmu.edu/grads/scripts/opoly_lowres.asc </a><br>
+  <a href="ftp://cola.gmu.edu/grads/scripts/opoly_mres.asc">ftp://cola.gmu.edu/grads/scripts/opoly_mres.asc </a><br>
+  <a href="ftp://cola.gmu.edu/grads/scripts/opoly_hires.asc">ftp://cola.gmu.edu/grads/scripts/opoly_hires.asc </a><br>
+<h3>Usage Notes </h3>
+<ol>
+  <li>  The default values for the optional arguments are: fill_color 15, outline_color 0, and Lowres. </li>
+  <li>For the low and medium resolution map files, coverage is global. 
+    For the high resolution map, coverage is limited to North America 
+    (0-90N, 170W-10W). </li>
+  <li>Basemap will work with any scaled or latlon map projection. 
+    If you are using Grads <span class="red">version 1.8+,</span> this script 
+    will also work properly with the robinson projection and 
+    polar stereographic projections from 0-90, 15-90, and 20-90 
+    (North and South).  Other projections will work but are not 
+    guaranteed because GrADS may not clip the basemap polygons properly. 
+    A solution to this  problem is to use "set mpvals" to override 
+    the dimension environment limits. See example #2 below. </li>
+  <li>A special basemap option is available to mask out the Mexican and 
+    Canadian land regions surrounding the US, so that only the 
+    conterminous states are seen. See Example #3 below. </li>
+</ol>
+<h3><a name="basemap_transparent"></a>Basemap and Transparent Colors</h3>
+<p>GrADS <span class="red">version 2.1+</span> has the capability to <a href="colorcontrol.html#transparent" target="pages">add a transparency level to any defined color.</a> This feature is especially complementary to  basemap's capabilities because the land/ocean areas can be subtly identified without completely covering up the displayed data underneath the mask. Unfortunately, the polygons in the basemap database were not created with transparency in mind, and many of them overlap. Ov [...]
+<p> To avoid this, you can plot a transparent color value using a color mask.  How this operates "under the hood" is somewhat like double buffering.  When the masked color number is encountered,  a mask is set up, the same size of the screen image.  While that color number is being plotted, the plotting is done to the mask image instead. The mask image can be thought of as  simply zeros and ones -- 0 indicating that the color has not been drawn there,  1 that it has.  When the drawing ac [...]
+<p>There is a further complication with transparent color masking and basemap. The basemap script is basically a repetition of many 'draw polyf' commands, so the color masking doesn't work the way it should because the color mask is flushed at the conclusion of each 'draw' command instead of at the conclusion of the basemap script itself. The solution was to convert the polygon data into  <a href="shapefiles.html" target="pages">shapefiles</a>. All the polygons in a shapefile are rendere [...]
+  <br>
+  <a href="ftp://cola.gmu.edu/grads/scripts/grads_lowres_land.tar.gz">ftp://cola.gmu.edu/grads/scripts/grads_lowres_land.tar.gz</a><br>
+  <a href="ftp://cola.gmu.edu/grads/scripts/grads_lowres_ocean.tar.gz">ftp://cola.gmu.edu/grads/scripts/grads_lowres_ocean.tar.gz</a><br>
+  <a href="ftp://cola.gmu.edu/grads/scripts/grads_mres_land.tar.gz">ftp://cola.gmu.edu/grads/scripts/grads_mres_land.tar.gz</a><br>
+  <a href="ftp://cola.gmu.edu/grads/scripts/grads_mres_ocean.tar.gz">ftp://cola.gmu.edu/grads/scripts/grads_mres_ocean.tar.gz</a><br>
+  <a href="ftp://cola.gmu.edu/grads/scripts/grads_hires_land.tar.gz">ftp://cola.gmu.edu/grads/scripts/grads_hires_land.tar.gz</a><br>
+<a href="ftp://cola.gmu.edu/grads/scripts/grads_hires_ocean.tar.gz">ftp://cola.gmu.edu/grads/scripts/grads_hires_ocean.tar.gz</a></p>
+<p>The bottom line is that basemap script will not work with transparent colors -- you must use the custom shapefiles instead. It is important to note that the shapefiles that were created based on the basemap polygon data do not conform to the official ESRI Shapefile Technical Specification. They will display properly when used with GrADS, but do not use these custom shapefiles for any other purpose or with any other shapefile-handling tool. </p>
+
+<h3> <br>
+    Examples</h3>
+<ol>
+<li>These commands were used to generate the three panels in the image below, where the land areas are filled in with basemap.gs.<br>
+  <pre>
+  set lat 46.8 51.2
+  set lon -128.5 -121.75
+  set gxout grfill
+  set xlab off
+  set ylab off<br>
+  set vpage 0 3.6 4 8.5
+  set mpdset lowres
+  set poli on
+  d u10m
+  basemap O 15 1 L
+  draw title LOWRES<br>
+  set vpage 3.4 7.0 4 8.5
+  set mpdset mres
+  set poli off
+  d u10m
+  basemap O 15 1 M
+  draw title MRES<br>
+  set vpage 6.8 10.4 4 8.5
+  set mpdset hires
+  set poli off
+  d u10m
+  basemap O 15 1 H
+  draw title HIRES<br><br><img src="images/basemap_demo.png" alt="basemap_demo"></pre>
+</li>
+<li>This set of commands demonstrates how to overcome the lack of proper clipping for some domains and projections.
+  <pre>set mproj nps 
+set lon -180 180 
+set lat 0 90 
+set mpvals -180 180 60 90 
+display sst 
+basemap L </pre>
+</li>
+<li>To mask out the Mexican and 
+Canadian land regions surrounding the US, so that only the 
+conterminous states are seen, change 
+  your land polygon file from lpoly_lowres.asc to lpoly_US.asc: 
+  <a href="ftp://cola.gmu.edu/grads/scripts/lpoly_US.asc">ftp://cola.gmu.edu/grads/scripts/lpoly_US.asc</a><br>
+Then run basemap twice: <br>
+<pre>basemap o 0 0  (<- that's oh zero zero) ;* mask out ocean 
+basemap L 0 0                           ;* mask out non-US land</pre>
+This will only work properly if your domain is within the 
+boundaries 20N-50N, 130W-60W. Low-res maps only. Here is an example of how this can look:<br>
+<br>
+<img src="images/basemapUS.png" width="544" height="361" alt="basemapUS"><br>
+<br>
+</li>
+<li><a name="example4"></a>These commands were used to generate the three panels in the image below using transparent color masking and shapefiles instead of the basemap script in order to achieve a semi-transaprent land mask. For each panel, the data and the map outlines are  drawn first, then the shapefiles are overlaid using the same semi-transparent color for the fill and outline.<br>
+<pre>
+'set rgb 16 1 1 1 -80'<br>'set map 0 1 3'<br>'set line 16'
+'set shpopts 16'
+
+'set vpage 0 3.6 0 4'
+'set mpdset lowres'
+'d u10m'
+'draw shp grads_lowres_land'<br>'draw title LOWRES SHAPEFILE'
+ 
+'set vpage 3.4 7.0 0 4'
+'set mpdset mres'
+'set poli off'
+'d u10m'
+'draw shp grads_mres_land'<br>'draw title MRES SHAPEFILE'
+
+'set vpage 6.8 10.4 0 4'
+'set mpdset hires'
+'d u10m'
+'draw shp grads_hires_land'<br>'draw title HIRES SHAPEFILE'
+</pre>
+<img src="images/basemap_demo2.png" width="851" height="241" alt="basemap demo2">  <br>
+</li>
+</ol>
+</body>
+</html>
+
diff --git a/doc/colorcontrol.html b/doc/colorcontrol.html
index 4da4c76..07930a1 100644
--- a/doc/colorcontrol.html
+++ b/doc/colorcontrol.html
@@ -3,43 +3,60 @@
 <html>
 <head>
 <title>Controlling Colors in GrADS</title>
+<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
+<style type="text/css">
+body {
+	background-color: #e0f0ff;
+}
+.red {
+	color: #900;
+}
+</style>
 </head>
-<body bgcolor="e0f0ff" text="#000000">
+<body text="#000000">
 
 <h2><b>Controlling Colors in GrADS</b></h2>
-<p>
-<font size=+1><b><i>The GrADS Default Colors</i></b></font>
+<p><a href="#defaultcolors">The  Pre-Defined Default Colors in GrADS</a><br>
+  <a href="#defaultrainbow">The Default Rainbow Palette</a><br>
+  <a href="#define">Defining New Colors</a><br>
+  <a href="#transparent">Transparent Colors</a><br>
+  <a href="#override">Overriding the Default Palette</a><br>
+  <a href="#constantcolor">Plotting Contours of Constant Color</a><br>
+<a href="#omit">Omitting Colors</a><br>
+<a href="#fgvals">Plotting Non-Continuous Index Grids</a><br>
+<br>
+  <br>
+</p>
+<hr>
+<p><a name="defaultcolors"></a><font size=+1><b><i>The Pre-Defined Default Colors in GrADS</i></b></font></p>
 <p>
 GrADS is built with 16 default colors that are used in a variety of
 applications. Every color in GrADS has a unique <i>color number</i> that is used
 as an index to identify it in GrADS commands. Complete specifications
 of the default colors numbered 0 to 15 are given below:
-
-<p>
 <pre>
-Col#  Description   Sample    R   G   B 
-<br>
-  0   background    <img src="images/dot_b.gif"  width=50 height=12>   0   0   0  (black by default)<br>
-  1   foreground    <img src="images/dot_w.gif"  width=50 height=12> 255 255 255  (white by default)<br>
-  2   red           <img src="images/dot_2.gif"  width=50 height=12> 250  60  60  <br>
-  3   green         <img src="images/dot_3.gif"  width=50 height=12>   0 220   0  <br>
-  4   dark blue     <img src="images/dot_4.gif"  width=50 height=12>  30  60 255  <br>
-  5   light blue    <img src="images/dot_5.gif"  width=50 height=12>   0 200 200  <br>
-  6   magenta       <img src="images/dot_6.gif"  width=50 height=12> 240   0 130  <br>
-  7   yellow        <img src="images/dot_7.gif"  width=50 height=12> 230 220  50  <br>
-  8   orange        <img src="images/dot_8.gif"  width=50 height=12> 240 130  40  <br>
-  9   purple        <img src="images/dot_9.gif"  width=50 height=12> 160   0 200  <br>
- 10   yellow/green  <img src="images/dot_10.gif" width=50 height=12> 160 230  50  <br>
- 11   medium blue   <img src="images/dot_11.gif" width=50 height=12>   0 160 255  <br>
- 12   dark yellow   <img src="images/dot_12.gif" width=50 height=12> 230 175  45  <br>
- 13   aqua          <img src="images/dot_13.gif" width=50 height=12>   0 210 140  <br>
- 14   dark purple   <img src="images/dot_14.gif" width=50 height=12> 130   0 220  <br>
- 15   gray          <img src="images/dot_15.gif" width=50 height=12> 170 170 170  <br>
-</pre>
+Col#  Description   Sample    R    G    B <br>
+  0   background    <img src="images/dot_b.gif"  width=50 height=12>    0    0    0  (black by default)
+  1   foreground    <img src="images/dot_w.gif"  width=50 height=12>  255  255  255  (white by default)
+  2   red           <img src="images/dot_2.gif"  width=50 height=12>  250   60   60  
+  3   green         <img src="images/dot_3.gif"  width=50 height=12>    0  220    0  
+  4   dark blue     <img src="images/dot_4.gif"  width=50 height=12>   30   60  255  
+  5   light blue    <img src="images/dot_5.gif"  width=50 height=12>    0  200  200  
+  6   magenta       <img src="images/dot_6.gif"  width=50 height=12>  240    0  130  
+  7   yellow        <img src="images/dot_7.gif"  width=50 height=12>  230  220   50  
+  8   orange        <img src="images/dot_8.gif"  width=50 height=12>  240  130   40  
+  9   purple        <img src="images/dot_9.gif"  width=50 height=12>  160    0  200  
+ 10   yellow/green  <img src="images/dot_10.gif" width=50 height=12>  160  230   50  
+ 11   medium blue   <img src="images/dot_11.gif" width=50 height=12>    0  160  255  
+ 12   dark yellow   <img src="images/dot_12.gif" width=50 height=12>  230  175   45  
+ 13   aqua          <img src="images/dot_13.gif" width=50 height=12>    0  210  140  
+ 14   dark purple   <img src="images/dot_14.gif" width=50 height=12>  130    0  220  
+ 15   gray          <img src="images/dot_15.gif" width=50 height=12>  170  170  170  <br>
 <font size=-1>Disclaimer: The color samples may not be displayed properly.</font>
 
+</pre>
 <p>
-<font size=+1><b><i>The GrADS Default Rainbow Sequence</i></b></font>
+  <font size=+1><b><i><a name="defaultrainbow"></a>The  Default Rainbow Palette</i></b></font>
 <p>
 GrADS creates a default rainbow palette using the following sequence of 13 built-in colors: 
 <table>
@@ -90,55 +107,60 @@ shades</code></a> command to get information about the contour levels
 and their color shades.
 
 <p>
-<font size=+1><b><i>Defining new colors</i></b></font>
+<p>
+<font size=+1><b><i><a name="define"></a>Defining new colors</i></b></font>
 
 <p>
-For some types of displays, the 16 GrADS default colors may not be
+For some graphics, the 16 GrADS default colors may not be
 suitable or adequate. It is possible for the user to define new colors
 using the <a href="gradcomdsetrgb.html"><code>set rgb</code></a> command:
 
-<p>
 <ul>
 <code><a href="gradcomdsetrgb.html">set rgb</a> <i>color# R G B</i></code>
 </ul>
+<p>For example, to create a palette of colors for
+  plotting anomalies, you can define new colors that will be shades
+  of blue and red that range in intensity from fully saturated to very
+  light. White will be the color in the center of the new anomaly
+  palette.
 
-<p>
-For example, let's create a palette of colors for
-plotting anomalies. We need to define new colors that will be shades
-of blue and red that range in intensity from fully saturated to very
-light. White will be the color in the center of the new anomaly
-palette.
-
-<p>
 <ul>
 <pre>
 * These are the BLUE shades
-<a href="gradcomdsetrgb.html">set rgb</a> 16   0   0 255
-<a href="gradcomdsetrgb.html">set rgb</a> 17  55  55 255
-<a href="gradcomdsetrgb.html">set rgb</a> 18 110 110 255
-<a href="gradcomdsetrgb.html">set rgb</a> 19 165 165 255
-<a href="gradcomdsetrgb.html">set rgb</a> 20 220 220 255
+<a href="gradcomdsetrgb.html">set rgb</a>  16    0    0  255
+<a href="gradcomdsetrgb.html">set rgb</a>  17   55   55  255
+<a href="gradcomdsetrgb.html">set rgb</a>  18  110  110  255
+<a href="gradcomdsetrgb.html">set rgb</a>  19  165  165  255
+<a href="gradcomdsetrgb.html">set rgb</a>  20  220  220  255
 * These are the RED shades
-<a href="gradcomdsetrgb.html">set rgb</a> 21 255 220 220
-<a href="gradcomdsetrgb.html">set rgb</a> 22 255 165 165
-<a href="gradcomdsetrgb.html">set rgb</a> 23 255 110 110
-<a href="gradcomdsetrgb.html">set rgb</a> 24 255  55  55
-<a href="gradcomdsetrgb.html">set rgb</a> 25 255   0   0
-</pre>
+<a href="gradcomdsetrgb.html">set rgb</a>  21  255  220  220
+<a href="gradcomdsetrgb.html">set rgb</a>  22  255  165  165
+<a href="gradcomdsetrgb.html">set rgb</a>  23  255  110  110
+<a href="gradcomdsetrgb.html">set rgb</a>  24  255   55   55
+<a href="gradcomdsetrgb.html">set rgb</a>  25  255    0    0
+</pre> 
 </ul>
 
 
 
 <p>
-<font size=+1><b><i>Overriding the Defaults</i></b></font>
-
+<font size=+1><b><i><a name="transparent" id="transparent"></a>Transparent Colors</i></b></font>
+<p>Starting with <span class="red">GrADS version 2.1</span>, there is an addional <em>optional</em> argument that may be used to set a transparency level for a user-defined color. 
+<ul>
+<code><a href="gradcomdsetrgb.html">set rgb</a> <i>color# R G B <A></i></code>
+</ul>
+<p><strong>Color Masking for Transparent Colors</strong></p>
+<p> A filled region on a plot is achieved by shaded contouring, filling land/ocean areas using <a href="basemap.html">basemap.gs</a>, or drawing a <a href="shapefiles.html">shapefile</a> with filled polygons. The filled areas usually consist of a large number of  polygons  that appear as one solid region.  When filling such an area on the plot using a semi-transparent color,  spurious lines may appear at the polygon boundaries or in areas where  the polygons overlap.  This is due to the  [...]
+<p> To avoid this, you can plot a semi-transparent color value using a color mask.  How this operates "under the hood" is somewhat like double buffering.  When the masked color number is encountered,  a mask is set up, the same size of the screen image.  While that color number is being plotted, the plotting is done to the mask image instead.  The mask image can be thought of as  simply zeros and ones -- 0 indicating that the color has not been drawn there,  1 that it has.  When this act [...]
+<p> There are some drawbacks to using masked colors.  The masked region is an image operation, so the boundaries may appear  jagged -- pixelated --  if the plot is rendered at sufficiently low resolution. There may also be a performance penalty for using masked colors.  It is a good idea to avoid using masked colors unless absolutely necessary. It is not  necessary to use masked colors for "set gxout shade2" because the new shaded contouring algorithm is very well behaved. In version 2.1 [...]
+<p>To set a color to be masked, simply specify its alpha channel value as negative.  The positive of that value will be used to draw the actual  color, when rendered via the mask. For examples, please look <a href="basemap.html#example4">here</a> and <a href="shapefiles.html#example4">here</a>.</p>
+<p> </p>
+<p><font size=+1><b><i><a name="override"></a>Overriding the Default Palette</i></b></font>
 <p>
 Now that we have a set of newly defined colors (numbered 16-25), we
 can override the defaults and specify our anomaly palette with exact
 contour levels and the colors that go with them. This is accomplished
 by using the following commands:
-
-<p>
 <ul>
 <code>
 <a href="gradcomdsetclevs.html">set clevs</a> <i>lev1 lev2 lev3 ... levN</i><br>
@@ -164,8 +186,6 @@ number of contour levels specified with <a
 href="gradcomdsetclevs.html">set clevs</a>. Continuing with our
 example of creating an anomaly palette, the commands would have the
 following syntax:
-
-<p>
 <ul>
 <code>
 <a href="gradcomdsetgxout.html">set gxout</a> shaded<br>
@@ -184,7 +204,6 @@ result in the following color key:
 <p>
 Here is example using 6 colors and 5 contour levels that shows how the
 filled contours (or shaded grids) relate to the data values:
-<p>
 <ul>
 <pre>
 col1:         values <= lev1
@@ -205,7 +224,8 @@ href="gradcomdsetccols.html">set ccols</a> should be equal -- one
 color for each contour.
 
 <p>
-<font size=+1><b><i>Plotting Contours of Constant Color</i></b></font>
+<p>
+<font size=+1><b><i><a name="constantcolor"></a>Plotting Contours of Constant Color</i></b></font>
 
 <p>
 It is sometimes preferable to plot line contours without the rainbow
@@ -213,28 +233,24 @@ coloring. An example might be a plot with sea level pressure contours
 in one color (red) and 500 mb height contours overlaid in another
 color (blue).  For drawing all the contours in the same color, use the
 <a href="gradcomdsetccolor.html"><code>set ccolor</code></a> command:
-
-<p>
 <ul>
-<code>
-<a href="gradcomdsetgxout.html">set gxout</a> contour <br>
-<a href="gradcomdsetccolor.html">set ccolor</a> 2 <br>
-<a href="gradcomddisplay.html">d</a> slp <br>
-<a href="gradcomdsetccolor.html">set ccolor</a> 4 <br>
-<a href="gradcomddisplay.html">d</a> z(lev=500) <br>
-</code>
-</ul>
+  <p><code>
+  <a href="gradcomdsetgxout.html">set gxout</a> contour <br>
+  <a href="gradcomdsetccolor.html">set ccolor</a> 2 <br>
+  <a href="gradcomddisplay.html">d</a> slp <br>
+  <a href="gradcomdsetccolor.html">set ccolor</a> 4 <br>
+  <a href="gradcomddisplay.html">d</a> z(lev=500)</code></p>
 
+</ul>
 <p>
-<font size=+1><b><i>Omitting Colors</i></b></font>
+<p>
+<font size=+1><b><i><a name="omit"></a>Omitting Colors</i></b></font>
 
 <p>
 The default behavior of GrADS when plotting filled contours or shaded
 grid cells is to colorize all areas. To omit a particular color (or
 contour level) from the plot, simply assign the background color. For
 example:
-
-<p>
 <ul>
 <code>
 <a href="gradcomdsetgxout.html">set gxout</a> shaded<br>
@@ -248,19 +264,19 @@ This example is similar to the one given above, but notice where some
 of the <code>ccols</code> have been set to "0" (the background
 color). The first, last, and middle colors have been omitted. These
 commands set up a plot that will only shade areas where the anomalies
-are between 1 and 5 and -1 and -5. The remaining areas will be black.
+are between 1 and 5 and -1 and -5. The remaining areas will be black (or white, depending on what the background color is set to be.)
 
 
+<p>When using <span class="red">version 2.0.0+</span> and  'gxout shade2'  or 'gxout shade2b', if any of the color numbers is < 0, the contour  is not drawn at all (i.e., it is effectively transparent). In <span class="red">version 2.1+</span>, the 'set gxout' option 'shaded' is an alias for 'shade2'. 
+<p>
 <p>
-<font size=+1><b><i>Plotting Non-Continuous Index Grids </i></b></font>
+<font size=+1><b><i><a name="fgvals"></a>Plotting Non-Continuous Index Grids </i></b></font>
 
 <p>
 Plotting grids with index values or non-continuous data (e.g. surface
 type classification) is simplified by using the graphics output type
 <code>fgrid</code> and the <a href="gradcomdsetfgvals.html"><code>set
 fgvals</code></a> command.
-
-<p>
 <ul>
 <code>
 <a href="gradcomdsetgxout.html">set gxout</a> fgrid <br>
diff --git a/doc/descriptorfile.html b/doc/descriptorfile.html
index 740c28f..3212ce2 100644
--- a/doc/descriptorfile.html
+++ b/doc/descriptorfile.html
@@ -126,7 +126,7 @@ body {
     <td colspan="2">The DTYPE entry specifies the type of data being described. 
       There are four options: grib, hdfsds, netcdf, or station. If the data type 
       is none of these, then the DTYPE entry is omitted completely from the descriptor 
-      file and GrADS will assume the data type is gridded binary. <br> <table width="100%" border="0" cellpadding="4" cellspacing="4" class="plaintext">
+      file and GrADS will assume the data type is<a href="aboutgriddeddata.html"> gridded binary</a>. <br> <table width="100%" border="0" cellpadding="4" cellspacing="4" class="plaintext">
         <tr> 
           <td valign="top" bgcolor="b8c8d7">bufr</td>
           <td bgcolor="b8c8d7" class="plaintext">(<font color="#990000">GrADS 
@@ -1266,12 +1266,12 @@ href="aboutgriddeddata.html#structure">structure of a gridded binary data file</
           <td valign="top" bgcolor="#b8c8d7"><i>additional_codes<br>
 (DTYPE grib2)<br>
 (optional) </i></td>
-          <td bgcolor="#b8c8d7">(<font color="#990000">GrADS version 2.0.2+</font>) This field specifies any additional GRIB2 codes that are required to uniquely identify the record when the elements in the <span class="italic">levs</span> and <span class="italic">units</span> fields are not sufficient. It is only required for certain Product Definition Templates: the Probability Forecasts (PDT 5 and 9) and the Optical Properties of Aerosol (PDT 48). The <i>additional_codes</i> field alw [...]
+          <td bgcolor="#b8c8d7">(<font color="#990000">GrADS version 2.0.2+</font>) This field specifies any additional GRIB2 codes that are required to uniquely identify the record when the elements in the <span class="italic">levs</span> and <span class="italic">units</span> fields are not sufficient. It is only required for certain Product Definition Templates: the Probability Forecasts (PDT 5 and 9),  Percentiles (PDT 6 and 10), and the Optical Properties of Aerosol (PDT 48). The <i> [...]
         </tr>
         <tr bgcolor="ccdceb">
           <td valign="top" bgcolor="#ccdceb"><i> additional_codes<br>
             (PDT 5 or 9) </i></td>
-          <td bgcolor="#ccdceb"><p>For the Probability Forecasts (PDT 5 or  9), the <i>additional_codes</i> field has 2 or 3 comma-delimted numbers, preceded by the letter "a" :</p>
+          <td bgcolor="#ccdceb"><p>For the Probability forecasts (PDT 5 or  9), the <i>additional_codes</i> field has 2 or 3 comma-delimted numbers, preceded by the letter "a" :</p>
             <ul>
               aPTYPE,LIMIT,LIMIT2
             </ul>
@@ -1336,7 +1336,42 @@ href="aboutgriddeddata.html#structure">structure of a gridded binary data file</
                 </tr>
               </table>
           
-            <p>The external utilities <a href="util/grib2scan">grib2scan</a> (with the -c option) and <a href="http://www.cpc.ncep.noaa.gov/products/wesley/wgrib2/index.html">wgrib2</a> are quite useful in determining what the values for the <i>additional_codes</i><em> </em>field should be for a GRIB2 data file.</p></td>
+            <p>The external utilities <a href="util/grib2scan">grib2scan</a> (with the -v option) and <a href="http://www.cpc.ncep.noaa.gov/products/wesley/wgrib2/index.html">wgrib2</a> are quite useful in determining what the values for the <i>additional_codes</i><em> </em>field should be for a GRIB2 data file.</p></td>
+        </tr>
+        <tr bgcolor="ccdceb">
+          <td valign="top" bgcolor="#ccdceb"><i> additional_codes<br>
+            (PDT 6 or 10) </i></td>
+          <td bgcolor="#ccdceb"><p>(<span class="red">Version 2.1.a3+</span>) For the Percentile forecasts (PDT 6 or  10), the <i>additional_codes</i> field has only one number preceded by the letter "a" :</p>
+            <ul>
+              aPCT
+            LE
+            </ul>
+            where
+            <table width="100%" border="0" cellpadding="0" cellspacing="0" class="plaintext">
+              <tr>
+                <td width="9%" valign="top">PCTLE</td>
+                <td width="2%" align="center" valign="top">=</td>
+                <td width="89%">The percentile value</td>
+              </tr>
+            </table>
+            <p>Examples:</p>
+            <table width="100%" border="0" cellpadding="0" cellspacing="0" class="plaintext">
+              <tr>
+                <td width="11%">t75</td>
+                <td width="10%" align="center">0,103,2</td>
+                <td width="11%" align="center">a75</td>
+                <td width="11%" align="center">0,0,0</td>
+                <td width="57%">75th percentile of of 2-m Temperatures</td>
+              </tr>
+              <tr>
+                <td>t90</td>
+                <td align="center">0,103,2</td>
+                <td align="center">a90</td>
+                <td align="center">0,0,0</td>
+                <td>90th percentile of of 2-m Temperatures</td>
+              </tr>
+            </table>
+            <p>The external utilities <a href="util/grib2scan">grib2scan</a> (with the -v option) and <a href="http://www.cpc.ncep.noaa.gov/products/wesley/wgrib2/index.html">wgrib2</a> are quite useful in determining what the values for the <i>additional_codes</i><em> </em>field should be for a GRIB2 data file.</p></td>
         </tr>
         <tr bgcolor="ccdceb">
           <td valign="top" bgcolor="#ccdceb"><i> additional_codes<br>
@@ -1414,7 +1449,7 @@ where
         and <= 5.65e-7<br>
         *desc2=Atmosphere Emission Mass Flux
         for Dry Dust, 
-        size is < 2e-5        <p>The external utilities <a href="util/grib2scan">grib2scan</a> (with the -c option) and <a href="http://www.cpc.ncep.noaa.gov/products/wesley/wgrib2/index.html">wgrib2</a> are quite useful in determining what the values for the <i>additional_codes</i><em> </em>field should be for a GRIB2 data file. </p></td>
+        size is < 2e-5        <p>The external utilities <a href="util/grib2scan">grib2scan</a> (with the -v option) and <a href="http://www.cpc.ncep.noaa.gov/products/wesley/wgrib2/index.html">wgrib2</a> are quite useful in determining what the values for the <i>additional_codes</i><em> </em>field should be for a GRIB2 data file. </p></td>
         </tr>
         <tr> 
           <td colspan="2" valign="top">The <i>units</i> component of the variable 
diff --git a/doc/drawingtips.html b/doc/drawingtips.html
new file mode 100644
index 0000000..7c33f44
--- /dev/null
+++ b/doc/drawingtips.html
@@ -0,0 +1,46 @@
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
+
+<html>
+<head>
+<title>Controlling Colors in GrADS</title>
+<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
+<style type="text/css">
+body {
+	background-color: #e0f0ff;
+}
+.red {
+	color: #900;
+}
+.red1 {color: #900;
+}
+</style>
+</head>
+<body text="#000000">
+
+<h2><b>Drawing Tips</b></h2>
+<p>This page contains   some suggestions for making your graphics looks as good as possible when using GrADS version 2.1+ with Cairo enabled. 
+<ol>
+  <li><strong>Draw axis labels, grid lines, and the map outline only once per plot</strong><br>
+    <br>
+  When drawing  graphical elements such as lines or letters on a plot, Cairo's anti-aliasing algorithm blends the color of the object into the existing background  to smooth the color transition and make the graphics look  less pixelated and more beautiful. If you redraw the same object a second time,  the existing background  is uneven and the anti-aliasing doesn't work as well and the objects can end up looking blotchy or ragged. Below is an example of the same string ("AaBbCc&quo [...]
+  <img src="images/letters.png" width="376" height="31" alt="letters">  <br>
+  To avoid this problem when drawing overlays in a single plot, disable the labeling after the first display. For example:<br>
+  <pre>
+  <a href="gradcomddisplay.html">d</a> hgt
+  <a href="gradcomdsetxlab.html">set xlab</a> off
+  <a href="gradcomdsetylab.html">set ylab</a> off
+  <a href="gradcomdsetgrid.html">set grid</a> off
+  <a href="gradcomdsetmpdraw.html">set mpdraw</a> off
+  <a href="gradcomddisplay.html">d</a><a href="gradfuncmag.html"></a> temp
+</pre>
+  </li>
+  <li><strong>Line thickness settings matter </strong><br>
+    <br>
+    In earlier versions of GrADS, line
+  thickness setting between 1 and 5 always looked the same in the display and in image output -- only the vector graphics  formats would show any differences. With Cairo, each line thickness setting will  change the  rendered line thickness, not only for the vector graphics output, but also for  the X window display and  any image output. The anti-aliasing also allows for smooth, thin lines in the image output. However, thin lines that are less than one pixel wide may appear somewhat dim [...]
+    <p>The default line widths for thickness settings between 1 and 12 are:<code> 0.6, 0.8, 1.0, 1.25, 1.5, 1.75, 2.0, 2.2, 2.4, 2.6, 2.8, 3.0. </code>The units (pixels or points) will depend on the surface being drawn to -- pixels for the display window and image output, points for vector graphics. Use the new command <code><a href="gradcomdsetlwid.html">set lwid</a></code> to define a new line thickness setting if the 12 default widths are unsatisfactory. </p>
+  </li>
+</ol>
+</body>
+</html>
+
diff --git a/doc/font.html b/doc/font.html
index 3b26c68..f5560a6 100644
--- a/doc/font.html
+++ b/doc/font.html
@@ -1 +1,81 @@
-<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.--><style type="text/css">
<!--
body {
	background-color: #e0f0ff;
}
-->
</style>

<h1>Font File </h1>

GrADS  supports Hershey fonts numbered 0 to 9.  Fonts 0 to 5 are
provided with the GrADS distribution.  The files are named
<code>font0.dat</code>, <code>font1.dat</code>, etc.  If you create
a <code>font6.dat</code> file (or 7 through
9) and put it in the same place as the other font
files, you can use that font immediately, by using the <code><a
href="gradcomdsetfont.html">set font</a></code> command,  or via <a href="fontcontrol.html">font escape sequences</a>.
<p>

The font files are in an ASCII format.  Each file is 95
records in length.  Each record represents a character in the font,
and the records are ordered in the order of ASCII code values,
starting with the blank (code value 32 decimal).  So the last
record represents the tilde, the 17th record the zero, etc.  So when
you are using the font the file represents, and enter a zero
character, the character  in the 17th record is plotted, whatever it
may be.<p>

Each record starts with a 3 character number.  This is
the number of code pairs in the record.  This number is followed by
the indicated number of code pairs.  Each code pair is two
characters. Each character represents a value, which is determined
as an offset from the Capital R (decimal 82).  So, if the character
is Capital L, it represents a value of -6.  If the character is a
lower case k, it represents a value of +25.  <p>

The first code pair represents the horizontal extent of
the character. So the first character of the code pair would be the
minimum X, and the 2nd character the maximum X.  If I remember correctly,
this extent should include white space.  This is followed by code
pairs that represent drawing positions in X and Y, where the first
character is X, and the 2nd Y.  A "pen up" is indicated by the code pair " R" (blank,
followed by capital R).  <p>

You can look at the existing font files for examples.
If you look at 
<code>font0.dat</code>, the first record represents the blank.  It
thus has one code
pair, which just represents the width of the blank in
the font, thus
allocating white space when a blank is encountered.  If
you look at 
record <code>57</code> (which represents Cap X), you see:
<code>6H\KFY[ RYFK[</code>
Decoding this, you see there are 6 code pairs.  The
first is the 
width extent, <code>H\</code>, which is -10 to 10.  The next two
pairs, <code>KFY[</code>, 
are points -7,-12 and 7,9.  So a line would be drawn
between those
two points (appropriate scaled).  The next code pair
indicates pen up, 
followed by <code>YFK[</code>, which are 7,-12 and -7,9.  <p>

You can see the horizontal extent does not match too
well with the 
actual character.  I am not quite sure why this is, nor
why the 
character is not centered.  This is the way the fonts
came, so I assume
there are some font design issues involved.  
<p>

If you want to design your own font, you will need to
review the 
code GrADS uses to actually plot these fonts, which is
<code>gxchpl.c</code>.
I determined scale factors and centering issues by trial
and error, and
these values are contained in the code.<p>

\ No newline at end of file
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.--><style type="text/css">
+<!--
+body {
+	background-color: #e0f0ff;
+}
+-->
+</style>
+
+<h1>Hershey Font Files</h1>
+
+GrADS  supports Hershey fonts numbered 0 to 9.  Fonts 0 to 5 are
+provided with the GrADS distribution.  The files are named
+<code>font0.dat</code>, <code>font1.dat</code>, etc.  If you create
+a <code>font6.dat</code> file (or 7 through
+9) and put it in the same place as the other font
+files, you can use that font immediately, by using the <code><a
+href="gradcomdsetfont.html">set font</a></code> command,  or via <a href="fontcontrol.html">font escape sequences</a>.
+<p>
+
+The font files are in an ASCII format.  Each file is 95
+records in length.  Each record represents a character in the font,
+and the records are ordered in the order of ASCII code values,
+starting with the blank (code value 32 decimal).  So the last
+record represents the tilde, the 17th record the zero, etc.  So when
+you are using the font the file represents, and enter a zero
+character, the character  in the 17th record is plotted, whatever it
+may be.<p>
+
+Each record starts with a 3 character number.  This is
+the number of code pairs in the record.  This number is followed by
+the indicated number of code pairs.  Each code pair is two
+characters. Each character represents a value, which is determined
+as an offset from the Capital R (decimal 82).  So, if the character
+is Capital L, it represents a value of -6.  If the character is a
+lower case k, it represents a value of +25.  <p>
+
+The first code pair represents the horizontal extent of
+the character. So the first character of the code pair would be the
+minimum X, and the 2nd character the maximum X.  If I remember correctly,
+this extent should include white space.  This is followed by code
+pairs that represent drawing positions in X and Y, where the first
+character is X, and the 2nd Y.  A "pen up" is indicated by the code pair " R" (blank,
+followed by capital R).  <p>
+
+You can look at the existing font files for examples.
+If you look at 
+<code>font0.dat</code>, the first record represents the blank.  It
+thus has one code
+pair, which just represents the width of the blank in
+the font, thus
+allocating white space when a blank is encountered.  If
+you look at 
+record <code>57</code> (which represents Cap X), you see:
+<code>6H\KFY[ RYFK[</code>
+Decoding this, you see there are 6 code pairs.  The
+first is the 
+width extent, <code>H\</code>, which is -10 to 10.  The next two
+pairs, <code>KFY[</code>, 
+are points -7,-12 and 7,9.  So a line would be drawn
+between those
+two points (appropriate scaled).  The next code pair
+indicates pen up, 
+followed by <code>YFK[</code>, which are 7,-12 and -7,9.  <p>
+
+You can see the horizontal extent does not match too
+well with the 
+actual character.  I am not quite sure why this is, nor
+why the 
+character is not centered.  This is the way the fonts
+came, so I assume
+there are some font design issues involved.  
+<p>
+
+If you want to design your own font, you will need to
+review the 
+code GrADS uses to actually plot these fonts, which is
+<code>gxchpl.c</code>.
+I determined scale factors and centering issues by trial
+and error, and
+these values are contained in the code.<p>
+
diff --git a/doc/fontcontrol.html b/doc/fontcontrol.html
index 0d2894f..7d0d851 100644
--- a/doc/fontcontrol.html
+++ b/doc/fontcontrol.html
@@ -1 +1,75 @@
-<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.--><title>Font Control</title>

<style type="text/css">
<!--
body {
	background-color: #e0f0ff;
}
.style1 {color: #990000}
-->
</style>
<H2><B> Font Control</B> in GrADS</H2>
<p><a href="#hershey">Hershey Fonts</a><br />
  <a href="#cairo">Cairo Fonts</a><br />
<a href="#size">Controlling Font Size</a><br />
<a href="#overrides">Temporary Overrides</a><br />
  <a href="#examples">Examples</a></H2>
<H3><a name="hershey" id="hershey"></a>Hershey Fonts</H3>
<P>GrADS has traditionally used the Hershey vector fonts for all text displays. The Hershey  fonts are drawn as a collection of line segments, and can be rotated or scaled (stretched) in the X or Y direction; this makes them extremely flexible for different applications in GrADS. The Hershey fonts are defined in a set of <a href="font.html">font files</a>, which are part of the GrADS distribution and should be stored in a directory named by the <a href="http://iges.org/grads/gadoc/gradcom [...]
<pre>
font 0 -- Simplex Roman 
font 1 -- Complex Roman
font 2 -- Complex Italic
font 3 -- Complex Greek
font 4 -- Duplex Roman
font 5 -- Triplex Roman
</pre>
<H3><a name="cairo" id="cairo"></a>Cairo Fonts</H3>
<P>Beginning with <span class="style1">GrADS version 2.1.a0</span>, additional fonts are available with the Cairo graphics library. GrADS employs Cairo's "toy" font API; it is simpler to implement, fast, and  meets GrADS's needs for drawing text. Cairo uses the freetype2 font library, which supports a number of scalable font formats including TrueType, Type 1, OpenType, X11 PCF, and Windows FNT. Whether GrADS will support all these font types depends on if they are available on  [...]

If your build of GrADS is not enabled with the Cairo graphics library, you will get an error message if you use  <code><a href="gradcomdsetfont.html">set font</a></code> to try to set a font number greater than 9.
<h3><a name="size" id="size"></a>Controlling Font Size</h3> 
<p>The <code><a href="gradcomdsetstrsiz.html">set strsiz</a></code> command controls the font size for Hershey and Cairo fonts. Because the Hershey fonts are vector-based, you can give different scaling factors for the width and height of the letters and the font will stretch accordingly. For Cairo fonts, only one scaling factor (the vertical size) is appropriate -- the fonts do not deform in the X or Y dimension, they simply get bigger or smaller. If the vertical size is not given with < [...]
<h3><a name="overrides" id="overrides"></a>Temporary Overrides</h3>
<P>Hershey fonts correspond to single-digit font numbers; Cairo fonts correspond to double-digit font numbers. When you invoke the <code><a href="gradcomdsetfont.html">set font</a></code> command and the font number is between 0 and 9, you are in <em>hershey mode</em>. If the font number is between 10 and 99, you are in <em>cairo mode</em>. 
Hershey and Cairo fonts cannot be mixed together in the same string. 
<P><em><strong>Font Override: </strong></em><br />
  To temporarily override the  font  in a string of text, use the back quote character (`). When you are in <em>hershey mode</em>, a back quote followed by a single digit selects that font number for the remainder of the string. When you are in <em>cairo mode</em>, a back quote followed by 'f' and a double-digit number selects that font number for the remainder of the string. See examples below.
<P><em><strong>Text Position Override:</strong></em><br />
  It is also possible to use the back quote to change the position of the text, to draw a string above or below the base line for subscripts or superscripts. A back quote followed by the letter a (`a) will draw the subsequent text in the string as a superscript (above normal). A back quote followed by the letter b (`b) will draw the subsequent text in the string as a subscript (below normal). A back quote followed by the letter n (`n) will draw the subsequent text in the string in a norma [...]
<P><em><strong>Degree Symbol:</strong></em><br />
If you are in <em>hershey mode</em>, you can draw a degree symbol by drawing a period with font number 3 (`3.) If you are in <em>cairo mode</em>, you can draw a degree symbol with a backquote followed by the letter d (`d). See examples below. 
<H3><a name="examples" id="examples"></a>Examples</H3>
<pre>Hershey Mode:
set font 0
draw string 1.5 1.25 `1use font 2 to `2emphasize `1a particular word
draw string 1.5 2.25 use font 3 for `3greek `0letters
draw string 1.5 3.25 `3p`0r`a2`n = area of a circle
draw string 1.5 4.25 label temperatures in `3.`0C or `3.`0F


Cairo Mode:
set font 10
draw string 1.5 1.25 use font 11 for `f11serif`f10 and font 12 for `f12monospace
set fontdef 13 symbol
draw string 1.5 2.25 use symbol font for `f13greek`f10 letters

draw string 1.5 4.25 label temperatures in `dC or `dF</pre>
\ No newline at end of file
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.--><title>Font Control</title>
+
+<style type="text/css">
+<!--
+body {
+	background-color: #e0f0ff;
+}
+.style1 {color: #990000}
+.red {
+	color: #900;
+}
+-->
+</style>
+<H2><B> Font Control</B> in GrADS</H2>
+<p><a href="#hershey">Hershey Fonts</a><br />
+<a href="#cairo">Cairo Fonts</a><br />
+<a href="#emulation">Cairo Emulation of Hershey Fonts</a><br />
+  <a href="#size">Controlling Font Size</a><br />
+  <a href="#thick">Controlling Font Thickness</a><br />
+  <a href="#overrides">Temporary Overrides</a><br />
+  <a href="#examples">Examples</a>
+  </H2>
+<H3><a name="hershey" id="hershey"></a>Hershey Fonts</H3>
+<P>GrADS has traditionally used the Hershey vector fonts for all text displays. The Hershey  fonts are drawn as a collection of line segments, and can be rotated or scaled (stretched) in the X or Y direction; this makes them extremely flexible for different applications in GrADS. The Hershey fonts are defined in a set of <a href="font.html">font files</a>, which are part of the GrADS distribution and should be stored in a directory named by the <a href="http://iges.org/grads/gadoc/gradco [...]
+<pre>
+font 0 -- Simplex Roman 
+font 1 -- Complex Roman
+font 2 -- Complex Italic
+font 3 -- Complex Greek
+font 4 -- Duplex Roman
+font 5 -- Triplex Roman
+</pre>
+<p>GrADS <span class="red">version 2.1</span> with the Cairo library enabled  uses <a href="http://en.wikipedia.org/wiki/Spatial_anti-aliasing" target="_blank">anti-aliasing </a>to render the graphics when drawing to the X display window and for image output, which will make the Hershey fonts look smoother than they do with version 2.0. </p>
+<H3><a name="cairo" id="cairo"></a>Cairo Fonts</H3>
+<P>Beginning with GrADS <span class="style1">version 2.1</span>, additional fonts may be used through the Cairo graphics library.  The  integration of Cairo into GrADS provides access to fonts that are generated from polygons, and thus can look much nicer than Hershey fonts.  However,  these fonts do not behave like the raster screen fonts that are used in the browser or a terminal session, etc.  They are still graphically rendered fonts,  and how the graphics rendering aligns with the p [...]
+<P>Cairo employs the FreeType font library, which supports a number of scalable font formats including TrueType, Type 1, OpenType, X11 PCF, and Windows FNT. Please see <a href="http://www.freetype.org/freetype2/index.html#features">http://www.freetype.org/freetype2/index.html#features</a> for a complete list of font formats that FreeType supports. The fonts that GrADS supports will depend on whether the font files are available on your particular system. On macintosh OSX systems, availab [...]
+<P>Hershey fonts correspond to single-digit font numbers; Cairo fonts correspond to double-digit font numbers. Font numbers 10-99 are reserved for user-defined fonts, which are specified with the <a href="gradcomdsetfont.html"><code>set font</code></a> command. The user must provide the name of a local font file, including its full path. If the user-specified font file cannot be opened, then the display defaults to a generic sans-serif font.
+  
+  If your build of GrADS is not enabled with the Cairo graphics library, you will get an error message if you use  <code><a href="gradcomdsetfont.html">set font</a></code> to try to set a font number greater than 9.
+<P>When using Cairo fonts, you may see this error message pop up: <strong>Fontconfig error: Cannot load default config file</strong>. This is a file that helps Cairo find fonts, but is only useful on the system where the library was originally built. The default config file is not required, and this message is harmless. The non-portability of font file locations is why it is necessary to specify the full path for a font file when using the <a href="gradcomdsetfont.html"><code>set font</c [...]
+
+<h3><a name="emulation" id="emulation"></a>Cairo Emulation of Hershey Fonts</h3>
+<P>If you would like to use Cairo fonts but do not know anything about  font files on your system or do not want to bother editing the font controls your existing scripts, there is a quick shortcut command for you:<code> '<a href="gradcomdsethershey.html">set hershey</a> off'</code>.
+This command uses generic Cairo fonts that are reasonable approximations of Hershey fonts 0, 1, 2, 4, and 5. Font 3 is the Greek (symbol) font, and cannot be  duplicated with generic controls. 
+<pre>
+Cairo version of font 0 -- Sans-Serif Regular 
+Cairo version of font 1 -- Serif Regular
+Cairo version of font 2 -- Monospace Italic
+Cairo version of font 4 -- Sans-Serif Bold
+Cairo version of font 5 -- Serif Bold
+</pre>
+<h3><a name="size" id="size"></a>Controlling Font Size</h3> 
+<p>The <code><a href="gradcomdsetstrsiz.html">set strsiz</a></code> command controls the font size for Hershey and Cairo fonts. Because the  fonts are vector-based, you can give different scaling factors for the width and height of the letters and the font will stretch accordingly.  If the vertical size is not given with <code><a href="gradcomdsetstrsiz.html">set strsiz</a></code>, the horizontal size will be used instead. </p>
+<h3><a name="thick" id="size2"></a>Controlling Font Thickness</h3>
+<p>The <code><a href="gradcomdsetstring.html">set string</a></code> command controls the  thickness for Hershey  fonts. For Cairo fonts, the thickness is controlled by using a bold version of your font, which will mean using a different font file. When using Cairo fonts, or when <code>'<a href="gradcomdsethershey.html">set hershey</a> off'</code> has been invoked, the thickness setting from<code> <a href="gradcomdsetstring.html">set string</a> </code>will be ignored. </p>
+<h3><a name="overrides" id="overrides"></a>Temporary Overrides</h3>
+<P>To access font numbers 10 and above within strings using the GrADS string escape characters, use the `f escape. The format of this is the backquote, followed by the character "f", followed by a two digit  integer number.
+<P><em><strong>Font Override: </strong></em><br />
+  To temporarily override the  font  in a string of text, use the back quote character (`). For Hershey fonts, a back quote followed by a single digit selects that font number for the remainder of the string, or until a new back quote character is encountered. For Cairo fonts, a back quote followed by 'f' and a double-digit number selects that font number for the remainder of the string, or until a new back quote character is encountered. See examples below.
+<P><em><strong>Text Position Override:</strong></em><br />
+  It is also possible to use the back quote to change the position of the text, to draw a string above or below the base line for subscripts or superscripts. A back quote followed by the letter a (`a) will draw the subsequent text in the string as a superscript (above normal). A back quote followed by the letter b (`b) will draw the subsequent text in the string as a subscript (below normal). A back quote followed by the letter n (`n) will draw the subsequent text in the string in a norm [...]
+<P><em><strong>Degree Symbol:</strong></em><br />
+You can draw a degree symbol by drawing a period with font number 3 (`3.)  See examples below. 
+<H3><a name="examples" id="examples"></a>Examples</H3>
+<pre>
+set font 0
+draw string 1.5 1.25 `1use font 2 to `2emphasize `1a particular word
+draw string 1.5 2.25 use font 3 for `3greek `0letters
+draw string 1.5 3.25 `3p`0r`a2`n = area of a circle
+draw string 1.5 4.25 label temperatures in `3.`0C or `3.`0F
+
+
+
+
+</pre>
diff --git a/doc/gadoc.html b/doc/gadoc.html
index 3aeee95..037689e 100644
--- a/doc/gadoc.html
+++ b/doc/gadoc.html
@@ -27,7 +27,7 @@ function MM_preloadImages() { //v3.0
 <p> </p>
 <table width="80%" border="0">
   <tr>
-    <td width="10%" valign="top"><img src="images/logom2.gif" width="98" height="81" border="1"></td>
+    <td width="10%" valign="top"><img src="/assets/logom2.gif" border="1"></td>
     <td width="90%"> 
       <table width="600" border="0">
         <tr> 
@@ -41,43 +41,34 @@ function MM_preloadImages() { //v3.0
         <tr> 
           <td class="linkpage"><table width=600 border="0" align="left" cellpadding="0" cellspacing="0" class="plaintext">
             <tr>
-              <td align="left" width="11"><img src="/assets/ball_sm_green.gif" alt="ball" width="6" height="6"></td>
-              <td align="center"><a href="/home.html"> IGES </a></td>
-              <td align="center" width="16"><img src="/assets/ball_sm_green.gif" alt="ball" width="6" height="6"></td>
-              <td align="center"><a href="/cola.html"> COLA </a></td>
-              <td align="center" width="16"><img src="/assets/ball_sm_green.gif" alt="ball" width="6" height="6"></td>
-              <td align="center"><a href="http://crew.iges.org"> CREW </a></td>
-              <td align="center" width="16"><img src="/assets/ball_sm_green.gif" alt="ball" width="6" height="6"></td>
-              <td align="center"><a href="http://wxmaps.org/"> Weather Maps </a></td>
-              <td align="center" width="16"><img src="/assets/ball_sm_green.gif" alt="ball" width="6" height="6"></td>
-              <td align="center"><a href="/grads/grads.html"> GrADS </a></td>
-              <td align="center" width="16"><img src="/assets/ball_sm_green.gif" alt="ball" width="6" height="6"></td>
-              <td align="center"><a href="/ellfb/home.html"> ELLFB </a></td>
-              <td align="center" width="16"><img src="/assets/ball_sm_green.gif" alt="ball" width="6" height="6"></td>
-              <td align="center"><a href="http://adv-model-earth-syst.org/index.php/JAMES/index"> JAMES </a></td>
-              <td align="center" width="16"><img src="/assets/ball_sm_green.gif" alt="ball" width="6" height="6"></td>
-              <td align="center"><a href="http://aoes.gmu.edu"> Climate Dynamics PhD</a></td>
-              <td align="right" width="11"><img src="/assets/ball_sm_green.gif" alt="ball" width="6" height="6"></td>
+              <td align="center" width="16"><img src="/assets/ball_sm_green.gif" width="6" height="6"></td>
+                <td align="center"><a href="/home.html">  IGES  </a></td>
+                <td align="center" width="16"><img src="/assets/ball_sm_green.gif" width="6" height="6"></td>
+                <td align="center"><a href="/cola.html">  COLA  </a></td>
+                <td align="center" width="16"><img src="/assets/ball_sm_green.gif" width="6" height="6"></td>
+                <td align="center"><a href="http://aoes.gmu.edu">  Climate Dynamics PhD  </a></td>
+                <td align="center" width="16"><img src="/assets/ball_sm_green.gif" width="6" height="6"></td>
+                <td align="center"><a href="/grads/grads.html">  GrADS  </a></td>
+                <td align="center" width="16"><img src="/assets/ball_sm_green.gif" width="6" height="6"></td>
+                <td align="center"><a href="http://wxmaps.org/">  Weather Maps  </a></td>
+                <td align="center" width="16"><img src="/assets/ball_sm_green.gif" width="6" height="6"></td>
+                <td align="center"><a href="http://wx.gmu.edu">  Virginia Weather  </a></td>
+                <td align="center" width="16"><img src="/assets/ball_sm_green.gif" width="6" height="6"></td>
             </tr>
           </table></td>
         </tr>
         <tr> 
           <td class="linkpage"> <table border="0" cellspacing="0" cellpadding="0" align="center" class="plaintext">
               <tr> 
-                <td align="left" width="11"><img src="/assets/ball_sm_green.gif" width="6" height="6"></td>
-                <td align="center"><a href="/grads/whatsnew.html"> What's New 
-                  </a></td>
                 <td align="center" width="16"><img src="/assets/ball_sm_green.gif" width="6" height="6"></td>
-                <td align="center"><a href="/grads/downloads.html"> Downloads 
-                  </a></td>
+                <td align="center"><a href="/grads/downloads.html">  Downloads  </a></td>
+                <td align="center" width="16"><img src="/assets/ball_sm_green.gif" width="6" height="6"></td>
+                <td align="center" class="plaintextbold"><a href="/grads/gadoc/index.html">  Documentation  </a></td>
                 <td align="center" width="16"><img src="/assets/ball_sm_green.gif" width="6" height="6"></td>
-                <td align="center"><a href="/grads/gadoc/index.html" class="plaintextbold"> Documentation 
-                  </a></td>
+                <td align="center"><a href="/grads/users.html">  Users Forum  </a></td>
                 <td align="center" width="16"><img src="/assets/ball_sm_green.gif" width="6" height="6"></td>
-                <td align="center"><a href="/grads/users.html"> Users Forum </a></td>
+                <td align="center"><a href="/grads/gds/index.html">  GDS  </a></td>
                 <td align="center" width="16"><img src="/assets/ball_sm_green.gif" width="6" height="6"></td>
-                <td align="center"><a href="/grads/gds/index.html"> GDS </a></td>
-                <td align="right" width="11"><img src="/assets/ball_sm_green.gif" width="6" height="6"></td>
               </tr>
             </table></td>
         </tr>
@@ -120,7 +111,7 @@ function MM_preloadImages() { //v3.0
         with a laptop.</span><br>
         <img src="/assets/ball_sm_green.gif" width="6" height="6"> 
         <span class="plaintext"><a href="http://iges.org/grads/gadoc/gadoc_files.tar.gz">http://iges.org/grads/gadoc/gadoc_files.tar.gz</a> 
-      (last updated 24 September 2012)</span> </p>
+      (last updated 9 November 2012)</span> </p>
       <p class="item14">Download Hard Copy Documentation<br>
         <span class="plaintext">If you simply <i>must</i> 
         have a printable version of the documentation, you will have to settle 
diff --git a/doc/gadoc_files.tar.gz b/doc/gadoc_files.tar.gz
deleted file mode 100644
index 1aeebe4..0000000
Binary files a/doc/gadoc_files.tar.gz and /dev/null differ
diff --git a/doc/gradcomdclear.html b/doc/gradcomdclear.html
index 85ce1f5..e81e325 100644
--- a/doc/gradcomdclear.html
+++ b/doc/gradcomdclear.html
@@ -1 +1,31 @@
-<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.--><title>GrADS Command: clear</title>
<style type="text/css">
<!--
.style1 {color: #990000}
-->
</style>
<body bgcolor="e0f0ff" text="#000000">

<H2><B>clear</B></H2><P>
<code>clear</code> (or just <code>c</code>)<p>
Issued without parameters, the <code>clear</code> command does pretty
heavy duty clearing of many of the GrADS internal settings.  Parameters
can be added to limit what is cleared when using more advanced
features.<p>
<H3>Usage Notes</H3><P>
<b>WARNING</b>: If you make any error in the syntax of <code>clear</code>
then GrADS does the full <code>clear</code><p>
<H3>Examples</H3>
<P>
<code>clear norset        </code>clears without resetting user options<br>
<code>clear events        </code>flushes the events buffer (e.g., mouse clicks)<br>
<code>clear graphics      </code>clears the graphics, but <b>not</b> the widgets<br>
<code>clear hbuff         </code>clears
the  buffered display and turns off double buffer mode<br>
<code>clear button <i>num</i>    </code>clears button  <code><i>num</i></code> <br>
<code>clear rband <i>num</i>     </code>clears rband  <code><i>num</i></code> <br>
<code>clear dropmenu <i>num</i>  </code>clears dropmenu <code><i>num</i></code> <br>
<code>clear sdfwrite      </code>clears sdfwrite file name and attributes without resetting other user options (<span class="style1">2.0.a3+</span>)<br>
<code>clear mask          </code>clears contour label mask, which is enabled with the command <code>'<a href="gradcomdsetclab.html">set clab</a> masked'</code>(<span class="style1">2.0.a7+</span>)<br>
<code>clear shp           </code>clears shapefile output file name and  attributes without resetting other user options (<span class="style1">2.0.a9+</span>)<br>
\ No newline at end of file
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.--><title>GrADS Command: clear</title>
+<style type="text/css">
+<!--
+.style1 {color: #990000}
+body {
+	background-color: #e0f0ff;
+}
+-->
+</style>
+<body text="#000000">
+
+<H2><B>clear</B></H2><P>
+<code>clear</code> (or just <code>c</code>)<p>
+Issued without parameters, the <code>clear</code> command does pretty
+heavy duty clearing of many of the GrADS internal settings.  Parameters
+can be added to limit what is cleared when using more advanced
+features.<p>
+<H3>Usage Notes</H3><P>
+<H3>Examples</H3>
+<P>
+<code>clear norset        </code>clears without resetting user options<br>
+<code>clear events        </code>flushes the events buffer (e.g., mouse clicks)<br>
+<code>clear graphics      </code>clears the graphics, but <b>not</b> the widgets<br>
+<code>clear hbuff         </code>clears
+the  buffered display and turns off double buffer mode<br>
+<code>clear button <i>num</i>    </code>clears button  <code><i>num</i></code> <br>
+<code>clear rband <i>num</i>     </code>clears rband  <code><i>num</i></code> <br>
+<code>clear dropmenu <i>num</i>  </code>clears dropmenu <code><i>num</i></code> <br>
+<code>clear sdfwrite      </code>clears sdfwrite file name and attributes without resetting other user options (<span class="style1">2.0.a3+</span>)<br>
+<code>clear mask          </code>clears contour label mask, which is enabled with the command <code>'<a href="gradcomdsetclab.html">set clab</a> masked'</code>(<span class="style1">2.0.a7+</span>)<br>
+<code>clear shp           </code>clears shapefile output file name and  attributes without resetting other user options (<span class="style1">2.0.a9+</span>)<br>
diff --git a/doc/gradcomddisableprint.html b/doc/gradcomddisableprint.html
index abe2648..0500b31 100644
--- a/doc/gradcomddisableprint.html
+++ b/doc/gradcomddisableprint.html
@@ -1 +1,16 @@
-<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.--><style type="text/css">
<!--
body {
	background-color: #e0f0ff;
}
-->
</style>

<h2>disable print</h2>
This command closes the  GrADS metafile  that  contains the instructions  to create a hardcopy of the graphical display.
<p>
<h3>Usage Notes</h3>
<p>See the notes in the documentation page for <code><a href="gradcomdenableprint.html">enable print</a></code></p>
<h3> </h3>

\ No newline at end of file
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.--><style type="text/css">
+<!--
+body {
+	background-color: #e0f0ff;
+}
+-->
+</style>
+
+<h2>disable print</h2>
+<p>This command  is obsolete beginning with GrADS version 2.1. It has been replaced by <code><a href="gradcomdgxprint.html">gxprint</a></code>.</p>
+<p>This command closes the  GrADS metafile  that  contains the instructions  to create a hardcopy of the graphical display. </p>
+<p>
+<h3>Usage Notes</h3>
+<p>See the notes in the documentation page for <code><a href="gradcomdenableprint.html">enable print</a></code></p>
+<h3> </h3>
+
diff --git a/doc/gradcomddrawbutton.html b/doc/gradcomddrawbutton.html
index 2a40214..909c59d 100644
--- a/doc/gradcomddrawbutton.html
+++ b/doc/gradcomddrawbutton.html
@@ -1 +1,62 @@
-<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->

<html>
<head>
<title>GrADS Command: draw button</title>
</head>
<body bgcolor="e0f0ff" text="#000000">

<h2><b>draw button</b></h2>
<p>
<code>draw button <i>number xpos ypos width height string</i></code>

<p>
Draws a button centered on <code><i>xpos,ypos</i></code> with the
following attributes:

<p>
<ul>
<code>number   </code>button number, can be 1 thru 255<br>
<code>xpos     </code>x center of the button in page coordinates (inches)<br>
<code>ypos     </code>y center of the button in page coordinates (inches)<br>
<code>width    </code>width (x) of the button (inches)<br>
<code>height   </code>height (y) of the button (inches)<br>
<code>string   </code>text to display centered in the button<br>
</ul>

<p>
<h3>Usage Notes</h3>
<ol>
<li>Button colors are specified with the <a
href="gradcomdsetbutton.html"><code>set button</code></a> command.
<p>
<li>A button's initial state is <code>ON</code>. If a user clicks on a
button following a <a href="gradcomdqpos.html"><code>q pos</code></a> command,
then the button state will switch from <code>ON (1)</code> to
<code>OFF (0)</code>. A second <a href="gradcomdqpos.html"><code>q pos</code></a>
followed by a mouse click on the button will return it to the
<code>ON</code> state.  
<p>
<li>The button "state" (i.e. <code>ON/OFF</code>) may also
be set with the <a href="gradcomdredrawbutton.html"><code>redraw
button</code></a> command.
<p>
<li>See the section of the User's Guide on <a
href="script.html#widgets">widgets</a> for more information on using
buttons.
</ol>

<p>
<h3>Example</h3>

<p>
<pre>
set rgb 90 100 100 100
set rgb 91  50  50  50
set rgb 92 200 200 200
set button 2 90 91 92 3 90 91 92 10
draw button  1 2.5 8.0 2.5 0.5  Click Here
</pre>

</body>
</html>
\ No newline at end of file
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
+
+<html>
+<head>
+<title>GrADS Command: draw button</title>
+</head>
+<body bgcolor="e0f0ff" text="#000000">
+
+<h2><b>draw button</b></h2>
+<p>
+<code>draw button <i>number xpos ypos width height string</i></code>
+
+<p>
+Draws a button centered on <code><i>xpos,ypos</i></code> with the
+following attributes:
+
+<p>
+<ul>
+<code>number   </code>button number, 1 - 512<br>
+<code>xpos     </code>x center of the button in page coordinates (inches)<br>
+<code>ypos     </code>y center of the button in page coordinates (inches)<br>
+<code>width    </code>width (x) of the button (inches)<br>
+<code>height   </code>height (y) of the button (inches)<br>
+<code>string   </code>text to display centered in the button<br>
+</ul>
+
+<p>
+<h3>Usage Notes</h3>
+<ol>
+<li>Button colors are specified with the <a
+href="gradcomdsetbutton.html"><code>set button</code></a> command.
+<p>
+<li>A button's initial state is <code>ON</code>. If a user clicks on a
+button following a <a href="gradcomdqpos.html"><code>q pos</code></a> command,
+then the button state will switch from <code>ON (1)</code> to
+<code>OFF (0)</code>. A second <a href="gradcomdqpos.html"><code>q pos</code></a>
+followed by a mouse click on the button will return it to the
+<code>ON</code> state.  
+<p>
+<li>The button "state" (i.e. <code>ON/OFF</code>) may also
+be set with the <a href="gradcomdredrawbutton.html"><code>redraw
+button</code></a> command.
+<p>
+<li>See the section of the User's Guide on <a
+href="script.html#widgets">widgets</a> for more information on using
+buttons.
+</ol>
+
+<p>
+<h3>Example</h3>
+
+<p>
+<pre>
+set rgb 90 100 100 100
+set rgb 91  50  50  50
+set rgb 92 200 200 200
+set button 2 90 91 92 3 90 91 92 10
+draw button  1 2.5 8.0 2.5 0.5  Click Here
+</pre>
+
+</body>
+</html>
diff --git a/doc/gradcomddrawwxsym.html b/doc/gradcomddrawwxsym.html
index d778b20..d7d5387 100644
--- a/doc/gradcomddrawwxsym.html
+++ b/doc/gradcomddrawwxsym.html
@@ -1,37 +1 @@
-<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
-<style type="text/css">
-body {
-	background-color: #e0f0ff;
-}
-</style>
-
-
-<H2><B>draw wxsym</B></H2>
-<P>
-<code>draw wxsym <i>symbol x y size
-<color <thickness>></i></code><p>
-Draws the specified <code>wx</code> symbol at the specified location.
-where:<p>
-<ul><code><i>symbol</i></code>               is
-an integer specifying what symbol to
-draw<br>
-<code><i>x</i></code>                         x
-location, in plotter inches<br>
-<code><i>y</i></code>                         y
-location<br>
-<code><i>size</i></code>                   size
-of the symbol <br>
-<code><i>color</i></code>                 color
-of symbol. Use <code>-1</code> (the default) to get
-standard colors (red for storm, blue for snow, etc)<br>
-<code><i>thickness</i></code>         line
-thickness of the symbol (default is 3)
-</ul>
-<p>
-<H3>Usage Notes</H3><P>
-<ol>
-<li>To see what symbols are available, run the script <code><a href="ftp://cola.gmu.edu/grads/scripts/wxsym.gs">wxsym.gs</a></code> to see how to issue the <code>wxsym</code>
-command.
-<li>To change the default colors of the weather symbols, use <code><a href="gradcomdsetwxcols.html">set wxcols</a></code><br>
-</ol>
-<H3>Examples</H3><P>
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->

<H2><B>draw wxsym</B></H2>
<P>
<code>draw wxsym <i>symbol x y size
<color <thickness>></i></code><p>
Draws the specified <code>wx</code> symbol at the specified location.
where:<p>
<ul><code><i>symbol</i></code>               is
an integer specifying what symbol to
draw<br>
<code><i>x</i></code>                         x
location, in plotter inches<br>
<code><i>y</i></code>                         y
location<br>
<code><i>size</i></code>                   size
of the symbol <br>
<code><i>color</i></code>                 color
of symbol. Use <code>-1</code> (the default) to get
standard colors (red for storm, blue for snow, etc)<br>
<code><i>thickness</i></code>         line
thickness of the symbol (default is 3)
</ul>
<p>
<H3>Usage Notes</H3><P>
<ol>
<li>To see what symbols are available, run the script <code><a href="ftp://grads.iges.org/grads/scripts/wxsym.gs">wxsym.gs</a></code> to see how to issue the <code>wxsym</code>
command.
<li>To change the default colors of the weather symbols, use <code><a href="gradcomdsetwxcols.html">set wxcols</a></code><br>
</ol>
<H3>Examples</H3><P>
\ No newline at end of file
diff --git a/doc/gradcomdenableprint.html b/doc/gradcomdenableprint.html
index 19a0511..f54facc 100644
--- a/doc/gradcomdenableprint.html
+++ b/doc/gradcomdenableprint.html
@@ -1,29 +1 @@
-<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.--><style type="text/css">
-<!--
-body {
-	background-color: #e0f0ff;
-}
--->
-</style>
-
-<h2>enable print</h2>
-<code>enable print <i>fname</i></code>
-<p>
-This command opens the output file <code> <i>fname</i></code> that will contain the  instructions  in GrADS metacode format to create a hardcopy of the graphical display. Any existing contents of <code><i>fname</i></code>  will be lost.
-
-The output file  <code> <i>fname</i></code> is referred to as a GrADS metafile. 
-<p>
-
-<h3>Usage Notes</h3>
-<p>Creating a GrADS metafile for vector-graphic hardcopy involves four steps:</p>
-<p>1. Open the metafile with the <code><a href="gradcomdenableprint.html">enable print</a> </code> command<br />
-2. Create the graphical display that you want to print<br />
-3. Issue the <a href="gradcomdprint.html"><code>print</code></a>  command. For multiple images in your metafile, use <code><a href="gradcomdclear.html">clear</a></code> and then <a href="gradcomdprint.html"><code>print</code></a>  again.<br />
-4. Close the metafile with the <code><a href="gradcomddisableprint.html">disable print</a> </code> command</p>
-<p>After you have created a GrADS metafile, you can </p>
-<p>1. convert it to postscript using the external utility <code><a href="gradutilgxps.html">gxps</a></code> <br />
-  2. 
-convert it to encapsulated postscript using <code><a href="gradutilgxeps.html">gxeps</a></code> or you can <br />
-3. 
-display it using the external utilities <code><a href="gradutilgxtran.html">gxtran</a></code> or <code><a href="ftp://cola.gmu.edu/grads/gv/gv32.exe">gv32.exe</a></code> (for MS Windows)</p>
-<p> </p>
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.--><style type="text/css">
<!--
body {
	background-color: #e0f0ff;
}
-->
</style>

<h2>enable print</h2>
<code>enable print <i>fname</i></code>
<p>
This command opens the output file <code> <i>fname</i></code> that will contain the  instructions  in GrADS metacode format to create a hardcopy of the graphical display. Any existing contents of <code><i>fname</i></code>  will be lost.

The output file  <code> <i>fname</i></code> is referred to as a GrADS metafile. 
<p>

<h3>Usage Notes</h3>
<p>Creating a GrADS metafile for vector-graphic hardcopy involves four steps:</p>
<p>1. Open the metafile with the <code><a href="gradcomdenableprint.html">enable print</a> </code> command<br />
2. Create the graphical display that you want to print<br />
3. Issue the <a href="gradcomdprint.html"><code>print</code></a>  command. For multiple images in your metafile, use <code><a href="gradcomdclear.html">clear</a></code> and then <a href="gradcomdprint.html"><code>print</code></a>  again.<br />
4. Close the metafile with the <code><a href="gradcomddisableprint.html">disable print</a> </code> command</p>
<p>After you have created a GrADS metafile, you can </p>
<p>1. convert it to postscript using the external utility <code><a href="gradutilgxps.html">gxps</a></code> <br />
  2. 
convert it to encapsulated postscript using <code><a href="gradutilgxeps.html">gxeps</a></code> or you can <br />
3. 
display it using the external utilities <code><a href="gradutilgxtran.html">gxtran</a></code> or <code><a href="ftp://grads.iges.org/grads/gv/gv32.exe">gv32.exe</a></code> (for MS Windows)</p>
<p> </p>
\ No newline at end of file
diff --git a/doc/gradcomdgxprint.html b/doc/gradcomdgxprint.html
new file mode 100644
index 0000000..e09cb23
--- /dev/null
+++ b/doc/gradcomdgxprint.html
@@ -0,0 +1,86 @@
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
+
+<html>
+<head>
+<title>GrADS Commands: printim</title>
+<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
+<style type="text/css">
+body {
+	background-color: #e0f0ff;
+}
+.red {
+	color: #900;
+}
+</style>
+</head>
+<body text="#000000">
+
+<h2><b>gxprint</b></h2>
+<p>
+Beginning with <span class="red">GrADS version 2.1</span>, the <a href="gradcomdgxprint.html"><code>gxprint</code></a> command will produce all hardcopy output in both image and vector graphic formats. The output is based on the current contents of the metabuffer, and it works in batch mode as well as interactive mode. It replaces the <code><a href="gradcomdprint.html">print</a></code>, 
+<code><a href="gradutilgxps.html">gxps</a></code>, <code><a href="gradutilgxeps.html">gxeps</a></code>, and <code><a href="gradcomdprintim.html">printim</a></code> commands. 
+<h3>Syntax
+</h3>
+<ul>
+  <code>gxprint <i>filename options</i></code> 
+</ul>
+<p>
+where:
+<ul>
+  <code><i>filename:</i>  </code>The name of the output file. If this 
+  file exists, it will be replaced. 
+  <br>
+  <code>            </code>If the filename ends with ".eps", ".ps", ".pdf", ".svg", ".png", ".gif", or ".jpg", then GrADS will automatically create the  output in the corresponding format.<br>
+  <br>
+  <p>
+  <code><i>options:</i></code><br>
+  <code>           eps           </code>Produce output in EPS format<br>
+  <code>           ps              </code>Produce output in PS format<br>
+  <code>           pdf           </code>Produce output in PDF format<br>
+  <code>           svg           </code>Produce output in SVG format<br>
+  <code>           png         </code>Produce image output in PNG format <br>
+  <code>           gif           </code>Produce image output in GIF  format (not available with Cairo)<br>
+  <code>           jpg           </code>Produce image output in JPG format (not available with Cairo)<br>
+  <code>           black       </code>Use black background (default is current display setting)<br>
+  <code>           white       </code>Use white background (default is current display setting)<br>
+  <code>           xNN         </code>Horizontal image size in <code>NN</code> pixels (for image output only)<br>
+  <code>           yNN         </code>Vertical image size in <code>NN</code> pixels (for image output only)<br>
+  <code>           -e NN       </code>The blank edge around the plot will be <code>NN</code> inches wide (for PS, EPS, and PDF output only)<br>
+  <code>           -t NN       </code>Color number <code>NN</code> is fully transparent<br>
+  <code>           -b <i>bgImage </i> </code>Image file <code><i>bgImage</i></code> is included in the background of the output<br>
+  <code>           -f <i>fgImage</i>  </code>Image file <code><i>fgImage</i></code> is included in the foreground of the output<br>
+  </p>
+</ul>
+<p> One or more <code><i>options</i></code> may be given in any order.
+<p>
+<h3>Usage Notes</h3>
+
+<ol>
+<li><code>gxprint</code> works with <span class="red">GrADS version 2.1+</span>.
+<li><code><i>bgImage</i></code> and <code><i>fgImage</i></code> must be PNG format. 
+<li>The GIF and JPG image formats are not support by the Cairo library. These options will work  only when using the GD library for rendering image output.
+<li>The default width of the edge around the PS, EPS, and PDF output files is 0.15625 inches. An edge width smaller than the default may result in the plot getting cropped by the printer. 
+<li>In <span class="red">GrADS version 2.1+</span>, it is also possible to achieve color transparency (full or partial) using the <code><a href="gradcomdsetrgb.html">set rgb</a></code> command. 
+<li>Multi-page output is not yet supported with <code>gxprint</code>. 
+</ol>
+
+<p>
+<h3>Examples </h3>
+
+<p>
+The following command produces a 1024x768 PNG image into file test.png:
+<ul>
+<code>gxprint test.png x1024 y768</code>
+</ul>
+<p>This command produces a GIF image with transparent color 0 and a background 
+  image mybkg.png. This means that in test.png, the background image mybkg.png 
+  will be seen wherever the color 0 (background) appeared in the current display. 
+</p>
+<ul>
+  <p><code>gxprint test.png -b mybkg.png -t 0 </code><br>
+  
+</ul>  
+
+</body>
+</html>
+
diff --git a/doc/gradcomdquery.html b/doc/gradcomdquery.html
index f521cd3..654bfb2 100644
--- a/doc/gradcomdquery.html
+++ b/doc/gradcomdquery.html
@@ -1 +1,203 @@
-<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->

<html>
<head>
<title>GrADS Command: query</title>
<link rel="stylesheet" href="GrADS.css">
<style type="text/css">
<!--
.style1 {color: #990000}
-->
</style>
</head>
<body bgcolor="e0f0ff" text="#000000">

<h2><b>query</b></h2>
<p class="plaintext"> The <code class="code">query</code> command allows the user 
  to get information about a variety of aspects of the current GrADS session. 
  Configuration, plot characteristics, graphics specifics, and file structure 
  are some examples. The use of <code class="code">query pos</code> combined with 
  the coordinate transformations is the basis of many interactive applications 
  with buttons and drop menus. The <code class="code">query</code> command may 
  be shortened to simply <code class="code">q</code>. The syntax is: 
<p>
<ul>
  <code class="code">query <i><option></i></code><br>
  or<br>
  <code class="code">q <i><option></i></code> 
</ul>
<p class="plaintext"> When given without an <code><i class="codeitalic">option</i></code>, 
  the <code class="code">query</code> command returns a list of the possible options. 
  These are: 
<blockquote>


  <table width="609" border="0" cellspacing="0" cellpadding="0">
    <tr> 
      <td class="code"><a href="gradcomdqattr.html">attr</a> <span class="codeitalic">n</span></td>
      <td class="plaintext">Returns all attributes for file n (or default file 
        if n is omitted)</td>
    </tr>
    <tr>
      <td class="code">cache n</td>
      <td class="plaintext">Returns netcdf4/hdf5 cache size  for file n (or default file 
      if n is omitted) (<span class="style1">2.0.a8+</span>)</td>
    </tr>
    <tr>
      <td class="code">cachesf</td>
      <td class="plaintext">Returns netcdf4/hdf5 cache scale factor (<span class="style1">2.0.a8+</span>)</td>
    </tr>
    <tr>
      <td class="code">calendar</td>
      <td class="plaintext">Returns calendar mode: unset, 365-day, or standard</td>
    </tr>
    <tr> 
      <td class="code" width="119">config</td>
      <td class="plaintext" width="490">Returns GrADS configuration information</td>
    </tr>
    <tr>
      <td class="code">contours</td>
      <td class="plaintext">Returns colors and levels of a line contours (<span class="style1">2.0.a8+</span>)</td>
    </tr>
    <tr> 
      <td class="code" width="119">ctlinfo</td>
      <td class="plaintext" width="490">Returns contents of data descriptor file</td>
    </tr>
    <tr>
      <td class="code"><a href="gradcomdqdbf.html">dbf</a></td>
      <td class="plaintext">Lists the contents of a shapefile attribute database (<span class="style1">2.0.a8+</span>)</td>
    </tr>
    <tr> 
      <td class="code" width="119">define</td>
      <td class="plaintext" width="490">Lists currently defined variables</td>
    </tr>
    <tr> 
      <td class="code" width="119">defval <span class="codeitalic">v1 i j</span></td>
      <td class="plaintext" width="490">Returns the value of defined variable 
        <code><i class="codeitalic">v1</i></code> at point <code><i class="codeitalic">i,j</i></code></td>
    </tr>
    <tr> 
      <td class="code" width="119"><a href="gradcomdqdialog.html">dialog</a> <span class="codeitalic">args</span></td>
      <td class="plaintext" width="490">Launches a dialog box that prompts for 
        text or numeric data entry</td>
    </tr>
    <tr> 
      <td class="code" width="119">dims</td>
      <td class="plaintext" width="490">Returns current dimension environment</td>
    </tr>
    <tr>
      <td class="code"><a href="gradcomdqens.html">ens</a></td>
      <td class="plaintext">Returns ensemble metadata</td>
    </tr>
    <tr> 
      <td class="code" width="119">file <span class="codeitalic">n</span></td>
      <td class="plaintext" width="490">Returns info on file number <code><i>n</i></code></td>
    </tr>
    <tr> 
      <td class="code" width="119">files</td>
      <td class="plaintext" width="490">Lists open files</td>
    </tr>
    <tr> 
      <td class="code" width="119"><a href="gradcomdqfwrite.html">fwrite</a></td>
      <td class="plaintext" width="490">Returns status and characteristics of 
        fwrite ouput file</td>
    </tr>
    <tr> 
      <td class="code" width="119">gxinfo</td>
      <td class="plaintext" width="490">Returns graphics environment info</td>
    </tr>
    <tr>
      <td class="code">gxout</td>
      <td class="plaintext">Returns current gxout settings</td>
    </tr>
    <tr> 
      <td class="code" width="119">lats</td>
      <td class="plaintext" width="490">Returns the status of the GrADS-LATS interface</td>
    </tr>
    <tr> 
      <td class="code" width="119"><a href="gradcomdqpos.html">pos</a></td>
      <td class="plaintext" width="490">Waits for mouse click, then returns position 
        plus additional widget information</td>
    </tr>
    <tr>
      <td class="code"><a href="gradcomdqsdfwrite.html">sdfwrite</a></td>
      <td class="plaintext">Returns the status of the sdfwrite options </td>
    </tr>
    <tr> 
      <td class="code" width="119"><a href="gradcomdqshades.html">shades</a></td>
      <td class="plaintext" width="490">Lists colors and levels of shaded contours</td>
    </tr>
    <tr>
      <td class="code"><a href="gradcomdqshp.html">shp</a></td>
      <td class="plaintext">Lists the contents of a shapefile (<span class="style1">2.0.a8+</span>)</td>
    </tr>
    <tr>
      <td class="code"><a href="gradcomdqshpopts.html">shpopts</a></td>
      <td class="plaintext">Returns  settings for drawing and writing shapefiles (<span class="style1">2.0.a9+</span>)</td>
    </tr>
    <tr> 
      <td class="code" width="119">string str</td>
      <td class="plaintext" width="490">Returns the width of string <code><i>str</i></code> in virtual page inches</td>
    </tr>
    <tr> 
      <td class="code" width="119">time</td>
      <td class="plaintext" width="490">Returns info about time settings</td>
    </tr>
    <tr> 
      <td class="code" width="119">udft</td>
      <td class="plaintext" width="490">Returns the user defined function table </td>
    </tr>
    <tr>
      <td class="code">undef</td>
      <td class="plaintext">Returns the output undefined value</td>
    </tr>
    <tr> 
      <td class="code" width="119">xinfo</td>
      <td class="plaintext" width="490">Returns characteristics of the graphics 
        display window</td>
    </tr>
    <tr> 
      <td class="code" width="119">xy2w<span class="codeitalic">  v1 v2</span></td>
      <td class="plaintext" width="490">Converts XY coords to world coords</td>
    </tr>
    <tr> 
      <td class="code" width="119">xy2gr <span class="codeitalic">v1 v2</span></td>
      <td class="plaintext" width="490">Converts XY coords to grid coords</td>
    </tr>
    <tr> 
      <td class="code" width="119">w2xy  <span class="codeitalic">v1 v2</span></td>
      <td class="plaintext" width="490">Converts world coords to XY coords</td>
    </tr>
    <tr> 
      <td class="code" width="119">w2gr  <span class="codeitalic">v1 v2</span></td>
      <td class="plaintext" width="490">Converts world coords to grid coords</td>
    </tr>
    <tr> 
      <td class="code" width="119">gr2w  <span class="codeitalic">v1 v2</span></td>
      <td class="plaintext" width="490">Converts grid coords to world coords</td>
    </tr>
    <tr> 
      <td class="code" width="119">gr2xy <span class="codeitalic">v1 v2</span></td>
      <td class="plaintext" width="490">Converts grid coords to XY coords</td>
    </tr>
    <tr> 
      <td class="code" width="119">pp2xy <span class="codeitalic">v1 v2</span></td>
      <td class="plaintext" width="490">Converts virtual page XY coords to real 
        page XY coords</td>
    </tr>
  </table>
</blockquote>
  <p> <code> </code> <br>
  <p> 
  <h3 class="item12bold">Usage Notes</h3>
  <p class="plaintext"> For more information on the use of the <code>query</code> 
    command, see the section of the User's Guide on <a
href="script.html#commands">commands that complement the scripting language</a>. 
  <p> 
  <h3 class="item12bold">Examples</h3>
</body>
</html>
\ No newline at end of file
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
+
+<html>
+<head>
+<title>GrADS Command: query</title>
+<link rel="stylesheet" href="GrADS.css">
+<style type="text/css">
+<!--
+.style1 {color: #990000}
+-->
+</style>
+</head>
+<body bgcolor="e0f0ff" text="#000000">
+
+<h2><b>query</b></h2>
+<p class="plaintext"> The <code class="code">query</code> command allows the user 
+  to get information about a variety of aspects of the current GrADS session. 
+  Configuration, plot characteristics, graphics specifics, and file structure 
+  are some examples. The use of <code class="code">query pos</code> combined with 
+  the coordinate transformations is the basis of many interactive applications 
+  with buttons and drop menus. The <code class="code">query</code> command may 
+  be shortened to simply <code class="code">q</code>. The syntax is: 
+<p>
+<ul>
+  <code class="code">query <i><option></i></code><br>
+  or<br>
+  <code class="code">q <i><option></i></code> 
+</ul>
+<p class="plaintext"> When given without an <code><i class="codeitalic">option</i></code>, 
+  the <code class="code">query</code> command returns a list of the possible options. 
+  These are: 
+<blockquote>
+
+
+  <table width="609" border="0" cellspacing="0" cellpadding="0">
+    <tr> 
+      <td class="code"><a href="gradcomdqattr.html">attr</a> <span class="codeitalic">n</span></td>
+      <td class="plaintext">Returns all attributes for file n (or default file 
+        if n is omitted)</td>
+    </tr>
+    <tr>
+      <td class="code">cache n</td>
+      <td class="plaintext">Returns netcdf4/hdf5 cache size  for file n (or default file 
+      if n is omitted) (<span class="style1">2.0.a8+</span>)</td>
+    </tr>
+    <tr>
+      <td class="code">cachesf</td>
+      <td class="plaintext">Returns netcdf4/hdf5 cache scale factor (<span class="style1">2.0.a8+</span>)</td>
+    </tr>
+    <tr>
+      <td class="code">calendar</td>
+      <td class="plaintext">Returns calendar mode: unset, 365-day, or standard</td>
+    </tr>
+    <tr> 
+      <td class="code" width="119">config</td>
+      <td class="plaintext" width="490">Returns GrADS configuration information</td>
+    </tr>
+    <tr>
+      <td class="code">contours</td>
+      <td class="plaintext">Returns colors and levels of a line contours (<span class="style1">2.0.a8+</span>)</td>
+    </tr>
+    <tr> 
+      <td class="code" width="119">ctlinfo</td>
+      <td class="plaintext" width="490">Returns contents of data descriptor file</td>
+    </tr>
+    <tr>
+      <td class="code"><a href="gradcomdqdbf.html">dbf</a></td>
+      <td class="plaintext">Lists the contents of a shapefile attribute database (<span class="style1">2.0.a8+</span>)</td>
+    </tr>
+    <tr> 
+      <td class="code" width="119">define</td>
+      <td class="plaintext" width="490">Lists currently defined variables</td>
+    </tr>
+    <tr> 
+      <td class="code" width="119">defval <span class="codeitalic">v1 i j</span></td>
+      <td class="plaintext" width="490">Returns the value of defined variable 
+        <code><i class="codeitalic">v1</i></code> at point <code><i class="codeitalic">i,j</i></code></td>
+    </tr>
+    <tr> 
+      <td class="code" width="119"><a href="gradcomdqdialog.html">dialog</a> <span class="codeitalic">args</span></td>
+      <td class="plaintext" width="490">Launches a dialog box that prompts for 
+        text or numeric data entry</td>
+    </tr>
+    <tr> 
+      <td class="code" width="119">dims</td>
+      <td class="plaintext" width="490">Returns current dimension environment</td>
+    </tr>
+    <tr>
+      <td class="code"><a href="gradcomdqens.html">ens</a></td>
+      <td class="plaintext">Returns ensemble metadata</td>
+    </tr>
+    <tr>
+      <td class="code">fgvals</td>
+      <td class="plaintext">Returns values and colors specified for gxout fgrid (<span class="style1">2.1.a2+</span>)</td>
+    </tr>
+    <tr> 
+      <td class="code" width="119">file <span class="codeitalic">n</span></td>
+      <td class="plaintext" width="490">Returns info on file number <code><i>n</i></code></td>
+    </tr>
+    <tr> 
+      <td class="code" width="119">files</td>
+      <td class="plaintext" width="490">Lists open files</td>
+    </tr>
+    <tr> 
+      <td class="code" width="119"><a href="gradcomdqfwrite.html">fwrite</a></td>
+      <td class="plaintext" width="490">Returns status and characteristics of 
+        fwrite ouput file</td>
+    </tr>
+    <tr> 
+      <td class="code" width="119">gxinfo</td>
+      <td class="plaintext" width="490">Returns graphics environment info</td>
+    </tr>
+    <tr>
+      <td class="code">gxout</td>
+      <td class="plaintext">Returns current gxout settings</td>
+    </tr>
+    <tr> 
+      <td class="code" width="119">lats</td>
+      <td class="plaintext" width="490">Returns the status of the GrADS-LATS interface</td>
+    </tr>
+    <tr> 
+      <td class="code" width="119"><a href="gradcomdqpos.html">pos</a></td>
+      <td class="plaintext" width="490">Waits for mouse click, then returns position 
+        plus additional widget information</td>
+    </tr>
+    <tr>
+      <td class="code"><a href="gradcomdqsdfwrite.html">sdfwrite</a></td>
+      <td class="plaintext">Returns the status of the sdfwrite options </td>
+    </tr>
+    <tr> 
+      <td class="code" width="119"><a href="gradcomdqshades.html">shades</a></td>
+      <td class="plaintext" width="490">Lists colors and levels of shaded contours</td>
+    </tr>
+    <tr>
+      <td class="code"><a href="gradcomdqshp.html">shp</a></td>
+      <td class="plaintext">Lists the contents of a shapefile (<span class="style1">2.0.a8+</span>)</td>
+    </tr>
+    <tr>
+      <td class="code"><a href="gradcomdqshpopts.html">shpopts</a></td>
+      <td class="plaintext">Returns  settings for drawing and writing shapefiles (<span class="style1">2.0.a9+</span>)</td>
+    </tr>
+    <tr> 
+      <td class="code" width="119">string str</td>
+      <td class="plaintext" width="490">Returns the width of string <code><i>str</i></code> in virtual page inches</td>
+    </tr>
+    <tr> 
+      <td class="code" width="119">time</td>
+      <td class="plaintext" width="490">Returns info about time settings</td>
+    </tr>
+    <tr> 
+      <td class="code" width="119">udft</td>
+      <td class="plaintext" width="490">Returns the user defined function table </td>
+    </tr>
+    <tr>
+      <td class="code">undef</td>
+      <td class="plaintext">Returns the output undefined value</td>
+    </tr>
+    <tr> 
+      <td class="code" width="119">xinfo</td>
+      <td class="plaintext" width="490">Returns characteristics of the graphics 
+        display window</td>
+    </tr>
+    <tr> 
+      <td class="code" width="119">xy2w<span class="codeitalic">  v1 v2</span></td>
+      <td class="plaintext" width="490">Converts XY coords to world coords</td>
+    </tr>
+    <tr> 
+      <td class="code" width="119">xy2gr <span class="codeitalic">v1 v2</span></td>
+      <td class="plaintext" width="490">Converts XY coords to grid coords</td>
+    </tr>
+    <tr> 
+      <td class="code" width="119">w2xy  <span class="codeitalic">v1 v2</span></td>
+      <td class="plaintext" width="490">Converts world coords to XY coords</td>
+    </tr>
+    <tr> 
+      <td class="code" width="119">w2gr  <span class="codeitalic">v1 v2</span></td>
+      <td class="plaintext" width="490">Converts world coords to grid coords</td>
+    </tr>
+    <tr> 
+      <td class="code" width="119">gr2w  <span class="codeitalic">v1 v2</span></td>
+      <td class="plaintext" width="490">Converts grid coords to world coords</td>
+    </tr>
+    <tr> 
+      <td class="code" width="119">gr2xy <span class="codeitalic">v1 v2</span></td>
+      <td class="plaintext" width="490">Converts grid coords to XY coords</td>
+    </tr>
+    <tr> 
+      <td class="code" width="119">pp2xy <span class="codeitalic">v1 v2</span></td>
+      <td class="plaintext" width="490">Converts virtual page XY coords to real 
+        page XY coords</td>
+    </tr>
+  </table>
+</blockquote>
+  <p> <code> </code> <br>
+  <p> 
+  <h3 class="item12bold">Usage Notes</h3>
+  <p class="plaintext"> For more information on the use of the <code>query</code> 
+    command, see the section of the User's Guide on <a
+href="script.html#commands">commands that complement the scripting language</a>. 
+  <p> 
+  <h3 class="item12bold">Examples</h3>
+</body>
+</html>
diff --git a/doc/gradcomdsdfwrite.html b/doc/gradcomdsdfwrite.html
index 717b446..cef18dd 100644
--- a/doc/gradcomdsdfwrite.html
+++ b/doc/gradcomdsdfwrite.html
@@ -1 +1,142 @@
-<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->

<html>
<head>
<title>GrADS Commands: sdfwrite</title>
<style type="text/css">
<!--
.style1 {color: #990000}
-->
</style>
</head>
<body bgcolor="e0f0ff" text="#000000">

<h2><b>sdfwrite</b></h2>
<p><code>sdfwrite <i>varname </i></code>
<p>This<code></code> command will write out a defined variable <code><i>varname </i></code>into a NetCDF formatted
  data file.  

<ul>
  <p> </p>
</ul>
<h3>Usage Notes</h3>

<p>
The <code>sdfwrite</code> command was initially implemented in GrADS version <span class="style1">2.0.a3</span>. Additional features added in subsequent releases are as follows:
<ul>
  <li>(<span class="style1">2.0.a5</span>) NetCDF output may be forced to have 4 or 5 dimensions. </li>
  <li>(<span class="style1">2.0.a8</span>) NetCDF output may be floating point or double precision. NetCDF output may also be version 4, with chunking and compression enabled. </li>
  <li>(<span class="style1">2.0.a9</span>) If the output is not forced to have 4 or 5 dimensions, it will have the same number of dimensions as the defined variable being written out to file. </li>
</ul>
<p>Options to control the name and format of the output file are implemented with the <code><a href="gradcomdsetsdfwrite.html">set sdfwrite</a></code> command. The <a href="gradcomdqsdfwrite.html"><code>q sdfwrite</code></a> command
  returns the status of the <code>sdfwrite</code> options. 

<p>The name of the output file will be <code>grads.sdfwrite.nc</code> unless specified otherwise with the <code><a href="gradcomdsetsdfwrite.html">set sdfwrite</a></code> command. If the 
file exists, it will be replaced.  It is not possible to append variables to an existing file.  
<p>The dimensions of the variable written to file correspond to the dimension environment that is set when the variable is  defined. The dimension environment that is set when the 'sdfwrite' command is invoked is ignored. Note this behavior is different from the fwrite command.
<p>By default, the output file will have a coordinate variable only for  varying dimensions in the defined variable; non-varying dimensions will not appear as a coordinate variable with a size of 1. However, as of version <span class="style1">2.0.a5</span>,  options have been added to the  <code><a href="gradcomdsetsdfwrite.html">set sdfwrite</a></code> command to  force the variable in the output file to have at least 4 or all 5 dimensions. When either of these options to   <code><a href [...]
For example, if your defined variable is 500mb height on14may2002 (a 2D variable that varies only in lon and lat), and you use the -4d option, the output file with show height as a 4D variable with a Z dimension of size 1 called 'lev' with a value "500 mb", and a T dimension of size 1 called 'time' with a value of "0 minutes since 2002-05-14 00:00".
<p>The coordinate variables will be  type 'double' and will have two default attributes ("units" and "long_name") with values that are based on the GrADS 5-dimensional gridded data model. The data variable will also be  type 'double' by default; beginning with version <span class="style1">2.0.a8</span>, you can also write out data of type 'float' if you use the <code>-flt</code> option with    <code><a href="gradcomdsetsdfwrite.html">set sdfwrite</a></code> command. Da [...]
  <code><a href="gradcomdsetundef.html">set undef</a></code> command.
<p>For example, if <code><i>varname</i></code> is called "testvar" and varies in X, Y, Z, T, and E, then the output file might have a NetCDF header that looks like this: 
<p><code>netcdf foo {<br>
  dimensions:<br>
  longitude = 9 ;<br>
  latitude = 9 ;<br>
  level = 9 ;<br>
  time = 9 ;<br>
  ensemble = 9 ;<br>
variables:<br>
  double longitude(longitude) ;<br>
     longitude:units = "degrees_east" ;<br>
     longitude:long_name = "Longitude" ;<br>
  double latitude(latitude) ;<br>
     latitude:units = "degrees_north" ;<br>
     latitude:long_name = "Latitude" ;<br>
  double level(level) ;<br>
     level:units = "millibar" ;<br>
     level:long_name = "Level" ;<br>
  double time(time) ;<br>
     time:units = "minutes since 01-01-0001 00:00" ;<br>
     time:long_name = "Time" ;<br>
  double ensemble(ensemble) ;<br>
     ensemble:grads_dim = "e" ;<br>
     ensemble:long_name = "Ensemble member" ;<br>
  double testvar(ensemble, time, level, latitude, longitude) ;<br>
     testvar:missing_value = -888. ;<br>
}
</code>
<p>The time axis units will always be "minutes since ..." and the date of the time axis origin will correspond to the initial time of the defined variable. 
<p>If the variable has an ensemble dimension, the attribute "grads_dim" with the value "e" will always be present so that the resulting output file can be opened with GrADS using the 'sdfopen' command. 
<p>To supplement or override the default attributes of the output file, use the <code><a href="gradcomdsetsdfattr.html">set sdfattr</a></code> command. 
<p>Beginning with version 2.0.a8, the output file may also be a compressed netCDF file. Use the <code>-zip</code> option with the <code><a href="gradcomdsetsdfwrite.html">set sdfwrite</a></code> command to enable compression. Please see the documentation on <a href="compression.html">compression</a> for  more details.
<h3>Examples </h3>

<p>
The following commands produce a regional subset of a global precip forecast :</p>
  <pre>open gfs.ctl
set lon -111.3 -103.8 
set lat 40.9 45.0 
set t 1 last
define precip = ptot
set sdfwrite wyoming_precip.nc
sdfwrite precip</pre>
    


<p><em><strong>Appending Variables to a File</strong></em><br>
  The sdfwrite command does not allow you to write out more than one variable to a file. The way to do achieve this is to write out each variable in a separate file, then merge them with  the <a href="http://nco.sourceforge.net/nco.html" target="_blank">NetCDF Operators (NCO)</a>. Use the <a href="http://nco.sourceforge.net/nco.html#ncks" target="_blank"><code>ncks</code></a> command to append variables defined on the same grid. The GrADS commands might look like this: 
<pre>
open gfs.ctl
set x 1 720
set y 1 361
set t 1 last
define slp = mslp
define precip = ptot
set sdfwrite -flt slp.nc
sdfwrite slp
sdt sdfwrite -flt precip.nc
sdfwrite precip
</pre>
Then, outside GrADS, or using the ! in front of the command to send it to the shell from within GrADS, merge these two files with <a href="http://nco.sourceforge.net/nco.html#ncks" target="_blank"><code>ncks</code></a>: 
<pre><a href="http://nco.sourceforge.net/nco.html#ncks" target="_blank">ncks</a> -O -h -A precip.nc slp.nc</pre>
<p>The -A is for appending to the output file, the -O is for overwriting existing output file, and the -h does not add anything to the output file's global 'history' attribute. Please see the <a href="http://nco.sourceforge.net/nco.html" target="_blank">NCO User's Guide</a> for more information. 
<p><em><strong>Concatenating Files</strong></em><br>
  Suppose you want to write out a long time series with the sdfwrite command, but your system does not have enough memory to define the whole grid. Use GrADS to write out the data in smaller time segments (e.g. one year, or one month, or one day), and then concatenate them together with the 
    <a href="http://nco.sourceforge.net/nco.html" target="_blank">NetCDF Operators (NCO)</a>. After you have created the separate files with GrADS, use the <a href="http://nco.sourceforge.net/nco.html#ncks" target="_blank"><code>ncks</code></a> command to change the time dimension to a record dimension, then use the <a href="http://nco.sourceforge.net/nco.html#ncrcat" target="_blank"><code>ncrcat</code></a> command to concatenate them together. The GrADS commands might look like  this: 
<pre>
open long_time_series.ctl
set x 1 720
set y 1 361
set time 01jan2001 31dec2001
define slp = mslp
set sdfwrite -flt slp_2001.nc
sdfwrite slp
set time 01jan2002 31dec2002
define slp = mslp
set sdfwrite -flt slp_2002.nc
sdfwrite slp
set time 01jan2003 31dec2003
define slp = mslp
set sdfwrite -flt slp_2003.nc
sdfwrite slp
</pre>
Then, outside GrADS, or using the ! in front of the command to send it to the shell from within GrADS, modify the time dimension with <a href="http://nco.sourceforge.net/nco.html#ncks" target="_blank"><code>ncks</code></a>, then concatenate with <a href="http://nco.sourceforge.net/nco.html#ncrcat" target="_blank"><code>ncrcat</code></a>: 
<pre><a href="http://nco.sourceforge.net/nco.html#ncks" target="_blank">ncks</a> -O -h --mk_rec_dmn time slp_2001.nc
<a href="http://nco.sourceforge.net/nco.html#ncks" target="_blank">ncks</a><a href="http://nco.sourceforge.net/nco.html#ncks"></a> -O -h --mk_rec_dmn time slp_2002.nc
<a href="http://nco.sourceforge.net/nco.html#ncks" target="_blank">ncks</a><a href="http://nco.sourceforge.net/nco.html#ncks"></a> -O -h --mk_rec_dmn time slp_2003.nc
<a href="http://nco.sourceforge.net/nco.html#ncrcat" target="_blank">ncrcat</a> -O -h slp_2001.nc slp_2002.nc slp_2003.nc slp.nc</pre>
<p>The --mk_rec_dmn options modifies the time dimension,  the -O is for overwriting existing output file, and the -h does not add anything to the output file's global 'history' attribute. Please see the <a href="http://nco.sourceforge.net/nco.html" target="_blank">NCO User's Guide</a> for more information -- there are  shortcuts for <a href="http://nco.sourceforge.net/nco.html#ncrcat" target="_blank"><code>ncrcat</code></a> to specify the long list of files to concatenate. 
<p><span class="style1">N.B. (For compressed NetCDF-4 files): </span>If the NetCDF files you create with GrADS are compressed netCDF-4 format, then you must use NCO version 4.0.4 (or higher) in order to maintain the compression in the output files. The chunk sizes may also be altered by ncks or ncrcat. Use the --cnk_dmn option to specify the name and chunk size of each dimension to manually override the defaults. For example: 
<pre><a href="http://nco.sourceforge.net/nco.html#ncrcat" target="_blank">ncrcat </a>-O -h --cnk_dmn lev,1 --cnk_dmn lat,361 --cnk_dmn lon,720 slp_2001.nc slp_2002.nc slp_2003.nc slp.nc</pre>
</body>
</html>

\ No newline at end of file
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
+
+<html>
+<head>
+<title>GrADS Commands: sdfwrite</title>
+<style type="text/css">
+<!--
+.style1 {color: #990000}
+-->
+</style>
+</head>
+<body bgcolor="e0f0ff" text="#000000">
+
+<h2><b>sdfwrite</b></h2>
+<p><code>sdfwrite <i>varname </i></code>
+<p>This<code></code> command will write out a defined variable <code><i>varname </i></code>into a NetCDF formatted
+  data file.  
+
+<ul>
+  <p> </p>
+</ul>
+<h3>Usage Notes</h3>
+
+<p>
+The <code>sdfwrite</code> command was initially implemented in GrADS version <span class="style1">2.0.a3</span>. Additional features added in subsequent releases are as follows:
+<ul>
+  <li>(<span class="style1">2.0.a5</span>) NetCDF output may be forced to have 4 or 5 dimensions. </li>
+  <li>(<span class="style1">2.0.a8</span>) NetCDF output may be floating point or double precision. NetCDF output may also be version 4, with chunking and compression enabled. </li>
+  <li>(<span class="style1">2.0.a9</span>) If the output is not forced to have 4 or 5 dimensions, it will have the same number of dimensions as the defined variable being written out to file. </li>
+  <li>(<span class="style1">2.1.a1</span>) New options were added to set a record (unlimited) dimension and to force the output to have 3 dimensions. </li>
+</ul>
+<p>Options to control the name and format of the output file are implemented with the <code><a href="gradcomdsetsdfwrite.html">set sdfwrite</a></code> command. The <a href="gradcomdqsdfwrite.html"><code>q sdfwrite</code></a> command
+  returns the status of the <code>sdfwrite</code> options. 
+
+<p>The name of the output file will be <code>grads.sdfwrite.nc</code> unless specified otherwise with the <code><a href="gradcomdsetsdfwrite.html">set sdfwrite</a></code> command. If the 
+file exists, it will be replaced.  It is not possible to append variables to an existing file.  
+<p>The dimensions of the variable written to file correspond to the dimension environment that was set when the variable was  defined. The dimension environment that is set when the 'sdfwrite' command is invoked is ignored. Note this behavior is different from the fwrite command.
+<p>By default, the output file will have a coordinate variable only for  varying dimensions in the defined variable; non-varying dimensions will not appear as a coordinate variable with a size of 1. However, options have been added to the  <code><a href="gradcomdsetsdfwrite.html">set sdfwrite</a></code> command to  force the variable in the output file to have at least 3, 4, or all 5 dimensions. When either of these options to   <code><a href="gradcomdsetsdfwrite.html">set sdfwrite</a></ [...]
+For example, if your defined variable is 500mb height on14may2002 (a 2D variable that varies only in lon and lat), and you use the -4d option, the output file with show height as a 4D variable with a Z dimension of size 1 called 'lev' with a value "500 mb", and a T dimension of size 1 called 'time' with a value of "0 minutes since 2002-05-14 00:00".
+<p>The coordinate variables will be  type 'double' and will have two default attributes ("units" and "long_name") with values that are based on the GrADS 5-dimensional gridded data model. The data variable will also be  type 'double' by default; beginning with version <span class="style1">2.0.a8</span>, you can also write out data of type 'float' if you use the <code>-flt</code> option with    <code><a href="gradcomdsetsdfwrite.html">set sdfwrite</a></code> command. D [...]
+  <code><a href="gradcomdsetundef.html">set undef</a></code> command.
+<p>For example, if <code><i>varname</i></code> is called "testvar" and varies in X, Y, Z, T, and E, then the output file might have a NetCDF header that looks like this: 
+<p><code>netcdf foo {<br>
+  dimensions:<br>
+  longitude = 9 ;<br>
+  latitude = 9 ;<br>
+  level = 9 ;<br>
+  time = 9 ;<br>
+  ensemble = 9 ;<br>
+variables:<br>
+  double longitude(longitude) ;<br>
+     longitude:units = "degrees_east" ;<br>
+     longitude:long_name = "Longitude" ;<br>
+  double latitude(latitude) ;<br>
+     latitude:units = "degrees_north" ;<br>
+     latitude:long_name = "Latitude" ;<br>
+  double level(level) ;<br>
+     level:units = "millibar" ;<br>
+     level:long_name = "Level" ;<br>
+  double time(time) ;<br>
+     time:units = "minutes since 01-01-0001 00:00" ;<br>
+     time:long_name = "Time" ;<br>
+  double ensemble(ensemble) ;<br>
+     ensemble:grads_dim = "e" ;<br>
+     ensemble:long_name = "Ensemble member" ;<br>
+  double testvar(ensemble, time, level, latitude, longitude) ;<br>
+     testvar:missing_value = -888. ;<br>
+}
+</code>
+<p>The time axis units will always be "minutes since ..." and the date of the time axis origin will correspond to the initial time of the defined variable. 
+<p>If the variable has an ensemble dimension, the attribute "grads_dim" with the value "e" will always be present so that the resulting output file can be opened with GrADS using the 'sdfopen' command. 
+<p>To supplement or override the default attributes of the output file, use the <code><a href="gradcomdsetsdfattr.html">set sdfattr</a></code> command. 
+<p>Beginning with version 2.0.a8, the output file may also be a compressed netCDF file. Use the <code>-zip</code> option with the <code><a href="gradcomdsetsdfwrite.html">set sdfwrite</a></code> command to enable compression. Please see the documentation on <a href="compression.html">compression</a> for  more details.
+<h3>Examples </h3>
+
+<p>
+The following commands produce a regional subset of a global precip forecast :</p>
+  <pre>open gfs.ctl
+set lon -111.3 -103.8 
+set lat 40.9 45.0 
+set t 1 last
+define precip = ptot
+set sdfwrite wyoming_precip.nc
+sdfwrite precip</pre>
+    
+
+
+<p><em><strong>Appending Variables to a File</strong></em><br>
+  The sdfwrite command does not allow you to write out more than one variable to a file. The way to do achieve this is to write out each variable in a separate file, then merge them with  the <a href="http://nco.sourceforge.net/nco.html" target="_blank">NetCDF Operators (NCO)</a>. Use the <a href="http://nco.sourceforge.net/nco.html#ncks" target="_blank"><code>ncks</code></a> command to append variables defined on the same grid. The GrADS commands might look like this: 
+<pre>
+open gfs.ctl
+set x 1 720
+set y 1 361
+set t 1 last
+define slp = mslp
+define precip = ptot
+set sdfwrite -flt slp.nc
+sdfwrite slp
+sdt sdfwrite -flt precip.nc
+sdfwrite precip
+</pre>
+Then, outside GrADS, or using the ! in front of the command to send it to the shell from within GrADS, merge these two files with <a href="http://nco.sourceforge.net/nco.html#ncks" target="_blank"><code>ncks</code></a>: 
+<pre><a href="http://nco.sourceforge.net/nco.html#ncks" target="_blank">ncks</a> -h -A precip.nc slp.nc</pre>
+<p>The -A is for appending to the output file, and the -h does not add anything to the output file's global 'history' attribute. Please see the <a href="http://nco.sourceforge.net/nco.html" target="_blank">NCO User's Guide</a> for more information. 
+<p><em><strong>Concatenating Files</strong></em><br>
+  Suppose you want to write out a long time series with the sdfwrite command, but your system does not have enough memory to define the whole grid. Use GrADS to write out the data in smaller time segments (e.g. one year, or one month, or one day), and then concatenate them together with the 
+<a href="http://nco.sourceforge.net/nco.html" target="_blank">NetCDF Operators (NCO)</a>. Concatenation in the time dimension only works properly if time is defined to be a record (unlimited) dimension. If you are using GrADS version <span class="style1">2.1.a2+</span>, you can use the <code>-rt</code> option to set the time axes as a record  dimension; otherwise, you must use  the <a href="http://nco.sourceforge.net/nco.html#ncks" target="_blank"><code>ncks</code></a> command to change  [...]
+<pre>
+open long_time_series.ctl
+set x 1 720
+set y 1 361
+set time 01jan2001 31dec2001
+define slp = mslp
+set sdfwrite -flt slp_2001.nc
+sdfwrite slp
+set time 01jan2002 31dec2002
+define slp = mslp
+set sdfwrite -flt slp_2002.nc
+sdfwrite slp
+set time 01jan2003 31dec2003
+define slp = mslp
+set sdfwrite -flt slp_2003.nc<br>sdfwrite slp
+</pre>
+<p>If you are using GrADS version <span class="style1">2.1.a2+</span>, the 'set sdfwrite' commands should look like this instead:<br>
+<code>set sdfwrite -flt -rt slp_2001.nc<br>
+set sdfwrite -flt -rt slp_2001.nc<br>
+set sdfwrite -flt -rt slp_2001.nc</code></p>
+<p>If you are using an earlier verison of GrADS, you must modify the time dimension with <a href="http://nco.sourceforge.net/nco.html#ncks" target="_blank"><code>ncks</code></a> -- do this outside of GrADS, or use the ! in front of the command to send it to the shell from within GrADS (the --mk_rec_dmn option modifies the time dimension): 
+</p>
+<pre><a href="http://nco.sourceforge.net/nco.html#ncks" target="_blank">ncks</a> -O -h --mk_rec_dmn time slp_2001.nc
+<a href="http://nco.sourceforge.net/nco.html#ncks" target="_blank">ncks</a><a href="http://nco.sourceforge.net/nco.html#ncks"></a> -O -h --mk_rec_dmn time slp_2002.nc
+<a href="http://nco.sourceforge.net/nco.html#ncks" target="_blank">ncks</a><a href="http://nco.sourceforge.net/nco.html#ncks"></a> -O -h --mk_rec_dmn time slp_2003.nc</pre>
+
+<p>Now you are ready to concatenate the files with <a href="http://nco.sourceforge.net/nco.html#ncrcat" target="_blank"><code>ncrcat</code></a>:
+<p><code><a href="http://nco.sourceforge.net/nco.html#ncrcat" target="_blank">
+  ncrcat</a> -O -h slp_2001.nc slp_2002.nc slp_2003.nc slp.nc</code>
+<p>The    -O is for overwriting existing output file, and the -h does not add anything to the output file's global 'history' attribute. Please see the <a href="http://nco.sourceforge.net/nco.html" target="_blank">NCO User's Guide</a> for more information -- there are  shortcuts for <a href="http://nco.sourceforge.net/nco.html#ncrcat" target="_blank"><code>ncrcat</code></a> to specify the long list of files to concatenate. 
+<p><span class="style1">N.B. (For compressed NetCDF-4 files): </span>If the NetCDF files you create with GrADS are compressed netCDF-4 format, then you must use NCO version 4.0.4 (or higher) in order to maintain the compression in the output files. The chunk sizes may also be altered by ncks or ncrcat. Use the --cnk_dmn option to specify the name and chunk size of each dimension to manually override the defaults. For example: 
+<pre><a href="http://nco.sourceforge.net/nco.html#ncrcat" target="_blank">ncrcat </a>-O -h --cnk_dmn lev,1 --cnk_dmn lat,361 --cnk_dmn lon,720 slp_2001.nc slp_2002.nc slp_2003.nc slp.nc</pre>
+</body>
+</html>
+
diff --git a/doc/gradcomdsetantialias.html b/doc/gradcomdsetantialias.html
new file mode 100644
index 0000000..94e9c5c
--- /dev/null
+++ b/doc/gradcomdsetantialias.html
@@ -0,0 +1,18 @@
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
+<style type="text/css">
+.red {
+	color: #900;
+}
+body {
+	background-color: #e0f0ff;
+}
+</style>
+
+
+<H2><B>set antialias</B></H2>
+<P><code>set antialias on</code> | <code>off</code>
+<p>This command, which is available in <span class="red">GrADS version 2.1+</span>, allows the user to disable or enable anti-aliasing. </p>
+<h3>Usage Notes</h3>
+<p>When using GrADS version 2.1+ with the Cairo graphics library, <a href="http://en.wikipedia.org/wiki/Spatial_anti-aliasing" target="_blank">anti-aliasing</a> is enabled  by default. This command does not "stick" -- anti-aliasing resets to "<code>on</code>" with <code><a href="gradcomdclear.html">clear</a></code>, <code><a href="gradcomdreset.html">reset</a></code>, and <code><a href="gradcomdreinit.html">reinit</a></code>. For some applications it may be desireable [...]
+<P>
+<P>
\ No newline at end of file
diff --git a/doc/gradcomdsetbackground.html b/doc/gradcomdsetbackground.html
index 54dacaf..47f09af 100644
--- a/doc/gradcomdsetbackground.html
+++ b/doc/gradcomdsetbackground.html
@@ -1,7 +1,16 @@
-<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
+<style type="text/css">
+body {
+	background-color: #e0f0ff;
+}
+</style>
+
 
 <h2>set background</h2>
-<code>set background <i>index</i></code><p>
-set background color to color or color <code><i>index</i></code>
-<h3>Usage</h3>
-<h3>Notes</h3>
+<p><code>set background<i> color#</i></code></p>
+<p>Sets the background color to<code><i> color#</i></code>. </p>
+<h3>Usage Notes</h3> 
+<ol>
+  <li>This command is used instead of<code> <a href="gradcomdsetdisplay.html">set display</a> </code>when a color other than black or white is desired for the background color.</li>
+  <li>The new background is not drawn until a<code> <a href="gradcomdclear.html">clear</a> </code>command is issued.</li>
+  <li>If you use <code>set background</code>, then the options '<code>black</code>' and '<code>white</code>' for the <code><a href="gradcomdgxprint.html">gxprint</a></code> command cannot be used to override the background color. </li>
+</ol>
diff --git a/doc/gradcomdsetccols.html b/doc/gradcomdsetccols.html
index 60711bc..1ce6f93 100644
--- a/doc/gradcomdsetccols.html
+++ b/doc/gradcomdsetccols.html
@@ -1,44 +1 @@
-<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
-
-<html>
-<head>
-<title>GrADS Command: set ccols</title>
-<style type="text/css">
-<!--
-.style1 {color: #990000}
-body {
-	background-color: #e0f0ff;
-}
--->
-</style>
-<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
-</head>
-<body text="#000000">
-
-<h2><b>set ccols</b></h2>
-<p>
-<code>set ccols <i>col1 col2 col3 ... colN</i></code>
-
-<p>
-Sets specific color numbers for contour levels specified by <a
-href="gradcomdsetclevs.html"><code>set clevs</code></a>. 
-<p>
-<h3>Usage Notes</h3>
-<ol>
-<li>
-Contour colors are reset with every execution of <a
-href="gradcomdclear.html"><code>clear</code></a> or <a
-href="gradcomddisplay.html"><code>display</code></a>.
-<li>User-specified ccols won't take effect unless clevs are also set.
-<li>If any of the color numbers is < 0, it is set to 0 (the background color).
-
-<li>(<span class="style1">Version 2.0.0+</span>) When using 'gxout shade2' or 'gxout shade2b', if any of the color numbers is < 0, the contour is not drawn (i.e., it is effectively transparent).
-<li>See section of User's Guide on <a href="colorcontrol.html">controlling colors in Grads</a> for more details.
-</ol>
-
-<p>
-<h3>Examples </h3>
-
-
-</body>
-</html>
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->

<html>
<head>
<title>GrADS Command: set ccols</title>
<style type="text/css">
<!--
.style1 {color: #990000}
-->
</style>
</head>
<body bgcolor="e0f0ff" text="#000000">

<h2><b>set ccols</b></h2>
<p>
<code>set ccols <i>col1 col2 col3 ... colN</i></code>

<p>
Sets specific color numbers for contour levels specified by <a
href="gradcomdsetclevs.html"><code>set clevs</code></a>. 
<p>
<h3>Usage Notes</h3>
<ol>
<li>
Contour colors are reset with every execution of <a
href="gradcomdclear.html"><code>clear</code></a> or <a
href="gradcomddisplay.html"><code>display</code></a>.
<li>User-specified ccols won't take effect unless clevs are also set.
<li>If any of the color numbers is < 0, it is set to 0 (the background color).

<li>(<span class="style1">Version 2.0.0+</span>) When using 'gxout shade2' or 'gxout shade2b', if any of the color numbers is < 0, the contour is not drawn (i.e., it is effectively transparent).
<li>See section of User's Guide on <a href="colorcontrol.html">controlling colors in Grads</a> for more details.
</ol>

<p>
<h3>Examples </h3>


</body>
</html>
\ No newline at end of file
diff --git a/doc/gradcomdsetdefval.html b/doc/gradcomdsetdefval.html
index ce0a50d..0c96e17 100644
--- a/doc/gradcomdsetdefval.html
+++ b/doc/gradcomdsetdefval.html
@@ -1,107 +1 @@
-<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
-
-<html>
-<head>
-<title>GrADS Command: set defval</title>
-</head>
-<body text="#000000" bgcolor="e0f0ff">
-
-<h2><b>set defval</b></h2>
-
-<p>
-This command is used to interactively modify grid point values for
-2-dimensional <a href="gradcomddefine.html"><code>defined</code></a>
-variables. It is generally used in conjunction with <a
-href="gradcomdquery.html"><code>query defval</code></a>. The syntax is:
-<p>
-<ul><code>set defval <i>var ival jval value</i></code></ul>
-
-<p>
-where:
-<ul>
-<code><i>var</i>    </code>- the 2-D defined variable<br>
-<code><i>ival</i>   </code>- X coordinate of the grid point<br>
-<code><i>jval</i>   </code>- Y coordinate of the grid point<br>
-<code><i>value</i>  </code>- the new value for the variable, or "missing" to set variable as undefined<br>
-</ul>
-
-<p>
-<h3>Usage Notes</h3>
-<p>
-<ol>
-<li>A typical application of <code>set defval</code> might be to correct the value of an isolated bad data value discoverd through a maskout operation. 
-</ol>
-
-<p>
-<h3>Examples </h3>
-
-<p>'set defval var 8 22 missing' </p>
-<p>Here is a sample script <a
-href="ftp://cola.gmu.edu/grads/scripts/defval_demo.gs">defval_demo.gs</a>
-  that illustrates the use of <code>query defval</code> and <code>set
-    defval</code> commands.
-</p>
-<pre>
-'open model.ctl'
-
-* restrict the dimension environment to see things more clearly
-xmin =  0.5
-xmax = 15.5
-ymin =  0.5
-ymax = 10.5
-'set x 'xmin' 'xmax
-'set y 'ymin' 'ymax
-
-* the "defval" commands will only work with 2-D defined variables 
-'define var = ps'
-
-* Display the variable with colored grid cells and their values
-'c'
-'set grid off'
-'set mproj off'
-'set xaxis 'xmin' 'xmax
-'set yaxis 'ymin' 'ymax
-'set gxout grfill'
-'d var'
-'set gxout grid'
-'set digsiz .14'
-'d var'
-
-* Use the mouse to click on a grid point to change
-say 'Click on any grid point'
-'q pos'
-xscreen = subwrd(result,3)
-yscreen = subwrd(result,4)
-
-* Convert screen positions to grid coordinates
-'q xy2gr 'xscreen' 'yscreen
-xgrid = subwrd(result,3)
-ygrid = subwrd(result,6)
-
-* Round the grid values to the nearest integer
-gx = math_nint(xgrid)
-gy = math_nint(ygrid)
-
-* Get the value of the defined variable 
-'q defval var 'gx' 'gy
-val = subwrd(result,3)
-say 'The value at grid point ('gx','gy') is --> 'val
-
-* Ask for a new replacement value and assign it
-prompt 'Enter a new value --> ' 
-pull newval
-'set defval var 'gx' 'gy' 'newval
-
-* Display the newly updated variable
-'c'
-'set xaxis 'xmin' 'xmax
-'set yaxis 'ymin' 'ymax
-'set gxout grfill'
-'d var'
-'set gxout grid'
-'d var'
-</pre>
-
-</body>
-</html>
-
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->

<html>
<head>
<title>GrADS Command: set defval</title>
</head>
<body text="#000000" bgcolor="e0f0ff">

<h2><b>set defval</b></h2>

<p>
This command is used to interactively modify grid point values for
2-dimensional <a href="gradcomddefine.html"><code>defined</code></a>
variables. It is generally used in conjunction with <a
href="gradcomdquery.html"><code>query defval</code></a>. The syntax is:
<p>
<ul><code>set defval <i>var ival jval value</i></code></ul>

<p>
where:
<ul>
<code><i>var</i>    </code>- the 2-D defined variable<br>
<code><i>ival</i>   </code>- X coordinate of the grid point<br>
<code><i>jval</i>   </code>- Y coordinate of the grid point<br>
<code><i>value</i>  </code>- the new value for the variable, or "missing" to set variable as undefined<br>
</ul>

<p>
<h3>Usage Notes</h3>
<p>
<ol>
<li>A typical application of <code>set defval</code> might be to correct the value of an isolated bad data value discoverd through a maskout operation. 
</ol>

<p>
<h3>Examples </h3>

<p>'set defval var 8 22 missing' </p>
<p>Here is a sample script <a
href="ftp://grads.iges.org/grads/scripts/defval_demo.gs">defval_demo.gs</a>
  that illustrates the use of <code>query defval</code> and <code>set
    defval</code> commands.
</p>
<pre>
'open model.ctl'

* restrict the dimension environment to see things more clearly
xmin =  0.5
xmax = 15.5
ymin =  0.5
ymax = 10.5
'set x 'xmin' 'xmax
'set y 'ymin' 'ymax

* the "defval" commands will only work with 2-D defined variables 
'define var = ps'

* Display the variable with colored grid cells and their values
'c'
'set grid off'
'set mproj off'
'set xaxis 'xmin' 'xmax
'set yaxis 'ymin' 'ymax
'set gxout grfill'
'd var'
'set gxout grid'
'set digsiz .14'
'd var'

* Use the mouse to click on a grid point to change
say 'Click on any grid point'
'q pos'
xscreen = subwrd(result,3)
yscreen = subwrd(result,4)

* Convert screen positions to grid coordinates
'q xy2gr 'xscreen' 'yscreen
xgrid = subwrd(result,3)
ygrid = subwrd(result,6)

* Round the grid values to the nearest integer
gx = math_nint(xgrid)
gy = math_nint(ygrid)

* Get the value of the defined variable 
'q defval var 'gx' 'gy
val = subwrd(result,3)
say 'The value at grid point ('gx','gy') is --> 'val

* Ask for a new replacement value and assign it
prompt 'Enter a new value --> ' 
pull newval
'set defval var 'gx' 'gy' 'newval

* Display the newly updated variable
'c'
'set xaxis 'xmin' 'xmax
'set yaxis 'ymin' 'ymax
'set gxout grfill'
'd var'
'set gxout grid'
'd var'
</pre>

</body>
</html>

\ No newline at end of file
diff --git a/doc/gradcomdsetfont.html b/doc/gradcomdsetfont.html
index 79caaf1..0702909 100644
--- a/doc/gradcomdsetfont.html
+++ b/doc/gradcomdsetfont.html
@@ -1 +1,68 @@
-<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.--><title>GrADS command: set font</title><style type="text/css">
<!--
body {
	background-color: #e0f0ff;
}
-->
</style>

<H2><B>set font</B></H2><P>
<code>set font <i>number</i></code>
<p>
Selects the font for subsequent text operations, where:
<code>number=0...5</code>.<p>
<H3>Usage Note</H3>
<P>It is also possible to <a href="fontcontrol.html">override the  font  in a string of text by using the back quote character (`).  
</a>
<P>For information about how the Hershey font files are created, see <a href="font.html">font file format</a>.
<H3>Examples</H3><P>
\ No newline at end of file
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.--><title>GrADS command: set font</title><style type="text/css">
+<!--
+body {
+	background-color: #e0f0ff;
+}
+.style1 {color: #990000}
+.red {
+	color: #900;
+}
+.red {
+	color: #900;
+}
+.red {
+	color: #900;
+}
+.red {
+	color: #900;
+}
+.bold {
+	font-weight: bold;
+	font-style: italic;
+}
+.bold {
+	font-style: italic;
+}
+.bold {
+	font-weight: bold;
+}
+-->
+</style>
+
+<H2><B>set font</B></H2>
+<P>This command allows the user to select the font for subsequent text operations. This command was enhanced for version 2.1, when new font controls were introduced with the addition of  graphics rendering using the Cairo library. 
+<h3>Syntax
+</h3>
+<P><code>set font <i>number</i>                     </code>(<span class="red">GrADS version 2.0* and earlier</span>)<br />
+  <code>set font <i>number</i> <file <i>filename</i>>     </code>(<span class="red">GrADS version 2.1* and later</span>)
+<p>
+<H3>Usage Notes</H3>
+<P>Use font <code><i>number</i></code> 0 through 5 to specify which Hershey font to use. <br />
+Use font <code><i>number</i></code> 6 through 9 for customized font files. See <a href="font.html">Hershey Font Files</a> for more information on how to create these files.<br />
+For all GrADS versions 2.0 and earlier, 0-9 are the only font numbers that are available. 
+<p>Starting with <span class="red">GrADS version 2.1</span>, additional font numbers 10 through 99 are available to <span class="bold">define</span> or <span class="bold">set</span> a Cairo font based on a local font file. When <span class="bold">defining</span> a new font, use the <code>'set font <i>number</i> file <i>filename</i>'</code> syntax. Make sure you include the <code>file</code> keyword followed by the  filename of the local font file, including its full path. Spaces are allo [...]
+<p>If<code> 'set font <i>number</i>' </code>is invoked with a <code><i>number</i></code> between 10 and 99, but that font <code><i>number</i></code> has not yet been defined, a default generic sans-serif font will be used. Similarly, if a user-specified font file cannot be opened or is in an unsupported format, then the display will default to a generic sans-serif font.</p>
+<P>Please read the documentation page on <a href="fontcontrol.html">Font Control in GrADS</a> for more information about using fonts in GrADS version 2.1. 
+<P>It is  possible to <a href="fontcontrol.html">temporarily override the  font</a>  in a string of text by using the back quote character (`) followed by a single-digit font number. To override fonts with 2-digit font numbers, use  back quote with an f (`f) followed by the font number. Examples are below.
+<P>If your build of <span class="red">GrADS version 2.1+</span> is not enabled with the Cairo graphics library, you will get an error message if you use <code><a href="gradcomdsetfont.html">set font</a></code> to try to set a font number greater than 9.
+
+<p> </p>
+<h3>Examples</h3>
+<pre>
+  set font 10 file /Library/Fonts/AmericanTypewriter.ttc<br />  set font 11 file /Library/Fonts/Kannada MN.ttc
+  set font 12 file /System/Library/Fonts/AppleGothic.ttf
+  set font 13 file /usr/share/fonts/default/Type1/a010013l.pfb
+  set font 14 file /usr/share/msttcorefonts/tahoma.ttf
+  set font 15 file /usr/share/X11/fonts/TTF/luximbi.ttf
+
+  set font 20 file /usr/share/fonts/default/ghsostcript/bchr.pfa
+  set font 21 file /usr/share/fonts/default/ghsostcript/bchri.pfa
+  set font 22 file /usr/share/fonts/default/ghsostcript/bchb.pfa
+  set font 23 file /usr/share/fonts/default/ghsostcript/bchbi.pfa
+
+  set font 20
+  draw string 1 1 For emphasizing text, use `f22bold, `f21italic, `f20or `f23both
+
+  set font 0
+  draw string 1 1 `1Use Hershey font 2 to `2emphasize `1a particular word 
+  </pre>
diff --git a/doc/gradcomdsetgxout.html b/doc/gradcomdsetgxout.html
index 88e32b6..e82d7d7 100644
--- a/doc/gradcomdsetgxout.html
+++ b/doc/gradcomdsetgxout.html
@@ -1,178 +1 @@
-<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
-
-<html>
-<head>
-<title>GrADS Command: set gxout</title>
-<style type="text/css">
-<!--
-.style1 {color: #990000}
-body {
-	background-color: #e0f0ff;
-}
-.red {
-	color: #900;
-}
--->
-</style>
-<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
-</head>
-<body text="#000000">
-
-<h2><b>set gxout</b></h2>
-<p>
-<code>set gxout <i>graphics_type</i></code>
-
-<p>
-Where <code><i>graphics_type</i></code> can be one of the following:
-<ul>
-
-<code>bar       </code>
-Bar chart (The <a href="library.html">library</a> contains an <a href="ftp://cola.gmu.edu/grads/scripts/box_and_whisker.gs">example script</a> demonstrating how to use gxout bar and errbar)<br>
-
-<code>barb      </code>
-Wind barbs <br>
-
-<code>contour   </code>
-Contour plot<br>
-
-<code>errbar    </code>
-Error bars (The <a href="library.html">library</a> contains an <a href="ftp://cola.gmu.edu/grads/scripts/box_and_whisker.gs">example script</a> demonstrating how to use gxout bar and errbar)<br>
-
-<code>geotiff   </code>
- (<span class="style1">2.0.a5+</span>) Generates a GeoTIFF format data file; options specified by <code><a href="gradcomdsetgeotiff.html">set geotiff</a></code><br>
-
-<code>grfill    </code>
-Shaded grid boxes<br>
-
-<code>fgrid     </code>
-Shaded grid boxes with values specified by 
-<a href="gradcomdsetfgvals.html"><code>set fgvals</code></a><br>
-
-<code>fwrite    </code>
-Writes data to file instead of drawing a plot; options specified by <code><a href="gradcomdsetfwrite.html">set fwrite</a></code><br>
-
-<code>grid      </code>
-Grid boxes with printed values<br> 
-<code>imap      </code>
-(<span class="style1">2.0.a8+</span>) Quickly drawn shaded grid boxes. No metafile, so no hard copy; image output only with <code><a href="gradcomdoutxwd.html">outxwd</a></code>.<br> 
-<code>kml       </code>
- (<span class="style1">2.0.a5+</span>) Generates a TIFF  image file and a KML  text file; options specified by <code><a href="gradcomdsetkml.html">set kml</a></code><br>
-
-<code>line      </code>
-Line Graph <br>
-
-<code>linefill  </code>
-Color fill between two lines <br>
-
-<code>print     </code>
-Generates ascii output for anything displayed; controlled by
-<a href="gradcomdsetprnopts.html"><code>set prnopts</code></a><br>
-
-<code>scatter   </code> Generates a <a href="scatterplot.html">scatter diagram</a>. Requires two grid expressions as arguments, separated by a semicolon. See Usage Note #2 below.<br>
-
-<code>shaded    </code>
-Shaded contour plot, alias for original algorithm (shade1)<br> 
-<code>shade1    </code>
-(<span class="style1">2.0.0+</span>) Shaded contour plot, original  algorithm<br> 
-<code>shade2    </code>
-(<span class="style1">2.0.0+</span>) Shaded contour plot, new algorithm, polygons merged to be larger and fewer in number (faster to render)<br> 
-<code>shade2b   </code>
-(<span class="style1">2.0.0+</span>) Shaded contour plot, new algorithm, polygons all on sub-grid scale (slower to render)<br> 
-
-<code>shp       </code>
-(<span class="style1">2.0.a9+</span>) Generates a shapefile; options specified by <code><a href="gradcomdsetshp.html">set shp</a></code><br> 
-
-<code>stream    </code>
-Wind streamlines <br>
-
-<code>stat      </code>
-Prints statistical output to terminal instead of drawing a plot<br>
-
-<code>vector    </code>
-Wind vector arrows<br>
-</ul>
-<p>
-For station data, these additional graphics output types are also available:
-<ul>
-<code>findstn   </code>
-Finds nearest station<br> 
-
-<code>model     </code>
-Plots station model<br>
-
-<code>stnmark   </code>
-Plots a mark at station location that is colorized by data value<br>
-
-<code>tserbarb  </code>
-Time series of wind barbs at a point (1-D)<br>
-
-<code>tserwx    </code>
-Time series of weather symbols at a point (1-D)<br>
-
-<code>value     </code>
-Plots station values<br> 
-
-<code>wxsym     </code>
-Plots weather symbols at station, controlled by 
-<a href="gradcomdsetwxopt.html"><code>set wxopt</code></a><br> 
-</ul>
-
-<p>
-<h3>Usage Notes</h3>
-<ol>
-  <p> 
-  <li>For the graphics output types <code>vector, stream, </code>and <code>barb</code>, 
-    the plotting routines need two result grids, where the first result grid is 
-    treated as the U component, and the second result grid is treated as the V 
-    component. These two result grids are provided with the <a href="gradcomddisplay.html">display</a> 
-    command by entering two expressions separated by a semicolon:
-    <ul>
-      <code> display u ; v<br>
-      display ave(u,t=1,t=10) ; ave(v,t=1,t=10)</code> 
-    </ul>
-    <p> 
-  <li>For the graphics output types <code>vector</code> and <code>stream</code>, 
-    you can specify a third  grid expression that will be used to colorize the vectors 
-    or streamlines:
-    <ul>
-      <code> display u ; v ; mag(u,v)<br>
-        display u ; v ; hcurl(u,v)</code> 
-    </ul>
-    Beginning with <span class="red">GrADS version 2.0.2</span>, the graphics output type <code>scatter</code> will also take a third grid expression to colorize the points in the scatter diagrm.
-<p> 
-  <li>To draw a 1-D time series with graphics output types vector or barb, set 
-    the dimension environment so that only time is varying, then :
-    <ul>
-      <code> display const(u,0); u ; v </code> 
-    </ul>
-    <p> 
-  <li>For the graphics output type <code>wxsym</code>, each value at a station 
-    location is assumed to be a wx symbol code number. To see a chart of all available 
-    wx symbols and their corresponding code numbers, run the sample script <code>wxsym.gs</code>. 
-    <p> 
-  <li>The graphics output type <code>findstn</code> requires three arguments to 
-    be provided with the <a
-href="gradcomddisplay.html"><code>display</code></a> command. The first argument 
-    is a station data expression. The 2nd and 3rd arguments are the X and Y screen 
-    coordinates of the of the desired search location. GrADS will find the station 
-    closest to the specified X and Y position, and print its stid, lon, and lat. 
-    This graphics output type should only be used when X and Y are the varying 
-    dimensions and AFTER a regular display command (that results in graphics output) 
-    is entered. 
-    <p> 
-  <li>For the graphics output type <code>stnmark</code>, the size and style of 
-    the mark are controled by <a href="gradcomdsetdigsiz.html"><code>set digsiz</code></a> 
-    and <a href="gradcomdsetcmark.html"><code>set cmark</code></a>. To turn off 
-    rainbow colorizing and use a single color instead, use <code><a href="gradcomdsetccolor.html">set 
-    ccolor</a> <i>color#</i></code>. 
-</ol>
-
-<p>
-<h3>Examples </h3>
-
-  The <a href="library.html">library</a> contains an <a href="ftp://cola.gmu.edu/grads/scripts/box_and_whisker.gs">example script</a> demonstrating how to use gxout bar and errbar
-
-<p> </p>
-</body>
-</html>
-
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->

<html>
<head>
<title>GrADS Command: set gxout</title>
<style type="text/css">
<!--
.style1 {color: #990000}
-->
</style>
</head>
<body bgcolor="e0f0ff" text="#000000">

<h2><b>set gxout</b></h2>
<p>
<code>set gxout <i>graphics_type</i></code>

<p>
Where <code><i>graphics_type</i></code> can be one of the following:
<ul>

<code>bar       </code>
Bar chart (The <a href="library.html">library</a> contains an <a href="ftp://iges.org/grads/scripts/box_and_whisker.gs">example script</a> demonstrating how to use gxout bar and errbar)<br>

<code>barb      </code>
Wind barbs <br>

<code>contour   </code>
Contour plot<br>

<code>errbar    </code>
Error bars (The <a href="library.html">library</a> contains an <a href="ftp://iges.org/grads/scripts/box_and_whisker.gs">example script</a> demonstrating how to use gxout bar and errbar)<br>

<code>geotiff   </code>
 (<span class="style1">2.0.a5+</span>) Generates a GeoTIFF format data file; options specified by <code><a href="gradcomdsetgeotiff.html">set geotiff</a></code><br>

<code>grfill    </code>
Shaded grid boxes<br>

<code>fgrid     </code>
Shaded grid boxes with values specified by 
<a href="gradcomdsetfgvals.html"><code>set fgvals</code></a><br>

<code>fwrite    </code>
Writes data to file instead of drawing a plot; options specified by <code><a href="gradcomdsetfwrite.html">set fwrite</a></code><br>

<code>grid      </code>
Grid boxes with printed values<br> 
<code>imap      </code>
(<span class="style1">2.0.a8+</span>) Quickly drawn shaded grid boxes. No metafile, so no hard copy; image output only with <code><a href="gradcomdoutxwd.html">outxwd</a></code>.<br> 
<code>kml       </code>
 (<span class="style1">2.0.a5+</span>) Generates a TIFF  image file and a KML  text file; options specified by <code><a href="gradcomdsetkml.html">set kml</a></code><br>

<code>line      </code>
Line Graph <br>

<code>linefill  </code>
Color fill between two lines <br>

<code>print     </code>
Generates ascii output for anything displayed; controlled by
<a href="gradcomdsetprnopts.html"><code>set prnopts</code></a><br>

<code>scatter   </code>
Scatter plot<br>

<code>shaded    </code>
Shaded contour plot, alias for original algorithm (shade1)<br> 
<code>shade1    </code>
(<span class="style1">2.0.0+</span>) Shaded contour plot, original  algorithm<br> 
<code>shade2    </code>
(<span class="style1">2.0.0+</span>) Shaded contour plot, new algorithm, polygons merged to be larger and fewer in number (faster to render)<br> 
<code>shade2b   </code>
(<span class="style1">2.0.0+</span>) Shaded contour plot, new algorithm, polygons all on sub-grid scale (slower to render)<br> 

<code>shp       </code>
(<span class="style1">2.0.a9+</span>) Generates a shapefile; options specified by <code><a href="gradcomdsetshp.html">set shp</a></code><br> 

<code>stream    </code>
Wind streamlines <br>

<code>stat      </code>
Prints statistical output to terminal instead of drawing a plot<br>

<code>vector    </code>
Wind vector arrows<br>
</ul>
<p>
For station data, these additional graphics output types are also available:
<ul>
<code>findstn   </code>
Finds nearest station<br> 

<code>model     </code>
Plots station model<br>

<code>stnmark   </code>
Plots a mark at station location that is colorized by data value<br>

<code>tserbarb  </code>
Time series of wind barbs at a point (1-D)<br>

<code>tserwx    </code>
Time series of weather symbols at a point (1-D)<br>

<code>value     </code>
Plots station values<br> 

<code>wxsym     </code>
Plots weather symbols at station, controlled by 
<a href="gradcomdsetwxopt.html"><code>set wxopt</code></a><br> 
</ul>

<p>
<h3>Usage Notes</h3>
<ol>
  <p> 
  <li>For the graphics output types <code>vector, stream,</code> and <code>barb</code>, 
    the plotting routines need two result grids, where the first result grid is 
    treated as the U component, and the second result grid is treated as the V 
    component. These two result grids are provided with the <a href="gradcomddisplay.html">display</a> 
    command by entering two expressions separated by a semicolon:
    <ul>
      <code> display u ; v<br>
      display ave(u,t=1,t=10) ; ave(v,t=1,t=10)</code> 
    </ul>
    <p> 
  <li>For the graphics output types <code>vector</code> and <code>stream</code>, 
    you can specify a third result grid that will be used to colorize the vectors 
    or streamlines:
    <ul>
      <code> display u ; v ; mag(u,v)<br>
      display u ; v ; hcurl(u,v)</code> 
    </ul>
    <p> 
  <li>To draw a 1-D time series with graphics output types vector or barb, set 
    the dimension environment so that only time is varying, then :
    <ul>
      <code> display const(u,0); u ; v </code> 
    </ul>
    <p> 
  <li>For the graphics output type <code>wxsym</code>, each value at a station 
    location is assumed to be a wx symbol code number. To see a chart of all available 
    wx symbols and their corresponding code numbers, run the sample script <code>wxsym.gs</code>. 
    <p> 
  <li>The graphics output type <code>findstn</code> requires three arguments to 
    be provided with the <a
href="gradcomddisplay.html"><code>display</code></a> command. The first argument 
    is a station data expression. The 2nd and 3rd arguments are the X and Y screen 
    coordinates of the of the desired search location. GrADS will find the station 
    closest to the specified X and Y position, and print its stid, lon, and lat. 
    This graphics output type should only be used when X and Y are the varying 
    dimensions and AFTER a regular display command (that results in graphics output) 
    is entered. 
    <p> 
  <li>For the graphics output type <code>stnmark</code>, the size and style of 
    the mark are controled by <a href="gradcomdsetdigsiz.html"><code>set digsiz</code></a> 
    and <a href="gradcomdsetcmark.html"><code>set cmark</code></a>. To turn off 
    rainbow colorizing and use a single color instead, use <a href="gradcomdsetccolor.html"><code>set 
    ccolor</a> <i>color#</i></code>. 
</ol>

<p>
<h3>Examples </h3>

  The <a href="library.html">library</a> contains an <a href="ftp://iges.org/grads/scripts/box_and_whisker.gs">example script</a> demonstrating how to use gxout bar and errbar

<p> </p>
</body>
</html>

\ No newline at end of file
diff --git a/doc/gradcomdsethershey.html b/doc/gradcomdsethershey.html
new file mode 100644
index 0000000..2d122b5
--- /dev/null
+++ b/doc/gradcomdsethershey.html
@@ -0,0 +1,29 @@
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
+<style type="text/css">
+.style1 {color: #990000}
+.red {	color: #900;
+}
+.red {	color: #900;
+}
+.red {	color: #900;
+}
+.red {	color: #900;
+}
+body {
+	background-color: #e0f0ff;
+}
+</style>
+
+
+<H2><B>set hershey</B></H2>
+<P>
+  <code>set hershey on</code> | <code>off</code>
+<p>This command, which is available beginning with <span class="red">GrADS version 2.1</span>, is a quick shortcut for users who would like to take advantage of Cairo fonts but do not know anything about  font files on their system or do not want to bother editing the font controls in existing scripts.
+Invoking <code>'set hershey off'</code> will tell GrADS to use generic Cairo fonts that are reasonable approximations of Hershey fonts 0, 1, 2, 4, and 5. Font 3 is the Greek (symbol) font, and cannot be  duplicated with generic controls. <code>'set hershey on'</code> will return GrADS to the use of traditional   Hershey fonts. 
+<p>
+<h3>Usage Notes</h3>
+<p>This command 'sticks' until the user issues another<code> <a href="gradcomdsethershey.html">set hershey</a> </code>command, or a<code> <a href="gradcomdreset.html">reset</a> </code> or<code> <a href="gradcomdreinit.html">reinit</a> </code>command is issued. </p>
+<p>Please read the documentation page on <a href="fontcontrol.html">Font Control in GrADS</a> for more information about using fonts in GrADS version 2.1. 
+<p>If your build is not enabled with the Cairo graphics library, <code>'set hershey off'</code> will have no effect. 
+<p>
+<H3> </H3>
\ No newline at end of file
diff --git a/doc/gradcomdsetlwid.html b/doc/gradcomdsetlwid.html
new file mode 100644
index 0000000..0b55418
--- /dev/null
+++ b/doc/gradcomdsetlwid.html
@@ -0,0 +1,27 @@
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
+<style type="text/css">
+.red {
+	color: #900;
+}
+body {
+	background-color: #e0f0ff;
+}
+</style>
+
+
+<H2><B>set lwid</B></H2>
+<P>This command, which is available in <span class="red">GrADS version 2.1+</span>, allows the user to define a new line thickness setting with a specified  width.
+<H3>Syntax </H3>
+<p><code>set lwid <i>thickness width</i></code>
+<p>The <code><i>thickness</i></code> argument must be an integer in the range of<code> 13 to 256. </code> Line thickness settings between 1 and 12 are pre-defined  and cannot be changed. The <code><i>width</i></code> argument must be a real number > 0, but line widths greater than 3.0 are not recommended.</H3>
+<H3>Usage Notes</H3>
+<P>The default line widths for <code><i>thickness</i></code> settings between 1 and 12 are:<code> 0.6, 0.8, 1.0, 1.25, 1.5, 1.75, 2.0, 2.2, 2.4, 2.6, 2.8, 3.0. </code> The default line width for <code><i>thickness</i></code> settings greater than 12 is 1.0. 
+The units  (pixels or points) will depend on the surface being drawn to.
+<P>Once a new thickness setting has been defined, it can be used with any command that controls thickness:<code> <a href="gradcomdsetannot.html">set annot</a>, <a href="gradcomdsetclopts.html">set clopts</a>, <a href="gradcomdsetcthick.html">set cthick</a>, <a href="gradcomdsetgrid.html">set grid</a>, <a href="gradcomdsetline.html">set line</a>, <a href="gradcomdsetmap.html">set map</a>, <a href="gradcomdsetmpt.html">set mpt</a>, <a href="gradcomdsetstring.html">set string</a>, <a href=" [...]
+<h3>Example</h3>
+<pre><p>set lwid 13 1.6<br />set cthick 13
+</p>
+</pre>
+<P>
+<P>
+<H3> </H3><P>
diff --git a/doc/gradcomdsetsdfwrite.html b/doc/gradcomdsetsdfwrite.html
index 66f4167..4e79841 100644
--- a/doc/gradcomdsetsdfwrite.html
+++ b/doc/gradcomdsetsdfwrite.html
@@ -1 +1,84 @@
-<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->

<html>
<head>
<title>GrADS Command: set sdfwrite</title>
<style type="text/css">
<!--
.style1 {color: #990000}
-->
</style>
</head>
<body bgcolor="e0f0ff" text="#000000">

<h2><b>set sdfwrite</b></h2>
<p>
<code>set sdfwrite <-4d or -5d> <-flt or -dbl> <-nc3 or -nc4> <-chunk> <-zip> <i>fname</i></code>
<p>
Sets the filename and other characteristics for self-describing  data output. Arguments in <code>< ></code> are optional. </p>
<ul>
  <p><code><i>fname</i>    </code>output filename (default = <code>grads.sdfwrite.nc</code>)<br>
    <code>-4d      </code>forces the output data file to have at least 4 coordinate dimensions (lon, lat, lev, and time)<br>
    <code>-5d      </code>forces the output data file to have 5 coordinate dimensions (lon, lat, lev, time, and ens)<br>
    <code>-flt     </code>output data written with floating point precision<br>
    <code>-dbl     </code>output data written with double precision (default)<br>
    <code>-nc3     </code>output data file written in  netCDF classic format (default)<br>
    <code>-nc4     </code>output data file written in netCDF-4 format<br>
    <code>-chunk   </code>output data will be chunked (only if <code>-nc4</code>); set chunk sizes with the <a href="gradcomdsetchunksize.html"><code>set chunksize</code></a> command<br>
    <code>-zip     </code>output data will be compressed (implies <code>-nc4</code> and <code>-chunk</code>)<br>
    </p>
</ul>
<p>
<h3>Usage Notes</h3>
<p>
This command is  available in GrADS <span class="style1">v2.0.a3+</span>. 
<p> The <code>-4d</code> and <code>-5d</code> options were introduced in GrADS <span class="style1">v2.0.a5+</span>. 
<p> The <code>-flt</code>, <code>-dbl</code>, <code>-nc3</code>,<code>-nc4</code>, <code>-chunk</code>, and <code>-zip</code> options were introduced in GrADS <span class="style1">2.0.a8+</span>.
<p>  If the <code>-4d</code> and <code>-5d</code> options are not used, the output will have the same number of dimensions as the defined variable being written out to file (GrADS <span class="style1">2.0.a9+</span>). In earlier versions, the <code>-4d</code> and <code>-5d</code> options "stuck" until the <code><a href="gradcomdreset.html">reset</a></code>, <code><a href="gradcomdreinit.html">reinit</a></code>, or <code><a href="gradcomdclear.html">clear sdfwrite</a></code> comm [...]
<p>The output data will be in NetCDF format.  The  file 
  <code><i>fname</i></code> will be replaced if it exists. Use the 
  <a href="gradcomdsdfwrite.html"><code>sdfwrite</code></a> command to create the output file. 
The <a href="gradcomdqsdfwrite.html"><code>query sdfwrite</code></a> command
  returns the status of the <code>sdfwrite</code> options. The <code><a href="gradcomdclear.html">clear sdfwrite</a></code> command resets the sdfwrite parameters back to their default values. 
<p>If you use the <code>-zip</code> option, then it is not necessary to also specify <code>-nc4</code> or <code>-chunk</code>; GrADS will automatically set these options. A compressed file is always in netCDF-4 format and is always chunked. Use the <a href="gradcomdsetchunksize.html"><code>set chunksize</code></a> command to set the chunk size before writing out the file. 
Please see the documentation on <a href="compression.html">compression</a> for more details. 
<p>
<h3>Examples </h3>
<p>Suppose you have a high resolution data set (5120x2560) and you wish to save the variable as compressed netcdf with floating point precsion. </p>
<p><code>set x 1 5120<br />
set y 1 2560<br />
set z 1<br />
set t 1<br />
define var = var<br /> 
set sdfwrite -flt  -zip var.nc<br />
set chunksize 512 256<br />
sdfwrite var<br />
</code></p>
<p> </p>
</body>
</html>

\ No newline at end of file
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
+
+<html>
+<head>
+<title>GrADS Command: set sdfwrite</title>
+<style type="text/css">
+<!--
+.style1 {color: #990000}
+-->
+</style>
+</head>
+<body bgcolor="e0f0ff" text="#000000">
+
+<h2><b>set sdfwrite</b></h2>
+<p>This command sets the filename and other characteristics for self-describing netCDF data output. Is it used in conjunction with the <code><a href="gradcomdsdfwrite.html">sdfwrite</a></code> command which writes out a defined variable. 
+<h3>Syntax
+</h3>
+<p><code>set sdfwrite <-3dz or -3dt or -4d or -5d>  <-rt or -re> <-flt or -dbl> <-nc3 or -nc4> <-chunk> <-zip> <i>fname</i></code>
+<p>where</p>
+<ul>
+  <p><code><i>fname</i>    </code>output filename (required) </p>
+</ul>
+  <p>The following six optional arguments are not enabled by default; each new call to <code><a href="gradcomdsetsdfwrite.html">set sdfwrite</a></code> will turn them off if they are not included. The default behavior is to write out a variable with the same number of varying dimensions as the defined variable and with no record (unlimited) dimension. 
+<ul>
+    <code>-3dt     </code>forces the output data file to have at least 3 coordinate dimensions (lon, lat,  and time)<br>
+    <code>-3dz     </code>forces the output data file to have at least 3 coordinate dimensions (lon, lat, and lev)<br>
+    <code>-4d      </code>forces the output data file to have at least 4 coordinate dimensions (lon, lat, lev, and time)<br>
+    <code>-5d      </code>forces the output data file to have 5 coordinate dimensions (lon, lat, lev, time, and ens)<br>
+    <code>-rt      </code>sets the T axis as the record (unlimited) dimension<br>
+    <code>-re      </code>sets the E axis as the record (unlimited) dimension<br>
+</ul>
+<p>The following six optional arguments will "stick" once they are invoked; defaults are restored with the <a href="http://iges.org/grads/gadoc/gradcomdreset.html"><code>reset</code></a>, <a href="http://iges.org/grads/gadoc/gradcomdreinit.html"><code>reinit</code></a>, or <a href="http://iges.org/grads/gadoc/gradcomdclear.html"><code>clear sdfwrite</code></a> commands.   
+  <ul>
+    <code>-flt     </code>output data written with floating point precision<br>
+    <code>-dbl     </code>output data written with double precision (default)<br>
+    <code>-nc3     </code>output data file written in  netCDF classic format (default)<br>
+    <code>-nc4     </code>output data file written in netCDF-4 format<br>
+    <code>-chunk   </code>output data will be chunked (only if <code>-nc4</code>); set chunk sizes with the <a href="gradcomdsetchunksize.html"><code>set chunksize</code></a> command<br>
+    <code>-zip     </code>output data will be compressed (implies <code>-nc4</code> and <code>-chunk</code>)<br>
+
+  </p>
+</ul>
+<p>
+<h3>Usage Notes</h3>
+<p>
+This command is  available in GrADS <span class="style1">v2.0.a3+</span>. 
+<br>
+The <code>-4d</code> and <code>-5d</code> options are available in GrADS <span class="style1">v2.0.a5+</span>. 
+<br>
+The <code>-flt</code>, <code>-dbl</code>, <code>-nc3</code>,<code>-nc4</code>, <code>-chunk</code>, and <code>-zip</code> options are available in GrADS <span class="style1">2.0.a8+</span>.<br>
+The <code>-3dz,</code><code>-3dt,-rt</code> and <code>-re</code> options are available in GrADS <span class="style1">2.1.a2+</span>.
+<p>The options set with this command "stick" until the <a href="http://iges.org/grads/gadoc/gradcomdreset.html"><code>reset</code></a>, <a href="http://iges.org/grads/gadoc/gradcomdreinit.html"><code>reinit</code></a>, or <a href="http://iges.org/grads/gadoc/gradcomdclear.html"><code>clear sdfwrite</code></a> commands are invoked -- they are not altered when <a href="gradcomdsdfwrite.html"><code>sdfwrite</code></a> is invoked; however, there have been some changes related to  which optio [...]
+<ul>
+  <li>(<span class="style1">2.0.a3</span>) Originally, all options were designed to "stick" until  a  <a href="http://iges.org/grads/gadoc/gradcomdclear.html"><code>clear sdfwrite</code></a> command was invoked.</li>
+  <li>(<span class="style1">2.0.a9</span>) The interface was changed so that the <code>-5d</code> and <code>-4d</code> options are  reset to the default (off) with each  new <code><a href="gradcomdsetsdfwrite.html">set sdfwrite</a></code> command. This means that if these options are not used, the  output variable will have the same number of dimensions as the defined variable. The  options that control the precision, format, and compression of the output file continue to "stick&quo [...]
+  <li>(<span class="style1">2.1.a2</span>) The new options (<code>-3dz,</code><code>-3dt,-rt</code> and <code>-re</code>) have the same behavior as the <code>-5d</code> and <code>-4d</code> options -- they are reset to the default (off) with each  new <code><a href="gradcomdsetsdfwrite.html">set sdfwrite</a></code> command. </li>
+</ul>
+<p> When the <code>-3dz,</code><code>-3dt,-4d</code> or <code>-5d</code>  options are used,   the output file will retain information about the values of the  dimensions that were fixed when the variable was defined; non-varying dimensions will appear as a coordinate variable of size 1.
+
+<p>The  file <code><i>fname</i></code> will be replaced if it exists. Use the 
+  <a href="gradcomdsdfwrite.html"><code>sdfwrite</code></a> command to create the output file in netCDF format. 
+The <a href="gradcomdqsdfwrite.html"><code>query sdfwrite</code></a> command
+returns the status of the <code>sdfwrite</code> options. 
+<p>The <code><a href="gradcomdclear.html">clear sdfwrite</a></code> command resets these sdfwrite parameters back to their default values, and releases from memory all attribute metadata that has been defined with <a href="gradcomdsetsdfattr.html"><code>set sdfattr</code></a>.
+<p>If you use the <code>-zip</code> option, then it is not necessary to also specify <code>-nc4</code> or <code>-chunk</code>; GrADS will automatically set these options. A compressed file is always in netCDF-4 format and is always chunked. Use the <a href="gradcomdsetchunksize.html"><code>set chunksize</code></a> command to set the chunk size before writing out the file. 
+Please see the documentation on <a href="compression.html">compression</a> for more details. 
+Compression is not availabe with the classic netCDF format. 
+<p>The <code>-rt</code> and <code>-re</code> options are used to  assign a  record (unlimited) dimension. The default is to not have a record dimension. A netCDF-4 file may have more than one record dimension -- it can be set to T or E or both. For netCDF classic format, only one dimension may be a record dimension, and it must be the outermost (slowest varying) dimension.
+<p>
+<h3>Examples </h3>
+<p>Suppose you have a high resolution data set (5120x2560) and you wish to save the variable as compressed netcdf with floating point precsion. </p>
+<p><code>set x 1 5120<br />
+set y 1 2560<br />
+set z 1<br />
+set t 1<br />
+define var = var<br /> 
+set sdfwrite -flt  -zip var.nc<br />
+set chunksize 512 256<br />
+sdfwrite var<br />
+</code></p>
+<p> </p>
+</body>
+</html>
+
diff --git a/doc/gradcomdsettile.html b/doc/gradcomdsettile.html
new file mode 100644
index 0000000..7bf766a
--- /dev/null
+++ b/doc/gradcomdsettile.html
@@ -0,0 +1,117 @@
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
+
+<html>
+<head>
+<title>GrADS Command: set rgb</title>
+<style type="text/css">
+<!--
+.style1 {color: #990000}
+.red {	color: #900;
+}
+.red {	color: #900;
+}
+.red {	color: #900;
+}
+.red {	color: #900;
+}
+body {
+	background-color: #e0f0ff;
+}
+-->
+</style>
+<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
+</head>
+<body text="#000000">
+
+<h2><b>set tile</b></h2>
+
+<p>
+This command, which is available beginning with <span class="red">GrADS version 2.1</span>, is used to create a new pattern fill. Patterns are defined in the form of "tiles" which are  small images that are used repeatedly to fill an area. GrADS supports the automatic generation of tiles for drawing certain  simple patterns.  More complex patterns can be acheived by providing a custom image file. 
+<h3>Syntax</h3>
+<p>
+<code>set tile <i>number type <width <height <lwid <fgcolor <bgcolor>>>>> </i></code>   (for automatic generation of basic tile patters)<br>
+ ... or ... <br>
+   <code> set tile <i>number</i> 0 <i>filename                                     </i>   </code>(for user-supplied file containing the custom tile image)
+<p>
+  where:
+<ul>
+  <p><code><i>number</i>    </code>is the tile number; it can range from 0 to 2047.<br>
+    <code><i>type</i>      </code>is the tile type, valid values and what they mean are shown below.
+    <br>
+    <code><i>width</i>     </code>is the width of the generated tile in pixels (default is 9).  <br>
+    <code><i>height</i>    </code>is the  height of the generated tile in pixels (default is 9). <br>
+<code><i>lwid</i>      </code>is the line thickness used to draw the  lines in the tile. <code><i>lwid</i></code> must be an integer between 1 and 12 (default is 3). <br>
+<code><i>fgcolor</i>   </code>is the  color used to draw the lines or dots in the tile (default is opaque white).<br>
+<code><i>bgcolor</i>   </code>is the  color  used to fill the background of the tile (default is fully transparent).<br>
+<code><i>filename</i></code>    the full name of the .png file (including the path) to be used as a custom tile for creating the patern.</p>
+</ul>
+<p> Valid options for the tile <code><i>type</i></code> are as follows: </p>
+<ul>
+  <p><code>  0 - </code>tile image is provided with specified <code><i>filename</i></code><br>
+    <code>  1 - </code>solid <br>
+    <code>  2 - </code>dots <br>
+    <code>  3 - </code>diagonal downward lines <br>
+    <code>  4 - </code>diagonal upward lines <br>
+    <code>  5 - </code>diagonal cross hatching <br>
+    <code>  6 - </code>vertical  lines <br>
+    <code>  7 - </code>horizontal  lines <br>
+    <code>  8 - </code>rectangular cross hatching <br>
+</ul>
+  <p>Once you have defined a new tile, create the pattern fill by assigning the defined tile number to a color using the <code><a href="gradcomdsetrgb.html">set rgb</a></code> command.  The special syntax is: </p>
+  <p><code>set rgb <i>nn</i> tile <i>tt</i></code></p>
+<p> where: </p>
+  <p><code><i>nn</i> </code>is the color number (must be between 16 and 2047)<br>
+    <code><i>tt</i> </code>is the defined tile number <br>
+</ul>
+</p>
+<h3>Usage Notes</h3>
+<p> For the automatically generated tiles, GrADS creates a small image on the fly using the specified width and  height. This tile image is   filled with the foreground color (if the <code><i>type</i></code> is 1), or it is filled with the background color and then the dots or lines are drawn on top using the foreground color and the specified line thickness.  Note that the lines are  drawn from corner to corner (for diagonal lines) or through the  middle of the image (for dots and horiz [...]
+<p> The fully described pattern fill will be a combination of the "set tile" command and "set rgb" commands. You may  use the 16 pre-defined colors in the tiles or any newly defined color. The only restriction is that a color number that has a tile assigned to it may not be used as a foreground or background color for another tile. New colors and tiles may be defined in any order, but they should  be set before any drawing is  done.  Changing color or tile values mid-stream in a plot may [...]
+<p> </p>
+<h3>Examples</h3>
+
+<P>The table of small images below shows what some basic automatically generated tiles can look like. 
+Each colum has a different <code><i>type</i></code> number, from 1-8.  Each row has a different foreground color and different values for the <code><i>width</i></code> and <code><i>height</i></code>, which are written to the left of each row. The value for 
+<code><i>lwid</i></code> is 1 for  all tiles. 
+<p><img src="images/pattern_demo.png" width="742" height="284" alt="pattern demo">
+<p>
+<p>This  image illustrates how you can use a stippled pattern fill as an overlay on a shaded plot. Script  sample to generate the plot is provided below.
+<p><img src="images/pattern_demo2.png" width="900" height="556" alt="pattern demo 2">
+<code>
+<p>* set up a grey scale color sequence with 'set rbcols'<br>
+  i = 60<br>
+  n = 60<br>
+  cmd = 'set rbcols'<br>
+  while (i<256) <br>
+  'set rgb 'n' 'i' 'i' 'i<br>
+  cmd = cmd%' '%n<br>
+  i = i + 15<br>
+  n = n + 1<br>
+endwhile<br>
+cmd
+<p>* define 2  colors<br>
+  'set rgb 20 255 0   0'<br>
+  'set rgb 21   0 0 255'</p>
+<p>* define 2 patterns<br>
+  'set tile 0 2 6 6 3 20'<br>
+'set tile 1 2 6 6 3 21'<br>
+'set rgb 22 tile 0'<br>
+'set rgb 23 tile 1'</p>
+<p>* draw the height field with the gray shades<br>
+  'set gxout shaded'<br>
+  'set lev 200'
+  <br>
+  'd z'</p>
+<p>* overlay stippled red/blue shading of v greater than 5 and less than -5<br>
+  'set clevs 5'<br>
+  'set ccols -1 22'<br>
+  'd v'<br>
+  'set clevs -5'<br>
+  'set ccols 23 -1'<br>
+'d v'</p>
+</code>
+<p>
+
+
+</body>
+</html>
diff --git a/doc/gradcomdsetvrange.html b/doc/gradcomdsetvrange.html
index a9bd002..a1e1b0b 100644
--- a/doc/gradcomdsetvrange.html
+++ b/doc/gradcomdsetvrange.html
@@ -1,30 +1,8 @@
 <!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
-<style type="text/css">
-body {
-	background-color: #e0f0ff;
-}
-</style>
-
 
 <h2><b>set vrange</b></h2>
-<p><code>set vrange v1 v2</code></p>
-<p>When drawing a 1-D plot, this command specifies the range of the  values for the scale on the Y-axis (from v1
-to v2).</p>
-<p> When drawing a 2-D scatter plot  using graphics output type <code><a href="gradcomdsetgxout.html">gxout scatter</a></code>, this command specifies the range of values for the scale on the X axis; use the <code><a href="gradcomdsetvrange2.html">set vrange2</a></code> command to control the range of the Y-axis values on your scatter plot.</p>
-<p>
-<H3>Usage Note</H3>
-<P> Reset by <code><a href="gradcomdclear.html">clear</a></code> only. 
-<H3>Examples</H3>
-<pre>
-set lat 50
-set lon 0 360
-set gxout contour
-set vrange -20 20
-d u10
-
-set gxout scatter
-set vrange 250 300
-set vrange2 980 1040
-d temp;slp
-</pre>
-
+<code>set vrange y1 y2</code><p>
+Specifies the range of the variable values for y-axis scaling (from y1
+- y2).  Reset by <code>clear</code> only.<p>
+<H3>Usage Note</H3><P>
+<H3>Examples</H3><P>
diff --git a/doc/gradcomdsetvrange2.html b/doc/gradcomdsetvrange2.html
index c93ce44..0789948 100644
--- a/doc/gradcomdsetvrange2.html
+++ b/doc/gradcomdsetvrange2.html
@@ -1,16 +1,8 @@
 <!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
-<style type="text/css">
-body {
-	background-color: #e0f0ff;
-}
-</style>
-
 
 <h2><b>set vrange2</b></h2>
-<code> set vrange2 v1 v2</code>
-<p>
-When drawing a 2-D scatter plot  using graphics output type <code><a href="gradcomdsetgxout.html">gxout scatter</a></code>, this command specifies the range of values for the scale on the Y axis (from v1 to v2).
-<H3>Usage Note</H3><P> Reset by <code>clear</code> only.
-
-<P> Use the <code><a href="gradcomdsetvrange.html">set vrange</a></code> command to control the range of the X-axis values on your scatter plot.
+<code> set vrange2 x1 x2</code><p>
+Specifies the range of the variable values for x-axis scaling (from x1
+- x2).  Reset by <code>clear</code> only.
+<H3>Usage Note</H3><P>
 <H3>Examples</H3><P>
diff --git a/doc/gradcomdsetwxcols.html b/doc/gradcomdsetwxcols.html
index 0159a7c..31180d5 100644
--- a/doc/gradcomdsetwxcols.html
+++ b/doc/gradcomdsetwxcols.html
@@ -1,23 +1 @@
-<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
-<style type="text/css">
-body {
-	background-color: #e0f0ff;
-}
-</style>
-
-
-<H2><B>set wxcols</B></H2>
-<P>
-<code>set wxcols <i>c1 c2 c3 c4 c5 </i></code>
-<P>
-where<code> <i>c1...c5</i> </code>are the weather symbol colors
-<P>c1 (default color 2, red) :  thunder/sleet/freezing/hurricane [used in symbols 1-13,24-27,31-32,38,40,41]<br />
-  c2 (default color 10, green) :  rain/drizzle [used in symbols 3,8,12-18,24,26-30,37] <br />
-  c3 (default color 11, blue) :  snow [used in symbols 4,9,19-23,37] <br />
-  c4 (default color 7, yellow):  fog [used in symbol 34] <br />
-  c5 (default color 15, gray):  blowing snow/sand/smoke [used in symbols 33,35,36,39] <br />
-
-<p>
-<H3>Usage Notes</H3><P>
-<H3>Examples</H3>
-<P>Run the script <a href="ftp://cola.gmu.edu/grads/scripts/wxsym.gs">wxsym.gs</a> to see how the colors of the various symbols are implemented. 
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->

<H2><B>set wxcols</B></H2>
<P>
<code>set wxcols <i>c1 c2 c3 c4 c5 </i></code>
<P>
where<code> <i>c1...c5</i> </code>are the weather symbol colors
<P>c1 (default color 2, red) :  thunder/sleet/freezing/hurricane [used in symbols 1-13,24-27,31-32,38,40,41]<br />
  c2 (default color 10, green) :  rain/drizzle [used in symbols 3,8,12-18,24,26-30,37] <br />
  c3 (default color 11, blue) :  snow [used in symbols 4,9,19-23,37] <br />
  c4 (default color 7, yellow):  fog [used in symbol 34] <br />
  c5 (default color 15, gray):  blowing snow/sand/smoke [used in symbols 33,35,36,39] <br />

<p>
<H3>Usage Notes</H3><P>
<H3>Examples</H3>
<P>Run the script <a href="ftp://grads.iges.org/grads/scripts/wxsym.gs">wxsym.gs</a> to see how the colors of the various symbols are implemented. 
\ No newline at end of file
diff --git a/doc/gradfuncaave.html b/doc/gradfuncaave.html
index 29408f5..b5bf5f4 100644
--- a/doc/gradfuncaave.html
+++ b/doc/gradfuncaave.html
@@ -2,19 +2,17 @@
 
 <html>
 <title>GrADS Function: aave</title>
-<style type="text/css">
-body {
-	background-color: #e0f0ff;
-}
-</style>
-<body text="#000000">
+<body  bgcolor="e0f0ff" text="#000000">
 
-<H2><b>aave()</b></H2><p>This function takes an areal average over an X-Y region. The syntax is:
+<H2><b>aave()</b></H2><p>
+<p>
+This function takes an areal average over an X-Y region. The syntax is:
 <p>
 <code>aave(<i>expr, xdim1, xdim2, ydim1, ydim2</i>)</code>
 
 <p>
 where:
+<p>
 <ul>
 <code><i>expr</i>    </code>- any valid GrADS expression <br>
 <code><i>xdim1</i>   </code>- starting X dimension expression <br>
@@ -36,23 +34,25 @@ is the same as
 
 <p>
 <H3>Usage Notes</H3>
+<p>
 <ol>
 <li>In the absence of missing data values, <code>aave</code> gives the
 same result as nested <code><a href="gradfuncave.html">ave</a></code> 
 functions in the X and Y dimensions. The expression
 <p>
-<code>ave(ave(<i>expr</i>,x=1,x=72),y=1,y=46)</code>
+<dd>ave(ave(<i>expr</i>,x=1,x=72),y=1,y=46)</code>
 <p> 
 will produce the same numerical result as 
 <p>
-<code>aave(<i>expr</i>,x=1,x=72,y=1,y=46)</code>
+<dd><code>aave(<i>expr</i>,x=1,x=72,y=1,y=46)</code>
 <p>
 but the <code>aave</code> function is faster more efficient. 
 
+<p>
 <li>When there are missing data values, the <code>aave</code> function
 does <i><b>not</b></i> return the same result as nested <a
 href="gradfuncave.html"><code>ave</code></a> functions. To
-see this, consider the small grid:
+see this, consider the small grid:<p>
 <pre>
         6       18      3       5
 
@@ -69,40 +69,44 @@ the result will be an average of 10. When <code>aave</code> is used, all
 the values participate equally (in this case, we are assuming no weights
 applied to the final average), and the result is 84/9 or about 9.33.
 
-
-<br>
-<br>
+<p>
 <li>The <code>aave</code> function assumes that the world
-  coordinates are longitude in the X dimension and latitude in the Y
-  dimension, and does weighting in the latitude dimension by the
-  difference between the sines of the latitude at the northern and
-  southern edges of the grid box. For areal averaging without latitude weighting,
-  use the <a href="gradfuncamean.html"><code>amean</code></a> function.
-  <br>
-  <br>
+coordinates are longitude in the X dimension and latitude in the Y
+dimension, and does weighting in the latitude dimension by the
+difference between the sines of the latitude at the northern and
+southern edges of the grid box. For areal averaging without latitude weighting,
+use the <a href="gradfuncamean.html"><code>amean</code></a> function.
+<p>
 <li>Both the <code>aave</code> and <a
 href="gradfuncamean.html"><code>amean</code></a> functions use
-appropriate weighting to account for unevenly spaced grids.<br>
-<br>
+appropriate weighting to account for unevenly spaced grids.
+
+<p>
 <li>The <code>aave</code> function always does its average to the exact
-  boundaries specified, in world coordinates. This is somewhat different
-  from the <a href="gradfuncave.html"><code>ave</code></a> function, where
-  the <code>-b</code> flag is used
-  to get this behavior. If the boundaries specified via the dimension
-  expressions do not fall on grid boundaries, then the boundary values are
-  weighted appropriately in the average.<br>
-  <br>
-<li>If grid coordinates are used in the dimensions expressions,
-then they are converted to world coordinates to determine the exact boundary values. This conversion is done using the scaling of the default
+boundaries specified, in world coordinates. This is somewhat different
+from the <a href="gradfuncave.html"><code>ave</code></a> function, where
+the <code>-b</code> flag is used
+to get this behavior. If the boundaries specified via the dimension
+expressions do not fall on grid boundaries, then the boundary values are
+weighted appropriately in the average.
+
+<p>
+<li>When grid coordinates are used in the dimensions expressions,
+then they are converted to world coordinates for the boundary to be
+determined. This conversion is done using the scaling of the default
 file. Note that the conversion is done using the outside grid
-box boundary, rather than the grid box center. For example:
-  <p><code>asum(expr,x=1,x=72,y=1,y=46)</code>
-  <p> Here the boundary would be determined by using the X grid values ranging from 0.5 to 
-    72.5 and Y grid values ranging from 0.5 to 46.5. These four grid boundary values would be converted to world coordinates using the scaling information from the default file. If
-    we assume that <code>x=1</code> is 0 degrees longitude and <code>x=72</code> is 355 degrees longitude, then the averaging
-    boundary would be -2.5 to 357.5 degrees, which would cover the
-    earth. In the Y dimension, when the boundary is beyond the pole, the <code>asum</code> function recognizes this and weights
-    appropriately. 
+boundary, rather than the grid center. For example: 
+<p>
+<dd><code>aave(expr,x=1,x=72,y=1,y=46)</code>
+<p>
+Here the boundary would be determined by using the grid values 0.5, 72.5,
+0.5, and 46.5 which would be converted to world coordinates. If we assume
+that <code>x=1</code> is 0 degrees longitude and <code>x=72</code> is 355
+degrees longitude, then the averaging boundary would be -2.5 to 357.5
+degrees, which would cover the earth. In the Y dimension, when the
+boundary is beyond the pole, the <code>aave</code> function recognizes
+this and weights appropriately.
+
 </ol>
 <p>
 
@@ -112,16 +116,15 @@ box boundary, rather than the grid box center. For example:
 <li>See the <a href="gradfunctloop.html"><code>tloop</code></a> function
 for an example of creating a time
 series of area averages. 
-<br><br>
-<li>An example of taking an area average of data only over land, given
+<p><li>An example of taking an area average of data only over land, given
 a
 mask grid: <p>
 
-<code>aave(maskout(p,mask.3(t=1)),x=1,x=72,y=1,y=46) </code><p>
+<dd><code>aave(maskout(p,mask.3(t=1)),x=1,x=72,y=1,y=46) </code><p>
 
 In this case, it is assumed the mask grid has negative values at ocean
 points. <p>
-</ol>
+
 
 </body>
 </html>
\ No newline at end of file
diff --git a/doc/gradfuncasum.html b/doc/gradfuncasum.html
index 370994d..e2d3866 100644
--- a/doc/gradfuncasum.html
+++ b/doc/gradfuncasum.html
@@ -2,17 +2,9 @@
 
 <html>
 <title>GrADS Function: asum</title>
-<style type="text/css">
-.red {
-	color: #900;
-}
-body {
-	background-color: #e0f0ff;
-}
-</style>
-<body text="#000000">
+<body  bgcolor="e0f0ff" text="#000000">
 
-<H2><b>asum()</b></H2>
+<H2><b>asum()</b></H2><p>
 <p>
 This function takes a sum over an X-Y region. The syntax is:
 <p>
@@ -20,6 +12,7 @@ This function takes a sum over an X-Y region. The syntax is:
 
 <p>
 where:
+<p>
 <ul>
 <code><i>expr</i>    </code>- any valid GrADS expression <br>
 <code><i>xdim1</i>   </code>- starting X dimension expression <br>
@@ -41,32 +34,38 @@ is the same as
 
 <p>
 <H3>Usage Notes</H3>
+<p>
 <ol>
 <li>The <code>asum</code> function always does its average to the
 exact boundaries specified, in world coordinates. If the boundaries
-specified via the dimension expressions do not fall on grid box
-boundaries, then the  values in the boundary grid boxes are weighted in the sum according to the length of the partial grid box in world coordinates. <br>
-  <br>
-<li>If grid coordinates are used in the dimensions expressions,
-then they are converted to world coordinates to determine the exact boundary values. This conversion is done using the scaling of the default
+specified via the dimension expressions do not fall on grid
+boundaries, then the boundary values are weighted appropriately in the
+sum.
+
+<p>
+<li>When grid coordinates are used in the dimensions expressions,
+then they are converted to world coordinates for the boundary to be
+determined. This conversion is done using the scaling of the default
 file. Note that the conversion is done using the outside grid
-box boundary, rather than the grid box center. For example: <p><code>asum(expr,x=1,x=72,y=1,y=46)</code>
+boundary, rather than the grid center. For example: 
 <p>
-  Here the boundary would be determined by using the X grid values ranging from 0.5 to 
-  72.5 and Y grid values ranging from 0.5 to 46.5. These four grid boundary values would be converted to world coordinates using the scaling information from the default file. If
-  we assume that <code>x=1</code> is 0 degrees longitude and
-  <code>x=72</code> is 355 degrees longitude, then the averaging
-  boundary would be -2.5 to 357.5 degrees, which would cover the
-  earth. In the Y dimension, when the boundary is beyond the pole, the
-  <code>asum</code> function recognizes this and weights
-  appropriately. To calculate a sum without any weighting of partial grid boxes at the domain boundaries, use the
-  <code><a href="gradfuncasumg.html">asumg</a></code> function.
-  
-  
-<li>There is no latitude-weighting of grid box values in <code>asum</code>. The <code><a href="gradfuncatot.html">atot</a></code> function (in <span class="red">GrADS version 2.0.2+</span>) will calculate a sum over an area and weight the grid box values according to the difference in the sine of the latitude at the northern and southern boundaries of each grid box. 
+<dd><code>asum(expr,x=1,x=72,y=1,y=46)</code>
+<p>
+Here the boundary would be determined by using the grid values 0.5,
+72.5, 0.5, and 46.5 which would be converted to world coordinates. If
+we assume that <code>x=1</code> is 0 degrees longitude and
+<code>x=72</code> is 355 degrees longitude, then the averaging
+boundary would be -2.5 to 357.5 degrees, which would cover the
+earth. In the Y dimension, when the boundary is beyond the pole, the
+<code>asum</code> function recognizes this and weights
+appropriately. To calculate a sum without any weighting, use the
+<code><a href="gradfuncasumg.html">asumg</a></code> function.
+
+
 </ol>
 <p>
 
+<H3>Examples</H3> 
 
  
 </body>
diff --git a/doc/gradfunclterp.html b/doc/gradfunclterp.html
index a6d9efe..d68afc6 100644
--- a/doc/gradfunclterp.html
+++ b/doc/gradfunclterp.html
@@ -1,92 +1 @@
-<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.--><title>lterp</title>
-
-<style type="text/css">
-body {
-	background-color: #e0f0ff;
-}
-.red {
-	color: #900;
-}
-</style>
-
-<h2><b>lterp</b></h2>
-<p>The lterp function performs  intepolation between two grids. It is a built-in function as of  version 2.0 -- in earlier versions it was implemented as a user defined function. Additional capabilities were added with version 2.0.2. The syntax is:
-<p><code>lterp (<i>source, dest</i>)                 </code> (<span class="red">Version 2.0.1 or earlier</span>) <br />
-  <code>lterp (<i>source, dest <,method> <,pct></i>)</code> (<span class="red">Version 2.0.2 or later</span>)
-<p> 
-
-Where 
-<p>	<code><i>source    </i></code>a grid expression that contains the data values to be interpolated<br />
-  <code><i>dest      </i></code>a grid expression that describes the grid that the data are to be interpolated to. 
-The data values in <code><i>dest</i></code>  are ignored, only the grid information is used. <br />
-<code><i>method    </i></code>an optional keyword that describes the interpolation method to be used. Options are:<br />
-<code>    bilin    </code>bilinear interpolation -- this is the default, the behavior when no method is specified, and is identical to the pre-2.0.2 behavior<br />
-<code>   bessel   </code> an enhancement to bilinear interpolation that uses 3rd order bessel interpolation <br />
-<code>    aave     </code>area average with latitude weighting -- may be better than bilin when interpolating from higher to lower grid resolution<br />
-<code>    amean    </code>area average without latitude weighting -- same as aave, but when weighting the grid box area by latitude is not desired <br />
-<code><i>pct       </i></code> the minimum percentage of area of each destination grid box that must contain non-missing input data to be considered valid<br />
-<code><i>          </i></code> (<code><i>pct</i></code> is optional and only relevant when used with <code>aave</code> and <code>amean</code> and must be between 0 and 100; default is 50%)
-<H3>Usage Notes</H3>
-<P>The lterp function works only with gridded data. The returned result  is a grid expression on the same grid as <code><i>dest</i></code>. 
-<P>The <code><i>source</i></code> and <code><i>dest</i></code> expressions   must have the same varying dimensions, which may be X, Y, or T. Interpolation is not performed in the Z or E dimension. 
-  <P>The <code><i>source</i></code> and <code><i>dest</i></code> expressions may vary in 1 or 2 dimensions, unless you are using the <code>aave</code> or <code>amean</code> methods, in which case the grids must be 2-D with X and Y as the varying dimensiions.   
-<P>If the domain of 
-  <code><i>source</i></code> is larger than the domain of <code><i>dest</i></code>, the returned result  will have an expanded grid to cover the requested domain.    
-
-<P>For interpolation in the time dimension, you may interpolate  (A) between monthly and yearly time axes, or (B) between minute, hourly, and daily time axes.
-<P>For the <code>bilin</code> method, each of the grid points in the <code><i>dest</i></code> grid contains the  average of  the nearest four grid points in the <code><i>source</i></code> grid, weighted by their distance from the destination grid point.  If any of the four surrounding input grid points contain missing data, the interpolated value will  be flagged as missing. 
-<P>(<span class="red">Version 2.0.2 or later</span>) The <code>bessel</code> method is adapted from the  regrid user defined function. It uses a bessel interpolation routine developed at Fleet Numerical
-  Meteorology and Oceanography Center (courtesy of D. Hensen).  
-The <code>bilin</code> method of  interpolation is performed at all points to
-  produce a "first guess."  Improvements to the  "first
-  guess" are made using the higher-order terms in the bessel
-  interpolator. Bessel interpolation uses not just the nearst 4 grid boxes in the <code><i>source</i></code> grid, but also the secondary ring of grid points that form a 4x4 matrix around the destination grid point. If  any of the grid boxes in the outer ring of the 4x4 matrix 
-  contain missing data, the output grid is assigned the <code>bilin</code> value. The <code>bessel</code> method may produce a closer fit to the <code><i>source</i></code> data
-  in regions where there are large gradients (e.g., around low pressure centers).
-<P>(<span class="red">Version 2.0.2 or later</span>) For the <code>aave</code> and <code>amean</code> methods, a spatial average using <code><i>source</i></code> data is calculated  in the area outlined by each grid box in the <code><i>dest</i></code> grid. 
-Note that in GrADS the boundaries of all grid boxes are the midpoints between their centers. If a grid box in the <code><i>source</i></code> grid partially overlaps the area of a <code><i>dest</i></code> grid box, its contribution to the spatial average is weighted by the fraction of area within the <code><i>dest</i></code> grid box domain. When the <code><i>source</i></code> grid contains missing data, the <code><i>pct</i></code> argument may be used to specify a threshold for the perce [...]
-<h3>Examples</h3>
-<p><code>* This shows how to use the new features in version 2.0.2 to interpolate between fine and coarse grids.<br />
-open fine.ctl<br />
-open coarse.ctl<br />
-d lterp(fine,coarse.2,aave)<br />
-d lterp(fine,coarse.2,aave,100)<br />
-d lterp(coarse.2,fine,bessel)</code><code><br />
-  </code><code><br />
-  *
-  This script interpolates a 1-D timeseries of hourly station data to a 3hourly grid<br />
-  open hourly_station_data.ctl<br />
-  open 3hourly_grid_data.ctl<br />
-  set x 1 <br />
-  set y 1<br />
-  set time 00z1jan 00z1feb<br />
-  d lterp(s2g1d(var.1(stid=kbwi)),var.2(lon=-77,lat=39))
-</code>
-<code>
-<p>* This script interpolates  2-D lat/lon grids<br />
-  'open obs.ctl'<br />
-  'open model.ctl'<br />
-  * define the source grid<br />
-'set dfile 2'<br />
-'q file'<br />
-line5 = sublin(result,5)<br />
-sx = subwrd(line5,3)<br />
-sy = subwrd(line5,6)<br />
-'set x 1 'sx<br />
-'set y 1 'sy<br />
-'set t 1'<br />
-'define data = model'<br />
-  * define the destination grid<br />
-  'set dfile 1'<br />
-  'q file'<br />
-  line5 = sublin(result,5)<br />
-  dx = subwrd(line5,3)<br />
-  dy = subwrd(line5,6)<br />
-  'set x 1 'dx<br />
-  'set y 1 'dy<br />
-  'set t 1'<br />
-  'define grid = obs'<br />
-* interpolate model data to obs grid <br />
-'d lterp(data,grid)'</code>
-<p>
-<p>
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.--><title>lterp</title>

<h2><b>lterp</b></h2>
<p>The lterp function performs bi-linear intepolation between two grids. It is a built-in function as of  version 2.0 -- in earlier versions it was implemented as a user defined function. The syntax is:
<p><code>lterp(<i>source,dest</i>)</code>
<p> 

The data values in  the <code><i>source</i></code> expression are interpolated to the grid in the   <code><i>dest</i></code> expression. The data values in the <code><i>dest</i></code> expression are ignored. The returned result  is on the same grid as <code><i>dest</i></code>.
<H3>Usage Notes</H3>
<P>Works only with gridded data. The <code><i>source</i></code> and <code><i>dest</i></code> expressions   must have the same varying dimensions, which may be X, Y, or T. Interpolation is not performed in the Z or E dimension. 
The <code><i>source</i></code> and <code><i>dest</i></code> expressions may vary in 1 or 2 dimensions. 
<P>If the domain of 
  <code><i>source</i></code> is larger than the domain of <code><i>dest</i></code>, the returned result  will have an expanded grid to cover the requested domain.    

<P>For interpolation in the time dimension, you may interpolate  (A) between monthly and yearly time axes, or (B) between minute, hourly, and daily time axes.
<h3>Examples</h3>
<p>* This script interpolates a 1-D timeseries of hourly station data to a 3hourly grid<br />
  open hourly_station_data.ctl<br />
  open 3hourly_grid_data.ctl<br />
  set x 1 <br />
  set y 1<br />
  set time 00z1jan 00z1feb<br />
  d lterp(s2g1d(var.1(stid=kbwi)),var.2(lon=-77,lat=39))
<p>

<p>* This script interpolates  2-D lat/lon grids<br />
  'open obs.ctl'<br />
  'open model.ctl'<br />
  * define the destination grid<br />
  'set dfile 1'<br />
  'q file'<br />
  line5 = sublin(result,5)<br />
  ix = subwrd(line5,3)<br />
  iy = subwrd(line5,6)<br />
  'set x 1 'ix<br />
  'set y 1 'iy<br />
  'set t 1'<br />
  'define grid = obs'<br />
  * define the source grid<br />
  'set dfile 2'<br />
  'q file'<br />
  line5 = sublin(result,5)<br />
  ix = subwrd(line5,3)<br />
  iy = subwrd(line5,6)<br />
  'set x 1 'ix<br />
  'set y 1 'iy<br />
  'set t 1'<br />
  'define data = model'<br />
  * interpolate model data to obs grid <br />
  'd lterp(data,grid)'

<p>
<p>
\ No newline at end of file
diff --git a/doc/gradutilgrib2scan.html b/doc/gradutilgrib2scan.html
index 764b993..3c834cb 100644
--- a/doc/gradutilgrib2scan.html
+++ b/doc/gradutilgrib2scan.html
@@ -1,133 +1 @@
-<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
-
-<html>
-<head>
-<title>GrADS Utilities: grib2scan</title>
-<style type="text/css">
-<!--
-.style1 {color: #006600}
-.style2 {color: #0033FF}
-.style3 {color: #996600}
-.style4 {color: #006666}
-.style5 {color: #993366}
-.style6 {color: #FF66FF}
-.style8 {color: #990000}
-.style11 {color: #00CC33}
-.style12 {color: #9900FF}
-.style13 {color: #FF6600}
-.style14 {
-	color: #990;
-}
-.style15 {
-	color: #F00;
-}
-.red {
-	color: #900;
-}
--->
-</style>
-</head>
-<body text="#000000" bgcolor="e0f0ff">
-
-<h2><b>grib2scan</b></h2>
-
-<p>
-The <code>grib2scan</code> utility is used for finding out what is inside a GRIB2 data file. It scans each record in the file, and prints out relevant information about the data in the record. 
-The command sytax is:
-<ul>
-<code>grib2scan [-v] <i>fname</i></code></ul>
-<p>
-Where <code><i>fname</i></code>
- is the input GRIB2 file name, and the <code>-v</code> option is used for verbose output. 
-<p>To assist in the interpretation of the grib2scan output, here are some links to GRIB2 documentation: <a href="http://www.wmo.int/pages/prog/www/WMOCodes/GRIB.html" target="_parent"><br>
-  WMO</a> (the official source)<a href="http://www.nco.ncep.noaa.gov/pmb/docs/grib2/grib2_doc.shtml" target="_parent"><br>
-NCEP</a> (unofficial, but with a user-friendly web interface). 
-<p>A GRIB2 file is a collection of records, each with a complete set of metadata to describe the data contained in the record. A GRIB2 record has 9 sections, some of which may occur more than once. The output from grib2scan is printed out as it scans each section of the record. Below are  examples of the  grib2scan output from   different GRIB2 records. An explanation of the output follows.
-<p><code>
-Record 1 starts at 0 of length <span class="style3">17242</span><br>
-    <span class="style2">Discipline=0</span> (Meteorological)
-  <br>
-  <span class="style1">  Reference Time</span> = 2007-10-09 00:00:00  
-  <span class="style4">Start of Forecast</span>  <br>
-   Field 1 <br>
-    <span class="style5">GDT=0</span> (Lat/Lon) nx*ny=10512
-   <br>
-     XDEF 144 linear 0.000000 2.500000
-  <br>
-     YDEF 73 linear 90.000000 2.500000
-  <br>
-    <span class="style6">PDT=1</span> Forecast Time = 0 Hour 
-  <br>
-     Parameter: <span class="style13">disc,cat,num</span> = 0,3,5  <br>
-     Level: <span class="style8">ltype,lval</span> = 100,20000   (sf,sval = 0 20000) 
-  <br>
-     Ens: <span class="style11">type,pert</span> = 3,1 (total=10) 
-  <br>
-    <span class="style12">DRT=40</span> (Grid Point Data - JPEG2000 Compression) (Lossless)<br>
-  <span class="style15"> ctl: var1.1   0,100,20000  0,3,5   description  </span><br>
-  <br>
-  Record 2 starts at 17242 of length <span class="style3">110483</span>  <br>
-    <span class="style2">Discipline=0</span> (Meteorological)
-  <br>
-    <span class="style1">Reference Time</span> = 2007-10-09 00:00:00  <span class="style4">Start of Forecast</span>  <br>
-   Field 1 
-  <br>
-   
-  <span class="style5">GDT=0</span> (Lat/Lon) nx*ny=259920
-   <br>
-     XDEF 720 linear 0.000000 0.500000
-     <br>
-     YDEF 361 linear 90.000000 0.500000
-  <br>
-    <span class="style6">PDT=8</span> 6 Hour Average EndTime = 2007-10-09 06:00 
-  <br>
-     Parameter: <span class="style13">disc,cat,num,sp</span> = 0,1,7,0
-  <br>
-     Level: <span class="style8">ltype,lval</span> = 1,0   (sf,sval = 0 0) 
-  <br>
-    <span class="style12">DRT=40</span> (Grid Point Data - JPEG2000 Compression) (Lossless)<br>
-   <span class="style15">ctl:  var2.1     0,1,0  0,1,7,0     description </span></code>
-<p><code>Record 3 starts at 16469 of length <span class="style3">2300 </span><br>
-  <span class="style2">  Discipline=0</span> (Meteorological)<br>
-    <span class="style1">Reference Time</span> = 2012-09-11 03:00:00  (Start of Forecast)<br>
-   Field 1 <br>
-    <span class="style5">GDT=30</span> (Lambert Conformal) nx*ny=23865<br>
-     nx=185 ny=129 lon1=226.541000 lat1=12.190000<br>
-     reflon=265.000000 dx=40635.000000 dy=40635.000000<br>
-     latin1=25.000000 latin2=25.000000 <br>
-    <span class="style6">PDT=5</span> 0 Hour Forecast  Valid Time = 2012-09-11 03:00 <br>
-     Parameter: <span class="style13">disc,cat,num</span> = 0,0,0<br>
-     Level: <span class="style8">ltype,lval</span> = 100,85000   (sf,sval = 0 85000)<br>
-     Prob: <span class="style14">type,lim</span> = 0,273  (Probability of event below 273)<br>
-    <span class="style12">DRT=40</span> (Grid Point Data - JPEG2000 Compression) (Lossless) <br>
-   <span class="style15">ctl:  var3.1     0,100,85000   a0,273   0,0,0     description </span><br>
-  <br>
-  Record 4 starts at 37355 of length <span class="style3">205 </span><br>
-  <span class="style2">Discipline=0</span> (Meteorological)<br>
-  <span class="style1">Reference Time</span> = 2012-07-25 00:00:00  (Start of Forecast)<br>
- Field 1 <br>
-  <span class="style5">GDT=0</span> (Lat/Lon) nx*ny=65160<br>
-   XDEF 360 linear 0.000000 1.000000<br>
-   YDEF 181 linear 90.000000 1.000000<br>
-  <span class="style6">PDT=48</span> 0 Hour Forecast  Valid Time = 2012-07-25 00:00 <br>
-   Parameter: <span class="style13">disc,cat,num</span> = 0,20,12<br>
-   Level: <span class="style8">ltype,lval</span> = 10,0   (sf,sval = 0 0)<br>
-   Aerosol: <span class="style14">atyp,styp,s1,s2 </span>= 62001,0,2e-05,0  (size is < 2e-05) <br>
-  <span class="style12">DRT=40</span> (Grid Point Data - JPEG2000 Compression) (Lossless) <br>
- <span class="style15">ctl:  var4.1     0,10,0   a62001,0,2e-05,0   0,20,12     description</span> </code>
-<p>Section 0, the Indicator Section, contains info grib2scan uses to confirm it is looking at a GRIB2 file. This section also contains the <span class="style2">Discipline</span>, as well as the <span class="style3">size of the entire record</span>. 
-<p>Section 1, the Identification Section,  contains characteristics that apply to all data in the record. Sections 0 and 1 are the only ones that may not be repeated in a GRIB2 record. From  section 1 we get the <span class="style1">Reference Time</span> printed in a YYYY-MM-DD HH:MM:SS format, plus the <span class="style4">significance of the reference time</span>.
-<p>Section 3, the Grid Definition Section,  contains the definition of the grid surface and geometry of the data values in the grid. The Grid Definition Template (<span class="style5">GDT</span>) value indicates the grid type -- in Record 1, the data are on a Lat/Lon grid at 2.5-degree resolution; Record 2 has a 0.5-degree Lat/Lon grid. For some <span class="style5">GDT</span> values, grib2scan in verbose mode will print out  helpful information for creating the XDEF and YDEF or PDEF ent [...]
-<p>Section 4, the Product Definition Section,  contains a lot of essential information about the nature of the data -- what the variable is called, its units, its vertical level, its valid time, whether it is part of an ensemble set, and whether it is an instantaneous value or statistically processed in some way. The Product Definition Template (<span class="style6">PDT</span>) value tells grib2scan  where to get the parameter category and number, which, along with the discipline, are re [...]
-If the parameter has been statistically processed (i.e. it is an average or an accumulation over a period of time), then a fourth number is required by GrADS to  indicate the kind of statistical process used to generate the parameter: the <span class="style13">discipline, category, number, and statistical process</span> must go into the descriptor file. In Record 2, the parameter is "Discipline 0: Meterological products, Parameter Category 1: Moisture, Parameter Number 7: Precipitat [...]
-Section 4 also give the parameter's <span class="style8">level type and value</span> -- 
-  
-  these comma-delimited numbers can also be copied from the grib2scan output into your descriptor file. In the first example, the level type is pressure, and the level value is 20000 Pascals (or 200 mb). Note that if a parameter occurs on more than one pressure level, you should use ZDEF to list the pressure level values and omit the level value in the variable declaration. Pressure values are converted back to millibars internally if you use the OPTIONS  keyword "pascals". In  [...]
-
-metadata also appears in section 4. Ensemble metadata is only relevant in Record 1, and appears as an <span class="style11">ensemble type and perturbation number</span>. Parameters that are derived from all ensemble members only require one code, a number that indicates the type of derived forecast (e.g. ensemble mean). These ensemble codes  belong in the exanded form of the EDEF declaration. 
-<p>Starting with <span class="red">GrADS Version 2.0.2</span>, support was added for GRIB2 products that require additional codes. These are for <span class="style6">PDT 5</span> and <span class="style6">9</span> (forecast probabilities) and <span class="style6">PDT 48</span> (aerosol properties). The <span class="style14">additional  codes</span> are listed after the <span class="style13">parameter</span> and <span class="style8">level </span>information. The <span class="style14">addit [...]
-<p>Section 5, the Data Representation Section,  contains information about how the data are represented. The Data Representation Template (<span class="style12">DRT</span>) number is not required in a GrADS descriptor file, but because it is sometimes useful to know how the data are formatted in the GRIB2 file, it is included in the grib2scan output. 
-
-<p>Starting with <span class="red">GrADS Version 2.0.2</span>, another new feature was added to the grib2scan output, a suggestion for a descriptor file entry for each field in the grib2 file. This is shown in<span class="style15"> red</span> at the bottom with the prefix "<span class="style15">ctl: </span>". 
-</body>
-</html>
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->

<html>
<head>
<title>GrADS Utilities: grib2scan</title>
<style type="text/css">
<!--
.style1 {color: #006600}
.style2 {color: #0033FF}
.style3 {color: #996600}
.style4 {color: #006666}
.style5 {color: #993366}
.style6 {color: #FF66FF}
.style8 {color: #990000}
.style11 {color: #00CC33}
.style12 {color: #9900FF}
.style13 {color: #FF6600}
-->
</style>
</head>
<body text="#000000" bgcolor="e0f0ff">

<h2><b>grib2scan</b></h2>

<p>
The <code>grib2scan</code> utility is used for finding out what is inside a GRIB2 data file. It scans each record in the file, and prints out relevant information about the data in the record. 
The command sytax is:
<ul>
<code>grib2scan [-v] <i>fname</i></code></ul>
<p>
Where <code><i>fname</i></code>
 is the input GRIB2 file name, and the <code>-v</code> option is used for verbose output. 
<p>To assist in the interpretation of the grib2scan output, here are some links to GRIB2 documentation: <a href="http://www.wmo.int/pages/prog/www/WMOCodes/GRIB.html" target="_parent"><br>
  WMO</a> (the official source)<a href="http://www.nco.ncep.noaa.gov/pmb/docs/grib2/grib2_doc.shtml" target="_parent"><br>
NCEP</a> (unofficial, but with a user-friendly web interface). 
<p>A GRIB2 file is a collection of records, each with a complete set of metadata to describe the data contained in the record. A GRIB2 record has 9 sections, some of which may occur more than once. The output from grib2scan is printed out as it scans each section of the record. Below are  examples of the  grib2scan output from  two different GRIB2 records. An explanation of the output follows.
<p><code>
Record 1 starts at 0 of length <span class="style3">17242</span><br>
    <span class="style2">Discipline=0</span> (Meteorological)
  <br>
  <span class="style1">  Reference Time</span> = 2007-10-09 00:00:00  
  <span class="style4">Start of Forecast</span>  <br>
   Field 1 <br>
    <span class="style5">GDT=0</span> (Lat/Lon) nx*ny=10512
   <br>
     XDEF 144 linear 0.000000 2.500000
  <br>
     YDEF 73 linear 90.000000 2.500000
  <br>
    <span class="style6">PDT=1</span> Forecast Time = 0 Hour 
  <br>
    Parameter: <span class="style13">disc,cat,num</span> = 0,3,5  <br>
    Level: <span class="style8">ltype,lval</span> = 100,20000   (sf,sval = 0 20000) 
  <br>
    Ens: <span class="style11">type,pert</span> = 3,1 (total=10) 
  <br>
    <span class="style12">DRT=40</span> (Grid Point Data - JPEG2000 Compression) (Lossless) 
  <br>
  <br>
  Record 2 starts at 17242 of length <span class="style3">110483</span>  <br>
    <span class="style2">Discipline=0</span> (Meteorological)
  <br>
    <span class="style1">Reference Time</span> = 2007-10-09 00:00:00  <span class="style4">Start of Forecast</span>  <br>
   Field 1 
  <br>
   
  <span class="style5">GDT=0</span> (Lat/Lon) nx*ny=259920
   <br>
     XDEF 720 linear 0.000000 0.500000
     <br>
     YDEF 361 linear 90.000000 0.500000
  <br>
    <span class="style6">PDT=8</span> (6 Hour Average) EndTime = 2007-10-09 06:00 
  <br>
    Parameter: <span class="style13">disc,cat,num,sp</span> = 0,1,7,0
  <br>
    Level: <span class="style8">ltype,lval</span> = 1,0   (sf,sval = 0 0) 
  <br>
    <span class="style12">DRT=40</span> (Grid Point Data - JPEG2000 Compression) (Lossless) 

  
  
 </code>
<p>Section 0, the Indicator Section, contains info grib2scan uses to confirm it is looking at a GRIB2 file. This section also contains the <span class="style2">Discipline</span>, as well as the <span class="style3">size of the entire record</span>. 
<p>Section 1, the Identification Section,  contains characteristics that apply to all data in the record. Sections 0 and 1 are the only ones that may not be repeated in a GRIB2 record. From  section 1 we get the <span class="style1">Reference Time</span> printed in a YYYY-MM-DD HH:MM:SS format, plus the <span class="style4">significance of the reference time</span>.
<p>Section 3, the Grid Definition Section,  contains the definition of the grid surface and geometry of the data values in the grid. The Grid Definition Template (<span class="style5">GDT</span>) value indicates the grid type -- in Record 1, the data are on a Lat/Lon grid at 2.5-degree resolution; Record 2 has a 0.5-degree Lat/Lon grid. For some <span class="style5">GDT</span> values, grib2scan in verbose mode will print out  helpful information for creating the XDEF and YDEF or PDEF entr [...]
<p>Section 4, the Product Definition Section,  contains a lot of essential information about the nature of the data -- what the variable is called, its units, its vertical level, its valid time, whether it is part of an ensemble set, and whether it is an instantaneous value or statistically processed in some way. The Product Definition Template (<span class="style6">PDT</span>) value tells grib2scan  where to get the parameter category and number, which, along with the discipline, are req [...]
If the parameter has been statistically processed (i.e. it is an average or an accumulation over a period of time), then a fourth number is required by GrADS to  indicate the kind of statistical process used to generate the parameter: the <span class="style13">discipline, category, number, and statistical process</span> must go into the descriptor file. In Record 2, the parameter is "Discipline 0: Meterological products, Parameter Category 1: Moisture, Parameter Number 7: Precipitati [...]
Section 4 also give the parameter's <span class="style8">level type and value</span> -- 
  
  these comma-delimited numbers can also be copied from the grib2scan output into your descriptor file. In the first example, the level type is pressure, and the level value is 20000 Pascals (or 200 mb). Note that if a parameter occurs on more than one pressure level, you should use ZDEF to list the pressure level values and omit the level value in the variable declaration. Pressure values are converted back to millibars internally if you use the OPTIONS  keyword "pascals". In R [...]

metadata also appears in section 4. Ensemble metadata is only relevant in Record 1, and appears as an <span class="style11">ensemble type and perturbation number</span>. Parameters that are derived from all ensemble members only require one code, a number that indicates the type of derived forecast (e.g. ensemble mean). These ensemble codes  belong in the exanded form of the EDEF declaration. 
<p>Section 5, the Data Representation Section,  contains information about how the data are represented. The Data Representation Template (<span class="style12">DRT</span>) number is not required in a GrADS descriptor file, but because it is sometimes useful to know how the data are formatted in the GRIB2 file, it is included in the grib2scan output. 

</body>
</html>
\ No newline at end of file
diff --git a/doc/gradutilgribmap.html b/doc/gradutilgribmap.html
index 593ea36..ed04797 100644
--- a/doc/gradutilgribmap.html
+++ b/doc/gradutilgribmap.html
@@ -1 +1,143 @@
-<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->

<html>
<head>
<title>GrADS Utilities: gribmap</title>
<style type="text/css">
<!--
.style1 {color: #990000}
-->
</style>
</head>
<body text="#000000" bgcolor="e0f0ff">

<h2><b>gribmap</b></h2>

<p>
The GrADS data descriptor file defines a grid structure into which
the data will fit -- it gives "shape" to the data by identifying its
spatial dimensions, the number of time steps, and the number of variables. 
<p>
If the data is in binary format, its <a
href="aboutgriddeddata.html#structure">structure</a> has already been
prescribed. If the data is in GRIB format, no consistent 
relationship exists between the data and the grid structure defined in the data
descriptor file. Hence, the need for the <code>gribmap</code> utility which "maps"
between the GRIB data and the GrADS data description.
<p>
As <code>gribmap</code> reads each field in the GRIB data file, the
parameters for that field (e.g. variable name, vertical level, time)
are compared to the information in the data descriptor file until 
a match is found. The process continues until all the GRIB elements have been 
"mapped" to their location within the GrADS grid structure.
<table width="680" border="0" cellpadding="5" cellspacing="5" class="plaintext">
  <tr bgcolor="c5d5ff">
    <td colspan="2" bordercolor="#F4F4F4" bgcolor="#E0F0FF"><p>The syntax for the <code>gribmap</code> command is as follows:</p>
      <p>      <code>���gribmap [<i>options</i>] </code></p>
      <p>Command line <code><i>options</i></code> are:<br>
      </p></td>
  </tr>
  
  <tr bgcolor="c5d5ff">
    <td width="100"><code>-0</code></td>
    <td>Ignores the forecast time when setting up a match, so that the base time is the valid time.</td>
  </tr>
  <tr bgcolor="c5d5ff">
    <td width="100"><code>-b</code></td>
    <td>Valid time for averages is set to be the beginning of the period rather than 
        the end. Default valid time is the end of the averaging period<code>.</code>    </td>
  </tr>
  <tr bgcolor="c5d5ff">
    <td><code>-big</code></td>
    <td>(<span class="style1">GrADS version 2.0.a8</span>) Required option if the GRIB1 or GRIB2 files are > 2 Gb. This option creates a bigger index file, which cannot be read by earlier versions of GrADS. </td>
  </tr>
  <tr bgcolor="c5d5ff">
    <td><code>-e<br>
      -E</code></td>
    <td>Ignores extra bytes (that are not part of the GRIB1 msg) at end of file. Some ECMWF GRIB files require this option because 
      of blocking. 
      Using the <code>-E</code> option ignores extra bytes in middle and/or end of GRIB file. </td>
  </tr>
  <tr bgcolor="c5d5ff">
    <td width="100"><code>-f<i>hr</i></code></td>
    <td>Matches only those grib records whose forecast time is <code><i>hr</i></code> hours. This is used to isolate a sequence of forecasts. For example, if you 
        wanted to sample all the 120-hour forecasts from the MRF ensemble runs, you 
        would use <code>gribmap -f120</code>.      </td>
  </tr>
  <tr bgcolor="c5d5ff">
    <td><code>-h<i>num</i></code></td>
    <td>Skips over <code><i>num</i></code> bytes before starting the scan process. </td>
  </tr>
  <tr bgcolor="c5d5ff">
    <td><code>-help</code></td>
    <td>Prints out the list of options </td>
  </tr>
  <tr bgcolor="c5d5ff">
    <td><code>-i <i>fname</i></code></td>
    <td><code><i>fname</i></code> is the name of the data descriptor file. If 
      not specified, <code>gribmap</code> will prompt the user. </td>
  </tr>
  <tr bgcolor="c5d5ff">
    <td><code>-m</code></td>
    <td>Use base time from descriptor file instead of GRIB header. This option only works with GRIB1.</td>
  </tr>
  <tr bgcolor="c5d5ff">
    <td><code>-min0</code></td>
    <td>Ignores the minutes code. </td>
  </tr>
  <tr bgcolor="c5d5ff">
    <td><code>-N</code></td>
    <td>Does NOT write out the index file. </td>
  </tr>
  <tr bgcolor="c5d5ff">
    <td><code>-q</code></td>
    <td> Quiet mode -- suppresses all messages except for errors. Default is off.</td>
  </tr>
  <tr bgcolor="c5d5ff">
    <td><code>-s<i>num</i></code></td>
    <td>Skips over no more than<em><code> num </code></em>bytes between records. The 
      default is 1000. </td>
  </tr>
  <tr bgcolor="c5d5ff">
    <td><code>-t0</code></td>
    <td>Matches only those grib records whose base time is the same as the initial 
      time in the data descriptor file. This is used to pull out a forecast sequence 
      (0, 12, 24, ... , 72 hours) starting a specific time. </td>
  </tr>
  <tr bgcolor="c5d5ff">
    <td width="100"><code>-u</code></td>
    <td><p>
    Updates existing gribmap if adding data files are being added to <a href="templates.html">templated</a> data set. This option has been (temporarily) disabled in GrADS version 2.0.     </td>
  </tr>
  <tr bgcolor="c5d5ff">
    <td><code>-v</code></td>
    <td> Verbose mode -- detailed output makes it easier to verify what is being mapped. 
      Default is off. </td>
  </tr>
</table>
<p>

</body>
</html>

\ No newline at end of file
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
+
+<html>
+<head>
+<title>GrADS Utilities: gribmap</title>
+<style type="text/css">
+<!--
+.style1 {color: #990000}
+-->
+</style>
+</head>
+<body text="#000000" bgcolor="e0f0ff">
+
+<h2><b>gribmap</b></h2>
+
+<p>
+The GrADS data descriptor file defines a grid structure into which
+the data will fit -- it gives "shape" to the data by identifying its
+spatial dimensions, the number of time steps, and the number of variables. 
+<p>
+If the data is in binary format, its <a
+href="aboutgriddeddata.html#structure">structure</a> has already been
+prescribed. If the data is in GRIB format, no consistent 
+relationship exists between the data and the grid structure defined in the data
+descriptor file. Hence, the need for the <code>gribmap</code> utility which "maps"
+between the GRIB data and the GrADS data description.
+<p>
+As <code>gribmap</code> reads each field in the GRIB data file, the
+parameters for that field (e.g. variable name, vertical level, time)
+are compared to the information in the data descriptor file until 
+a match is found. The process continues until all the GRIB elements have been 
+"mapped" to their location within the GrADS grid structure. Please read the documentation on <a href="grib.html">Handling GRIB in GrADS</a> for more details. 
+<h3>Syntax</h3>
+<table width="680" border="0" cellpadding="5" cellspacing="5" class="plaintext">
+  <tr bgcolor="c5d5ff">
+    <td colspan="2" bordercolor="#F4F4F4" bgcolor="#E0F0FF"><p><code>gribmap [<i>options</i>] </code></p>
+      <p>Command line <code><i>options</i></code> are:<br>
+    </p></td>
+  </tr>
+  
+  <tr bgcolor="c5d5ff">
+    <td width="100"><code>-0</code></td>
+    <td>Ignores the forecast time when setting up a match, so that the base time is the valid time.</td>
+  </tr>
+  <tr bgcolor="c5d5ff">
+    <td width="100"><code>-b</code></td>
+    <td>Valid time for averages is set to be the beginning of the period rather than 
+        the end. Default valid time is the end of the averaging period<code>.</code>    </td>
+  </tr>
+  <tr bgcolor="c5d5ff">
+    <td><code>-big</code></td>
+    <td>(<span class="style1">GrADS version 2.0.a8+</span>) Required option if the GRIB1 or GRIB2 files are > 2 Gb. This option creates a bigger index file, which cannot be read by earlier versions of GrADS. </td>
+  </tr>
+  <tr bgcolor="c5d5ff">
+    <td><code>-e<br>
+      -E</code></td>
+    <td>Ignores extra bytes (that are not part of the GRIB1 msg) at end of file. Some ECMWF GRIB files require this option because 
+      of blocking. 
+      Using the <code>-E</code> option ignores extra bytes in middle and/or end of GRIB file. </td>
+  </tr>
+  <tr bgcolor="c5d5ff">
+    <td width="100"><code>-f<i> hr</i></code></td>
+    <td>Matches only those grib records whose forecast time is <code><i>hr</i></code> hours. This is used to isolate a sequence of forecasts. For example, if you 
+        wanted to sample all the 120-hour forecasts from the MRF ensemble runs, you 
+        would use <code>gribmap -f120</code>.      </td>
+  </tr>
+  <tr bgcolor="c5d5ff">
+    <td><code>-h<i> num</i></code></td>
+    <td>Skips over <code><i>num</i></code> bytes before starting the scan process. </td>
+  </tr>
+  <tr bgcolor="c5d5ff">
+    <td><code>-help</code></td>
+    <td>Prints out the list of options </td>
+  </tr>
+  <tr bgcolor="c5d5ff">
+    <td><code>-i <i>fname</i></code></td>
+    <td><code><i>fname</i></code> is the name of the data descriptor file. If 
+      not specified, <code>gribmap</code> will prompt the user. </td>
+  </tr>
+  <tr bgcolor="c5d5ff">
+    <td><code>-m</code></td>
+    <td>Use base time from descriptor file instead of GRIB header. This option only works with GRIB1.</td>
+  </tr>
+  <tr bgcolor="c5d5ff">
+    <td><code>-min0</code></td>
+    <td>Ignores the minutes code. </td>
+  </tr>
+  <tr bgcolor="c5d5ff">
+    <td><code>-N</code></td>
+    <td>Does NOT write out the index file. </td>
+  </tr>
+  <tr bgcolor="c5d5ff">
+    <td><code>-new</code></td>
+    <td>(<span class="style1">GrADS version 2.1.a2+</span>) Creates a new version of an existing index file</td>
+  </tr>
+  <tr bgcolor="c5d5ff">
+    <td><code>-old</code></td>
+    <td>(<span class="style1">GrADS version 2.1.a2+</span>) Creates an old version of an existing index file</td>
+  </tr>
+  <tr bgcolor="c5d5ff">
+    <td><code>-q</code></td>
+    <td> Quiet mode -- suppresses all messages except for errors. Default is off.</td>
+  </tr>
+  <tr bgcolor="c5d5ff">
+    <td><code>-s<i> num</i></code></td>
+    <td>Skips over no more than<em><code> num </code></em>bytes between records. The 
+      default is 1000. </td>
+  </tr>
+  <tr bgcolor="c5d5ff">
+    <td><code>-t0</code></td>
+    <td>Matches only those grib records whose base time is the same as the initial 
+      time in the data descriptor file. This is used to pull out a forecast sequence 
+      (0, 12, 24, ... , 72 hours) starting a specific time. </td>
+  </tr>
+  <tr bgcolor="c5d5ff">
+    <td width="100"><code>-u</code></td>
+    <td><p>
+    Updates existing index file when expanding the size of the T or E dimensions in a <a href="templates.html">templated</a> data set. Only one dimension may be expanded at a time. This option was temporarily disabled in GrADS version 2.0.*, but is back in <span class="style1">version 2.1.a2</span>. (See Usage Notes and Examples below.)</td>
+  </tr>
+  <tr bgcolor="c5d5ff">
+    <td><code>-v</code></td>
+    <td> Verbose mode -- detailed output makes it easier to verify what is being mapped. 
+      Default is off. </td>
+  </tr>
+</table>
+<p> </p>
+<h3>Usage Notes</h3>
+<p>Over the many years of GrADS development, the contents of the index file created by <code>gribmap</code> have changed only a few times. Although it is not present in the user interface, there is a version number associated with the index file. When the contents of the index are different and the version has been upgraded, you will get an error message when trying to read that file with an older version of GrADS. Index files created with <code>gribmap</code> version <span class="style1 [...]
+<p>The <code>-old</code> option (introduced with GrADS version<span class="style1"> 2.1.a2</span>) allows you to downgrade the version of an index file so that it may be read by any version of GrADS. The <code>-old</code> option does not re-scan the GRIB files, it merely alters the metadata in the index file's header to match the old version. There are some cases when the <code>-old</code> option cannot be used: an index file that was created with the <code>-big</code> option cannot be d [...]
+<p>The <code>-u</code> option was disabled in version <span class="style1">2.0*</span> because of the introduction of the E dimension, but has been  restored in version <span class="style1">2.1.a2</span>, so that now both the T and E dimensions can be updated. The EDEF and TDEF entries must be updated separately -- only one dimension can be expanded at a time. Reviving the update feature necessitated a change to the metadata in the index file's header, so the index version  has changed w [...]
+<p>If you have an old index file that you would like to update, first use the <code>-new</code> option to rewrite the index file with the additional metadata. The <code>-new</code> option does not re-scan the GRIB files, it merely upgrades the metadata in the index file's header.</p>
+<p> </p>
+<h3>Example</h3>
+<p>Suppose you have an existing GRIB dataset (a reanalysis) that needs to have its time axis extended. To use the update feature without having to re-scan all files, follow these steps:  </p>
+<p>1.  Do not alter the descriptor file (yet). Run<code> gribmap -new </code>to upgrade the metadata in the index file and change the index version.<br>
+  2. Edit the descriptor file to expand the TDEF size. Do not change the name of the file in the INDEX entry. <br>
+  3. Run<code> gribmap -u </code>with the edited descriptor file.<br>
+  4. Run<code> gribmap -old </code>to downgrade the metadata in the new index file.</p>
+<p>Step #4 is optional, but it allows older versions of GrADS to read the updated data file. Without step #4, only the newest version of GrADS (<span class="style1">2.1.a2+</span>) will be able to open the updated descriptor file. </p>
+<p> </p>
+</body>
+</html>
+
diff --git a/doc/imageoutput.html b/doc/imageoutput.html
index 35af36e..d4e6e2b 100644
--- a/doc/imageoutput.html
+++ b/doc/imageoutput.html
@@ -1,143 +1 @@
-<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
-
-<html>
-<head>
-<title>GrADS Image Output</title></head>
-<body bgcolor="e0f0ff" text="#000000">
-
-<h2><b>Producing Hardcopy and Image Output from GrADS</b></h2>
-
-<h3>Generating Image Files from GrADS</h3>
-
-There are several GrADS commands that will convert the
-contents of the graphics window into an image file. The differences
-between them are the image formats they support and the way they are
-implemented in GrADS. 
-<p>
-<b><i>printim</i></b>
-<p>
-The <a href="gradcomdprintim.html"><code>printim</code></a> command
-was introduced in version 1.8. It produces a PNG, GIF, or JPG formatted image file based on the current
-contents of the GrADS metabuffer, which is the stuff displayed in the
-graphics window, minus any widgets. <a
-href="gradcomdprintim.html"><code>printim</code></a> will work in
-batch mode. 
-<p><b><i>outxwd</i></b>
-<p> The <code><a href="gradcomdoutxwd.html">outxwd</a></code> command draws the contents of the graphics display window to a file in XWD (X window dump) format. It does not work in batch mode. 
-<p><b><i>wi</i></b>
-<p> The <code><a href="gradcomdwi.html">wi</a></code> command was deprecated long ago and is not included in version 1.9 or later. 
-<p>
-<h3>Generating GrADS metafiles</h3>
-
-<p>
-<b><i>1. Set-up the GrADS metafile</i></b>
-<p>
-The first step in creating hardcopy image output is to invoke the <code><a href="gradcomdenableprint.html">enable print</a></code> command -- this opens the output file<em><code> </code></em>and enables
-GrADS to direct image information to that file. If the file exists, it will be overwritten.
-
-<p>
-<b><i>2. Display the image</i></b>
-<p>
-The next step is to display the graphic that you want to print. When
-you have finished, issue the <code><a href="gradcomdprint.html">print</a></code>command. GrADS copies the vector instructions used to create the current
-display into the output file in a GrADS metacode format.
-
- For multiple images in your metafile, use <code><a href="gradcomdclear.html">clear</a></code>, create the new image, and then <a href="gradcomdprint.html"><code>print</code></a> again.
-
-<p>
-<b><i>3. Close the GrADS metafile</i></b>
-<p>
-There are three way to close the output file:
-<br>
-<a href="gradcomddisableprint.html"><code>disable print</code></a><br>
-<a href="gradcomdreinit.html"><code>reinit</code></a><br>
-<a href="gradcomdquit.html"><code>quit</code></a><br>
-
-<p>
-<h3>Converting GrADS Metafiles to Postscript</h3>
-
-<p>
-GrADS metacode files may be translated into postscript using the GrADS
-external utilities <a href="gradutilgxps.html"><code>gxps</code></a> and <a
-href="gradutilgxeps.html"><code>gxeps</code></a>. Both utilities will
-prompt for input and output filenames, unless they
-are provided on the command line. The input filename should be the
-file created by the <a href="gradcomdenableprint.html"> <code>enable
-print</code></a> command. The output filename can be anything, but a
-".ps" extension is conventional. Any existing file with this name will
-be overwritten. Once the output file is created, you may print it
-using UNIX print commands. Please consult the references pages for 
-<a href="gradutilgxps.html"><code>gxps</code></a> and 
-<a href="gradutilgxeps.html"><code>gxeps</code></a> to see 
-all the command line arguments and options.
-
-<p>
-<a href="gradutilgxps.html"><code>gxps</code></a> and <a
-href="gradutilgxeps.html"><code>gxeps</code></a> are not
-GrADS commands. They must be executed from the UNIX command line, or
-preceded by a <a href="gradcomdshell.html"><code>!</code></a> and
-executed as a shell command from the GrADS command line.
-<p>
-
-<h3>Generating Postscript from  within GrADS </h3>
-<p> There is a shortcut for creating an encapsulated postscript (EPS) file directly from within a GrADS session: use the <a href="gradcomdprint.html"><code>print</code></a> command without invoking the <code><a href="gradcomdenableprint.html">enable print</a></code> command first. This shortcut allows the user to skip the steps of creating the GrADS metafile and invoking the external utility <a
-href="gradutilgxeps.html"><code>gxeps</code></a>. However, using this shortcut means there can only be one image per file, and none of the options available when invoking <a
-href="gradutilgxeps.html"><code>gxeps</code></a> directly can be used.
-
-<p>
-<h3>Displaying GrADS Metafiles</h3>
-
-<p>
-GrADS metacode files may be displayed using the GrADS external utility
-<a href="gradutilgxtran.html"><code>gxtran</code></a>. The input
-filename should be the file created by the <a
-href="gradcomdenableprint.html"> <code>enable print</code></a>
-command. If the GrADS metafile contains more than one image, <a
-href="gradutilgxtran.html"><code>gxtran</code></a> will animate them.
-The animation can be automatic or controlled by the user with carriage
-returns.  Please consult the <a
-href="gradutilgxtran.html"></code>gxtran</code> reference page</a> to
-see all the command line arguments and options.
-
-<p>
-<h3>Displaying GrADS Metafiles with Windows 95/NT</h3>
-
-<p>
-The GrADS metafile Viewer (GV) allows you to view and manipulate GrADS
-graphics output files using Windows 95/NT. There are two files to download:
-<ul>
-<li> <a href="ftp://cola.gmu.edu/grads/gv/gv32.exe">gv32.exe</a>
-<li> <a href="ftp://cola.gmu.edu/grads/gv/gv32.hlp">gv32.hlp</a>
-</ul>
-<p>
-To open the metafile simply double click on a file listed in the File
-Manager or Explorer, drag and drop the file onto GV, or use the
-standard <i>Open</i> dialog box. GV assumes that default extension of GRADS
-metafiles is GMF. If your file includes more than one picture you can
-browse through pages using the keyboard keys (PageDown and PageUp) or the
-toolbar buttons.
-<p>
-Use the <i>View</i> commands and the <i>View/Options</i>
-dialog box to customize the image -- display it as black-and-white or
-color, change the line thickness, or clip and enlarge any part of the
-image.  Use the right mouse button to access the most commonly used
-features.
-<p>
-There are two ways to save separate pages of a GRADS metafile as
-Windows Metafile (WMF): 1) use the <i>File/Save Page As</i>
-command, or 2) use the <i>Edit/Copy</i> command to copy the
-current page to the Windows Clipboard and then <i>Edit/Paste</i>
-it in your favorite Windows application that handles Windows
-Metafiles.
-<p>
-Use <i>File/Print</i> command to print a current document <b>to
-any printer</b> (you do not need a Postscript printer).  Use
-<i>File/Print Preview</i> to display the active metafile as it
-would appear when printed.
-<p>
-
-
-</body>
-</html>
-
-
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->

<html>
<head>
<title>GrADS Image Output</title></head>
<body bgcolor="e0f0ff" text="#000000">

<h2><b>Producing Hardcopy and Image Output from GrADS</b></h2>

<h3>Generating Image Files from GrADS</h3>

There are several GrADS commands that will convert the
contents of the graphics window into an image file. The differences
between them are the image formats they support and the way they are
implemented in GrADS. 
<p>
<b><i>printim</i></b>
<p>
The <a href="gradcomdprintim.html"><code>printim</code></a> command
was introduced in version 1.8. It produces a PNG, GIF, or JPG formatted image file based on the current
contents of the GrADS metabuffer, which is the stuff displayed in the
graphics window, minus any widgets. <a
href="gradcomdprintim.html"><code>printim</code></a> will work in
batch mode. 
<p><b><i>outxwd</i></b>
<p> The <code><a href="gradcomdoutxwd.html">outxwd</a></code> command draws the contents of the graphics display window to a file in XWD (X window dump) format. It does not work in batch mode. 
<p><b><i>wi</i></b>
<p> The <code><a href="gradcomdwi.html">wi</a></code> command was deprecated long ago and is not included in version 1.9 or later. 
<p>
<h3>Generating GrADS metafiles</h3>

<p>
<b><i>1. Set-up the GrADS metafile</i></b>
<p>
The first step in creating hardcopy image output is to invoke the <code><a href="gradcomdenableprint.html">enable print</a></code> command -- this opens the output file<em><code> </code></em>and enables
GrADS to direct image information to that file. If the file exists, it will be overwritten.

<p>
<b><i>2. Display the image</i></b>
<p>
The next step is to display the graphic that you want to print. When
you have finished, issue the <code><a href="gradcomdprint.html">print</a></code>command. GrADS copies the vector instructions used to create the current
display into the output file in a GrADS metacode format.

 For multiple images in your metafile, use <code><a href="gradcomdclear.html">clear</a></code>, create the new image, and then <a href="gradcomdprint.html"><code>print</code></a> again.

<p>
<b><i>3. Close the GrADS metafile</i></b>
<p>
There are three way to close the output file:
<br>
<a href="gradcomddisableprint.html"><code>disable print</code></a><br>
<a href="gradcomdreinit.html"><code>reinit</code></a><br>
<a href="gradcomdquit.html"><code>quit</code></a><br>

<p>
<h3>Converting GrADS Metafiles to Postscript</h3>

<p>
GrADS metacode files may be translated into postscript using the GrADS
external utilities <a href="gradutilgxps.html"><code>gxps</code></a> and <a
href="gradutilgxeps.html"><code>gxeps</code></a>. Both utilities will
prompt for input and output filenames, unless they
are provided on the command line. The input filename should be the
file created by the <a href="gradcomdenableprint.html"> <code>enable
print</code></a> command. The output filename can be anything, but a
".ps" extension is conventional. Any existing file with this name will
be overwritten. Once the output file is created, you may print it
using UNIX print commands. Please consult the references pages for 
<a href="gradutilgxps.html"><code>gxps</code></a> and 
<a href="gradutilgxeps.html"><code>gxeps</code></a> to see 
all the command line arguments and options.

<p>
<a href="gradutilgxps.html"><code>gxps</code></a> and <a
href="gradutilgxeps.html"><code>gxeps</code></a> are not
GrADS commands. They must be executed from the UNIX command line, or
preceded by a <a href="gradcomdshell.html"><code>!</code></a> and
executed as a shell command from the GrADS command line.
<p>

<h3>Generating Postscript from  within GrADS </h3>
<p> There is a shortcut for creating an encapsulated postscript (EPS) file directly from within a GrADS session: use the <a href="gradcomdprint.html"><code>print</code></a> command without invoking the <code><a href="gradcomdenableprint.html">enable print</a></code> command first. This shortcut allows the user to skip the steps of creating the GrADS metafile and invoking the external utility <a
href="gradutilgxeps.html"><code>gxeps</code></a>. However, using this shortcut means there can only be one image per file, and none of the options available when invoking <a
href="gradutilgxeps.html"><code>gxeps</code></a> directly can be used.

<p>
<h3>Displaying GrADS Metafiles</h3>

<p>
GrADS metacode files may be displayed using the GrADS external utility
<a href="gradutilgxtran.html"><code>gxtran</code></a>. The input
filename should be the file created by the <a
href="gradcomdenableprint.html"> <code>enable print</code></a>
command. If the GrADS metafile contains more than one image, <a
href="gradutilgxtran.html"><code>gxtran</code></a> will animate them.
The animation can be automatic or controlled by the user with carriage
returns.  Please consult the <a
href="gradutilgxtran.html"></code>gxtran</code> reference page</a> to
see all the command line arguments and options.

<p>
<h3>Displaying GrADS Metafiles with Windows 95/NT</h3>

<p>
The GrADS metafile Viewer (GV) allows you to view and manipulate GrADS
graphics output files using Windows 95/NT. There are two files to download:
<ul>
<li> <a href="ftp://grads.iges.org/grads/gv/gv32.exe">gv32.exe</a>
<li> <a href="ftp://grads.iges.org/grads/gv/gv32.hlp">gv32.hlp</a>
</ul>
<p>
To open the metafile simply double click on a file listed in the File
Manager or Explorer, drag and drop the file onto GV, or use the
standard <i>Open</i> dialog box. GV assumes that default extension of GRADS
metafiles is GMF. If your file includes more than one picture you can
browse through pages using the keyboard keys (PageDown and PageUp) or the
toolbar buttons.
<p>
Use the <i>View</i> commands and the <i>View/Options</i>
dialog box to customize the image -- display it as black-and-white or
color, change the line thickness, or clip and enlarge any part of the
image.  Use the right mouse button to access the most commonly used
features.
<p>
There are two ways to save separate pages of a GRADS metafile as
Windows Metafile (WMF): 1) use the <i>File/Save Page As</i>
command, or 2) use the <i>Edit/Copy</i> command to copy the
current page to the Windows Clipboard and then <i>Edit/Paste</i>
it in your favorite Windows application that handles Windows
Metafiles.
<p>
Use <i>File/Print</i> command to print a current document <b>to
any printer</b> (you do not need a Postscript printer).  Use
<i>File/Print Preview</i> to display the active metafile as it
would appear when printed.
<p>


</body>
</html>


\ No newline at end of file
diff --git a/doc/images/basemapUS.png b/doc/images/basemapUS.png
new file mode 100644
index 0000000..6a7c8f9
Binary files /dev/null and b/doc/images/basemapUS.png differ
diff --git a/doc/images/basemap_demo.png b/doc/images/basemap_demo.png
new file mode 100644
index 0000000..5e12abb
Binary files /dev/null and b/doc/images/basemap_demo.png differ
diff --git a/doc/images/basemap_demo2.png b/doc/images/basemap_demo2.png
new file mode 100644
index 0000000..d65abd3
Binary files /dev/null and b/doc/images/basemap_demo2.png differ
diff --git a/doc/images/cmarks.png b/doc/images/cmarks.png
new file mode 100644
index 0000000..d48c186
Binary files /dev/null and b/doc/images/cmarks.png differ
diff --git a/doc/images/letters.png b/doc/images/letters.png
new file mode 100644
index 0000000..bce88c0
Binary files /dev/null and b/doc/images/letters.png differ
diff --git a/doc/images/pattern_demo.png b/doc/images/pattern_demo.png
new file mode 100644
index 0000000..c2205c9
Binary files /dev/null and b/doc/images/pattern_demo.png differ
diff --git a/doc/images/pattern_demo2.png b/doc/images/pattern_demo2.png
new file mode 100644
index 0000000..02763be
Binary files /dev/null and b/doc/images/pattern_demo2.png differ
diff --git a/doc/images/shp_demo4.png b/doc/images/shp_demo4.png
new file mode 100644
index 0000000..399c0cf
Binary files /dev/null and b/doc/images/shp_demo4.png differ
diff --git a/doc/images/strpos.png b/doc/images/strpos.png
new file mode 100644
index 0000000..e74ffab
Binary files /dev/null and b/doc/images/strpos.png differ
diff --git a/doc/indexlist.html b/doc/indexlist.html
index f703828..b9059fc 100644
--- a/doc/indexlist.html
+++ b/doc/indexlist.html
@@ -1,770 +1 @@
-<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
-
-<html>
-<head>
-<title>Documentation Index</title>
-<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
-<link href="GrADS.css" rel="stylesheet" type="text/css">
-</head>
-<body bgcolor="#e0f0ff" text="#000000">
-<a name="indexa">
-<table cellpadding=2 border=0 WIDTH=20>
-<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-<font color="fffacd"><b>A</b></font></td></tr>
-</table>
-</a>
-
-<p class="plaintext">
-<code><a href="gradfuncaave.html" target="pages">aave()</a></code><br>
-<code><a href="gradfuncabs.html" target="pages">abs()</a></code><br>
-<code><a href="gradfuncacos.html" target="pages">acos()</a></code><br>
-<a href="templates.html" target="pages">aggregate data files</a><br>
-<code><a href="gradfuncamax.html" target="pages">amax()</a></code><br>
-<code><a href="gradfuncamaxlocx.html" target="pages">amaxlocx()</a></code><br>
-<code><a href="gradfuncamaxlocy.html" target="pages">amaxlocy()</a></code><br>
-<code><a href="gradfuncamean.html" target="pages">amean()</a></code><br>
-<code><a href="gradfuncamin.html" target="pages">amin()</a></code><br>
-<code><a href="gradfuncaminlocx.html" target="pages">aminlocx()</a></code><br>
-<code><a href="gradfuncaminlocy.html" target="pages">aminlocy()</a></code><br>
-<a href="animation.html" target="pages">animation</a><br>
-<code>set <a href="gradcomdsetannot.html" target="pages">annot</a></code><br>
-<code>set <a href="gradcomdsetarrlab.html" target="pages">arrlab</a></code><br>
-<code>set <a href="gradcomdsetarrowhead.html" target="pages">arrowhead</a></code><br>
-<code>set <a href="gradcomdsetarrscl.html" target="pages">arrscl</a></code><br>
-<code><a href="gradfuncasin.html" target="pages">asin()</a></code><br>
-<code><a href="gradfuncasum.html" target="pages">asum()</a></code><br>
-<code><a href="gradfuncasumg.html" target="pages">asumg()</a></code><br>
-<code><a href="gradfuncatan2.html" target="pages">atan2()</a></code><br>
-<a href="http://dao.gsfc.nasa.gov/software/grads/win32/latest/pc-dist/doc/gagui/gagui_intro.html" target="_top">athena widgets</a><br>
-<code><a href="gradfuncatot.html" target="pages">atot()</a></code><br>
-<code><a href="gradcomdqattr.html" target="pages">q </a>attr</code><br> 
-<code><a href="gradfuncave.html" target="pages">ave()</a></code><br>
-<p>
-<a name="indexb">
-<table cellpadding=2 border=0 WIDTH=20>
-<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-<font color="fffacd"><b>B</b></font></td></tr>
-</table>
-</a>
-
-<p class="plaintext">
-<code>set <a href="gradcomdsetbackground.html" target="pages">background</a></code><br>
-<code>set <a href="gradcomdsetbarbase.html" target="pages">barbase</a></code><br>
-<code>set <a href="gradcomdsetbargap.html" target="pages">bargap</a></code><br>
-<code>set <a href="gradcomdsetbaropts.html" target="pages">baropts</a></code><br>
-<a href="basic.html" target="pages">basic operation</a><br>
-<a href="aboutgriddeddata.html" target="pages">binary data sets</a><br>
-<code>set <a href="gradcomdsetblack.html" target="pages">black</a></code><br>
-  <a href="bufrformat.html" target="pages">BUFR format</a><br>
-<code><a href="gradutilbufrscan.html" target="pages">bufrscan</a></code>  <br>
-<a href="supplibs.html" target="pages">build  from source</a><br>
-<code>draw <a href="gradcomddrawbutton.html" target="pages">button</a></code><br>
-<code>redraw <a href="gradcomdredrawbutton.html" target="pages">button</a></code><br>
-<code>set <a href="gradcomdsetbutton.html" target="pages">button</a></code><br>
-<p>
-<a name="indexc">
-<table cellpadding=2 border=0 WIDTH=20>
-<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-<font color="fffacd"><b>C</b></font></td></tr>
-</table>
-</a>
-
-<p class="plaintext">
-<code><a href="gradcomdquery.html" target="pages">q </a>cache</code><br> 
-<code><a href="gradcomdquery.html" target="pages">q</a> cachesf</code><br> 
-<code>set <a href="gradcomdsetcachesf.html" target="pages">cachesf</a></code><br>
-<a href="gradcomddrawdropmenu.html" target="pages">cascading dropmenus</a><br>
-<code>set <a href="gradcomdsetccolor.html" target="pages">ccolor</a></code><br>
-<code>set <a href="gradcomdsetccols.html" target="pages">ccols</a></code><br>
-<code><a href="gradfunccdiff.html" target="pages">cdiff()</a></code><br>
-<code><a href="templates.html#chsub" target="pages">chsub</a></code><br>
-<code>set <a href="gradcomdsetchunksize.html" target="pages">chunksize</a></code><br> 
-<code>set <a href="gradcomdsetcint.html" target="pages">cint</a></code><br> 
-<code>set <a href="gradcomdsetclab.html" target="pages">clab</a></code><br>
-<code><a href="gradcomdclear.html" target="pages">clear</a></code><br>
-<code>set <a href="gradcomdsetclevs.html" target="pages">clevs</a></code><br>
-<code>set <a href="gradcomdsetclip.html" target="pages">clip</a></code><br>
-<code>set <a href="gradcomdsetclopts.html" target="pages">clopts</a></code><br>
-<code><a href="gradcomdclose.html" target="pages">close</a></code><br>
-<code>set <a href="gradcomdsetclskip.html" target="pages">clskip</a></code><br>
-<code>set <a href="gradcomdsetcmark.html" target="pages">cmark</a></code><br>
-<code>set <a href="gradcomdsetcmax.html" target="pages">cmax</a></code><br>
-<code>set <a href="gradcomdsetcmin.html" target="pages">cmin</a></code><br>
-<code><a href="gradcomdcollect.html" target="pages">collect</a></code><br>
-<code><a href="gradfunccoll2gr.html" target="pages">coll2gr()</a></code><br>
-default <a href="16colors.html" target="pages">colors</a><br>
-controlling <a href="colorcontrol.html" target="pages">colors</a><br>
-<a href="commandline.html" target="pages">command line editing</a><br>
-<a href="commandsatt.html" target="pages">commands: attribute</a><br>
-<a href="compression.html" target="pages">compression</a><br>
-<code><a href="gradcomdquery.html" target="pages">q</a> config</code><br> 
-<code><a href="gradfuncconst.html" target="pages">const()</a></code><br>
-<code><a href="gradcomdquery.html" target="pages">q</a> contours</code><br> 
-<a href="descriptorfile.html" target="pages">control file</a><br>
-<a href="gradfuncscorr.html" target="pages">correlation, spatial</a><br>
-<a href="gradfunctcorr.html" target="pages">correlation, temporal</a><br>
-<code><a href="gradfunccos.html" target="pages">cos()</a></code><br>
-<code>set <a href="gradcomdsetcoslat.html" target="pages">coslat</a></code><br>
-<a href="usingstationdata.html#xsection" target="pages">cross sections</a><br>
-<code>set <a href="gradcomdsetcsmooth.html" target="pages">csmooth</a></code><br>
-<code>set <a href="gradcomdsetcstyle.html" target="pages">cstyle</a></code><br>
-<code>set <a href="gradcomdsetcterp.html" target="pages">cterp</a></code><br>
-<code><a href="gradcomdquery.html" target="pages">q</a> ctlinfo</code><br> 
-<code>set <a href="gradcomdsetcthick.html" target="pages">cthick</a></code><br> 
-</font>
-
-<p>
-<a name="indexd">
-<table cellpadding=2 border=0 WIDTH=20>
-<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-<font color="fffacd"><b>D</b></font></td></tr>
-</table>
-</a>
-
-<p class="plaintext">
-data descriptor files:<br>
-  <a href="descriptorfile.html" target="pages">elements</a><br>
-  <a href="bufrformat.html" target="pages">for BUFR data</a><br>
-  <a href="aboutgriddeddata.html#descriptor" target="pages">for gridded data</a><br>
-    <a href="SDFdescriptorfile.html" target="pages">for NetCDF/HDF files</a><br>
-  <a href="aboutstationdata.html#descriptor" target="pages">for station data</a><br>
-<a href="aboutgriddeddata.html" target="pages">data sets (gridded)</a><br>
-<a href="aboutstationdata.html" target="pages">data sets (station)</a><br>
-<code>set <a href="gradcomdsetdatawarn.html" target="pages">datawarn</a></code><br>
-<code>q <a href="gradcomdqdbf.html" target="pages">dbf</a></code><br>
-<code>set <a href="gradcomdsetdbuff.html" target="pages">dbuff</a></code><br>
-<code><a href="gradcomddefine.html" target="pages">define</a></code><br>
-<code><a href="gradcomdquery.html" target="pages">q</a> define</code><br>
-<code><a href="gradcomdquery.html" target="pages">q</a> defval</code><br>
-<code>set <a href="gradcomdsetdefval.html" target="pages">defval</a></code><br>
-<a href="fontcontrol.html#overrides" target="pages">degree symbol</a><br>
-<code>set <a href="gradcomdsetdfile.html" target="pages">dfile</a></code><br>
-<code>q <a href="gradcomdqdialog.html" target="pages">dialog</a></code><br> 
-<code>set <a href="gradcomdsetdialog.html" target="pages">dialog</a></code><br> 
-<code>set <a href="gradcomdsetdignum.html" target="pages">dignum</a></code><br> 
-<code>set <a href="gradcomdsetdigsize.html" target="pages">digsiz</a></code><br> 
-<a href="dimenv.html" target="pages">dimension environment</a><br>
-<code><a href="gradcomdquery.html" target="pages">q</a> dims</code><br>
-<code><a href="gradcomddisablefwrite.html" target="pages">disable fwrite</a></code><br>
-<code><a href="gradcomddisableprint.html" target="pages">disable print</a></code><br>
-<code><a href="gradcomddisplay.html" target="pages">display</a></code><br>
-<code>set <a href="gradcomdsetdisplay.html" target="pages">display</a></code><br> 
-<a href="display.html" target="pages">displaying data</a><br>
-<a href="imageoutput.html" target="pages">displaying metafiles</a><br>
-<code><a href="gradcomddrawbutton.html" target="pages">draw button</a></code><br>
-<code><a href="gradcomddrawdropmenu.html" target="pages">draw dropmenu</a></code><br>
-<code><a href="gradcomddrawline.html" target="pages">draw line</a></code><br>
-<code><a href="gradcomddrawmap.html" target="pages">draw map</a></code><br>
-<code><a href="gradcomddrawmark.html" target="pages">draw mark</a></code><br>
-<code><a href="gradcomddrawpolyf.html" target="pages">draw polyf</a></code><br>
-<code><a href="gradcomddrawrec.html" target="pages">draw rec</a></code><br>
-<code><a href="gradcomddrawrecf.html" target="pages">draw recf</a></code><br>
-<code><a href="gradcomddrawshp.html" target="pages">draw shp</a></code><br>
-<code><a href="gradcomddrawstring.html" target="pages">draw string</a></code><br> 
-<code><a href="gradcomddrawtitle.html" target="pages">draw title</a></code><br>
-<code><a href="gradcomddrawwxsym.html" target="pages">draw wxsym</a></code><br>
-<code><a href="gradcomddrawxlab.html" target="pages">draw xlab</a></code><br>
-<code><a href="gradcomddrawylab.html" target="pages">draw ylab</a></code><br>
-<code>draw <a href="gradcomddrawdropmenu.html" target="pages">dropmenu</a></code><br>
-<code>set <a href="gradcomdsetdropmenu.html" target="pages">dropmenu</a></code><br>
-<p>
-<a name="indexe">
-<table cellpadding=2 border=0 WIDTH=20>
-<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-<font color="fffacd"><b>E</b></font></td></tr>
-</table>
-</a>
-
-<p class="plaintext">
-<code>set <a href="gradcomdsetxyzte.html" target="pages">e</a></code><br>
-<code><a href="gradfunceloop.html" target="pages">eloop</a></code><br>
-<code><a href="gradcomdenableprint.html" target="pages">enable print</a></code><br>
-<code>q <a href="gradcomdqens.html" target="pages">ens</a></code><br> 
-<code>set <a href="gradcomdsetlatlonlevtimeens.html" target="pages">ens</a></code><br>
-<a href="ensembles.html" target="pages">ensemble dimension</a><br>
-<a href="gradcomdgrads.html#env" target="pages">environment variables</a><br>
-<code><a href="gradcomdexec.html" target="pages">exec</a></code><br>
-<code><a href="gradfuncexp.html" target="pages">exp()</a></code><br>
-<a href="expressions.html" target="pages">expressions</a><br>
-<a href="utilities.html" target="pages">external utilites</a><br>
-<p>
-<a name="indexf">
-<table cellpadding=2 border=0 WIDTH=20>
-<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-<font color="fffacd"><b>F</b></font></td></tr>
-</table>
-</a>
-
-<p class="plaintext">
-<code>set <a href="gradcomdsetfgvals.html" target="pages">fgvals</a></code><br> 
-<code><a href="gradcomdquery.html" target="pages">q</a> file(s)</code><br>
-<code><a href="gradcomdflush.html" target="pages">flush</a></code><br> 
-<code><a href="gradfuncfndlvl.html" target="pages">fndlvl()</a></code><br>
-<a href="fontcontrol.html" target="pages">font control</a><br>
-<a href="font.html" target="pages">font file</a><br>
-<code>set <a href="gradcomdsetfont.html" target="pages">font</a></code><br> 
-<code>set <a href="gradcomdsetframe.html" target="pages">frame</a></code><br> 
-<code>disable <a href="gradcomddisablefwrite.html" target="pages">fwrite</a></code><br>
-<code>q <a href="gradcomdqfwrite.html" target="pages">fwrite</a></code><br> 
-<code>set <a href="gradcomdsetfwrite.html" target="pages">fwrite</a></code><br>
-<a href="functions.html" target="pages">functions: alpha</a><br>
-<a href="functionsatt.html" target="pages">functions: attribute</a><br>
-<a href="mathfunctions.html" target="pages">math functions</a><br>
-<p>
-<a name="indexg">
-<table cellpadding=2 border=0 WIDTH=20>
-<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-<font color="fffacd"><b>G</b></font></td></tr>
-</table>
-</a>
-
-<p class="plaintext">
-<code>set <a href="gradcomdsetgeotiff.html" target="pages">geotiff</a></code><br>
-<code><a href="gradfuncgint.html" target="pages">gint()</a></code><br>
-<code><a href="gradfuncgr2stn.html" target="pages">gr2stn()</a></code><br>
-<code><a href="gradcomdquery.html" target="pages">q</a> gr2w</code><br>
-<code><a href="gradcomdquery.html" target="pages">q</a> gr2xy</code><br>
-<code>set <a href="gradcomdsetgrads.html" target="pages">grads</a></code><br> 
-<code><a href="gradcomdgrads.html" target="pages">grads</a></code><br>
-<code><a href="gradcomdgrads.html" target="pages">gradsc</a></code><br>
-<code><a href="gradcomdgrads.html" target="pages">gradsdap</a></code><br>
-<code><a href="gradcomdgrads.html" target="pages">gradsdods</a></code><br>
-<code><a href="gradcomdgrads.html" target="pages">gradshdf</a></code><br>
-<code><a href="gradcomdgrads.html" target="pages">gradsnc</a></code><br>
-  <a href="grib.html" target="pages">GRIB format</a><br>
-<code><a href="gradutilgribmap.html" target="pages">gribmap</a></code><br>
-<code><a href="gradutilgribscan.html" target="pages">gribscan</a></code><br>
-<code><a href="gradutilgrib2scan.html" target="pages">grib2scan</a></code><br>
-<code>set <a href="gradcomdsetgrid.html" target="pages">grid</a></code><br>
-<code>set <a href="gradcomdsetgridln.html" target="pages">gridln</a></code><br>
-<code><a href="gsf.html" target="pages">gsfallow()</a></code><br>
-<code><a href="gsf.html" target="pages">gsfpath()</a></code><br>
-<code><a href="gradutilgxeps.html" target="pages">gxeps</a></code><br>
-<code><a href="gradcomdquery.html" target="pages">q</a> gxinfo</code><br>
-<code><a href="gradcomdquery.html" target="pages">q</a> gxout</code><br>
-<code>set <a href="gradcomdsetgxout.html" target="pages">gxout</a></code><br>  
-<code><a href="gradutilgxps.html" target="pages">gxps</a></code><br>
-<code><a href="gradutilgxtran.html" target="pages">gxtran</a></code><br>
-</font>
-
-<p>
-<a name="indexh">
-<table cellpadding=2 border=0 WIDTH=20>
-<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-<font color="fffacd"><b>H</b></font></td></tr>
-</table>
-</a>
-
-<p class="plaintext">
-<a href="imageoutput.html" target="pages">hardcopy output</a><br>
-<code><a href="gradfunchcurl.html" target="pages">hcurl()</a></code><br>
-  <code><a href="SDFdescriptorfile.html" target="pages">HDF-SDS format</a></code><br>
-<code><a href="gradfunchdivg.html" target="pages">hdivg()</a></code><br>
-<code><a href="gradcomdhelp.html" target="pages">help</a></code><br>
-<code>set <a href="gradcomdsethempref.html" target="pages">hempref</a></code><br>
-
-<p class="plaintext">
-<a name="indexi">
-<table cellpadding=2 border=0 WIDTH=20>
-<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-<font color="fffacd"><b>I</b></font></td></tr>
-</table>
-</a>
-<p class="plaintext">
-<a href="imageoutput.html" target="pages">image output</a><br>
-<code>set <a href="gradcomdsetimprun.html" target="pages">imprun</a></code><br>
-
-<p class="plaintext">
-<a name="indexj">
-<table cellpadding=2 border=0 WIDTH=20>
-<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-<font color="fffacd"><b>J</b></font></td></tr>
-</table>
-</a>
-<p class="plaintext">
-
-<p class="plaintext"> 
-<a name="indexk">
-<table cellpadding=2 border=0 WIDTH=20>
-<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-<font color="fffacd"><b>K</b></font></td></tr>
-</table>
-</a>
-<p class="plaintext">
-<code>set <a href="gradcomdsetkml.html" target="pages">kml</a></code><br>
-
-
-<p class="plaintext">
-<a name="indexl">
-</a></p>
-<table cellpadding=2 border=0 WIDTH=20>
-  <tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-  <font color="fffacd"><b>L</b></font></td></tr>
-</table>
-</a>
-
-<p class="plaintext">
-<code>set <a href="gradcomdsetlatlonlevtimeens.html" target="pages">lat</a></code><br>
-<code>set <a href="gradcomdsetlatlonlevtimeens.html" target="pages">lev</a></code><br>
-<code>set <a href="gradcomdsetlfcols.html" target="pages">lfcols</a></code><br> 
-script <a href="library.html" target="pages">library</a><br>
-<code>draw <a href="gradcomddrawline.html" target="pages">line</a></code><br>
-<code>set <a href="gradcomdsetline.html" target="pages">line</a></code><br>
-<code><a href="gradfunclog.html" target="pages">log()</a></code><br>
-<code><a href="gradfunclog10.html" target="pages">log10()</a></code><br>
-<code>set <a href="gradcomdsetlog1d.html" target="pages">log1d</a></code><br>
-<code>set <a href="gradcomdsetlatlonlevtimeens.html" target="pages">lon</a></code><br>
-<code>set <a href="gradcomdsetloopdim.html" target="pages">loopdim</a></code><br>
-<code>set <a href="gradcomdsetlooping.html" target="pages">looping</a></code><br> 
-<code><a href="gradfunclterp.html" target="pages">lterp()</a></code><br> 
-</font>
-
-<p>
-<a name="indexm">
-<table cellpadding=2 border=0 WIDTH=20>
-<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-<font color="fffacd"><b>M</b></font></td></tr>
-</table>
-</a>
-
-<p class="plaintext">
-<code><a href="gradfuncmag.html" target="pages">mag()</a></code><br>
-<a href="map.html" target="pages">map projections</a><br>
-<code>draw <a href="gradcomddrawmap.html" target="pages">map</a></code><br>
-<code>set <a href="gradcomdsetmap.html" target="pages">map</a></code><br>
-<code>draw <a href="gradcomddrawmark.html" target="pages">mark</a></code><br>
-<code><a href="gradfuncmaskout.html" target="pages">maskout()</a></code><br> 
-<a href="mathfunctions.html" target="pages">math functions</a><br>
-<code><a href="gradfuncmax.html" target="pages">max()</a></code><br>
-<code><a href="gradfuncmaxloc.html" target="pages">maxloc()</a></code><br>
-<code>set <a href="gradcomdsetmdlopts.html" target="pages">mdlopts</a></code><br>
-<code><a href="gradfuncmean.html" target="pages">mean()</a></code><br>
-<a href="imageoutput.html" target="pages">metafiles</a><br>
-<code><a href="gradfuncmin.html" target="pages">min()</a></code><br>
-<code><a href="gradfuncminloc.html" target="pages">minloc()</a></code><br>
-<code>set <a href="gradcomdsetmissconn.html" target="pages">missconn</a></code><br>
-<code><a href="gradcomdmodify.html" target="pages">modify</a></code><br>
-<code>set <a href="gradcomdsetmpdraw.html" target="pages">mpdraw</a></code><br>
-<code>set <a href="gradcomdsetmpdset.html" target="pages">mpdset</a></code><br>
-<code>set <a href="gradcomdsetmproj.html" target="pages">mproj</a></code><br>
-<code>set <a href="gradcomdsetmpt.html" target="pages">mpt</a></code><br>
-<code>set <a href="gradcomdsetmpvals.html" target="pages">mpvals</a></code><br>
-<a href="pagecontrol.html#multipanel" target="pages">multi-panel plots</a><br>
-</font>
-
-<p>
-<a name="indexn">
-<table cellpadding=2 border=0 WIDTH=20>
-<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-<font color="fffacd"><b>N</b></font></td></tr>
-</table>
-</a>
-
-<p class="plaintext">
-<code><a href="SDFdescriptorfile.html" target="pages">NetCDF format</a></code><br>
-</font>
-
-<p>
-<a name="indexo">
-<table cellpadding=2 border=0 WIDTH=20>
-<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-<font color="fffacd"><b>O</b></font></td></tr>
-</table>
-</a>
-
-<p class="plaintext">
-<code><a href="gradfuncoabin.html" target="pages">oabin()</a></code><br>
-<code><a href="gradfuncoacres.html" target="pages">oacres()</a></code><br>
-<code><a href="offt.html" target="pages">offt</a></code><br>
-<code><a href="gradcomdopen.html" target="pages">open</a></code><br>
-<code><a href="gradcomdoutxwd.html" target="pages">outxwd</a></code><br>
-</font>
-
-<p>
-<a name="indexp">
-<table cellpadding=2 border=0 WIDTH=20>
-<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-<font color="fffacd"><b>P</b></font></td></tr>
-</table>
-</a>
-
-<p class="plaintext">
-<a href="pagecontrol.html" target="pages">page control</a><br>
-<code>set <a href="gradcomdsetparea.html" target="pages">parea</a></code><br>
-  <a href="http://dao.gsfc.nasa.gov/software/grads/win32/latest/" target="_top">PC 
-  GrADS</a><br>
-<code><a href="pdef.html" target="pages">PDEF</a></code><br>
-<a href="pagecontrol.html#plotarea" target="pages">plot area</a><br>
-<code>set <a href="gradcomdsetpoli.html" target="pages">poli</a></code><br>
-<code>draw <a href="gradcomddrawpolyf.html" target="pages">polyf</a></code><br>
-<code>q <a href="gradcomdqpos.html" target="pages">pos</a></code><br> 
-<code><a href="gradfuncpow.html" target="pages">pow()</a></code><br>
-<code><a href="gradcomdprint.html" target="pages">print</a></code><br>
-<code>disable <a href="gradcomddisableprint.html" target="pages">print</a></code><br>
-<code>enable <a href="gradcomdenableprint.html" target="pages">print</a></code><br>  
-<code><a href="gradcomdprintim.html" target="pages">printim</a></code><br>
-<code>set <a href="gradcomdsetprnopts.html" target="pages">prnopts</a></code><br>
-</font>
-
-<p>
-<a name="indexq">
-<table cellpadding=2 border=0 WIDTH=20>
-<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-<font color="fffacd"><b>Q</b></font></td></tr>
-</table>
-</a>
-
-<p class="plaintext">
-<code><a href="gradcomdquery.html" target="pages">q (query)</a></code><br>
-<code><a href="gradcomdqattr.html" target="pages">q attr</a></code><br> 
-<code><a href="gradcomdqdbf.html" target="pages">q dbf</a></code><br>
-<code><a href="gradcomdqdialog.html" target="pages">q dialog</a></code><br>
-<code><a href="gradcomdqens.html" target="pages">q ens</a></code><br> 
-<code><a href="gradcomdqfwrite.html" target="pages">q fwrite</a></code><br> 
-<code><a href="gradcomdqpos.html" target="pages">q pos</a></code><br> 
-<code><a href="gradcomdqsdfwrite.html" target="pages">q sdfwrite</a></code><br>
-<code><a href="gradcomdqshades.html" target="pages">q shades</a></code><br>
-<code><a href="gradcomdqshp.html" target="pages">q shp</a></code><br>
-<code><a href="gradcomdqshpopts.html" target="pages">q shpopts</a></code><br>
-<a href="reference_card.pdf" target="_top">quick: commands</a><br>
-<a href="reference_card_scl.pdf"target="_top">quick: scripts</a><br>
-<code><a href="gradcomdquit.html" target="pages">quit</a></code><br>  
-</font>
-
-<p>
-<a name="indexr">
-<table cellpadding=2 border=0 WIDTH=20>
-<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-<font color="fffacd"><b>R</b></font></td></tr>
-</table>
-</a>
-
-<p class="plaintext">
-<code>set <a href="gradcomdsetrband.html" target="pages">rband</a></code><br>
-<code>set <a href="gradcomdsetrbcols.html" target="pages">rbcols</a></code><br>
-<code>set <a href="gradcomdsetrbrange.html" target="pages">rbrange</a></code><br>
-<a href="pagecontrol.html#real" target="pages">real page</a><br>
-<code>draw <a href="gradcomddrawrec.html" target="pages">rec</a></code><br>
-<code>draw <a href="gradcomddrawrecf.html" target="pages">recf</a></code><br>
-<code><a href="gradcomdredrawbutton.html" target="pages">redraw button</a></code><br>
-<code><a href="gradcomdreset.html" target="pages">reset</a></code><br>   
-<code><a href="gradcomdreinit.html" target="pages">reinit</a></code><br>   
-<a href="reinitialization.html" target="pages">reinitialization</a><br>
-<code>set <a href="gradcomdsetrgb.html" target="pages">rgb</a></code><br>
-<code><a href="gradcomdrun.html" target="pages">run</a></code><br> 
-</font>
-
-<p>
-<a name="indexs">
-<table cellpadding=2 border=0 WIDTH=20>
-<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-<font color="fffacd"><b>S</b></font></td></tr>
-</table>
-</a>
-
-<p class="plaintext">
-<code><a href="gradfuncs2g1d.html" target="pages">s2g1d()</a></code><br>
-<a href="scatterplot.html" target="pages">scatter plots</a><br>
-<code><a href="gradfuncscorr.html" target="pages">scorr()</a></code><br>
-<code><a href="gradcomdscreen.html" target="pages">screen</a></code><br>
-<a href="gsf.html" target="pages">script functions</a><br>
-<a href="library.html" target="pages">script library</a><br>
-<a href="script.html" target="pages">scripting language</a><br>
-<code><a href="gradcomdsdfopen.html" target="pages">sdfopen</a></code><br>
-<code><a href="gradcomdsdfwrite.html" target="pages">sdfwrite</a></code><br>
-<code>q <a href="gradcomdqsdfwrite.html" target="pages">sdfwrite</a></code><br>
-<code>set <a href="gradcomdsetsdfattr.html" target="pages">sdfattr</a></code><br>
-<code>set <a href="gradcomdsetsdfwrite.html" target="pages"> sdfwrite</a></code><br>
-<code><a href="gradcomdsetannot.html" target="pages">set annot</a></code><br>
-<code><a href="gradcomdsetarrlab.html" target="pages">set arrlab</a></code><br>
-<code><a href="gradcomdsetarrowhead.html" target="pages">set arrowhead</a></code><br>
-<code><a href="gradcomdsetarrscl.html" target="pages">set arrscl</a></code><br>
-<code><a href="gradcomdsetbackground.html" target="pages">set background</a></code><br>
-<code><a href="gradcomdsetbarbase.html" target="pages">set barbase</a></code><br>
-<code><a href="gradcomdsetbargap.html" target="pages">set bargap</a></code><br>
-<code><a href="gradcomdsetbaropts.html" target="pages">set baropts</a></code><br>
-<code><a href="gradcomdsetblack.html" target="pages">set black</a></code><br>
-<code><a href="gradcomdsetbutton.html" target="pages">set button</a></code><br>
-<code><a href="gradcomdsetcachesf.html" target="pages">set cachesf</a></code><br>
-<code><a href="gradcomdsetccolor.html" target="pages">set ccolor</a></code><br>
-<code><a href="gradcomdsetccols.html" target="pages">set ccols</a></code><br>
-<code><a href="gradcomdsetcint.html" target="pages">set cint</a></code><br>
-<code><a href="gradcomdsetchunksize.html" target="pages">set chunksize</a></code><br>  
-<code><a href="gradcomdsetclab.html" target="pages">set clab</a></code><br>
-<code><a href="gradcomdsetclevs.html" target="pages">set clevs</a></code><br>
-<code><a href="gradcomdsetclip.html" target="pages">set clip</a></code><br>
-<code><a href="gradcomdsetclopts.html" target="pages">set clopts</a></code><br>
-<code><a href="gradcomdsetclskip.html" target="pages">set clskip</a></code><br>
-<code><a href="gradcomdsetcmark.html" target="pages">set cmark</a></code><br>
-<code><a href="gradcomdsetcmax.html" target="pages">set cmax</a></code><br>
-<code><a href="gradcomdsetcmin.html" target="pages">set cmin</a></code><br>
-<code><a href="gradcomdsetcmin.html" target="pages">set cmin</a></code><br>
-<code><a href="gradcomdsetcoslat.html" target="pages">set coslat</a></code><br>
-<code><a href="gradcomdsetcstyle.html" target="pages">set cstyle</a></code><br>
-<code><a href="gradcomdsetcterp.html" target="pages">set cterp</a></code><br>
-<code><a href="gradcomdsetcthick.html" target="pages">set cthick</a></code><br>
-<code><a href="gradcomdsetdatawarn.html" target="pages">set datawarn</a></code><br>
-<code><a href="gradcomdsetdbuff.html" target="pages">set dbuff</a></code><br>
-<code><a href="gradcomdsetdefval.html" target="pages">set defval</a></code><br>
-<code><a href="gradcomdsetdfile.html" target="pages">set dfile</a></code><br>
-<code><a href="gradcomdsetdialog.html" target="pages">set dialog</a></code><br> 
-<code><a href="gradcomdsetdignum.html" target="pages">set dignum</a></code><br> 
-<code><a href="gradcomdsetdigsize.html" target="pages">set digsiz</a></code><br> 
-<code><a href="gradcomdsetdisplay.html" target="pages">set display</a></code><br> 
-<code><a href="gradcomdsetdropmenu.html" target="pages">set dropmenu</a></code><br>
-<code><a href="gradcomdsetlatlonlevtimeens.html" target="pages">set ens</a></code><br>
-<code><a href="gradcomdsetfgvals.html" target="pages">set fgvals</a></code><br> 
-<code><a href="gradcomdsetfont.html" target="pages">set font</a></code><br> 
-<code><a href="gradcomdsetframe.html" target="pages">set frame</a></code><br> 
-<code><a href="gradcomdsetfwrite.html" target="pages">set fwrite</a></code><br>
-<code><a href="gradcomdsetgrads.html" target="pages">set grads</a></code><br> 
-<code><a href="gradcomdsetgeotiff.html" target="pages">set geotiff</a></code><br> 
-<code><a href="gradcomdsetgrid.html" target="pages">set grid</a></code><br>
-<code><a href="gradcomdsetgridln.html" target="pages">set gridln</a></code><br>
-<code><a href="gradcomdsetgxout.html" target="pages">set gxout</a></code><br>  
-<code><a href="gradcomdsethempref.html" target="pages">set hempref</a></code><br>
-<code><a href="gradcomdsetimprun.html" target="pages">set imprun</a></code><br>
-<code><a href="gradcomdsetkml.html" target="pages">set kml</a></code><br>
-<code><a href="gradcomdsetlatlonlevtimeens.html" target="pages">set lat</a></code><br>
-<code><a href="gradcomdsetlatlonlevtimeens.html" target="pages">set lev</a></code><br>
-<code><a href="gradcomdsetlfcols.html" target="pages">set lfcols</a></code><br> 
-<code><a href="gradcomdsetline.html" target="pages">set line</a></code><br>
-<code><a href="gradcomdsetlog1d.html" target="pages">set log1d</a></code><br>
-<code><a href="gradcomdsetlatlonlevtimeens.html" target="pages">set lon</a></code><br>
-<code><a href="gradcomdsetloopdim.html" target="pages">set loopdim</a></code><br>
-<code><a href="gradcomdsetlooping.html" target="pages">set looping</a></code><br> 
-<code><a href="gradcomdsetmap.html" target="pages">set map</a></code><br>
-<code><a href="gradcomdsetmdlopts.html" target="pages">set mdlopts</a></code><br>
-<code><a href="gradcomdsetmissconn.html" target="pages">set missconn</a></code><br>
-<code><a href="gradcomdsetmpdraw.html" target="pages">set mpdraw</a></code><br>
-<code><a href="gradcomdsetmpdset.html" target="pages">set mpdset</a></code><br>
-<code><a href="gradcomdsetmproj.html" target="pages">set mproj</a></code><br>
-<code><a href="gradcomdsetmpt.html" target="pages">set mpt</a></code><br>
-<code><a href="gradcomdsetmpvals.html" target="pages">set mpvals</a></code><br>
-<code><a href="gradcomdsetparea.html" target="pages">set parea</a></code><br>
-<code><a href="gradcomdsetpoli.html" target="pages">set poli</a></code><br>
-<code><a href="gradcomdsetprnopts.html" target="pages">set prnopts</a></code><br>
-<code><a href="gradcomdsetrband.html" target="pages">set rband</a></code><br>
-<code><a href="gradcomdsetrbcols.html" target="pages">set rbcols</a></code><br>
-<code><a href="gradcomdsetrbrange.html" target="pages">set rbrange</a></code><br>
-<code><a href="gradcomdsetrgb.html" target="pages">set rgb</a></code><br>
-<code><a href="gradcomdsetsdfattr.html" target="pages">set sdfattr</a></code><br>
-<code><a href="gradcomdsetsdfwrite.html" target="pages">set sdfwrite</a></code><br>
-<code><a href="gradcomdsetshp.html" target="pages">set shp</a></code><br>
-<code><a href="gradcomdsetshpattr.html" target="pages">set shpattr</a></code><br>
-<code><a href="gradcomdsetshpopts.html" target="pages">set shpopts</a></code><br>
-<code><a href="gradcomdsetstat.html" target="pages">set stat</a></code><br>
-<code><a href="gradcomdsetstid.html" target="pages">set stid</a></code><br>
-<code><a href="gradcomdsetstnprint.html" target="pages">set stnprint</a></code><br>
-<code><a href="gradcomdsetstring.html" target="pages">set string</a></code><br>
-<code><a href="gradcomdsetstrmden.html" target="pages">set strmden</a></code><br>
-<code><a href="gradcomdsetstrmden.html" target="pages">set strmopts</a></code><br>
-<code><a href="gradcomdsetstrsiz.html" target="pages">set strsiz</a></code><br>
-<code><a href="gradcomdsetxyzte.html" target="pages">set t</a></code><br>
-<code><a href="gradcomdsetlatlonlevtimeens.html" target="pages">set time</a></code><br>
-<code><a href="gradcomdsettimelab.html" target="pages">set timelab</a></code><br>
-<code><a href="gradcomdsettlsupp.html" target="pages">set tlsupp</a></code><br>
-<code><a href="gradcomdsetundef.html" target="pages">set undef</a></code><br>
-<code><a href="gradcomdsetvpage.html" target="pages">set vpage</a></code><br>
-<code><a href="gradcomdsetvrange.html" target="pages">set vrange</a></code><br>
-<code><a href="gradcomdsetvrange2.html" target="pages">set vrange2</a></code><br>
-<code><a href="gradcomdsetwarn.html" target="pages">set warn</a></code><br>
-<code><a href="gradcomdsetwxcols.html" target="pages">set wxcols</a></code><br>
-<code><a href="gradcomdsetwxopt.html" target="pages">set wxopt</a></code><br>
-<code><a href="gradcomdsetxyzte.html" target="pages">set x</a></code><br>
-<code><a href="gradcomdsetxaxis.html" target="pages">set xaxis</a></code><br>
-<code><a href="gradcomdsetxflip.html" target="pages">set xflip</a></code><br>
-<code><a href="gradcomdsetxlab.html" target="pages">set xlab</a></code><br>
-<code><a href="gradcomdsetxlabs.html" target="pages">set xlabs</a></code><br>
-<code><a href="gradcomdsetxlevs.html" target="pages">set xlevs</a></code><br>
-<code><a href="gradcomdsetxlint.html" target="pages">set xlint</a></code><br>
-<code><a href="gradcomdsetxlopts.html" target="pages">set xlopts</a></code><br>
-<code><a href="gradcomdsetxlpos.html" target="pages">set xlpos</a></code><br>
-<code><a href="gradcomdsetxsize.html" target="pages">set xsize</a></code><br>
-<code><a href="gradcomdsetxyrev.html" target="pages">set xyrev</a></code><br>
-<code><a href="gradcomdsetxyzte.html" target="pages">set y</a></code><br>
-<code><a href="gradcomdsetyaxis.html" target="pages">set yaxis</a></code><br>
-<code><a href="gradcomdsetyflip.html" target="pages">set yflip</a></code><br>
-<code><a href="gradcomdsetylab.html" target="pages">set ylab</a></code><br>
-<code><a href="gradcomdsetylabs.html" target="pages">set ylabs</a></code><br>
-<code><a href="gradcomdsetylevs.html" target="pages">set ylevs</a></code><br>
-<code><a href="gradcomdsetylint.html" target="pages">set ylint</a></code><br>
-<code><a href="gradcomdsetylopts.html" target="pages">set ylopts</a></code><br>
-<code><a href="gradcomdsetylpos.html" target="pages">set ylpos</a></code><br>
-<code><a href="gradcomdsetxyzte.html" target="pages">set z</a></code><br>
-<code><a href="gradcomdsetzlog.html" target="pages">set zlog</a></code><br>
-<code>query <a href="gradcomdqshades.html" target="pages">shades</a></code><br>
-<a href="shapefiles.html" target="pages">shapefiles</a><br>
-<code><a href="gradcomdshell.html" target="pages">!shell</a></code><br>
-<code>draw <a href="gradcomddrawshp.html" target="pages">shp</a></code><br>
-<code>q <a href="gradcomdqshp.html" target="pages">shp</a></code><br>
-<code>set <a href="gradcomdsetshp.html" target="pages">shp</a></code><br>
-<code>q <a href="gradcomdqshpopts.html" target="pages">shpopts</a></code><br>
-<code>set <a href="gradcomdsetshpopts.html" target="pages">shpopts</a></code><br>
-<code><a href="gradfuncsin.html" target="pages">sin()</a></code><br>
-<code><a href="gradfuncskip.html" target="pages">skip()</a></code><br>
-<code><a href="gradfuncsmth9.html" target="pages">smth9()</a></code><br>
-<code><a href="gradfuncsqrt.html" target="pages">sqrt()</a></code><br>
-<code><a href="gradfuncsregr.html" target="pages">sregr()</a></code><br>
-<a href="start.html" target="pages">starting GrADS</a><br>
-<code>set <a href="gradcomdsetstat.html" target="pages">stat</a></code><br>
-about <a href="aboutstationdata.html" target="pages">station data</a><br>
-using <a href="usingstationdata.html" target="pages">station data</a><br>
-<code>set <a href="gradcomdsetstid.html" target="pages">stid</a></code><br>
-<code><a href="gradfuncstnave.html" target="pages">stnave()</a></code><br>
-<code><a href="gradfuncstnmin.html" target="pages">stnmin()</a></code><br>
-<code><a href="gradutilstnmap.html" target="pages">stnmap</a></code><br>
-<code><a href="gradfuncstnmax.html" target="pages">stnmax()</a></code><br>
-<code>set <a href="gradcomdsetstnprint.html" target="pages">stnprint</a></code><br>
-<a href="fontcontrol.html" target="pages">string formatting</a><br>
-<code>draw <a href="gradcomddrawstring.html" target="pages">string</a></code><br> 
-<code><a href="gradcomdquery.html" target="pages">q</a> string</code><br>
-<code>set <a href="gradcomdsetstring.html" target="pages">string</a></code><br>
-<code>set <a href="gradcomdsetstrmden.html" target="pages">strmden</a></code><br>
-<code>set <a href="gradcomdsetstrsiz.html" target="pages">strsiz</a></code><br>
-<code><a href="gradfuncsum.html" target="pages">sum()</a></code><br>
-<code><a href="gradfuncsumg.html" target="pages">sumg()</a></code><br>
-<a href="supplibs.html" target="pages">supplibs</a><br>
-<code><a href="gradcomdswap.html" target="pages">swap</a></code><br>
-</font>
-<p>
-<a name="indext">
-<table cellpadding=2 border=0 WIDTH=20>
-<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-<font color="fffacd"><b>T</b></font></td></tr>
-</table>
-</a>
-
-<p class="plaintext">
-<code>set <a href="gradcomdsetxyzte.html" target="pages">t</a></code><br>
-<code><a href="gradfunctan.html" target="pages">tan()</a></code><br>     
-<code><a href="gradfunctcorr.html" target="pages">tcorr()</a></code><br>
-<a href="templates.html" target="pages">templates</a><br>
-<code><a href="gradcomdquery.html" target="pages">q</a> time</code><br>
-<code>set <a href="gradcomdsetlatlonlevtimeens.html" target="pages">time</a></code><br>
-<code>set <a href="gradcomdsettimelab.html" target="pages">timelab</a></code><br>
-<code>draw <a href="gradcomddrawtitle.html" target="pages">title</a></code><br>
-<code><a href="gradfunctloop.html" target="pages">tloop()</a></code><br>
-<code>set <a href="gradcomdsettlsupp.html" target="pages">tlsupp</a></code><br>
-<code><a href="gradfunctmave.html" target="pages">tmave()</a></code><br>
-<code><a href="gradfunctregr.html" target="pages">tregr()</a></code><br>
-<a href="tutorial.html" target="pages">Tutorial</a><br>
-<code><a href="gradfunctvrh2q.html" target="pages">tvrh2q()</a></code><br>
-<code><a href="gradfunctvrh2t.html" target="pages">tvrh2t()</a></code><br>
-</font>
-
-<p>
-<a name="indexu">
-<table cellpadding=2 border=0 WIDTH=20>
-<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-<font color="fffacd"><b>U</b></font></td></tr>
-</table>
-</a>
-
-<p class="plaintext">
-<code><a href="gradcomdquery.html" target="pages">q</a> undef</code><br>
-<code>set <a href="gradcomdsetundef.html" target="pages">undef</a></code><br>
-<code><a href="gradcomdundefine.html" target="pages">undefine</a></code><br>
-<a href="udf.html" target="pages">user defined functions</a><br>
-<a href="users.html" target="pages">user's guide</a><br>
-external <a href="utilities.html" target="pages">utilites</a><br>
-</font>
-
-<p>
-<a name="indexv">
-<table cellpadding=2 border=0 WIDTH=20>
-<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-<font color="fffacd"><b>V</b></font></td></tr>
-</table>
-</a>
-
-<p class="plaintext">
-<a href="variable.html" target="pages">variables</a><br>
-<code><a href="gradfuncvint.html" target="pages">vint()</a></code><br>    
-<a href="pagecontrol.html#real" target="pages">virtual page</a><br>
-<code>set <a href="gradcomdsetvpage.html" target="pages">vpage</a></code><br>
-<code>set <a href="gradcomdsetvrange.html" target="pages">vrange</a></code><br>
-<code>set <a href="gradcomdsetvrange2.html" target="pages">vrange2</a></code><br>
-</font>
-
-<p>
-<a name="indexw">
-<table cellpadding=2 border=0 WIDTH=20>
-<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-<font color="fffacd"><b>W</b></font></td></tr>
-</table>
-</a>
-
-<p class="plaintext">
-<code><a href="gradcomdquery.html" target="pages">q</a> w2gr</code><br>
-<code><a href="gradcomdquery.html" target="pages">q</a> w2xy</code><br>
-<code>set <a href="gradcomdsetwarn.html" target="pages">warn</a></code><br>
-<code><a href="gradcomdwi.html" target="pages">wi</a></code><br>
-<a href="script.html#widgets" target="pages">widgets</a><br>
-<code>set <a href="gradcomdsetwxcols.html" target="pages">wxcols</a></code><br>
-<code>set <a href="gradcomdsetwxopt.html" target="pages">wxopt</a></code><br>
-<code>draw <a href="gradcomddrawwxsym.html" target="pages">wxsym</a></code><br>
-</font>
-
-<p>
-<a name="indexx">
-<table cellpadding=2 border=0 WIDTH=20>
-<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-<font color="fffacd"><b>X</b></font></td></tr>
-</table>
-</a>
-
-<p class="plaintext">
-<code>set <a href="gradcomdsetxyzte.html" target="pages">x</a></code><br>
-<code>set <a href="gradcomdsetxaxis.html" target="pages">xaxis</a></code><br>
-<code><a href="gradcomdxdfopen.html" target="pages">xdfopen</a></code><br>
-<code>set <a href="gradcomdsetxflip.html" target="pages">xflip</a></code><br>
-<code>draw <a href="gradcomddrawxlab.html" target="pages">xlab</a></code><br>
-<code>set <a href="gradcomdsetxlab.html" target="pages">xlab</a></code><br>
-<code>set <a href="gradcomdsetxlabs.html" target="pages">xlabs</a></code><br>
-<code>set <a href="gradcomdsetxlevs.html" target="pages">xlevs</a></code><br>
-<code>set <a href="gradcomdsetxlint.html" target="pages">xlint</a></code><br>
-<code>set <a href="gradcomdsetxlopts.html" target="pages">xlopts</a></code><br>
-<code>set <a href="gradcomdsetxlpos.html" target="pages">xlpos</a></code><br>
-<code>set <a href="gradcomdsetxsize.html" target="pages">xsize</a></code><br>
-<code>set <a href="gradcomdsetxyrev.html" target="pages">xyrev</a></code><br>
-<code><a href="gradcomdquery.html" target="pages">q</a> xy2gr</code><br>
-<code><a href="gradcomdquery.html" target="pages">q</a> xy2w</code><br>
-</font>
-
-<p>
-<a name="indexy">
-<table cellpadding=2 border=0 WIDTH=20>
-<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-<font color="fffacd"><b>Y</b></font></td></tr>
-</table>
-</a>
-
-<p class="plaintext">
-<code>set <a href="gradcomdsetxyzte.html" target="pages">y</a></code><br>
-<code>set <a href="gradcomdsetyaxis.html" target="pages">yaxis</a></code><br>
-<code>set <a href="gradcomdsetyflip.html" target="pages">yflip</a></code><br>
-<code>draw <a href="gradcomddrawylab.html" target="pages">ylab</a></code><br>
-<code>set <a href="gradcomdsetylab.html" target="pages">ylab</a></code><br>
-<code>set <a href="gradcomdsetylabs.html" target="pages">ylabs</a></code><br>
-<code>set <a href="gradcomdsetylevs.html" target="pages">ylevs</a></code><br>
-<code>set <a href="gradcomdsetylint.html" target="pages">ylint</a></code><br>
-<code>set <a href="gradcomdsetylopts.html" target="pages">ylopts</a></code><br>
-<code>set <a href="gradcomdsetylpos.html" target="pages">ylpos</a></code><br>
-</font>
-
-<p>
-<a name="indexz">
-<table cellpadding=2 border=0 WIDTH=20>
-<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
-<font color="fffacd"><b>Z</b></font></td></tr>
-</table>
-</a>
-
-<p class="plaintext">
-<code>set <a href="gradcomdsetxyzte.html" target="pages">z</a></code><br>
-<code>set <a href="gradcomdsetzlog.html" target="pages">zlog</a></code><br>
-</font>
-
-</body>
-</html>
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->

<html>
<head>
<title>Documentation Index</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<link href="GrADS.css" rel="stylesheet" type="text/css">
</head>
<body bgcolor="#e0f0ff" text="#000000">
<a name="indexa">
<table cellpadding=2 border=0 WIDTH=20>
<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
<font color="fffacd"><b>A</b></font></td></tr>
</table>
</a>

<p class="plaintext">
<code><a href="gradfuncaave.html" target="pages">aave()</a></code><br>
<code><a href="gradfuncabs.html" target="pages">abs()</a></code><br>
<code><a href="gradfuncacos.html" target="pages">acos()</a></code><br>
<a href="templates.html" target="pages">aggregate data files</a><br>
<code><a href="gradfuncamean.html" target="pages">amean()</a></code><br>
<a href="animation.html" target="pages">animation</a><br>
<code>set <a href="gradcomdsetannot.html" target="pages">annot</a></code><br>
<code>set <a href="gradcomdsetarrlab.html" target="pages">arrlab</a></code><br>
<code>set <a href="gradcomdsetarrowhead.html" target="pages">arrowhead</a></code><br>
<code>set <a href="gradcomdsetarrscl.html" target="pages">arrscl</a></code><br>
<code><a href="gradfuncasin.html" target="pages">asin()</a></code><br>
<code><a href="gradfuncasum.html" target="pages">asum()</a></code><br>
<code><a href="gradfuncasumg.html" target="pages">asumg()</a></code><br>
<code><a href="gradfuncatan2.html" target="pages">atan2()</a></code><br>
<a href="http://dao.gsfc.nasa.gov/software/grads/win32/latest/pc-dist/doc/gagui/gagui_intro.html" target="_top">athena widgets</a><br>
<code><a href="gradcomdqattr.html" target="pages">q </a>attr</code><br> 
<code><a href="gradfuncave.html" target="pages">ave()</a></code><br>
<p>
<a name="indexb">
<table cellpadding=2 border=0 WIDTH=20>
<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
<font color="fffacd"><b>B</b></font></td></tr>
</table>
</a>

<p class="plaintext">
<code>set <a href="gradcomdsetbackground.html" target="pages">background</a></code><br>
<code>set <a href="gradcomdsetbarbase.html" target="pages">barbase</a></code><br>
<code>set <a href="gradcomdsetbargap.html" target="pages">bargap</a></code><br>
<code>set <a href="gradcomdsetbaropts.html" target="pages">baropts</a></code><br>
<a href="basic.html" target="pages">basic operation</a><br>
<a href="aboutgriddeddata.html" target="pages">binary data sets</a><br>
<code>set <a href="gradcomdsetblack.html" target="pages">black</a></code><br>
  <a href="bufrformat.html" target="pages">BUFR format</a><br>
<code><a href="gradutilbufrscan.html" target="pages">bufrscan</a></code>  <br>
<a href="supplibs.html" target="pages">build  from source</a><br>
<code>draw <a href="gradcomddrawbutton.html" target="pages">button</a></code><br>
<code>redraw <a href="gradcomdredrawbutton.html" target="pages">button</a></code><br>
<code>set <a href="gradcomdsetbutton.html" target="pages">button</a></code><br>
<p>
<a name="indexc">
<table cellpadding=2 border=0 WIDTH=20>
<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
<font color="fffacd"><b>C</b></font></td></tr>
</table>
</a>

<p class="plaintext">
<code><a href="gradcomdquery.html" target="pages">q </a>cache</code><br> 
<code><a href="gradcomdquery.html" target="pages">q</a> cachesf</code><br> 
<code>set <a href="gradcomdsetcachesf.html" target="pages">cachesf</a></code><br>
<a href="gradcomddrawdropmenu.html" target="pages">cascading dropmenus</a><br>
<code>set <a href="gradcomdsetccolor.html" target="pages">ccolor</a></code><br>
<code>set <a href="gradcomdsetccols.html" target="pages">ccols</a></code><br>
<code><a href="gradfunccdiff.html" target="pages">cdiff()</a></code><br>
<code>set <a href="gradcomdsetchunksize.html" target="pages">chunksize</a></code><br> 
<code>set <a href="gradcomdsetcint.html" target="pages">cint</a></code><br> 
<code>set <a href="gradcomdsetclab.html" target="pages">clab</a></code><br>
<code><a href="gradcomdclear.html" target="pages">clear</a></code><br>
<code>set <a href="gradcomdsetclevs.html" target="pages">clevs</a></code><br>
<code>set <a href="gradcomdsetclip.html" target="pages">clip</a></code><br>
<code>set <a href="gradcomdsetclopts.html" target="pages">clopts</a></code><br>
<code><a href="gradcomdclose.html" target="pages">close</a></code><br>
<code>set <a href="gradcomdsetclskip.html" target="pages">clskip</a></code><br>
<code>set <a href="gradcomdsetcmark.html" target="pages">cmark</a></code><br>
<code>set <a href="gradcomdsetcmax.html" target="pages">cmax</a></code><br>
<code>set <a href="gradcomdsetcmin.html" target="pages">cmin</a></code><br>
<code><a href="gradcomdcollect.html" target="pages">collect</a></code><br>
<code><a href="gradfunccoll2gr.html" target="pages">coll2gr()</a></code><br>
default <a href="16colors.html" target="pages">colors</a><br>
controlling <a href="colorcontrol.html" target="pages">colors</a><br>
<a href="commandline.html" target="pages">command line editing</a><br>
<a href="commandsatt.html" target="pages">commands: attribute</a><br>
<a href="compression.html" target="pages">compression</a><br>
<code><a href="gradcomdquery.html" target="pages">q</a> config</code><br> 
<code><a href="gradfuncconst.html" target="pages">const()</a></code><br>
<code><a href="gradcomdquery.html" target="pages">q</a> contours</code><br> 
<a href="descriptorfile.html" target="pages">control file</a><br>
<a href="gradfuncscorr.html" target="pages">correlation, spatial</a><br>
<a href="gradfunctcorr.html" target="pages">correlation, temporal</a><br>
<code><a href="gradfunccos.html" target="pages">cos()</a></code><br>
<code>set <a href="gradcomdsetcoslat.html" target="pages">coslat</a></code><br>
<a href="usingstationdata.html#xsection" target="pages">cross sections</a><br>
<code>set <a href="gradcomdsetcsmooth.html" target="pages">csmooth</a></code><br>
<code>set <a href="gradcomdsetcstyle.html" target="pages">cstyle</a></code><br>
<code>set <a href="gradcomdsetcterp.html" target="pages">cterp</a></code><br>
<code><a href="gradcomdquery.html" target="pages">q</a> ctlinfo</code><br> 
<code>set <a href="gradcomdsetcthick.html" target="pages">cthick</a></code><br> 
</font>

<p>
<a name="indexd">
<table cellpadding=2 border=0 WIDTH=20>
<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
<font color="fffacd"><b>D</b></font></td></tr>
</table>
</a>

<p class="plaintext">
data descriptor files:<br>
  <a href="descriptorfile.html" target="pages">elements</a><br>
  <a href="bufrformat.html" target="pages">for BUFR data</a><br>
  <a href="aboutgriddeddata.html#descriptor" target="pages">for gridded data</a><br>
    <a href="SDFdescriptorfile.html" target="pages">for NetCDF/HDF files</a><br>
  <a href="aboutstationdata.html#descriptor" target="pages">for station data</a><br>
<a href="aboutgriddeddata.html" target="pages">data sets (gridded)</a><br>
<a href="aboutstationdata.html" target="pages">data sets (station)</a><br>
<code>set <a href="gradcomdsetdatawarn.html" target="pages">datawarn</a></code><br>
<code>q <a href="gradcomdqdbf.html" target="pages">dbf</a></code><br>
<code>set <a href="gradcomdsetdbuff.html" target="pages">dbuff</a></code><br>
<code><a href="gradcomddefine.html" target="pages">define</a></code><br>
<code><a href="gradcomdquery.html" target="pages">q</a> define</code><br>
<code><a href="gradcomdquery.html" target="pages">q</a> defval</code><br>
<code>set <a href="gradcomdsetdefval.html" target="pages">defval</a></code><br>
<a href="fontcontrol.html#overrides" target="pages">degree symbol</a><br>
<code>set <a href="gradcomdsetdfile.html" target="pages">dfile</a></code><br>
<code>q <a href="gradcomdqdialog.html" target="pages">dialog</a></code><br> 
<code>set <a href="gradcomdsetdialog.html" target="pages">dialog</a></code><br> 
<code>set <a href="gradcomdsetdignum.html" target="pages">dignum</a></code><br> 
<code>set <a href="gradcomdsetdigsize.html" target="pages">digsiz</a></code><br> 
<a href="dimenv.html" target="pages">dimension environment</a><br>
<code><a href="gradcomdquery.html" target="pages">q</a> dims</code><br>
<code><a href="gradcomddisablefwrite.html" target="pages">disable fwrite</a></code><br>
<code><a href="gradcomddisableprint.html" target="pages">disable print</a></code><br>
<code><a href="gradcomddisplay.html" target="pages">display</a></code><br>
<code>set <a href="gradcomdsetdisplay.html" target="pages">display</a></code><br> 
<a href="display.html" target="pages">displaying data</a><br>
<a href="imageoutput.html" target="pages">displaying metafiles</a><br>
<code><a href="gradcomddrawbutton.html" target="pages">draw button</a></code><br>
<code><a href="gradcomddrawdropmenu.html" target="pages">draw dropmenu</a></code><br>
<code><a href="gradcomddrawline.html" target="pages">draw line</a></code><br>
<code><a href="gradcomddrawmap.html" target="pages">draw map</a></code><br>
<code><a href="gradcomddrawmark.html" target="pages">draw mark</a></code><br>
<code><a href="gradcomddrawpolyf.html" target="pages">draw polyf</a></code><br>
<code><a href="gradcomddrawrec.html" target="pages">draw rec</a></code><br>
<code><a href="gradcomddrawrecf.html" target="pages">draw recf</a></code><br>
<code><a href="gradcomddrawshp.html" target="pages">draw shp</a></code><br>
<code><a href="gradcomddrawstring.html" target="pages">draw string</a></code><br> 
<code><a href="gradcomddrawtitle.html" target="pages">draw title</a></code><br>
<code><a href="gradcomddrawwxsym.html" target="pages">draw wxsym</a></code><br>
<code><a href="gradcomddrawxlab.html" target="pages">draw xlab</a></code><br>
<code><a href="gradcomddrawylab.html" target="pages">draw ylab</a></code><br>
<code>draw <a href="gradcomddrawdropmenu.html" target="pages">dropmenu</a></code><br>
<code>set <a href="gradcomdsetdropmenu.html" target="pages">dropmenu</a></code><br>
<p>
<a name="indexe">
<table cellpadding=2 border=0 WIDTH=20>
<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
<font color="fffacd"><b>E</b></font></td></tr>
</table>
</a>

<p class="plaintext">
<code>set <a href="gradcomdsetxyzte.html" target="pages">e</a></code><br>
<code><a href="gradfunceloop.html" target="pages">eloop</a></code><br>
<code><a href="gradcomdenableprint.html" target="pages">enable print</a></code><br>
<code>q <a href="gradcomdqens.html" target="pages">ens</a></code><br> 
<code>set <a href="gradcomdsetlatlonlevtimeens.html" target="pages">ens</a></code><br>
<a href="ensembles.html" target="pages">ensemble dimension</a><br>
<a href="gradcomdgrads.html#env" target="pages">environment variables</a><br>
<code><a href="gradcomdexec.html" target="pages">exec</a></code><br>
<code><a href="gradfuncexp.html" target="pages">exp()</a></code><br>
<a href="expressions.html" target="pages">expressions</a><br>
<a href="utilities.html" target="pages">external utilites</a><br>
<p>
<a name="indexf">
<table cellpadding=2 border=0 WIDTH=20>
<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
<font color="fffacd"><b>F</b></font></td></tr>
</table>
</a>

<p class="plaintext">
<code>set <a href="gradcomdsetfgvals.html" target="pages">fgvals</a></code><br> 
<code><a href="gradcomdquery.html" target="pages">q</a> file(s)</code><br>
<code><a href="gradcomdflush.html" target="pages">flush</a></code><br> 
<code><a href="gradfuncfndlvl.html" target="pages">fndlvl()</a></code><br>
<a href="fontcontrol.html" target="pages">font control</a><br>
<a href="font.html" target="pages">font file</a><br>
<code>set <a href="gradcomdsetfont.html" target="pages">font</a></code><br> 
<code>set <a href="gradcomdsetframe.html" target="pages">frame</a></code><br> 
<code>disable <a href="gradcomddisablefwrite.html" target="pages">fwrite</a></code><br>
<code>q <a href="gradcomdqfwrite.html" target="pages">fwrite</a></code><br> 
<code>set <a href="gradcomdsetfwrite.html" target="pages">fwrite</a></code><br>
<a href="functions.html" target="pages">functions: alpha</a><br>
<a href="functionsatt.html" target="pages">functions: attribute</a><br>
<a href="mathfunctions.html" target="pages">math functions</a><br>
<p>
<a name="indexg">
<table cellpadding=2 border=0 WIDTH=20>
<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
<font color="fffacd"><b>G</b></font></td></tr>
</table>
</a>

<p class="plaintext">
<code>set <a href="gradcomdsetgeotiff.html" target="pages">geotiff</a></code><br>
<code><a href="gradfuncgint.html" target="pages">gint()</a></code><br>
<code><a href="gradfuncgr2stn.html" target="pages">gr2stn()</a></code><br>
<code><a href="gradcomdquery.html" target="pages">q</a> gr2w</code><br>
<code><a href="gradcomdquery.html" target="pages">q</a> gr2xy</code><br>
<code>set <a href="gradcomdsetgrads.html" target="pages">grads</a></code><br> 
<code><a href="gradcomdgrads.html" target="pages">grads</a></code><br>
<code><a href="gradcomdgrads.html" target="pages">gradsc</a></code><br>
<code><a href="gradcomdgrads.html" target="pages">gradsdap</a></code><br>
<code><a href="gradcomdgrads.html" target="pages">gradsdods</a></code><br>
<code><a href="gradcomdgrads.html" target="pages">gradshdf</a></code><br>
<code><a href="gradcomdgrads.html" target="pages">gradsnc</a></code><br>
  <a href="grib.html" target="pages">GRIB format</a><br>
<code><a href="gradutilgribmap.html" target="pages">gribmap</a></code><br>
<code><a href="gradutilgribscan.html" target="pages">gribscan</a></code><br>
<code><a href="gradutilgrib2scan.html" target="pages">grib2scan</a></code><br>
<code>set <a href="gradcomdsetgrid.html" target="pages">grid</a></code><br>
<code>set <a href="gradcomdsetgridln.html" target="pages">gridln</a></code><br>
<code><a href="gsf.html" target="pages">gsfallow()</a></code><br>
<code><a href="gsf.html" target="pages">gsfpath()</a></code><br>
<code><a href="gradutilgxeps.html" target="pages">gxeps</a></code><br>
<code><a href="gradcomdquery.html" target="pages">q</a> gxinfo</code><br>
<code><a href="gradcomdquery.html" target="pages">q</a> gxout</code><br>
<code>set <a href="gradcomdsetgxout.html" target="pages">gxout</a></code><br>  
<code><a href="gradutilgxps.html" target="pages">gxps</a></code><br>
<code><a href="gradutilgxtran.html" target="pages">gxtran</a></code><br>
</font>

<p>
<a name="indexh">
<table cellpadding=2 border=0 WIDTH=20>
<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
<font color="fffacd"><b>H</b></font></td></tr>
</table>
</a>

<p class="plaintext">
<a href="imageoutput.html" target="pages">hardcopy output</a><br>
<code><a href="gradfunchcurl.html" target="pages">hcurl()</a></code><br>
  <code><a href="SDFdescriptorfile.html" target="pages">HDF-SDS format</a></code><br>
<code><a href="gradfunchdivg.html" target="pages">hdivg()</a></code><br>
<code><a href="gradcomdhelp.html" target="pages">help</a></code><br>
<code>set <a href="gradcomdsethempref.html" target="pages">hempref</a></code><br>

<p class="plaintext">
<a name="indexi">
<table cellpadding=2 border=0 WIDTH=20>
<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
<font color="fffacd"><b>I</b></font></td></tr>
</table>
</a>
<p class="plaintext">
<a href="imageoutput.html" target="pages">image output</a><br>
<code>set <a href="gradcomdsetimprun.html" target="pages">imprun</a></code><br>

<p class="plaintext">
<a name="indexj">
<table cellpadding=2 border=0 WIDTH=20>
<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
<font color="fffacd"><b>J</b></font></td></tr>
</table>
</a>
<p class="plaintext">

<p class="plaintext"> 
<a name="indexk">
<table cellpadding=2 border=0 WIDTH=20>
<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
<font color="fffacd"><b>K</b></font></td></tr>
</table>
</a>
<p class="plaintext">
<code>set <a href="gradcomdsetkml.html" target="pages">kml</a></code><br>


<p class="plaintext">
<a name="indexl">
</a></p>
<table cellpadding=2 border=0 WIDTH=20>
  <tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
  <font color="fffacd"><b>L</b></font></td></tr>
</table>
</a>

<p class="plaintext">
<code>set <a href="gradcomdsetlatlonlevtimeens.html" target="pages">lat</a></code><br>
<code>set <a href="gradcomdsetlatlonlevtimeens.html" target="pages">lev</a></code><br>
<code>set <a href="gradcomdsetlfcols.html" target="pages">lfcols</a></code><br> 
script <a href="library.html" target="pages">library</a><br>
<code>draw <a href="gradcomddrawline.html" target="pages">line</a></code><br>
<code>set <a href="gradcomdsetline.html" target="pages">line</a></code><br>
<code><a href="gradfunclog.html" target="pages">log()</a></code><br>
<code><a href="gradfunclog10.html" target="pages">log10()</a></code><br>
<code>set <a href="gradcomdsetlog1d.html" target="pages">log1d</a></code><br>
<code>set <a href="gradcomdsetlatlonlevtimeens.html" target="pages">lon</a></code><br>
<code>set <a href="gradcomdsetloopdim.html" target="pages">loopdim</a></code><br>
<code>set <a href="gradcomdsetlooping.html" target="pages">looping</a></code><br> 
<code><a href="gradfunclterp.html" target="pages">lterp()</a></code><br> 
</font>

<p>
<a name="indexm">
<table cellpadding=2 border=0 WIDTH=20>
<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
<font color="fffacd"><b>M</b></font></td></tr>
</table>
</a>

<p class="plaintext">
<code><a href="gradfuncmag.html" target="pages">mag()</a></code><br>
<a href="map.html" target="pages">map projections</a><br>
<code>draw <a href="gradcomddrawmap.html" target="pages">map</a></code><br>
<code>set <a href="gradcomdsetmap.html" target="pages">map</a></code><br>
<code>draw <a href="gradcomddrawmark.html" target="pages">mark</a></code><br>
<code><a href="gradfuncmaskout.html" target="pages">maskout()</a></code><br> 
<a href="mathfunctions.html" target="pages">math functions</a><br>
<code><a href="gradfuncmax.html" target="pages">max()</a></code><br>
<code><a href="gradfuncmaxloc.html" target="pages">maxloc()</a></code><br>
<code>set <a href="gradcomdsetmdlopts.html" target="pages">mdlopts</a></code><br>
<code><a href="gradfuncmean.html" target="pages">mean()</a></code><br>
<a href="imageoutput.html" target="pages">metafiles</a><br>
<code><a href="gradfuncmin.html" target="pages">min()</a></code><br>
<code><a href="gradfuncminloc.html" target="pages">minloc()</a></code><br>
<code>set <a href="gradcomdsetmissconn.html" target="pages">missconn</a></code><br>
<code><a href="gradcomdmodify.html" target="pages">modify</a></code><br>
<code>set <a href="gradcomdsetmpdraw.html" target="pages">mpdraw</a></code><br>
<code>set <a href="gradcomdsetmpdset.html" target="pages">mpdset</a></code><br>
<code>set <a href="gradcomdsetmproj.html" target="pages">mproj</a></code><br>
<code>set <a href="gradcomdsetmpt.html" target="pages">mpt</a></code><br>
<code>set <a href="gradcomdsetmpvals.html" target="pages">mpvals</a></code><br>
<a href="pagecontrol.html#multipanel" target="pages">multi-panel plots</a><br>
</font>

<p>
<a name="indexn">
<table cellpadding=2 border=0 WIDTH=20>
<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
<font color="fffacd"><b>N</b></font></td></tr>
</table>
</a>

<p class="plaintext">
<code><a href="SDFdescriptorfile.html" target="pages">NetCDF format</a></code><br>
</font>

<p>
<a name="indexo">
<table cellpadding=2 border=0 WIDTH=20>
<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
<font color="fffacd"><b>O</b></font></td></tr>
</table>
</a>

<p class="plaintext">
<code><a href="gradfuncoabin.html" target="pages">oabin()</a></code><br>
<code><a href="gradfuncoacres.html" target="pages">oacres()</a></code><br>
<code><a href="offt.html" target="pages">offt</a></code><br>
<code><a href="gradcomdopen.html" target="pages">open</a></code><br>
<code><a href="gradcomdoutxwd.html" target="pages">outxwd</a></code><br>
</font>

<p>
<a name="indexp">
<table cellpadding=2 border=0 WIDTH=20>
<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
<font color="fffacd"><b>P</b></font></td></tr>
</table>
</a>

<p class="plaintext">
<a href="pagecontrol.html" target="pages">page control</a><br>
<code>set <a href="gradcomdsetparea.html" target="pages">parea</a></code><br>
  <a href="http://dao.gsfc.nasa.gov/software/grads/win32/latest/" target="_top">PC 
  GrADS</a><br>
<code><a href="pdef.html" target="pages">PDEF</a></code><br>
<a href="pagecontrol.html#plotarea" target="pages">plot area</a><br>
<code>set <a href="gradcomdsetpoli.html" target="pages">poli</a></code><br>
<code>draw <a href="gradcomddrawpolyf.html" target="pages">polyf</a></code><br>
<code>q <a href="gradcomdqpos.html" target="pages">pos</a></code><br> 
<code><a href="gradfuncpow.html" target="pages">pow()</a></code><br>
<code><a href="gradcomdprint.html" target="pages">print</a></code><br>
<code>disable <a href="gradcomddisableprint.html" target="pages">print</a></code><br>
<code>enable <a href="gradcomdenableprint.html" target="pages">print</a></code><br>  
<code><a href="gradcomdprintim.html" target="pages">printim</a></code><br>
<code>set <a href="gradcomdsetprnopts.html" target="pages">prnopts</a></code><br>
</font>

<p>
<a name="indexq">
<table cellpadding=2 border=0 WIDTH=20>
<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
<font color="fffacd"><b>Q</b></font></td></tr>
</table>
</a>

<p class="plaintext">
<code><a href="gradcomdquery.html" target="pages">q (query)</a></code><br>
<code><a href="gradcomdqattr.html" target="pages">q attr</a></code><br> 
<code><a href="gradcomdqdbf.html" target="pages">q dbf</a></code><br>
<code><a href="gradcomdqdialog.html" target="pages">q dialog</a></code><br>
<code><a href="gradcomdqens.html" target="pages">q ens</a></code><br> 
<code><a href="gradcomdqfwrite.html" target="pages">q fwrite</a></code><br> 
<code><a href="gradcomdqpos.html" target="pages">q pos</a></code><br> 
<code><a href="gradcomdqsdfwrite.html" target="pages">q sdfwrite</a></code><br>
<code><a href="gradcomdqshades.html" target="pages">q shades</a></code><br>
<code><a href="gradcomdqshp.html" target="pages">q shp</a></code><br>
<code><a href="gradcomdqshpopts.html" target="pages">q shpopts</a></code><br>
<a href="reference_card.pdf" target="_top">quick: commands</a><br>
<a href="reference_card_scl.pdf"target="_top">quick: scripts</a><br>
<code><a href="gradcomdquit.html" target="pages">quit</a></code><br>  
</font>

<p>
<a name="indexr">
<table cellpadding=2 border=0 WIDTH=20>
<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
<font color="fffacd"><b>R</b></font></td></tr>
</table>
</a>

<p class="plaintext">
<code>set <a href="gradcomdsetrband.html" target="pages">rband</a></code><br>
<code>set <a href="gradcomdsetrbcols.html" target="pages">rbcols</a></code><br>
<code>set <a href="gradcomdsetrbrange.html" target="pages">rbrange</a></code><br>
<a href="pagecontrol.html#real" target="pages">real page</a><br>
<code>draw <a href="gradcomddrawrec.html" target="pages">rec</a></code><br>
<code>draw <a href="gradcomddrawrecf.html" target="pages">recf</a></code><br>
<code><a href="gradcomdredrawbutton.html" target="pages">redraw button</a></code><br>
<code><a href="gradcomdreset.html" target="pages">reset</a></code><br>   
<code><a href="gradcomdreinit.html" target="pages">reinit</a></code><br>   
<a href="reinitialization.html" target="pages">reinitialization</a><br>
<code>set <a href="gradcomdsetrgb.html" target="pages">rgb</a></code><br>
<code><a href="gradcomdrun.html" target="pages">run</a></code><br> 
</font>

<p>
<a name="indexs">
<table cellpadding=2 border=0 WIDTH=20>
<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
<font color="fffacd"><b>S</b></font></td></tr>
</table>
</a>

<p class="plaintext">
<code><a href="gradfuncs2g1d.html" target="pages">s2g1d()</a></code><br>
<code><a href="gradfuncscorr.html" target="pages">scorr()</a></code><br>
<code><a href="gradcomdscreen.html" target="pages">screen</a></code><br>
<a href="gsf.html" target="pages">script functions</a><br>
<a href="library.html" target="pages">script library</a><br>
<a href="script.html" target="pages">scripting language</a><br>
<code><a href="gradcomdsdfopen.html" target="pages">sdfopen</a></code><br>
<code><a href="gradcomdsdfwrite.html" target="pages">sdfwrite</a></code><br>
<code>q <a href="gradcomdqsdfwrite.html" target="pages">sdfwrite</a></code><br>
<code>set <a href="gradcomdsetsdfattr.html" target="pages">sdfattr</a></code><br>
<code>set <a href="gradcomdsetsdfwrite.html" target="pages"> sdfwrite</a></code><br>
<code><a href="gradcomdsetannot.html" target="pages">set annot</a></code><br>
<code><a href="gradcomdsetarrlab.html" target="pages">set arrlab</a></code><br>
<code><a href="gradcomdsetarrowhead.html" target="pages">set arrowhead</a></code><br>
<code><a href="gradcomdsetarrscl.html" target="pages">set arrscl</a></code><br>
<code><a href="gradcomdsetbackground.html" target="pages">set background</a></code><br>
<code><a href="gradcomdsetbarbase.html" target="pages">set barbase</a></code><br>
<code><a href="gradcomdsetbargap.html" target="pages">set bargap</a></code><br>
<code><a href="gradcomdsetbaropts.html" target="pages">set baropts</a></code><br>
<code><a href="gradcomdsetblack.html" target="pages">set black</a></code><br>
<code><a href="gradcomdsetbutton.html" target="pages">set button</a></code><br>
<code><a href="gradcomdsetcachesf.html" target="pages">set cachesf</a></code><br>
<code><a href="gradcomdsetccolor.html" target="pages">set ccolor</a></code><br>
<code><a href="gradcomdsetccols.html" target="pages">set ccols</a></code><br>
<code><a href="gradcomdsetcint.html" target="pages">set cint</a></code><br>
<code><a href="gradcomdsetchunksize.html" target="pages">set chunksize</a></code><br>  
<code><a href="gradcomdsetclab.html" target="pages">set clab</a></code><br>
<code><a href="gradcomdsetclevs.html" target="pages">set clevs</a></code><br>
<code><a href="gradcomdsetclip.html" target="pages">set clip</a></code><br>
<code><a href="gradcomdsetclopts.html" target="pages">set clopts</a></code><br>
<code><a href="gradcomdsetclskip.html" target="pages">set clskip</a></code><br>
<code><a href="gradcomdsetcmark.html" target="pages">set cmark</a></code><br>
<code><a href="gradcomdsetcmax.html" target="pages">set cmax</a></code><br>
<code><a href="gradcomdsetcmin.html" target="pages">set cmin</a></code><br>
<code><a href="gradcomdsetcmin.html" target="pages">set cmin</a></code><br>
<code><a href="gradcomdsetcoslat.html" target="pages">set coslat</a></code><br>
<code><a href="gradcomdsetcstyle.html" target="pages">set cstyle</a></code><br>
<code><a href="gradcomdsetcterp.html" target="pages">set cterp</a></code><br>
<code><a href="gradcomdsetcthick.html" target="pages">set cthick</a></code><br>
<code><a href="gradcomdsetdatawarn.html" target="pages">set datawarn</a></code><br>
<code><a href="gradcomdsetdbuff.html" target="pages">set dbuff</a></code><br>
<code><a href="gradcomdsetdefval.html" target="pages">set defval</a></code><br>
<code><a href="gradcomdsetdfile.html" target="pages">set dfile</a></code><br>
<code><a href="gradcomdsetdialog.html" target="pages">set dialog</a></code><br> 
<code><a href="gradcomdsetdignum.html" target="pages">set dignum</a></code><br> 
<code><a href="gradcomdsetdigsize.html" target="pages">set digsiz</a></code><br> 
<code><a href="gradcomdsetdisplay.html" target="pages">set display</a></code><br> 
<code><a href="gradcomdsetdropmenu.html" target="pages">set dropmenu</a></code><br>
<code><a href="gradcomdsetlatlonlevtimeens.html" target="pages">set ens</a></code><br>
<code><a href="gradcomdsetfgvals.html" target="pages">set fgvals</a></code><br> 
<code><a href="gradcomdsetfont.html" target="pages">set font</a></code><br> 
<code><a href="gradcomdsetframe.html" target="pages">set frame</a></code><br> 
<code><a href="gradcomdsetfwrite.html" target="pages">set fwrite</a></code><br>
<code><a href="gradcomdsetgrads.html" target="pages">set grads</a></code><br> 
<code><a href="gradcomdsetgeotiff.html" target="pages">set geotiff</a></code><br> 
<code><a href="gradcomdsetgrid.html" target="pages">set grid</a></code><br>
<code><a href="gradcomdsetgridln.html" target="pages">set gridln</a></code><br>
<code><a href="gradcomdsetgxout.html" target="pages">set gxout</a></code><br>  
<code><a href="gradcomdsethempref.html" target="pages">set hempref</a></code><br>
<code><a href="gradcomdsetimprun.html" target="pages">set imprun</a></code><br>
<code><a href="gradcomdsetkml.html" target="pages">set kml</a></code><br>
<code><a href="gradcomdsetlatlonlevtimeens.html" target="pages">set lat</a></code><br>
<code><a href="gradcomdsetlatlonlevtimeens.html" target="pages">set lev</a></code><br>
<code><a href="gradcomdsetlfcols.html" target="pages">set lfcols</a></code><br> 
<code><a href="gradcomdsetline.html" target="pages">set line</a></code><br>
<code><a href="gradcomdsetlog1d.html" target="pages">set log1d</a></code><br>
<code><a href="gradcomdsetlatlonlevtimeens.html" target="pages">set lon</a></code><br>
<code><a href="gradcomdsetloopdim.html" target="pages">set loopdim</a></code><br>
<code><a href="gradcomdsetlooping.html" target="pages">set looping</a></code><br> 
<code><a href="gradcomdsetmap.html" target="pages">set map</a></code><br>
<code><a href="gradcomdsetmdlopts.html" target="pages">set mdlopts</a></code><br>
<code><a href="gradcomdsetmissconn.html" target="pages">set missconn</a></code><br>
<code><a href="gradcomdsetmpdraw.html" target="pages">set mpdraw</a></code><br>
<code><a href="gradcomdsetmpdset.html" target="pages">set mpdset</a></code><br>
<code><a href="gradcomdsetmproj.html" target="pages">set mproj</a></code><br>
<code><a href="gradcomdsetmpt.html" target="pages">set mpt</a></code><br>
<code><a href="gradcomdsetmpvals.html" target="pages">set mpvals</a></code><br>
<code><a href="gradcomdsetparea.html" target="pages">set parea</a></code><br>
<code><a href="gradcomdsetpoli.html" target="pages">set poli</a></code><br>
<code><a href="gradcomdsetprnopts.html" target="pages">set prnopts</a></code><br>
<code><a href="gradcomdsetrband.html" target="pages">set rband</a></code><br>
<code><a href="gradcomdsetrbcols.html" target="pages">set rbcols</a></code><br>
<code><a href="gradcomdsetrbrange.html" target="pages">set rbrange</a></code><br>
<code><a href="gradcomdsetrgb.html" target="pages">set rgb</a></code><br>
<code><a href="gradcomdsetsdfattr.html" target="pages">set sdfattr</a></code><br>
<code><a href="gradcomdsetsdfwrite.html" target="pages">set sdfwrite</a></code><br>
<code><a href="gradcomdsetshp.html" target="pages">set shp</a></code><br>
<code><a href="gradcomdsetshpattr.html" target="pages">set shpattr</a></code><br>
<code><a href="gradcomdsetshpopts.html" target="pages">set shpopts</a></code><br>
<code><a href="gradcomdsetstat.html" target="pages">set stat</a></code><br>
<code><a href="gradcomdsetstid.html" target="pages">set stid</a></code><br>
<code><a href="gradcomdsetstnprint.html" target="pages">set stnprint</a></code><br>
<code><a href="gradcomdsetstring.html" target="pages">set string</a></code><br>
<code><a href="gradcomdsetstrmden.html" target="pages">set strmden</a></code><br>
<code><a href="gradcomdsetstrsiz.html" target="pages">set strsiz</a></code><br>
<code><a href="gradcomdsetxyzte.html" target="pages">set t</a></code><br>
<code><a href="gradcomdsetlatlonlevtimeens.html" target="pages">set time</a></code><br>
<code><a href="gradcomdsettimelab.html" target="pages">set timelab</a></code><br>
<code><a href="gradcomdsettlsupp.html" target="pages">set tlsupp</a></code><br>
<code><a href="gradcomdsetundef.html" target="pages">set undef</a></code><br>
<code><a href="gradcomdsetvpage.html" target="pages">set vpage</a></code><br>
<code><a href="gradcomdsetvrange.html" target="pages">set vrange</a></code><br>
<code><a href="gradcomdsetvrange2.html" target="pages">set vrange2</a></code><br>
<code><a href="gradcomdsetwarn.html" target="pages">set warn</a></code><br>
<code><a href="gradcomdsetwxcols.html" target="pages">set wxcols</a></code><br>
<code><a href="gradcomdsetwxopt.html" target="pages">set wxopt</a></code><br>
<code><a href="gradcomdsetxyzte.html" target="pages">set x</a></code><br>
<code><a href="gradcomdsetxaxis.html" target="pages">set xaxis</a></code><br>
<code><a href="gradcomdsetxflip.html" target="pages">set xflip</a></code><br>
<code><a href="gradcomdsetxlab.html" target="pages">set xlab</a></code><br>
<code><a href="gradcomdsetxlabs.html" target="pages">set xlabs</a></code><br>
<code><a href="gradcomdsetxlevs.html" target="pages">set xlevs</a></code><br>
<code><a href="gradcomdsetxlint.html" target="pages">set xlint</a></code><br>
<code><a href="gradcomdsetxlopts.html" target="pages">set xlopts</a></code><br>
<code><a href="gradcomdsetxlpos.html" target="pages">set xlpos</a></code><br>
<code><a href="gradcomdsetxsize.html" target="pages">set xsize</a></code><br>
<code><a href="gradcomdsetxyrev.html" target="pages">set xyrev</a></code><br>
<code><a href="gradcomdsetxyzte.html" target="pages">set y</a></code><br>
<code><a href="gradcomdsetyaxis.html" target="pages">set yaxis</a></code><br>
<code><a href="gradcomdsetyflip.html" target="pages">set yflip</a></code><br>
<code><a href="gradcomdsetylab.html" target="pages">set ylab</a></code><br>
<code><a href="gradcomdsetylabs.html" target="pages">set ylabs</a></code><br>
<code><a href="gradcomdsetylevs.html" target="pages">set ylevs</a></code><br>
<code><a href="gradcomdsetylint.html" target="pages">set ylint</a></code><br>
<code><a href="gradcomdsetylopts.html" target="pages">set ylopts</a></code><br>
<code><a href="gradcomdsetylpos.html" target="pages">set ylpos</a></code><br>
<code><a href="gradcomdsetxyzte.html" target="pages">set z</a></code><br>
<code><a href="gradcomdsetzlog.html" target="pages">set zlog</a></code><br>
<code>query <a href="gradcomdqshades.html" target="pages">shades</a></code><br>
<a href="shapefiles.html" target="pages">shapefiles</a><br>
<code><a href="gradcomdshell.html" target="pages">!shell</a></code><br>
<code>draw <a href="gradcomddrawshp.html" target="pages">shp</a></code><br>
<code>q <a href="gradcomdqshp.html" target="pages">shp</a></code><br>
<code>set <a href="gradcomdsetshp.html" target="pages">shp</a></code><br>
<code>q <a href="gradcomdqshpopts.html" target="pages">shpopts</a></code><br>
<code>set <a href="gradcomdsetshpopts.html" target="pages">shpopts</a></code><br>
<code><a href="gradfuncsin.html" target="pages">sin()</a></code><br>
<code><a href="gradfuncskip.html" target="pages">skip()</a></code><br>
<code><a href="gradfuncsmth9.html" target="pages">smth9()</a></code><br>
<code><a href="gradfuncsqrt.html" target="pages">sqrt()</a></code><br>
<code><a href="gradfuncsregr.html" target="pages">sregr()</a></code><br>
<a href="start.html" target="pages">starting GrADS</a><br>
<code>set <a href="gradcomdsetstat.html" target="pages">stat</a></code><br>
about <a href="aboutstationdata.html" target="pages">station data</a><br>
using <a href="usingstationdata.html" target="pages">station data</a><br>
<code>set <a href="gradcomdsetstid.html" target="pages">stid</a></code><br>
<code><a href="gradfuncstnave.html" target="pages">stnave()</a></code><br>
<code><a href="gradfuncstnmin.html" target="pages">stnmin()</a></code><br>
<code><a href="gradutilstnmap.html" target="pages">stnmap</a></code><br>
<code><a href="gradfuncstnmax.html" target="pages">stnmax()</a></code><br>
<code>set <a href="gradcomdsetstnprint.html" target="pages">stnprint</a></code><br>
<a href="fontcontrol.html" target="pages">string formatting</a><br>
<code>draw <a href="gradcomddrawstring.html" target="pages">string</a></code><br> 
<code><a href="gradcomdquery.html" target="pages">q</a> string</code><br>
<code>set <a href="gradcomdsetstring.html" target="pages">string</a></code><br>
<code>set <a href="gradcomdsetstrmden.html" target="pages">strmden</a></code><br>
<code>set <a href="gradcomdsetstrsiz.html" target="pages">strsiz</a></code><br>
<code><a href="gradfuncsum.html" target="pages">sum()</a></code><br>
<code><a href="gradfuncsumg.html" target="pages">sumg()</a></code><br>
<a href="supplibs.html" target="pages">supplibs</a><br>
<code><a href="gradcomdswap.html" target="pages">swap</a></code><br>
</font>
<p>
<a name="indext">
<table cellpadding=2 border=0 WIDTH=20>
<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
<font color="fffacd"><b>T</b></font></td></tr>
</table>
</a>

<p class="plaintext">
<code>set <a href="gradcomdsetxyzte.html" target="pages">t</a></code><br>
<code><a href="gradfunctan.html" target="pages">tan()</a></code><br>     
<code><a href="gradfunctcorr.html" target="pages">tcorr()</a></code><br>
<a href="templates.html" target="pages">templates</a><br>
<code><a href="gradcomdquery.html" target="pages">q</a> time</code><br>
<code>set <a href="gradcomdsetlatlonlevtimeens.html" target="pages">time</a></code><br>
<code>set <a href="gradcomdsettimelab.html" target="pages">timelab</a></code><br>
<code>draw <a href="gradcomddrawtitle.html" target="pages">title</a></code><br>
<code><a href="gradfunctloop.html" target="pages">tloop()</a></code><br>
<code>set <a href="gradcomdsettlsupp.html" target="pages">tlsupp</a></code><br>
<code><a href="gradfunctmave.html" target="pages">tmave()</a></code><br>
<code><a href="gradfunctregr.html" target="pages">tregr()</a></code><br>
<a href="tutorial.html" target="pages">Tutorial</a><br>
<code><a href="gradfunctvrh2q.html" target="pages">tvrh2q()</a></code><br>
<code><a href="gradfunctvrh2t.html" target="pages">tvrh2t()</a></code><br>
</font>

<p>
<a name="indexu">
<table cellpadding=2 border=0 WIDTH=20>
<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
<font color="fffacd"><b>U</b></font></td></tr>
</table>
</a>

<p class="plaintext">
<code><a href="gradcomdquery.html" target="pages">q</a> undef</code><br>
<code>set <a href="gradcomdsetundef.html" target="pages">undef</a></code><br>
<code><a href="gradcomdundefine.html" target="pages">undefine</a></code><br>
<a href="udf.html" target="pages">user defined functions</a><br>
<a href="users.html" target="pages">user's guide</a><br>
external <a href="utilities.html" target="pages">utilites</a><br>
</font>

<p>
<a name="indexv">
<table cellpadding=2 border=0 WIDTH=20>
<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
<font color="fffacd"><b>V</b></font></td></tr>
</table>
</a>

<p class="plaintext">
<a href="variable.html" target="pages">variables</a><br>
<code><a href="gradfuncvint.html" target="pages">vint()</a></code><br>    
<a href="pagecontrol.html#real" target="pages">virtual page</a><br>
<code>set <a href="gradcomdsetvpage.html" target="pages">vpage</a></code><br>
<code>set <a href="gradcomdsetvrange.html" target="pages">vrange</a></code><br>
<code>set <a href="gradcomdsetvrange2.html" target="pages">vrange2</a></code><br>
</font>

<p>
<a name="indexw">
<table cellpadding=2 border=0 WIDTH=20>
<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
<font color="fffacd"><b>W</b></font></td></tr>
</table>
</a>

<p class="plaintext">
<code><a href="gradcomdquery.html" target="pages">q</a> w2gr</code><br>
<code><a href="gradcomdquery.html" target="pages">q</a> w2xy</code><br>
<code>set <a href="gradcomdsetwarn.html" target="pages">warn</a></code><br>
<code><a href="gradcomdwi.html" target="pages">wi</a></code><br>
<a href="script.html#widgets" target="pages">widgets</a><br>
<code>set <a href="gradcomdsetwxcols.html" target="pages">wxcols</a></code><br>
<code>set <a href="gradcomdsetwxopt.html" target="pages">wxopt</a></code><br>
<code>draw <a href="gradcomddrawwxsym.html" target="pages">wxsym</a></code><br>
</font>

<p>
<a name="indexx">
<table cellpadding=2 border=0 WIDTH=20>
<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
<font color="fffacd"><b>X</b></font></td></tr>
</table>
</a>

<p class="plaintext">
<code>set <a href="gradcomdsetxyzte.html" target="pages">x</a></code><br>
<code>set <a href="gradcomdsetxaxis.html" target="pages">xaxis</a></code><br>
<code><a href="gradcomdxdfopen.html" target="pages">xdfopen</a></code><br>
<code>set <a href="gradcomdsetxflip.html" target="pages">xflip</a></code><br>
<code>draw <a href="gradcomddrawxlab.html" target="pages">xlab</a></code><br>
<code>set <a href="gradcomdsetxlab.html" target="pages">xlab</a></code><br>
<code>set <a href="gradcomdsetxlabs.html" target="pages">xlabs</a></code><br>
<code>set <a href="gradcomdsetxlevs.html" target="pages">xlevs</a></code><br>
<code>set <a href="gradcomdsetxlint.html" target="pages">xlint</a></code><br>
<code>set <a href="gradcomdsetxlopts.html" target="pages">xlopts</a></code><br>
<code>set <a href="gradcomdsetxlpos.html" target="pages">xlpos</a></code><br>
<code>set <a href="gradcomdsetxsize.html" target="pages">xsize</a></code><br>
<code>set <a href="gradcomdsetxyrev.html" target="pages">xyrev</a></code><br>
<code><a href="gradcomdquery.html" target="pages">q</a> xy2gr</code><br>
<code><a href="gradcomdquery.html" target="pages">q</a> xy2w</code><br>
</font>

<p>
<a name="indexy">
<table cellpadding=2 border=0 WIDTH=20>
<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
<font color="fffacd"><b>Y</b></font></td></tr>
</table>
</a>

<p class="plaintext">
<code>set <a href="gradcomdsetxyzte.html" target="pages">y</a></code><br>
<code>set <a href="gradcomdsetyaxis.html" target="pages">yaxis</a></code><br>
<code>set <a href="gradcomdsetyflip.html" target="pages">yflip</a></code><br>
<code>draw <a href="gradcomddrawylab.html" target="pages">ylab</a></code><br>
<code>set <a href="gradcomdsetylab.html" target="pages">ylab</a></code><br>
<code>set <a href="gradcomdsetylabs.html" target="pages">ylabs</a></code><br>
<code>set <a href="gradcomdsetylevs.html" target="pages">ylevs</a></code><br>
<code>set <a href="gradcomdsetylint.html" target="pages">ylint</a></code><br>
<code>set <a href="gradcomdsetylopts.html" target="pages">ylopts</a></code><br>
<code>set <a href="gradcomdsetylpos.html" target="pages">ylpos</a></code><br>
</font>

<p>
<a name="indexz">
<table cellpadding=2 border=0 WIDTH=20>
<tr><td bgcolor="7b2100" align=center valign=center WIDTH=20>
<font color="fffacd"><b>Z</b></font></td></tr>
</table>
</a>

<p class="plaintext">
<code>set <a href="gradcomdsetxyzte.html" target="pages">z</a></code><br>
<code>set <a href="gradcomdsetzlog.html" target="pages">zlog</a></code><br>
</font>

</body>
</html>
\ No newline at end of file
diff --git a/doc/library.html b/doc/library.html
index 91e0934..cc70057 100644
--- a/doc/library.html
+++ b/doc/library.html
@@ -163,13 +163,11 @@
 
   <tr> 
 
-    <td valign=top border=1 class="plaintext"><a href="ftp://cola.gmu.edu/grads/scripts/meteogram_eta.gs">meteogram_eta.gs</a><br>
-      <a href="ftp://cola.gmu.edu/grads/scripts/meteogram_gfs.gs">meteogram_gfs.gs</a><br>
-      <a href="ftp://cola.gmu.edu/grads/scripts/meteogram_gfsb.gs">meteogram_gfsb.gs</a></td>
+    <td valign=top border=1 class="plaintext"><a href="ftp://cola.gmu.edu/grads/scripts/meteogram_subset_GDS.gs">meteogram_subset_GDS.gs</a><br>
+      <a href="ftp://cola.gmu.edu/grads/scripts/meteogram_GDS.gs">meteogram_GDS.gs</a></td>
 
-    <td class="plaintext">These scrips draw meteograms based on NCEP forecast 
-      data, which is accessed through the GrADS-DODS Server. You must use a DODS-enabled 
-      version of GrADS for these scripts to work. </td>
+    <td class="plaintext">These scrips draw a 10-day meteogram based on NCEP GFS forecast 
+      data, which is accessed through the GrADS Data Server. First run meteogram_subset_GDS.gs  with an OPeNDAP-enabled build of GrADS  to download the data to a local file. Then run meteogram_GDS.gs to draw the meteogram. </td>
   </tr>
 
   <tr>
diff --git a/doc/mathfunctions.html b/doc/mathfunctions.html
index 14a52c8..539e8f3 100644
--- a/doc/mathfunctions.html
+++ b/doc/mathfunctions.html
@@ -1,195 +1 @@
-<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
-
-<html>
-<head>
-<title>GrADS Scripting Language Math Functions</title>
-</head>
-<body text="#000000" bgcolor="e0f0ff">
-
-<h2><b>GrADS Scripting Language Math Functions</b></h2>
-<p>
-A set of math functions has been developed for use within the GrADS
-scripting language. Their use is somewhat self-explanatory, based on
-the following descriptions of the arguments and return codes.
-
-<p> <br>
-  else if (cmpwrd(name,"math_sqrt")) rc = gsfmath(pcmn,8);<br>
-  else if (cmpwrd(name,"math_abs")) rc = gsfmath(pcmn,9);<br>
-<p><code>rc = math_<i>trigfunc</i>(<i>angle <,angle2> </i>)</code> 
-<ul>
-  <code><i>trigfunc</i>  </code> sin, cos, tan, asin, acos, atan, atan2, 
-  sinh, cosh, tanh, asinh, acosh, or atanh<br>
-  <code><i>angle</i>     </code> must be given in radians 
-  <br>
-  <code><i>angle2</i>    </code> (only used for atan2) <br>
-  <code>rc        </code> the result of 
-  the trig function calculation 
-</ul>
-
-<p>
-<code>rc = math_format(<i>format,num</i>)</code>
-<ul>
-  <code><i>format</i>    </code> a C-language style format 
-  statement for a floating point number, e.g. <code>%5.2f</code><br>
-  <code><i>num</i>       </code> the number 
-  to be formatted<br>
-  <code>rc        </code> the formatted 
-  number
-</ul>
-<code>rc = math_nint(<i>num</i>)</code>
-<ul>
-  <code><i>num</i>       </code> a real number 
-  in decimal form<br>
-  <code>rc        </code> <code><i>num</i></code> 
-  rounded up or down to the nearest integer
-</ul>
-<code>rc = math_int(<i>num</i>)</code>
-<ul>
-  <code><i>num</i>       </code> a real number 
-  in decimal form<br>
-  <code>rc        </code> the integer 
-  part of <code><i>num</i></code> not greater than <code><i>num</i></code>
-</ul>
-<code>rc = math_log(<i>num</i>);</code> 
-<ul>
-  <code><i>num</i>       </code> any number 
-  > 0<br>
-  <code>rc        </code> natural logarithm 
-  of <code><i>num</i></code> 
-</ul>
-<code></code><code>rc = math_log10(<i>num</i>);</code> 
-<ul>
-  <code><i>num</i>       </code> any number 
-  > 0.0<br>
-  
-  <code>rc        </code> base 10 logarithm of <code><i>num</i></code> 
-  
-</ul>
-<code></code><code></code><code>rc = math_pow(<i>num,exponent</i>);</code> 
-<ul>
-  <p><code><i>num</i>       </code> any number<br>
-    <code><i>exponent</i>  </code> any number<br>
-    <code>rc        </code> <code><i>num</i></code> 
-    raised to the power <code><i>exponent</i></code> </p>
-</ul>
-<p><code>rc = math_sqrt(<i>num</i>)</code> </p>
-<ul>
-  <code><i>num</i>       </code> any number<br>
-  <code>rc        </code> the square root 
-  of <code><i>num</i></code> 
-</ul>
-<p><code>rc = math_abs(<i>num</i>)</code> </p>
-<ul>
-  <code><i>num</i>       </code> any number<br>
-  <code>rc        </code> the absolute 
-  value of <code><i>num</i></code> 
-</ul>
-<p><code>rc = math_exp(<i>num</i>)</code> </p>
-<ul>
-  <code><i>num</i>       </code> any number<br>
-  <code>rc        </code> the result of 
-  the exponential function; <code>e</code> raised to the power <code><i>num</i></code>
-</ul>
-<code></code><code>rc = math_fmod(<i>num1,num2</i>);</code> 
-<ul>
-  <code><i>num1</i>      </code> any number<br>
-  <code><i>num2</i>      </code> any number not 
-  equal to zero<br>
-  <code>rc        </code> the remainder 
-  when <code><i>num1</i></code> is divided by <code><i>num2</i></code> 
-</ul>
-<code>rc = math_mod(<i>num1,num2</i>);</code> 
-<ul>
-  <code><i>num1</i>      </code> any number<br>
-  <code><i>num2</i>      </code> any number not 
-  equal to zero<br>
-  <code>rc        </code> the integer 
-  part of the remainder when <code><i>num1</i></code> is divided by <code><i>num2</i></code> 
-</ul>
-<code>rc = math_strlen(<i>string</i>)</code>
-<ul>
-<code><i>string</i>    </code>
-any string variable<br>
-<code>rc        </code>
-the length of <code><i>string</i></code>
-</ul>
-<code>rc = valnum(<i>string</i>)</code>
-<ul>
-  <code><i>string</i>    </code> any string variable<br>
-  <code>rc         0 - <i>string</i></code> 
-  is not a number<br>
-  <code>           1 - 
-  <i>string</i></code> is an integer<br>
-  <code>           2 - 
-  <i>string</i></code> is not an integer
-</ul>
-
-<code>rc = wrdpos(<i>string,int</i>)</code>
- <ul>
-<code><i>string</i>    </code>
-any string, usually contains more than one word<br>
-<code><i>int</i>       </code>
-an integer<br>
-<code>rc        </code>
-word #<code><i>int</i></code of ><code><i>string</i></code> starts at this character #<br>
-</ul>
-
-
-<p>
-<h3>Usage Notes</h3>
-
-<p>
-These math functions will only work with GrADS version 1.8 (or higher). 
-
-<p>
-<h3>Examples </h3>
-
-<p> These script records were taken from a sample script called "<a href="ftp://cola.gmu.edu/grads/scripts/script_math_demo.gs">script_math_demo.gs</a>". 
-<p>
-<code>
-v = 3.1456<br>
-fmt = '%-6.1f'<br>
-rc = math_format(fmt,v)<br>
-say fmt' of 'v' = 'rc<br>
-<br>
-pi = 3.1415926<br>
-d2r = pi/180<br>
-angd = 45<br>
-ang = angd * d2r<br>
-cos = math_cos(ang)<br>
-say 'cos of 'angd' = 'cos<br>
-<br>
-num = '3.1455'<br>
-rc = valnum(num)<br>
-if (rc = 0) ; say num' is not a number' ; endif<br>
-if (rc = 1) ; say num' is an integer' ; endif<br>
-if (rc = 2) ; say num' is not an integer' ; endif<br>
-<br>
-v = 3.0<br>
-while(v < 4.0) <br>
-  rc1 = math_nint(v)<br>
-  rc2 = math_int(v)<br>
-  print 'nint of 'v' = 'rc1'  int of 'v' = 'rc2<br>
-  v = v + 0.1<br>
-endwhile<br>
-<br>
-pow = math_pow(2,0.5);<br>
-print '2 raised to the power 0.5 = 'pow<br>
-<br>
-num = math_exp(1)<br>
-print 'exp(1) = 'num<br>
-<br>
-fmod = math_fmod(5,2)<br>
-print '5 modulo 2 (the remainder when 5 is divided by 2) = 'fmod<br>
-<br>
-s = 'this is a test'<br>
-rc = math_strlen(s)<br>
-print 'length of the string "'s'" = 'rc
-p = 2<br>
-rc = wrdpos(s,p)<br>
-print 'word 'p' of the string "'s'" starts at character 'rc<br>
-<br>
-</code>
-</body>
-</html>
-
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->

<html>
<head>
<title>GrADS Scripting Language Math Functions</title>
</head>
<body text="#000000" bgcolor="e0f0ff">

<h2><b>GrADS Scripting Language Math Functions</b></h2>
<p>
A set of math functions has been developed for use within the GrADS
scripting language. Their use is somewhat self-explanatory, based on
the following descriptions of the arguments and return codes.

<p> <br>
  else if (cmpwrd(name,"math_sqrt")) rc = gsfmath(pcmn,8);<br>
  else if (cmpwrd(name,"math_abs")) rc = gsfmath(pcmn,9);<br>
<p><code>rc = math_<i>trigfunc</i>(<i>angle <,angle2> </i>)</code> 
<ul>
  <code><i>trigfunc</i>  </code> sin, cos, tan, asin, acos, atan, atan2, 
  sinh, cosh, tanh, asinh, acosh, or atanh<br>
  <code><i>angle</i>     </code> must be given in radians 
  <br>
  <code><i>angle2</i>    </code> (only used for atan2) <br>
  <code>rc        </code> the result of 
  the trig function calculation 
</ul>

<p>
<code>rc = math_format(<i>format,num</i>)</code>
<ul>
  <code><i>format</i>    </code> a C-language style format 
  statement for a floating point number, e.g. <code>%5.2f</code><br>
  <code><i>num</i>       </code> the number 
  to be formatted<br>
  <code>rc        </code> the formatted 
  number
</ul>
<code>rc = math_nint(<i>num</i>)</code>
<ul>
  <code><i>num</i>       </code> a real number 
  in decimal form<br>
  <code>rc        </code> <code><i>num</i></code> 
  rounded up or down to the nearest integer
</ul>
<code>rc = math_int(<i>num</i>)</code>
<ul>
  <code><i>num</i>       </code> a real number 
  in decimal form<br>
  <code>rc        </code> the integer 
  part of <code><i>num</i></code> not greater than <code><i>num</i></code>
</ul>
<code>rc = math_log(<i>num</i>);</code> 
<ul>
  <code><i>num</i>       </code> any number 
  > 0<br>
  <code>rc        </code> natural logarithm 
  of <code><i>num</i></code> 
</ul>
<code></code><code>rc = math_log10(<i>num</i>);</code> 
<ul>
  <code><i>num</i>       </code> any number 
  > 0.0<br>
  
  <code>rc        </code> base 10 logarithm of <code><i>num</i></code> 
  
</ul>
<code></code><code></code><code>rc = math_pow(<i>num,exponent</i>);</code> 
<ul>
  <p><code><i>num</i>       </code> any number<br>
    <code><i>exponent</i>  </code> any number<br>
    <code>rc        </code> <code><i>num</i></code> 
    raised to the power <code><i>exponent</i></code> </p>
</ul>
<p><code>rc = math_sqrt(<i>num</i>)</code> </p>
<ul>
  <code><i>num</i>       </code> any number<br>
  <code>rc        </code> the square root 
  of <code><i>num</i></code> 
</ul>
<p><code>rc = math_abs(<i>num</i>)</code> </p>
<ul>
  <code><i>num</i>       </code> any number<br>
  <code>rc        </code> the absolute 
  value of <code><i>num</i></code> 
</ul>
<p><code>rc = math_exp(<i>num</i>)</code> </p>
<ul>
  <code><i>num</i>       </code> any number<br>
  <code>rc        </code> the result of 
  the exponential function; <code>e</code> raised to the power <code><i>num</i></code>
</ul>
<code></code><code>rc = math_fmod(<i>num1,num2</i>);</code> 
<ul>
  <code><i>num1</i>      </code> any number<br>
  <code><i>num2</i>      </code> any number not 
  equal to zero<br>
  <code>rc        </code> the remainder 
  when <code><i>num1</i></code> is divided by <code><i>num2</i></code> 
</ul>
<code>rc = math_mod(<i>num1,num2</i>);</code> 
<ul>
  <code><i>num1</i>      </code> any number<br>
  <code><i>num2</i>      </code> any number not 
  equal to zero<br>
  <code>rc        </code> the integer 
  part of the remainder when <code><i>num1</i></code> is divided by <code><i>num2</i></code> 
</ul>
<code>rc = math_strlen(<i>string</i>)</code>
<ul>
<code><i>string</i>    </code>
any string variable<br>
<code>rc        </code>
the length of <code><i>string</i></code>
</ul>
<code>rc = valnum(<i>string</i>)</code>
<ul>
  <code><i>string</i>    </code> any string variable<br>
  <code>rc         0 - <i>string</i></code> 
  is not a number<br>
  <code>           1 - 
  <i>string</i></code> is an integer<br>
  <code>           2 - 
  <i>string</i></code> is not an integer
</ul>

<code>rc = wrdpos(<i>string,int</i>)</code>
 <ul>
<code><i>string</i>    </code>
any string, usually contains more than one word<br>
<code><i>int</i>       </code>
an integer<br>
<code>rc        </code>
word #<code><i>int</i></code of ><code><i>string</i></code> starts at this character #<br>
</ul>


<p>
<h3>Usage Notes</h3>

<p>
These math functions will only work with GrADS version 1.8 (or higher). 

<p>
<h3>Examples </h3>

<p> These script records were taken from a sample script called "<a href="ftp://grads.iges.org/grads/scripts/script_math_demo.gs">script_math_demo.gs</a>". 
<p>
<code>
v = 3.1456<br>
fmt = '%-6.1f'<br>
rc = math_format(fmt,v)<br>
say fmt' of 'v' = 'rc<br>
<br>
pi = 3.1415926<br>
d2r = pi/180<br>
angd = 45<br>
ang = angd * d2r<br>
cos = math_cos(ang)<br>
say 'cos of 'angd' = 'cos<br>
<br>
num = '3.1455'<br>
rc = valnum(num)<br>
if (rc = 0) ; say num' is not a number' ; endif<br>
if (rc = 1) ; say num' is an integer' ; endif<br>
if (rc = 2) ; say num' is not an integer' ; endif<br>
<br>
v = 3.0<br>
while(v < 4.0) <br>
  rc1 = math_nint(v)<br>
  rc2 = math_int(v)<br>
  print 'nint of 'v' = 'rc1'  int of 'v' = 'rc2<br>
  v = v + 0.1<br>
endwhile<br>
<br>
pow = math_pow(2,0.5);<br>
print '2 raised to the power 0.5 = 'pow<br>
<br>
num = math_exp(1)<br>
print 'exp(1) = 'num<br>
<br>
fmod = math_fmod(5,2)<br>
print '5 modulo 2 (the remainder when 5 is divided by 2) = 'fmod<br>
<br>
s = 'this is a test'<br>
rc = math_strlen(s)<br>
print 'length of the string "'s'" = 'rc
p = 2<br>
rc = wrdpos(s,p)<br>
print 'word 'p' of the string "'s'" starts at character 'rc<br>
<br>
</code>
</body>
</html>

\ No newline at end of file
diff --git a/doc/pagecontrol.html b/doc/pagecontrol.html
index 9feb989..3695aa9 100644
--- a/doc/pagecontrol.html
+++ b/doc/pagecontrol.html
@@ -135,11 +135,11 @@ href="gradcomdsetvpage.html"><code>set vpage</code></a> to define
 several virtual pages that fit within the limits of the real page. 
 Virtual pages may overlap.
 The sample script called 
-<a href="ftp://cola.gmu.edu/grads/scripts/panels_demo.gs">
+<a href="ftp://grads.iges.org/grads/scripts/panels_demo.gs">
 <code>panels_demo.gs</code></a> demonstrates how to set up virtual
 page coordinates for a multi-panel plot with a specified number of
 rows and columns. It uses a <a href="gsf.html">GrADS script function</a>
-called <a href="ftp://cola.gmu.edu/grads/scripts/panels.gsf">
+called <a href="ftp://grads.iges.org/grads/scripts/panels.gsf">
 <code>panels.gsf</code></a>. 
 
 <p>
diff --git a/doc/script.html b/doc/script.html
index 5b608c3..a0f83ff 100644
--- a/doc/script.html
+++ b/doc/script.html
@@ -1 +1,1282 @@
-<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->

<html>
<title>GrADS Scripting Language</title>
<body bgcolor="e0f0ff" text="#000000">
<h1>GrADS Scripting Language</h1>
<p>
<a href="#intro">Introduction to GrADS scripts</a><br>
<a href="#elements">Elements of the Language:</a><br>
      <a href="#comment">comment</a><br>
      <a href="#statement">statement</a><br>
      <a href="#assignment">assignment</a><br>
      <a href="#standardio">say / prompt / pull</a><br>
      <a href="#ifendif">if / else / endif</a><br>
      <a href="#while">while / endwhile</a><br>
      <a href="#variables">variables</a><br>
      <a href="#operators">operators</a><br>
      <a href="#expressions">expressions</a><br>
      <a href="#functions">Functions</a><br>
      <a href="#intrinsic">Intrinsic Functions</a><br>
<a href="#commands">Commands that complement the scripting language</a><br>
<a href="#widgets">Widgets</a><br>
<a href="library.html">Script Library</a><br>
<a href="reference_card_scl.pdf">Scripting Language Reference Card</a>
<font size=-1>
(Requires <a href="http://www.adobe.com/products/acrobat/readstep.html">
Adobe Acrobat Reader</a>)</font>

<p>
<hr>
<p>

<h2><a name="intro"><u>Introduction to GrADS Scripts</u></a></h2>

<p>
Scripts offer users the facility to program GrADS operations.
Although it is relatively easy for users to produce sophisticated
GrADS graphics without ever writing a script, there are occasions
where the programming capability makes things even easier. This
section explains the general capabilities of scripts, how to run them,
and suggests a strategy for users who may wish to write their own.

<p>
<i><b>What scripts can do</b></i>

<p>
The GrADS scripting language, used via the GrADS <code><a
href="gradcomdrun.html">run</a></code> command, provides a similar
capability to the <code><a href="gradcomdexec.html">exec</a></code>
command, except that scripts also have flow control, defined
variables, and access to GrADS command output. Scripts may be written
to perform a variety of functions, such as allowing a user to interact
with Grads via point and click interface, animating any desired
quantities, and annotating plots with information obtained from GrADS
query commands.

<p>
The scripting language is similar to REXX in implementation. All
variables are of type STRING. Mathematical operations are supported on
script variables. Flow control is achieved via
<code>if/else/endif</code> and <code>while/endwhile</code>
constructs. Loop flow may be modified by the <code>continue</code> or
<code>break</code> commands. Strings contained in variables or
generated via an expression may be issued to GrADS as commands. The
output from those commands (i.e., the text that GrADS would have
output to the terminal) is put into a variable and made available to
the script. The language includes support for functions.

<p>
Before writing your own scripts, it is recommended that you read the
rest of this section and then try to run some of the scripts in the <a
href="library.html">library</a>. Study these example
scripts, referring to this page for information on syntax etc., and
you will soon be equipped to write scripts of your own.<p>

<p>
<i><b>Running scripts</b></i>

<p>
The command to execute a script is the 
<code><a href="gradcomdrun.html">run</a></code> command:

<p>
<ul><code>
<a href="gradcomdrun.html">run</a> <i>filename &ltarguments&gt</i>
</code></ul>

<p>
This command runs the script contained in the named file, which
generally has a <code>".gs"</code> tag at the end. Optional
<code><i>arguments</i></code> are passed to the script as a string
variable. You may issue any GrADS command from a script, including the
<code>run</code> command. When calling scripts recursively, be sure
that you can back out of the recursion and return to your main script.


<p>
<i><b>Automatic script execution</b></i>

<p>
You may have a simple script automatically executed before every
<code><a href="gradcomddisplay.html">display</a></code> command:

<p>
<ul><code>
<a href="gradcomdsetimprun.html">set imprun</a> <i>script-name</i>
</code></ul>

<p>
This script would typically be used to set an option that by
default gets reset after each <code><a href="gradcomddisplay.html">display</a></code> 
command, for example:

<p>
<ul><code><a href="gradcomdsetgrads.html">set grads</a> off</code></ul>

<p>
You can issue any GrADS command from this script, but the interactions
are not always clear.  For example, if you issued a <code><a
href="gradcomddisplay.html">display</a></code> command from this
script, you could easily enter an infinite recursion loop.

<p>
The argument to the script is the expression from the <code><a
href="gradcomddisplay.html">display</a></code>
command.

<p>
<i><b><a name="storing">Storing GrADS scripts</a></b></i>

<p>
It is convenient to put all your GrADS "utility" scripts in one
directory (e.g., <code>/usr/local/grads/lib/scripts</code>).

<p>
To simplify running these scripts, GrADS first looks in the
current directory for the script and then, if it can't find it,
appends the "<code>.gs</code>" extension and tries again.  For example,
suppose you are working on a test script called <code>t.gs</code>.  You would
run it in GrADS by,

<p>
<ul><code>run t</code></ul>

<p>
If after the first two tries, the script still can't be located,
then GrADS looks in the directory defined by the environment
variable <code>GASCRP</code>.  In the <code>t(csh)</code>, for example,

<p>
<ul><code>setenv GASCRP /home1/grads/lib</code></ul>

<p>
or in <code>ksh</code>,

<p>
<ul><code>export GASCRP=/home1/grads/lib</code></ul>

<p>
Note the if the <code>/</code> is not added to the end of the
directory name, it is automatically added by UNIX. However, it'll
still work if you type<p>

<ul><code>setenv GASCRP /home1/grads/lib/</code></ul>

<p>
If the script cannot be found, then <code>.gs</code> is appended and GrADS
tries yet again.  Thus,

<p>
<ul><code>d slp <br> run /home1/grads/lib/cbarn.gs</code></ul>

<p>
simplifies to,

<p>
<ul><code>d slp <br> run cbarn</code></ul>


<hr>

<h2><a name="elements"><u>Elements of the Language</u></a></h2>

<p>
A script file is made up of records. The end of a script record is
determined by either a newline character or a semicolon (where the
semicolon is not contained within a constant string).<p>

Each script record may be one of the following types:<p>
<ul>
<li>comment<br>
<li>statement<br>
<li>assignment<br>
<li>say / prompt / pull<br>
<li>if / else / endif<br>
<li>while / endwhile / break / continue<br>
<li>function header / return<br>
</ul>

<p>
Many of the above record types will contain expressions.  Script
expressions are composed of operands and operators. Operands
are strings constants, variables, or function calls; operators
are mathematical, logical, or concatenation operations. Further
discussion of these record types and the expressions they may
contain is given below.

<p>
<i><b><a name="comment">Comment</a></b></i>

<p>
Comments in GrADS scripts must contain an asterisk (*) in the first column. 

<p>
<i><b><a name="statement">Statement</a></b></i>

<p>
The statement record consists only of an expression:
<p>
<ul><code><i>expression</i></code></ul>

<p>
The expression is evaluated, and the resulting string is then
submitted to GrADS as a command for execution. The script variable
<code>rc</code> will contain the return code from the GrADS command
(this will always be an integer value). In addition, any text output
from GrADS in response to the command is put in the variable
<code>result</code> for examination by the script. A GrADS error
resulting from an invalid command WILL NOT terminate execution of the
script.

<p>
The simplest type of expression is a string constant, which is just a
character string enclosed in single or double quotes. Here's an
example of simple script containing a comment plus statements
comprised of string constants:

<p>
<ul>
<code>
* this is a sample script <br>
'open my_sst_dataset.ctl' <br>
'set lat -30 30' <br>
'set lon 90 300' <br>
'display sst' <br>
</code>
</ul>


<p>
<i><b><a name="assignment">Assignment</a></b></i>

<p>
Assignment records are used to define variables and assign them
values. The format of the assignment record is:
<p>
<ul><code>variable = <i>expression</i></code></ul>

<p>
The expression is evaluated, and the result is assigned to be the
value of the indicated variable. The same example from above can be
rewritten to include assignment statements. Note the use of explicit
and implied concatenation:

<p>
<ul>
<code>
'open my_sst_dataset.ctl' <br>
minlat = -30 <br>
maxlat = minlat + 60 <br>
minlon =  90 <br>
maxlon = 300 <br>
'set lat 'minlat%' '%maxlat <br>
'set lon 'minlon' 'maxlon <br>
'display sst' <br>
</code>
</ul>

<p>
<i><b><a name="standardio">say / prompt</a></b></i>

<p>
To present information or questions to the GrADS user via the terminal
(standard output), use the <code>say</code> or <code>prompt</code>
commands:
<p>
<ul><code>
say <i>expression</i><br>
prompt <i>expression</i><br>
</code></ul>
<p>
The result of the <code><i>expression</i></code> is written to the
terminal. The <code>prompt</code> command works the same way as the
<code>say</code> command but does not append a carriage return. It is
possible to combine variables and string constants when writing to
standard output:
<p>
For example:<p>
<ul><code>
line = "Peter Pan, the flying one" <br>
say line<br>
say `She said it is `line<br>
</code></ul>
<p>
gives:
<p>
<ul><code>
Peter Pan, the flying one<br>
She said it is Peter Pan, the flying one
</code></ul>


<p>
<i><b>pull</b></i>

<p>
To retrieve information provided by the GrADS user via the terminal
(standard input), use the <code>pull</code> command:<p>
<ul><code>pull <i>variable</i></code></ul>
<p>
The script will pause for user input from the keyboard (ending with
the carriage return), and then the string entered by the user is
assigned to the indicated variable name. To elaborate on a
previous example:

<p>
<ul><code>
'open my_sst_dataset.ctl' <br>
prompt 'Enter min and max latitudes: ' <br>
pull minlat maxlat <br>
prompt 'Enter min and max longitudes: ' <br>
pull minlon maxlon <br>
'set lat 'minlat%' '%maxlat <br>
'set lon 'minlon' 'maxlon <br>
'display sst' <br>
</code></ul>


<p>
<i><b><a name="ifendif">if / else / endif</a></b></i>

<p>
One way to control the flow of script execution is via the <code>if/else/endif</code> 
construct. The format is as follows:<p>
<ul>
<code>
if expression<br>
   script record<br>
   script record<br>
   . <br>
   . <br>
else<br>
   script record<br>
   . <br> 
   . <br>
endif<br>
</code>
</ul>

<p>
The <code>else</code> block is optional, but the <code>endif</code>
record must be present. The script records following <code>if
expression</code> are executed if the expression evaluates to a string
containing the character 1. If the expression evaluates to 0, then the
script records in the <code>if</code> block are not executed and the
script continues with the <code>else</code> block (if it is present)
or the record following <code>endif</code>. The <code>if
expression</code> record must be separated from the script records
that follow it. For example, the following script record would be
invalid:
<p>
<ul><code>if (i = 10) j = 20 </code></ul>
<p>
The correct syntax requires three separate script records. This is
achieved by putting each record on one line:
<p> 
<ul><code> if (i = 10)<br> 
   j = 20 <br> endif<br> </code></ul>
<p>
Alternatively, the three records could be on the same line separated 
by a semicolon:
<p>
<ul><code>if (i = 10) ; j = 20 ; endif</code></ul>
<p>
N.B. There is no <code>elseif</code> construct in GrADS.


<p>
<i><b><a name="while">while / endwhile</a></b></i>

<p>
Another method for controlling the flow of script execution is the <code>while/endwhile</code> construct. The format is as follows:
<p>
<ul>
<code>
while expression<br>
   script record<br>
   script record <br>
   . <br>
   . <br>
endwhile<br>
</code>
</ul>

<p>
The script records following <code>while expression</code> are
executed if the expression evaluates to a string containing the
character 1. If the expression evaluates to 0, then the script records
in the <code>while</code> block are not executed and the script continues
with the record following <code>endwhile</code>. The <code>while
expression</code> record must be separated from the script records
that follow it.

<p>
Two additional script commands may be used to modify the
<code>while</code> loop execution: <code><b>break</b></code> and
<code><b>continue</b></code>. Inserting the <code>break</code> statement will
immediately end execution of the loop and the script will move on to
the records following <code>endwhile</code>. The <code>continue</code>
statement will immediately end execution of the loop, but the script
will then branch immediately back to the top of the loop, and the
expression will be re-evaluated.<p>

While loops are often used as counters. For example:<p>
<ul>
  <code> count = 1 <br>
  while (count < 10) <br>
     'set t 'count <br>
     'display z' <br>
     if (rc != 0) ; break ; endif <br>
     count = count + 1 <br>
  endwhile<br>
  </code>
</ul>


<p>
<i><b><a name="variables">Variables</a></b></i>

<p>
The contents of a script variable is always a character string.
However, if the contents of a variable represent a number in the
correct format, certain operators may perform numeric operations on
that variable, giving a string result which will also be a number.
<p>
Variable names can have from 1 to 8 characters, beginning with an
alphabetic character and containing letters or numbers only. The name
is case sensitive. If a variable has not yet been assigned, its value
is its name.
<p>
String variables or string constants are enclosed in either single or
double quotes. An example of an assignment statement that defines a
string variable is as follows:
<p>
<ul><code>name = `Peter Pan' <br> name = "Peter Pan"</code></ul>
<p>
Numeric variables may be entered without quotes, but are still
considered strings.
<p>
<ul><code>number = -99.99</code></ul>


<p>
<i><b>Predefined script variables</b></i>
<p>
Some variable names are predefined; it is a good idea to avoid
assigning values to these variables. The following are predefined
script variables -- their values will change with every execution of a
GrADS command from the script:
<p>
<ul><code>rc <br> result </code></ul>

<p>
<code>lat, lon, lev,</code> and <code>time </code>are also used
as predefined variables in GrADS. Although using them within a script
is okay, in order to avoid confusion it is not recommended.

<p>
<i><b>Global string variables</b></i>
<p>
String variables are usually local to the functions they are contained
in. Global string variables are also available.  They are specified
via the variable name. Any variable name starting with an
underscore (_) will be assumed to be a global variable, and will keep
its value throughout an entire script file. An example of an
assignment statement that defines a global string variable is as
follows:
<p>
<ul><code>_var1 = "global variable 1"</code></ul>
<p>
<i>N.B.</i> Global variables cannot be used in function headers. For example:
<p>
<ul><code>function dostuff(_var)</code></ul>
<p>
wouldn't make sense, since <code>_var</code> is a global variable, and would
be invalid if it were the only argument.

<p>
<i><b>Compound string variables</b></i>
<p>
Compound variables are used to construct arrays in scripts. A compound
variable has a variable name with segments separated by periods. For
example:
<p>
<ul><code>varname.i.j</code></ul>
<p>
In this case, when the variable contents are accessed,
<code>i</code> and <code>j</code> will be looked up to see if they are
also variables (non-compound). If they are, the <code>i</code> and
<code>j</code> will be replaced by the string values of <code>i</code>
and <code>j</code>. For example:
<p>
<ul><code>i = 10 <br> j = 3 <br> varname.i.j = 343</code></ul>
<p>
In the above example, the assignment is equivalent to:
<p>
<ul><code>varname.10.3 = 343</code></ul>
<p>
Note that the string values of <code>i</code> and <code>j</code> may
be anything, but the variable name specification in the script must
follow the rules for variable names: letters or numbers, with a
leading letter. The variable name after substitution may be any
string:
<p>
<ul><code>i = 'a#$xx' <br> varname.i = 343</code></ul>
<p>
The above is valid.  However, we cannot refer to this variable
name directly:
<p>
<ul><code>varname.a#$xx = 343</code></ul>
<p>
would be invalid.
<p>
Variable names may <i>not</i> be longer than 16 characters, either
before or after substitution.
<p>
Note that the GrADS scripting language is not particularly
efficient in handling large numbers of variables.  Thus compound
variables should not be used to create large arrays:
<p>
<ul><code>
i = 1 <br> 
while (i < 10000) <br> 
&nbsp&nbsp var.i = i <br>
&nbsp&nbsp i = i + 1 <br>
endwhile
</code></ul>
<p>
The above loop will create 10000 distinct variable names. Such
a large number of variables in the variable chain will slow the
script down a lot. 
</ul>


<p>
<i><b><a name="operators">Operators</a></b></i>

<p>
The following operators are implemented in the scripting language:<p>
<ul>
<code>|          </code> logical OR <br>
<code>&      </code> logical AND <br>
<code>!          </code> unary NOT <br>
<code>-          </code> unary minus <br>
<code>=          </code> equal <br>
<code>!=        </code> not equal <br>
<code>>       </code> greater than <br>
<code>>=     </code> greater than or equal <br>
<code><       </code> less than <br>
<code><=     </code> less than or equal <br> 
<code>%          </code> concatenation <br>
<code>+          </code> addition <br>
<code>-          </code> subtraction <br>
<code>*          </code> multiplication <br>
<code>/          </code> division<br>
</ul>

<p>
The following operators will perform a numeric operation if the
operands are numeric:<p>

<ul><code>=, !=, >, >=, <, <=, +, -, *, /</code></ul>

<p>
If any of the following operations are attempted with non-numeric
operands, an error will result:<p>

<ul><code>+, -, *, /</code></ul>

<p>
Arithmetical operations are done in floating point. If the result is
integral, the result string will be an integer. Logical operations
will give a character <code>0</code> (zero) if the result is FALSE,
and a character <code>1</code> (one) if the result is TRUE.


<p>
<i><b><a name="expressions">Expressions</a></b></i>

<p>
Script expressions consist of any combination of operands, operators,
and parentheses. Operands may be string constants, variables, 
or function calls. The precedence of the operators is:
<p>
<ul><code>
-, !  (Unary) <br>
/, * <br>
+, - <br>
% <br>
=, !=, >, >=, <, <= <br>
& <br>
| <br>
</code></ul>

<p>
Within the same precedence level, operations are performed left
to right. Parentheses modify the order of operation according to
standard convention.

<p>
All script expressions, including all function calls, etc. are
evaluated and the resulting string is what gets executed as a
command. For example:
<p>
<ul><code>
var1 = -1 ; var2 = 10 <br>
if (var1*var2 < 10 & var1 > 0) <br>
   say 'both statements are true' <br>
else <br>
   say 'it is not the case that both statements are true' <br>
endif <br>
</code></ul>
<p>
For the expression following <code>if</code>, both sides of the
logical operation must be evaluated before the entire expression can
be simplified into a true or false result. In this case, the
subexpression on the left is true, but the subexpression on the left
is not, so the whole expressions resolves to 0 (zero) and the script
will print:
<p>
<ul><code>it is not the case that both statements are true</code></ul>

<p>
<b><i>Concatenation</i></b>
<p>
In some espressions, the concatenation operator may be implied. The <code>%</code>
operator may be omitted whenever the two operands are a string
constant and a variable name. With implied concatentation, intervening
blanks will be ignored.
<p>
For example, the following expressions have the same effect:
<p>
<ul>
<code>'set lat 'minlat%' '%maxlat      </code>
uses the concatenation operator % <br>
<code>'set lat 'minlat' 'maxlat       </code>
concatenation is implied <br>
</ul>

<p>
Assuming two previous statements, <code>minlat = -30 </code> and
<code> maxlat = 30</code>, the resulting expression would be:
<p>
<ul><code>'set lat -30 30'</code></ul>
<p>
Keep in mind the order of precedence when using the concatenation operator.

<p>
<i><b><a name="functions">Functions</a></b></i>
<p>
Function calls take the form of:
<p>
<ul><code>name(arg,arg,arg,...)</code></ul>

<p>
where the function name follows the same rules as for variable names, and
the arguments may be any expression.

Functions may either be contained within the script file itself,
or the may be intrinsic functions. Functions contained within
other script files are not supported as yet (other script files
may be executed via the GrADS run command).<p>

In either case, functions are invoked as a script expression is
being evaluated.  Script functions always have a single string
result, but may have one or more string arguments.  Functions are
invoked by:<p>

<dd><code>name(arg,arg,arg...)</code><p>

If the function has no arguments, you must still provide the
parentheses:<p>

<dd><code>name()</code><p>

You may provide your own functions from within your script file
by using the <code>function</code> definition record:<p>

<dd><code>function name(variable, variable, ...)</code><p>

To return from a function, use the <code>return</code> command:<p>

<dd><code>return <i>expression</i></code><p>

The <code><i>expression</i></code> is optional; if not provided, a NULL string will
be returned.  (A null string is: '')  The result of the function
is the result of the expression specified on the return command.<p>

When a function is invoked, the arguments are evaluated, then
flow of control is transferred to the function.  The variables
contained in the list within the function definition record are
initialized   to the values of the passed arguments.  If too few
arguments where passed for the variables specified, the trailing
variables are uninitialized.  If too many arguments are passed,
the extra arguments are discarded.<p>

You may modify the variables from the function definition record
without modifying the variables from the calling routine.<p>

Scope of variables is normally local to the function, but can be
global.<p>

When a script file is first invoked (via the <code>run</code> command), 
execution starts at the beginning of the file.  A function
definition record may optionally be provided at the beginning. 
If it is, it should specify one variable name.  This variable
will be initialized to any <code>run</code> command options.  If no options
were given, the variable will be initialized to NULL.<p>

<p>
<i><b><a name="intrinsic">Intrinsic Functions</a></b></i>
<p>
<ul>
<b><code>strlen (<i>string</i>)</code></b>
<br>
This function returns the length (number of characters) of  
<code><i>string</i></code>.

<p><b><code>sublin (<i>string, n</i>)</code></b>
<br>
This function gets a single line from a string containing several
lines. The result is the <code><i>nth</i></code> line of
<code><i>string</i></code>.  If the string has too few lines, the
result is NULL.  <code><i>n</i></code> must be an integer.

<p>
<b><code>subwrd (<i>string, n</i>)</code></b>
<br>
This functions gets a single word from a string. 
The result is the <code><i>nth</i></code> word of <code><i>string</i></code>.  
If the string is too short, the result is NULL. 
<code><i>n</i></code> must be an integer.

<p>
<b><code>substr (<i>string, start, length</i>)</code></b>
<br>
This function gets part of a string. 
The sub-string of <code><i>string</i></code> starting at location
<code><i>start</i></code> for length <code><i>length</i></code> will be returned.  
If the string is too short, the result will be short or NULL. 
<code><i>start</i></code> and <code><i>length</i></code> must be integers.

<p>
<b><code>read (<i>filename</i>)</code></b>
<br>
This functions reads individual records from file <code><i>filename</i></code>.
Repeated calls must be made to read consecutive records. The result is
a string containing two lines: the first line is the return code, the 
2nd line is the record read from the file. The record may be a maximum 
of 80 characters. Use the <code>sublin</code> function to separate the
result. Return codes are:<br>

<ul>
<code>0 - </code>ok <br>
<code>1 - </code>open error <br>
<code>2 - </code>end of file <br>
<code>8 - </code>file open for write <br>
<code>9 - </code>I/O error<br>
</ul>

Files are opened when the first call to read is made for a 
particular file name. Files are closed when the execution of the
script file terminates (note that files remain open between
function calls, etc).

<p>
<b><code>write (<i>filename, record</i> <, append>)</code></b>
<br>
This functions writes records to output file <code>filename</code>.  

On the first call to write for a particular file, the file is opened
in write mode.  This will destroy an existing file!  If you use the
optional append flag, the file will be opened in append mode, and all
writes will be appended to the end of the file.  Return codes are:<br>
<ul>
<code>0</code> - ok <br>
<code>1</code> - open error <br>
<code>8</code> - file open for read</ul>

<p>
<b><code>close (<i>name</i>)</code></b>
<br>

This function closes the named file.  This must be done if you wish to
read from a file you have been writing to.  This can also be used to
rewind a file.  Return codes are:<br>
<ul>
<code>0</code> - ok <br>
<code>1</code> - file not open</ul><p>
</ul>

<h2><a name="commands"><u>Commands that complement the scripting language</u></a></h2>
<p>
There are some GrADS commands that, although not designed
exclusively for scripts, are most useful in script applications. 
These include:

<p>
<b><code><a href="gradcomdquery.html">query</a> <<i>option</i>></code></b> or 
<b><code><a href="gradcomdquery.html">q</a> <<i>option</i>></code></b>
<ul>
<p>
To see the list of available options, issue the <code><a
href="gradcomdquery.html">query</a></code> command by itself. A
description of the <code><a href="gradcomdquery.html">query</a></code>
options that are most useful for script applications follows.

<p>
<b><code><a href="gradcomdquery.html">q</a> define</code></b> --
Lists all defined variables

<p>
<b><code><a href="gradcomdquery.html">q</a> defval <i>ival
jval</i></code></b> -- Gives defined grid value at <i>ival, jval</i>
<p>
To interactively modify grid point values for a <code>defined</code>
variable, <code><a href="gradcomdquery.html">q</a> defval</code>
can be used in conjunction with <code><a
href="gradcomdsetdefval.html">set defval</a></code>. For example, the
code shown below queries the value of sst at gridpoint(i,j), then
tests to see if the value is less than -1.6, and if it is, sets the
sst to a bad value.<p>
<ul>
<code>
'q defval sst 'i' 'j <br>
val = subwrd(result,3) <br>
if (val < -1.6)  <br>
&nbsp&nbsp'set defval sst 'i' 'j' 'bad_value <br>
endif <br>
</code>
</ul>

<p>
<b><code><a href="gradcomdquery.html">q</a> dims</code></b> --
Gives the current dimension environment

<p>
<b><code><a href="gradcomdquery.html">q</a> file
<i>n</i></code></b> -- Gives info on file number <i>n</i>

<p>
<b><code><a href="gradcomdquery.html">q</a> files</code></b> --
Lists open files

<p>
<b><code><a href="gradcomdquery.html">q</a> fwrite</code></b> --
Gives the name of the file used for fwrite operations

<p>
<b><code><a href="gradcomdquery.html">q</a> gxinfo</code></b> --
Lists graphics settings

<p>
This option is handy when trying to find the plot area. The output
from <code><a href="gradcomdquery.html">q</a> gxinfo</code> might
look like this:

<p>
<code>
<ul>
Last Graphic = Line <br>
Page Size = 11 by 8.5 <br>
X Limits = 2 to 10.5 <br>
Y Limits = 0.75 to 7.75 <br>
Xaxis = Lon  Yaxis = Val <br>
Mproj = 2<br>
</ul>
</code>

<p>
The first line indicates that the output is a line plot. The second line
gives the page dimensions -- in this case GrADS is in landscape
mode. The third and fourth lines give the x and y boundaries of the
plot. In this case the plot has 1-inch margins in the x direction and
0.75-inch margins in the y direction.  The fifth line tells what kind
of axes you have, and the sixth line identifies the map projection:
<br>
<ul>
<code>1    </code>Scaled (no preservation of aspect ratio)<br>
<code>2    </code>Latlon (2-D horizontal fields) <br>
<code>3    </code>Northern polar stereographic <br>
<code>4    </code>Southern polar stereographic <br>
<code>5    </code>Robinson (lon range must be -180 to
180 and lat range must be -90 to 90)<br>
</ul>

<p>
<b><code><a href="gradcomdqpos.html">q pos</a></code></b> -- Waits for mouse click, returns position<br>

<p>
<b><code><a href="gradcomdquery.html">q</a> shades</code></b> -- Gives colors and levels of shaded contours<br>

<p>
<b><code><a href="gradcomdquery.html">q</a> time</code></b> - gives time range of current open file<br>

<p>
<b><code><a href="gradcomdquery.html">q</a> <i>transform coord1 coord2</i></code></b> -- Coordinate transformations 

<ul>
<p>
where <code><i>transform</i></code> is one of: <br>
<code>xy2w       </code>XY coords to world coords <br>
<code>xy2gr      </code>XY coords to grid coords <br>
<code>w2xy       </code>world coords to XY coords <br>
<code>w2gr       </code>world coords to grid coords <br>
<code>gr2w       </code>grid coords to world coords <br>
<code>gr2xy      </code>grid coords to XY coords <br>
</ul>

<p>
<i>XY coords</i> are inches on the page (screen) where the page is
11x8.5 inches or 8.5x11 inches, depending on how GrADS was started.

<p>
<i>World coords</i> are lat, lon, lev, time or val, depending on what
the dimension environment is when the grid was displayed. Note that
time is displayed (and must be specified) in GrADS absolute date/time
format. val is the value coordinate for a 1-D plot (linegraph).

<p>
<i>Grid coordinates</i> are the i,j indices the grid being
displayed. For station data sets, grid and world coordinates are
equivalent except for the time dimension. Note that if you display a
grid from a 'wrapped' data set, the grid numbers may be out of range
of the actual file grid numbers. (A 'wrapped' data set is a data set
that covers the earth in the longitude direction. Wrapping takes place
automatically). The conversions are done consistently, but you may
want to be sure you can handle the wrapping case if your data set is
global.

<p>
N.B. Coordinate transform queries are only valid after something has
been displayed, and the transformations apply only to the most recent
item that has been displayed.
</ul>

<p>
<b><code><a name="scriptfindstn">set gxout findstn</a></code></b>
<p>
When using the graphics output type <code><a href="gradcomdsetgxout.html">set gxout findstn</a></code>, three
arguments must be provided with the <a
href="gradcomddisplay.html"><code>display</code></a> command. The
first argument is a station data expression. The 2nd and 3rd arguments
are the X and Y screen coordinates of the of the desired search
location.  GrADS will find the station closest to the specified X and
Y position, and print its stid, lon, and lat.  This graphics output
type should only be used when X and Y are the varying dimensions and
AFTER a regular display command (that results in graphics output) is
entered.
<p>
<b><code>set dbuff on|off</code></b>
<p>
This command sets double buffer mode <code>on</code> or
<code>off</code>. This allows animation to be controlled from a
script. The <a href="gradcomdclear.html"><code>clear</code></a>
command also sets double buffer mode <code>off</code>.

<p>
<b><code>swap</code></b>

<p>
Swaps buffers, when double buffer mode is <code>on</code>. If double
buffer mode is <code>off</code>, this command has no effect.

<p>
The usual usage of these commands would be:<p>

<ul>
<code>
set dbuff on <br>
start looping <br>
&nbsp&nbsp display <i>something</i><br>
&nbsp&nbsp swap <br>
endloop <br>
set dbuff off<br>
</code>
</ul>

<p>
<a name="widgets"><h2><u>Widgets</u></h2></a>
<p>
GrADS has the capability to implement a graphical user interface. This
interface is used to draw widgets (buttons and pull down menus) that
allow a "point and click" interface between the Grads user and the
scripting language.

<p>
<h3>Buttons</h3>
<p>
Here is a sample from a script illustrating how to draw a button:

<p>
<ul>
<pre>
set rgb 90 100 100 100
set rgb 91  50  50  50
set rgb 92 200 200 200
set button 2 90 91 92 3 90 92 91 6
draw button 1 5.5 1 2 0.5 This is a Button
</pre>
</ul>

<p>
The reference pages for <a href="gradcomdsetbutton.html"><code>set
button</code></a> and <a href="gradcomddrawbutton.html"><code>draw
button</code></a> contain information on how to specify the button
characteristics and position.

<p>
A button's initial "state" is <code>ON</code>. If a user clicks on a
button following a <a href="gradcomdqpos.html"><code>q pos</code></a>
command, then the button state will switch from <code>ON (1)</code> to
<code>OFF (0)</code>. A second <a href="gradcomdqpos.html"><code>q
pos</code></a> followed by a mouse click on the button will return it
to the <code>ON</code> state. The button state may also be changed
with the <a href="gradcomdredrawbutton.html"><code>redraw
button</code></a> command.

<p>
The output from the <a href="gradcomdqpos.html"><code>q pos</code></a> command 
is what makes the button widgets so useful. Here is a template of what 
<a href="gradcomdqpos.html"><code>q pos</code></a> returns after a mouse click
on a button:

<p>
<code>
Position = <i>xpos ypos mousebutton widgetclass buttonnumber buttonstate </i></code>

<p>
where:
<ul>
<code><i>xpos, ypos</i>&nbsp&nbsp&nbsp&nbsp</code>
- coordinates of the mouse click in virtual page units <br>
<code><i>mousebutton</i>&nbsp&nbsp&nbsp</code>
- either 1, 2, or 3 for the left, center, or right mouse button <br>
<code><i>widgetclass</i>&nbsp&nbsp&nbsp</code>
- 1 is the widget class number for buttons  <br>
<code><i>buttonnumber</i>&nbsp&nbsp</code>
- the number assigned to the button when it was originally drawn <br>
<code><i>buttonstate</i>&nbsp&nbsp&nbsp</code>
- either 0 (meaning "off") or 1 (meaning "on")
</ul>

<p>
If the user did not click on a button, then <code><i>widgetclass</i></code>
will be 0 and there will be no output for
<code><i>buttonnumber</i></code> or <code><i>buttonstate</i></code>.


<p>
<h3>Drop Menus</h3>
<p>
As with button widgets, dropmenus provide a "point-and-click"
interface between scripts and the GrADS user. The reference pages for
<a href="gradcomdsetdropmenu.html"><code>set dropmenu</code></a> and
<a href="gradcomddrawdropmenu.html"><code>draw dropmenu</code></a>
contain information on how to specify the dropmenu characteristics and
position.
<p>
The output from <a href="gradcomdqpos.html"><code>q pos</code></a>
after a click on a dropmenu is similar to that described above for
buttons.  Here is a template of what is returned by <a
href="gradcomdqpos.html"><code>q pos</code></a> after a mouse click
on a dropmenu:

<p>
<code>Position = <i>xpos ypos mousebutton widgetclass menunumber inum</i></code>

<p>
where:
<ul>
<code><i>xpos, ypos</i>&nbsp&nbsp&nbsp&nbsp</code>
- coordinates of the mouse click in the menu base in virtual page units <br>
<code><i>mousebutton</i>&nbsp&nbsp&nbsp</code>
- either 1, 2, or 3 for the left, center, or right mouse button <br>
<code><i>widgetclass</i>&nbsp&nbsp&nbsp</code>
- 3 is the widget class number for dropmenus  <br>
<code><i>menunumber</i>&nbsp&nbsp&nbsp&nbsp</code>
- the number assigned to the dropmenu when it was originally drawn <br>
<code><i>inum</i>&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp</code>
-  the menu item number selected from the menu list
</ul>

<p>
If no menu item is selected, then <code><i>menunumber</i></code> and <code><i>inum</i></code> will
both be -1.


<p>
Here is a script sample illustrating how to use a dropmenu:

<p>
<pre>
'reset events'
'set rgb 90 100 100 100'
'set rgb 91 150 150 150'
'set rgb 92 200 200 200'
'set dropmenu 1 91 90 92 0 91 90 92 1 91 90 92 90 92 6'
'draw dropmenu 1 1 8 1.5 0.5 Select a Variable | Wind | Temperature | Height | SLP '
noselect = 1
while (noselect)
  'q pos'
  menunum  = subwrd(result,7)
  menuitem = subwrd(result,8)
  if (menunum = 1)
    if menuitem = 1 ; newbase = 'Variable = Wind'   ; endif
    if menuitem = 2 ; newbase = 'Variable = Temp'   ; endif
    if menuitem = 3 ; newbase = 'Variable = Height' ; endif
    if menuitem = 4 ; newbase = 'Variable = SLP'    ; endif
    'draw dropmenu 1 1 8 1.5 0.5 'newbase' | Wind | Temperature | Height | SLP '
    noselect = 0
  endif
endwhile
</pre>
<p>
Here is another script sample illustrating how to use cascading dropmenus:
<p>
<pre>
'clear'
'set rgb 90 100 100 100'
'set rgb 91 150 150 150'
'set rgb 92 200 200 200'
'set button 1 91 -1 -1 1 91 90 92 12'
'draw button 1 1 8 1 0.5 quit'
'set dropmenu 1 91 -1 -1 1 91 90 92 1 91 90 92 90 92 6'
'draw dropmenu 1 1.5 7.5 2 0.5  Menu Base | Space | Earth >05> | Sun | Moon'
'draw dropmenu 5 cascade Ocean | Land | Atmosphere >11> | Biosphere'
'draw dropmenu 11 cascade Snow | Rain | Mist | Tornado '

while (1)
  'q pos'
  say result
  ev = subwrd(result,6)
  if (ev!=3); break; endif;
endwhile
</pre>
<p>
It is left to the GrADS script writer (that means you!) to run the demo and 
interpret the output of <a href="gradcomdqpos.html"><code>q pos</code></a>
when clicking on all the options in the cascade of dropmenus. 

<p>
<h3>Rubber banding</h3>

<p>
GrADS has a widget type called <code>rband</code> for rubber banding.  There
are two <code>rband</code> modes: <code>box</code> and <code>line</code>.
To set up the <code>rband</code> widget, use the following command:
<p>
<ul><code>
<a href="gradcomdsetrband.html">set rband</a> <i>num mode x1 y1 x2 y2</i>
</code></ul>

<p>
where:
<p>
<ul>
<code><i>num</i>   </code>
- widget number<br>
<code><i>mode</i>  </code>
- may be either <code>box</code> or <code>line</code><br>
<code><i>x1</i>    </code>
- lowest X point where the widget will be active (in virtual page units)<br>
<code><i>y1</i>    </code>
- lowest Y point where the widget will be active (in virtual page units)<br>
<code><i>x2</i>    </code>
- highest X point where the widget will be active (in virtual page units)<br> 
<code><i>y2</i>    </code>
- highest Y point where the widget will be active (in virtual page units)<br>
</ul>

<p>
In <code>box</code> mode, as the user clicks and drags the mouse in
the active rband area a box is drawn with one corner located at the
initial click and the opposite corner located at the release point. In
<code>line</code> mode, a line is drawn between these two points.

<p>
For example, suppose you  want to set up a
<code>box</code> rubber band widget in the plot region only.

<p>
First, execute <a href="gradcomdquery.html"><code>q gxinfo</code></a>
to get the X and Y limits of the plot area. The result from <a
href="gradcomdquery.html"><code>q gxinfo</code></a> might look like
this:

<ul>
<pre>
Last Graphic = Line
Page Size = 11 by 8.5
X Limits = 2 to 10.5
Y Limits = 0.75 to 7.75
Xaxis = Lon  Yaxis = Val
Mproj = 2
</pre>
</ul>

<p>
Second, set up the widget with <a
href="gradcomdsetrband.html"><code>set rband</code></a> using the dimensions
grabbed from the result of <a href="gradcomdquery.html"><code>q gxinfo</code></a>:
<p>
<ul>
<pre>
xlims = sublin(result,3)
ylims = sublin(result,4)
x1 = subwrd(xlims,4)
x2 = subwrd(xlims,6)
y1 = subwrd(ylims,4)
y2 = subwrd(ylims,6)
'set rband 21 box 'x1' 'y1' 'x2' 'y2
</pre>
</ul>

<p>
Finally, use <a href="gradcomdqpos.html"><code>q pos</code></a> 
to activate the widget.

<p>
<ul><code>ga-> q pos</code></ul>

<p>
This freezes the system until the user clicks, drags, and 
then releases the mouse somewhere within the active rband area. 
Here is a template for the output you would get from GrADS after
a mouse click and drag in the rband area:<p>

<ul>
<code>Position = <i>xpos1 ypos1 mousebutton widgetclass widgetnumber xpos2 ypos2</i></code>
</ul>

<p>
where:
<ul>
<code><i>xpos1, ypos1</i>&nbsp&nbsp&nbsp</code>
- coordinates of the initial mouse click in virtual page units <br>
<code><i>mousebutton</i>&nbsp&nbsp&nbsp&nbsp</code>
- either 1, 2, or 3 for the left, center, or right mouse button <br>
<code><i>widgetclass</i>&nbsp&nbsp&nbsp&nbsp</code>
- 2 is the widget class number for rbands  <br>
<code><i>widgetnumber</i>&nbsp&nbsp&nbsp</code>
- the number assigned to the
rband widget when it was set up  <br>
<code><i>xpos2, ypos2</i>&nbsp&nbsp&nbsp</code>
- coordinates of the mouse release point in virtual page units <br>
</ul>

<p>
The page coordinates can be then be used to draw a box (or a line)
where the user specified, or parsed and used in the coordinate
transform <a href="gradcomdquery.html"><code>q xy2w</code></a> to
recover the lat/lon region selected by the user.

</body>
</html>
\ No newline at end of file
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
+
+<html>
+<title>GrADS Scripting Language</title>
+<style type="text/css">
+.red {
+	color: #900;
+}
+</style>
+<body bgcolor="e0f0ff" text="#000000">
+<h1>GrADS Scripting Language</h1>
+<p>
+<a href="#intro">Introduction to GrADS scripts</a><br>
+<a href="#elements">Elements of the Language:</a><br>
+      <a href="#comment">comment</a><br>
+      <a href="#statement">statement</a><br>
+      <a href="#assignment">assignment</a><br>
+      <a href="#standardio">say / prompt / pull</a><br>
+      <a href="#ifendif">if / else / endif</a><br>
+      <a href="#while">while / endwhile</a><br>
+      <a href="#variables">variables</a><br>
+      <a href="#operators">operators</a><br>
+      <a href="#expressions">expressions</a><br>
+      <a href="#functions">Functions</a><br>
+      <a href="#intrinsic">Intrinsic Functions</a><br>
+<a href="#commands">Commands that complement the scripting language</a><br>
+<a href="#widgets">Widgets</a> (N.B. The widgets have been temporarily disabled for <span class="red">version 2.1.a1</span>) <br>
+<a href="library.html">Script Library</a><br>
+<a href="reference_card_scl.pdf">Scripting Language Reference Card</a>
+<font size=-1>
+(Requires <a href="http://www.adobe.com/products/acrobat/readstep.html">
+Adobe Acrobat Reader</a>)</font>
+
+<p>
+<hr>
+<p>
+
+<h2><a name="intro"><u>Introduction to GrADS Scripts</u></a></h2>
+
+<p>
+Scripts offer users the facility to program GrADS operations.
+Although it is relatively easy for users to produce sophisticated
+GrADS graphics without ever writing a script, there are occasions
+where the programming capability makes things even easier. This
+section explains the general capabilities of scripts, how to run them,
+and suggests a strategy for users who may wish to write their own.
+
+<p>
+<i><b>What scripts can do</b></i>
+
+<p>
+The GrADS scripting language, used via the GrADS <code><a
+href="gradcomdrun.html">run</a></code> command, provides a similar
+capability to the <code><a href="gradcomdexec.html">exec</a></code>
+command, except that scripts also have flow control, defined
+variables, and access to GrADS command output. Scripts may be written
+to perform a variety of functions, such as allowing a user to interact
+with Grads via point and click interface, animating any desired
+quantities, and annotating plots with information obtained from GrADS
+query commands.
+
+<p>
+The scripting language is similar to REXX in implementation. All
+variables are of type STRING. Mathematical operations are supported on
+script variables. Flow control is achieved via
+<code>if/else/endif</code> and <code>while/endwhile</code>
+constructs. Loop flow may be modified by the <code>continue</code> or
+<code>break</code> commands. Strings contained in variables or
+generated via an expression may be issued to GrADS as commands. The
+output from those commands (i.e., the text that GrADS would have
+output to the terminal) is put into a variable and made available to
+the script. The language includes support for functions.
+
+<p>
+Before writing your own scripts, it is recommended that you read the
+rest of this section and then try to run some of the scripts in the <a
+href="library.html">library</a>. Study these example
+scripts, referring to this page for information on syntax etc., and
+you will soon be equipped to write scripts of your own.<p>
+
+<p>
+<i><b>Running scripts</b></i>
+
+<p>
+The command to execute a script is the 
+<code><a href="gradcomdrun.html">run</a></code> command:
+
+<p>
+<ul><code>
+<a href="gradcomdrun.html">run</a> <i>filename &ltarguments&gt</i>
+</code></ul>
+
+<p>
+This command runs the script contained in the named file, which
+generally has a <code>".gs"</code> tag at the end. Optional
+<code><i>arguments</i></code> are passed to the script as a string
+variable. You may issue any GrADS command from a script, including the
+<code>run</code> command. When calling scripts recursively, be sure
+that you can back out of the recursion and return to your main script.
+
+
+<p>
+<i><b>Automatic script execution</b></i>
+
+<p>
+You may have a simple script automatically executed before every
+<code><a href="gradcomddisplay.html">display</a></code> command:
+
+<p>
+<ul><code>
+<a href="gradcomdsetimprun.html">set imprun</a> <i>script-name</i>
+</code></ul>
+
+<p>
+This script would typically be used to set an option that by
+default gets reset after each <code><a href="gradcomddisplay.html">display</a></code> 
+command, for example:
+
+<p>
+<ul><code><a href="gradcomdsetgrads.html">set grads</a> off</code></ul>
+
+<p>
+You can issue any GrADS command from this script, but the interactions
+are not always clear.  For example, if you issued a <code><a
+href="gradcomddisplay.html">display</a></code> command from this
+script, you could easily enter an infinite recursion loop.
+
+<p>
+The argument to the script is the expression from the <code><a
+href="gradcomddisplay.html">display</a></code>
+command.
+
+<p>
+<i><b><a name="storing">Storing GrADS scripts</a></b></i>
+
+<p>
+It is convenient to put all your GrADS "utility" scripts in one
+directory (e.g., <code>/usr/local/grads/lib/scripts</code>).
+
+<p>
+To simplify running these scripts, GrADS first looks in the
+current directory for the script and then, if it can't find it,
+appends the "<code>.gs</code>" extension and tries again.  For example,
+suppose you are working on a test script called <code>t.gs</code>.  You would
+run it in GrADS by,
+
+<p>
+<ul><code>run t</code></ul>
+
+<p>
+If after the first two tries, the script still can't be located,
+then GrADS looks in the directory defined by the environment
+variable <code>GASCRP</code>.  In the <code>t(csh)</code>, for example,
+
+<p>
+<ul><code>setenv GASCRP /home1/grads/lib</code></ul>
+
+<p>
+or in <code>ksh</code>,
+
+<p>
+<ul><code>export GASCRP=/home1/grads/lib</code></ul>
+
+<p>
+Note the if the <code>/</code> is not added to the end of the
+directory name, it is automatically added by UNIX. However, it'll
+still work if you type<p>
+
+<ul><code>setenv GASCRP /home1/grads/lib/</code></ul>
+
+<p>
+If the script cannot be found, then <code>.gs</code> is appended and GrADS
+tries yet again.  Thus,
+
+<p>
+<ul><code>d slp <br> run /home1/grads/lib/cbarn.gs</code></ul>
+
+<p>
+simplifies to,
+
+<p>
+<ul><code>d slp <br> run cbarn</code></ul>
+
+
+<hr>
+
+<h2><a name="elements"><u>Elements of the Language</u></a></h2>
+
+<p>
+A script file is made up of records. The end of a script record is
+determined by either a newline character or a semicolon (where the
+semicolon is not contained within a constant string).<p>
+
+Each script record may be one of the following types:<p>
+<ul>
+<li>comment<br>
+<li>statement<br>
+<li>assignment<br>
+<li>say / prompt / pull<br>
+<li>if / else / endif<br>
+<li>while / endwhile / break / continue<br>
+<li>function header / return<br>
+</ul>
+
+<p>
+Many of the above record types will contain expressions.  Script
+expressions are composed of operands and operators. Operands
+are strings constants, variables, or function calls; operators
+are mathematical, logical, or concatenation operations. Further
+discussion of these record types and the expressions they may
+contain is given below.
+
+<p>
+<i><b><a name="comment">Comment</a></b></i>
+
+<p>
+Comments in GrADS scripts must contain an asterisk (*) in the first column. 
+
+<p>
+<i><b><a name="statement">Statement</a></b></i>
+
+<p>
+The statement record consists only of an expression:
+<p>
+<ul><code><i>expression</i></code></ul>
+
+<p>
+The expression is evaluated, and the resulting string is then
+submitted to GrADS as a command for execution. The script variable
+<code>rc</code> will contain the return code from the GrADS command
+(this will always be an integer value). In addition, any text output
+from GrADS in response to the command is put in the variable
+<code>result</code> for examination by the script. A GrADS error
+resulting from an invalid command WILL NOT terminate execution of the
+script.
+
+<p>
+The simplest type of expression is a string constant, which is just a
+character string enclosed in single or double quotes. Here's an
+example of simple script containing a comment plus statements
+comprised of string constants:
+
+<p>
+<ul>
+<code>
+* this is a sample script <br>
+'open my_sst_dataset.ctl' <br>
+'set lat -30 30' <br>
+'set lon 90 300' <br>
+'display sst' <br>
+</code>
+</ul>
+
+
+<p>
+<i><b><a name="assignment">Assignment</a></b></i>
+
+<p>
+Assignment records are used to define variables and assign them
+values. The format of the assignment record is:
+<p>
+<ul><code>variable = <i>expression</i></code></ul>
+
+<p>
+The expression is evaluated, and the result is assigned to be the
+value of the indicated variable. The same example from above can be
+rewritten to include assignment statements. Note the use of explicit
+and implied concatenation:
+
+<p>
+<ul>
+<code>
+'open my_sst_dataset.ctl' <br>
+minlat = -30 <br>
+maxlat = minlat + 60 <br>
+minlon =  90 <br>
+maxlon = 300 <br>
+'set lat 'minlat%' '%maxlat <br>
+'set lon 'minlon' 'maxlon <br>
+'display sst' <br>
+</code>
+</ul>
+
+<p>
+<i><b><a name="standardio">say / prompt</a></b></i>
+
+<p>
+To present information or questions to the GrADS user via the terminal
+(standard output), use the <code>say</code> or <code>prompt</code>
+commands:
+<p>
+<ul><code>
+say <i>expression</i><br>
+prompt <i>expression</i><br>
+</code></ul>
+<p>
+The result of the <code><i>expression</i></code> is written to the
+terminal. The <code>prompt</code> command works the same way as the
+<code>say</code> command but does not append a carriage return. It is
+possible to combine variables and string constants when writing to
+standard output:
+<p>
+For example:<p>
+<ul><code>
+line = "Peter Pan, the flying one" <br>
+say line<br>
+say `She said it is `line<br>
+</code></ul>
+<p>
+gives:
+<p>
+<ul><code>
+Peter Pan, the flying one<br>
+She said it is Peter Pan, the flying one
+</code></ul>
+
+
+<p>
+<i><b>pull</b></i>
+
+<p>
+To retrieve information provided by the GrADS user via the terminal
+(standard input), use the <code>pull</code> command:<p>
+<ul><code>pull <i>variable</i></code></ul>
+<p>
+The script will pause for user input from the keyboard (ending with
+the carriage return), and then the string entered by the user is
+assigned to the indicated variable name. To elaborate on a
+previous example:
+
+<p>
+<ul><code>
+'open my_sst_dataset.ctl' <br>
+prompt 'Enter min and max latitudes: ' <br>
+pull minlat maxlat <br>
+prompt 'Enter min and max longitudes: ' <br>
+pull minlon maxlon <br>
+'set lat 'minlat%' '%maxlat <br>
+'set lon 'minlon' 'maxlon <br>
+'display sst' <br>
+</code></ul>
+
+
+<p>
+<i><b><a name="ifendif">if / else / endif</a></b></i>
+
+<p>
+One way to control the flow of script execution is via the <code>if/else/endif</code> 
+construct. The format is as follows:<p>
+<ul>
+<code>
+if expression<br>
+   script record<br>
+   script record<br>
+   . <br>
+   . <br>
+else<br>
+   script record<br>
+   . <br> 
+   . <br>
+endif<br>
+</code>
+</ul>
+
+<p>
+The <code>else</code> block is optional, but the <code>endif</code>
+record must be present. The script records following <code>if
+expression</code> are executed if the expression evaluates to a string
+containing the character 1. If the expression evaluates to 0, then the
+script records in the <code>if</code> block are not executed and the
+script continues with the <code>else</code> block (if it is present)
+or the record following <code>endif</code>. The <code>if
+expression</code> record must be separated from the script records
+that follow it. For example, the following script record would be
+invalid:
+<p>
+<ul><code>if (i = 10) j = 20 </code></ul>
+<p>
+The correct syntax requires three separate script records. This is
+achieved by putting each record on one line:
+<p> 
+<ul><code> if (i = 10)<br> 
+   j = 20 <br> endif<br> </code></ul>
+<p>
+Alternatively, the three records could be on the same line separated 
+by a semicolon:
+<p>
+<ul><code>if (i = 10) ; j = 20 ; endif</code></ul>
+<p>
+N.B. There is no <code>elseif</code> construct in GrADS.
+
+
+<p>
+<i><b><a name="while">while / endwhile</a></b></i>
+
+<p>
+Another method for controlling the flow of script execution is the <code>while/endwhile</code> construct. The format is as follows:
+<p>
+<ul>
+<code>
+while expression<br>
+   script record<br>
+   script record <br>
+   . <br>
+   . <br>
+endwhile<br>
+</code>
+</ul>
+
+<p>
+The script records following <code>while expression</code> are
+executed if the expression evaluates to a string containing the
+character 1. If the expression evaluates to 0, then the script records
+in the <code>while</code> block are not executed and the script continues
+with the record following <code>endwhile</code>. The <code>while
+expression</code> record must be separated from the script records
+that follow it.
+
+<p>
+Two additional script commands may be used to modify the
+<code>while</code> loop execution: <code><b>break</b></code> and
+<code><b>continue</b></code>. Inserting the <code>break</code> statement will
+immediately end execution of the loop and the script will move on to
+the records following <code>endwhile</code>. The <code>continue</code>
+statement will immediately end execution of the loop, but the script
+will then branch immediately back to the top of the loop, and the
+expression will be re-evaluated.<p>
+
+While loops are often used as counters. For example:<p>
+<ul>
+  <code> count = 1 <br>
+  while (count < 10) <br>
+     'set t 'count <br>
+     'display z' <br>
+     if (rc != 0) ; break ; endif <br>
+     count = count + 1 <br>
+  endwhile<br>
+  </code>
+</ul>
+
+
+<p>
+<i><b><a name="variables">Variables</a></b></i>
+
+<p>
+The contents of a script variable is always a character string.
+However, if the contents of a variable represent a number in the
+correct format, certain operators may perform numeric operations on
+that variable, giving a string result which will also be a number.
+<p>
+Variable names can have from 1 to 8 characters, beginning with an
+alphabetic character and containing letters or numbers only. The name
+is case sensitive. If a variable has not yet been assigned, its value
+is its name.
+<p>
+String variables or string constants are enclosed in either single or
+double quotes. An example of an assignment statement that defines a
+string variable is as follows:
+<p>
+<ul><code>name = `Peter Pan' <br> name = "Peter Pan"</code></ul>
+<p>
+Numeric variables may be entered without quotes, but are still
+considered strings.
+<p>
+<ul><code>number = -99.99</code></ul>
+
+
+<p>
+<i><b>Predefined script variables</b></i>
+<p>
+Some variable names are predefined; it is a good idea to avoid
+assigning values to these variables. The following are predefined
+script variables -- their values will change with every execution of a
+GrADS command from the script:
+<p>
+<ul><code>rc <br> result </code></ul>
+
+<p>
+<code>lat, lon, lev,</code> and <code>time </code>are also used
+as predefined variables in GrADS. Although using them within a script
+is okay, in order to avoid confusion it is not recommended.
+
+<p>
+<i><b>Global string variables</b></i>
+<p>
+String variables are usually local to the functions they are contained
+in. Global string variables are also available.  They are specified
+via the variable name. Any variable name starting with an
+underscore (_) will be assumed to be a global variable, and will keep
+its value throughout an entire script file. An example of an
+assignment statement that defines a global string variable is as
+follows:
+<p>
+<ul><code>_var1 = "global variable 1"</code></ul>
+<p>
+<i>N.B.</i> Global variables cannot be used in function headers. For example:
+<p>
+<ul><code>function dostuff(_var)</code></ul>
+<p>
+wouldn't make sense, since <code>_var</code> is a global variable, and would
+be invalid if it were the only argument.
+
+<p>
+<i><b>Compound string variables</b></i>
+<p>
+Compound variables are used to construct arrays in scripts. A compound
+variable has a variable name with segments separated by periods. For
+example:
+<p>
+<ul><code>varname.i.j</code></ul>
+<p>
+In this case, when the variable contents are accessed,
+<code>i</code> and <code>j</code> will be looked up to see if they are
+also variables (non-compound). If they are, the <code>i</code> and
+<code>j</code> will be replaced by the string values of <code>i</code>
+and <code>j</code>. For example:
+<p>
+<ul><code>i = 10 <br> j = 3 <br> varname.i.j = 343</code></ul>
+<p>
+In the above example, the assignment is equivalent to:
+<p>
+<ul><code>varname.10.3 = 343</code></ul>
+<p>
+Note that the string values of <code>i</code> and <code>j</code> may
+be anything, but the variable name specification in the script must
+follow the rules for variable names: letters or numbers, with a
+leading letter. The variable name after substitution may be any
+string:
+<p>
+<ul><code>i = 'a#$xx' <br> varname.i = 343</code></ul>
+<p>
+The above is valid.  However, we cannot refer to this variable
+name directly:
+<p>
+<ul><code>varname.a#$xx = 343</code></ul>
+<p>
+would be invalid.
+<p>
+Variable names may <i>not</i> be longer than 16 characters, either
+before or after substitution.
+<p>
+Note that the GrADS scripting language is not particularly
+efficient in handling large numbers of variables.  Thus compound
+variables should not be used to create large arrays:
+<p>
+<ul><code>
+i = 1 <br> 
+while (i < 10000) <br> 
+&nbsp&nbsp var.i = i <br>
+&nbsp&nbsp i = i + 1 <br>
+endwhile
+</code></ul>
+<p>
+The above loop will create 10000 distinct variable names. Such
+a large number of variables in the variable chain will slow the
+script down a lot. 
+</ul>
+
+
+<p>
+<i><b><a name="operators">Operators</a></b></i>
+
+<p>
+The following operators are implemented in the scripting language:<p>
+<ul>
+<code>|          </code> logical OR <br>
+<code>&      </code> logical AND <br>
+<code>!          </code> unary NOT <br>
+<code>-          </code> unary minus <br>
+<code>=          </code> equal <br>
+<code>!=        </code> not equal <br>
+<code>>       </code> greater than <br>
+<code>>=     </code> greater than or equal <br>
+<code><       </code> less than <br>
+<code><=     </code> less than or equal <br> 
+<code>%          </code> concatenation <br>
+<code>+          </code> addition <br>
+<code>-          </code> subtraction <br>
+<code>*          </code> multiplication <br>
+<code>/          </code> division<br>
+</ul>
+
+<p>
+The following operators will perform a numeric operation if the
+operands are numeric:<p>
+
+<ul><code>=, !=, >, >=, <, <=, +, -, *, /</code></ul>
+
+<p>
+If any of the following operations are attempted with non-numeric
+operands, an error will result:<p>
+
+<ul><code>+, -, *, /</code></ul>
+
+<p>
+Arithmetical operations are done in floating point. If the result is
+integral, the result string will be an integer. Logical operations
+will give a character <code>0</code> (zero) if the result is FALSE,
+and a character <code>1</code> (one) if the result is TRUE.
+
+
+<p>
+<i><b><a name="expressions">Expressions</a></b></i>
+
+<p>
+Script expressions consist of any combination of operands, operators,
+and parentheses. Operands may be string constants, variables, 
+or function calls. The precedence of the operators is:
+<p>
+<ul><code>
+-, !  (Unary) <br>
+/, * <br>
++, - <br>
+% <br>
+=, !=, >, >=, <, <= <br>
+& <br>
+| <br>
+</code></ul>
+
+<p>
+Within the same precedence level, operations are performed left
+to right. Parentheses modify the order of operation according to
+standard convention.
+
+<p>
+All script expressions, including all function calls, etc. are
+evaluated and the resulting string is what gets executed as a
+command. For example:
+<p>
+<ul><code>
+var1 = -1 ; var2 = 10 <br>
+if (var1*var2 < 10 & var1 > 0) <br>
+   say 'both statements are true' <br>
+else <br>
+   say 'it is not the case that both statements are true' <br>
+endif <br>
+</code></ul>
+<p>
+For the expression following <code>if</code>, both sides of the
+logical operation must be evaluated before the entire expression can
+be simplified into a true or false result. In this case, the
+subexpression on the left is true, but the subexpression on the left
+is not, so the whole expressions resolves to 0 (zero) and the script
+will print:
+<p>
+<ul><code>it is not the case that both statements are true</code></ul>
+
+<p>
+<b><i>Concatenation</i></b>
+<p>
+In some espressions, the concatenation operator may be implied. The <code>%</code>
+operator may be omitted whenever the two operands are a string
+constant and a variable name. With implied concatentation, intervening
+blanks will be ignored.
+<p>
+For example, the following expressions have the same effect:
+<p>
+<ul>
+<code>'set lat 'minlat%' '%maxlat      </code>
+uses the concatenation operator % <br>
+<code>'set lat 'minlat' 'maxlat       </code>
+concatenation is implied <br>
+</ul>
+
+<p>
+Assuming two previous statements, <code>minlat = -30 </code> and
+<code> maxlat = 30</code>, the resulting expression would be:
+<p>
+<ul><code>'set lat -30 30'</code></ul>
+<p>
+Keep in mind the order of precedence when using the concatenation operator.
+
+<p>
+<i><b><a name="functions">Functions</a></b></i>
+<p>
+Function calls take the form of:
+<p>
+<ul><code>name(arg,arg,arg,...)</code></ul>
+
+<p>
+where the function name follows the same rules as for variable names, and
+the arguments may be any expression.
+
+Functions may either be contained within the script file itself,
+or the may be intrinsic functions. Functions contained within
+other script files are not supported as yet (other script files
+may be executed via the GrADS run command).<p>
+
+In either case, functions are invoked as a script expression is
+being evaluated.  Script functions always have a single string
+result, but may have one or more string arguments.  Functions are
+invoked by:<p>
+
+<dd><code>name(arg,arg,arg...)</code><p>
+
+If the function has no arguments, you must still provide the
+parentheses:<p>
+
+<dd><code>name()</code><p>
+
+You may provide your own functions from within your script file
+by using the <code>function</code> definition record:<p>
+
+<dd><code>function name(variable, variable, ...)</code><p>
+
+To return from a function, use the <code>return</code> command:<p>
+
+<dd><code>return <i>expression</i></code><p>
+
+The <code><i>expression</i></code> is optional; if not provided, a NULL string will
+be returned.  (A null string is: '')  The result of the function
+is the result of the expression specified on the return command.<p>
+
+When a function is invoked, the arguments are evaluated, then
+flow of control is transferred to the function.  The variables
+contained in the list within the function definition record are
+initialized   to the values of the passed arguments.  If too few
+arguments where passed for the variables specified, the trailing
+variables are uninitialized.  If too many arguments are passed,
+the extra arguments are discarded.<p>
+
+You may modify the variables from the function definition record
+without modifying the variables from the calling routine.<p>
+
+Scope of variables is normally local to the function, but can be
+global.<p>
+
+When a script file is first invoked (via the <code>run</code> command), 
+execution starts at the beginning of the file.  A function
+definition record may optionally be provided at the beginning. 
+If it is, it should specify one variable name.  This variable
+will be initialized to any <code>run</code> command options.  If no options
+were given, the variable will be initialized to NULL.<p>
+
+<p>
+<i><b><a name="intrinsic">Intrinsic Functions</a></b></i>
+<p>
+<ul>
+<b><code>strlen (<i>string</i>)</code></b>
+<br>
+This function returns the length (number of characters) of  
+<code><i>string</i></code>.
+
+<p><b><code>sublin (<i>string, n</i>)</code></b>
+<br>
+This function gets a single line from a string containing several
+lines. The result is the <code><i>nth</i></code> line of
+<code><i>string</i></code>.  If the string has too few lines, the
+result is NULL.  <code><i>n</i></code> must be an integer.
+
+<p>
+<b><code>subwrd (<i>string, n</i>)</code></b>
+<br>
+This functions gets a single word from a string. 
+The result is the <code><i>nth</i></code> word of <code><i>string</i></code>.  
+If the string is too short, the result is NULL. 
+<code><i>n</i></code> must be an integer.
+
+<p>
+<b><code>substr (<i>string, start, length</i>)</code></b>
+<br>
+This function gets part of a string. 
+The sub-string of <code><i>string</i></code> starting at location
+<code><i>start</i></code> for length <code><i>length</i></code> will be returned.  
+If the string is too short, the result will be short or NULL. 
+<code><i>start</i></code> and <code><i>length</i></code> must be integers.
+
+<p>
+<b><code>read (<i>filename</i>)</code></b>
+<br>
+This functions reads individual records from file <code><i>filename</i></code>.
+Repeated calls must be made to read consecutive records. The result is
+a string containing two lines: the first line is the return code, the 
+2nd line is the record read from the file. The record may be a maximum 
+of 80 characters. Use the <code>sublin</code> function to separate the
+result. Return codes are:<br>
+
+<ul>
+<code>0 - </code>ok <br>
+<code>1 - </code>open error <br>
+<code>2 - </code>end of file <br>
+<code>8 - </code>file open for write <br>
+<code>9 - </code>I/O error<br>
+</ul>
+
+Files are opened when the first call to read is made for a 
+particular file name. Files are closed when the execution of the
+script file terminates (note that files remain open between
+function calls, etc).
+
+<p>
+<b><code>write (<i>filename, record</i> <, append>)</code></b>
+<br>
+This functions writes records to output file <code>filename</code>.  
+
+On the first call to write for a particular file, the file is opened
+in write mode.  This will destroy an existing file!  If you use the
+optional append flag, the file will be opened in append mode, and all
+writes will be appended to the end of the file.  Return codes are:<br>
+<ul>
+<code>0</code> - ok <br>
+<code>1</code> - open error <br>
+<code>8</code> - file open for read</ul>
+
+<p>
+<b><code>close (<i>name</i>)</code></b>
+<br>
+
+This function closes the named file.  This must be done if you wish to
+read from a file you have been writing to.  This can also be used to
+rewind a file.  Return codes are:<br>
+<ul>
+<code>0</code> - ok <br>
+<code>1</code> - file not open</ul><p>
+</ul>
+
+<h2><a name="commands"><u>Commands that complement the scripting language</u></a></h2>
+<p>
+There are some GrADS commands that, although not designed
+exclusively for scripts, are most useful in script applications. 
+These include:
+
+<p>
+<b><code><a href="gradcomdquery.html">query</a> <<i>option</i>></code></b> or 
+<b><code><a href="gradcomdquery.html">q</a> <<i>option</i>></code></b>
+<ul>
+<p>
+To see the list of available options, issue the <code><a
+href="gradcomdquery.html">query</a></code> command by itself. A
+description of the <code><a href="gradcomdquery.html">query</a></code>
+options that are most useful for script applications follows.
+
+<p>
+<b><code><a href="gradcomdquery.html">q</a> define</code></b> --
+Lists all defined variables
+
+<p>
+<b><code><a href="gradcomdquery.html">q</a> defval <i>ival
+jval</i></code></b> -- Gives defined grid value at <i>ival, jval</i>
+<p>
+To interactively modify grid point values for a <code>defined</code>
+variable, <code><a href="gradcomdquery.html">q</a> defval</code>
+can be used in conjunction with <code><a
+href="gradcomdsetdefval.html">set defval</a></code>. For example, the
+code shown below queries the value of sst at gridpoint(i,j), then
+tests to see if the value is less than -1.6, and if it is, sets the
+sst to a bad value.<p>
+<ul>
+<code>
+'q defval sst 'i' 'j <br>
+val = subwrd(result,3) <br>
+if (val < -1.6)  <br>
+&nbsp&nbsp'set defval sst 'i' 'j' 'bad_value <br>
+endif <br>
+</code>
+</ul>
+
+<p>
+<b><code><a href="gradcomdquery.html">q</a> dims</code></b> --
+Gives the current dimension environment
+
+<p>
+<b><code><a href="gradcomdquery.html">q</a> file
+<i>n</i></code></b> -- Gives info on file number <i>n</i>
+
+<p>
+<b><code><a href="gradcomdquery.html">q</a> files</code></b> --
+Lists open files
+
+<p>
+<b><code><a href="gradcomdquery.html">q</a> fwrite</code></b> --
+Gives the name of the file used for fwrite operations
+
+<p>
+<b><code><a href="gradcomdquery.html">q</a> gxinfo</code></b> --
+Lists graphics settings
+
+<p>
+This option is handy when trying to find the plot area. The output
+from <code><a href="gradcomdquery.html">q</a> gxinfo</code> might
+look like this:
+
+<p>
+<code>
+<ul>
+Last Graphic = Line <br>
+Page Size = 11 by 8.5 <br>
+X Limits = 2 to 10.5 <br>
+Y Limits = 0.75 to 7.75 <br>
+Xaxis = Lon  Yaxis = Val <br>
+Mproj = 2<br>
+</ul>
+</code>
+
+<p>
+The first line indicates that the output is a line plot. The second line
+gives the page dimensions -- in this case GrADS is in landscape
+mode. The third and fourth lines give the x and y boundaries of the
+plot. In this case the plot has 1-inch margins in the x direction and
+0.75-inch margins in the y direction.  The fifth line tells what kind
+of axes you have, and the sixth line identifies the map projection:
+<br>
+<ul>
+<code>1    </code>Scaled (no preservation of aspect ratio)<br>
+<code>2    </code>Latlon (2-D horizontal fields) <br>
+<code>3    </code>Northern polar stereographic <br>
+<code>4    </code>Southern polar stereographic <br>
+<code>5    </code>Robinson (lon range must be -180 to
+180 and lat range must be -90 to 90)<br>
+</ul>
+
+<p>
+<b><code><a href="gradcomdqpos.html">q pos</a></code></b> -- Waits for mouse click, returns position<br>
+
+<p>
+<b><code><a href="gradcomdquery.html">q</a> shades</code></b> -- Gives colors and levels of shaded contours<br>
+
+<p>
+<b><code><a href="gradcomdquery.html">q</a> time</code></b> - gives time range of current open file<br>
+
+<p>
+<b><code><a href="gradcomdquery.html">q</a> <i>transform coord1 coord2</i></code></b> -- Coordinate transformations 
+
+<ul>
+<p>
+where <code><i>transform</i></code> is one of: <br>
+<code>xy2w       </code>XY coords to world coords <br>
+<code>xy2gr      </code>XY coords to grid coords <br>
+<code>w2xy       </code>world coords to XY coords <br>
+<code>w2gr       </code>world coords to grid coords <br>
+<code>gr2w       </code>grid coords to world coords <br>
+<code>gr2xy      </code>grid coords to XY coords <br>
+</ul>
+
+<p>
+<i>XY coords</i> are inches on the page (screen) where the page is
+11x8.5 inches or 8.5x11 inches, depending on how GrADS was started.
+
+<p>
+<i>World coords</i> are lat, lon, lev, time or val, depending on what
+the dimension environment is when the grid was displayed. Note that
+time is displayed (and must be specified) in GrADS absolute date/time
+format. val is the value coordinate for a 1-D plot (linegraph).
+
+<p>
+<i>Grid coordinates</i> are the i,j indices the grid being
+displayed. For station data sets, grid and world coordinates are
+equivalent except for the time dimension. Note that if you display a
+grid from a 'wrapped' data set, the grid numbers may be out of range
+of the actual file grid numbers. (A 'wrapped' data set is a data set
+that covers the earth in the longitude direction. Wrapping takes place
+automatically). The conversions are done consistently, but you may
+want to be sure you can handle the wrapping case if your data set is
+global.
+
+<p>
+N.B. Coordinate transform queries are only valid after something has
+been displayed, and the transformations apply only to the most recent
+item that has been displayed.
+</ul>
+
+<p>
+<b><code><a name="scriptfindstn">set gxout findstn</a></code></b>
+<p>
+When using the graphics output type <code><a href="gradcomdsetgxout.html">set gxout findstn</a></code>, three
+arguments must be provided with the <a
+href="gradcomddisplay.html"><code>display</code></a> command. The
+first argument is a station data expression. The 2nd and 3rd arguments
+are the X and Y screen coordinates of the of the desired search
+location.  GrADS will find the station closest to the specified X and
+Y position, and print its stid, lon, and lat.  This graphics output
+type should only be used when X and Y are the varying dimensions and
+AFTER a regular display command (that results in graphics output) is
+entered.
+<p>
+<b><code>set dbuff on|off</code></b>
+<p>
+This command sets double buffer mode <code>on</code> or
+<code>off</code>. This allows animation to be controlled from a
+script. The <a href="gradcomdclear.html"><code>clear</code></a>
+command also sets double buffer mode <code>off</code>.
+
+<p>
+<b><code>swap</code></b>
+
+<p>
+Swaps buffers, when double buffer mode is <code>on</code>. If double
+buffer mode is <code>off</code>, this command has no effect.
+
+<p>
+The usual usage of these commands would be:<p>
+
+<ul>
+<code>
+set dbuff on <br>
+start looping <br>
+&nbsp&nbsp display <i>something</i><br>
+&nbsp&nbsp swap <br>
+endloop <br>
+set dbuff off<br>
+</code>
+</ul>
+
+<p>
+<a name="widgets"><h2><u>Widgets</u></h2></a>
+<p>
+GrADS has the capability to implement a graphical user interface. This
+interface is used to draw widgets (buttons and pull down menus) that
+allow a "point and click" interface between the Grads user and the
+scripting language.
+
+ (N.B. The widgets have been temporarily disabled for <span class="red">version 2.1.a1</span>) 
+<p>
+<h3>Buttons</h3>
+<p>
+Here is a sample from a script illustrating how to draw a button:
+
+<p>
+<ul>
+<pre>
+set rgb 90 100 100 100
+set rgb 91  50  50  50
+set rgb 92 200 200 200
+set button 2 90 91 92 3 90 92 91 6
+draw button 1 5.5 1 2 0.5 This is a Button
+</pre>
+</ul>
+
+<p>
+The reference pages for <a href="gradcomdsetbutton.html"><code>set
+button</code></a> and <a href="gradcomddrawbutton.html"><code>draw
+button</code></a> contain information on how to specify the button
+characteristics and position.
+
+<p>
+A button's initial "state" is <code>ON</code>. If a user clicks on a
+button following a <a href="gradcomdqpos.html"><code>q pos</code></a>
+command, then the button state will switch from <code>ON (1)</code> to
+<code>OFF (0)</code>. A second <a href="gradcomdqpos.html"><code>q
+pos</code></a> followed by a mouse click on the button will return it
+to the <code>ON</code> state. The button state may also be changed
+with the <a href="gradcomdredrawbutton.html"><code>redraw
+button</code></a> command.
+
+<p>
+The output from the <a href="gradcomdqpos.html"><code>q pos</code></a> command 
+is what makes the button widgets so useful. Here is a template of what 
+<a href="gradcomdqpos.html"><code>q pos</code></a> returns after a mouse click
+on a button:
+
+<p>
+<code>
+Position = <i>xpos ypos mousebutton widgetclass buttonnumber buttonstate </i></code>
+
+<p>
+where:
+<ul>
+<code><i>xpos, ypos</i>&nbsp&nbsp&nbsp&nbsp</code>
+- coordinates of the mouse click in virtual page units <br>
+<code><i>mousebutton</i>&nbsp&nbsp&nbsp</code>
+- either 1, 2, or 3 for the left, center, or right mouse button <br>
+<code><i>widgetclass</i>&nbsp&nbsp&nbsp</code>
+- 1 is the widget class number for buttons  <br>
+<code><i>buttonnumber</i>&nbsp&nbsp</code>
+- the number assigned to the button when it was originally drawn <br>
+<code><i>buttonstate</i>&nbsp&nbsp&nbsp</code>
+- either 0 (meaning "off") or 1 (meaning "on")
+</ul>
+
+<p>
+If the user did not click on a button, then <code><i>widgetclass</i></code>
+will be 0 and there will be no output for
+<code><i>buttonnumber</i></code> or <code><i>buttonstate</i></code>.
+
+
+<p>
+<h3>Drop Menus</h3>
+<p>
+As with button widgets, dropmenus provide a "point-and-click"
+interface between scripts and the GrADS user. The reference pages for
+<a href="gradcomdsetdropmenu.html"><code>set dropmenu</code></a> and
+<a href="gradcomddrawdropmenu.html"><code>draw dropmenu</code></a>
+contain information on how to specify the dropmenu characteristics and
+position.
+<p>
+The output from <a href="gradcomdqpos.html"><code>q pos</code></a>
+after a click on a dropmenu is similar to that described above for
+buttons.  Here is a template of what is returned by <a
+href="gradcomdqpos.html"><code>q pos</code></a> after a mouse click
+on a dropmenu:
+
+<p>
+<code>Position = <i>xpos ypos mousebutton widgetclass menunumber inum</i></code>
+
+<p>
+where:
+<ul>
+<code><i>xpos, ypos</i>&nbsp&nbsp&nbsp&nbsp</code>
+- coordinates of the mouse click in the menu base in virtual page units <br>
+<code><i>mousebutton</i>&nbsp&nbsp&nbsp</code>
+- either 1, 2, or 3 for the left, center, or right mouse button <br>
+<code><i>widgetclass</i>&nbsp&nbsp&nbsp</code>
+- 3 is the widget class number for dropmenus  <br>
+<code><i>menunumber</i>&nbsp&nbsp&nbsp&nbsp</code>
+- the number assigned to the dropmenu when it was originally drawn <br>
+<code><i>inum</i>&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp</code>
+-  the menu item number selected from the menu list
+</ul>
+
+<p>
+If no menu item is selected, then <code><i>menunumber</i></code> and <code><i>inum</i></code> will
+both be -1.
+
+
+<p>
+Here is a script sample illustrating how to use a dropmenu:
+
+<p>
+<pre>
+'reset events'
+'set rgb 90 100 100 100'
+'set rgb 91 150 150 150'
+'set rgb 92 200 200 200'
+'set dropmenu 1 91 90 92 0 91 90 92 1 91 90 92 90 92 6'
+'draw dropmenu 1 1 8 1.5 0.5 Select a Variable | Wind | Temperature | Height | SLP '
+noselect = 1
+while (noselect)
+  'q pos'
+  menunum  = subwrd(result,7)
+  menuitem = subwrd(result,8)
+  if (menunum = 1)
+    if menuitem = 1 ; newbase = 'Variable = Wind'   ; endif
+    if menuitem = 2 ; newbase = 'Variable = Temp'   ; endif
+    if menuitem = 3 ; newbase = 'Variable = Height' ; endif
+    if menuitem = 4 ; newbase = 'Variable = SLP'    ; endif
+    'draw dropmenu 1 1 8 1.5 0.5 'newbase' | Wind | Temperature | Height | SLP '
+    noselect = 0
+  endif
+endwhile
+</pre>
+<p>
+Here is another script sample illustrating how to use cascading dropmenus:
+<p>
+<pre>
+'clear'
+'set rgb 90 100 100 100'
+'set rgb 91 150 150 150'
+'set rgb 92 200 200 200'
+'set button 1 91 -1 -1 1 91 90 92 12'
+'draw button 1 1 8 1 0.5 quit'
+'set dropmenu 1 91 -1 -1 1 91 90 92 1 91 90 92 90 92 6'
+'draw dropmenu 1 1.5 7.5 2 0.5  Menu Base | Space | Earth >05> | Sun | Moon'
+'draw dropmenu 5 cascade Ocean | Land | Atmosphere >11> | Biosphere'
+'draw dropmenu 11 cascade Snow | Rain | Mist | Tornado '
+
+while (1)
+  'q pos'
+  say result
+  ev = subwrd(result,6)
+  if (ev!=3); break; endif;
+endwhile
+</pre>
+<p>
+It is left to the GrADS script writer (that means you!) to run the demo and 
+interpret the output of <a href="gradcomdqpos.html"><code>q pos</code></a>
+when clicking on all the options in the cascade of dropmenus. 
+
+<p>
+<h3>Rubber banding</h3>
+
+<p>
+GrADS has a widget type called <code>rband</code> for rubber banding.  There
+are two <code>rband</code> modes: <code>box</code> and <code>line</code>.
+To set up the <code>rband</code> widget, use the following command:
+<p>
+<ul><code>
+<a href="gradcomdsetrband.html">set rband</a> <i>num mode x1 y1 x2 y2</i>
+</code></ul>
+
+<p>
+where:
+<p>
+<ul>
+<code><i>num</i>   </code>
+- widget number<br>
+<code><i>mode</i>  </code>
+- may be either <code>box</code> or <code>line</code><br>
+<code><i>x1</i>    </code>
+- lowest X point where the widget will be active (in virtual page units)<br>
+<code><i>y1</i>    </code>
+- lowest Y point where the widget will be active (in virtual page units)<br>
+<code><i>x2</i>    </code>
+- highest X point where the widget will be active (in virtual page units)<br> 
+<code><i>y2</i>    </code>
+- highest Y point where the widget will be active (in virtual page units)<br>
+</ul>
+
+<p>
+In <code>box</code> mode, as the user clicks and drags the mouse in
+the active rband area a box is drawn with one corner located at the
+initial click and the opposite corner located at the release point. In
+<code>line</code> mode, a line is drawn between these two points.
+
+<p>
+For example, suppose you  want to set up a
+<code>box</code> rubber band widget in the plot region only.
+
+<p>
+First, execute <a href="gradcomdquery.html"><code>q gxinfo</code></a>
+to get the X and Y limits of the plot area. The result from <a
+href="gradcomdquery.html"><code>q gxinfo</code></a> might look like
+this:
+
+<ul>
+<pre>
+Last Graphic = Line
+Page Size = 11 by 8.5
+X Limits = 2 to 10.5
+Y Limits = 0.75 to 7.75
+Xaxis = Lon  Yaxis = Val
+Mproj = 2
+</pre>
+</ul>
+
+<p>
+Second, set up the widget with <a
+href="gradcomdsetrband.html"><code>set rband</code></a> using the dimensions
+grabbed from the result of <a href="gradcomdquery.html"><code>q gxinfo</code></a>:
+<p>
+<ul>
+<pre>
+xlims = sublin(result,3)
+ylims = sublin(result,4)
+x1 = subwrd(xlims,4)
+x2 = subwrd(xlims,6)
+y1 = subwrd(ylims,4)
+y2 = subwrd(ylims,6)
+'set rband 21 box 'x1' 'y1' 'x2' 'y2
+</pre>
+</ul>
+
+<p>
+Finally, use <a href="gradcomdqpos.html"><code>q pos</code></a> 
+to activate the widget.
+
+<p>
+<ul><code>ga-> q pos</code></ul>
+
+<p>
+This freezes the system until the user clicks, drags, and 
+then releases the mouse somewhere within the active rband area. 
+Here is a template for the output you would get from GrADS after
+a mouse click and drag in the rband area:<p>
+
+<ul>
+<code>Position = <i>xpos1 ypos1 mousebutton widgetclass widgetnumber xpos2 ypos2</i></code>
+</ul>
+
+<p>
+where:
+<ul>
+<code><i>xpos1, ypos1</i>&nbsp&nbsp&nbsp</code>
+- coordinates of the initial mouse click in virtual page units <br>
+<code><i>mousebutton</i>&nbsp&nbsp&nbsp&nbsp</code>
+- either 1, 2, or 3 for the left, center, or right mouse button <br>
+<code><i>widgetclass</i>&nbsp&nbsp&nbsp&nbsp</code>
+- 2 is the widget class number for rbands  <br>
+<code><i>widgetnumber</i>&nbsp&nbsp&nbsp</code>
+- the number assigned to the
+rband widget when it was set up  <br>
+<code><i>xpos2, ypos2</i>&nbsp&nbsp&nbsp</code>
+- coordinates of the mouse release point in virtual page units <br>
+</ul>
+
+<p>
+The page coordinates can be then be used to draw a box (or a line)
+where the user specified, or parsed and used in the coordinate
+transform <a href="gradcomdquery.html"><code>q xy2w</code></a> to
+recover the lat/lon region selected by the user.
+
+</body>
+</html>
\ No newline at end of file
diff --git a/doc/shapefiles.html b/doc/shapefiles.html
index 0343e57..605bb46 100644
--- a/doc/shapefiles.html
+++ b/doc/shapefiles.html
@@ -1,80 +1 @@
-<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.--><title>Shapefiles</title>
-<style type="text/css">
-<!--
-.style1 {color: #990000}
--->
-</style>
-<H2><strong>The Shapefile</strong> Interface in GrADS</H2>
-<p><strong>
-<a href="#intro">Introduction</a><br />
-<a href="#whatis">What is a shapefile?</a><br />
-<a href="#draw">Drawing shapefiles</a><br />
-<a href="#query">Querying shapefiles</a><br />
-<a href="#envv">Relevant Environment Variables</a><br />
-<a href="#writing">Writing shapefiles</a><br />
-<a href="#examples">Examples</a><br />
-<a href="#caveat">Caveat</a></strong></p>
-<p><img src="../../assets/colaline.gif" alt="line" width="600" height="4" />
-<p><em><strong><a name="intro" id="intro"></a>Introduction</strong></em><br />
-  GrADS version 2.0.a8 introduced the new  capability to  <strong>draw</strong> and <strong>query</strong> the contents of a shapefile; version 2.0.a9 added the capability to <strong>create</strong> new shapefiles from GrADS gridded or station data sets. This documentation page serves as an overview of the GrADS shapefile inteface, providing guidance on what shapefiles are, how to find out what they contain, how to draw their contents, and how to create new shapefiles. 
-<P><em><strong><a name="whatis" id="whatis"></a>What is a Shapefile?</strong></em><br />
-  The shapefile format (promulgated by <a href="http://esri.com" target="_parent">ESRI</a>) stores non-topological geometry and attribute information for the spatial features in a data set.  Shapefiles are used extensively in Geographic Information Systems (GIS) and they typically contain data related to coastlines, political boundaries, state or county boundaries, climate zones, roads, rivers, topography, etc. The geometry of each spatial feature or 'shape' is stored as a set of vector  [...]
-The projection file contains specifics about the spherical geometry; it is an optional but useful component of a shapefile.
-<P>Some resources for freely available shapefiles are:
-
-<ul>
-  <li><a href="http://www.weather.gov/geodata/" target="_blank">National Weather Service Shapefile Database</a></li>
-  <li><a href="http://www.nationalatlas.gov/atlasftp.html" target="_blank">National Atlas</a></li>
-  <li><a href="http://www.diva-gis.org/Data" target="_blank">DIVA-GIS</a></li>
-  <li><a href="http://www.naturalearthdata.com/downloads/">Natural Earth</a></li>
-</ul>
-<P><a name="draw" id="draw"></a><em><strong>Drawing Shapefiles</strong></em><br />
-GrADS will draw the contents of a shapefile as an overlay on top of an existing plot with the command <code><a href="gradcomddrawshp.html">draw shp</a></code>. It is necessary to draw a plot first in order to establish the dimensions and scaling of the display. Shapefiles contain 2-dimensional spatial features, so your plot must be varying in the X-Y (lon/lat) domain. 
-<P>A shapefile may contain one of three kinds of graphical elements: points, lines, or polygons. 
-<ul>
-  <li> For shapefiles that contain points, GrADS will draw a mark at each point location. The mark type and size are controlled by the <code><a href="gradcomdsetshpopts.html">set shpopts</a></code> command, and the color is controlled by the <code><a href="gradcomdsetline.html">set line</a></code> command. </li>
-  <li>For shapefiles that contain lines, GrADS will draw the line elements using the color, style, and thickness settings that are controlled by the <code><a href="gradcomdsetline.html">set line</a></code> command. </li>
-  <li>For shapefiles that contain polygons, the default behavior of GrADS is draw only the perimeter of each polygon element.The color, style, and thickness of the polygon perimeters are controlled by the <code><a href="gradcomdsetline.html">set line</a></code> command.  Use  the <code><a href="gradcomdsetshpopts.html">set shpopts</a></code> command to draw filled polygons and set the fill color. </li>
-</ul>
-<p>The <code><a href="gradcomddrawshp.html">draw shp</a></code> command draws all the shapes in the shapefile by default, but it is possible to specify a single shape or a range of shapes to draw. Using these extra arguments to the  <code><a href="gradcomddrawshp.html">draw shp</a></code> command, you can control the line and color characteristics of individual shapes. The <code><a href="gradcomdqshpopts.html">q shpopts</a></code> command lists the current settings for drawing shapefiles. </p>
-<p><a name="query" id="query"></a><em><strong>Querying Shapefiles</strong></em><br />
-The GrADS shapefile interface also allows the user to discover the contents of a shapefile. The  <code><a href="gradcomdqshp.html">q shp</a></code> command returns information about the shapes in the file (number of vertices and lon/lat bounds), and the  <code><a href="gradcomdqdbf.html">q dbf</a></code> command returns all the attribute information for each shape in the file. </p>
-<p>The first line of the <code><a href="gradcomdqshp.html">q shp</a></code> output contains the shapefile type, the number of shapes in the file, and the X and Y bounds of actual extent of the shapes in the file. Subsequent lines list information about each shape element in the file: the identification number, the shape type, the number of parts, the number of vertices, and the bounds of the shape in the X, Y, Z, and M (measure) dimesions. The  GrADS interface ignores the Z or M values o [...]
-<p>The first line of the <code><a href="gradcomdqdbf.html">q dbf</a></code> output contains a comma-delimited list of the names of all the attributes for each record in the database. Subsequent lines contain the comma-delimited list of all the attribute values for each record. </p>
-<p>Please refer to the reference pages for <code><a href="gradcomdqshp.html">q shp</a></code> and <code><a href="gradcomdqdbf.html">q dbf</a></code> for additional information and examples of the output. </p>
-<p><em><strong><a name="envv" id="writing2"></a>Relevant Environment Variables</strong></em><br />
-When drawing and  querying shapefiles, if you put the  set of component files  (*.shp, *.shx, *.dbf) in the GrADS data directory (specified by the environment variable <a href="gradcomdgrads.html#env"><code>GADDIR</code></a>), then it is not necessary to include the full path when referring to the shapefile. Starting with <span class="style1">GrADS version 2.0.0</span>, a new  environment variable was introduced, <a href="gradcomdgrads.html#env"><code>GASHP</code></a>, for specifiying a  [...]
-<p><em><strong><a name="writing" id="writing"></a>Writing Shapefiles</strong></em><br /> 
-GrADS version 2.0.a9 adds the capability of writing out shapefiles based on gridded or station data sets. The shape types currently supported are points and lines. Point shapes may be created from  station data or from individual grid point values. The GrADS station data format is a natural fit for point shapefiles, but grid point values are also useful in the shapefile format -- they can be used to create a stippled overlay on top of shaded contour plot (see <a href="#examples">Examples [...]
-<p>To write out a shapefile, there is a new graphics output option, <code><a href="gradcomdsetgxout.html">set gxout shp</a></code>. This graphics  option is used in conjunction with   the <code><a href="gradcomdsetshp.html">set shp</a></code> command which allows the user to set  the filename root  for shapefile output, control the type of shapefile to be created, and set formatting options for numeric values. The <code><a href="gradcomddisplay.html">display</a></code> command  will then [...]
-<p>The dBase file created with the shapefile contains metadata fields or attributes for each shape. There are three data types for attributes: string, integer, or double. Attributes may be static (the attribute value is the same for each shape) or dynamic (the attribute value varies with shape). A set of attributes (both static and dynamic)  are automatically generated by GrADS for all shapes. Attributes for point shapes from station data are: GrADS version, longitude, latitude, station  [...]
-<p>The <code><a href="gradcomdqshpopts.html">q shpopts</a></code> command lists the current settings for shapefile output, including the output file name root, the type of shapefile to be created, the formatting of any numeric output, and any user-provided attributes.</p>
-<p> The <code><a href="gradcomdclear.html">clear shp</a></code> command releases all user-defined shapefile attributes from memory, and resets the  output filename root and shapefile type to their default values. The <code><a href="gradcomdreset.html">reset</a></code> and <code><a href="gradcomdreinit.html">reinit</a></code> commands will do the same thing -- use  <code><a href="gradcomdclear.html">clear shp</a></code> if you do not want to reset all the other user settings. </p>
-<p><a name="examples" id="examples"></a><em><strong>Examples </strong></em><br />
-  <em><strong><br />
-  </strong></em>Here are two examples showing a series of commands to create  shapefiles: </p>
-<pre>set gxout shp
-set shp -pt -fmt 8 4 gridptm
-set shpattr AUTHOR string JMA
-set shpattr TYPE string grid points
-set shpattr DESC string land surface temperature
-d maskout(tsfc,landmask-1)
-  
-set gxout shp
-clear shp
-set shp -ln -fmt 8 4 linem
-set shpattr AUTHOR string JMA
-set shpattr TYPE string grid contours
-set shpattr DESC string surface temperature
-d tsfc
-</pre>
-<p>Here is a slightly more complicated <a href="ftp://cola.gmu.edu/grads/scripts/shp_demo2.gs">example script</a> that shows how to create a shapefile from a GrADS gridded data set (a GFS precipitation forecast), and then draws the contents of that shapefile as a stippled overlay (with three gray shades) on top of a contour plot of another variable, sea level pressure. The script generates a plot that looks like this:</p>
-<p><img src="shp_demo2.png" alt="shp demo 2" /></p>
-<p>Here is  another <a href="ftp://cola.gmu.edu/grads/scripts/shp_demo1.gs">example script</a> that shows how to use the shapefile interface to draw U.S. climate divisions colorized according to the values of the Palmer Drought Severity Index (PDSI), and then overlays the 500mb height anomaly (from a GDS data set) for that same month and year. The script generates a plot that looks like this: </p>
-<p><img src="shp_demo1.png" alt="pdsi" /></p>
-<p>The final <a href="ftp://cola.gmu.edu/grads/scripts/shp_demo3.gs">example script</a> uses shapefiles to draw state and county boundaries as well as roads on a radar image instead of drawing the GrADS map. Here is the result:</p>
-<p><img src="shp_demo3.png" alt="shp demo 3" width="887" height="604" /></p>
-<p> </p>
-<p><em><strong><a name="caveat" id="caveat"></a>Caveat</strong><br />
-</em>The <a href="http://www.esri.com/library/whitepapers/pdfs/shapefile.pdf">ESRI Shapefile Techncial Description</a> states that <em>"A polygon consists of one or more rings. A ring is a connected sequence of four or more points that form a closed, non-self-intersecting loop."</em>  A polygon with two rings would look something like a flat donut -- the area between the two rings forms the interior of the polygon, and the area enclosed by the inner ring is actually  in the ext [...]
-<p>The rings of a polygon are referred to as its parts, and the number of parts in each polygon is included in the ouput of the <code><a href="gradcomdqshp.html">q shp</a></code> command. So it is possible to discover whether this limitation is affecting your plot. </p>
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.--><title>Shapefiles</title>
<style type="text/css">
<!--
.style1 {color: #990000}
-->
</style>
<H2><strong>The Shapefile</strong> Interface in GrADS</H2>
<p><strong>
<a href="#intro">Introduction</a><br />
<a href="#whatis">What is a shapefile?</a><br />
<a href="#draw">Drawing shapefiles</a><br />
<a href="#query">Querying shapefiles</a><br />
<a href="#envv">Relevant Environment Variables</a><br />
<a href="#writing">Writing shapefiles</a><br />
<a href="#examples">Examples</a><br />
<a href="#caveat">Caveat</a></strong></p>
<p><img src="../../assets/colaline.gif" alt="line" width="600" height="4" />
<p><em><strong><a name="intro" id="intro"></a>Introduction</strong></em><br />
  GrADS version 2.0.a8 introduced the new  capability to  <strong>draw</strong> and <strong>query</strong> the contents of a shapefile; version 2.0.a9 added the capability to <strong>create</strong> new shapefiles from GrADS gridded or station data sets. This documentation page serves as an overview of the GrADS shapefile inteface, providing guidance on what shapefiles are, how to find out what they contain, how to draw their contents, and how to create new shapefiles. 
<P><em><strong><a name="whatis" id="whatis"></a>What is a Shapefile?</strong></em><br />
  The shapefile format (promulgated by <a href="http://esri.com" target="_parent">ESRI</a>) stores non-topological geometry and attribute information for the spatial features in a data set.  Shapefiles are used extensively in Geographic Information Systems (GIS) and they typically contain data related to coastlines, political boundaries, state or county boundaries, climate zones, roads, rivers, topography, etc. The geometry of each spatial feature or 'shape' is stored as a set of vector c [...]
The projection file contains specifics about the spherical geometry; it is an optional but useful component of a shapefile.
<P>Some resources for freely available shapefiles are:

<ul>
  <li><a href="http://www.weather.gov/geodata/" target="_blank">National Weather Service Shapefile Database</a></li>
  <li><a href="http://www.nationalatlas.gov/atlasftp.html" target="_blank">National Atlas</a></li>
  <li><a href="http://www.diva-gis.org/Data" target="_blank">DIVA-GIS</a></li>
  <li><a href="http://www.naturalearthdata.com/downloads/">Natural Earth</a></li>
</ul>
<P><a name="draw" id="draw"></a><em><strong>Drawing Shapefiles</strong></em><br />
GrADS will draw the contents of a shapefile as an overlay on top of an existing plot with the command <code><a href="gradcomddrawshp.html">draw shp</a></code>. It is necessary to draw a plot first in order to establish the dimensions and scaling of the display. Shapefiles contain 2-dimensional spatial features, so your plot must be varying in the X-Y (lon/lat) domain. 
<P>A shapefile may contain one of three kinds of graphical elements: points, lines, or polygons. 
<ul>
  <li> For shapefiles that contain points, GrADS will draw a mark at each point location. The mark type and size are controlled by the <code><a href="gradcomdsetshpopts.html">set shpopts</a></code> command, and the color is controlled by the <code><a href="gradcomdsetline.html">set line</a></code> command. </li>
  <li>For shapefiles that contain lines, GrADS will draw the line elements using the color, style, and thickness settings that are controlled by the <code><a href="gradcomdsetline.html">set line</a></code> command. </li>
  <li>For shapefiles that contain polygons, the default behavior of GrADS is draw only the perimeter of each polygon element.The color, style, and thickness of the polygon perimeters are controlled by the <code><a href="gradcomdsetline.html">set line</a></code> command.  Use  the <code><a href="gradcomdsetshpopts.html">set shpopts</a></code> command to draw filled polygons and set the fill color. </li>
</ul>
<p>The <code><a href="gradcomddrawshp.html">draw shp</a></code> command draws all the shapes in the shapefile by default, but it is possible to specify a single shape or a range of shapes to draw. Using these extra arguments to the  <code><a href="gradcomddrawshp.html">draw shp</a></code> command, you can control the line and color characteristics of individual shapes. The <code><a href="gradcomdqshpopts.html">q shpopts</a></code> command lists the current settings for drawing shapefiles. </p>
<p><a name="query" id="query"></a><em><strong>Querying Shapefiles</strong></em><br />
The GrADS shapefile interface also allows the user to discover the contents of a shapefile. The  <code><a href="gradcomdqshp.html">q shp</a></code> command returns information about the shapes in the file (number of vertices and lon/lat bounds), and the  <code><a href="gradcomdqdbf.html">q dbf</a></code> command returns all the attribute information for each shape in the file. </p>
<p>The first line of the <code><a href="gradcomdqshp.html">q shp</a></code> output contains the shapefile type, the number of shapes in the file, and the X and Y bounds of actual extent of the shapes in the file. Subsequent lines list information about each shape element in the file: the identification number, the shape type, the number of parts, the number of vertices, and the bounds of the shape in the X, Y, Z, and M (measure) dimesions. The  GrADS interface ignores the Z or M values of [...]
<p>The first line of the <code><a href="gradcomdqdbf.html">q dbf</a></code> output contains a comma-delimited list of the names of all the attributes for each record in the database. Subsequent lines contain the comma-delimited list of all the attribute values for each record. </p>
<p>Please refer to the reference pages for <code><a href="gradcomdqshp.html">q shp</a></code> and <code><a href="gradcomdqdbf.html">q dbf</a></code> for additional information and examples of the output. </p>
<p><em><strong><a name="envv" id="writing2"></a>Relevant Environment Variables</strong></em><br />
When drawing and  querying shapefiles, if you put the  set of component files  (*.shp, *.shx, *.dbf) in the GrADS data directory (specified by the environment variable <a href="gradcomdgrads.html#env"><code>GADDIR</code></a>), then it is not necessary to include the full path when referring to the shapefile. Starting with <span class="style1">GrADS version 2.0.0</span>, a new  environment variable was introduced, <a href="gradcomdgrads.html#env"><code>GASHP</code></a>, for specifiying a l [...]
<p><em><strong><a name="writing" id="writing"></a>Writing Shapefiles</strong></em><br /> 
GrADS version 2.0.a9 adds the capability of writing out shapefiles based on gridded or station data sets. The shape types currently supported are points and lines. Point shapes may be created from  station data or from individual grid point values. The GrADS station data format is a natural fit for point shapefiles, but grid point values are also useful in the shapefile format -- they can be used to create a stippled overlay on top of shaded contour plot (see <a href="#examples">Examples< [...]
<p>To write out a shapefile, there is a new graphics output option, <code><a href="gradcomdsetgxout.html">set gxout shp</a></code>. This graphics  option is used in conjunction with   the <code><a href="gradcomdsetshp.html">set shp</a></code> command which allows the user to set  the filename root  for shapefile output, control the type of shapefile to be created, and set formatting options for numeric values. The <code><a href="gradcomddisplay.html">display</a></code> command  will then  [...]
<p>The dBase file created with the shapefile contains metadata fields or attributes for each shape. There are three data types for attributes: string, integer, or double. Attributes may be static (the attribute value is the same for each shape) or dynamic (the attribute value varies with shape). A set of attributes (both static and dynamic)  are automatically generated by GrADS for all shapes. Attributes for point shapes from station data are: GrADS version, longitude, latitude, station I [...]
<p>The <code><a href="gradcomdqshpopts.html">q shpopts</a></code> command lists the current settings for shapefile output, including the output file name root, the type of shapefile to be created, the formatting of any numeric output, and any user-provided attributes.</p>
<p> The <code><a href="gradcomdclear.html">clear shp</a></code> command releases all user-defined shapefile attributes from memory, and resets the  output filename root and shapefile type to their default values. The <code><a href="gradcomdreset.html">reset</a></code> and <code><a href="gradcomdreinit.html">reinit</a></code> commands will do the same thing -- use  <code><a href="gradcomdclear.html">clear shp</a></code> if you do not want to reset all the other user settings. </p>
<p><a name="examples" id="examples"></a><em><strong>Examples </strong></em><br />
  <em><strong><br />
  </strong></em>Here are two examples showing a series of commands to create  shapefiles: </p>
<pre>set gxout shp
set shp -pt -fmt 8 4 gridptm
set shpattr AUTHOR string JMA
set shpattr TYPE string grid points
set shpattr DESC string land surface temperature
d maskout(tsfc,landmask-1)
  
set gxout shp
clear shp
set shp -ln -fmt 8 4 linem
set shpattr AUTHOR string JMA
set shpattr TYPE string grid contours
set shpattr DESC string surface temperature
d tsfc
</pre>
<p>Here is a slightly more complicated <a href="ftp://iges.org/grads/scripts/shp_demo2.gs">example script</a> that shows how to create a shapefile from a GrADS gridded data set (a GFS precipitation forecast), and then draws the contents of that shapefile as a stippled overlay (with three gray shades) on top of a contour plot of another variable, sea level pressure. The script generates a plot that looks like this:</p>
<p><img src="shp_demo2.png" alt="shp demo 2" /></p>
<p>Here is  another <a href="ftp://iges.org/grads/scripts/shp_demo1.gs">example script</a> that shows how to use the shapefile interface to draw U.S. climate divisions colorized according to the values of the Palmer Drought Severity Index (PDSI), and then overlays the 500mb height anomaly (from a GDS data set) for that same month and year. The script generates a plot that looks like this: </p>
<p><img src="shp_demo1.png" alt="pdsi" /></p>
<p>The final <a href="ftp://iges.org/grads/scripts/shp_demo3.gs">example script</a> uses shapefiles to draw state and county boundaries as well as roads on a radar image instead of drawing the GrADS map. Here is the result:</p>
<p><img src="shp_demo3.png" alt="shp demo 3" width="887" height="604" /></p>
<p> </p>
<p><em><strong><a name="caveat" id="caveat"></a>Caveat</strong><br />
</em>The <a href="http://www.esri.com/library/whitepapers/pdfs/shapefile.pdf">ESRI Shapefile Techncial Description</a> states that <em>"A polygon consists of one or more rings. A ring is a connected sequence of four or more points that form a closed, non-self-intersecting loop."</em>  A polygon with two rings would look something like a flat donut -- the area between the two rings forms the interior of the polygon, and the area enclosed by the inner ring is actually  in the exte [...]
<p>The rings of a polygon are referred to as its parts, and the number of parts in each polygon is included in the ouput of the <code><a href="gradcomdqshp.html">q shp</a></code> command. So it is possible to discover whether this limitation is affecting your plot. </p>
\ No newline at end of file
diff --git a/doc/supplibs.html b/doc/supplibs.html
index 11c75f3..e66dd73 100644
--- a/doc/supplibs.html
+++ b/doc/supplibs.html
@@ -36,7 +36,7 @@ quit </span></p>
   mkdir $HOME/supplibs/lib/pkgconfig</span><br>
 <span class="code">mkdir $HOME/supplibs/include<br>
 mkdir $HOME/supplibs/bin</span></p>
-<p>Move through the list of libraries in the table below, building them in order listed. Instructions for configuring and installing in the <span class="code">$HOME/supplibs</span> directory are given for each library. <span class="style1">If you are building on Mac OSX 10.6, set the environment variable CFLAGS to "-arch i386".</span> </p>
+<p>Move through the list of libraries in the table below, building them in order listed. Instructions for configuring and installing in the <span class="code">$HOME/supplibs</span> directory are given for each library. <span class="style1">If you are building on Mac OSX 10.6, set the environment variable CFLAGS to "-arch i386". For Mac OSX 10.7, I have used -arch x86_64. </span></p>
 <p>When you are done, unpack the GrADS source code tarball under $HOME. Change into the new GrADS directory you just created, and type<span class="code"> ./configure. </span>When the configuration is done, it will show a summary of which features have been enabled. Then type '<span class="code">make install</span>' and look for your executables in the ./bin directory. </p>
 <p>Good Luck!! </p>
 <table width="100%" border="0" cellpadding="4" cellspacing="4" class="plaintext">
@@ -57,7 +57,7 @@ mkdir $HOME/supplibs/bin</span></p>
       tar xvfz ./tarfiles/readline-5.0.tar.gz <br>
       mkdir readline<br>
       cd readline-5.0<br>
-      ./configure --disable-shared 
+      ./configure  
       --prefix=$HOME/supplibs/src/readline<br>
       make ; 
       make install<br>
@@ -76,7 +76,7 @@ mkdir $HOME/supplibs/bin</span></p>
       tar xvfz ./tarfiles/ncurses-5.7.tar.gz<br>
       mkdir ncurses<br>
       cd ncurses-5.7<br>
-      ./configure --disable-shared 
+      ./configure  
       --prefix=$HOME/supplibs/src/ncurses<br>
       make ;
       make install<br>
@@ -106,22 +106,22 @@ mkdir $HOME/supplibs/bin</span></p>
   </tr>
   <tr>
     <td valign="top" bgcolor="b8c8d7">libpng</td>
-    <td valign="top" bgcolor="b8c8d7">1.2.18</td>
+    <td valign="top" bgcolor="b8c8d7">1.5.12</td>
     <td valign="top" bgcolor="b8c8d7">PNG reference library. <br>
       Links:<br>      
-      <a href="http://www.libpng.org/pub/png/libpng.html" target="_parent">home page</a><br>      <a href="ftp://cola.gmu.edu/grads/Supplibs/2.1/src/libpng-1.2.18.tar.gz">local copy of source code</a><br></td>
+      <a href="http://www.libpng.org/pub/png/libpng.html" target="_parent">home page</a><br>      <a href="ftp://cola.gmu.edu/grads/Supplibs/2.1/src/libpng-1.5.12.tar.gz">local copy of source code</a><br></td>
     <td bgcolor="b8c8d7" class="code"><p>cd $HOME/supplibs/src/<br>
-      tar xvfz tarfiles/libpng-1.2.18.tar.gz<br>
+      tar xvfz tarfiles/libpng-1.5.12.tar.gz<br>
       mkdir libpng<br>
-      cd libpng-1.2.18<br>
-      ./configure --disable-shared 
+      cd libpng-1.5.12<br>
+      ./configure  
       --prefix=$HOME/supplibs/src/libpng<br>
       make ; 
       make install<br>
-      cp $HOME/supplibs/src/libpng/lib/libpng12.a $HOME/supplibs/lib<br>
-      mkdir $HOME/supplibs/include/libpng12<br>
-    cp $HOME/supplibs/src/libpng/include/libpng12/*.h $HOME/supplibs/include/libpng12<br>
-    cp $HOME/supplibs/src/libpng/lib/pkgconfig/libpng12.pc $HOME/supplibs/lib/pkgconfig</p>
+      cp $HOME/supplibs/src/libpng/lib/libpng15.a $HOME/supplibs/lib<br>
+      mkdir $HOME/supplibs/include/libpng15<br>
+    cp $HOME/supplibs/src/libpng/include/libpng15/*.h $HOME/supplibs/include/libpng15<br>
+    cp $HOME/supplibs/src/libpng/lib/pkgconfig/libpng15.pc $HOME/supplibs/lib/pkgconfig</p>
     <p><span class="style1">Note: The pkgconfig file is required for building cairo</span></p></td>
   </tr>
   <tr bgcolor="ccdceb">
@@ -158,7 +158,7 @@ mkdir $HOME/supplibs/bin</span></p>
       tar xvfz tarfiles/gd-2.0.34.tar.gz<br>
       mkdir gd<br>
       cd gd-2.0.34<br>
-      ./configure --disable-shared \<br>
+      ./configure  \<br>
       --with-png=$HOME/supplibs/src/libpng \<br>
       --with-jpeg=$HOME/supplibs/src/jpeg \<br>
       --prefix=$HOME/supplibs/src/gd<br>
@@ -179,7 +179,7 @@ mkdir $HOME/supplibs/bin</span></p>
       tar xvfz tarfiles/jasper-1.900.1.tar.gz<br>
       mkdir jasper<br>
       cd jasper-1.900.1<br>
-      ./configure --disable-shared 
+      ./configure  
       \<br>
       --prefix=$HOME/supplibs/src/jasper \<br>
       --with-jpeg=$HOME/supplibs/src/jpeg<br>
@@ -222,7 +222,7 @@ cd g2clib-1.4.0</p>
       tar xvfz tarfiles/szip-2.1.tar.gz<br>
       mkdir szip<br>
       cd szip-2.1<br>
-      ./configure --disable-shared --prefix=$HOME/supplibs/src/szip<br>
+      ./configure --prefix=$HOME/supplibs/src/szip<br>
       make ; 
       make install<br>
     cp $HOME/supplibs/src/szip/lib/libsz.a $HOME/supplibs/lib</p></td>
@@ -238,7 +238,7 @@ cd g2clib-1.4.0</p>
       tar xvfz ./tarfiles/udunits-1.11.7.tar.gz<br>
       ln -sf udunits-1.11.7 udunits<br>
       cd udunits/src/<br>
-        ./configure --disable-shared --prefix=$HOME/supplibs/src/udunits<br>
+        ./configure --prefix=$HOME/supplibs/src/udunits<br>
         make ;
         make install<br>
         cd ../<br>
@@ -256,7 +256,7 @@ cd g2clib-1.4.0</p>
       tar xvfz tarfiles/HDF4.2r3.tar.gz<br>
       mkdir hdf<br>
       cd HDF4.2r3<br>
-        ./configure --disable-netcdf --disable-shared --disable-fortran \<br>
+        ./configure --disable-netcdf  --disable-fortran \<br>
         --with-zlib=$HOME/supplibs/src/zlib \<br>
         --with-jpeg=$HOME/supplibs/src/jpeg \<br>
         --with-szip=$HOME/supplibs/src/szip \<br>
@@ -270,16 +270,16 @@ cd g2clib-1.4.0</p>
   </tr>
   <tr bgcolor="b8c8d7">
     <td valign="top" bgcolor="b8c8d7">hdf5</td>
-    <td valign="top" bgcolor="b8c8d7">1.8.7</td>
+    <td valign="top" bgcolor="b8c8d7">1.8.11</td>
     <td valign="top">(<span class="style1">GrADS 2.0.a7+</span>) <br>
       Hierarchical Data Format library, version 5. Requires: zlib, szip<br>
 Links:<br><a href="http://www.hdfgroup.org/HDF5/" target="_parent">home page</a><br>
-<a href="ftp://cola.gmu.edu/grads/Supplibs/2.1/src/hdf5-1.8.7.tar.gz">local copy of source code</a></td>
+<a href="ftp://cola.gmu.edu/grads/Supplibs/2.1/src/hdf5-1.8.11.tar.gz">local copy of source code</a></td>
     <td bgcolor="b8c8d7"><p class="code">cd $HOME/supplibs/src/<br>
-      tar xvfz tarfiles/hdf5-1.8.7.tar.gz<br>
+      tar xvfz tarfiles/hdf5-1.8.11.tar.gz<br>
       mkdir hdf5<br>
-      cd hdf5-1.8.7<br>
-      ./configure --disable-shared --disable-fortran \<br>
+      cd hdf5-1.8.11<br>
+      ./configure --disable-fortran \<br>
       --with-zlib=$HOME/supplibs/src/zlib \<br>
       --with-szlib=$HOME/supplibs/src/szip \<br>
       --prefix=$HOME/supplibs/src/hdf5<br>
@@ -303,7 +303,7 @@ Links:<br><a href="http://www.hdfgroup.org/HDF5/" target="_parent">home page</a>
       
       ./configure --without-ssl --without-libidn 
       --enable-static \<br>
-      --disable-shared --disable-ldap --prefix=$HOME/supplibs/src/curl<br>
+      --disable-ldap --prefix=$HOME/supplibs/src/curl<br>
       make ; 
       make install<br>
     cp $HOME/supplibs/src/curl/lib/libcurl.a $HOME/supplibs/lib<br>
@@ -311,28 +311,24 @@ cp $HOME/supplibs/src/curl/lib/pkgconfig/libcurl.pc $HOME/supplibs/lib/pkgconfig
   </tr>
   <tr bgcolor="ccdceb">
     <td valign="top" bgcolor="b8c8d7">netcdf</td>
-    <td valign="top" bgcolor="b8c8d7">4.1.3</td>
+    <td valign="top" bgcolor="b8c8d7">4.2.1.1</td>
     <td valign="top" bgcolor="b8c8d7">(<span class="style1">GrADS 2.0.a8+</span>) <br>
       Network Common Data Form library. <br>
       Requires hdf5, zlib, szip, curl. <br>
       Links:<br>      <a href="http://www.unidata.ucar.edu/software/netcdf/" target="_parent">home page</a><br>
-      <a href="ftp://cola.gmu.edu/grads/Supplibs/2.1/src/netcdf-4.1.3.tar.gz">local copy of source code</a></td>
+      <a href="ftp://cola.gmu.edu/grads/Supplibs/2.1/src/netcdf-4.2.1.1.tar.gz">local copy of source code</a></td>
     <td bgcolor="b8c8d7"><p class="code">cd $HOME/supplibs/src<br>
-      tar xvfz tarfiles/netcdf-4.1.3.tar.gz<br>
+      tar xvfz tarfiles/netcdf-4.2.1.1tar.gz<br>
       mkdir 
       netcdf<br>
-        cd netcdf-4.1.3</p>
+        cd netcdf-4.2.1.1</p>
       <p class="code"><span class="style1">Note: before running configure, set the following environment variables:<br>
-        setenv LIBS "-lsz -lm -lrt -lz"<br>
+        setenv LIBS "-lsz -lm -lrt -lz -ldl -lcurl"<br>
       setenv LDFLAGS -L$HOME/supplibs/lib<br>
       setenv CPPFLAGS -I$HOME/supplibs/include/hdf5</span><br>
         <br>
-        ./configure --disable-f77 --enable-netcdf-4 --enable-dap --disable-shared \<br>
-        --with-hdf5=$HOME/supplibs/src/hdf5 \<br>
-        --with-zlib=$HOME/supplibs/src/zlib \<br>
-        --with-szlib=$HOME/supplibs/src/szip \<br>
-        --with-curl=$HOME/supplibs/src/curl \<br>
-        --prefix=$HOME/supplibs/src/netcdf <br>
+      ./configure --disable-f77 --enable-netcdf-4 \<br>
+--enable-dap         --prefix=$HOME/supplibs/src/netcdf <br>
         make ;
         make install<br>
         cp $HOME/supplibs/src/netcdf/lib/libnetcdf.a $HOME/supplibs/lib<br>
@@ -357,7 +353,7 @@ unsetenv LDFLAGS<br>
       tar xvfz tarfiles/tiff-3.8.2.tar.gz<br>
       mkdir tiff<br>
       cd tiff-3.8.2<br>
-      ./configure --disable-shared 
+      ./configure  
       --prefix=$HOME/supplibs/src/tiff<br>
       make ; 
       make install<br>
@@ -379,7 +375,7 @@ unsetenv LDFLAGS<br>
       mkdir geotiff<br>
       cd libgeotiff-1.2.5<br>
       ./configure --enable-incode-epsg 
-      --enable-static --disable-shared \<br>
+      --enable-static  \<br>
       --with-libtiff=$HOME/supplibs/src/tiff \<br>
       --prefix=$HOME/supplibs/src/geotiff <br>
       make ; 
@@ -418,7 +414,7 @@ unsetenv LDFLAGS<br>
       tar xvfz tarfiles/pkgconfig-0.23.tar.gz<br>
       mkdir pkg-config<br>
       cd pkg-config-0.23<br>
-      ./configure --disable-shared --prefix=$HOME/supplibs/src/pkg-config<br>
+      ./configure --prefix=$HOME/supplibs/src/pkg-config<br>
       make  ; 
       make install<br>
       cp $HOME/supplibs/src/pkg-config/bin/pkg-config $HOME/supplibs/bin/<br>
@@ -440,7 +436,7 @@ unsetenv LDFLAGS<br>
       tar xvfz tarfiles/libxml2-2.6.16.tar.gz<br>
       mkdir libxml2<br>
       cd libxml2-2.6.16<br>
-      ./configure --disable-shared  --prefix=$HOME/supplibs/src/libxml2 \<br>
+      ./configure   --prefix=$HOME/supplibs/src/libxml2 \<br>
       --with-zlib=$HOME/supplibs/src/zlib \<br>
       --without-threads --without-iconv --without-iso8859x <br>
       make ; 
@@ -464,7 +460,7 @@ Links:<br>
       autoreconf. This is only necessary if curl is installed someplace else on your system without the special configure options outlined above for building curl. Alternatively, you can set the following environment vars:<br>
       setenv PKG_CONFIG $HOME/supplibs/bin/pkg-config<br>
 setenv PKG_CONFIG_PATH $HOME/supplibs/lib/pkgconfig</p>
-      <p class="code">./configure --disable-shared \<br>
+      <p class="code">./configure  \<br>
         --with-xml2=$HOME/supplibs/src/libxml2 \<br>
         --with-zlib=$HOME/supplibs/src/zlib \<br>
         --with-curl=$HOME/supplibs/src/curl \<br>
@@ -507,7 +503,7 @@ Links:<br>
       mkdir libXrender<br>
       cd libXrender-0.9.6</p>
       <p class="code style1">N.B. It may be necessary to unset the environment vars PGK_CONFIG and PKG_CONFIG_PATH before configuring libXrender. If so, be sure to reset them before continuing to build the remainder of the libraries.</p>
-      <p class="code">./configure --disable-shared --prefix=$HOME/supplibs/src/libXrender<br>
+      <p class="code">./configure --prefix=$HOME/supplibs/src/libXrender<br>
         make ;
         make install<br>
         cp $HOME/supplibs/src/libXrender/lib/libXrender.a $HOME/supplibs/lib<br>
@@ -515,89 +511,110 @@ Links:<br>
   </tr>
   <tr bgcolor="b8c8d7">
     <td valign="top" bgcolor="ccdceb">pixman</td>
-    <td valign="top" bgcolor="ccdceb">0.21.2</td>
+    <td valign="top" bgcolor="ccdceb">0.28.0</td>
     <td valign="top" bgcolor="ccdceb"><p>(<span class="style1">GrADS 2.1.a0+</span>)<br>
     A pixel manipulation library for <br>
     X and Cairo.<br>
     Links:<br>
     <a href="http://cgit.freedesktop.org/pixman/">home page</a><br>
-    <a href="ftp://cola.gmu.edu/grads/Supplibs/2.1/src/pixman-0.21.2.tar.gz">local copy of source code</a></p>    </td>
+    <a href="ftp://cola.gmu.edu/grads/Supplibs/2.1/src/pixman-0.28.0.tar.gz">local copy of source code</a></p>    </td>
     <td bgcolor="ccdceb"><p class="code">cd $HOME/supplibs/src<br>
-      tar xvfz tarfiles/pixman-0.21.2.tar.gz <br>
+      tar xvfz tarfiles/pixman-0.28.0.tar.gz <br>
       mkdir pixman<br>
-      cd pixman-0.21.2<br>
-      ./configure --disable-shared --prefix=$HOME/supplibs/src/pixman<br> 
+      cd pixman-0.28.0<br>
+      ./configure  --prefix=$HOME/supplibs/src/pixman<br> 
       make ; 
         make install<br>
         cp $HOME/supplibs/src/pixman/lib/libpixman-1.a $HOME/supplibs/lib<br>
-    cp $HOME/supplibs/src/pixman/lib/pkgconfig/pixman-1.pc $HOME/supplibs/lib/pkgconfig</p>    </td>
+    cp $HOME/supplibs/src/pixman/lib/pkgconfig/pixman-1.pc $HOME/supplibs/lib/pkgconfig<br>
+    <br>
+    mkdir $HOME/supplibs/include/pixman-1<br>
+    cp $HOME/supplibs/src/pixman/include/pixman-1/.h 
+    $HOME/supplibs/include/pixman-1/</p>    </td>
   </tr>
   <tr bgcolor="b8c8d7">
-    <td valign="top" bgcolor="b8c8d7">freetype</td>
-    <td valign="top" bgcolor="b8c8d7">2.4.4</td>
+    <td height="386" valign="top" bgcolor="b8c8d7">freetype</td>
+    <td valign="top" bgcolor="b8c8d7">2.4.10</td>
     <td valign="top" bgcolor="b8c8d7">(<span class="style1">GrADS 2.1.a0+</span>)<br>
 A software font engine.
 Required by Cairo. <br>
 Links:<br>
 <a href="http://www.freetype.org/">home page</a><br>
-<a href="ftp://cola.gmu.edu/grads/Supplibs/2.1/src/freetype-2.4.4.tar.gz">local copy of source code</a></td>
+<a href="ftp://cola.gmu.edu/grads/Supplibs/2.1/src/freetype-2.4.10.tar.gz">local copy of source code</a></td>
     <td bgcolor="b8c8d7"><p class="code">cd $HOME/supplibs/src<br>
-      tar xvfz tarfiles/freetype-2.4.3.tar.gz<br>
+      tar xvfz tarfiles/freetype-2.4.10.tar.gz<br>
       mkdir freetype<br>
-      cd freetype-2.4.3<br>
+      cd freetype-2.4.10<br>
         ./configure 
-        --disable-shared 
+         
         \<br>
         --without-fsspec 
         --without-fsref 
-        --without-ats \<br>
+        --without-ats --without-bzip2 \<br>
         --without-quickdraw-toolbox 
         --without-quickdraw-carbon \<br>
         --with-zlib=$HOME/supplibs/src/zlib \<br>
         --prefix=$HOME/supplibs/src/freetype<br>
         make ; 
         make install<br>
+        <br>
         cp $HOME/supplibs/src/freetype/lib/libfreetype.a $HOME/supplibs/lib<br>
-    cp $HOME/supplibs/src/freetype/lib/pkgconfig/freetype2.pc $HOME/supplibs/lib/pkgconfig</p>    </td>
+    cp $HOME/supplibs/src/freetype/lib/pkgconfig/freetype2.pc $HOME/supplibs/lib/pkgconfig<br>
+    <br>
+    mkdir -p $HOME/supplibs/include/freetype2/freetype/config<br>
+    cd $HOME/supplibs/include/freetype2    <br>
+    cp $HOME/supplibs/src/freetype/include/freetype/*.h .<br>
+    cd ./freetype
+<br>
+cp $HOME/supplibs/src/freetype/include/freetype2/freetype/*.h . <br>
+cd ./config <br>
+cp 
+$HOME/supplibs/src/freetype/include/freetype2/freetype/config/*.h . </td>
   </tr>
   <tr bgcolor="b8c8d7">
     <td valign="top" bgcolor="ccdceb">fontconfig</td>
-    <td valign="top" bgcolor="ccdceb">2.8.0</td>
+    <td valign="top" bgcolor="ccdceb">2.9.0</td>
     <td valign="top" bgcolor="ccdceb">(<span class="style1">GrADS 2.1.a0+</span>)<br>
       A library for configuring and customizing font access. 
 Required by Cairo. <br>
 Links:<br>
 <a href="http://www.freedesktop.org/wiki/Software/fontconfig">home page</a><br>
-<a href="ftp://cola.gmu.edu/grads/Supplibs/2.1/src/fontconfig-2.8.0.tar.gz">local copy of source code</a></td>
+<a href="ftp://cola.gmu.edu/grads/Supplibs/2.1/src/fontconfig-2.9.0.tar.gz">local copy of source code</a></td>
     <td bgcolor="ccdceb"><p class="code">cd $HOME/supplibs/src<br>
-      tar xvfz tarfiles/fontconfig-2.8.0.tar.gz<br>
+      tar xvfz tarfiles/fontconfig-2.9.0.tar.gz<br>
       mkdir fontconfig<br>
-      cd fontconfig-2.8.0<br>
-      ./configure --disable-shared --enable-libxml2 \<br>
+      cd fontconfig-2.9.0<br>
+      ./configure --enable-libxml2 \<br>
       --prefix=$HOME/supplibs/src/fontconfig \<br>
     --with-freetype-config=$HOME/supplibs/src/freetype/bin/freetype-config \<br>
     --with-add-fonts=/Library/Fonts,/System/Library/Fonts <span class="style1">(for mac)</span>   
       <br>
     --with-add-fonts=/usr/share/X11/fonts,/usr/share/fonts <span class="style1">(for unix)
     </span>
-    <p class="code style1">N.B. After configuration,  edit config.h to set USE_ICONV = 0<br>
-      I don't know of another way to tell it not to use libiconv.       
-      <p class="code">make ; make install<br> 
+    <p class="code"><span class="code style1">N.B. After configuration,  edit config.h to set USE_ICONV = 0<br>
+      I don't know of another way to tell it not to use libiconv.   </span>    
+        <br>
+    make ; make install<br>
+    <br> 
         cp $HOME/supplibs/src/fontconfig/lib/libfontconfig.a $HOME/supplibs/lib/<br>
-    cp $HOME/supplibs/src/fontconfig/lib/pkgconfig/fontconfig.pc $HOME/supplibs/lib/pkgconfig</td>
+    cp $HOME/supplibs/src/fontconfig/lib/pkgconfig/fontconfig.pc \ $HOME/supplibs/lib/pkgconfig      <br>
+    <br>
+    mkdir $HOME/supplibs/include/fontconfig<br>
+    cp $HOME/supplibs/src/fontconfig/include/fontconfig/*.h 
+    \ $HOME/supplibs/include/fontconfig <br></td>
   </tr>
   <tr bgcolor="b8c8d7">
     <td valign="top" bgcolor="b8c8d7">cairo</td>
-    <td valign="top" bgcolor="b8c8d7">1.10.2</td>
-    <td valign="top" bgcolor="b8c8d7">(<span class="style1">GrADS 2.1.a0+</span>)<br>
+    <td valign="top" bgcolor="b8c8d7">1.12.16</td>
+    <td valign="top" bgcolor="b8c8d7">(<span class="style1">GrADS 2.1.a1+</span>)<br>
 A 2D graphics library with support for multiple output devices. Requires pkgconfig, zlib, xml2, libpng, pixman, fontconfig, freetype, and Xrender.<br>
 Links:<br>
 <a href="http://www.cairographics.org/">home page</a><br>
-<a href="ftp://cola.gmu.edu/grads/Supplibs/2.1/src/cairo-1.10.2.tar.gz">local copy of source code</a></td>
+<a href="ftp://cola.gmu.edu/grads/Supplibs/2.1/src/cairo-1.12.16.tar.gz">local copy of source code</a></td>
     <td bgcolor="b8c8d7"><p class="code">cd $HOME/supplibs/src<br>
-      tar xvf tarfiles/cairo-1.10.2.tar.gz<br>
+      tar xvf tarfiles/cairo-1.12.16.tar.gz<br>
       mkdir cairo<br>
-      cd cairo-1.10.2<br>
+      cd cairo-1.12.16<br>
       ./configure --prefix=$HOME/supplibs/src/cairo \<br>
       --enable-xlib=yes \<br>
       --enable-xml=yes \<br>
diff --git a/doc/templates.html b/doc/templates.html
index 33bdbaa..b36e322 100644
--- a/doc/templates.html
+++ b/doc/templates.html
@@ -89,11 +89,15 @@ When specifying the initial time (e.g., NWP model output), use these substitutio
     <code>%in2   </code>initial 2 digit minute (leading zero if needed)<br>
 </ul>
 
-<a name="chsub"></a>Starting with version 1.9b4, a new template option has been added that allows 
-for any user-specified string substitution, instead of only date string substitution. 
-This is useful when none of the above template options match the time ranges in 
-the files you wish to aggregate, or if the files are located on different disk pathnames. 
-The syntax is as follows:
+<h3>Templating over ENSEMBLE</h3>
+<p>With the introduction of the extra grid dimension for ensembles in <span class="style1">version 2.0</span>, support was also added for file templating over E. The sole substitution template is <code>%e</code> and the substitution string is the ensemble name, which is provided in the EDEF entry in the descriptor file. Note that the ensemble names are limited to 15 characters -- keep this limit in mind when designing your data directory structure and file naming conventions (or use symb [...]
+  If your data set has an ensemble dimension, and you are using templating over T but not E (i.e., there is no %e in the DSET entry), then  all ensemble members are presumed to have identical time axes, and  all members must be contained in the data file for a given time. Templating over T but not E is not supported for  data sets in flat binary or GRIB1 formats. 
+<h3>String Substitution</h3>
+<p><a name="chsub"></a>The <code>%ch</code> template option, introduced in <span class="style1">version 1.9b4</span>, allows 
+  for <em>any</em> user-specified string substitution, not just date strings. 
+  This is useful when none of the above template options match the time ranges in 
+  the files you wish to aggregate, or if the files are located on different disk pathnames. 
+The syntax is as follows: </p>
 <ul>
   <code>%ch   </code>substitute string 
 </ul>
@@ -104,14 +108,9 @@ which will be substituted for <code>%ch</code> in the data file names for the
 time steps beginning with<br>
 t1 and ending with t2. The CHSUB descriptor file entries have the following syntax: 
 <ul>
-  <p><code>chsub  <em>t1</em>  <em>t2</em>  <em>string</em></code></p>
-  <p>   </p>
+  <p><code>CHSUB  <em>t1</em>  <em>t2</em>  <em>string</em></code></p>
 </ul>
-<h3>Templating over ENSEMBLE</h3>
-<p>In version 2.0, with the introduction of the extra grid dimension for ensembles, support was also added for file templating over E. The sole substitution template is <code>%e</code> and the substitution string is the ensemble name, which is provided in the EDEF entry in the descriptor file. Note that the ensemble names are limited to 15 characters -- keep this limit in mind when designing your data directory structure and file naming conventions (or use symbolic links to create short  [...]
-If your data set has an ensemble dimension, and you are using templating over T but not E (i.e., there is no %e in the DSET entry), then  all ensemble members are presumed to have identical time axes, and  all members must be contained in the data file for a given time. Templating over T but not E is not supported for  data sets in flat binary or GRIB1 formats. 
-<p>
-
+<p><span class="style1">Version 2.1.a3</span> adds a new feature to the string substitution template: the <code><em>string</em></code> provided in the <code>CHSUB</code> entry may  contain time-based template components. GrADS will do the <code>CHSUB</code> string substitution <em>before</em> the complete filename is  generated by resolving all the other template substitution components. An application of this strategy might be to merge a reanalyis and forecast into one seamless time ser [...]
 <h3>Examples</h3>
 <ol>
   <li>Here's a set of binary files spanning a single month, where each day's worth 
@@ -180,7 +179,17 @@ If your data set has an ensemble dimension, and you are using templating over T
    </code>
   so your DSET enry will look like this: <br>
   <code>   DSET ^MMOUT_DOMAIN1_%tm2</code><br>
-  <br></li>
+  <br>
+  </li>
+  <li>Here is an example of using different time template substitutions within a %ch string substitution. <br>
+   <code>
+      DSET /data/projects/ops/pub/%ch<br>
+      CHSUB 1    1898 das/Y%y4/M%m2/D%d2/GEOS.fp.asm.inst3_2d_smp_Nx.%y4%m2%d2_%h2%n2.V01.nc4<br>
+      CHSUB 1899 1909 forecast/Y2014/M10/D15/H06/GEOS.fp.fcst.inst3_2d_smp_Nx.20141015_06+%y4%m2%d2_%h2%n2.V01.nc4<br>
+      OPTIONS template<br>
+    </code>
+    <br>
+  </li>
 </ol>
 </body>
 </html>
diff --git a/doc/tutorial.html b/doc/tutorial.html
index 41508e1..047399e 100644
--- a/doc/tutorial.html
+++ b/doc/tutorial.html
@@ -1,374 +1 @@
-<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->
-
-<html>
-<head>
-<title>GrADS Tutorial</title>
-<link href="GrADS.css" rel="stylesheet" type="text/css">
-</head>
-<body bgcolor="e0f0ff" text="#000000">
-
-<h1>Tutorial (<a href="Tutorial_Espanol.doc">En Español</a>)</h1>
-<p>
-<h3>What is it?</h3>
-This document presents a brief tutorial for Brian Doty's <a
-href="http://grads.iges.org/grads">Grid
-Analysis and Display System (GrADS)</a>. The following sample
-session
-will give you a feeling for how to use the basic capabilities of
-GrADS. This sample session takes about 30 minutes to run through. Here is a copy of
-<p>
-
-<h3>Before you start:download the sample data</h3>
-You will need the following sample data files in order to go through
-this tutorial: 
-<p>
-<ul>
-<a href="ftp://cola.gmu.edu/grads/sprite/tutorial/model.ctl">
-<code>model.ctl   </code></a>GrADS descriptor file (0.7 kb) <br>
-<a href="ftp://cola.gmu.edu/grads/sprite/tutorial/model.grb">
-<code>model.grb   </code></a>GrADS (GRIB) data file (579 kb) <br>
-<a href="ftp://cola.gmu.edu/grads/sprite/tutorial/model.gmp">
-<code>model.gmp   </code></a>GrADS gribmap index file (4 kb) <br>
-</ul>
-
-<p>
-This data file is described by the data descriptor file
-<a href="ftp://cola.gmu.edu/grads/sprite/tutorial/model.ctl">
-<code>model.ctl</code></a>. You may want to look at this file before
-continuing.  The data descriptor file describes the actual data file,
-which in the case contains 5 days of global grids that are 72 x 46
-elements in size.<p> Please download these 3 files to a local
-directory before proceeding. 
-<p> 
-<h3>Sample Session</h3>
-<p>
-To start up GrADS, enter:
-<p>
-<dd><a href="gradcomdgrads.html"><code>grads</code></a> 
-  <p> If the <span class="code">grads</span> executable is not in your current 
-    directory, or if it is not in your PATH somewhere, you may need to enter the 
-    full pathname, ie: 
-  <p>
-<dd><code>/usr/homes/smith/grads/grads</code> 
-  <p>
-GrADS will prompt you with a landscape vs. portrait question;
-just press enter.  At this point a graphics output window should
-open on your console.  You may wish to move or resize this
-window. Keep in mind that you will be entering GrADS commands
-from the window where you first started GrADS -- this window will
-need to be made the 'active' window and you will not want to
-entirely cover that window with the graphics output window.
-<p>
-In the text window (where you started grads from), you should now
-see a prompt:  <code>ga-></code>    You will enter GrADS commands at this
-prompt and see the results displayed in the graphics output
-window.<p>
-
-The first command you will enter is:<p>
-
-<dd><code><a href="gradcomdopen.html">open</a> model.ctl</code><p>
-
-You may want to see what is in this file, so enter:<p>
-
-<dd><code><a href="gradcomdquery.html">query</a> file</code><p>
-
-One of the available variable is called <code>ps</code>, for surface pressure. 
-We can display this variable by entering:<p>
-
-<dd><code><a href="gradcomddisplay.html">d</a> ps</code><p>
-
-<code>d</code> is short for <a href="gradcomddisplay.html"><code>display</code></a>.   You
-will note that by default, GrADS
-will display an X, Y plot at the first time and at the lowest
-level in the data set.<p>
-<center><img src="tutorial_fig1.gif"></center><p><br>
-
-Now you will enter commands to alter the <a
-href="dimenv.html"><code>dimension environment</code></a>. 
-The <a href="gradcomddisplay.html"><code>display</code></a> command (and
-implicitly, the access,
-operation, and
-output of the data) will do things with respect to the current
-dimension environment.  You control the dimension environment 
-with the <code>set</code> command:
-
-<p>
-<ul>
-<code>
-<a href="gradcomdclear.html">clear</a>
-          </code>clears the display<br> 
-<code><a href="gradcomdsetlatlonlevtimeens.html">set lon</a> -90
-    </code>sets longitude to 90 degrees West<br> 
-<code><a href="gradcomdsetlatlonlevtimeens.html">set lat</a> 40
-     </code>sets latitude to 40 degrees North<br> 
-<code><a href="gradcomdsetlatlonlevtimeens.html">set lev</a> 500
-    </code>sets level to 500 mb<br>
-<code><a href="gradcomdsetlatlonlevtimeens.html">set t</a> 1
-        </code>sets time to first time step<br> 
-<code><a href="gradcomddisplay.html">d</a> z
-            </code>displays the variable 'z'<br>
-</ul>
-
-<p>
-In the above sequence of commands, we have set all four GrADS
-dimensions to a single value.  When we set a dimension to a
-single value, we say that dimension is "fixed".  Since all the
-dimensions are fixed, when we display a variable we get a single
-value, in this case the value at the location 90W, 40N, 500mb,
-and the 1st time in the data set.<p>
-
-If we now enter:<p>
-<ul>
-<code><a href="gradcomdsetlatlonlevtimeens.html">set lon</a> -180 0</code>             X is now a varying
-dimension<br>
-<code><a href="gradcomddisplay.html">d</a> z</code></ul><p>
-
-We have set the X dimension, or longitude, to vary.  We have done
-this by entering two values on the set command.  We now have one
-varying dimension (the other dimensions are still fixed), and
-when we display a variable we get a line graph, in this case a
-graph of 500mb Heights at 40N.<p>
-<center><img src="tutorial_fig2.gif"></center><p><br>
-Now enter:<p>
-<ul>
-<code><a href="gradcomdclear.html">clear</a><br>
-<a href="gradcomdsetlatlonlevtimeens.html"> set lat</a> 0 90<br> 
-<a href="gradcomddisplay.html">d</a> z</code></ul><p>
-
-We now have two varying dimensions, so by default we get a
-contour plot.  If we have 3 varying dimensions:<p>
-<ul>
-<code><a href="gradcomdclear.html">c</a><br>
-<a href="gradcomdsetlatlonlevtimeens.html"> set t</a> 1 5<br>
-<a href="gradcomddisplay.html">d</a> z</code></ul><p>
-
-we get an animation sequence, in this case through time.<p>
-
-Now enter:<p>
-<ul>
-<code><a href="gradcomdclear.html">clear</a><br>
-<a href="gradcomdsetlatlonlevtimeens.html"> set lon</a> -90<br>
-<a href="gradcomdsetlatlonlevtimeens.html">set lat</a> -90 90<br>
-<a href="gradcomdsetlatlonlevtimeens.html"> set lev</a> 1000 100<br>
-<a href="gradcomdsetlatlonlevtimeens.html">set t</a> 1<br>
-<a href="gradcomddisplay.html"> d</a> t<br>
-<a href="gradcomddisplay.html"> d</a> u</code></ul><p>
-
-In this case we have set the Y (latitude) and Z (level)
-dimensions to vary, so we get a vertical cross section.  We have
-also displayed two variables, which simply overlay each other. 
-You may display as many items as you desire overlaid before you
-enter the <code><a href="gradcomdclear.html">clear</a></code> command.<p>
-<center><img src="tutorial_fig3.gif"></center><p><br>
-Another example, in this case with X and T varying (Hovmoller
-plot):<p>
-<ul>
-<code><a href="gradcomdclear.html">c</a><br>
-<a href="gradcomdsetlatlonlevtimeens.html"> set lon</a> -180 0<br>
-<a href="gradcomdsetlatlonlevtimeens.html"> set lat</a> 40<br>
-<a href="gradcomdsetlatlonlevtimeens.html"> set lev</a> 500<br>
-<a href="gradcomdsetlatlonlevtimeens.html"> set t 1 5<br>
-<a href="gradcomddisplay.html"> d z</a></code></ul><p>
-<center><img src="tutorial_fig4.gif"></center><p><br>
-Now that you know how to select the portion of the data set to
-view, we will move on to the topic of operations on the data. 
-First, set the dimension environment to an Z, Y varying one:<p>
-<ul>
-<code><a href="gradcomdclear.html">clear</a><br>
-<a href="gradcomdsetlatlonlevtimeens.html"> set lon</a> -180 0<br>
-<a href="gradcomdsetlatlonlevtimeens.html"> set lat</a> 0 90<br>
-<a href="gradcomdsetlatlonlevtimeens.html"> set lev</a> 500 <br>
-<a href="gradcomdsetlatlonlevtimeens.html">set t</a> 1</code></ul><p>
-
-Now lets say that we want to see the temperature in Fahrenheit
-instead of Kelvin.  We can do the conversion by entering:<p>
-
-<dd><code><a href="gradcomddisplay.html">display</a> (t-273.16)*9/5+32</code><p>
-
-Any expression may be entered that involves the standard
-operators of +, -, *, and /, and which involves operands which
-may be constants, variables, or functions.  An example involving
-functions:<p>
-
-<ul>
-<code><a href="gradcomdclear.html">clear</a><br>
-<a href="gradcomddisplay.html">d</a> <a
-href="gradfuncsqrt.html">sqrt</a>(u*u+v*v)</code></ul><p>
-
-
-to calculate the magnitude of the wind.  A function is provided
-to do this calculation directly:<p>
-
-<dd><code><a href="gradcomddisplay.html">d</a> <a
-href="gradfuncmag.html">mag</a>(u,v)</code><p>
-<center><img src="tutorial_fig5.gif"></center><p><br>
-Another built in function is the averaging function:<p>
-<ul>
-<code><a href="gradcomdclear.html">clear</a><br>
-<a href="gradcomddisplay.html">d</a> <a
-href="gradfuncave.html">ave</a>(z,t=1,t=5)</code></ul><p>
-
-In this case we calculate the 5 day mean.  We can also remove the
-mean from the current field:<p>
-
-<dd><code><a href="gradcomddisplay.html">d</a> z - <a
-href="gradfuncave.html">ave</a>(z,t=1,t=5)</code><p>
-
-We can also take means over longitude to remove the zonal mean:<p>
-<ul>
-<code><a href="gradcomdclear.html">clear</a> d z-<a href="gradfuncave.html">ave</a>(z,x=1,x=72)<br>
-<a href="gradcomddisplay.html">d</a> z</code></ul><p>
-
-We can also perform time differencing:<p>
-<ul>
-<a href="gradcomdclear.html">clear</a><br>
-<a href="gradcomddisplay.html">d</a> z(t=2)-z(t=1)</code></ul><p>
-
-This computes the change between the two fields over 1 day.  We
-could have also done this calculation using an offset from the
-current time:<p>
-
-<dd><code><a href="gradcomddisplay.html">d</a> z(t+1) - z</code><p>
-
-The complete specification of a variable name is:<p>
-
-<dd><code>name.file(dim +|-|= value, ...)</code><p>
-
-If we had two files open, perhaps one with model output, the
-other with analyses, we could take the difference between the two
-fields by entering:<p>
-
-
-<dd><code><a href="gradcomddisplay.html">display</a> z.2 - z.1</code><p>
-
-Another built in function calculates horizontal relative
-vorticity via finite differencing:<p>
-<ul>
-<code><a href="gradcomdclear.html">clear</a><br>
-<a href="gradcomddisplay.html">d</a> <a
-href="gradfunchcurl.html">hcurl</a>(u,v)</code></ul><p>
-
-Yet another function takes a mass weighted vertical integral:<p>
-<ul>
-<code><a href="gradcomdclear.html">clear</a><br>
-<a href="gradcomddisplay.html">d</a> <a href="gradfuncvint.html">
-vint</a>(ps,q,275)</code></ul><p>
-
-Here we have calculated precipitable water in mm.<p>
-
-Now we will move on to the topic of controlling the graphics
-output.  So far, we have allowed GrADS to chose a default contour
-interval.  We can override this by:<p>
-
-<ul><code><a href="gradcomdclear.html">clear</a><br>
-<a href="gradcomdsetcint.html">set cint</a> 30<br>
-<a href="gradcomddisplay.html">d</a> z</code></ul><p>
-
-We can also control the contour color by:<p>
-<ul>
-<code><a href="gradcomdclear.html">clear</br>
-<a href="gradcomdsetccolor.html">set ccolor</a> 3<br>
-<a href="gradcomddisplay.html">d</a> z</code></ul><p>
-
-We can select alternate ways of displaying the data:<p>
-<ul>
-<code><a href="gradcomdclear.html">clear</a><br>
-<a href="gradcomdsetgxout.html">set gxout</a> shaded<br>
-<a href="gradcomddisplay.html">d</a> <a href="gradfunchcurl.html">
-hcurl</a>(u,v)</code></ul><p>
-
-This is not very smooth; we can apply a cubic smoother by
-entering:<p>
-<ul>
-<code><a href="gradcomdclear.html">clear</a><br>
-<a href="gradcomdsetcsmooth.html">set csmooth</a> on<br>
-<a href="gradcomddisplay.html">d</a> <a href="gradfunchcurl.html">
-hcurl</a>(u,v)</code></ul><p>
-<center><img src="tutorial_fig6.gif"></center><p><br>
-We can overlay different graphics types:<p>
-<ul>
-<code><a href="gradcomdsetgxout.html">set gxout</a> contour<br>
-<a href="gradcomdsetccolor.html">set ccolor</a> 0<br>
-<a href="gradcomdsetcint.html">set cint</a> 30<br>
-<a href="gradcomddisplay.html">d</a> z</code></ul><p>
-
-and we can annotate:<p>
-
-<dd><code><a href="gradcomddrawtitle.html">draw title</a> 500mb Heights and
-Vorticity</code><p>
-
-We can view wind vectors:<p>
-
-<ul>
-<code><a href="gradcomdclear.html">clear</a><br>
-<a href="gradcomdsetgxout.html">set gxout</a> vector<br>
-<a href="gradcomddisplay.html">d</a> u;v</code></ul><p>
-<center><img src="tutorial_fig7.gif"></center><p><br>
-Here we are displaying two expressions, the first for the U
-component of the vector; the 2nd the V component of the vector. 
-We can also colorize the vectors by specifying a 3rd field:<p>
-
-<dd><code><a href="gradcomddisplay.html">d</a> u;v;q</code><p>
-
-or maybe:<p>
-
-<dd><code><a href="gradcomddisplay.html">d</a> u;v;<a
-href="gradfunchcurl.html">hcurl</a>(u,v)</code><p>
-
-You may display pseudo vectors by displaying any field you want:<p>
-
-<ul>
-<code><a href="gradcomdclear.html">clear</a><br>
-<a href="gradcomddisplay.html">d</a> <a href="gradfuncmag.html">mag</a>(u,v) ;
-q*10000</code></ul><p>
-
-Here the U component is the wind speed; the V component is
-moisture.<p>
-
-We can also view streamlines (and colorize them):<p>
-<ul>
-<code><a href="gradcomdclear.html">clear</a><br>
-<a href="gradcomdsetgxout.html">set gxout</a> stream<br>
-<a href="gradcomddisplay.html">d</a> u;v;<a
-href="gradfunchcurl.html">hcurl</a>(u,v)</code></ul><p>
-
-Or we can display actual grid point values:<p>
-<ul>
-<code><a href="gradcomdclear.html">clear</a><br>
-<a href="gradcomdsetgxout.html">set gxout</a> grid<br>
-<a href="gradcomddisplay.html">d</a> u</code></ul><p>
-<center><img src="tutorial_fig8.gif"></center><p><br>
-We may wish to alter the map background:<p>
-<ul>
-<code><a href="gradcomdclear.html">clear</a><br> 
-<a href="gradcomdsetlatlonlevtimeens.html">set lon</a> -110 -70<br>
-<a href="gradcomdsetlatlonlevtimeens.html">set lat</a> 30 45<br>
-<a href="gradcomdsetmpdset.html">set mpdset</a> nam<br>
-<a href="gradcomdsetdigsize.html">set digsize</a> 0.2<br>
-<a href="gradcomdsetdignum.html">set dignum</a> 2<br> 
-<a href="gradcomddisplay.html">d</a> u</code></ul><p>
-
-To alter the projection:<p>
-<ul>
-<code><a href="gradcomdsetlatlonlevtimeens.html">set lon</a> -140 -40<br>
-<a href="gradcomdsetlatlonlevtimeens.html">set lat</a> 15 80 <br>
-<a href="gradcomdsetmpvals.html">set mpvals</a> -120 -75 25 65<br>
-<a href="gradcomdsetmproj.html">set mproj</a> nps<br>
-<a href="gradcomdsetgxout.html">set gxout</a> contour<br>
-<a href="gradcomdsetcint.html">set cint</a> 30<br> 
-<a href="gradcomddisplay.html">d</a> z</code></ul><p>
-
-In this case, we have told grads to access and operate on data
-from longitude 140W to 40W, and latitude 15N to 80N.  But we have
-told it to display a polar stereographic plot that contains the
-region bounded by 120W to 75W and 25N to 65N.  The extra plotting
-area is clipped by the map projection routine.<p>
-<center><img src="tutorial_fig9.gif"></center><p><br>
-This concludes the sample session.  At this point, you may wish
-to examine the data set further, or you may want to go through
-the GrADS documentation and try out the other options described
-there.
-
-</body>
-</html>
-
+<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->

<html>
<head>
<title>GrADS Tutorial</title>
<link href="GrADS.css" rel="stylesheet" type="text/css">
</head>
<body bgcolor="e0f0ff" text="#000000">

<h1>Tutorial (<a href="Tutorial_Espanol.doc">En Español</a>)</h1>
<p>
<h3>What is it?</h3>
This document presents a brief tutorial for Brian Doty's <a
href="http://grads.iges.org/grads">Grid
Analysis and Display System (GrADS)</a>. The following sample
session
will give you a feeling for how to use the basic capabilities of
GrADS. This sample session takes about 30 minutes to run through. Here is a copy of
<p>

<h3>Before you start:download the sample data</h3>
You will need the following sample data files in order to go through
this tutorial: 
<p>
<ul>
<a href="ftp://grads.iges.org/grads/sprite/tutorial/model.ctl">
<code>model.ctl   </code></a>GrADS descriptor file (0.7 kb) <br>
<a href="ftp://grads.iges.org/grads/sprite/tutorial/model.grb">
<code>model.grb   </code></a>GrADS (GRIB) data file (579 kb) <br>
<a href="ftp://grads.iges.org/grads/sprite/tutorial/model.gmp">
<code>model.gmp   </code></a>GrADS gribmap index file (4 kb) <br>
</ul>

<p>
This data file is described by the data descriptor file
<a href="ftp://grads.iges.org/grads/sprite/tutorial/model.ctl">
<code>model.ctl</code></a>. You may want to look at this file before
continuing.  The data descriptor file describes the actual data file,
which in the case contains 5 days of global grids that are 72 x 46
elements in size.<p> Please download these 3 files to a local
directory before proceeding. 
<p> 
<h3>Sample Session</h3>
<p>
To start up GrADS, enter:
<p>
<dd><a href="gradcomdgrads.html"><code>grads</code></a> 
  <p> If the <span class="code">grads</span> executable is not in your current 
    directory, or if it is not in your PATH somewhere, you may need to enter the 
    full pathname, ie: 
  <p>
<dd><code>/usr/homes/smith/grads/grads</code> 
  <p>
GrADS will prompt you with a landscape vs. portrait question;
just press enter.  At this point a graphics output window should
open on your console.  You may wish to move or resize this
window. Keep in mind that you will be entering GrADS commands
from the window where you first started GrADS -- this window will
need to be made the 'active' window and you will not want to
entirely cover that window with the graphics output window.
<p>
In the text window (where you started grads from), you should now
see a prompt:  <code>ga-></code>    You will enter GrADS commands at this
prompt and see the results displayed in the graphics output
window.<p>

The first command you will enter is:<p>

<dd><code><a href="gradcomdopen.html">open</a> model.ctl</code><p>

You may want to see what is in this file, so enter:<p>

<dd><code><a href="gradcomdquery.html">query</a> file</code><p>

One of the available variable is called <code>ps</code>, for surface pressure. 
We can display this variable by entering:<p>

<dd><code><a href="gradcomddisplay.html">d</a> ps</code><p>

<code>d</code> is short for <a href="gradcomddisplay.html"><code>display</code></a>.   You
will note that by default, GrADS
will display an X, Y plot at the first time and at the lowest
level in the data set.<p>
<center><img src="tutorial_fig1.gif"></center><p><br>

Now you will enter commands to alter the <a
href="dimenv.html"><code>dimension environment</code></a>. 
The <a href="gradcomddisplay.html"><code>display</code></a> command (and
implicitly, the access,
operation, and
output of the data) will do things with respect to the current
dimension environment.  You control the dimension environment 
with the <code>set</code> command:

<p>
<ul>
<code>
<a href="gradcomdclear.html">clear</a>
          </code>clears the display<br> 
<code><a href="gradcomdsetlatlonlevtimeens.html">set lon</a> -90
    </code>sets longitude to 90 degrees West<br> 
<code><a href="gradcomdsetlatlonlevtimeens.html">set lat</a> 40
     </code>sets latitude to 40 degrees North<br> 
<code><a href="gradcomdsetlatlonlevtimeens.html">set lev</a> 500
    </code>sets level to 500 mb<br>
<code><a href="gradcomdsetlatlonlevtimeens.html">set t</a> 1
        </code>sets time to first time step<br> 
<code><a href="gradcomddisplay.html">d</a> z
            </code>displays the variable 'z'<br>
</ul>

<p>
In the above sequence of commands, we have set all four GrADS
dimensions to a single value.  When we set a dimension to a
single value, we say that dimension is "fixed".  Since all the
dimensions are fixed, when we display a variable we get a single
value, in this case the value at the location 90W, 40N, 500mb,
and the 1st time in the data set.<p>

If we now enter:<p>
<ul>
<code><a href="gradcomdsetlatlonlevtimeens.html">set lon</a> -180 0</code>             X is now a varying
dimension<br>
<code><a href="gradcomddisplay.html">d</a> z</code></ul><p>

We have set the X dimension, or longitude, to vary.  We have done
this by entering two values on the set command.  We now have one
varying dimension (the other dimensions are still fixed), and
when we display a variable we get a line graph, in this case a
graph of 500mb Heights at 40N.<p>
<center><img src="tutorial_fig2.gif"></center><p><br>
Now enter:<p>
<ul>
<code><a href="gradcomdclear.html">clear</a><br>
<a href="gradcomdsetlatlonlevtimeens.html"> set lat</a> 0 90<br> 
<a href="gradcomddisplay.html">d</a> z</code></ul><p>

We now have two varying dimensions, so by default we get a
contour plot.  If we have 3 varying dimensions:<p>
<ul>
<code><a href="gradcomdclear.html">c</a><br>
<a href="gradcomdsetlatlonlevtimeens.html"> set t</a> 1 5<br>
<a href="gradcomddisplay.html">d</a> z</code></ul><p>

we get an animation sequence, in this case through time.<p>

Now enter:<p>
<ul>
<code><a href="gradcomdclear.html">clear</a><br>
<a href="gradcomdsetlatlonlevtimeens.html"> set lon</a> -90<br>
<a href="gradcomdsetlatlonlevtimeens.html">set lat</a> -90 90<br>
<a href="gradcomdsetlatlonlevtimeens.html"> set lev</a> 1000 100<br>
<a href="gradcomdsetlatlonlevtimeens.html">set t</a> 1<br>
<a href="gradcomddisplay.html"> d</a> t<br>
<a href="gradcomddisplay.html"> d</a> u</code></ul><p>

In this case we have set the Y (latitude) and Z (level)
dimensions to vary, so we get a vertical cross section.  We have
also displayed two variables, which simply overlay each other. 
You may display as many items as you desire overlaid before you
enter the <code><a href="gradcomdclear.html">clear</a></code> command.<p>
<center><img src="tutorial_fig3.gif"></center><p><br>
Another example, in this case with X and T varying (Hovmoller
plot):<p>
<ul>
<code><a href="gradcomdclear.html">c</a><br>
<a href="gradcomdsetlatlonlevtimeens.html"> set lon</a> -180 0<br>
<a href="gradcomdsetlatlonlevtimeens.html"> set lat</a> 40<br>
<a href="gradcomdsetlatlonlevtimeens.html"> set lev</a> 500<br>
<a href="gradcomdsetlatlonlevtimeens.html"> set t 1 5<br>
<a href="gradcomddisplay.html"> d z</a></code></ul><p>
<center><img src="tutorial_fig4.gif"></center><p><br>
Now that you know how to select the portion of the data set to
view, we will move on to the topic of operations on the data. 
First, set the dimension environment to an Z, Y varying one:<p>
<ul>
<code><a href="gradcomdclear.html">clear</a><br>
<a href="gradcomdsetlatlonlevtimeens.html"> set lon</a> -180 0<br>
<a href="gradcomdsetlatlonlevtimeens.html"> set lat</a> 0 90<br>
<a href="gradcomdsetlatlonlevtimeens.html"> set lev</a> 500 <br>
<a href="gradcomdsetlatlonlevtimeens.html">set t</a> 1</code></ul><p>

Now lets say that we want to see the temperature in Fahrenheit
instead of Kelvin.  We can do the conversion by entering:<p>

<dd><code><a href="gradcomddisplay.html">display</a> (t-273.16)*9/5+32</code><p>

Any expression may be entered that involves the standard
operators of +, -, *, and /, and which involves operands which
may be constants, variables, or functions.  An example involving
functions:<p>

<ul>
<code><a href="gradcomdclear.html">clear</a><br>
<a href="gradcomddisplay.html">d</a> <a
href="gradfuncsqrt.html">sqrt</a>(u*u+v*v)</code></ul><p>


to calculate the magnitude of the wind.  A function is provided
to do this calculation directly:<p>

<dd><code><a href="gradcomddisplay.html">d</a> <a
href="gradfuncmag.html">mag</a>(u,v)</code><p>
<center><img src="tutorial_fig5.gif"></center><p><br>
Another built in function is the averaging function:<p>
<ul>
<code><a href="gradcomdclear.html">clear</a><br>
<a href="gradcomddisplay.html">d</a> <a
href="gradfuncave.html">ave</a>(z,t=1,t=5)</code></ul><p>

In this case we calculate the 5 day mean.  We can also remove the
mean from the current field:<p>

<dd><code><a href="gradcomddisplay.html">d</a> z - <a
href="gradfuncave.html">ave</a>(z,t=1,t=5)</code><p>

We can also take means over longitude to remove the zonal mean:<p>
<ul>
<code><a href="gradcomdclear.html">clear</a> d z-<a href="gradfuncave.html">ave</a>(z,x=1,x=72)<br>
<a href="gradcomddisplay.html">d</a> z</code></ul><p>

We can also perform time differencing:<p>
<ul>
<a href="gradcomdclear.html">clear</a><br>
<a href="gradcomddisplay.html">d</a> z(t=2)-z(t=1)</code></ul><p>

This computes the change between the two fields over 1 day.  We
could have also done this calculation using an offset from the
current time:<p>

<dd><code><a href="gradcomddisplay.html">d</a> z(t+1) - z</code><p>

The complete specification of a variable name is:<p>

<dd><code>name.file(dim +|-|= value, ...)</code><p>

If we had two files open, perhaps one with model output, the
other with analyses, we could take the difference between the two
fields by entering:<p>


<dd><code><a href="gradcomddisplay.html">display</a> z.2 - z.1</code><p>

Another built in function calculates horizontal relative
vorticity via finite differencing:<p>
<ul>
<code><a href="gradcomdclear.html">clear</a><br>
<a href="gradcomddisplay.html">d</a> <a
href="gradfunchcurl.html">hcurl</a>(u,v)</code></ul><p>

Yet another function takes a mass weighted vertical integral:<p>
<ul>
<code><a href="gradcomdclear.html">clear</a><br>
<a href="gradcomddisplay.html">d</a> <a href="gradfuncvint.html">
vint</a>(ps,q,275)</code></ul><p>

Here we have calculated precipitable water in mm.<p>

Now we will move on to the topic of controlling the graphics
output.  So far, we have allowed GrADS to chose a default contour
interval.  We can override this by:<p>

<ul><code><a href="gradcomdclear.html">clear</a><br>
<a href="gradcomdsetcint.html">set cint</a> 30<br>
<a href="gradcomddisplay.html">d</a> z</code></ul><p>

We can also control the contour color by:<p>
<ul>
<code><a href="gradcomdclear.html">clear</br>
<a href="gradcomdsetccolor.html">set ccolor</a> 3<br>
<a href="gradcomddisplay.html">d</a> z</code></ul><p>

We can select alternate ways of displaying the data:<p>
<ul>
<code><a href="gradcomdclear.html">clear</a><br>
<a href="gradcomdsetgxout.html">set gxout</a> shaded<br>
<a href="gradcomddisplay.html">d</a> <a href="gradfunchcurl.html">
hcurl</a>(u,v)</code></ul><p>

This is not very smooth; we can apply a cubic smoother by
entering:<p>
<ul>
<code><a href="gradcomdclear.html">clear</a><br>
<a href="gradcomdsetcsmooth.html">set csmooth</a> on<br>
<a href="gradcomddisplay.html">d</a> <a href="gradfunchcurl.html">
hcurl</a>(u,v)</code></ul><p>
<center><img src="tutorial_fig6.gif"></center><p><br>
We can overlay different graphics types:<p>
<ul>
<code><a href="gradcomdsetgxout.html">set gxout</a> contour<br>
<a href="gradcomdsetccolor.html">set ccolor</a> 0<br>
<a href="gradcomdsetcint.html">set cint</a> 30<br>
<a href="gradcomddisplay.html">d</a> z</code></ul><p>

and we can annotate:<p>

<dd><code><a href="gradcomddrawtitle.html">draw title</a> 500mb Heights and
Vorticity</code><p>

We can view wind vectors:<p>

<ul>
<code><a href="gradcomdclear.html">clear</a><br>
<a href="gradcomdsetgxout.html">set gxout</a> vector<br>
<a href="gradcomddisplay.html">d</a> u;v</code></ul><p>
<center><img src="tutorial_fig7.gif"></center><p><br>
Here we are displaying two expressions, the first for the U
component of the vector; the 2nd the V component of the vector. 
We can also colorize the vectors by specifying a 3rd field:<p>

<dd><code><a href="gradcomddisplay.html">d</a> u;v;q</code><p>

or maybe:<p>

<dd><code><a href="gradcomddisplay.html">d</a> u;v;<a
href="gradfunchcurl.html">hcurl</a>(u,v)</code><p>

You may display pseudo vectors by displaying any field you want:<p>

<ul>
<code><a href="gradcomdclear.html">clear</a><br>
<a href="gradcomddisplay.html">d</a> <a href="gradfuncmag.html">mag</a>(u,v) ;
q*10000</code></ul><p>

Here the U component is the wind speed; the V component is
moisture.<p>

We can also view streamlines (and colorize them):<p>
<ul>
<code><a href="gradcomdclear.html">clear</a><br>
<a href="gradcomdsetgxout.html">set gxout</a> stream<br>
<a href="gradcomddisplay.html">d</a> u;v;<a
href="gradfunchcurl.html">hcurl</a>(u,v)</code></ul><p>

Or we can display actual grid point values:<p>
<ul>
<code><a href="gradcomdclear.html">clear</a><br>
<a href="gradcomdsetgxout.html">set gxout</a> grid<br>
<a href="gradcomddisplay.html">d</a> u</code></ul><p>
<center><img src="tutorial_fig8.gif"></center><p><br>
We may wish to alter the map background:<p>
<ul>
<code><a href="gradcomdclear.html">clear</a><br> 
<a href="gradcomdsetlatlonlevtimeens.html">set lon</a> -110 -70<br>
<a href="gradcomdsetlatlonlevtimeens.html">set lat</a> 30 45<br>
<a href="gradcomdsetmpdset.html">set mpdset</a> nam<br>
<a href="gradcomdsetdigsize.html">set digsize</a> 0.2<br>
<a href="gradcomdsetdignum.html">set dignum</a> 2<br> 
<a href="gradcomddisplay.html">d</a> u</code></ul><p>

To alter the projection:<p>
<ul>
<code><a href="gradcomdsetlatlonlevtimeens.html">set lon</a> -140 -40<br>
<a href="gradcomdsetlatlonlevtimeens.html">set lat</a> 15 80 <br>
<a href="gradcomdsetmpvals.html">set mpvals</a> -120 -75 25 65<br>
<a href="gradcomdsetmproj.html">set mproj</a> nps<br>
<a href="gradcomdsetgxout.html">set gxout</a> contour<br>
<a href="gradcomdsetcint.html">set cint</a> 30<br> 
<a href="gradcomddisplay.html">d</a> z</code></ul><p>

In this case, we have told grads to access and operate on data
from longitude 140W to 40W, and latitude 15N to 80N.  But we have
told it to display a polar stereographic plot that contains the
region bounded by 120W to 75W and 25N to 65N.  The extra plotting
area is clipped by the map projection routine.<p>
<center><img src="tutorial_fig9.gif"></center><p><br>
This concludes the sample session.  At this point, you may wish
to examine the data set further, or you may want to go through
the GrADS documentation and try out the other options described
there.

</body>
</html>

\ No newline at end of file
diff --git a/doc/tutorial_fig9.png b/doc/tutorial_fig9.png
new file mode 100644
index 0000000..6e19cd9
Binary files /dev/null and b/doc/tutorial_fig9.png differ
diff --git a/src/Makefile.am b/src/Makefile.am
index d14fa5b..d156894 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -9,15 +9,16 @@
 #
 
 # Targets that will built by "make all"
+#			 xgrads 
 bin_PROGRAMS	       = grads \
-		         gribmap gxeps gxps stnmap wgrib gribscan bufrscan \
+		         gribmap stnmap wgrib gribscan bufrscan \
 			 $(extra_utils)
 
 # Targets that will not always be built
-EXTRA_PROGRAMS	       = gxtran grib2scan
+EXTRA_PROGRAMS	       = grib2scan
 
 # Convenience target
-utils: bufrscan gribscan gribmap gxeps gxps stnmap wgrib $(extra_utils)
+utils: bufrscan gribscan gribmap stnmap wgrib $(extra_utils)
 
 ######################################################################
 #
@@ -32,27 +33,25 @@ supp_lib_dir		= $(SUPPLIBS)/lib
 LDADD			= -L$(supp_lib_dir) 
 INCLUDES		= $(readline_inc) $(printim_inc) $(grib2_inc) $(gui_inc) $(nc_inc) \
 			  $(hdf_inc) $(hdf5_inc) $(geotiff_inc) $(shp_inc) $(gadap_inc) \
-                          $(X_CFLAGS) $(XAW_CFLAGS) $(GD_CFLAGS) $(HDF4_CFLAGS)
+                          $(X_CFLAGS) $(XAW_CFLAGS) $(GD_CFLAGS) $(HDF4_CFLAGS) $(cairo_inc)
 
 # Settings used for all GrADS binaries
-common_ldadd            = $(LDADD) $(X_LIBS) $(host_ldadd) -lX11
+common_ldadd            = $(LDADD) $(X_LIBS) $(host_ldadd) -lX11 -lXext
 
 ######################################################################
 #
 # Headers and data
 #
 
-# Headers must be listed here to be included in the distribution.  The
-# "noinst_" prefix prevents "make install" from trying to do anything
-# with them
-hdr_core            = gagmap.h grads.h gs.h gatypes.h \
-		      gvt.h gx.h gxmap.h wx.h
+# Headers must be listed here to be included in the distribution.
+# The "noinst_" prefix prevents "make install" from trying to do anything with them
+hdr_core            = gagmap.h grads.h gs.h gatypes.h gvt.h gx.h gxmap.h wx.h
 hdr_bufr	    = gabufr.h
 hdr_x11		    = gx.h bitmaps.h
 hdr_sdf             = gasdf.h gasdf_std_time.h 
 hdr_gui		    = gagui.h
-hdr_png             = mtables.c
-noinst_HEADERS	    = $(hdr_core) $(hdr_x11) $(hdr_sdf) $(hdr_png) $(hdr_gui) $(hdr_bufr)
+hdr_cairo           = gxC.h
+noinst_HEADERS	    = $(hdr_core) $(hdr_x11) $(hdr_sdf) $(hdr_gui) $(hdr_bufr) $(hdr_cairo)
 
 # Get rid of buildinfo.h on "make distclean"
 DISTCLEANFILES	       = buildinfo.h
@@ -81,20 +80,31 @@ endif
 grads_SOURCES          = grads.c gxsubs.c gxmeta.c gxchpl.c gxcntr.c gxstrm.c \
 			 gxwmap.c gxshad.c gxshad2.c gaexpr.c gafunc.c gautil.c gagx.c \
 			 gscrpt.c gamach.c bufrstn.c gabufr.c gabufrtbl.c \
-			 gxX.c gxdxwd.c galloc.c $(src_gui) $(src_gadap) \
-                         gaddes.c gaio.c gacfg.c gauser.c gasdf.c gatxt.c
+			 gxdxwd.c galloc.c $(src_gui) $(src_gadap) \
+                         gaddes.c gaio.c gacfg.c gauser.c gasdf.c gatxt.c gxX.c gxC.c \
+                         gxprint.c 
+
+#xgrads_SOURCES         = grads.c gxsubs.c gxmeta.c gxchpl.c gxcntr.c gxstrm.c \
+#			 gxwmap.c gxshad.c gxshad2.c gaexpr.c gafunc.c gautil.c gagx.c \
+#			 gscrpt.c gamach.c bufrstn.c gabufr.c gabufrtbl.c \
+#			 gxdxwd.c galloc.c $(src_gui) $(src_gadap) \
+#                        gaddes.c gaio.c gacfg.c gauser.c gasdf.c gatxt.c gxX11.c \
+#			 gxprintGD.c gxGD.c 
 
 # Sources that will not always be compiled
 # Since gradsc is the only GrADS binary that is not conditionally compiled,
 # any source file that we want to go in the distribution must be listed.
-#EXTRA_grads_SOURCES    = gagmap.c gagui.c gsgui.c gxhpng.c dodstn.c
 EXTRA_grads_SOURCES    = gagmap.c gagui.c gsgui.c dodstn.c
 
 
 # libraries needed 
 grads_LDADD	       = $(common_ldadd) $(readline_libs) $(printim_libs) \
 			 $(grib2_libs) $(hdf_libs) $(hdf5_libs) $(nc_libs) \
-			 $(gui_libs) $(geotiff_libs) $(shp_libs) $(dap_libs)
+			 $(gui_libs) $(geotiff_libs) $(shp_libs) $(dap_libs) $(cairo_libs)
+
+#xgrads_LDADD	       = $(common_ldadd) $(readline_libs) $(printim_libs) \
+#			 $(grib2_libs) $(hdf_libs) $(hdf5_libs) $(nc_libs) \
+#			 $(gui_libs) $(geotiff_libs) $(shp_libs) $(dap_libs)
 
 # Custom compilation for object files specific to this GrADS binary
 COMPILE_C = $(COMPILE) 
@@ -108,8 +118,10 @@ COMPILE_C = $(COMPILE)
 # If gadap is enabled, use C++ linker instead of C linker
 if USEGADAP
 grads_LINK          = $(CXX) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
+#xgrads_LINK          = $(CXX) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
 else
 grads_LINK          = $(CC) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
+#xgrads_LINK          = $(CC) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
 endif
 
 # Object files that should not be reused by the other GrADS binaries,
@@ -132,9 +144,6 @@ gaddes.sa.o: $(srcdir)/gaddes.c
 gautil.sa.o: $(srcdir)/gautil.c
 	$(COMPILE) -DSTNDALN -o gautil.sa.o -c $(srcdir)/gautil.c
 
-gxmeta.sa.o: $(srcdir)/gxmeta.c
-	$(COMPILE) -DSTNDALN -o gxmeta.sa.o -c $(srcdir)/gxmeta.c
-
 ##############################################################
 #
 # stnmap
@@ -157,20 +166,6 @@ wgrib_SOURCES	       = wgrib.c
 
 ##############################################################
 #
-# gxps
-#
-gxps_SOURCES	       = gxps.c
-gxeps_SOURCES	       = gxeps.c
-
-##############################################################
-#
-# gxtran
-#
-gxtran_SOURCES	       = gxtran.c gxsubs.c gxchpl.c gxX.c gxdxwd.c galloc.c 
-gxtran_LDADD	       = gxmeta.sa.o $(LDADD) $(X_LIBS) $(printim_libs) -lX11
-
-##############################################################
-#
 # gribscan
 #
 gribscan_SOURCES       = gribscan.c gamach.c galloc.c
diff --git a/src/Makefile.in b/src/Makefile.in
index 97b0fff..1060d6c 100644
--- a/src/Makefile.in
+++ b/src/Makefile.in
@@ -44,10 +44,10 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-bin_PROGRAMS = grads$(EXEEXT) gribmap$(EXEEXT) gxeps$(EXEEXT) \
-	gxps$(EXEEXT) stnmap$(EXEEXT) wgrib$(EXEEXT) gribscan$(EXEEXT) \
-	bufrscan$(EXEEXT) $(am__EXEEXT_1)
-EXTRA_PROGRAMS = gxtran$(EXEEXT) grib2scan$(EXEEXT)
+bin_PROGRAMS = grads$(EXEEXT) gribmap$(EXEEXT) stnmap$(EXEEXT) \
+	wgrib$(EXEEXT) gribscan$(EXEEXT) bufrscan$(EXEEXT) \
+	$(am__EXEEXT_1)
+EXTRA_PROGRAMS = grib2scan$(EXEEXT)
 subdir = src
 DIST_COMMON = $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in $(srcdir)/config.h.in
@@ -77,8 +77,9 @@ bufrscan_DEPENDENCIES =
 am__grads_SOURCES_DIST = grads.c gxsubs.c gxmeta.c gxchpl.c gxcntr.c \
 	gxstrm.c gxwmap.c gxshad.c gxshad2.c gaexpr.c gafunc.c \
 	gautil.c gagx.c gscrpt.c gamach.c bufrstn.c gabufr.c \
-	gabufrtbl.c gxX.c gxdxwd.c galloc.c gagui.c gsgui.c dodstn.c \
-	gaddes.c gaio.c gacfg.c gauser.c gasdf.c gatxt.c
+	gabufrtbl.c gxdxwd.c galloc.c gagui.c gsgui.c dodstn.c \
+	gaddes.c gaio.c gacfg.c gauser.c gasdf.c gatxt.c gxX.c gxC.c \
+	gxprint.c
 @USEGUI_TRUE at am__objects_1 = gagui.$(OBJEXT) gsgui.$(OBJEXT)
 @USEGADAP_TRUE at am__objects_2 = dodstn.$(OBJEXT)
 am_grads_OBJECTS = grads.$(OBJEXT) gxsubs.$(OBJEXT) gxmeta.$(OBJEXT) \
@@ -87,10 +88,10 @@ am_grads_OBJECTS = grads.$(OBJEXT) gxsubs.$(OBJEXT) gxmeta.$(OBJEXT) \
 	gaexpr.$(OBJEXT) gafunc.$(OBJEXT) gautil.$(OBJEXT) \
 	gagx.$(OBJEXT) gscrpt.$(OBJEXT) gamach.$(OBJEXT) \
 	bufrstn.$(OBJEXT) gabufr.$(OBJEXT) gabufrtbl.$(OBJEXT) \
-	gxX.$(OBJEXT) gxdxwd.$(OBJEXT) galloc.$(OBJEXT) \
-	$(am__objects_1) $(am__objects_2) gaddes.$(OBJEXT) \
-	gaio.$(OBJEXT) gacfg.$(OBJEXT) gauser.$(OBJEXT) \
-	gasdf.$(OBJEXT) gatxt.$(OBJEXT)
+	gxdxwd.$(OBJEXT) galloc.$(OBJEXT) $(am__objects_1) \
+	$(am__objects_2) gaddes.$(OBJEXT) gaio.$(OBJEXT) \
+	gacfg.$(OBJEXT) gauser.$(OBJEXT) gasdf.$(OBJEXT) \
+	gatxt.$(OBJEXT) gxX.$(OBJEXT) gxC.$(OBJEXT) gxprint.$(OBJEXT)
 grads_OBJECTS = $(am_grads_OBJECTS)
 am__DEPENDENCIES_1 =
 am__DEPENDENCIES_2 = $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \
@@ -100,7 +101,7 @@ grads_DEPENDENCIES = $(am__DEPENDENCIES_2) $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \
-	$(am__DEPENDENCIES_1)
+	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1)
 am_grib2scan_OBJECTS = grib2scan.$(OBJEXT) gamach.$(OBJEXT) \
 	galloc.$(OBJEXT)
 grib2scan_OBJECTS = $(am_grib2scan_OBJECTS)
@@ -117,19 +118,6 @@ am_gribscan_OBJECTS = gribscan.$(OBJEXT) gamach.$(OBJEXT) \
 gribscan_OBJECTS = $(am_gribscan_OBJECTS)
 gribscan_DEPENDENCIES = gautil.sa.o gatxt.o $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1)
-am_gxeps_OBJECTS = gxeps.$(OBJEXT)
-gxeps_OBJECTS = $(am_gxeps_OBJECTS)
-gxeps_LDADD = $(LDADD)
-gxeps_DEPENDENCIES =
-am_gxps_OBJECTS = gxps.$(OBJEXT)
-gxps_OBJECTS = $(am_gxps_OBJECTS)
-gxps_LDADD = $(LDADD)
-gxps_DEPENDENCIES =
-am_gxtran_OBJECTS = gxtran.$(OBJEXT) gxsubs.$(OBJEXT) gxchpl.$(OBJEXT) \
-	gxX.$(OBJEXT) gxdxwd.$(OBJEXT) galloc.$(OBJEXT)
-gxtran_OBJECTS = $(am_gxtran_OBJECTS)
-gxtran_DEPENDENCIES = gxmeta.sa.o $(am__DEPENDENCIES_1) \
-	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1)
 am_stnmap_OBJECTS = stnmap.$(OBJEXT) gamach.$(OBJEXT) galloc.$(OBJEXT)
 stnmap_OBJECTS = $(am_stnmap_OBJECTS)
 stnmap_DEPENDENCIES = gaddes.sa.o gautil.sa.o gatxt.o \
@@ -147,12 +135,10 @@ CCLD = $(CC)
 LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
 SOURCES = $(bufrscan_SOURCES) $(grads_SOURCES) $(EXTRA_grads_SOURCES) \
 	$(grib2scan_SOURCES) $(gribmap_SOURCES) $(gribscan_SOURCES) \
-	$(gxeps_SOURCES) $(gxps_SOURCES) $(gxtran_SOURCES) \
 	$(stnmap_SOURCES) $(wgrib_SOURCES)
 DIST_SOURCES = $(bufrscan_SOURCES) $(am__grads_SOURCES_DIST) \
 	$(EXTRA_grads_SOURCES) $(grib2scan_SOURCES) $(gribmap_SOURCES) \
-	$(gribscan_SOURCES) $(gxeps_SOURCES) $(gxps_SOURCES) \
-	$(gxtran_SOURCES) $(stnmap_SOURCES) $(wgrib_SOURCES)
+	$(gribscan_SOURCES) $(stnmap_SOURCES) $(wgrib_SOURCES)
 HEADERS = $(noinst_HEADERS)
 ETAGS = etags
 CTAGS = ctags
@@ -261,6 +247,8 @@ build_alias = @build_alias@
 build_cpu = @build_cpu@
 build_os = @build_os@
 build_vendor = @build_vendor@
+cairo_inc = @cairo_inc@
+cairo_libs = @cairo_libs@
 dap_libs = @dap_libs@
 datadir = @datadir@
 exec_prefix = @exec_prefix@
@@ -320,29 +308,26 @@ supp_lib_dir = $(SUPPLIBS)/lib
 LDADD = -L$(supp_lib_dir) 
 INCLUDES = $(readline_inc) $(printim_inc) $(grib2_inc) $(gui_inc) $(nc_inc) \
 			  $(hdf_inc) $(hdf5_inc) $(geotiff_inc) $(shp_inc) $(gadap_inc) \
-                          $(X_CFLAGS) $(XAW_CFLAGS) $(GD_CFLAGS) $(HDF4_CFLAGS)
+                          $(X_CFLAGS) $(XAW_CFLAGS) $(GD_CFLAGS) $(HDF4_CFLAGS) $(cairo_inc)
 
 
 # Settings used for all GrADS binaries
-common_ldadd = $(LDADD) $(X_LIBS) $(host_ldadd) -lX11
+common_ldadd = $(LDADD) $(X_LIBS) $(host_ldadd) -lX11 -lXext
 
 ######################################################################
 #
 # Headers and data
 #
 
-# Headers must be listed here to be included in the distribution.  The
-# "noinst_" prefix prevents "make install" from trying to do anything
-# with them
-hdr_core = gagmap.h grads.h gs.h gatypes.h \
-		      gvt.h gx.h gxmap.h wx.h
-
+# Headers must be listed here to be included in the distribution.
+# The "noinst_" prefix prevents "make install" from trying to do anything with them
+hdr_core = gagmap.h grads.h gs.h gatypes.h gvt.h gx.h gxmap.h wx.h
 hdr_bufr = gabufr.h
 hdr_x11 = gx.h bitmaps.h
 hdr_sdf = gasdf.h gasdf_std_time.h 
 hdr_gui = gagui.h
-hdr_png = mtables.c
-noinst_HEADERS = $(hdr_core) $(hdr_x11) $(hdr_sdf) $(hdr_png) $(hdr_gui) $(hdr_bufr)
+hdr_cairo = gxC.h
+noinst_HEADERS = $(hdr_core) $(hdr_x11) $(hdr_sdf) $(hdr_gui) $(hdr_bufr) $(hdr_cairo)
 
 # Get rid of buildinfo.h on "make distclean"
 DISTCLEANFILES = buildinfo.h
@@ -363,24 +348,36 @@ DISTCLEANFILES = buildinfo.h
 grads_SOURCES = grads.c gxsubs.c gxmeta.c gxchpl.c gxcntr.c gxstrm.c \
 			 gxwmap.c gxshad.c gxshad2.c gaexpr.c gafunc.c gautil.c gagx.c \
 			 gscrpt.c gamach.c bufrstn.c gabufr.c gabufrtbl.c \
-			 gxX.c gxdxwd.c galloc.c $(src_gui) $(src_gadap) \
-                         gaddes.c gaio.c gacfg.c gauser.c gasdf.c gatxt.c
+			 gxdxwd.c galloc.c $(src_gui) $(src_gadap) \
+                         gaddes.c gaio.c gacfg.c gauser.c gasdf.c gatxt.c gxX.c gxC.c \
+                         gxprint.c 
 
 
+#xgrads_SOURCES         = grads.c gxsubs.c gxmeta.c gxchpl.c gxcntr.c gxstrm.c \
+#			 gxwmap.c gxshad.c gxshad2.c gaexpr.c gafunc.c gautil.c gagx.c \
+#			 gscrpt.c gamach.c bufrstn.c gabufr.c gabufrtbl.c \
+#			 gxdxwd.c galloc.c $(src_gui) $(src_gadap) \
+#                        gaddes.c gaio.c gacfg.c gauser.c gasdf.c gatxt.c gxX11.c \
+#			 gxprintGD.c gxGD.c 
+
 # Sources that will not always be compiled
 # Since gradsc is the only GrADS binary that is not conditionally compiled,
 # any source file that we want to go in the distribution must be listed.
-#EXTRA_grads_SOURCES    = gagmap.c gagui.c gsgui.c gxhpng.c dodstn.c
 EXTRA_grads_SOURCES = gagmap.c gagui.c gsgui.c dodstn.c
 
 # libraries needed 
 grads_LDADD = $(common_ldadd) $(readline_libs) $(printim_libs) \
 			 $(grib2_libs) $(hdf_libs) $(hdf5_libs) $(nc_libs) \
-			 $(gui_libs) $(geotiff_libs) $(shp_libs) $(dap_libs)
+			 $(gui_libs) $(geotiff_libs) $(shp_libs) $(dap_libs) $(cairo_libs)
+
 
+#xgrads_LDADD	       = $(common_ldadd) $(readline_libs) $(printim_libs) \
+#			 $(grib2_libs) $(hdf_libs) $(hdf5_libs) $(nc_libs) \
+#			 $(gui_libs) $(geotiff_libs) $(shp_libs) $(dap_libs)
 
 # Custom compilation for object files specific to this GrADS binary
 COMPILE_C = $(COMPILE) 
+#xgrads_LINK          = $(CXX) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
 @USEGADAP_FALSE at grads_LINK = $(CC) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
 
 ##############################################################
@@ -390,6 +387,7 @@ COMPILE_C = $(COMPILE)
 
 # If gadap is enabled, use C++ linker instead of C linker
 @USEGADAP_TRUE at grads_LINK = $(CXX) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
+#xgrads_LINK          = $(CC) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
 
 # Object files that should not be reused by the other GrADS binaries,
 # plus libraries needed by this GrADS binary
@@ -419,20 +417,6 @@ wgrib_SOURCES = wgrib.c
 
 ##############################################################
 #
-# gxps
-#
-gxps_SOURCES = gxps.c
-gxeps_SOURCES = gxeps.c
-
-##############################################################
-#
-# gxtran
-#
-gxtran_SOURCES = gxtran.c gxsubs.c gxchpl.c gxX.c gxdxwd.c galloc.c 
-gxtran_LDADD = gxmeta.sa.o $(LDADD) $(X_LIBS) $(printim_libs) -lX11
-
-##############################################################
-#
 # gribscan
 #
 gribscan_SOURCES = gribscan.c gamach.c galloc.c
@@ -539,15 +523,6 @@ gribmap$(EXEEXT): $(gribmap_OBJECTS) $(gribmap_DEPENDENCIES)
 gribscan$(EXEEXT): $(gribscan_OBJECTS) $(gribscan_DEPENDENCIES) 
 	@rm -f gribscan$(EXEEXT)
 	$(LINK) $(gribscan_LDFLAGS) $(gribscan_OBJECTS) $(gribscan_LDADD) $(LIBS)
-gxeps$(EXEEXT): $(gxeps_OBJECTS) $(gxeps_DEPENDENCIES) 
-	@rm -f gxeps$(EXEEXT)
-	$(LINK) $(gxeps_LDFLAGS) $(gxeps_OBJECTS) $(gxeps_LDADD) $(LIBS)
-gxps$(EXEEXT): $(gxps_OBJECTS) $(gxps_DEPENDENCIES) 
-	@rm -f gxps$(EXEEXT)
-	$(LINK) $(gxps_LDFLAGS) $(gxps_OBJECTS) $(gxps_LDADD) $(LIBS)
-gxtran$(EXEEXT): $(gxtran_OBJECTS) $(gxtran_DEPENDENCIES) 
-	@rm -f gxtran$(EXEEXT)
-	$(LINK) $(gxtran_LDFLAGS) $(gxtran_OBJECTS) $(gxtran_LDADD) $(LIBS)
 stnmap$(EXEEXT): $(stnmap_OBJECTS) $(stnmap_DEPENDENCIES) 
 	@rm -f stnmap$(EXEEXT)
 	$(LINK) $(stnmap_LDFLAGS) $(stnmap_OBJECTS) $(stnmap_LDADD) $(LIBS)
@@ -736,7 +711,7 @@ uninstall-am: uninstall-binPROGRAMS uninstall-info-am
 
 
 # Convenience target
-utils: bufrscan gribscan gribmap gxeps gxps stnmap wgrib $(extra_utils)
+utils: bufrscan gribscan gribmap stnmap wgrib $(extra_utils)
 
 ##############################################################
 #
@@ -749,9 +724,6 @@ gaddes.sa.o: $(srcdir)/gaddes.c
 
 gautil.sa.o: $(srcdir)/gautil.c
 	$(COMPILE) -DSTNDALN -o gautil.sa.o -c $(srcdir)/gautil.c
-
-gxmeta.sa.o: $(srcdir)/gxmeta.c
-	$(COMPILE) -DSTNDALN -o gxmeta.sa.o -c $(srcdir)/gxmeta.c
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
diff --git a/src/VERSION b/src/VERSION
index e9307ca..3a8944c 100644
--- a/src/VERSION
+++ b/src/VERSION
@@ -1 +1 @@
-2.0.2
+2.1.a3
diff --git a/src/bitmaps2.h b/src/bitmaps2.h
new file mode 100644
index 0000000..0ce378d
--- /dev/null
+++ b/src/bitmaps2.h
@@ -0,0 +1,24 @@
+#define icon_bitmap_width 41
+#define icon_bitmap_height 41
+static  char icon_bitmap_bits[] = {
+   0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
+   0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x01,
+   0x01, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x01,
+   0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
+   0xc7, 0xc7, 0xc7, 0xc7, 0xc7, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
+   0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x01,
+   0x01, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x01,
+   0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
+   0xc7, 0xc7, 0xc7, 0xc7, 0xc7, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
+   0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x01,
+   0x01, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x01,
+   0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
+   0xc7, 0xc7, 0xc7, 0xc7, 0xc7, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
+   0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x01,
+   0x01, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x01,
+   0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
+   0xc7, 0xc7, 0xc7, 0xc7, 0xc7, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
+   0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x01,
+   0x01, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x01,
+   0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
+   0xff, 0xff, 0xff, 0xff, 0xff, 0x01};
diff --git a/src/bufrscan.c b/src/bufrscan.c
index dc49f16..6337a94 100644
--- a/src/bufrscan.c
+++ b/src/bufrscan.c
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 /*  written by Joe Wielgosz */
diff --git a/src/bufrstn.c b/src/bufrstn.c
index addb696..5181df7 100644
--- a/src/bufrstn.c
+++ b/src/bufrstn.c
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 /* Authored by Jennifer Adams */
diff --git a/src/config.h.in b/src/config.h.in
index 9ce8068..c7938b2 100644
--- a/src/config.h.in
+++ b/src/config.h.in
@@ -141,6 +141,9 @@
 /* Define to 1 if you have the ANSI C header files. */
 #undef STDC_HEADERS
 
+/* Cairo enabled */
+#undef USECAIRO
+
 /* Enable OPeNDAP for grids */
 #undef USEDAP
 
diff --git a/src/dodstn.c b/src/dodstn.c
index ed09cd9..5b4c84e 100644
--- a/src/dodstn.c
+++ b/src/dodstn.c
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 /* Authored by Joe Wielgosz 
diff --git a/src/gabufr.c b/src/gabufr.c
index eb97219..f9549c8 100644
--- a/src/gabufr.c
+++ b/src/gabufr.c
@@ -1,5 +1,4 @@
-/* Copyright (C) 1988-2011 by Brian Doty and the 
-   Institute of Global Environment and Society (IGES).  
+/* Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
    See file COPYRIGHT for more information.   */
 
 /* Authored by Joe Wielgosz */
diff --git a/src/gabufr.h b/src/gabufr.h
index 1019f21..c581e8a 100644
--- a/src/gabufr.h
+++ b/src/gabufr.h
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 #ifndef GABUFR_H
diff --git a/src/gabufrtbl.c b/src/gabufrtbl.c
index 49511d8..5b36d00 100644
--- a/src/gabufrtbl.c
+++ b/src/gabufrtbl.c
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 /* Authored by Joe Wielgosz */
diff --git a/src/gacfg.c b/src/gacfg.c
index 634b025..e84bb57 100644
--- a/src/gacfg.c
+++ b/src/gacfg.c
@@ -1,8 +1,6 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
-
 /* file: gacfg.c
  *
  *   Prints the configuration options of this build of GrADS.
@@ -53,6 +51,15 @@ const char *nc_inq_libvers(void);
 #if USEGADAP==1
 const char *libgadap_version(void);
 #endif
+
+#if USECAIRO==1
+#include <cairo.h>
+#include <fontconfig.h> 
+#include <ft2build.h>
+#include FT_FREETYPE_H
+#include <pixman.h>
+#endif
+
 /*
  * gacfg() - Prints several configuration parameters. 
  *
@@ -80,9 +87,9 @@ snprintf(cmd,255,"Config: v%s",GRADS_VERSION);
 #if READLINE==1
  strcat(cmd," readline");
 #endif
-#if GXPNG==1
- strcat(cmd," printim");
-#endif
+/* #if GXPNG==1 */
+/*  strcat(cmd," printim"); */
+/* #endif */
 #if GRIB2==1
  strcat(cmd," grib2");
 #endif
@@ -110,6 +117,9 @@ snprintf(cmd,255,"Config: v%s",GRADS_VERSION);
 #if USESHP==1
  strcat(cmd," shapefile");
 #endif
+#if USECAIRO==1
+ strcat(cmd," cairo");
+#endif
  strcat(cmd,"\n");
  gaprnt(verbose,cmd);
  
@@ -119,8 +129,7 @@ snprintf(cmd,255,"Config: v%s",GRADS_VERSION);
  }
  
  gaprnt (verbose, "Grid Analysis and Display System (GrADS) Version " GRADS_VERSION "\n");
- gaprnt (verbose, "Copyright (c) 1988-2011 by Brian Doty and the\n");
- gaprnt (verbose, "Institute for Global Environment and Society (IGES) \n");
+ gaprnt (verbose, "Copyright (C) 1988-2015 by the Institute for Global Environment and Society (IGES) \n");
  gaprnt (verbose, "This program is distributed WITHOUT ANY WARRANTY \n");
  gaprnt (verbose, "See file COPYRIGHT for more information. \n\n");
  
@@ -147,14 +156,15 @@ snprintf(cmd,255,"Config: v%s",GRADS_VERSION);
    gaprnt(verbose,"  o Command line editing DISABLED\n");
 #endif
 
-#if GXPNG==1
-   gaprnt(verbose,"  o printim command for image output ENABLED \n");
-   gaprnt(verbose,"      http://www.zlib.net \n");
-   gaprnt(verbose,"      http://www.libpng.org/pub/png/libpng.html \n");
-   gaprnt(verbose,"      http://www.libgd.org/Main_Page \n");
-#else 
-   gaprnt(verbose,"  o printim command DISABLED\n");
-#endif
+/* JMA Leave info about printim commented out for now */
+/* #if GXPNG==1 */
+/*    gaprnt(verbose,"  o printim command for image output ENABLED \n"); */
+/*    gaprnt(verbose,"      http://www.zlib.net \n"); */
+/*    gaprnt(verbose,"      http://www.libpng.org/pub/png/libpng.html \n"); */
+/*    gaprnt(verbose,"      http://www.libgd.org/Main_Page \n"); */
+/* #else  */
+/*    gaprnt(verbose,"  o printim command DISABLED\n"); */
+/* #endif */
 
 #if GRIB2==1
    gaprnt(verbose,"  o GRIB2 interface ENABLED \n");
@@ -239,6 +249,24 @@ snprintf(cmd,255,"Config: v%s",GRADS_VERSION);
 #else
    gaprnt(verbose,"  o Shapefile interface DISABLED\n");
 #endif
+
+#if USECAIRO==1
+   gaprnt(verbose,"  o Cairo graphics interface ENABLED \n");
+   gaprnt(verbose,"      http://cairographics.org \n");
+   gaprnt(verbose,"      http://cgit.freedesktop.org/pixman \n");
+   gaprnt(verbose,"      http://www.freetype.org/index2.html \n");
+   gaprnt(verbose,"      http://www.freedesktop.org/wiki/Software/fontconfig \n");
+   snprintf(cmd,255,"      Cairo %d.%d.%d\n",CAIRO_VERSION_MAJOR,CAIRO_VERSION_MINOR,CAIRO_VERSION_MICRO);
+   gaprnt(verbose,cmd);
+   snprintf(cmd,255,"      Pixman %d.%d.%d\n",PIXMAN_VERSION_MAJOR,PIXMAN_VERSION_MINOR,PIXMAN_VERSION_MICRO);
+   gaprnt(verbose,cmd);
+   snprintf(cmd,255,"      Freetype %d.%d.%d\n",FREETYPE_MAJOR,FREETYPE_MINOR,FREETYPE_PATCH); 
+   gaprnt(verbose,cmd);
+   snprintf(cmd,255,"      Fontconfig %d.%d.%d\n",FC_MAJOR,FC_MINOR,FC_REVISION);
+   gaprnt(verbose,cmd);
+#else
+   gaprnt(verbose,"  o Cairo interface DISABLED \n");
+#endif
  
  
  gaprnt(verbose,"\nFor additional information please consult http://iges.org/grads\n\n");
diff --git a/src/gaddes.c b/src/gaddes.c
index 5654711..09662c9 100644
--- a/src/gaddes.c
+++ b/src/gaddes.c
@@ -1,5 +1,4 @@
-/* Copyright (C) 1988-2011 by Brian Doty and the 
-   Institute of Global Environment and Society (IGES).  
+/* Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
    See file COPYRIGHT for more information.   */
 
 /* Authored by B. Doty */
@@ -69,7 +68,6 @@ gaint gaddes (char *name, struct gafile *pfi, gaint mflag) {
   static char *errs[9] = {"XDEF","YDEF","ZDEF","TDEF","UNDEF",
 			    "DSET","VARS","TITLE","DTYPE"};
 
- /*mf --- define here vice grads.c for cdunif.c mf*/
   mfcmn.fullyear=-999; 
 
   /* initialize variables */
@@ -122,7 +120,6 @@ gaint gaddes (char *name, struct gafile *pfi, gaint mflag) {
 
   /* Parse the data descriptor file */
   while (fgets(rec,512,descr)!=NULL) {
-
     /* Remove any leading blanks from rec */
     reclen = strlen(rec);
     jj = 0;
@@ -567,7 +564,8 @@ gaint gaddes (char *name, struct gafile *pfi, gaint mflag) {
 		j++;
 		if (j>1) goto err6a;
 	      }
-	      if (pfi->bufrinfo->offset.yrxy[0]==-999 || pfi->bufrinfo->offset.yrxy[1]==-999) goto err6a;
+	      if (pfi->bufrinfo->offset.yrxy[0]==-999 || pfi->bufrinfo->offset.yrxy[1]==-999) 
+		goto err6a;
 	    }
 
 	  } else if (cmpwrd("mo",ch)) {
@@ -584,7 +582,8 @@ gaint gaddes (char *name, struct gafile *pfi, gaint mflag) {
 		j++;
 		if (j>1) goto err6a;
 	      }
-	      if (pfi->bufrinfo->offset.moxy[0]==-999 || pfi->bufrinfo->offset.moxy[1]==-999) goto err6a;
+	      if (pfi->bufrinfo->offset.moxy[0]==-999 || pfi->bufrinfo->offset.moxy[1]==-999) 
+		goto err6a;
 	    }
 	  } else if (cmpwrd("dy",ch)) {
 	    if ((ch=nxtwrd(ch))==NULL) {
@@ -600,7 +599,8 @@ gaint gaddes (char *name, struct gafile *pfi, gaint mflag) {
 		j++;
 		if (j>1) goto err6a;
 	      }
-	      if (pfi->bufrinfo->offset.dyxy[0]==-999 || pfi->bufrinfo->offset.dyxy[1]==-999) goto err6a;
+	      if (pfi->bufrinfo->offset.dyxy[0]==-999 || pfi->bufrinfo->offset.dyxy[1]==-999) 
+		goto err6a;
 	    }
 	  } else if (cmpwrd("hr",ch)) {
 	    if ((ch=nxtwrd(ch))==NULL) {
@@ -616,7 +616,8 @@ gaint gaddes (char *name, struct gafile *pfi, gaint mflag) {
 		j++;
 		if (j>1) goto err6a;
 	      }
-	      if (pfi->bufrinfo->offset.hrxy[0]==-999 || pfi->bufrinfo->offset.hrxy[1]==-999) goto err6a;
+	      if (pfi->bufrinfo->offset.hrxy[0]==-999 || pfi->bufrinfo->offset.hrxy[1]==-999) 
+		goto err6a;
 	    }
 	  } else if (cmpwrd("mn",ch)) {
 	    if ((ch=nxtwrd(ch))==NULL) {
@@ -632,7 +633,8 @@ gaint gaddes (char *name, struct gafile *pfi, gaint mflag) {
 		j++;
 		if (j>1) goto err6a;
 	      }
-	      if (pfi->bufrinfo->offset.mnxy[0]==-999 || pfi->bufrinfo->offset.mnxy[1]==-999) goto err6a;
+	      if (pfi->bufrinfo->offset.mnxy[0]==-999 || pfi->bufrinfo->offset.mnxy[1]==-999) 
+		goto err6a;
 	    }
 	  } else if (cmpwrd("sc",ch)) {
 	    if ((ch=nxtwrd(ch))==NULL) {
@@ -648,7 +650,8 @@ gaint gaddes (char *name, struct gafile *pfi, gaint mflag) {
 		j++;
 		if (j>1) goto err6a;
 	      }
-	      if (pfi->bufrinfo->offset.scxy[0]==-999 || pfi->bufrinfo->offset.scxy[1]==-999) goto err6a;
+	      if (pfi->bufrinfo->offset.scxy[0]==-999 || pfi->bufrinfo->offset.scxy[1]==-999) 
+		goto err6a;
 	    }
 	  } else {
 	    goto err6a;
@@ -1216,6 +1219,7 @@ gaint gaddes (char *name, struct gafile *pfi, gaint mflag) {
         pvar->isu = 0;
 	pvar->isdvar = 0;
 	pvar->nvardims = 0; 
+	pvar->nh5vardims = 0; 
 	pvar->g2aflg = 0;
 #if USEHDF5==1
 	pvar->h5varflg=-999;
@@ -1318,6 +1322,7 @@ gaint gaddes (char *name, struct gafile *pfi, gaint mflag) {
 	/* parse the units fields; begin with 0th element for variable units */
         j = 0;
 	pvar->nvardims=0;
+	pvar->nh5vardims=0;
         while (1) {
           if (*ch=='x'||*ch=='y'||*ch=='z'||*ch=='t'||*ch=='e') { 
             if (*(ch+1)!=',' && *(ch+1)!=' ') goto err6;
@@ -1331,6 +1336,8 @@ gaint gaddes (char *name, struct gafile *pfi, gaint mflag) {
             if ( (ch=getdbl(ch,&(pvar->units[j])))==NULL ) goto err6;
 	    /* no negative array indices for ncflag files */
 	    if ((pfi->ncflg) && (pvar->units[j] < 0))  goto err6;   
+	    /* for hdf5, count the fixed array indices as varying dimensions */
+	    if ((pfi->ncflg==3) && (pvar->units[j] >= 0)) pvar->nh5vardims++;
           }
           while (*ch==' ') ch++;
           if (*ch=='\0' || *ch=='\n') goto err6;
@@ -1341,6 +1348,8 @@ gaint gaddes (char *name, struct gafile *pfi, gaint mflag) {
           j++;
           if (j>8) goto err6;
         }
+	/* for hdf5, add the letters and numbers to get true number of varying dimensions */
+	pvar->nh5vardims += pvar->nvardims;  
 
 	/* parse the variable description */
         getstr (pvar->varnm,mrec+(ch-rec),140);
@@ -1440,7 +1449,6 @@ gaint gaddes (char *name, struct gafile *pfi, gaint mflag) {
 
   if (err) goto retrn;
 
-
   /* Done scanning!
      Check if scanned stuff makes sense, and then set things up correctly */
 
@@ -1523,134 +1531,107 @@ gaint gaddes (char *name, struct gafile *pfi, gaint mflag) {
     mfile = fopen (pfi->mnam, "rb");
     if (mfile==NULL) {
       snprintf(pout,255,"Open Error:  Can't open Station/Index map file %s \n",pfi->mnam);
-      gaprnt (0,pout);
-      goto retrn;
+      gaprnt (0,pout); goto retrn;
     }
     if (mflag==2) goto skipread;
     
     mflflg = 1;
     swpflg = 0; 
       
-    /* GRIB (version 1 or 2) gridded data */
+    /* GRIB1 or GRIB2 gridded data */
     if (pfi->type!=2) {
-      /* GRIB version 1 */
+
+      /* * * GRIB1 * * */
       if (pfi->idxflg==1) {    
-	/* allocate memory for index data */
+
+	/* allocate memory for index structure */
 	sz = sizeof(struct gaindx);
-	if ((pindx = (struct gaindx *)galloc(sz,"pindx"))==NULL) 
-	  goto err8;
-	pfi->pindx = pindx;
-	/*  check the gribmap version number */
+	if ((pindx = (struct gaindx *)galloc(sz,"pindx"))==NULL) goto err8;
+
+	/* get the gribmap version number */
 	fseek(mfile,1,0);
 	rc = fread(&vermap,sizeof(unsigned char),1,mfile);
 	if (rc!=1) { 
-	  gaprnt(0,"Error reading version number from GRIB1 index file\n"); 
-	  goto retrn; 
+	  gaprnt(0,"Error reading version number from GRIB1 index file\n"); goto retrn; 
 	}
 
-	/* gribmap version 2 or 3 */
+	/* gribmap version 2 or 3 -- these versions are deprecated, but we still support reading them */
 	if ((vermap == 2) || (vermap == 3)) {        
+	  pindx->type = vermap; 
 
-	  /* read the header */
+	  /* read the array sizes from header */
 	  fseek(mfile,2,0);
 	  rc = fread(urec,sizeof(unsigned char),4,mfile);
-	  if (rc!=4) { 
-	    gaprnt(0,"Error reading hinum from GRIB1 index file\n"); 
-	    goto retrn; 
-	  }
+	  if (rc!=4) { gaprnt(0,"Error reading hinum from GRIB1 index file\n"); goto retrn; }
 	  pindx->hinum=gagby(urec,0,4);
-	  
+
 	  rc = fread(urec,sizeof(unsigned char),4,mfile);
-	  if (rc!=4) { 
-	    gaprnt(0,"Error reading hfnum from GRIB1 index file\n"); 
-	    goto retrn; 
-	  }
+	  if (rc!=4) { gaprnt(0,"Error reading hfnum from GRIB1 index file\n"); goto retrn; }
 	  pindx->hfnum=gagby(urec,0,4);
 	  
 	  rc = fread(urec,sizeof(unsigned char),4,mfile);
-	  if (rc!=4) { 
-	    gaprnt(0,"Error reading intnum from GRIB1 index file\n"); 
-	    goto retrn; 
-	  }
+	  if (rc!=4) { gaprnt(0,"Error reading intnum from GRIB1 index file\n"); goto retrn; }
 	  pindx->intnum=gagby(urec,0,4);
 	  
 	  rc = fread(urec,sizeof(unsigned char),4,mfile);
-	  if (rc!=4) { 
-	    gaprnt(0,"Error reading fltnum from GRIB1 index file\n"); 
-	    goto retrn; 
-	  }
+	  if (rc!=4) { gaprnt(0,"Error reading fltnum from GRIB1 index file\n"); goto retrn; }
 	  pindx->fltnum=gagby(urec,0,4);
 	  
 	  if (vermap == 2) {
-	    /* skip the begining time struct info */
-	    /* this not written out in version 3 maps */
+	    /* skip the begining time struct info; this not written out in version 3 maps */
 	    rc = fread(urec,sizeof(unsigned char),7,mfile);
-	    if (rc!=7) { 
-	      gaprnt(0,"Error reading time data from GRIB1 index file\n"); 
-	      goto retrn; 
-	    }
+	    if (rc!=7) { gaprnt(0,"Error reading time data from GRIB1 index file\n"); goto retrn; }
 	  }
 
-	  /* read the index data */
+	  /* now read the arrays of index data */
 	  pindx->hipnt  = NULL;
 	  pindx->hfpnt  = NULL;
 	  pindx->intpnt = NULL;
 	  pindx->fltpnt = NULL;
-	  if (pindx->hinum>0) {
-	    sz = sizeof(gaint)*pindx->hinum;
-	    if ((pindx->hipnt = (gaint*)galloc(sz,"hipnt"))==NULL) 
-	      goto err8;
+	  /* header integers */
+	  if (pindx->hinum>0) {  
+	    if ((pindx->hipnt = (gaint*)galloc(pindx->hinum*sizeof(gaint),"hipnt"))==NULL) goto err8;
 	    for (i=0; i<pindx->hinum; i++) {
 	      rc = fread(urec,sizeof(unsigned char),4,mfile);
 	      if (rc!=4) { 
 		snprintf(pout,255,"Error reading integer %d from header of GRIB1 index file\n",i); 
-		gaprnt(0,pout); 
-		goto retrn; 
+		gaprnt(0,pout); goto retrn; 
 	      }
 	      idum = gagby(urec,0,4);
 	      if (gagbb(urec,0,1)) idum = -idum;
 	      *(pindx->hipnt+i) = idum;
 	    }
 	  }
-
+	  /* header floats -- these are not used, hfnum is always zero */
 	  if (pindx->hfnum>0) {
-	    sz = sizeof(gafloat)*pindx->hfnum;
-	    if ((pindx->hfpnt = (gafloat*)galloc(sz,"hfpnt"))==NULL) 
-	      goto err8; 
-	    rc = fread (pindx->hfpnt,sizeof(gafloat),pindx->hfnum,mfile);
+	    if ((pindx->hfpnt = (gafloat*)galloc(pindx->hfnum*sizeof(gafloat),"hfpnt"))==NULL) goto err8; 
+	    rc = fread(pindx->hfpnt,sizeof(gafloat),pindx->hfnum,mfile);
 	    if (rc!=pindx->hfnum) { 
-	      gaprnt(0,"Error reading floats from header of GRIB1 index file\n"); 
-	      goto retrn; 
+	      gaprnt(0,"Error reading floats from header of GRIB1 index file\n"); goto retrn; 
 	    }
 	  }
-
+	  /* index data: integer */
 	  if (pindx->intnum>0) {
-	    sz = sizeof(gaint)*pindx->intnum;
-	    if ((pindx->intpnt = (gaint*)galloc(sz,"intpnt"))==NULL) 
-	      goto err8; 
+	    if ((pindx->intpnt = (gaint*)galloc(pindx->intnum*sizeof(gaint),"intpnt"))==NULL) goto err8; 
 	    for (i=0; i<pindx->intnum; i++) {
 	      rc = fread(urec,sizeof(unsigned char),4,mfile);
 	      if (rc!=4) { 
 		snprintf(pout,255,"Error reading integer %d from GRIB1 index file\n",i); 
-		gaprnt(0,pout); 
-		goto retrn; 
+		gaprnt(0,pout); goto retrn; 
 	      }
 	      idum = gagby(urec,0,4);
 	      if (gagbb(urec,0,1)) idum = -gagbb(urec,1,31);
 	      *(pindx->intpnt+i) = idum;
 	    }
 	  }
-
+	  /* index data: float */
 	  if (pindx->fltnum>0) {
-	    sz = sizeof(gafloat)*pindx->fltnum;
-	    if ((pindx->fltpnt = (gafloat *)galloc(sz,"fltpnt"))==NULL) 
-	      goto err8; 
+	    if ((pindx->fltpnt = (gafloat *)galloc(pindx->fltnum*sizeof(gafloat),"fltpnt"))==NULL) goto err8; 
 	    for (i=0; i<pindx->fltnum; i++) {
 	      rc = fread(urec,sizeof(unsigned char),4,mfile);
 	      if (rc!=4) { 
 		snprintf(pout,255,"Error reading float %d from GRIB1 index file\n",i); 
-		gaprnt(0,pout); 
-		goto retrn; 
+		gaprnt(0,pout); goto retrn; 
 	      }
 	      fdum = ibm2flt(urec);
 	      *(pindx->fltpnt+i) = fdum;
@@ -1658,138 +1639,144 @@ gaint gaddes (char *name, struct gafile *pfi, gaint mflag) {
 	  }
 	} 
 	else {     
-	  /* other gribmap versions */
+	  /* gribmap versions 1 or 4 or 5 */
 	  fseek (mfile,0L,0);
 	  rc = fread (pindx,sizeof(struct gaindx),1,mfile);
-          if (rc!=1) {
-	    gaprnt(0,"Error reading header from GRIB1 index file\n");
-	    goto retrn;
-          }
+          if (rc!=1) { gaprnt(0,"Error reading header from GRIB1 index file\n"); goto retrn; }
 	  if (pindx->type>>24 > 0) swpflg=1;
-	  if (swpflg) gabswp((gafloat *)pindx,5);
-	  pindx->hipnt = NULL;
-	  pindx->hfpnt = NULL;
+	  if (swpflg) gabswp((gafloat *)pindx,5); /* swap the 5 integers in the gaindx structure */
+	  pindx->hipnt  = NULL;
+	  pindx->hfpnt  = NULL;
 	  pindx->intpnt = NULL;
 	  pindx->fltpnt = NULL;
-          if (pindx->type != 1 && pindx->type != 4 ) {
+	  /* check the version number */
+          if (pindx->type != 1 && pindx->type != 4 && pindx->type != 5) {
             snprintf(pout,100,"Invalid version number %i in GRIB index file\n",pindx->type); 
-            gaprnt(0,pout); 
-            goto retrn; 
+            gaprnt(0,pout); goto retrn; 
           }
+	  /* header integers */
 	  if (pindx->hinum>0) {
-	    sz = sizeof(gaint)*pindx->hinum;
-	    if ((pindx->hipnt = (gaint *)galloc(sz,"hipnt2")) == NULL) 
-	      goto err8; 
+	    if ((pindx->hipnt = (gaint *)galloc(sizeof(gaint)*pindx->hinum,"hipnt2"))==NULL) goto err8; 
 	    rc = fread (pindx->hipnt,sizeof(gaint),pindx->hinum,mfile);
-            if (rc!=pindx->hinum) {
-	      gaprnt(0,"Error reading header ints from GRIB1 index file\n");
-	      goto retrn;
-            }
+            if (rc!=pindx->hinum) { gaprnt(0,"Error reading header ints from GRIB1 index file\n"); goto retrn; }
 	    if (swpflg) gabswp((gafloat *)(pindx->hipnt),pindx->hinum);
 	  }
+	  /* header floats --  these are not used, hfnum is always zero */
 	  if (pindx->hfnum>0) {
-	    sz = sizeof(gafloat)*pindx->hfnum;
-	    if ((pindx->hfpnt = (gafloat *)galloc(sz,"hfpnt2")) == NULL)
-	      goto err8; 
+	    if ((pindx->hfpnt = (gafloat *)galloc(sizeof(gafloat)*pindx->hfnum,"hfpnt2"))==NULL) goto err8; 
 	    rc = fread (pindx->hfpnt,sizeof(gafloat),pindx->hfnum,mfile);
-            if (rc!=pindx->hfnum) {
-	      gaprnt(0,"Error reading header floats from GRIB1 index file\n");
-	      goto retrn;
-            }
+            if (rc!=pindx->hfnum) { gaprnt(0,"Error reading header floats from GRIB1 index file\n"); goto retrn; } 
 	    if (swpflg) gabswp(pindx->hfpnt,pindx->hfnum);
 	  }
+	  /* index data: integer */
 	  if (pindx->intnum>0) {
-	    sz = sizeof(gaint)*pindx->intnum;
-	    if ((pindx->intpnt = (gaint *)galloc(sz,"ipnt2")) == NULL) 
-	      goto err8; 
+	    if ((pindx->intpnt = (gaint *)galloc(sizeof(gaint)*pindx->intnum,"ipnt2"))==NULL) goto err8; 
 	    rc = fread (pindx->intpnt,sizeof(gaint),pindx->intnum,mfile);
-            if (rc!=pindx->intnum) {
-	      gaprnt(0,"Error reading int array from GRIB1 index file\n");
-	      goto retrn;
-            }
+            if (rc!=pindx->intnum) { gaprnt(0,"Error reading int array from GRIB1 index file\n"); goto retrn; }
 	    if (swpflg) gabswp((gafloat *)(pindx->intpnt),pindx->intnum);
 	  }
+	  /* index data: float */
 	  if (pindx->fltnum>0) {
-	    sz = sizeof(gafloat)*pindx->fltnum;
-	    if ((pindx->fltpnt = (gafloat *)galloc(sz,"fpnt2")) == NULL)
-	      goto err8; 
+	    if ((pindx->fltpnt = (gafloat *)galloc(sizeof(gafloat)*pindx->fltnum,"fpnt2"))==NULL) goto err8; 
 	    rc = fread (pindx->fltpnt,sizeof(gafloat),pindx->fltnum,mfile);
-            if (rc!=pindx->fltnum) {
-	      gaprnt(0,"Error reading float array from GRIB1 index file\n");
-	      goto retrn;
-            }
+            if (rc!=pindx->fltnum) { gaprnt(0,"Error reading float array from GRIB1 index file\n"); goto retrn; }
 	    if (swpflg) gabswp(pindx->fltpnt,pindx->fltnum);
 	  }
-          if (pindx->type == 4) {
+	  /* index data: off_t */
+	  if ((pindx->type==4) ||                      /* version=4 --> off_t in use */
+	      (pindx->type==5 && pindx->hipnt+4>0)) {  /* version=5 & bignum>0 --> off_t in use */
             if (sizeof(off_t)!=8) goto err8a;
-	    sz = sizeof(struct gaindxb);
-	    if ((pindxb = (struct gaindxb *)galloc(sz,"pindxb"))==NULL) goto err8;
-	    pfi->pindxb = pindxb;
+	    if ((pindxb = (struct gaindxb *)galloc(sizeof(struct gaindxb),"pindxb"))==NULL) goto err8;
             pindxb->bignum = *(pindx->hipnt + 4); 
             pindxb->bigpnt = NULL;
-	    if (pindxb->bignum>0) {
-	      sz = sizeof(off_t)*pindxb->bignum;
-	      if ((pindxb->bigpnt = (off_t *)galloc(sz,"offpnt")) == NULL) goto err8; 
-	      rc = fread (pindxb->bigpnt,sizeof(off_t),pindxb->bignum,mfile);
-              if (rc!=pindxb->bignum) {
-	        gaprnt(0,"Error reading off_t array from GRIB1 index file\n");
-	        goto retrn;
-              }
-	      if (swpflg) gabswp8(pindxb->bigpnt,pindxb->bignum);
-	    }
+	    if ((pindxb->bigpnt = (off_t *)galloc(sizeof(off_t)*pindxb->bignum,"offpnt"))==NULL) goto err8; 
+	    rc = fread (pindxb->bigpnt,sizeof(off_t),pindxb->bignum,mfile);
+	    if (rc!=pindxb->bignum) { gaprnt(0,"Error reading off_t array from GRIB1 index file\n"); goto retrn; }
+	    if (swpflg) gabswp8(pindxb->bigpnt,pindxb->bignum);
+	    /* everything parsed OK, so hang the pindxb off the gafile structure */
+	    pfi->pindxb = pindxb;
           }
 	}
+	/* everything parsed OK, so hang the pindx off the gafile structure */
+	pfi->pindx = pindx;
       }
 #if GRIB2
-      /* GRIB Version 2 */
+      /* * * GRIB2 * * */
       else if (pfi->idxflg==2) {   	 
 	/* allocate memory for the grib2 index data */
-	sz = sizeof(struct gag2indx);
-	if ((g2indx = (struct gag2indx *)galloc(sz,"g2indx")) == NULL) 
-	  goto err8;
-	pfi->g2indx = g2indx;
-        g2indx->g2intpnt = NULL;
+	if ((g2indx = (struct gag2indx *)galloc(sizeof(struct gag2indx),"g2indx"))==NULL) goto err8;
+        g2indx->bigflg = 0;
+	g2indx->g2intpnt = NULL;
         g2indx->g2bigpnt = NULL;
 	/* get the grib2map version number */
 	fseek(mfile,0L,SEEK_SET);
 	rc = fread(&g2indx->version,sizeof(gaint),1,mfile);
 	if (rc!=1) {
-	  gaprnt(0,"Error reading version number from GRIB2 index file\n");
-	  goto retrn;
+	  gaprnt(0,"Error reading version number from GRIB2 index file\n"); goto retrn;
 	}
 	/* check if we need to byte swap */
 	if (g2indx->version>>24 > 0) swpflg=1;
 	else swpflg=0;
 	if (swpflg) gabswp(&g2indx->version,1);
+        if (g2indx->version==3 ) {
+          /* read the extra header fields in most recent version */
+	  rc = fread(&g2indx->bigflg,sizeof(gaint),1,mfile);
+	  if (rc!=1) {
+	    gaprnt(0,"Error reading bigflg from GRIB2 index file\n"); goto retrn;
+	  }
+	  if (swpflg) gabswp(&g2indx->bigflg,1);
+	  rc = fread(&g2indx->trecs,sizeof(gaint),1,mfile);
+	  if (rc!=1) {
+	    gaprnt(0,"Error reading trecs from GRIB2 index file\n"); goto retrn;
+	  }
+	  if (swpflg) gabswp(&g2indx->trecs,1);
+	  rc = fread(&g2indx->tsz,sizeof(gaint),1,mfile);
+	  if (rc!=1) {
+	    gaprnt(0,"Error reading tsz from GRIB2 index file\n"); goto retrn;
+	  }
+	  if (swpflg) gabswp(&g2indx->tsz,1);
+	  rc = fread(&g2indx->esz,sizeof(gaint),1,mfile);
+	  if (rc!=1) {
+	    gaprnt(0,"Error reading esz from GRIB2 index file\n"); goto retrn;
+	  }
+	  if (swpflg) gabswp(&g2indx->esz,1);
+	}
+	else {
+	  /* We can't know the trecs, tsz, and esz values for older versions of the map,
+	     but we can set bigflg  */
+	  if (g2indx->version==2) 
+	    g2indx->bigflg = 1;
+	  else 
+	    g2indx->bigflg = 0;
+	}
+
 	/* get the index values */
-	if (g2indx->version == 1 || g2indx->version == 2) {     
-          if (g2indx->version == 2 && sizeof(off_t)!=8) goto err8a;
+	if (g2indx->version==1 || g2indx->version==2 || g2indx->version==3) {     
+          if (g2indx->bigflg && sizeof(off_t)!=8) goto err8a;
+	  /* g2intnum is the size of the array of index values */
 	  rc = fread(&g2indx->g2intnum,sizeof(gaint),1,mfile);
 	  if (rc!=1) {
-	    gaprnt(0,"Error reading index values from GRIB2 index file\n");
-	    goto retrn;
-	  } 
+	    gaprnt(0,"Error reading g2intnum from GRIB2 index file\n"); goto retrn;
+	  }
 	  if (swpflg) gabswp(&g2indx->g2intnum,1);
 	  if (g2indx->g2intnum>0) {
+	    /* read the integer index data */
 	    sz = sizeof(gaint)*g2indx->g2intnum;
-	    if ((g2indx->g2intpnt = (gaint *)galloc(sz,"g2intpnt")) == NULL) 
-	      goto err8;
+	    if ((g2indx->g2intpnt = (gaint *)galloc(sz,"g2intpnt"))==NULL) goto err8;
 	    rc = fread(g2indx->g2intpnt,sizeof(gaint),g2indx->g2intnum,mfile);
 	    if (rc!=g2indx->g2intnum) {
-	      snprintf(pout,255,"Error reading GRIB2 index file, rc=%d\n",rc);
-	      gaprnt(0,pout);
-	      goto retrn;
+	      snprintf(pout,255,"Error reading int array from GRIB2 index file, rc=%d\n",rc);
+	      gaprnt(0,pout); goto retrn;
 	    }
 	    if (swpflg) gabswp(g2indx->g2intpnt,g2indx->g2intnum);
-            if (g2indx->version == 2) {
+	    /* read the off_t index data */
+            if (g2indx->bigflg) {
 	      sz = sizeof(off_t)*g2indx->g2intnum;
-	      if ((g2indx->g2bigpnt = (off_t *)galloc(sz,"g2bigpnt")) == NULL) 
-	        goto err8;
+	      if ((g2indx->g2bigpnt = (off_t *)galloc(sz,"g2bigpnt"))==NULL) goto err8;
 	      rc = fread(g2indx->g2bigpnt,sizeof(off_t),g2indx->g2intnum,mfile);
 	      if (rc!=g2indx->g2intnum) {
-	        snprintf(pout,255,"Error reading GRIB2 index file, rc=%d\n",rc);
-	        gaprnt(0,pout);
-	        goto retrn;
+	        snprintf(pout,255,"Error reading off_t array from GRIB2 index file, rc=%d\n",rc);
+	        gaprnt(0,pout); goto retrn;
 	      }
 	      if (swpflg) gabswp8(g2indx->g2bigpnt,g2indx->g2intnum);
             }
@@ -1797,9 +1784,10 @@ gaint gaddes (char *name, struct gafile *pfi, gaint mflag) {
 	}
 	else {     
 	  snprintf(pout,255,"Unknown GRIB2 index version number: %d\n",g2indx->version);
-	  gaprnt(0,pout);
-	  goto retrn;
+	  gaprnt(0,pout); goto retrn;
 	}
+	/* everything parsed OK, so hang the pindx off the gafile structure */
+	pfi->g2indx = g2indx;
       }
 #endif
     }  /* end of GRIB index handling */
@@ -1808,10 +1796,10 @@ gaint gaddes (char *name, struct gafile *pfi, gaint mflag) {
       /* stnmap file processing */
       fread(rec,1,16,mfile);  /* minimum map file is 16 bytes */
       vermap=1;
-      if (strncmp(rec,"GrADS_stnmapV002",16) == 0) {
+      if (strncmp(rec,"GrADS_stnmapV002",16)==0) {
 	vermap=2;
       }
-      if (vermap == 2) {
+      if (vermap==2) {
 	fread(urec,sizeof(unsigned char),4,mfile);
 	idum=gagby(urec,0,4);
 	if (gagbb(urec,0,1)) idum=-idum;
@@ -1821,8 +1809,8 @@ gaint gaddes (char *name, struct gafile *pfi, gaint mflag) {
 	if (gagbb(urec,0,1)) idum=-idum;
 	maxlv=idum;
 	sz = sizeof(gaint)*mcnt;
-	if ((pfi->tstrt = (gaint *)galloc(sz,"tstrt")) == NULL) goto err8;
-	if ((pfi->tcnt  = (gaint *)galloc(sz,"tcnt")) == NULL) goto err8;
+	if ((pfi->tstrt = (gaint *)galloc(sz,"tstrt"))==NULL) goto err8;
+	if ((pfi->tcnt  = (gaint *)galloc(sz,"tcnt"))==NULL) goto err8;
 	for(i=0;i<mcnt;i++) {
 	  fread(urec,sizeof(unsigned char),4,mfile);
 	  idum=gagby(urec,0,4);
@@ -1847,8 +1835,8 @@ gaint gaddes (char *name, struct gafile *pfi, gaint mflag) {
 	  gabswp((gafloat *)(&maxlv),1);
 	}
 	sz = sizeof(gaint)*mcnt;
-	if ((pfi->tstrt = (gaint *)galloc(sz,"tstrt1")) == NULL) goto err8;
-	if ((pfi->tcnt  = (gaint *)galloc(sz,"tcnt1")) == NULL) goto err8;
+	if ((pfi->tstrt = (gaint *)galloc(sz,"tstrt1"))==NULL) goto err8;
+	if ((pfi->tcnt  = (gaint *)galloc(sz,"tcnt1"))==NULL) goto err8;
 	fread (pfi->tstrt,sizeof(gaint),mcnt,mfile);
 	fread (pfi->tcnt,sizeof(gaint),mcnt,mfile);
 	if (swpflg) {
@@ -1887,7 +1875,7 @@ gaint gaddes (char *name, struct gafile *pfi, gaint mflag) {
   if (vectorpairs) {
     vplist = vectorpairs; 
     sz = strlen(vplist)+1;
-    if ((pair = (char *)galloc(sz,"pair")) == NULL) {
+    if ((pair = (char *)galloc(sz,"pair"))==NULL) {
       gaprnt(0,"memory allocation error for list of vector pairs\n");
       goto err8;
     } 
@@ -1936,7 +1924,7 @@ gaint gaddes (char *name, struct gafile *pfi, gaint mflag) {
 	  i++; 
 	}
 	/* move pointer forward one word */
-	if ((vplist = nxtwrd (vplist)) == NULL) break;
+	if ((vplist = nxtwrd (vplist))==NULL) break;
       }
     }
     gree(pair,"f174");
@@ -1947,7 +1935,7 @@ gaint gaddes (char *name, struct gafile *pfi, gaint mflag) {
   pvar=pfi->pvar1;
   for (j=1; j<=pfi->vnum; j++) {
     /* for GRIB2 data sets */
-    if (pfi->idxflg == 2) {
+    if (pfi->idxflg==2) {
       /* Look for a variable with units[0-2] == 0,2,2 or 0,2,3  that hasn't been handled yet */
       if ((pvar->vecpair<0) && 
 	  ((pvar->units[0]==0 && 
@@ -2059,7 +2047,6 @@ gaint gaddes (char *name, struct gafile *pfi, gaint mflag) {
   }
   if (err) goto retrn;
 
-
   /* Figure out locations of variables within a time group */
   pvar = pfi->pvar1;
 
@@ -2927,12 +2914,10 @@ gaint i;
   if (pfi->tcnt)   gree(pfi->tcnt,"f63");
   if (pfi->pvar1)  gree(pfi->pvar1,"f64");
   if (pfi->ens1)   gree(pfi->ens1,"f65");
-  for (i=0; i<9; i++) if (pfi->ppi[i]) gree(pfi->ppi[i],"f66");
-  for (i=0; i<9; i++) if (pfi->ppf[i]) gree(pfi->ppf[i],"f67");
-  if (pfi->ppw) gree(pfi->ppw,"f68");
-  if (!flag) for (i=0; i<5; i++) {
-    if (pfi->grvals[i]) gree(pfi->grvals[i],"f69");
-  }
+  for (i=0; i<9; i++) { if (pfi->ppi[i]) gree(pfi->ppi[i],"f66"); pfi->ppi[i]=NULL; }
+  for (i=0; i<9; i++) { if (pfi->ppf[i]) gree(pfi->ppf[i],"f67"); pfi->ppf[i]=NULL; }
+  if (pfi->ppw) { gree(pfi->ppw,"f68"); pfi->ppw=NULL; }
+  if (!flag) for (i=0; i<5; i++) if (pfi->grvals[i]) gree(pfi->grvals[i],"f69");
   if (pfi->pindx) {
     pindx = pfi->pindx;
     if (pindx->hipnt)  gree(pindx->hipnt,"f70");
@@ -2940,11 +2925,13 @@ gaint i;
     if (pindx->intpnt) gree(pindx->intpnt,"f72");
     if (pindx->fltpnt) gree(pindx->fltpnt,"f73");
     gree(pindx,"f74");
+    pfi->pindx = NULL;
   }
   if (pfi->pindxb) {
     pindxb = pfi->pindxb;
     if (pindxb->bigpnt)  gree(pindxb->bigpnt,"b98");
     gree(pindxb,"b99");
+    pfi->pindxb = NULL;
   }
 #if GRIB2
   if (pfi->g2indx) {
@@ -2952,6 +2939,7 @@ gaint i;
     if (g2indx->g2intpnt) gree(g2indx->g2intpnt,"f75");
     if (g2indx->g2bigpnt) gree(g2indx->g2bigpnt,"b75");
     gree(g2indx,"f76");
+    pfi->g2indx = NULL;
   }
 #endif
   if (pfi->fnums)  gree(pfi->fnums,"f77");
@@ -3270,10 +3258,10 @@ merr2:
   goto err;
 
 err:
-  if (pfi->ppi[0]!=NULL) gree(pfi->ppi[0],"f80a");
-  if (pfi->ppf[0]!=NULL) gree(pfi->ppf[0],"f80c");
-  if (pfi->ppf[1]!=NULL) gree(pfi->ppf[1],"f80d");
-  if (pfi->ppwrot && pfi->ppw!=NULL) gree(pfi->ppw,"f80e");
+  if (pfi->ppi[0]!=NULL) { gree(pfi->ppi[0],"f80a"); pfi->ppi[0]=NULL; }
+  if (pfi->ppf[0]!=NULL) { gree(pfi->ppf[0],"f80c"); pfi->ppf[0]=NULL; }
+  if (pfi->ppf[1]!=NULL) { gree(pfi->ppf[1],"f80d"); pfi->ppf[1]=NULL; }
+  if (pfi->ppwrot && pfi->ppw!=NULL) { gree(pfi->ppw,"f80e"); pfi->ppw=NULL; }
   if (fvals!=NULL) gree(fvals,"f80f");
   return(1);
 
diff --git a/src/gaexpr.c b/src/gaexpr.c
index aa9c71c..2caed7e 100644
--- a/src/gaexpr.c
+++ b/src/gaexpr.c
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 /* Authored by B. Doty */
@@ -65,9 +64,8 @@ gaint size;
   pass++;
 
   cmdlen = strlen(expr);
-/*   size = cmdlen * ( 7 + sizeof(struct smem) ); */
   size = sizeof(struct smem[cmdlen+10]);
-  stack = (struct smem *)malloc(size);
+  stack = (struct smem *)galloc(size,"stack");
   if (stack==NULL) {
     gaprnt (0,"Memory Allocation Error:  parser stack\n");
     return (1);
@@ -139,8 +137,8 @@ gaint size;
       }
 
       else {
-        cont=0; err=1;
         gaprnt (0,"Syntax Error:  Expected operand or '('\n");
+        cont=0; err=1;
       }
 
     } else {                         /* Expect operator or ')'      */
@@ -218,21 +216,22 @@ gaint size;
     }
 
 /*  release any memory still hung off the stack  */
-    for (i=0; i<curr; i++) {
+    for (i=0; i<=curr; i++) {
       if (stack[i].type==-1) {
         pgr = stack[i].obj.pgr;
         gagfre(pgr);
+        pst->result.pgr=NULL; 
       } else if (stack[i].type==-2) {
         stn = stack[i].obj.stn;
         for (j=0; j<BLKNUM; j++) {
-          if (stn->blks[j] != NULL) free(stn->blks[j]);
+          if (stn->blks[j] != NULL) gree(stn->blks[j],"f172");
         }
-        free(stn);
+        gree(stn);
+        pst->result.stn=NULL; 
       }
     }
   }
-
-  free(stack);
+  gree(stack);
   pass--;
   return (err);
 }
@@ -460,8 +459,14 @@ char *uval1,*uval2;
           else *val2 = *val1 / *val2;
         }
       } else if (op==10) {
-        if (swap) *val2 = pow(*val2,*val1);
-        else *val2 = pow(*val1,*val2);
+        if (swap) {
+	  if (isnan(pow(*val2,*val1))) *uval2 = 0;
+	  else *val2 = pow(*val2,*val1);
+	}
+        else {
+	  if (isnan(pow(*val1,*val2))) *uval2 = 0;
+	  else *val2 = pow(*val1,*val2);
+	}
       } else if (op==11)  *val2 = hypot(*val1,*val2);
       else if (op==12) {
         if (*val1==0.0 && *val2==0.0) *val2 = 0.0;
@@ -586,8 +591,14 @@ gaint swap,i,j,flag,dimtyp;
         }
       } 
       else if (op==10) {
-        if (swap) rpt1->val = pow(rpt2->val,rpt1->val);
-        else rpt1->val = pow(rpt1->val,rpt2->val);
+        if (swap) {
+	  if (isnan(pow(rpt2->val,rpt1->val))) rpt1->umask = 0;
+	  else rpt1->val = pow(rpt2->val,rpt1->val);
+	}
+        else {
+	  if (isnan(pow(rpt1->val,rpt2->val))) rpt1->umask = 0;
+	  else rpt1->val = pow(rpt1->val,rpt2->val);
+	}
       } 
       else if (op==11)  
 	rpt1->val = hypot(rpt1->val,rpt2->val);
@@ -650,8 +661,14 @@ gaint i;
       }
     } 
     else if (op==10) {
-      if (swap) rpt->val = pow(val,rpt->val);
-      else rpt->val = pow(rpt->val,val);
+      if (swap) {
+	if (isnan(pow(val,rpt->val))) rpt->umask = 0;
+	else rpt->val = pow(val,rpt->val);
+      }
+      else {
+	if (isnan(pow(rpt->val,val))) rpt->umask = 0;
+	else rpt->val = pow(rpt->val,val);
+      }
     } 
     else if (op==11)  
       rpt->val = hypot(rpt->val,val);
@@ -1367,7 +1384,6 @@ size_t sz;
     gaprnt (0,"Memory Allocation Error:  Station Request Block \n");
     return (NULL);
   }
- 
   stn->rnum = 0;
   stn->rpt = NULL;
   stn->pfi = pfi;
diff --git a/src/gafunc.c b/src/gafunc.c
index 45d5abc..cd574a6 100644
--- a/src/gafunc.c
+++ b/src/gafunc.c
@@ -1,5 +1,4 @@
-/* Copyright (C) 1988-2011 by Brian Doty and the 
-   Institute of Global Environment and Society (IGES).  
+/* Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
    See file COPYRIGHT for more information.   */
 
 /*  Originally authored by B. Doty.  
@@ -21,6 +20,10 @@
 #include <string.h>
 #include "grads.h"
 
+#ifdef OPENGRADS
+#include "gaudx.h"
+#endif
+
 /* expose Mike Fiorino's global struct to these routines for warning level setting */
 extern struct gamfcmn mfcmn;
 
@@ -187,6 +190,11 @@ gaint (*fpntr)(struct gafunc *, struct gastat *)=NULL;
     if (cmpwrd("amaxlocx",name)) fpntr = ffamaxlocx;    
     if (cmpwrd("amaxlocy",name)) fpntr = ffamaxlocy;    
 
+#ifdef OPENGRADS
+    /* OpenGrADS User Defined Extensions */
+    if (fpntr==NULL) *(void **) &fpntr = (void *) gaudf(name); 
+#endif
+
     if (fpntr==NULL) {                       /* Didn't find it....      */
       gaprnt (0,"Syntax Error:  Invalid Operand \n");
       snprintf(pout,255,"  '%s' not a variable or function name\n",name);
@@ -5049,6 +5057,7 @@ gaint ffclgr (struct gafunc *pfc, struct gastat *pst) {
     else if (intprs(pfc->argpnt[1],&i) != NULL) ucnt = i;
     else gaprnt (1,"COLL2GR Warning:  2nd arg Invalid; Ignored\n");
   }
+  /* JMA this option not documented */
   if (pfc->argnum>2) {
     if (cmpwrd("-n0",pfc->argpnt[2])) noundef=0;
     else if (cmpwrd("-n1",pfc->argpnt[2])) noundef=1;
@@ -5171,6 +5180,7 @@ gaint ffclgr (struct gafunc *pfc, struct gastat *pst) {
       flag = 0;
       while (rpt) {
         if (dequal(rpt->lev,lev,1.0e-8)==0) {
+	  /* level in rpt matches level in grid, no need to interpolate */
           flag = 1;
           break;
         }
@@ -5207,9 +5217,10 @@ gaint ffclgr (struct gafunc *pfc, struct gastat *pst) {
       }
       if (flag) {
 	*(gr+j*scnt+i) = rpt->val;
-	*(gru+j*scnt+i) = 1;
+	*(gru+j*scnt+i) = rpt->umask;
       }
       else {
+	/* JMA bad test for undef here? */
         if (dequal(vhi,stn->undef,1.0e-8)==0 || dequal(vlo,stn->undef,1.0e-8)==0) {
           *(gru+j*scnt+i) = 0;
         } else {
diff --git a/src/gagmap.c b/src/gagmap.c
index c91745b..6e69e52 100644
--- a/src/gagmap.c
+++ b/src/gagmap.c
@@ -1,20 +1,18 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
-/*  Values output into the grib1 map file:
+/*  Values output into the GRIB1 map file:
      Header:
-     hipnt info: 0 - version number (1)
-                 1 - number of times in file
+     hipnt info: 0 - version number
+                 1 - size of time axis
                  2 - number of records per time
                  3 - Grid type
-                   255 - user defined grid.  descriptor
-                         describes grid exactly; one record
-                         per grid.
-                    29 - Predefined grid set 29 and 30.
-                         Two records per grid.
+                     255: user defined grid. 1 record per grid.
+                     29: predefined grid set 29 and 30. 2 records per grid.
+		 4 - size of off_t index array  (added for version 4)
+		 5 - size of ensemble axis  (added for version 5)
      hfpnt info:  None
-     Info:
+     Indices:
      intpnt info (for each mapped grib record) :
                  0 - position of start of data in file
                  1 - position of start of bit map in file
@@ -23,6 +21,7 @@
                  0 - decimal scale factor for this record
                  1 - binary scale factor
                  2 - reference value
+
 */
 
 #ifdef HAVE_CONFIG_H
@@ -67,7 +66,7 @@ gaint gribmap (void) {
 #if GRIB2
  unsigned char *cgrib=NULL;
  g2int  listsec0[3],listsec1[13],numlocal,numfields,n;
- g2int  unpack,expand,lgrib;
+ g2int  unpack=0,expand=0,lgrib;
  off_t iseek,lskip;
  gribfield  *gfld;
  size_t  lengrib;
@@ -75,20 +74,16 @@ gaint gribmap (void) {
 #endif
  char *ch=NULL;
  gaint ret,ierr,flag,rcgr,record;
- gaint rc,i,e,tmin=0,tmax=0,told,tcur,fnum,didmatch=0;
- gaint sp,sp2,ioff,eoff,it,write_map;
+ gaint rc,i,t,e,ee,r,tmin=0,tmax=0,told,tcur,fnum,didmatch=0;
+ gaint sp,sp2,ioff,eoff,tstart,estart,it;
+ gaint oldver,newver,oldtrecs=0,oldtsz=0,oldesz=0,oldbigflg,oldeoff,oldioff,oldi;
  struct gafile *pfi;
  struct dt dtim,dtimi;
  struct gaens *ens;
  struct gaindxb indxbb;
 
-#if GRIB2
- unpack=0;
- expand=0;
-#endif
+ /* initialize a few things */
  mfile=NULL;
- write_map=1;
-
  pindxb = &indxbb;
 
  /* Get the descriptor file name */
@@ -103,32 +98,282 @@ gaint gribmap (void) {
  /* Allocate memory for gafile structure */
  pfi = getpfi();
  if (pfi==NULL) {
-   printf ("gribmap error: unable to allocate memory for gafile structure\n");
-   return(1);
+   printf ("gribmap: ERROR! unable to allocate memory for gafile structure\n"); return(1);
  }
 
  /* Parse the descriptor file */
- rc = gaddes (ifile, pfi, 0);
+ if (update | upgrade | downgrade) {
+   /* if updating, upgrading, or downgrading ... read the index file too */
+   rc = gaddes (ifile, pfi, 1);
+   if (rc) printf("gribmap: ERROR! unable to parse the data descriptor file or the existing index file\n");
+ }
+ else {
+   rc = gaddes (ifile, pfi, 0);
+   if (rc) printf("gribmap: ERROR! unable to parse the data descriptor file\n");
+ }
  if (rc) return(1);
 
- /* Check index flags */
+ /* Make sure this is a GRIB dataset */
  if (pfi->idxflg!=1 && pfi->idxflg!=2) {
-   printf ("gribmap error: data descriptor file is not for GRIB data\n");
-   return(1);
+   printf ("gribmap: ERROR! data descriptor file is not for GRIB data\n"); return(1);
  } 
 
- /* * GRIB1 * */
- else if (pfi->idxflg==1) {
+ /* Upgrade or Downgrade the version of the index file */
+ if (upgrade || downgrade) {
+
+   /* * * GRIB1 index file upgrade/downgrade * * */
+   if (pfi->idxflg==1) {
+     if (upgrade && pfi->pindx->type == g1ver) {
+       printf("gribmap: GRIB1 index file version is already up to date\n"); return (0);
+     }
+     if (downgrade)
+       if (pfi->pindx->type==4 || (pfi->pindx->type==5 && *(pfi->pindx->hipnt+4)>0)) {
+       printf("gribmap: GRIB1 index file was created with the \"-big\" option and cannot be downgraded \n"); 
+       return (0);
+     }
+     if (upgrade)
+       printf("gribmap: upgrading GRIB1 index file from version %d to %d\n",pfi->pindx->type,g1ver);
+     else
+       printf("gribmap: downgrading GRIB1 index file from version %d to 1\n",pfi->pindx->type);
+     
+     /* Set up a new gaindx structure and copy info from pfi->pindx */
+     if ((pindx = (struct gaindx *)galloc(sizeof(struct gaindx),"pindxgm"))==NULL) {
+       printf ("gribmap: ERROR! malloc failed for new pindx structure\n"); return(1);
+     }
+     if (upgrade) {
+       pindx->type  = g1ver; 
+       pindx->hinum = 6;     /* new # of ints in the header */
+     }
+     else {
+       pindx->type  = 1;     /* the original, an oldie but goodie */
+       pindx->hinum = 4;     /* old # of ints in the header */
+     }
+     pindx->hfnum  = 0;     /* # of floats in the header, always zero */  
+     pindx->intnum = pfi->pindx->intnum;
+     pindx->fltnum = pfi->pindx->fltnum;
+     
+     /* allocate memory for new arrays */
+     if ((pindx->hipnt = (gaint *)galloc(sizeof(gaint)*pindx->hinum,"hipntgm"))==NULL) {
+       printf ("gribmap: ERROR! malloc failed for new hipnt array\n"); return(1);
+     }
+     if ((pindx->intpnt = (gaint *)galloc(sizeof(gaint)*pindx->intnum,"intpntgm"))==NULL) {
+       printf ("gribmap: ERROR! malloc failed for new intpnt array\n"); return(1);
+     }
+     if ((pindx->fltpnt = (gafloat *)galloc(sizeof(gafloat)*pindx->fltnum,"fltpntgm"))==NULL) {
+       printf ("gribmap: ERROR! malloc failed for new fltpnt array\n"); return(1);
+     }
+     pindxb->bignum = 0;    /* assume big file offsets are not in use */
+     if (upgrade) {
+       if (pfi->pindx->type==4) {
+	 pindxb->bignum = pfi->pindxb->bignum;
+	 if ((pindxb->bigpnt = (off_t *)galloc(sizeof(off_t)*pindxb->bignum,"bigpntgm"))==NULL) {
+	   printf ("gribmap: ERROR! malloc failed for new bigpnt array\n"); return(1);
+	 }
+       }
+     }
+
+     /* set the values of the header integers */
+     if (upgrade)
+       *(pindx->hipnt+0) = g1ver;
+     else
+       *(pindx->hipnt+0) = 1;
+     *(pindx->hipnt+1) = pfi->dnum[3];
+     *(pindx->hipnt+2) = pfi->trecs;
+     *(pindx->hipnt+3) = pfi->grbgrd;
+     if (pfi->grbgrd<-900) *(pindx->hipnt+3) = 255;
+     if (upgrade) {
+       if (pfi->pindx->type==4) 
+	 *(pindx->hipnt+4) = pfi->pindxb->bignum;
+       else                     
+	 *(pindx->hipnt+4) = 0;   
+       *(pindx->hipnt+5) = pfi->dnum[4];
+     }
+
+     /* copy the index arrays */
+     for (i=0; i<pindx->intnum; i++) *(pindx->intpnt+i) = *(pfi->pindx->intpnt+i);
+     for (i=0; i<pindx->fltnum; i++) *(pindx->fltpnt+i) = *(pfi->pindx->fltpnt+i); 
+     if (upgrade) {
+       if (pfi->pindx->type==4) 
+	 for (i=0; i<pindxb->bignum; i++) *(pindxb->bigpnt+i) = *(pfi->pindxb->bigpnt+i); 
+     }
+
+     /* write out the new index file */
+     rc = wtg1map(pfi,pindx,pindxb);
+     return (rc);
+   } /* end of GRIB1 index file upgrade/downgrade */
+
+#if GRIB2
+   /* * * GRIB2 index file upgrade/downgrade * * */
+   else {
+     if (upgrade && pfi->g2indx->version == g2ver) {
+       printf("gribmap: GRIB2 index file version is already up to date\n"); return (0);
+     }
+     if (downgrade)
+       if (pfi->g2indx->version==2 || (pfi->g2indx->version==3 && pfi->g2indx->bigflg)) {
+       printf("gribmap: GRIB2 index file was created with the \"-big\" option and cannot be downgraded \n"); 
+       return (0);
+     }
+     if (upgrade)
+       printf("gribmap: upgrading GRIB2 index file from version %d to %d\n",pfi->g2indx->version,g2ver);
+     else
+       printf("gribmap: downgrading GRIB2 index file from version %d to 1\n",pfi->g2indx->version);
+     
+     /* Set up new g2index structure and copy info from pfi->g2indx */
+     if ((g2indx = (struct gag2indx *)malloc(sizeof(struct gag2indx)))==NULL) {
+       printf ("gribmap: ERROR! malloc failed for new g2indx\n"); return(1);
+     }
+     if (upgrade)
+       g2indx->version = g2ver; 
+     else
+       g2indx->version = 1; 
+     g2indx->g2intnum = pfi->g2indx->g2intnum;
+     g2indx->g2intpnt = NULL;
+
+     if (upgrade) {
+       if (pfi->g2indx->version==2)
+	 g2indx->bigflg = 1;
+       else 
+	 g2indx->bigflg = 0;
+       g2indx->trecs = pfi->trecs; 
+       g2indx->tsz = pfi->dnum[3];
+       g2indx->esz = pfi->dnum[4];
+       g2indx->g2bigpnt = NULL;
+     }
+     
+     /* allocate memory and copy index arrays */
+     if ((g2indx->g2intpnt = (gaint *)malloc(sizeof(gaint)*g2indx->g2intnum))==NULL) {
+       printf ("gribmap: ERROR! malloc failed for new g2intpnt array\n"); return(1);
+     }
+     for (i=0; i<g2indx->g2intnum; i++) *(g2indx->g2intpnt+i) = *(pfi->g2indx->g2intpnt+i);
+     if (upgrade) {
+       if (g2indx->bigflg) {
+	 if ((g2indx->g2bigpnt = (off_t *)malloc(sizeof(off_t)*g2indx->g2intnum))==NULL) {
+	   printf ("gribmap: ERROR! malloc failed for new g2bigpnt array\n"); return(1);
+	 }
+	 for (i=0; i<g2indx->g2intnum; i++) *(g2indx->g2bigpnt+i) = *(pfi->g2indx->g2bigpnt+i);
+       }
+     }
+
+     /* Write out the new index file */
+     rc = wtg2map(pfi,g2indx);
+     return (rc);
+   } /* end of GRIB2 index file upgrade */
+#endif
+ } /* end of upgrade/downgrade code */
+
+
+ /* If updating the index file, check info in the existing file */
+ if (update) {
+
+   if (pfi->idxflg==1 && pfi->grbgrd==29) {
+     printf("gribmap: ERROR! Index files for grbgrd 29 cannot be updated.\n"); return(1);
+   }
+   /* make sure the existing map will have the metadata we need */
+   if (pfi->idxflg==1) {
+     oldver = pfi->pindx->type;
+     newver = g1ver;
+   }
+#if GRIB2
+   else {
+     oldver = pfi->g2indx->version;
+     newver = g2ver;
+   }
+#endif
+   if (oldver < newver) {
+     printf("gribmap: ERROR! Existing index file is an old version and cannot be updated.\n");
+     printf("* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *\n");
+     printf("* To use the update feature without having to re-scan all files, follow these steps:  *\n");
+     printf("*   1. Edit your descriptor file so that the TDEF and EDEF entries match the grid     *\n"); 
+     printf("*      dimensions when the existing index file was created (i.e., undo your update.)  *\n");
+     printf("*   2. Run gribmap with the \"-new\" option to upgrade the version of the index file.   *\n");
+     printf("*   3. Re-implement the changes to the TDEF or EDEF entries in your descriptor file   *\n");
+     printf("*      that expand the grid dimensions. Only one dimension can be updated at a time.  *\n");
+     printf("*   4. Run gribmap with the -u option.                                                *\n");
+     printf("* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *\n");
+     return(1);
+   }
+   /* get metadata from existing index */
+   if (pfi->idxflg==1) {
+     oldtrecs = *(pfi->pindx->hipnt+2);
+     oldtsz = *(pfi->pindx->hipnt+1);
+     oldesz = *(pfi->pindx->hipnt+5);
+     oldbigflg = *(pfi->pindx->hipnt+4);
+   }
+#if GRIB2
+   else {
+     oldtrecs = pfi->g2indx->trecs;
+     oldtsz = pfi->g2indx->tsz;
+     oldesz = pfi->g2indx->esz;
+     oldbigflg = pfi->g2indx->bigflg;
+   }
+#endif
+
+   /* compare new and old metadata to see what needs to be updated */
+   if (oldtrecs != pfi->trecs) {
+     printf("gribmap: ERROR! number of XY grids in existing index file doesn't match descriptor file. \n");
+     return(1);
+   }
+   if (oldtsz != pfi->dnum[3]) {
+     if (oldtsz > pfi->dnum[3]) {
+       printf("gribmap: ERROR! size of T axis in descriptor file is smaller than in existing index file. \n");
+       return(1);
+     }
+     printf("gribmap: updating the size of the T axis from %d to %d\n",oldtsz,pfi->dnum[3]);
+     update++;   /* increment by 1 to update T dimension */
+   }
+   if (oldesz != pfi->dnum[4]) {
+     if (oldesz > pfi->dnum[4]) {
+       printf("gribmap: ERROR! Size of E axis in descriptor file is smaller than in existing index file. \n");
+       return(1);
+     }
+     printf("gribmap: updating the size of the E axis from %d to %d\n",oldesz,pfi->dnum[4]);
+     update+=2;   /* increment by 2 to update E dimension */
+   }
+   /* additional checks on the results from comparing E and T sizes */
+   /* update=2 : T only  	
+      update=3 : E only  
+      update=4 : both T and E (not allowed) */
+   if (update==1) {
+     printf("gribmap: Sizes of T and E axes in descriptor file are the same as in existing index file. \n");
+     printf("         Nothing needs to be updated, so a new map file will not be created. \n");
+     return(0);
+   }
+   if (update==4) {
+     printf("gribmap: ERRROR! Two dimensions cannot be updated at the same time. \n");
+     printf("                 Update one dimension first (it can be T or E), then update the other. \n");
+     return(1);
+   }
+   if (update==3 && pfi->dnum[4]>1 && pfi->tmplat==1) {
+     printf("gribmap: ERROR! The E axis cannot be updated when data files are only templated over T. \n");
+     return(1);
+   }
+   /* make sure bigflg matches for existing and new map */
+   if (oldbigflg==0 && bigflg>0) {
+     printf("gribmap: ERROR! Existing index file is not for large files. \n");
+     printf("                If new data files are < 2GB, remove the \"-big\" option. \n");
+     printf("                If new data files are >= 2GB, remove the \"-u\" option. \n");
+     return(1);
+   }
+   if (oldbigflg>0 && bigflg==0) {
+     printf("gribmap: Warning! Existing index file is for large files; adding \"-big\" option for the update. \n");
+     bigflg = 1;
+   }
+ } /* end of update code common for both GRIB1 and GRIB2 */
+
+
+
+ /* * * * * * *
+  * * GRIB1 * *
+  * * * * * * */
+ if (pfi->idxflg==1) {
 
    /* Allocate memory for gaindx structure */
-   sz = sizeof(struct gaindx);
-   pindx = (struct gaindx *)galloc(sz,"pindxgm");
-   if (pindx==NULL) {
-     printf ("grib1map error: unable to allocate memory for pindx\n");
+   if ((pindx = (struct gaindx *)galloc(sizeof(struct gaindx),"pindxgm"))==NULL) {
+     printf ("gribmap: ERROR! unable to allocate memory for pindx\n");
      return(1);
    }
    
-   /* Save the initial time from the descriptor file for the tau0 option and the map file */
+   /* Save the initial time from the descriptor file for the tau0 option */
    btimdd.yr = *(pfi->abvals[3]);
    btimdd.mo = *(pfi->abvals[3]+1);
    btimdd.dy = *(pfi->abvals[3]+2);
@@ -151,7 +396,7 @@ gaint gribmap (void) {
 	 pfi->linear[0]!=1 || pfi->linear[1]!=1 ||
 	 *(pfi->grvals[0])!= 2.5 || *(pfi->grvals[0]+1) != -2.5 ||
 	 *(pfi->grvals[1])!= 2.5 || *(pfi->grvals[1]+1) != -92.5 ) {
-       printf("grib1map error: grid specification for GRIB grid type 29/30.\n");
+       printf("gribmap: ERROR! grid specification for GRIB grid type 29/30.\n");
        printf("                grid scaling must indicate a 2.5 x 2.5 grid\n");
        printf("                grid size must be 144 x 73\n");
        printf("                grid must go from 0 to 357.5 and -90 to 90\n");
@@ -163,55 +408,140 @@ gaint gribmap (void) {
    }
    
    /* Set up grib1 index and initialize values */
-   pindx->type   = g1ver;
-   pindx->hinum  = 4;
-   if (bigflg) pindx->hinum  = 5;
-   pindx->hfnum  = 0;
-   if (bigflg) pindx->intnum = nrec * pfi->trecs * pfi->dnum[3] * pfi->dnum[4];
-   else pindx->intnum = nrec * ng1elems * pfi->trecs * pfi->dnum[3] * pfi->dnum[4];
-   pindx->fltnum = nrec * ng1elems * pfi->trecs * pfi->dnum[3] * pfi->dnum[4];
-   if (bigflg) pindxb->bignum = 2 * nrec * pfi->trecs * pfi->dnum[3] * pfi->dnum[4];
-   sz = sizeof(gaint)*pindx->hinum;
-   pindx->hipnt  = (gaint *)galloc(sz,"hipntgm");
-   sz = sizeof(gaint)*pindx->intnum;
-   pindx->intpnt = (gaint *)galloc(sz,"intpntgm");
-   sz = sizeof(gafloat)*pindx->fltnum;
-   pindx->fltpnt = (gafloat *)galloc(sz,"fltpntgm");
-   if (pindx->hipnt==NULL || pindx->intpnt==NULL || pindx->fltpnt==NULL) {
-     printf ("grib1map error: unable to allocate memory for index pointers\n");
-     return(1);
+   /* nrec is the number of records per grid (usually only 1)
+      pfi-trecs is the number of XY grids per time step 
+      pfi->dnum[3] is the number of time steps
+      pfi->dnum[4] is the number of ensembles */
+   pindx->type = g1ver;
+   pindx->hfnum  = 0;     /* # of floats in the header, always zero */  
+   pindx->hinum  = 6;     /* # of ints in the header */
+   if (bigflg) {
+     /* factors of 1 and 2 add up to ng1elems */
+     pindx->intnum  = 1 * nrec * pfi->trecs * pfi->dnum[3] * pfi->dnum[4];
+     pindxb->bignum = 2 * nrec * pfi->trecs * pfi->dnum[3] * pfi->dnum[4];
+   }
+   else {
+     pindx->intnum  = ng1elems * nrec * pfi->trecs * pfi->dnum[3] * pfi->dnum[4];
+     pindxb->bignum = 0;
+   }
+   pindx->fltnum = ng1elems * nrec * pfi->trecs * pfi->dnum[3] * pfi->dnum[4];
+
+   if ((pindx->hipnt = (gaint *)galloc(sizeof(gaint)*pindx->hinum,"hipntgm"))==NULL) {
+     printf ("gribmap: ERROR! malloc failed for hipnt array\n"); return(1);
+   }
+   if ((pindx->intpnt = (gaint *)galloc(sizeof(gaint)*pindx->intnum,"intpntgm"))==NULL) {
+     printf ("gribmap: ERROR! malloc failed for intpnt array\n"); return(1);
+   }
+   if ((pindx->fltpnt = (gafloat *)galloc(sizeof(gafloat)*pindx->fltnum,"fltpntgm"))==NULL) {
+     printf ("gribmap: ERROR! malloc failed for fltpnt array\n"); return(1);
    }
    if (bigflg) {
-     sz = sizeof(off_t)*pindxb->bignum;
-     pindxb->bigpnt = (off_t *)galloc(sz,"bigpntgm");
-     if (pindxb->bigpnt==NULL) {
-       printf ("grib1map error: unable to allocate memory for index pointers\n");
-       return(1);
+     if ((pindxb->bigpnt = (off_t *)galloc(sizeof(off_t)*pindxb->bignum,"bigpntgm"))==NULL) {
+       printf ("gribmap: ERROR! malloc failed for bigpnt array\n"); return(1);
      }
    }
+   /* initialize values in the index arrays */
    for (i=0; i<pindx->intnum; i++) *(pindx->intpnt+i) = -999;
    for (i=0; i<pindx->fltnum; i++) *(pindx->fltpnt+i) = -999; 
    if (bigflg) {
       for (i=0; i<pindxb->bignum; i++) *(pindxb->bigpnt+i) = (off_t)-999;
    }
+   /* set the values of the 6 header integers */
    *(pindx->hipnt+0) = g1ver;
    *(pindx->hipnt+1) = pfi->dnum[3];
    *(pindx->hipnt+2) = pfi->trecs;
    *(pindx->hipnt+3) = pfi->grbgrd;
    if (pfi->grbgrd<-900) *(pindx->hipnt+3) = 255;
-   if (bigflg) *(pindx->hipnt+4) = pindxb->bignum;
+   *(pindx->hipnt+4) = pindxb->bignum;
+   *(pindx->hipnt+5) = pfi->dnum[4];
+
+   if (update) {
+     /* copy the existing index data into new index buffer */
+     for (e=0; e < oldesz; e++ ) {
+       for (t=0; t < oldtsz; t++) {
+	 oldeoff = e * oldtrecs * oldtsz;
+	 oldioff = t * oldtrecs;
+	 eoff = e * pfi->trecs * pfi->dnum[3];
+	 ioff = t * pfi->trecs;
+
+	 /* when updating a grib1 index file, nrec is always 1 and joff is always 0.
+	    nrec=2 and joff>0 are for grbgrd==29, but we aren't updating that ancient format.
+	    in gribfill() subroutine, the file offset koff = nrec*ng1elems*(eoff+ioff)+joff 
+	    but here it is just ng1elems*(eoff+ioff)  */
+	 if (bigflg) {
+	   /* copy the int array (here 1 means ng1elems-2) */
+	   for (r=0; r<1*oldtrecs; r+=1) {
+	     oldi = 1*(oldeoff+oldioff);
+	     i = 1*(eoff+ioff);
+	     *(pindx->intpnt+i+r) = *(pfi->pindx->intpnt+oldi+r);
+	   }
+	   /* copy the off_t arrays (here 2 means ng1elems-1) */
+	   for (r=0; r<2*oldtrecs; r+=2) {
+	     oldi = 2*(oldeoff+oldioff);
+	     i = 2*(eoff+ioff);
+	     *(pindxb->bigpnt+i+r+0) = *(pfi->pindxb->bigpnt+oldi+r+0);
+	     *(pindxb->bigpnt+i+r+1) = *(pfi->pindxb->bigpnt+oldi+r+1);
+	   }
+	 } else {
+	   /* copy the int array */
+	   for (r=0; r<ng1elems*oldtrecs; r+=ng1elems) {
+	     oldi = ng1elems*(oldeoff+oldioff);
+	     i = ng1elems*(eoff+ioff);
+	     *(pindx->intpnt+i+r+0) = *(pfi->pindx->intpnt+oldi+r+0);
+	     *(pindx->intpnt+i+r+1) = *(pfi->pindx->intpnt+oldi+r+1);
+	     *(pindx->intpnt+i+r+2) = *(pfi->pindx->intpnt+oldi+r+2);
+	   }
+	 }
+	 /* copy the float array */
+	 for (r=0; r<ng1elems*oldtrecs; r+=ng1elems) {
+	   oldi = ng1elems*(oldeoff+oldioff);
+	   i = ng1elems*(eoff+ioff);
+	   *(pindx->fltpnt+i+r+0) = *(pfi->pindx->fltpnt+oldi+r+0);
+	   *(pindx->fltpnt+i+r+1) = *(pfi->pindx->fltpnt+oldi+r+1);
+	   *(pindx->fltpnt+i+r+2) = *(pfi->pindx->fltpnt+oldi+r+2);
+	 }
+       }
+     }
+     /* set start points for axes that are being updated */
+     if (update==2) {                /* T only */
+       tstart = oldtsz;
+       estart = 1;
+     }
+     else if (update==3) {           /* E only */
+       tstart = 0; 
+       estart = oldesz + 1;
+     }
+     else {                          /* shouldn't get here, but just in case... */
+       tstart=0;
+       estart=1;
+     }
+   }
+   else {
+     /* start at the beginning when creating a new map file */
+     tstart=0;
+     estart=1;
+   }
 
-   /* Loop over all files in the data set */
+   /* if updating the map, advance through the chain of ensemble structures to starting point */
+   if (estart>1) {
+     ee=1;
+     ens=pfi->ens1; 
+     while (ee<estart) { ee++; ens++; } 
+   }
+   else {
+     ee=1;
+     ens=pfi->ens1; 
+   }
+   /* Begin looping over all files that need to be scanned in the data set */ 
    gfile = NULL;
-   for (e=1,ens=pfi->ens1; e<=pfi->dnum[4]; e++,ens++) {
-     tcur = 0;
-     while (1) {    /* loop over all times for this ensemble */
+   /* Loop over ensembles */
+   for (e=ee; e<=pfi->dnum[4]; e++) {
+     tcur = tstart;
+     /* Loop over all times for this ensemble */
+     while (1) {    
        if (pfi->tmplat) {
 	 /* make sure no file is open */
-	 if (gfile!=NULL) {
-	   fclose(gfile);
-	   gfile=NULL;
-	 }
+	 if (gfile!=NULL) { fclose(gfile); gfile=NULL; }
 	 /* advance to first valid time step for this ensemble */
 	 if (tcur==0) {
 	   told = 0;
@@ -221,51 +551,46 @@ gaint gribmap (void) {
 	 else {  /* tcur!=0 */
 	   told = pfi->fnums[(e-1)*pfi->dnum[3]+tcur-1];
 	   /* increment time step until fnums changes */
-	   while (told==pfi->fnums[(e-1)*pfi->dnum[3]+tcur-1] && tcur<=pfi->dnum[3]) {
-	     tcur++;
-	   }
+	   while (told==pfi->fnums[(e-1)*pfi->dnum[3]+tcur-1] && tcur<=pfi->dnum[3]) tcur++;
 	 }
-
 	 /* make sure we haven't advanced past end of time axis */
 	 if (tcur>pfi->dnum[3]) break;
-
 	 /* check if we're past all valid time steps for this ensemble */
 	 if ((told != -1) && (pfi->fnums[(e-1)*pfi->dnum[3]+tcur-1] == -1)) break;
-
 	 /* Find the range of t indexes that have the same fnums value.
 	    These are the times that are contained in this particular file */
 	 tmin = tcur;
 	 tmax = tcur-1;
 	 fnum = pfi->fnums[(e-1)*pfi->dnum[3]+tcur-1];
-
 	 if (fnum != -1) {
 	   while (fnum == pfi->fnums[(e-1)*pfi->dnum[3]+tmax]) tmax++;
 	   gr2t(pfi->grvals[3], (gadouble)tcur, &dtim); 
 	   gr2t(pfi->grvals[3], ens->gt, &dtimi);
 	   ch = gafndt(pfi->name, &dtim, &dtimi, pfi->abvals[3], pfi->pchsub1, pfi->ens1,tcur,e,&flag);
 	   if (ch==NULL) {
-	     printf(" grib1map error: couldn't determine data file name for e=%d t=%d\n",e,tcur);
+	     printf("gribmap: ERROR! unable to determine data file name for e=%d t=%d\n",e,tcur);
 	     return(1);
 	   }
 	 }
        }
        else { 
-	 /* Data set is not templated */
+	 /* Data set is not templated, only one data file to open*/
 	 ch = pfi->name;
 	 tmin = 1;
 	 tmax = pfi->dnum[3];
        }
        
        /* Open this GRIB file and position to start of first record */
-       if (!quiet) printf(" grib1map:  opening GRIB file: %s \n",ch);
+       if (!quiet) printf("gribmap: opening GRIB file %s \n",ch);
        gfile = fopen(ch,"rb");
        if (gfile==NULL) {
 	 if (pfi->tmplat) {
-	   if (!quiet) printf (" grib1map warning: could not open GRIB file: %s\n",ch);
-	   continue;
-	 } else {
-	   printf (" grib1map error: could not open GRIB file: %s\n",ch);
-	   return(1);
+	   if (!quiet) printf ("gribmap: Warning! could not open GRIB file %s\n",ch);
+	   fflush(stdout); continue;
+	 } 
+	 else {
+	   printf ("gribmap: ERROR! could not open GRIB file %s\n",ch);
+	   fflush(stdout); return(1);
 	 }
        }
        if (pfi->tmplat) gree(ch,"312");
@@ -282,7 +607,7 @@ gaint gribmap (void) {
 	 fseeko (gfile,(off_t)0,0);
 	 rc = fread (rec,1,100,gfile);
 	 if (rc<100) {
-	   printf (" grib1map error: I/O error reading header\n");
+	   printf ("gribmap: ERROR! I/O error reading header\n");
 	   return(1);
 	 }
 	 len = gagby(rec,88,4);
@@ -305,12 +630,12 @@ gaint gribmap (void) {
        
        /* see how we did */
        if (rc==50) {
-	 printf (" grib1map error: I/O error reading GRIB file\n");
-	 printf ("                 possible cause is premature EOF\n");
+	 printf ("gribmap: ERROR! I/O error reading GRIB file\n");
+	 printf ("                possible cause is premature EOF\n");
 	 break;
        }
        if (rc>1 && rc!=98) {
-	 printf (" grib1map error: GRIB file format error (rc = %i)\n",rc);
+	 printf ("gribmap: ERROR! GRIB file format error (rc = %i)\n",rc);
 	 return(rc);
        }
        
@@ -318,9 +643,10 @@ gaint gribmap (void) {
        if (!pfi->tmplat) break;
        
      } /* end of while (1) loop */
-   } /* end of for (e=1; e<=pfi->dnum[4]; e++) loop */
+     ens++;
+   } /* end of loop over ensemble members: for (e=1; e<=pfi->dnum[4]; e++) */
    
-   if (!quiet) printf (" grib1map:  reached end of files\n");
+   if (!quiet) printf ("gribmap: reached end of files\n");
    
    /* check if file closed already for case where template was set,
       but it was not templated and the template code above closed it. */
@@ -328,90 +654,121 @@ gaint gribmap (void) {
      fclose (gfile);
      gfile=NULL;
    }
-   
-   /* open the map file */
+
+   /* Write out the index file */
    if (write_map) {
-     mfile = fopen(pfi->mnam,"wb");
-     if (mfile==NULL) {
-       printf (" grib1map error: could not open index file: %s\n",pfi->mnam);
-       return(1);
-     } 
-     else {
-       if (!quiet) printf(" grib1map:  writing the map...\n\n");
-       /* output the map depending on version # */
-       if (g1ver==1 || g1ver==4) {
-	 fwrite (pindx,sizeof(struct gaindx),1,mfile);
-	 if (pindx->hinum>0)  fwrite(pindx->hipnt,sizeof(gaint),pindx->hinum,mfile);
-	 if (pindx->hfnum>0)  fwrite(pindx->hfpnt,sizeof(gafloat),pindx->hfnum,mfile);
-	 if (pindx->intnum>0) fwrite(pindx->intpnt,sizeof(gaint),pindx->intnum,mfile);
-	 if (pindx->fltnum>0) fwrite(pindx->fltpnt,sizeof(gafloat),pindx->fltnum,mfile);
-	 if (g1ver==4) {
-           if (pindxb->bignum>0) fwrite(pindxb->bigpnt,sizeof(off_t),pindxb->bignum,mfile);
-         }
-	 fclose (mfile);
-       }
-       else {
-	 rc = wtgmap();
-	 if (rc == 601) {
-	   printf(" grib1map error: overflow in float -> IBM float conversion\n");
-	   fclose (mfile);
-	   return (601); 
-	 }
-	 fclose (mfile);
-       }
-     }
+     rc = wtg1map(pfi,pindx,pindxb);
+     if (rc) return (rc);
    }
    return (didmatch);
- }
+
+ }  /* end of GRIB1 handling */
 
 #if GRIB2
- else /* GRIB2 */ {
+ /* * * * * * *
+  * * GRIB2 * *
+  * * * * * * */
+ else {
 
-   /* Set up g2index and initialize values */
+   /* Set up new g2index structure and initialize values */
    g2indx = (struct gag2indx *)malloc(sizeof(struct gag2indx));
    if (g2indx==NULL) {
-     printf ("gribmap error: unable to allocate memory for g2indx\n");
+     printf ("gribmap: ERROR! unable to allocate memory for g2indx\n");
      fflush(stdout);
      return(1);
    }
+   g2indx->version = g2ver; 
+   /* ng2elems is 2: fieldnum and file position are written into the map file for each record. 
+      Without bigflg, both of these numbers are integers;
+        g2intnum gets a factor of 2 (ng2elems) because the integer array contains both numbers. 
+      When bigflg is set, fieldnum is an integer, and fileposition is an off_t (large files);
+        g2intnum has a factor of 1 (ng2elems-1) because the integer array contains only fieldnum
+        and a separate array (g2bigpnt) is written out as off_t with file positions. */
    if (bigflg) {
-     g2indx->version = 2; 
-     g2indx->g2intnum =  (ng2elems-1) * pfi->trecs * pfi->dnum[3] * pfi->dnum[4];
+     g2indx->g2intnum = (ng2elems-1) * pfi->trecs * pfi->dnum[3] * pfi->dnum[4];
    } else {
-     g2indx->version = 1; 
      g2indx->g2intnum = ng2elems * pfi->trecs * pfi->dnum[3] * pfi->dnum[4];
    }
+   g2indx->bigflg = bigflg;
+   g2indx->trecs = pfi->trecs; 
+   g2indx->tsz = pfi->dnum[3];
+   g2indx->esz = pfi->dnum[4];
+   g2indx->g2intpnt = NULL;
+   g2indx->g2bigpnt = NULL;
+
+   /* allocate memory and intialize index arrays */
    g2indx->g2intpnt = (gaint *)malloc(sizeof(gaint)*g2indx->g2intnum);
    if (g2indx->g2intpnt==NULL) {
-     printf ("gribmap error: unable to allocate memory for g2indx->g2intpnt\n");
-     fflush(stdout);
-     goto err;
+     printf ("gribmap: ERROR! unable to allocate memory for g2indx->g2intpnt\n");
+     fflush(stdout); goto err;
    }
    for (i=0; i<g2indx->g2intnum; i++) g2indx->g2intpnt[i] = -999;
    if (bigflg) {
-     sz = pfi->trecs * pfi->dnum[3] * pfi->dnum[4];
-     g2indx->g2bigpnt = (off_t *)malloc(sizeof(off_t)*sz);
+     g2indx->g2bigpnt = (off_t *)malloc(sizeof(off_t)*g2indx->g2intnum);
      if (g2indx->g2bigpnt==NULL) {
-       printf ("gribmap error: unable to allocate memory for g2indx->g2bigpnt\n");
-       fflush(stdout);
-       goto err;
+       printf ("gribmap: ERROR! unable to allocate memory for g2indx->g2bigpnt\n");
+       fflush(stdout); goto err;
+     }
+     for (i=0; i<g2indx->g2intnum; i++) g2indx->g2bigpnt[i] = (off_t)-999;
+   }
+
+   if (update) {
+     /* copy the existing index data into new index buffer */
+     for (e=0; e < oldesz; e++ ) {
+       for (t=0; t < oldtsz; t++) {
+	 oldeoff = e * oldtrecs * oldtsz;
+	 oldioff = t * oldtrecs;
+	 eoff = e * g2indx->trecs * g2indx->tsz;
+	 ioff = t * g2indx->trecs;
+	 if (bigflg) {
+	   for (r=0; r<(ng2elems-1)*oldtrecs; r+=(ng2elems-1)) {
+	     oldi = (ng2elems-1)*(oldeoff+oldioff);
+	     i = (ng2elems-1)*(eoff+ioff);
+	     *(g2indx->g2bigpnt+i+r) = *(pfi->g2indx->g2bigpnt+oldi+r);
+	     *(g2indx->g2intpnt+i+r) = *(pfi->g2indx->g2intpnt+oldi+r);
+	   }
+	 } else {
+	   for (r=0; r<ng2elems*oldtrecs; r+=ng2elems) {
+	     oldi = ng2elems*(oldeoff+oldioff);
+	     i = ng2elems*(eoff+ioff);
+	     *(g2indx->g2intpnt+i+r+0) = *(pfi->g2indx->g2intpnt+oldi+r+0);
+	     *(g2indx->g2intpnt+i+r+1) = *(pfi->g2indx->g2intpnt+oldi+r+1);
+	   }
+	 }
+       }
+     }
+     /* set start points for axes that are being updated */
+     if (update==2) {                /* T only */
+       tstart = oldtsz;
+       estart = 1;
      }
-     for (i=0; i<sz; i++) g2indx->g2bigpnt[i] = (off_t)-999;
+     else if (update==3) {           /* E only */
+       tstart = 0; 
+       estart = oldesz + 1;
+     }
+     else {                          /* shouldn't get here, but just in case... */
+       tstart=0;
+       estart=1;
+     }
+   }
+   else {
+     /* start at the beginning when creating a new map file */
+     tstart=0;
+     estart=1;
    }
 
-   /* Break out point for case with E>1 but data files are only templated over T */
+   /* Break out point for case with E>1 but data files are only templated over T 
+      (all ensemble members are in one file) */
    if (pfi->dnum[4]>1 && pfi->tmplat==1) {
+     /* initialize a few things */
+     gfile = NULL;
+     e = 1;
+     ens = pfi->ens1; 
+     tcur = tstart;
+
      /* Loop over all files in the data set */ 
-     gfile=NULL;
-     e=1;
-     ens=pfi->ens1; 
-     tcur = 0;
-     while (1) {  /* loop over all times */
-       /* make sure no file is open */
-       if (gfile!=NULL) {
-	 fclose(gfile);
-	 gfile=NULL;
-       }
+     while (1) {      
+       if (gfile!=NULL) { fclose(gfile); gfile=NULL; }  /* make sure no file is open */
        if (tcur==0) { /* first time step */
 	 told = 0;
 	 tcur = 1;
@@ -419,14 +776,11 @@ gaint gribmap (void) {
        else {  /* tcur!=0 */
 	 told = pfi->fnums[(e-1)*pfi->dnum[3]+tcur-1];
 	 /* increment time step until fnums changes */
-	 while (told==pfi->fnums[(e-1)*pfi->dnum[3]+tcur-1] && tcur<=pfi->dnum[3]) {
-	   tcur++;
-	 }
+	 while (told==pfi->fnums[(e-1)*pfi->dnum[3]+tcur-1] && tcur<=pfi->dnum[3]) tcur++;
        }
        /* make sure we haven't advanced past end of time axis */
        if (tcur>pfi->dnum[3]) break;
-       
-       
+              
        /* Find the range of t indexes that have the same fnums value.
 	  These are the times that are contained in this particular file */
        tmin = tcur;
@@ -436,26 +790,26 @@ gaint gribmap (void) {
 	 while (fnum == pfi->fnums[(e-1)*pfi->dnum[3]+tmax]) tmax++;
 	 gr2t(pfi->grvals[3], (gadouble)tcur, &dtim); 
 	 gr2t(pfi->grvals[3], ens->gt, &dtimi);
-	 ch = gafndt(pfi->name, &dtim, &dtimi, pfi->abvals[3], pfi->pchsub1, pfi->ens1,tcur,e,&flag);
+	 ch = gafndt(pfi->name, &dtim, &dtimi, pfi->abvals[3], pfi->pchsub1, pfi->ens1, tcur, e, &flag);
 	 if (ch==NULL) {
-	   printf("gribmap error: couldn't determine data file name for e=%d t=%d\n",e,tcur);
-	   fflush(stdout);
-	   goto err;
+	   printf("gribmap: ERROR! couldn't determine data file name for e=%d t=%d\n",e,tcur);
+	   fflush(stdout); goto err;
 	 }
        }
-       /* Open this GRIB file and position to start of first record (s/b subroutine) */
+
+       /* Open this GRIB file and position to start of first record */
        if (!quiet) printf("gribmap: scanning GRIB2 file: %s \n",ch);
        fflush(stdout);
        gfile = fopen(ch,"rb");
        if (gfile==NULL) {
-	 if (!quiet) printf ("gribmap warning: could not open GRIB file: %s\n",ch);
-	 fflush(stdout);
-	 continue;
+	 if (!quiet) printf ("gribmap: Warning! could not open GRIB file: %s\n",ch);
+	 fflush(stdout); continue;
        }
        gree(ch,"f311a");
+
        /* Loop over fields in the grib file and find matches */
-       iseek=(off_t)0;
-       record=1;
+       iseek = (off_t)0;
+       record = 1;
        while (1) {
 	 /* move to next grib message in file */
 	 gaseekgb(gfile,iseek,32000,&lskip,&lgrib);
@@ -465,41 +819,35 @@ gaint gribmap (void) {
 	 sz = lgrib;
 	 cgrib = (unsigned char *)galloc(sz,"cgrib2");
 	 if (cgrib == NULL) {
-	   printf("gribmap error: unable to allocate memory for record %d at byte %jd\n",record,(intmax_t)iseek); 
-	   fflush(stdout);
-	   goto err;
+	   printf("gribmap: ERROR! unable to allocate memory for record %d at byte %jd\n",record,(intmax_t)iseek); 
+	   fflush(stdout); goto err;
 	 }
 	 ret = fseeko(gfile,lskip,SEEK_SET);
 	 lengrib = fread(cgrib,sizeof(unsigned char),lgrib,gfile);
 	 if (lengrib < lgrib) {
-	   printf("gribmap error: unable to read record %d at byte %jd\n",record,(intmax_t)iseek); 
-	   fflush(stdout);
-	   goto err;
+	   printf("gribmap: ERROR! unable to read record %d at byte %jd\n",record,(intmax_t)iseek); 
+	   fflush(stdout); goto err;
 	 }
 
          /* Check for ultra long length -- which we do not yet handle */
-
          if (gagby(cgrib,8,4)!=0 || gagbb(cgrib+12,0,1)!=0) {
-	   printf("gribmap error: grib2 record too long! record %d at byte %jd\n",record,(intmax_t)iseek); 
-	   fflush(stdout);
-	   goto err;
+	   printf("gribmap: ERROR! grib2 record too long! record %d at byte %jd\n",record,(intmax_t)iseek); 
+	   fflush(stdout); goto err;
          }
 	 
 	 /* Get info about grib2 message */
 	 ierr = 0;
 	 ierr = g2_info(cgrib,listsec0,listsec1,&numfields,&numlocal);
 	 if (ierr) {
-	   printf("gribmap error: g2_info failed: ierr=%d\n",ierr); 
-	   fflush(stdout);
-	   goto err;
+	   printf("gribmap: ERROR! g2_info failed: ierr=%d\n",ierr); 
+	   fflush(stdout); goto err;
 	 }
 	 for (n=0; n<numfields; n++) {
 	   ierr = 0;
 	   ierr = g2_getfld(cgrib,n+1,unpack,expand,&gfld);
 	   if (ierr) {
-	     printf("gribmap error: g2_getfld failed: ierr=%d\n",ierr); 
-	     fflush(stdout);
-	     goto err;
+	     printf("gribmap: ERROR! g2_getfld failed: ierr=%d\n",ierr); 
+	     fflush(stdout); goto err;
 	   }
 	   
 	   /* get statistical process type from grib field */
@@ -526,237 +874,240 @@ gaint gribmap (void) {
 	     g2_free(gfld);   	   
 	     break;
 	   }
-	   it = (it-1)*pfi->trecs;  /* number of records per time */
+	   it = (it-1)*pfi->trecs;  /* (it-1)*number of records per time */
 	   
 	   /* Check if the variable is a match */
 	   ioff = g2var_match(gfld,pfi,sp,sp2);
 	   if (ioff==-999) {
+	     if (verb) printf("\n");
 	     fflush(stdout);
 	     g2_free(gfld);   	   
 	     break;
 	   }
 	   
-	   /* check if ensemble codes match */
-	   e = g2ens_match(gfld,pfi);
-	   if (e==-999) {
+	   /* check if any ensemble codes match */
+	   ee = g2ens_match(gfld,pfi);
+	   if (ee==-999) {
+	     if (verb) printf("\n");
 	     fflush(stdout);
 	     g2_free(gfld);   	   
 	     break;
 	   }
-	   eoff = (e-1)*pfi->dnum[3]*pfi->trecs;  /* number of records per ensemble */
+	   eoff = (ee-1)*pfi->dnum[3]*pfi->trecs;  /* (ee-1)*number of records per ensemble */
 	   
 	   /* fill in the gribmap entry */
 	   if (verb) printf("  MATCH \n");
 	   fflush(stdout);
-	   g2fill (eoff,it+ioff,ng2elems,iseek,n+1,g2indx);
+	   g2fill (eoff, it+ioff, ng2elems, iseek, n+1, g2indx);
 	   g2_free(gfld); 
 	 }
 	 /* free memory containing grib record */
 	 gree(cgrib,"f310");
 	 cgrib=NULL;
-	 record++;                 /* increment grib record counter */
+	 record++;                    /* increment grib record counter */
 	 iseek = lskip+(off_t)lgrib;  /* increment byte offset to next grib msg in file */
        }  /* end of while(1) loop over all fields in the grib message*/
+
      } /* end of while loop over all times */
      
    }
    else {
-   /* All data sets except those that have E>1 but are templated only over T */
+     /* Begin handling for all other data sets */
 
-   /* Loop over all files in the data set */ 
-   gfile=NULL;
-   for (e=1,ens=pfi->ens1; e<=pfi->dnum[4]; e++,ens++) {
-     tcur = 0;
-     while (1) {  /* loop over all times for this ensemble */
-       if (pfi->tmplat) {
-	 /* make sure no file is open */
-	 if (gfile!=NULL) {
-	   fclose(gfile);
-	   gfile=NULL;
-	 }
-	 /* advance to first valid time step for this ensemble */
-	 if (tcur==0) {
-	   told = 0;
-	   tcur = 1;
-	   while (pfi->fnums[(e-1)*pfi->dnum[3]+tcur-1] == -1) tcur++;  
-	 }
-	 else {  /* tcur!=0 */
-	   told = pfi->fnums[(e-1)*pfi->dnum[3]+tcur-1];
-	   /* increment time step until fnums changes */
-	   while (told==pfi->fnums[(e-1)*pfi->dnum[3]+tcur-1] && tcur<=pfi->dnum[3]) {
-	     tcur++;
+     /* If updating the map, advance through chain of ensemble structures to starting point */
+     if (estart>1) {
+       ee=1;
+       ens=pfi->ens1; 
+       while (ee<estart) { ee++; ens++; } 
+     }
+     else {
+       ee=1;
+       ens=pfi->ens1; 
+     }
+     /* Begin looping over all files that need to be scanned in the data set */ 
+     gfile=NULL;
+     /* Loop over ensembles */
+     for (e=ee; e<=pfi->dnum[4]; e++) {
+       tcur = tstart;
+       /* Loop over all times for this ensemble */
+       while (1) {  
+	 if (pfi->tmplat) {
+	   /* make sure no file is open */
+	   if (gfile!=NULL) { fclose(gfile); gfile=NULL; }
+	   /* advance to first valid time step for this ensemble */
+	   if (tcur==0) {
+	     told = 0;
+	     tcur = 1;
+	     while (pfi->fnums[(e-1)*pfi->dnum[3]+tcur-1] == -1) tcur++;  
 	   }
-	 }
-	 
-	 /* make sure we haven't advanced past end of time axis */
-	 if (tcur>pfi->dnum[3]) break;
-	 
-	 /* check if we're past all valid time steps for this ensemble */
-	 if ((told != -1) && (pfi->fnums[(e-1)*pfi->dnum[3]+tcur-1] == -1)) break;
-	 
-	 /* Find the range of t indexes that have the same fnums value.
-	    These are the times that are contained in this particular file */
-	 tmin = tcur;
-	 tmax = tcur-1;
-	 fnum = pfi->fnums[(e-1)*pfi->dnum[3]+tcur-1];
-	 if (fnum != -1) {
-	   while (fnum == pfi->fnums[(e-1)*pfi->dnum[3]+tmax]) tmax++;
-	   gr2t(pfi->grvals[3], (gadouble)tcur, &dtim); 
-	   gr2t(pfi->grvals[3], ens->gt, &dtimi);
-	   ch = gafndt(pfi->name, &dtim, &dtimi, pfi->abvals[3], pfi->pchsub1, pfi->ens1,tcur,e,&flag);
-	   if (ch==NULL) {
-	     printf("gribmap error: couldn't determine data file name for e=%d t=%d\n",e,tcur);
-	     fflush(stdout);
-	     goto err;
+	   else {  /* tcur!=0 */
+	     told = pfi->fnums[(e-1)*pfi->dnum[3]+tcur-1];
+	     /* increment time step until fnums changes */
+	     while (told==pfi->fnums[(e-1)*pfi->dnum[3]+tcur-1] && tcur<=pfi->dnum[3]) tcur++;
+	   }
+	   /* make sure we haven't advanced past end of time axis */
+	   if (tcur>pfi->dnum[3]) break;
+	   /* check if we're past all valid time steps for this ensemble */
+	   if ((told != -1) && (pfi->fnums[(e-1)*pfi->dnum[3]+tcur-1] == -1)) break;
+	   /* Find the range of t indexes that have the same fnums value.
+	      These are the times that are contained in this particular file */
+	   tmin = tcur;
+	   tmax = tcur-1;
+	   fnum = pfi->fnums[(e-1)*pfi->dnum[3]+tcur-1];
+	   if (fnum != -1) {
+	     while (fnum == pfi->fnums[(e-1)*pfi->dnum[3]+tmax]) tmax++;
+	     gr2t(pfi->grvals[3], (gadouble)tcur, &dtim); 
+	     gr2t(pfi->grvals[3], ens->gt, &dtimi);
+	     ch = gafndt(pfi->name, &dtim, &dtimi, pfi->abvals[3], pfi->pchsub1, pfi->ens1, tcur, e, &flag);
+	     if (ch==NULL) {
+	       printf("gribmap: ERROR! Unable to determine data file name for e=%d t=%d\n",e,tcur);
+	       fflush(stdout); goto err;
+	     }
 	   }
 	 }
-       }
-       else {  
-	 /* only one data file to open */
-	 ch = pfi->name;
-	 tmin = 1;
-	 tmax = pfi->dnum[3];
-       }
-       
-       /* Open this GRIB file and position to start of first record (s/b subroutine) */
-       if (!quiet) printf("gribmap: scanning GRIB2 file: %s \n",ch);
-       fflush(stdout);
-       gfile = fopen(ch,"rb");
-       if (gfile==NULL) {
-	 if (pfi->tmplat) {
-	   if (!quiet) printf ("gribmap warning: could not open GRIB file: %s\n",ch);
-	   fflush(stdout);
-	   continue;
-	 }
-	 else {
-	   printf ("gribmap error: could not open GRIB file: %s\n",ch);
-	   fflush(stdout);
-	   goto err;
+	 else {  
+	   /* not templated -- only one data file to open */
+	   ch = pfi->name;
+	   tmin = 1;
+	   tmax = pfi->dnum[3];
 	 }
-       }
-       if (pfi->tmplat) gree(ch,"f311");
-       
-       /* Loop over fields in the grib file and find matches */
-       iseek=(off_t)0;
-       record=1;
-       while (1) {
-	 /* move to next grib message in file */
-	 gaseekgb(gfile,iseek,32000,&lskip,&lgrib);
-	 if (lgrib == 0) break;    /* end loop at EOF or problem */
 	 
-	 /* read the message into memory */
-	 sz = lgrib;
-	 cgrib = (unsigned char *)galloc(sz,"cgrib2");
-	 if (cgrib == NULL) {
-	   printf("gribmap error: unable to allocate memory for record %d at byte %jd\n",record,(intmax_t)iseek); 
-	   fflush(stdout);
-	   goto err;
-	 }
-	 ret = fseeko(gfile,lskip,SEEK_SET);
-	 lengrib = fread(cgrib,sizeof(unsigned char),lgrib,gfile);
-	 if (lengrib < lgrib) {
-	   printf("gribmap error: unable to read record %d at byte %jd\n",record,(intmax_t)iseek); 
-	   fflush(stdout);
-	   goto err;
+	 /* Open this GRIB file and position to start of first record */
+	 if (!quiet) printf("gribmap: scanning GRIB2 file: %s \n",ch);
+	 fflush(stdout);
+	 gfile = fopen(ch,"rb");
+	 if (gfile==NULL) {
+	   if (pfi->tmplat) {
+	     if (!quiet) printf ("gribmap: Warning! could not open GRIB file: %s\n",ch);
+	     fflush(stdout); continue;
+	   }
+	   else {
+	     printf ("gribmap: ERROR! could not open GRIB file: %s\n",ch);
+	     fflush(stdout); goto err;
+	   }
 	 }
-
-         /* Check for ultra long length -- which we do not yet handle */
-         if (gagby(cgrib,8,4)!=0 || gagbb(cgrib+12,0,1)!=0) {
-	   printf("gribmap error: grib2 record length too long! record %d at byte %jd\n",record,(intmax_t)iseek); 
-	   fflush(stdout);
-	   goto err;
-         }
+	 if (pfi->tmplat) gree(ch,"f311");
 	 
-	 /* Get info about grib2 message */
-	 ierr = 0;
-	 ierr = g2_info(cgrib,listsec0,listsec1,&numfields,&numlocal);
-	 if (ierr) {
-	   printf("gribmap error: g2_info failed: ierr=%d\n",ierr); 
-	   fflush(stdout);
-	   goto err;
-	 }
-	 for (n=0; n<numfields; n++) {
-	   ierr = 0;
-	   ierr = g2_getfld(cgrib,n+1,unpack,expand,&gfld);
-	   if (ierr) {
-	     printf("gribmap error: g2_getfld failed: ierr=%d\n",ierr); 
-	     fflush(stdout);
-	     goto err;
-	   }
-	   
-	   /* get statistical process type from grib field */
-	   sp = g2sp(gfld);
-	   sp2 = g2sp2(gfld);
+	 /* Loop over fields in the grib file and find matches */
+	 iseek=(off_t)0;
+	 record=1;
+	 while (1) {
+	   /* move to next grib message in file */
+	   gaseekgb(gfile,iseek,32000,&lskip,&lgrib);
+	   if (lgrib == 0) break;    /* end loop at EOF or problem */
 	   
-	   /* print out useful codes from grib2 field */
-	   if (verb) g2prnt(gfld,record,n+1,sp,sp2);
-	     
-	   /* Check grid properties */
-	   rc = g2grid_check(gfld,pfi,record,n+1);
-	   if (rc) {
-	     if (verb) printf("\n");
-	     fflush(stdout);
-	     g2_free(gfld);   	   
-	     break; 
+	   /* read the message into memory */
+	   cgrib = (unsigned char *)galloc(lgrib,"cgrib2");
+	   if (cgrib == NULL) {
+	     printf("gribmap: ERROR! malloc failed for record %d at byte %jd\n",record,(intmax_t)iseek); 
+	     fflush(stdout); goto err;
+	   }
+	   ret = fseeko(gfile,lskip,SEEK_SET);
+	   lengrib = fread(cgrib,sizeof(unsigned char),lgrib,gfile);
+	   if (lengrib < lgrib) {
+	     printf("gribmap: ERROR! unable to read record %d at byte %jd\n",record,(intmax_t)iseek); 
+	     fflush(stdout); goto err;
 	   }
 	   
-	   /* Check time values in grib field */
-	   it = g2time_check(gfld,listsec1,pfi,record,n+1,tmin,tmax);
-	   if (it==-99) {
-	     if (verb) printf("\n");
-	     fflush(stdout);
-	     g2_free(gfld);   	   
-	     break;
+	   /* Check for ultra long length -- which we do not yet handle */
+	   if (gagby(cgrib,8,4)!=0 || gagbb(cgrib+12,0,1)!=0) {
+	     printf("gribmap: ERROR! grib2 record length too long! record %d at byte %jd\n",record,(intmax_t)iseek); 
+	     fflush(stdout); goto err;
 	   }
-	   it = (it-1)*pfi->trecs;  /* number of records per time */
 	   
-	   /* Check if the variable is a match */
-	   ioff = g2var_match(gfld,pfi,sp,sp2);
-	   if (ioff==-999) {
-	     fflush(stdout);
-	     g2_free(gfld);   	   
-	     break;
+	   /* Get info about grib2 message */
+	   ierr = 0;
+	   ierr = g2_info(cgrib,listsec0,listsec1,&numfields,&numlocal);
+	   if (ierr) {
+	     printf("gribmap: ERROR! g2_info failed: ierr=%d\n",ierr); 
+	     fflush(stdout); goto err;
 	   }
-	   if (pfi->tmplat) {
-	     /* make sure grib codes match for this ensemble */
-	     rc = g2ens_check(ens,gfld);
-	     if (rc==1) {
+	   for (n=0; n<numfields; n++) {
+	     ierr = 0;
+	     ierr = g2_getfld(cgrib,n+1,unpack,expand,&gfld);
+	     if (ierr) {
+	       printf("gribmap: ERROR! g2_getfld failed: ierr=%d\n",ierr); 
+	       fflush(stdout); goto err;
+	     }
+	     
+	     /* get statistical process type from grib field */
+	     sp = g2sp(gfld);
+	     sp2 = g2sp2(gfld);
+	     
+	     /* print out useful codes from grib2 field */
+	     if (verb) g2prnt(gfld,record,n+1,sp,sp2);
+	     
+	     /* Check grid properties */
+	     rc = g2grid_check(gfld,pfi,record,n+1);
+	     if (rc) {
+	       if (verb) printf("\n");
+	       fflush(stdout);
+	       g2_free(gfld);   	   
+	       break; 
+	     }
+	     
+	     /* Check time values in grib field */
+	     it = g2time_check(gfld,listsec1,pfi,record,n+1,tmin,tmax);
+	     if (it==-99) {
+	       if (verb) printf("\n");
 	       fflush(stdout);
 	       g2_free(gfld);   	   
 	       break;
 	     }
-	   } 
-	   else {
-	     /* check if ensemble codes match */
-	     e = g2ens_match(gfld,pfi);
-	     if (e==-999) {
+	     it = (it-1)*pfi->trecs;  /* number of records per time */
+	     
+	     /* Check if the variable is a match */
+	     ioff = g2var_match(gfld,pfi,sp,sp2);
+	     if (ioff==-999) {
+	       if (verb) printf("\n");
 	       fflush(stdout);
 	       g2_free(gfld);   	   
 	       break;
 	     }
+	     if (pfi->tmplat) {
+	       /* make sure grib codes match for this ensemble */
+	       rc = g2ens_check(ens,gfld);
+	       if (rc==1) {
+		 if (verb) printf("\n");
+		 fflush(stdout);
+		 g2_free(gfld);   	   
+		 break;
+	       }
+	       else ee = e; 
+	     } 
+	     else {
+	       /* check if any ensemble codes match */
+	       ee = g2ens_match(gfld,pfi);
+	       if (ee==-999) {
+		 if (verb) printf("\n");
+		 fflush(stdout);
+		 g2_free(gfld);   	   
+		 break;
+	       }
+	     }
+	     eoff = (ee-1)*pfi->dnum[3]*pfi->trecs;  /* (ee-1)*number of records per ensemble */
+	     
+	     /* fill in the gribmap entry */
+	     if (verb) printf("  MATCH \n");
+	     fflush(stdout);
+	     g2fill (eoff,it+ioff,ng2elems,lskip,n+1,g2indx);
+	     g2_free(gfld); 
+	     
 	   }
-	   eoff = (e-1)*pfi->dnum[3]*pfi->trecs;  /* number of records per ensemble */
-
-	   /* fill in the gribmap entry */
-	   if (verb) printf("  MATCH \n");
-	   fflush(stdout);
-	   g2fill (eoff,it+ioff,ng2elems,lskip,n+1,g2indx);
-	   g2_free(gfld); 
-
-	 }
-	 /* free memory containing grib record */
-	 gree(cgrib,"f310");
- 	 cgrib=NULL;
-	 record++;                 /* increment grib record counter */
-	 iseek = lskip+(off_t)lgrib;   /* increment byte offset to next grib msg in file */
-
-       }  /* end of while(1) loop over all fields in the grib message*/
-
-       /* break out if not templating -- only need to scan one grib file */
-       if (!pfi->tmplat) goto done;
-
-     } /* end of while(1) loop over all grib files for a given ensemble member*/
-   } /* end of loop over ensemble members: for (e=1,ens=pfi->ens1; e<=pfi->dnum[4]; e++,ens++) */
+	   /* free memory containing grib record */
+	   gree(cgrib,"f310");
+	   cgrib=NULL;
+	   record++;                     /* increment grib record counter */
+	   iseek = lskip+(off_t)lgrib;   /* increment byte offset to next grib msg in file */
+	   
+	 }  /* end of while(1) loop over all fields in the grib message*/
+	 
+	 /* break out if not templating -- only need to scan one grib file */
+	 if (!pfi->tmplat) goto done;
+	 
+       } /* end of while(1) loop over all grib files for a given ensemble member*/
+       ens++;
+     } /* end of loop over ensemble members: for (e=1; e<=pfi->dnum[4]; e++) */
    } /* end of else statement for if (pfi->dnum[4]>1 && pfi->tmplat==1)  */
    
    if (!quiet) printf ("gribmap: reached end of files\n");
@@ -772,14 +1123,18 @@ done:
    
    /* Write out the index file */
    if (write_map) {
-     rc=wtg2map(pfi,g2indx);
+     rc = wtg2map(pfi,g2indx);
      if (rc) return (rc);
    }
+
    return(0);
    
 err: 
-   if (g2indx->g2intpnt) gree(g2indx->g2intpnt,"f314");
-   if (g2indx) gree(g2indx,"f315");
+   if (g2indx) {
+     if (g2indx->g2intpnt) gree(g2indx->g2intpnt,"f314");
+     if (g2indx->g2bigpnt) gree(g2indx->g2bigpnt,"f314");
+     gree(g2indx,"f315");
+   }
    if (cgrib) gree(cgrib,"f316");
    return(1);
  }
@@ -821,7 +1176,7 @@ gaint gribhdr (struct grhdr *ghdr) {
  } 
  
  if (i == scanlim) {
-   printf("grib1map error: GRIB header not found in scanning between records\n");
+   printf("gribmap: ERROR! GRIB header not found in scanning between records\n");
    printf("                try increasing the value of the -s argument\n");
 
    if (scaneof) return(98);
@@ -846,7 +1201,7 @@ gaint gribhdr (struct grhdr *ghdr) {
  cpos = fpos;
  ghdr->vers = gagby(rec,7,1);
  if (ghdr->vers>1) {
-   printf ("grib1map error: file is not GRIB version 0 or 1, version number is %i\n",ghdr->vers);
+   printf ("gribmap: ERROR! file is not GRIB version 0 or 1, version number is %i\n",ghdr->vers);
    if (scaneof) return(98);
    return (99);
  }
@@ -1234,17 +1589,21 @@ gaint gribrec (struct grhdr *ghdr, struct gafile *pfi, struct gaindx *pindx,
 }
 
 
-/* Routine to fill in values for this record, now that we have found how it matches.  
-   We are not handling the time aspect as yet */
+/* Routine to fill in the index values for this record, now that we have found that it matches.  */
 
 void gribfill (gaint eoff, gaint ioff, gaint joff, gaint nsiz, struct grhdr *ghdr, struct gaindx *pindx) {
 gaint boff,koff;
 
-  koff = nsiz*(eoff+ioff) + joff;
+/* the variable nsiz=nrec*ng1elems; 
+   nrec=1 unless we're dealing with gribgrd 29 which has 2 grids per record so nrec=2 
+   ng1elems=3 */
+  koff = nsiz*(eoff+ioff) + joff;   /* use this when bigflg is not set */
   if (bigflg) {
+    /* ldpos and lbpos are type off_t instead of int */
     boff = 2*(eoff+ioff) + joff;
     *(pindxb->bigpnt+boff) = ghdr->ldpos;
     if (ghdr->bmsflg) *(pindxb->bigpnt+boff+1) = ghdr->lbpos;
+    /* bnum is still written out as an int */
     boff = (eoff+ioff) + joff;
     *(pindx->intpnt+boff) = ghdr->bnum;
   } else {
@@ -1280,7 +1639,9 @@ void gribpr(struct grhdr *ghdr) {
 }
 
 
-/* Routine to write out machine independent grib1 map file */
+/* Routine to write out machine independent grib1 map file
+   This subroutine was used with g1ver=2 or 3, but is now deprecated with g1ver=5. 
+ */
 
 gaint wtgmap(void) {
 gaint i,nb,bcnt,idum;
@@ -1304,7 +1665,7 @@ unsigned char ibmfloat[4];
  /* allocate space for the map */
  map = (unsigned char *)malloc(nb);
  if (map == NULL) {
-   fprintf(stderr,"grib1map error: memory allocation error creating the map\n");
+   fprintf(stderr,"gribmap: ERROR! memory allocation error creating the map\n");
    return(60);
  }
 
@@ -1384,6 +1745,62 @@ void putint(gaint dum, unsigned char *buf, gaint *off) {
  
 }
 
+/* New routine to write out a GRIB1 map file (for g1ver 4+) */
+
+gaint wtg1map(struct gafile *pfi, struct gaindx *pindx, struct gaindxb *pindxb) {
+  FILE *mfile=NULL;
+  gaint rc;
+
+  mfile = fopen(pfi->mnam,"wb");
+  if (mfile==NULL) {
+    printf ("gribmap: ERROR! Could not create GRIB1 index file: %s\n",pfi->mnam); 
+    return(1);
+  } 
+  printf("gribmap: writing the GRIB1 index file (version %d) \n",pindx->type);
+
+  rc = fwrite (pindx,sizeof(struct gaindx),1,mfile);
+  if (rc!=1) {
+    printf("gribmap: ERROR! Unable to write pindx structure to GRIB1 index file\n");
+    fflush(stdout); return(1);
+  }  
+  if (pindx->hinum>0) {
+    rc = fwrite(pindx->hipnt,sizeof(gaint),pindx->hinum,mfile);
+    if (rc!=pindx->hinum) {
+      printf("gribmap: ERROR! Unable to write header integers to GRIB1 index file\n");
+      fflush(stdout); return(1);
+    }  
+  }
+  if (pindx->hfnum>0) {
+    rc = fwrite(pindx->hfpnt,sizeof(gafloat),pindx->hfnum,mfile);
+    if (rc!=pindx->hfnum) {
+      printf("gribmap: ERROR! Unable to write header floats to GRIB1 index file\n");
+      fflush(stdout); return(1);
+    }  
+  }
+  if (pindx->intnum>0) {
+    rc = fwrite(pindx->intpnt,sizeof(gaint),pindx->intnum,mfile);
+    if (rc!=pindx->intnum) {
+      printf("gribmap: ERROR! Unable to write index integers to GRIB1 index file\n");
+      fflush(stdout); return(1);
+    }  
+  }
+  if (pindx->fltnum>0) {
+    rc = fwrite(pindx->fltpnt,sizeof(gafloat),pindx->fltnum,mfile);
+    if (rc!=pindx->fltnum) {
+      printf("gribmap: ERROR! Unable to write index floats to GRIB1 index file\n");
+      fflush(stdout); return(1);
+    }  
+  }
+  if (pindxb->bignum>0) {
+    rc = fwrite(pindxb->bigpnt,sizeof(off_t),pindxb->bignum,mfile);
+    if (rc!=pindxb->bignum) {
+      printf("gribmap: ERROR! Unable to write index off_ts to GRIB1 index file\n");
+      fflush(stdout); return(1);
+    }  
+  }
+  fclose (mfile);
+  return(0);
+}
 
 #if GRIB2
 
@@ -1391,7 +1808,7 @@ void putint(gaint dum, unsigned char *buf, gaint *off) {
 void g2fill (gaint eoff, gaint ioff, gaint ng2elems, off_t iseek, g2int fldnum, 
 		struct gag2indx *g2indx) {
 gaint joff;
-  if (g2indx->version == 2) {
+  if (g2indx->bigflg) {
     joff = eoff+ioff;
     ioff = (ng2elems-1)*(eoff+ioff);
     *(g2indx->g2bigpnt+joff) = iseek;
@@ -1403,66 +1820,90 @@ gaint joff;
   }
 }
 
-/* Routine to write out grib2 index file 
+/* Routine to write out grib2 index file. 
+   All versions of the index file are machine dependent. 
+   A test to see if byte-swapping is required is done
+   in gaddes.c, when the data descriptor file is opened. 
 
-     g2ver=1 : machine dependent. contains the version number, followed by 
+     g2ver=1 : contains the version number, followed by 
                the array size N, followed by the array of N numbers. 
                All are 4-byte integers (type gaint). 
-     g2ver=2 : machine dependent. contains the version number, followed by 
+     g2ver=2 : contains the version number, followed by 
                the array size N, followed by the array of N numbers that are
                4 byte ints, followed by an array of N numbers that are 8 byte 
                off_t integers.
-
-     A test to see if byte-swapping is required	to read the index file is done
-     in gaddes.c, when the data descriptor file is opened. 
+     g2ver=3 : contains the version number, 
+               followed by five integers: bigflg, trecs, tsz, esz, array size (N), 
+	       then the arrays of index values (N integers).
+               If bigflg is set, then off_t array is in use.
 */
-
-
 gaint wtg2map(struct gafile *pfi, struct gag2indx *g2indx) {
   FILE *mfile;
-  gaint rc;
+  gaint rc,i;
   
-  /* open the index file */
+  /* open the index file for writing */
   mfile = fopen(pfi->mnam,"wb");
   if (mfile==NULL) {
-    printf ("error: Unable to open index file: %s\n",pfi->mnam);
-    fflush(stdout);
-    return(1);
+    printf ("gribmap: Error! Unable to open index file: %s\n",pfi->mnam);
+    fflush(stdout); return(1);
   } 
-  
-  printf("gribmap: Writing out the index file \n");
+  printf("gribmap: Writing out the GRIB2 index file (version %d)\n",g2indx->version);
   /* write the version number */
   rc = fwrite(&g2indx->version, sizeof(gaint),1,mfile);
   if (rc!=1) {
-    printf("error: Unable to write version number to index file, rc=%d \n",rc);
-    fflush(stdout);
-    return(1);
+    printf("gribmap: ERROR! Unable to write version number to index file, rc=%d \n",rc);
+    fflush(stdout); return(1);
   }  
+  if (g2indx->version>1) {
+    /* write bigflg */
+    rc = fwrite(&g2indx->bigflg, sizeof(gaint),1,mfile);
+    if (rc!=1) {
+      printf("gribmap: ERROR! Unable to write bigflg to index file, rc=%d \n",rc);
+      fflush(stdout); return(1);
+    }  
+    /* write trecs */
+    rc = fwrite(&g2indx->trecs, sizeof(gaint),1,mfile);
+    if (rc!=1) {
+      printf("gribmap: ERROR! Unable to write trecs to index file, rc=%d \n",rc);
+      fflush(stdout); return(1);
+    }  
+    /* write tsz */
+    rc = fwrite(&g2indx->tsz, sizeof(gaint),1,mfile);
+    if (rc!=1) {
+      printf("gribmap: ERROR! Unable to write tsz to index file, rc=%d \n",rc);
+      fflush(stdout); return(1);
+    }  
+    /* write esz */
+    rc = fwrite(&g2indx->esz, sizeof(gaint),1,mfile);
+    if (rc!=1) {
+      printf("gribmap: ERROR! Unable to write esz to index file, rc=%d \n",rc);
+      fflush(stdout); return(1);
+    }  
+  }
   /* write the array size */
   rc = fwrite(&g2indx->g2intnum,sizeof(gaint),1,mfile);
   if (rc!=1) {
-    printf("error: Unable to write g2intnum to index file, rc=%d \n",rc);
-    fflush(stdout);
-    return(1);
+    printf("gribmap: ERROR! Unable to write g2intnum to index file, rc=%d \n",rc);
+    fflush(stdout); return(1);
   }  
-  /* writhe the array of index values */
+  /* write the the array of index values */
   rc = fwrite(g2indx->g2intpnt,sizeof(gaint),g2indx->g2intnum,mfile);
   if (rc!=g2indx->g2intnum) {
-    printf("error: Unable to write g2intpnt to index file, rc=%d \n",rc);
-    fflush(stdout);
-    return(1);
+    printf("gribmap: ERROR! Unable to write g2intpnt to index file, rc=%d \n",rc);
+    fflush(stdout); return(1);
   }  
-
-  /* if version 2, write the the array of off_t values */
-  if (g2indx->version==2) {
-    rc = fwrite(g2indx->g2bigpnt,sizeof(off_t),g2indx->g2intnum,mfile);
-    if (rc!=g2indx->g2intnum) {
-      printf("error: Unable to write g2bigpnt to index file, rc=%d \n",rc);
-      fflush(stdout);
-      return(1);
-    }  
+  if (g2indx->version>1) {
+    /* if bigflg is set, write the the array of off_t values */
+    if (g2indx->bigflg==1) {
+      rc = fwrite(g2indx->g2bigpnt,sizeof(off_t),g2indx->g2intnum,mfile);
+      if (rc!=g2indx->g2intnum) {
+	printf("gribmap: ERROR! Unable to write g2bigpnt to index file, rc=%d \n",rc);
+	fflush(stdout); return(1);
+      }  
+    }
   }
   fclose(mfile);
+
   return(0);
   
 }
@@ -1509,7 +1950,7 @@ gaint xsize=0,ysize=0;
 gaint g2time_check (gribfield *gfld, g2int *listsec1, struct gafile *pfi, 
 		    gaint r, gaint f, gaint tmin, gaint tmax) {
   struct dt tref,tfld,tvalid;
-  gaint it,tfield,trui_idx,endyr_idx;
+  gaint it,tfield,trui_idx,endyr_idx=0;
   gafloat t;
   gadouble v1,delta;
   /* Get reference time from Section 1 of GRIB message */
@@ -1554,10 +1995,11 @@ gaint g2time_check (gribfield *gfld, g2int *listsec1, struct gafile *pfi,
     }
     /* For fields that are statistically processed over a time interval 
        e.g. averages, accumulations, extremes, et al. */
-    else if (gfld->ipdtnum == 8 || gfld->ipdtnum==9 || gfld->ipdtnum==11 || gfld->ipdtnum==12) {
+    else if (gfld->ipdtnum>=8 && gfld->ipdtnum<=12) {
       trui_idx=7; 
       if      (gfld->ipdtnum==8)  endyr_idx=15;
       else if (gfld->ipdtnum==9)  endyr_idx=22;
+      else if (gfld->ipdtnum==10) endyr_idx=16;
       else if (gfld->ipdtnum==11) endyr_idx=18;
       else if (gfld->ipdtnum==12) endyr_idx=17;
 
@@ -1621,6 +2063,7 @@ gaint g2time_check (gribfield *gfld, g2int *listsec1, struct gafile *pfi,
 	   tvalid.yr,tvalid.mo,tvalid.dy,tvalid.hr,tvalid.mn,it,tmin,tmax);
     return(-99);
   }
+  if (verb) printf("valid at %4d-%02d-%02d-%02d:%02d (t=%d)",tvalid.yr,tvalid.mo,tvalid.dy,tvalid.hr,tvalid.mn,it);
   return (it);
 }
 
@@ -1629,9 +2072,9 @@ gaint g2time_check (gribfield *gfld, g2int *listsec1, struct gafile *pfi,
 
 gaint g2var_match (gribfield *gfld, struct gafile *pfi, gaint sp, gaint sp2) {
   struct gavar *pvar;
-  gadouble lev1,lev2,z,ll,ul;
+  gadouble lev1,lev2,z;
   gadouble (*conv) (gadouble *, gadouble);
-  gaint rc1,rc2,rc3,rc4,rc5,rc6,lev_idx,match;
+  gaint rc1,rc2,rc3,rc4,rc5,rc6,lev_idx;
   gaint i,ioff,iz;
   
   lev_idx=9;
@@ -1749,6 +2192,10 @@ gaint g2a_check (gribfield *gfld, struct gavar *pvar) {
 	match=1;
     }
   }
+  /* percentile forecasts */
+  else if (gfld->ipdtnum==6 || gfld->ipdtnum==10) {
+    if ((gaint)pvar->units[16]==(gaint)gfld->ipdtmpl[15]) match=1; /* percentiles match */
+  }
   /* optical properties of aerosol */
   else if (gfld->ipdtnum==48) {
     s1 = scaled2dbl(gfld->ipdtmpl[4],gfld->ipdtmpl[5]);
@@ -1795,44 +2242,39 @@ gaint g2a_check (gribfield *gfld, struct gavar *pvar) {
   return(match);
 }
 
-/* Loops over ensembles to see if ensemble codes match current grib2 field 
-   If size of ensemble dimension is 1, no checks are done, returns e=1.
+/* Loops over ensembles to see if any of the ensemble codes match current grib2 field.
    Returns ensemble index e if codes are present and match, -999 otherwise */
 gaint g2ens_match (gribfield *gfld, struct gafile *pfi) {
   struct gaens *ens;
   gaint e;
   e=1;
-  if (pfi->dnum[4]==1) {
-    e=1;
-    return(e); 
-  }
-  else {
-    for (e=1,ens=pfi->ens1; e<=pfi->dnum[4]; e++,ens++) {
-      /* No grib codes and not an ensemble PDT */
-      if (ens->grbcode[0]==-999 && ens->grbcode[1]==-999 &&
-	  (gfld->ipdtnum!=1 && gfld->ipdtnum!=2 && gfld->ipdtnum!=11 && gfld->ipdtnum!=12)) {    
-	return(e);
-      }
-      if (ens->grbcode[0]>-900) {
-	if (ens->grbcode[1]>-900) {
-	  /* PDT 1 or 11 */
-	  if ((gfld->ipdtnum==1 || gfld->ipdtnum==11) &&
-	      ((ens->grbcode[0] == gfld->ipdtmpl[15]) && 
-	       (ens->grbcode[1] == gfld->ipdtmpl[16]))) {
-	    return(e);
-	  }
+  ens=pfi->ens1;
+  for (e=1; e<=pfi->dnum[4]; e++) {
+    if (ens->grbcode[0]>-900) {
+      if (ens->grbcode[1]>-900) {
+	/* PDT 1 or 11 */
+	if ((gfld->ipdtnum==1 || gfld->ipdtnum==11) &&
+	    ((ens->grbcode[0] == gfld->ipdtmpl[15]) && 
+	     (ens->grbcode[1] == gfld->ipdtmpl[16]))) {
+	  return(e);
 	}
-	else {
-	  /* PDT 2 or 12 */
-	  if ((gfld->ipdtnum==2 || gfld->ipdtnum==12) &&
-	      (ens->grbcode[0] == gfld->ipdtmpl[15])) {
-	    return(e);
-	  }
+      }
+      else {
+	/* PDT 2 or 12 */
+	if ((gfld->ipdtnum==2 || gfld->ipdtnum==12) &&
+	    (ens->grbcode[0] == gfld->ipdtmpl[15])) {
+	  return(e);
 	}
       }
     }
-    return(-999);
+    /* No grib codes and not an ensemble PDT */
+    if (ens->grbcode[0]==-999 && ens->grbcode[1]==-999 &&
+	(gfld->ipdtnum!=1 && gfld->ipdtnum!=2 && gfld->ipdtnum!=11 && gfld->ipdtnum!=12)) {    
+      return(e);
+    }
+    ens++;
   }
+  return(-999);
 }
 
 /* Checks ensemble codes, if provided in descriptor file. 
@@ -1894,7 +2336,7 @@ void g2prnt (gribfield *gfld, gaint r, g2int f, gaint sp, gaint sp2) {
   /* print record/field number */
   printf("%d.%ld: ",r,f);
   /* print level info */
-  if (gfld->ipdtmpl[lev_idx+1]==-127) 
+  if (gfld->ipdtmpl[lev_idx+1]<0) 
     printf("lev1=%ld ",gfld->ipdtmpl[lev_idx]); /* just print the level1 type */
   else
     printf("lev1=%ld,%g ",gfld->ipdtmpl[lev_idx],scaled2dbl(gfld->ipdtmpl[lev_idx+1],gfld->ipdtmpl[lev_idx+2]));
diff --git a/src/gagmap.h b/src/gagmap.h
index cd2da82..56381b8 100644
--- a/src/gagmap.h
+++ b/src/gagmap.h
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 #ifndef DRIVER_GAGMAP
@@ -10,6 +9,7 @@
 
 WHERE FILE *gfile;
 WHERE FILE *mfile;
+WHERE FILE *exmfile;
 
 /* Following structures hold all the unpacked header info from a grib record. */
 
@@ -72,6 +72,8 @@ WHERE gaint scaneof;        /* option to ignore failure to find data at end of f
 WHERE gaint scanEOF;        /* option to ignore failure to find data at end of file */
 WHERE gaint scanlim;        /* the default # of max bytes between records */
 WHERE gaint notau;          /* force time to be base time */
+WHERE gaint upgrade;        /* create newer version of existing index file */
+WHERE gaint downgrade;      /* create older version of existing index file */
 WHERE gaint tauflg;         /* search for a fixed tau in filling the 4-D volume */
 WHERE gaint tauoff;         /* the fixed tau in h */
 WHERE gaint tau0;           /* set the base dtg for tau search */
@@ -113,6 +115,7 @@ extern void gribpr (struct grhdr *);
 /* function prototypes */
 gaint wtgmap(void) ;
 void  putint(gaint, unsigned char *,gaint *) ;
+gaint wtg1map(struct gafile *, struct gaindx *, struct gaindxb *);
 #if GRIB2
 void  g2fill (gaint, gaint, gaint, off_t, g2int, struct gag2indx *);
 gaint wtg2map (struct gafile *, struct gag2indx *);
diff --git a/src/gagui.c b/src/gagui.c
index a31a005..94a042b 100644
--- a/src/gagui.c
+++ b/src/gagui.c
@@ -66,7 +66,6 @@ extern struct gacmn gcmn;
 #include "gagui.h"
 
 static char default_var[128];         /* default variable for display */
-
 static char last_path_open[512];      /* remember last path names */
 static char last_path_sdfopen[512];
 static char last_path_exec[512];
diff --git a/src/gagx.c b/src/gagx.c
index ddb64d7..6896e16 100644
--- a/src/gagx.c
+++ b/src/gagx.c
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 /* Authored by B. Doty */
@@ -72,7 +71,7 @@ void gagx (struct gacmn *pcm) {
   pcm->ccolor = -9;
   pcm->cint = 0.0;
   pcm->cstyle = -9;
-  pcm->cthick = 3;
+  pcm->cthick = 4;
   pcm->shdcnt = 0;
   pcm->cntrcnt = 0;
   pcm->lastgx = 0;
@@ -881,9 +880,8 @@ gaint i;
   }
   gxclip (0.0, pcm->xsiz, 0.0, pcm->ysiz);
   gxcolr (pcm->anncol);
-  gxwide (pcm->annthk-3);
-  if (pcm->pass==0 && pcm->grdsflg)
-          gxchpl("GrADS: COLA/IGES",16,0.05,0.05,0.1,0.08,0.0);
+  gxwide (4);
+  if (pcm->pass==0 && pcm->grdsflg) gxchpl("GrADS: IGES/COLA",16,0.05,0.05,0.1,0.09,0.0);
   if (pcm->pass==0 && pcm->timelabflg) gatmlb(pcm);
   gxstyl(1);
   gaaxpl(pcm,0,1);
@@ -896,7 +894,7 @@ void gasmrk (struct gacmn *pcm) {
 struct gastn *stn;
 struct garpt *rpt;
 gadouble rlon,x,y,cwid,sizstid;
-gaint i,len,icnst,cnt; 
+gaint i,len,icnst,cnt,bcol; 
 char lab[20];
 
   gamscl (pcm);       /* Do map level scaling */
@@ -957,7 +955,10 @@ char lab[20];
           x = x-cwid*0.5;
           y = y-(sizstid*1.7);
           if (pcm->ccolor!=0) {
-            gxcolr (gxqbck());
+	    bcol = gxdbkq();
+	    /* If bcol is neither black nor white, leave it alone. Otherwise, set to 0 for 'background' */
+	    if (bcol<2) bcol=0; 
+	    gxcolr (bcol);
             gxrecf (x-0.01,x+cwid+0.01,y-0.01,y+sizstid+0.01);
           }
           if (pcm->ccolor<0) gxcolr(1);
@@ -971,9 +972,8 @@ char lab[20];
   }
   gxclip (0.0, pcm->xsiz, 0.0, pcm->ysiz);
   gxcolr(pcm->anncol);
-  gxwide(pcm->annthk-3);
-  if (pcm->pass==0 && pcm->grdsflg)
-          gxchpl("GrADS: COLA/IGES",16,0.05,0.05,0.1,0.08,0.0);
+  gxwide(4);
+  if (pcm->pass==0 && pcm->grdsflg) gxchpl("GrADS: IGES/COLA",16,0.05,0.05,0.1,0.09,0.0);
   if (pcm->pass==0 && pcm->timelabflg) gatmlb(pcm);
   gxstyl(1);
   gaaxpl(pcm,0,1);
@@ -989,7 +989,7 @@ struct gastn *stn, *stn2;
 struct garpt *rpt, *rpt2;
 gadouble x,y,rlon;
 gadouble dir,spd,umax,vmax,vscal=0.0,cwid;
-gaint len,flag,hemflg;
+gaint len,flag,hemflg,bcol;
 char lab[20];
 
   gamscl (pcm);       /* Do map level scaling */
@@ -1109,7 +1109,10 @@ char lab[20];
             y = y-(pcm->digsiz*0.5);
           }
           if (pcm->ccolor!=0) {
-            gxcolr (gxqbck());
+	    bcol = gxdbkq();
+	    /* If bcol is neither black nor white, leave it alone. Otherwise, set to 0 for 'background' */
+	    if (bcol<2) bcol=0; 
+	    gxcolr (bcol);
             gxrecf (x-0.01,x+cwid+0.01,y-0.01,y+pcm->digsiz+0.01);
           }
           if (pcm->ccolor<0) gxcolr(1);
@@ -1142,7 +1145,10 @@ char lab[20];
 	    x = x-cwid*0.5;
 	    y = y-(pcm->digsiz*1.7);
 	    if (pcm->ccolor!=0) {
-	      gxcolr (gxqbck());
+	      bcol = gxdbkq();
+	      /* If bcol is neither black nor white, leave it alone. Otherwise, set to 0 for 'background' */
+	      if (bcol<2) bcol=0; 
+	      gxcolr (bcol);
 	      gxrecf (x-0.01,x+cwid+0.01,y-0.01,y+pcm->digsiz+0.01);
 	    }
 	    if (pcm->ccolor<0) gxcolr(1);
@@ -1156,9 +1162,8 @@ char lab[20];
   }
   gxclip (0.0, pcm->xsiz, 0.0, pcm->ysiz);
   gxcolr(pcm->anncol);
-  gxwide(pcm->annthk-3);
-  if (pcm->pass==0 && pcm->grdsflg)
-          gxchpl("GrADS: COLA/IGES",16,0.05,0.05,0.1,0.08,0.0);
+  gxwide(4);
+  if (pcm->pass==0 && pcm->grdsflg) gxchpl("GrADS: IGES/COLA",16,0.05,0.05,0.1,0.09,0.0);
   if (pcm->pass==0 && pcm->timelabflg) gatmlb(pcm);
   gxstyl(1);
   gaaxpl(pcm,0,1);
@@ -1335,9 +1340,8 @@ gaint i,num,rc;
 
   gxclip (0.0, pcm->xsiz, 0.0, pcm->ysiz);
   gxcolr(pcm->anncol);
-  gxwide(pcm->annthk-3);
-  if (pcm->pass==0 && pcm->grdsflg)
-          gxchpl("GrADS: COLA/IGES",16,0.05,0.05,0.1,0.08,0.0);
+  gxwide(4);
+  if (pcm->pass==0 && pcm->grdsflg) gxchpl("GrADS: IGES/COLA",16,0.05,0.05,0.1,0.09,0.0);
   if (pcm->pass==0 && pcm->timelabflg) gatmlb(pcm);
   gxstyl(1);
   gaaxpl(pcm,0,1);
@@ -1728,7 +1732,7 @@ struct gastn *stn, *stn2;
 struct garpt *rpt, *rpt2, *frpt;
 gadouble rmin,rmax,x,y;
 gadouble tsav,dir;
-gaint ipen,im,i,hemflg;
+gaint ipen,im,i,hemflg,bcol;
 
   stn = pcm->result[0].stn;
   rpt = stn->rpt;
@@ -1780,12 +1784,15 @@ gaint ipen,im,i,hemflg;
       if (rpt->umask != 0) {
         i = (gaint)(rpt->val+0.5);
         wxsym (i, x, pcm->ysiz1, pcm->digsiz*1.5, -1, pcm->wxcols);
-      } else {
-        gxchpl ("M",1,x,pcm->ysiz1,pcm->digsiz,pcm->digsiz,0.0);
-      }
+      } 
+      /* Don't show me M when there's no weather */
+/*       else { */
+/*         gxchpl ("M",1,x,pcm->ysiz1,pcm->digsiz,pcm->digsiz,0.0); */
+/*       } */
       rpt = rpt->rpt;
     }
-  } else if (pcm->tser==2) {
+  } 
+  else if (pcm->tser==2) {
     stn2 = pcm->result[1].stn;
     rpt = stn->rpt;
     rpt2 = stn2->rpt;
@@ -1806,58 +1813,62 @@ gaint ipen,im,i,hemflg;
       rpt = rpt->rpt;
       rpt2 = rpt2->rpt;
     }
-  } else {
-  gxclip (pcm->xsiz1-0.01, pcm->xsiz2+0.01, pcm->ysiz1, pcm->ysiz2);
-  if (pcm->cstyle!=0) {
-    rpt = stn->rpt;
-    tsav = rpt->tim;
-    ipen = 3;
-    while (rpt!=NULL) {
-      if (!cmpch(frpt->stid,rpt->stid,8)) {
-        if (rpt->umask != 0) {
-          if (rpt->tim - tsav > 1.0 && !pcm->miconn) ipen = 3;
-          if (pcm->rotate) gxconv (rpt->val,rpt->tim,&x,&y,3);
-          else gxconv (rpt->tim,rpt->val,&x,&y,3);
-          gxplot (x,y,ipen);
-          ipen = 2;
-        } else if (!pcm->miconn) ipen=3;
-        tsav = rpt->tim;
+  } 
+  else {
+    gxclip (pcm->xsiz1-0.01, pcm->xsiz2+0.01, pcm->ysiz1, pcm->ysiz2);
+    if (pcm->cstyle!=0) {
+      rpt = stn->rpt;
+      tsav = rpt->tim;
+      ipen = 3;
+      while (rpt!=NULL) {
+	if (!cmpch(frpt->stid,rpt->stid,8)) {
+	  if (rpt->umask != 0) {
+	    if (rpt->tim - tsav > 1.0 && !pcm->miconn) ipen = 3;
+	    if (pcm->rotate) gxconv (rpt->val,rpt->tim,&x,&y,3);
+	    else gxconv (rpt->tim,rpt->val,&x,&y,3);
+	    gxplot (x,y,ipen);
+	    ipen = 2;
+	  } else if (!pcm->miconn) ipen=3;
+	  tsav = rpt->tim;
+	}
+	rpt = rpt->rpt;
       }
-      rpt = rpt->rpt;
     }
-  }
-
-  rpt = stn->rpt;
-  im = pcm->cmark;
-  if (im>0) {
-    while (rpt!=NULL) {
-      if (!cmpch(frpt->stid,rpt->stid,8)) {
-        if (rpt->umask != 0) {
-          if (pcm->rotate) gxconv (rpt->val,rpt->tim,&x,&y,3);
-          else gxconv (rpt->tim,rpt->val,&x,&y,3);
-          if (im==1 || im==2 || im==4) {
-            gxcolr (gxqbck());
-            if (im==1) gxmark (4,x,y,pcm->digsiz+0.01);
-            else gxmark (im+1,x,y,pcm->digsiz+0.01);
-            gxcolr(pcm->ccolor);
-          }
-          gxmark (im,x,y,pcm->digsiz+0.01);
-        }
+    
+    rpt = stn->rpt;
+    im = pcm->cmark;
+    if (im>0) {
+      while (rpt!=NULL) {
+	if (!cmpch(frpt->stid,rpt->stid,8)) {
+	  if (rpt->umask != 0) {
+	    if (pcm->rotate) gxconv (rpt->val,rpt->tim,&x,&y,3);
+	    else gxconv (rpt->tim,rpt->val,&x,&y,3);
+	    if (im==1 || im==2 || im==4) {
+	      bcol = gxdbkq();
+	      /* If bcol is neither black nor white, leave it alone. Otherwise, set to 0 for 'background' */
+	      if (bcol<2) bcol=0; 
+	      gxcolr (bcol);
+	      if (im==1) gxmark (4,x,y,pcm->digsiz+0.01);
+	      else gxmark (im+1,x,y,pcm->digsiz+0.01);
+	      gxcolr(pcm->ccolor);
+	    }
+	    gxmark (im,x,y,pcm->digsiz+0.01);
+	  }
+	}
+	rpt = rpt->rpt;
       }
-      rpt = rpt->rpt;
     }
-  }
 
-  gxclip (0.0, pcm->xsiz, 0.0, pcm->ysiz);
-  if (pcm->rotate) 
-    gaaxpl(pcm,5,3);   /* hard-coded 4's changed to 5's */
-  else 
-    gaaxpl(pcm,3,5);   /* hard-coded 4's changed to 5's */
+    /* Axis labels are not drawn for gxout tserbarb or tserwx */
+    gxclip (0.0, pcm->xsiz, 0.0, pcm->ysiz);
+    if (pcm->rotate) 
+      gaaxpl(pcm,5,3);   /* hard-coded 4's changed to 5's */
+    else 
+      gaaxpl(pcm,3,5);   /* hard-coded 4's changed to 5's */
   }
-  gxwide (pcm->annthk-3);
+  gxwide (4);
   gxcolr (pcm->anncol);
-  if (pcm->pass==0 && pcm->grdsflg)
-           gxchpl("GrADS: COLA/IGES",16,0.05,0.05,0.1,0.08,0.0);
+  if (pcm->pass==0 && pcm->grdsflg) gxchpl("GrADS: IGES/COLA",16,0.05,0.05,0.1,0.09,0.0);
   if (pcm->pass==0 && pcm->timelabflg) gatmlb(pcm);
   gagsav (13,pcm,NULL);
 }
@@ -1950,9 +1961,8 @@ char stid[10];
   else 
     gaaxpl(pcm,5,2);
   gxcolr(pcm->anncol);
-  gxwide (pcm->annthk-3);
-  if (pcm->pass==0 && pcm->grdsflg)
-          gxchpl("GrADS: COLA/IGES",16,0.05,0.05,0.1,0.08,0.0);
+  gxwide (4);
+  if (pcm->pass==0 && pcm->grdsflg) gxchpl("GrADS: IGES/COLA",16,0.05,0.05,0.1,0.09,0.0);
   if (pcm->pass==0 && pcm->timelabflg) gatmlb(pcm);
   gagsav (13,pcm,NULL);
 }
@@ -2614,10 +2624,9 @@ size_t sz;
     gaaxpl(pcm,5,pgr1->idim);      /* hard coded 4's changed to 5's */
   else 
     gaaxpl(pcm,pgr1->idim,5);      /* hard coded 4's changed to 5's */
-  gxwide (pcm->annthk-3);
+  gxwide (4);
   gxcolr (pcm->anncol);
-  if (pcm->pass==0 && pcm->grdsflg)
-           gxchpl("GrADS: COLA/IGES",16,0.05,0.05,0.1,0.08,0.0);
+  if (pcm->pass==0 && pcm->grdsflg) gxchpl("GrADS: IGES/COLA",16,0.05,0.05,0.1,0.09,0.0);
   if (pcm->pass==0 && pcm->timelabflg) gatmlb(pcm);
   gagsav (17,pcm,pgr1);
 }
@@ -2670,7 +2679,7 @@ struct gagrid *pgr,*pgr2=NULL,*pgr3=NULL;
 gadouble x1,x2,y1,y2,x,y,xz,yz,rmin,rmax,xx,yy;
 gadouble *gr,*gr2=0,*gr3=0;
 gadouble gap,umax,vmax,vscal=0,dir;
-gaint ip,i,im,bflg,rotflg,flag,pflg,hflg=0,hemflg;
+gaint ip,i,im,bflg,rotflg,flag,pflg,hflg=0,hemflg,bcol;
 char *gru,*gr2u=NULL,*gr3u=NULL;
 
   /* Determine min and max */
@@ -2944,9 +2953,14 @@ char *gru,*gr2u=NULL,*gr3u=NULL;
               }
             }
           } else {
-            if (im==1 || im==2 || im==4 || im==8) {
-              gxcolr (gxqbck());
+	    /* draw cmarks */
+            if (im==1 || im==2 || im==4 || im==7 || im==8) {
+	      bcol = gxdbkq();
+	      /* If bcol is neither black nor white, leave it alone. Otherwise, set to 0 for 'background' */
+	      if (bcol<2) bcol=0; 
+              gxcolr (bcol);
               if (im==1) gxmark (4,x,y,pcm->digsiz+0.01);
+	      else if (im==7) gxmark (12,x,y,pcm->digsiz+0.01); /* draw a closed diamond */
               else gxmark (im+1,x,y,pcm->digsiz+0.01);
               gxcolr(pcm->ccolor);
             }
@@ -2966,10 +2980,9 @@ char *gru,*gr2u=NULL,*gr3u=NULL;
     gaaxpl(pcm,5,pgr->idim);   /* hard coded 4 changed to 5 */
   else 
     gaaxpl(pcm,pgr->idim,5);   /* hard coded 4 changed to 5 */
-  gxwide (pcm->annthk-3);
+  gxwide (4);
   gxcolr (pcm->anncol);
-  if (pcm->pass==0 && pcm->grdsflg)
-           gxchpl("GrADS: COLA/IGES",16,0.05,0.05,0.1,0.08,0.0);
+  if (pcm->pass==0 && pcm->grdsflg) gxchpl("GrADS: IGES/COLA",16,0.05,0.05,0.1,0.09,0.0);
   if (pcm->pass==0 && pcm->timelabflg) gatmlb(pcm);
   if (barflg) gagsav (8,pcm,pgr);
   else  gagsav (6,pcm,pgr);
@@ -3056,10 +3069,9 @@ char *umask, *vmask, *cmask=NULL;
   }
 
   gxclip (0.0, pcm->xsiz, 0.0, pcm->ysiz);
-  gxwide (pcm->annthk-3);
+  gxwide (4);
   gxcolr (pcm->anncol);
-  if (pcm->pass==0 && pcm->grdsflg)
-       gxchpl("GrADS: COLA/IGES",16,0.05,0.05,0.1,0.08,0.0);
+  if (pcm->pass==0 && pcm->grdsflg) gxchpl("GrADS: IGES/COLA",16,0.05,0.05,0.1,0.09,0.0);
   if (pcm->pass==0 && pcm->timelabflg) gatmlb(pcm);
   gaaxpl(pcm,pgru->idim,pgru->jdim);
   gagsav (9,pcm,pgru);
@@ -3230,10 +3242,9 @@ char *umask,*vmask,*cmask=NULL;
     x = pcm->xsiz2 - 2.0 + (pcm->arrsiz/2.0) - 0.5*0.13*(gadouble)len;
     gxchpl (pout,len,x,pcm->ysiz1-0.7,0.13,0.13,0.0);
   }
-  gxwide (pcm->annthk-3);
+  gxwide (4);
   gxcolr (pcm->anncol);
-  if (pcm->pass==0 && pcm->grdsflg)
-       gxchpl("GrADS: COLA/IGES",16,0.05,0.05,0.1,0.08,0.0);
+  if (pcm->pass==0 && pcm->grdsflg) gxchpl("GrADS: IGES/COLA",16,0.05,0.05,0.1,0.09,0.0);
   if (pcm->pass==0 && pcm->timelabflg) gatmlb(pcm);
   gaaxpl(pcm,pgru->idim,pgru->jdim);
   if (brbflg) gagsav (15,pcm,pgru);
@@ -3246,11 +3257,11 @@ gaint scatcol[6] = {1,3,2,4,7,8};
 gaint scattyp[6] = {1,6,4,8,7,2};
 
 void gascat (struct gacmn *pcm) {
-struct gagrid *pgr1, *pgr2, *pgrc;
-gadouble *r1, *r2, *c, x, y;
+struct gagrid *pgr1, *pgr2, *pgrc=NULL;
+gadouble *r1, *r2, *c=NULL, x, y;
 gadouble cmin1,cmax1,cmin2,cmax2,cint1,cint2;
 gaint siz,i,pass,im,flag,lcol,drawthismark;
-char *r1mask, *r2mask, *cmask;
+char *r1mask, *r2mask, *cmask=NULL;
 
   if (pcm->numgrd<2) {
     gaprnt (0,"Error plotting scatter field:  Only one grid provided\n");
@@ -3430,8 +3441,7 @@ char *r1mask, *r2mask, *cmask;
     gxconv (cmax1, 0.0, &x, &y, 1);
     gxplot (x,y,2);
   }
-  if (pcm->pass==0 && pcm->grdsflg)
-          gxchpl("GrADS: COLA/IGES",16,0.05,0.05,0.1,0.08,0.0);
+  if (pcm->pass==0 && pcm->grdsflg) gxchpl("GrADS: IGES/COLA",16,0.05,0.05,0.1,0.09,0.0);
   if (pcm->pass==0 && pcm->timelabflg) gatmlb(pcm);
   gagsav (7,pcm,pgr1);
   pcm->gpass[3]++;
@@ -3550,9 +3560,8 @@ char *rmask,*mmask=NULL,lab[20];
 
   gxclip (0.0, pcm->xsiz, 0.0, pcm->ysiz);
   gxcolr(pcm->anncol);
-  gxwide(pcm->annthk-3);
-  if (pcm->pass==0 && pcm->grdsflg)
-        gxchpl("GrADS: COLA/IGES",16,0.05,0.05,0.1,0.08,0.0);
+  gxwide(4);
+  if (pcm->pass==0 && pcm->grdsflg) gxchpl("GrADS: IGES/COLA",16,0.05,0.05,0.1,0.09,0.0);
   if (pcm->pass==0 && pcm->timelabflg) gatmlb(pcm);
   gaaxpl(pcm,pgr->idim,pgr->jdim);
   gagsav (4,pcm,pgr);
@@ -4093,6 +4102,7 @@ struct dbfld* newdbfld (char *fldname, DBFFieldType dbtype, gaint len, gaint pre
 void gakml (struct gacmn *pcm) {
   FILE *kmlfp=NULL;
   struct gagrid *pgr;
+  struct gxdbquery dbq;
   gaint r,g,b,err=0,i,rc;
   
   /* Determine if output is a grid or a station result */
@@ -4170,13 +4180,10 @@ void gakml (struct gacmn *pcm) {
       snprintf(pout,255,"    <Style id=\"%d\">\n      <LineStyle>\n",pcm->cntrcols[i]);
       if ((fwrite(pout,sizeof(char),strlen(pout),kmlfp))!=strlen(pout)) {err=1; goto cleanup;}
       /* get rgb values for this color */
-      if (pcm->cntrcols[i]<16) {
-	gxqdrgb(pcm->cntrcols[i],&r,&g,&b);         /* default color */
-      }
-      else {
-	gxqrgb(pcm->cntrcols[i],&r,&g,&b);          /* user-defined color */
-	if (r==-999) r = g = b = 0;
-      } 
+      gxdbqcol(pcm->cntrcols[i], &dbq);
+      r = dbq.red;
+      g = dbq.green;
+      b = dbq.blue;
       snprintf(pout,255,"        <color>ff%02x%02x%02x</color>\n",b,g,r);
       if ((fwrite(pout,sizeof(char),strlen(pout),kmlfp))!=strlen(pout)) {err=1; goto cleanup;}
       snprintf(pout,255,"        <width>%d</width>\n",pcm->cthick);
@@ -4204,13 +4211,10 @@ void gakml (struct gacmn *pcm) {
       snprintf(pout,255,"      <LineStyle>\n");
       if ((fwrite(pout,sizeof(char),strlen(pout),kmlfp))!=strlen(pout)) {err=1; goto cleanup;}
       /* get rgb values for this color */
-      if (pcm->shdcls[i]>=0 && pcm->shdcls[i]<16) {
-	gxqdrgb(pcm->shdcls[i],&r,&g,&b);         /* default color */
-      }
-      else {
-	gxqrgb(pcm->shdcls[i],&r,&g,&b);          /* user-defined color */
-	if (r==-999) r = g = b = 0;
-      }
+      gxdbqcol(pcm->shdcls[i], &dbq);
+      r = dbq.red;
+      g = dbq.green;
+      b = dbq.blue;
       snprintf(pout,255,"        <color>ff%02x%02x%02x</color>\n",b,g,r);
       if ((fwrite(pout,sizeof(char),strlen(pout),kmlfp))!=strlen(pout)) {err=1; goto cleanup;}
       snprintf(pout,255,"        <width>0</width>\n");
@@ -4282,10 +4286,11 @@ void gakml (struct gacmn *pcm) {
 void gagtif (struct gacmn *pcm, gaint kmlflg) {
 #if GEOTIFF==1 
  struct gagrid *pgr;
+ struct gxdbquery dbq;
  gadouble *gr,cmin,cmax,cint,pmin,pmax,dval;
  gadouble pixelscale[3],tiepoints[24];
  gafloat fval;
- gaint i,j,rc,grsize,isize,jsize,color,r,g,b;
+ gaint i,j,rc,grsize,isize,jsize,color,r,g,b,CMAX;
  char *gru;
  TIFF *tif=NULL;
  GTIF *gtif=NULL;
@@ -4523,24 +4528,24 @@ void gagtif (struct gacmn *pcm, gaint kmlflg) {
    gaselc (pcm,pgr->rmin,pgr->rmax);
    
    /* create and write out the color map */
-   colormap = (uint16*)_TIFFmalloc(3 * 256 * sizeof (uint16));
+   /* palette-color image in TIFF cannot have more than 256 colors */
+   CMAX = 256;
+   colormap = (uint16*)_TIFFmalloc(3 * CMAX * sizeof (uint16));
    if (colormap==NULL) {
      gaprnt(0,"Error: TIFFmalloc failed for colormap\n"); goto cleanup;
    }
    cm=colormap;
-   for (j=0;j<256;j++){
-     if (j<16) {
-       gxqdrgb(j,&r,&g,&b);         /* get default color rgb values */
-     }
-     else {
-       gxqrgb(j,&r,&g,&b);          /* get user-defined color rgb values */
-       if (r==-999) r = g = b = 0;
-     } 
-     *(cm+0*256+j) = (uint16)r;
-     *(cm+1*256+j) = (uint16)g;
-     *(cm+2*256+j) = (uint16)b;
+   for (j=0;j<CMAX;j++){
+     /* get rgb values for each color */
+     gxdbqcol(j, &dbq);
+     r = dbq.red;
+     g = dbq.green;
+     b = dbq.blue;
+     *(cm+0*CMAX+j) = (uint16)r;
+     *(cm+1*CMAX+j) = (uint16)g;
+     *(cm+2*CMAX+j) = (uint16)b;
    }
-   if (TIFFSetField(tif, TIFFTAG_COLORMAP, colormap, colormap+256, colormap+512)!=1) { 
+   if (TIFFSetField(tif, TIFFTAG_COLORMAP, colormap, colormap+CMAX, colormap+(2*CMAX))!=1) { 
      gaprnt(0,"Error: TIFFSetField failed for colormap\n"); goto cleanup; 
    }
 
@@ -4560,9 +4565,8 @@ void gagtif (struct gacmn *pcm, gaint kmlflg) {
      if (gru[i]!=0) {
        color = gashdc (pcm, gr[i]);     /* get the relevent color for grid data value */
      }
-     else {                             /* use the device background for undefined values */
-       if (pcm->devbck) color = 1;
-       else color = 0;
+     else {                             
+       color = gxdbkq();                /* use the device background for undefined values */
      }
      cbuf[i] = (unsigned char)color;
    }
@@ -5108,9 +5112,8 @@ size_t sz;
   if (pgr->idim==0 && pgr->jdim==1) gawmap (pcm, 0);
   gxclip (0.0, pcm->xsiz, 0.0, pcm->ysiz);
   gxcolr(pcm->anncol);
-  gxwide(pcm->annthk-3);
-  if (pcm->pass==0 && pcm->grdsflg)
-        gxchpl("GrADS: COLA/IGES",16,0.05,0.05,0.1,0.08,0.0);
+  gxwide(4);
+  if (pcm->pass==0 && pcm->grdsflg) gxchpl("GrADS: IGES/COLA",16,0.05,0.05,0.1,0.09,0.0);
   if (pcm->pass==0 && pcm->timelabflg) gatmlb(pcm);
   gaaxpl(pcm,pgr->idim,pgr->jdim);
   gafram (pcm);
@@ -5228,6 +5231,7 @@ size_t sz;
     }
   }
 
+  /* set contour color */
   if (pcm->ccolor>=0) gxcolr(pcm->ccolor);
   if (pcm->ccolor<0 && pcm->rainmn==0.0 && pcm->rainmx==0.0 && !pcm->cflag) {
     pcm->rainmn = cmin;
@@ -5357,8 +5361,8 @@ size_t sz;
         rr = pcm->clevs[i];
         if (rr<0.0&&pcm->cstyle==-9) gxstyl (3);
         else gxstyl(pcm->cstyle);
-        if (pcm->ccolor < 0 && pcm->ccflg == 0) {
-          if (pcm->cflag==1) ii=irb/2;
+        if (pcm->ccolor < 0 && pcm->ccflg == 0) {   /* user has not specified contour colors */
+          if (pcm->cflag==1) ii=irb/2;              /* only one specified level */
           else ii = (gaint)((gadouble)(i*irb)/((gadouble)(pcm->cflag-1)));
           if (ii>irb) ii=irb;
           if (ii<0) ii=0;
@@ -5382,13 +5386,13 @@ size_t sz;
 	    }
           }
         }
-        if (pcm->ccflg) {
+        if (pcm->ccflg) {   /* overlays */
           ii = i;
           if (ii>=pcm->ccflg) ii = pcm->ccflg-1;
           gxcolr (pcm->ccols[ii]);
 	  cntrcol = pcm->ccols[ii];  
         }
-	if (pcm->ccolor > 0 && pcm->ccflg == 0) cntrcol = pcm->ccolor; /* overlays */
+	if (pcm->ccolor > 0 && pcm->ccflg == 0) cntrcol = pcm->ccolor;
         if (pcm->clstr) 
 	  snprintf(chlab,49,pcm->clstr,rr);
         else 
@@ -5418,7 +5422,8 @@ size_t sz;
 	cntrcnt++;
       }
       pcm->cntrcnt = cntrcnt; 
-    } else {
+    } 
+    else {   /* user has not specified contour levels */
       clcnt = 0;
       clopt = 0;  /* normalize clskip only when well-behaved */
       if (fabs(cmin/cint)<1e6 || fabs(cmax/cint)<1e6) clopt=1; 
@@ -5519,11 +5524,10 @@ size_t sz;
     gree(rrrmask,"f292a");
   }
   gxclip (0.0, pcm->xsiz, 0.0, pcm->ysiz);
-  gxcolr(pcm->anncol);
-  gxwide (pcm->annthk-3);
+  gxcolr (pcm->anncol);
+  gxwide (4); 
   if (shpflg==0) {
-    if (pcm->pass==0 && pcm->grdsflg)
-      gxchpl("GrADS: COLA/IGES",16,0.05,0.05,0.1,0.08,0.0);
+    if (pcm->pass==0 && pcm->grdsflg) gxchpl("GrADS: IGES/COLA",16,0.05,0.05,0.1,0.09,0.0);
     if (pcm->pass==0 && pcm->timelabflg) gatmlb(pcm);
     gaaxpl(pcm,pgr->idim,pgr->jdim);
     gafram (pcm);
@@ -5580,12 +5584,13 @@ char lab[30],olab[30],*chlb=NULL;
   addmo.hr = 0L;
   addmo.mn = 0L;
   if (axis==1) {
-    cs = pcm->xlsiz; 
+    cs   = pcm->xlsiz; 
     colr = pcm->xlcol;
     thck = pcm->xlthck;
     if (pcm->xlside) pos = pcm->ysiz2 + pcm->xlpos;
     else pos = pcm->ysiz1 + pcm->xlpos;
     if (pcm->xlpos!=0.0) { 
+      /* X axis is offset from frame */
       gxcolr (pcm->anncol);
       gxwide (pcm->annthk);
       gxstyl (1);
@@ -5599,6 +5604,7 @@ char lab[30],olab[30],*chlb=NULL;
     if (pcm->ylside) pos = pcm->xsiz2 + pcm->ylpos;
     else pos = pcm->xsiz1 + pcm->ylpos;
     if (pcm->ylpos!=0.0) {
+      /* Y axis is offset from frame */
       gxcolr (pcm->anncol);
       gxwide (pcm->annthk);
       gxstyl (1);
@@ -5606,6 +5612,7 @@ char lab[30],olab[30],*chlb=NULL;
       gxplot (pos,pcm->ysiz2,2);
     }
   }
+
   /* Select axis min and max */
   vincr=0.0;
   if (dim==5) {         /* hard coded 5 */
@@ -5655,7 +5662,6 @@ char lab[30],olab[30],*chlb=NULL;
   }
 
   /* Handle axis flipping */
-
   if (axis) {
     if (pcm->xflip) {
       m=(pcm->xsiz2-pcm->xsiz1)/(vmin-vmax);
@@ -5675,7 +5681,6 @@ char lab[30],olab[30],*chlb=NULL;
   }
 
   /* Select label interval */
-
   if (vmin>vmax) {
     v = 1.0*vmax;  /* Avoid optimization */
     vmax = vmin;
@@ -5714,10 +5719,12 @@ char lab[30],olab[30],*chlb=NULL;
     }
   }
 
+  /* draw labels, tic marks, and grid lines */
   gxcolr(colr);
   gxwide(thck);
   gxstyl(1);
   if (dim!=3) {
+    /* determine the label values */
     if (axis==1 && pcm->xlflg>0) cnt = pcm->xlflg;
     else if (axis==0 && pcm->ylflg>0) cnt = pcm->ylflg;
     else {
@@ -5730,16 +5737,18 @@ char lab[30],olab[30],*chlb=NULL;
         else *(pcm->ylevs+i) = v;
       }
     }
-
     i = 0;
     if (axis==1 && pcm->xlabs) chlb = pcm->xlabs;
     if (axis==0 && pcm->ylabs) chlb = pcm->ylabs;
     while (i<cnt) {
+      /* convert labels to strings */
       if (axis) v = *(pcm->xlevs+i);
       else v = *(pcm->ylevs+i);
-      if (axis==1 && pcm->xlstr) snprintf(lab,29,pcm->xlstr,v);
-      else if (axis==0 && pcm->ylstr) snprintf(lab,29,pcm->ylstr,v);
-      else if ( ( axis==1 && pcm->xlabs ) || ( axis==0 && pcm->ylabs) ) {
+      if (axis==1 && pcm->xlstr) 
+        snprintf(lab,29,pcm->xlstr,v);
+      else if (axis==0 && pcm->ylstr) 
+        snprintf(lab,29,pcm->ylstr,v);
+      else if (( axis==1 && pcm->xlabs ) || ( axis==0 && pcm->ylabs)) {
         snprintf(lab,29,chlb,v);
         while (*chlb) chlb++;
         chlb++;
@@ -5762,16 +5771,18 @@ char lab[30],olab[30],*chlb=NULL;
           i++;
           continue;
         }
+	/* X tic marks */
         gxplot (x,pos,3);
         if (pcm->xlside) gxplot (x,pos+(cs*0.4),2);
         else gxplot (x,pos-(cs*0.4),2);
+	/* X grid lines */
         if (pcm->grflag==1 || pcm->grflag==3) {
-          gxwide (1);
+          gxwide (pcm->grthck); 
           gxstyl (pcm->grstyl);
           gxcolr (pcm->grcolr);
           gxplot (x,pcm->ysiz1,3);
           gxplot (x,pcm->ysiz2,2);
-          gxcolr(colr);
+	  gxcolr(colr);
           gxwide(thck);
           gxstyl(1);
         }
@@ -5787,6 +5798,7 @@ char lab[30],olab[30],*chlb=NULL;
           i++;
           continue;
         }
+	/* Y tic marks */
         gxplot (pos,y,3);
         if (pcm->ylside) {
           gxplot (pos+(cs*0.4),y,2);
@@ -5796,8 +5808,9 @@ char lab[30],olab[30],*chlb=NULL;
           x = pos - (cwid+cs)*0.8;
           if (pcm->yllow<(cwid+cs)*0.8) pcm->yllow = (cwid+cs)*0.8;
         }
+	/* X grid lines */
         if (pcm->grflag==1 || pcm->grflag==2) {
-          gxwide (1);
+          gxwide (pcm->grthck);
           gxstyl (pcm->grstyl);
           gxcolr (pcm->grcolr);
           gxplot (pcm->xsiz1,y,3);
@@ -5826,7 +5839,7 @@ char lab[30],olab[30],*chlb=NULL;
         if (pcm->xlside) gxplot (x,pos+(cs*0.4),2);
         else gxplot (x,pos-(cs*0.4),2);
         if (pcm->grflag==1 || pcm->grflag==3) {
-          gxwide (1);
+          gxwide (pcm->grthck);
           gxstyl (pcm->grstyl);
           gxcolr (pcm->grcolr);
           gxplot (x,pcm->ysiz1,3);
@@ -5883,7 +5896,7 @@ char lab[30],olab[30],*chlb=NULL;
         if (pcm->ylside) gxplot (pos+(cs*0.4),y,2);
         else gxplot (pos-(cs*0.4),y,2);
         if (pcm->grflag==1 || pcm->grflag==2) {
-          gxwide (1);
+          gxwide (pcm->grthck);
           gxstyl (pcm->grstyl);
           gxcolr (pcm->grcolr);
           gxplot (pcm->xsiz1,y,3);
@@ -6022,22 +6035,26 @@ gaint i;
   if (pcm->mpdraw==0) return;
   gxclip (pcm->xsiz1, pcm->xsiz2, pcm->ysiz1, pcm->ysiz2);
   if (pcm->mapcol<0) {
+    /* set default map color, style, thickness */
     if (iflg) {
       mopt.dcol = pcm->mcolor;
       mopt.dstl = 1;
-      mopt.dthk = 1;
+      mopt.dthk = 3;
     } else {
       mopt.dcol = 1;
       mopt.dstl = 1;
-      mopt.dthk = 4;
+      mopt.dthk = 3;
     }
   } else {
+    /* user has invoked 'set map' */
     mopt.dcol = pcm->mapcol;
     mopt.dstl = pcm->mapstl;
     mopt.dthk = pcm->mapthk;
   }
+  /* set boundaries */
   mopt.lnmin = pcm->dmin[0]; mopt.lnmax = pcm->dmax[0];
   mopt.ltmin = pcm->dmin[1]; mopt.ltmax = pcm->dmax[1];
+  /* arrays of map line attributes */
   mopt.mcol = pcm->mpcols;
   mopt.mstl = pcm->mpstls;
   mopt.mthk = pcm->mpthks;
@@ -6559,40 +6576,6 @@ gadouble v,s,plincr,lndif,ln,lt,cs;
   if (pcm->mproj==5) {
     lnmin = pcm->dmin[0]; lnmax = pcm->dmax[0];
     ltmin = pcm->dmin[1]; ltmax = pcm->dmax[1];
-    for (ln=lnmin; ln<lnmax+10.0; ln+=45.0) {
-      if (ln<lnmin+10.0 || ln>lnmax-10.0) {
-        gxstyl (1);
-        gxcolr (1);
-        gxwide (5);
-      } else {
-        gxstyl (pcm->grstyl);
-        gxcolr (pcm->grcolr);
-        gxwide (1);
-      }
-      gxconv (ln,ltmin,&x1,&y1,2);
-      gxplot (x1,y1,3);
-      for (lt=ltmin; lt<ltmax+1.0; lt+=2.0) {
-        gxconv (ln,lt,&x1,&y1,2);
-        gxplot (x1,y1,2);
-      }
-    }
-    for (lt=ltmin; lt<ltmax+10.0; lt+=30.0) {
-      if (lt<ltmin+10.0 || lt>ltmax-10.0) {
-        gxstyl (1);
-        gxcolr (1);
-        gxwide (5);
-      } else {
-        gxstyl (pcm->grstyl);
-        gxcolr (pcm->grcolr);
-        gxwide (1);
-      }
-      gxconv (lnmin,lt,&x1,&y1,2);
-      gxplot (x1,y1,3);
-      for (ln=lnmin; ln<lnmax+1.0; ln+=2.0) {
-        gxconv (ln,lt,&x1,&y1,2);
-        gxplot (x1,y1,2);
-      }
-    }
     /* these are labels when lon ranges from -180 to 180 */
     if (fabs(lnmin+180.0)<1.0 && fabs(lnmax-180.0)<1.0 && fabs(ltmin+90.0)<1.0 && fabs(ltmax-90.0)<1.0) {
       cs = 0.10;
@@ -6648,11 +6631,50 @@ gadouble v,s,plincr,lndif,ln,lt,cs;
       gxconv (360.0,30.0,&x1,&y1,2);    gxchpl ("30N",3,x1+cs*1.0,y1-cs*0.55,cs*1.1,cs,0.0);
       gxconv (360.0,60.0,&x1,&y1,2);    gxchpl ("60N",3,x1+cs*1.5,y1-cs*0.55,cs*1.1,cs,0.0);
     }
+    /* draw longitude lines */
+    for (ln=lnmin; ln<lnmax+10.0; ln+=45.0) {
+      if (ln<lnmin+10.0 || ln>lnmax-10.0) {
+	/* these form the frame, so use annotation color and thickness */
+        gxstyl (1);
+        gxcolr (pcm->anncol);
+        gxwide (pcm->annthk);
+      } else {
+	/* these are grid lines */
+        gxstyl (pcm->grstyl);
+        gxcolr (pcm->grcolr);
+        gxwide (pcm->grthck);
+      }
+      gxconv (ln,ltmin,&x1,&y1,2);
+      gxplot (x1,y1,3);
+      for (lt=ltmin; lt<ltmax+1.0; lt+=2.0) {
+        gxconv (ln,lt,&x1,&y1,2);
+        gxplot (x1,y1,2);
+      }
+    }
+    /* draw latitude lines */
+    for (lt=ltmin; lt<ltmax+10.0; lt+=30.0) {
+      if (lt<ltmin+10.0 || lt>ltmax-10.0) {
+	/* these form the frame, so use annotation color and thickness */
+        gxstyl (1);
+        gxcolr (pcm->anncol);
+        gxwide (pcm->annthk);
+      } else {
+	/* these are grid lines */
+        gxstyl (pcm->grstyl);
+        gxcolr (pcm->grcolr);
+        gxwide (pcm->grthck);
+      }
+      gxconv (lnmin,lt,&x1,&y1,2);
+      gxplot (x1,y1,3);
+      for (ln=lnmin; ln<lnmax+1.0; ln+=2.0) {
+        gxconv (ln,lt,&x1,&y1,2);
+        gxplot (x1,y1,2);
+      }
+    }
     return;
   }  /* end of robinson projection case */
 
   /* Choose grid interval for longitude */
-
   lnincr=0.0;
   lnmin = pcm->dmin[0];
   lnmax = pcm->dmax[0];
@@ -6667,10 +6689,9 @@ gadouble v,s,plincr,lndif,ln,lt,cs;
   gacsel (lnmin,lnmax,&lnincr,&lnstrt,&lnend);
   lndif = lnmax - lnmin;
 
-  if(pcm->xlint!=0.0) lnincr=pcm->xlint;   /*mf 960402 set the lon increment from xlint */
+  if (pcm->xlint!=0.0) lnincr=pcm->xlint;   /* set the lon increment from xlint */
 
   /* Choose grid interval for latitude */
-
   ltincr=0.0;
   ltmin = pcm->dmin[1];
   ltmax = pcm->dmax[1];
@@ -6695,7 +6716,7 @@ gadouble v,s,plincr,lndif,ln,lt,cs;
     else if (ltincr>0.2) ltincr = 0.5;
   }
 
-  if(pcm->ylint!=0.0) ltincr=pcm->ylint;   /*mf 960402 set the lat increment from ylint */
+  if (pcm->ylint!=0.0) ltincr=pcm->ylint;   /* set the lat increment from ylint */
 
   if (ltstrt<-89.9) {
     ltstrt = ltstrt + ltincr;
@@ -6708,7 +6729,7 @@ gadouble v,s,plincr,lndif,ln,lt,cs;
 
   gxstyl (pcm->grstyl);
   gxcolr (pcm->grcolr);
-  gxwide (1);
+  gxwide (pcm->grthck);
   gxclip (pcm->xsiz1,pcm->xsiz2,pcm->ysiz1,pcm->ysiz2);
   for (v=lnstrt; v<lnend+lnincr*0.5; v+=lnincr) {
     gxconv (v,ltmin,&x1,&y1,2);
@@ -6732,8 +6753,8 @@ gadouble v,s,plincr,lndif,ln,lt,cs;
   /* Plot circular frame if user requested such a thing */
 
   if (pcm->frame==2) {
-    gxcolr(pcm->anncol);
-    gxwide (pcm->annthk-3);
+    gxcolr (pcm->anncol);
+    gxwide (pcm->annthk);
     gxstyl (1);
     /* for orthographic projections */
     if (pcm->mproj==7) {
@@ -6756,8 +6777,8 @@ gadouble v,s,plincr,lndif,ln,lt,cs;
     }
     /* for other projections: nps, sps */
     else {
-      if (pcm->mproj==3) v = ltmin;
-      else v = ltmax;
+      if (pcm->mproj==3) v=ltmin;
+      else v=ltmax;
       /* draw line around latitude circle */
       gxconv (lnmin,v,&x1,&y1,2);
       gxplot (x1,y1,3);
@@ -7100,13 +7121,12 @@ err:
   return;
 }
 
-void gafram(struct gacmn *pcm) {
+void gafram (struct gacmn *pcm) {
 
+  gxcolr (pcm->anncol);
   if (pcm->frame==0) return;
   if (pcm->frame==2 && pcm->mproj>2) return;
   if (pcm->mproj>4) return;
-
-  gxcolr (pcm->anncol);
   gxwide (pcm->annthk);
   gxstyl (1);
   gxplot (pcm->xsiz1,pcm->ysiz1,3);
@@ -7343,7 +7363,7 @@ void gatmlb (struct gacmn *pcm) {
     sys_time();
     snprintf(dtgstr,31,"%04ld-%02ld-%02ld-%02ld:%02ld",
 	  timeobj.year, timeobj.month, timeobj.date, timeobj.hour, timeobj.minute) ;
-    gxchpl(dtgstr,strlen(dtgstr),pcm->pxsize-1.6,0.05,0.1,0.08,0.0);
+    gxchpl(dtgstr,strlen(dtgstr),pcm->pxsize-1.7,0.05,0.1,0.09,0.0);
   }
 }
 
diff --git a/src/gaio.c b/src/gaio.c
index a758a36..e6307c2 100644
--- a/src/gaio.c
+++ b/src/gaio.c
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 /* Authored by B. Doty and Jennifer Adams */
@@ -52,7 +51,7 @@ static char pout[256];
 /* For STNDALN, routines included are gaopfn, gaopnc, and gaophdf */
 #ifndef STNDALN
 
-/* GRIB I/O caching.  GRIB data is chached, as well as the bit
+/* GRIB I/O caching.  GRIB data is cached, as well as the bit
    maps, if present.  Sometimes the expanded bit map is cached. */
 static char *cache;             /* I/O cache for GRIB */
 static unsigned char *bcache;   /* Bit map cache */
@@ -485,9 +484,11 @@ gaint y,z,t,e;
     if (oflg) {
       /* Force new bit map cache if new file opened */
       bpsav = (off_t)-999;    
+    }
 #if USEHDF5==1
-      /* if HDF5, call h5setup and h5openvar if new file opened */
-      if (pfi->ncflg==3) {
+    /* For HDF5, call h5setup and h5openvar if new file opened or if a new variable */
+    if (pfi->ncflg==3) {
+      if (oflg || pvr->h5varflg<0) { 
 	/* get the variable name */
 	if (pvr->longnm[0] != '\0')
 	  vname = pvr->longnm;
@@ -513,8 +514,8 @@ gaint y,z,t,e;
 	/* set h5-relevant variables in the gavar structure */
 	pvr->h5vid = (gaint)vid; 
       }
-#endif
     }
+#endif
   }
   else {
     ee = e;  /* set relative ensemble number to e for non-templated data sets */
@@ -1420,7 +1421,7 @@ char *gru;
 gaint gairow (gaint x, gaint y, gaint z, gaint t, gaint e, gaint offset, gaint len, 
 	      gadouble *gr, char *gru) {
 gaint irec,ioff,bstrt,bend,blen,cstrt,cend,clen,rc;
-gaint brec;
+gaint brec,bigflg;
 gaint ival,i,yy,boff,siz,gtyp,xsiz,ysiz;
 off_t fpos,bpos,seek;
 float dsf,bsf,ref;
@@ -1447,7 +1448,11 @@ gaint g2off,ng2elems=2;
  /* GRIB1 */
  if (pfi->idxflg==1) {
    /* Figure out position and length of the I/O */
-   gtyp = *(pindx->hipnt+3);
+   gtyp = *(pindx->hipnt+3);     /* this is written into index header as pfi->grbgrd */
+   bigflg=0;
+   if ((pindx->type==4) ||                       /* version=4 --> off_t in use */
+       (pindx->type==5 && *(pindx->hipnt+4)>0))  /* version=5 & bignum>0 --> off_t in use */
+     bigflg=1;
    irec = (e-1)*pfi->dnum[3]*pfi->trecs + (t-1)*pfi->trecs + pvr->recoff + z - 1;
    brec = irec;
    if (gtyp==29) {
@@ -1466,15 +1471,15 @@ gaint g2off,ng2elems=2;
    else 
      ioff = yy*xsiz + x - 1;      
    boff = ioff;
-   if (pindx->type==4) blen = *(pindx->intpnt + brec);
-   else blen = *(pindx->intpnt + irec + 2);
+   if (bigflg) blen = *(pindx->intpnt + brec);
+   else        blen = *(pindx->intpnt + irec + 2);
    if (blen<0) {
      for (i=0; i<len; i++) *(gr+i) = pfi->undef;
      for (i=0; i<len; i++) *(gru+i) = 0;
      return (0);
    }
-   if (pindx->type==4) bpos = *(pindxb->bigpnt + brec*2 + 1);
-   else bpos = (off_t)(*(pindx->intpnt + irec + 1));
+   if (bigflg) bpos = *(pindxb->bigpnt + brec*2 + 1);
+   else        bpos = (off_t)(*(pindx->intpnt + irec + 1));
    dsf = *(pindx->fltpnt+irec);
    bsf = *(pindx->fltpnt+irec+1);
    ref = *(pindx->fltpnt+irec+2);
@@ -1530,8 +1535,8 @@ gaint g2off,ng2elems=2;
    cstrt = bstrt/8;
    cend = bend/8;
    clen = cend-cstrt+2;
-   if (pindx->type==4) fpos = *(pindxb->bigpnt+brec*2);
-   else fpos = (off_t)(*(pindx->intpnt+irec));
+   if (bigflg) fpos = *(pindxb->bigpnt+brec*2);
+   else        fpos = (off_t)(*(pindx->intpnt+irec));
    rc = gaird(fpos,cstrt,clen,xsiz,ysiz,blen);
    if (rc) return(rc);
    bstrt = bstrt - cstrt*8;
@@ -1556,7 +1561,7 @@ gaint g2off,ng2elems=2;
    
   /* figure out which record to retrieve from index file */
   irec = (e-1)*pfi->dnum[3]*pfi->trecs + (t-1)*pfi->trecs + pvr->recoff + z - 1;
-  if (pfi->g2indx->version==1) irec = irec * ng2elems;
+  if (pfi->g2indx->bigflg==0) irec = irec * ng2elems;
   if (irec > pfi->g2indx->g2intnum) {
     snprintf(pout,255,"GRIB2 I/O error: irec=%d is greater than g2intnum=%d\n",irec,pfi->g2indx->g2intnum);
     gaprnt(0,pout);
@@ -1564,7 +1569,7 @@ gaint g2off,ng2elems=2;
   }
 
   /* get file position offset and field number from grib2map file */
-  if (pfi->g2indx->version==2) {
+  if (pfi->g2indx->bigflg) {
     seek = *(pfi->g2indx->g2bigpnt+irec);
     ifld = *(pfi->g2indx->g2intpnt+irec);
   } else {
@@ -1572,7 +1577,7 @@ gaint g2off,ng2elems=2;
     ifld = *(pfi->g2indx->g2intpnt+irec+1);
   }
   if (debug==2) {
-    snprintf(pout,255,"gairow debug: seek,ifld = %jd %ld\n",seek, ifld);
+    snprintf(pout,255,"gairow debug: seek,ifld = %ld %ld\n",(long)seek,(long)ifld);
     gaprnt(0,pout);
   }
 
@@ -2463,7 +2468,7 @@ gaint gancsetup (void) {
 		}
 		snprintf(pout,255,"%ld bytes)\n",(long)size);
 		gaprnt(1,pout);
-		snprintf(pout,255,"*** cache size = %ld bytes \n",cachesz);
+		snprintf(pout,255,"*** cache size = %ld bytes \n",pfi->cachesize);
 		gaprnt(1,pout);
 		gaprnt(1,"*** There are two ways to control the cache size: \n");
 		gaprnt(1,"*** add a CACHESIZE entry to the descriptor file \n");
@@ -2712,7 +2717,6 @@ gaint oldncopts ;         /* to save and restore setting for automatic error han
     if (pvr->units[i] == -104) { start[i] = ee; count[i] = elen; }
     if (pvr->units[i] >=0) { start[i] = pvr->units[i];  count[i] = 1; }
   }
-
   /* what is the real order of dimension sizes in grtmp? */
   got1 = 0;
   nid = njd = -1 ; 
@@ -3444,36 +3448,38 @@ gaint h5setup(void) {
   
   /* Check the chunk size */
   ndims = pvr->nvardims;
-  if ((chsize = (hsize_t*)galloc(ndims*sizeof(hsize_t),"chsize"))!=NULL) {
-    if ((plid = H5Dget_create_plist(vid)) > 0) {
-      if ((rank = H5Pget_chunk(plid,ndims,chsize)) > 0) {
-	if ((tid  = H5Dget_type(vid)) > 0) {
-	  if ((size = H5Tget_size(tid)) > 0) {
-	    nelems = 1;
-	    for (i=0; i<ndims; i++) nelems *= chsize[i];
-	    if (nelems*size > pfi->cachesize) {
-	      gaprnt(1,"*** WARNING! ***\n");
-	      gaprnt(1,"*** The I/O for this variable will be extremely slow \n");
-	      gaprnt(1,"*** because the chunks are too big to fit in the cache \n");
-	      snprintf(pout,255,"*** chunk size = %ld bytes  (",(long)(nelems*size));
-	      gaprnt(1,pout);
-	      for (i=ndims-1; i>=0; i--) { 
-		snprintf(pout,255,"%ld * ",(long)chsize[i]); gaprnt(1,pout); 
-	      }
-	      snprintf(pout,255,"%ld bytes)\n",(long)size);
-	      gaprnt(1,pout);
-	      snprintf(pout,255,"*** cache size = %ld bytes \n",pfi->cachesize);
-	      gaprnt(1,pout);
-	      gaprnt(1,"*** There are two ways to control the cache size: \n");
-	      gaprnt(1,"*** add a CACHESIZE entry to the descriptor file \n");
-	      gaprnt(1,"*** or use the 'set cachesf' command \n");
-	      gaprnt(1,"*** Please read http://iges.org/grads/gadoc/compression.html \n");
-	    }
-	  }
-	}
+  if ((plid = H5Dget_create_plist(vid)) > 0) {
+    if ((H5Pget_layout(plid)) == H5D_CHUNKED) {
+      if ((chsize = (hsize_t*)galloc(ndims*sizeof(hsize_t),"chsize"))!=NULL) {
+        if ((rank = H5Pget_chunk(plid,ndims,chsize)) > 0) {
+	  if ((tid  = H5Dget_type(vid)) > 0) {
+	    if ((size = H5Tget_size(tid)) > 0) {
+	      nelems = 1;
+              for (i=0; i<ndims; i++) nelems *= chsize[i];
+                if (nelems*size > pfi->cachesize) {
+                gaprnt(1,"*** WARNING! ***\n");
+                gaprnt(1,"*** The I/O for this variable will be extremely slow \n");
+                gaprnt(1,"*** because the chunks are too big to fit in the cache \n");
+                snprintf(pout,255,"*** chunk size = %ld bytes  (",(long)(nelems*size));
+                gaprnt(1,pout);
+                for (i=ndims-1; i>=0; i--) { 
+                	snprintf(pout,255,"%ld * ",(long)chsize[i]); gaprnt(1,pout); 
+                }
+                snprintf(pout,255,"%ld bytes)\n",(long)size);
+                gaprnt(1,pout);
+                snprintf(pout,255,"*** cache size = %ld bytes \n",pfi->cachesize);
+                gaprnt(1,pout);
+                gaprnt(1,"*** There are two ways to control the cache size: \n");
+                gaprnt(1,"*** add a CACHESIZE entry to the descriptor file \n");
+                gaprnt(1,"*** or use the 'set cachesf' command \n");
+                gaprnt(1,"*** Please read http://iges.org/grads/gadoc/compression.html \n");
+              }
+            }
+          }
+        }
+        gree(chsize,"f274");
       }
     }
-    gree(chsize,"f274");
   }
 #endif
   return(0); 
@@ -3602,14 +3608,13 @@ gafloat *fval;
     if (pvr->units[i] == -104) { start[i] = e-1; count[i] = 1;   }
     if (pvr->units[i] >= 0) { start[i] = pvr->units[i];   count[i] = 1; }
   }
-
   /* select the desired hyperslab in the source dataspace */
   if ((H5Sselect_hyperslab(pvr->dataspace, H5S_SELECT_SET, start, NULL, count, NULL))<0) {
     gaprnt(0,"HDF5 Error: unable to select dataspace hyperslab\n");
     return (1);
   }
   /* create a new destination dataspace  and open it for access */
-  if ((memspace  = H5Screate_simple(pvr->nvardims,count,NULL))<0) {
+  if ((memspace  = H5Screate_simple(pvr->nh5vardims,count,NULL))<0) {
     gaprnt(0,"HDF5 Error: unable to create memspace\n");
     return (1);
   }
@@ -4829,6 +4834,7 @@ gadouble *dval=NULL;
     H5Aclose(aid);
     H5Tclose(atype);
   }
+  
   h5closevar(dsid,vid);
   return(n_atts);
 #endif
diff --git a/src/galloc.c b/src/galloc.c
index 7862a3e..7242d1a 100644
--- a/src/galloc.c
+++ b/src/galloc.c
@@ -1,3 +1,6 @@
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
+    See file COPYRIGHT for more information.   */
+
 #ifdef HAVE_CONFIG_H
 #include "config.h"
 
diff --git a/src/gamach.c b/src/gamach.c
index 66677fc..9974ac6 100644
--- a/src/gamach.c
+++ b/src/gamach.c
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 /* 
@@ -289,7 +288,7 @@ unsigned char *ch1;
       *(ch1+3) = *(ch+ioff);
       *(ch1+2) = *(ch+ioff+1);
       *(ch1+1) = *(ch+ioff+2);
-      *ch1     = *(ch+ioff+3);
+      *ch1 = *(ch+ioff+3);
     }
   }
   return (ival);
diff --git a/src/gasdf.c b/src/gasdf.c
index d18d101..d92219a 100644
--- a/src/gasdf.c
+++ b/src/gasdf.c
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 /*  
@@ -934,12 +933,12 @@ utUnit timeunit ;
 		}
 	      } 
 	      else /* monthly or greater */ {
-		if (tvals[6] < (60.0 * 24.0 * 360.0)) {
+		if (incrfactor < (60.0 * 24.0 * 360.0)) {
 		  tvals[5] = ((gaint) ((incrfactor / (60.0 * 24.0)) + 0.5)) / 28;
 		  tvals[6] = 0.0 ;
 		} 
 		else {
-		  gaprnt(0,"gadsdf: Time increment too large for 'minutes since' time units attribute\n");
+		  gaprnt(0,"gadsdf: Time increment is too large for 'minutes since' time units attribute\n");
 		  goto err2;
 		}
 	      }
@@ -1895,6 +1894,7 @@ gaint findZ(struct gafile *pfi, struct gavar **Zcoordptr, gaint *ispressptr) {
 	if (!strncasecmp(attr->value, "hybrid_sigma_pressure", 21)) match=1;
 	if (!strncasecmp(attr->value, "mb", 2)) match=1;  
 	if (!strncasecmp(attr->value, "millibar", 8)) match=1;  
+	if (!strncasecmp(attr->value, "hPa", 3)) match=1;
 	if (match) {
 	  *Zcoordptr = lclvar ;
 	  *ispressptr = 1 ;
@@ -2353,6 +2353,7 @@ char dimname[H4_MAX_NC_NAME+1];
     pvar->isu = 0;
     pvar->isdvar = 0;
     pvar->nvardims = 0;
+    pvar->nh5vardims = 0; 
     for (ii=0; ii<16; ii++) pvar->units[ii]=-999;
 
     /* get the variable info */
diff --git a/src/gauser.c b/src/gauser.c
index 07671f5..42c5555 100644
--- a/src/gauser.c
+++ b/src/gauser.c
@@ -1,5 +1,4 @@
-/*  copyright (C) 1988-2010 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 /* Authored by B. Doty */
@@ -41,6 +40,10 @@
 #include "grads.h"
 #include "gx.h"
 
+#ifdef OPENGRADS
+#include "gaudx.h"
+#endif
+
 char *gatxtl(char *str, int level);
 
 extern struct gamfcmn mfcmn;
@@ -65,10 +68,12 @@ gaint gacmd (char *com, struct gacmn *pcm, gaint exflg) {
 struct gafile *pfi,*pfi2;
 struct gadefn *pdf,*pdf2;
 struct gaclct *clct,*clct2;
-gaint rc,reinit,fnum,i,len,retcod,flag,xin,yin,bwin,gifflg,tcolor;
+gaint rc,reinit,fnum,i,len,retcod,flag,xin,yin,bwin,fmtflg,tcolor,pos;
+gadouble border;
 char cc[260], bgImage[256], fgImage[256];
-char *cmd,*rslt,*ccc,*ch;
+char *cmd,*rslt,*ccc,*ch,ext[10];
 size_t sz;
+char *formats[7] = {"EPS","PS","PDF","SVG","PNG","GIF","JPG"};
 
   ccc = NULL;
   gaiomg();   /* enable interpolation message */
@@ -77,9 +82,9 @@ size_t sz;
   while(*(com+len)) len++;
   len++;
   sz = len+1;
-  ccc = (char *)galloc(sz,"ccc");
+  ccc = (char *)galloc(sz,"cmd");
   if (ccc==NULL) {
-    gaprnt(0,"Memory allocation error: Command Proecessing\n");
+    gaprnt(0,"Memory allocation error: Command Processing\n");
     return(1);
   }
   for (i=0; i<len; i++) *(ccc+i) = *(com+i);
@@ -96,6 +101,7 @@ size_t sz;
   if (*cmd>='a' && *cmd<='z') {
     i = 0;
     ch = cmd;
+    /* defined variable names are alphanumeric, and must start with a letter */
     while ( (*ch>='a' && *ch<='z') || (*ch>='0' && *ch<='9' ) ) {
       i++;
       if (i>16) break;
@@ -120,7 +126,19 @@ size_t sz;
     }
   }
 
-  if (!(cmpwrd("clear",cmd) || cmpwrd("c",cmd))) gxfrme (9);
+#ifdef OPENGRADS
+  /* OpenGrADS User Defined Extensions */
+  savpcm = pcm;
+  retcod = (int) gaudc (com);
+  if ( retcod >= 0 ) goto retrn; /* found a udc, all done */
+  else retcod = 0;               /* not found, keep going */
+#endif
+
+  /* if command is NOT clear ...*/
+  if (!(cmpwrd("clear",cmd) || cmpwrd("c",cmd))) {  
+    gxfrme (9);  /* ... clear the X request buffer */
+  }
+
   if (*com=='\0' || *com=='\n') goto retrn; 
 
   if (cmpwrd("quit",cmd)) {
@@ -172,9 +190,11 @@ size_t sz;
     goto retrn;
 
   } else if (cmpwrd("reset",cmd) || cmpwrd("reinit",cmd)) {
+    /* reset vpage */
     pcm->xsiz = pcm->pxsize;
     pcm->ysiz = pcm->pysize;
     gxvpag (pcm->xsiz, pcm->ysiz, 0.0, pcm->xsiz, 0.0, pcm->ysiz);
+    /* reset gacmn and call gacln */
     gainit();
     gacln (pcm,1);
     gacln (pcm,2);
@@ -238,8 +258,6 @@ size_t sz;
       pcm->dfnum = 0;
       pcm->undef =  -9.99e8;         /* default undef value */
       pcm->pdf1 = NULL;
-      pcm->grflg = 0;
-      pcm->devbck = 0;
       if (pcm->ffile) fclose(pcm->ffile);
       pcm->ffile = NULL;
       if (pcm->sfile) fclose(pcm->sfile);
@@ -250,14 +268,13 @@ size_t sz;
       if (pcm->ncwid != -999) nc_close(pcm->ncwid);
 #endif
       pcm->fwenflg = BYTEORDER;
-      gxhend();
-      gxdbck(pcm->devbck);
-      gxgrey(pcm->grflg);
 #if GRIB2
       g2clear();
 #endif
       gaprnt (1,"All files closed; all defined objects released;\n");
-    }
+    } /* end of actions for 'reinit' */
+
+    /* reset the default file and the dimension environment */
     if (pcm->fnum>0 && pcm->pfi1) {
       pcm->pfid = pcm->pfi1;
       pcm->dfnum = 1;
@@ -290,13 +307,22 @@ size_t sz;
       gacmd ("set t 1",pcm,0);
       gacmd ("set e 1",pcm,0);
     }
+    /* reset graphics settings */
+    if (reinit) {
+      gxdbck(0);             /* device backgroud reset to black only on reinit, not reset */
+    }
+    gxdsignal(3);            /* tell hardware to re-enable anti-aliasing */
+    gxdbsethersh(0);         /* set hershey font on   */
     gxchdf(0);               /* set default font to 0 */ 
+    gxcolr(1);               /* set color to foreground */    
+    gxdbsettransclr(-1);     /* unset any transparent color override */
     gxfrme (1);
     if (reinit)
       gaprnt (1,"All GrADS attributes have been reinitialized\n");
     else gaprnt (1,"Most GrADS attributes have been reset\n");
     goto retrn;
   }
+
   else if (cmpwrd("screen",cmd)) {
     if ((cmd=nxtwrd(cmd)) == NULL) {
       gaprnt (0,"Screen Error: Missing keyword\n");
@@ -389,21 +415,22 @@ size_t sz;
     rc = 0;
     if ((cmd=nxtwrd(cmd)) != NULL) {
       rc=99;
-      if (cmpwrd("norset",cmd))   rc = 1;
-      if (cmpwrd("events",cmd))   rc = 2;
-      if (cmpwrd("graphics",cmd)) rc = 3;
-      if (cmpwrd("hbuff",cmd))    rc = 4;
-      if (cmpwrd("button",cmd))   rc = 5;
-      if (cmpwrd("rband",cmd))    rc = 6;
-      if (cmpwrd("dropmenu",cmd)) rc = 7;
-      if (cmpwrd("sdfwrite",cmd)) rc = 8;
-      if (cmpwrd("mask",cmd))     rc = 9;
-      if (cmpwrd("shp",cmd))      rc = 10;
+      if (cmpwrd("norset",cmd))   rc = 1;  /* clears without resetting user options */
+      if (cmpwrd("events",cmd))   rc = 2;  /* flushes the Xevents buffer */
+      if (cmpwrd("graphics",cmd)) rc = 3;  /* clears the graphics but not the widgets */
+      if (cmpwrd("hbuff",cmd))    rc = 4;  /* clears the buffered display and turns off double buffer mode */
+      if (cmpwrd("button",cmd))   rc = 5;  /* clears a button */
+      if (cmpwrd("rband",cmd))    rc = 6;  /* clears a rubber band */
+      if (cmpwrd("dropmenu",cmd)) rc = 7;  /* clears a dropmenu */
+      if (cmpwrd("sdfwrite",cmd)) rc = 8;  /* clears sdfwrite filename and attributes only */
+      if (cmpwrd("mask",cmd))     rc = 9;  /* clears contour label mask */
+      if (cmpwrd("shp",cmd))      rc = 10; /* clears shapefile output filename and attributs only */
     }
     if (rc==99) {
       gaprnt (0,"Invalid option on clear command\n");
       goto retrn;
     }
+    /* clear the frame and X-related other options */
     if (rc<2) {
       if (exflg) gxfrme (0);
       else gxfrme (1);
@@ -422,13 +449,15 @@ size_t sz;
       }
       gxrs1wd (rc-4, fnum);
     }
+    else if (rc==9) gxmaskclear();
+    /* call gacln (reset gacmn) with different options */
+    if (pcm->aaflg==0) gxdsignal(3); /* tell hardware to re-enable anti-aliasing */
     if (rc==1) gacln(pcm,0);
-    else if (rc==8) gacln(pcm,2);  /* clears sdfwrite file name and attributes */
     else if (rc<5 || rc==99) {
       gacln (pcm,1);
       pcm->dbflg = 0;
     }
-    else if (rc==9) gxmaskclear();
+    else if (rc==8) gacln(pcm,2);  /* clears sdfwrite file name and attributes */
     else if (rc==10) gacln(pcm,3);  /* clears user-provided shapefile attributes */
     goto retrn;
   }
@@ -492,11 +521,13 @@ size_t sz;
     goto retrn;
   }
   else if (cmpwrd("disable",cmd)) {
-    if ((cmd=nxtwrd(com)) == NULL) 
-      gxhend();                                     /* without 2nd arg, assume 'disable print' */ 
+    if ((cmd=nxtwrd(com)) == NULL) {
+      gaprnt(0,"DISABLE error: Missing keyword\n");
+      goto retrn;
+    }
     else {
       if (cmpwrd("print",cmd)) 
-	gxhend();                                   /* close the metafile output file  */
+	gaprnt(0,"ERROR: The \"disable print\" command is no longer valid. Use \"gxprint\" instead.\n");
       else if (cmpwrd("fwrite",cmd)) {
 	if (pcm->ffile) {                           /* don't close a file unless it's open  */ 
 	  if (pcm->ffile!=stdout) fclose(pcm->ffile);    /* don't close stdout */    
@@ -517,137 +548,199 @@ size_t sz;
     goto retrn;
   }
   else if (cmpwrd("redraw",cmd)) {
-    gardrw(com,pcm);
-    gxfrme(9);
+    gardrw (com,pcm);
+    gxfrme (9);
     goto retrn;
   }
   else if (cmpwrd("draw",cmd)) {
-    gadraw(com,pcm);
-    gxfrme (9);          /* flush any buffers as needed */
+    gadraw (com,pcm);
+    gxsignal (1);        /* tell rendering layer and metabuffer draw is done */
+    gxfrme (9);          /* flush X request buffer */
     goto retrn;
   }
   else if (cmpwrd("print",cmd)) {
-    gxhprt (com);
+    gaprnt(0,"ERROR: The \"print\" command is no longer valid. Use \"gxprint\" instead.\n");
     goto retrn;
   }
-#if GXPNG==1
-  else if (cmpwrd("printim",cmd)) {
+  else if (cmpwrd("gxprint",cmd) || cmpwrd("printim",cmd)) {
+    /* check for output file name */
     if ((ch=nxtwrd(com)) == NULL) {
-      gaprnt (0,"PRINTIM error:  missing output file name\n");
+      gaprnt (0,"GXPRINT error:  missing output file name\n");
       retcod = 1;
       goto retrn;
     }
+    /* check for irregularities in output file name */
     getwrd (cc,ch,256);
     if ((cmd=nxtwrd(cmd)) == NULL) {
-      gaprnt (0,"PRINTIM error:  logic error 64\n");
+      gaprnt (0,"GXPRINT error:  logic error 64\n");
       retcod = 1;
       goto retrn;
     }
+    /* initialize */
     xin = -999;
     yin = -999;
     bwin = -999;
-    gifflg = 9;
-    bgImage[0]='\0';
-    fgImage[0]='\0';
-    tcolor=-1;
+    fmtflg = 0;
+    bgImage[0] = '\0';
+    fgImage[0] = '\0';
+    tcolor = -1;
+    border = -1.0;
+    /* parse the user-provided options */
     while ((cmd=nxtwrd(cmd)) != NULL) {
+      /* set backgroud/foreground colors */
       if      (cmpwrd("black",cmd))  bwin = 0;
       else if (cmpwrd("white",cmd))  bwin = 1;
-      else if (cmpwrd("png",cmd))  gifflg = 0;
-      else if (cmpwrd("gif",cmd))  gifflg = 1;
-      else if (cmpwrd("jpg",cmd))  gifflg = 3;
-      else if (cmpwrd("jpeg",cmd)) gifflg = 3;
+      /* explicit format types -- the union of all possibilities from all rendering engines */
+      else if (cmpwrd("eps",cmd))  fmtflg = 1;
+      else if (cmpwrd("ps" ,cmd))  fmtflg = 2;
+      else if (cmpwrd("pdf",cmd))  fmtflg = 3;
+      else if (cmpwrd("svg",cmd))  fmtflg = 4;
+      /* ... image formats start here ... */
+      else if (cmpwrd("png",cmd))  fmtflg = 5;
+      else if (cmpwrd("gif",cmd))  fmtflg = 6;
+      else if (cmpwrd("jpg",cmd))  fmtflg = 7;
+      else if (cmpwrd("jpeg",cmd)) fmtflg = 7;
+      /* get background image filename */
       else if (cmpwrd("-b",cmd)) {
-	/* get background image filename */
-        if((cmd=nxtwrd(cmd)) != NULL) {
-          if(strlen(cmd) < 256){
+        if ((cmd=nxtwrd(cmd)) != NULL) {
+          if (strlen(cmd) < 256){
             getwrd(bgImage,cmd, 255);
-            snprintf(pout,255,"Background image file: %s \n", bgImage);
-	    gaprnt(2,pout);
           }
         } else {
-          gaprnt(1,"PRINTIM warning: Background image file name not provided\n");
+          gaprnt(1,"GXPRINT warning: Background image file name not provided\n");
 	  if (cmd == NULL) break;
 	}
       }
+      /* get foreground image filename */
       else if (cmpwrd("-f",cmd)) {
-	/* get foreground image filename */
         if((cmd=nxtwrd(cmd)) != NULL) {
           if(strlen(cmd) < 256){
             getwrd(fgImage,cmd, 255);
-            snprintf(pout,255,"Foreground image file: %s \n", fgImage);
-	    gaprnt(2,pout);
           }
 	} else {
-          gaprnt(1,"PRINTIM warning: Foreground image file name not provided\n");
+          gaprnt(1,"GXPRINT warning: Foreground image file name not provided\n");
 	  if (cmd == NULL) break;
 	}
       }
+      /* set transparent color number */
       else if (cmpwrd("-t",cmd)) {
 	/* set transparent color number */
         if((cmd=nxtwrd(cmd)) != NULL) {
-	  if(sscanf(cmd, "%i", &tcolor) != 1) {
-	     gaprnt(1,"PRINTIM warning: Invalid transparent color number\n");
-	  } 
+	  if(sscanf(cmd, "%i", &tcolor) != 1) {    /* get a color number  */
+	     gaprnt(1,"GXPRINT warning: Invalid transparent color number\n");
+	  }
 	} else {
-	  gaprnt(1,"PRINTIM warning: Missing transparent color number\n");
+	  gaprnt(1,"GXPRINT warning: Missing transparent color number\n");
 	  if (cmd == NULL) break;
 	}
       }
+      /* set horizontal image size */
       else if (*cmd=='x') {
-	/* set horizontal image size */
         if (intprs(cmd+1,&(xin)) == NULL ) {
-          gaprnt (0,"PRINTIM error:  Invalid x option; ignored\n");
+          gaprnt (0,"GXPRINT error:  Invalid x option; ignored\n");
           xin = -999;
         }
       }
+      /* set vertical image size */
       else if (*cmd=='y') {
-	/* set vertical image size */
         if (intprs(cmd+1,&(yin)) == NULL ) {
-          gaprnt (0,"PRINTIM error: Invalid y option; ignored\n");
+          gaprnt (0,"GXPRINT error: Invalid y option; ignored\n");
           yin = -999;
         }
-      } else {
-        gaprnt (0,"PRINTIM error: Invalid option; ignored\n");
       }
-    }
-    if (gifflg == 9) {
+      /* set width of border around the edge of the plot */
+      else if (cmpwrd("-e",cmd)) {
+        if((cmd=nxtwrd(cmd)) != NULL) {
+	  if (getdbl(cmd,&border) == NULL) {   
+	     gaprnt(1,"GXPRINT warning: Invalid edge width \n");
+	  }
+	} else {
+	  gaprnt(1,"GXPRINT warning: Missing edge width \n");
+	  if (cmd == NULL) break;
+	}
+      }
+      else {
+        gaprnt (0,"GXPRINT error: Invalid option; ignored\n");
+      }
+    }    
+    /* done parsing options */
+
+    /* try to divine the format from the output filename extension */
+    if (fmtflg == 0) {
       len = 0;
       while (*(cc+len)) len++;
-      len = len-4;
-      if (len>0) {
-	/* png */
-        if (*(cc+len)=='.' && *(cc+len+1)=='p' && *(cc+len+2)=='n' && *(cc+len+3)=='g' ) gifflg = 0;
-        if (*(cc+len)=='.' && *(cc+len+1)=='P' && *(cc+len+2)=='N' && *(cc+len+3)=='G' ) gifflg = 0;
-	/* gif */
-        if (*(cc+len)=='.' && *(cc+len+1)=='g' && *(cc+len+2)=='i' && *(cc+len+3)=='f' ) gifflg = 1;
-        if (*(cc+len)=='.' && *(cc+len+1)=='G' && *(cc+len+2)=='I' && *(cc+len+3)=='F' ) gifflg = 1;
-	/* jpg */
-        if (*(cc+len)=='.' && *(cc+len+1)=='j' && *(cc+len+2)=='p' && *(cc+len+3)=='g' ) gifflg = 3;
-        if (*(cc+len)=='.' && *(cc+len+1)=='J' && *(cc+len+2)=='P' && *(cc+len+3)=='G' ) gifflg = 3;
-      }
-      if (gifflg==9) gifflg = 0; /* png is default format */
-    }
-    rc = gxhpng (cc,xin,yin,bwin,gifflg,bgImage,fgImage,tcolor);
-    if (rc==1) gaprnt (0,"PRINTIM error: open error\n");
-    if (rc==2) gaprnt (0,"PRINTIM error: output error\n");
-    if (rc==3) gaprnt (0,"PRINTIM error: background image open error\n");
-    if (rc==4) gaprnt (0,"PRINTIM error: foreground image open error\n");
-    if (rc==5) gaprnt (0,"PRINTIM error: background image must be .png\n");
-    if (rc==6) gaprnt (0,"PRINTIM error: foreground image must be .png\n");
-    if (rc==7) gaprnt (0,"PRINTIM error: gdImageCreate failed for background image\n");
-    if (rc==8) gaprnt (0,"PRINTIM error: gdImageCreate failed for foreground image\n");
+      pos = len;
+      for (pos=len; pos>=0; pos--) if (*(cc+pos)=='.') break;
+      len = len-pos;
+      if (pos>0) {
+	for (i=0;i<len;i++) ext[i] = *(cc+pos+i); 
+	lowcas (ext);
+	if (!strncmp(ext, ".eps",4)) fmtflg = 1;
+	if (!strncmp(ext, ".ps" ,3)) fmtflg = 2;
+	if (!strncmp(ext, ".pdf",4)) fmtflg = 3;
+	if (!strncmp(ext, ".svg",4)) fmtflg = 4;
+	if (!strncmp(ext, ".png",4)) fmtflg = 5;
+	if (!strncmp(ext, ".gif",4)) fmtflg = 6;
+	if (!strncmp(ext, ".jpg",4)) fmtflg = 7;
+      }
+    }
+    if (fmtflg == 0) {
+      gaprnt (0,"GXPRINT error: Unable to determine output format\n");
+      retcod = 1;
+      goto retrn;
+    }
+    
+    /* Image size specs are incompatible with non-image formats */
+    if (fmtflg==1 || fmtflg==2 || fmtflg==3 || fmtflg==4) {
+      if (xin>0 || yin>0) {
+	snprintf(pout,255,"GXPRINT Warning: Image size specifications are incompatible with the %s format and will be ignored\n",
+		 formats[fmtflg-1]);
+	gaprnt (1,pout);
+	xin = -999;
+	yin = -999;
+      }
+    }
+
+    /* fgImage and bgImage options are incompatible with non-image formats */
+    if (fmtflg==1 || fmtflg==2 || fmtflg==3 || fmtflg==4) {
+      if (*bgImage || *fgImage) {
+	snprintf(pout,255,"GXPRINT Warning: Background/Foreground images are incompatible with the %s format and will be ignored\n",
+		 formats[fmtflg-1]);
+	gaprnt (1,pout);
+	bgImage[0]='\0';
+	fgImage[0]='\0';
+      }
+    }
+
+    /* vector formats ps, eps, and pdf get a 5/32" edge by default, all others have no edge */
+    if (border < 1.0) { 
+      border = 0.0;  
+      if (fmtflg==1 || fmtflg==2 || fmtflg==3) border = 0.15625;
+    }
+
+    /* Create the hardcopy output */
+    rc = gxprint (cc,xin,yin,bwin,fmtflg,bgImage,fgImage,tcolor,border);
+    if (rc==1)  gaprnt (0,"GXPRINT error: something went wrong during rendering of the output file\n");
+    if (rc==2)  gaprnt (0,"GXPRINT error: output error\n");
+    if (rc==3)  gaprnt (0,"GXPRINT error: background image open error\n");
+    if (rc==4)  gaprnt (0,"GXPRINT error: foreground image open error\n");
+    if (rc==5)  gaprnt (0,"GXPRINT error: background image must be .png\n");
+    if (rc==6)  gaprnt (0,"GXPRINT error: foreground image must be .png\n");
+    if (rc==7)  gaprnt (0,"GXPRINT error: failed to import background image\n");
+    if (rc==8)  gaprnt (0,"GXPRINT error: failed to import foreground image\n");
+    if (rc==9)  gaprnt (0,"GXPRINT error: unsupported output format\n");
+    if (rc==10) gaprnt (0,"GXPRINT error: background image must be the same size as output\n");
+    if (rc==11) gaprnt (0,"GXPRINT error: foreground image must be the same size as output\n");
     if (rc) retcod = 1;
-    else retcod = 0;
-    goto retrn;
-  }
-#else
-  else if (cmpwrd("printim",cmd)) {
-    gaprnt (0,"PRINTIM error: command not supported in this build\n");
-    retcod = 1;
+    else {
+      retcod = 0;
+      snprintf(pout,255,"Created %s file %s",formats[fmtflg-1], cc); gaprnt(2,pout); 
+      if (*bgImage) { snprintf(pout,255," ; bgImage = %s",bgImage); gaprnt(2,pout); }
+      if (*fgImage) { snprintf(pout,255," ; fgImage = %s",fgImage); gaprnt(2,pout); }
+      gaprnt(2,"\n");
+    }
     goto retrn;
   }
-#endif
   else if (cmpwrd("set",cmd)) {
     retcod = gaset (cmd, com, pcm);
     goto retrn;
@@ -691,6 +784,7 @@ size_t sz;
       goto retrn;
     }
     retcod = gadspl (cmd, pcm);
+    gxsignal (1);        /* tell rendering engine and metafile buffer display is finished */
     gxfrme (9);          /* flush any buffers as needed */
     goto retrn;
   }
@@ -772,13 +866,16 @@ void mygreta(char *path) {
 /*  } */
 }
 
+
+
 /* if flag is 0, clean without resetting user options. 
    if flag is 1, clean and reset user options except sdfwrite & shapefile parameters
    if flag is 2, clean and reset only sdfwrite parameters 
    if flag is 3, clean and reset only shapefile fields
    if flag is 4, clean and reset only KML and GeoTIFF options
-   The reset/reinit commands calls gacln four times, with flag=1 and flag=2, flag=3, and flag=4.
 
+   The clear command calls gacln with flag=1.
+   The reset/reinit commands calls gacln four times, with flag=1 and flag=2, flag=3, and flag=4.
 */
 
 void gacln (struct gacmn *pcm, gaint flg) {
@@ -803,12 +900,14 @@ struct dbfld *fld,*nextfld;
   pcm->ygr2ab = NULL;
   pcm->xab2gr = NULL;
   pcm->yab2gr = NULL;
+  pcm->aaflg = 1;      
 
   /* reset sdfwrite parameters */
   if (flg==2) {
     pcm->ncwid = -999;
     pcm->sdfwtype = 1;
     pcm->sdfwpad = 0;
+    pcm->sdfrecdim = 0;
     pcm->sdfchunk = 0;
     pcm->xchunk = 0;
     pcm->ychunk = 0;
@@ -838,8 +937,9 @@ struct dbfld *fld,*nextfld;
   /* reset shapefile fields */ 
   if (flg==3) {
 #if USESHP==1    
-    /* reset shapefile type to line */
+    /* reset shapefile type to line and no fill */
     pcm->shptype=2; 
+    pcm->fillpoly = -1;
     /* release file name */
     if (pcm->shpfname) {
       gree (pcm->shpfname,"g89");
@@ -887,7 +987,7 @@ struct dbfld *fld,*nextfld;
   if (flg==1) {
     pcm->cstyle = -9;
     pcm->ccolor = -9;
-    pcm->cthick = 3;
+    pcm->cthick = 4;
     pcm->cmark = -9;
     pcm->cint = 0;
     pcm->cflag = 0;
@@ -930,7 +1030,6 @@ struct dbfld *fld,*nextfld;
     pcm->tlsupp = 0;
     pcm->ptflg = 0;
     pcm->cachesf = 1.0; 
-    pcm->fillpoly = -1;
     pcm->marktype = 3;
     pcm->marksize = 0.05;
   }
@@ -1177,7 +1276,7 @@ char shparg[4096];
     gxchln (cmd,len,pcm->strhsz,&swide);
     shite = pcm->strvsz;
 
-    ang = pcm->strrot*M_PI/180;
+    ang = pcm->strrot*M_PI/180.0;
     x = x - justx[pcm->strjst] * swide * cos(ang);
     y = y - justx[pcm->strjst] * swide * sin(ang);
     x = x - justy[pcm->strjst] * shite * cos(ang+1.5708);
@@ -1409,6 +1508,7 @@ char shparg[4096];
 	      }
 	      
 	      /* draw the line, or draw border around the polygon */
+  
 	      gxwide (pcm->linthk);            
 	      gxstyl(pcm->linstl); 
 	      gxcolr (pcm->lincol);
@@ -1416,6 +1516,7 @@ char shparg[4096];
 	      for (j=1; j<newcnt; j++) {
 		gxplot (*(newxy+j*2),*(newxy+j*2+1),2);
 	      }
+  
 	      /* release memory holding the x,y coordinates for this part */
 	      gree(newxy,"f204a");
 	    }
@@ -1434,7 +1535,9 @@ char shparg[4096];
       SHPDestroyObject (shp); shp=NULL;
     }
     SHPClose (shpid);
-    /* redraw the frame around the plot */
+    /* Calling gafram() here is important because the shapes are likely to overlap the frame 
+       and it will need to be redrawn. Also, gafram() will change the color which will
+       trigger the reset of the color mask.  */
     gafram(pcm);
     /* reset the clipping area */
     gxclip (0.0, pcm->xsiz, 0.0, pcm->ysiz);
@@ -1501,8 +1604,7 @@ char shparg[4096];
       if (llinc<0.0001) llinc=0.0001;
   
       /* Do the interpolation and convert to x,y -- 
-         the gxmpoly routine does this and is located in
-         gxwmap */
+         the gxmpoly routine does this and is located in gxwmap */
 
       newxy = gxmpoly(xy,cnt,llinc,&newcnt); 
       gree(xy,"f204");
@@ -1707,6 +1809,10 @@ char cc[256], *ch;
     gaprnt (0,"ENABLE error: Invalid operand \n");
     return (1);
   }
+  else {
+    gaprnt(0,"ERROR: The \"enable print\" command is no longer valid. Use \"gxprint\" instead.\n");
+    return (1);
+  }
   if ((ch=nxtwrd(ch)) == NULL) {
     gaprnt (0,"ENABLE error: Missing file name \n");
     return (1);
@@ -1714,7 +1820,7 @@ char cc[256], *ch;
   cmd = nxtwrd(cmd);
   cmd = nxtwrd(cmd);
   getwrd (cc,cmd,256);
-  rc = gxhbgn(cc);
+  /* if we ever re-use the enable command, this is where the function call will go */
   return (rc);
 }
 
@@ -2169,12 +2275,13 @@ char name[20];
   }
   name[i] = '\0';
   if (*cmd!='=') {
-    gaprnt (0,"DEFINE error:  Name too long; missing '='\n");
+    gaprnt (0,"DEFINE error: Failed to find '=' after parsing the defined variable name \n");
+    gaprnt (0,"              The name may be too long or contain non-alphanumeric characters \n");
     goto retrn;
   }
   cmd++;
   if (*cmd=='\0') {
-    gaprnt (0,"DEFINE error:  expression missing\n");
+    gaprnt (0,"DEFINE error: Missing expression\n");
     goto retrn;
   }
 
@@ -2184,8 +2291,8 @@ char name[20];
 
   pfi = pcm->pfid;
   if (pfi->type==2 || pfi->type==3) {
-    gaprnt (0,"Define error:  Define not yet valid for station data\n");
-    gaprnt (0,"    Default file is a station data file\n");
+    gaprnt (0,"DEFINE error: Define not yet valid for station data\n");
+    gaprnt (0,"              Default file is a station data file\n");
     goto retrn;
   }
 
@@ -2538,8 +2645,10 @@ char name[20];
   *prev = pdf;          /* Chain it up */
   pdf->pforw = NULL;
   getwrd(pdf->abbrv,name,19);
-  gree(pgr1,"f96");
+
   gree(pst,"f97");
+  gree(pgr1,"f96"); 
+
   /* Restore user dim limits*/
   pcm->dmax[2] = zmax;
   pcm->tmax    = tmax;                    
@@ -2618,7 +2727,6 @@ struct dt tdef, tdefi;
 char *tfile, *tfile2;
 gaint ncid=0, rc, error, n_atts, n_gatts;
 gaint sdid=0;
-char dimname[256];
 #endif
 #if USEHDF5 == 1
 gaint h5id=-999;
@@ -2650,6 +2758,7 @@ gadouble minvals[4], maxvals[4];
     gaprnt (2,"  q dialog   Launches a dialog box\n");
     gaprnt (2,"  q dims     Returns current dimension environment\n");
     gaprnt (2,"  q ens      Returns a list of ensemble members\n");
+    gaprnt (2,"  q fgvals   Returns values and colors specified for gxout fgrid\n");
     gaprnt (2,"  q file     Returns info on a particular file\n");
     gaprnt (2,"  q files    Lists all open files\n");
     gaprnt (2,"  q fwrite   Returns status of fwrite output file\n");
@@ -2677,6 +2786,16 @@ gadouble minvals[4], maxvals[4];
   else if (cmpwrd(arg,"mem")) {
     glook();
   }
+  else if (cmpwrd(arg,"bcol")) {
+    snprintf(pout,255,"Background color is %d\n",gxdbkq());
+    gaprnt(2,pout);
+  }
+  else if (cmpwrd(arg,"lcol")) {
+    snprintf(pout,255,"Current line color is %d\n",gxqclr());
+    gaprnt(2,pout);
+    snprintf(pout,255,"pcm->lincol is %d\n",pcm->lincol);
+    gaprnt(2,pout);
+  }
   else if (cmpwrd(arg,"undef")) {
     snprintf(pout,255,"Output undef value is set to %12f\n",pcm->undef);
     gaprnt(2,pout);
@@ -3220,15 +3339,27 @@ gadouble minvals[4], maxvals[4];
     }
     snprintf(pout,255,"SDFwrite output undef value is set to %12f\n",pcm->undef);
     gaprnt(2,pout);
-    if (pcm->sdfwpad==0) {
-      gaprnt (2,"SDFwrite file will have same number of dimensions as defined variable\n");
-    }
-    if (pcm->sdfwpad==1) {
-      gaprnt (2,"SDFwrite file will have at least 4 dimensions\n");
-    }
-    if (pcm->sdfwpad==2) {
-      gaprnt (2,"SDFwrite file will have 5 dimensions\n");
-    }
+    /* information about dimensions */
+    if (pcm->sdfwpad==0)
+      gaprnt (2,"SDFwrite file will have the same number of dimensions as the defined variable\n");
+    if (pcm->sdfwpad==1)
+      gaprnt (2,"SDFwrite file will have 3 dimensions: lon, lat, and lev\n");
+    if (pcm->sdfwpad==2)
+      gaprnt (2,"SDFwrite file will have 3 dimensions: lon, lat, and time\n");
+    if (pcm->sdfwpad==3) 
+      gaprnt (2,"SDFwrite file will have 4 dimensions: lon, lat, lev, and time\n");
+    if (pcm->sdfwpad==4)
+      gaprnt (2,"SDFwrite file will have 5 dimensions: lon, lat, lev, time, and ens\n");
+    /* including the record dimension */
+    if (pcm->sdfrecdim==1) 
+      gaprnt (2,"SDFwrite file will have 1 record dimension: time\n");
+    else if (pcm->sdfrecdim==2)
+      gaprnt (2,"SDFwrite file will have 1 record dimension: ens\n");
+    else if (pcm->sdfrecdim==3)
+      gaprnt (2,"SDFwrite file will have 2 record dimensions: time and ens\n");
+    else
+      gaprnt (2,"SDFwrite file will not have a record dimension\n");
+
     if (pcm->attr) {
       attr=pcm->attr;
       gaprnt (2,"SDFwrite attribute metadata:\n");
@@ -3883,6 +4014,15 @@ gadouble minvals[4], maxvals[4];
     }
   }
 
+  else if (cmpwrd(arg,"fgvals")) {
+    snprintf(pout,255,"Number of fgvals = %d\n",pcm->fgcnt);
+    gaprnt(2,pout);
+    for (i=0; i<pcm->fgcnt; i++) {
+      snprintf(pout,255,"%d %d\n",pcm->fgcols[i],pcm->fgvals[i]);
+      gaprnt(2,pout);
+    }
+  }
+
   else if (cmpwrd(arg,"time")) {
     if (pcm->pfi1==NULL) {
       gaprnt (0,"No Files Open\n");
@@ -4143,6 +4283,7 @@ gadouble minvals[4], maxvals[4];
 #endif
     }
 
+
     /* Print netcdf coordinate attributes */
 #if USENETCDF == 1
     if (pfi->ncflg == 1) {
@@ -4371,7 +4512,7 @@ static gaint dcolor[10] = {-1, 1, 3, 7, 2, 6, 9, 10, 11, 12 };
   if (!lflg) {            /* not looping */
     pcm->mcolor = 8;
     if (pcm->ccolor==-9) {
-      if (vcnt==2 && pcm->grflg==0) 
+      if (vcnt==2) 
 	pcm->ccolor = dcolor[pcm->pass%10];
       else 
 	pcm->ccolor = dcolor[(pcm->pass+1)%10];
@@ -4380,7 +4521,7 @@ static gaint dcolor[10] = {-1, 1, 3, 7, 2, 6, 9, 10, 11, 12 };
       pcm->cmark = pcm->pass+2;
       while (pcm->cmark>5) pcm->cmark-=5;
     }
-    if (pcm->ccolor<0 || pcm->grflg) pcm->mcolor = 15;
+    if (pcm->ccolor<0) pcm->mcolor = 15;
     rc = gapars(cmd, pst, pcm);
     if (rc) goto retrn;
     gaplot (pcm); 
@@ -4405,7 +4546,7 @@ static gaint dcolor[10] = {-1, 1, 3, 7, 2, 6, 9, 10, 11, 12 };
     pcm->mcolor = 15; 
     if (pcm->ccolor==-9) {
       pcm->ccolor = -1;
-      if (vcnt<2 || pcm->grflg) pcm->ccolor = 1;
+      if (vcnt<2) pcm->ccolor = 1;
     }
     if (pcm->cmark==-9) {
       pcm->cmark = pcm->pass+2;
@@ -4556,14 +4697,16 @@ err:
   return (1);
 }
 
-void gagrel (struct gacmn *pcm) {
+/* release data objects */
+
+void gagrel (struct gacmn *pcm) { 
 gaint i;
 
   for (i=0; i<pcm->relnum; i++) {
-    if (pcm->type[i]==1) {
+    if (pcm->type[i]==1) 
       gagfre (pcm->result[i].pgr);
-    }
-    else gasfre (pcm->result[i].stn);
+    else 
+      gasfre (pcm->result[i].stn);
   }
   pcm->numgrd = 0;
   pcm->relnum = 0;
@@ -4583,13 +4726,14 @@ struct dbfld *fld, *newfld=NULL;
 gadouble (*conv) (gadouble *, gadouble);
 gadouble v1,v2,*vals,tt;
 gadouble val1,val2,xlo,xhi,ylo,yhi;
-gaint kwrd,i,i1,i2,num,id,itt,itt1,itt2,itmp[5];
+gaint kwrd,i,i1,i2,num,id,itt,itt1,itt2,itmp[20];
 gaint enum1,enum2;
 gaint xx,yy,red,green,blue;
 char *ch=NULL,*ch2=NULL,*strng,*pat,*cmd1;
 char ename1[16],ename2[16];
 size_t sz;
-static char *kwds[125] = {"X","Y","Z","T","LON","LAT","LEV","TIME",
+char *tileimg=NULL;
+static char *kwds[129] = {"X","Y","Z","T","LON","LAT","LEV","TIME",
 			  "CINT","CSTYLE","CCOLOR","LOOPDIM",
 			  "LOOPING","LOOPINCR","DFILE","VRANGE",
 			  "CSMOOTH","GRID","CMARK","XAXIS","YAXIS",
@@ -4613,7 +4757,8 @@ static char *kwds[125] = {"X","Y","Z","T","LON","LAT","LEV","TIME",
 			  "DATAWARN","DIALOG","WRITEGDS","COSLAT",
 			  "E","ENS","SDFWRITE","SDFATTR","GEOTIFF","KML",
 			  "UNDEF","CHUNKSIZE","CACHESF","SHPOPTS",
-			  "SHP","SHPATTR","LOG1D","STRMOPTS"};
+			  "SHP","SHPATTR","LOG1D","STRMOPTS","TILE",
+			  "HERSHEY","LWID","ANTIALIAS"};
 
   strng = NULL;
   kwrd=-1;
@@ -4699,15 +4844,80 @@ static char *kwds[125] = {"X","Y","Z","T","LON","LAT","LEV","TIME",
     }
     pcm->bargap = itt;
   }
+  else if (cmpwrd("lwid",cmd)) {
+    kwrd = 127;
+    if ((cmd = nxtwrd (cmd)) == NULL) goto err;
+    if (intprs(cmd,&itt) == NULL ) goto err;
+    if (itt<13 || itt>256) {
+      gaprnt(0,"SET LWID Error: line thickness index number must be between 13 and 256\n");
+      return(1);
+    }
+    if ((cmd = nxtwrd (cmd)) == NULL) goto err;
+    if (getdbl(cmd,&v1) == NULL ) goto err;
+    gxdbsetwid(itt,v1);
+  }
   else if (cmpwrd("font",cmd)) {
     kwrd = 85;
     if ((cmd = nxtwrd (cmd)) == NULL) goto err;
     if (intprs(cmd,&itt) == NULL ) goto err;
-    if (itt<0 || itt>9) {
-      gaprnt(0,"SET FONT Error: font must be 0 to 9\n");
+    if (itt<0 || itt>99) {
+      gaprnt(0,"SET FONT Error: font must be 0 to 99\n");
       return(1);
     }
-    gxchdf(itt);
+    gxchdf(itt);  /* change the default font in gxchpl.c */
+    if ((cmd = nxtwrd (cmd)) != NULL) {
+      /* check for 'file' keyword */
+      if (cmpwrd("file",cmd)) {
+	if ((cmd = nxtwrd (cmd)) != NULL) {
+	  /* user has provided a file to define a new font */
+	  if (itt<10) {
+	    gaprnt(0,"SET FONT Error: Cannot define new font for font numbers less than 10\n"); 
+	    return(1);
+	  }
+	  else {
+	    /* get the length of the user-supplied filename */
+	    itt2 = 0;
+	    while (*(cmd+itt2)!='\n'&&*(cmd+itt2)!='\0') itt2++; /* spaces are allowed */
+	    /* allocate memory for tmp filename */
+	    ch = NULL;
+	    ch = (char *)malloc(itt2+1);
+	    if (ch==NULL) {
+	      gaprnt (0,"Memory allocation error for tmp font file name\n"); goto err;
+	    }
+	    /* copy the user-supplied filename (mixed case) to ch */
+	    i2 = cmd - cmd1;
+	    for (i1=0; i1<itt2; i1++) *(ch+i1) = *(com+i1+i2);
+	    *(ch+itt2)='\0';      /* make sure it is null-terminated */
+	    gxdbsetfn (itt, ch); 
+	    free (ch);
+	  }
+	}
+      }
+      else {
+	gaprnt(0,"SET FONT Error: Missing keyword \"file\" in new font definition\n"); 
+	return(1);
+      }
+    }
+  }
+  else if (cmpwrd("hershey",cmd)) {
+    kwrd = 126;
+    if ((cmd = nxtwrd (cmd)) == NULL) goto err;
+    if (cmpwrd("on",cmd))       gxdbsethersh(0);  /* 0, use hershey fonts */  
+    else if (cmpwrd("off",cmd)) gxdbsethersh(1);  /* 1, use emulation */  
+    else goto err;
+  }
+  else if (cmpwrd("antialias",cmd)) {
+    kwrd = 126;
+    if ((cmd = nxtwrd (cmd)) == NULL) goto err;
+    if (cmpwrd("off",cmd)) {
+      pcm->aaflg = 0;   /* set flag in gacmn */
+      gxsignal(2);      /* tell hardware and metabuffer to disable anti-aliasing */  
+    }
+    else if (cmpwrd("on",cmd)) {
+      pcm->aaflg = 1;   /* set flag in gacmn */
+      gxsignal(3);      /* tell hardware and metabuffer to enable anti-aliasing */
+    }
+    else goto err;
   }
   else if (cmpwrd("clip",cmd)) {
     kwrd = 66;
@@ -4797,25 +5007,39 @@ static char *kwds[125] = {"X","Y","Z","T","LON","LAT","LEV","TIME",
   else if (cmpwrd("rgb",cmd)) {
     kwrd = 44;
     if ((cmd = nxtwrd (cmd)) == NULL) goto err;
-    if (intprs(cmd,&itt) == NULL ) goto err;
-    if ((cmd = nxtwrd (cmd)) == NULL) goto err;
-    if (intprs(cmd,&red) == NULL ) goto err;
-    if ((cmd = nxtwrd (cmd)) == NULL) goto err;
-    if (intprs(cmd,&green) == NULL ) goto err;
+    if (intprs(cmd,&itt) == NULL) goto err;
     if ((cmd = nxtwrd (cmd)) == NULL) goto err;
-    if (intprs(cmd,&blue) == NULL ) goto err;
-    if (itt<16 || itt>255 || 
-	red<0 || red>255 ||  
-        green<0 || green>255 || 
-	blue<0 || blue>255) {
-      gaprnt (0,"SET RGB Error:  Invalid color number or rgb value\n");
-      gaprnt (0,"  Color number must be 16-255, rgb value 0-255\n");
-      return(1);
+    if (cmpwrd("tile",cmd)) {
+      if ((cmd = nxtwrd (cmd)) == NULL) goto err;
+      if (intprs(cmd,&green) == NULL) goto err;
+      red = -9; blue = -9;
+    } else {
+      if (intprs(cmd,&red) == NULL) goto err;
+      if ((cmd = nxtwrd (cmd)) == NULL) goto err;
+      if (intprs(cmd,&green) == NULL) goto err;
+      if ((cmd = nxtwrd (cmd)) == NULL) goto err;
+      if (intprs(cmd,&blue) == NULL) goto err;
+      if ((cmd = nxtwrd (cmd)) == NULL) 
+	itt2 = 255; 
+      else {
+        if (intprs(cmd,&itt2) == NULL)  goto err;
+      }
+      if (itt<16 || itt>2048) {
+        gaprnt (0,"SET RGB Error:  Color number must be between 16 and 2048 \n");
+        return(1);
+      }
+      if (red<0   || red>255   ||  
+	  green<0 || green>255 ||  
+	  blue<0  || blue>255) {   
+        gaprnt (0,"SET RGB Error:  RGB values must be between 0 and 255 \n");
+        return(1);
+      }
+      if (itt2<-255 || itt2>255) { 
+        gaprnt (0,"SET RGB Error:  Alpha value must be between -255 and 255 \n");
+        return(1);
+      }
     }
-    if (!gxacol (itt,red,green,blue) ) {
-      snprintf(pout,255,"Color R:%i G:%i B:%i Unavailable: closest color assigned\n",red,green,blue);
-      gaprnt (2,pout);
-    } 
+    gxacol (itt,red,green,blue,itt2);
   }
   else if (cmpwrd("stat",cmd)) {
     kwrd = 102;
@@ -5352,18 +5576,27 @@ static char *kwds[125] = {"X","Y","Z","T","LON","LAT","LEV","TIME",
   else if (cmpwrd("sdfwrite",cmd)) {
     kwrd = 113;
     if ((cmd = nxtwrd (cmd)) == NULL) goto err;  
+    /* options for padding the output and setting a record dimension 
+       are set to 'off' with each new call to 'set sdfwrite' */
+    pcm->sdfwpad = 0;   
+    pcm->sdfrecdim = 0;
     /* parse any arguments to 'set sdfwrite' command */
-    pcm->sdfwpad = 0;  
     while (cmpwrd("-4d",cmd)  || cmpwrd("-5d",cmd) || 
+	   cmpwrd("-3dz",cmd) || cmpwrd("-3dt",cmd) ||
 	   cmpwrd("-flt",cmd) || cmpwrd("-dbl",cmd) ||
 	   cmpwrd("-nc3",cmd) || cmpwrd("-nc4",cmd) ||
+	   cmpwrd("-rt",cmd)  || cmpwrd("-re",cmd) ||
 	   cmpwrd("-zip",cmd) || cmpwrd("-chunk",cmd)) {
-      if (cmpwrd("-4d",cmd))    pcm->sdfwpad = 1;   
-      if (cmpwrd("-5d",cmd))    pcm->sdfwpad = 2;
+      if (cmpwrd("-3dz",cmd))   pcm->sdfwpad = 1;   
+      if (cmpwrd("-3dt",cmd))   pcm->sdfwpad = 2;   
+      if (cmpwrd("-4d",cmd))    pcm->sdfwpad = 3;   
+      if (cmpwrd("-5d",cmd))    pcm->sdfwpad = 4;
       if (cmpwrd("-dbl",cmd))   pcm->sdfprec = 8;
       if (cmpwrd("-flt",cmd))   pcm->sdfprec = 4;
       if (cmpwrd("-nc3",cmd))   pcm->sdfwtype = 1;
       if (cmpwrd("-nc4",cmd))   pcm->sdfwtype = 2;
+      if (cmpwrd("-rt",cmd))    pcm->sdfrecdim+=1;
+      if (cmpwrd("-re",cmd))    pcm->sdfrecdim+=2;
       if (cmpwrd("-zip",cmd))   pcm->sdfzip = 1;
       if (cmpwrd("-chunk",cmd)) pcm->sdfchunk = 1;
 
@@ -5387,15 +5620,16 @@ static char *kwds[125] = {"X","Y","Z","T","LON","LAT","LEV","TIME",
     snprintf(pout,255,"SDFWrite file name = %s\n",ch);
     gaprnt (2,pout);
     gaprnt (2,"SDFWrite will replace an existing file\n");
-    if (pcm->sdfwpad==0) {
-      gaprnt (2,"SDFwrite file will have same number of dimensions as defined variable\n");
-    }
-    if (pcm->sdfwpad==1) {
-      gaprnt (2,"SDFwrite file will have at least 4 dimensions\n");
-    }
-    if (pcm->sdfwpad==2) {
-      gaprnt (2,"SDFwrite file will have 5 dimensions\n");
-    }
+    if (pcm->sdfwpad==0)
+     gaprnt (2,"SDFwrite file will have the same number of dimensions as the defined variable\n");
+    if (pcm->sdfwpad==1)
+      gaprnt (2,"SDFwrite file will have 3 dimensions: lon, lat, and lev\n");
+    if (pcm->sdfwpad==2)
+      gaprnt (2,"SDFwrite file will have 3 dimensions: lon, lat, and time\n");
+    if (pcm->sdfwpad==3) 
+      gaprnt (2,"SDFwrite file will have 4 dimensions: lon, lat, lev, and time\n");
+    if (pcm->sdfwpad==4)
+      gaprnt (2,"SDFwrite file will have 5 dimensions: lon, lat, lev, time, and ens\n");
 #if HAVENETCDF4 != 1
     /* reset flags if we dont' have netcdf-4 */
     if (pcm->sdfwtype == 2) {
@@ -5403,18 +5637,38 @@ static char *kwds[125] = {"X","Y","Z","T","LON","LAT","LEV","TIME",
       gaprnt(2,"         sdfwrite output will be netCDF classic format instead\n");
       pcm->sdfwtype = 1;
       if (pcm->sdfchunk==1) {
-	gaprnt(2,"         without chunking ");
+	gaprnt(2,"         without chunking\n");
 	pcm->sdfchunk = 0;
       }
       if (pcm->sdfzip==1) {
-	gaprnt(2,"or compression");
+	gaprnt(2,"         without compression\n");
 	pcm->sdfzip = 0;
       }
-      gaprnt(2,"\n");
     }
 #endif
+    /* check for two record dimensions */
+    if (pcm->sdfrecdim==3 && pcm->sdfwtype==1) {
+      gaprnt(0,"Only one record dimension is allowed with netCDF classic format. \n");
+      gaprnt(0,"  Use the \"-nc4\" option to enable multiple record dimensions. \n");
+      goto err;
+    }
+    if (pcm->sdfrecdim==1) 
+      gaprnt (2,"SDFwrite file will have 1 record dimension: time\n");
+    else if (pcm->sdfrecdim==2)
+      gaprnt (2,"SDFwrite file will have 1 record dimension: ens\n");
+    else if (pcm->sdfrecdim==3)
+      gaprnt (2,"SDFwrite file will have 2 record dimensions: time and ens\n");
+    else
+      gaprnt (2,"SDFwrite file will not have a record dimension\n");
+
     /* If -zip, make sure we have -nc4 and -chunk */
     if (pcm->sdfzip) {
+      if (pcm->sdfwtype==1) {
+	gaprnt(0,"Compression is not available with netCDF classic format. \n");
+	gaprnt(0,"  Use the \"-nc4\" option to enable compression or \n");
+	gaprnt(0,"  reset the compression option with \"clear sdfwrite\". \n");
+	goto err;
+      }
       pcm->sdfwtype = 2;
       pcm->sdfchunk = 1;
     }
@@ -5595,7 +5849,7 @@ static char *kwds[125] = {"X","Y","Z","T","LON","LAT","LEV","TIME",
       itt2 = itt;
       while (*(cmd+itt)!=' '&&*(cmd+itt)!='\n'&&*(cmd+itt)!='\0') itt++;
       sz = itt+2-itt2;
-      ch = (char *)galloc(sz,"setmpdset");
+      ch = (char *)galloc(sz,"setmpds");
       if (ch==NULL) {
         gaprnt (0,"Memory allocation Error\n");
         goto err;
@@ -5634,24 +5888,23 @@ static char *kwds[125] = {"X","Y","Z","T","LON","LAT","LEV","TIME",
   else if (cmpwrd("display",cmd)) {
     kwrd = 57;
     if ((cmd = nxtwrd (cmd)) == NULL) goto err;
-    if (cmpwrd("color",cmd)) pcm->grflg=0;
-    else if (cmpwrd("grey",cmd)) pcm->grflg=1;
-    else if (cmpwrd("greyscale",cmd)) pcm->grflg=1;
+    if      (cmpwrd("color",cmd) || cmpwrd("grey",cmd) || cmpwrd("greyscale",cmd)) itt=2; /* this will be a no-op */
+    else if (cmpwrd("white",cmd)) itt=1; 
+    else if (cmpwrd("black",cmd)) itt=0; 
     else goto err;
     if ((cmd = nxtwrd (cmd)) != NULL) {
-      if (cmpwrd("white",cmd)) pcm->devbck = 1;
-      else if (cmpwrd("black",cmd)) pcm->devbck = 0;
+      if      (cmpwrd("white",cmd)) itt = 1;
+      else if (cmpwrd("black",cmd)) itt = 0;
       else goto err;
     }
-    gxdbck(pcm->devbck);
-    gxgrey(pcm->grflg);
+    if (itt==0 || itt==1) gxdbck(itt);
   }
   else if (cmpwrd("gxout",cmd)) {
     kwrd = 21;
     if ((cmd = nxtwrd (cmd)) == NULL) goto err;
     pcm->gout0 = 9;
     if      (cmpwrd("contour",cmd))  pcm->gout2a = 1;
-    else if (cmpwrd("shaded",cmd))   pcm->gout2a = 2;
+    else if (cmpwrd("shaded",cmd))   pcm->gout2a = 16;
     else if (cmpwrd("shade1",cmd))   pcm->gout2a = 2;
     else if (cmpwrd("shade2",cmd))   pcm->gout2a = 16;
     else if (cmpwrd("shade2b",cmd))  pcm->gout2a = 17;
@@ -5839,11 +6092,14 @@ static char *kwds[125] = {"X","Y","Z","T","LON","LAT","LEV","TIME",
       if ((cmd = nxtwrd (cmd)) != NULL) {
         if (intprs(cmd,&itt) == NULL ) goto err;
         else pcm->grcolr = itt;
+	if ((cmd = nxtwrd (cmd)) != NULL) {
+	  if (intprs(cmd,&itt) == NULL ) goto err;
+	  else pcm->grthck = itt;
+	}
       }
     }
     if (pcm->grflag) {
-      snprintf(pout,255,"grid is on, style %i color %i \n",
-         pcm->grstyl, pcm->grcolr);
+      snprintf(pout,255,"grid is on, style %i color %i thickness %d\n",pcm->grstyl,pcm->grcolr,pcm->grthck);
       gaprnt (2,pout);
     } else {
       gaprnt (2,"grid is off\n");
@@ -6169,10 +6425,8 @@ static char *kwds[125] = {"X","Y","Z","T","LON","LAT","LEV","TIME",
         }
       }
     }
-    snprintf(pout,255,"SET LINE values:  color = %i  style = %i",
-      pcm->lincol, pcm->linstl);
-    gaprnt (2,pout);
-    snprintf(pout,255,"  thickness = %i\n",pcm->linthk);
+    snprintf(pout,255,"SET LINE values:  color = %i  style = %i  thickness = %i\n",
+	     pcm->lincol, pcm->linstl, pcm->linthk);
     gaprnt (2,pout);
   }
   else if (cmpwrd("map",cmd)) {
@@ -6201,10 +6455,8 @@ static char *kwds[125] = {"X","Y","Z","T","LON","LAT","LEV","TIME",
     if (pcm->mapcol < 0 ) {
       gaprnt (2,"SET MAP values:  auto\n");
     } else {
-      snprintf(pout,255,"SET MAP values:  color = %i  style = %i",
-        pcm->mapcol, pcm->mapstl);
-      gaprnt (2,pout);
-      snprintf(pout,255,"  thickness = %i\n",pcm->mapthk);
+      snprintf(pout,255,"SET MAP values:  color = %i  style = %i  thickness = %i\n",
+	       pcm->mapcol, pcm->mapstl, pcm->mapthk);
       gaprnt (2,pout);
     }
   }
@@ -6393,7 +6645,7 @@ static char *kwds[125] = {"X","Y","Z","T","LON","LAT","LEV","TIME",
     if (intprs(cmd,&itt) == NULL ) goto err;
     snprintf(pout,255,"background = %i \n",itt);
     gaprnt (2,pout);
-    gxbckg(itt);
+    gxdbck(itt);        
   }
   else if (cmpwrd("cthick",cmd)) {
     kwrd = 49;
@@ -6776,6 +7028,71 @@ static char *kwds[125] = {"X","Y","Z","T","LON","LAT","LEV","TIME",
     else if (cmpwrd("off",cmd) ) pcm->dwrnflg = 0;
     else goto err;
   }
+  else if (cmpwrd("tile",cmd)) {
+    kwrd = 125;
+    for (i=0; i<15; i++) itmp[i] = -999;
+    if ((cmd = nxtwrd (cmd)) == NULL) goto err;
+    if (intprs(cmd,itmp) == NULL ) goto err;  /* tile number */
+    if (*(itmp+0)<0 || *(itmp+0)>=COLORMAX) {
+      snprintf (pout,255,"Tile number must be between 0 and %d\n",COLORMAX-1); 
+      gaprnt (0,pout);
+      goto err;
+    } 
+    if ((cmd = nxtwrd (cmd)) == NULL) goto err;
+    if (intprs(cmd,itmp+1) == NULL ) goto err;  /* tile type */
+    if (*(itmp+1)<0 || *(itmp+1)>8) {
+      snprintf (pout,255,"Tile type must be between 0 and 8\n"); 
+      gaprnt (0,pout);
+      goto err;
+    } 
+
+    /* check for type 0 */
+    if (*(itmp+1)==0) {
+      if ((cmd = nxtwrd (cmd)) != NULL) {
+	/* user has provided a file to define a new tile -- get the length */
+	itt2 = 0;
+	while (*(cmd+itt2)!='\n'&&*(cmd+itt2)!='\0') itt2++; /* spaces are allowed */
+	/* allocate memory for tile filename */
+	tileimg = (char *)malloc(itt2+1);
+	if (tileimg==NULL) {
+	  gaprnt (0,"Memory allocation error for tile image filename\n"); goto err;
+	}
+	/* copy the user-supplied filename (mixed case) to tileimg */
+	i2 = cmd - cmd1;
+	for (i1=0; i1<itt2; i1++) *(tileimg+i1) = *(com+i1+i2);
+	/* Make sure filename ends in ".png"  */
+	i = itt2-4;
+	if (i>0) {
+	  if (*(tileimg+i+1)!='p' || *(tileimg+i+2)!='n' || *(tileimg+i+3)!='g' ) {
+	    if (*(tileimg+i+1)!='P' || *(tileimg+i+2)!='N' || *(tileimg+i+3)!='G' ) {
+	      gaprnt(0,"Custom tile image file must be PNG format\n");
+	      free (tileimg);
+	      goto err;
+	    }
+	  }
+	}
+	*(tileimg+itt2)='\0';      /* ensure tile image filename is null-terminated */
+	/* check if file exists*/
+	FILE *tileimgfile=NULL;
+	tileimgfile=fopen(tileimg,"rb");
+	if (tileimgfile==NULL) {
+	  gaprnt(0,"Unable to open tile image file\n");
+	  free (tileimg);
+	  goto err;
+	}
+	else fclose(tileimgfile);
+      }
+    }
+    else {
+      /* get rest of args for on-the-fly tile generation */
+      for (i=2; i<7; i++) {  
+	if ((cmd = nxtwrd (cmd)) == NULL) break;
+	if (intprs(cmd,itmp+i) == NULL ) goto err;
+      }
+    }
+    gxdbsetpatt(itmp,tileimg);
+    if (tileimg) free (tileimg);
+  }
   else if (cmpwrd("fill",cmd)) {
     kwrd = 96;
     pat = (char *)galloc(6,"fillpat");
@@ -7024,6 +7341,7 @@ gaint rc;
       gaprnt (1," Updated documentation is at http://iges.org/grads/gadoc/pdef.html\n");
     }
   }
+  
   return (0);
 }
 
@@ -7476,7 +7794,9 @@ gadouble *axis, *axis0;
 gadouble (*conv) (gadouble *, gadouble);
 gaint i, rc;
 size_t sz;
- 
+size_t start, count;
+
+ /* populate a local array with the coordinate values */
  axis = NULL;
  sz = sizeof(gadouble)*pfi->dnum[dim];
  axis = (gadouble *)galloc(sz,"sdfaxis");
@@ -7502,7 +7822,20 @@ size_t sz;
    }
  }
  axis = axis0;
- rc = nc_put_var_double(pcm->ncwid, varid, axis0);
+
+ /* When writing the coordinate values to the file,
+    use nc_put_vara_double if it's a record dimension */
+
+ if ((dim==4 && (pcm->sdfrecdim==2 || pcm->sdfrecdim==3)) ||
+     (dim==3 && (pcm->sdfrecdim==1 || pcm->sdfrecdim==3))) {
+   count = (size_t)pfi->dnum[dim];
+   start = 0;
+   rc = nc_put_vara_double(pcm->ncwid, varid, &start, &count, axis0);
+ }
+ else {
+   rc = nc_put_var_double(pcm->ncwid, varid, axis0);
+ }
+
  if (rc) {
    snprintf(pout,255,"sdfwdim error from nc_put_var_double (dim=%d): \n ",dim);
    gaprnt(0,pout);
@@ -7516,11 +7849,16 @@ size_t sz;
 }
 
 /* Routine to set up a coordinate dimension and variable in a self-describing output file */
-gaint sdfdefdim (gaint fileid, char *dimname, gaint dimsize, gaint *dimid, gaint *varid) {
+gaint sdfdefdim (gaint fileid, char *dimname, gaint dimsize, gaint *dimid, gaint *varid, 
+		 gaint recflg, gaint sdfwtype) {
 #if USENETCDF == 1
 gaint rc;
+size_t chunksize;
  /* define the dimension */
- rc = nc_def_dim(fileid, dimname, dimsize, dimid);
+ if (recflg)
+   rc = nc_def_dim(fileid, dimname, NC_UNLIMITED, dimid);
+ else
+   rc = nc_def_dim(fileid, dimname, dimsize, dimid);
  if (rc) {
    snprintf(pout,255,"sdfdefdim error from nc_def_dim (%s): \n ",dimname);
    gaprnt (0,pout);
@@ -7535,6 +7873,23 @@ gaint rc;
    handle_error(rc); 
    return (1);
  }
+
+#if HAVENETCDF4==1
+ /* define record dimensions as chunked for netcdf-4 files */
+ if (recflg && sdfwtype==2) {
+   chunksize = (size_t)dimsize;
+   rc = nc_def_var_chunking (fileid, *dimid, NC_CHUNKED, &chunksize);
+   if (rc) {
+     snprintf(pout,255,"sdfdefdim error from nc_def_var_chunking (%s): \n ",dimname);
+     gaprnt(0,pout);
+     handle_error(rc);
+     return (1);
+   }
+ }
+#endif
+
+
+
  return (0);
 #endif
  return(0);
@@ -7552,6 +7907,7 @@ gaint i,rc,nvdims=0,vdims[5],dimids[5];
 size_t start[5],count[5],*chunksize=NULL;
 gaint xdimid,ydimid,zdimid,tdimid,edimid;
 gaint xvarid,yvarid,zvarid,tvarid,evarid,varid;
+gaint padX,padY,padZ,padT,padE,recflg;
 char name[20],tunit[256];
 gafloat flundef,*flbuf=NULL;
 char *filename={"grads.sdfwrite.nc"};
@@ -7600,13 +7956,20 @@ char *filename={"grads.sdfwrite.nc"};
   /* initialize the vdims array */
   vdims[0] = vdims[1] = vdims[2] = vdims[3] = vdims[4] = -999;
 
-  /* Set up the dimensions and the coordinate variables. 
-     For now, no record dimension is defined.  */
-  
+  /* Set up the dimensions and the coordinate variables */ 
+  padX = padY = padZ = padT = padE = 0;
+  if (pcm->sdfwpad) {
+    padX = 1;
+    padY = 1;
+    if (pcm->sdfwpad==1 || pcm->sdfwpad>=3) padZ = 1;
+    if (pcm->sdfwpad>=2) padT = 1;
+    if (pcm->sdfwpad==4) padE = 1;
+  }
+
   /* X is varying or user wants to pad the output with non-varying dims */
-  if (pcm->vdim[0] || pcm->sdfwpad) {
+  if (pfi->dnum[0]>1 || padX) {
     /* define the dimension */
-    if (sdfdefdim (pcm->ncwid, "lon", pfi->dnum[0], &xdimid, &xvarid)) goto err;
+    if (sdfdefdim (pcm->ncwid, "lon", pfi->dnum[0], &xdimid, &xvarid, 0, pcm->sdfwtype)) goto err;
     /* assign default and user-defined attributes */
     if (sdfwatt(pcm, xvarid, "lon", "units", "degrees_east")) goto err;
     if (sdfwatt(pcm, xvarid, "lon", "long_name", "Longitude")) goto err;
@@ -7621,9 +7984,9 @@ char *filename={"grads.sdfwrite.nc"};
   }
 
   /* Y is varying or user wants to pad the output with non-varying dims  */
-  if (pcm->vdim[1] || pcm->sdfwpad) {                    
+  if (pfi->dnum[1]>1 || padY) {                    
     /* define the dimension */
-    if (sdfdefdim (pcm->ncwid, "lat", pfi->dnum[1], &ydimid, &yvarid)) goto err;
+    if (sdfdefdim (pcm->ncwid, "lat", pfi->dnum[1], &ydimid, &yvarid, 0, pcm->sdfwtype)) goto err;
     /* assign default and user-defined attributes */
     if (sdfwatt(pcm, yvarid, "lat", "units", "degrees_north")) goto err;
     if (sdfwatt(pcm, yvarid, "lat", "long_name", "Latitude")) goto err;
@@ -7638,9 +8001,9 @@ char *filename={"grads.sdfwrite.nc"};
   }
 
   /* Z is varying or user wants to pad the output with non-varying dims */
-  if (pcm->vdim[2] || pcm->sdfwpad) {                    
+  if (pfi->dnum[2]>1 || padZ) {                    
     /* define the dimension */
-    if (sdfdefdim (pcm->ncwid, "lev", pfi->dnum[2], &zdimid, &zvarid)) goto err;
+    if (sdfdefdim (pcm->ncwid, "lev", pfi->dnum[2], &zdimid, &zvarid, 0, pcm->sdfwtype)) goto err;
     /* assign default and user-defined attributes */
     if (sdfwatt(pcm, zvarid, "lev", "units", "millibar")) goto err;
     if (sdfwatt(pcm, zvarid, "lev", "long_name", "Level")) goto err;
@@ -7655,9 +8018,11 @@ char *filename={"grads.sdfwrite.nc"};
   }
 
   /* T is varying or user wants to pad the output with non-varying dims */
-  if (pcm->vdim[3] || pcm->sdfwpad) {                    
+  if (pfi->dnum[3]>1 || padT) {                    
     /* define the dimension */
-    if (sdfdefdim (pcm->ncwid, "time", pfi->dnum[3], &tdimid, &tvarid)) goto err;
+    recflg=0;
+    if (pcm->sdfrecdim==1 | pcm->sdfrecdim==3) recflg=1;
+    if (sdfdefdim (pcm->ncwid, "time", pfi->dnum[3], &tdimid, &tvarid, recflg, pcm->sdfwtype)) goto err;
     /* assign default and user-defined attributes */
     if (sdfwatt(pcm, tvarid, "time", "long_name", "Time")) goto err;
     if (sdfwatt(pcm, tvarid, "time", NULL, NULL)) goto err;
@@ -7681,9 +8046,11 @@ char *filename={"grads.sdfwrite.nc"};
   }
 
   /* E is varying or user wants to pad the output with non-varying dims */
-  if (pcm->vdim[4] || pcm->sdfwpad==2) {                    
+  if (pfi->dnum[4]>1 || padE) {                    
     /* define the dimension */
-    if (sdfdefdim (pcm->ncwid, "ens", pfi->dnum[4], &edimid, &evarid)) goto err;
+    recflg=0;
+    if (pcm->sdfrecdim>=2) recflg=1;
+    if (sdfdefdim (pcm->ncwid, "ens", pfi->dnum[4], &edimid, &evarid, recflg, pcm->sdfwtype)) goto err;
     /* assign default and user-defined attributes */
     if (sdfwatt(pcm, evarid, "ens", "grads_dim", "e")) goto err;
     if (sdfwatt(pcm, evarid, "ens", "long_name", "Ensemble member")) goto err;
@@ -7794,11 +8161,11 @@ char *filename={"grads.sdfwrite.nc"};
   }
 
   /* Write the coordinate variable data */
-  if (pcm->vdim[0] || pcm->sdfwpad) if (sdfwdim (pfi, pcm, 0, xvarid)) goto err;
-  if (pcm->vdim[1] || pcm->sdfwpad) if (sdfwdim (pfi, pcm, 1, yvarid)) goto err;
-  if (pcm->vdim[2] || pcm->sdfwpad) if (sdfwdim (pfi, pcm, 2, zvarid)) goto err;
-  if (pcm->vdim[3] || pcm->sdfwpad) if (sdfwdim (pfi, pcm, 3, tvarid)) goto err;
-  if (pcm->vdim[4] || pcm->sdfwpad==2) if (sdfwdim (pfi, pcm, 4, evarid)) goto err;
+  if (pfi->dnum[0]>1 || padX) if (sdfwdim (pfi, pcm, 0, xvarid)) goto err;
+  if (pfi->dnum[1]>1 || padY) if (sdfwdim (pfi, pcm, 1, yvarid)) goto err;
+  if (pfi->dnum[2]>1 || padZ) if (sdfwdim (pfi, pcm, 2, zvarid)) goto err;
+  if (pfi->dnum[3]>1 || padT) if (sdfwdim (pfi, pcm, 3, tvarid)) goto err;
+  if (pfi->dnum[4]>1 || padE) if (sdfwdim (pfi, pcm, 4, evarid)) goto err;
 
   /* set the start and count array values */
   for (i=0; i<nvdims; i++) {
diff --git a/src/gautil.c b/src/gautil.c
index 381e4ce..6492a81 100644
--- a/src/gautil.c
+++ b/src/gautil.c
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 /* Originally authored by B. Doty */
@@ -1118,7 +1117,9 @@ char *rmask;
   for (i=0;i<size;i++) {
     if (*rmask == 1) {
       cnt++;
-      if (pgr->rmin>*r) pgr->rmin = *r;
+      if (pgr->rmin>*r) {
+	pgr->rmin = *r;
+      }
       if (pgr->rmax<*r) pgr->rmax = *r;
     }
     r++; rmask++;
@@ -1565,19 +1566,68 @@ struct gachsub *pchsub;
 struct gaens *ens;
 struct dt stim;
 gaint len,olen,iv,tdif,i,tused,eused,mo,doy,dys,hrs,mns;
-char *fnout, *in, *out, *work, *in2, *out2;
+char *fnout, *in, *out, *work, *in2, *out2, *newfn;
 size_t sz;
 
   tused = eused = 0;
   olen = 0;
-  while (*(fn+olen)) olen++;
+  while (*(fn+olen)) olen++;              /* get length of original DSET entry */
   olen+=5;
   sz = olen;
-  fnout = (char *)galloc(sz+1,"fnout");
-  if (fnout==NULL) return (NULL);
+  newfn = (char *)galloc(sz+1,"newfn");  /* allocate memory for new DSET with chsubs */
+  if (newfn==NULL) return (NULL);
 
-  in = fn;
-  out = fnout;
+  in = fn;         /* original dset entry */
+  out = newfn;     /* output string */
+
+  /* Do the string substitution first */
+  while (*in) {
+    pchsub = pch1st;
+    if (*in=='%' && *(in+1)=='c' && *(in+2)=='h') {
+      /* we have a string to substitute */
+      tused=1;
+      while (pchsub) {
+        if (t>=pchsub->t1 && (pchsub->t2 == -99 || t<=pchsub->t2) ) {
+          len = wrdlen(pchsub->ch);           /* get length of substitution string */
+          olen += len;
+	  sz = olen;
+          work = (char *)galloc(sz+1,"work");  /* allocate memory for new chsubbed string */
+          if (work==NULL) { gree(newfn,"f240"); return (NULL); }
+
+	  out2 = work;                        
+          in2 = newfn;                       
+          while (in2!=out) {
+            *out2 = *in2;  /* copy chars from new DSET that occur before this %ch into new work string */
+            in2++; out2++;
+          }
+          gree(newfn,"f241");      
+          newfn = work;               /* replace newfn */
+          out = out2;                 /* replace output string */
+          getwrd(out,pchsub->ch,len); /* copy substitution string to output string */
+          out += len;
+          break;
+        }
+        pchsub = pchsub->forw;        
+      }
+      in+=3;
+    }
+    else {
+      /* just copy this character from original DSET entry to output string */
+      *out = *in;    
+      in++; out++;
+    }
+  }
+  *out = '\0';
+
+  /* Now begin again with new chsubbed dset entry and do all the time template substitutions */
+  in = newfn;
+  olen = 0;
+  while (*(newfn+olen)) olen++;
+  olen+=5;
+  sz = olen;
+  fnout = (char *)galloc(sz+1,"fnout");
+  if (fnout==NULL) { gree(newfn,"f240a"); return (NULL); }
+  out = fnout;  /* output string */
 
   while (*in) {
     pchsub = pch1st;
@@ -1619,6 +1669,7 @@ size_t sz;
         *out = *(mons[dtimi->mo-1]);
         *(out+1) = *(mons[dtimi->mo-1]+1);
         *(out+2) = *(mons[dtimi->mo-1]+2);
+
         out+=3;  in+=4;
       } else if (*(in+2)=='d' && *(in+3)=='1') {
         snprintf(out,sz,"%i",dtimi->dy);
@@ -1869,41 +1920,12 @@ size_t sz;
       while (*out) out++;
       in+=5;
     } 
-    /* string substitution */
-    else if (*in=='%' && *(in+1)=='c' && *(in+2)=='h') {
-      tused=1;
-      while (pchsub) {
-        if (t>=pchsub->t1 && (pchsub->t2 == -99 || t<=pchsub->t2) ) {
-          len = wrdlen(pchsub->ch);    /* Reallocate output string */
-          olen += len;
-	  sz = olen;
-          work = (char *)galloc(sz+1,"work");
-          if (work==NULL) {
-            gree(fnout,"f240");
-            return (NULL);
-          }
-          in2 = fnout; 
-	  out2 = work;
-          while (in2!=out) {
-            *out2 = *in2;
-            in2++; out2++;
-          }
-          gree(fnout,"f241");     
-          fnout = work;
-          out = out2;
-          getwrd(out,pchsub->ch,len);
-          out += len;
-          break;
-        }
-        pchsub = pchsub->forw;
-      }
-      in+=3;
-    } 
     /* ensemble name substitution */
     else if  (*in=='%' && *(in+1)=='e') {
       eused=1;
       if (ens == NULL) {
 	gree(fnout,"f242");
+        gree(newfn,"f240b");
 	return (NULL);
       } else {
 	/* advance through array of ensemble structures, till we reach ensemble 'e' */
@@ -1912,6 +1934,7 @@ size_t sz;
 	len = strlen(ens->name);
 	if (len < 1) {
 	  gree(fnout,"f243");
+          gree(newfn,"f240c");
 	  return (NULL);
 	}
 	olen += len;
@@ -1919,6 +1942,7 @@ size_t sz;
 	work = (char *)galloc(sz+1,"work2");     /* Reallocate output string */
 	if (work==NULL) {
 	  gree(fnout,"f244");
+          gree(newfn,"f240d");
 	  return (NULL);
 	}
 	in2 = fnout;            /* copy the string we've got so far */
@@ -1953,6 +1977,7 @@ size_t sz;
   else {
     *flag = 0;                       /* no templating */
   }
+  gree(newfn,"f240e");
   return (fnout);
 }
 
diff --git a/src/grads.c b/src/grads.c
index e28aaf6..3fa773d 100644
--- a/src/grads.c
+++ b/src/grads.c
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 /* Main program for GrADS (Grid Analysis and Display System).
@@ -67,7 +66,11 @@ struct gacmn gcmn;
 static struct gawgds wgds;   
 extern struct gamfcmn mfcmn;
 
+#ifdef OPENGRADS
+int Main (int argc, char *argv[])  {
+#else
 int main (int argc, char *argv[])  {
+#endif
 
 void command_line_help(void) ;
 void gxdgeo (char *);
@@ -75,7 +78,7 @@ void gxend (void);
 void gatxti(gaint on, gaint cs);
 char *gatxtl(char *str,gaint level);
 
-char cmd[500];
+char cmd[1024];
 gaint rc,i,j,land,port,cmdflg,hstflg,gflag,xwideflg,killflg,ratioflg;
 gaint metabuff,size=0,g2size=0;
 gaint txtcs=-2;
@@ -190,13 +193,16 @@ if (metabuff==1) printf ("Note: -m option was specified, but no metafile buffer
 if (ipcflg) printf("\n<IPC>" );  /* delimit splash screen */
 
 printf ("\nGrid Analysis and Display System (GrADS) Version %s\n",gatxtl(GRADS_VERSION,0));
-printf ("Copyright (c) 1988-2011 by Brian Doty and the\n");
-printf ("Institute for Global Environment and Society (IGES)\n");
+printf ("Copyright (C) 1988-2015 by the Institute for Global Environment and Society (IGES)\n");
 printf ("GrADS comes with ABSOLUTELY NO WARRANTY\n");
 printf ("See file COPYRIGHT for more information\n\n");
 
 gacfg(0);
 
+#ifdef OPENGRADS
+<gaudi(&gcmn); /* Initialize OpenGrADS User Defined Extensions */
+#endif
+
 
 if (!land && !port && aspratio<-990) {
   nxtcmd (cmd,"Landscape mode? ('n' for portrait): ");
@@ -241,11 +247,10 @@ gcmn.dfnum = 0;
 gcmn.undef = -9.99e8;         /* default undef value */
 gcmn.fseq = 10; 
 gcmn.pdf1 = NULL;
-gcmn.grflg = 0;
-gcmn.devbck = 0;
 gcmn.sdfwname = NULL;
 gcmn.sdfwtype = 1;
 gcmn.sdfwpad = 0;
+gcmn.sdfrecdim = 0;
 gcmn.sdfchunk = 0;
 gcmn.sdfzip = 0;
 gcmn.sdfprec = 8;
@@ -401,6 +406,7 @@ gaint i;
   gcmn.cmark = -9;
   gcmn.grflag = 1;
   gcmn.grstyl = 5;
+  gcmn.grthck = 4;
   gcmn.grcolr = 15;
   gcmn.blkflg = 0;
   gcmn.dignum = 0;
@@ -410,7 +416,6 @@ gaint i;
   gcmn.lincol = 1;
   gcmn.linstl = 1;
   gcmn.linthk = 3;
-
   gcmn.mproj = 2;
   gcmn.mpdraw = 1;
   gcmn.mpflg = 0;
@@ -421,7 +426,11 @@ gaint i;
     gcmn.mpthks[i] = 3;
   }
   gcmn.mpcols[0] = -1;  gcmn.mpcols[1] = -1; gcmn.mpcols[2] = -1;
-  gcmn.mpdset[0] = (char *)galloc(7,"mpdset0");
+  for (i=0; i<8; i++) {
+    if (gcmn.mpdset[i]) gree(gcmn.mpdset[i],"g1");
+    gcmn.mpdset[i] = NULL;
+  }
+  gcmn.mpdset[0] = (char *)galloc(7,"mpdset");
   *(gcmn.mpdset[0]+0) = 'l'; 
   *(gcmn.mpdset[0]+1) = 'o';
   *(gcmn.mpdset[0]+2) = 'w'; 
@@ -438,7 +447,7 @@ gaint i;
   gcmn.strhsz = 0.1;
   gcmn.strvsz = 0.12;
   gcmn.anncol = 1;
-  gcmn.annthk = 6;
+  gcmn.annthk = 5;
   gcmn.tlsupp = 0;
   gcmn.xlcol = 1;
   gcmn.ylcol = 1;
@@ -536,7 +545,8 @@ gaint i;
   gcmn.cachesf = 1.0; 
   gcmn.dblen = 12;
   gcmn.dbprec = 6;
-
+  gcmn.loopflg = 0;
+  gcmn.aaflg = 1;
 
 }
 
diff --git a/src/grads.h b/src/grads.h
index 13ed035..5236e33 100644
--- a/src/grads.h
+++ b/src/grads.h
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 #include <stdio.h>
@@ -103,6 +102,7 @@ struct gacmn {
   gadouble *xabval;
   gadouble *yabval;
   struct gawgds *wgds;         /* Pointer to gds output structure       */
+  gaint aaflg;                 /* Hardware anti-aliasing flag           */
   gaint hbufsz;                /* Metafile buffer size                  */
   gaint g2bufsz;               /* Grib2 cache buffer size               */
   gaint pass;                  /* Number of passes since last clear     */
@@ -153,6 +153,7 @@ struct gacmn {
   gadouble rmin2,rmax2,rint2;  /* Axis limits for 1-D plots             */
   gaint aflag,aflag2;          /* Keep 1D axis limits fixed             */
   gaint grflag,grstyl,grcolr;  /* Grid flag, linestyle, color           */
+  gaint grthck;                /* Grid thickness                        */
   gaint dignum;                /* grid value plot control (gxout=grid)  */
   gadouble digsiz;
   gaint arrflg;                /* Use already set arrow scaling         */
@@ -210,8 +211,6 @@ struct gacmn {
   gadouble strrot;             /* Draw string rotation */
   gadouble strhsz,strvsz;      /* Draw string hor. size, vert. size     */
   gaint anncol,annthk;         /* Draw title color, thickness           */
-  gaint grflg;                 /* Grey Scale flag   */
-  gaint devbck;                /* Device background */
   gaint xlcol,xlthck,ylcol,ylthck,clcol,clthck;  /* color, thickness */
   gaint xlside,ylside,ylpflg;
   gadouble xlsiz,ylsiz,clsiz,xlpos,ylpos,yllow;         /* Axis lable size */
@@ -253,6 +252,7 @@ struct gacmn {
   gaint sdfprec;             /* precision (8==double, 4==float, etc.) */
   gaint sdfchunk;            /* flag to indicate whether or not to chunk */
   gaint sdfzip;              /* flag to indicate whether or not to compress */
+  gaint sdfrecdim;           /* flag to indicate record dimensions */
   gaint ncwid;               /* netcdf write file id  */
   gaint xchunk;              /* size of sdfoutput file chunk in X dimension */
   gaint ychunk;              /* size of sdfoutput file chunk in Y dimension */
@@ -696,6 +696,7 @@ struct gavar {
   gaint isu;                   /* Variable is the u-component of a vector pair */
   gaint isdvar;                /* Variable is a valid data variable (for SDF files) */
   gaint nvardims;              /* Number of variable dimensions        */
+  gaint nh5vardims;            /* Number of variable dimensions for hdf5 */
   gaint vardimids[100];        /* Variable dimension IDs. 	       */
 #if USEHDF5==1
   hid_t h5varflg;              /* hdf5 variable has been opened */
@@ -764,7 +765,13 @@ struct gaindxb {
 #if GRIB2
 /* Structures for GRIB2 data */
 struct gag2indx {
-  gaint version;                /* Version number: 1: gaint offsets  2: off_t offsets */
+  gaint version;                /* Version number: 
+				   1: gaint offsets  
+				   2: off_t offsets 
+				   3: new header elements, including off_t flag */
+  gaint bigflg;                 /* off_t offsets in use */
+  gaint trecs;                  /* Number of records (XY grids) per time step */
+  gaint tsz,esz;                /* Sizes of T and E dimensions */
   gaint g2intnum;               /* Number of index offset values */  
   gaint *g2intpnt;              /* Pointer to index g2ints */
   off_t *g2bigpnt;              /* Pointer to record offsets when off_t offsets in use */
@@ -881,7 +888,7 @@ gaint gahistory(char*, char *, struct gacmn *);
 gaint ncwrite (char *, struct gacmn *);
 gaint sdfwatt (struct gacmn*, gaint, char *, char *, char *);
 gaint sdfwdim (struct gafile *, struct gacmn *, gaint, gaint);
-gaint sdfdefdim (gaint, char *, gaint, gaint *, gaint *);
+gaint sdfdefdim (gaint, char *, gaint, gaint *, gaint *, gaint, gaint);
 
 gaint gaddes (char *, struct gafile *, gaint);
 gaint deflin (char *, struct gafile *, gaint, gaint);
diff --git a/src/grib2scan.c b/src/grib2scan.c
index 67ecbed..5f560d7 100644
--- a/src/grib2scan.c
+++ b/src/grib2scan.c
@@ -1,7 +1,7 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
-    See file COPYRIGHT for more information.
-    Written by Brian Doty and Jennifer M. Adams  */
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
+    See file COPYRIGHT for more information. */
+
+/*  Written by Brian Doty and Jennifer M. Adams  */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -392,12 +392,12 @@ gaint sect3 (unsigned char *s3, struct gag2 *pg2) {
 
 /* Look at contents of Section 4 */
 gaint sect4 (unsigned char *s4, struct gag2 *pg2) {
-  struct dt reft,fcst,begt,endt;
+  struct dt reft,fcst,endt;
   gaint enstotal,sp,sp2,gotfcst;
-  gaint ptyp,llsf,llval,ulsf,ulval,llval2,i;
+  gaint ptyp,llsf,llval,ulsf,ulval,i,pctle;
   gadouble ll=0,ul=0;
   gadouble lev1=0,lev2=0;
-  gaint var1,var2,var3,var4,var5,numtr,pos1,pos2;
+  gaint var1,var2,var3,var4,var5,numtr,pos1=0,pos2=0;
   gaint off,atyp,styp,s1sf,s1sval,s2sf,s2sval,wtyp,w1sf,w1sval,w2sf,w2sval;
   gadouble s1,s2,w1,w2;
   
@@ -405,8 +405,8 @@ gaint sect4 (unsigned char *s4, struct gag2 *pg2) {
   pg2->parcat   = gagby(s4, 9,1); 
   pg2->parnum   = gagby(s4,10,1); 
   /* PDT 48 has 24 unique octets inserted after octet 11 instead of starting at octet 35 */
+  off=0;
   if (pg2->pdt==48) off=24; 
-  else off=0;
   pg2->trui     = gagby(s4,17+off,1); 
   pg2->ftime    = gagby(s4,18+off,4); 
   pg2->lev1type = gagby(s4,22+off,1);
@@ -456,7 +456,8 @@ gaint sect4 (unsigned char *s4, struct gag2 *pg2) {
     }
     else if (pg2->pdt==15) {
       /* for PDT 4.15, get info about the type of spatial and statistical processing used */
-      /* pos2 is the location of octet for statistical process code (sp), subsequent octet is for spatial process */
+      /* pos2 is the location of octet for statistical process code (sp), 
+	 subsequent octet is for spatial process */
       pos2=34;
       sp  = gagby(s4,pos2+0,1);
       sp2 = gagby(s4,pos2+1,1);
@@ -485,27 +486,26 @@ gaint sect4 (unsigned char *s4, struct gag2 *pg2) {
     endt.hr = gagby(s4,pos1+4,1);
     endt.mn = gagby(s4,pos1+5,1);
 
-    /* get info about statistical processing */
-    sp   = gagby(s4,pos2+0,1);
-    var1 = gagby(s4,pos2+1,1);
-    var2 = gagby(s4,pos2+2,1);
-    var3 = gagby(s4,pos2+3,4);
-    var4 = gagby(s4,pos2+7,1);
-    var5 = gagby(s4,pos2+8,4);
-
-    /* get number of time specifications */
+    /* get number of time range specifications */
     numtr = gagby(s4,pos1+7,1);       
+
+    /* get info about outermost (or only) statistical process */
     if (numtr) {
-      if (var5==0) {   /* continuous statistical processing function */
-	printf("  %d ",var3);
-	CodeTable4p4(var2);
-	if (sp==255)
-	  printf("Interval");
-	else
-	  CodeTable4p10(sp);
-	printf("  BegTime = %4i-%02i-%02i %02i:%02i",fcst.yr,fcst.mo,fcst.dy,fcst.hr,fcst.mn);
-	printf("  EndTime = %4i-%02i-%02i %02i:%02i",endt.yr,endt.mo,endt.dy,endt.hr,endt.mn);
-      }
+      sp   = gagby(s4,pos2+0,1);  /* statistical process */
+      var1 = gagby(s4,pos2+1,1);  /* not used, type of time increment... */
+      var2 = gagby(s4,pos2+2,1);  /* time unit for var3 */
+      var3 = gagby(s4,pos2+3,4);  /* length of time over which statistical processing is done */
+      var4 = gagby(s4,pos2+7,1);  /* not used, time unit for var5 */
+      var5 = gagby(s4,pos2+8,4);  /* not used, time increment between successive fields, 0 if continuous */
+      printf("  %d ",var3);
+      CodeTable4p4(var2);
+      if (sp==255)
+        printf(" Interval");
+      else
+        CodeTable4p10(sp);
+      printf("  BegTime = %4i-%02i-%02i %02i:%02i",fcst.yr,fcst.mo,fcst.dy,fcst.hr,fcst.mn);
+      printf("  EndTime = %4i-%02i-%02i %02i:%02i",endt.yr,endt.mo,endt.dy,endt.hr,endt.mn);
+      if ((verb) & (numtr>1)) printf("\n   (Record has %d time range specifications for statistical processing)",numtr);
     }
   }
   printf(" \n");
@@ -555,8 +555,8 @@ gaint sect4 (unsigned char *s4, struct gag2 *pg2) {
     }
   }	
   else {    /* only one level type */
-    if (pg2->lev1 != -1) {
-      printf ("   Level: ltype,lval = %d,%g ",pg2->lev1type,lev1);
+    if (pg2->lev1 != -1 && pg2->lev1type>10) {     /* some level types don't have an associated level value */
+      printf ("   Level: ltype,lval = %d,%g ",pg2->lev1type,lev1); 
       if (ctl) sprintf (levs,"%d,%g",pg2->lev1type,lev1);
       if (verb) printf("  (sf,sval = %d %d)",pg2->lev1sf,pg2->lev1);
       printf ("\n");
@@ -633,6 +633,13 @@ gaint sect4 (unsigned char *s4, struct gag2 *pg2) {
     printf("\n");
   }
 
+  /* Percentile Forecasts */
+  if ((pg2->pdt==6) | (pg2->pdt==10)) {
+    pctle = gagby(s4,34,1);
+    printf ("   Percentile: %d\n",pctle);
+    if (ctl) sprintf (extra,"a%d",pctle);
+  }
+
   /* Optical Properties of Aerosols */
   if (pg2->pdt==48) {
     atyp   = gagby(s4,11,2);
diff --git a/src/gribmap.c b/src/gribmap.c
index a7d3ce1..e4b503d 100644
--- a/src/gribmap.c
+++ b/src/gribmap.c
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 #ifdef HAVE_CONFIG_H
@@ -38,17 +37,19 @@ gaint main (gaint argc, char *argv[]) {
   verb=0;         /* verbose default is NO */
   quiet=0;        /* quiet mode default is NO */
   bigflg=0;       /* assume small <2GB files sizes */
-  g1ver=3;        /* default version for grib1 maps */
-  g2ver=1;        /* default version for grib2 maps */
+  g1ver=5;        /* default version for grib1 maps */
+  g2ver=3;        /* default version for grib2 maps */
   scaneof=0;      /* option to ignore failure to find data at end of file */
   scanEOF=0;      /* option to ignore failure to find data at end of file */
   scanlim=1000;   /* the default # of max bytes between records */
   notau=0;        /* force time to be base time */
+  upgrade=0;      /* do not create a newer version of existing index file */
+  downgrade=0;    /* do not create a older version of existing index file */
   tauave=0;       /* use end time (default) for averaged products vs. start time */
   tauflg=0;       /* search for a fixed tau in filling the 4-D volume */
   tauoff=0;       /* the fixed tau in h */
   tau0=0;         /* set the base dtg for tau search */
-  update=0;       /* set the base dtg for tau search */
+  update=0;       /* write out a new index file */
   write_map=1;    /* write out the map  */
   diag=0;         /* full diagnostics */
   mpiflg=0;
@@ -73,22 +74,13 @@ gaint main (gaint argc, char *argv[]) {
         notau = 1;                            /* reference time is the valid time */ 
 	flg = 0;
       }
-      else if (*ch=='-' && *(ch+1)=='1') {    /* Create machine-specific version 1 map */
-        g1ver = 1;
-	flg = 0;
-      }
-      else if (*ch=='-' && *(ch+1)=='2') {    /* Create machine-independent version 2 map */
-        g1ver = 2;
-	flg = 0;
-      }
-      else if (*ch=='-' && *(ch+1)=='b' && *(ch+2)=='i' && *(ch+3)=='g') {    /* >2GB sizes */
+      else if (*ch=='-' && *(ch+1)=='b' && *(ch+2)=='i' && *(ch+3)=='g') {    /* >2GB file sizes */
         if (sizeof(off_t) != 8) {
-          printf ("Gribmap Error:  -big flag requires size of off_t to be 8.\n");
+          printf ("gribmap: ERROR! The \"-big\" flag requires size of off_t to be 8.\n");
           printf ("                The size of off_t is %ld\n",sizeof(off_t));
           return (4);
         }
-        bigflg=1;
-        g1ver=4;
+        bigflg = 1;
 	flg = 0;
       }
       else if (*ch=='-' && *(ch+1)=='b') {    /* Valid time for averages is beginning of period */
@@ -124,7 +116,7 @@ gaint main (gaint argc, char *argv[]) {
 	help=1;
 	flg = 0;
       }
-      else if (*ch=='-' && *(ch+1)=='h') {          /* Header bytes to skip before scanning */
+      else if (*ch=='-' && *(ch+1)=='h') {   /* Header bytes to skip before scanning */
         ch+=2;
 	i = 0;
 	while(*(ch+i) && i<900) {
@@ -140,10 +132,18 @@ gaint main (gaint argc, char *argv[]) {
         no_min = 1;
         flg = 0;
       }
-      else if (*ch=='-' && *(ch+1)=='m') {         /* Use base time from descriptor instead of grib header */
+      else if (*ch=='-' && *(ch+1)=='m') {    /* Use base time from descriptor instead of grib header */
         mpiflg = 1;
         flg = 0;
       }
+      else if (*ch=='-' && *(ch+1)=='n' && *(ch+2)=='e' && *(ch+3)=='w') { /* Newer version of index file */
+        upgrade = 1;
+        flg = 0;
+      }
+      else if (*ch=='-' && *(ch+1)=='o' && *(ch+2)=='l' && *(ch+3)=='d') { /* Older version of index file */
+        downgrade = 1;
+        flg = 0;
+      }
       else if (*ch=='-' && *(ch+1)=='N') {    /* Do not write a map file */
         write_map=0;
 	flg = 0;
@@ -171,8 +171,7 @@ gaint main (gaint argc, char *argv[]) {
         flg = 0;
       }
       else if (*ch=='-' && *(ch+1)=='u') {    /* Update existing map (for templated data sets) */
-	printf("The -u option has been temporarily disabled\n");
-	/* update = 1; */
+	update = 1;
 	flg = 0;
       }
       else if (*ch=='-' && *(ch+1)=='v') {    /* Verbose mode */
@@ -185,7 +184,7 @@ gaint main (gaint argc, char *argv[]) {
       iarg++;
     }
 
-  } 
+  }
   else {
     command_line_help();
   }
@@ -194,6 +193,16 @@ gaint main (gaint argc, char *argv[]) {
     command_line_help();
     return(0);
   }
+  /* check to make sure there are no conflicting options */
+  if (upgrade && downgrade) {
+    printf("gribmap: ERROR! You cannot use the \"-new\" and \"-old\" options together \n");
+    return(1);
+  }
+  if (bigflg && downgrade) {
+    printf("gribmap: ERROR! You cannot use the \"-big\" and \"-old\" options together \n");
+    return(1);
+  }
+
 
   mfcmn.cal365=-1; /* initialize the GrADS calendar so it is set to the file calendar in gaddes */
   rc=gribmap();
@@ -221,10 +230,12 @@ printf("   -i fname  provides the name of data descriptor file to map\n");
 printf("   -m        uses the initial time from the descriptor file instead of the base time in the grib header \n");
 printf("   -min0     ignores minutes code \n");
 printf("   -N        does NOT write out the map \n");
+printf("   -new      creates a newer version of an existing index file \n");
+printf("   -old      creates an older version of an existing index file \n");
 printf("   -q        quiet mode gives no listing except for errors\n");
 printf("   -sNNNN    where NNNN is the maximum # of bytes to skip between GRIB messages (default is 1000)\n");
 printf("   -t0       forces a match if base time in the GRIB header equals the initial time in the descriptor file\n");
-/* printf("   -u        updates existing gribmap (N.B. This option is temporarily disabled)\n"); */
+printf("   -u        updates existing gribmap (N.B. For extending T or E axis)\n");
 printf("   -v        verbose option shows details of the mapping\n");
 printf("\n");
 }
diff --git a/src/gribscan.c b/src/gribscan.c
index 96152db..9d86a50 100644
--- a/src/gribscan.c
+++ b/src/gribscan.c
@@ -1,3 +1,6 @@
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
+    See file COPYRIGHT for more information.   */
+
 #ifdef HAVE_CONFIG_H
 #include "config.h"
 
@@ -382,7 +385,7 @@ gaint main (gaint argc, char *argv[]) {
      printf ("->%c%c%c%c%c%c<-\n",*uch,*(uch+1),*(uch+2),*(uch+3),*(uch+4),*(uch+5));
      return (99);
    } else {
-     if (verb) printf("the header is %lld bytes long\n",fpos);
+     if (verb) printf("the header is %ld bytes long\n",fpos);
    }
 
  } else if (skip > -1) {
@@ -995,12 +998,12 @@ if(!silent) {
   if( bdsout && !silent ) {
     if ( !qout) {
       if( delim ) {
-	printf(",BDS,%d,%10g,%d,%lld,%d",ghdr->bnum,ghdr->ref,npts,cposis,ghdr->len);
+	printf(",BDS,%d,%10g,%d,%ld,%d",ghdr->bnum,ghdr->ref,npts,cposis,ghdr->len);
       } else {
-	printf(" BDS % 3d %10g % 10d % 10lld % 10d",ghdr->bnum,ghdr->ref,npts,cposis,ghdr->len);
+	printf(" BDS % 3d %10g % 10d % 10ld % 10d",ghdr->bnum,ghdr->ref,npts,cposis,ghdr->len);
       }
     } else {
-      printf(", B ,%2d,%g,%d,%lld,%d",ghdr->bnum,ghdr->ref,npts,cposis,ghdr->len);
+      printf(", B ,%2d,%g,%d,%ld,%d",ghdr->bnum,ghdr->ref,npts,cposis,ghdr->len);
     }
     printf("\n");
   } 
diff --git a/src/gs.h b/src/gs.h
index 553ff5e..e448cc1 100644
--- a/src/gs.h
+++ b/src/gs.h
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 #define RSIZ 3600  /* increased from 600 in version 1.9 */
diff --git a/src/gscrpt.c b/src/gscrpt.c
index 9a113c3..328c391 100644
--- a/src/gscrpt.c
+++ b/src/gscrpt.c
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 /* Authored by B. Doty */
diff --git a/src/gstmp.c b/src/gstmp.c
index 47b71c1..d6b67f3 100644
--- a/src/gstmp.c
+++ b/src/gstmp.c
@@ -1,3 +1,7 @@
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
+    See file COPYRIGHT for more information.   */
+
+/*  Code originally by M.Fiorino   */
 
 /* 
  * Include ./configure's header file
@@ -49,8 +53,7 @@ int rc;
              name provided does not start with a /, then 
              we try the directories in the GASCRP envvar, 
              both with the primary name and the .gs extension.
-
-     Code originally by M.Fiorino   */
+*/
 
 FILE *gsonam (struct gscmn *pcmn, struct gsfdef *pfdf) {
 FILE *ifile;
diff --git a/src/gx.h b/src/gx.h
index 9f0c2d1..929fe3f 100644
--- a/src/gx.h
+++ b/src/gx.h
@@ -1,11 +1,12 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 #include <stdlib.h>
 
 /* Installation options for the GX package. */
 
+#define COLORMAX 2048
+
 /* HBUFSZ is the size of the metafile output buffer in
    number of short integers.  The metafile buffer should be as
    large as is convenient for the target system.  Frames larger
@@ -162,6 +163,17 @@ struct gxcntr {
   gaint shpflg;                /* flag for shapfiles */
 };
 
+/* Structure to be used to query the backend db settings. */
+
+struct gxdbquery {
+  gadouble wid;
+  gaint red,green,blue,alpha,tile;
+  gaint ptype,pxs,pys,pthick,pfcol,pbcol;
+  gaint fbold,fitalic,fstatus;
+  char *fname;
+};
+
+
 /* Function prototypes for GX library routines  */
 
 /* Functions in gxdev:
@@ -180,7 +192,6 @@ struct gxcntr {
    gxdfil: Hardware Polygon fill
    gxdxsz: Resize X Window (X only)
    gxdbtn: Get pointer pos at mouse btn press
-   gxgrey: Set grey scale
    gxdbck: Set hardware background/foreground
    gxrswd: Reset Widget Structures
    gxrs1wd: Reset one widget
@@ -199,7 +210,7 @@ void gxdbat (void);
 void gxdend (void);
 void gxdfrm (int);
 void gxdcol (int);
-gaint gxdacl (int, int, int, int);
+gaint gxdbacol (int, int, int, int, int);
 void gxdwid (int);
 void gxdmov (gadouble, gadouble);
 void gxddrw (gadouble, gadouble);
@@ -209,7 +220,6 @@ void gxdbl (void);
 void gxdswp (void);
 void gxdfil (gadouble *, gaint);
 void gxdxsz (int, int);
-void gxgrey (int);
 void gxdbck (int);
 gaint gxdbkq (void);
 void gxdeve (int);
@@ -219,6 +229,7 @@ void gxdrmu (int, struct gdmu *, int, int);
 void gxdsfn (void);
 void gxdcf (void);
 void gxdrdw (void);
+void gxdopt (gaint);
 void gxrdrw (int);
 void gxrswd (int);
 void gxrs1wd (int, int);
@@ -243,6 +254,7 @@ void gxdgeo (char *);
 int gxheps(char*);
 void gxdimg(gaint *, gaint, gaint, gaint, gaint);
 void gxdgcoord(gadouble, gadouble, gaint *, gaint *);
+void gxdboutbck (gaint);
 
 /* Routines in gxsubs:
    gxstrt: Initialize graphics output
@@ -250,8 +262,6 @@ void gxdgcoord(gadouble, gadouble, gaint *, gaint *);
    gxfrme: Start new frame
    gxcolr: Set color attribute
    gxacol: Assign new rgb to color number from 16-99
-   gxbckg: Set background color
-   gxqbck: Query background color
    gxwide: Set line width attribute
    gxmove: Move to X, Y
    gxdraw: Draw solid line to X, Y using current color and linewidth
@@ -283,16 +293,14 @@ void gxdgcoord(gadouble, gadouble, gaint *, gaint *);
    gxgsym: Get env var
    gxgnam: Get full path name
    gxptrn: Set fill pattern
-                                                                */
+   gxqchl: Query the width of a character 
+*/
 
 void gxstrt (gadouble, gadouble, int, int);
 void gxend (void);
 void gxfrme (int);
-void gxsfrm (void);
 void gxcolr (int);
-gaint gxacol (int, int, int, int);
-void gxbckg (int);
-gaint gxqbck (void);
+gaint gxacol (int, int, int, int, int);
 void gxwide (int);
 void gxmove (gadouble, gadouble);
 void gxdraw (gadouble, gadouble);
@@ -303,7 +311,9 @@ void gxclip (gadouble, gadouble, gadouble, gadouble);
 void gxtitl (char *, gadouble, gadouble, gadouble, gadouble, gadouble);
 void gxvpag (gadouble, gadouble, gadouble, gadouble, gadouble, gadouble);
 void gxvcon (gadouble, gadouble, gadouble *, gadouble *);
+void gxvcon2 (gadouble, gadouble, gadouble *, gadouble *);
 void gxppvp (gadouble, gadouble, gadouble *, gadouble *);
+void gxppvp2 (gadouble, gadouble *);
 void gxscal (gadouble, gadouble, gadouble, gadouble, gadouble, gadouble, gadouble, gadouble);
 void gxproj ( void (*) (gadouble, gadouble, gadouble*, gadouble*) );
 void gxgrid ( void (*) (gadouble, gadouble, gadouble*, gadouble*) );
@@ -324,12 +334,16 @@ void bdterp (gadouble, gadouble, gadouble, gadouble, gadouble *, gadouble *);
 void gxptrn (int, int, int);
 char *gxgsym(char *);
 char *gxgnam(char *);
+gadouble gxdrawch (char, gaint, gadouble, gadouble, gadouble, gadouble, gadouble);
+gadouble gxqchl (char, gaint, gadouble);
+void gxsignal (gaint);
+
+
 
 /* Gxmeta routines handle graphics buffering and metafile output.
    Routines in gxmeta:
    gxhopt: Specify buffering option before open
    gxhnew: Buffering initialization on startup
-   gxhbgn: Enable hardcopy (metafile) output
    hout0:  Buffer 0 arg metafile command
    hout1:  Buffer one arg metafile command
    hout2:  Buffer two arg metafile command
@@ -338,30 +352,43 @@ char *gxgnam(char *);
    hout3i: Buffer three arg int metafile command
    hout4i: Buffer four arg int metafile command
    hfull:  Deal with full metafile memory buffer
-   gxhprt: Handle print command (output to metafile)
    gxhwri: Write buffer to metafile
-   gxhend: Close output metafile
    gxhfrm: Handle new frame action
    gxhdrw: Handle redraw operation
                                            */
 
 void gxhopt (int);
 void gxhnew (gadouble, gadouble, int);
-gaint gxhbgn (char *);
 void hout0 (int);
 void hout1 (int, int);
 void hout2 (int, gadouble, gadouble);
 void hout4 (int, gadouble, gadouble, gadouble, gadouble);
 void hout2i (int, int, int);
 void hout3i (int, int, int, int);
-void hout4i (int, int, int, int, int);
+void hout5i (int, int, int, int, int, int);
 void hfull (void);
-void gxhprt (char *);
 gaint gxhwri (void *, int);
-void gxhend (void);
 void gxhfrm (int);
-void gxhdrw (int);
+void gxhdrw (gaint,gaint);
 void gxddbl (void);
+gaint mbufget (void);
+void mbufrel (gaint);
+void gxmbuferr(void);
+void houtch (char, gaint, gadouble, gadouble, gadouble, gadouble, gadouble);
+void hout1c (gaint , gaint);
+void gxdbinit (void);
+void gxdbqfont (gaint, struct gxdbquery *);
+void gxdbqcol (gaint, struct gxdbquery *);
+void gxdbqwid (gaint, struct gxdbquery *);
+void gxdbsetwid (gaint, gadouble);
+gaint gxdbqhersh (void);
+void gxdbsethersh (gaint);
+void gxdbsetfn (gaint, char *);
+void gxdbsetfnstatus (gaint, gaint);
+void gxdbsetpatt (gaint *, char *);
+void gxdbqpatt (gaint, struct gxdbquery *);
+void gxdbsettransclr (gaint);
+gaint gxdbqtransclr (void);
 
 /* Routines in gxchpl:
    gxchii: Initialize character plotting
@@ -487,3 +514,35 @@ void gxlamcp (gadouble, gadouble, gadouble *, gadouble *);
 void gxlamcb (gadouble, gadouble, gadouble *, gadouble *);
 gadouble *gxmpoly(gadouble *xy, gaint cnt, gadouble llinc, gaint *newcnt); 
 void gree();
+
+
+/* routines in gxX.c */
+gadouble gxdch (char, gaint, gadouble, gadouble, gadouble, gadouble, gadouble);
+gadouble gxdqchl (char, gaint, gadouble);
+void gxdopt(gaint);
+void gxinitimg (gaint, gaint);
+void gxendimg (char *);
+void gxdsignal (gaint);
+void gxsetpatt (gaint);
+void gxdXflush (void);
+void gxdclip (gadouble, gadouble, gadouble, gadouble);
+gaint gxdacol (gaint, gaint, gaint, gaint, gaint);
+
+/* routines in gxprint.c */
+void gxpbgn (gadouble, gadouble);
+void gxpinit (gadouble , gadouble);
+void gxpend (void);
+gaint gxprint (char *, gaint, gaint, gaint, gaint, char *, char *, gaint, gadouble);
+void gxpcol (gaint);
+void gxpacol (gaint);
+void gxpwid (gaint);
+void gxprec (gadouble, gadouble, gadouble, gadouble);
+void gxpbpoly (void);
+gaint gxpepoly (gadouble *, gaint);
+void gxpmov (gadouble, gadouble);
+void gxpdrw (gadouble, gadouble);
+void gxpflush (void);
+void gxpsignal (gaint);
+void gxpclip (gadouble, gadouble, gadouble, gadouble);
+gadouble gxpch (char, gaint , gadouble, gadouble, gadouble, gadouble, gadouble);
+gadouble gxpqchl (char, gaint , gadouble);
diff --git a/src/gxC.c b/src/gxC.c
new file mode 100644
index 0000000..dcea093
--- /dev/null
+++ b/src/gxC.c
@@ -0,0 +1,1135 @@
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
+    See file COPYRIGHT for more information.   */
+
+/* This file contains the primary Cairo-GrADS interface. 
+   The interactive interface (X windows) is managed by routines in gxX.c and the routines here.  
+   Hardcopy output is generated here, but managed in gxprint.c  */
+
+
+/* Include ./configure's header file */
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <math.h>
+
+#include <cairo-ps.h>
+#include <cairo-svg.h>
+#include <cairo-pdf.h>
+#include <cairo-ft.h>
+#include <cairo-xlib.h>
+#include <fontconfig.h> 
+#include <ft2build.h>
+#include FT_FREETYPE_H
+
+#include "gatypes.h"
+#include "gx.h"
+#include "gxC.h"
+
+#define SX 800                              /* default X dimension of the image output */
+
+
+/* local variables */
+static gaint lcolor=-999,lwidth;            /* Current attributes */
+static gaint actualcolor;                   /* current *actual* color */
+static gaint lcolorsave,lwidthsave;         /* for save and restore */
+static gaint rsav,gsav,bsav,psav;           /* Avoid excess color change calls */ 
+static gaint aaflg=0;                       /* Anti-Aliasing flag */
+static gaint filflg=0;                      /* Polygon-Filling flag */
+static gaint brdrflg=0;                     /* Vector graphic border flag */
+static gadouble brdrwid=0.0;                /* Vector graphic border size */
+static gaint rotate=0;                      /* rotate landscape plots for hardcopy output */
+static gaint width, height;                 /* Drawable size */
+static gaint Xwidth, Xheight;               /* Window size */
+static gaint Bwidth, Bheight;               /* Batch surface size */
+static gaint force=0;                       /* force a color change */
+static gadouble xsize, ysize;               /* GrADS page size (inches) */
+static gadouble xscl,yscl;                  /* Window Scaling */
+static gadouble xxx,yyy;                    /* Old position */
+static FT_Library library=NULL;             /* for drawing fonts with FreeType with cairo */
+static FT_Face face[100];                   /* for saving FreeType font faces */ 
+static gaint faceinit=0;                    /* for knowing whether font faces have been initialized */
+static cairo_surface_t *surface=NULL;       /* Surface being drawn to */   
+static cairo_t *cr;                         /* graphics context */
+static gaint surftype;                      /* Type of current surface.
+                                               1=X, 2=Image, 3=PS/EPS, 4=PDF, 5=SVG */
+static cairo_surface_t *Xsurface=NULL, *Hsurface=NULL, *Bsurface=NULL;
+                                            /* X, Hardcopy, and Batch mode surfaces */
+                                            /* X surface is passed to us by gxX. */
+                                            /* Others are created as needed. */
+static cairo_t *Xcr, *Hcr, *Bcr;            /* X, Hardcopy, and Batch mode contexts */  
+static cairo_pattern_t *pattern[2048];      /* Save our patterns here */
+static cairo_surface_t *pattsurf[2048];
+static cairo_surface_t *surfmask, *surfsave;  /* Stuff for masking */
+static cairo_t *crmask, *crsave;
+static cairo_pattern_t *patternmask;
+static gaint drawing;                         /* In the middle of line-to's? */
+static gaint maskflag;                        /* Masking going on */
+static gaint batch=0;                         /* Batch mode */
+static gadouble clx,cly,clw,clh;              /* current clipping coordinates */
+static gadouble clxsav,clysav,clwsav,clhsav;  /* saved clipping coordinates */
+
+/* Initialize X interface, allocate cr */
+/* If in batch mode, we don't get here */
+
+void gxCbgn (cairo_surface_t *Xsfc, gadouble xsz, gadouble ysz, gaint dw, gaint dh) {
+gaint i;
+
+  batch = 0;
+  for (i=0; i<2048; i++) pattern[i] = NULL;
+  for (i=0; i<2048; i++) pattsurf[i] = NULL;
+  if (!faceinit) {
+    for (i=0; i<100; i++) face[i] = NULL; 
+    faceinit=1;
+  }
+
+  drawing = 0;
+  maskflag = 0;
+
+  /* window dimensions */
+  width = dw;   
+  height = dh;  
+  Xwidth = dw; 
+  Xheight = dh;
+
+  /* set page sizes  in inches */
+  xsize = xsz; 
+  ysize = ysz;
+
+  /* initialize clipping parameters */
+  clx = 0;     
+  cly = 0;
+  clw = width;
+  clh = height;
+
+  /* scale factors */
+  xscl = (gadouble)(dw)/xsz;
+  yscl = (gadouble)(dh)/ysz;
+
+
+  /* make the X surface active for drawing */
+  surface = Xsfc;
+  surftype = 1;
+  Xsurface = surface;
+  cr = cairo_create(surface);
+  Xcr = cr;
+    
+  /* default drawing settings */
+  cairo_set_line_cap(cr,CAIRO_LINE_CAP_ROUND);
+  cairo_set_line_join(cr,CAIRO_LINE_JOIN_ROUND);
+  gxCaa(1);                   /* initialize anti-aliasing to be ON */ 
+  gxCcol(1);                  /* initial color is foreground */
+}
+
+/* Close down and clean up */
+
+void gxCend (void) {
+  if (batch) {
+    /* batch mode */
+    cairo_destroy(Bcr);
+    cairo_surface_finish(Bsurface);
+    cairo_surface_destroy(Bsurface);
+    Bcr = NULL;
+    Bsurface = NULL;
+  }
+  else {
+    /* the interactive session */
+    gxCflush(0);
+    cairo_destroy(cr);
+    cr = NULL;
+  }
+  /* close the FreeType library */
+  gxCftend();     
+}
+
+
+/* Initialize an image surface for batch mode, created on startup.
+   This will be used to get the lengths of strings. 
+   Called by the printing layer.
+   If in interactive mode, we don't get here. */
+
+void gxCbatch (gadouble xsz, gadouble ysz) {
+gaint dh,dw;               /* image size in pixels */
+gaint i;
+
+  batch=1;
+  if (!faceinit) {
+    for (i=0; i<100; i++) face[i] = NULL; 
+    faceinit=1;
+  }
+
+  /* set page sizes  in inches */
+  xsize = xsz; 
+  ysize = ysz;
+
+  /* set window dimensions; 100 times the page size or 1100 by 850 */
+  if (xsize > ysize) { 
+    dw = 1100;
+    dh = 850;
+  } 
+  else {
+    dw = 850;
+    dh = 1100;
+  }
+  width = dw;
+  height = dh; 
+  Bwidth = dw; 
+  Bheight = dh;
+
+  /* scale factors (pixels per inch) */
+  xscl = (gadouble)(dw)/xsize;
+  yscl = (gadouble)(dh)/ysize;
+
+  /* initialize clipping parameters */
+  clx = 0;     
+  cly = 0;
+  clw = width;
+  clh = height;
+
+  /* create the image surface */
+  surface = cairo_image_surface_create (CAIRO_FORMAT_ARGB32, dw, dh);
+  surftype = 2;
+  cr = cairo_create (surface);
+
+  Bsurface = surface;
+  Bcr = cr;
+}
+
+
+/* Initialize a hardcopy surface and make it the active surface for drawing. 
+   Save settings for the interactive surface so they can be restored when we are done.  
+   fmtflg == 1  for eps
+   fmtflg == 2  for ps
+   fmtflg == 3  for pdf
+   fmtflg == 4  for svg
+   fmtflg == 5  for png
+
+   For vector graphic outputs, we need the output file name at initialization.
+   For image output, we need the output file name at the end.
+
+   We typically dump a single image to a file, and then close it. 
+   Page breaks are not (yet?) in the new metabuffer structure
+   Cairo docs: "An Encapsulated PostScript file should never contain more than one page"
+
+*/
+
+gaint gxChinit (gadouble xsz, gadouble ysz, gaint xin, gaint yin, gaint bwin, 
+		char *fname, gaint fmtflg, char *bgImage, gadouble border) {
+gaint status;
+gaint dh=0,dw=0;          /* image size in pixels */
+gadouble psx=0,psy=0;     /* page size in points */
+gaint bcol;
+gaint bgwidth,bgheight,len;
+
+  gxCflush (1);
+  drawing = 0;
+  maskflag = 0;
+
+  /* save these settings to restore when hardcopy drawing is finished */
+  lcolorsave = lcolor; 
+  lwidthsave = lwidth;
+  clxsav = clx; 
+  clysav = cly;
+  clwsav = clw;
+  clhsav = clh;
+
+  /* set page sizes in inches */
+  xsize = xsz;
+  ysize = ysz;
+
+  if (fmtflg==5) {  /* Image output */
+    /*  Set the image width and height */
+    if (xin<0 || yin<0) {     /* user has not specified image size */
+      if (xsize > ysize) {    /* landscape */
+	dw = SX; 
+	dh = (gaint)((ysize/xsize)*SX);
+      }
+      else {
+	dw = (gaint)((xsize/ysize)*SX); 
+	dh = SX;
+      }
+    } 
+    else {
+      dw = xin; 
+      dh = yin;
+    }
+    /* image dimensions */
+    width = dw; 
+    height = dh;
+    /* scale factors (pixels per inch) */
+    xscl = (gadouble)(dw)/xsize;
+    yscl = (gadouble)(dh)/ysize;
+  }
+
+  if (fmtflg==1 || fmtflg==2 || fmtflg==3 || fmtflg==4) {  /* vector graphic output */
+    /* set page size in points */
+    if (ysize > xsize) {      
+      /* portrait: no rotation needed for any format */
+      psx = xsize * 72.0;
+      psy = ysize * 72.0;
+    }
+    else {
+      /* landscape: ps, eps, and pdf must be rotated to fit on page */
+      if (fmtflg==1 || fmtflg==2 || fmtflg==3) {
+	rotate = 1;         
+	psx = ysize * 72.0;
+	psy = xsize * 72.0;
+      }
+      else {
+	/* landscape: svg doesn't need to be rotated */
+	psx = xsize * 72.0;
+	psy = ysize * 72.0;
+      }
+    }
+    /* page dimensions */
+    width = (gaint)psx;
+    height = (gaint)psy;
+    /* scale factors (points per inch) */
+    xscl = 72.0;
+    yscl = 72.0;
+    /* set a border for ps, eps, and pdf formats */
+    if (fmtflg<=3) {
+      brdrwid = border * xscl;
+      brdrflg = 1; 
+    }
+  }
+
+  /* initialize clipping parameters */
+  clx = 0;     
+  cly = 0;
+  clw = width;
+  clh = height;
+
+  /* Create the hardcopy surface */
+  if (fmtflg==1 || fmtflg==2) {            /* PS or EPS */
+    surftype = 3;
+    surface = cairo_ps_surface_create (fname,psx,psy);
+    if (fmtflg==1) cairo_ps_surface_set_eps(surface,1);
+  }
+  else if (fmtflg==3) {                    /* PDF */
+    surftype = 4;
+    surface = cairo_pdf_surface_create(fname,psx,psy);
+  }
+  else if (fmtflg==4) {                    /* SVG */
+    surftype = 5;
+    surface = cairo_svg_surface_create(fname,psx,psy);
+  }
+  else if (fmtflg==5) {                    /* PNG */
+    surftype = 2;
+
+    if (*bgImage) {
+      /* Make sure bgImage is a .png  */
+      len = 0;
+      while (*(bgImage+len)) len++;
+      len = len-4;
+      if (len>0) {
+	if (*(bgImage+len+1)!='p' || *(bgImage+len+2)!='n' || *(bgImage+len+3)!='g' ) {
+	  if (*(bgImage+len+1)!='P' || *(bgImage+len+2)!='N' || *(bgImage+len+3)!='G' ) {
+	    return(5);
+	  }
+	}
+      }
+      /* create a new surface from the background image */
+      surface = cairo_image_surface_create_from_png (bgImage);
+      status = cairo_surface_status (surface);
+      if (status) {
+	printf("Error in gxChinit: unable to import background image %s\n",bgImage); 
+        printf("Cairo status: %s\n",cairo_status_to_string(status));
+	cairo_surface_finish(surface);
+	cairo_surface_destroy(surface);
+	return(7); 
+      }
+      /* make sure background image size matches output image size */
+      bgwidth = cairo_image_surface_get_width (surface);
+      bgheight = cairo_image_surface_get_height (surface);
+      if (bgwidth != width || bgheight != height) {
+	printf(" background image size is %d x %d \n",bgwidth,bgheight);
+	printf("     output image size is %d x %d \n",width,height);
+	cairo_surface_finish(surface);
+	cairo_surface_destroy(surface);
+	return(10);
+      }
+    }
+    else {
+      /* no background image specified by user */
+      surface = cairo_image_surface_create (CAIRO_FORMAT_ARGB32, dw, dh);
+    }
+  }
+
+  /* Make sure surface set up without any problems */
+  status = cairo_surface_status (surface);
+  if (status) {
+    printf("Error in gxChinit: failed to initialize hardcopy surface \n");
+    printf("Cairo status: %s\n",cairo_status_to_string(status));
+    cairo_surface_finish(surface);
+    cairo_surface_destroy(surface);
+    return(1);
+  }
+ 
+  /* Set the Cairo context */
+  cr = cairo_create (surface);
+  Hsurface = surface; 
+  Hcr = cr;
+
+  /* default drawing settings */
+  cairo_set_line_cap(cr,CAIRO_LINE_CAP_ROUND);
+  cairo_set_line_join(cr,CAIRO_LINE_JOIN_ROUND);
+  gxCaa(1);                   /* initialize anti-aliasing to be ON */ 
+
+  force = 1;             /* force a color change */
+  bcol = gxdbkq();
+  if (bcol>1) {
+    /* User has set the background to be a color other than black/white.
+       The background rectangle is therefore in the metabuffer and will
+       cover whatever we draw here to initalize the output */
+    if (bwin>-900) {
+      printf("Warning: Background color cannot be changed at print time    \n");
+      printf(" if it has been set to a color other than black or white. \n");
+      printf(" The current background color is %d. \n",bcol);
+      if (bwin==1) 
+      printf(" The option \"white\" will be ignored. \n");
+      else
+      printf(" The option \"black\" will be ignored. \n");
+    }
+  }
+  else {
+    if (bwin>-900) 
+      gxdboutbck(bwin);  /* change the background color if user provided an override */
+    gxCcol(0);           /* 0 here means 'background' */
+    cairo_paint(cr);     /* paint it */
+  }
+
+  gxCcol(1);             /* set the initial color to 'foreground' */
+  force = 0;             /* back to unforced color changes */
+  return (0);
+}
+
+
+/* End the hardcopy drawing and reset drawing to the interactive/batch surface */
+
+gaint gxChend (char *fname, gaint fmtflg, char *fgImage) {
+gaint fgwidth,fgheight,len,status;
+cairo_surface_t *sfc2=NULL;     /* Surface for fgImage */   
+
+  gxCflush(1);         /* finish drawing */
+  
+  /* bgImage and fgImage only work when output format is PNG */
+  if (fmtflg==5) {              
+    if (*fgImage) {
+      /* Make sure fgImage is a .png  */
+      len = 0;
+      while (*(fgImage+len)) len++;
+      len = len-4;
+      if (len>0) {
+	if (*(fgImage+len+1)!='p' || *(fgImage+len+2)!='n' || *(fgImage+len+3)!='g' ) {
+	  if (*(fgImage+len+1)!='P' || *(fgImage+len+2)!='N' || *(fgImage+len+3)!='G' ) {
+	    return(6);
+	  }
+	}
+      }
+      /* create a new surface from the foreground image */
+      sfc2 = cairo_image_surface_create_from_png (fgImage);
+      status = cairo_surface_status (sfc2);
+      if (status) {
+	printf("Error in gxChend: unable to import foreground image %s\n",fgImage);
+	printf("Cairo status: %s\n",cairo_status_to_string(status));
+	cairo_surface_finish(sfc2);
+	cairo_surface_destroy(sfc2); 
+	return(8); 
+      }
+      /* check to make sure foreground and output images are the same size */
+      fgwidth = cairo_image_surface_get_width (sfc2);
+      fgheight = cairo_image_surface_get_height (sfc2);
+      if (fgwidth != width || fgheight != height) {
+	printf(" foreground image size is %d x %d \n",fgwidth,fgheight);
+	printf("     output image size is %d x %d \n",width,height);
+	cairo_surface_finish(sfc2);
+	cairo_surface_destroy(sfc2);
+	return(11);
+      }
+      /* draw the foreground image OVER the hardcopy surface */
+      cairo_set_operator(cr, CAIRO_OPERATOR_OVER);
+      cairo_set_source_surface(cr, sfc2, 0, 0);
+      cairo_paint(cr);
+      /* clean up */
+      cairo_surface_finish(sfc2);
+      cairo_surface_destroy(sfc2);
+    }
+  }
+
+  /* Make sure surface was rendered without any problems */
+  status = cairo_surface_status (surface);
+  if (status) {
+    printf("Error in gxChend: an error occured during rendering of hardcopy surface \n");
+    printf("Cairo status: %s\n",cairo_status_to_string(status));
+    cairo_surface_finish(surface);
+    cairo_surface_destroy(surface);
+    return(1);
+  }
+
+  /* dump everything to hardcopy output, finish and destroy the surface */
+  cairo_surface_show_page (surface);
+  if (fmtflg==5) {
+    cairo_surface_write_to_png (surface, fname);  /* for image (png) output only */
+  }
+  cairo_destroy(cr);
+  cairo_surface_finish(surface);
+  cairo_surface_destroy(surface);
+  rotate=0;             /* unset rotation for landscape hardcopy */
+  brdrflg=0;            /* reset border flag for vector graphic output */
+  brdrwid=0.0;          /* reset border width for vector graphic output */
+  gxdboutbck(-1);       /* unset output background color */
+
+  /* Reset everything back to the interactive/batch surface for drawing */
+  Hsurface=NULL;
+  if (batch) {
+    surface = Bsurface;
+    cr = Bcr;
+    width  = Bwidth; 
+    height = Bheight;
+  }
+  else {
+    surface = Xsurface;
+    cr = Xcr;
+    width  = Xwidth; 
+    height = Xheight;
+  }
+  lcolor = lcolorsave; 
+  lwidth = lwidthsave; 
+  clx = clxsav; 
+  cly = clysav;
+  clw = clwsav;
+  clh = clhsav;
+  xscl = (gadouble)(width)/xsize;
+  yscl = (gadouble)(height)/ysize;
+
+  return (0);
+}
+
+
+/* Make this X surface active for drawing */
+
+void gxCsfc (cairo_surface_t *Xsfc) {
+  surface = Xsfc;
+  surftype = 1;
+  Xsurface = surface;
+  cr = cairo_create(surface);
+  Xcr = cr;
+}
+
+/* Swap action for double buffering */
+
+void gxCswp (cairo_surface_t *Xsfc, cairo_surface_t *Xsfc2) {
+  /* draw the background (sfc2) onto the foreground (sfc) */
+  cr = cairo_create(Xsfc);
+  cairo_set_source_surface(cr, Xsfc2, 0, 0);
+  cairo_paint(cr);
+  /* reset the cairo context to the background surface,  */
+  cr = cairo_create(Xsfc2);
+}
+
+/* Frame action.  Clear the frame. */ 
+
+void gxCfrm (void) {
+gaint bcolr,savcol;
+
+  gxCflush(0);
+  savcol = lcolor;    /* Ccol will change lcolor value */
+  bcolr = gxdbkq();   /* get background color from data base */
+  force = 1;          /* force the color change */
+  if (bcolr>1) 
+    gxCcol(bcolr);    /* the background color is neither black nor white */
+  else {
+    gxCcol(0);        /* 0 here means 'background' */
+  }
+  cairo_paint(cr);    /* paint the source */
+  gxCcol(savcol);     /* restore the current color */
+  force = 0;          /* back to unforced color changes */
+}
+
+/* Our interactive surface got resized. */
+
+void gxCrsiz (gaint dw, gaint dh) {
+  width = dw;  
+  height = dh; 
+  Xwidth = width; 
+  Xheight = height;
+  xscl = (gadouble)(dw)/xsize;
+  yscl = (gadouble)(dh)/ysize;
+  gxCfrm();
+}
+
+/*  Finish up any pending actions, like drawing, or masking */
+/*  opt=0 discard everything. opt=1 finish rendering. */
+
+void gxCflush (gaint opt) {
+  if (drawing) cairo_stroke(cr);
+  drawing = 0;
+  if (maskflag) {
+    cr = crsave;  
+    surface = surfsave;
+    if (opt) {
+      cairo_surface_show_page(surfmask);
+      patternmask = cairo_pattern_create_for_surface(surfmask);
+      cairo_set_source_rgba(cr, (double)(rsav)/255.0, (double)(gsav)/255.0, 
+			    (double)(bsav)/255.0, (double)(-1*psav)/255.0);
+      cairo_mask(cr, patternmask);
+    }
+    cairo_destroy(crmask);
+    cairo_surface_finish (surfmask);
+    cairo_surface_destroy (surfmask);
+    maskflag = 0;
+  }
+  if (surftype==1 && opt) gxdXflush();  /* force completed graphics to display */
+}
+
+/* New color value */
+
+void gxCcol (gaint clr) {
+struct gxdbquery dbq;
+gaint bcol;
+
+  if (drawing) cairo_stroke(cr);
+  drawing = 0;
+  lcolor = clr;                  /* outside this routine lcolor 0/1 still means background/foreground */
+  bcol = gxdbkq();               /* get background color */
+  if (bcol==1) {                 /* if background is white ...  */
+    if (clr==0)      clr = 1;    /*  ...change color 0 to white (1) */
+    else if (clr==1) clr = 0;    /*  ...change color 1 to black (0) */
+  }
+  gxdbqcol(clr, &dbq);           /* query the data base for color values */
+  if (clr == gxdbqtransclr()) {  /* If this is the transparent color, override values  */
+    dbq.red   = 0;
+    dbq.green = 0;
+    dbq.blue  = 0;
+    dbq.alpha = 0;
+    dbq.tile  = -999;
+  }
+  if (force || clr!=actualcolor || dbq.red!=rsav || dbq.green!=gsav || dbq.blue!=bsav || dbq.alpha!=psav) {
+    /* change to new color */
+    if (maskflag) gxCflush(1);
+    actualcolor = clr;           /* inside this routine actualcolor 0/1 means black or white */
+    if (dbq.tile > -900) {
+      /* new color is a pattern */
+      if (pattern[dbq.tile]==NULL)  gxCpattc (dbq.tile);
+      cairo_set_source(cr, pattern[dbq.tile]);
+      cairo_pattern_set_extend(cairo_get_source(cr), CAIRO_EXTEND_REPEAT);
+    } 
+    else {
+      if (dbq.alpha==255) {
+        cairo_set_source_rgb(cr, (double)(dbq.red)/255.0, (double)(dbq.green)/255.0, (double)(dbq.blue)/255.0);
+      } 
+      else {
+	/* set up color masking if alpha value is negative */
+        if (dbq.alpha < 0) {
+          maskflag = 1;
+          surfmask = cairo_image_surface_create (CAIRO_FORMAT_ARGB32, width , height);
+          crmask = cairo_create(surfmask);                    /* create a new graphics context */
+          cairo_set_source_rgba(crmask, 1.0, 1.0, 1.0, 1.0);  /* set mask color */  
+	  gxdbqwid(lwidth-1,&dbq);                            /* set current line width */
+	  cairo_set_line_width(crmask,dbq.wid);  
+	  cairo_set_line_cap(crmask,CAIRO_LINE_CAP_ROUND);    /* set line drawing specs */
+	  cairo_set_line_join(crmask,CAIRO_LINE_JOIN_ROUND);
+	  /* save the current surface/cr, set the new surfmask/crmask to be the current one */
+          crsave = cr;
+          surfsave = surface;
+          cr = crmask;
+          surface = surfmask;
+        }
+	else {
+          cairo_set_source_rgba(cr, (double)(dbq.red)/255.0, (double)(dbq.green)/255.0,
+			 	    (double)(dbq.blue)/255.0, (double)(dbq.alpha)/255.0);
+        }
+      }
+    }
+    /* save these color values */
+    rsav = dbq.red; 
+    gsav = dbq.green; 
+    bsav = dbq.blue; 
+    psav = dbq.alpha; 
+  }
+}
+
+/* Set the line width */
+
+void gxCwid (gaint wid) {                 
+struct gxdbquery dbq;
+  if (drawing) cairo_stroke(cr);
+  drawing = 0;
+  lwidth = wid;
+  gxdbqwid(wid-1,&dbq);  /* at this point wid still starts at 1, so subtract to get index right */
+  cairo_set_line_width(cr,dbq.wid);  
+}
+
+
+/* Convert x,y coordinates from inches on the page into coordinates for current drawing surface */
+
+void gxCxycnv (gadouble x, gadouble y, gadouble *nx, gadouble *ny) {
+  if (surftype>2 && rotate) {
+    *ny = (gadouble)height - x*xscl;
+    *nx = (gadouble)width - (y*yscl);
+  }
+  else {
+    *nx = x*xscl;
+    *ny = (gadouble)height - (y*yscl);
+  }
+  if (brdrflg) {
+    *nx = brdrwid + *nx*(((gadouble)width -brdrwid*2.0)/(gadouble)width);
+    *ny = brdrwid + *ny*(((gadouble)height-brdrwid*2.0)/(gadouble)height);
+  }
+}
+
+
+/* Move to x,y */
+
+void gxCmov (gadouble x, gadouble y) {
+  if (drawing) cairo_stroke(cr);
+  drawing = 0;
+  gxCxycnv (x,y,&xxx,&yyy);
+}
+
+
+/* Draw to x,y */
+
+void gxCdrw (gadouble x, gadouble y) {
+gadouble di, dj;
+  gxCxycnv (x,y,&di,&dj);
+  if (!filflg) {           /* we're not filling a polygon */
+    if (!drawing) {        /* this is the start of a line */
+      drawing = 1;
+      cairo_move_to(cr,xxx,yyy);
+      cairo_line_to(cr,di,dj);
+    }
+    else {
+      cairo_line_to(cr,di,dj);
+    }
+  }
+  xxx = di;
+  yyy = dj;
+}
+
+
+/* Set the clipping coordinates */
+
+void gxCclip (gadouble x1, gadouble x2, gadouble y1, gadouble y2) {
+gadouble di1,di2,dj1,dj2;
+  gxCxycnv (x1,y1,&di1,&dj1);
+  gxCxycnv (x2,y2,&di2,&dj2);
+  /* set the clipping variables -- these get used when drawing characters */
+  clx = di1;
+  cly = dj2;
+  clw = di2-di1;
+  clh = dj1-dj2;
+}
+
+
+/* Draw a filled rectangle */
+
+void gxCrec (gadouble x1, gadouble x2, gadouble y1, gadouble y2) {
+gadouble di1,di2,dj1,dj2;
+  if (drawing) cairo_stroke(cr);
+  drawing = 0;
+  gxCxycnv (x1,y1,&di1,&dj1);
+  gxCxycnv (x2,y2,&di2,&dj2);
+  if (di1!=di2 && dj1!=dj2) { 
+    cairo_rectangle(cr,di1,dj2,di2-di1,dj1-dj2);  
+    /* disable antialiasing, otherwise faint lines appear around the edges */
+    if (aaflg) {
+      cairo_set_antialias(cr,CAIRO_ANTIALIAS_NONE); 
+      cairo_fill(cr);
+      cairo_set_antialias(cr,CAIRO_ANTIALIAS_DEFAULT); 
+    }
+    else {
+      cairo_fill(cr);
+    }
+  } else {
+    cairo_move_to(cr,di1,dj1);
+    cairo_line_to(cr,di2,dj2);
+    cairo_stroke(cr);
+  }
+}
+
+
+/* initialize a polygon fill by turning on a flag */
+
+void gxCbfil (void) {
+  filflg = 1;
+}
+
+/* Draw a filled polygon */
+
+void gxCfil (gadouble *xy, gaint n) {
+gadouble *pt,x,y;
+gaint i;
+
+  if (drawing) cairo_stroke(cr);
+  drawing = 0;
+  pt = xy;
+  for (i=0; i<n; i++) {
+    gxCxycnv (*pt,*(pt+1),&x,&y);
+    if (i==0) cairo_move_to(cr,x,y);
+    else cairo_line_to(cr,x,y);
+    pt+=2;
+  }
+  /* disable antialiasing, otherwise faint lines appear around the edges */
+  if (aaflg) {
+    cairo_set_antialias(cr,CAIRO_ANTIALIAS_NONE);
+    cairo_fill(cr);                                  
+    cairo_set_antialias(cr,CAIRO_ANTIALIAS_DEFAULT);
+  }
+  else {
+    cairo_fill(cr);                                  
+  }
+  /* turn off polygon-filling flag */
+  filflg = 0;
+  return;
+}
+
+
+/* Turn anti-aliasing on (flag=1) or off (flag=0) 
+   Anti-aliasing is also automatically disabled in gxCrec and gxCfil so that
+   faint lines do not appear around the edges of filled rectangles and polygons.
+*/
+
+void gxCaa (gaint flag) {
+  if (flag) {
+    if (aaflg==0) {
+      cairo_set_antialias(cr,CAIRO_ANTIALIAS_DEFAULT);
+      aaflg = 1;
+    }
+  }
+  else {
+    if (aaflg) {
+      cairo_set_antialias(cr,CAIRO_ANTIALIAS_NONE);
+      aaflg = 0; 
+    }
+  }
+}
+
+
+/* Get the x bearing (width) used to plot a character in the specific font and size */
+
+gadouble gxCqchl (char ch, gaint fn, gadouble w) {
+cairo_text_extents_t te;
+gadouble usize,awidth,swidth,fontsize=100.0;
+char str[2];
+char *astr = "A";
+
+  gxCselfont (fn);
+
+  /* get the scale factor (for width only) based on the size of "A" */
+  cairo_set_font_size (cr, fontsize);
+  cairo_text_extents (cr, astr, &te);
+  awidth  = fontsize/te.width;
+  usize = w * awidth * xscl;
+  if (brdrflg)
+    usize = usize*(((gadouble)width-brdrwid*2.0)/(gadouble)width);
+
+  /* get the text extents of the character */
+  str[0] = ch;
+  str[1] = '\0';
+  cairo_text_extents (cr, str, &te);
+
+  /* return the scaled width of the character */
+  swidth = te.x_advance*usize/(fontsize*xscl);
+  return(swidth);
+}
+
+/* Draw a character. 
+   Specify a large font size and then scale it down, to prevent 
+   the pixelation from interfereing with the exact positioning.
+   Not much code, but it took a lot of work to get this right.  */
+
+gadouble gxCch (char ch, gaint fn, gadouble x, gadouble y, gadouble w, gadouble h, gadouble rot) {
+cairo_text_extents_t te;
+gadouble xpage,ypage,usize,vsize;
+gadouble aheight,awidth,swidth,fontsize=100.0;
+char str[2];
+char *astr = "A";
+
+  if (drawing) cairo_stroke(cr);
+  drawing = 0;
+  gxCselfont (fn);
+
+  /* get the scale factor based on size of "A" */
+  cairo_set_font_size (cr, fontsize);
+  cairo_text_extents (cr, astr, &te);
+  awidth  = fontsize/te.width;
+  aheight = fontsize/te.height;
+  usize = w * xscl * awidth;
+  vsize = h * yscl * aheight;
+  if (brdrflg) {
+    usize = usize*(((gadouble)width-brdrwid*2.0)/(gadouble)width);
+    vsize = vsize*(((gadouble)height-brdrwid*2.0)/(gadouble)height);
+  }
+  /* Convert the position coordinates and adjust the rotation if necessary */
+  gxCxycnv (x,y,&xpage,&ypage);
+  if (rotate) rot = rot + M_PI/2;
+
+  /* get the text extents of the character we want to draw */
+  str[0] = ch;
+  str[1] = '\0';
+  cairo_text_extents (cr, str, &te);
+
+  /* draw a character */
+  cairo_save(cr);                                    /* save the untranslated, unrotated, unclipped context */
+  cairo_rectangle(cr,clx,cly,clw,clh);               /* set the clipping area */
+  cairo_clip (cr);                                   /* clip it */
+  cairo_translate(cr,xpage,ypage);                   /* translate to location of character */
+  cairo_rotate(cr,-1.0*rot);                         /* rotate if necessary */
+  cairo_move_to (cr, 0.0, 0.0);                      /* move to (translated) origin */
+  cairo_scale (cr, usize/fontsize, vsize/fontsize);  /* apply the scale factor right before drawing */
+  cairo_show_text (cr, str);                         /* finally, draw the darned thing */
+  cairo_restore(cr);                                 /* restore the saved graphics context */
+
+  /* return the scaled width of the character */
+  swidth = te.x_advance*usize/(fontsize*xscl);
+  return(swidth);
+}
+
+
+/* Set the Cairo font based on the font number and the settings 
+   obtained from the backend database settings */
+
+void gxCselfont (gaint fn) {
+  struct gxdbquery dbq;
+  cairo_font_face_t *cf_face=NULL;           
+  FT_Face newface;
+  gaint dflt,rc;
+  gaint cbold,citalic;
+  
+  /* get font info from graphics database */
+  gxdbqfont (fn, &dbq);
+
+  /* font 0-5 (but not 3) and hershflag=1 in gxmeta.c, so we use cairo to draw something hershey-like */
+  if (fn<6) {
+    cbold = CAIRO_FONT_WEIGHT_NORMAL;
+    if (dbq.fbold == 1) cbold = CAIRO_FONT_WEIGHT_BOLD;
+    citalic = CAIRO_FONT_SLANT_NORMAL;
+    if (dbq.fitalic == 1) citalic = CAIRO_FONT_SLANT_ITALIC;
+    if (dbq.fitalic == 2) citalic = CAIRO_FONT_SLANT_OBLIQUE;
+  
+    if (dbq.fname == NULL) {
+      /* we should never have fn<6 and fname==NULL, but just in case... */
+      cairo_select_font_face (cr, "sans-serif", citalic, cbold); 
+    } else {
+      cairo_select_font_face (cr, dbq.fname, citalic, cbold);
+    }
+  }
+  else {
+    /* font>=10 */
+    dflt=0;
+    if (library == NULL) {
+      gxCftinit();                    /* make sure FreeType library has been initialized */
+      if (library == NULL) dflt=1;    /* use default fonts */  
+    }
+    if (dbq.fname == NULL) dflt=1;    /* make sure we have a font filename */
+
+    if (!dflt) {
+      if (dbq.fstatus==0) {
+        /* try to open user-provided font file */
+        rc = FT_New_Face(library, dbq.fname, 0, &newface);
+        if (rc) { 
+  	  printf("Error: Unable to open font file \"%s\"\n",dbq.fname);
+          printf(" Will use a default \"sans-serif\" font instead\n");
+          dflt=1;
+	  /* update the data base so this error message only appears once */
+	  gxdbsetfn(fn, NULL);
+        } 
+        else {
+	  /* we succeeded, so save the face and update the font status */
+          face[fn] = newface; 
+	  gxdbsetfnstatus(fn, 1);
+	}          
+      }
+      else {
+        /* this font has already been opened, so we use the saved face */
+        newface = face[fn];
+      }
+    }
+
+    if (!dflt) {
+	/* create a new font face  */
+	cf_face = cairo_ft_font_face_create_for_ft_face (newface, 0);
+	cairo_set_font_face(cr,cf_face);
+    }
+    else {
+      /* set up a default font with the Cairo "Toy" interface */
+      cairo_select_font_face (cr, "sans-serif", CAIRO_FONT_SLANT_NORMAL, CAIRO_FONT_WEIGHT_NORMAL);
+    }
+  }
+}
+
+/* Create a tile pattern on the fly.  Get all the info on the 
+   pattern from the backend db.   */
+
+void gxCpattc (gaint pnum) {
+struct gxdbquery dbq;
+cairo_surface_t *surfacep1;
+cairo_t *crpatt;
+gadouble xx,yy,x1,y1;
+gaint pt,alph,status;
+
+  if (pnum<0 || pnum>=COLORMAX) return;
+
+  gxdbqpatt (pnum, &dbq);
+  gxdbqwid (dbq.pthick, &dbq);
+
+  if (dbq.ptype==0) {
+    /* create tile from user-provided filename */
+    surfacep1 = cairo_image_surface_create_from_png (dbq.fname);
+    status = cairo_surface_status (surfacep1);
+    if (status) {
+      printf("Error in gxCpattc: unable to import tile image %s \n",dbq.fname);
+      printf("Cairo status: %s\n",cairo_status_to_string(status));
+      cairo_surface_finish(surfacep1);
+      cairo_surface_destroy(surfacep1); 
+      return; 
+    }
+    crpatt = cairo_create(surfacep1);
+  }
+  else {
+    /* create the tile on-the-fly */
+    surfacep1 = cairo_image_surface_create (CAIRO_FORMAT_ARGB32, dbq.pxs, dbq.pys);
+    crpatt = cairo_create(surfacep1);
+    
+    if (dbq.ptype==1) {
+      /* Type is a solid -- paint entire surface with foreground color */
+      if (dbq.pfcol < 0 ) {
+	/* use default foreground color, opaque white */
+	cairo_set_source_rgba(crpatt, 1.0, 1.0, 1.0, 1.0);
+      } else {
+	gxdbqcol (dbq.pfcol, &dbq);
+	if (dbq.red < 0) {                
+	  /* this color cannot be assigned to a tile, use default */
+	  cairo_set_source_rgba(crpatt, 1.0, 1.0, 1.0, 1.0);
+	} else {
+	  alph = dbq.alpha;
+	  if (alph<0) alph = -1*alph;
+	  cairo_set_source_rgba(crpatt, (double)(dbq.red)/255.0, (double)(dbq.green)/255.0,
+				(double)(dbq.blue)/255.0, (double)(alph)/255.0);
+	}
+      }
+    } else {
+      /* Type is not a solid -- paint entire surface with background color */
+      if (dbq.pbcol < 0 ) {
+	/* use default background color, which is completely transparent */
+	cairo_set_source_rgba(crpatt, 0.0, 0.0, 0.0, 0.0);
+      } else {
+	gxdbqcol (dbq.pbcol, &dbq);
+	if (dbq.red < 0) {
+	  /* this color cannot be assigned to a tile, use default */
+	  cairo_set_source_rgba(crpatt, 0.0, 0.0, 0.0, 0.0);
+	} else {
+	  alph = dbq.alpha;
+	  if (alph<0) alph = -1*alph;
+	  cairo_set_source_rgba(crpatt, (double)(dbq.red)/255.0, (double)(dbq.green)/255.0,
+				(double)(dbq.blue)/255.0, (double)(alph)/255.0);
+	}
+      }
+    }
+    cairo_paint(crpatt);
+
+    /* now paint the dots or lines */
+    if (dbq.ptype>1) {     /* Not solid */
+      if (dbq.pfcol < 0 ) {
+	/* use default foreground color, opaque white */
+	cairo_set_source_rgba(crpatt, 1.0, 1.0, 1.0, 1.0);
+      } else {
+	gxdbqcol (dbq.pfcol, &dbq);
+	if (dbq.red < 0) {
+	  /* this color cannot be assigned to a tile, use default */
+	  cairo_set_source_rgba(crpatt, 1.0, 1.0, 1.0, 1.0);
+	} else {
+	  alph = dbq.alpha;
+	  if (alph<0) alph = -1*alph;
+	  cairo_set_source_rgba(crpatt, (double)(dbq.red)/255.0, (double)(dbq.green)/255.0,
+				(double)(dbq.blue)/255.0, (double)(alph)/255.0);
+	}
+      }
+      cairo_set_line_width(crpatt,dbq.wid);  
+      xx = (gadouble)dbq.pxs;
+      yy = (gadouble)dbq.pys;
+      pt = dbq.ptype;
+      if (pt==2) {         /* dot */
+	x1 = (xx/2.0)-dbq.wid/2.0; y1 = (yy/2.0);
+	cairo_arc (crpatt, x1, y1, dbq.wid, 0.0, 2.0*3.1416);
+	cairo_fill (crpatt);
+      } else if (pt>=3 && pt<=5) {   /* diagonals */
+	if (pt==3 || pt==5) {
+	  cairo_move_to (crpatt, 0.0, 0.0);
+	  cairo_line_to (crpatt, xx, yy);
+	  cairo_stroke (crpatt);
+	  cairo_move_to (crpatt, 0.0, -1.0*yy);
+	  cairo_line_to (crpatt, 2.0*xx, yy);
+	  cairo_stroke (crpatt);
+	  cairo_move_to (crpatt, -1.0*xx, 0.0);
+	  cairo_line_to (crpatt, xx, 2.0*yy);
+	  cairo_stroke (crpatt);
+	}
+	if (pt==4 || pt==5) {
+	  cairo_move_to (crpatt, 0.0, yy);
+	  cairo_line_to (crpatt, xx, 0.0);
+	  cairo_stroke (crpatt);
+	  cairo_move_to (crpatt, 0.0, 2.0*yy);
+	  cairo_line_to (crpatt, 2.0*xx, 0.0);
+	  cairo_stroke (crpatt);
+	  cairo_move_to (crpatt, -1.0*xx, yy);
+	  cairo_line_to (crpatt, xx, -1.0*yy);
+	  cairo_stroke (crpatt);
+	}
+      } else if (pt>=6 && pt<=8) {   /* up/down accross */
+	x1 = xx/2.0; y1 = yy/2.0;
+	if (pt==6 || pt==8) {
+	  cairo_move_to (crpatt, x1, 0.0);
+	  cairo_line_to (crpatt, x1, yy);
+	  cairo_stroke (crpatt);
+	}
+	if (pt==7 || pt==8) {
+	  cairo_move_to (crpatt, 0.0, y1);
+	  cairo_line_to (crpatt, xx, y1);
+	  cairo_stroke (crpatt);
+	}
+      } 
+    }
+  }
+
+  cairo_surface_show_page (surfacep1);
+  pattern[pnum] = cairo_pattern_create_for_surface(surfacep1);
+  pattsurf[pnum] = surfacep1; 
+  cairo_destroy(crpatt);
+}
+
+/* Here we get notified that a pattern has been reset/changed.  
+   This will trigger re-creating the pattern if it is used. */
+
+void gxCpattrset (gaint pnum) {
+  if (pnum<0 || pnum>=2048) return;
+  cairo_pattern_destroy (pattern[pnum]);
+  cairo_surface_finish (pattsurf[pnum]);
+  cairo_surface_destroy (pattsurf[pnum]);
+  pattern[pnum] = NULL;
+  pattsurf[pnum] = NULL;
+}
+
+/* initialize the FreeType library */
+void gxCftinit (void) {
+  if (FT_Init_FreeType(&library)) library = NULL;
+}
+
+/* close the FreeType library */
+void gxCftend (void) {
+  FT_Done_FreeType(library);
+}
+
+void gxCpush (void) {
+  cairo_push_group(cr);
+}
+
+void gxCpop (void) {
+  cairo_pop_group_to_source(cr);
+  cairo_paint(cr);
+}
diff --git a/src/gxC.h b/src/gxC.h
new file mode 100644
index 0000000..60550d4
--- /dev/null
+++ b/src/gxC.h
@@ -0,0 +1,67 @@
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
+    See file COPYRIGHT for more information.   */
+
+/*  This file contains the function prototypes for Cairo/grads interface. */
+
+/*
+gxCaa       -- Turn anti-aliasing on or off
+gxCbatch    -- Initialize an image surface in batch mode (for getting string lengths)
+gxCbfil     -- Begin a polygon fill
+gxCbgn      -- Initialize the X interface in interactive mode
+gxCch       -- Draw a character
+gxCclip     -- Set the clipping coordinates
+gxCcol      -- Set the new color
+gxCdrw      -- Draw to
+gxCend      -- Close down the interactive session 
+gxCfil      -- Draw a filled polygon
+gxCflush    -- Finish up any pending actions
+gxCfrm      -- Clear the frame
+gxCftinit   -- Initialize the FreeType library
+gxCftend    -- Close the FreeType Library
+gxChinit    -- Initialize a hardcopy surface 
+gxChend     -- End the hardcopy drawing 
+gxCmov      -- Move to
+gxCpattc    -- Create a tile pattern
+gxcpattrset -- Reset a pattern
+gxCqchl     -- Get the width of a character
+gxCrec      -- Draw a filled rectangle
+gxCrsiz     -- Resize the interactive surface
+gxCselfont  -- Set the font 
+gxCsfc      -- Make a surface active for drawing 
+gxCswp      -- Swap action (for double buffering)
+gxCwid      -- Set the line width
+gxCxycnv    -- Convert position coordinates 
+*/
+
+
+#include <cairo.h>
+
+void gxCaa (gaint);
+void gxCbatch (gadouble , gadouble);
+void gxCbfil (void); 
+void gxCbgn (cairo_surface_t *, gadouble , gadouble, gaint, gaint);
+gadouble gxCch (char, gaint, gadouble, gadouble, gadouble, gadouble, gadouble);
+void gxCclip (gadouble, gadouble, gadouble, gadouble);
+void gxCcol (gaint);
+void gxCdrw (gadouble, gadouble);
+void gxCend (void);
+void gxCfil (gadouble*, gaint);
+void gxCflush (gaint);
+void gxCfrm (void);
+void gxCftinit (void);
+void gxCftend (void);
+gaint gxChinit (gadouble, gadouble, gaint, gaint, gaint, char *, gaint, char *, gadouble);
+gaint gxChend (char*, gaint, char *);
+void gxCmov (gadouble, gadouble);
+void gxCpattc (gaint);
+void gxCpattrset (gaint);
+void gxCpop (void);
+void gxCpush (void);
+gadouble gxCqchl (char, gaint, gadouble);
+void gxCrec (gadouble, gadouble, gadouble, gadouble);
+void gxCrsiz (gaint, gaint);
+void gxCselfont (gaint);
+void gxCsfc (cairo_surface_t *);
+void gxCswp (cairo_surface_t *,cairo_surface_t *);
+void gxCwid (gaint);                
+void gxCxycnv (gadouble, gadouble, gadouble*, gadouble*);
diff --git a/src/gxGD.c b/src/gxGD.c
new file mode 100644
index 0000000..aed5d44
--- /dev/null
+++ b/src/gxGD.c
@@ -0,0 +1,386 @@
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
+    See file COPYRIGHT for more information.   */
+
+/* Routines to rasterize the graphics using the GD library. */
+
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+#include <stdio.h>
+#include <string.h>
+#include <gd.h>
+#include "gatypes.h"
+#include "gx.h"
+#include "gxGD.h"
+
+
+/* default size of the graph */
+#define SX 800
+#define SY 600
+
+/* local variables */
+static gdImagePtr im=NULL;
+static gdPoint xxyy[256];
+static gdPoint *xybuf=NULL;
+
+static gaint cdef[256],cnum[256];
+static gaint ximg,yimg;
+static gaint ixrs,iyrs;
+static gaint backbw,gdthck,fflag,xyflag,ccol,xyc=0;
+static gaint xsav,ysav;
+static gaint xcur,ycur,xycnt=0;
+
+
+gaint gxGDinit (gadouble xrsize, gadouble yrsize, gaint xin, gaint yin, gaint bwin, char *bgImage) {
+gaint i,len;
+FILE *bgfile;
+
+  for (i=0; i<256; i++) cdef[i]=0; 
+  /* keep track of background color */
+  if (bwin<-900) 
+    backbw = gxdbkq();   /* default is hardware background color */
+  else 
+    backbw = bwin;       /* user-specified, 0==black, 1==white */
+
+  /*  Allocate the GD image and set up the scaling for it */
+  if (xin<0 || yin<0) {  
+    /* user has not specified image size */
+    if (xrsize > yrsize) {
+      ximg = SX; 
+      yimg = (gaint)((yrsize/xrsize)*SX);
+    }
+    else {
+      ximg = (gaint)((xrsize/yrsize)*SX); 
+      yimg = SX;
+    }
+  } 
+  else {
+    ximg = xin; 
+    yimg = yin;
+  }
+  ixrs = (gaint)(xrsize*1000.0+0.5);
+  iyrs = (gaint)(yrsize*1000.0+0.5);
+
+
+  im = NULL;
+  /* handle background PNG picture */
+  if (*bgImage) {
+    /* Make sure bgImage is a .png -- otherwise return error */
+    len = 0;
+    while (*(bgImage+len)) len++;
+    len = len-4;
+    if (len>0) {
+      if (*(bgImage+len+1)!='p' || 
+	  *(bgImage+len+2)!='n' || 
+	  *(bgImage+len+3)!='g' ) {
+	if (*(bgImage+len+1)!='P' || 
+	    *(bgImage+len+2)!='N' || 
+	    *(bgImage+len+3)!='G' ) {
+	  return(5);
+	} 
+      }
+    }
+    /* open bgImage */
+    if ((bgfile=fopen(bgImage,"rb"))) {
+      if ((im=gdImageCreateFromPng(bgfile)) != NULL) {
+	if (im->sx < ximg || im->sy < yimg) {
+	  gdImageDestroy(im);
+	  im=NULL;
+	}
+      } 
+      else {
+	fclose(bgfile);
+	return(7);
+      }
+      fclose(bgfile);
+    } 
+    else return(3);
+  }
+
+  if (!im) {
+    /* im = gdImageCreateTrueColor(ximg,yimg);  For anti-aliasing */
+    im = gdImageCreate(ximg,yimg);
+  }
+
+  /*  Set up background and foreground colors */
+  if (backbw) {
+    /* background is white ... */
+    cnum[0] = gdImageColorAllocate(im, 255, 255, 255);  /* ... so color 0 is white */
+    cnum[1] = gdImageColorAllocate(im, 0, 0, 0);        /*  and color 1 is black */
+  } else {
+    /* the other way around */
+    cnum[0] = gdImageColorAllocate(im, 0, 0, 0);
+    cnum[1] = gdImageColorAllocate(im, 255, 255, 255);
+  }
+  cdef[0] = 1; 
+  cdef[1] = 1;
+
+  /* initialize flags and other variables */
+  fflag = 0;
+  xyflag = 0;
+  gdthck = 1;
+  ccol = 1;  
+
+  return(0);
+}
+
+void gxGDcol (gaint clr) {  /* new color */
+struct gxdbquery dbq;
+  gxGDflush();
+  ccol = clr; 
+  if (ccol<0)   ccol=0;   
+  if (ccol>255) ccol=15;   /* limit of 256 colors in GD */
+  gxdbqcol(clr, &dbq);     /* query the data base for info about this color */
+  /* Allocate this color if not done already */
+  if (cdef[ccol]==0) {
+    cnum[ccol] = gdImageColorAllocate(im, dbq.red, dbq.green, dbq.blue);
+    cdef[ccol] = 1;
+  }
+}
+
+void gxGDwid (gaint wid) {  /* new line thickness */
+gaint thck;
+  gxGDflush();
+  thck = wid;
+  gdthck = 1;
+  if (thck>5) gdthck = 2;
+  if (thck>11) gdthck = 3;
+}
+
+void gxGDacol (gaint clr) {  /* new color definition */
+  gxGDflush();
+  cdef[clr] = 0;   /* Indicate that this new color must be allocated */
+}
+
+void gxGDrec (gadouble x1, gadouble x2, gadouble y1, gadouble y2) {  /* filled rectangle */ 
+gaint i,xp,yp,xp2,yp2;
+gaint ix1,ix2,iy1,iy2;
+  gxGDflush();
+
+  ix1  = (gaint)(x1*1000.0+0.5);
+  ix2  = (gaint)(x2*1000.0+0.5);
+  iy1  = (gaint)(y1*1000.0+0.5);
+  iy2  = (gaint)(y2*1000.0+0.5);
+
+  xp = (ximg*ix1)/ixrs;
+  yp = yimg-(yimg*iy1)/iyrs;
+  xp2 = (ximg*ix2)/ixrs;
+  yp2 = yimg-(yimg*iy2)/iyrs;
+
+  if (xp>xp2) { 
+    i = xp;
+    xp = xp2;
+    xp2 = i;
+  }
+  if (yp>yp2) { 
+    i = yp;
+    yp = yp2;
+    yp2 = i;
+  }
+  gdImageFilledRectangle(im, xp, yp, xp2, yp2, cnum[ccol]);
+}
+
+void gxGDbpoly (void) {  /* start a polygon fill */
+  gxGDflush();
+  fflag = 1;
+  xyc = 0;
+}
+
+gaint gxGDepoly (gadouble *xybuffer, gaint xyc) {  /* terminate a polygon fill */
+gaint thisx,thisy,i,ptr,ix1,iy1;
+gadouble x1,y1;
+
+  /* allocate memory for array of gdPoints */
+  xybuf = (gdPoint *)malloc(sizeof(gdPoint)*(xyc+2));
+  if (xybuf==NULL) {
+    printf("Memory allocation error in gxGDepoly\n");
+    return(99);
+  }
+  /* populate xybuf with gdPoint values */
+  ptr=0;
+  for (i=0; i<xyc; i++) {
+    x1 = *(xybuffer+ptr);
+    y1 = *(xybuffer+ptr+1);
+    ix1  = (gaint)(x1*1000.0+0.5);
+    iy1  = (gaint)(y1*1000.0+0.5);
+    thisx = (ximg*ix1)/ixrs;
+    thisy = yimg-(yimg*iy1)/iyrs;
+    (xybuf+i)->x = thisx;
+    (xybuf+i)->y = thisy;
+    ptr+=2;
+  }
+  /* close the polygon if necessary */
+  if (xybuf->x != (xybuf+xyc-1)->x ||
+      xybuf->y != (xybuf+xyc-1)->y) {
+    (xybuf+xyc)->x = xybuf->x;
+    (xybuf+xyc)->y = xybuf->y;
+    xyc++;
+  }
+  /* render it */
+  gdImageFilledPolygon(im, xybuf, xyc, cnum[ccol]); 
+  /* clean up */
+  free (xybuf);
+  xybuf = NULL;
+  fflag = 0;
+  return(0);
+}
+
+void gxGDmov (gadouble x1, gadouble y1) {  /* move to */ 
+gaint ix1,iy1;
+
+  gxGDflush();
+
+  ix1  = (gaint)(x1*1000.0+0.5);
+  iy1  = (gaint)(y1*1000.0+0.5);
+  xsav = (ximg*ix1)/ixrs;
+  ysav = yimg-(yimg*iy1)/iyrs;
+
+  if (!fflag) {
+    xxyy[0].x = xsav;
+    xxyy[0].y = ysav;
+    xycnt = 1;
+    xyflag = 0;
+  }
+}
+
+void gxGDdrw (gadouble x1, gadouble y1) {  /* draw to */  
+gaint ix1,iy1;
+
+  ix1  = (gaint)(x1*1000.0+0.5);
+  iy1  = (gaint)(y1*1000.0+0.5);
+  xcur = (ximg*ix1)/ixrs;
+  ycur = yimg-(yimg*iy1)/iyrs;
+
+  if (!fflag) { 
+    xxyy[xycnt].x = xcur;
+    xxyy[xycnt].y = ycur;
+    if (xycnt<255) xycnt++;
+    else {
+      gxGDpoly(xycnt+1,cnum[ccol],gdthck);
+      xxyy[0].x = xcur;
+      xxyy[0].y = ycur;
+      xycnt = 1; 
+    }
+    xyflag = 1;
+  }
+  xsav = xcur; 
+  ysav = ycur;
+}
+
+void gxGDflush (void) {  /* finish up any drawing operation */
+  if (xyflag) { 
+    gxGDpoly(xycnt,cnum[ccol],gdthck); 
+    xyflag=0; 
+    xycnt=0; 
+  }
+}
+
+/* Turns out that the anti-aliasing doesn't work with
+   the line thickness, in gd-v2.  Decided to not use
+   the anti-aliasing this version.  But kept the 
+   function calls here, commented out, for possible
+   future use.  */
+
+void gxGDpoly (gaint xycnt, gaint col, gaint thck) {
+
+  /*     gdImageSetAntiAliased(im,col); */
+  gdImageSetThickness(im,thck);
+
+  if (xycnt==2) {
+    /*     gdImageLine(im, xxyy[0].x, xxyy[0].y, xxyy[1].x, xxyy[1].y, gdAntiAliased); */
+    gdImageLine(im, xxyy[0].x, xxyy[0].y, xxyy[1].x, xxyy[1].y, col);
+  }
+  else if (xycnt>2) {
+    /*    gdImageOpenPolygon(im, xxyy, xycnt, gdAntiAliased); */
+    gdImageOpenPolygon(im, xxyy, xycnt, col);
+  }
+}
+
+
+gaint gxGDfgimg (char *fgImage) {  /* handle foreground PNG picture */
+gaint len;
+FILE *fgfile;
+gdImagePtr imfg;
+
+  /* Make sure foreground image file is a .png -- otherwise return error */
+  len = 0;
+  while (*(fgImage+len)) len++;
+  len = len-4;
+  if (len>0) {
+    if (*(fgImage+len+1)!='p' || 
+	*(fgImage+len+2)!='n' || 
+	*(fgImage+len+3)!='g' ) {
+      if (*(fgImage+len+1)!='P' || 
+	  *(fgImage+len+2)!='N' || 
+	  *(fgImage+len+3)!='G' ) {
+	return(6);
+      } 
+    }
+  }
+  
+  if ((fgfile=fopen(fgImage,"rb"))) {
+    if ((imfg=gdImageCreateFromPng(fgfile)) !=NULL) {
+      gdImageCopy(im,imfg,0,0,0,0,imfg->sx,imfg->sy);
+    }
+    else {
+      fclose(fgfile);
+      return(8);
+    }
+  } else {
+    return(4);
+  }
+  fclose(fgfile);
+  gdImageDestroy(imfg);
+  return (0);
+}
+
+
+gaint gxGDend (char *fnout, char *bgImage, gaint fmtflg, gaint tcolor) {
+FILE *ofile, *bgfile;
+gdImagePtr imbg;
+gaint retcod;
+
+  retcod = 0;
+
+  /* optionally convert a color to transparent */
+  if (tcolor != -1 ) {
+    if (cdef[tcolor]){
+      gdImageColorTransparent(im,cnum[tcolor]);
+      printf("Transparent color: #%d\n",tcolor);
+    }
+  }
+
+  if (*bgImage) {
+    if ((bgfile=fopen(bgImage,"rb"))) {
+      if ((imbg=gdImageCreateFromPng(bgfile)) !=NULL) {
+	gdImageCopy(imbg,im,0,0,0,0,im->sx,im->sy);
+      }
+    }
+    fclose(bgfile);
+    gdImageDestroy(im);
+    im=imbg;
+  }
+
+  ofile = fopen(fnout, "wb");
+  if (ofile==NULL) { 
+    printf("Open error on %s\n",fnout);
+    retcod = 1; 
+  } else {
+    if (fmtflg==6) {                    /* image output in gif format */
+      gdImageGif (im, ofile);
+    }
+    else if (fmtflg==7) {     	        /* image output in jpg format */
+      gdImageJpeg(im, ofile, -1);
+    }
+    else {                       	/* image output in png format */
+      gdImagePng(im, ofile);
+    }
+    fclose(ofile);
+  }
+
+  gdImageDestroy(im);
+  im = NULL;
+  return (retcod);
+}
+
+
diff --git a/src/gxGD.h b/src/gxGD.h
new file mode 100644
index 0000000..c239f23
--- /dev/null
+++ b/src/gxGD.h
@@ -0,0 +1,23 @@
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
+    See file COPYRIGHT for more information.   */
+
+/* Function prototypes for GD interface. 
+   The interactive interface (X windows) is managed by the routines in gxX11.c
+   Hardcopy output is managed in gxprintGD.c  */
+
+/* function prototypes */
+gaint gxGDinit (gadouble, gadouble, gaint, gaint, gaint, char *);
+void  gxGDcol (gaint);
+void  gxGDwid (gaint);
+void  gxGDacol (gaint);
+void  gxGDrec (gadouble, gadouble, gadouble, gadouble);
+void  gxGDbpoly (void);
+gaint gxGDepoly (gadouble *, gaint);
+void  gxGDmov (gadouble, gadouble);
+void  gxGDdrw (gadouble, gadouble);
+void  gxGDflush (void);
+void  gxGDpoly (gaint, gaint, gaint);
+gaint gxGDfgimg (char *);
+gaint gxGDend (char *, char *, gaint, gaint);
+
+
diff --git a/src/gxX.c b/src/gxX.c
index ff69b67..d5fc129 100644
--- a/src/gxX.c
+++ b/src/gxX.c
@@ -1,7 +1,8 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
+/* Simplified X interface for Cairo -- no widgets, buttons, X-based pattern fill, etc. */
+
 /* Include ./configure's header file */
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -16,18 +17,16 @@
 #include <X11/Xatom.h>
 #include <X11/keysym.h>
 
+#include <cairo.h>
+#include <cairo-xlib.h>
+
 #include "gatypes.h"
 #include "gx.h"
-#include "bitmaps.h"
+#include "gxC.h"
+#include "bitmaps2.h"
 
-/* Following function prototype has to go here since it 
-   depends on X include information, which shouln't go in gx.h */
-
-/*  gxbcol:  Assign best rgb to color number from standard colormap */
-gaint gxbcol (XStandardColormap*, XColor *);
-void set_display_screen (Display *, gaint);
-void Window_Dump(Window,FILE *);
-void Pixmap_Dump(Window, FILE *, gaint, gaint, gaint, gaint);
+/* function prototypes */
+void gxdXflush (void);
 
 /* Interface for X11 Release 3  */
 
@@ -61,94 +60,44 @@ void Pixmap_Dump(Window, FILE *, gaint, gaint, gaint, gaint);
                                                                   */
 
 static gaint batch=0;                       /* Batch mode? */
-static gaint wchose=0;                      /* Controls technique for wide lines 1= s/w 0 X server*/
-static gaint lcolor,lwidth,owidth;          /* Current attributes */
-static gaint grflg;                         /* Greyscale flag */
-static gaint devbck;                        /* Device background */
 static gadouble xscl,yscl;                  /* Window Scaling */
-static gaint xxx,yyy;                       /* Old position */
 static gadouble xsize, ysize;               /* User specified size */
-static unsigned long cvals[276];            /* Color pixel values */
-static gaint cused[276];                    /* Color is assigned */
-static gaint cmach[276];                    /* Color is matched */
 static gaint dblmode;                       /* single or double buffering */
 static gaint width,height,depth;            /* Window dimensions */
-
-static gaint reds[16] =   {  0,255,250,  0, 30,  0,240,230,240,160,160,  0,230,  0,130,170};
-static gaint greens[16] = {  0,255, 60,220, 60,200,  0,220,130,  0,230,160,175,210,  0,170};
-static gaint blues[16]  = {  0,255, 60,  0,255,200,130, 50, 40,200, 50,255, 45,140,220,170};
-
-static gaint greys[16] = {0,255,215,140,80,110,230,170,200,50,155,95,185,125,65,177};
-static gaint grrev[16] = {0,1,14,3,8,7,9,5,4,6,13,12,11,10,2,15};
-
-/* Various arrays are kept for structures that describe displayed
-   widgets.  This information is kept in static arrays for
-   efficiency reasons -- so the arrays will tend to be in memory
-   together and will be much faster to scan when paging is
-   going on.  A linked list set up would be much easier to code
-   and much cleaner, but at least for now I will stick with
-   the pre-defined arrays.  */
-
-static struct gobj obj[512];    /* Displayed objects */
-static struct gobj obj2[512];   /* Background objects */
-static gaint obnum,obnum2;        /* Current number of objects */
-static struct gbtn btn[256];    /* Current buttons */
-static struct gbtn btn2[256];   /* Background buttons */
-static struct grbb rbb[32];     /* Current rubber-band regions */
-static struct grbb rbb2[32];    /* Background rbb regions */
-static struct gdmu dmu[200];    /* Current dropmenus */
-static struct gdmu dmu2[200];   /* Background dropmenus */
-/* static struct gdlg dlg[1];      /\* Current dialog *\/ */
-
 static struct gevent *evbase;   /* Anchor for GrADS event queue */
 
+/* Cairo related */
+static cairo_surface_t *surface=NULL,*surface2=NULL;
+
 /* All stuff passed to Xlib routines as args are put here in
    static areas since we are not invoking Xlib routines from main*/
 
+static Visual *xvis;
 static Screen *sptr;
 Display *display=(Display *)NULL;
 static gaint snum;
-static GC gc;
-static XGCValues values;
 static XEvent report;
-Window win=(Window) NULL;    /* used via extern in gagui */
-static Pixmap pmap;
-static Pixmap pmaps[200];
-static XImage *image;
-static Drawable drwbl;
+Window win=(Window) NULL;   /* used via extern in gagui */
+static Drawable drwbl,drwbl2;
 static char *window_name = "GrADS " GRADS_VERSION "";
-/*char *window_name = "GrADS";*/
 static char *display_name = NULL; 
 static char *icon_name = "GrADS";
 static Pixmap icon_pixmap;
 static XSizeHints size_hints;
-/* static XIconSize *size_list; */
 static gaint argc;
 static char **argv;
 static char *args[4];
 static char *name = "grads";
 static char *dgeom = "500x400+10+10";
 static char *ugeom = NULL;
-static Colormap cmap;
-static XColor cell;
-static XPoint *point;
 static gaint dblmode;                     /* single or double buffering */
-static XFontStruct *font1, *font2, *font3;
-static XFontStruct *font1i, *font2i, *font3i;
 static XSetWindowAttributes xsetw;
-static gaint gfont,cfont;                       /* Font in use by grads */
-static gaint pfilld[200];
 static gaint rstate = 1;              /* Redraw state -- when zero,
                                       acceptance of X Events is
                                       blocked. */
 static gaint bsflg;                   /* Backing store enabled or not */
 static gaint excnt;                   /* Count of exposes to skip */
 
-/* Invokes usage of software to generate wide lines (vs Xserver) */
-
-void gxwdln (void) {
-  wchose=1;
-}
 
 /* tell x interface that we are in batch mode */
 
@@ -156,17 +105,6 @@ void gxdbat (void) {
   batch = 1;
 }
 
-/* Query default color rgb values*/
-
-void gxqdrgb (gaint clr, gaint *r, gaint *g, gaint *b) {
-  if (clr>=0 && clr<16) {
-    *r = reds[clr];
-    *g = greens[clr];
-    *b = blues[clr];
-  } 
-  return;
-}
-
 /* Routine to specify user X stuff (geom string, window name).  Must be
    called before gxdbgn to have any affect */
 
@@ -175,44 +113,30 @@ void gxdgeo (char *arg) {
 }
 
 void gxdbgn (gadouble xsz, gadouble ysz) {
-gaint dw, dh, flag, i, ipos, jpos, border;
-char **flist,*xfnam;
-
-  for (i=0; i<200; i++) pfilld[i] = 0;
-  for (i=0; i<256; i++) cused[i] = 0; 
-  for (i=0; i<256; i++) { btn[i].ch = NULL; btn2[i].ch = NULL; }
-  for (i=0; i<256; i++) { btn[i].num = -1; btn2[i].num = -1; }
-  for (i=0; i<32;  i++) { rbb[i].num = -1; rbb2[i].num = -1; }
-  for (i=0; i<200; i++) { dmu[i].num = -1; dmu2[i].num = -1; }
-  for (i=0; i<512; i++) { obj[i].type = -1; obj2[i].type = -1; }
-  obnum = 0; obnum2 = 0;
+gaint dw,dh,flag,ipos,jpos,border;
+
   evbase = NULL;
   excnt = 0;
-
   args[0] = name;
   args[1] = NULL;
   argv = args;
   argc = 1;
-
   xsize = xsz;
   ysize = ysz;
   border = 4;
 
   /* Connect to X server */
-
-  if ( (display=XOpenDisplay(display_name)) == NULL ) {
+  if ((display=XOpenDisplay(display_name)) == NULL) {
     printf("Error in GXSTRT: Unable to connect to X server\n");
-    exit( -1 );
+    exit(-1);
   }
 
-  /* Get screen size from display structure macro, then figure out
-     proper window size */
-
+  /* Get screen size from display structure macro, then figure out proper window size */
   snum = DefaultScreen(display);
   sptr = DefaultScreenOfDisplay(display);
+  xvis = DefaultVisual(display,snum);
   bsflg = 0;
   if (DoesBackingStore(sptr)) bsflg = 1;
-  cmap = DefaultColormap(display, snum);
   dw = DisplayWidth(display, snum);
   dh = DisplayHeight(display, snum);
   depth = DefaultDepth(display, snum);
@@ -221,7 +145,7 @@ char **flist,*xfnam;
 
   /* window sizes are scaled according to the height of display */
   if ( xsize >= ysize ) {           /* landscape */
-    if (xsize==11.0 && ysize==8.5) {    /* preseve old default */
+    if (xsize==11.0 && ysize==8.5) {    /* preserve old default */
       dh = (gaint)((gadouble)dh*0.6);        
       dw = (gaint)((gadouble)(dh)*xsz/ysz);  
     } else {
@@ -238,90 +162,42 @@ char **flist,*xfnam;
 
   size_hints.flags = PPosition | PSize ;
   if (ugeom) {
-    XGeometry (display, snum, ugeom, dgeom, 4, 1, 1, 0, 0,
-        &ipos, &jpos, &dw, &dh);
+    XGeometry (display,snum,ugeom,dgeom,4,1,1,0,0,&ipos,&jpos,&dw,&dh);
     size_hints.flags = USPosition | USSize ;
   }
   size_hints.x = ipos;
   size_hints.y = jpos;
   size_hints.width = dw;
   size_hints.height = dh;
-  width = dw ; /* hoop */
-  height = dh ; /* hoop */
-  xscl = (gadouble) (dw) / xsize ; /* hoop */
-  yscl = (gadouble) (dh) / ysize ; /* hoop */
+  width = dw ; 
+  height = dh ;
+  xscl = (gadouble) (dw) / xsize ;
+  yscl = (gadouble) (dh) / ysize ;
 
   /* Create window */
-
-  win = XCreateSimpleWindow(display, RootWindow(display,snum),
-        ipos, jpos, dw, dh, border,
-        WhitePixel(display, snum), BlackPixel(display,snum));
-  devbck = 0;
+  win = XCreateSimpleWindow(display,RootWindow(display,snum),ipos,jpos,dw,dh,border,
+			    WhitePixel(display,snum),BlackPixel(display,snum));
 
   /* Set up icon pixmap */
-
-  icon_pixmap = XCreateBitmapFromData(display, win, (char*)icon_bitmap_bits,
-                icon_bitmap_width, icon_bitmap_height);
+  icon_pixmap = XCreateBitmapFromData(display,win,(char*)icon_bitmap_bits,
+				      icon_bitmap_width,icon_bitmap_height);
 
   /* Set standard properties */
-
-  XSetStandardProperties(display, win, window_name, icon_name,
-       icon_pixmap, argv, argc, &size_hints);
-
-  /* Set colors */
-
-  for (i=0; i<16; i++) {
-    cell.red = reds[i]*256;
-    cell.blue = blues[i]*256;
-    cell.green = greens[i]*256;
-    if (XAllocColor(display, cmap, &cell)) {
-      cvals[i] = cell.pixel;
-    } else {
-      cvals[i] = cvals[1];    /* Assume white and black got allocated */
-    }
-    cused[i] = 1;
-  }
-  for (i=0; i<16; i++) {
-    cell.red = greys[i]*256;
-    cell.blue = greys[i]*256;
-    cell.green = greys[i]*256;
-    if (XAllocColor(display, cmap, &cell)) {
-      cvals[i+256] = cell.pixel;
-    } else {
-      cvals[i+256] = cvals[15];
-    }
-    cused[i+256] = 1;
-  }
+  XSetStandardProperties(display,win,window_name,icon_name,icon_pixmap,argv,argc,&size_hints);
 
   /* Select event types */
-
-  XSelectInput(display, win, ButtonReleaseMask | ButtonPressMask |
-      ButtonMotionMask | ExposureMask | StructureNotifyMask);
-
-  /* Get a Graphics Context */
-
-  gc = XCreateGC(display, win, 0L, &values);
-  XSetForeground(display, gc, cvals[1]);
-  XSetLineAttributes(display, gc, 0L, LineSolid,
-                     CapButt, JoinBevel);
-  lwidth = 1;
-  owidth = 0;
-  lcolor = 1;
-  grflg = 0;
+  XSelectInput(display, win, ButtonReleaseMask | ButtonPressMask | ExposureMask | StructureNotifyMask);
 
   /* Display Window */
-
-  XMapWindow(display, win);
+  XMapWindow(display,win);
 
   /* We now have to wait for the expose event that indicates our
      window is up.  Also handle any resizes so we get the scaling
      right in case it gets changed right away.  We will check again
      for resizes during frame operations */
-
-#ifndef __CYGWIN32__
   flag = 1;
   while (flag)  {
-    XNextEvent(display, &report);
+    XNextEvent(display,&report);
     switch  (report.type) {
     case Expose:
       if (report.xexpose.count != 0) break;
@@ -335,129 +211,24 @@ char **flist,*xfnam;
       break;
     }
   }
-#endif /* __CYGWIN32__ */
-
-  /* Now ready for drawing, so we can exit. */
 
+  /* Now ready for drawing */
   drwbl = win;   /* Initial drawable is the visible window */
   dblmode = 0;   /* Initially no double buffering mode     */
 
   xsetw.backing_store = Always;
-  XChangeWindowAttributes (display, win, CWBackingStore, &xsetw);
-
-  /* Set up a font */
-
-  font1 = NULL;
-  font2 = NULL;
-  font3 = NULL;
-  font1i = NULL;
-  font2i = NULL;
-  font3i = NULL;
-
-  xfnam = gxgsym("GAXFS");
-  if (xfnam) flist = XListFonts (display, xfnam, 1, &i);
-  else flist = NULL;
-  if (flist==NULL) {
-    flist = XListFonts (display, "-adobe-helvetica-bold-r-normal-*-80*", 1, &i);
-  }
-  if (flist==NULL) {
-    flist = XListFonts (display, "-adobe-helvetica-bold-r-normal-*-100*", 1, &i);
-  }
-  if (flist==NULL) {
-    font1 = XLoadQueryFont (display, "fixed");
-  } else {
-    font1 = XLoadQueryFont (display, *flist);
-    if (font1==NULL) printf ("ERROR: Unable to open a basic font!!!\n");
-    XFreeFontNames (flist);
-  }
-
-  xfnam = gxgsym("GAXFSI");
-  if (xfnam) flist = XListFonts (display, xfnam, 1, &i);
-  else flist = NULL;
-  if (flist==NULL) {
-    flist = XListFonts (display, "-adobe-helvetica-bold-o-normal-*-80*", 1, &i);
-  }
-  if (flist==NULL) {
-    flist = XListFonts (display, "-adobe-helvetica-bold-o-normal-*-100*", 1, &i);
-  }
-  if (flist==NULL) {
-    font1i = XLoadQueryFont (display, "fixed");
-  } else {
-    font1i = XLoadQueryFont (display, *flist);
-    if (font1i==NULL) font1i = font1;
-    XFreeFontNames (flist);
-  }
-
-  xfnam = gxgsym("GAXFM");
-  if (xfnam) flist = XListFonts (display, xfnam, 1, &i);
-  else flist = NULL;
-  if (flist==NULL) {
-    flist = XListFonts (display, "-adobe-helvetica-bold-r-normal--~-100*", 1, &i);
-  }
-  if (flist==NULL) {
-    flist = XListFonts (display, "-adobe-helvetica-bold-r-normal-*-120*", 1, &i);
-  }
-  if (flist==NULL) {
-    font2 = font1;
-  } else {
-    font2 = XLoadQueryFont (display, *flist);
-    if (font2==NULL) font2 = font1;
-    XFreeFontNames (flist);
-  }
-  xfnam = gxgsym("GAXFMI");
-  if (xfnam) flist = XListFonts (display, xfnam, 1, &i);
-  else flist = NULL;
-  if (flist==NULL) {
-    flist = XListFonts (display, "-adobe-helvetica-bold-o-normal--~-100*", 1, &i);
-  }
-  if (flist==NULL) {
-    flist = XListFonts (display, "-adobe-helvetica-bold-o-normal-*-120*", 1, &i);
-  }
-  if (flist==NULL) {
-    font2i = font1i;
-  } else {
-    font2i = XLoadQueryFont (display, *flist);
-    if (font2i==NULL) font2i = font1i;
-    XFreeFontNames (flist);
-  }
-
-  xfnam = gxgsym("GAXFL");
-  if (xfnam) flist = XListFonts (display, xfnam, 1, &i);
-  else flist = NULL;
-  if (flist==NULL) {
-    flist = XListFonts (display, "-adobe-helvetica-bold-r-normal-*-140*", 1, &i);
-  }
-  if (flist==NULL) {
-    font3 = font2;
-  } else {
-    font3 = XLoadQueryFont (display, *flist);
-    if (font3==NULL) font3 = font2;
-    XFreeFontNames (flist);
-  }
-  xfnam = gxgsym("GAXFLI");
-  if (xfnam) flist = XListFonts (display, xfnam, 1, &i);
-  else flist = NULL;
-  if (flist==NULL) {
-    flist = XListFonts (display, "-adobe-helvetica-bold-o-normal-*-140*", 1, &i);
-  }
-  if (flist==NULL) {
-    font3i = font2i;
-  } else {
-    font3i = XLoadQueryFont (display, *flist);
-    if (font3i==NULL) font3i = font2i;
-    XFreeFontNames (flist);
-  }
-  cfont = 0;
-  gxdsfn();
+  XChangeWindowAttributes (display,win,CWBackingStore,&xsetw);
 
-}
+  /* Set up the cairo Xlib surface and initialize gxC */
+  surface = cairo_xlib_surface_create (display,drwbl,xvis,dw,dh);
+  gxCbgn(surface,xsz,ysz,dw,dh);
 
-void gxgrey (gaint flag) {
-  grflg = flag;
 }
 
 void gxdend (void) {
-  XFreeGC(display, gc);
+  gxCend();
+  cairo_surface_finish (surface);
+  cairo_surface_destroy (surface);
   XCloseDisplay(display);
 }
 
@@ -468,27 +239,21 @@ void gxdend (void) {
       7 -- new frame, but just clear graphics.  Do not clear
            event queue; redraw widgets.
       8 -- clear only the event queue.
-      9 -- flush the X request buffer */
+      9 -- flush the X request buffer 
+*/
 
 void gxdfrm (gaint iact) {
-struct gevent *geve, *geve2;
-gaint i;
+struct gevent *geve,*geve2;
   if (iact==9) {
     gxdeve(0);
-    XFlush(display);
+    gxdXflush();
     return;
   }
   if (iact==0 || iact==1 || iact==7) {
-    XSetForeground(display, gc, cvals[devbck]);
-    XFillRectangle (display, drwbl, gc, 0, 0, width, height);
-    XSetForeground(display, gc, cvals[lcolor]);
-    for (i=0; i<512; i++) obj[i].type = -1;
-    obnum = 0;
+    gxCfrm();
   }
 
-  /* Flush X event queue.  If iact is 7, keep the event info,
-     otherwise discard it. */
-
+  /* Flush X event queue. If iact is 7, keep the event info, otherwise discard it. */
   if (iact==7) gxdeve(0);
   else {
     while (XCheckMaskEvent(display, ButtonReleaseMask | ButtonPressMask |
@@ -500,14 +265,12 @@ gaint i;
           height = report.xconfigure.height;
           xscl = (gadouble)(width)/xsize;
           yscl = (gadouble)(height)/ysize;
-          gxdsfn();
           if (iact==8) gxdrdw();
         }
       }
     }
 
     /* Flush GrADS event queue */
-
     geve = evbase;
     while (geve) {
       geve2 = geve->forw;
@@ -517,16 +280,7 @@ gaint i;
     evbase = NULL;
   }
 
-  /* Reset all widgets if appropriate. */
-
-  if (iact<7 && iact!=2) gxrswd(0);
-
-  /* Redraw all widgets if appropriate.*/
-
-  if (iact==7) {
-    gxrdrw(0);
-    XFlush(display);
-  }
+  if (iact==7) gxdXflush();
 }
 
 /* Examine X event queue.  Flag tells us if we should wait for an
@@ -535,7 +289,7 @@ gaint i;
 
 void gxdeve (gaint flag) {
 struct gevent *geve, *geve2;
-gaint i,j,ii,rc,wflg,button,eflg,idm,rdrflg;
+gaint i,j,rc,wflg,button,eflg,rdrflg;
 
   if (flag && evbase) flag = 0;   /* Don't wait if an event stacked */
   wflg = flag;
@@ -544,21 +298,22 @@ gaint i,j,ii,rc,wflg,button,eflg,idm,rdrflg;
   while (1) {
     if (wflg && !rdrflg) {
       XMaskEvent(display, ButtonReleaseMask | ButtonPressMask |
-         ButtonMotionMask | KeyPressMask | ExposureMask | StructureNotifyMask, &report);
+          ExposureMask | StructureNotifyMask, &report);
       rc = 1;
     } else {
       rc = XCheckMaskEvent(display, ButtonReleaseMask | ButtonPressMask |
-         ButtonMotionMask | KeyPressMask | ExposureMask | StructureNotifyMask, &report);
+          ExposureMask | StructureNotifyMask, &report);
     }
     if (!rc && rdrflg) {
-      gxdsfn();
-      gxdrdw();
-      rdrflg = 0;
+      gxdrdw(); 
+      rdrflg = 0; 
       continue;
     }
     if (!rc) break;
 
     switch  (report.type) {
+    case ButtonRelease:
+      break;
     case Expose:
       if (excnt>0) excnt--;
       else if (!bsflg) rdrflg = 1;
@@ -589,26 +344,6 @@ gaint i,j,ii,rc,wflg,button,eflg,idm,rdrflg;
       geve->x = xsize*((gadouble)i)/width;
       geve->y = ysize - ysize*((gadouble)j)/height;
       geve->type = 0;
-
-      /* Scan to see if point-click event was on one of our
-         widgets.  Handling depends on what is clicked on. */
-
-      ii = 0;
-      while (ii<512 && obj[ii].type>-1) {
-        if (obj[ii].type!=0 && i>obj[ii].i1 && i<obj[ii].i2 &&
-                               j>obj[ii].j1 && j<obj[ii].j2) {
-          if (obj[ii].mb < 0 || obj[ii].mb == button) {
-            if (obj[ii].type==1) gxevbn(geve,ii);
-            else if (obj[ii].type==2) gxevrb(geve,ii,i,j);
-            else if (obj[ii].type==3) {
-              idm = ii;
-              while (idm != -999) idm = gxevdm(geve,idm,i,j);
-            }
-            ii = 100000;           /* Exit loop */
-          }
-        }
-        ii++;
-      }
       wflg = 0;                  /* Check for more events, but don't
                                     wait if there aren't any. */
       break;
@@ -626,7 +361,6 @@ gaint i,j,ii,rc,wflg,button,eflg,idm,rdrflg;
     if (eflg) break;
   }
   if (rdrflg) {
-    gxdsfn();
     gxdrdw();
   }
 }
@@ -657,2509 +391,220 @@ gaint i;
     *type = geve->type;
     for (i=0; i<10; i++) *(info+i) = geve->info[i];
     for (i=0; i<4; i++) *(rinfo+i) = geve->rinfo[i];
-    evbase = geve->forw;       /* Take even off queue */
+    evbase = geve->forw;       /* Take event off queue */
     free(geve);
   }
 
 }
 
-void gxdcol (gaint clr) {
-  if (clr<0) clr=0;
-  if (clr>255) clr=255;
-  if (devbck) {
-    if (clr==0) clr = 1;
-    else if (clr==1) clr = 0;
-  }
-  if (clr<16 && grflg) {
-    if (devbck) clr = grrev[clr];
-    clr+=256; 
-  }
-  if (!cused[clr] && !cmach[clr]) clr=15; 
-  XSetForeground(display, gc, cvals[clr]);
-  lcolor=clr;
-}
-
-
-/* static void qprint(XStandardColormap* bst);  */
-
-gaint gxdacl (gaint clr, gaint red, gaint green, gaint blue) {
-  XStandardColormap best;
-  gaint screen_num = DefaultScreen(display);
-		
-  if (clr<16 || clr>255) return 1;
-  if (cused[clr]) {
-     XFreeColors(display, cmap, &(cvals[clr]),1,0);
-     cused[clr]=0;
-  }
-  cell.red = red*256;
-  cell.blue = blue*256;
-  cell.green = green*256;
-  cmach[clr] = 0;
-  if (XAllocColor(display, cmap, &cell)) {
-    cvals[clr] = cell.pixel;
-    cused[clr] = 1;
-  } else if (XGetStandardColormap(display, 
-             RootWindow(display,screen_num), &best, XA_RGB_BEST_MAP)) {
-    if (gxbcol(&best, &cell)) {
-      cvals[clr] = cell.pixel;
-      cmach[clr] = 1;
-      printf ("Color Match.  Color number = %i\n",clr);
-    } else {
-      printf ("Color Matching Error.  Color number = %i\n",clr);
-    }
-  } else {
-    printf ("Color Map Allocation Error.  Color number = %i\n",clr);
-  }
-  if (cused[clr] == 0 || cmach[clr] == 1) {
-    return 0;
-  } 
-  return(1);
+gaint gxdacol (gaint clr, gaint red, gaint green, gaint blue, gaint alpha) { 
+  /* define a new color -- this is a no-op for cairo */
+  return(0);
 }
 
-gaint gxbcol (XStandardColormap* best, XColor * cell) {
-  XColor color, colors[256];
-  unsigned long bestpixel=0;
-  gaint d, i;
-  gaint min;
- 
-  for (i=0; i<256; i++) {
-    colors[i].pixel = i; 
-  }
-
-  XQueryColors(display, cmap, colors, 256);
-
-  min = 65536;
-
-  for (i=0; i<256; i++) {
-    d = abs(cell->red - colors[i].red)
-      + abs(cell->green - colors[i].green) 
-      + abs(cell->blue - colors[i].blue);
-    if (d<min) { min = d;  bestpixel = i; }
-  }
-
-  if (bestpixel < 256) {
-
-    cell->pixel = bestpixel; 
-    color.pixel = bestpixel; 
-    XQueryColor(display, cmap, &color);
-    return 1;
-
-  } else {
-    return 0;
-  }	
-
+void gxdcol (gaint clr) {                    /* set color to new value */
+  gxCcol(clr);
 }
 
-void gxdwid (gaint wid){                 /* Set width     */
-gauint lw;
-  lwidth=wid;
-  if (wchose) return;
-  lw = 0;
-  if (lwidth>5) lw=2;
-  if (lwidth>11) lw=3;
-  if (lw != owidth) {
-    XSetLineAttributes(display, gc, lw, LineSolid,
-                     CapButt, JoinBevel);
-  }
-  owidth = lw;
+void gxdwid (gaint wid){                     /* Set line width */
+  gxCwid(wid);
 }
 
 void gxdmov (gadouble x, gadouble y){        /* Move to x,y   */
-  xxx = (gaint)(x*xscl+0.5);
-  yyy = height - (gaint)(y*yscl+0.5);
+  gxCmov(x,y);
 }
 
-void gxddrw (gadouble x, gadouble y){        /* Draw to x,y   */
-gaint i, j;
-gaint w,h;
-  i = (gaint)(x*xscl+0.5);
-  j = height - (gaint)(y*yscl+0.5);
-  XDrawLine (display, drwbl, gc, xxx, yyy, i, j);
-  if (wchose && lwidth>5) {
-    w = xxx - i;
-    if (w<0) w = -1*w;
-    h = yyy-j;
-    if (h<0) h = -1*h;
-    if (w<h) {
-      XDrawLine (display, drwbl, gc, xxx-1, yyy, i-1, j);
-      if (lwidth>11) XDrawLine (display, drwbl, gc, xxx+1, yyy, i+1, j);
-    } else {
-      XDrawLine (display, drwbl, gc, xxx, yyy-1, i, j-1);
-      if (lwidth>11) XDrawLine (display, drwbl, gc, xxx, yyy+1, i, j+1);
-    }
-  }
-  xxx = i;
-  yyy = j;
+void gxddrw (gadouble x, gadouble y) {       /* Draw to x,y */
+  gxCdrw (x,y);
   if (QLength(display)&&rstate) gxdeve(0);
 }
 
-void gxdrec (gadouble x1, gadouble x2, gadouble y1, gadouble y2) {
-gaint i1,i2,j1,j2;
-
-  i1 = (gaint)(x1*xscl+0.5);
-  j1 = height - (gaint)(y1*yscl+0.5);
-  i2 = (gaint)(x2*xscl+0.5);
-  j2 = height - (gaint)(y2*yscl+0.5);
-  if (i1!=i2 && j1!=j2) {
-    XFillRectangle (display, drwbl, gc, i1, j2, i2-i1, j1-j2);
-  } else {
-    XDrawLine (display, drwbl, gc, i1, j1, i2, j2);
-  }
+void gxdrec (gadouble x1, gadouble x2, gadouble y1, gadouble y2) {   /* draw a filled rectangle */
+  gxCrec(x1,x2,y1,y2);
   if (QLength(display)&&rstate) gxdeve(0);
 }
-
-void gxdsgl (void) {
-gaint i;
-  if (dblmode) {
-    gxrswd(1);
-    for (i=0; i<512; i++) { obj[i].type=-1; obj2[i].type = -1;}
-    obnum = 0;  obnum2 = 0;
-    XFreePixmap (display, pmap);
-    drwbl = win;
-  }
-  dblmode = 0;
+ 
+void gxddbl (void) {                         /* turn on double buffer mode */
+  XSync(display, 0);
+  gxCfrm();  /* clear the foreground */
+  /* create a new background surface, set it to be the current drawable */
+  surface2 = cairo_surface_create_similar (surface, CAIRO_CONTENT_COLOR_ALPHA, width, height);
+  cairo_xlib_surface_set_drawable(surface2,drwbl,width,height);
+  gxCsfc(surface2);   /* set the cairo graphics context to the new background surface */
+  drwbl2 = cairo_xlib_surface_get_drawable(surface2); 
+  drwbl = drwbl2;
+  gxCfrm();  /* clear the new background surface */
+  dblmode = 1; 
   return;
 }
 
-void gxddbl (void) {
-gaint i;
-  pmap = XCreatePixmap (display, win, width, height, depth);
-  XSync(display, 0) ; /* hoop */
-  if (pmap==(Pixmap)NULL) {
-    printf ("Error allocating pixmap for animation mode\n");
-    printf ("Animation mode will not be enabled\n");
-    return;
-  }
-  dblmode = 1;
-  drwbl = pmap;
-  XSetForeground(display, gc, cvals[devbck]);
-  XFillRectangle (display, drwbl, gc, 0, 0, width, height);
-  XSetForeground(display, gc, cvals[lcolor]);
-  gxrswd(1);  /* Reset all widgets */
-  for (i=0; i<512; i++) { obj[i].type=-1; obj2[i].type = -1;}
-  obnum = 0;  obnum2 = 0;
+void gxdswp (void) {                        /* swap command -- copy backgroud to the foreground */
+  if (dblmode) {
+     /* this will draw the background (surface2) onto the foreground (surface) and
+	reset the cairo context to the background surface  */
+    gxCswp(surface,surface2);
+    gxCfrm();     /* clear the background */
+   }
   return;
 }
 
-void dump_back_buffer(filename) 
-    char *filename ; 
-{ 
-    FILE *xwdfile ; 
-
-    if (dblmode) { 
-        set_display_screen(display, snum) ; 
-        xwdfile = fopen(filename, "w") ; 
-	if (!xwdfile) { 
-	    fprintf(stderr, "Couldn't open outxwd argument for writing.\n") ; 
-	    return ; 
-	} 
-        fflush(stderr) ; 
-	Window_Dump(win, xwdfile) ; 
-	Pixmap_Dump(pmap, xwdfile, 0, 0, width, height) ; 
-	fclose(xwdfile) ; 
-    } 
-} 
-
-void dump_front_buffer(filename) 
-    char *filename ; 
-{ 
-    FILE *xwdfile ; 
-
-    set_display_screen(display, snum) ; 
-    xwdfile = fopen(filename, "w") ; 
-    if (!xwdfile) { 
-        fprintf(stderr, "Couldn't open outxwd argument for writing.\n") ; 
-	return ; 
-    } 
-    fflush(stderr) ; 
-    Window_Dump(win, xwdfile) ; 
-    Pixmap_Dump(win, xwdfile, 0, 0, width, height) ; 
-    fclose(xwdfile) ; 
-} 
-
-void gxdswp (void) {
+void gxdsgl (void) {                         /* turn off double buffer mode */
   if (dblmode) {
-    XCopyArea (display, pmap, win, gc, 0, 0, width, height, 0, 0);
+    /* destroy the background surface */
+     cairo_surface_destroy(surface2);
+     /* set the window as the current drawable */
+     drwbl = win;
+     cairo_xlib_surface_set_drawable(surface,drwbl,width,height);
+     gxCsfc(surface);   /* this will set the cairo graphics context to the foreground surface */
   }
-  XSetForeground(display, gc, cvals[devbck]);
-  XFillRectangle (display, drwbl, gc, 0, 0, width, height);
-  XSetForeground(display, gc, cvals[lcolor]);
-  gxrswd(0);
-  gxcpwd();
-  gxrswd(2);
+  dblmode = 0;
   return;
 }
 
-void gxdfil (gadouble *xy, gaint n) {
-gadouble *pt;
-gaint i;
-XPoint *pnt;
-
-  point = (XPoint *)malloc(sizeof(XPoint)*n);
-  if (point==NULL) {
-    printf ("Error in polygon fill routine gxdfil: \n");
-    printf ("   Unable to allocate enough memory for the request\n");
-    return;
-  }
-  pnt = point;
-  pt = xy;
-  for (i=0; i<n; i++) {
-    pnt->x = (gaint)(*pt*xscl+0.5);
-    pnt->y = height - (gaint)(*(pt+1)*yscl+0.5);
-    pt+=2;
-    pnt++;
-  }
-  XFillPolygon (display, drwbl, gc, point, n, Nonconvex, CoordModeOrigin);
-  free (point);
+void gxdfil (gadouble *xy, gaint n) {        /* draw a filled polygon */
+  gxCfil (xy,n);
   if (QLength(display)&&rstate) gxdeve(0);
-  return;
 }
 
-void gxdxsz (gaint xx, gaint yy) {
+void gxdxsz (gaint xx, gaint yy) {           /* resize the X window */
   if (batch) return;
+  if (xx==width && yy==height) return;
   XResizeWindow (display, win, xx, yy);
   gxdeve(2);
 }
 
-/* set hardware background color */
+void gxdrdw (void) {                        /* Redraw when user resizes window */
+  rstate = 0;
+  cairo_xlib_surface_set_size(surface, width, height);
+  gxCrsiz (width, height);
+  gxhdrw(0,0);
+  rstate = 1;
+}
+
+/* no widgets -- all routines are no-ops */
 
-void gxdbck (gaint flg) {
 
-  devbck = flg;
-  if (devbck>1) devbck = 1;
+/* button widget */
+void gxdpbn (gaint bnum, struct gbtn *pbn, gaint redraw, gaint btnrel, gaint nstat) { 
 }
 
-gaint gxdbkq  (void) {
-   return (devbck);
+/* drop menu */
+void gxdrmu (gaint mnum, struct gdmu *pmu, gaint redraw, gaint nstat) { 
 }
 
-/* Routine to display a button widget */
-/* Flags are cumbersome, sigh....
-      redraw -- indicates the button is being redrawn, probably
-                due to a resize event.  When set, the assumption
-                is that *pbn is NULL and is ignored
-      btnrel -- indicates the button is being redrawn in a new state
-                due to a buttonpress/buttonrelease event.
-      nstat  -- forces the state to go to this new setting.
-                Used for 'redraw button' command.  */
-
-void gxdpbn (gaint bnum, struct gbtn *pbn, gaint redraw, gaint btnrel, gaint nstat) {
-gaint i, j, w, h, ilo, ihi, jlo, jhi, ccc, len;
-struct gbtn *gbb;
-struct gobj *pob=NULL;
-  if (bnum<0 || bnum>255) return;
-  if (dblmode) {
-    gbb = &(btn2[bnum]);
-    if (btnrel) {
-      drwbl = win;
-      gbb = &(btn[bnum]);
-    }
-  } else gbb = &(btn[bnum]);
-  if (!redraw) {
-    *gbb = *pbn;
-    gbb->num = bnum;
-  }
-  if (!redraw || rstate==0) {
-    if (dblmode) {
-      if (obnum2>511) {
-        printf ("Error: Too many widgets on screen\n");
-        return;
-      }
-    } else {
-      if (obnum>511) {
-        printf ("Error: Too many widgets on screen\n");
-        return;
-      }
-    }
-    if (dblmode) {pob = &(obj2[obnum2]); obnum2++;}
-    else {pob = &(obj[obnum]); obnum++;}
-  }
-  if (gbb->num<0) return;
-  if (nstat>-1) gbb->state = nstat;
-  if (redraw>1) {
-    if (pbn->ch) {
-      if (gbb->ch) gree(gbb->ch,"f500");
-      gbb->ch = pbn->ch;
-      gbb->len = pbn->len;
-    }
-    if (redraw==3) {
-      gbb->fc = pbn->fc; gbb->bc = pbn->bc;
-      gbb->oc1 = pbn->oc1; gbb->oc2 = pbn->oc2;
-      gbb->ftc = pbn->ftc; gbb->btc = pbn->btc;
-      gbb->otc1 = pbn->otc1; gbb->otc2 = pbn->otc2;
-    }
-  }
-  i = (gaint)(gbb->x*xscl+0.5);
-  j = height - (gaint)(gbb->y*yscl+0.5);
-  w = (gaint)(gbb->w*xscl+0.5);
-  h = (gaint)(gbb->h*yscl+0.5);
-  w = w - 2;
-  h = h - 2;
-  gbb->ilo = 1 + i - w/2;
-  gbb->jlo = 1 + j - h/2;
-  gbb->ihi = gbb->ilo + w;
-  gbb->jhi = gbb->jlo + h;
-  ilo = gbb->ilo;  ihi = gbb->ihi;
-  jlo = gbb->jlo;  jhi = gbb->jhi;
-  if (gbb->state) ccc = gbb->btc;
-  else ccc = gbb->bc;
-  if (ccc>-1) {
-    gxdcol(ccc);
-    XFillRectangle (display, drwbl, gc, gbb->ilo, gbb->jlo, w, h);
-  }
-  gxdwid(gbb->thk);
-  if (gbb->state) ccc = gbb->otc1;
-  else ccc = gbb->oc1;
-  if (ccc>-1) {
-    gxdcol(ccc);
-    XDrawLine (display, drwbl, gc, ilo, jhi, ihi, jhi);
-    XDrawLine (display, drwbl, gc, ihi, jhi, ihi, jlo);
-  }
-  if (gbb->state) ccc = gbb->otc2;
-  else ccc = gbb->oc2;
-  if (ccc>-1) {
-    gxdcol(ccc);
-    XDrawLine (display, drwbl, gc, ihi, jlo, ilo, jlo);
-    XDrawLine (display, drwbl, gc, ilo, jlo, ilo, jhi);
-  }
-  if (gbb->state) ccc = gbb->ftc;
-  else ccc = gbb->fc;
-  if (ccc>-1) {
-    len = 0;
-    while (*(gbb->ch+len)) len++;
-/*    len++;*/
-    gxdcol(ccc);
-    if (gfont==1 && font1) {
-      XSetFont (display, gc, font1->fid);
-      w = XTextWidth(font1, gbb->ch, len);
-      i = i - w/2;
-      j = j + 5*font1->ascent/9;
-    }
-    if (gfont==2 && font2) {
-      XSetFont (display, gc, font2->fid);
-      w = XTextWidth(font2, gbb->ch, len);
-      i = i - w/2;
-      j = j + 5*font2->ascent/9;
-    }
-    if (gfont==3 && font3) {
-      XSetFont (display, gc, font3->fid);
-      w = XTextWidth(font3, gbb->ch, len);
-      i = i - w/2;
-      j = j + 5*font3->ascent/9;
-    }
-    XDrawString(display, drwbl, gc, i, j, gbb->ch, len);
-  }
-  gxdcol(lcolor);
-  if (dblmode && btnrel) drwbl = pmap;
-  if (!redraw || rstate==0) {
-    pob->type = 1;
-    pob->mb = -1;
-    pob->i1 = ilo;  pob->i2 = ihi;
-    pob->j1 = jlo;  pob->j2 = jhi;
-    pob->iob.btn = gbb;
-  }
-  XFlush(display);
+/* rubber-band region */
+void gxdrbb (gaint num, gaint type, gadouble xlo, gadouble ylo, gadouble xhi, gadouble yhi, gaint mbc) {
 }
 
-/* Routine to display a drop menu widget:
-      redraw -- indicates the button is being redrawn, probably
-                due to a resize event.  When set, the assumption
-                is that *dmu is NULL and is ignored; info for
-                redrawing is obtained from the existing
-                structure list.
-      nstat  -- re-defines the dropmenu.
-                Used for 'redraw dropmenu' command.  */
-
-void gxdrmu (gaint mnum, struct gdmu *pmu, gaint redraw, gaint nstat) {
-gaint i, j, w, h, ilo, ihi, jlo, jhi, len, lw;
-struct gdmu *gmu;
-struct gobj *pob=NULL;
-
-  if (mnum<0 || mnum>199) return;
-  if (dblmode) gmu = &(dmu2[mnum]);
-  else gmu = &(dmu[mnum]);
-  if (!redraw) {
-    *gmu = *pmu;
-    gmu->num = mnum;
-  }
-  if (gmu->num<0) return;
-  if (gmu->casc) return;
-  if (!redraw || rstate==0) {
-    if (dblmode) {
-      if (obnum2>511) {
-        printf ("Error: Too many widgets on screen\n");
-        return;
-      }
-    } else {
-      if (obnum>511) {
-        printf ("Error: Too many widgets on screen\n");
-        return;
-      }
-    }
-    if (dblmode) {pob = &(obj2[obnum2]); obnum2++;}
-    else {pob = &(obj[obnum]); obnum++;}
-  }
-  i = (gaint)(gmu->x*xscl+0.5);
-  j = height - (gaint)(gmu->y*yscl+0.5);
-  w = (gaint)(gmu->w*xscl+0.5);
-  h = (gaint)(gmu->h*yscl+0.5);
-  w = w - 2;
-  h = h - 2;
-  gmu->ilo = 1 + i - w/2;
-  gmu->jlo = 1 + j - h/2;
-  gmu->ihi = gmu->ilo + w;
-  gmu->jhi = gmu->jlo + h;
-  ilo = gmu->ilo;  ihi = gmu->ihi;
-  jlo = gmu->jlo;  jhi = gmu->jhi;
-  if (gmu->bc>-1) {
-    gxdcol(gmu->bc);
-    XFillRectangle (display, drwbl, gc, ilo, jlo, w+1, h+1);
-  }
-  lw = 1;
-  if (gmu->thk>5) lw = 2;
-  if (gmu->thk>12) lw = 3;
-  gxdwid(1);
-  if (gmu->oc1>-1) {
-    gxdcol(gmu->oc1);
-    XDrawLine (display, drwbl, gc, ilo, jhi, ihi, jhi);
-    if (lw>1) XDrawLine (display, drwbl, gc, ilo+1, jhi-1, ihi-1, jhi-1);
-    if (lw>2) XDrawLine (display, drwbl, gc, ilo+2, jhi-2, ihi-2, jhi-2);
-    XDrawLine (display, drwbl, gc, ihi, jhi, ihi, jlo);
-    if (lw>1) XDrawLine (display, drwbl, gc, ihi-1, jhi-1, ihi-1, jlo+1);
-    if (lw>2) XDrawLine (display, drwbl, gc, ihi-2, jhi-2, ihi-2, jlo+2);
-  }
-  if (gmu->oc2>-1) {
-    gxdcol(gmu->oc2);
-    XDrawLine (display, drwbl, gc, ihi, jlo, ilo, jlo);
-    if (lw>1) XDrawLine (display, drwbl, gc, ihi-1, jlo+1, ilo+1, jlo+1);
-    if (lw>2) XDrawLine (display, drwbl, gc, ihi-2, jlo+2, ilo+2, jlo+2);
-    XDrawLine (display, drwbl, gc, ilo, jlo, ilo, jhi);
-    if (lw>1) XDrawLine (display, drwbl, gc, ilo+1, jlo+1, ilo+1, jhi-1);
-    if (lw>2) XDrawLine (display, drwbl, gc, ilo+2, jlo+2, ilo+2, jhi-2);
-  }
-  if (gmu->fc>-1) {
-    len = 0;
-    while (*(gmu->ch+len)) len++;
-/*    len++;*/
-    gxdcol(gmu->fc);
-    if (gfont==1 && font1i) {
-      XSetFont (display, gc, font1i->fid);
-      w = XTextWidth(font1i, gmu->ch, len);
-      i = ilo + font1i->ascent/2;
-      j = j + 5*font1i->ascent/9;
-    }
-    if (gfont==2 && font2i) {
-      XSetFont (display, gc, font2i->fid);
-      w = XTextWidth(font2i, gmu->ch, len);
-      i = ilo + font2i->ascent/2;
-      j = j + 5*font2i->ascent/9;
-    }
-    if (gfont==3 && font3i) {
-      XSetFont (display, gc, font3i->fid);
-      w = XTextWidth(font3i, gmu->ch, len);
-      i = ilo + font3i->ascent/2;
-      j = j + 5*font3i->ascent/9;
-    }
-    XDrawString(display, drwbl, gc, i, j, gmu->ch, len);
-    if (gfont==1 && font1) XSetFont (display, gc, font1->fid);
-    if (gfont==2 && font2) XSetFont (display, gc, font2->fid);
-    if (gfont==3 && font3) XSetFont (display, gc, font3->fid);
-  }
-  gxdcol(lcolor);
-  if (!redraw || rstate==0) {
-    pob->type = 3;
-    pob->mb = -1;
-    pob->i1 = ilo;  pob->i2 = ihi;
-    pob->j1 = jlo;  pob->j2 = jhi;
-    pob->iob.dmu = gmu;
-  }
-  XFlush(display);
+/* Dialog box */
+char *gxdlg (struct gdlg *qry) {
+  return (NULL);
 }
 
-/* Select font based on screen size */
-
-void gxdsfn(void) {
-
-  if (width<601 || height<421) {
-    if (gfont!=1) {
-      if (font1) XSetFont (display, gc, font1->fid);
-      gfont = 1;
-    }
-  } else if (width<1001 || height<651) {
-    if (gfont!=2) {
-      if (font2) XSetFont (display, gc, font2->fid);
-      gfont = 2;
-    }
-  } else {
-    if (gfont!=3) {
-      if (font3) XSetFont (display, gc, font3->fid);
-      gfont = 3;
-    }
-  }
+/* Reset a widget */
+void gxrs1wd (int wdtyp, int wdnum) {
 }
 
+/* Screen save and show operations, also no-ops */
+void gxdssv (int frame) {
+}
+void gxdssh (int cnt) {
+}
+void gxdsfr (int frame) {
+}
 
-/* Attempt to redraw when user resizes window */
+/* Routine to install stipple pixmaps, a no-op */
 
-void gxdrdw (void) {
-int i;
-  rstate = 0;
-  XSetForeground(display, gc, cvals[devbck]);
-  XFillRectangle (display, drwbl, gc, 0, 0, width, height);
-  XSetForeground(display, gc, cvals[lcolor]);
-  for (i=0; i<512; i++) obj[i].type = -1;
-  obnum = 0;
-  if (dblmode) {
-    dblmode = 0;
-    XFreePixmap (display, pmap);
-    pmap = XCreatePixmap (display, win, width, height, depth);
-    if (pmap==(Pixmap)NULL) {
-      printf ("Error allocating pixmap for resize operation\n");
-      printf ("Animation mode will be disabled\n");
-      dblmode = 0;
-      drwbl = win;
-      rstate = 1;
-      return;
-    }
-    drwbl = win;
-    XSetForeground(display, gc, cvals[devbck]);
-    XFillRectangle (display, drwbl, gc, 0, 0, width, height);
-    XFillRectangle (display, pmap, gc, 0, 0, width, height);
-    XSetForeground(display, gc, cvals[lcolor]);
-    for (i=0; i<512; i++) obj2[i].type = -1;
-    obnum2 = 0;
-    gxhdrw(1);
-    gxrdrw(1);
-    dblmode = 1;
-    drwbl = pmap;
-  }
-  gxhdrw(0);
-  gxrdrw(0);
-  rstate = 1;
+void gxdptn (int typ, int den, int ang) {
 }
 
-/* Redraw all widgets.  Flag indicates whether to redraw
-   foreground or background widgets. */
+void dump_back_buffer(char *filename) { 
+} 
 
-void gxrdrw (int flag) {
-int i;
-  if (flag) {
-    for (i=0; i<256; i++) {
-      if (btn2[i].num>-1) gxdpbn(i, NULL, 1, 0, -1);
-    }
-    for (i=0; i<32; i++) {
-      if (rbb2[i].num>-1) gxdrbb(i, rbb2[i].type,
-            rbb2[i].xlo,rbb2[i].ylo,rbb2[i].xhi,rbb2[i].yhi,rbb2[i].mb);
-    }
-    for (i=0; i<200; i++) {
-      if (dmu2[i].num>-1) gxdrmu(i, NULL, 1, -1);
-    }
-  } else {
-    for (i=0; i<256; i++) {
-      if (btn[i].num>-1) gxdpbn(i, NULL, 1, 0, -1);
-    }
-    for (i=0; i<32; i++) {
-      if (rbb[i].num>-1) gxdrbb(i, rbb[i].type,
-            rbb[i].xlo,rbb[i].ylo,rbb[i].xhi,rbb[i].yhi,rbb[i].mb);
-    }
-    for (i=0; i<200; i++) {
-      if (dmu[i].num>-1) gxdrmu(i, NULL, 1, -1);
-    }
-  }
-}
+void dump_front_buffer(char *filename)  {
+} 
 
-/* Reset all widgets; release memory as appropriate. */
-/* flag = 0 resets foreground, flag = 1 resets both,
-   flag = 2 resets background only; for after swapping */
+/* Invokes usage of software to generate wide lines (vs Xserver) */
+void gxwdln (void) {
+}
 
-void gxrswd(int flag) {
-int i;
+int win_data (struct xinfo *xinf) {
+  int absx, absy;
+  Window dummy;
+  XWindowAttributes result;
 
-  if (flag!=2) {
-    for (i=0; i<256; i++) {
-      if (btn[i].num>-1 && btn[i].ch!=NULL) gree(btn[i].ch,"f501");
-      btn[i].num = -1;
-      btn[i].ch = NULL;
-    }
-    for (i=0; i<200; i++) {
-      if (dmu[i].num>-1 && dmu[i].ch!=NULL) gree(dmu[i].ch,"f502");
-      dmu[i].num = -1;
-      dmu[i].ch = NULL;
-    }
-    for (i=0; i<32; i++) rbb[i].num = -1;
-  }
+  if (batch) return (0);
+  if (display == (Display *) NULL || win == (Window) NULL) return 0;
+  if (!XGetWindowAttributes (display, win, &result) ) return 0;
+  if (!XTranslateCoordinates (display, win, RootWindow (display, snum), 0, 0,
+			      &absx, &absy, &dummy) ) return 0;
+  xinf->winid=(int)win;
+  xinf->winw=result.width;  
+  xinf->winh=result.height;  
+  xinf->winb=result.border_width;
+  xinf->winx=absx;  
+  xinf->winy=absy;  
+  return 1;
+}
+ 
+/* Given x,y page location, return screen pixel location */
 
-  if (flag) {
-    for (i=0; i<256; i++) {
-      if (flag!=2) {
-        if (btn2[i].num>-1 && btn2[i].ch!=NULL) gree(btn2[i].ch,"f503");
-      }
-      btn2[i].num = -1;
-      btn2[i].ch = NULL;
-    }
-    for (i=0; i<200; i++) {
-      if (flag!=2) {
-        if (dmu2[i].num>-1 && dmu2[i].ch!=NULL) gree(dmu2[i].ch,"f504");
-      }
-      dmu2[i].num = -1;
-      dmu2[i].ch = NULL;
-    }
-    for (i=0; i<32; i++) rbb2[i].num = -1;
+void gxdgcoord (gadouble x, gadouble y, gaint *i, gaint *j) {
+  if (batch) {
+    *i = -999;
+    *j = -999;
+    return;
   }
+  *i = (gaint)(x*xscl+0.5);
+  *j = height - (gaint)(y*yscl+0.5);
 }
 
+void gxdimg(gaint *im, gaint imin, gaint jmin, gaint isiz, gaint jsiz) {
+  /* JMA gxout imap is a no-op in this build */
+}
 
-/* Copy all widgets during swap in double buffer mode */
+/* Get the x bearing (width) used to plot a character */
 
-void gxcpwd(void) {
-struct grbb *grb;
-struct gbtn *gbn;
-struct gdmu *gmu;
-int i;
+gadouble gxdqchl (char ch, gaint fn, gadouble w) {
+  return (gxCqchl(ch,fn,w)); 
+}
 
-  for (i=0; i<256; i++) {
-    if (btn2[i].num>-1) btn[i] = btn2[i];
-  }
+/* Plot a character */
+gadouble gxdch (char ch, gaint fn, gadouble x, gadouble y, gadouble w, gadouble h, gadouble rot) {
+gadouble xadv;
 
-  for (i=0; i<200; i++) {
-    if (dmu2[i].num>-1) dmu[i] = dmu2[i];
-  }
 
-  for (i=0; i<32; i++) {
-    if (rbb2[i].num>-1) rbb[i] = rbb2[i];
-  }
+  xadv = gxCch(ch,fn,x,y,w,h,rot);   /* draw character with Cairo, width of character returned */
+  if (QLength(display)&&rstate) gxdeve(0);
+  return (xadv);
+}
 
-  /* Rebuild list of currently displayed items */
-
-  for (i=0; i<512; i++) obj[i].type = -1;
-  obnum = obnum2;
-  for (i=0; i<obnum; i++) {
-    obj[i] = obj2[i];
-    if (obj[i].type==1) {
-      gbn = obj[i].iob.btn;
-      obj[i].iob.btn = &(btn[gbn->num]);
-    } else if (obj[i].type==2) {
-      grb = obj[i].iob.rbb;
-      obj[i].iob.rbb = &(rbb[grb->num]);
-    } else if (obj[i].type==3) {
-      gmu = obj[i].iob.dmu;
-      obj[i].iob.dmu = &(dmu[gmu->num]);
-    }
-  }
-  for (i=0; i<512; i++) obj2[i].type = -1;
-  obnum2 = 0;
+/* Flush pending graphics; called from gxC and gxX */
+void gxdXflush (void) {
+  XFlush(display);
 }
 
-/* Reset a particular widget, given widget type and number */
-/* Assumes arrays are used for holding all the widget info */
+/* Allows higher levels to indicate various options, conditions, etc. to the
+   hardware rendering layer.  */
+/* opt = 4:  major finish point; complete any ongoing graphics rendering */
 
-void gxrs1wd (int wdtyp, int wdnum) {
-struct grbb *grb;
-struct gbtn *gbn;
-struct gdmu *gmu;
-int ii,jj=0;
-
-  if (wdtyp<1 || wdtyp>3) return;
-  if (wdtyp==1 && (wdnum<0 || wdnum>255)) return;
-  if (wdtyp==2 && (wdnum<0 || wdnum>31)) return;
-  if (wdtyp==3 && (wdnum<0 || wdnum>199)) return;
-
-  /* Remove this widget from the list of displayed items */
-
-  ii = 0;
-  while (ii<512 && obj[ii].type>-1) {
-    if (obj[ii].type!=0 && obj[ii].type==wdtyp) {
-      if (obj[ii].type==1) {
-        gbn = obj[ii].iob.btn;
-        jj = gbn->num;
-      } else if (obj[ii].type==2) {
-        grb = obj[ii].iob.rbb;
-        jj = grb->num;
-      } else if (obj[ii].type==3) {
-        gmu = obj[ii].iob.dmu;
-        jj = gmu->num;
-      }
-      if (jj==wdnum) {
-        obj[ii].type = 0;   /* This should be enough to cause this */
-                            /* widget to be ignored. */
-        ii = 100000;   /* Exit loop */
-      }
-    }
-    ii++;
-  }
+void gxdopt (gaint opt) {
+  if (opt==4) gxCflush(1);
+}
 
-  /* Remove this widget from the widget array */
+void gxsetpatt (gaint pnum) {
+  gxCpattrset(pnum);   
+}
 
-  if (wdtyp==1) {
-    if (btn[wdnum].num>-1 && btn[wdnum].num != wdnum)  {
-       printf ("Logic Error 64 in gxrs1wd\n");
-    }
-    if (btn[wdnum].num>-1 && btn[wdnum].ch!=NULL) gree(btn[wdnum].ch,"f505");
-    btn[wdnum].num = -1;
-    btn[wdnum].ch = NULL;
-  } else if (wdtyp==2) {
-    if (rbb[wdnum].num>-1 && rbb[wdnum].num != wdnum) {
-       printf ("Logic Error 65 in gxrs1wd\n");
-    }
-    rbb[wdnum].num = -1;
-  } else if (wdtyp==3) {
-    if (dmu[wdnum].num>-1 && dmu[wdnum].num != wdnum) {
-       printf ("Logic Error 65 in gxrs1wd\n");
-    }
-    if (dmu[wdnum].num>-1 && dmu[wdnum].ch!=NULL) gree(dmu[wdnum].ch,"f506");
-    dmu[wdnum].num = -1;
-    dmu[wdnum].ch = NULL;
-  }
+void gxdsignal (gaint sig) {
+  if (sig==1) gxCflush(1);   /* finish rendering */
+  if (sig==2) gxCaa(0);      /* disable anti-aliasing */
+  if (sig==3) gxCaa(1);      /* enable anti-aliasing */
+  if (sig==4) gxCpush();     /* push */
+  if (sig==5) gxCpop();      /* pop */
 }
 
+void gxdclip (gadouble xlo, gadouble xhi, gadouble ylo, gadouble yhi) {
+  gxCclip (xlo,xhi,ylo,yhi);
+}
 
-/* Click ocurred over a button object. */
-
-void gxevbn(struct gevent *geve, int iobj) {
-struct gbtn *gbn;
-int jj,c1,c2,i1,i2,j1,j2;
-
-  /* Fill in button specific event info */
-
-  geve->type = 1;
-  gbn = obj[iobj].iob.btn;
-  geve->info[0] = gbn->num;
-
-  jj = gbn->num;
-  if (btn[jj].state) {
-    c1=btn[jj].otc1; c2=btn[jj].otc2;
-    geve->info[1] = 0;
-  } else {
-    c1=btn[jj].oc1; c2=btn[jj].oc2;
-    geve->info[1] = 1;
-  }
-
-  /* Redraw button outline as pressed, if appropriate
-     (ie, if the outline colors are different) */
-
-  i1=btn[jj].ilo; i2=btn[jj].ihi;
-  j1=btn[jj].jlo; j2=btn[jj].jhi;
-  if ( !(btn[jj].state && btn[jj].oc1==btn[jj].otc2 &&
-         btn[jj].oc2==btn[jj].otc1)) {
-    if (c2>-1 && c1>-1) {
-      gxdwid(btn[jj].thk);
-      gxdcol(c2);
-      XDrawLine (display, win, gc, i1, j2, i2, j2);
-      XDrawLine (display, win, gc, i2, j2, i2, j1);
-      gxdcol(c1);
-      XDrawLine (display, win, gc, i2, j1, i1, j1);
-      XDrawLine (display, win, gc, i1, j1, i1, j2);
-      XFlush(display);
-    }
-  }
-
-  /* Wait for button release, and do final redraw
-     of button with new state. */
-
-  while (1) {
-    XMaskEvent(display, ButtonReleaseMask | ButtonMotionMask, &report);
-    if (report.type == ButtonRelease) break;
-  }
-
-  if (btn[jj].state) btn[jj].state=0;
-  else btn[jj].state=1;
-  gxdpbn (jj, NULL, 1, 1, -1);
-  XFlush(display);
-}
-
-/* Click ocurred in a rubber-banded region.  */
-
-void gxevrb(struct gevent *geve, int iobj, int i, int j) {
-struct grbb *grb;
-int i1,i2,j1,j2,i1o,j1o,i2o,j2o,xoflg,typ;
-int ilo,ihi,jlo,jhi;
-
-  i1o = i2o = j1o = j2o = 0;
-  /* Get rest of event info */
-  geve->type = 2;
-  grb = obj[iobj].iob.rbb;
-  geve->info[0] = grb->num;
-  typ = grb->type;
-  ilo = obj[iobj].i1;  ihi = obj[iobj].i2;
-  jlo = obj[iobj].j1;  jhi = obj[iobj].j2;
-
-  /* Set foreground color to something that will show up when Xor'd */
-
-  XSetForeground(display, gc, cvals[0]^cvals[1]);
-  XSetFunction(display, gc, GXxor);
-
-  /* Loop on button motion, waiting for button release */
-
-  xoflg = 0;
-  while (1) {
-    XMaskEvent(display, ButtonReleaseMask|ButtonMotionMask, &report);
-    if (report.type==MotionNotify) {
-      if (xoflg) {
-        if (typ==1)
-           XDrawRectangle(display, win, gc, i1o, j1o, i2o-i1o, j2o-j1o);
-        else XDrawLine (display, win, gc, i1o, j1o, i2o, j2o);
-      }
-      if (i<report.xmotion.x) { i1 = i; i2 = report.xmotion.x; }
-      else { i2 = i; i1 = report.xmotion.x; }
-      if (j<report.xmotion.y) { j1 = j; j2 = report.xmotion.y; }
-      else { j2 = j; j1 = report.xmotion.y; }
-      if (i1<ilo) i1 = ilo; if (i2>ihi) i2 = ihi;
-      if (j1<jlo) j1 = jlo; if (j2>jhi) j2 = jhi;
-      if (typ==1) XDrawRectangle (display, win, gc, i1, j1, i2-i1, j2-j1);
-      else XDrawLine (display, win, gc, i1, j1, i2, j2);
-      i1o=i1; i2o=i2; j1o=j1; j2o=j2; xoflg = 1;
-    } else break;
-  }
-  if (xoflg) {
-    if (typ==1)
-       XDrawRectangle(display, win, gc, i1o, j1o, i2o-i1o, j2o-j1o);
-    else XDrawLine (display, win, gc, i1o, j1o, i2o, j2o);
-  }
-  XSetForeground(display, gc, cvals[lcolor]);
-  XSetFunction(display, gc, GXcopy);
-  XFlush(display);
-  i1 = report.xbutton.x; j1 = report.xbutton.y;
-  if (i1<ilo) i1 = ilo; if (i1>ihi) i1 = ihi;
-  if (j1<jlo) j1 = jlo; if (j1>jhi) j1 = jhi;
-  geve->rinfo[0] = xsize*((gadouble)i1)/width;
-  geve->rinfo[1] = ysize - ysize*((gadouble)j1)/height;
-}
-
-/* Set up a rubber-band region.  */
-
-void gxdrbb (gaint num, gaint type,
-                   gadouble xlo, gadouble ylo, gadouble xhi, gadouble yhi, gaint mbc) {
-struct grbb *prb;
-struct gobj *pob;
-
-  if (num<0 || num>31) return;
-  if (xlo>=xhi) return;
-  if (ylo>=yhi) return;
-
-  if (dblmode) {
-    if (obnum2>511) return;
-    pob = &(obj2[obnum2]); obnum2++;
-    prb = &(rbb2[num]);
-  } else {
-    if (obnum>511) return;
-    pob = &(obj[obnum]); obnum++;
-    prb = &(rbb[num]);
-  }
-
-  pob->type = 2;
-  pob->mb = mbc;
-  pob->i1 = (gaint)(xlo*xscl+0.5);
-  pob->i2 = (gaint)(xhi*xscl+0.5);
-  pob->j1 = height - (gaint)(yhi*yscl+0.5);
-  pob->j2 = height - (gaint)(ylo*yscl+0.5);
-  pob->iob.rbb = prb;
-  prb->num = num;
-  prb->xlo = xlo; prb->xhi = xhi;
-  prb->ylo = ylo; prb->yhi = yhi;
-  prb->type = type;
-  prb->mb = mbc;
-}
-
-/* Handle drop menu.  Create new (temporary) window and
-   put the text in it.  Window is destroyed when the mouse
-   button is released.  */
-
-static int dmrecu,dmi1[4],dmi2[4],dmj1[4],dmj2[4],dmnum[4],dmsel[4],dmcur[4];
-
-int gxevdm(struct gevent *geve, int iobj, int ipos, int jpos) {
-struct gdmu *gmu;
-int i,j,iorig,jorig,ival,ilo,ihi,jlo,jhi,w,h,len,lw;
-
-  geve->type = 3;
-  gmu = obj[iobj].iob.dmu;
-
-  /* Redraw base using toggled colors */
-  i=0;
-  ilo = gmu->ilo; ihi = gmu->ihi;
-  jlo = gmu->jlo; jhi = gmu->jhi;
-  w = ihi - ilo;
-  h = jhi - jlo;
-  j = jlo + h/2 - 1;
-  if (gmu->tbc>-1 && gmu->tfc>-1) {
-    if (gmu->tbc>-1) {
-      gxdcol(gmu->tbc);
-      XFillRectangle (display, drwbl, gc, ilo, jlo, w+1, h+1);
-    }
-    if (gmu->tfc>-1) {
-      len = 0;
-      while (*(gmu->ch+len)) len++;
-/*    len++;*/
-      gxdcol(gmu->tfc);
-      if (gfont==1 && font1i) {
-        XSetFont (display, gc, font1i->fid);
-        w = XTextWidth(font1i, gmu->ch, len);
-        i = ilo + font1i->ascent/2;
-        j = j + 5*font1i->ascent/9;
-      }
-      if (gfont==2 && font2i) {
-        XSetFont (display, gc, font2i->fid);
-        w = XTextWidth(font2i, gmu->ch, len);
-        i = ilo + font2i->ascent/2;
-        j = j + 5*font2i->ascent/9;
-      }
-      if (gfont==3 && font3i) {
-        XSetFont (display, gc, font3i->fid);
-        w = XTextWidth(font3i, gmu->ch, len);
-        i = ilo + font3i->ascent/2;
-        j = j + 5*font3i->ascent/9;
-      }
-      XDrawString(display, drwbl, gc, i, j, gmu->ch, len);
-    }
-  }
-  gxdwid(1);
-  lw = 1;
-  if (gmu->thk>5) lw = 2;
-  if (gmu->thk>11) lw = 3;
-  if (gmu->toc1>-1) {
-    gxdcol(gmu->toc1);
-    XDrawLine (display, drwbl, gc, ilo, jhi, ihi, jhi);
-    if (lw>1) XDrawLine (display, drwbl, gc, ilo+1, jhi-1, ihi-1, jhi-1);
-    if (lw>2) XDrawLine (display, drwbl, gc, ilo+2, jhi-2, ihi-2, jhi-2);
-    XDrawLine (display, drwbl, gc, ihi, jhi, ihi, jlo);
-    if (lw>1) XDrawLine (display, drwbl, gc, ihi-1, jhi-1, ihi-1, jlo+1);
-    if (lw>2) XDrawLine (display, drwbl, gc, ihi-2, jhi-2, ihi-2, jlo+2);
-  }
-  if (gmu->toc2>-1) {
-    gxdcol(gmu->toc2);
-    XDrawLine (display, drwbl, gc, ihi, jlo, ilo, jlo);
-    if (lw>1) XDrawLine (display, drwbl, gc, ihi-1, jlo+1, ilo+1, jlo+1);
-    if (lw>2) XDrawLine (display, drwbl, gc, ihi-2, jlo+2, ilo+2, jlo+2);
-    XDrawLine (display, drwbl, gc, ilo, jlo, ilo, jhi);
-    if (lw>1) XDrawLine (display, drwbl, gc, ilo+1, jlo+1, ilo+1, jhi-1);
-    if (lw>2) XDrawLine (display, drwbl, gc, ilo+2, jlo+2, ilo+2, jhi-2);
-  }
-
-  /* Set up and display first menu */
-
-  iorig = obj[iobj].i1;
-  jorig = obj[iobj].j2;
-
-  dmrecu = -1;
-  for (i=0; i<4; i++) {
-    dmi1[i] = -1; dmi2[i] = -1; dmj1[i] = -1; dmj2[i] = -1;
-    dmnum[i] = -1; dmsel[i] = -1;
-  }
-
-  ival = gxpopdm (gmu, iobj, iorig, iorig, jorig);
-
-  /* Display base in standard colors */
-
-  gxdsfn();
-  w = ihi - ilo;
-  h = jhi - jlo;
-  j = jlo + h/2 - 1;
-  if (gmu->bc>-1 && gmu->fc>-1) {
-    if (gmu->bc>-1) {
-      gxdcol(gmu->bc);
-      XFillRectangle (display, drwbl, gc, ilo, jlo, w+1, h+1);
-    }
-    if (gmu->fc>-1) {
-      len = 0;
-      while (*(gmu->ch+len)) len++;
-/*    len++;*/
-      gxdcol(gmu->fc);
-      if (gfont==1 && font1i) {
-        XSetFont (display, gc, font1i->fid);
-        w = XTextWidth(font1i, gmu->ch, len);
-        i = ilo + font1i->ascent/2;
-        j = j + 5*font1i->ascent/9;
-      }
-      if (gfont==2 && font2i) {
-        XSetFont (display, gc, font2i->fid);
-        w = XTextWidth(font2i, gmu->ch, len);
-        i = ilo + font2i->ascent/2;
-        j = j + 5*font2i->ascent/9;
-      }
-      if (gfont==3 && font3i) {
-        XSetFont (display, gc, font3i->fid);
-        w = XTextWidth(font3i, gmu->ch, len);
-        i = ilo + font3i->ascent/2;
-        j = j + 5*font3i->ascent/9;
-      }
-      XDrawString(display, drwbl, gc, i, j, gmu->ch, len);
-    }
-  }
-  gxdwid(gmu->thk);
-  if (gmu->oc1>-1) {
-    gxdcol(gmu->oc1);
-    XDrawLine (display, drwbl, gc, ilo, jhi, ihi, jhi);
-    if (lw>1) XDrawLine (display, drwbl, gc, ilo+1, jhi-1, ihi-1, jhi-1);
-    if (lw>2) XDrawLine (display, drwbl, gc, ilo+2, jhi-2, ihi-2, jhi-2);
-    XDrawLine (display, drwbl, gc, ihi, jhi, ihi, jlo);
-    if (lw>1) XDrawLine (display, drwbl, gc, ihi-1, jhi-1, ihi-1, jlo+1);
-    if (lw>2) XDrawLine (display, drwbl, gc, ihi-2, jhi-2, ihi-2, jlo+2);
-  }
-  if (gmu->oc2>-1) {
-    gxdcol(gmu->oc2);
-    XDrawLine (display, drwbl, gc, ihi, jlo, ilo, jlo);
-    if (lw>1) XDrawLine (display, drwbl, gc, ihi-1, jlo+1, ilo+1, jlo+1);
-    if (lw>2) XDrawLine (display, drwbl, gc, ihi-2, jlo+2, ilo+2, jlo+2);
-    XDrawLine (display, drwbl, gc, ilo, jlo, ilo, jhi);
-    if (lw>1) XDrawLine (display, drwbl, gc, ilo+1, jlo+1, ilo+1, jhi-1);
-    if (lw>2) XDrawLine (display, drwbl, gc, ilo+2, jlo+2, ilo+2, jhi-2);
-  }
-  XFlush(display);
-  for (i=0; i<4; i++) if (dmsel[i]<0) dmnum[i] = -1;
-  geve->info[0] = dmnum[0];
-  geve->info[1] = dmsel[0];
-  geve->info[2] = dmnum[1];
-  geve->info[3] = dmsel[1];
-  geve->info[4] = dmnum[2];
-  geve->info[5] = dmsel[2];
-  geve->info[6] = dmnum[3];
-  geve->info[7] = dmsel[3];
-  return (ival);
-}
-
-/* pull-down menu */
-
-int gxpopdm(struct gdmu *gmu, int iobj, int porig, int iorig, int jorig) {
-int flag,i,j,cnt,len,maxw,w=0,h=0,absx,absy,enter;
-int item=0,itemold,jmin,jmax,imin,imax,isiz,jsiz,j1,j2,dmflag,ii;
-int pimin=0,pjmin=0,pisiz=0,pjsiz=0,ptrs[200],eflag,lln,cascf,ecnt,itt,itt2;
-unsigned long lw;
-char *ch,ich[5];
-Pixmap tpmap=0;
-Window pop, dummy;
-GC gcp;
-
-  dmrecu++;
-  cnt = 0;
-  ch = gmu->ch;
-  len = 0;
-  i = 0;
-  if (dmrecu==0) {
-    while (*(ch+len)) len++;
-    ch = ch+len+1;
-    i = len+1;
-  }
-  maxw = 0;
-  cascf = 0;
-  while (i<gmu->len) {
-    len = 0;
-    lln = 0;
-    ptrs[cnt] = -1;
-    eflag = 1;
-    while (*(ch+len)) {
-      if (i+len+4<gmu->len && *(ch+len)=='>' &&
-           (*(ch+len+1)>='0' && *(ch+len+1)<='9') &&
-           (*(ch+len+2)>='0' && *(ch+len+2)<='9') &&
-            *(ch+len+3)=='>') {
-        ich[0] = *(ch+len+1);
-        ich[1] = *(ch+len+2);
-        ich[2] = '\0';
-        ptrs[cnt] =  atoi(ich);
-        eflag = 0;
-        lln--;
-        cascf = 1;
-      }
-      if (i+len+5<gmu->len && *(ch+len)=='>' &&
-           (*(ch+len+1)>='0' && *(ch+len+1)<='1') &&
-           (*(ch+len+2)>='0' && *(ch+len+2)<='9') &&
-           (*(ch+len+3)>='0' && *(ch+len+3)<='9') &&
-            *(ch+len+4)=='>') {
-        ich[0] = *(ch+len+1);
-        ich[1] = *(ch+len+2);
-        ich[2] = *(ch+len+3);
-        ich[3] = '\0';
-        ptrs[cnt] =  atoi(ich);
-        eflag = 0;
-        lln--;
-        cascf = 1;
-      }
-      len++;
-      if (eflag) lln++;
-    }
-    if (gfont==1 && font1i) {
-      w = XTextWidth(font1i, ch, lln);
-      h = font1i->ascent;
-    }
-    if (gfont==2 && font2i) {
-      w = XTextWidth(font2i, ch, lln);
-      h = font2i->ascent;
-    }
-    if (gfont==3 && font3i) {
-      w = XTextWidth(font3i, ch, lln);
-      h = font3i->ascent;
-    }
-    w = w + h;
-    if (w>maxw) maxw = w;
-    ch = ch+len+1;
-    i = i+len+1;
-    cnt++;
-  }
-  if (cascf) {
-    ich[0] = 'x'; ich[1] = 'x'; ich[2] = 'x'; ich[3] = 'x';
-    if (gfont==1 && font1i) w = XTextWidth(font1i, ich, 3);
-    if (gfont==2 && font2i) w = XTextWidth(font2i, ich, 3);
-    if (gfont==3 && font3i) w = XTextWidth(font3i, ich, 3);
-    maxw = maxw + w;
-  }
-  h = h*2;
-  jsiz = h * cnt;
-  isiz = maxw;
-  imin = iorig; imax = imin + isiz;
-  jmin = jorig; jmax = jmin + jsiz;
-  if (imax > width) {
-    if (cascf) imax = iorig - isiz;
-/*    else imax = width;*/
-    else imax = porig;
-    imin = imax - isiz;
-  }
-  if (jmax > height) {
-    jmax = height;
-    jmin = jmax - jsiz;
-  }
-
-  dmi1[dmrecu] = imin; dmi2[dmrecu] = imax;
-  dmj1[dmrecu] = jmin; dmj2[dmrecu] = jmax;
-  dmnum[dmrecu] = gmu->num;
-
-  xsetw.save_under = 1;
-  if (!bsflg) {
-    tpmap = XCreatePixmap (display, win, isiz, jsiz, depth);
-    XSync(display, 0);
-    if (tpmap) {
-       pimin = imin; pjmin = jmin; pisiz = isiz; pjsiz = jsiz;
-       XCopyArea (display, win, tpmap, gc, pimin, pjmin, pisiz, pjsiz, 0, 0);
-    }
-  }
-  pop = XCreateWindow(display, win, imin, jmin, isiz, jsiz, 0,
-        CopyFromParent, CopyFromParent, CopyFromParent,
-        CWSaveUnder, &xsetw);
-  XSelectInput(display, pop, ButtonReleaseMask | ButtonPressMask |
-      ButtonMotionMask | ExposureMask | StructureNotifyMask);
-  gcp = XCreateGC(display, pop, 0L, &values);
-  XSetForeground(display, gcp, cvals[1]);
-  lw = 1;
-  if (gmu->thk>5) lw = 2;
-  if (gmu->thk>11) lw = 3;
-  XSetLineAttributes(display, gcp, lw, LineSolid,
-                     CapButt, JoinBevel);
-  XMapWindow(display, pop);
-  flag = 1;
-  while (flag)  {
-    XMaskEvent(display, ExposureMask | StructureNotifyMask, &report);
-    switch  (report.type) {
-    case Expose:
-      if (report.xexpose.count != 0) break;
-      else flag = 0;
-      break;
-    case ConfigureNotify:
-      break;
-    }
-  }
-  if (gmu->bbc>-1) {
-    XSetForeground(display, gcp, cvals[gmu->bbc]);
-    XFillRectangle (display, pop, gcp, 0, 0, isiz, jsiz);
-  }
-  if (gmu->boc1 > -1) {
-    XSetForeground(display, gcp, cvals[gmu->boc1]);
-    XDrawLine (display, pop, gcp, 0, jsiz-1, isiz-1, jsiz-1);
-    XDrawLine (display, pop, gcp, isiz-1, jsiz-1, isiz-1, 0);
-  }
-  if (gmu->boc2 > -1) {
-    XSetForeground(display, gcp, cvals[gmu->boc2]);
-    XDrawLine (display, pop, gcp, isiz-1, 0, 0, 0);
-    XDrawLine (display, pop, gcp, 0, 0, 0, jsiz-1);
-  }
-  if (gfont==1 && font1i) XSetFont (display, gcp, font1i->fid);
-  if (gfont==2 && font2i) XSetFont (display, gcp, font2i->fid);
-  if (gfont==3 && font3i) XSetFont (display, gcp, font3i->fid);
-  cnt = 0;
-  ch = gmu->ch;
-  len = 0;
-  i=0;
-  if (dmrecu==0) {
-    while (*(ch+len)) len++;
-    ch = ch+len+1;
-    i = len+1;
-  }
-  while (i<gmu->len) {
-    len = 0;
-    lln = 0;
-    eflag = 1;
-    while (*(ch+len)) {
-      if (i+len+4<gmu->len && *(ch+len)=='>' &&
-           (*(ch+len+1)>='0' && *(ch+len+1)<='9') &&
-           (*(ch+len+2)>='0' && *(ch+len+2)<='9') &&
-            *(ch+len+3)=='>') {
-        eflag = 0;
-      }
-      if (i+len+5<gmu->len && *(ch+len)=='>' &&
-           (*(ch+len+1)>='0' && *(ch+len+1)<='1') &&
-           (*(ch+len+2)>='0' && *(ch+len+2)<='9') &&
-           (*(ch+len+3)>='0' && *(ch+len+3)<='9') &&
-            *(ch+len+4)=='>') {
-        eflag = 0;
-      }
-      len++;
-      if (eflag) lln++;
-    }
-    if (gfont==1 && font1i) {
-      w = XTextWidth(font1i, ch, lln);
-    }
-    if (gfont==2 && font2i) {
-      w = XTextWidth(font2i, ch, lln);
-    }
-    if (gfont==3 && font3i) {
-      w = XTextWidth(font3i, ch, lln);
-    }
-    j1 = h/4;
-    j2 = (cnt+1)*h - h/3;
-    XSetForeground(display, gcp, cvals[gmu->bfc]);
-    XDrawString(display, pop, gcp, j1, j2, ch, lln);
-    if (ptrs[cnt]>-1) {
-      j1 = h/5;
-      j2 = (cnt+1)*h - h/2;
-      if (gmu->soc2 > -1) {
-        XSetForeground(display, gcp, cvals[gmu->soc2]);
-        XDrawLine (display, pop, gcp, isiz-j1*3, j2+j1, isiz-j1*3, j2-j1);
-        XDrawLine (display, pop, gcp, isiz-j1*3, j2-j1, isiz-j1, j2);
-      }
-      if (gmu->soc1 > -1) {
-        XSetForeground(display, gcp, cvals[gmu->soc1]);
-        XDrawLine (display, pop, gcp, isiz-j1, j2, isiz-j1*3, j2+j1);
-      }
-    }
-    ch = ch+len+1;
-    i = i+len+1;
-    cnt++;
-  }
-  itemold = -1;
-  enter = 1;
-
-  XTranslateCoordinates (display, win, RootWindow (display, snum), 0, 0,
-			      &absx, &absy, &dummy);
-
-  /* Follow pointer around.  If it lands on another drop-menu
-     header, exit to draw that one instead.  */
-
-  dmflag = -999;
-  ecnt = 0;
-  while (1) {
-    XMaskEvent(display, ButtonPressMask | ButtonReleaseMask | ButtonMotionMask, &report);
-    if (report.type == ButtonPress || enter == 1) {
-      i = report.xbutton.x_root;
-      j = report.xbutton.y_root;
-      i -= absx;
-      j -= absy;
-      item = (j-jmin)/h;
-      if (i>imax || i<imin || j>jmax || j<jmin) item = -1;
-      if (item > -1 && ptrs[item] > -1) {
-        j1 = item*h+1;
-        dmcur[dmrecu] = item;
-        itt = ptrs[item];
-        if (dmu[itt].num == itt) {
-          dmflag = gxpopdm( &(dmu[ptrs[item]]), iobj, imin, imax, j1+jmin);
-          if (dmflag != -99) {
-            if (dmsel[dmrecu+1]<1) {
-              item = -2;
-              itemold = -2;
-            }
-          }
-        }
-      }
-      dmflag = -999;
-      itemold = item;
-      if(enter == 1) {
-        enter = 0;
-      } else {
-        break;
-      }
-    }
-    if (report.type == ButtonRelease && item > -1) break;
-    if (report.type == MotionNotify) {
-      i = report.xmotion.x;
-      j = report.xmotion.y;
-      i = report.xmotion.x_root;
-      j = report.xmotion.y_root;
-      i -= absx;
-      j -= absy;
-      if (i>imax || i<imin || j>jmax || j<jmin ) {
-        item = -1;
-        if (dmrecu>0) {
-          for (itt=0; itt<dmrecu; itt++) {
-            if (i>=dmi1[itt] && i<=dmi2[itt] &&
-                j>=dmj1[itt] && j<=dmj2[itt]  ) {
-              itt2 = (j-dmj1[itt])/h;
-              if (itt2 != dmcur[itt]) {
-                dmflag = -99;
-                itt = 999;
-              }
-            }
-          }
-        }
-      }
-      else item = (j-jmin)/h;
-      if (dmflag == -99) {itemold = -1; break; }
-      if (item!=itemold) {
-        if (item>-1) {
-          j1 = item*h+lw; j2 = (item+1)*h-lw-1;
-          if (gmu->soc2 > -1) {
-            XSetForeground(display, gcp, cvals[gmu->soc2]);
-            XDrawLine (display, pop, gcp, lw, j1, lw, j2);
-            XDrawLine (display, pop, gcp, lw, j1, isiz-lw-1, j1);
-          }
-          if (gmu->soc1 > -1) {
-            XSetForeground(display, gcp, cvals[gmu->soc1]);
-            XDrawLine (display, pop, gcp, isiz-lw-1, j1, isiz-lw-1, j2);
-            XDrawLine (display, pop, gcp, lw, j2, isiz-lw-1, j2);
-          }
-          if (ptrs[item]>-1) {
-            j1 = h/5;
-            j2 = (item+1)*h - h/2;
-            if (gmu->soc1 > -1) {
-              XSetForeground(display, gcp, cvals[gmu->soc1]);
-              XDrawLine (display, pop, gcp, isiz-j1*3, j2+j1, isiz-j1*3, j2-j1);
-              XDrawLine (display, pop, gcp, isiz-j1*3, j2-j1, isiz-j1, j2);
-            }
-            if (gmu->soc2 > -1) {
-              XSetForeground(display, gcp, cvals[gmu->soc2]);
-              XDrawLine (display, pop, gcp, isiz-j1, j2, isiz-j1*3, j2+j1);
-            }
-          }
-          ecnt = 0;
-        }
-        if (itemold>-1) {
-          j1 = itemold*h+lw; j2 = (itemold+1)*h-lw-1;
-          if (gmu->bbc > -1) {
-            XSetForeground(display, gcp, cvals[gmu->bbc]);
-            XDrawLine (display, pop, gcp, lw, j1, lw, j2);
-            XDrawLine (display, pop, gcp, lw, j1, isiz-lw-1, j1);
-            XDrawLine (display, pop, gcp, isiz-lw-1, j1, isiz-lw-1, j2);
-            XDrawLine (display, pop, gcp, lw, j2, isiz-lw-1, j2);
-          }
-          if (ptrs[itemold]>-1) {
-            j1 = h/5;
-            j2 = (itemold+1)*h - h/2;
-            if (gmu->soc2 > -1) {
-              XSetForeground(display, gcp, cvals[gmu->soc2]);
-              XDrawLine (display, pop, gcp, isiz-j1*3, j2+j1, isiz-j1*3, j2-j1);
-              XDrawLine (display, pop, gcp, isiz-j1*3, j2-j1, isiz-j1, j2);
-            }
-            if (gmu->soc1 > -1) {
-              XSetForeground(display, gcp, cvals[gmu->soc1]);
-              XDrawLine (display, pop, gcp, isiz-j1, j2, isiz-j1*3, j2+j1);
-            }
-          }
-          ecnt = 0;
-        }
-      }
-      if (ecnt > 3 && item > -1 && item==itemold && ptrs[item] > -1) {
-        j1 = itemold*h+1;
-        dmcur[dmrecu] = item;
-        itt = ptrs[item];
-        if (dmu[itt].num == itt) {
-          dmflag = gxpopdm( &(dmu[ptrs[item]]), iobj, imin, imax, j1+jmin);
-          if (dmflag != -99) {
-            if (dmsel[dmrecu+1]<1) {
-              item = -2;
-              itemold = -2;
-            }
-            break;
-          }
-          dmflag = -999;
-        }
-      }
-      if (item==itemold) ecnt++;
-      itemold = item;
-      if (item==-1) {
-        ii = 0;
-        while (ii<512 && obj[ii].type>-1) {
-          if (ii != iobj && obj[ii].type==3 &&
-              i>obj[ii].i1 && i<obj[ii].i2 && j>obj[ii].j1 && j<obj[ii].j2) {
-            dmflag = ii;
-            ii = 100000;           /* Exit loop */
-          }
-          ii++;
-        }
-      }
-      if (dmflag > -1) break;
-    }
-  }
-  dmsel[dmrecu] = itemold + 1;
-  if (ptrs[itemold]>-1 && dmsel[dmrecu+1]<0) dmsel[dmrecu] = -1;
-  XUnmapWindow(display,pop);
-  XDestroyWindow(display,pop);
-  if (!bsflg) {
-    if (tpmap) {
-      XCopyArea (display, tpmap, win, gc, 0, 0, pisiz, pjsiz, pimin, pjmin);
-      XFreePixmap (display, tpmap);
-    }
-    excnt++;
-  }
-  XFlush(display);
-  dmrecu--;
-  return (dmflag);
-}
-
-/* Handle dialog box.  A new, temporary window is created,
-   and text input is allowed.  Window is destroyed as soon as
-   the enter key is detected.  */
-
-/* modified 102400 by love to support user settings for window with editing. */
-
-char *gxdlg (struct gdlg *qry) {
-int flag,i,j,cnt,len,w,h=0,rlen,plen,tlen;
-int dflag,cn,c0,c1,c2,i1,i2=0,ii,w1=0,w2=0,cflag,eflag,pflag;
-int jmin,imin,isiz,jsiz,j1,j2;
-int n0,n1,n2,n3,n4,n5,n6,n7,p0,p1,p2,p3,p4,p5,p6,pl=0;
-Time lastBtnDown;
-char *tch,buff[80],*rch,ch[1],*pch;
-KeySym keysym;
-int pimin,pjmin,pisiz,pjsiz;
-Pixmap tpmap=0, wmap=0;
-Window pop;
-GC gcp;
-
-  pch = (char *)malloc(512);
-  if (pch==NULL) {
-    printf ("Memory Allocation Error: Dialog Box\n");
-    return ('\0');
-  }
-  tch = (char *)malloc(512);
-  if (tch==NULL) {
-    printf ("Memory Allocation Error: Dialog Box\n");
-    return ('\0');
-  }
-  rch = (char *)malloc(512);
-  if (rch==NULL) {
-    printf ("Memory Allocation Error: Dialog Box\n");
-    return ('\0');
-  }
-  plen = 0;
-  rlen = 0;
-
-  XSelectInput(display, win, ButtonReleaseMask | ButtonPressMask |
-      ButtonMotionMask | ExposureMask | StructureNotifyMask);
-
-/* Check for a '|' and split the input string into a prompt and
-   an initial string.  Check for a '\' or '/' to split the line */
-  len = 0;
-  if (qry->ch) while (*(qry->ch+len)) len++;
-  flag = 0;
-  pflag = 0;
-  c0 = 0;
-  c1 = 0;
-  c2 = 0;
-  for (i = 0; i<len; i++) {
-    *(tch-c1+i) = *(qry->ch+i);
-    if ((*(qry->ch+i) == '|' || *(qry->ch+i) == '/') && pflag == 0) {
-      c1 = i + 1; 
-      strcpy(pch,tch);
-      pflag = i;
-    }
-    if (*(qry->ch+i) == '/' && flag == 0) flag = i;
-  }
-  plen = c1;
-  if (*(pch) == '|' || *(pch) == '/') {*(pch) = '\0'; plen = 0;}
-  if (*(pch+pflag) == '|' || *(pch+pflag) == '/') *(pch+pflag) = ' ';
-  *(pch+c1) = '\0';
-  
-/* Define input string */
-  for (i = 0; i<len-c1; i++) { /* find leading blanks and new line indicators */
-    if (*(tch+i) == '/' || *(tch+i) == ' ' || *(tch+i) == '|') continue;
-    else {c2 = i; break;}
-  }
-  for (i = 0; i<len-c2; i++) 	/* remove leading blanks and new line indicators */
-    *(rch+i) =  *(tch+c2+i); 
-  strcpy(tch,rch);
-  tlen = len - c2 - c1;
-  *(tch+tlen) = '\0';
-    
-  if (qry->x<0 &&qry->y<0 &&qry->h<0 &&qry->w<0)
-    dflag = 1;
-  else if (flag)
-    dflag = 2; 
-  else 
-    dflag = 0;
- 
-  if (pflag && !flag) c0 = c1;
-  if (dflag == 1 ) c0 = 0;
-  
-/* Set width and height of dialog box */
-  if (gfont==1 && font1i) {
-    if (pch) w1 = XTextWidth(font1i, pch, plen);
-    else w1 = 0;
-    h = font1i->ascent;
-  }
-  if (gfont==2 && font2i) {
-    if (pch) w1 = XTextWidth(font2i, pch, plen);
-    else w1 = 0;
-    h = font2i->ascent;
-  }
-  if (gfont==3 && font3i) {
-    if (pch) w1 = XTextWidth(font3i, pch, plen);
-    else w1 = 0;
-    h = font3i->ascent;
-  }
-  if (gfont==1 && font1) {
-    if (tch) w2 = XTextWidth(font1, tch, tlen);
-    else w2 = 0;
-    h = font1->ascent;
-  }
-  if (gfont==2 && font2) {
-    if (tch) w2 = XTextWidth(font2, tch, tlen);
-    else w2 = 0;
-    h = font2->ascent;
-   }
-   if (gfont==3 && font3) {
-    if (tch) w1 = XTextWidth(font3, tch, tlen);
-    else w2 = 0;
-    h = font3->ascent;
-  }
-  if (flag) w = ((w1)>(w2))?(w1):(w2);
-  else w = w1 + w2;
-  if (flag) h = h*1.8;
-
-
-/* Convert box size to pixels */
-  if (qry->h == -1 ) {
-    jsiz = h*5;
-    if (jsiz>height) jsiz = height*3/4;
-  }
-  else jsiz = (int)(qry->h*yscl+0.5);
-  if (qry->h == 0 ) jsiz = h*1.8;
-  
-  if (qry->w == -1 ) isiz = width*2/3;
-  else isiz = (int)(qry->w*xscl+0.5);
-  if (qry->w == 0 ) isiz = w+h*1.5;
-  
-  if (qry->x == -1 ) imin = (width-isiz)/2;
-  else imin = qry->x*xscl+0.5-isiz/2;
-  
-  if (qry->y == -1 ) jmin = (height-jsiz)/2;
-  else jmin = height - (qry->y*yscl+0.5+jsiz/2);
-  pimin = imin; pjmin = jmin; pisiz = isiz; pjsiz = jsiz;
-  
-  xsetw.save_under = 1;
-  if (!bsflg) {
-    wmap = XCreatePixmap (display, win, width, height, depth);
-    XSync(display, 0);
-    if (wmap) {
-       XCopyArea (display, win, wmap, gc, 0, 0, width, height, 0, 0);
-    }
-  }
-  pop = XCreateWindow(display, win, pimin, pjmin, pisiz, pjsiz, 0,
-        CopyFromParent, CopyFromParent, CopyFromParent,
-        CWSaveUnder, &xsetw);
-  XSelectInput(display, pop, ExposureMask | StructureNotifyMask | KeyPressMask);
-  gcp = XCreateGC(display, pop, 0L, &values);
-  if (qry->oc > -1) cn = qry->oc;
-  else cn = 1;
-  XSetForeground(display, gcp, cvals[cn]);
-  XSetLineAttributes(display, gcp, 0L, LineSolid,
-                     CapButt, JoinBevel);
-  XMapWindow(display, pop);
-  flag = 1;
-  while (flag)  {
-    XMaskEvent(display, ExposureMask | StructureNotifyMask, &report);
-    switch  (report.type) {
-    case Expose:
-      if (report.xexpose.count != 0) break;
-      else flag = 0;
-      break;
-    case ConfigureNotify:
-      break;
-    }
-  }
-
-/* Draw dialog box and text */
-  if (dflag == 1 && plen == 0) {
-    plen = tlen;
-    strcpy(pch,tch);
-    tlen = 0;
-    *(tch) = '\0';
-  }
-  if (qry->bc > -1) cn = qry->bc;
-  else cn = 15;
-  XSetForeground(display, gcp, cvals[cn]);
-  XFillRectangle (display, pop, gcp, 0, 0, pisiz, pjsiz);
-  if (qry->oc > -1) cn = qry->oc;
-  else cn = 1;
-  XSetForeground(display, gcp, cvals[cn]);
-  XDrawRectangle (display, pop, gcp, 0, 0, pisiz-1, pjsiz-1);
-  if (qry->th > 5) XDrawRectangle (display, pop, gcp, 1, 1, pisiz-3, pjsiz-3);
-  if (qry->fc > -1) cn = qry->fc;
-  else cn = 0;
-  XSetForeground(display, gcp, cvals[cn]);
-  if (dflag) {
-    if (gfont==1 && font1i) XSetFont (display, gcp, font1i->fid);
-    if (gfont==2 && font2i) XSetFont (display, gcp, font2i->fid);
-    if (gfont==3 && font3i) XSetFont (display, gcp, font3i->fid);
-    i = (isiz-w)/2;
-    if (dflag == 1) {
-      j = h*2;
-    } else {
-      j = jsiz*3/7;
-    }
-    XSetForeground(display, gcp, cvals[0]);
-    if (plen>0) XDrawString(display, pop, gcp, i, j, pch, plen);
-    if (qry->pc > -1) cn = qry->pc;
-    else cn = 1;
-    XSetForeground(display, gcp, cvals[cn]);
-    if (plen>0) XDrawString(display, pop, gcp, i-1, j-1, pch, plen);
-    if (gfont==1 && font1) XSetFont (display, gcp, font1->fid);
-    if (gfont==2 && font2) XSetFont (display, gcp, font2->fid);
-    if (gfont==3 && font3) XSetFont (display, gcp, font3->fid);
-    if (dflag == 1) {
-      j = h*4;
-      j1 = h*2+1;
-      j2 = jsiz-j1-1;
-    } else {
-      j = jsiz*6/7;
-      j1 = jsiz*1/2;
-      j2 = jsiz -j1 -1;
-    }
-    if (qry->fc > -1) cn = qry->fc;
-    else cn = 0;
-    XSetForeground(display, gcp, cvals[cn]);
-    if (gfont==1 && font1) XSetFont (display, gcp, font1->fid);
-    if (gfont==2 && font2) XSetFont (display, gcp, font2->fid);
-    if (gfont==3 && font3) XSetFont (display, gcp, font3->fid);
-    if (tlen>0) XDrawString(display, pop, gcp, i, j, tch, tlen);
-    strcpy(rch,tch);
-    rlen = tlen;
-  } else {
-    if (gfont==1 && font1) XSetFont (display, gcp, font1->fid);
-    if (gfont==2 && font2) XSetFont (display, gcp, font2->fid);
-    if (gfont==3 && font3) XSetFont (display, gcp, font3->fid);
-    j1 = 1;
-    j2 = jsiz -j1 -1;
-    j = (j1+j2+h-1)/2;
-    if (pflag) {
-      i = h/2;
-      strcpy(rch,pch);
-      strcat(rch,tch);
-      rlen = plen + tlen;
-      if (rlen>0) XDrawString(display, pop, gcp, i, j, rch, rlen);
-    } else {
-      i = (isiz-w)/2;
-      if (tlen>0) XDrawString(display, pop, gcp, i, j, tch, tlen);
-      strcpy(rch,tch);
-      rlen = tlen;
-    }    
-  }
-
-  if (!bsflg) {
-    tpmap = XCreatePixmap (display, pop, pisiz, pjsiz, depth);
-    XSync(display, 0);
-    if (tpmap) {
-       XCopyArea (display, pop, tpmap, gc, 0, 0, pisiz, pjsiz, 0, 0);
-    }
-  }
-
-/* Loop on edit session and exit on Enter */
-  c1 = rlen;
-  c2 = rlen;
-  cflag = 0;
-  eflag = 0;
-  for (i=0; i<512; i++) *(tch+i) = '\0';
-  lastBtnDown = 0;
-  while (1) {
-    XMaskEvent(display, ButtonReleaseMask | ButtonPressMask |
-         ButtonMotionMask | KeyPressMask | ExposureMask | StructureNotifyMask, &report);
-   
-/*mf 980112
-  explicit cast of report to make it work on the NERSC j90
-  this is NOT correct for X11R6.3
-mf*/
-
-    if (report.type == NoExpose) continue;
-
-    if (report.type == Expose || report.type == GraphicsExpose) {
-      if (excnt>0) excnt--;
-      if (!bsflg) {
-        if (wmap && report.type == Expose) {
-          XCopyArea (display, wmap, win, gc, 0, 0, width, height, 0, 0);
-        }
-        if (tpmap) {
-          XCopyArea (display, tpmap, pop, gc, 0, 0, pisiz, pjsiz, 0, 0);
-        }
-      }
-      XFlush(display);
-    }
-    if (!bsflg && report.type != Expose && report.type != GraphicsExpose && tpmap) {
-      XFreePixmap (display, tpmap); 
-      tpmap = (Pixmap) NULL;
-    }
-    if (report.type == ButtonPress && report.xbutton.time < lastBtnDown + 300) {
-      c1 = c0;
-      c2 = rlen;
-      i1 = (isiz-w)/2;
-      i2 = (isiz+w)/2;
-      cflag = 1;
-    } else if (report.type == ButtonPress && rlen>0) {
-      i1 = report.xbutton.x - imin;
-      if (2*i1 > isiz-w && 2*i1 < isiz+w) c1 = (i1 - (isiz-w)/2 + 4)*rlen/w;
-      if (2*i1 <= isiz-w) c1 = 0;
-      if (2*i1 >= isiz+w) c1 = rlen; 
-      if (2*i1 <= isiz-w) i1 = (isiz-w)/2; 
-      if (2*i1 >= isiz+w) i1 = (isiz+w)/2; 
-      if (c1 < c0) c1 = c0;
-      c2 = c1;
-      lastBtnDown = report.xbutton.time;
-    } else if ((report.type == ButtonRelease || report.type == MotionNotify) && rlen>0 && cflag==0) {
-      i2 = report.xbutton.x - imin;
-      if (2*i2 > isiz-w && 2*i2 < isiz+w) c2 = (i2 - (isiz-w)/2 + 8)*rlen/w;
-      if (2*i2 <= isiz-w) c2 = c0;
-      if (2*i2 >= isiz+w) c2 = rlen; 
-      if (2*i2 <= isiz-w) i2 = (isiz-w)/2; 
-      if (2*i2 >= isiz+w) i2 = (isiz+w)/2; 
-      if (c2 < c0) c2 = c0;
-      cflag = 0;
-    }
-    if(rlen == 0) {
-      i2 = isiz/2;
-      i1 = isiz/2;
-      c2 = c0;
-      c1 = c0;
-    }
-    if (report.type ==  KeyPress) {
-      cnt = XLookupString((XKeyEvent *)&report,buff,80,&keysym,NULL);
-      if (cnt>0) {
-        if (keysym==XK_Return || keysym==XK_Linefeed) {
-          if (qry->nu == 1) {
-            for (i=0; i<rlen-c0; i++) *(tch+i) = *(rch+c0+i);
-            tlen = rlen-c0;
-            ii = 0;
-            n0=0; n1=0; n2=0; n3=0; n4=0; n5=0; n6=0; n7=0;
-            p0=0; p1=0; p2=0; p3=0; p4=0; p5=0; p6=0;
-            for (i = 0; i<tlen; i++) {
-              if (*(tch+i) == '.') {n1++; p1=i+1;}
-              if (*(tch+i) == '+') {n2++; p2=i+1;}
-              if (*(tch+i) == '-') {n3++; p3=i+1;}
-              if (*(tch+i) == 'e') {n4++; p4=i+1;}
-              if (*(tch+i) == 'E') {n5++; p5=i+1;}
-              if (*(tch+i) >= 'a' && *(tch+i) <= 'z' && *(tch+i) != 'e') n0=1;
-              if (*(tch+i) >= 'A' && *(tch+i) <= 'Z' && *(tch+i) != 'E') n0=1;
-              if (n0==1 && p0==0) p0 = i;
-              if (n0==1) pl =i;
-              if (*(tch+i) == '#') {n6++; p6=i+1;}
-              if (*(tch+i) >= '0' && *(tch+i) <= '9') n7=1;
-            }     
-            if (n1==1 && p1==1) ii = 1; /* require digit before decimal  */    
-            if (n1==1 && p1==2 && p2==1 && n2==1) ii = 1;
-            if (n1==1 && p1==2 && p3==1 && n3==1) ii = 1;  
-            if (n1==1 && p1==2 && p2==p4+1 && n2==2) ii = 1;
-            if (n1==1 && p1==2 && p3==p4+1 && n3==2) ii = 1;  
-            if (n1==1 && p1==2 && p2==p5+1 && n2==2) ii = 1;
-            if (n1==1 && p1==2 && p3==p5+1 && n3==2) ii = 1;  
-            if (n1>1) ii = 2; /* too many decimal points */
-            if (n2>=1 && p2>p4+1 && n4==1) ii = 3; /* misplaced + sign in exponent */
-            if (n2>=1 && p2>p5+1 && n5==1) ii = 3;
-            if (n3>=1 && p3>p4+1 && n4==1) ii = 4; /* misplaced - sign in exponent */
-            if (n3>=1 && p3>p5+1 && n5==1) ii = 4;           
-            if (n2>=1 && p2>1 && n4+n5==0) ii = 5; /* misplaced + sign in number */
-            if (n2>=1 && p2>1 && p2<p4 && n4==1) ii = 5;
-            if (n2>=1 && p2>1 && p2<p5 && n5==1) ii = 5;            
-            if (n3>=1 && p3>1 && n4+n5==0) ii = 6; /* misplaced - sign in number */
-            if (n3>=1 && p3>1 && p3<p4 && n4==1) ii = 6;
-            if (n3>=1 && p3>1 && p3<p5 && n5==1) ii = 6;
-            if (n1==1 && p1>p4 && n4==1) ii = 7; /* decimal in exponent */
-            if (n1==1 && p1>p5 && n5==1) ii = 7;            
-            if (n4>0 && p4==tlen) ii = 8; /* missing exponent value */
-            if (n5>0 && p5==tlen) ii = 8;
-            if (n4>0 && p4==tlen-1 && p2==tlen) ii = 8;
-            if (n5>0 && p5==tlen-1 && p2==tlen) ii = 8;
-            if (n4>0 && p4==tlen-1 && p3==tlen) ii = 8;
-            if (n5>0 && p5==tlen-1 && p3==tlen) ii = 8;
-            if (n7==0) ii = 9; /* missing number value */
-            if (n4>0 && p4==1) ii = 9;
-            if (n5>0 && p5==1) ii = 9;
-            if (n4>0 && p4==2 && p1==1) ii = 9;
-            if (n5>0 && p5==2 && p1==1) ii = 9;
-            if (n4>0 && p4==2 && p2==1) ii = 9;
-            if (n5>0 && p5==2 && p2==1) ii = 9;
-            if (n4>0 && p4==2 && p3==1) ii = 9;
-            if (n5>0 && p5==2 && p3==1) ii = 9;
-            if (n2>2) ii = 10; /* too many '+' signs */
-            if (n3>2) ii = 11; /* too many '-' signs */
-            if (n4+n5>1) ii = 12; /* too many exponent symbols */
-            if (n6>0) ii = 13; /* # sign still present, number not entered */
-            if (n0>0) ii = 14; /* number includes an alpha char */
-            if (ii>1) { /* calculate error indices to highlight */
-              eflag = 1;
-              if (ii==2) {c1 = p1-1; c2 = p1;}
-              if (ii==3) {c1 = p2-1; c2 = p2;}
-              if (ii==4) {c1 = p3-1; c2 = p3;}
-              if (ii==5) {c1 = p2-1; c2 = p2;}
-              if (ii==6) {c1 = p3-1; c2 = p3;}
-              if (ii==7) {c1 = p1-1; c2 = p1;}
-              if (ii==8) {c1 = tlen; c2 = tlen+1; 
-                 *(tch+tlen)='#'; *(tch+tlen+1)='\0'; tlen++;}
-              if (ii==9) {c1 = 0; c2 = 1; 
-                  strcpy(rch,tch); *(tch)='#'; 
-                 for (i=1; i<tlen+1; i++) *(tch+i) = *(rch+i-1); 
-                 *(tch+tlen+1) = '\0';}
-              if (ii==10) {c1 = p2-1; c2 = p2;}
-              if (ii==11) {c1 = p3-1; c2 = p3;}
-              if (ii==12) {
-                if (p5>p4) {c1 = p5-1; c2 = p5;}
-                else {c1 = p4-1; c2 = p4;}
-              }
-              if (ii==13) {c1 = p6-1; c2 = p6;}
-              if (ii==14) {c1 = p0-1; c2 = pl+1;}
-              rlen = tlen+c0;
-              if (pflag && !dflag) {
-                c1 += plen; c2 += plen;
-                strcpy(rch,tch);
-                strcpy(tch,pch);
-                strcat(tch,rch);
-                rlen = strlen(tch);
-              } 
-              strcpy(rch,tch);
-            
-            } else {
-              eflag = 0;
-               if (ii==1) { /* insert zero digit before decimal  */ 
-                strcpy(rch,tch);
-                tlen++;
-                ii = 0;
-                for (i=0; i<tlen; i++) {
-                  if (i==p1-1) {
-                    *(tch+i) = '0';
-                    i++;
-                  }
-                  *(tch+i) = *(rch+ii);
-                  ii++;
-                }
-                *(tch+tlen) = '\0';
-              }
-              rlen = tlen+c0;
-              if (pflag && !dflag) {
-                strcpy(rch,tch);
-                strcpy(tch,pch);
-                strcat(tch,rch);
-              }
-              strcpy(rch,tch);
-            
-              break;
-            }           
-          } else break;
-        }
-        if (keysym==XK_BackSpace && c1>c0) {
-          strcpy(tch,rch);
-          ii = 0;
-          for (i=c0; i<rlen; i++) {
-            if (i == c1-1 && c1 == c2) continue;
-            if (i >= c1 && i < c2) continue;
-            *(rch+ii) = *(tch+i);
-            ii++;
-          }
-          rlen = ii;
-          if (pflag && !dflag) {strcpy(tch,pch); strcat(tch,rch); strcpy(rch,tch); rlen+=plen;}
-          *(rch+rlen) = '\0';
-          c1--;
-          c2 = c1;
-        }
-        if (keysym==XK_Delete) {
-          strcpy(tch,rch);
-          ii = 0;
-          for (i=c0; i<rlen; i++) {
-            if (i == c1 && c1 == c2) continue;
-            if (i >= c1 && i < c2) continue;
-            *(rch+ii) = *(tch+i);
-            ii++;
-          }
-          rlen = ii;
-          if (pflag && !dflag) {strcpy(tch,pch); strcat(tch,rch); strcpy(rch,tch); rlen+=plen;}
-          if (c1==rlen &&c1>0) c1--;
-          *(rch+rlen) = '\0';
-          c2 = c1;
-        }
-        if (keysym>=XK_space && keysym<=XK_asciitilde) {
-          if (qry->nu == 1) {
-            *(ch) = buff[0];
-            if ((*ch>='0' && *ch<='9') || *ch=='+' || *ch=='-' || *ch=='.' || *ch=='e' || *ch=='E') ;
-            else continue;
-          }
-          strcpy(tch,rch);
-          rlen += c1-c2+1;
-          ii = 0;
-          for (i=0; i<rlen; i++) {
-            if (i == c1) {
-              *(rch+c1) = buff[0];
-              i++;
-              ii += c2-c1;
-            }
-            *(rch+i) = *(tch+ii);
-            ii++;
-          }
-          c1++;
-          *(rch+rlen) = '\0';
-          c2 = c1;
-        }
-        for (i=0; i<512; i++) *(tch+i) = '\0';
-      }
-      if ((keysym==XK_KP_Left  ||keysym==XK_Left) && c1>c0) {if (c1==c2) c2--; c1--;}
-      if ((keysym==XK_KP_Right ||keysym==XK_Right) && c1<rlen) {if (c1==c2) c2++; c1++;}
-      if ((keysym==XK_KP_Down  ||keysym==XK_Down) && c2>c1) c2--; 
-      if ((keysym==XK_KP_Up    ||keysym==XK_Up) && c2<rlen) c2++;
-    }
-    if (rlen>=0 && c1>=c2) {
-      if (qry->bc > -1) cn = qry->bc;
-      else cn = 15;
-      XSetForeground(display, gcp, cvals[cn]);
-      XFillRectangle (display, pop, gcp, 2, j1+1, isiz-4, j2-2);
-      if (qry->fc > -1) cn = qry->fc;
-      else cn = 0;
-      XSetForeground(display, gcp, cvals[cn]);
-      if (gfont==1 && font1) w = XTextWidth(font1, rch, rlen);
-      if (gfont==2 && font2) w = XTextWidth(font2, rch, rlen);
-      if (gfont==3 && font3) w = XTextWidth(font3, rch, rlen);
-      if (w+h < isiz) i = (isiz-w)/2;
-      else i = isiz-w-h/2;
-      if (pflag && !dflag && w+h < isiz) i = h/2;
-      if (c1>0) strncpy(tch,rch, (size_t) c1);
-      *(tch+c1) = '\0';
-      if (gfont==1 && font1) w1 = XTextWidth(font1, tch, c1);
-      if (gfont==2 && font2) w1 = XTextWidth(font2, tch, c1);
-      if (gfont==3 && font3) w1 = XTextWidth(font3, tch, c1);
-      ii = i+w1;
-      if (ii<=0) {
-        i=-w1;
-        XDrawString(display, pop, gcp, i, j, rch, rlen);
-        XDrawString(display, pop, gcp, i, j, "|", 1);
-      } else {
-        XDrawString(display, pop, gcp, i, j, rch, rlen);
-        XDrawString(display, pop, gcp, ii, j, "|", 1);
-      }
-    }
-    if(c1<c2) {
-      if (gfont==1 && font1) w = XTextWidth(font1, rch, rlen);
-      if (gfont==2 && font2) w = XTextWidth(font2, rch, rlen);
-      if (gfont==3 && font3) w = XTextWidth(font3, rch, rlen);
-      if (w+h < isiz) i = (isiz-w)/2;
-      else i = isiz-w-h/2;
-      if (pflag && !dflag && w+h < isiz) i = h/2;
-      
-      if (c1>0) strncpy(tch,rch, (size_t) c1);
-      *(tch+c1) = '\0';
-      if (gfont==1 && font1) w1 = XTextWidth(font1, tch, c1);
-      if (gfont==2 && font2) w1 = XTextWidth(font2, tch, c1);
-      if (gfont==3 && font3) w1 = XTextWidth(font3, tch, c1);
-      if (qry->bc > -1) cn = qry->bc;
-      else cn = 15;
-      XSetForeground(display, gcp, cvals[cn]);
-      XFillRectangle (display, pop, gcp, 2, j1+1, isiz-4, j2-2);
-      if (qry->fc > -1) cn = qry->fc;
-      else cn = 0;
-      XSetForeground(display, gcp, cvals[cn]);
-      XDrawString(display, pop, gcp, i, j, tch, c1);
-      
-      for (ii=0; ii<c2-c1; ii++) *(tch+ii) = *(rch+ii+c1);
-      *(tch+c2-c1) = '\0';
-      if (gfont==1 && font1) w2 = XTextWidth(font1, tch, c2-c1);
-      if (gfont==2 && font2) w2 = XTextWidth(font2, tch, c2-c1);
-      if (gfont==3 && font3) w2 = XTextWidth(font3, tch, c2-c1);
-      i += w1;     
-      if (qry->fc > -1) cn = qry->fc;
-      else cn = 0;
-      if (eflag) cn = 2;
-      XSetForeground(display, gcp, cvals[cn]);
-      XFillRectangle (display, pop, gcp, i, j1+1, w2, j2-2);
-      if (qry->bc > -1) cn = qry->bc;
-      else cn = 15;
-      XSetForeground(display, gcp, cvals[cn]);
-      XDrawString(display, pop, gcp, i, j, tch, c2-c1);
-      
-      for (ii=0; ii<rlen-c2; ii++) *(tch+ii) = *(rch+ii+c2);
-      *(tch+rlen-c2) = '\0';
-      i += w2;
-      if (qry->bc > -1) cn = qry->bc;
-      else cn = 15;
-      XSetForeground(display, gcp, cvals[cn]);
-      XFillRectangle (display, pop, gcp, i, j1+1, isiz-i2, j2-2);
-      if (qry->fc > -1) cn = qry->fc;
-      else cn = 0;
-      XSetForeground(display, gcp, cvals[cn]);
-      XDrawString(display, pop, gcp, i, j, tch, rlen-c2);
-      
-      if (qry->oc > -1) cn = qry->oc;
-      else cn = 1;
-      XSetForeground(display, gcp, cvals[cn]);
-      XDrawRectangle (display, pop, gcp, 0, 0, isiz-1, jsiz-1);
-      if (qry->th > 5) XDrawRectangle (display, pop, gcp, 1, 1, isiz-3, jsiz-3);
-    }
-    for (i=0; i<512; i++) *(tch+i) = '\0';
-
-    if (!bsflg && report.type != Expose && report.type != GraphicsExpose && !tpmap) {
-      tpmap = XCreatePixmap (display, pop, pisiz, pjsiz, depth);
-      XSync(display, 0);
-      if (tpmap) {
-         XCopyArea (display, pop, tpmap, gc, 0, 0, pisiz, pjsiz, 0, 0);
-      }
-    }
-  }
-
-/* Restore original screen */
-  XUnmapWindow(display,pop);
-  XDestroyWindow(display,pop);
-  gxdsfn();
-  XSelectInput(display, win, ButtonReleaseMask | ButtonPressMask |
-      ButtonMotionMask | ExposureMask | StructureNotifyMask);
-  if (!bsflg) {
-    if (wmap) {
-      XCopyArea (display, wmap, win, gc, 0, 0, width, height, 0, 0);
-      XFreePixmap (display, wmap);
-    }
-    if (tpmap) {
-      XFreePixmap (display, tpmap);
-    }
-    excnt++;
-  }
-  XFlush(display);
-  
-/* Remove '+' signs */
-  if (qry->nu == 1) {
-    strcpy(tch,rch);
-    ii = 0;
-    for (i=0; i<rlen; i++) {
-      if (*(rch+i)  == '+') continue;
-      *(rch+ii) = *(tch+i);
-      ii++;
-    }
-    rlen = ii;
-  } 
-/* Trim prompt string */
-  if (pflag && !dflag) {
-    strcpy(tch,rch);
-    ii = 0;
-    for (i=c0; i<rlen; i++) {
-      *(rch+ii) = *(tch+i);
-      ii++;
-    }
-    rlen = ii;
-  }
-  *(rch+rlen) = '\n';
-  *(rch+rlen+1) = '\0';
-  return (rch);
-}
-
-/* Screen save and show operation */
-/* Save from displayed window.  Do show operation to current
-   window display, sometimes background */
-
-void gxdssv (int frame) {
-  if (batch) {
-    printf("Error: the screen command does not work in batch mode\n");
-    return;
-  }
-  if (frame<0 || frame>199) return;
-  if (!pfilld[frame]) {
-    pmaps[frame] = XCreatePixmap (display, win, width, height, depth);
-    if (pmaps[frame]==(Pixmap)NULL) {
-      printf ("Error allocating pixmap for screen save operation\n");
-      printf ("Screen will not be saved\n");
-      return;
-    }
-    pfilld[frame] = 1;
-  }
-  XCopyArea (display, win, pmaps[frame], gc, 0, 0, width, height, 0, 0);
-}
-
-void gxdssh (int cnt) {
-  if (batch) {
-    printf("Error: the screen command does not work in batch mode\n");
-    return;
-  }
-  if (cnt<0 || cnt>199) return;
-  if (pfilld[cnt]) XCopyArea (display, pmaps[cnt], drwbl, gc, 0, 0, width, height, 0, 0);
-}
-
-void gxdsfr (int frame) {
-  if (batch) {
-    printf("Error: the screen command does not work in batch mode\n");
-    return;
-  }
-  if (frame<0 || frame>199) return;
-  if (pfilld[frame]) {
-    XFreePixmap (display, pmaps[frame]);
-    pfilld[frame] = 0;
-  }
-}
-
-/* Routine to install stipple pixmaps to provide pattern fills for
-   recf and polyf.  Choices include solid, dot, line and open.
-   Check and line density can be controlled as well as line angle. */
-
-void gxdptn (int typ, int den, int ang) {
-unsigned char *bitmap_bits;
-int bitmap_width, bitmap_height;
-Pixmap stipple_pixmap;
-
-  if (typ==0) {
-    bitmap_bits = open_bitmap_bits;
-    bitmap_width = open_bitmap_width;
-    bitmap_height = open_bitmap_height;
-  }
-  else if (typ==1) {
-    XSetFillStyle (display, gc, FillSolid);
-    return;
-  }
-  else if (typ==2) {
-    if (den==6) {
-      bitmap_bits = dot_6_bitmap_bits;
-      bitmap_width = dot_6_bitmap_width;
-      bitmap_height = dot_6_bitmap_height;
-    }
-    else if (den==5) {
-      bitmap_bits = dot_5_bitmap_bits;
-      bitmap_width = dot_5_bitmap_width;
-      bitmap_height = dot_5_bitmap_height;
-    }
-    else if (den==4) {
-      bitmap_bits = dot_4_bitmap_bits;
-      bitmap_width = dot_4_bitmap_width;
-      bitmap_height = dot_4_bitmap_height;
-    }
-    else if (den==3) {
-      bitmap_bits = dot_3_bitmap_bits;
-      bitmap_width = dot_3_bitmap_width;
-      bitmap_height = dot_3_bitmap_height;
-    }
-    else if (den==2) {
-      bitmap_bits = dot_2_bitmap_bits;
-      bitmap_width = dot_2_bitmap_width;
-      bitmap_height = dot_2_bitmap_height;
-    }
-    else if (den==1) {
-      bitmap_bits = dot_1_bitmap_bits;
-      bitmap_width = dot_1_bitmap_width;
-      bitmap_height = dot_1_bitmap_height;
-    }
-    else {
-      printf ("Error in density specification: density = %d\n",den);
-      return;
-    }
-  }
-  else if (typ==3) {
-    if (ang==0) {
-      if (den==5) {
-        bitmap_bits = line_0_5_bitmap_bits;
-        bitmap_width = line_0_5_bitmap_width;
-        bitmap_height = line_0_5_bitmap_height;
-      }
-      else if (den==4) {
-        bitmap_bits = line_0_4_bitmap_bits;
-        bitmap_width = line_0_4_bitmap_width;
-        bitmap_height = line_0_4_bitmap_height;
-      }
-      else if (den==3) {
-        bitmap_bits = line_0_3_bitmap_bits;
-        bitmap_width = line_0_3_bitmap_width;
-        bitmap_height = line_0_3_bitmap_height;
-      }
-      else if (den==2) {
-        bitmap_bits = line_0_2_bitmap_bits;
-        bitmap_width = line_0_2_bitmap_width;
-        bitmap_height = line_0_2_bitmap_height;
-      }
-      else if (den==1) {
-        bitmap_bits = line_0_1_bitmap_bits;
-        bitmap_width = line_0_1_bitmap_width;
-        bitmap_height = line_0_1_bitmap_height;
-      }
-      else {
-        printf ("Error in density specification: density = %d\n",den);
-        return;
-      }
-    }
-    else if (ang==30) {
-      if (den==5) {
-        bitmap_bits = line_30_5_bitmap_bits;
-        bitmap_width = line_30_5_bitmap_width;
-        bitmap_height = line_30_5_bitmap_height;
-      }
-      else if (den==4) {
-        bitmap_bits = line_30_4_bitmap_bits;
-        bitmap_width = line_30_4_bitmap_width;
-        bitmap_height = line_30_4_bitmap_height;
-      }
-      else if (den==3) {
-        bitmap_bits = line_30_3_bitmap_bits;
-        bitmap_width = line_30_3_bitmap_width;
-        bitmap_height = line_30_3_bitmap_height;
-      }
-      else if (den==2) {
-        bitmap_bits = line_30_2_bitmap_bits;
-        bitmap_width = line_30_2_bitmap_width;
-        bitmap_height = line_30_2_bitmap_height;
-      }
-      else if (den==1) {
-        bitmap_bits = line_30_1_bitmap_bits;
-        bitmap_width = line_30_1_bitmap_width;
-        bitmap_height = line_30_1_bitmap_height;
-      }
-      else {
-        printf ("Error in density specification: density = %d\n",den);
-        return;
-      }
-    }
-    else if (ang==45) {
-      if (den==5) {
-        bitmap_bits = line_45_5_bitmap_bits;
-        bitmap_width = line_45_5_bitmap_width;
-        bitmap_height = line_45_5_bitmap_height;
-      }
-      else if (den==4) {
-        bitmap_bits = line_45_4_bitmap_bits;
-        bitmap_width = line_45_4_bitmap_width;
-        bitmap_height = line_45_4_bitmap_height;
-      }
-      else if (den==3) {
-        bitmap_bits = line_45_3_bitmap_bits;
-        bitmap_width = line_45_3_bitmap_width;
-        bitmap_height = line_45_3_bitmap_height;
-      }
-      else if (den==2) {
-        bitmap_bits = line_45_2_bitmap_bits;
-        bitmap_width = line_45_2_bitmap_width;
-        bitmap_height = line_45_2_bitmap_height;
-      }
-      else if (den==1) {
-        bitmap_bits = line_45_1_bitmap_bits;
-        bitmap_width = line_45_1_bitmap_width;
-        bitmap_height = line_45_1_bitmap_height;
-      }
-      else {
-        printf ("Error in density specification: density = %d\n",den);
-        return;
-      }
-    }
-    else if (ang==60) {
-      if (den==5) {
-        bitmap_bits = line_60_5_bitmap_bits;
-        bitmap_width = line_60_5_bitmap_width;
-        bitmap_height = line_60_5_bitmap_height;
-      }
-      else if (den==4) {
-        bitmap_bits = line_60_4_bitmap_bits;
-        bitmap_width = line_60_4_bitmap_width;
-        bitmap_height = line_60_4_bitmap_height;
-      }
-      else if (den==3) {
-        bitmap_bits = line_60_3_bitmap_bits;
-        bitmap_width = line_60_3_bitmap_width;
-        bitmap_height = line_60_3_bitmap_height;
-      }
-      else if (den==2) {
-        bitmap_bits = line_60_2_bitmap_bits;
-        bitmap_width = line_60_2_bitmap_width;
-        bitmap_height = line_60_2_bitmap_height;
-      }
-      else if (den==1) {
-        bitmap_bits = line_60_1_bitmap_bits;
-        bitmap_width = line_60_1_bitmap_width;
-        bitmap_height = line_60_1_bitmap_height;
-      }
-      else {
-        printf ("Error in density specification: density = %d\n",den);
-        return;
-      }
-    }
-    else if (ang==-30) {
-      if (den==5) {
-        bitmap_bits = line_120_5_bitmap_bits;
-        bitmap_width = line_120_5_bitmap_width;
-        bitmap_height = line_120_5_bitmap_height;
-      }
-      else if (den==4) {
-        bitmap_bits = line_120_4_bitmap_bits;
-        bitmap_width = line_120_4_bitmap_width;
-        bitmap_height = line_120_4_bitmap_height;
-      }
-      else if (den==3) {
-        bitmap_bits = line_120_3_bitmap_bits;
-        bitmap_width = line_120_3_bitmap_width;
-        bitmap_height = line_120_3_bitmap_height;
-      }
-      else if (den==2) {
-        bitmap_bits = line_120_2_bitmap_bits;
-        bitmap_width = line_120_2_bitmap_width;
-        bitmap_height = line_120_2_bitmap_height;
-      }
-      else if (den==1) {
-        bitmap_bits = line_120_1_bitmap_bits;
-        bitmap_width = line_120_1_bitmap_width;
-        bitmap_height = line_120_1_bitmap_height;
-      }
-      else {
-        printf ("Error in density specification: density = %d\n",den);
-        return;
-      }
-    }
-    else if (ang==-45) {
-      if (den==5) {
-        bitmap_bits = line_135_5_bitmap_bits;
-        bitmap_width = line_135_5_bitmap_width;
-        bitmap_height = line_135_5_bitmap_height;
-      }
-      else if (den==4) {
-        bitmap_bits = line_135_4_bitmap_bits;
-        bitmap_width = line_135_4_bitmap_width;
-        bitmap_height = line_135_4_bitmap_height;
-      }
-      else if (den==3) {
-        bitmap_bits = line_135_3_bitmap_bits;
-        bitmap_width = line_135_3_bitmap_width;
-        bitmap_height = line_135_3_bitmap_height;
-      }
-      else if (den==2) {
-        bitmap_bits = line_135_2_bitmap_bits;
-        bitmap_width = line_135_2_bitmap_width;
-        bitmap_height = line_135_2_bitmap_height;
-      }
-      else if (den==1) {
-        bitmap_bits = line_135_1_bitmap_bits;
-        bitmap_width = line_135_1_bitmap_width;
-        bitmap_height = line_135_1_bitmap_height;
-      }
-      else {
-        printf ("Error in density specification: density = %d\n",den);
-        return;
-      }
-    }
-    else if (ang==-60) {
-      if (den==5) {
-        bitmap_bits = line_150_5_bitmap_bits;
-        bitmap_width = line_150_5_bitmap_width;
-        bitmap_height = line_150_5_bitmap_height;
-      }
-      else if (den==4) {
-        bitmap_bits = line_150_4_bitmap_bits;
-        bitmap_width = line_150_4_bitmap_width;
-        bitmap_height = line_150_4_bitmap_height;
-      }
-      else if (den==3) {
-        bitmap_bits = line_150_3_bitmap_bits;
-        bitmap_width = line_150_3_bitmap_width;
-        bitmap_height = line_150_3_bitmap_height;
-      }
-      else if (den==2) {
-        bitmap_bits = line_150_2_bitmap_bits;
-        bitmap_width = line_150_2_bitmap_width;
-        bitmap_height = line_150_2_bitmap_height;
-      }
-      else if (den==1) {
-        bitmap_bits = line_150_1_bitmap_bits;
-        bitmap_width = line_150_1_bitmap_width;
-        bitmap_height = line_150_1_bitmap_height;
-      }
-      else {
-        printf ("Error in density specification: density = %d\n",den);
-        return;
-      }
-    }
-    else if (ang==90||ang==-90) {
-      if (den==5) {
-        bitmap_bits = line_90_5_bitmap_bits;
-        bitmap_width = line_90_5_bitmap_width;
-        bitmap_height = line_90_5_bitmap_height;
-      }
-      else if (den==4) {
-        bitmap_bits = line_90_4_bitmap_bits;
-        bitmap_width = line_90_4_bitmap_width;
-        bitmap_height = line_90_4_bitmap_height;
-      }
-      else if (den==3) {
-        bitmap_bits = line_90_3_bitmap_bits;
-        bitmap_width = line_90_3_bitmap_width;
-        bitmap_height = line_90_3_bitmap_height;
-      }
-      else if (den==2) {
-        bitmap_bits = line_90_2_bitmap_bits;
-        bitmap_width = line_90_2_bitmap_width;
-        bitmap_height = line_90_2_bitmap_height;
-      }
-      else if (den==1) {
-        bitmap_bits = line_90_1_bitmap_bits;
-        bitmap_width = line_90_1_bitmap_width;
-        bitmap_height = line_90_1_bitmap_height;
-      }
-      else {
-        printf ("Error in density specification: density = %d\n",den);
-        return;
-      }
-    }
-    else {
-      printf ("Error in angle specification: angle = %d\n",ang);
-      return;
-    }
-  }
-  else {
-    printf ("Error in fill specification: type = %d\n",typ);
-    return;
-  }
-
-  if (typ>1) {
-    stipple_pixmap = XCreateBitmapFromData(display, win, (char*)bitmap_bits,
-		     bitmap_width, bitmap_height);
-    XSetStipple(display, gc, stipple_pixmap);
-    XSetFillStyle(display, gc, FillStippled);
-  }
-}
-
-/*gl 980114 - function to save window info gl*/
-/*
- * int
- * win_data ---  Saves current window information 
- */
-
-int win_data (struct xinfo *xinf) {
-  int absx, absy;
-  Window dummy;
-  XWindowAttributes result;
-
-  if (display == (Display *) NULL || win == (Window) NULL) return 0;
-  if (!XGetWindowAttributes (display, win, &result) ) return 0;
-  if (!XTranslateCoordinates (display, win, RootWindow (display, snum), 0, 0,
-			      &absx, &absy, &dummy) ) return 0;
-  xinf->winid=(int)win;
-  xinf->winw=result.width;  
-  xinf->winh=result.height;  
-  xinf->winb=result.border_width;
-  xinf->winx=absx;  
-  xinf->winy=absy;  
-  return 1;
-}
- 
-/* Given x,y page location, return screen pixel location */
-
-void gxdgcoord (gadouble x, gadouble y, gaint *i, gaint *j) {
-  if (batch) {
-    *i = -999;
-    *j = -999;
-    return;
-  }
-  *i = (gaint)(x*xscl+0.5);
-  *j = height - (gaint)(y*yscl+0.5);
-}
-
-void gxdimg(gaint *im, gaint imin, gaint jmin, gaint isiz, gaint jsiz) {
-int i,j,col;
-
-  if (batch) return;
-
-  image = XGetImage(display, drwbl, imin, jmin, isiz, jsiz, AllPlanes, XYPixmap);
-  if (image==NULL) {
-    printf ("Unable to allocate image file for gxout imap. \n");
-    return;
-  }
-
-  for (j=0; j<jsiz; j++) {
-    for (i=0; i<isiz; i++) {
-       col = *(im+j*isiz+i);
-       if (col<255) XPutPixel(image,i,j,cvals[col]);
-    }
-  }
-  XPutImage(display, drwbl, gc, image, 0, 0, imin, jmin, isiz, jsiz);
-  XDestroyImage(image);
-}
diff --git a/src/gxX.c b/src/gxX11.c
similarity index 97%
copy from src/gxX.c
copy to src/gxX11.c
index ff69b67..b0a369a 100644
--- a/src/gxX.c
+++ b/src/gxX11.c
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 /* Include ./configure's header file */
@@ -63,8 +62,7 @@ void Pixmap_Dump(Window, FILE *, gaint, gaint, gaint, gaint);
 static gaint batch=0;                       /* Batch mode? */
 static gaint wchose=0;                      /* Controls technique for wide lines 1= s/w 0 X server*/
 static gaint lcolor,lwidth,owidth;          /* Current attributes */
-static gaint grflg;                         /* Greyscale flag */
-static gaint devbck;                        /* Device background */
+static gaint devbck;                        /* Device background, query the graphics database to get this */
 static gadouble xscl,yscl;                  /* Window Scaling */
 static gaint xxx,yyy;                       /* Old position */
 static gadouble xsize, ysize;               /* User specified size */
@@ -79,7 +77,6 @@ static gaint greens[16] = {  0,255, 60,220, 60,200,  0,220,130,  0,230,160,175,2
 static gaint blues[16]  = {  0,255, 60,  0,255,200,130, 50, 40,200, 50,255, 45,140,220,170};
 
 static gaint greys[16] = {0,255,215,140,80,110,230,170,200,50,155,95,185,125,65,177};
-static gaint grrev[16] = {0,1,14,3,8,7,9,5,4,6,13,12,11,10,2,15};
 
 /* Various arrays are kept for structures that describe displayed
    widgets.  This information is kept in static arrays for
@@ -117,12 +114,10 @@ static Pixmap pmaps[200];
 static XImage *image;
 static Drawable drwbl;
 static char *window_name = "GrADS " GRADS_VERSION "";
-/*char *window_name = "GrADS";*/
 static char *display_name = NULL; 
 static char *icon_name = "GrADS";
 static Pixmap icon_pixmap;
 static XSizeHints size_hints;
-/* static XIconSize *size_list; */
 static gaint argc;
 static char **argv;
 static char *args[4];
@@ -175,6 +170,7 @@ void gxdgeo (char *arg) {
 }
 
 void gxdbgn (gadouble xsz, gadouble ysz) {
+struct gxdbquery dbq;
 gaint dw, dh, flag, i, ipos, jpos, border;
 char **flist,*xfnam;
 
@@ -186,6 +182,7 @@ char **flist,*xfnam;
   for (i=0; i<200; i++) { dmu[i].num = -1; dmu2[i].num = -1; }
   for (i=0; i<512; i++) { obj[i].type = -1; obj2[i].type = -1; }
   obnum = 0; obnum2 = 0;
+
   evbase = NULL;
   excnt = 0;
 
@@ -256,7 +253,8 @@ char **flist,*xfnam;
   win = XCreateSimpleWindow(display, RootWindow(display,snum),
         ipos, jpos, dw, dh, border,
         WhitePixel(display, snum), BlackPixel(display,snum));
-  devbck = 0;
+  gxdbck(0);    /* set background to zero, and then update local variable devbck */
+  devbck = gxdbkq();
 
   /* Set up icon pixmap */
 
@@ -271,9 +269,12 @@ char **flist,*xfnam;
   /* Set colors */
 
   for (i=0; i<16; i++) {
-    cell.red = reds[i]*256;
-    cell.blue = blues[i]*256;
-    cell.green = greens[i]*256;
+
+    /* get rgb values for each color from the graphics database */
+    gxdbqcol(i, &dbq);
+    cell.red   = dbq.red*256;
+    cell.blue  = dbq.blue*256;
+    cell.green = dbq.green*256;
     if (XAllocColor(display, cmap, &cell)) {
       cvals[i] = cell.pixel;
     } else {
@@ -307,7 +308,6 @@ char **flist,*xfnam;
   lwidth = 1;
   owidth = 0;
   lcolor = 1;
-  grflg = 0;
 
   /* Display Window */
 
@@ -452,10 +452,6 @@ char **flist,*xfnam;
 
 }
 
-void gxgrey (gaint flag) {
-  grflg = flag;
-}
-
 void gxdend (void) {
   XFreeGC(display, gc);
   XCloseDisplay(display);
@@ -479,6 +475,7 @@ gaint i;
     return;
   }
   if (iact==0 || iact==1 || iact==7) {
+    devbck = gxdbkq();
     XSetForeground(display, gc, cvals[devbck]);
     XFillRectangle (display, drwbl, gc, 0, 0, width, height);
     XSetForeground(display, gc, cvals[lcolor]);
@@ -486,9 +483,7 @@ gaint i;
     obnum = 0;
   }
 
-  /* Flush X event queue.  If iact is 7, keep the event info,
-     otherwise discard it. */
-
+  /* Flush X event queue.  If iact is 7, keep the event info, otherwise discard it. */
   if (iact==7) gxdeve(0);
   else {
     while (XCheckMaskEvent(display, ButtonReleaseMask | ButtonPressMask |
@@ -507,7 +502,6 @@ gaint i;
     }
 
     /* Flush GrADS event queue */
-
     geve = evbase;
     while (geve) {
       geve2 = geve->forw;
@@ -559,6 +553,8 @@ gaint i,j,ii,rc,wflg,button,eflg,idm,rdrflg;
     if (!rc) break;
 
     switch  (report.type) {
+    case ButtonRelease:  
+      break;
     case Expose:
       if (excnt>0) excnt--;
       else if (!bsflg) rdrflg = 1;
@@ -589,10 +585,8 @@ gaint i,j,ii,rc,wflg,button,eflg,idm,rdrflg;
       geve->x = xsize*((gadouble)i)/width;
       geve->y = ysize - ysize*((gadouble)j)/height;
       geve->type = 0;
-
       /* Scan to see if point-click event was on one of our
          widgets.  Handling depends on what is clicked on. */
-
       ii = 0;
       while (ii<512 && obj[ii].type>-1) {
         if (obj[ii].type!=0 && i>obj[ii].i1 && i<obj[ii].i2 &&
@@ -663,59 +657,65 @@ gaint i;
 
 }
 
+/* sets color to new value */
+
 void gxdcol (gaint clr) {
   if (clr<0) clr=0;
   if (clr>255) clr=255;
+  devbck = gxdbkq();
   if (devbck) {
     if (clr==0) clr = 1;
     else if (clr==1) clr = 0;
   }
-  if (clr<16 && grflg) {
-    if (devbck) clr = grrev[clr];
-    clr+=256; 
-  }
   if (!cused[clr] && !cmach[clr]) clr=15; 
   XSetForeground(display, gc, cvals[clr]);
   lcolor=clr;
 }
 
+/* define a new color */ 
 
-/* static void qprint(XStandardColormap* bst);  */
+gaint gxdacol(gaint clr, gaint red, gaint green, gaint blue, gaint alpha) {
+struct gxdbquery dbq;
+XStandardColormap best;
+gaint screen_num = DefaultScreen(display);
+gaint rc;
 
-gaint gxdacl (gaint clr, gaint red, gaint green, gaint blue) {
-  XStandardColormap best;
-  gaint screen_num = DefaultScreen(display);
-		
-  if (clr<16 || clr>255) return 1;
+  if (clr<16 || clr>255) return(1);
   if (cused[clr]) {
-     XFreeColors(display, cmap, &(cvals[clr]),1,0);
-     cused[clr]=0;
-  }
-  cell.red = red*256;
-  cell.blue = blue*256;
-  cell.green = green*256;
-  cmach[clr] = 0;
+    /* if this color was previously defined, release */
+    XFreeColors(display, cmap, &(cvals[clr]),1,0);
+    cused[clr]=0;
+  }
+  /* get rgb values for this color from the graphics database */
+  gxdbqcol(clr, &dbq);
+  cell.red   = dbq.red*256;
+  cell.blue  = dbq.blue*256;
+  cell.green = dbq.green*256;
+
+  cmach[clr]=0;
+  rc=2;
   if (XAllocColor(display, cmap, &cell)) {
+    /* success! */
     cvals[clr] = cell.pixel;
     cused[clr] = 1;
-  } else if (XGetStandardColormap(display, 
-             RootWindow(display,screen_num), &best, XA_RGB_BEST_MAP)) {
+    rc=0;
+  } 
+  else if (XGetStandardColormap(display,RootWindow(display,screen_num),&best,XA_RGB_BEST_MAP)) {
+    /* try best match from standard colormap */
     if (gxbcol(&best, &cell)) {
+      /* plan B success! */
       cvals[clr] = cell.pixel;
       cmach[clr] = 1;
-      printf ("Color Match.  Color number = %i\n",clr);
-    } else {
-      printf ("Color Matching Error.  Color number = %i\n",clr);
-    }
-  } else {
-    printf ("Color Map Allocation Error.  Color number = %i\n",clr);
-  }
-  if (cused[clr] == 0 || cmach[clr] == 1) {
-    return 0;
+      rc=1;
+    } 
+    else printf ("Color Matching Error.  Color number = %i\n",clr);
   } 
-  return(1);
+  else printf ("Color Map Allocation Error.  Color number = %i\n",clr);
+  return(rc);
 }
 
+
+/* Assign best rgb to color number from standard colormap */
 gaint gxbcol (XStandardColormap* best, XColor * cell) {
   XColor color, colors[256];
   unsigned long bestpixel=0;
@@ -725,29 +725,22 @@ gaint gxbcol (XStandardColormap* best, XColor * cell) {
   for (i=0; i<256; i++) {
     colors[i].pixel = i; 
   }
-
   XQueryColors(display, cmap, colors, 256);
-
   min = 65536;
-
   for (i=0; i<256; i++) {
     d = abs(cell->red - colors[i].red)
       + abs(cell->green - colors[i].green) 
       + abs(cell->blue - colors[i].blue);
     if (d<min) { min = d;  bestpixel = i; }
   }
-
   if (bestpixel < 256) {
-
     cell->pixel = bestpixel; 
     color.pixel = bestpixel; 
     XQueryColor(display, cmap, &color);
     return 1;
-
   } else {
     return 0;
   }	
-
 }
 
 void gxdwid (gaint wid){                 /* Set width     */
@@ -793,6 +786,7 @@ gaint w,h;
   if (QLength(display)&&rstate) gxdeve(0);
 }
 
+/* Draw a filled rectangle */
 void gxdrec (gadouble x1, gadouble x2, gadouble y1, gadouble y2) {
 gaint i1,i2,j1,j2;
 
@@ -832,6 +826,7 @@ gaint i;
   }
   dblmode = 1;
   drwbl = pmap;
+  devbck = gxdbkq();
   XSetForeground(display, gc, cvals[devbck]);
   XFillRectangle (display, drwbl, gc, 0, 0, width, height);
   XSetForeground(display, gc, cvals[lcolor]);
@@ -881,6 +876,7 @@ void gxdswp (void) {
   if (dblmode) {
     XCopyArea (display, pmap, win, gc, 0, 0, width, height, 0, 0);
   }
+  devbck = gxdbkq();
   XSetForeground(display, gc, cvals[devbck]);
   XFillRectangle (display, drwbl, gc, 0, 0, width, height);
   XSetForeground(display, gc, cvals[lcolor]);
@@ -921,17 +917,6 @@ void gxdxsz (gaint xx, gaint yy) {
   gxdeve(2);
 }
 
-/* set hardware background color */
-
-void gxdbck (gaint flg) {
-
-  devbck = flg;
-  if (devbck>1) devbck = 1;
-}
-
-gaint gxdbkq  (void) {
-   return (devbck);
-}
 
 /* Routine to display a button widget */
 /* Flags are cumbersome, sigh....
@@ -1204,6 +1189,7 @@ void gxdsfn(void) {
 void gxdrdw (void) {
 int i;
   rstate = 0;
+  devbck = gxdbkq();
   XSetForeground(display, gc, cvals[devbck]);
   XFillRectangle (display, drwbl, gc, 0, 0, width, height);
   XSetForeground(display, gc, cvals[lcolor]);
@@ -1222,18 +1208,19 @@ int i;
       return;
     }
     drwbl = win;
+    devbck = gxdbkq();
     XSetForeground(display, gc, cvals[devbck]);
     XFillRectangle (display, drwbl, gc, 0, 0, width, height);
     XFillRectangle (display, pmap, gc, 0, 0, width, height);
     XSetForeground(display, gc, cvals[lcolor]);
     for (i=0; i<512; i++) obj2[i].type = -1;
     obnum2 = 0;
-    gxhdrw(1);
+    gxhdrw(1,0);
     gxrdrw(1);
     dblmode = 1;
     drwbl = pmap;
   }
-  gxhdrw(0);
+  gxhdrw(0,0);
   gxrdrw(0);
   rstate = 1;
 }
@@ -3163,3 +3150,20 @@ int i,j,col;
   XPutImage(display, drwbl, gc, image, 0, 0, imin, jmin, isiz, jsiz);
   XDestroyImage(image);
 }
+
+gadouble gxdch (char ch, gaint fn, gadouble x, gadouble y, gadouble w, gadouble h, gadouble rot) {
+  return (-999); 
+}
+gadouble gxdqchl (char ch, gaint fn, gadouble w) {
+  return (-999); 
+}
+void gxdopt (gaint opt) {
+}
+void gxsetpatt(gaint pnum) {
+}
+void gxdsignal (gaint sig) {
+}
+void gxdXflush (void) {
+}
+void gxdclip (gadouble xlo, gadouble xhi, gadouble ylo, gadouble yhi) {
+}
diff --git a/src/gxchpl.c b/src/gxchpl.c
index 34f3dbe..51385d9 100644
--- a/src/gxchpl.c
+++ b/src/gxchpl.c
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 /* Authored by B. Doty */
@@ -24,11 +23,19 @@
 #include "gatypes.h"
 #include "gx.h"
 
+/* function prototypes */
+gadouble gxchplc (char, gaint, gadouble, gadouble, gadouble, gadouble, gadouble);
+gadouble gxchqlc (char, gaint, gadouble);
+void gxchplo (char *, int, gadouble, gadouble, gadouble, gadouble, gadouble);
+void houtch (char, gaint, gadouble, gadouble, gadouble, gadouble, gadouble);
+void gree();
+
+/* local variables */
 static char *fch[10];     /* Pointers to font data once it is read in */
 static gaint *foff[10];   /* Pointers to character offsets */
 static gaint *flen[10];   /* Pointers to character lengths */
 static gaint dfont;       /* Default font */
-void gree();
+
 
 /* Initialize */
 
@@ -41,136 +48,142 @@ gaint i;
 /* Change default font */
 
 void gxchdf (gaint df) {
-  if (df<0 || df>9) return;
+  if (df<0 || df>99) return;
   dfont = df;
 }
 
 /* Plot character string */
 
 void gxchpl (char *chrs, int len, gadouble x, gadouble y, gadouble height, gadouble width, gadouble angle) {
-gadouble xc,yc,xscl,yscl,xs,ys,w,d,ang,rx,ry,yoff;
-gaint i,fn,ic,jc,cnt,ipen,supsub;
-char *cdat;
-
-  xscl = width/21.0;
-  yscl = height/22.0;
+gadouble h,w,xoff,yoff,wact;
+gaint fn, supsub, nfn;
+ 
   fn = dfont;
-  angle = angle*M_PI/180;
+  angle = angle * M_PI/180.0;    /* convert angle from degrees to radians */
   supsub = 0;
   while (*chrs!='\0' && len>0) {
     while (*chrs=='`') {
-      if (*(chrs+1)>='0' && *(chrs+1)<='9') {
+      if (*(chrs+1)>='0' && *(chrs+1)<='9') {    /* get 1-digit font number */
         fn = (gaint)*(chrs+1) - 48;
         chrs+=2;
         len-=2;
-      } else if (*(chrs+1)=='a') {
+      } else if (*(chrs+1)=='a') {    /* superscript */
         supsub = 1;
         chrs+=2; len-=2;
-      } else if (*(chrs+1)=='b') {
+      } else if (*(chrs+1)=='b') {    /* subscript */
         supsub = 2;
         chrs+=2; len-=2;
-      } else if (*(chrs+1)=='n') {
+      } else if (*(chrs+1)=='n') {    /* normal */
         supsub = 0;
         chrs+=2; len-=2;
+      } else if (*(chrs+1)=='f') {    /* get 2-digit font number */
+        if (len>3) {
+          nfn = 10*((gaint)*(chrs+2) - 48) + ((gaint)*(chrs+3) - 48);
+          if (nfn>=0 && nfn<100) fn = nfn;
+        }
+        chrs+=4;
+        len-=4;
       } else break;
     }
     if (*chrs!='\0' && len>0) {
-      if (angle==0.0) {           /* Fast path for ang=0 */
-        cdat = gxchgc ( (gaint)*(chrs), fn, &cnt);
-        if (cdat==NULL) return;
-        ic = (gaint)(*(cdat+3)) - 82;
-        jc = (gaint)(*(cdat+4)) - 82;
-        if (supsub) {
-          xs = xscl*0.45; ys = yscl*0.45;
-          if (supsub==1) yoff = height*0.35;
-          else yoff = -1.0*height*0.42;
-        } else {
-          xs = xscl; ys = yscl; yoff = 0.0;
-        }
-        w = (gadouble)(jc-ic) * xs * 1.05;
-        xc= x + w/2.0;
-        yc = y + height*0.42 + yoff;
-        cdat += 5;
-        ipen = 3;
-        for (i=1; i<cnt; i++) {
-          ic = (gaint)*cdat;
-          jc = (gaint)*(cdat+1);
-          if (ic==32) ipen = 3;
-          else {
-            ic = ic - 82;
-            jc = jc - 82;
-            rx = xc + ((gadouble)ic)*xs;
-            ry = yc - ((gadouble)jc)*ys;
-            if (ipen==3) gxmove (rx,ry);
-            else gxdraw (rx,ry);
-            ipen = 2;
-          }
-          cdat += 2;
-        }
-        x = x + w;
-        chrs++; len--;
+      if (supsub) {
+	/* adjust size and position for superscripts and subscripts */
+        h = height*0.45; w = width*0.45;
+        if (supsub==1) yoff = height*0.58;
+        else yoff = -0.20*height;
       } else {
-        cdat = gxchgc ( (gaint)*(chrs), fn, &cnt);
-        if (cdat==NULL) return;
-        ic = (gaint)(*(cdat+3)) - 82;
-        jc = (gaint)(*(cdat+4)) - 82;
-        if (supsub) {
-          xs = xscl*0.45; ys = yscl*0.45;
-          if (supsub==1) yoff = height*0.35;
-          else yoff = -1.0*height*0.42;
-        } else {
-          xs = xscl; ys = yscl; yoff = 0.0;
-        }
-        w = (gadouble)(jc-ic) * xs * 1.05;
-        d = hypot(w/2.0,height*0.42+yoff);
-        ang = atan2(height*0.42+yoff,w/2.0)+angle;
-        xc = x + d*cos(ang);
-        yc = y + d*sin(ang);
-        cdat += 5;
-        ipen = 3;
-        for (i=1; i<cnt; i++) {
-          ic = (gaint)*cdat;
-          jc = (gaint)*(cdat+1);
-          if (ic==32) ipen = 3;
-          else {
-            ic = ic - 82;
-            jc = jc - 82;
-            rx = ((gadouble)ic)*xs;
-            ry = -1.0*((gadouble)jc)*ys;
-            if (rx==0.0 && ry==0.0) {
-              d = 0.0; ang = 0.0;
-            } else {
-              d = hypot(rx,ry);
-              ang = atan2(ry,rx)+angle;
-            }
-            rx = xc + d*cos(ang);
-            ry = yc + d*sin(ang);
-            if (ipen==3) gxmove (rx,ry);
-            else gxdraw (rx,ry);
-            ipen = 2;
-          }
-          cdat += 2;
-        }
-        x = x + w*cos(angle);
-        y = y + w*sin(angle);
-        chrs++; len--;
+        h = height; w = width; yoff = 0.0;
       }
+      xoff = yoff*sin(angle);
+      yoff = yoff*cos(angle);
+
+      /* plot the character */
+      wact = gxdrawch (*chrs, fn, x-xoff, y+yoff, w, h, angle);
+      if (wact < -900.0 && fn<6) {
+	/* draw with Hershey font */
+        wact = gxchplc (*chrs, fn, x-xoff, y+yoff, w, h, angle); 
+        if (wact < -900.0) return;
+      } 
+      x = x + wact*cos(angle);
+      y = y + wact*sin(angle);
+
+      chrs++; len--;
     }
   }
 }
 
-/* Figure out the length of a character string, without
-   plotting it */
+/* Get actual width of a single character in the indicated Hershey font */
 
-gaint gxchln (char *chrs, gaint len, gadouble width, gadouble *w) {
-int fn,ic,jc,supsub;
-gadouble xscl,xs;
+gadouble gxchqlc (char ccc, gaint fn, gadouble width) {
+gadouble xs,w;
+gaint cnt,ic,jc;
 char *cdat;
 
-  *w = 0.0;
-  xscl = width/21.0;
+  xs = width/21.0;
+  cdat = gxchgc ( (gaint)ccc, fn, &cnt);
+  if (cdat==NULL) return (-999.9);
+  ic = (gaint)(*(cdat+3)) - 82;
+  jc = (gaint)(*(cdat+4)) - 82;
+  w = (gadouble)(jc-ic) * xs * 1.05;
+  return (w);
+}
+
+/* plot a single char in the indicated hershey font with the indicated location, size, and angle, 
+   and return the distance to advance after plotting */
+
+gadouble gxchplc (char ccc, gaint fn, gadouble x, gadouble y, gadouble width, gadouble height, gadouble angle) {
+gadouble xs,ys,w,d,xc,yc,ang,rx,ry;
+gaint i,ic,jc,cnt,ipen;
+char *cdat;
+
+  xs = width/21.0;
+  ys = height/22.0;
+  cdat = gxchgc ( (gaint)ccc, fn, &cnt);
+  if (cdat==NULL) return (-999.9);
+  ic = (gaint)(*(cdat+3)) - 82;
+  jc = (gaint)(*(cdat+4)) - 82;
+  w = (gadouble)(jc-ic) * xs * 1.05;
+  d = hypot(w/2.0,height*0.42);
+  ang = atan2(height*0.42,w/2.0)+angle;
+  xc = x + d*cos(ang);
+  yc = y + d*sin(ang);
+  cdat += 5;
+  ipen = 3;
+  for (i=1; i<cnt; i++) {
+    ic = (gaint)*cdat;
+    jc = (gaint)*(cdat+1);
+    if (ic==32) ipen = 3;
+    else {
+      ic = ic - 82;
+      jc = jc - 82;
+      rx = ((gadouble)ic)*xs;
+      ry = -1.0*((gadouble)jc)*ys;
+      if (rx==0.0 && ry==0.0) {
+        d = 0.0; ang = 0.0;
+      } else {
+        d = hypot(rx,ry);
+        ang = atan2(ry,rx)+angle;
+      }
+      rx = xc + d*cos(ang);
+      ry = yc + d*sin(ang);
+      if (ipen==3) gxmove (rx,ry);
+      else gxdraw (rx,ry);
+      ipen = 2;
+    }
+    cdat += 2;
+  }
+  return(w);
+}
+
+/* Determine the length of a character string without plotting it. */
+
+gaint gxchln (char *chrs, gaint len, gadouble width, gadouble *wret) {
+gadouble w,wact,cw;
+gaint fn, supsub, nfn;
+ 
   fn = dfont;
   supsub = 0;
+  cw = 0;
   while (*chrs!='\0' && len>0) {
     while (*chrs=='`') {
       if (*(chrs+1)>='0' && *(chrs+1)<='9') {
@@ -186,18 +199,35 @@ char *cdat;
       } else if (*(chrs+1)=='n') {
         supsub = 0;
         chrs+=2; len-=2;
+      } else if (*(chrs+1)=='f') {
+        if (len>3) {
+          nfn = 10*((gaint)*(chrs+2) - 48) + ((gaint)*(chrs+3) - 48);
+          if (nfn>=0 && nfn<100) fn = nfn;
+        }
+        chrs+=4;
+        len-=4;
       } else break;
     }
-    cdat = gxchgc ((gaint)*(chrs), fn, &ic);
-    if (cdat==NULL) return(1);
-    ic = (gaint)(*(cdat+3)) - 82;
-    jc = (gaint)(*(cdat+4)) - 82;
-    if (supsub) xs = xscl*0.45;
-    else xs = xscl;
-    *w = *w + (gadouble)(jc-ic) * xs * 1.05;
-    chrs++; len--;
+    if (*chrs!='\0' && len>0) {
+      if (supsub) {
+        w = width*0.45;
+      } else {
+        w = width;
+      }
+
+      /* First see if the rendering back end wants to plot this, or punt.
+         If it wants to punt, we get a -999 back, so we use Hershey instead  */
+      wact = gxqchl (*chrs, fn, w);
+      if (wact < -900.0) {
+        wact = gxchqlc (*chrs, fn, w); 
+      }
+      cw = cw + wact;
+
+      chrs++; len--;
+    }
   }
-  return 0;
+  *wret = cw;
+  return (cw);
 }
 
 /* Get location and length of particular character info
@@ -308,3 +338,115 @@ char buff[20],*fname,*fdat;
 
   return(0);
 }
+
+void gxchplo (char *chrs, int len, gadouble x, gadouble y, gadouble height, gadouble width, gadouble angle) {
+gadouble xc,yc,xscl,yscl,xs,ys,w,d,ang,rx,ry,yoff;
+gaint i,fn,ic,jc,cnt,ipen,supsub;
+char *cdat;
+
+  xscl = width/21.0;
+  yscl = height/22.0;
+  fn = dfont;
+  angle = angle * 3.1416/180.0;
+  supsub = 0;
+  while (*chrs!='\0' && len>0) {
+    while (*chrs=='`') {
+      if (*(chrs+1)>='0' && *(chrs+1)<='9') {
+        fn = (gaint)*(chrs+1) - 48;
+        chrs+=2;
+        len-=2;
+      } else if (*(chrs+1)=='a') {
+        supsub = 1;
+        chrs+=2; len-=2;
+      } else if (*(chrs+1)=='b') {
+        supsub = 2;
+        chrs+=2; len-=2;
+      } else if (*(chrs+1)=='n') {
+        supsub = 0;
+        chrs+=2; len-=2;
+      } else break;
+    }
+    if (*chrs!='\0' && len>0) {
+      if (angle==0.0) {           /* Fast path for ang=0 */
+        cdat = gxchgc ( (gaint)*(chrs), fn, &cnt);
+        if (cdat==NULL) return;
+        ic = (gaint)(*(cdat+3)) - 82;
+        jc = (gaint)(*(cdat+4)) - 82;
+        if (supsub) {
+          xs = xscl*0.45; ys = yscl*0.45;
+          if (supsub==1) yoff = height*0.35;
+          else yoff = -1.0*height*0.42;
+        } else {
+          xs = xscl; ys = yscl; yoff = 0.0;
+        }
+        w = (gadouble)(jc-ic) * xs * 1.05;
+        xc= x + w/2.0;
+        yc = y + height*0.42 + yoff;
+        cdat += 5;
+        ipen = 3;
+        for (i=1; i<cnt; i++) {
+          ic = (gaint)*cdat;
+          jc = (gaint)*(cdat+1);
+          if (ic==32) ipen = 3;
+          else {
+            ic = ic - 82;
+            jc = jc - 82;
+            rx = xc + ((gadouble)ic)*xs;
+            ry = yc - ((gadouble)jc)*ys;
+            if (ipen==3) gxmove (rx,ry);
+            else gxdraw (rx,ry);
+            ipen = 2;
+          }
+          cdat += 2;
+        }
+        x = x + w;
+        chrs++; len--;
+      } else {
+        cdat = gxchgc ( (gaint)*(chrs), fn, &cnt);
+        if (cdat==NULL) return;
+        ic = (gaint)(*(cdat+3)) - 82;
+        jc = (gaint)(*(cdat+4)) - 82;
+        if (supsub) {
+          xs = xscl*0.45; ys = yscl*0.45;
+          if (supsub==1) yoff = height*0.35;
+          else yoff = -1.0*height*0.42;
+        } else {
+          xs = xscl; ys = yscl; yoff = 0.0;
+        }
+        w = (gadouble)(jc-ic) * xs * 1.05;
+        d = hypot(w/2.0,height*0.42+yoff);
+        ang = atan2(height*0.42+yoff,w/2.0)+angle;
+        xc = x + d*cos(ang);
+        yc = y + d*sin(ang);
+        cdat += 5;
+        ipen = 3;
+        for (i=1; i<cnt; i++) {
+          ic = (gaint)*cdat;
+          jc = (gaint)*(cdat+1);
+          if (ic==32) ipen = 3;
+          else {
+            ic = ic - 82;
+            jc = jc - 82;
+            rx = ((gadouble)ic)*xs;
+            ry = -1.0*((gadouble)jc)*ys;
+            if (rx==0.0 && ry==0.0) {
+              d = 0.0; ang = 0.0;
+            } else {
+              d = hypot(rx,ry);
+              ang = atan2(ry,rx)+angle;
+            }
+            rx = xc + d*cos(ang);
+            ry = yc + d*sin(ang);
+            if (ipen==3) gxmove (rx,ry);
+            else gxdraw (rx,ry);
+            ipen = 2;
+          }
+          cdat += 2;
+        }
+        x = x + w*cos(angle);
+        y = y + w*sin(angle);
+        chrs++; len--;
+      }
+    }
+  }
+}
diff --git a/src/gxcntr.c b/src/gxcntr.c
index bf76043..04a89a2 100644
--- a/src/gxcntr.c
+++ b/src/gxcntr.c
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 /* qqq resolve gxdraw vs gxsdrw issue for cterp off */
@@ -143,7 +142,9 @@ if (lwksiz<iw*jw*2) {                  /* If storage inadaquate then */
   if (fwksiz<500) fwksiz=500;          /* Insure big enough for small grids */
   sz = fwksiz*sizeof(gadouble);
   fwk = (gadouble *)galloc(sz,"fwk");    /* Allocate fwk   */
-  if (lwk==NULL) {
+  /* JMA bug reported by Michael Bala in email dated 10/28/2014 -- was checking lwk instead of fwk 
+     unable to verify if this fixed the problem */
+  if (fwk==NULL) {
     printf ("Error in GXCLEV: Unable to allocate storage \n");
     gree (lwk,"c3");
     lwk = NULL;
@@ -733,63 +734,58 @@ void gxclab (gadouble csize, gaint flag, gaint colflg) {
 gadouble x,y,xy[10],xd1,xd2,yd1,yd2,w,h,buff;
 gaint i,lablen,colr,bcol,fcol;
 
-if (!flag) { gxlabn=0; return; }
-colr = gxqclr();
-for (i=0; i<gxlabn; i++ ) {
-  lablen=strlen(gxlabv[i]);
-  bcol = gxqbck();
-  h = csize*1.2;                     /* set label height */
-  w = 0.2;
-  gxchln (gxlabv[i],lablen,csize,&w);  /* get label width */
-  if (gxlabs[i]==0.0) {              /* contour label is not rotated */
-    x = gxlabx[i] - (w/2.0);         /* adjust reference point */
-    y = gxlaby[i] - (h/2.0);
-    gxcolr (bcol);
-    buff=h*0.2;     /* add a buffer above and below the string, already padded in X */
-    gxrecf (x, x+w, y-buff, y+h+buff);   /* draw the background rectangle,  */
-    if (colflg>-1) fcol = colflg;
-    else fcol = gxlabc[i];
-    if (fcol==gxqbck()) {
-      if (gxqbck()==0) gxcolr(1);
-      else gxcolr(0);
-    }
-    else gxcolr (fcol);
-    gxchpl (gxlabv[i],lablen,x,y,h,csize,0.0);  /* draw the label */
-  } else {                           /* contour label is rotated */
-    xd1 = (h/2.0)*sin(gxlabs[i]);
-    xd2 = (w/2.0)*cos(gxlabs[i]);
-    yd1 = (h/2.0)*cos(gxlabs[i]);
-    yd2 = (w/2.0)*sin(gxlabs[i]);
-    x = gxlabx[i] - xd2 + xd1;       /* adjust reference point */
-    y = gxlaby[i] - yd2 - yd1;
-    xd1 = (h/2.0*1.6)*sin(gxlabs[i]);
-    xd2 = 1.1*(w/2.0)*cos(gxlabs[i]);
-    yd1 = (h/2.0*1.6)*cos(gxlabs[i]);
-    yd2 = 1.1*(w/2.0)*sin(gxlabs[i]);
-    xy[0] = gxlabx[i] - xd2 + xd1;   /* rotated background rectangle => polygon */
-    xy[1] = gxlaby[i] - yd2 - yd1;
-    xy[2] = gxlabx[i] - xd2 - xd1;
-    xy[3] = gxlaby[i] - yd2 + yd1;
-    xy[4] = gxlabx[i] + xd2 - xd1;
-    xy[5] = gxlaby[i] + yd2 + yd1;
-    xy[6] = gxlabx[i] + xd2 + xd1;
-    xy[7] = gxlaby[i] + yd2 - yd1;
-    xy[8] = xy[0];
-    xy[9] = xy[1];
-    gxcolr (bcol);
-    gxfill (xy,5);
-    if (colflg>-1) fcol = colflg;
-    else fcol = gxlabc[i];
-    if (fcol==gxqbck()) {
-      if (gxqbck()==0) gxcolr(1);
-      else gxcolr(0);
-    }
-    else gxcolr (fcol);
-    gxchpl (gxlabv[i],lablen,x,y,h,csize,gxlabs[i]*180/M_PI)  /* draw the label */;
-  }
-}
-gxcolr (colr);
-gxlabn=0;
+ if (!flag) { gxlabn=0; return; }
+ colr = gxqclr();
+ for (i=0; i<gxlabn; i++ ) {
+   lablen=strlen(gxlabv[i]);
+   bcol = gxdbkq();
+   if (bcol<2) bcol=0;  /* If bcol is neither black nor white, leave it alone. Otherwise, set to 0 for 'background' */
+   h = csize*1.2;                       /* set label height */
+   w = 0.2;
+   gxchln (gxlabv[i],lablen,csize,&w);  /* get label width */
+   if (gxlabs[i]==0.0) {                /* contour label is not rotated */
+     x = gxlabx[i] - (w/2.0);           /* adjust reference point */
+     y = gxlaby[i] - (h/2.0);
+     gxcolr (bcol);
+     buff=h*0.2;                        /* add a buffer above and below the string, already padded in X */
+     gxrecf (x, x+w, y-buff, y+h+buff); /* draw the background rectangle,  */
+     if (colflg>-1) fcol = colflg;
+     else fcol = gxlabc[i];
+     if (fcol==bcol) gxcolr(1);         /* if label color is same as background, use foreground */
+     else gxcolr (fcol);
+     gxchpl (gxlabv[i],lablen,x,y,h,csize,0.0);  /* draw the label */
+   } else {                             /* contour label is rotated */
+     xd1 = (h/2.0)*sin(gxlabs[i]);
+     xd2 = (w/2.0)*cos(gxlabs[i]);
+     yd1 = (h/2.0)*cos(gxlabs[i]);
+     yd2 = (w/2.0)*sin(gxlabs[i]);
+     x = gxlabx[i] - xd2 + xd1;         /* adjust reference point */
+     y = gxlaby[i] - yd2 - yd1;
+     xd1 = (h/2.0*1.6)*sin(gxlabs[i]);
+     xd2 = 1.1*(w/2.0)*cos(gxlabs[i]);
+     yd1 = (h/2.0*1.6)*cos(gxlabs[i]);
+     yd2 = 1.1*(w/2.0)*sin(gxlabs[i]);
+     xy[0] = gxlabx[i] - xd2 + xd1;     /* rotated background rectangle => polygon */
+     xy[1] = gxlaby[i] - yd2 - yd1;
+     xy[2] = gxlabx[i] - xd2 - xd1;
+     xy[3] = gxlaby[i] - yd2 + yd1;
+     xy[4] = gxlabx[i] + xd2 - xd1;
+     xy[5] = gxlaby[i] + yd2 + yd1;
+     xy[6] = gxlabx[i] + xd2 + xd1;
+     xy[7] = gxlaby[i] + yd2 - yd1;
+     xy[8] = xy[0];
+     xy[9] = xy[1];
+     gxcolr (bcol);
+     gxfill (xy,5);
+     if (colflg>-1) fcol = colflg;
+     else fcol = gxlabc[i];
+     if (fcol==bcol) gxcolr(1);         /* if label color is same as background, use foreground */
+     else gxcolr (fcol);
+     gxchpl (gxlabv[i],lablen,x,y,h,csize,gxlabs[i]*180/M_PI); /* draw the label */
+   }
+ }
+ gxcolr (colr);
+ gxlabn=0;
 }
 
 /* When label masking is in use, this routine is called to plot all the 
@@ -801,43 +797,43 @@ gaint i,rc;
 struct gxclbuf *pclbuf, *p2;
 struct gxcntr lcntr;
 
-  /* Set up gxcntr struct appropriately -- most values are dummy */
-  lcntr.labsiz = 0.5;
-  lcntr.ltype = 0;
-  lcntr.mask = 1;
-  lcntr.labcol = 1;
-  lcntr.ccol = 1;
-  lcntr.label = NULL;
-
-  /* Copy the lines into fwk, dump the lines,
-     release storage, return.  fwk should be guaranteed big enough for the 
-     largest line we have, and shouldn't have been release via gxcrel at
-     this point. */
-
-  pclbuf = clbufanch;
-  while (pclbuf) { 
-    if (pclbuf->lxy) {
-      xystrt = fwk+2;  
-      xyend = xystrt + 2*(pclbuf->len-1);
-      for (i=0; i<2*pclbuf->len; i++) *(xystrt+i) = *(pclbuf->lxy+i); 
-      gxcolr (pclbuf->color);
-      gxstyl (pclbuf->style);
-      gxwide (pclbuf->width); 
-      lcntr.spline = pclbuf->sfit;
-      rc = gxcspl(1,&lcntr);
-    }
-    pclbuf = pclbuf->fpclbuf;
-  }
-  pclbuf = clbufanch;
-  while (pclbuf) {
-    p2 = pclbuf->fpclbuf;
-    if (pclbuf->lxy) gree (pclbuf->lxy,"c5");
-    gree (pclbuf,"c6");
-    pclbuf = p2;
-  }
-  clbufanch = NULL;
-  clbuflast = NULL;
-  return;
+ /* Set up gxcntr struct appropriately -- most values are dummy */
+ lcntr.labsiz = 0.5;
+ lcntr.ltype = 0;
+ lcntr.mask = 1;
+ lcntr.labcol = 1;
+ lcntr.ccol = 1;
+ lcntr.label = NULL;
+ 
+ /* Copy the lines into fwk, dump the lines,
+    release storage, return.  fwk should be guaranteed big enough for the 
+    largest line we have, and shouldn't have been release via gxcrel at
+    this point. */
+ 
+ pclbuf = clbufanch;
+ while (pclbuf) { 
+   if (pclbuf->lxy) {
+     xystrt = fwk+2;  
+     xyend = xystrt + 2*(pclbuf->len-1);
+     for (i=0; i<2*pclbuf->len; i++) *(xystrt+i) = *(pclbuf->lxy+i); 
+     gxcolr (pclbuf->color);
+     gxstyl (pclbuf->style);
+     gxwide (pclbuf->width); 
+     lcntr.spline = pclbuf->sfit;
+     rc = gxcspl(1,&lcntr);
+   }
+   pclbuf = pclbuf->fpclbuf;
+ }
+ pclbuf = clbufanch;
+ while (pclbuf) {
+   p2 = pclbuf->fpclbuf;
+   if (pclbuf->lxy) gree (pclbuf->lxy,"c5");
+   gree (pclbuf,"c6");
+   pclbuf = p2;
+ }
+ clbufanch = NULL;
+ clbuflast = NULL;
+ return;
 }
 
 /* When gxout shape is in use, this routine is called to dump all the 
@@ -865,8 +861,7 @@ gadouble x,y,*lons=NULL,*lats=NULL,*vals=NULL,lon,lat,val,dval;
  shpid=0;
  pclbuf = clbufanch;
  if (pclbuf==NULL) {
-   snprintf(pout,511,"Error in gxshplin: contour buffer is empty\n");
-   gaprnt(0,pout);
+   printf("Error in gxshplin: contour buffer is empty\n");
    rc = -1; 
    goto cleanup;
  }
@@ -874,20 +869,17 @@ gadouble x,y,*lons=NULL,*lats=NULL,*vals=NULL,lon,lat,val,dval;
    if (pclbuf->lxy) {
      /* allocate memory for lons and lats of the vertices in contour line */
      if ((lons = (gadouble*)galloc (pclbuf->len*sizeof(gadouble),"shplons"))==NULL) {
-       snprintf(pout,511,"Error in gxshplin: unable to allocate memory for lon array\n");
-       gaprnt(0,pout);
+       printf("Error in gxshplin: unable to allocate memory for lon array\n");
        rc = -1;
        goto cleanup;
      }
      if ((lats = (gadouble*)galloc (pclbuf->len*sizeof(gadouble),"shplats"))==NULL) {
-       snprintf(pout,511,"Error in gxshplin: unable to allocate memory for lat array\n");
-       gaprnt(0,pout);
+       printf("Error in gxshplin: unable to allocate memory for lat array\n");
        rc = -1;
        goto cleanup;
      }
      if ((vals = (gadouble*)galloc (pclbuf->len*sizeof(gadouble),"shpvals"))==NULL) {
-       snprintf(pout,511,"Error in gxshplin: unable to allocate memory for val array\n");
-       gaprnt(0,pout);
+       printf("Error in gxshplin: unable to allocate memory for val array\n");
        rc = -1;
        goto cleanup;
      }
@@ -905,8 +897,7 @@ gadouble x,y,*lons=NULL,*lats=NULL,*vals=NULL,lon,lat,val,dval;
      i = SHPWriteObject(sfid,-1,shp);
      SHPDestroyObject(shp);
      if (i!=shpid) {
-       snprintf(pout,511,"Error in gxshplin: SHPWriteObject returned %d, shpid=%d\n",i,shpid);
-       gaprnt(0,pout);
+       printf("Error in gxshplin: SHPWriteObject returned %d, shpid=%d\n",i,shpid);
        rc = -1;
        goto cleanup;
      }
@@ -1044,7 +1035,8 @@ void gxpclab (gadouble xpos, gadouble ypos, gadouble rot, gaint ccol, struct gxc
 
   csize = pcntr->labsiz;
   lablen = strlen(clabel);
-  bcol = gxqbck();
+  bcol = gxdbkq();
+  if (bcol<2) bcol=0;  /* If bcol is neither black nor white, leave it alone. Otherwise, set to 0 for 'background' */
   h = csize*1.2;                          /* set label height */
   w = 0.2;
   gxchln (clabel,lablen,csize,&w);        /* get label width */
@@ -1063,7 +1055,8 @@ void gxpclab (gadouble xpos, gadouble ypos, gadouble rot, gaint ccol, struct gxc
   if (pcntr->labwid > -1) gxwide(pcntr->labwid);
   if (pcntr->labwid == -999) {
     /* invoke settings for fat background label */
-     gxwide(12); gxcolr(bcol);
+     gxwide(12); 
+     gxcolr(bcol);
   }
   /* draw the label */
   gxchpl (clabel,lablen,x,y,h,csize,0.0);
@@ -1072,7 +1065,9 @@ void gxpclab (gadouble xpos, gadouble ypos, gadouble rot, gaint ccol, struct gxc
     gxwide(1); gxcolr(fcol);
     gxchpl (clabel,lablen,x,y,h,csize,0.0);
   }
+  /* update the mask where this label is positioned */
   gxmaskrec (x-buff, x+w+buff, y-buff, y+h+buff);
+
   gxcolr (scol);
   gxwide (swid);
 }
diff --git a/src/gxdxwd.c b/src/gxdxwd.c
index c265959..f1132cd 100644
--- a/src/gxdxwd.c
+++ b/src/gxdxwd.c
@@ -1,3 +1,5 @@
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
+    See file COPYRIGHT for more information.   */
 
 /* 
  * Include ./configure's header file
diff --git a/src/gxeps.c b/src/gxeps.c
deleted file mode 100644
index 4af58a0..0000000
--- a/src/gxeps.c
+++ /dev/null
@@ -1,1775 +0,0 @@
-
-/* 
- * Include ./configure's header file
- */
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
-
-/***********************************************************
- * GXEPS a grads metafile to PostScript converter
- * Copyright (c) 1999 - 2001 Matthias Munnich
- *
- * I regard gxeps as freeware as long as proper credit is given.
- * As I often read lengthy copyright notices I adjusted
- * one which seemed fitting. Here it goes:
- * * Permission has been granted to copy and distribute gxeps in any 
- * context, including a commercial application, provided that this notice 
- * is present in user-accessible supporting documentation.
- * 
- * This does not affect your ownership of the derived work itself, and 
- * the intent
- * is to assure proper credit for the authors of gxeps, not to interfere
- * with your productive use of gxeps. If you have questions, ask. 
- * "Derived works" includes all programs that utilize gxeps.
- * Credit must be given in user-accessible documentation.
- * 
- * Permission to use, copy, modify, and distribute this software and its 
- * documentation for any purpose and without fee is hereby granted, provided 
- * that the above copyright notice appear in all copies and that both that 
- * copyright notice and this permission notice appear in supporting 
- * documentation.  This software is provided "as is" without express or 
- * implied warranty.
- * 
- * Matthias Munnich mailto:munnich at atmos.ucla.edu
- * ==================================================
- *
- *   $Log: gxeps.c,v $
- *   Revision 1.13  2009/05/06 14:13:43  jma
- *   additional mods for the 255 colors
- *
- *   Revision 1.12  2009/04/30 15:25:31  jma
- *   changed max number of colors from 99 to 255
- *
- *   Revision 1.11  2009/01/05 12:48:24  jma
- *   changed
- *   #include <config.h>
- *   to
- *   #include "config.h"
- *
- *   Revision 1.10  2008/11/07 19:03:55  jma
- *   removed all the #ifdefs for PRINT_EPS
- *   this is now permanently enabled so you can
- *   create postcript files using 'print' without 'enable print'
- *
- *   Revision 1.9  2008/01/23 13:04:49  jma
- *   removed files, no more support of USEIMG
- *
- *   Revision 1.8  2007/09/13 13:58:42  jma
- *   First and incomplete stab at double precision data handling and undef mask.
- *   Compiles with few warnings on OSX, checked in now for testing on linux.
- *
- *   Revision 1.7  2007/05/31 15:45:28  jma
- *   Changes to the configure system -- updated for dods 3.4 as the default. 
- *   Some other minor changes to src files to add #include statements to remove compiler warnings.
- *
- *   Revision 1.6  2004/02/27 14:42:11  administrator
- *   Changes to RGB color settings in gxps.c and gxeps.c to match the colors in
- *   gxX.c, gxhpng.c, and the documentation. This should make image and postscript
- *   ouput look just like the graphical display.
- *
- *   Revision 1.5  2003/11/10 21:27:39  jma
- *   Fix to gxeps.c to add graylines (-G option) which fixes hardcopy output from basemap.gs
- *
- *   Revision 1.4  2003/04/04 01:52:30  joew
- *   Mod from Matthias Munnich:
- *
- *   -DMM_NEW_PROMPT
- *       - The grads prompt is changed to "ga[command number]> ", e.g., "ga[17]> ".
- *
- *   -DMM_READLINE Enhanced READLINE.
- *   Command line enhancements:
- *       - New "history" or "his" command:
- *         "his[tory] [-sqx] [first] [last] [filename]" writes commands "first" to "last"
- *         in the command history buffer to file "filename".
- *         "his[tory] -r filename" reads commands from file "filename" into the command
- *         history buffer.
- *
- *          Options:
- *           -s  Write history in script syntax (quoted).
- *           -x  Write history unquoted for "exec" command.
- *           -q  Write quitely.
- *           -r  Read history from file.
- *
- *         For files with extension ".gs" the history is written quoted (option "-s").
- *         Examples:
- *            "ga[17]> his" list the current command history.
- *            "ga[17]> his 17 27 foo.gs" writes quoted commands 17 through 27 to file
- *            foo.gs so that ga[17]> foo will reproduce the current state.
- *
- *       - New startup option "-H [history_log_file]":
- *         At startup the last 256 commands in history_log_file are read into the command
- *         history buffer.  When GrADS is terminated the new history is written to
- *         history_log_file.
- *         The default history_log_file is $HOME/.grads.log. (This may need adjustment
- *         for Windows).
- *
- *       - New "repeat" or "r" command: r[epeat] [start] stop
- *         Examples:
- *         "ga[17]> r 21"  repeats command number 21. "ga[17]> r 20 30" repeats commands
- *         20 to 30 skipping r commands to avoid infinite loops.
- *
- *   Revision 1.3  2003/04/03 19:46:27  joew
- *   Mod from Matthias Munnich: improved EPS output
- *
- *   Revision 1.6  2001/12/17 23:37:15  munnich
- *   Symbol fonts are now always drawn. To this end the string information
- *   where moved to command -15 (begin string).
- *
- *   Revision 1.5  2001/12/07 00:40:42  munnich
- *   Fixed bugs with gxheps.
- *
- *   Revision 1.4  2001/12/04 05:37:53  munnich
- *   Incorporated gxeps into the print command. If printing is
- *   not yet "enabled" the print command now uses gxeps code
- *   to directly produce EPS files. Most of the standard gxeps
- *   options are valid. Help is given via ga-> print -h or any
- *   invalid option.
- *   Affected files: Makefile, gauser.c, gx.h, gxmeta.c
- *
- *   Also changed the map drawing to use polygons if clip is hard.
- *   Affected: gxwmap.c
- *   RCS file: /long/munnich/CVSROOT/grads/cola/src/Makefile.in,v
- *   RCS file: /long/munnich/CVSROOT/grads/cola/src/gauser.c,v
- *   RCS file: /long/munnich/CVSROOT/grads/cola/src/gx.h,v
- *   cvs diff: gxeps.c is a new entry, no comparison available
- *   RCS file: /long/munnich/CVSROOT/grads/cola/src/gxmeta.c,v
- *   RCS file: /long/munnich/CVSROOT/grads/cola/src/gxwmap.c,v
- *
- *   Revision 0.94  2001/12/02 06:22:59  munnich
- *   gxeps.c
- *
- *   Revision 0.93  2001/12/02 06:20:55  munnich
- *   Fixed Filled rectangle bug for RSCALE != 2
- *
- *   Revision 0.92  2001/11/24 04:48:25  munnich
- *   Added clipboundary to bounding box computation.
- *   Added meta file draw line command (-13) to search for Polygons.
- *   Took care that the gsave/grestore pairs in clipping match at the end.
- *
- *   Revision 0.91  2001/11/22 02:17:23  munnich
- *   Back to 1000dpi resolution due to visible roundoff errors.
- *   Added IsoLatin1 support for PostScript level 2.
- *   Made PS Level 2 default.
- *
- *   Revision 0.90  2001/11/21 07:03:28  munnich
- *   Fixed a hardware clipping bug.
- *
- *   Revision 0.88  2001/04/19 01:55:35  munnich
- *   Fixed a bug in rotated strings.-- 
- *   of grads as well.
- *
- *   Revision 0.87  2001/03/08 21:57:23  munnich
- *   Introduced hardware clipping, line styles, polygon and line drawing.
- *   Use hardware clipping to cut contour lines for labels.
- *   Right now smoothing of contours is disabled.
- *   To be done:
- *   1. Enable smoothing of contours.
- *   2. Make hardware clipping and line style a setting
- *      which can be changed by something like
- *      set clip hard/soft
- *      set style hard/soft
- *   3. Disgard overlapping lables (an old "bug").
- *
- *   Revision 0.86  2001/03/08 21:21:22  munnich
- *   Added support for new metafile commands:
- *   (*) -13    draw a polygon
- *   (*) -14    draw a line
- *   (*) -17    set line style (dashes)
- *   (*) -18    set/change clipping region
- *
- *   Revision 0.85  2001/02/01 21:23:45  munnich
- *   1. Another change to the memory reallocation for large polygons.
- *   Now it should always works.
- *   2. New macro PSFONTS to enable PostScript font support.
- *   3. Input can now come from stdin by using option -i -.
- *
- *   Revision 0.84  2001/01/27 06:57:04  munnich
- *   Fixed coordinate line thicknes bug.
- *
- *   Revision 0.83  2000/10/13 16:36:01  munnich
- *   Another bug fix related user defined colors.
- *
- *   Revision 0.82  2000/10/12 22:33:52  munnich
- *   Fixed a bug related to user defined colors and black&white mode.
- *
- *   Revision 0.81  2000/09/20 22:51:42  munnich
- *   Fixed rotated strings
- *
- *   Revision 0.80  2000/09/15 19:19:24  munnich
- *   Implemented "-g" option for true 8.5'' x 11'' inch output size.
- *
- *   Revision 0.79  2000/09/05 01:33:13  munnich
- *   Back to old scaling for letter paper.
- *
- *   Revision 0.78  2000/08/25 20:54:30  munnich
- *   Back to version 0.76. V0.77 was broken.
- *
- *   Revision 0.76  2000/06/02 23:45:10  munnich
- *   *** empty log message ***
- *
- *   Revision 0.75  2000/06/02 23:23:52  munnich
- *   Fixed Orientation comment.
- *
- *   Revision 0.74  2000/04/03 17:28:54  munnich
- *   Fixed 2 bugs:
- *   (i) gsave was not bracketed with a grestore when
- *   neither options -L nor -n were used.
- *   (ii) Undefined colors are now set to gray (no. 15).
- *
- *   There is also a rudimentary font support in gxeps.c.
- *   This only comes into affect when a new metafile format is
- *   introduced.  Everthing should be backward compatible.
- *
- *   Revision 0.73  1998/11/30 10:13:57  m211033
- *   Fixed a 2 bug: Lineswidth and colors can know
- *   change within a polygon. This bug only occurred with
- *   colored streamline plots.
- *
- *   Changed the line breaking method for polygons.
- *
- *   Revision 0.72  1997/12/08 14:16:15  m211033
- *   Added the -R option which suppresses the rotation
- *   for landscape metafiles.
- *
- *   Revision 0.71  1997/11/05 17:26:41  m211033
- *   Added a compile option NEVER_CTL_D which disables
- *   the -d option for DEFAULT_CTL_D 0, i.e. no ^D is added in
- *   any case.
- *
- *   Revision 0.70  1997/04/15 15:14:37  m211033
- *   Added a BORDER macro that controls the
- *   added white space (in points) around the graph
- *   for the bounding box comment.
- *
- * Revision 0.69  1997/04/09  14:38:39  m211033
- * Black background now as large as the bounding box.
- * BoundingBox corrected for black background.
- *
- *   Revision 0.68  1996/11/22 14:10:45  m211033
- *   BoundingBox takes filled rectangulars into account.
- *
- * Revision 0.67  96/11/19  16:46:19  m211033
- * Two bugs were fixed:
- * (i) with DEFAULT_CTL_D 1 the -d option didn't work.
- * (ii) Color change now leads to a flush of stored lines
- *     (Before sometimes a line was drawn in a invisible color.)
- * 
- * Revision 0.66  96/10/23  12:50:26  m211033
- * Fixed the data type of file position.
- * 
- * Revision 0.65  1996/06/26  15:20:29  m211033
- * Inserted a gsave to match the grestore.
- * This fixes an annotation bug.
- * Resolution is reduce to 500dpi since Version 0.64.
- *
- * Revision 0.64  1996/05/15  10:17:00  m211033
- * The cut of filled line did not work. No the old method
- * is used untill drawline and fillline is rewritten for
- * the use of reversepath.
- * Filline now also looks for colinear lines.
- *
- * Revision 0.63  1996/04/26  19:32:57  m211033
- * Got rid off the error prone reallocation for saved point.
- *
- * Revision 0.62  96/04/26  19:08:25  m211033
- * Fixed another bug with multible plots in one metafile.
- * 
- * Revision 0.61  1996/04/26  17:16:57  m211033
- * Now it tries to find straight lines in polygons.
- *
- * Revision 0.6  96/04/26  16:15:45  m211033
- * Tries to find dashed lines to make the EPS output
- * more compact. Unnecessary return(0) in while(1) eliminated.
- * 
- *
- ***********************************************************/
-          /* default PS-level */
-#define PS_LEVEL 2
-          /* set this to 1 for default a4 paper */
-#define DEFAULTA4 0
-     /* default add control-D at end-of-file (some printer may need this) */
-#define DEFAULT_CTL_D 0
-   /* if NEVER_CTL_D is defined ^D will never be added (disables -d Option) */
-#define NEVER_CTL_D
-#define BORDER 10
-
-/* PS font support */
-#define PSFONTS 
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <math.h>
-#include <time.h>
-
-#define max(A, B) ((A) > (B) ? (A) : (B))
-#define min(A, B) ((A) < (B) ? (A) : (B))
-
-
-/* Some scales for letter paper */
-/* RSCALE: resolution scale */
-#define RSCALE 1
-/* #define LETSCALE 0.1314 */
-#define LETSCALE 0.0657 * RSCALE
-#define LETXOFF 30
-#define LETYOFF 45
-/* GrADS scaling 8.'' x 11'' */
-#define GASCALE 0.144 
-/* Some scales for a4 paper */
-#define A4SCALE 0.1134 
-#define A4XOFF 71
-#define A4YOFF 109
-/* default file extensions */
-#define IN_EXT "gm"
-#define OUT_EXT "eps"
-
-#define PNMAX 512
-/* maximum string size */
-#define STRSIZ 300
-#ifdef OLD__GNUC__
-#define fpos_t long
-#endif
-
-/* is also defined in gxhpng.c */
-struct point {short x; short y;};
-struct point bblow, bbhigh;     /* BoundingBox */
-struct point cliplow, cliphigh; /* Clipping Box */
-struct options {                /* command line options (flags) */
-  short pscale, color, ctl_d, comment, pslevel,
-    tstamp, reverse, rotate, verbose, label, font,
-    history, graylines;
-};
-FILE *infile, *outfile;
-fpos_t bboxpos,pagespos,pagepos,blackpos; /* output file position of boundingbox and page # comments */
-void boundbox(struct point* pnt); /* compute bounding box */
-void printbbox(short opscale,short landscape,struct options *o);  /* print bounding box to PS-file */
-int print_options(char *argv[]); /* print command line options */
-void drawline(struct point pnts[],short *pcnt,
-	      short lcolor,short *colold,short *lastfill,short flush); /* draw a polygon */
-int SaveLine(struct point pnts[],struct point dline[]);
-void PrintDashLine(struct point dline[]);
-short CheckDashLine(struct point pnts[],struct point dline[]);
-void SetDline(struct point pnts[],struct point dline[]);
-short CheckExpandDashLine(struct point pnts[],struct point dline[]);
-int parse_arg(int argc,char *argv[],struct options *o,char **fin, char **fout); /* parse command line */
-int openfiles(char **fin, char **fout, short verbose); /* Open files */
-void fillline(struct point pnts[],short pcnt); /* fill a polygon */
-void initepsf(short landscape,int argc,char *argv[],char *fout,struct options *o); /* write PS-file header */
-void init_newpage(short landscape,char *fout,struct options *o); /* New page header */
-void setjust(short *opts, short *justx, short *justy);
-int gxheps(char*);
-void getwrd (char *, char *, int);
-int gxeps(int , char **);
-
-#ifndef GXHEPS
-#define RDSTREAM(var,num)  fread (var , sizeof(short), num, infile);
-#define MAIN main
-#else
-#define MAIN gxeps
-#define RDSTREAM(var,num)  var=poi; poi+=num;
-char *nxtwrd (char *); 
-
-/* --------------------- Wrapper for gxeps -------------------------- */
-int gxheps(char *com) {
-  char *args,**argv; 
-  int argc=0;
-  char *cmd,*ch;
-  int i,rc;
-
-  cmd=com;
-
-  while( ((cmd=nxtwrd(cmd)) != NULL)) {
-    argc++; 
-  }
-
-  argc+=1;
-
-  argv=(char **) malloc(argc*sizeof(char **));
-  args=(char *) malloc( (strlen(com)+5) *sizeof(char));
-  for(i=0;i<argc;i++) argv[i]=NULL;
-
-  /* copy words in com into args and assign pointers to each word */
-  cmd=com;
-  /* copy command (print) */
-  i=0;
-  ch=args;
-  getwrd(ch,cmd,256);
-  argv[i]=ch;
-  ch+=strlen(ch)+1; 
-  
-  /* copy gxeps options */ 
-  while(++i<argc) {
-    cmd=nxtwrd(cmd);
-    getwrd(ch,cmd,256); 
-    argv[i]=ch;
-    ch+=strlen(ch)+1;
-  }
-
-#ifdef DEBUG_EPS
-  printf(" GXHEPS:\n");
-  printf("argc = %d\n",argc);
-  for(i=0;i<argc;i++)
-      printf("argv[%d]= >%s<\n",i,argv[i]);
-  printf("Calling gxeps...\n");
-#endif
-  rc=gxeps(argc, argv);
-  rc=0;
-  free(argv);
-  free(args);
-  return (rc);
-}
-
-#endif
-
-/* --------------------------------------------------------------------------------- */
-int MAIN (int argc, char *argv[])  {
-   short cmd,coldef[256],lcolor=0, colold=-1, wold=-1, landscape=0, npnmax=1, lastfill=0;
-   short oldstyle=0;
-   struct point *pnts, *pnts2;            /* points of a polygon */
-   struct options o;                      /* command line options */
-   int nodraw=0;                          /* skip draw commands (for string drawing) */
-   int pnmax=PNMAX;                        /* maximum length of a polygon */
-   register int  i,j, ii,jj;
-   short pcnt,pcntSave,fcnt=0,filflg=0;
-   float red,blue,green;
-   char *fin=NULL,*fout=NULL;              /* file names */
-   char str[STRSIZ+50]; /* I hope nobody writes longer lines */
-   short justx,justy; /* justification in % */
-#ifndef GXHEPS
-   fpos_t infile_pos;
-   char string[STRSIZ]; /* I hope nobody writes longer lines */
-   short opts[8];
-#else
-   char *string;
-   short *opts;
-  int cnt,flag,fflag,ib;
-  short *poi,*pend;
-#endif
-   o.pscale=DEFAULTA4;                                           /* default options */
-#ifdef NEVER_CTL_D
-   o.ctl_d=0;
-#else
-   o.ctl_d=DEFAULT_CTL_D;
-#endif
-#ifdef PSFONTS
-   o.font=1;
-#else
-   o.font=0;
-#endif
-   o.reverse=o.verbose=o.comment=o.tstamp=o.label=0;
-   o.history=1;
-   o.rotate=o.color=1;
-   o.pslevel=PS_LEVEL;
-   o.graylines=0;
-   landscape=0;
-   bblow.x=1200;bblow.y=1200;
-   bbhigh.x=0; bbhigh.y=0;
-   pnts=(struct point *) malloc(pnmax*sizeof(struct point)); /* initial maximal polygon size */
-
-  for(i=0;i<16;i++) coldef[i]=1;          /* Initialize defined color flag*/
-  for(i=16;i<=255;i++) coldef[i]=0;
-
-  if(parse_arg(argc,argv,&o,&fin,&fout))
-    return(1);     /* Parse command line arguments */
-  if(openfiles(&fin,&fout,o.verbose))
-    return(1);                  /* open files */
-
-  /* Translate the file */
-
-#ifdef GXHEPS  
-  /*  Set up pointers into current meta buffer list */
-
-  if (dbmode && pntf==0) {
-    lens2[pnt2-1] = hpnt-hbuff;
-    cnt = pnt2; flag = 1;
-  } else {
-    lens[pnt-1] = hpnt-hbuff;
-    cnt = pnt; flag = 0;
-  }
-  fflag = 0;
-
-    /* Initialization (cmd ==-1) not in buffer. we do it here */
-
-    landscape= (yrsize<xrsize);  /* ysize < xsize : landscape */
-    if(o.rotate && landscape) o.rotate=1; /* no -R option and */
-    else o.rotate=0; 
-    
-    initepsf(landscape,argc,argv,fout,&o);
-    colold=-1;
-    init_newpage(landscape,fout,&o);
-    pcnt = 0;
-
-  for (ib=0; ib<cnt; ib++) {
-    if (flag) {
-      poi = bufs2[ib];
-      pend = poi + lens2[ib];
-    } else { 
-      poi = bufs[ib];
-      pend = poi + lens[ib];
-    } 
-
-    while (poi<pend) {
-    cmd= *poi; poi++;
-#else 
-      /* gxeps utility */
-  fcnt = 1;
-  while (1) {
-    fread (&cmd , sizeof(short), 1, infile);
-#endif
-
-    if (cmd==-11) {				/* Draw to */
-      /*      fread (opts, sizeof(short), 2, infile); */
-      RDSTREAM(opts,2)
-      if(nodraw) {
-	pnts[pcnt+1].x=opts[0]/RSCALE;
-	pnts[pcnt+1].y=opts[1]/RSCALE;
-	boundbox(&pnts[pcnt+1]);
-	if (lcolor != colold)  {
-	  fprintf(outfile,"c%i ",lcolor);
-	  colold=lcolor;
-	}
-	continue;
-      }
-      pnts[++pcnt].x=opts[0]/RSCALE;
-      pnts[pcnt].y=opts[1]/RSCALE;
-      boundbox(&pnts[pcnt]);
-      if (pcnt%(pnmax/4)==(pnmax/4)-1){
-        if (!filflg) {   /* flush pnts to keep vector counts small */
-	  drawline(pnts,&pcnt,lcolor,&colold,&lastfill,-1);
-          pnts[0].x=opts[0]/RSCALE;
-	  pnts[0].y=opts[1]/RSCALE;
-        } else if(pcnt==pnmax-1) { /* increase pnmax to hold more points */
-	  pnmax =PNMAX* ++npnmax;
-	  pnts2=(struct point *) malloc(pnmax*sizeof(struct point)); /* new memory array */
-	  memcpy(pnts2,pnts,pnmax*sizeof(struct point));    /* copy saved pnts to new array */
-	  free(pnts);
-	  pnts=pnts2;
-	  if(o.verbose)
-	    printf("     Memory allocation for polygons increased to %i points.\n",pnmax);
-        }
-      }
-    }
-    else if (cmd==-10){				/* Move to */
-      /*      fread ( opts, sizeof(short), 2, infile); */
-      RDSTREAM(opts,2)
-      if (pcnt) {
-	if( (pnts[pcnt].x==opts[0]/RSCALE) && (pnts[pcnt].y==opts[1]/RSCALE) ) {
-	  continue;
-	}
-	drawline(pnts,&pcnt,lcolor,&colold,&lastfill,0);
-      }
-      pnts[pcnt].x=opts[0]/RSCALE;
-      pnts[pcnt].y=opts[1]/RSCALE;
-      boundbox(&pnts[pcnt]);
-      if(nodraw) continue;
-    }
-    else if (cmd==-4) {				/* Set line width */
-      if (pcnt) {
-	pcntSave=pcnt;
-	drawline(pnts,&pcnt,lcolor,&colold,&lastfill,1);
-	pnts[pcnt].x=pnts[pcntSave].x;
-	pnts[pcnt].y=pnts[pcntSave].y;
-      } else
-	drawline(pnts,&pcnt,lcolor,&colold,&lastfill,1);
-      /*       fread (opts, sizeof(short), 2, infile); */
-      RDSTREAM(opts,2)
-      i = opts[0];
-      if (i>12) i=12;
-      else if (i<1) i=1;
-      if(--i!=wold){
-	fprintf(outfile,"w%i ",i);
-	wold=i;
-      }
-    }
-    else if (cmd==-3) {				/* Set color */
-      if (pcnt) {
-	pcntSave=pcnt;
-	drawline(pnts,&pcnt,lcolor,&colold,&lastfill,1);
-	pnts[pcnt].x=pnts[pcntSave].x;
-	pnts[pcnt].y=pnts[pcntSave].y;
-      }
-      /*      fread (opts, sizeof(short), 1, infile); */
-      RDSTREAM(opts,1)
-      lcolor = opts[0];
-      /********      printf("New lcol#=%i\n",lcolor); */
-      if (lcolor<0) lcolor=0;
-      if (lcolor>255) lcolor=255; 
-      if (!(coldef[lcolor])) lcolor=15;
-      /*      if (nodraw) fprintf(outfile,"c%i ",lcolor); */
-      fprintf(outfile,"c%i ",lcolor);
-    }
-    else if (cmd==-7){				/* Start fill */
-      /*       fread (opts, sizeof(short), 1, infile); */
-      RDSTREAM(opts,1)
-      filflg = 1;
-      /* if(o.verbose) fprintf(outfile, "%%Fflag\n"); */
-    }
-    else if (cmd==-8){				/* End fill */
-      if (pcnt) { 
-	  if (lcolor != colold || lastfill==0)  {
-	  fprintf(outfile,"g%i ",lcolor);
-	  colold=lcolor;
-	  }
-        fillline(pnts,pcnt); pcnt=0;
-        filflg = 0;
-	lastfill=1;
-      }
-    }
-    else if (cmd==-6){				/* Rectangle fill */
-      if (pcnt) {drawline(pnts,&pcnt,lcolor,&colold,&lastfill,1);}
-      /*       fread (opts, sizeof(short), 4, infile); */
-      RDSTREAM(opts,4)
-      if (lcolor != colold || lastfill==0)  {
-	fprintf(outfile,"g%i ",lcolor);
-	colold=lcolor;
-      }
-      for(i=0;i<4;i++) opts[i]/=RSCALE;
-      pnts[0].x=opts[0];
-      pnts[0].y=opts[2];
-      pnts[1].x=opts[1];
-      pnts[1].y=opts[3];
-      boundbox(&pnts[0]);
-      boundbox(&pnts[1]);
-      fprintf(outfile,"%i %i %i %i B\n",
-	      opts[0],opts[2],opts[1]-opts[0],opts[3]-opts[2]);
-      lastfill=1;
-    }
-    else if (cmd==-9) {				/* End of plotting */
-      /*  fsetpos(outfile,&pagepos); */
-	fprintf (outfile,"%%%%Trailer\n%%%%EOF\n");
-	/*  if(!o.reverse) printbbox(o.pscale,landscape); */
-	/*  if(o.verbose) printf("BBox without offset: %i %i %i %i \n",
-                           bblow.x, bblow.y, bbhigh.x, bbhigh.y); */
-      if (o.ctl_d) fprintf (outfile,"%c%c",(char)4,'\n');
-      if(o.verbose) printf ("     Number of pages = %i\n",fcnt);
-#ifdef GXHEPS
-      fsetpos(outfile,&pagespos);
-      printf("WARNING: command -9 in plot buffer.\n");
-#endif
-      fprintf(outfile,"%i",fcnt);
-      fclose (outfile);
-      return(0);
-    }
-    else if (cmd==-1) {				/* Start of plotting */
-      /*       fread (opts, sizeof(short), 2, infile); */
-      RDSTREAM(opts,2);
-      landscape= (opts[1]<opts[0]);  /* ysize < xsize : landscape */
-      if(o.rotate && landscape) o.rotate=1; /* no -R option and */
-      else o.rotate=0; 
-      
-      initepsf(landscape,argc,argv,fout,&o);
-      colold=-1;
-      init_newpage(landscape,fout,&o);
-      pcnt = 0;
-    }
-    else if (cmd==-2) {				/* New Page */
-      if (pcnt) drawline(pnts,&pcnt,lcolor,&colold,&lastfill,1);
-      fprintf(outfile,"C0\n");
-#ifdef DEBUG_EPS
-     fprintf(outfile,
-     " %i %i moveto %i %i lineto %i %i lineto %i %i lineto closepath stroke\n ",
-     bblow.x,bblow.y,bblow.x, bbhigh.y,bbhigh.x,bbhigh.y,bbhigh.x,bblow.y);
-#endif
-      fprintf (outfile,"showpage\n");
-      printbbox(o.pscale,landscape,&o);
-#ifndef GXHEPS
-      fgetpos(infile,&infile_pos);
-      /*       fread (&cmd , sizeof(short), 1, infile);  */
-      RDSTREAM(&cmd,1)
-      fsetpos(infile,&infile_pos);
-#endif
-      if (cmd != -9) {  /* if next command is not end_of_plotting */
-      ++fcnt;
-      fprintf (outfile,"\n%%%%Page: %i %i\n",fcnt,fcnt); /* print %%Page: for the last page */
-#ifndef GXHEPS
-         fprintf(outfile,"%%%%BoundingBox: ");
-         fgetpos(outfile, &bboxpos);
-         fprintf(outfile,"                  \n");
-#else
-         fprintf(outfile,"%%%%BoundingBox: (atend)\n");
-#endif
-         bblow.x=1200;bblow.y=1200;
-         bbhigh.x=0; bbhigh.y=0;
-	 colold=-1;
-         init_newpage(landscape,fout,&o);
-      }
-    }
-    else if (cmd==-5){				/* Define new color */
-      /*       fread (opts, sizeof(short), 4, infile); */
-      RDSTREAM(opts,4);
-      i = opts[0];
-      if (i>15 && i<=255) {
-          green = ((float)(opts[2]))/255.0;
-          if (green<0.0) green=0.0;
-          if (green>1.0) green=1.0;
-          red = ((float)opts[1])/255.0;
-          if (red<0.0) red=0.0;
-          if (red>1.0) red=1.0;
-          blue = ((float)opts[3])/255.0;
-          if (blue<0.0) blue=0.0;
-          if (blue>1.0) blue=1.0;
-          fprintf(outfile,"blackwhite \n");
-	  /* (b/w: mapped into grey scale via green intensity) */
-	  if(o.graylines)
-	    fprintf(outfile,"  {/g%i {%.5g g} bdef /c%i {%.5g g} bdef}\n",i,1.0-green,i,1.0-green);
-	  else
-	    fprintf(outfile,"  {/g%i {%.5g g} bdef /c%i {g1} bdef}\n",i,1.0-green,i);
-	  fprintf(outfile,"  {/c%i {%.5g %.5g %.5g c} bdef\n",i,red,green,blue);
-          fprintf(outfile,"/g%i {c%i} def}\n ifelse\n",i,i);
-	  coldef[i]=1;
-      }
-    }
-      /*  -13 draw a polygon.  It has 2*siz+1 args. */
-      else if (cmd==-13) {
-	/* 	fread (opts, sizeof(short), 1, infile); */
-	RDSTREAM(opts,1)
-	i=opts[0]/2; /* i: # points in polygon */
-	/* 	fprintf(outfile,"%% polygon of %d points, opts[0]=%d\n",i,opts[0]); */
-	pnts2=(struct point *) malloc(i*sizeof(struct point));
-#ifndef GXHEPS
-	fread (pnts2, sizeof(struct point), i, infile);
-#else
-        pnts2=(struct point *) poi; poi+=2*i;
-#endif
-	jj=0;
-	for(ii=i-1;ii>0; ii--){
-	  jj+=fprintf(outfile,"%d %d ",(pnts2[ii].x-pnts2[ii-1].x)/RSCALE,
-		      (pnts2[ii].y-pnts2[ii-1].y)/RSCALE);
-	  if(jj>70) {
-	    jj=0;
-	    fprintf(outfile,"\n");
-	  }
-	}
-	fprintf(outfile,"%d %d%s%d S\n",pnts2->x/RSCALE,pnts2->y/RSCALE,(jj>70) ? "\n" : " ", --i);
-	/*	if(jj>70) fprintf(outfile,"\n");
-		fprintf(outfile,"%d S\n",--i); */
-      }
-  
-
-      /* -14 is draw a line  It has four float args. */ 
- 
-    else if (cmd==-14) {
-      /*      fread (opts, sizeof(short), 4, infile); */
-      RDSTREAM(opts,4)
-      if(pcnt) { /* Check if we can add this secment to the stored polygon..*/
-	if( (pnts[pcnt].x==opts[0]/RSCALE) && (pnts[pcnt].y==opts[1]/RSCALE) ){
-	  pnts[++pcnt].x=opts[2]/RSCALE;
-	  pnts[pcnt].y=opts[3]/RSCALE;
-	  boundbox(&pnts[pcnt]);
-	  if (pcnt%(pnmax/4)==(pnmax/4)-1){
-	    drawline(pnts,&pcnt,lcolor,&colold,&lastfill,-1);
-	    pnts[0].x=opts[2]/RSCALE;
-	    pnts[0].y=opts[3]/RSCALE;
-	  }
-	} else 	if( (pnts[pcnt].x==opts[2]/RSCALE) && (pnts[pcnt].y==opts[3]/RSCALE) ){
-	  pnts[++pcnt].x=opts[0]/RSCALE;
-	  pnts[pcnt].y=opts[1]/RSCALE;
-	  boundbox(&pnts[pcnt]);
-	  if (pcnt%(pnmax/4)==(pnmax/4)-1){
-	    drawline(pnts,&pcnt,lcolor,&colold,&lastfill,-1);
-	    pnts[0].x=opts[0]/RSCALE;
-	    pnts[0].y=opts[1]/RSCALE;
-    }
-	} else {
-	  drawline(pnts,&pcnt,lcolor,&colold,&lastfill,0);
-	}
-      } else {
-	pnts[pcnt].x=opts[0]/RSCALE;
-	pnts[pcnt].y=opts[1]/RSCALE;
-	boundbox(&pnts[pcnt]);
-	pnts[++pcnt].x=opts[2]/RSCALE;
-	pnts[pcnt].y=opts[3]/RSCALE;
-	boundbox(&pnts[pcnt]);
-/*       fprintf(outfile," %d %d %d %d L\n", */
-/* 	      (opts[2]-opts[0])/RSCALE,(opts[3]-opts[1])/RSCALE,opts[0]/RSCALE,opts[1]/RSCALE); */
-/*       boundbox((struct point *)&opts[0]); */
-/*       boundbox((struct point *)&opts[2]); */
-      }
-    }
-    else if (cmd==-15) {		/* Begin  Char. String drawing */
-      /*  if (pcnt) drawline(pnts,&pcnt,lcolor,&colold,&lastfill,1); */
-      /*       fread (opts, sizeof(short), 8, infile); */
-      RDSTREAM(opts,8)
-                  /* opts[0]=len,   opts[1]=x, opts[2]=y, opts[3]=height,
-                   * opts[4]=width, opts[5]=angle, opts[6]=font number
-                   * opts[7]=justification
-                   */
-      if(opts[0]>=STRSIZ) {
-	printf("String too long. Recompile with bigger STRSIZ.\n");
-	return(1);
-      }
-#ifndef GXHEPS
-      fread(string,sizeof(short),(opts[0])/sizeof(short)+2,infile);
-#else
-      string=(char *) poi; 
-      poi+= (int) (opts[0])/sizeof(short)+2;
-#endif
-      i=j=0;
-      do { /* quote parentheses */
-	if(string[i]=='(' || string[i]==')' ) {
-	  str[j++]='\\';
-	  str[j++]=string[i++];
-	} else
-	  str[j++]=string[i++];
-      }  while(string[i]!='\0');
-      str[j]='\0';
-      
-      if((opts[6] != 3) && o.font) nodraw=1;
-      if(!nodraw) fprintf(outfile,"%% String: ");
-      setjust(opts,&justx,&justy);
-      if(opts[7] == 1) {
-      fprintf(outfile,"(%s) %d %d %d %d %d %d LS\n",
-                  str,opts[6],opts[4]*85/50/RSCALE,opts[3]*75/50/RSCALE,
-	         (int)((float)opts[5]/64.),opts[1]/RSCALE,opts[2]/RSCALE);
-	
-      } else {
-
-		fprintf(outfile,"(%s) %d %d %d %d %d %d %d %d JS\n",
-			str,opts[6],opts[4]*85/50/RSCALE,opts[3]*75/50/RSCALE,
-			(int)((float)opts[5]/64.),opts[1]/RSCALE,opts[2]/RSCALE,justx,justy);
-	      
-      }
-      if(!nodraw) fprintf(outfile,"%% String begin{\n");
-    }
-    else if (cmd==-16) {		/* End string  drawing */
-      if (pcnt) drawline(pnts,&pcnt,lcolor,&colold,&lastfill,1);
-      if(nodraw) {
-      nodraw=0;
-      } else {
-	fprintf(outfile,"\n%%} String end\n");
-      }
-    }
-
-      /* -17 indicates linestyle.  One arg; style number.  */
-  
-      else if (cmd==-17) {
-	/* 	fread (opts, sizeof(short), 1, infile); */
-	RDSTREAM(opts,1)
-	if(oldstyle != opts[0]) {
-	  if (pcnt) {drawline(pnts,&pcnt,lcolor,&colold,&lastfill,1);} 
-	  if(opts[0]>0 && opts[0]<9)
-	    fprintf(outfile,"s%d ",opts[0]);
-	  else
-	    fprintf(outfile,"s1 %%s%d\n",opts[0]);
-	  oldstyle=opts[0];
-	}
-    }
-
-      /* -18 Change clipping region: has 5 args  */
-  
-      else if (cmd==-18) {
-	/* 	fread (opts, sizeof(short), 5, infile); */
-	RDSTREAM(opts,5)
-
-	if(opts[0]==0) {
-	  fprintf(outfile,"C0\n");
-	  cliplow.x=0;cliplow.y=0;cliphigh.x=11000;cliphigh.y=11000;
-	}
-	else if(opts[0]==1) { /* clip exterior of rectangle */
-	  fprintf(outfile,"%d %d %d %d C1\n",opts[1]/RSCALE,opts[3]/RSCALE,
-		  (opts[2]-opts[1])/RSCALE,(opts[4]-opts[3])/RSCALE);
-	  cliplow.x=opts[1]/RSCALE;
-	  cliplow.y=opts[3]/RSCALE;
-	  cliphigh.x=opts[2]/RSCALE;
-	  cliphigh.y=opts[4]/RSCALE;
- 	}
-	else if(opts[0]==2) /* add interior of rectangle to clipping*/
-	  fprintf(outfile,"%d %d %d %d C2\n",opts[1]/RSCALE,opts[4]/RSCALE,
-		  (opts[2]-opts[1])/RSCALE,(opts[3]-opts[4])/RSCALE);
-      }
-
-    else if (cmd==-20) {		/* Draw button -- ignore */
-      /*       fread (opts, sizeof(short), 1, infile); */
-      RDSTREAM(opts,1)
-    }
-    else {
-       printf ("   Fatal error: Invalid command \"%i\" found in metafile\"%s\".\n",cmd,fin);
-       printf ("   Is \"%s\" really a GrADS (v1.5 or higher) metafile?\n",fin);
-      return(1);
-    }
-  }
-#ifdef GXHEPS
-    }
-    /* Commands -2 (new page) and -9 (end plot) not in buffer *
-     *  We need to do it now */
-    
-    /* cmd == -2  New page  + -9 end of plotting*/
-    if (pcnt) drawline(pnts,&pcnt,lcolor,&colold,&lastfill,1);
-    fprintf (outfile,"showpage\n");
-    fprintf (outfile,"%%%%Trailer\n");
-    fprintf(outfile,"%%%%BoundingBox: ");
-    printbbox(o.pscale,landscape,&o);
-    fprintf (outfile,"\n%%%%EOF\n");
-    fprintf(outfile,"\n");
-    if (o.ctl_d) fprintf (outfile,"%c%c",(char)4,'\n');
-    fclose (outfile);
-    if(fout != NULL) printf("  EPS file written to %s\n",fout);
-    return(0);
-#endif
-}
-/* --------------------------------------------------------------------------------- */
-
-void initepsf(short landscape,int argc,char *argv[],char *fout,struct options *o){
-       char *gr[16] =  {                      /* default greys */
-                  "1", "0", "0.16", "0.46", "0.7", "0.58", "0.1", "0.34",
-                  "0.22", "0.82", "0.4", "0.64", "0.28", "0.52", "0.76", "0.5"
-             };
-       char * col[16] = {          /* colors */
-		"1.00 1.00 1.00",  /* white */
-		"0.00 0.00 0.00",  /* black */
-		"0.98 0.24 0.24",  /* red */
-		"0.00 0.86 0.00",  /* green */
-		"0.12 0.24 1.00",  /* blue */
-		"0.00 0.78 0.78",  /* cyan */
-		"0.94 0.00 0.51",  /* magenta */
-		"0.90 0.86 0.19",  /* yellow */
-		"0.94 0.51 0.16",  /* orange */
-		"0.63 0.00 0.78",  /* purple */
-		"0.63 0.90 0.19",  /* yellow/green */
-		"0.00 0.63 1.00",  /* med. blue */
-		"0.90 0.69 0.18",  /* dark yellow */
-		"0.00 0.82 0.55",  /* aqua */
-		"0.51 0.00 0.86",  /* dark purple */
-		"0.67 0.67 0.67"   /* grey */
-};
-      char *widths[12] = {                      /* widths */
-	 "4 w","7 w","10 w","14 w","17 w","20 w",
-                "24 w","27 w","31 w","34 w","38 w","41 w"
-	/*   "1 w","3 w","5 w","7 w","9 w","10 w",
-	     "12 w","14 w","15 w","17 w","19 w","21 w"  RSCALE=2 widths */
-             };
-      int i;
-      char buf[256];
-      time_t thetime=time(NULL);
-      if(o->pslevel>1) fprintf(outfile, "%%!PS-Adobe-2.0 EPSF-1.2\n");
-      else             fprintf(outfile, "%%!PS-Adobe-1.0 EPSF-1.2\n");
-#ifndef GXHEPS
-      fprintf(outfile,"%%%%BoundingBox: ");
-      fgetpos(outfile, &bboxpos);
-      fprintf(outfile,"                    \n");
-#else
-         fprintf(outfile,"%%%%BoundingBox: (atend)\n");
-#endif
-      if(getenv("USER"))
-	fprintf(outfile,"%%%%For: %s\n",getenv("USER"));
-      fprintf(outfile,
-              "%%%%Creator: gxeps $Revision: 1.13 $\n"
-              "%%%%Title: %s\n"
-              "%%%%CreationDate: %s"
-              "%%%%Pages: ",fout,ctime(&thetime));
-#ifndef GXHEPS
-      fgetpos(outfile, &pagespos);
-#endif
-      if(o->pscale !=2) {
-	fprintf(outfile,"    \n%%%%PageOrder: Ascend\n%%%%PaperSize: ");
-	if(o->pscale==1) fprintf(outfile, "A4\n");
-	else      fprintf(outfile, "Letter\n");
-      }
-      if(landscape) fprintf(outfile, "%%%%PageOrientation: Landscape\n");
-      else      fprintf(outfile, "%%%%PageOrientation: Portrait\n");
-      /*       fprintf(outfile,"%%%%DocumentFonts: "); */
-      /*      if(o->tstamp||o->label) fprintf(outfile,"Helvetica"); */
-      fprintf(outfile,"\n%%GxepsCommandLine: ");
-      for(i=0;i<argc;i++) fprintf(outfile," %s",argv[i]);
-      fprintf(outfile,"\n");
-      if(getenv("HOST"))
-	fprintf(outfile,"%%Host: %s\n",getenv("HOST"));
-      if(getenv("PWD"))
-	fprintf(outfile,"%%PWD: %s\n",getenv("PWD"));
-      if(o->comment) {			/* get user comments */
-         fprintf(outfile,"\n%%BeginUserComments\n");
-         printf("%s%s","Comments to plot=?",
-               " (Period (.) on a single line to finish)\n");
-        while(1) {
-          fgets(buf,130,stdin);
-          if(buf[0]=='.' && buf[1]=='\n') break;
-          fprintf(outfile,"%% %s",buf);
-        }
-         fprintf(outfile,"%%EndUserComments\n");
-      }
-#ifdef GXHEPS
-#if READLINE == 1
-     if(o->history) {
-       fprintf(outfile,"%%BeginGradsCommandHistory\n");
-       fclose(outfile);
-       strcpy(buf,"his -q ");
-       gahistory("his",strncat(buf,fout,255), NULL);
-       outfile=fopen(fout,"a");
-       fprintf(outfile,"%%EndGradsCommandHistory\n");
-      }
-#endif
-#endif
-      fprintf(outfile,"%%%%EndComments\n");
-      fprintf(outfile,"%s",
-                      "\n%%BeginProlog\n");
-      fprintf(outfile,"%%Change the following (values: true, false) to get color or b/w output\n");
-      fprintf(outfile,"/blackwhite {%s} def\n",
-	      (o->color) ? "false" : "true");
-      fprintf(outfile,"%s",
-	              "/clipOn {false} def\n"
-	              "/bdef {bind def} bind def\n"
-	              "/edef {exch def} bind def\n"
-                      "/in {72 mul} bdef\n"
-                      "/cm {in 2.54 div} bdef\n"
-                      "/c {setrgbcolor} bdef\n"
-                      "/g {setgray} bdef\n"
-                      "/w {setlinewidth} bdef\n"
-                      "/L {moveto rlineto stroke} bdef\n"
-                      "/D {5 -1 roll 0 setdash L []0 setdash} bdef %% dashed line\n"
-                      "/P {% Lay out a polygon\n"
-                      "    % usage: x_n y_n x_n-1 y_n-1 ... x_0 y_0 n P\n"
-                      "    3 1 roll moveto {rlineto} repeat} bdef\n"
-                      "/F {P fill} bdef %Fill a polygon\n"
-                      "/S {P stroke} bdef %Draw a polygon\n"
-                      "/gxfonts {%Usage: <font#> gxfonts\n"
-                      "    [/Helvetica /Times-Roman /Times-Italic /Symbol /Helvetica-Bold /Times-Bold] \n"
-                      "     exch get findfont} bdef\n"
-                      "/sfont {%Usage: <font#> <width> <height> sfont\n"
-                      "     /szy edef /szx edef gxfonts [szx 0 0 szy 0 0 ] makefont setfont} def\n"
-                      "/LS % Left alligned string\n" 
-                      "{ % Usage: <string> <font#> <width> <height> <angle> <pos_x> <pos_y>\n"
-                      "   gsave translate rotate sfont 0 0 moveto show grestore\n"
-                      "} def\n"
-                      "/RS % Right alligned string\n" 
-                      "{ % Usage: <string> <font#> <width> <height> <angle> <pos_x> <pos_y>\n"
-                      "   gsave translate rotate sfont 0 0 moveto dup stringwith pop \n"
-                      "   0 sub rmoveto show grestore\n"
-                      "} def\n"
-		      "/JS % General justified string \n"
-		      "{ %Usage: <string> <font#> <width> <height> "
-		      "<angle> <pos_x> <pos_y> <justx> <justy> JS\n"
-		      " % (Note: justx, justy in percent: e.g., justx=50 => x-centered)\n"
-		      "   /jy edef /jx edef gsave translate rotate sfont 0 0 moveto dup stringwidth\n"
-		      "   jy mul 0.01 neg mul exch jx mul 0.01 mul neg exch rmoveto show grestore\n} def\n"
-		      );
-if(o->pslevel>1){
-         fprintf(outfile,"%s",
-                      "/B {rectfill} bdef %Fill a box, usage: xlow ylow width height B\n");
-         fprintf(outfile,"%s",
-                      "/iso_reencode { % Usage: <Font> iso_reencode\n"
-                      "  dup /isoname exch def findfont\n"
-                      "  dup length dict begin\n"
-                      "  { 1 index /FID ne\n"
-                      "      {def}\n"
-                      "      {pop pop}\n"
-                      "      ifelse\n"
-                      "  } forall\n"
-                      "  /Encoding ISOLatin1Encoding def\n"
-                      "  currentdict end\n"
-                      "  isoname exch definefont pop\n"
-		      "} def\n"
-		      "[/Helvetica /Times-Roman /Times-Italic /Helvetica-Bold /Times-Bold]\n"
-                      "   {iso_reencode} forall\n");
-      }
-      else { 
-         fprintf(outfile,"%s",
-                      "/B { %Fill a box, usage: xlow ylow width height B\n"
-                      "     /height exch def /width exch def moveto width 0 rlineto\n"
-                      "     0 height rlineto width neg 0 rlineto closepath fill} bdef \n");
-      }
-         fprintf(outfile,"%s",
-                      "/BL { %layout a box, usage: xlow ylow width height BL\n"
-                      "     /height exch def /width exch def moveto width 0 rlineto\n"
-                      "     0 height rlineto width neg 0 rlineto closepath} bdef \n");
-         fprintf(outfile,"%s","/G {gsave} bdef /R {grestore} bdef\n");
-/*          fprintf(outfile,"%s", */
-/*                       "/C { %Clip a box, usage: xlow ylow width height C\n" */
-/*                       "  clippath BL  clip newpath} bdef \n"); */
-         fprintf(outfile,"%s", 
-                      "/C0 { %Reset clip path\n"  
-                      "     clipOn {grestore /clipOn {false} def} if} def\n"
-                      "/C1 { %Reset clipping to a box. Usage: xlow ylow width height C\n" 
-                      "      clipOn {grestore} if gsave /clipOn {true} def\n"
-		      "      BL eoclip newpath } bdef\n" 
-                      "/C2 {%Add clip inside a box to current clipping.  Usage: xlow ylow width height C \n"
-                      "      clipOn not {gsave /clipOn {true} def} if\n"
-                      "     clippath BL eoclip newpath } bdef\n");
-
-
-      fprintf(outfile,"\n%%Define line widths\n");
-      for (i=0;i<12;i++) fprintf(outfile,"/w%i {%s} bdef\n",i,widths[i]);
-
-      fprintf(outfile,"\n%%Define dashes\n");
-      fprintf(outfile,"/s0 {[] 0 setdash} bdef\n");
-      fprintf(outfile,"/s1 {[] 0 setdash} bdef\n");
-      fprintf(outfile,"/s2 {[125 60] 0 setdash} bdef\n");
-      fprintf(outfile,"/s3 {[60 60] 0 setdash} bdef\n");
-      fprintf(outfile,"/s4 {[125 60 60 60] 0 setdash} bdef\n");
-      fprintf(outfile,"/s5 {[10 40] 0 setdash} bdef\n");
-      fprintf(outfile,"/s6 {[75 60] 0 setdash} bdef\n");
-      fprintf(outfile,"/s7 {[125 40 15 15 15 40] 0 setdash} bdef\n");
-      fprintf(outfile,"/s8 {[15 80] 0 setdash} bdef\n");
-      
-
-      fprintf(outfile,"\n%%Define colors:\n");
-      if (o->reverse) {                       /* switch black and white colors */
-          fprintf(outfile,"/c0 {%s g} bdef %%black and white reversed\n",gr[1]);
-          fprintf(outfile,"/c1 {%s g} bdef\n",gr[0]);
-      } else {
-          for (i=0;i<2;i++) fprintf(outfile,"/c%i {%s g} bdef\n",i,gr[i]);
-      }
-      for (i=2;i<16;i++) fprintf(outfile,"/c%i {%s c} bdef\n",i,col[i]);
-
-      fprintf(outfile,"\n%%Define grays:\n");
-      if (o->reverse) {                       /* switch black and white */
-          fprintf(outfile,"/g0 {%s g} bdef %%black and white reversed\n",gr[1]);
-          fprintf(outfile,"/g1 {%s g} bdef\n",gr[0]);
-      } else {
-          for (i=0;i<2;i++) fprintf(outfile,"/g%i {%s g} bdef\n",i,gr[i]);
-      }
-      for (i=2;i<16;i++) fprintf(outfile,"/g%i {%s g} bdef\n",i,gr[i]);
-      fprintf(outfile,"\nblackwhite\n");
-      fprintf(outfile,"{ %%Black&white output: re-define line colors black, fill colors gray... \n  ");
-      for (i=1;i<16;i++) fprintf(outfile,"/c%i {g1} def%s",i,(((i+1)%5)==0) ? "\n  " : " ");
-      fprintf(outfile,"}\n{ %%Color output: undefine fill-colors... \n  ");
-      for (i=0;i<16;i++) fprintf(outfile,"/g%i {c%i} def%s",i,i,(((i+1)%5)==0) ? "\n  " : " ");
-      fprintf(outfile,"\n} ifelse\n");
-      
-
-      fprintf(outfile,"%%%%EndProlog\n\n%%%%BeginSetup\n");
-      fprintf(outfile,"1 setlinecap 1 setlinejoin\n%%%%EndSetup\n");
-#ifndef GXHEPS
-      fgetpos(outfile,&pagepos);
-#endif
-      fprintf(outfile,"%%%%Page: 1 1\n");
-      return;
-}
-/* --------------------------------------------------------------------------------- */
-
-void init_newpage(short landscape,char *fout,struct options *o){
-      int i;
-      char buf[130];
-      time_t thetime=time(NULL);
-      struct tm *ltime=localtime(&thetime);
-#ifndef GXHEPS
-      if (o->reverse) {
-        fgetpos(outfile, &blackpos);
-        fprintf(outfile,"                              %% black background\n");
-      }
-#endif
-      if(o->tstamp||o->label) fprintf(outfile,"gsave\n");
-      if(o->pscale==1) { /* A4 paper */
-        if (o->rotate) {
-	  fprintf(outfile,"21 cm 0 translate 90 rotate\n"); /* landscape mode */
-          fprintf(outfile,"%i %i translate %%move origin slightly in\n",A4YOFF, A4XOFF);
-	} else {
-          fprintf(outfile,"%i %i translate %%move origin slightly in\n",A4XOFF, A4YOFF);
-	}
-	fprintf(outfile,"%f %f scale  %% Units: 1000 = 2 cm\n",A4SCALE, A4SCALE);
-      } else if (o->pscale==0){ /* Letter paper */
-        if (o->rotate) {
-	  fprintf(outfile,"8.5 in 0 translate 90 rotate %% landscape\n");
-          fprintf(outfile,"%i %i translate %%move origin slightly in\n",LETYOFF,LETXOFF);
-	} else {
-          fprintf(outfile,"%i %i translate %%move origin slightly in\n",LETXOFF,LETYOFF);
-	}
-	fprintf(outfile,"%f %f scale  %%Units: 1000 = .9125 inch\n",LETSCALE, LETSCALE);
-      } else if (o->pscale==2){ /* GrADS 8.5''x 11' scaling */
-        if (o->rotate) 
-	  fprintf(outfile,"8.5 in 0 translate 90 rotate %% landscape\n");
-	fprintf(outfile,"%f %f scale  %%Units: 1000 = .9125 inch\n",GASCALE, GASCALE);
-      }
-      if(landscape)
-	fprintf(outfile,"0 0 %d %d BL clip newpath %% Initial clipping.\n",
-			    11000/RSCALE, 8500/RSCALE);
-      else
-	fprintf(outfile,"0 0 %d %d BL clip newpath %% Initial clipping.\n",
-			    8500/RSCALE, 11000/RSCALE);
-	
-      fprintf(outfile,"c1\n");
-      if(o->tstamp||o->label) {
-	fprintf(outfile,"matrix currentmatrix %% store CTM\n");
-        fprintf(outfile,"grestore\nc1 /Helvetica findfont 8 scalefont setfont\n");
-	if(o->pscale) fprintf(outfile,"1 cm 28.5 cm translate 0 0 moveto\n");
-	else     fprintf(outfile,"0.3 in 0.5 in translate 0 0 moveto\n");
-	if(o->tstamp) {
-          strftime(buf,130,"%c",ltime);
-	  fprintf(outfile,"(%s,  %s) show %%file and time stamp\n", fout,buf);
-	}
-        if(o->label) {			/* get user label */
-          fprintf(outfile,"\n\n%%BeginUserLabel\n");
-          printf("   %s%s","Label to print on the plot=?"," (Period (.) on a single line to finish)\n");
-          while(1) {
-            fgets(buf,130,stdin);
-            if(buf[0]=='.' && buf[1]=='\n') break;
-            fprintf(outfile,"0 -7 translate 0 0 moveto (");
-	    for (i=0;i<strlen(buf)-1;i++){
-	      if(buf[i]=='(' || buf[i]==')'|| buf[i]=='\\') fprintf(outfile,"%c",'\\'); 
-              fprintf(outfile,"%c",buf[i]);
-            }
-	    fprintf(outfile,") show\n");
-          }
-          fprintf(outfile,"%%EndUserLabel\n");
-        }
-        fprintf(outfile,"setmatrix %% restore CTM\n");
-      }
-      return;
-}
-/* --------------------------------------------------------------------------------- */
-
-void drawline(struct point pnts[],short *pcnt,
-	      short lcolor,short *colold,short *lastfill,short flush){
-   register int i,im,j,colum;
-   static short LastLine=0;
-   static short firstcall=1;
-   static struct point *dline;
-   long dx,dy,dx1,dy1;
-
-   /* flush=1; mm debugging */
-
-   if(firstcall) {
-      dline=(struct point *) malloc(4*sizeof(struct point)); 
-      firstcall=0;
-   }
-   if(*pcnt==1) {
-      if (LastLine==2){ /* there is a saved dashed line */
-	     if ((LastLine=CheckExpandDashLine(pnts,dline))==2) {
-	        dline[1].x=pnts[1].x; dline[1].y=pnts[1].y;
-	     } else { /*  Dashed Line  not expandable => print dashed line */
-	        PrintDashLine(dline);
-		LastLine=SaveLine(pnts,dline);
-	     }
-      } else if (LastLine==1) { /* there is a saved non-dashed line */
-            if((LastLine=CheckDashLine(pnts,dline))==2) {                 
-	        SetDline(pnts,dline);
-            } else { /* Not New LastLine */
-	        PrintDashLine(dline);
-		LastLine=SaveLine(pnts,dline);
-	    }
-      } else { /* no last line saved */
-         if (lcolor != (*colold) || (*lastfill) ) {
-             fprintf(outfile,"c%i ",lcolor);
-             *lastfill=0;
-             *colold=lcolor;
-         }
-	    LastLine=SaveLine(pnts,dline);
-      }
-      if(flush){ 
-   if ( lcolor != (*colold) || (*lastfill) )  {
-     fprintf(outfile,"c%i ",lcolor);
-     *lastfill=0;
-     *colold=lcolor;
-   }
-	 PrintDashLine(dline);
-	 LastLine=0;
-      }
-   } else { 
-        if(LastLine) PrintDashLine(dline);
-	if(*pcnt>1){
-           if ( lcolor != (*colold) || (*lastfill) ) {
-                fprintf(outfile,"c%i ",lcolor);
-                *lastfill=0;
-                *colold=lcolor;
-           }
-	   dx=(long)(pnts[*pcnt].x- pnts[(*pcnt)-1].x);
-	   dy=(long)(pnts[*pcnt].y- pnts[(*pcnt)-1].y);
-	   j=0;
-	   colum=1;
-           for(i=(*pcnt)-1;i>0;i--) {
-              im=i-1;
-	      dx1=(long)(pnts[i].x-pnts[im].x);
-	      dy1=(long)(pnts[i].y-pnts[im].y);
-	      if (((dx==0&&dy==0) || (dx*dy1==dx1*dy)) && !((dx==0&&dx1!=0) || (dy==0&&dy1!=0)) ) {
-		 dx+=dx1;
-		 dy+=dy1;
-		 (*pcnt)--;
-	      } else {
-		             /* if old and new line directions disagree */
-		 colum+=fprintf(outfile,"%ld %ld",dx,dy);
-                 if (colum>=70) {
-		     fprintf(outfile,"%c",'\n');
-		     colum=1;
-		 } else 
-		     colum+=fprintf(outfile,"%c",' ');
-		 dx=dx1;
-		 dy=dy1;
-	      }
-           }
-	   fprintf(outfile,"%ld %ld",dx,dy);
-                 if (colum>=60) {
-		     fprintf(outfile,"%c",'\n');
-		     colum=1;
-		 } else 
-		     colum+=fprintf(outfile,"%c",' ');
-           colum+=fprintf(outfile,"%i %i ",pnts[0].x,pnts[0].y);
-	   if(flush==-1) fprintf(outfile,"%i P\n",*pcnt);
-	   else
-	     if(*pcnt==1) fprintf(outfile,"L\n");
-	     else fprintf(outfile,"%i S\n",*pcnt);
-	}
-	LastLine=0;
-   } 
-   *pcnt=0;
-}
-/* --------------------------------------------------------------------------------- */
-int SaveLine(struct point pnts[],struct point dline[]){
-  dline[0].x=pnts[0].x;
-  dline[0].y=pnts[0].y;
-  dline[1].x=pnts[1].x;
-  dline[1].y=pnts[1].y;
-  dline[2].x=pnts[0].x;
-  dline[2].y=pnts[0].y;
-  dline[3].x=pnts[0].x;
-  dline[3].y=pnts[0].y;
-  return 1;
-}
-/* --------------------------------------------------------------------------------- */
-void PrintDashLine(struct point dline[]){
-  short SolidLine,dxsolid,dysolid,dxskip,dyskip;
-  dxsolid=dline[2].x-dline[0].x;
-  dysolid=dline[2].y-dline[0].y;
-  dxskip=dline[3].x-dline[2].x;
-  dyskip=dline[3].y-dline[2].y;
-  SolidLine= ((dxsolid==0)&&(dysolid==0)&&(dxskip==0)&&(dyskip==0));
-  if(!SolidLine) fprintf(outfile,"[%i %i] ",
-	      (short) (sqrt((float) dxsolid*dxsolid+(float) dysolid*dysolid)+0.5),
-	      (short) (sqrt((float) dxskip*dxskip+(float) dyskip*dyskip)+0.5));
-  fprintf(outfile,"%i %i %i %i %c\n",dline[1].x-dline[0].x,dline[1].y-dline[0].y,
-	  dline[0].x,dline[0].y,SolidLine ? 'L' : 'D');
-  return;
-}
-/* --------------------------------------------------------------------------------- */
-short CheckDashLine(struct point pnts[],struct point dline[]){
-  short dx,dy;
-  dx=pnts[1].x-pnts[0].x;
-  if (dx!=dline[1].x-dline[0].x) return 1; /* delta x disagree */
-  dy=pnts[1].y-pnts[0].y;
-  if (dy!=dline[1].y-dline[0].y) return 1; /* delta y disagree */
-  if((int) dx *(pnts[0].y-dline[1].y) !=(int) (pnts[0].x-dline[1].x)*dy)
-      return 1;  /* line directions disagree */
-  else return 2;
-}
-/* --------------------------------------------------------------------------------- */
-short CheckExpandDashLine(struct point pnts[],struct point dline[]){
-  if( (dline[3].x-dline[2].x!=pnts[0].x-dline[1].x) ||
-      (dline[3].y-dline[2].y!=pnts[0].y-dline[1].y) ||
-      (dline[2].x-dline[0].x!=pnts[1].x-pnts[0].x)  ||
-      (dline[2].y-dline[0].y!=pnts[1].y-pnts[0].y)    )return 1;
-  else return 2;
-}
-/* --------------------------------------------------------------------------------- */
-void SetDline(struct point pnts[],struct point dline[]){
-  dline[2].x=dline[1].x;
-  dline[2].y=dline[1].y;
-  dline[3].x=pnts[0].x;
-  dline[3].y=pnts[0].y;
-  dline[1].x=pnts[1].x;
-  dline[1].y=pnts[1].y;
-  return;
-  }
-/* --------------------------------------------------------------------------------- */
-void fillline(struct point pnts[],short pcnt){
-   register int i,im;
-   /* check if the polygon is a rectangel: */
-   if(pcnt==4 &&  pnts[0].x==pnts[1].x && pnts[2].x==pnts[3].x &&
-	     pnts[1].y==pnts[2].y && pnts[0].y==pnts[3].y) {
-      fprintf(outfile,"%i %i %i %i B\n",
-	      pnts[0].x,pnts[0].y,pnts[2].x-pnts[0].x,pnts[2].y-pnts[0].y);
-   } else if(pcnt==4 && pnts[0].y==pnts[1].y && pnts[2].y==pnts[3].y &&
-	     pnts[1].x==pnts[2].x && pnts[0].x==pnts[3].x) {
-      fprintf(outfile,"%i %i %i %i B\n",
-	      pnts[0].x,pnts[0].y,pnts[2].x-pnts[0].x,pnts[2].y-pnts[0].y);
-   } else {
-     long dx,dy,dx1,dy1;
-     int j,colum;
-	   dx=(long)(pnts[pcnt].x- pnts[(pcnt)-1].x);
-	   dy=(long)(pnts[pcnt].y- pnts[(pcnt)-1].y);
-	   j=0;
-	   colum=1;
-           for(i=(pcnt)-1;i>0;i--){
-              im=i-1;
-	      dx1=(long)(pnts[i].x-pnts[im].x);
-	      dy1=(long)(pnts[i].y-pnts[im].y);
-	      if (((dx1==0&&dy1==0) ||
-		   (dx*dy1==dx1*dy)) && !((dx==0&&dx1!=0)||(dy==0&&dy1!=0)) ) {
-		 dx+=dx1;
-		 dy+=dy1;
-		 (pcnt)--;
-	      } else {      /* if old and new line directions disagree */
-		 colum+=fprintf(outfile,"%ld %ld",dx,dy);
-                 /* (j++%10==9) ? fprintf(outfile,"%c",'\n') : fprintf(outfile,"%c",' '); */
-                 if (colum>=70) {
-		     fprintf(outfile,"%c",'\n');
-		     colum=1;
-		 } else 
-		     colum+=fprintf(outfile,"%c",' ');
-		 dx=dx1;
-		 dy=dy1;
-	      }
-           }
-	   if(colum>=60)
-	       fprintf(outfile,"%ld %ld\n%i %i %i F\n",dx,dy,pnts[0].x,pnts[0].y,pcnt);
-	   else
-               fprintf(outfile,"%ld %ld %i %i %i F\n",dx,dy,pnts[0].x,pnts[0].y,pcnt);
-   }
-}
-/* --------------------------------------------------------------------------------- */
-
-void boundbox(struct point* pnts){  /* compute bounding box */
-  /*  Does not work because of clipping to the outside 
-   *  For now, let's not take clipping into account
-   *  *** TO BE FIXED ***
-  if((cliplow.x<bblow.x) && (pnts->x<bblow.x)) bblow.x=max(pnts->x,cliplow.x);
-  if((cliplow.y<bblow.y) && (pnts->y<bblow.y)) bblow.y=max(pnts->y,cliplow.y);
-  if((cliphigh.x>bbhigh.x) && (pnts->x>bbhigh.x)) bbhigh.x=min(pnts->x,cliphigh.x);
-  if((cliphigh.y>bbhigh.y) && (pnts->y>bbhigh.y)) bbhigh.y=min(pnts->y,cliphigh.y);
-  */
-     if(pnts->x<bblow.x) bblow.x=pnts->x;
-     if(pnts->y<bblow.y) bblow.y=pnts->y;
-    if(pnts->x>bbhigh.x) bbhigh.x=pnts->x;
-     if(pnts->y>bbhigh.y) bbhigh.y=pnts->y;
-     return;
-}
-/* --------------------------------------------------------------------------------- */
-void printbbox(short pscale,short landscape,struct options *o){
-#ifndef GXHEPS
-     fsetpos(outfile, &bboxpos);
-#endif
-     if(pscale) {
-        bblow.x= ( (float) bblow.x) *A4SCALE;
-        bbhigh.x= ((float) bbhigh.x)*A4SCALE;
-        bblow.y= ((float) bblow.y)*A4SCALE;
-        bbhigh.y= ((float) bbhigh.y)*A4SCALE;
-        if(o->rotate==0) {
-          fprintf(outfile,"%i %i %i %i",
-               bblow.x+A4XOFF-BORDER,bblow.y+A4YOFF-BORDER,bbhigh.x+A4XOFF+BORDER,
-		  bbhigh.y+A4YOFF+BORDER);
-#ifndef GXHEPS
-	  if(o->reverse) {
-            fsetpos(outfile, &blackpos);
-            fprintf(outfile,"0 g %i %i %i %i B 1 g ",
-               bblow.x+A4XOFF-BORDER,bblow.y+A4YOFF-BORDER,bbhigh.x-bblow.x+2*BORDER,
-		    bbhigh.y-bblow.y+2*BORDER);
-	  }
-#endif
-        } else {
-           fprintf(outfile,"%i %i %i %i",
-              595-bbhigh.y-A4XOFF-BORDER,bblow.x+A4YOFF-BORDER,612-bblow.y-A4XOFF+BORDER,
-		   bbhigh.x+A4YOFF+BORDER);
-#ifndef GXHEPS
-	  if(o->reverse) {
-            fsetpos(outfile, &blackpos);
-            fprintf(outfile,"0 g %i %i %i %i B 1 g ",
-		  595-bbhigh.y-A4XOFF-BORDER,bblow.x+A4YOFF-BORDER,bbhigh.y-bblow.y+2*BORDER,
-		    bbhigh.x-bblow.x+2*BORDER); 
-	  }
-#endif
-	}
-     } else {
-        bblow.x= ((float) bblow.x)*LETSCALE;
-        bbhigh.x= ((float) bbhigh.x)*LETSCALE;
-        bblow.y= ((float) bblow.y)*LETSCALE;
-        bbhigh.y= ((float) bbhigh.y)*LETSCALE;
-        if(o->rotate==0){
-           fprintf(outfile,"%i %i %i %i",
-               bblow.x+LETXOFF-BORDER,bblow.y+LETYOFF-BORDER,bbhigh.x+LETXOFF+BORDER,
-		   bbhigh.y+LETYOFF+BORDER);
-#ifndef GXHEPS
-	  if(o->reverse) {
-            fsetpos(outfile, &blackpos);
-            fprintf(outfile,"0 g %i %i %i %i B 1 g ",
-               bblow.x+LETXOFF-BORDER,bblow.y+LETYOFF-BORDER,bbhigh.x-bblow.x+2*BORDER,
-		    bbhigh.y-bblow.y+2*BORDER);
-	  }
-#endif
-	} else {
-           fprintf(outfile,"%i %i %i %i",
-              612-bbhigh.y-LETXOFF-BORDER,bblow.x+LETYOFF-BORDER,612-bblow.y-LETXOFF+BORDER,
-		   bbhigh.x+LETYOFF+BORDER);
-#ifndef GXHEPS
-	  if(o->reverse) {
-            fsetpos(outfile, &blackpos);
-            fprintf(outfile,"0 g %i %i %i %i B 1 g ",
-		      612-bbhigh.y-LETXOFF-BORDER,bblow.x+LETYOFF-BORDER,
-		    bbhigh.y-bblow.y+2*BORDER,bbhigh.x-bblow.x+2*BORDER); 
-	  }
-#endif
-	}
-     }
-#ifndef GXEPS       
-     fseek(outfile,0L,2); 
-#endif
-}
-/* --------------------------------------------------------------------------------- */
-
-
-int parse_arg(int argc,char *argv[],struct options *o,char **fin, char **fout){
-     register int i,j;
-     i = 1;
-#ifndef GXHEPS
-     if(argc==1) return(print_options(argv));
-#endif
-
-     for (i=1;i<argc;i++) {
-
-     if (*(argv[i])=='-') {  /* parse options */
-       j = 0;
-       while (*(argv[i]+(++j))) {
-         if      (*(argv[i]+j)=='a') o->pscale = 1;
-         else if (*(argv[i]+j)=='1') o->pslevel = 1;
-         else if (*(argv[i]+j)=='2') o->pslevel = 2;
-	 else if (*(argv[i]+j)=='b') o->color = 0;
-         else if (*(argv[i]+j)=='c') o->color = 1;
-#ifdef NEVER_CTL_D
-         else if (*(argv[i]+j)=='d') ;
-#else
-         else if (*(argv[i]+j)=='d') o->ctl_d = !o->ctl_d;
-#endif
-#ifdef PSFONTS
-         else if (*(argv[i]+j)=='f') o->font =0;
-#endif
-         else if (*(argv[i]+j)=='g') o->pscale = 2;
-	 else if (*(argv[i]+j)=='G') o->graylines = 1;
-	 else if (*(argv[i]+j)=='h') return (print_options(argv));
-	 else if (*(argv[i]+j)=='H') o->history = 0;
-         else if (*(argv[i]+j)=='i') {*fin = argv[++i];break;}
-         else if (*(argv[i]+j)=='l') o->pscale = 0;
-         else if (*(argv[i]+j)=='L') o->label = 1;
-         else if (*(argv[i]+j)=='n') o->comment = 1;
-         else if (*(argv[i]+j)=='o') {*fout = argv[++i];break;}
-         else if (*(argv[i]+j)=='r') o->reverse = 1;
-         else if (*(argv[i]+j)=='R') o->rotate = 0;
-         else if (*(argv[i]+j)=='s') o->tstamp = 1;
-         else if (*(argv[i]+j)=='v') o->verbose = 1;
-         else { 
-	   fprintf(stderr,"Unknown option: %s\n\n",argv[i]);
-	   print_options(argv);
-	     return(1);
-	 }
-       }
-     }
-    else  /* No command line "-" */
-#ifdef GXHEPS
-	 *fout = argv[i];
-#else
-      *fin=argv[i];
-#endif
-  }
-#ifdef GXHEPS
-     if(*fout==NULL)
-       *fout="grads.eps";
-#endif     
-     return(0);
-}
-/* --------------------------------------------------------------------------------- */
-
-int print_options(char *argv[]){
-#ifndef GXHEPS	       
-	       /* printf("   This is gxeps $Revision: 1.13 $\n"); */
-	       printf("   This is gxeps Version: GRADS_VERSION\n");
-#endif
-#ifdef NEVER_CTL_D
-       fprintf(stderr,"   %s%s%s","Usage: ",argv[0],
-#ifndef GXHEPS	       
-	   " [-abcfghiLlnRrsv -i <in_file>[."  IN_EXT
-#else
-	   " [-abcfghiLlnRrsv"
-#endif 
-           "] -o <out_file>] [<in_file>[."IN_EXT"]].\n");
-#else
-       fprintf(stderr,"%s%s%s","Usage: ",argv[0],
-	   " [-acdifhLlnRrsv -i <in_file>[."  IN_EXT
-           "] -o <out_file>] [<in_file>[."IN_EXT"]].\n");
-#endif
-       fprintf(stderr,"Options:\n");
-       fprintf(stderr,"     -1   PostScript Level 1 output.\n");
-       fprintf(stderr,"     -2   PostScript Level 2 output  (default).\n");
-       fprintf(stderr,"     -a   A4 paper.\n");
-       fprintf(stderr,"     -b   Black & white output.\n");
-       fprintf(stderr,"     -c   Color output (default).\n");
-#ifndef NEVER_CTL_D
-       if(DEFAULT_CTL_D)  fprintf(stderr,"     -d   Do not add Control-D at end.\n");
-       else fprintf(stderr,"     -d   Add Control-D at end.\n");
-#endif
-#ifdef PSFONTS
-       fprintf(stderr,"     -f   Do not use PostScript fonts.\n");
-#endif
-       fprintf(stderr,"     -g   True 8.5'' x 11'' output (GrADS scaling).\n");
-       fprintf(stderr,"     -G   Use gray lines in black & white mode (default: all black).\n");
-#ifdef GXHEPS
-       fprintf(stderr,"     -H   Do not include GrADS command history in output.\n");
-#endif
-       fprintf(stderr,"     -h   Help.\n");
-#ifndef GXHEPS	       
-       fprintf(stderr,"     -i   <in_file>[."IN_EXT"], '-' = stdin.\n");
-#endif
-       fprintf(stderr,"     -l   letter paper\n");
-       fprintf(stderr,"     -L   Ask for a label to be printed on the plot.\n");
-       fprintf(stderr,"     -n   Ask for a note to include in postscript file header.\n");
-       fprintf(stderr,"     -o   <out_file> (default: basename(in_file)."OUT_EXT", '-' = stdout).\n");
-#ifndef GXHEPS	       
-       fprintf(stderr,"     -R   Do not rotate landscape metafiles.\n");
-#endif
-       fprintf(stderr,"     -r   Black background.\n");
-       fprintf(stderr,"     -s   Add a file & time stamp.\n");
-       fprintf(stderr,"     -v   Verbose.\n\n");
-       fprintf(stderr,"For more information visit http://www.bol.ucla.edu/~munnich/grads/gxeps.html.\n");
-     return(8);
-     }
-/* --------------------------------------------------------------------------------- */
-
-int openfiles(char **fin, char **fout,short verbose){ /* Open files */
-
-#ifndef GXHEPS
-  int i;
-  if (*fin==NULL) {
-    *fin = (char *) malloc(sizeof(char)*150);
-     fgets(*fin,150,stdin);
-     printf("   Read infile = %s\n",*fin);
-  }
-  if(strcmp(*fin,"-")==0) infile=stdin;
-  else infile = fopen(*fin ,"rb");
-  if (infile == NULL) {
-    *fin=strcat(*fin,"."IN_EXT);
-    infile = fopen(*fin,"rb");
-    if (infile == NULL) {
-      (*fin)[strlen(*fin)-3]='\0';
-      printf ("Input file %s[."IN_EXT"] not found.\n",*fin);
-      return(1);
-    }
-  }
-  /* setvbuf(infile,NULL,_IOFBF,(size_t) 524288L); */
-  if (*fout==NULL) {
-    *fout = (char *) malloc(sizeof(char)*150);
-    strcpy(*fout,*fin);
-    for (i=strlen(*fout)-1;i>=0;i--) {
-      if((*fout)[i]=='.') {strcpy((*fout)+i+1,OUT_EXT);
-	break;
-      }
-      if(i==0){strcpy((*fout)+strlen(*fout),"."OUT_EXT);}
-    }
-  }
-#endif
-  if(strcmp(*fout,"-")==0) outfile=stdout;
-  else outfile = fopen(*fout,"w");
-  if (outfile==NULL) {
-    printf ("Error opening output file %s \n",*fout);
-    return(1);
-  }
-  if(verbose) {
-    printf("\n   Gxeps $Revision: 1.13 $\n");
-#ifndef GXHEPS
-    printf("     Input file  = %s\n",*fin);
-#endif
-    if(strcmp(*fout,"-")==0) printf("output to stdout\n");
-    else printf("     Output file = %s\n",*fout);
-  }
-  /* setvbuf(outfile,NULL,_IOFBF,(size_t) 524288L); */
-  return(0);
-}
-/* --------------------------------------------------------------------------------- */
-void setjust(short *opts, short *justx, short *justy)
-{	/* 
-	 * Set justification
-	 * for just>9 an addition border of size height is
-	 * added. This is mainly used for axis labels who initial
-	 * position touched the axis.
-	 */
-	short just,wid;
-	struct point pnt;
-
-	just=opts[7];
-	/*  Remember:
-	 *  xpos=opts[1];
-	 *  ypos=opts[2];
-	 *  height=opts[3].
-	 */
-	if(just==2) {
-		*justx=50;
-		*justy=0;
-	} else if (just==3) {
-		*justx=100;
-		*justy=0;
-	} else if (just==4) {
-		*justx=0;
-		*justy=50;
-	} else if (just==5) {
-		*justx=50;
-		*justy=50;
-	} else if (just==6) {
-		if(opts[5]/64==90) {
-			*justx=50;
-			*justy=100;
-		} else {
-			*justx=100;
-			*justy=50;
-		}
-	} else if (just==7) {
-		*justx=0;
-		*justy=100;
-	} else if (just==8) {
-		*justx=50;
-		*justy=100;
-	} else if (just==9) {
-		*justx=100;
-		*justy=100;
-	} else if (just==11) { /* title, x-axis label top */
-		*justx=50;
-		*justy=100;
-		opts[2]+=opts[3];
-	} else if (just==12) { /* y-axis label left */
-		*justx=100;
-		*justy=50;
-		opts[1]-=opts[3];
-		opts[2]-=opts[3]/2;
-	} else if (just==13) { /* yaxis label right */
-		*justx=0;
-		*justy=50;
-		opts[1]+=opts[3]; 
-		opts[2]-=opts[3]/2;
-	} else if (just==14) { /* title or x-axis label */
-		*justx=50;
-		*justy=100;
-		opts[2]-=2*opts[3];
-	}
-	/* Guess new bounding box
-	 * 
-	 * We dont know the exact string width 
-	 * and guess it to be height * strlen * 3/4
-	 */
-
-	wid=opts[3]*opts[0]*3/4; 
-	/* lower left */
-	pnt.x=opts[1]-wid * *justx/100;
-	pnt.y=opts[2]-opts[3]**justy/100;
-	boundbox(&pnt);
-	/* lower right */
-	pnt.x=opts[1]+wid*(100 - *justx)/100;
-	boundbox(&pnt);
-	/* upper right */
-	pnt.y=opts[2]+opts[3]*(100 - *justy)/100;
-	boundbox(&pnt);
-	/* upper left */
-	pnt.x=opts[1]-wid * *justx/100;
-	boundbox(&pnt);
-  return;
-}
-/* --------------------------------------------------------------------------------- */
-/*
-/Helvetica findfont
-dup length dict begin
-  { 1 index /FID ne
-      {def}
-      {pop pop}
-    ifelse
-  }
-/Encoding ISOLatin1Encoding def
-  currentdict
-end
-/Helvetica-ISOLatin1 exch definefont pop
-
-/iso_reencode { 
-  dup findfont
-  dup length dict begin
-  { 1 index /FID ne
-      {def}
-      {pop pop}
-      ifelse
-  } forall
-  /Encoding ISOLatin1Encoding def
-  currentdict end
-  exch definefont pop 
-} def
- */
-/* --------------------------------------------------------------------------------- */
diff --git a/src/gxgif.c b/src/gxgif.c
deleted file mode 100644
index cec4ceb..0000000
--- a/src/gxgif.c
+++ /dev/null
@@ -1,2683 +0,0 @@
-/***********************************************************
- *
- * GXGIF: a grads metafile to GIF converter.
- * Written by Matthias Muennich 
- *
- *   $Log: gxgif.c,v $
- *   Revision 1.5  2009/04/30 15:25:31  jma
- *   changed max number of colors from 99 to 255
- *
- *   Revision 1.4  2009/01/05 12:48:24  jma
- *   changed
- *   #include <config.h>
- *   to
- *   #include "config.h"
- *
- *   Revision 1.3  2003/06/24 21:31:08  joew
- *   put conditionals around #include malloc.h, for Mac OS X
- *
- *   Revision 1.2  2002/10/28 19:08:33  joew
- *   Preliminary change for 'autonconfiscation' of GrADS: added a conditional
- *   #include "config.h" to each C file. The GNU configure script generates a unique config.h for each platform in place of -D arguments to the compiler.
- *   The include is only done when GNU configure is used.
- *
- *   Revision 1.1.1.1  2002/06/27 19:44:05  cvsadmin
- *   initial GrADS CVS import - release 1.8sl10
- *
- *   Revision 1.1.1.1  2001/10/18 02:00:54  Administrator
- *   Initial repository: v1.8SL8 plus slight MSDOS mods
- *
- *   Revision 0.4  1997/12/19 10:43:56  m211033
- *   Added a version statement in verbose mode.
- *
- *   Revision 0.3  1997/12/04 10:08:26  m211033
- *   Copied the subroutines used from gd1.2 into gxgif.c
- *   to make the code independent of the gd library.
- *   Added an option "-h" for horizontal filling of polygons
- *   (=> horizontal spurious lines).
- *   Fixed the output file names for more that 1 image.
- *   Fixed the "-r" option.
- *
- *   Revision 0.2  1997/02/25 13:30:35  m211033
- *   Added support for different line thicknesses and
- *   cleaned up the code.
- *
- *   Revision 0.1  1997/02/21 15:20:51  m211033
- *   different line width are not yet supported.
- *   The gdImageFilledPolygon routine gives wrong height
- *   when filling horizontally. This led to flaud horizontal
- *   lines in the GIF file. I rewrote it switching x and y
- *   coordinates. The lines disappeared. Now vertical lines
- *   may show up. For a fix we have to wait for a better
- *   version on gdImageFilledPolygon.
- *   No black and white mode is available right now.
- *
- *
- *
- ***********************************************************/
-
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-
-/* If autoconfed, only include malloc.h when it's presen */
-#ifdef HAVE_MALLOC_H
-#include <malloc.h>
-#endif
-
-#else /* undef HAVE_CONFIG_H */
-
-#include <malloc.h>
-
-#endif /* HAVE_CONFIG_H */
-
-#include <stdio.h>
-#include <math.h>
-#include <string.h>
-#include <stdlib.h>
-/*  #include "gd.h" */
-static char rcsid[] = "$Id: gxgif.c,v 1.5 2009/04/30 15:25:31 jma Exp $";
-
-/* ---------------------------- begin gd.h -------------------------------------- */
-#ifndef GD_H
-#define GD_H 1
-
-/* gd.h: declarations file for the gifdraw module.
-
-	Written by Tom Boutell, 5/94.
-	Copyright 1994, Cold Spring Harbor Labs.
-	Permission granted to use this code in any fashion provided
-	that this notice is retained and any alterations are
-	labeled as such. It is requested, but not required, that
-	you share extensions to this module with us so that we
-	can incorporate them into new versions. */
-
-/* stdio is needed for file I/O. */
-#include <stdio.h>
-
-/* This can't be changed, it's part of the GIF specification. */
-
-#define gdMaxColors 256
-
-/* Image type. See functions below; you will not need to change
-	the elements directly. Use the provided macros to
-	access sx, sy, the color table, and colorsTotal for 
-	read-only purposes. */
-
-typedef struct gdImageStruct {
-	unsigned char ** pixels;
-	int sx;
-	int sy;
-	int colorsTotal;
-	int red[gdMaxColors];
-	int green[gdMaxColors];
-	int blue[gdMaxColors]; 
-	int open[gdMaxColors];
-	int transparent;
-	int *polyInts;
-	int polyAllocated;
-	struct gdImageStruct *brush;
-	struct gdImageStruct *tile;	
-	int brushColorMap[gdMaxColors];
-	int tileColorMap[gdMaxColors];
-	int styleLength;
-	int stylePos;
-	int *style;
-	int interlace;
-} gdImage;
-
-typedef gdImage * gdImagePtr;
-
-typedef struct {
-	/* # of characters in font */
-	int nchars;
-	/* First character is numbered... (usually 32 = space) */
-	int offset;
-	/* Character width and height */
-	int w;
-	int h;
-	/* Font data; array of characters, one row after another.
-		Easily included in code, also easily loaded from
-		data files. */
-	char *data;
-} gdFont;
-
-/* Text functions take these. */
-typedef gdFont *gdFontPtr;
-
-/* For backwards compatibility only. Use gdImageSetStyle()
-	for MUCH more flexible line drawing. Also see
-	gdImageSetBrush(). */
-#define gdDashSize 4
-
-/* Special colors. */
-
-#define gdStyled (-2)
-#define gdBrushed (-3)
-#define gdStyledBrushed (-4)
-#define gdTiled (-5)
-
-/* NOT the same as the transparent color index.
-	This is used in line styles only. */
-#define gdTransparent (-6)
-
-/* Functions to manipulate images. */
-
-gdImagePtr gdImageCreate(int sx, int sy);
-gdImagePtr gdImageCreateFromGif(FILE *fd);
-gdImagePtr gdImageCreateFromGd(FILE *in);
-gdImagePtr gdImageCreateFromXbm(FILE *fd);
-void gdImageDestroy(gdImagePtr im);
-void gdImageSetPixel(gdImagePtr im, int x, int y, int color);
-int gdImageGetPixel(gdImagePtr im, int x, int y);
-void gdImageLine(gdImagePtr im, int x1, int y1, int x2, int y2, int color);
-/* For backwards compatibility only. Use gdImageSetStyle()
-	for much more flexible line drawing. */
-void gdImageDashedLine(gdImagePtr im, int x1, int y1, int x2, int y2, int color);
-/* Corners specified (not width and height). Upper left first, lower right
- 	second. */
-void gdImageRectangle(gdImagePtr im, int x1, int y1, int x2, int y2, int color);
-/* Solid bar. Upper left corner first, lower right corner second. */
-void gdImageFilledRectangle(gdImagePtr im, int x1, int y1, int x2, int y2, int color);
-int gdImageBoundsSafe(gdImagePtr im, int x, int y);
-void gdImageChar(gdImagePtr im, gdFontPtr f, int x, int y, int c, int color);
-void gdImageCharUp(gdImagePtr im, gdFontPtr f, int x, int y, char c, int color);
-void gdImageString(gdImagePtr im, gdFontPtr f, int x, int y, char *s, int color);
-void gdImageStringUp(gdImagePtr im, gdFontPtr f, int x, int y, char *s, int color);
-
-/* Point type for use in polygon drawing. */
-
-typedef struct {
-	int x, y;
-} gdPoint, *gdPointPtr;
-
-void gdImagePolygon(gdImagePtr im, gdPointPtr p, int n, int c);
-void gdImageFilledPolygon(gdImagePtr im, gdPointPtr p, int n, int c);
-
-int gdImageColorAllocate(gdImagePtr im, int r, int g, int b);
-int gdImageColorClosest(gdImagePtr im, int r, int g, int b);
-int gdImageColorExact(gdImagePtr im, int r, int g, int b);
-void gdImageColorDeallocate(gdImagePtr im, int color);
-void gdImageColorTransparent(gdImagePtr im, int color);
-void gdImageGif(gdImagePtr im, FILE *out);
-void gdImageGd(gdImagePtr im, FILE *out);
-void gdImageArc(gdImagePtr im, int cx, int cy, int w, int h, int s, int e, int color);
-void gdImageFillToBorder(gdImagePtr im, int x, int y, int border, int color);
-void gdImageFill(gdImagePtr im, int x, int y, int color);
-void gdImageCopy(gdImagePtr dst, gdImagePtr src, int dstX, int dstY, int srcX, int srcY, int w, int h);
-/* Stretches or shrinks to fit, as needed */
-void gdImageCopyResized(gdImagePtr dst, gdImagePtr src, int dstX, int dstY, int srcX, int srcY, int dstW, int dstH, int srcW, int srcH);
-void gdImageSetBrush(gdImagePtr im, gdImagePtr brush);
-void gdImageSetTile(gdImagePtr im, gdImagePtr tile);
-void gdImageSetStyle(gdImagePtr im, int *style, int noOfPixels);
-/* On or off (1 or 0) */
-void gdImageInterlace(gdImagePtr im, int interlaceArg);
-
-/* Macros to access information about images. READ ONLY. Changing
-	these values will NOT have the desired result. */
-#define gdImageSX(im) ((im)->sx)
-#define gdImageSY(im) ((im)->sy)
-#define gdImageColorsTotal(im) ((im)->colorsTotal)
-#define gdImageRed(im, c) ((im)->red[(c)])
-#define gdImageGreen(im, c) ((im)->green[(c)])
-#define gdImageBlue(im, c) ((im)->blue[(c)])
-#define gdImageGetTransparent(im) ((im)->transparent)
-#define gdImageGetInterlaced(im) ((im)->interlace)
-#endif
-
-/* ---------------------------- end gd.h -------------------------------------- */
-
-
-
-/* default file extensions */
-#define IN_EXT "gm"
-#define OUT_EXT "gif"
-
-/* default size of the graph */
-#define SX 550
-#define SY 425
-
-/* PNMAX: maximal points in polygons */
-#define PNMAX 4096
-#ifdef __GNUC__
-#define fpos_t long
-#endif 
-
-/* ---------------------------- global vars -------------------------------------- */
-
-struct options {int reverse, fillx, verbose, sx, sy;}; /* command line options (flags) */
-FILE *infile, *outfile;
-gdImagePtr im,w[12];
-int cidx[13][100];  /* color index table [0][*]: filling, [1-12][*] brush images */
-int r[100]={0, 255, 240,   0,  31,   0, 220, 230, 240, 161, 161,   0, 230,   0, 110, 125},
-    g[100]={0, 255,   0, 220,  61, 199,   0, 220, 130,   0, 230, 161, 176, 209,   0, 125},
-    b[100]={0, 255,   0,   0, 250, 199,  99,  51,  41, 199,  51, 230,  46, 140, 220, 125};
-
-/* ---------------------------- prototypes --------------------------------------- */
-
-void printOptions(char *argv[]); /* print command line options */
-void drawLine(gdPoint pnts[],short *pcnt,int wd,int color); /* draw a polygon */
-void parseArg(int argc,char *argv[],struct options *o,char **fin, char **fout); /* parse command line */
-void openFiles(char **fin, char **fout, short verbose); /* Open files */
-void defBGround(gdImagePtr im,short reverse); /* set background */
-
-/* changed gd-library routines */
-void gdImagePolygonUnclosed(gdImagePtr im, gdPointPtr p, int n, int c);
-void gdImageFilledPolygonx(gdImagePtr im, gdPointPtr p, int n, int c);
-extern int gdCompareInt(const void *a, const void *b);
-
-/* --------------------------------------------------------------------------------- */
-int main (int argc, char *argv[])  {
-   short cmd,opts[4], rotate=0;
-   int col=0, wd=0;
-   int sx=SX,sy=SY,sh,lly,ury;
-   short coldef[100];
-   float blowx,blowy;
-   gdPoint pnts[PNMAX];                    /* points of a polygon */
-   struct options o;                      /* command line options */
-   register int  i,j;
-   short pcnt,fcnt;
-   char *fin=NULL,*fout=NULL,*fout_new=NULL;              /* file names */
-   fpos_t infile_pos;
-   short width[12] = {                      /* width (units: .001 inch) */
-               2 ,7 ,10 ,14 ,17 ,20 ,
-	       24 ,27 ,31 ,34 ,38 ,41 };
-
-   o.reverse=o.verbose=o.fillx=o.sx=o.sy=0;
-   for(i=0;i<13;i++)
-     for(j=0;j<100;j++) cidx[i][j]=-1;
-   for(i=0;i<16;i++) coldef[i]=1;
-   for(i=16;i<100;i++) coldef[i]=0;
-
-  parseArg(argc,argv,&o,&fin,&fout);     /* Parse command line arguments */
-  openFiles(&fin,&fout,o.verbose);                  /* open files */
-
-  /* Translate metafile */
-
-  fcnt = 1;
-  while (1) {
-    fread (&cmd, sizeof(short), 1, infile);
-
-    if (cmd==-11){				/* Draw to */
-      fread (opts, sizeof(short), 2, infile);
-      pnts[++pcnt].x=opts[0]*blowx;
-      pnts[pcnt].y= sy-opts[1]*blowy;
-    }
-    else if (cmd==-10){				/* Move to */
-      if (pcnt) drawLine(pnts,&pcnt,wd,col);
-      fread ((char *) opts, sizeof(short), 2, infile);
-      pnts[pcnt].x=opts[0]*blowx;
-      pnts[pcnt].y= sy-opts[1]*blowy;
-    }
-    else if (cmd==-4) {				/* Set line width */
-      if (pcnt) drawLine(pnts,&pcnt,wd,col);
-      fread ((char *)opts, sizeof(short), 2, infile);
-      i = opts[0];
-      if (i>12) i=12;
-      else if (i<1) i=1;
-      wd=width[i-1]*blowx+1;
-    }
-    else if (cmd==-3) {				/* Set color */
-      if (pcnt) drawLine(pnts,&pcnt,wd,col);
-      fread ((char *)opts, sizeof(short), 1, infile);
-      col = opts[0];
-      if (col<0) col=0;
-      if (col>255) col=255; 
-      if (!(coldef[i])) col=15;
-      if(o.reverse){
-	  if(col==1) col=0;
-	  else if(col==0) col=1;
-      }
-    }
-    else if (cmd==-7){				/* Start fill */
-      fread ((char *)opts, sizeof(short), 1, infile);
-    }
-    else if (cmd==-8){				/* End fill */
-      if (pcnt>1)
-        if(cidx[0][col]<0){
-	  cidx[0][col]=gdImageColorAllocate(im, r[col],g[col],b[col]);
-	}
-        if(o.fillx) gdImageFilledPolygon(im, pnts, ++pcnt, cidx[0][col]);
-        else gdImageFilledPolygonx(im, pnts, ++pcnt, cidx[0][col]);
-        pcnt=0;
-    }
-    else if (cmd==-6){				/* Rectangle fill */
-      if (pcnt) drawLine(pnts,&pcnt,wd,col);
-      fread ((char *)opts, sizeof(short), 4, infile);
-      lly=sy-opts[2]*blowy;
-      ury=sy-opts[3]*blowy;
-        if(cidx[0][col]<0)
-	  cidx[0][col]=gdImageColorAllocate(im, r[col],g[col],b[col]);
-      gdImageFilledRectangle(im, (int) opts[0]*blowx,ury,
-			     (int) opts[1]*blowx,lly, cidx[0][col]);
-    }
-    else if (cmd==-9) {				/* End of plotting */
-      if(o.verbose) printf ("Number of pages = %i\n",fcnt);
-      /*       gdImageInterlace(im, 1); */
-      gdImageGif(im, outfile);
-      fclose(outfile);
-      gdImageDestroy(im);
-      return(0);
-    }
-    else if (cmd==-1) {				/* Start of plotting */
-      fread ((char *)opts, sizeof(short), 2, infile);
-      if(opts[0]<opts[1]) {sh=sx; sx=sy; sy=sh;}
-      if(o.sx) {
-          sx=o.sx;
-         if(o.sy==0) sy=sx *(opts[1]/100)/(opts[0]/100);
-      }
-      if(o.sy) {
-          sy=o.sy;
-          if(o.sx==0) sx=sy*(opts[0]/100)/(opts[1]/100);
-      }
-      blowx=(float)sx/(float)opts[0];  /* picture size in metafile: opts[0] x opts[1] */ 
-      blowy=(float)sy/(float)opts[1];
-      if(o.verbose) printf("Image size: %d x %d pixels\n",sx,sy);
-
-      for (i=0;i<=width[11]*blowx;i++)
-	  w[i] = gdImageCreate(i+1,i+1);
-      im = gdImageCreate(sx,sy);
-      defBGround(im,o.reverse);
-      col=1;
-      pcnt = 0;
-    }
-    else if (cmd==-2) {				/* New Page */
-      if (pcnt) drawLine(pnts,&pcnt,wd,col);
-      /* gdImageInterlace(im, 1); */
-      gdImageGif(im, outfile);
-      fclose(outfile);
-      gdImageDestroy(im);
-      for (i=0;i<=width[11]*blowx;i++)
-	  gdImageDestroy(w[i]);
-      fgetpos(infile,&infile_pos);
-      fread (&cmd , sizeof(short), 1, infile); 
-      fsetpos(infile,&infile_pos);
-      if (cmd != -9) {  /* if next command is not end_of_plotting */
-	  if(fout_new==NULL){
-             fout[strlen(fout)-4]='\0';
-             fout_new = (char *) malloc(sizeof(char)*150);
-	  }
-          strcpy(fout_new,fout);
-	  sprintf(fout_new+strlen(fout_new), "_%d",++fcnt);
-          strcpy((fout_new)+strlen(fout_new),"."OUT_EXT);
-          if(o.verbose) printf ("New GIF-file:%s\n",fout_new);
-          outfile = fopen(fout_new,"wb");
-#ifdef NOTDEF
-	  strcpy(fout+strlen(fout),"1");
-          outfile = fopen(fout,"wb");
-#endif
-          for (i=0;i<=width[11]*blowx;i++)
-	      w[i] = gdImageCreate(i+1,i+1);
-          im = gdImageCreate(sx,sy);
-          defBGround(im,o.reverse);
-          col=1;
-          pcnt = 0;
-      }
-      else return(0);
-    }
-    else if (cmd==-5){				/* Define new color */
-      fread ((char *)opts, sizeof(short), 4, infile);
-      i = opts[0];
-      if (i>15 && i<100) {
-	  r[i]=opts[1];
-	  g[i]=opts[2];
-	  b[i]=opts[3];
-	  coldef[i]=1;
-      }
-    }
-    else if (cmd==-20) {		/* Draw button -- ignore */
-      fread ((char *)opts, sizeof(short), 1, infile);
-    }
-    else {
-       printf ("Fatal error: Invalid command \"%i\" found in metafile\"%s\".\n",cmd,fin);
-       printf ("Is \"%s\" really a GrADS (v1.5 or higher) metafile?\n",fin);
-      return(1);
-    }
-  }
-}
-/* --------------------------------------------------------------------------------- */
-/* --------------------------------------------------------------------------------- */
-
-void defBGround(gdImagePtr im, short reverse){
-    if(reverse) 
-         cidx[0][1]=gdImageColorAllocate(im, 255, 255, 255); /* white background */
-    else
-         cidx[0][0]=gdImageColorAllocate(im, 0, 0, 0);       /* black background */
-    return;
-}
-
-/* --------------------------------------------------------------------------------- */
-
-void drawLine(gdPoint pnts[],short *pcnt,int wd, int col){
-    if(cidx[wd][col]<0)
-      cidx[wd][col]=gdImageColorAllocate(w[wd-1],r[col],g[col],b[col]);
-    gdImageFilledRectangle(w[wd-1],0,0,wd,wd, cidx[wd][col]);
-    gdImageSetBrush(im, w[wd-1]);
-    if(*pcnt>1) gdImagePolygonUnclosed(im, pnts, (*pcnt)+1, gdBrushed);
-    else gdImageLine(im, pnts[0].x, pnts[0].y,pnts[1].x,pnts[1].y,gdBrushed);
-   *pcnt=0;
-   return;
-}
-/* --------------------------------------------------------------------------------- */
-void parseArg(int argc,char *argv[],struct options *o,char **fin, char **fout){
-     register int i,j;
-     if(argc==1) printOptions(argv);
-     for (i=1;i<argc;i++) {
-       if (*(argv[i])=='-') {  /* parse options */
-         j = 0;
-         while (*(argv[i]+(++j))) {
-           if (*(argv[i]+j)=='i') {*fin = argv[++i];break;}
-           else if (*(argv[i]+j)=='h') o->fillx = 1;
-           else if (*(argv[i]+j)=='o') {*fout = argv[++i];break;}
-           else if (*(argv[i]+j)=='r') o->reverse = 1;
-           else if (*(argv[i]+j)=='x') {
-	     sscanf(argv[++i],"%d",&(o->sx));break;
-	   }
-           else if (*(argv[i]+j)=='y') {
-	     sscanf(argv[++i],"%d",&(o->sy));break;
-	   }
-           else if (*(argv[i]+j)=='v') {
-	       o->verbose = 1;
-	       printf("This is gxgif $Revision: 1.5 $, $Date: 2009/04/30 15:25:31 $\n");
-	   }
-           else { 
-	     fprintf(stderr,"Unknown option: %s\n\n",argv[i]);
-	     printOptions(argv);
-	     exit(1);
-	   }
-         }
-       }
-      else  /* No command line "-" */
-        *fin=argv[i];
-    }
-    return;
-}
-/* --------------------------------------------------------------------------------- */
-
-void printOptions(char *argv[]){
-       fprintf(stderr,"%s%s%s","Usage: ",argv[0],
-	   " [-hrv -x <pixels> -y <pixels> -i <in_file>[."  IN_EXT
-           "] -o <out_file>] [<in_file>[."IN_EXT"]].\n");
-       fprintf(stderr,"Options:\n");
-       fprintf(stderr,"     -i   <in_file>[."IN_EXT"].\n");;
-       fprintf(stderr,"     -h   Fill polygons horizontally.\n");
-       fprintf(stderr,"     -o   <out_file> (default: basename(in_file)."OUT_EXT", '-' = stdout).\n");
-       fprintf(stderr,"     -r   Black background.\n");
-       fprintf(stderr,"     -v   Verbose.\n");
-       fprintf(stderr,"     -x <pixels>  # pixels horizontally.\n");
-       fprintf(stderr,"     -y <pixels>  # pixels vertically.\n");
-     exit(8);
-     }
-/* --------------------------------------------------------------------------------- */
-
-void openFiles(char **fin, char **fout,short verbose){ /* Open files */
-  int i;
-
-  if (*fin==NULL) {
-    *fin = (char *) malloc(sizeof(char)*150);
-     fgets(*fin,150,stdin);
-     printf("read infile = %s\n",*fin);
-  }
-  infile = fopen(*fin ,"rb");
-  if (infile == NULL) {
-    *fin=strcat(*fin,"."IN_EXT);
-    infile = fopen(*fin,"rb");
-    if (infile == NULL) {
-      (*fin)[strlen(*fin)-3]='\0';
-      printf ("Input file %s[."IN_EXT"] not found.\n",*fin);
-      exit(1);
-    }
-  }
-  if (*fout==NULL) {
-    *fout = (char *) malloc(sizeof(char)*150);
-    strcpy(*fout,*fin);
-    for (i=strlen(*fout)-1;i>=0;i--) {
-      if((*fout)[i]=='.') {strcpy((*fout)+i+1,OUT_EXT);
-	break;
-      }
-      if(i==0){strcpy((*fout)+strlen(*fout),"."OUT_EXT);}
-    }
-  }
-  if(strcmp(*fout,"-")==0) outfile=stdout;
-  else outfile = fopen(*fout,"wb");
-  if (outfile==NULL) {
-    printf ("Error opening output file %s \n",*fout);
-    exit(1);
-  }
-  if(verbose) {
-    printf("GrADS metafile: %s\n",*fin);
-    if(strcmp(*fout,"-")==0) printf("output to stdout\n");
-    else printf("GIF-file: %s\n",*fout);
-  }
-  return;
-}
-/* --------------------------------------------------------------------------------- */
-void gdImagePolygonUnclosed(gdImagePtr im, gdPointPtr p, int n, int c)
-{
-        int i;
-        int lx, ly;
-        if (!n) {
-                return;
-        }
-        lx = p->x;
-        ly = p->y;
-        /* gdImageLine(im, lx, ly, p[n-1].x, p[n-1].y, c); */
-        for (i=1; (i < n); i++) {
-                p++;
-                gdImageLine(im, lx, ly, p->x, p->y, c);
-                lx = p->x;
-                ly = p->y;
-        }
-}       
-
-/* --------------------------------------------------------------------------------- */
-	
-void gdImageFilledPolygonx(gdImagePtr im, gdPointPtr p, int n, int c)
-{
-	int i;
-	int x;
-	int x1, x2;
-	int ints;
-	if (!n) {
-		return;
-	}
-	if (!im->polyAllocated) {
-		im->polyInts = (int *) malloc(sizeof(int) * n);
-		im->polyAllocated = n;
-	}		
-	if (im->polyAllocated < n) {
-		while (im->polyAllocated < n) {
-			im->polyAllocated *= 2;
-		}	
-		im->polyInts = (int *) realloc(im->polyInts,
-			sizeof(int) * im->polyAllocated);
-	}
-	x1 = p[0].x;
-	x2 = p[0].x;
-	for (i=1; (i < n); i++) {
-		if (p[i].x < x1) {
-			x1 = p[i].x;
-		}
-		if (p[i].x > x2) {
-			x2 = p[i].x;
-		}
-	}
-	for (x=x1; (x <= x2); x++) {
-		int interLast = 0;
-		int dirLast = 0;
-		int interFirst = 1;
-		ints = 0;
-		for (i=0; (i <= n); i++) {
-			int y1, y2;
-			int x1, x2;
-			int dir;
-			int ind1, ind2;
-			int lastInd1 = 0;
-			if ((i == n) || (!i)) {
-				ind1 = n-1;
-				ind2 = 0;
-			} else {
-				ind1 = i-1;
-				ind2 = i;
-			}
-			x1 = p[ind1].x;
-			x2 = p[ind2].x;
-			if (x1 < x2) {
-				x1 = p[ind1].x;
-				x2 = p[ind2].x;
-				y1 = p[ind1].y;
-				y2 = p[ind2].y;
-				dir = -1;
-			} else if (x1 > x2) {
-				x2 = p[ind1].x;
-				x1 = p[ind2].x;
-				y2 = p[ind1].y;
-				y1 = p[ind2].y;
-				dir = 1;
-			} else {
-				/* Horizontal; just draw it */
-				gdImageLine(im, 
-					 x1, p[ind1].y, 
-					x1, p[ind2].y, 
-					c);
-				continue;
-			}
-			if ((x >= x1) && (x <= x2)) {
-				int inter = 
-					(x-x1) * (y2-y1) / (x2-x1) + y1;
-				/* Only count intersections once
-					except at maxima and minima. Also, 
-					if two consecutive intersections are
-					endpoints of the same horizontal line
-					that is not at a maxima or minima,	
-					discard the leftmost of the two. */
-				if (!interFirst) {
-					if ((p[ind1].x == p[lastInd1].x) &&
-						(p[ind1].y != p[lastInd1].y)) {
-						if (dir == dirLast) {
-							if (inter > interLast) {
-								/* Replace the old one */
-								im->polyInts[ints] = inter;
-							} else {
-								/* Discard this one */
-							}	
-							continue;
-						}
-					}
-					if (inter == interLast) {
-						if (dir == dirLast) {
-							continue;
-						}
-					}
-				} 
-				if (i > 0) {
-					im->polyInts[ints++] = inter;
-				}
-				lastInd1 = i;
-				dirLast = dir;
-				interLast = inter;
-				interFirst = 0;
-			}
-		}
-		qsort(im->polyInts, ints, sizeof(int), gdCompareInt);
-		for (i=0; (i < (ints-1)); i+=2) {
-			gdImageLine(im, x, im->polyInts[i],
-				 x, im->polyInts[i+1],  c);
-		}
-	}
-}
-/* ---------------------------- begin gd.c -------------------------------------- */
-static void gdImageBrushApply(gdImagePtr im, int x, int y);
-static void gdImageTileApply(gdImagePtr im, int x, int y);
-
-gdImagePtr gdImageCreate(int sx, int sy)
-{
-	int i;
-	gdImagePtr im;
-	im = (gdImage *) malloc(sizeof(gdImage));
-	im->pixels = (unsigned char **) malloc(sizeof(unsigned char *) * sx);
-	im->polyInts = 0;
-	im->polyAllocated = 0;
-	im->brush = 0;
-	im->tile = 0;
-	im->style = 0;
-	for (i=0; (i<sx); i++) {
-		im->pixels[i] = (unsigned char *) calloc(
-			sy, sizeof(unsigned char));
-	}	
-	im->sx = sx;
-	im->sy = sy;
-	im->colorsTotal = 0;
-	im->transparent = (-1);
-	im->interlace = 0;
-	return im;
-}
-
-void gdImageDestroy(gdImagePtr im)
-{
-	int i;
-	for (i=0; (i<im->sx); i++) {
-		free(im->pixels[i]);
-	}	
-	free(im->pixels);
-	if (im->polyInts) {
-			free(im->polyInts);
-	}
-	if (im->style) {
-		free(im->style);
-	}
-	free(im);
-}
-
-int gdImageColorClosest(gdImagePtr im, int r, int g, int b)
-{
-	int i;
-	long rd, gd, bd;
-	int ct = (-1);
-	long mindist = 0;
-	for (i=0; (i<(im->colorsTotal)); i++) {
-		long dist;
-		if (im->open[i]) {
-			continue;
-		}
-		rd = (im->red[i] - r);	
-		gd = (im->green[i] - g);
-		bd = (im->blue[i] - b);
-		dist = rd * rd + gd * gd + bd * bd;
-		if ((i == 0) || (dist < mindist)) {
-			mindist = dist;	
-			ct = i;
-		}
-	}
-	return ct;
-}
-
-int gdImageColorExact(gdImagePtr im, int r, int g, int b)
-{
-	int i;
-	for (i=0; (i<(im->colorsTotal)); i++) {
-		if (im->open[i]) {
-			continue;
-		}
-		if ((im->red[i] == r) && 
-			(im->green[i] == g) &&
-			(im->blue[i] == b)) {
-			return i;
-		}
-	}
-	return -1;
-}
-
-int gdImageColorAllocate(gdImagePtr im, int r, int g, int b)
-{
-	int i;
-	int ct = (-1);
-	for (i=0; (i<(im->colorsTotal)); i++) {
-		if (im->open[i]) {
-			ct = i;
-			break;
-		}
-	}	
-	if (ct == (-1)) {
-		ct = im->colorsTotal;
-		if (ct == gdMaxColors) {
-			return -1;
-		}
-		im->colorsTotal++;
-	}
-	im->red[ct] = r;
-	im->green[ct] = g;
-	im->blue[ct] = b;
-	im->open[ct] = 0;
-	return ct;
-}
-
-void gdImageColorDeallocate(gdImagePtr im, int color)
-{
-	/* Mark it open. */
-	im->open[color] = 1;
-}
-
-void gdImageColorTransparent(gdImagePtr im, int color)
-{
-	im->transparent = color;
-}
-
-void gdImageSetPixel(gdImagePtr im, int x, int y, int color)
-{
-	int p;
-	switch(color) {
-		case gdStyled:
-		if (!im->style) {
-			/* Refuse to draw if no style is set. */
-			return;
-		} else {
-			p = im->style[im->stylePos++];
-		}
-		if (p != (gdTransparent)) {
-			gdImageSetPixel(im, x, y, p);
-		}
-		im->stylePos = im->stylePos %  im->styleLength;
-		break;
-		case gdStyledBrushed:
-		if (!im->style) {
-			/* Refuse to draw if no style is set. */
-			return;
-		}
-		p = im->style[im->stylePos++];
-		if ((p != gdTransparent) && (p != 0)) {
-			gdImageSetPixel(im, x, y, gdBrushed);
-		}
-		im->stylePos = im->stylePos %  im->styleLength;
-		break;
-		case gdBrushed:
-		gdImageBrushApply(im, x, y);
-		break;
-		case gdTiled:
-		gdImageTileApply(im, x, y);
-		break;
-		default:
-		if (gdImageBoundsSafe(im, x, y)) {
-			 im->pixels[x][y] = color;
-		}
-		break;
-	}
-}
-
-static void gdImageBrushApply(gdImagePtr im, int x, int y)
-{
-	int lx, ly;
-	int hy;
-	int hx;
-	int x1, y1, x2, y2;
-	int srcx, srcy;
-	if (!im->brush) {
-		return;
-	}
-	hy = gdImageSY(im->brush)/2;
-	y1 = y - hy;
-	y2 = y1 + gdImageSY(im->brush);	
-	hx = gdImageSX(im->brush)/2;
-	x1 = x - hx;
-	x2 = x1 + gdImageSX(im->brush);
-	srcy = 0;
-	for (ly = y1; (ly < y2); ly++) {
-		srcx = 0;
-		for (lx = x1; (lx < x2); lx++) {
-			int p;
-			p = gdImageGetPixel(im->brush, srcx, srcy);
-			/* Allow for non-square brushes! */
-			if (p != gdImageGetTransparent(im->brush)) {
-				gdImageSetPixel(im, lx, ly,
-					im->brushColorMap[p]);
-			}
-			srcx++;
-		}
-		srcy++;
-	}	
-}		
-
-static void gdImageTileApply(gdImagePtr im, int x, int y)
-{
-	int srcx, srcy;
-	int p;
-	if (!im->tile) {
-		return;
-	}
-	srcx = x % gdImageSX(im->tile);
-	srcy = y % gdImageSY(im->tile);
-	p = gdImageGetPixel(im->tile, srcx, srcy);
-	/* Allow for transparency */
-	if (p != gdImageGetTransparent(im->tile)) {
-		gdImageSetPixel(im, x, y,
-			im->tileColorMap[p]);
-	}
-}		
-
-int gdImageGetPixel(gdImagePtr im, int x, int y)
-{
-	if (gdImageBoundsSafe(im, x, y)) {
-		return im->pixels[x][y];
-	} else {
-		return 0;
-	}
-}
-
-/* Bresenham as presented in Foley & Van Dam */
-
-void gdImageLine(gdImagePtr im, int x1, int y1, int x2, int y2, int color)
-{
-	int dx, dy, incr1, incr2, d, x, y, xend, yend, xdirflag, ydirflag;
-	dx = abs(x2-x1);
-	dy = abs(y2-y1);
-	if (dy <= dx) {
-		d = 2*dy - dx;
-		incr1 = 2*dy;
-		incr2 = 2 * (dy - dx);
-		if (x1 > x2) {
-			x = x2;
-			y = y2;
-			ydirflag = (-1);
-			xend = x1;
-		} else {
-			x = x1;
-			y = y1;
-			ydirflag = 1;
-			xend = x2;
-		}
-		gdImageSetPixel(im, x, y, color);
-		if (((y2 - y1) * ydirflag) > 0) {
-			while (x < xend) {
-				x++;
-				if (d <0) {
-					d+=incr1;
-				} else {
-					y++;
-					d+=incr2;
-				}
-				gdImageSetPixel(im, x, y, color);
-			}
-		} else {
-			while (x < xend) {
-				x++;
-				if (d <0) {
-					d+=incr1;
-				} else {
-					y--;
-					d+=incr2;
-				}
-				gdImageSetPixel(im, x, y, color);
-			}
-		}		
-	} else {
-		d = 2*dx - dy;
-		incr1 = 2*dx;
-		incr2 = 2 * (dx - dy);
-		if (y1 > y2) {
-			y = y2;
-			x = x2;
-			yend = y1;
-			xdirflag = (-1);
-		} else {
-			y = y1;
-			x = x1;
-			yend = y2;
-			xdirflag = 1;
-		}
-		gdImageSetPixel(im, x, y, color);
-		if (((x2 - x1) * xdirflag) > 0) {
-			while (y < yend) {
-				y++;
-				if (d <0) {
-					d+=incr1;
-				} else {
-					x++;
-					d+=incr2;
-				}
-				gdImageSetPixel(im, x, y, color);
-			}
-		} else {
-			while (y < yend) {
-				y++;
-				if (d <0) {
-					d+=incr1;
-				} else {
-					x--;
-					d+=incr2;
-				}
-				gdImageSetPixel(im, x, y, color);
-			}
-		}
-	}
-}
-
-
-int gdImageBoundsSafe(gdImagePtr im, int x, int y)
-{
-	return (!(((y < 0) || (y >= im->sy)) ||
-		((x < 0) || (x >= im->sx))));
-}
-
-
-/* Code drawn from ppmtogif.c, from the pbmplus package
-**
-** Based on GIFENCOD by David Rowley <mgardi at watdscu.waterloo.edu>. A
-** Lempel-Zim compression based on "compress".
-**
-** Modified by Marcel Wijkstra <wijkstra at fwi.uva.nl>
-**
-** Copyright (C) 1989 by Jef Poskanzer.
-**
-** Permission to use, copy, modify, and distribute this software and its
-** documentation for any purpose and without fee is hereby granted, provided
-** that the above copyright notice appear in all copies and that both that
-** copyright notice and this permission notice appear in supporting
-** documentation.  This software is provided "as is" without express or
-** implied warranty.
-**
-** The Graphics Interchange Format(c) is the Copyright property of
-** CompuServe Incorporated.  GIF(sm) is a Service Mark property of
-** CompuServe Incorporated.
-*/
-
-/*
- * a code_int must be able to hold 2**GIFBITS values of type int, and also -1
- */
-typedef int             code_int;
-
-#ifdef SIGNED_COMPARE_SLOW
-typedef unsigned long int count_int;
-typedef unsigned short int count_short;
-#else /*SIGNED_COMPARE_SLOW*/
-typedef long int          count_int;
-#endif /*SIGNED_COMPARE_SLOW*/
-
-static int colorstobpp(int colors);
-static void BumpPixel (void);
-static int GIFNextPixel (gdImagePtr im);
-static void GIFEncode (FILE *fp, int GWidth, int GHeight, int GInterlace, int Background, int Transparent, int BitsPerPixel, int *Red, int *Green, int *Blue, gdImagePtr im);
-static void Putword (int w, FILE *fp);
-static void compress (int init_bits, FILE *outfile, gdImagePtr im);
-static void output (code_int code);
-static void cl_block (void);
-static void cl_hash (register count_int hsize);
-static void char_init (void);
-static void char_out (int c);
-static void flush_char (void);
-/* Allows for reuse */
-static void init_statics(void);
-
-void gdImageGif(gdImagePtr im, FILE *out)
-{
-	int interlace, transparent, BitsPerPixel;
-	interlace = im->interlace;
-	transparent = im->transparent;
-
-	BitsPerPixel = colorstobpp(im->colorsTotal);
-	/* Clear any old values in statics strewn through the GIF code */
-	init_statics();
-	/* All set, let's do it. */
-	GIFEncode(
-		out, im->sx, im->sy, interlace, 0, transparent, BitsPerPixel,
-		im->red, im->green, im->blue, im);
-}
-
-static int
-colorstobpp(int colors)
-{
-    int bpp = 0;
-
-    if ( colors <= 2 )
-        bpp = 1;
-    else if ( colors <= 4 )
-        bpp = 2;
-    else if ( colors <= 8 )
-        bpp = 3;
-    else if ( colors <= 16 )
-        bpp = 4;
-    else if ( colors <= 32 )
-        bpp = 5;
-    else if ( colors <= 64 )
-        bpp = 6;
-    else if ( colors <= 128 )
-        bpp = 7;
-    else if ( colors <= 256 )
-        bpp = 8;
-    return bpp;
-    }
-
-/*****************************************************************************
- *
- * GIFENCODE.C    - GIF Image compression interface
- *
- * GIFEncode( FName, GHeight, GWidth, GInterlace, Background, Transparent,
- *            BitsPerPixel, Red, Green, Blue, gdImagePtr )
- *
- *****************************************************************************/
-
-#define TRUE 1
-#define FALSE 0
-
-static int Width, Height;
-static int curx, cury;
-static long CountDown;
-static int Pass = 0;
-static int Interlace;
-
-/*
- * Bump the 'curx' and 'cury' to point to the next pixel
- */
-static void
-BumpPixel(void)
-{
-        /*
-         * Bump the current X position
-         */
-        ++curx;
-
-        /*
-         * If we are at the end of a scan line, set curx back to the beginning
-         * If we are interlaced, bump the cury to the appropriate spot,
-         * otherwise, just increment it.
-         */
-        if( curx == Width ) {
-                curx = 0;
-
-                if( !Interlace )
-                        ++cury;
-                else {
-                     switch( Pass ) {
-
-                       case 0:
-                          cury += 8;
-                          if( cury >= Height ) {
-                                ++Pass;
-                                cury = 4;
-                          }
-                          break;
-
-                       case 1:
-                          cury += 8;
-                          if( cury >= Height ) {
-                                ++Pass;
-                                cury = 2;
-                          }
-                          break;
-
-                       case 2:
-                          cury += 4;
-                          if( cury >= Height ) {
-                             ++Pass;
-                             cury = 1;
-                          }
-                          break;
-
-                       case 3:
-                          cury += 2;
-                          break;
-                        }
-                }
-        }
-}
-
-/*
- * Return the next pixel from the image
- */
-static int
-GIFNextPixel(gdImagePtr im)
-{
-        int r;
-
-        if( CountDown == 0 )
-                return EOF;
-
-        --CountDown;
-
-        r = gdImageGetPixel(im, curx, cury);
-
-        BumpPixel();
-
-        return r;
-}
-
-/* public */
-
-static void
-GIFEncode(FILE *fp, int GWidth, int GHeight, int GInterlace, int Background, int Transparent, int BitsPerPixel, int *Red, int *Green, int *Blue, gdImagePtr im)
-{
-        int B;
-        int RWidth, RHeight;
-        int LeftOfs, TopOfs;
-        int Resolution;
-        int ColorMapSize;
-        int InitCodeSize;
-        int i;
-
-        Interlace = GInterlace;
-
-        ColorMapSize = 1 << BitsPerPixel;
-
-        RWidth = Width = GWidth;
-        RHeight = Height = GHeight;
-        LeftOfs = TopOfs = 0;
-
-        Resolution = BitsPerPixel;
-
-        /*
-         * Calculate number of bits we are expecting
-         */
-        CountDown = (long)Width * (long)Height;
-
-        /*
-         * Indicate which pass we are on (if interlace)
-         */
-        Pass = 0;
-
-        /*
-         * The initial code size
-         */
-        if( BitsPerPixel <= 1 )
-                InitCodeSize = 2;
-        else
-                InitCodeSize = BitsPerPixel;
-
-        /*
-         * Set up the current x and y position
-         */
-        curx = cury = 0;
-
-        /*
-         * Write the Magic header
-         */
-        fwrite( Transparent < 0 ? "GIF87a" : "GIF89a", 1, 6, fp );
-
-        /*
-         * Write out the screen width and height
-         */
-        Putword( RWidth, fp );
-        Putword( RHeight, fp );
-
-        /*
-         * Indicate that there is a global colour map
-         */
-        B = 0x80;       /* Yes, there is a color map */
-
-        /*
-         * OR in the resolution
-         */
-        B |= (Resolution - 1) << 5;
-
-        /*
-         * OR in the Bits per Pixel
-         */
-        B |= (BitsPerPixel - 1);
-
-        /*
-         * Write it out
-         */
-        fputc( B, fp );
-
-        /*
-         * Write out the Background colour
-         */
-        fputc( Background, fp );
-
-        /*
-         * Byte of 0's (future expansion)
-         */
-        fputc( 0, fp );
-
-        /*
-         * Write out the Global Colour Map
-         */
-        for( i=0; i<ColorMapSize; ++i ) {
-                fputc( Red[i], fp );
-                fputc( Green[i], fp );
-                fputc( Blue[i], fp );
-        }
-
-	/*
-	 * Write out extension for transparent colour index, if necessary.
-	 */
-	if ( Transparent >= 0 ) {
-	    fputc( '!', fp );
-	    fputc( 0xf9, fp );
-	    fputc( 4, fp );
-	    fputc( 1, fp );
-	    fputc( 0, fp );
-	    fputc( 0, fp );
-	    fputc( (unsigned char) Transparent, fp );
-	    fputc( 0, fp );
-	}
-
-        /*
-         * Write an Image separator
-         */
-        fputc( ',', fp );
-
-        /*
-         * Write the Image header
-         */
-
-        Putword( LeftOfs, fp );
-        Putword( TopOfs, fp );
-        Putword( Width, fp );
-        Putword( Height, fp );
-
-        /*
-         * Write out whether or not the image is interlaced
-         */
-        if( Interlace )
-                fputc( 0x40, fp );
-        else
-                fputc( 0x00, fp );
-
-        /*
-         * Write out the initial code size
-         */
-        fputc( InitCodeSize, fp );
-
-        /*
-         * Go and actually compress the data
-         */
-        compress( InitCodeSize+1, fp, im );
-
-        /*
-         * Write out a Zero-length packet (to end the series)
-         */
-        fputc( 0, fp );
-
-        /*
-         * Write the GIF file terminator
-         */
-        fputc( ';', fp );
-}
-
-/*
- * Write out a word to the GIF file
- */
-static void
-Putword(int w, FILE *fp)
-{
-        fputc( w & 0xff, fp );
-        fputc( (w / 256) & 0xff, fp );
-}
-
-
-/***************************************************************************
- *
- *  GIFCOMPR.C       - GIF Image compression routines
- *
- *  Lempel-Ziv compression based on 'compress'.  GIF modifications by
- *  David Rowley (mgardi at watdcsu.waterloo.edu)
- *
- ***************************************************************************/
-
-/*
- * General DEFINEs
- */
-
-#define GIFBITS    12
-
-#define HSIZE  5003            /* 80% occupancy */
-
-#ifdef NO_UCHAR
- typedef char   char_type;
-#else /*NO_UCHAR*/
- typedef        unsigned char   char_type;
-#endif /*NO_UCHAR*/
-
-/*
- *
- * GIF Image compression - modified 'compress'
- *
- * Based on: compress.c - File compression ala IEEE Computer, June 1984.
- *
- * By Authors:  Spencer W. Thomas       (decvax!harpo!utah-cs!utah-gr!thomas)
- *              Jim McKie               (decvax!mcvax!jim)
- *              Steve Davies            (decvax!vax135!petsd!peora!srd)
- *              Ken Turkowski           (decvax!decwrl!turtlevax!ken)
- *              James A. Woods          (decvax!ihnp4!ames!jaw)
- *              Joe Orost               (decvax!vax135!petsd!joe)
- *
- */
-#include <ctype.h>
-
-#define ARGVAL() (*++(*argv) || (--argc && *++argv))
-
-static int n_bits;                        /* number of bits/code */
-static int maxbits = GIFBITS;                /* user settable max # bits/code */
-static code_int maxcode;                  /* maximum code, given n_bits */
-static code_int maxmaxcode = (code_int)1 << GIFBITS; /* should NEVER generate this code */
-#ifdef COMPATIBLE               /* But wrong! */
-# define MAXCODE(n_bits)        ((code_int) 1 << (n_bits) - 1)
-#else /*COMPATIBLE*/
-# define MAXCODE(n_bits)        (((code_int) 1 << (n_bits)) - 1)
-#endif /*COMPATIBLE*/
-
-static count_int htab [HSIZE];
-static unsigned short codetab [HSIZE];
-#define HashTabOf(i)       htab[i]
-#define CodeTabOf(i)    codetab[i]
-
-static code_int hsize = HSIZE;                 /* for dynamic table sizing */
-
-/*
- * To save much memory, we overlay the table used by compress() with those
- * used by decompress().  The tab_prefix table is the same size and type
- * as the codetab.  The tab_suffix table needs 2**GIFBITS characters.  We
- * get this from the beginning of htab.  The output stack uses the rest
- * of htab, and contains characters.  There is plenty of room for any
- * possible stack (stack used to be 8000 characters).
- */
-
-#define tab_prefixof(i) CodeTabOf(i)
-#define tab_suffixof(i)        ((char_type*)(htab))[i]
-#define de_stack               ((char_type*)&tab_suffixof((code_int)1<<GIFBITS))
-
-static code_int free_ent = 0;                  /* first unused entry */
-
-/*
- * block compression parameters -- after all codes are used up,
- * and compression rate changes, start over.
- */
-static int clear_flg = 0;
-
-static int offset;
-static long int in_count = 1;            /* length of input */
-static long int out_count = 0;           /* # of codes output (for debugging) */
-
-/*
- * compress stdin to stdout
- *
- * Algorithm:  use open addressing double hashing (no chaining) on the
- * prefix code / next character combination.  We do a variant of Knuth's
- * algorithm D (vol. 3, sec. 6.4) along with G. Knott's relatively-prime
- * secondary probe.  Here, the modular division first probe is gives way
- * to a faster exclusive-or manipulation.  Also do block compression with
- * an adaptive reset, whereby the code table is cleared when the compression
- * ratio decreases, but after the table fills.  The variable-length output
- * codes are re-sized at this point, and a special CLEAR code is generated
- * for the decompressor.  Late addition:  construct the table according to
- * file size for noticeable speed improvement on small files.  Please direct
- * questions about this implementation to ames!jaw.
- */
-
-static int g_init_bits;
-static FILE* g_outfile;
-
-static int ClearCode;
-static int EOFCode;
-
-static void
-compress(int init_bits, FILE *outfile, gdImagePtr im)
-{
-    register long fcode;
-    register code_int i /* = 0 */;
-    register int c;
-    register code_int ent;
-    register code_int disp;
-    register code_int hsize_reg;
-    register int hshift;
-
-    /*
-     * Set up the globals:  g_init_bits - initial number of bits
-     *                      g_outfile   - pointer to output file
-     */
-    g_init_bits = init_bits;
-    g_outfile = outfile;
-
-    /*
-     * Set up the necessary values
-     */
-    offset = 0;
-    out_count = 0;
-    clear_flg = 0;
-    in_count = 1;
-    maxcode = MAXCODE(n_bits = g_init_bits);
-
-    ClearCode = (1 << (init_bits - 1));
-    EOFCode = ClearCode + 1;
-    free_ent = ClearCode + 2;
-
-    char_init();
-
-    ent = GIFNextPixel( im );
-
-    hshift = 0;
-    for ( fcode = (long) hsize;  fcode < 65536L; fcode *= 2L )
-        ++hshift;
-    hshift = 8 - hshift;                /* set hash code range bound */
-
-    hsize_reg = hsize;
-    cl_hash( (count_int) hsize_reg);            /* clear hash table */
-
-    output( (code_int)ClearCode );
-
-#ifdef SIGNED_COMPARE_SLOW
-    while ( (c = GIFNextPixel( im )) != (unsigned) EOF ) {
-#else /*SIGNED_COMPARE_SLOW*/
-    while ( (c = GIFNextPixel( im )) != EOF ) {  /* } */
-#endif /*SIGNED_COMPARE_SLOW*/
-
-        ++in_count;
-
-        fcode = (long) (((long) c << maxbits) + ent);
-        i = (((code_int)c << hshift) ^ ent);    /* xor hashing */
-
-        if ( HashTabOf (i) == fcode ) {
-            ent = CodeTabOf (i);
-            continue;
-        } else if ( (long)HashTabOf (i) < 0 )      /* empty slot */
-            goto nomatch;
-        disp = hsize_reg - i;           /* secondary hash (after G. Knott) */
-        if ( i == 0 )
-            disp = 1;
-probe:
-        if ( (i -= disp) < 0 )
-            i += hsize_reg;
-
-        if ( HashTabOf (i) == fcode ) {
-            ent = CodeTabOf (i);
-            continue;
-        }
-        if ( (long)HashTabOf (i) > 0 )
-            goto probe;
-nomatch:
-        output ( (code_int) ent );
-        ++out_count;
-        ent = c;
-#ifdef SIGNED_COMPARE_SLOW
-        if ( (unsigned) free_ent < (unsigned) maxmaxcode) {
-#else /*SIGNED_COMPARE_SLOW*/
-        if ( free_ent < maxmaxcode ) {  /* } */
-#endif /*SIGNED_COMPARE_SLOW*/
-            CodeTabOf (i) = free_ent++; /* code -> hashtable */
-            HashTabOf (i) = fcode;
-        } else
-                cl_block();
-    }
-    /*
-     * Put out the final code.
-     */
-    output( (code_int)ent );
-    ++out_count;
-    output( (code_int) EOFCode );
-}
-
-/*****************************************************************
- * TAG( output )
- *
- * Output the given code.
- * Inputs:
- *      code:   A n_bits-bit integer.  If == -1, then EOF.  This assumes
- *              that n_bits =< (long)wordsize - 1.
- * Outputs:
- *      Outputs code to the file.
- * Assumptions:
- *      Chars are 8 bits long.
- * Algorithm:
- *      Maintain a GIFBITS character long buffer (so that 8 codes will
- * fit in it exactly).  Use the VAX insv instruction to insert each
- * code in turn.  When the buffer fills up empty it and start over.
- */
-
-static unsigned long cur_accum = 0;
-static int cur_bits = 0;
-
-static unsigned long masks[] = { 0x0000, 0x0001, 0x0003, 0x0007, 0x000F,
-                                  0x001F, 0x003F, 0x007F, 0x00FF,
-                                  0x01FF, 0x03FF, 0x07FF, 0x0FFF,
-                                  0x1FFF, 0x3FFF, 0x7FFF, 0xFFFF };
-
-static void
-output(code_int code)
-{
-    cur_accum &= masks[ cur_bits ];
-
-    if( cur_bits > 0 )
-        cur_accum |= ((long)code << cur_bits);
-    else
-        cur_accum = code;
-
-    cur_bits += n_bits;
-
-    while( cur_bits >= 8 ) {
-        char_out( (unsigned int)(cur_accum & 0xff) );
-        cur_accum >>= 8;
-        cur_bits -= 8;
-    }
-
-    /*
-     * If the next entry is going to be too big for the code size,
-     * then increase it, if possible.
-     */
-   if ( free_ent > maxcode || clear_flg ) {
-
-            if( clear_flg ) {
-
-                maxcode = MAXCODE (n_bits = g_init_bits);
-                clear_flg = 0;
-
-            } else {
-
-                ++n_bits;
-                if ( n_bits == maxbits )
-                    maxcode = maxmaxcode;
-                else
-                    maxcode = MAXCODE(n_bits);
-            }
-        }
-
-    if( code == EOFCode ) {
-        /*
-         * At EOF, write the rest of the buffer.
-         */
-        while( cur_bits > 0 ) {
-                char_out( (unsigned int)(cur_accum & 0xff) );
-                cur_accum >>= 8;
-                cur_bits -= 8;
-        }
-
-        flush_char();
-
-        fflush( g_outfile );
-
-        if( ferror( g_outfile ) )
-		return;
-    }
-}
-
-/*
- * Clear out the hash table
- */
-static void
-cl_block (void)             /* table clear for block compress */
-{
-
-        cl_hash ( (count_int) hsize );
-        free_ent = ClearCode + 2;
-        clear_flg = 1;
-
-        output( (code_int)ClearCode );
-}
-
-static void
-cl_hash(register count_int hsize)          /* reset code table */
-                         
-{
-
-        register count_int *htab_p = htab+hsize;
-
-        register long i;
-        register long m1 = -1;
-
-        i = hsize - 16;
-        do {                            /* might use Sys V memset(3) here */
-                *(htab_p-16) = m1;
-                *(htab_p-15) = m1;
-                *(htab_p-14) = m1;
-                *(htab_p-13) = m1;
-                *(htab_p-12) = m1;
-                *(htab_p-11) = m1;
-                *(htab_p-10) = m1;
-                *(htab_p-9) = m1;
-                *(htab_p-8) = m1;
-                *(htab_p-7) = m1;
-                *(htab_p-6) = m1;
-                *(htab_p-5) = m1;
-                *(htab_p-4) = m1;
-                *(htab_p-3) = m1;
-                *(htab_p-2) = m1;
-                *(htab_p-1) = m1;
-                htab_p -= 16;
-        } while ((i -= 16) >= 0);
-
-        for ( i += 16; i > 0; --i )
-                *--htab_p = m1;
-}
-
-/******************************************************************************
- *
- * GIF Specific routines
- *
- ******************************************************************************/
-
-/*
- * Number of characters so far in this 'packet'
- */
-static int a_count;
-
-/*
- * Set up the 'byte output' routine
- */
-static void
-char_init(void)
-{
-        a_count = 0;
-}
-
-/*
- * Define the storage for the packet accumulator
- */
-static char accum[ 256 ];
-
-/*
- * Add a character to the end of the current packet, and if it is 254
- * characters, flush the packet to disk.
- */
-static void
-char_out(int c)
-{
-        accum[ a_count++ ] = c;
-        if( a_count >= 254 )
-                flush_char();
-}
-
-/*
- * Flush the packet to disk, and reset the accumulator
- */
-static void
-flush_char(void)
-{
-        if( a_count > 0 ) {
-                fputc( a_count, g_outfile );
-                fwrite( accum, 1, a_count, g_outfile );
-                a_count = 0;
-        }
-}
-
-static void init_statics(void) {
-	/* Some of these are properly initialized later. What I'm doing
-		here is making sure code that depends on C's initialization
-		of statics doesn't break when the code gets called more
-		than once. */
-	Width = 0;
-	Height = 0;
-	curx = 0;
-	cury = 0;
-	CountDown = 0;
-	Pass = 0;
-	Interlace = 0;
-	a_count = 0;
-	cur_accum = 0;
-	cur_bits = 0;
-	g_init_bits = 0;
-	g_outfile = 0;
-	ClearCode = 0;
-	EOFCode = 0;
-	free_ent = 0;
-	clear_flg = 0;
-	offset = 0;
-	in_count = 1;
-	out_count = 0;	
-	hsize = HSIZE;
-	n_bits = 0;
-	maxbits = GIFBITS;
-	maxcode = 0;
-	maxmaxcode = (code_int)1 << GIFBITS;
-}
-
-
-/* +-------------------------------------------------------------------+ */
-/* | Copyright 1990, 1991, 1993, David Koblas.  (koblas at netcom.com)    | */
-/* |   Permission to use, copy, modify, and distribute this software   | */
-/* |   and its documentation for any purpose and without fee is hereby | */
-/* |   granted, provided that the above copyright notice appear in all | */
-/* |   copies and that both that copyright notice and this permission  | */
-/* |   notice appear in supporting documentation.  This software is    | */
-/* |   provided "as is" without express or implied warranty.           | */
-/* +-------------------------------------------------------------------+ */
-
-
-#define        MAXCOLORMAPSIZE         256
-
-#define        TRUE    1
-#define        FALSE   0
-
-#define CM_RED         0
-#define CM_GREEN       1
-#define CM_BLUE                2
-
-#define        MAX_LWZ_BITS            12
-
-#define INTERLACE              0x40
-#define LOCALCOLORMAP  0x80
-#define BitSet(byte, bit)      (((byte) & (bit)) == (bit))
-
-#define        ReadOK(file,buffer,len) (fread(buffer, len, 1, file) != 0)
-
-#define LM_to_uint(a,b)                        (((b)<<8)|(a))
-
-/* We may eventually want to use this information, but def it out for now */
-#if 0
-static struct {
-       unsigned int    Width;
-       unsigned int    Height;
-       unsigned char   ColorMap[3][MAXCOLORMAPSIZE];
-       unsigned int    BitPixel;
-       unsigned int    ColorResolution;
-       unsigned int    Background;
-       unsigned int    AspectRatio;
-} GifScreen;
-#endif
-
-static struct {
-       int     transparent;
-       int     delayTime;
-       int     inputFlag;
-       int     disposal;
-} Gif89 = { -1, -1, -1, 0 };
-
-static int ReadColorMap (FILE *fd, int number, unsigned char (*buffer)[256]);
-static int DoExtension (FILE *fd, int label, int *Transparent);
-static int GetDataBlock (FILE *fd, unsigned char *buf);
-static int GetCode (FILE *fd, int code_size, int flag);
-static int LWZReadByte (FILE *fd, int flag, int input_code_size);
-static void ReadImage (gdImagePtr im, FILE *fd, int len, int height, unsigned char (*cmap)[256], int interlace, int ignore);
-
-int ZeroDataBlock;
-
-gdImagePtr
-gdImageCreateFromGif(FILE *fd)
-{
-       int imageNumber;
-       int BitPixel;
-       int ColorResolution;
-       int Background;
-       int AspectRatio;
-       int Transparent = (-1);
-       unsigned char   buf[16];
-       unsigned char   c;
-       unsigned char   ColorMap[3][MAXCOLORMAPSIZE];
-       unsigned char   localColorMap[3][MAXCOLORMAPSIZE];
-       int             imw, imh;
-       int             useGlobalColormap;
-       int             bitPixel;
-       int             imageCount = 0;
-       char            version[4];
-       gdImagePtr im = 0;
-       ZeroDataBlock = FALSE;
-
-       imageNumber = 1;
-       if (! ReadOK(fd,buf,6)) {
-		return 0;
-	}
-       if (strncmp((char *)buf,"GIF",3) != 0) {
-		return 0;
-	}
-       strncpy(version, (char *)buf + 3, 3);
-       version[3] = '\0';
-
-       if ((strcmp(version, "87a") != 0) && (strcmp(version, "89a") != 0)) {
-		return 0;
-	}
-       if (! ReadOK(fd,buf,7)) {
-		return 0;
-	}
-       BitPixel        = 2<<(buf[4]&0x07);
-       ColorResolution = (int) (((buf[4]&0x70)>>3)+1);
-       Background      = buf[5];
-       AspectRatio     = buf[6];
-
-       if (BitSet(buf[4], LOCALCOLORMAP)) {    /* Global Colormap */
-               if (ReadColorMap(fd, BitPixel, ColorMap)) {
-			return 0;
-		}
-       }
-       for (;;) {
-               if (! ReadOK(fd,&c,1)) {
-                       return 0;
-               }
-               if (c == ';') {         /* GIF terminator */
-                       int i;
-                       if (imageCount < imageNumber) {
-                               return 0;
-                       }
-                       /* Terminator before any image was declared! */
-                       if (!im) {
-                              return 0;
-                       }
-		       /* Check for open colors at the end, so
-                          we can reduce colorsTotal and ultimately
-                          BitsPerPixel */
-                       for (i=((im->colorsTotal-1)); (i>=0); i--) {
-                               if (im->open[i]) {
-                                       im->colorsTotal--;
-                               } else {
-                                       break;
-                               }
-                       } 
-                       return im;
-               }
-
-               if (c == '!') {         /* Extension */
-                       if (! ReadOK(fd,&c,1)) {
-                               return 0;
-                       }
-                       DoExtension(fd, c, &Transparent);
-                       continue;
-               }
-
-               if (c != ',') {         /* Not a valid start character */
-                       continue;
-               }
-
-               ++imageCount;
-
-               if (! ReadOK(fd,buf,9)) {
-	               return 0;
-               }
-
-               useGlobalColormap = ! BitSet(buf[8], LOCALCOLORMAP);
-
-               bitPixel = 1<<((buf[8]&0x07)+1);
-
-               imw = LM_to_uint(buf[4],buf[5]);
-               imh = LM_to_uint(buf[6],buf[7]);
-	       if (!(im = gdImageCreate(imw, imh))) {
-			 return 0;
-	       }
-               im->interlace = BitSet(buf[8], INTERLACE);
-               if (! useGlobalColormap) {
-                       if (ReadColorMap(fd, bitPixel, localColorMap)) { 
-                                 return 0;
-                       }
-                       ReadImage(im, fd, imw, imh, localColorMap, 
-                                 BitSet(buf[8], INTERLACE), 
-                                 imageCount != imageNumber);
-               } else {
-                       ReadImage(im, fd, imw, imh,
-                                 ColorMap, 
-                                 BitSet(buf[8], INTERLACE), 
-                                 imageCount != imageNumber);
-               }
-               if (Transparent != (-1)) {
-                       gdImageColorTransparent(im, Transparent);
-               }	   
-       }
-}
-
-static int
-ReadColorMap(FILE *fd, int number, unsigned char (*buffer)[256])
-{
-       int             i;
-       unsigned char   rgb[3];
-
-
-       for (i = 0; i < number; ++i) {
-               if (! ReadOK(fd, rgb, sizeof(rgb))) {
-                       return TRUE;
-               }
-               buffer[CM_RED][i] = rgb[0] ;
-               buffer[CM_GREEN][i] = rgb[1] ;
-               buffer[CM_BLUE][i] = rgb[2] ;
-       }
-
-
-       return FALSE;
-}
-
-static int
-DoExtension(FILE *fd, int label, int *Transparent)
-{
-       static unsigned char     buf[256];
-
-       switch (label) {
-       case 0xf9:              /* Graphic Control Extension */
-               (void) GetDataBlock(fd, (unsigned char*) buf);
-               Gif89.disposal    = (buf[0] >> 2) & 0x7;
-               Gif89.inputFlag   = (buf[0] >> 1) & 0x1;
-               Gif89.delayTime   = LM_to_uint(buf[1],buf[2]);
-               if ((buf[0] & 0x1) != 0)
-                       *Transparent = buf[3];
-
-               while (GetDataBlock(fd, (unsigned char*) buf) != 0)
-                       ;
-               return FALSE;
-       default:
-               break;
-       }
-       while (GetDataBlock(fd, (unsigned char*) buf) != 0)
-               ;
-
-       return FALSE;
-}
-
-static int
-GetDataBlock(FILE *fd, unsigned char *buf)
-{
-       unsigned char   count;
-
-       if (! ReadOK(fd,&count,1)) {
-               return -1;
-       }
-
-       ZeroDataBlock = count == 0;
-
-       if ((count != 0) && (! ReadOK(fd, buf, count))) {
-               return -1;
-       }
-
-       return count;
-}
-
-static int
-GetCode(FILE *fd, int code_size, int flag)
-{
-       static unsigned char    buf[280];
-       static int              curbit, lastbit, done, last_byte;
-       int                     i, j, ret;
-       unsigned char           count;
-
-       if (flag) {
-               curbit = 0;
-               lastbit = 0;
-               done = FALSE;
-               return 0;
-       }
-
-       if ( (curbit+code_size) >= lastbit) {
-               if (done) {
-                       if (curbit >= lastbit) {
-                                /* Oh well */
-                       }                        
-                       return -1;
-               }
-               buf[0] = buf[last_byte-2];
-               buf[1] = buf[last_byte-1];
-
-               if ((count = GetDataBlock(fd, &buf[2])) == 0)
-                       done = TRUE;
-
-               last_byte = 2 + count;
-               curbit = (curbit - lastbit) + 16;
-               lastbit = (2+count)*8 ;
-       }
-
-       ret = 0;
-       for (i = curbit, j = 0; j < code_size; ++i, ++j)
-               ret |= ((buf[ i / 8 ] & (1 << (i % 8))) != 0) << j;
-
-       curbit += code_size;
-
-       return ret;
-}
-
-static int
-LWZReadByte(FILE *fd, int flag, int input_code_size)
-{
-       static int      fresh = FALSE;
-       int             code, incode;
-       static int      code_size, set_code_size;
-       static int      max_code, max_code_size;
-       static int      firstcode, oldcode;
-       static int      clear_code, end_code;
-       static int      table[2][(1<< MAX_LWZ_BITS)];
-       static int      stack[(1<<(MAX_LWZ_BITS))*2], *sp;
-       register int    i;
-
-       if (flag) {
-               set_code_size = input_code_size;
-               code_size = set_code_size+1;
-               clear_code = 1 << set_code_size ;
-               end_code = clear_code + 1;
-               max_code_size = 2*clear_code;
-               max_code = clear_code+2;
-
-               GetCode(fd, 0, TRUE);
-               
-               fresh = TRUE;
-
-               for (i = 0; i < clear_code; ++i) {
-                       table[0][i] = 0;
-                       table[1][i] = i;
-               }
-               for (; i < (1<<MAX_LWZ_BITS); ++i)
-                       table[0][i] = table[1][0] = 0;
-
-               sp = stack;
-
-               return 0;
-       } else if (fresh) {
-               fresh = FALSE;
-               do {
-                       firstcode = oldcode =
-                               GetCode(fd, code_size, FALSE);
-               } while (firstcode == clear_code);
-               return firstcode;
-       }
-
-       if (sp > stack)
-               return *--sp;
-
-       while ((code = GetCode(fd, code_size, FALSE)) >= 0) {
-               if (code == clear_code) {
-                       for (i = 0; i < clear_code; ++i) {
-                               table[0][i] = 0;
-                               table[1][i] = i;
-                       }
-                       for (; i < (1<<MAX_LWZ_BITS); ++i)
-                               table[0][i] = table[1][i] = 0;
-                       code_size = set_code_size+1;
-                       max_code_size = 2*clear_code;
-                       max_code = clear_code+2;
-                       sp = stack;
-                       firstcode = oldcode =
-                                       GetCode(fd, code_size, FALSE);
-                       return firstcode;
-               } else if (code == end_code) {
-                       int             count;
-                       unsigned char   buf[260];
-
-                       if (ZeroDataBlock)
-                               return -2;
-
-                       while ((count = GetDataBlock(fd, buf)) > 0)
-                               ;
-
-                       if (count != 0)
-                       return -2;
-               }
-
-               incode = code;
-
-               if (code >= max_code) {
-                       *sp++ = firstcode;
-                       code = oldcode;
-               }
-
-               while (code >= clear_code) {
-                       *sp++ = table[1][code];
-                       if (code == table[0][code]) {
-                               /* Oh well */
-                       }
-                       code = table[0][code];
-               }
-
-               *sp++ = firstcode = table[1][code];
-
-               if ((code = max_code) <(1<<MAX_LWZ_BITS)) {
-                       table[0][code] = oldcode;
-                       table[1][code] = firstcode;
-                       ++max_code;
-                       if ((max_code >= max_code_size) &&
-                               (max_code_size < (1<<MAX_LWZ_BITS))) {
-                               max_code_size *= 2;
-                               ++code_size;
-                       }
-               }
-
-               oldcode = incode;
-
-               if (sp > stack)
-                       return *--sp;
-       }
-       return code;
-}
-
-static void
-ReadImage(gdImagePtr im, FILE *fd, int len, int height, unsigned char (*cmap)[256], int interlace, int ignore)
-{
-       unsigned char   c;      
-       int             v;
-       int             xpos = 0, ypos = 0, pass = 0;
-       int i;
-       /* Stash the color map into the image */
-       for (i=0; (i<gdMaxColors); i++) {
-               im->red[i] = cmap[CM_RED][i];	
-               im->green[i] = cmap[CM_GREEN][i];	
-               im->blue[i] = cmap[CM_BLUE][i];	
-               im->open[i] = 1;
-       }
-       /* Many (perhaps most) of these colors will remain marked open. */
-       im->colorsTotal = gdMaxColors;
-       /*
-       **  Initialize the Compression routines
-       */
-       if (! ReadOK(fd,&c,1)) {
-               return; 
-       }
-       if (LWZReadByte(fd, TRUE, c) < 0) {
-               return;
-       }
-
-       /*
-       **  If this is an "uninteresting picture" ignore it.
-       */
-       if (ignore) {
-               while (LWZReadByte(fd, FALSE, c) >= 0)
-                       ;
-               return;
-       }
-
-       while ((v = LWZReadByte(fd,FALSE,c)) >= 0 ) {
-               /* This how we recognize which colors are actually used. */
-               if (im->open[v]) {
-                       im->open[v] = 0;
-               }
-               gdImageSetPixel(im, xpos, ypos, v);
-               ++xpos;
-               if (xpos == len) {
-                       xpos = 0;
-                       if (interlace) {
-                               switch (pass) {
-                               case 0:
-                               case 1:
-                                       ypos += 8; break;
-                               case 2:
-                                       ypos += 4; break;
-                               case 3:
-                                       ypos += 2; break;
-                               }
-
-                               if (ypos >= height) {
-                                       ++pass;
-                                       switch (pass) {
-                                       case 1:
-                                               ypos = 4; break;
-                                       case 2:
-                                               ypos = 2; break;
-                                       case 3:
-                                               ypos = 1; break;
-                                       default:
-                                               goto fini;
-                                       }
-                               }
-                       } else {
-                               ++ypos;
-                       }
-               }
-               if (ypos >= height)
-                       break;
-       }
-
-fini:
-       if (LWZReadByte(fd,FALSE,c)>=0) {
-               /* Ignore extra */
-       }
-}
-
-void gdImageRectangle(gdImagePtr im, int x1, int y1, int x2, int y2, int color)
-{
-	gdImageLine(im, x1, y1, x2, y1, color);		
-	gdImageLine(im, x1, y2, x2, y2, color);		
-	gdImageLine(im, x1, y1, x1, y2, color);
-	gdImageLine(im, x2, y1, x2, y2, color);
-}
-
-void gdImageFilledRectangle(gdImagePtr im, int x1, int y1, int x2, int y2, int color)
-{
-	int x, y;
-	for (y=y1; (y<=y2); y++) {
-		for (x=x1; (x<=x2); x++) {
-			gdImageSetPixel(im, x, y, color);
-		}
-	}
-}
-
-int gdGetWord(int *result, FILE *in)
-{
-	int r;
-	r = getc(in);
-	if (r == EOF) {
-		return 0;
-	}
-	*result = r << 8;
-	r = getc(in);	
-	if (r == EOF) {
-		return 0;
-	}
-	*result += r;
-	return 1;
-}
-
-void gdPutWord(int w, FILE *out)
-{
-	putc((unsigned char)(w >> 8), out);
-	putc((unsigned char)(w & 0xFF), out);
-}
-
-int gdGetByte(int *result, FILE *in)
-{
-	int r;
-	r = getc(in);
-	if (r == EOF) {
-		return 0;
-	}
-	*result = r;
-	return 1;
-}
-
-gdImagePtr gdImageCreateFromGd(FILE *in)
-{
-	int sx, sy;
-	int x, y;
-	int i;
-	gdImagePtr im;
-	if (!gdGetWord(&sx, in)) {
-		goto fail1;
-	}
-	if (!gdGetWord(&sy, in)) {
-		goto fail1;
-	}
-	im = gdImageCreate(sx, sy);
-	if (!gdGetByte(&im->colorsTotal, in)) {
-		goto fail2;
-	}
-	if (!gdGetWord(&im->transparent, in)) {
-		goto fail2;
-	}
-	if (im->transparent == 257) {
-		im->transparent = (-1);
-	}
-	for (i=0; (i<gdMaxColors); i++) {
-		if (!gdGetByte(&im->red[i], in)) {
-			goto fail2;
-		}
-		if (!gdGetByte(&im->green[i], in)) {
-			goto fail2;
-		}
-		if (!gdGetByte(&im->blue[i], in)) {
-			goto fail2;
-		}
-	}	
-	for (y=0; (y<sy); y++) {
-		for (x=0; (x<sx); x++) {	
-			int ch;
-			ch = getc(in);
-			if (ch == EOF) {
-				gdImageDestroy(im);
-				return 0;
-			}
-			im->pixels[x][y] = ch;
-		}
-	}
-	return im;
-fail2:
-	gdImageDestroy(im);
-fail1:
-	return 0;
-}
-	
-void gdImageGd(gdImagePtr im, FILE *out)
-{
-	int x, y;
-	int i;
-	int trans;
-	gdPutWord(im->sx, out);
-	gdPutWord(im->sy, out);
-	putc((unsigned char)im->colorsTotal, out);
-	trans = im->transparent;
-	if (trans == (-1)) {
-		trans = 257;
-	}	
-	gdPutWord(trans, out);
-	for (i=0; (i<gdMaxColors); i++) {
-		putc((unsigned char)im->red[i], out);
-		putc((unsigned char)im->green[i], out);	
-		putc((unsigned char)im->blue[i], out);	
-	}
-	for (y=0; (y < im->sy); y++) {	
-		for (x=0; (x < im->sx); x++) {	
-			putc((unsigned char)im->pixels[x][y], out);
-		}
-	}
-}
-
-gdImagePtr
-gdImageCreateFromXbm(FILE *fd)
-{
-	gdImagePtr im;	
-	int bit;
-	int w, h;
-	int bytes;
-	int ch;
-	int i, x, y;
-	char *sp;
-	char s[161];
-	if (!fgets(s, 160, fd)) {
-		return 0;
-	}
-	sp = &s[0];
-	/* Skip #define */
-	sp = strchr(sp, ' ');
-	if (!sp) {
-		return 0;
-	}
-	/* Skip width label */
-	sp++;
-	sp = strchr(sp, ' ');
-	if (!sp) {
-		return 0;
-	}
-	/* Get width */
-	w = atoi(sp + 1);
-	if (!w) {
-		return 0;
-	}
-	if (!fgets(s, 160, fd)) {
-		return 0;
-	}
-	sp = s;
-	/* Skip #define */
-	sp = strchr(sp, ' ');
-	if (!sp) {
-		return 0;
-	}
-	/* Skip height label */
-	sp++;
-	sp = strchr(sp, ' ');
-	if (!sp) {
-		return 0;
-	}
-	/* Get height */
-	h = atoi(sp + 1);
-	if (!h) {
-		return 0;
-	}
-	/* Skip declaration line */
-	if (!fgets(s, 160, fd)) {
-		return 0;
-	}
-	bytes = (w * h / 8) + 1;
-	im = gdImageCreate(w, h);
-	gdImageColorAllocate(im, 255, 255, 255);
-	gdImageColorAllocate(im, 0, 0, 0);
-	x = 0;
-	y = 0;
-	for (i=0; (i < bytes); i++) {
-		char h[3];
-		int b;
-		/* Skip spaces, commas, CRs, 0x */
-		while(1) {
-			ch = getc(fd);
-			if (ch == EOF) {
-				goto fail;
-			}
-			if (ch == 'x') {
-				break;
-			}	
-		}
-		/* Get hex value */
-		ch = getc(fd);
-		if (ch == EOF) {
-			goto fail;
-		}
-		h[0] = ch;
-		ch = getc(fd);
-		if (ch == EOF) {
-			goto fail;
-		}
-		h[1] = ch;
-		h[2] = '\0';
-		sscanf(h, "%x", &b);		
-		for (bit = 1; (bit <= 128); (bit = bit << 1)) {
-			gdImageSetPixel(im, x++, y, (b & bit) ? 1 : 0);	
-			if (x == im->sx) {
-				x = 0;
-				y++;
-				if (y == im->sy) {
-					return im;
-				}
-				/* Fix 8/8/95 */
-				break;
-			}
-		}
-	}
-	/* Shouldn't happen */
-	fprintf(stderr, "Error: bug in gdImageCreateFromXbm!\n");
-	return 0;
-fail:
-	gdImageDestroy(im);
-	return 0;
-}
-
-void gdImagePolygon(gdImagePtr im, gdPointPtr p, int n, int c)
-{
-	int i;
-	int lx, ly;
-	if (!n) {
-		return;
-	}
-	lx = p->x;
-	ly = p->y;
-	gdImageLine(im, lx, ly, p[n-1].x, p[n-1].y, c);
-	for (i=1; (i < n); i++) {
-		p++;
-		gdImageLine(im, lx, ly, p->x, p->y, c);
-		lx = p->x;
-		ly = p->y;
-	}
-}	
-	
-int gdCompareInt(const void *a, const void *b);
-	
-void gdImageFilledPolygon(gdImagePtr im, gdPointPtr p, int n, int c)
-{
-	int i;
-	int y;
-	int y1, y2;
-	int ints;
-	if (!n) {
-		return;
-	}
-	if (!im->polyAllocated) {
-		im->polyInts = (int *) malloc(sizeof(int) * n);
-		im->polyAllocated = n;
-	}		
-	if (im->polyAllocated < n) {
-		while (im->polyAllocated < n) {
-			im->polyAllocated *= 2;
-		}	
-		im->polyInts = (int *) realloc(im->polyInts,
-			sizeof(int) * im->polyAllocated);
-	}
-	y1 = p[0].y;
-	y2 = p[0].y;
-	for (i=1; (i < n); i++) {
-		if (p[i].y < y1) {
-			y1 = p[i].y;
-		}
-		if (p[i].y > y2) {
-			y2 = p[i].y;
-		}
-	}
-	for (y=y1; (y <= y2); y++) {
-		int interLast = 0;
-		int dirLast = 0;
-		int interFirst = 1;
-		ints = 0;
-		for (i=0; (i <= n); i++) {
-			int x1, x2;
-			int y1, y2;
-			int dir;
-			int ind1, ind2;
-			int lastInd1 = 0;
-			if ((i == n) || (!i)) {
-				ind1 = n-1;
-				ind2 = 0;
-			} else {
-				ind1 = i-1;
-				ind2 = i;
-			}
-			y1 = p[ind1].y;
-			y2 = p[ind2].y;
-			if (y1 < y2) {
-				y1 = p[ind1].y;
-				y2 = p[ind2].y;
-				x1 = p[ind1].x;
-				x2 = p[ind2].x;
-				dir = -1;
-			} else if (y1 > y2) {
-				y2 = p[ind1].y;
-				y1 = p[ind2].y;
-				x2 = p[ind1].x;
-				x1 = p[ind2].x;
-				dir = 1;
-			} else {
-				/* Horizontal; just draw it */
-				gdImageLine(im, 
-					p[ind1].x, y1, 
-					p[ind2].x, y1,
-					c);
-				continue;
-			}
-			if ((y >= y1) && (y <= y2)) {
-				int inter = 
-					(y-y1) * (x2-x1) / (y2-y1) + x1;
-				/* Only count intersections once
-					except at maxima and minima. Also, 
-					if two consecutive intersections are
-					endpoints of the same horizontal line
-					that is not at a maxima or minima,	
-					discard the leftmost of the two. */
-				if (!interFirst) {
-					if ((p[ind1].y == p[lastInd1].y) &&
-						(p[ind1].x != p[lastInd1].x)) {
-						if (dir == dirLast) {
-							if (inter > interLast) {
-								/* Replace the old one */
-								im->polyInts[ints] = inter;
-							} else {
-								/* Discard this one */
-							}	
-							continue;
-						}
-					}
-					if (inter == interLast) {
-						if (dir == dirLast) {
-							continue;
-						}
-					}
-				} 
-				if (i > 0) {
-					im->polyInts[ints++] = inter;
-				}
-				lastInd1 = i;
-				dirLast = dir;
-				interLast = inter;
-				interFirst = 0;
-			}
-		}
-		qsort(im->polyInts, ints, sizeof(int), gdCompareInt);
-		for (i=0; (i < (ints-1)); i+=2) {
-			gdImageLine(im, im->polyInts[i], y,
-				im->polyInts[i+1], y, c);
-		}
-	}
-}
-	
-int gdCompareInt(const void *a, const void *b)
-{
-	return (*(const int *)a) - (*(const int *)b);
-}
-
-void gdImageSetStyle(gdImagePtr im, int *style, int noOfPixels)
-{
-	if (im->style) {
-		free(im->style);
-	}
-	im->style = (int *) 
-		malloc(sizeof(int) * noOfPixels);
-	memcpy(im->style, style, sizeof(int) * noOfPixels);
-	im->styleLength = noOfPixels;
-	im->stylePos = 0;
-}
-
-void gdImageSetBrush(gdImagePtr im, gdImagePtr brush)
-{
-	int i;
-	im->brush = brush;
-	for (i=0; (i < gdImageColorsTotal(brush)); i++) {
-		int index;
-		index = gdImageColorExact(im, 
-			gdImageRed(brush, i),
-			gdImageGreen(brush, i),
-			gdImageBlue(brush, i));
-		if (index == (-1)) {
-			index = gdImageColorAllocate(im,
-				gdImageRed(brush, i),
-				gdImageGreen(brush, i),
-				gdImageBlue(brush, i));
-			if (index == (-1)) {
-				index = gdImageColorClosest(im,
-					gdImageRed(brush, i),
-					gdImageGreen(brush, i),
-					gdImageBlue(brush, i));
-			}
-		}
-		im->brushColorMap[i] = index;
-	}
-}
-	
-void gdImageSetTile(gdImagePtr im, gdImagePtr tile)
-{
-	int i;
-	im->tile = tile;
-	for (i=0; (i < gdImageColorsTotal(tile)); i++) {
-		int index;
-		index = gdImageColorExact(im, 
-			gdImageRed(tile, i),
-			gdImageGreen(tile, i),
-			gdImageBlue(tile, i));
-		if (index == (-1)) {
-			index = gdImageColorAllocate(im,
-				gdImageRed(tile, i),
-				gdImageGreen(tile, i),
-				gdImageBlue(tile, i));
-			if (index == (-1)) {
-				index = gdImageColorClosest(im,
-					gdImageRed(tile, i),
-					gdImageGreen(tile, i),
-					gdImageBlue(tile, i));
-			}
-		}
-		im->tileColorMap[i] = index;
-	}
-}
-
-void gdImageInterlace(gdImagePtr im, int interlaceArg)
-{
-	im->interlace = interlaceArg;
-}
-
diff --git a/src/gxhpng.c b/src/gxhpng.c
deleted file mode 100644
index ce6909b..0000000
--- a/src/gxhpng.c
+++ /dev/null
@@ -1,437 +0,0 @@
-/* 
- * include ./configure's header file
- */
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
-
-
-/* Rasterize current metafile buffer via gd library.  Loosly based
-   on the gxpng utility:
-
-   gxpng Copyright 1999 Matthias Muennich 
-
-   Has been modified to behave more like the X interface, so the
-   output image will look more like the screen image (B. Doty)
-
-   Modified for GD version 2 (B. Doty, 11/06) */
-
-#include "gd.h"
-
-gaint gxhpng (char *, gaint, gaint, gaint, gaint, char *, char *, gaint) ;
-void gxgdpoly (gaint, gaint, gaint);
-void gaprnt (gaint, char *);
-
-/* default size of the graph */
-
-#define SX 800
-#define SY 600
-
-static char pout[256];   /* Build error msgs here */
-static gdImagePtr im;
-static gdPoint xxyy[256];
-
-/* rgb values for 16 defined colors */
-/* these exactly match what's in gxX.c so that the graphical display 
-   and the printim output look the same */
-static gaint 
- rr[16]={0,255,250,  0, 30,  0,240,230,240,160,160,  0,230,  0,130,170},
- gg[16]={0,255, 60,220, 60,200,  0,220,130,  0,230,160,175,210,  0,170},
- bb[16]={0,255, 60,  0,255,200,130, 50, 40,200, 50,255, 45,140,220,170};
-
-gaint gxhpng (char *fnout, gaint xin, gaint yin, gaint bwin, gaint gifflg, 
-	    char *bgImage, char *fgImage, gaint tcolor) {
-FILE *ofile, *bgfile, *fgfile;
-gdPoint *xybuf=NULL;
-gdImagePtr imfg, imbg=0;
-float xlo,xhi,ylo,yhi;
-gaint xpos,ypos,xs,ys,xrs,yrs;
-gaint cmd,i,len,cnt,flag,ii,siz,xp,yp,xp2,yp2,thck,backbw;
-gaint ccol,fflag,xyc=0,red,grn,blu,xcur,ycur,xsav,ysav,retcod;
-gaint cdef[256],cnum[256],rc[256],gc[256],bc[256]; 
-gaint xycnt=0,xyflag,gdthck;
-short *poi,*pend;
-
-  im = NULL;
-
-  if (bwin<-900) backbw = gxdbkq();
-  else backbw = bwin;
-
-  for (i=0; i<=255; i++) {
-    cdef[i]=0;
-    rc[i] = 125; gc[i] = 125; bc[i] = 125;  /* initialize colors */
-  }
-  for (i=0; i<16; i++) { 
-    rc[i] = rr[i]; gc[i] = gg[i]; bc[i] = bb[i];
-  }
-
-  /*  Set up pointers into current meta buffer list */
-
-  if (dbmode && pntf==0) {
-    lens2[pnt2-1] = hpnt-hbuff;
-    cnt = pnt2; flag = 1;
-  } else {
-    lens[pnt-1] = hpnt-hbuff;
-    cnt = pnt; flag = 0;
-  }
-
-  /*  Allocate the gd image and set up the scaling for it */
-
-  if (xin<0 || yin<0) {  
-    /* user has not specified image size */
-    if (xrsize > yrsize) {
-      xs = SX; 
-      ys = (gaint)((yrsize/xrsize)*SX);
-    }
-    else {
-      xs = (gaint)((xrsize/yrsize)*SX); 
-      ys = SX;
-    }
-  } 
-  else {
-    xs = xin; 
-    ys = yin;
-  }
-  xrs = (gaint)(xrsize*1000.0+0.5);
-  yrs = (gaint)(yrsize*1000.0+0.5);
-
-  /* handle background PNG picture */
-  if (*bgImage) {
-    /* Make sure bgImage is a .png -- otherwise return error */
-    len = 0;
-    while (*(bgImage+len)) len++;
-    len = len-4;
-    if (len>0) {
-      if (*(bgImage+len+1)!='p' || 
-	  *(bgImage+len+2)!='n' || 
-	  *(bgImage+len+3)!='g' ) {
-	if (*(bgImage+len+1)!='P' || 
-	    *(bgImage+len+2)!='N' || 
-	    *(bgImage+len+3)!='G' ) {
-	  return(5);
-	} 
-      }
-    }
-
-    if ((bgfile=fopen(bgImage,"rb"))) {
-      if ((im=gdImageCreateFromPng(bgfile)) != NULL) {
-	if (im->sx < xs || im->sy < ys) {
-	  gdImageDestroy(im);
-	  im=NULL;
-	}
-      } else {
-	fclose(bgfile);
-	return(7);
-      }
-      fclose(bgfile);
-    } else {
-      return(3);
-    }
-  }
-
-  if (!im) {
-    /* im = gdImageCreateTrueColor(xs,ys);  For anti-aliasing */
-    im = gdImageCreate(xs,ys);
-  }
-
-  /*  Set up background and foreground colors */
-  if (backbw) {
-    cnum[0] = gdImageColorAllocate(im, 255, 255, 255);
-    cnum[1] = gdImageColorAllocate(im, 0, 0, 0);
-  } else {
-    cnum[0] = gdImageColorAllocate(im, 0, 0, 0);
-    cnum[1] = gdImageColorAllocate(im, 255, 255, 255);
-  }
-  cdef[0] = 1; cdef[1] = 1;
-  ccol = 1;
-
-  /* Loop thru allocated meta buffers and handle the graphics commands found there */
-  fflag = 0;
-  xyflag = 0;
-  gdthck = 1;
-  for (ii=0; ii<cnt; ii++) {
-    if (flag) {
-      poi = bufs2[ii];
-      pend = poi + lens2[ii];
-    } else { 
-      poi = bufs[ii];
-      pend = poi + lens[ii];
-    } 
-
-    while (poi<pend) {
-      /* Get message type */
-      cmd = *poi; 
-
-      /* Handle various message types */
-      /* -9 is end of file.  Should not happen. */
-      if (cmd==-9) {
-        gaprnt(0,"Logic Error 4 in gxhpng.  Notify Developer\n");
-        return(99);
-      }
-
-      /*  -1 indicates start of file.  Should not ocurr. */
-      else if (cmd==-1) {
-        gaprnt(0,"Logic Error 8 in gxhpng.  Notify Developer\n");
-        return(99);
-      }
-
-      /* -2 indicates new frame.  Also should not ocurr */
-      else if (cmd==-2) {
-        gaprnt(0,"Logic Error 12 in gxhpng.  Notify Developer\n");
-        return(99);
-      }
-
-      /* -3 indicates new color.  One arg; color number.  */
-      /*  Allocate in gd if not done already */
-      else if (cmd==-3) {
-        if (xyflag) { gxgdpoly(xycnt,cnum[ccol],gdthck); xyflag=0; xycnt=0; }
-        ccol = *(poi+1);
-        if (ccol<0) ccol=0;
-        if (cdef[ccol]==0) {
-          cnum[ccol] = gdImageColorAllocate(im, rc[ccol], gc[ccol], bc[ccol]);
-          cdef[ccol] = 1;
-        }
-        poi += 2;
-      }
-
-      /* -4 indicates new line thickness.  It has two arguments */
-      else if (cmd==-4) {
-        if (xyflag) { gxgdpoly(xycnt,cnum[ccol],gdthck); xyflag=0; xycnt = 0; }
-        thck = *(poi+2);
-        gdthck = 1;
-        if (thck>5) gdthck = 2;
-        if (thck>11) gdthck = 3;
-        poi += 3;
-      }
-
-      /*  -5 defines a new color, in rgb.  It has four int args */
-      /*  If this changes the existing definition for this color, 
-          then indicate this has not yet been allocated to gd */
-      else if (cmd==-5){
-        if (xyflag) { gxgdpoly(xycnt,cnum[ccol],gdthck); xyflag=0; xycnt = 0; }
-        i = *(poi+1);
-        red = *(poi+2);
-        grn = *(poi+3);
-        blu = *(poi+4);
-        if (rc[i]!=red || gc[i]!=grn || bc[i]!=blu) {
-          rc[i] = red; gc[i] = grn; bc[i] = blu;
-          cdef[i] = 0;
-        }
-        poi += 5;
-      }
-
-      /* -6 is for a filled rectangle.  It has four float args. */ 
-      else if (cmd==-6){
-        if (xyflag) { gxgdpoly(xycnt,cnum[ccol],gdthck); xyflag=0; xycnt = 0; }
-        xlo = *(poi+1); ylo = *(poi+3);
-        xhi = *(poi+2); yhi = *(poi+4);
-        xp = (xlo*xs)/xrs;
-        yp = ys-(ylo*ys)/yrs;
-        xp2 = (xhi*xs)/xrs;
-        yp2 = ys-(yhi*ys)/yrs;
-        if (xp>xp2) { 
-           i = xp;
-           xp = xp2;
-           xp2 = i;
-        }
-        if (yp>yp2) { 
-           i = yp;
-           yp = yp2;
-           yp2 = i;
-        }
-        gdImageFilledRectangle(im, xp, yp, xp2, yp2, cnum[ccol]);
-        poi += 5;
-      }
-
-      /* -7 indicates the start of a polygon fill.  It has one arg. */
-      else if (cmd==-7){
-        if (xyflag) { gxgdpoly(xycnt,cnum[ccol],gdthck); xyflag=0; xycnt = 0; }
-        siz = *(poi+1);
-        xybuf = (gdPoint *)malloc(sizeof(gdPoint)*(siz+1));
-        if (xybuf==NULL) {
-          gaprnt(0,"Memory allocation error: gxhpng\n");
-          return(99);
-        }
-        fflag = 1;
-        xyc = 0;
-        poi += 2;
-      }
-
-      /* -8 is to terminate polygon fill.  It has no args */
-      else if (cmd==-8) {
-        if (xybuf->x != (xybuf+xyc-1)->x ||
-            xybuf->y != (xybuf+xyc-1)->y) {
-          (xybuf+xyc)->x = xybuf->x;
-          (xybuf+xyc)->y = xybuf->y;
-          xyc++;
-        }
-        gdImageFilledPolygon(im, xybuf, xyc, cnum[ccol]); 
-        free (xybuf);
-        fflag = 0;
-        poi += 1;
-      }
-
-      /* -10 is a move to instruction.  It has two float args */ 
-      else if (cmd==-10){
-        if (xyflag) { gxgdpoly(xycnt,cnum[ccol],gdthck); xyflag=0; xycnt = 0; }
-        xpos = *(poi+1); ypos = *(poi+2);
-        xsav = (xpos*xs)/xrs;
-        ysav = ys-(ypos*ys)/yrs;
-        if (fflag) {
-          (xybuf+xyc)->x = xsav;
-          (xybuf+xyc)->y = ysav;
-          xyc++;
-        } else {   
-          xxyy[0].x = xsav;
-          xxyy[0].y = ysav;
-          xycnt = 1;
-          xyflag = 0;
-        }
-        poi += 3;
-      }
-
-      /*  -11 is draw to.  It has two float args. */  
-      else if (cmd==-11){
-        xpos = *(poi+1); ypos = *(poi+2);
-        xcur = (xpos*xs)/xrs;
-        ycur = ys-(ypos*ys)/yrs;
-        if (fflag) {    /* Assume first poly point is moveto */
-          if ((xybuf+xyc-1)->x != xcur || (xybuf+xyc-1)->y != ycur) { 
-            (xybuf+xyc)->x = xcur;
-            (xybuf+xyc)->y = ycur;
-            xyc++;
-          }
-        } else {
-          xxyy[xycnt].x = xcur;
-          xxyy[xycnt].y = ycur;
-          if (xycnt<255) xycnt++;
-          else {
-            gxgdpoly(xycnt+1,cnum[ccol],gdthck);
-            xxyy[0].x = xcur;
-            xxyy[0].y = ycur;
-            xycnt = 1; 
-          }
-          xyflag = 1;
-        }
-        xsav = xcur; ysav = ycur;
-        poi += 3;
-      }
-
-      /* -12 indicates new fill pattern.  We ignore it here */
-      else if (cmd==-12) {
-        if (xyflag) { gxgdpoly(xycnt,cnum[ccol],gdthck); xyflag=0; xycnt = 0; }
-        poi += 4;
-      }
-
-      /* -20 is a draw widget.  We ignore it here. */
-      else if (cmd==-20) {
-        if (xyflag) { gxgdpoly(xycnt,cnum[ccol],gdthck); xyflag=0; xycnt = 0; }
-        poi += 2;
-      }
-
-      /* Any other command would be invalid */
-      else {
-        gaprnt(0,"Logic Error 20 in gxhpng.  Notify Developer\n");
-        return(99);
-      }
-    }
-  }
-  if (xyflag) { gxgdpoly(xycnt,cnum[ccol],gdthck); xyflag=0; xycnt = 0; }
-
-  /* handle foreground PNG picture */
-  if (*fgImage) {
-    /* Make sure fgImage is a .png -- otherwise return error */
-    len = 0;
-    while (*(fgImage+len)) len++;
-    len = len-4;
-    if (len>0) {
-      if (*(fgImage+len+1)!='p' || 
-	  *(fgImage+len+2)!='n' || 
-	  *(fgImage+len+3)!='g' ) {
-	if (*(fgImage+len+1)!='P' || 
-	    *(fgImage+len+2)!='N' || 
-	    *(fgImage+len+3)!='G' ) {
-	  return(6);
-	} 
-      }
-    }
-
-    if ((fgfile=fopen(fgImage,"rb"))) {
-      if ((imfg=gdImageCreateFromPng(fgfile)) !=NULL) {
-	gdImageCopy(im,imfg,0,0,0,0,imfg->sx,imfg->sy);
-      }
-      else {
-	fclose(fgfile);
-	return(8);
-      }
-    } else {
-      return(4);
-    }
-    fclose(fgfile);
-    gdImageDestroy(imfg);
-  }
-
-
-  retcod = 0;
-  /* optionally convert a color to transparent */
-  if (tcolor != -1 ) {
-    if (cdef[tcolor]){
-      gdImageColorTransparent(im,cnum[tcolor]);
-      snprintf(pout,255,"Transparent color: #%d\n",tcolor);
-      gaprnt(2,pout);
-    }
-  }
-  if (*bgImage) {
-    if ((bgfile=fopen(bgImage,"rb"))) {
-      if ((imbg=gdImageCreateFromPng(bgfile)) !=NULL) {
-	gdImageCopy(imbg,im,0,0,0,0,im->sx,im->sy);
-      }
-    }
-    fclose(bgfile);
-    gdImageDestroy(im);
-    im=imbg;
-  }
-
-  ofile = fopen(fnout, "wb");
-  if (ofile==NULL) { 
-    snprintf(pout,255,"Open error on %s\n",fnout);
-    gaprnt(0,pout);
-    retcod = 1; 
-  } else {
-    if (gifflg==1) {                    /* image output in gif format */
-      gdImageGif (im, ofile);
-    }
-    else if (gifflg==3) {     	  /* image output in jpg format */
-      gdImageJpeg(im, ofile, -1);
-    }
-    else {                       	  /* image output in png format */
-      gdImagePng(im, ofile);
-    }
-    fclose(ofile);
-  }
-
-  gdImageDestroy(im);
-  return (retcod);
-}
-
-/* Turns out that the anti-aliasing doesn't work with
-   the line thickness, in gd-v2.  Decided to not use
-   the anti-aliasing this version.  But kept the 
-   function calls here, commented out, for possible
-   future use.  */
-
-void gxgdpoly (gaint xycnt, gaint col, gaint thck) {
-  if (xycnt==2) {
-/*     gdImageSetAntiAliased(im,col); */
-     gdImageSetThickness(im,thck);
-/*     gdImageLine(im, xxyy[0].x, xxyy[0].y, xxyy[1].x, xxyy[1].y, gdAntiAliased); */
-     gdImageLine(im, xxyy[0].x, xxyy[0].y, xxyy[1].x, xxyy[1].y, col);
-  }
-  if (xycnt>2) {
-/*    gdImageSetAntiAliased(im,col); */
-    gdImageSetThickness(im,thck);
-/*    gdImageOpenPolygon(im, xxyy, xycnt, gdAntiAliased); */
-    gdImageOpenPolygon(im, xxyy, xycnt, col);
-  }
-}
-
diff --git a/src/gxmeta.c b/src/gxmeta.c
index 2bd2d4c..5cc463b 100644
--- a/src/gxmeta.c
+++ b/src/gxmeta.c
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 /* Routines related to hardcopy (metafile) output. */
@@ -7,7 +6,7 @@
 #ifdef HAVE_CONFIG_H
 #include "config.h"
 
-/* If autoconfed, only include malloc.h when it's presen */
+/* If autoconfed, only include malloc.h when it's present */
 #ifdef HAVE_MALLOC_H
 #include <malloc.h>
 #endif
@@ -24,523 +23,409 @@
 #include "gatypes.h"
 #include "gx.h"
 
-static gaint bopt=BUFOPT;                   /* Buffering option   */
-static long buffsz;                         /* metafile buffer size, formerly known as HBUFSZ */
-static gaint bflag;                         /* Buffering disabled */
-static gaint hflag;                         /* File output enabled*/
-static gaint herr;                          /* Fatal error        */
-static gaint hferr;                         /* File I/O error     */
-static gaint hpflg;                         /* User printed frame */
-static short *hbuff, *hpnt, *hend;          /* Current buffer ptrs*/
-static FILE *hfile;                         /* meta file pointer  */
-static gaint hpos;                          /* Frame pos in metafi*/
-static short *bufs[250];                    /* Buffer stuff       */
-static short *bufs2[250];                   /* Enough for 50MB    */
-static gaint lens[250],lens2[250];
-static gaint pnt,pnt2,pntf;     
-static gaint dbmode;                        /* Double Buffer mode */
-static gadouble xrsize,yrsize;
-
-void xycnv (short, short, gadouble *, gadouble *);
-
-/* Specify on startup what sort of buffering we want.  
-   We can do memory buffering (the default on UNIX machines) 
-   or file buffering, done only when print is enabled */
-
-void gxhopt (gaint flag) {
-  bopt = flag;
-}
+void *galloc(size_t,char *);
 
-/* Initialize any buffering, etc. when GrADS starts up */
+/* Struct to form linked list for the meta buffer */
+/* The buffer area is allocated as float, to insure at least four bytes
+   per element.  In some cases, ints and chars will get stuffed into a 
+   float (via pointer casting).  */
 
-void gxhnew (gadouble xsiz, gadouble ysiz, gaint hbufsz) {
-  buffsz = hbufsz;
-  xrsize = xsiz;
-  yrsize = ysiz;
-  hflag = 0; 
-  herr = 0;
-  hferr = 0;
-  hpflg = 0;
-  dbmode = 0;
-  if (bopt) bflag = 1;
-  else {
-    hbuff = (short *)malloc(sizeof(short)*buffsz);
-    if (hbuff==NULL) {
-      printf ("Unable to allocate memory for metafile operations.\n");
-      herr = 1;
-      bufs[0] = NULL;
-    } else {
-      bflag = 0;
-      pnt = 1;
-      bufs[0] = hbuff;
-      hpnt = hbuff;
-      hend = hbuff+(buffsz-10L);
-    }
-  }
-  pnt2 = 0;
-}
+/* Don't use gafloat or gaint for meta buffer stuffing.  */
 
-/* Enable hardcopy (metafile) output.   */
+struct gxmbuf {
+  struct gxmbuf *fpmbuf;         /* Forward pointer */
+  float *buff;                   /* Buffer area */
+  gaint len;                     /* Length of Buffer area */
+  gaint used;                    /* Amount of buffer used */
+};
 
-gaint gxhbgn (char *fname) {
-gaint xx,rc;
-short bb[3];
+/* Buffer chain anchor here; also a convenience pointer to the last buffer
+   in the chain.  Times 2, for double buffering.  mbufanch and mbuflast 
+   always point to the buffer currently being added to.  In double buffering
+   mode, that will be the background buffer (and mbufanch2 points to the 
+   buffer representing the currently display image). */
 
-  if (hferr) {
-    printf ("Metafile error state is positive.\n");
-    printf ("Disable Print before attempting an Enable Print.\n");
-    return (0);
-  }
+static struct gxmbuf *mbufanch=NULL;  /* Buffer Anchor */
+static struct gxmbuf *mbuflast=NULL;  /* Last struct in chain */
 
-  /* Open metafile if not already open.  */
+static struct gxmbuf *mbufanch2=NULL;  /* Buffer Anchor */
+static struct gxmbuf *mbuflast2=NULL;  /* Last struct in chain */
 
-  if (hflag) {
-    printf ("Metafile already open\n");
-    return(0);
-  }
+static gaint dbmode;       /* double buffering flag */
 
-  hfile = fopen(fname,"wb");
-  if (hfile==NULL) {
-    printf ("Error opening meta file %s \n", fname);
-    return (1);
-  }
+#define BWORKSZ 250000
 
-  /* Allocate the memory buffer if we are doing file buffering.  */
+static gaint mbuferror = 0;    /* Indicate an error state; suspends buffering */
 
-  if (bopt) {
-    hbuff = (short *)malloc(sizeof(short)*buffsz);
-    if (hbuff==NULL) {
-      printf ("Unable to allocate memory for metafile operations.\n");
-      fclose(hfile);
-      return (1);
-    }
-    hpnt = hbuff;
-    hend = hbuff+(buffsz-10L);
-    bflag = 0;
-  }
+/* Initialize any buffering, etc. when GrADS starts up */
 
-  /* Write physical page size to output metafile */
-
-  bb[0] = -1;
-  xx = (gaint)(xrsize*1000.0+0.5);
-  if (xx<0) xx=0;
-  if (xx>32760) xx=32760;
-  bb[1] = xx;
-  xx = (gaint)(yrsize*1000.0+0.5);
-  if (xx<0) xx=0;
-  if (xx>32760) xx=32760;
-  bb[2] = xx;
-  rc = gxhwri(bb, 3);
-  if (rc) return (1);
-  hpos = ftell(hfile);
-  herr = 0;
-  hpflg = 0;
-  hferr = 0;
-  hflag = 1;
-  if (bopt) {
-    printf ("File buffering enabled. ");
-    printf ("Issue CLEAR command to start buffering.\n");
+void gxhnew (gadouble xsiz, gadouble ysiz, gaint hbufsz) {
+gaint rc;
+  mbufanch = NULL;
+  mbuflast = NULL;
+  mbuferror = 0;
+  if (sizeof(int) > sizeof(float)) {
+    printf ("Error in gx initialization: Incompatable int and float sizes\n");
+    mbuferror = 99;
+    return;
+  }
+  rc = mbufget();
+  if (rc) {
+    printf ("Error in gx initialization: Unable to allocate meta buffer\n");
+    mbuferror = 99;
   }
-  return (0);
 }
 
-/* Metafile output, command with 0 args */
+
+/* Add command with 0 args to metafile buffer */
 
 void hout0 (gaint cmd) {
-  if (bflag||herr) return;
-  *hpnt = cmd;
-  hpnt++;
-  if (hpnt>hend) hfull();
+gaint rc;
+signed char *ch;
+  if (mbuferror) return;
+  if (mbuflast->len - mbuflast->used <3) {
+    rc = mbufget();
+    if (rc) {
+      gxmbuferr();
+      return;
+    }
+  }
+  ch = (signed char *)(mbuflast->buff+mbuflast->used);
+  *ch = (signed char)99;
+  *(ch+1) = (signed char)cmd;
+  mbuflast->used++;
 }
 
-/* Metafile output, command plus one integer argument */
+/* Add a command with one small integer argument to the metafile buffer.
+   The argument is assumed to fit into a signed char (-127 to 128).  */
+
+void hout1c (gaint cmd, gaint opt) {
+gaint rc;
+signed char *ch;
+  if (mbuferror) return;
+  if (mbuflast->len - mbuflast->used <4) {
+    rc = mbufget();
+    if (rc) {
+      gxmbuferr();
+      return;
+    }
+  }
+  ch = (signed char *)(mbuflast->buff+mbuflast->used);
+  *ch = (signed char)99;
+  *(ch+1) = (signed char)cmd;
+  mbuflast->used++;
+  *(ch+2) = (signed char)opt;
+  mbuflast->used++;
+}
+
+/* Add command with one integer argument to metafile buffer */
 
 void hout1 (gaint cmd, gaint opt) {
-  if (bflag||herr) return;
-  *hpnt = cmd;
-  hpnt++;
-  *hpnt = opt;
-  hpnt++;
-  if (hpnt>hend) hfull();
+gaint rc;
+signed char *ch;
+int *iii;
+  if (mbuferror) return;
+  if (mbuflast->len - mbuflast->used <4) {
+    rc = mbufget();
+    if (rc) {
+      gxmbuferr();
+      return;
+    }
+  }
+  ch = (signed char *)(mbuflast->buff+mbuflast->used);
+  *ch = (signed char)99;
+  *(ch+1) = (signed char)cmd;
+  mbuflast->used++;
+  iii = (int *)(mbuflast->buff+mbuflast->used);
+  *iii = (int)opt;
+  mbuflast->used++;
 }
 
-/* Metafile output, command plus two double args */
+/* Metafile buffer, command plus two double args */
 
 void hout2 (gaint cmd, gadouble x, gadouble y) {
-gaint xx,yy;
-  if (bflag||herr) return;
-  *hpnt = cmd;
-  hpnt++;
-  xx = (gaint)(x*1000.0+0.5);
-  if (xx<0) xx=0;
-  if (xx>32760) xx=32760;
-  *hpnt = xx;
-  hpnt++;
-  yy = (gaint)(y*1000.0+0.5);
-  if (yy<0) yy=0;
-  if (yy>32760) yy=32760;
-  *hpnt = yy;
-  hpnt++;
-  if (hpnt>hend) hfull();
+gaint rc;
+signed char *ch;
+  if (mbuferror) return;
+  if (mbuflast->len - mbuflast->used <5) {
+    rc = mbufget();
+    if (rc) {
+      gxmbuferr();
+      return;
+    }
+  }
+  ch = (signed char *)(mbuflast->buff+mbuflast->used);
+  *ch = (signed char)99;
+  *(ch+1) = (signed char)cmd;
+  mbuflast->used++;
+  *(mbuflast->buff+mbuflast->used) = (float)x;
+  mbuflast->used++;
+  *(mbuflast->buff+mbuflast->used) = (float)y;
+  mbuflast->used++;
 }
 
-/* Metafile output, command plus two integer args */
+/* Metafile buffer, command plus two integer args */
 
 void hout2i (gaint cmd, gaint i1, gaint i2) {
-
-  if (bflag||herr) return;
-  *hpnt = cmd;
-  hpnt++;
-  *hpnt = i1;
-  hpnt++;
-  *hpnt = i2;
-  hpnt++;
-  if (hpnt>hend) hfull();
+gaint rc;
+signed char *ch;
+int *iii;
+  if (mbuferror) return;
+  if (mbuflast->len - mbuflast->used <5) {
+    rc = mbufget();
+    if (rc) {
+      gxmbuferr();
+      return;
+    }
+  }
+  ch = (signed char *)(mbuflast->buff+mbuflast->used);
+  *ch = (signed char)99;
+  *(ch+1) = (signed char)cmd;
+  mbuflast->used++;
+  iii = (int *)(mbuflast->buff+mbuflast->used);
+  *iii = (int)i1;
+  mbuflast->used++;
+  iii = (int *)(mbuflast->buff+mbuflast->used);
+  *iii = (int)i2;
+  mbuflast->used++;
 }
 
-/* Metafile output, command plus three integer args */
+/* Metafile buffer, command plus three integer args */
 
 void hout3i (gaint cmd, gaint i1, gaint i2, gaint i3) {
-
-  if (bflag||herr) return;
-  *hpnt = cmd;
-  hpnt++;
-  *hpnt = i1;
-  hpnt++;
-  *hpnt = i2;
-  hpnt++;
-  *hpnt = i3;
-  hpnt++;
-  if (hpnt>hend) hfull();
-}
-
-/* Metafile output, command plus four integer args */
-
-void hout4i (gaint cmd, gaint i1, gaint i2, gaint i3, gaint i4) {
-
-  if (bflag||herr) return;
-  *hpnt = cmd;
-  hpnt++;
-  *hpnt = i1;
-  hpnt++;
-  *hpnt = i2;
-  hpnt++;
-  *hpnt = i3;
-  hpnt++;
-  *hpnt = i4;
-  hpnt++;
-  if (hpnt>hend) hfull();
-}
-
-/* Metafile output, command plus four double args */
-
-void hout4 (gaint cmd, gadouble xl, gadouble xh, gadouble yl, gadouble yh) {
-gaint vv;
-  if (bflag||herr) return;
-  *hpnt = cmd;
-  hpnt++;
-  vv = (gaint)(xl*1000.0+0.5);
-  if (vv<0) vv=0;
-  if (vv>32760) vv=32760;
-  *hpnt = vv;
-  hpnt++;
-  vv = (gaint)(xh*1000.0+0.5);
-  if (vv<0) vv=0;
-  if (vv>32760) vv=32760;
-  *hpnt = vv;
-  hpnt++;
-  vv = (gaint)(yl*1000.0+0.5);
-  if (vv<0) vv=0;
-  if (vv>32760) vv=32760;
-  *hpnt = vv;
-  hpnt++;
-  vv = (gaint)(yh*1000.0+0.5);
-  if (vv<0) vv=0;
-  if (vv>32760) vv=32760;
-  *hpnt = vv;
-  hpnt++;
-  if (hpnt>hend) hfull();
-}
-
-/* Handle situation where memory buffer is full.  Either output
-   to the temporary file buffer, or disable additional input
-   into the memory buffer. */
-
-void hfull (void) {
-gaint len,rc;
-
-  if (bopt) {
-    len = hpnt - hbuff;
-    rc = gxhwri(hbuff, len);
-    if (rc) return;
-    else hpnt = hbuff;
-  } else {
-    if (dbmode && pntf==1) {
-      lens2[pnt2-1] = hpnt-hbuff;
-      if (pnt2>249) {
-        printf ("Out of buffer space\n");
-        herr=1;
-        return;
-      }
-      hbuff = (short *)malloc(sizeof(short)*buffsz);
-      if (hbuff==NULL) {
-        printf ("Memory allocation error for metafile buffers.\n");
-        herr = 1;
-      } else {
-        bufs2[pnt2] = hbuff;
-        hpnt = hbuff;
-        hend = hbuff+(buffsz-10L);
-        pnt2++;
-      } 
-    } else {
-      if (pnt>249) {
-        printf ("Out of buffer space\n");
-        herr=1;
-        return;
-      }
-      lens[pnt-1] = hpnt-hbuff;
-      hbuff = (short *)malloc(sizeof(short)*buffsz);
-      if (hbuff==NULL) {
-        printf ("Memory allocation error for metafile buffers.\n");
-        herr = 1;
-      } else {
-        bufs[pnt] = hbuff;
-        hpnt = hbuff;
-        hend = hbuff+(buffsz-10L);
-        pnt++;
-      } 
+gaint rc;
+signed char *ch;
+int *iii;
+  if (mbuferror) return;
+  if (mbuflast->len - mbuflast->used <6) {
+    rc = mbufget();
+    if (rc) {
+      gxmbuferr();
+      return;
     }
   }
+  ch = (signed char *)(mbuflast->buff+mbuflast->used);
+  *ch = (signed char)99;
+  *(ch+1) = (signed char)cmd;
+  mbuflast->used++;
+  iii = (int *)(mbuflast->buff+mbuflast->used);
+  *iii = (int)i1;
+  mbuflast->used++;
+  iii = (int *)(mbuflast->buff+mbuflast->used);
+  *iii = (int)i2;
+  mbuflast->used++;
+  iii = (int *)(mbuflast->buff+mbuflast->used);
+  *iii = (int)i3;
+  mbuflast->used++;
 }
 
-/* Output the current frame to the metafile.   Empty the metafile
-   buffer, and set things so that the frame will be marked on a
-   frame action.
-
-   If no metafile is open, write an EPS file by calling gxheps.
-*/
-
-void gxhprt (char *cmd) {
-gaint len,i,rc;
+/* Metafile buffer, command plus four integer args */
 
-  if (bopt && dbmode) {
-    printf ("Cannot print while in double-buffer mode ");
-    printf ("when using file buffering\n");
-    return;
-  }
-#ifndef STNDALN
-  if(!hflag) { /* No metafile open write a EPS file using gxeps */
-    gxheps(cmd);
-    return;
-  }
-#endif
-  if (herr||hferr) {
-    printf ("Error status on print metafile is positive.\n");
-    printf ("Cannot print current frame.\n");
-    return;
-  }
-  if (!hflag) {
-    printf ("Metafile not currently open\n");
-    return;
-  }
-  if (bopt) {
-    len = hpnt - hbuff;
-    rc = gxhwri(hbuff,len);
-    if (rc) return;
-    else hpnt = hbuff;
-  } else {
-    if (dbmode && pntf==0) {
-      i = 0;
-      while (i<pnt2) {
-        rc = gxhwri(bufs2[i],lens2[i]);
-        if (rc) return;
-        i++;
-      }
-    } else {
-      if (!dbmode) lens[pnt-1] = hpnt-hbuff;
-      i = 0;
-      while (i<pnt) {
-        rc = gxhwri(bufs[i],lens[i]);
-        if (rc) return;
-        i++;
-      }
+void hout5i (gaint cmd, gaint i1, gaint i2, gaint i3, gaint i4, gaint i5) {
+gaint rc;
+signed char *ch;
+int *iii;
+  if (mbuferror) return;
+  if (mbuflast->len - mbuflast->used <8) {
+    rc = mbufget();
+    if (rc) {
+      gxmbuferr();
+      return;
     }
   }
-  hpflg = 1;
-  hpos = ftell(hfile);
-  return;
+  ch = (signed char *)(mbuflast->buff+mbuflast->used);
+  *ch = (signed char)99;
+  *(ch+1) = (signed char)cmd;
+  mbuflast->used++;
+  iii = (int *)(mbuflast->buff+mbuflast->used);
+  *iii = (int)i1;
+  mbuflast->used++;
+  iii = (int *)(mbuflast->buff+mbuflast->used);
+  *iii = (int)i2;
+  mbuflast->used++;
+  iii = (int *)(mbuflast->buff+mbuflast->used);
+  *iii = (int)i3;
+  mbuflast->used++;
+  iii = (int *)(mbuflast->buff+mbuflast->used);
+  *iii = (int)i4;
+  mbuflast->used++;
+  iii = (int *)(mbuflast->buff+mbuflast->used);
+  *iii = (int)i5;
+  mbuflast->used++;
 }
 
-/* Write to output metafile */ 
-
-gaint gxhwri (void *buf, gaint len) {
-/* kk 020624 --- s */
-/*  if (len>0) fwrite (buf, sizeof(short), len, hfile); */
-  if (len>0) fwrite (buf, sizeof(short)*len, 1, hfile);
-/* kk 020624 --- e */
-  if (ferror(hfile)) {
-    printf ("I/O Error writing to print metafile.\n");
-    fclose(hfile);
-    hferr = 1;
-    hflag = 0;
-    hpflg = 0;
-    if (bopt) {
-      free(hbuff);
-      herr = 1;
-      bflag = 1;
+/* Metafile buffer, command plus four double args */
+
+void hout4 (gaint cmd, gadouble xl, gadouble xh, gadouble yl, gadouble yh) {
+gaint rc;
+signed char *ch;
+  if (mbuferror) return;
+  if (mbuflast->len - mbuflast->used <7) {
+    rc = mbufget();
+    if (rc) {
+      gxmbuferr();
+      return;
     }
-    return (1);
   }
-  return (0);
+  ch = (signed char *)(mbuflast->buff+mbuflast->used);
+  *ch = (signed char)99;
+  *(ch+1) = (signed char)cmd;
+  mbuflast->used++;
+  *(mbuflast->buff+mbuflast->used) = (float)xl;
+  mbuflast->used++;
+  *(mbuflast->buff+mbuflast->used) = (float)xh;
+  mbuflast->used++;
+  *(mbuflast->buff+mbuflast->used) = (float)yl;
+  mbuflast->used++;
+  *(mbuflast->buff+mbuflast->used) = (float)yh;
+  mbuflast->used++;
 }
 
-/* Close the metafile output file without further output */
+/* Add a single character to the metafile buffer, along with the font number (less
+   than 100), location (x,y), and size/rotation specs (4 floats).  Uses -21 as a
+   cmd value.   */
 
-void gxhend (void) {
-short bb[2];
+void houtch (char ch, gaint fn, gadouble x, gadouble y,
+         gadouble w, gadouble h, gadouble ang) {
 gaint rc;
-  if (hferr) {
-    printf ("Resetting print metafile error status.\n");
-    hferr = 0;
-    if (bopt) herr = 0;
-    return;
-  }
-  if (!hflag) {
-    printf ("No hardcopy metafile open\n");
-    return;
-  }
-  fseek(hfile,hpos,0L);
-  if (hpflg) {
-    bb[0] = -2;
-    bb[1] = -9;
-    rc = gxhwri(bb,2);
-  } else {
-    bb[0] = -9;
-    rc = gxhwri(bb,1);
-  }
-  if (!rc) {
-    fclose(hfile);
-    printf ("Hardcopy output file is closed \n");
-    hflag = 0;
-    if (bopt) {
-      free(hbuff);
-      bflag = 1;
+signed char *ccc;
+char *ucc;
+  if (mbuferror) return;
+  if (mbuflast->len - mbuflast->used <8) {
+    rc = mbufget();
+    if (rc) {
+      gxmbuferr();
+      return;
     }
   }
+  ccc = (signed char *)(mbuflast->buff+mbuflast->used);
+  ucc = (char *)(ccc+2);
+  *ccc = (signed char)99;
+  *(ccc+1) = (signed char)(-21);
+  *ucc = ch; 
+  *(ccc+3) = (signed char)fn;
+  mbuflast->used++;
+  *(mbuflast->buff+mbuflast->used) = (float)x;
+  mbuflast->used++;
+  *(mbuflast->buff+mbuflast->used) = (float)y;
+  mbuflast->used++;
+  *(mbuflast->buff+mbuflast->used) = (float)w;
+  mbuflast->used++;
+  *(mbuflast->buff+mbuflast->used) = (float)h;
+  mbuflast->used++;
+  *(mbuflast->buff+mbuflast->used) = (float)ang;
+  mbuflast->used++;
 }
 
-/* User has issued a clear.  Mark an end of frame if needed in
-   the output file; free buffers if we are in memory buffering
-   mode */
+/* User has issued a clear.  
+   This may also indicate the start or end of double buffering.  
+   If we are not double buffering, just free up the memory buffer and return.  
+   If we are starting up double buffering, we need another buffer chain.  
+   If we are ending double buffering, all memory needs to be released.  
+   If we are in the midst of double buffering, do a "swap" and free the foreground buffer. 
+
+   Values for action are:
+      0 -- new frame (clear display), wait before clearing.
+      1 -- new frame, no wait.
+      2 -- New frame in double buffer mode.  If not supported
+           has same result as action=1.  Usage involves multiple
+           calls with action=2 to obtain an animation effect.  
+      7 -- new frame, but just clear graphics.  Do not clear  
+           event queue; redraw buttons. 
+      8 -- clear only the event queue.
+      9 -- clear only the X request buffer
+*/ 
 
 void gxhfrm (gaint iact) {
-short bb;
-gaint rc,i;
-
-  if (hflag) {
-    fseek(hfile,hpos,0L);
-    if (hpflg) {
-      bb = -2;
-      rc = gxhwri(&bb, 1);
-      hpflg = 0;
-      if (!rc) hpos = ftell(hfile);
-    }
-  }
-  if (iact==2 && dbmode==0) {
-    dbmode = 1;
-    if (bopt==0) {
-      hbuff = (short *)malloc(sizeof(short)*buffsz);
-      if (hbuff==NULL) {
-        printf ("Memory allocation error for metafile buffers.\n");
-        herr = 1;
-        pnt2 = 0;
-        bufs2[0] = NULL;
-      } else {
-        pnt2 = 1;
-        pntf = 1;
-        bufs2[0] = hbuff;
-      } 
-    }
+struct gxmbuf *pmbuf, *pmbufl;
+
+  /* Start up double buffering */
+  if (iact==2 && dbmode==0) { 
+    mbufrel(1); 
+    if (mbufanch==NULL) mbufget();
+    mbufanch2 = mbufanch;
+    mbuflast2 = mbuflast;
+    mbufanch = NULL;
+    mbuflast = NULL;
+    mbufget();
+    dbmode = 1; 
   }
+
+  /* End of double buffering */
   if (iact!=2 && dbmode==1) {
+    mbufrel(0);
+    mbufanch = mbufanch2;
+    mbufrel(1);
     dbmode = 0;
-    if (bopt==0) {
-      for (i=0; i<pnt2; i++) free(bufs2[i]);
-      pnt2 = 0;
-    }
+    mbuferror = 0;
+    return;
   }
-  if (bopt==0) {
-    if (dbmode) {
-      if (pntf==0) {
-        lens[pnt-1] = hpnt-hbuff;
-        for (i=1; i<pnt2; i++) free(bufs2[i]);   
-        pntf = 1;
-        pnt2 = 1;
-        hbuff = bufs2[0];
-        hpnt = hbuff;
-        hend = hbuff+(buffsz-10L);
-      } else {
-        lens2[pnt2-1] = hpnt-hbuff;
-        for (i=1; i<pnt; i++) free(bufs[i]);   
-        pntf = 0;
-        pnt = 1;
-        hbuff = bufs[0];
-        hpnt = hbuff;
-        hend = hbuff+(buffsz-10L);
-      }
-    } else {
-      for (i=1; i<pnt; i++) {
-        free(bufs[i]);
-      }
-      pnt = 1;
-      hbuff = bufs[0];
-      hpnt = hbuff;
-      hend = hbuff+(buffsz-10L);
-    }
-    if (herr && bufs[0] && !dbmode) herr = 0;
-  } else hpnt = hbuff;
+
+  /* If double buffering, swap buffers */
+  if (dbmode) {
+    pmbuf = mbufanch;     /* Save pointer to background buffer */
+    pmbufl = mbuflast;
+    mbufanch = mbufanch2;
+    mbufrel(1);           /* Get rid of former foreground buffer */
+    mbufanch2 = pmbuf;    /* Set foreground to former background */
+    mbuflast2 = pmbufl; 
+  } 
+  else {
+    /* Not double buffering, so just free buffers */
+    mbufrel(1);
+  }
+  if (!dbmode) mbuferror = 0;        /* Reset error state on clear command */
 }
 
-/* Redraw based on contents of current buffers */
+/* Redraw based on contents of current buffers.  Items that persist from plot
+   to plot ARE NOT IN THE META BUFFER; these items are set in the hardware attribute
+   database and are queried by the backend. 
+
+   This routine is called from gxX (ie, a lower level of the backend rendering), 
+   and this routine calls back into gxX.  This is not, however, implemented as
+   true recursion -- events are disabled in gxX during this redraw, so addtional
+   levels of recursion are not allowed.  
 
-void gxhdrw (gaint dbflg) {
-short *poi,*pend;
-gaint cmd, i, cnt, flag, ii, siz;
-gaint lcolor,fflag,xyc=0;
-gadouble xlo,xhi,ylo,yhi,xpos,ypos,*xybuf=NULL;
+   If dbflg, draw from the background buffer.  Otherwise draw from the 
+   foreground buffer. */
+
+void gxhdrw (gaint dbflg, gaint pflg) {
+struct gxmbuf *pmbuf;
+float *buff;
+int *iii;
+gadouble r,s,x,y,w,h,ang;
+gadouble *xybuf;
+gaint ppp,cmd,op1,op2,op3,op4,op5,fflag,xyc=0,fn,sig;
+signed char *ch;
+char ccc,*uch;
 
   if (dbflg && !dbmode) {
     printf ("Logic error 0 in Redraw.  Contact Developer.\n");
     return;
   }
+ 
+  if (dbflg) pmbuf = mbufanch2;
+  else pmbuf = mbufanch; 
 
-  if (dbmode && pntf==1) {
-    lens2[pnt2-1] = hpnt-hbuff;
-    cnt = pnt2; flag = 1;
-    if (dbflg) {cnt = pnt; flag = 0;}
-  } else {
-    lens[pnt-1] = hpnt-hbuff;
-    cnt = pnt; flag = 0;
-    if (dbflg) {cnt = pnt2; flag = 1;}
-  }
-
-  gxsfrm ();
   fflag = 0;
+  xybuf = NULL;
 
-  for (ii=0; ii<cnt; ii++) {
-    if (flag) {
-      poi = bufs2[ii];
-      pend = poi + lens2[ii];
-    } else { 
-      poi = bufs[ii];
-      pend = poi + lens[ii];
-    } 
-    
-    while (poi<pend) {
+  while (pmbuf) {
+    ppp = 0;
+    while (ppp < pmbuf->used) {
 
       /* Get message type */
+ 
+      ch = (signed char *)(pmbuf->buff + ppp);
+      cmd = (gaint)(*ch);
+      if (cmd != 99) {
+        printf ("Metafile buffer is corrupted\n");
+        printf ("Unable to complete redraw and/or print operation\n");
+        return;
+      }
+      cmd = (gaint)(*(ch+1));
+      ppp++;
 
-      cmd = *poi; 
 
       /* Handle various message types */
       /* -9 is end of file.  Should not happen. */
@@ -567,120 +452,601 @@ gadouble xlo,xhi,ylo,yhi,xpos,ypos,*xybuf=NULL;
       /* -3 indicates new color.  One arg; color number.  */
   
       else if (cmd==-3) {
-        lcolor = *(poi+1);
-        gxdcol (lcolor);
-        poi += 2;
+        iii = (int *)(pmbuf->buff + ppp);
+        op1 = (gaint)(*iii);
+	if (pflg) 
+	  gxpcol (op1);          /* for printing */
+	else 
+	  gxdcol (op1);          /* for hardware */
+        ppp++;
       }
 
       /* -4 indicates new line thickness.  It has two arguments */
  
       else if (cmd==-4) {
-        i = *(poi+2);
-        gxdwid(i);
-        poi += 3;
+        iii = (int *)(pmbuf->buff + ppp);
+        op1 = (gaint)(*iii);
+	if (pflg)
+	  gxpwid (op1);          /* for printing */
+	else
+	  gxdwid (op1);          /* for hardware */
+        ppp += 2;
       }
 
-      /*  -5 defines a new color, in rgb.  It has four int args */
+      /*  -5 defines a new color, in rgb.  It has five int args */
 
       else if (cmd==-5){
-        gxdacl ((gaint)*(poi+1),(gaint)*(poi+2),(gaint)*(poi+3),(gaint)*(poi+4));
-        poi += 5;
+        iii = (int *)(pmbuf->buff + ppp);
+        op1 = (gaint)(*iii);
+        iii = (int *)(pmbuf->buff + ppp + 1);
+        op2 = (gaint)(*iii);
+        iii = (int *)(pmbuf->buff + ppp + 2);
+        op3 = (gaint)(*iii);
+        iii = (int *)(pmbuf->buff + ppp + 3);
+        op4 = (gaint)(*iii);
+        iii = (int *)(pmbuf->buff + ppp + 4);
+        op5 = (gaint)(*iii);
+        gxdbacol (op1,op2,op3,op4,op5);   /* update the data base */
+	if (pflg) 
+	  gxpacol (op1);                 /* for printing (no-op for cairo) */
+	else 
+	  gxdacol (op1,op2,op3,op4,op5); /* for hardware (no-op for cairo) */
+        ppp += 5;
       }
 
       /* -6 is for a filled rectangle.  It has four args. */ 
  
       else if (cmd==-6){
-        xycnv (*(poi+1),*(poi+3),&xlo,&ylo);
-        xycnv (*(poi+2),*(poi+4),&xhi,&yhi);
-        gxdrec(xlo,xhi,ylo,yhi);
-        poi += 5;
+        buff = pmbuf->buff + ppp;
+        r = (gadouble)(*buff);
+        s = (gadouble)(*(buff+1));
+        x = (gadouble)(*(buff+2));
+        y = (gadouble)(*(buff+3));
+	if (pflg) 
+	  gxprec(r,s,x,y);          /* for printing */
+	else
+	  gxdrec(r,s,x,y);          /* for hardware */
+        ppp += 4;
       }
 
-      /* -7 indicates the start of a polygon fill.  It has one arg. */
+      /* -7 indicates the start of a polygon fill.  It has one arg, 
+         the length of the polygon.  We allocate an array for the entire
+         polygon, so we can present it to the hardware backend in 
+         on piece. */
 
-      else if (cmd==-7){
-        siz = *(poi+1);
-        xybuf = (gadouble *)malloc(sizeof(gadouble)*siz*2);
+      else if (cmd==-7) {
+        iii = (int *)(pmbuf->buff + ppp);
+        op1 = (gaint)(*iii);
+        xybuf = (gadouble *)galloc(sizeof(gadouble)*op1*2,"gxybuf");
         if (xybuf==NULL) {
           printf ("Memory allocation error: Redraw\n");
           return;
         }
-        fflag = 1;
         xyc = 0;
-        poi += 2;
+        fflag = 1;
+        ppp += 1;
+	/* tell printing layer about new polygon. */
+	if (pflg) gxpbpoly();  
       }
 
       /* -8 is to terminate polygon fill.  It has no args */
 
-      else if (cmd==-8){
-        gxdfil (xybuf,xyc);
+      else if (cmd==-8) {
         if (xybuf==NULL) {
           printf ("Logic Error 16 in Redraw.  Notify Developer\n");
           return;
-        } else free (xybuf);
+        }
+	if (pflg) 
+	  gxpepoly (xybuf,xyc);  /* for printing */
+	else
+	  gxdfil (xybuf,xyc);    /* for hardware */
+        gree (xybuf,"gxybuf");
+        xybuf = NULL;
         fflag = 0;
-        poi += 1;
       }
 
       /* -10 is a move to instruction.  It has two double args */ 
 
-      else if (cmd==-10){
-        xycnv (*(poi+1),*(poi+2),&xpos,&ypos);
-        if (fflag) {
-          *(xybuf+xyc*2) = xpos;
-          *(xybuf+xyc*2+1) = ypos;
-          xyc++;
-        } else gxdmov(xpos,ypos);
-        poi += 3;
+      else if (cmd==-10) {
+        buff = pmbuf->buff + ppp;
+        x = (gadouble)(*buff);
+        y = (gadouble)(*(buff+1));
+	if (fflag) {
+	  xybuf[xyc*2] = x;
+	  xybuf[xyc*2+1] = y;
+	  xyc++;
+	}
+	if (pflg) 
+	  gxpmov(x,y);            /* for printing */
+	else         
+	  gxdmov(x,y);            /* for hardware */
+        ppp += 2;
       }
 
       /*  -11 is draw to.  It has two double args. */  
         
-      else if (cmd==-11){
-        xycnv (*(poi+1),*(poi+2),&xpos,&ypos);
-        if (fflag) {
-          xybuf[xyc*2] = xpos;
-          xybuf[xyc*2+1] = ypos;
-          xyc++;
-        } else gxddrw(xpos,ypos);
-        poi += 3;
+      else if (cmd==-11) {
+        buff = pmbuf->buff + ppp;
+        x = (gadouble)(*buff);
+        y = (gadouble)(*(buff+1));
+	if (fflag) {
+	  xybuf[xyc*2] = x;
+	  xybuf[xyc*2+1] = y;
+	  xyc++;
+	}
+	if (pflg) 
+	  gxpdrw(x,y);            /* for printing */
+	else 
+	  gxddrw(x,y);            /* for hardware */
+        ppp += 2;
       }
-
+      
       /* -12 indicates new fill pattern.  It has three arguments. */
  
       else if (cmd==-12) {
-        gxdptn ((gaint)*(poi+1),(gaint)*(poi+2),(gaint)*(poi+3));
-        poi += 4;
+	/* This is a no-op for cairo; X-based pattern drawing only JMA Check that this works?? */
+/* 	gxdptn ((gaint)*(poi+1),(gaint)*(poi+2),(gaint)*(poi+3));  */
+	if (pflg) gxpflush(); 
+        ppp += 3;
       }
 
       /* -20 is a draw widget.  We will redraw it in current state. */
 
       else if (cmd==-20) {
-        gxdpbn ((gaint)*(poi+1),NULL,1,0,-1);
-        poi += 2;
+	/* This is a no-op for cairo; X-based widget drawing only JMA Check that this works?? */
+/* 	gxdpbn ((gaint)*(poi+1),NULL,1,0,-1);  */
+	if (pflg) gxpflush(); 
+        ppp += 1;
+      }
+
+      /* -21 is for drawing a single character in the indicated font and size */
+
+      else if (cmd==-21) {
+        ch = (signed char *)(pmbuf->buff + ppp - 1);
+        fn = (gaint)(*(ch+3));
+        uch = (char *)(pmbuf->buff + ppp - 1);
+        ccc = *(uch+2);
+        buff = pmbuf->buff + ppp;
+        x = (gadouble)(*buff);
+        y = (gadouble)(*(buff+1));
+        w = (gadouble)(*(buff+2));
+        h = (gadouble)(*(buff+3));
+        ang = (gadouble)(*(buff+4));
+	if (pflg) 
+	  r = gxpch (ccc,fn,x,y,w,h,ang);     /* print a character */
+	else 
+	  r = gxdch (ccc,fn,x,y,w,h,ang);     /* draw a character */
+        ppp += 5;
+      }
+
+      /* -22 is for a signal. It has one signed character argument */
+
+      else if (cmd==-22) {
+	ch = (signed char *)(pmbuf->buff + ppp - 1);
+	sig = (gaint)(*(ch+2));
+	if (pflg) 
+	  gxpsignal(sig); 
+	else 
+	  gxdsignal(sig);
+	ppp++;
+      }
+
+      /* -23 is for the clipping area. It has four args. */ 
+ 
+      else if (cmd==-23){
+        buff = pmbuf->buff + ppp;
+        r = (gadouble)(*buff);
+        s = (gadouble)(*(buff+1));
+        x = (gadouble)(*(buff+2));
+        y = (gadouble)(*(buff+3));
+	if (pflg) 
+	  gxpclip(r,s,x,y);          /* for printing */
+	else
+	  gxdclip(r,s,x,y);          /* for hardware */
+        ppp += 4;
       }
 
       /* Any other command would be invalid */
 
       else {
-        printf ("Logic Error 20 in Redraw.  Notify Developer\n");
+         printf ("Logic Error 20 in Redraw.  Notify Developer\n");
         return;
       }
+    } 
+    if (pmbuf == mbuflast) break;
+    pmbuf = pmbuf->fpmbuf;
+  }
+  /* tell hardware and printing layer we are finished */
+  if (pflg) gxpflush();  
+  gxdopt(4);
+}
+
+
+/* Allocate and chain another buffer area */
+
+gaint mbufget (void) {
+struct gxmbuf *pmbuf;
+
+  if (mbufanch==NULL) {
+    pmbuf = (struct gxmbuf *)galloc(sizeof(struct gxmbuf),"gxmbuf");  
+    if (pmbuf==NULL) return (1);
+    mbufanch = pmbuf;                  /* set the new buffer structure as the anchor */
+    mbuflast = pmbuf;                  /* ... and also as the last one */
+    pmbuf->buff = (float *)galloc(sizeof(float)*BWORKSZ,"mbufbuff");  /* allocate a buffer */
+    if (pmbuf->buff==NULL) return(1);
+    pmbuf->len = BWORKSZ;              /* set the buffer length */
+    pmbuf->used = 0;                   /* initialize the buffer as unused */
+    pmbuf->fpmbuf = NULL;              /* terminate the chain */
+  }
+  else {
+    if (mbuflast->fpmbuf==NULL) {      /* no more buffers in the chain */
+      pmbuf = (struct gxmbuf *)galloc(sizeof(struct gxmbuf),"gxmbuf");  
+      if (pmbuf==NULL) return (1);
+      mbuflast->fpmbuf = pmbuf;        /* add the new buffer structure to the chain */
+      mbuflast = pmbuf;                /* reset mbuflast to the newest buffer structure in the chain */
+      pmbuf->buff = (float *)galloc(sizeof(float)*BWORKSZ,"mbufbuff");  /* allocate a buffer */
+      if (pmbuf->buff==NULL) return(1);
+      pmbuf->len = BWORKSZ;            /* set the buffer length */
+      pmbuf->used = 0;                 /* initialize the buffer as unused */
+      pmbuf->fpmbuf = NULL;            /* terminate the chain */
+    }
+    else {                             /* we'll just re-use what's already been chained up */
+      pmbuf = mbuflast->fpmbuf;        /* get the next buffer in the chain */
+      pmbuf->used = 0;                 /* reset this buffer to unused */
+      mbuflast = pmbuf;                /* set mbuflast to point to this buffer */
     }
   }
+  return (0);
 }
 
-void xycnv (short ix, short iy, gadouble *x, gadouble *y) {
+/* Free buffer chain.  If flag is 1, leave the first buffer, 
+   if there is at least one buffer already chained.
+   If flag is zero, free all buffers.  */
+
+void mbufrel (gaint flag) {
+struct gxmbuf *pmbuf,*pmbuf2;
+gaint i;
+
+  i = flag;
+  pmbuf = mbufanch;                /* point at the anchor */
+  while (pmbuf) {
+    pmbuf2 = pmbuf->fpmbuf;        /* get next link in chain */
+    if (!i) {                      /* this part only gets executed when flag is 0 */
+      if (pmbuf->buff) gree (pmbuf->buff,"gxmbuf");
+      gree (pmbuf,"mbufbuff");     /* free the pmbuf link */
+      i = 0; 
+    }
+    pmbuf = pmbuf2;                /* move up the chain */
+  }
+  if (!flag) {
+    mbufanch = NULL;               /* no more metabuffer */
+  } 
+  else {
+    if (mbufanch) mbufanch->used = 0;
+  }
+  mbuflast = mbufanch;
+}
 
-  *x = ((gadouble)ix)/1000.0;
-  *y = ((gadouble)iy)/1000.0;
+void gxmbuferr() {
+  printf ("Error in gxmeta: Unable to allocate meta buffer\n");
+  printf ("                 Buffering for the current plot is disabled\n");
+  mbuferror = 1;
+  mbufrel(0);
+}
+
+/* The following should go into its own source file */
+
+/* Keep track of persistent settings for "device backend" attributes, such as 
+   settings for custom colors, line widths, fonts, patterns, etc.  This interface
+   provides routines to set the values and to query the values. 
+   If support is ever added for writing the meta buffer out to a file, 
+   the information here should be written to the beginning of the file.  */
+
+static gaint pdcred[16] = {  0,255,250,  0, 30,  0,240,230,240,160,160,  0,230,  0,130,170};
+static gaint pdcgre[16] = {  0,255, 60,220, 60,200,  0,220,130,  0,230,160,175,210,  0,170};
+static gaint pdcblu[16] = {  0,255, 60,  0,255,200,130, 50, 40,200, 50,255, 45,140,220,170};
+
+static gaint greys[16]  = {  0,255,215,140, 80,110,230,170,200, 50,155, 95,185,125, 65,177};
+
+static gadouble pdcwid[12] = {0.6, 0.8, 1.0, 1.25, 1.5, 1.75, 2.0, 2.2, 2.4, 2.6, 2.8, 3.0};
+
+/* basic colors.  legacy backends will only support the first 256 */
+static gaint reds[COLORMAX], greens[COLORMAX], blues[COLORMAX], alphas[COLORMAX];
+static gaint tilenum[COLORMAX];
+
+/* tile patterns.  these can include solid colors with transparency.  */
+static gaint ptypes[COLORMAX], pxsz[COLORMAX], pysz[COLORMAX];
+static gaint pfthick[COLORMAX],pfcols[COLORMAX],pbcols[COLORMAX];
+static char *pnames[COLORMAX];
+
+/* custom line widths.  */
+
+static gadouble widths[256];
+
+/* custom font info */
+
+static char *fontname[100];
+static char *fn_serif = "serif";
+static char *fn_sans = "sans-serif";
+static char *fn_mono = "monospace";
+static gaint fnstatus[100];
+static gaint fnbold[100];
+static gaint fnitalic[100];
+static gaint hershflag;      /* For fn 1 to 6, use Hershey fonts or not */
+static gaint dbdevbck;       /* Device background color */
+static gaint dboutbck;       /* Ouput (image or hardcopy) background color */
+static gaint dbtransclr;     /* transparent color number (for hardcopy) */
+
+
+
+/* Initialize all the device backend persitent info on startup.
+   The "basic colors" (0 to 15) are pre-defined
+   Line widths (0 to 11) are also pre-defined. */
+
+void gxdbinit () {
+gaint i;
+
+  /* Initialize colors (default and user-defined) */
+  for (i=0; i<COLORMAX; i++) {
+    reds[i]   = 150; 
+    greens[i] = 150;
+    blues[i]  = 150;
+    alphas[i] = 255;
+    tilenum[i] = -999;
+    ptypes[i] = -999;
+    pnames[i] = NULL;
+    pxsz[i] = 10; 
+    pysz[i] = 10;
+    pfthick[i] = 3; 
+    pfcols[i] = -999; 
+    pbcols[i] = -999;
+  }
+  for (i=0; i<16; i++) {
+    reds[i]   = pdcred[i];
+    greens[i] = pdcgre[i];
+    blues[i]  = pdcblu[i];
+    alphas[i] = 255;
+  }
+
+  /* initialize line widths (default and user-defined) */
+  for (i=0; i<256; i++) widths[i] = 1.0; 
+  for (i=0; i<12; i++) widths[i] = pdcwid[i]; 
+
+  /* Initialize font settings */
+  for (i=0; i<100; i++) {
+    fontname[i] = NULL;
+    fnstatus[i] = 0;
+    fnbold[i] = 0;
+    fnitalic[i] = 0;
+  }
+
+  /* these will be for emulations of hershey fonts 0-5, but not 3 */
+  fontname[0] = fn_sans;   fnbold[0] = 0;  fnitalic[0] = 0; /* JMA set fnstatus for these? */
+  fontname[1] = fn_serif;  fnbold[1] = 0;  fnitalic[1] = 0;
+  fontname[2] = fn_mono;   fnbold[2] = 0;  fnitalic[2] = 1;
+  fontname[4] = fn_sans;   fnbold[4] = 1;  fnitalic[4] = 0;
+  fontname[5] = fn_serif;  fnbold[5] = 1;  fnitalic[5] = 0;
+
+  /* other flags for this and that */
+  hershflag  = 0;     /* zero, use hershey fonts.  1, use emulation. */  
+  dbdevbck   = 0;     /* initial device background color is black */
+  dboutbck   = -1;    /* initial output background color is 'undefined' */
+  dbtransclr = -1;    /* initial transparent color is 'undefined' */
+   
+}
+
+/* Set a font name for a font from 10 to 99.  
+   Use of a font number that has no defined font family name will be handled
+   by the device backend, usually by using a default sans-serif font. */
+
+void gxdbsetfn (gaint fn, char *str) {
+gaint len,i;
+char *newname;
+
+  if (fontname[fn]) {
+    /* this font number has been previously assigned. Reset and free memory */
+    free (fontname[fn]);
+    fontname[fn] = NULL;
+    fnstatus[fn] = 0;
+    fnbold[fn] = 0;
+    fnitalic[fn] = 0;
+  }
+  if (str) {
+    len = 0;
+    while (*(str+len)) len++;
+    newname = (char *)malloc(len+1);
+    if (newname==NULL) return;
+    for (i=0; i<len; i++) *(newname+i) = *(str+i);
+    *(newname+len) = '\0';
+    fontname[fn] = newname;
+    fnstatus[fn] = 0; 
+  }
+  /* No 'else' statement here ... we can allow a font name to be NULL */
+}
+
+/* Set the status of a font for a font from 10 to 99.
+   The status is 1 if the font file has been opened.  */
+
+void gxdbsetfnstatus (gaint fn, gaint status) {
+  if (fn>9 && fn<100) fnstatus[fn] = status;
+}
+
+
+/* Query font settings */
+
+void gxdbqfont (gaint fn, struct gxdbquery *pdbq) {
+  if (fn<0 || fn>99) {
+    pdbq->fname   = fontname[0];
+    pdbq->fstatus = fnstatus[0];
+    pdbq->fbold   = fnbold[0];
+    pdbq->fitalic = fnitalic[0];
+  } else {
+    pdbq->fname   = fontname[fn];
+    pdbq->fstatus = fnstatus[fn];
+    pdbq->fbold   = fnbold[fn];
+    pdbq->fitalic = fnitalic[fn];
+  }
+}
+
+/* Query a color */
+
+void gxdbqcol (gaint colr, struct gxdbquery *pdbq) {
+  if (colr<0 || colr>=COLORMAX) {
+    pdbq->red = 150;
+    pdbq->green = 150;
+    pdbq->blue = 150;
+    pdbq->alpha = 255;
+    pdbq->tile = -999;
+  } else {
+    pdbq->red = reds[colr];
+    pdbq->green = greens[colr];
+    pdbq->blue = blues[colr];
+    pdbq->alpha = alphas[colr];
+    pdbq->tile = tilenum[colr];
+  }
+}
+
+/* Define a new color */
+
+gaint gxdbacol (gaint clr, gaint red, gaint green, gaint blue, gaint alpha) {
+  if (clr<0 || clr>=COLORMAX ) return(1); 
+  if (red == -9) {
+    /* this is a pattern */
+    reds[clr] = red; 
+    greens[clr] = green; 
+    blues[clr] = blue;  
+    alphas[clr] = 255;
+    tilenum[clr] = green;
+  } else {
+    /* this is a color */
+    reds[clr] = red;
+    greens[clr] = green;
+    blues[clr] = blue;
+    alphas[clr] = alpha;
+    tilenum[clr] = -999;
+  }
+  return 0;
+}
+
+/* Query line width */
+
+void gxdbqwid (gaint lwid, struct gxdbquery *pdbq) {    
+  if (lwid<0 || lwid>255) pdbq->wid = 1.0; 
+  else pdbq->wid = widths[lwid];
+}
+
+/* Set line width */
+
+void gxdbsetwid (gaint lwid, gadouble val) {    
+  if (lwid>=1 && lwid<=256) {
+    if (val>0) widths[lwid-1] = val;
+  }
+}
+
+/* Set pattern settings */
+
+void gxdbsetpatt (gaint *itt, char *str) {    
+gaint pnum,len,i;
+char *newname;
+
+  pnum = *itt;
+  if (pnum<0 || pnum>=COLORMAX) return;
+  /* trigger a pattern reset in the hardware layer */
+  gxsetpatt(pnum);                        
+
+  if (pnames[pnum]) {
+    /* reset tile filename and free memory */
+    free (pnames[pnum]);
+    pnames[pnum] = NULL;
+  }
+
+  /* reset all elements */
+  ptypes[pnum]  = -999;
+  pxsz[pnum]    = -999; 
+  pysz[pnum]    = -999;
+  pfthick[pnum] = -999; 
+  pfcols[pnum]  = -999; 
+  pbcols[pnum]  = -999;
+
+  /* now populate data base entries with new values */
+  if (str) {
+    len = 0;
+    while (*(str+len)) len++;
+    newname = (char *)malloc(len+1);
+    if (newname==NULL) return;
+    for (i=0; i<len; i++) *(newname+i) = *(str+i);
+    *(newname+len) = '\0';
+    pnames[pnum] = newname;
+  }
+  if (*(itt+1) < -900) return;  ptypes[pnum]  = *(itt+1);
+  if (*(itt+2) < -900) return;  pxsz[pnum]    = *(itt+2);
+  if (*(itt+3) < -900) return;  pysz[pnum]    = *(itt+3);
+  if (*(itt+4) < -900) return;  pfthick[pnum] = *(itt+4);
+  if (*(itt+5) < -900) return;  pfcols[pnum]  = *(itt+5);
+  if (*(itt+6) < -900) return;  pbcols[pnum]  = *(itt+6);
+}
+
+/* Query pattern settings */
+
+void gxdbqpatt (gaint pnum, struct gxdbquery *pdbq) {    
+  if (pnum<0 || pnum>=COLORMAX) return;
+  pdbq->ptype = ptypes[pnum];
+  pdbq->pxs = pxsz[pnum];
+  if (pdbq->pxs < -900) pdbq->pxs = 9;
+  pdbq->pys = pysz[pnum];
+  if (pdbq->pys < -900) pdbq->pys = 9;
+  pdbq->pthick = pfthick[pnum];
+  if (pdbq->pthick < -900) pdbq->pthick = 3;
+  pdbq->pfcol = pfcols[pnum];
+  pdbq->pbcol = pbcols[pnum];
+  pdbq->fname = pnames[pnum];
+};
+
+/* Query hershey flag */
+
+gaint gxdbqhersh (void) {    
+  return (hershflag);
+}
+
+/* Set hershey flag */
+
+void gxdbsethersh (gaint flag) {    
+  if (flag==0 || flag==1) 
+    hershflag = flag;
+}
+
+/* Query transparent color (for image output) */
+
+gaint gxdbqtransclr (void) {   
+  return (dbtransclr);
+}
+
+/* Set transparent color (for image output) */
+
+void gxdbsettransclr (gaint clr) {   
+  dbtransclr = clr; 
+}
+
+/* Set device background color. */
+
+void gxdbck (gaint clr) {    
+  dbdevbck = clr;
+}
+
+/* Set output background color */
+
+void gxdboutbck (gaint clr) {    
+  dboutbck = clr;
+}
+
+/* Query background color */
+
+gaint gxdbkq  (void) {    
+  /* If the output background color is not set, return device background color */
+  if (dboutbck != -1) 
+    return (dboutbck);
+  else 
+    return (dbdevbck);
 }
 
-#if GXPNG==1
-#include "gxhpng.c"
-#endif
 
-#ifndef STNDALN
-#  define GXHEPS
-#  include "gxeps.c"
-#endif
diff --git a/src/gxprint.c b/src/gxprint.c
new file mode 100644
index 0000000..831cf3a
--- /dev/null
+++ b/src/gxprint.c
@@ -0,0 +1,114 @@
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
+    See file COPYRIGHT for more information.   */
+
+/* Routines to print the graphics with calls to the Cairo library, needs gxC.c */
+
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+#include <stdio.h>
+#include "gatypes.h"
+#include "gx.h"
+#include "gxC.h"
+
+
+/* local variables */
+static char pout[256];           
+static gadouble xsize,ysize;   
+static gaint rc=0;
+
+/* keep a local copy of real page size */
+
+void gxpbgn (gadouble xsz, gadouble ysz) {
+  xsize = xsz;
+  ysize = ysz;
+}
+
+/* Tell Cairo to initialize a surface for checking string lengths.
+   This is only called when in batch mode */
+
+void gxpinit (gadouble xsz, gadouble ysz) {
+  gxCbatch (xsz,ysz);
+}
+
+/* Tell Cairo to destroy the surface for checking string lengths. */
+
+void gxpend (void) {
+  gxCend ();
+}
+
+/* Render the hardcopy output. 
+
+    fnout -- output filename
+    xin,yin -- image sizes (-999 for non-image formats)
+    bwin -- background color
+    fmtflg -- output format 
+    bgImage, fgImage -- background/foreground image filenames
+    tcolor -- transparent color 
+*/
+gaint gxprint (char *fnout, gaint xin, gaint yin, gaint bwin, gaint fmtflg, 
+	       char *bgImage, char *fgImage, gaint tcolor, gadouble border) {
+
+  /* Make sure we don't try to print an unsupported format */
+  /* JMA figure out how to add gif and jpg */ 
+  if (fmtflg!=1 && fmtflg!=2 && fmtflg!=3 && fmtflg!=4 && fmtflg!=5) return (9);
+
+  if (tcolor != -1) gxdbsettransclr (tcolor);   /* tell graphics database about transparent color override */
+
+  /* initialize the output for vector graphics or image */
+  rc = gxChinit (xsize,ysize,xin,yin,bwin,fnout,fmtflg,bgImage,border);
+  if (rc) return (rc); 
+
+  /* draw the contents of the metabuffer */
+  gxhdrw (0,1);
+  if (rc) return (rc); 
+
+  /* finish up */
+  rc = gxChend (fnout,fmtflg,fgImage);
+
+  gxdbsettransclr (-1);    /* unset transparent color override */
+  return (rc);
+}
+
+void gxpcol (gaint col) {  /* new color */
+  gxCcol (col);
+}
+void gxpacol (gaint col) {  /* new color definition */
+  /* this is a no-op for cairo */
+}
+void gxpwid (gaint wid) {  /* new line thickness */
+  gxCwid (wid);
+}
+void gxprec (gadouble x1, gadouble x2, gadouble y1, gadouble y2) {  /* filled rectangle */ 
+  gxCrec (x1,x2,y1,y2);
+}
+void gxpbpoly (void) {  /* start a polygon fill */
+  gxCbfil(); 
+}
+gaint gxpepoly (gadouble *xybuf, gaint xyc) {  /* terminate a polygon fill */
+  gxCfil (xybuf,xyc);
+  return(0);
+}
+void gxpmov (gadouble xpos, gadouble ypos) {  /* move to */ 
+  gxCmov (xpos,ypos);
+}
+void gxpdrw (gadouble xpos, gadouble ypos) {  /* draw to */  
+  gxCdrw (xpos,ypos);
+}
+void gxpflush (void) { /* finish drawing */
+  gxCflush(1);
+}
+void gxpsignal (gaint sig) { 
+  if (sig==1) gxCflush(1);   /* finish drawing */
+  if (sig==2) gxCaa(0);      /* disable anti-aliasing */
+  if (sig==3) gxCaa(1);      /* enable anti-aliasing */
+}
+gadouble gxpch (char ch, gaint fn, gadouble x, gadouble y, gadouble w, gadouble h, gadouble rot) { /* draw character */
+  return (gxCch (ch, fn, x, y, w, h, rot));
+}
+gadouble gxpqchl (char ch, gaint fn, gadouble w) {  /* query character length */
+ return (gxCqchl (ch, fn, w)); 
+}
+void gxpclip (gadouble x1, gadouble x2, gadouble y1, gadouble y2) {  /* set clipping area */ 
+  gxCclip (x1,x2,y1,y2);
+}
diff --git a/src/gxprintGD.c b/src/gxprintGD.c
new file mode 100644
index 0000000..363a0a0
--- /dev/null
+++ b/src/gxprintGD.c
@@ -0,0 +1,97 @@
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
+    See file COPYRIGHT for more information.   */
+
+/* Routines to print the graphics with calls to the GD library, needs gxGD.c */
+
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+#include <stdio.h>
+#include "gatypes.h"
+#include "gxGD.h"
+#include "gx.h"
+
+/* local variables */
+static char pout[256];           
+static gadouble xrsize,yrsize;   
+static gaint rc=0;
+
+
+/* local copy of real page size */
+void gxpbgn (gadouble xsz, gadouble ysz) {
+  xrsize = xsz;
+  yrsize = ysz;
+}
+
+/* This is a no-op for the GD build */
+void gxpinit (gadouble xmx, gadouble ymx) {
+}
+
+/* render the image output with the GD library */
+gaint gxprint (char *fnout, gaint xin, gaint yin, gaint bwin, gaint fmtflg, 
+	       char *bgImage, char *fgImage, gaint tcolor, gadouble border) {
+
+  /* Make sure we don't try to print an unsupported format */
+  if (fmtflg!=5 && fmtflg!=6 && fmtflg!=7) return(9);
+
+  /* initialize the image output */
+  rc = gxGDinit(xrsize, yrsize, xin, yin, bwin, bgImage);
+  if (rc) return (rc);
+
+  /* draw the contents of the metabuffer */
+  gxhdrw (0,1);
+  if (rc) return (rc);
+
+  /* Add the foreground image */
+  if (*fgImage) rc = gxGDfgimg (fgImage);
+  if (rc) return (rc);
+
+  /* finish up */
+  rc = gxGDend (fnout, bgImage, fmtflg, tcolor);
+  return (rc);
+}
+
+void gxpcol (gaint col) {  /* new color */
+  gxGDcol (col);
+}
+void gxpacol (gaint col) {  /* new color definition */
+  gxGDacol (col);
+}
+void gxpwid (gaint wid) {  /* new line thickness */
+  gxGDwid (wid);
+}
+void gxprec (gadouble x1, gadouble x2, gadouble y1, gadouble y2) {  /* filled rectangle */ 
+  gxGDrec (x1,x2,y1,y2);
+}
+void gxpbpoly (void) {  /* start a polygon fill */
+  gxGDbpoly ();
+}
+gaint gxpepoly (gadouble *xybuf, gaint xyc) {  /* terminate a polygon fill */
+  rc = gxGDepoly(xybuf,xyc);
+  return (rc);
+}
+void gxpmov (gadouble xpos, gadouble ypos) {  /* move to */ 
+  gxGDmov (xpos,ypos);
+}
+void gxpdrw (gadouble xpos, gadouble ypos) {  /* draw to */  
+  gxGDdrw (xpos,ypos);
+}
+void gxpflush (void) { /* finish drawing */
+  gxGDflush();
+}
+void gxpsignal (gaint sig) { /* finish drawing */
+  if (sig==1) gxGDflush();
+}
+
+/* these are no-ops in this build */
+gadouble gxpch (char ch, gaint fn, gadouble x, gadouble y, gadouble w, gadouble h, gadouble rot) { 
+  return 0;
+}
+gadouble gxpqchl (char ch, gaint fn, gadouble w) {
+  return -999;
+}
+void gxpclip (gadouble x1, gadouble x2, gadouble y1, gadouble y2) {
+}
+void gxpend (void) {
+}
+
diff --git a/src/gxps.c b/src/gxps.c
deleted file mode 100644
index f21e61b..0000000
--- a/src/gxps.c
+++ /dev/null
@@ -1,635 +0,0 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
-    See file COPYRIGHT for more information.   */
-
-/* 
- * Include ./configure's header file
- */
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
-
-#include <stdio.h>
-#include <math.h>
-
-
-int help=0;
-void command_line_help(void) ;
-
-char *valprs (char *, float *);
-
-char buff[132];
-int pnt;
-FILE *infile;
-FILE *outfile;
-int rotflg;
-
-void mycln (char *, int *);
-void chout (char *, int);
-void chend (void);
-int nxtcmd (char *, char *);
-void blkbck (void);
-void xycnv (short, short, float *, float *);
-void xycnva4 (short, short, float *, float *);
-
-float grey[256],red[256],green[256],blue[256];
-
-/* These values should match the RGB values in gxX.c and gxhpng.c and the documentation */
-float reds[16]   = {1.0, 0.0, 0.98, 0.00, 0.12, 0.00, 0.94, 0.90, 0.94, 0.63, 0.63, 0.00, 0.90, 0.00, 0.51, 0.67};
-float greens[16] = {1.0, 0.0, 0.24, 0.86, 0.24, 0.78, 0.00, 0.86, 0.51, 0.00, 0.90, 0.63, 0.69, 0.82, 0.00, 0.67};
-float blues[16]  = {1.0, 0.0, 0.24, 0.00, 1.00, 0.78, 0.51, 0.19, 0.16, 0.78, 0.19, 1.00, 0.18, 0.55, 0.86, 0.67};
-float greys[16]  = {1.0, 0.0, 0.16, 0.46, 0.70, 0.58, 0.10, 0.34, 0.22, 0.82, 0.40, 0.64, 0.28, 0.52, 0.76, 0.50};
-
-char *lwdesc[12] = {" 0.001 w",
-                    " 0.006 w",
-                    " 0.009 w",
-                    " 0.012 w",
-                    " 0.015 w",
-                    " 0.018 w",
-                    " 0.021 w",
-                    " 0.024 w",
-                    " 0.027 w",
-                    " 0.030 w",
-                    " 0.033 w",
-                    " 0.036 w"};
-
-static int rflag, cflag, dflag;
-static float bwide;
-
-int main (int argc, char *argv[])  {
-short opts[4];
-int cmd, i, j;
-char ch[201];
-int len, cont, iflag, oflag;
-int lcolor=0,lwide,sflag=0,fflag=0,fcnt,ccnt,filflg=0,scnt=0,a4flag,bdflag;
-float xlo,xhi,ylo,yhi,xpos,ypos,xsiz,ysiz;
-char in[256],out[256],*ifi,*ofi,ctld[2];
-
-  /* Initialize */
-
-  ctld[0] = (char)4;
-  ctld[1] = '\n';
-  for (i=0; i<=255; i++) {
-    grey[i] = -999.0;
-    red[i] = -999.0;
-    green[i] = -999.0;
-    blue[i] = -999.0;
-  }
-  for (i=0; i<16; i++) {
-    grey[i] = greys[i];
-    red[i] = reds[i];
-    green[i] = greens[i];
-    blue[i] = blues[i];
-  }
-
-  /* Parse command line arguments */
-
-  i = 1;
-  iflag = 0; oflag = 0;
-  cflag = 0; rflag = 0; dflag = 1;
-  a4flag = 0;
-  bwide = 0.5;
-  bdflag=0;
-
-  ifi = NULL; ofi = NULL;
-  while (i<argc) {
-    if (*(argv[i])=='-' && *(argv[i]+1)=='h' && *(argv[i]+2)=='e' && *(argv[i]+3)=='l' && *(argv[i]+4)=='p' ) {
-      command_line_help();
-      return(0);
-    } else if (*(argv[i])=='-') {
-      j = 1;
-      while (*(argv[i]+j)) {
-        if (*(argv[i]+j)=='i') iflag = 1;
-        else if (*(argv[i]+j)=='o') oflag = 1;
-        else if (*(argv[i]+j)=='c') cflag = 1;
-        else if (*(argv[i]+j)=='r') rflag = 1;
-        else if (*(argv[i]+j)=='a') a4flag = 1;
-        else if (*(argv[i]+j)=='d') dflag = 0;
-        else if (*(argv[i]+j)=='b') bdflag = 1;
-        else printf ("Unknown flag %c; ignored.\n",*(argv[i]+j));
-        j++;
-      }
-    } else {
-      if (iflag) {ifi = argv[i]; iflag = 0;}
-      else if (oflag) {ofi = argv[i]; oflag = 0;}
-      else if (bdflag)  {
-        if (valprs(argv[i],&bwide)==NULL) {
-          printf ("Invalid border width\n");
-          bwide = 0.5;
-        }
-      }
-      else printf ("Unknown argument: %s.  Ignored.\n",argv[i]);
-    }
-    i++;
-  }
-  if (ifi==NULL) {
-    command_line_help();
-    nxtcmd (in,"Enter input file: ");
-    ifi = in;
-  }
-  if (ofi==NULL) {
-    nxtcmd (out,"Enter output file: ");
-    ofi = out;
-  }
-
-  if (rflag) {
-    grey[0] = greys[1]; grey[1] = greys[0];
-    red[0] = reds[1]; red[1] = reds[0];
-    green[0] = greens[1]; green[1] = greens[0];
-    blue[0] = blues[1]; blue[1] = blues[0];
-  }
-
-  /* Open files */
-
-  infile = fopen(ifi,"rb");
-  if (infile == NULL) {
-    printf ("Input file does not exist: \n");
-    printf ("  %s\n",ifi);
-    return(1);
-  }
-  outfile = fopen(ofi,"wb");
-  if (outfile==NULL) {
-    printf ("Error opening output file: \n");
-    printf ("  %s\n",ofi);
-    return(1);
-  }
-
-  /* Translate the file */
-
-  pnt = 0;
-  fcnt = 0;
-
-  ccnt=0; 
-  cont = 1;
-  while (cont) {
-    fread (opts , sizeof(short), 1, infile);
-    cmd = opts[0];
-    ccnt++;
-    /* End of plotting */
-
-    if (cmd==-9) {
-      cont = 0;
-      chend();
-      if (fflag) {fwrite ("showpage\n",1,9,outfile); fcnt++;}
-      if (dflag) fwrite (ctld,1,2,outfile);
-      printf ("Number of frames = %i\n",fcnt);
-      fclose (outfile);
-    }
-
-    /* Start of plotting */
-
-    else if (cmd==-1) {
-      fread ((char *)opts, sizeof(short), 2, infile);
-      fwrite("%!\n",1,3,outfile);
-      fwrite("initgraphics 1 setlinecap 1 setlinejoin\n",1,40,outfile);
-      fwrite("72 72 scale\n",1,12,outfile);
-      fwrite("/m {moveto} def\n",1,16,outfile);
-      fwrite("/d {lineto} def\n",1,16,outfile);
-      fwrite("/c {setrgbcolor} def\n",1,21,outfile);
-      fwrite("/g {setgray} def\n",1,17,outfile);
-      fwrite("/n {newpath} def\n",1,17,outfile);
-      fwrite("/w {setlinewidth} def\n",1,22,outfile);
-      fwrite("/s {stroke} def\n",1,16,outfile);
-      fwrite("/f {fill} def\n",1,14,outfile);
-      blkbck();
-      chout(" 0 w",4);
-      xsiz = opts[0];
-      ysiz = opts[1];
-      rotflg=0;
-      if (ysiz>xsiz) rotflg=1;
-      fflag = 1;
-      sflag = 0;
-    }
-
-    /* New Page */
-
-    else if (cmd==-2) {
-      if (sflag) {chout(" s",2); sflag=0;}
-      chend();
-      fwrite ("gsave showpage\n",1,15,outfile);
-      fcnt++;
-      fflag = 0;
-    }
-
-    /* Set color */
-
-    else if (cmd==-3) {
-      if (!fflag) {
-        chout(" grestore",9);
-        blkbck();
-      }
-      if (sflag) {chout(" s",2); sflag=0;}
-      fread ((char *)opts, sizeof(short), 1, infile);
-      lcolor = opts[0];
-      if (lcolor<0) lcolor=0;
-      if (lcolor>255) lcolor=255;
-      if (cflag) {
-        if (red[lcolor]<-900.0) lcolor=15;
-        snprintf(ch,200," %.5g %.5g %.5g c",red[lcolor],green[lcolor],blue[lcolor]);
-      } else {
-        if (lcolor>0) snprintf(ch,200," %.5g g",grey[1]);
-        else snprintf(ch,200," %.5g g",grey[0]);
-      }
-      mycln(ch,&len);
-      chout(ch,len);
-      fflag = 1;
-    }
-
-    /* Set line width */
-
-    else if (cmd==-4) {
-      if (!fflag) {
-        chout(" grestore",9);
-        blkbck();
-      }
-      if (sflag) {chout(" s",2); sflag=0;}
-      fread ((char *)opts, sizeof(short), 2, infile);
-      i = opts[0];
-      if (i>12) i=12;
-      if (i<1) i=1;
-      chout(lwdesc[i-1],8);
-      lwide = i;
-      fflag = 1;
-    }
-
-    /* Define new color (mapped into grey scale via green intensity) */
-
-    else if (cmd==-5){
-      fread ((char *)opts, sizeof(short), 4, infile);
-      i = opts[0];
-      if (i>15 && i<=255) {
-        if (cflag) {
-          red[i] = ((float)opts[1])/255.0;
-          green[i] = ((float)opts[2])/255.0;
-          blue[i] = ((float)opts[3])/255.0;
-          if (red[i]<0.0) red[i]=0.0;
-          if (red[i]>1.0) red[i]=1.0;
-          if (green[i]<0.0) green[i]=0.0;
-          if (green[i]>1.0) green[i]=1.0;
-          if (blue[i]<0.0) blue[i]=0.0;
-          if (blue[i]>1.0) blue[i]=1.0;
-        } else {
-          grey[i] = ((float)(opts[2]))/255.0;
-          if (grey[i]<0.0) grey[i]=0.0;
-          if (grey[i]>1.0) grey[i]=1.0;
-          grey[i] = 1.0 - grey[i];
-        }
-      }
-    }
-
-    /* Rectangle fill */
-
-    else if (cmd==-6){
-      if (!fflag) {
-        chout(" grestore",9);
-        blkbck();
-      }
-      if (sflag) {chout(" s",2); sflag=0;}
-      fread ((char *)opts, sizeof(short), 4, infile);
-
-      if(a4flag) {
-	xycnva4 (opts[0],opts[2],&xlo,&ylo);
-	xycnva4 (opts[1],opts[3],&xhi,&yhi);
-      } else { 
-	xycnv (opts[0],opts[2],&xlo,&ylo);
-	xycnv (opts[1],opts[3],&xhi,&yhi);
-      }
-
-      if (!cflag) {
-        if (grey[lcolor]<-100.0) snprintf(ch,200," %.5g g",grey[15]);
-        else snprintf(ch,200," %.5g g",grey[lcolor]);
-        mycln(ch,&len);
-        chout(ch,len);
-      }
-      chout(" n",2);
-      snprintf(ch,200," %.5g %.5g m",xlo,ylo);
-      mycln(ch,&len);
-      chout(ch,len);
-      snprintf(ch,200," %.5g %.5g d",xhi,ylo);
-      mycln(ch,&len);
-      chout(ch,len);
-      snprintf(ch,200," %.5g %.5g d",xhi,yhi);
-      mycln(ch,&len);
-      chout(ch,len);
-      snprintf(ch,200," %.5g %.5g d",xlo,yhi);
-      mycln(ch,&len);
-      chout(ch,len);
-      snprintf(ch,200," %.5g %.5g d",xlo,ylo);
-      mycln(ch,&len);
-      chout(ch,len);
-      chout(" f",2);
-      if (!cflag) {
-        if (lcolor>0) snprintf(ch,200," %.5g g",grey[1]);
-        else snprintf(ch,200," %.5g g",grey[0]);
-        mycln(ch,&len);
-        chout(ch,len);
-      }
-      fflag = 1;
-    }
-
-    /* Start fill */
-
-    else if (cmd==-7){
-      fread ((char *)opts, sizeof(short), 1, infile);
-      if (!cflag) {
-        if (grey[lcolor]<-100.0) snprintf(ch,200," %.5g g",grey[15]);
-        else snprintf(ch,200," %.5g g",grey[lcolor]);
-        mycln(ch,&len);
-        chout(ch,len);
-      }
-      filflg = 1;
-      fflag = 1;
-    }
-
-    /* End fill */
-
-    else if (cmd==-8){
-      if (sflag) {chout(" f",2); sflag=0;}
-      if (!cflag) {
-        if (lcolor>0) snprintf(ch,200," %.5g g",grey[1]);
-        else snprintf(ch,200," %.5g g",grey[0]);
-        mycln(ch,&len);
-        chout(ch,len);
-      }
-      filflg = 0;
-      fflag = 1;
-    }
-
-    /* Move to */
-
-    else if (cmd==-10){
-      if (!fflag) {
-        chout(" grestore",9);
-        blkbck();
-      }
-      if (sflag) {chout(" s",2); sflag=0; scnt = 0;}
-      fread ((char *)opts, sizeof(short), 2, infile);
-      if(a4flag) {
-	xycnva4 (opts[0],opts[1],&xpos,&ypos);
-      } else { 
-	xycnv (opts[0],opts[1],&xpos,&ypos);
-      }
-
-      fflag = 1;
-    }
-
-    /* Draw to */
-
-    else if (cmd==-11){
-      if (!fflag) {
-        chout(" grestore",9);
-        blkbck();
-      }
-      fread (opts, sizeof(short), 2, infile);
-      if (!sflag) {
-        chout (" n",2);         
-        snprintf(ch,200," %.5g %.5g m",xpos,ypos);
-        mycln(ch,&len);
-        chout(ch,len);
-        scnt = 0;
-      }
-
-      if(a4flag) {
-	xycnva4 (opts[0],opts[1],&xpos,&ypos);
-      } else { 
-	xycnv (opts[0],opts[1],&xpos,&ypos);
-      }
-
-      if (scnt>511 && !filflg) {    /* Keep vector counts small */
-        snprintf(ch,200," %.5g %.5g d",xpos,ypos);
-        mycln(ch,&len);
-        chout(ch,len);
-        chout (" s n",4);
-        snprintf(ch,200," %.5g %.5g m",xpos,ypos);
-        mycln(ch,&len);
-        chout(ch,len);
-        scnt = 0;
-      }
-      snprintf(ch,200," %.5g %.5g d",xpos,ypos);
-      mycln(ch,&len);
-      chout(ch,len);
-      sflag = 1;
-      scnt++;
-      fflag = 1;
-    }
-    else if (cmd==-20) {       /* Draw button -- ignore */
-      fread ((char *)opts, sizeof(short), 1, infile);
-    }
-    else {
-      printf ("Invalid command found %i \n",cmd);
-      return(1);
-    }
-  }
-  return(0);
-}
-
-void blkbck () {
-  if (!rflag) return;
-  chout(" 0 0 0 c",8);
-  chout(" n 0 0 m 8.5 0 d",16);
-  chout(" 8.5 11 d",9);
-  chout(" 0 11 d",7);
-  chout(" 0 0 d f",8);
-}
-
-void mycln (char *ch, int *len) {
-int i,j,flag,cnt;
-  i = 0;
-  j = 0;
-  flag = 0;
-  cnt = 0;
-  while (ch[j]) {
-    ch[i] = ch[j];
-    if (flag) {
-      if (ch[j]<'0'||ch[j]>'9') {flag = 0; cnt=0;}
-      else cnt++;
-    }
-    if (ch[j]=='.') flag = 1;
-    if (flag&&cnt>3) j++;
-    else {i++; j++;}
-  }
-  *len = i;
-}
-
-void chout(char *ch, int len) {
-int i;
-
-  if (len+pnt>130) {
-    buff[pnt] = '\n';
-    pnt++;
-    fwrite (buff,1,pnt,outfile);
-    pnt = 0;
-  }
-  for (i=0; i<len; i++) {
-    buff[pnt] = *(ch+i);
-    pnt++;
-  }
-}
-
-void chend (void) {
-
-  buff[pnt] = '\n';
-  pnt++;
-  fwrite (buff,1,pnt,outfile);
-  pnt = 0;
-}
-
-int nxtcmd (char *cmd, char *prompt) {
-int past,cnt;
-
-  printf ("%s ",prompt);
-  past = 0;
-  cnt = 0;
-  while (1) {
-    *cmd = getchar();
-    if (*cmd == EOF) return (-1);
-    if (*cmd == '\n') {
-      *cmd = '\0';
-      return (cnt);
-    }
-    if (past || *cmd != ' ') {
-      cmd++; cnt++; past = 1;
-    }
-  }
-}
-
-void xycnv (short ix, short iy, float *x, float *y) {
-
-  if (rotflg) {
-    *x = ((float)ix)/1000.0;
-    *y = ((float)iy)/1000.0;
-  } else {
-    *x = 8.5 - ((float)iy)/1000.0;
-    *y = ((float)ix)*0.001;
-  }
-  *x = bwide + *x*((8.5-bwide*2.0)/8.5);
-  *y = bwide + *y*((11.0-bwide*2.0)/11.0);
-}
-
-/* To Mike
-     Now I finished the adjustment and test for A4 paper.
-                                              Thank you ! 
-                                    1995.10.19   H.Koide */
-
-void xycnva4 (short ix, short iy, float *x, float *y) {
-
-  if (rotflg) {
-    *x = ((float)ix)/1000.0;
-    *y = ((float)iy)/1025.6;
-  } else {
-    *x = 8.5 - ((float)iy)/1000.0;
-    *y = ((float)ix)/1025.6;
-  }
-  *x = bwide + *x*((8.5-bwide*2.0)/8.5);
-  *y = bwide + *y*((11.0-bwide*2.0)/11.0);
-}
-
-/* Parses a number in a character string.
-   This routine will detect numbers of the form:
-       nnnn
-       nnnn.fff
-       nnnn.fffExxx
-
-   Args:    ch     - pointer to the number, in character form.
-            val    - floating point value returned
-            return value  - address of 1st character past the
-                            number parsed.  NULL if no number found
-                            at pointer ch or if the number is an
-                            invalid format.
-             */
-
-char *valprs (char *ch, float *val) {
-
-int nflag,dflag,eflag,enflag,flag,cont;
-int pflag,epflag,evflag;
-float exp,dfp;
-int zip;
-
-  flag=0;
-  nflag=0;dflag=0;eflag=0;enflag=0;
-  pflag=0;epflag=0;evflag=0;
-  *val=0.0;exp=0.0;dfp=0.1;
-  zip='0';
-
-  cont=1;
-  while (cont) {
-
-    if (*ch>='0' && *ch<='9') {
-      if (!flag) flag=1;
-      if (eflag) {evflag=1; exp=(exp*10)+(*ch-zip);}
-      else if (dflag) { *val = *val+((*ch-zip)*dfp); dfp=dfp/10.0; }
-      else *val = (*val*10.0)+(*ch-zip);
-
-    } else if (*ch=='-') {
-      if (eflag&&!evflag) {
-        if (enflag) {cont=0; flag=0;}
-        enflag=1;
-      }
-      else if (!flag) {
-        if (nflag) {cont=0; flag=0;}
-        nflag=1;
-      } else cont=0;
-
-    } else if (*ch=='+') {
-      if (eflag&&!evflag) {
-        if (epflag) {cont=0; flag=0;}
-        epflag=1;
-      }
-      else if (!flag) {
-        if (pflag) {cont=0; flag=0;}
-        pflag=1;
-      } else cont=0;
-
-    } else if (*ch=='.') {
-      if (dflag||eflag) {cont=0;}
-      else dflag=1;
-
-    } else if (*ch=='e') {
-      if (eflag) {
-        cont=0;
-        if (!evflag) flag=0;
-      }
-      else if (flag) {eflag=1; dflag=0;}
-      else cont=0;
-
-    } else cont=0;
-
-    if (cont) ch++;
-  }
-
-  if (flag) {
-    if (nflag) *val = *val*(-1.0);
-    if (eflag) {
-      if (enflag) exp = exp*(-1.0);
-      *val = *val*(pow(10.0,exp));
-    }
-    return (ch);
-  } else return (NULL);
-
-}
-
-
-
-void command_line_help(void) {
-/*--- 
-  output command line options 
----*/
-
-printf("gxps for GrADS Version " GRADS_VERSION "\n\n");
-printf("Convert GrADS meta files (from print command in grads) to postscript (level 1)\n\n");
-printf("Command line options: \n\n");
-printf("          -help   Just this help\n");
-printf("          -i      input GrADS meta file\n");
-printf("          -o      output postscript file\n");
-printf("          -c      color output (default is black and white)\n");
-printf("          -r      reverse background (typically black) default is white background\n");
-printf("          -b      border width in inches (default is 0.5)\n");
-printf("          -a      create ps suitable for A4 printers\n");
-printf("          -d      do NOT add ctrl-d to end of ps file (added for some HP printers, generally ignored)");
-printf("   Example:\n\n");
-printf("   gxps -b 0.10 -c -r -i myplot.gm -o myplot.ps\n\n");
-printf("   makes a color ps file with a black background and a border width plot of 0.10 inches\n\n");
-
-printf("\n");
-
-}
diff --git a/src/gxshad.c b/src/gxshad.c
index b403752..57a838d 100644
--- a/src/gxshad.c
+++ b/src/gxshad.c
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 /* Authored by B. Doty */
diff --git a/src/gxshad2.c b/src/gxshad2.c
index 3518121..1c7ec12 100644
--- a/src/gxshad2.c
+++ b/src/gxshad2.c
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 /* Authored by B. Doty  2010,2011 */
diff --git a/src/gxstrm.c b/src/gxstrm.c
index 900ffa0..d56f41c 100644
--- a/src/gxstrm.c
+++ b/src/gxstrm.c
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 /* Authored by B. Doty */
diff --git a/src/gxsubs.c b/src/gxsubs.c
index af7e842..8c0d671 100644
--- a/src/gxsubs.c
+++ b/src/gxsubs.c
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 /* Authored by B. Doty */
@@ -34,23 +33,21 @@ void gree();
    all the routines in the file.    */
 
 static char *datad = "/usr/local/lib/grads";
-static gadouble xsize, ysize;                /* Virtual size       */
-static gadouble rxsize, rysize;              /* Real size          */
+static gadouble xsize, ysize;                /* Virtual page size  */
+static gadouble rxsize, rysize;              /* Real page size     */
 static gaint lwflg;                          /* Reduce lw due vpage*/
 static gadouble clminx,clmaxx,clminy,clmaxy; /* Clipping region    */
 static gaint cflag;                          /* Clipping flag      */
 static gaint mflag;                          /* mask flag          */
 static gadouble dash[8];                     /* Linestyle pattern  */
 static gaint dnum,lstyle;                    /* Current linestyle  */
-static gaint color;                          /* Current color      */
+static gaint lcolor;                         /* Current color      */
 static gaint lwide;                          /* Current linewidth  */
 static gadouble oldx,oldy;                   /* Previous position  */
 static gaint bufmod;                         /* Buffering mode     */
 static gadouble xsave,ysave,alen,slen;       /* Linestyle constants*/
 static gaint jpen,dpnt;
-static gaint bcol;                           /* Background color   */
-static gaint intflg;                         /* Batch flag         */
-static gaint reds[256],grns[256],blus[256];  /* Save defined color info */
+static gaint intflg;                         /* Batch/Interactive flag    */
 static void (*fconv) (gadouble, gadouble, gadouble *, gadouble *);
                                              /* fconv points to proj rnt  */
 static void (*gconv) (gadouble, gadouble, gadouble *, gadouble *);
@@ -62,6 +59,8 @@ static gaint maskflg;                        /* mask flag; -999 no mask yet,
                                                 0 no mask used, 1 mask values set, -888 error  */
 static gaint masksize;                       /* Size of mask array */
 static gaint maskx;                          /* Size of a row in the array */
+static gaint bcol;                           /* background color */
+static gaint savcol;                         /* for color save/restore */
 
 /* For STNDALN, routines included are gxgnam and gxgsym */
 #ifndef STNDALN
@@ -70,46 +69,102 @@ static gaint maskx;                          /* Size of a row in the array */
 /* batch flag = 1, batch mode only (no graphics output) */
 
 void gxstrt (gadouble xmx, gadouble ymx, gaint batch, gaint hbufsz) {
-  gaint ii;
 
   printf ("GX Package Initialization: Size = %g %g \n",xmx,ymx);
   if (batch) printf ("Running in Batch mode\n");
-  intflg = !batch;
+  gxdbinit();                               /* Initialize the graphics data base */
+  intflg = !batch;                          /* Set batch/interactive flag */
   if (intflg) {
-    gxdbgn (xmx, ymx);
-    gxdcol (1);                             /* Initial device color    */
-    gxdwid (1);                             /* Initial line width      */
+    gxdbgn (xmx, ymx);                      /* Initialize graphics output */
+    gxdwid (3);                             /* Initial line width      */
   } else {
-    gxdbat ();
+    gxdbat ();                              /* Tell hardware layer we're in batch mode */
+    gxpinit (xmx, ymx);                     /* Tell printing layer to initialize batch mode surface */
   }
-  rxsize = xmx;  rysize = ymx;
+  gxpbgn (xmx, ymx);                        /* Tell printing layer about page size */
+  rxsize = xmx;                             /* Set local variables with real page size  */
+  rysize = ymx;
   clminx=0; clmaxx=xmx;                     /* Set clipping area       */
   clminy=0; clmaxy=ymx;
-  xsave=0.0; ysave=0.0; lstyle=0; lwide = 1;
+  xsave=0.0; ysave=0.0; 
+  lstyle=0; lwide = 3;
   oldx=0.0; oldy=0.0;
   fconv=NULL;                               /* No projection set up    */
   gconv=NULL;                               /* No grid scaling set up  */
   bconv=NULL;                               /* No back transform       */
-  gxscal (0.0,xmx,0.0,ymx,0.0,xmx,0.0,ymx); /* Linear scaling=inches*/
-  gxvpag (xmx,ymx,0.0,xmx,0.0,ymx);         /* Virtual page scaling */
   gxchii();                                 /* Init character plotting */
-  bufmod=0;
-  bcol = 0;                                 /* Background is black     */
-  for (ii=0; ii<=255; ii++) reds[ii]=-999;
+  bufmod=0;                                 /* double buffering is OFF */
   gxhnew(rxsize,rysize,hbufsz);             /* Init hardcopy buffering */
-  color = 1;
+  gxscal (0.0,xmx,0.0,ymx,0.0,xmx,0.0,ymx); /* Linear scaling=inches   */
+  gxvpag (xmx,ymx,0.0,xmx,0.0,ymx);         /* Virtual page scaling    */
   mask = NULL; maskflg = -999;              /* Don't allocate mask until first use */
+  gxcolr(1);                                /* Initial color is 1 (foreground) */
 }
 
 /* Terminate graphics output */
 
-void gxend (void){                     /* Return screen to normal */
-  gxhend();
+void gxend (void) {                         /* Return screen to normal */
   if (mask) free(mask);
-  if (intflg) gxdend();
-  printf ("GX package terminated \n");
+  if (intflg) 
+    gxdend();                               /* Close X11 window        */
+  else
+    gxpend ();                              /* Tell printing layer to destroy batch mode surface */
+  printf ("GX Package Terminated \n");
 }
 
+
+/* Send a signal to the rendering engine and the metabuffer. 
+   Signal values are: 
+     1 == Done with draw/display so finish rendering
+     2 == Disable anti-aliasing 
+     3 == Enable anti-aliasing 
+     4 == Cairo push
+     5 == Cairo pop and then paint
+*/
+void gxsignal (gaint sig) {
+  if (intflg) gxdsignal(sig);  /* tell the rendering layer about the signal */
+  hout1c(-22,sig);             /* put the signal in the metafile buffer */
+}
+
+
+/* Query the width of a character */
+gadouble gxqchl (char ch, gaint fn, gadouble w) {
+gadouble wid;
+
+  /* cases where we want to use Hershey fonts */
+  if (fn==3) return (-999.9);                  /* symbol font */
+  if (fn>5 && fn<10) return (-999.9);          /* user-defined font file */
+  if (fn<6 && !gxdbqhersh()) return (-999.9);  /* font 0-5 and hershflag=0 in gxmeta.c */
+
+  if (intflg) 
+    wid = gxdqchl (ch, fn, w);                 /* get the character width (interactive mode) */
+  else 
+    wid = gxpqchl (ch, fn, w);                 /* get the character width (batch mode) */
+  return (wid);
+}
+
+/* Draw a character */
+gadouble gxdrawch (char ch, gaint fn, gadouble x, gadouble y, gadouble w, gadouble h, gadouble rot) {
+gadouble wid;
+
+  /* cases where we want to use Hershey fonts */ 
+  if (fn==3) return (-999.9);                  /* symbol font */
+  if (fn>5 && fn<10) return (-999.9);          /* user-defined font file */
+  if (fn<6 && !gxdbqhersh()) return (-999.9);  /* font 0-5 and hershflag=0 in gxmeta.c */
+
+  /* from here on we're using Cairo fonts */
+  gxvcon(x,y,&x,&y);                           /* scale the position and size for the virual page */
+  gxvcon2(w,h,&w,&h);
+  if (intflg) 
+    wid = gxdch (ch, fn, x, y, w, h, rot);     /* plot a character */
+  else 
+    wid = gxpqchl (ch, fn, w);                 /* get the character width (batch mode) */
+  houtch (ch, fn, x, y, w, h, rot);            /* put the character in the metabuffer */
+  gxppvp2(wid,&wid);                             /* rescale the character width back to real page size */
+  return (wid);                                /* return character width */
+}
+
+
 /* Frame action.  Values for action are:
       0 -- new frame (clear display), wait before clearing.
       1 -- new frame, no wait.
@@ -122,7 +177,6 @@ void gxend (void){                     /* Return screen to normal */
       9 -- clear only the X request buffer */
 
 void gxfrme (gaint action) {
-gaint scol,i;
 
   if (action>7) { 
     if (intflg) gxdfrm(action);
@@ -130,100 +184,73 @@ gaint scol,i;
   }
   gxmaskclear();
   if (intflg) {
-    if (action==0) getchar();              /* Wait if requested    */
-    if (action!=2&&bufmod) {
-      gxdsgl ();
+    if (action==0) getchar();        /* Wait if requested    */
+    if (action!=2 && bufmod) {
+      gxdsgl ();                     /* tell hardware to turn off double buffer mode */
       bufmod=0;
     }
-    if (action==2&&(!bufmod)) {
-      gxddbl ();
+    if (action==2 && (!bufmod)) {
+      gxddbl ();                     /* tell hardware to turn on double buffer mode */
       bufmod=1;
     }
-    if (bufmod) gxdswp ();
-    gxdfrm (action);
+    if (bufmod) gxdswp ();           /* swap */
+    gxdfrm (action);                 /* tell hardware layer about frame action */
+    gxdfrm (9);                      /* clear the X request buffer */
   }
-
-  gxhfrm (action);                         /* Reset meta buffer */
-
-  for (i=16; i<=255; i++) {
-    if (reds[i]>-1) hout4i(-5,i,reds[i],grns[i],blus[i]);
-  }
-  if (bcol>0) {
-    scol = color;
+  gxhfrm (action);                   /* reset metabuffer */
+  bcol = gxdbkq();
+  if (bcol>1) {
+    /* If background is not black/white, draw a full page rectangle and populate the metabuffer */
+    savcol = lcolor;
     gxcolr(bcol);
-    color = scol;
-    gxrecf (0.0, rxsize, 0.0, rysize);
-    if (intflg) gxdfrm (9);
+    gxrecf(0.0, rxsize, 0.0, rysize);
+    gxcolr(savcol);
   }
-
 }
 
-/* Perform new frame stuff for redraw.  This primarily involves
-   the background color. */
 
-void gxsfrm (void) {
-  if (bcol>0) {
-    gxdcol(bcol);
-    gxdrec (0.0, rxsize, 0.0, rysize);
-    gxdcol(color);
-  }
-}
-
-/* Set color.  Colors are: 0 - black;  1 - white
-                           2 - red;    3 - green;    4 - blue
-                           5 - cyan;   6 - magenta   7 - yellow
-                           8 - orange; 9 - purple;  10 - lt. green
-                          11 - m.blue 12 - d.yellow 13 - aqua
-			  14 - d.purple 15  - gray
-   Other colors may be available but are defined by the device
-   driver.   */
+/* Set color.  Colors are: 0 - black;    1 - white
+                           2 - red;      3 - green     4 - blue
+                           5 - cyan;     6 - magenta   7 - yellow
+                           8 - orange;   9 - purple   10 - lt. green
+                          11 - m.blue   12 - yellow   13 - aqua
+			  14 - d.purple 15 - gray
+   Other colors may be available but are defined by the device driver */
 
 void gxcolr (gaint clr){                 /* Set color     */
   if (clr<0) clr=0;
-  if (clr>255) clr=255; 
+  if (clr>=COLORMAX) clr=COLORMAX-1; 
   hout1(-3,clr);
   if (intflg) gxdcol (clr);
-  color = clr;
-}
-
-/* Set and query background color */
-
-void gxbckg (gaint col) {
-  bcol = col;
+  lcolor = clr;
 }
 
-gaint gxqbck (void) {
-  return(bcol);
-}
+/* define a new color */
 
-gaint gxacol (gaint clr, gaint red, gaint green, gaint blue ) {
-gaint rtn;
-  rtn=1;
-  hout4i(-5,clr,red,green,blue);
-  if (intflg) rtn = gxdacl (clr, red, green, blue);
-  if (clr>15 && clr<=255) {
-    reds[clr] = red;
-    grns[clr] = green;
-    blus[clr] = blue;
-  }
-  return rtn;
+gaint gxacol (gaint clr, gaint red, gaint green, gaint blue, gaint alpha ) {
+  gaint rc=0;
+  gxdbacol (clr, red, green, blue, alpha);                 /* update the database */
+  hout5i(-5,clr,red,green,blue,alpha);                     /* tell the metabuffer */
+  if (intflg) rc = gxdacol(clr, red, green, blue, alpha);  /* tell hardware */ 
+  return(rc);
 }
 
 
 /* Set line weight */
 
-void gxwide (gaint wid){                 /* Set width     */
+void gxwide (gaint wid) {                 /* Set width     */
 gaint hwid;
   hwid = wid;
-  if (lwflg) hwid = (wid+1)/2;
+  /* Reduce line width setting if we're working in a small virtual page */
+  /* Commented out by JMA -- we should leave line width settings completely up to the user */
+  /*   if (lwflg) hwid = (wid+1)/2;  */
   hout2i(-4,hwid,wid);
-  if (intflg) gxdwid (wid);
-  lwide = wid;
+  if (intflg) gxdwid (hwid);
+  lwide = hwid;
 }
 
-
 /* Move to x, y with 'clipping'.  Clipping is implmented
-   corsely, where any move or draw point that is outside the
+   coarsely, where any move or draw point that is outside the
    clip region is not plotted.                          */
 
 void gxmove (gadouble x, gadouble y) {        /* Move to x,y   */
@@ -242,7 +269,7 @@ void gxmove (gadouble x, gadouble y) {        /* Move to x,y   */
 
 /* Draw to x, y with clipping */
 
-void gxdraw (gadouble x, gadouble y){        /* Draw to x,y   */
+void gxdraw (gadouble x, gadouble y) {        /* Draw to x,y   */
 gadouble xnew,ynew;
 gaint pos=0;
   if ( x<clminx || x>clmaxx || y<clminy || y>clmaxy ) {
@@ -368,6 +395,7 @@ void gxstyl (gaint style) {              /* Set line style  */
   slen=dash[0]; jpen=2; dpnt=0;
 }
 
+
 /* Move and draw with linestyles and clipping */
 
 void gxplot (gadouble x, gadouble y, gaint ipen ) {    /* Move or draw  */
@@ -418,6 +446,9 @@ gadouble x1,y1;
 /* Specify software clip region.  */
 
 void gxclip (gadouble xmin, gadouble xmax, gadouble ymin, gadouble ymax) {
+gadouble clxmin,clxmax,clymin,clymax;
+
+  /* for software clipping */
   clminx = xmin;
   clmaxx = xmax;
   clminy = ymin;
@@ -426,6 +457,12 @@ void gxclip (gadouble xmin, gadouble xmax, gadouble ymin, gadouble ymax) {
   if (clmaxx>xsize) clmaxx = xsize;
   if (clminy<0.0) clminy = 0.0;
   if (clmaxy>ysize) clmaxy = ysize;
+
+  /* specify the hardware clip region, and put it in the metabuffer as well */
+  gxvcon(clminx,clminy,&clxmin,&clymin);
+  gxvcon(clmaxx,clmaxy,&clxmax,&clymax);
+  if (intflg) gxdclip(clxmin,clxmax,clymin,clymax);
+  hout4(-23,clxmin,clxmax,clymin,clymax); 
 }
 
 /* Constants for linear scaling */
@@ -446,43 +483,64 @@ void gxscal (gadouble xmin, gadouble xmax, gadouble ymin, gadouble ymax,
 
 static gadouble vxm,vxb,vym,vyb;
 
-/* Specify virtual page scaling */
+/* Specify virtual page scaling. 
+   Input args are as follows:
+     xmax,ymax == virtual page sizes
+     smin,smax == real page X-coordinates of virtual page
+     tmin,tmax == real page Y-coordinates of virtual page
+*/
 
 void gxvpag (gadouble xmax, gadouble ymax,
-             gadouble smin, gadouble smax, gadouble tmin, gadouble tmax){
+	     gadouble smin, gadouble smax, gadouble tmin, gadouble tmax){
 gadouble xmin, ymin;
+  /* set virtual page size */
   xmin = 0.0;
   ymin = 0.0;
-  xsize = xmax;
-  ysize = ymax;
+  xsize = xmax;  
+  ysize = ymax;  
+  /* check if virtual page coordinates extend beyond the real page size */
   if (smin<0.0) smin=0.0;
   if (smax>rxsize) smax = rxsize;
   if (tmin<0.0) tmin=0.0;
   if (tmax>rysize) tmax = rysize;
+  /* set clipping area to virtual page */
   clminx = 0.0;
   clmaxx = xmax;
   clminy = 0.0;
   clmaxy = ymax;
-  if ((smax-smin)/rxsize < 0.6 || (tmax-tmin)/rysize < 0.6) lwflg = 1;
+  /* if virtual page is small, set a flag to reduce line thickness */
+  if ((smax-smin)/rxsize < 0.49 || (tmax-tmin)/rysize < 0.49) lwflg = 1;
   else lwflg = 0;
+  /* set up constants for virtual page scaling */
   vxm=(smax-smin)/(xmax-xmin);
   vxb=smin-(vxm*xmin);
   vym=(tmax-tmin)/(ymax-ymin);
   vyb=tmin-(vym*ymin);
+  /* For non-software clipping ... put coordinates in the metabuffer and tell the hardware */
+  gxclip(clminx,clmaxx,clminy,clmaxy); 
 }
 
 /* Do virtual page scaling conversion */
 
-void gxvcon (gadouble s, gadouble t, gadouble *x, gadouble *y) {
+void gxvcon (gadouble s, gadouble t, gadouble *x, gadouble *y) {  /* positions, real->virtual */
   *x = s*vxm+vxb;
   *y = t*vym+vyb;
 }
+
+void gxvcon2 (gadouble s, gadouble t, gadouble *x, gadouble *y) {  /* characters, real->virtual */
+  *x = s*vxm;
+  *y = t*vym;
+}
  
-void gxppvp (gadouble x, gadouble y, gadouble *s, gadouble *t) {
+void gxppvp (gadouble x, gadouble y, gadouble *s, gadouble *t) {   /* positions, virtual->real */
   *s = (x-vxb)/vxm;
   *t = (y-vyb)/vym;
 }
 
+void gxppvp2 (gadouble x, gadouble *s) {  /* character width, virtual->real */
+  *s = (x)/vxm;
+}
+
 
 /* Specify projection-level scaling, typically used for map
    projections.  The address of the routine to perform the scaling
@@ -627,7 +685,9 @@ gadouble x;
   gxvcon (xlo,ylo,&xlo,&ylo);
   gxvcon (xhi,yhi,&xhi,&yhi);
   hout4(-6,xlo,xhi,ylo,yhi);
-  if (intflg) gxdrec (xlo, xhi, ylo, yhi);
+  if (intflg) {
+    gxdrec (xlo, xhi, ylo, yhi);
+  }
 }
 
 /* Define fill pattern for rectangles and polygons. */
@@ -646,18 +706,7 @@ gaint gxqwid (void) {
 /* query color */
 
 gaint gxqclr (void) {
-  return (color);
-}
-
-/* query non-default color rgb values*/
-
-void gxqrgb (gaint clr, gaint *r, gaint *g, gaint *b) {
-  if (clr>15 && clr<=255) {
-    *r = reds[clr];
-    *g = grns[clr];
-    *b = blus[clr];
-  } 
-  return;
+  return (lcolor);
 }
 
 /* query style */
@@ -749,12 +798,20 @@ gaint i,ii,cnt;
     gxdraw (x+siz2*0.71,y-siz2*0.71);
     return;
   }
-  if (mtype==7) {                      /* Open diamond */
+  if (mtype==7 || mtype==12) {   /* Open or closed diamond */
     gxmove (x-siz2*0.75,y);
     gxdraw (x,y+siz2*1.1);
     gxdraw (x+siz2*0.75,y);
     gxdraw (x,y-siz2*1.1);
     gxdraw (x-siz2*0.75,y);
+    if (mtype==12) {
+      xy[0] = x-siz2*0.75; xy[1]=y;
+      xy[2] = x; xy[3] = y+siz2*1.1;
+      xy[4] = x+siz2*0.75; xy[5] = y;
+      xy[6] = x; xy[7] = y-siz2*1.1;
+      xy[8] = x-siz2*0.75; xy[9] = y;
+      gxfill(xy,4);
+    }
     return;
   }
   if (mtype==8 || mtype==9) {          /* Triangles */
@@ -805,7 +862,6 @@ gadouble *r, *out, *buff, x, y, xybuff[40];
 gaint i,flag,onum,aflag;
 
   if (num<3) return;
-
   /* Do clipping.    */
 
   aflag = 0;
@@ -865,17 +921,17 @@ gaint i,flag,onum,aflag;
     r+=2;
   }
 
-  /* Output to meta buffer if requested.   */
+  /* Output to metabuffer */
 
-  hout1(-7,onum);
+  hout1(-7,onum);             /* start a polygon fill */
   r = buff;
-  hout2(-10,*r,*(r+1));
+  hout2(-10,*r,*(r+1));       /* move to first point in polygon */
   r+=2;
   for (i=1; i<onum; i++) {
-    hout2(-11,*r,*(r+1));
+    hout2(-11,*r,*(r+1));     /* draw to next point in polygon */
     r+=2;
   }
-  hout0(-8);
+  hout0(-8);                  /* terminate polygon */
 
   /* Output to hardware */
 
diff --git a/src/gxtran.c b/src/gxtran.c
deleted file mode 100644
index c642d88..0000000
--- a/src/gxtran.c
+++ /dev/null
@@ -1,312 +0,0 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
-    See file COPYRIGHT for more information.   */
-
-/* 
- * Include ./configure's header file
- */
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
-
-/* Note that a GrADS metafile is composed of messages, which themselves
-   are composed of from one to five short integers.  In each case, 
-   the first integer contains the message type, which also indicates
-   how many arguments (and what type of arguments) follow.  Note that
-   if the argument is in plot units, it needs to be divided by 1000
-   to get floating point units.  */
-
-#include <stdio.h>
-#include <math.h>
-#include "grads.h"
-#include "gx.h"
-
-struct gamfcmn mfcmn;
-
-int help=0;
-void command_line_help(void) ;
-
-char buff[132];
-int pnt;
-FILE *infile;
-
-int nxtcmd (char *, char *);
-void xyccc (short, short, float *, float *);
-int fflag;
-
-/*mf 980115 -- 
-  increase buffer from 1000 to 10000 - this is dynamically allocated in gxmeta
-  gxtran was seg faulting for plots with BIG polygon files
-mf*/
-
-double xybuf[10000];
-
-int main (int argc, char *argv[])  {
-
-short opts[4];
-int cmd,i,j,iflag,rflag,aflag,gflag,wflag,rc;
-int cont,xyc,lcolor,fflag,fcnt;
-float xlo,xhi,ylo,yhi,xpos,ypos,xsiz,ysiz;
-char in[100],*ifi;
-
-
-  /* Parse command line arguments */
-
-  i = 1;
-  iflag = 0; rflag = 0; aflag = 0; gflag = 0; wflag = 0; xyc = 0;
-  ifi = NULL;
-  while (i<argc) {
-    if (*(argv[i])=='-' && *(argv[i]+1)=='h' && *(argv[i]+2)=='e' && *(argv[i]+3)=='l' && *(argv[i]+4)=='p' ) {
-      command_line_help();
-      return(0);
-    } else if (*(argv[i])=='-') {
-      j = 1;
-      while (*(argv[i]+j)) {
-        if (*(argv[i]+j)=='i') iflag = 1;
-        else if (*(argv[i]+j)=='i') iflag = 1;
-        else if (*(argv[i]+j)=='r') rflag = 1;
-        else if (*(argv[i]+j)=='a') aflag = 1;
-        else if (*(argv[i]+j)=='g') gflag = 1;
-        else printf ("Unknown flag %c; ignored.\n",*(argv[i]+j));
-        j++;
-      }
-    } else {
-      if (iflag) {ifi = argv[i]; iflag = 0;}
-      else if (gflag) { gxdgeo(argv[i]); wflag = 1; gflag = 0; }
-      else printf ("Unknown argument: %s.  Ignored.\n",argv[i]);
-    }
-    i++;
-  }
-
-  if (ifi==NULL) {
-    command_line_help();
-    nxtcmd (in,"Enter input file: ");
-    ifi = in;
-  }
-
-  infile = fopen(ifi,"rb");
-  if (infile == NULL) {
-    printf ("Cannot open input file: %s\n",ifi);
-    return 1;
-  }
-
-  pnt = 0;
-  fcnt = 0;
-  fflag = 0;
-
-  cont = 1;
-  while (cont) {
-    
-    /* Read the 1st integer, which is the message type */
-
-    rc = fread (opts , sizeof(short), 1, infile);
-    if (rc != 1) {
-      printf ("Error on fread of message type\n");
-      return 1;
-    }
-    cmd = opts[0];
-
-    /* -9 indicates end of file.  Terminate graphics output.
-       It is followed by 0 arguments */
-
-    if (cmd==-9) {
-      cont = 0;
-      if (aflag) gxfrme(0);
-      gxend();
-    }
-
-    /*  -1 indicates start of file.  It is followed by two arguments,
-        which are the X and Y size of the virtual device in plotter
-        units */ 
-
-    else if (cmd==-1) {
-      fread ((char *)opts, sizeof(short), 2, infile);
-      xyccc (opts[0],opts[1],&xsiz,&ysiz);
-      gxstrt (xsiz,ysiz,0,1000000);  /* default buffer size */
-      if (rflag) gxdbck(1);          
-      if (wflag) gxfrme(1);
-      else gxfrme(0);
-      if (aflag) gxfrme(2);
-    }
-  
-    /* -2 indicates new frame.  It has no arguments */
-
-    else if (cmd==-2) {
-      gxfrme(9);
-      if (aflag) gxfrme(2);
-      else gxfrme(0);
-    }
-
-    /* -3 indicates new color.  It has one argument, a color number.
-       Colors 0 to 15 are predefined; colors 16 through 99 are 
-       allowed to be user defined (colors 100 through 255 are 
-       reserved for image use, a feature under development). */
-  
-    else if (cmd==-3) {
-      fread ((char *)opts, sizeof(short), 1, infile);
-      lcolor = opts[0];
-      gxcolr(lcolor);
-    }
-
-    /*  -4 indicates new line thickness.  It has one argument, 
-        where 1 indicates the thinnest line, 10 indicates a fairly
-        thick line.  Postscript Line thicknesses (used by gxps):
-  
-                    " 0.001 w",
-                    " 0.006 w",
-                    " 0.009 w",
-                    " 0.012 w",
-                    " 0.015 w",
-                    " 0.018 w",
-                    " 0.021 w",
-                    " 0.024 w",
-                    " 0.027 w",
-                    " 0.030 w",
-                    " 0.033 w",
-                    " 0.036 w"    
-
-         Line weights greater than 12 are just set to 0.036.  */
- 
-    else if (cmd==-4) {
-      fread ((char *)opts, sizeof(short), 2, infile);
-      i = opts[0];
-      gxwide(i);
-    }
-
-    /*  -5 defines a new color, in rgb.  it is followed by  four
-        args:  color number (16 to 99), then red, green, blue, 
-        each ranging from 0 to 255 */
-
-    else if (cmd==-5){
-      fread ((char *)opts, sizeof(short), 4, infile);
-      i = opts[0];
-      gxacol (i,opts[1],opts[2],opts[3]);
-    }
-
-    /*  -6 is for a filled rectangle.  It is followed by four args, 
-        each a plotting coordinate (divide by 1000 to get floating
-        point arg).  The coords are:  xlo, xhi, ylo, yhi */
- 
-    else if (cmd==-6){
-      fread ((char *)opts, sizeof(short), 4, infile);
-      xyccc (opts[0],opts[2],&xlo,&ylo);
-      xyccc (opts[1],opts[3],&xhi,&yhi);
-      gxrecf(xlo,xhi,ylo,yhi);
-    }
-
-    /* -7 indicates the start of a polygon fill.  It is followed
-       by the polygon outline, provided as move and draw instructions,
-       which are followed by the -8 command.  This command has
-       one arg, the length. */
-
-    else if (cmd==-7){
-      fread ((char *)opts, sizeof(short), 1, infile);
-      fflag = 1;
-      xyc = 0;
-    }
-
-    /*  -8 is to terminate polygon fill.  It has no args */
-
-    else if (cmd==-8){
-      gxfill (xybuf,xyc);
-      fflag = 0;
-    }
-
-    /* -10 is a move to instruction.  It is followed by two args, 
-       the X and Y position to move to, in plotting units.  If this
-       is between a -7 and a -8 command, then it is part of the 
-       polygon outline to be filled */
-
-    else if (cmd==-10){
-      fread ((char *)opts, sizeof(short), 2, infile);
-      xyccc (opts[0],opts[1],&xpos,&ypos);
-      if (fflag) {
-        xybuf[xyc*2] = xpos;
-        xybuf[xyc*2+1] = ypos;
-        xyc++;
-      } else gxplot(xpos,ypos,3);
-    }
-
-    /*  -11 is draw to.  It is followed by two instructions.  
-        If between a -7 and -8 instruction, it is part of a polygon
-        to be filled. */ 
-        
-    else if (cmd==-11){
-      fread ((char *)opts, sizeof(short), 2, infile);
-      xyccc (opts[0],opts[1],&xpos,&ypos);
-      if (fflag) {
-        xybuf[xyc*2] = xpos;
-        xybuf[xyc*2+1] = ypos;
-        xyc++;
-      } else {
-	gxplot(xpos,ypos,2);
-      }
-    }
-
-    else if (cmd==-20) {       /* Draw button -- ignore */
-      fread ((char *)opts, sizeof(short), 1, infile);
-    }
-
-    /* Any other command would be invalid */
-
-    else {
-      printf ("Invalid command found %i \n",cmd);
-      return 1;
-    }
-  }
-  return 0;
-}
-
-int nxtcmd (char *cmd, char *prompt) {
-int past,cnt;
-
-  printf ("%s ",prompt);
-  past = 0;
-  cnt = 0;
-  while (1) {
-    *cmd = getchar();
-    if (*cmd == EOF) return (-1);
-    if (*cmd == '\n') {
-      *cmd = '\0';
-      return (cnt);
-    }
-    if (past || *cmd != ' ') {
-      cmd++; cnt++; past = 1;
-    }
-  }
-}
-
-void xyccc (short ix, short iy, float *x, float *y) {
-
-  *x = ((float)ix)/1000.0;
-  *y = ((float)iy)/1000.0;
-}
-
-
-void command_line_help(void) {
-/*--- 
-  output command line options 
----*/
-
-printf("gxtran for GrADS Version " GRADS_VERSION "\n\n");
-printf("Display a GrADS meta file (from the \"print\" command in grads)\n\n");
-printf("Command line options: \n\n");
-printf("          -help   Just this help\n");
-printf("          -i      input GrADS meta file\n");
-printf("          -o      output postscript file\n");
-printf("          -r      reverse background (typically black) default is white background\n");
-printf("          -g LLLLxHHHH+(-)XXXX+(-)YYYY  set size of graphics window (like X windows)\n");
-printf("                LLLL -- length of box in pixels (x side)\n");
-printf("                HHHH -- height of box in pixels (y side)\n");
-printf("       + or -   XXXX -- starting pixel point in x (0,0 is upper lefthand corner)\n");
-printf("       + or -   YYYY -- starting pixel point in y\n");
-printf("          -a      \"animate\" by displaying all images as fast as possible\n");
-printf("   Example:\n\n");
-printf("   gxtran -r -i myplot.gm\n\n");
-printf("   displays the plot(s) in the GrADS meta file mplot.gm \n\n");
-
-}
-
-void gaprnt (int i, char *ch) {
-  printf ("%s",ch);
-}
diff --git a/src/gxwmap.c b/src/gxwmap.c
index 39927c2..9021d00 100644
--- a/src/gxwmap.c
+++ b/src/gxwmap.c
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 /* Authored by B. Doty */
@@ -30,6 +29,7 @@
 
 int gagby (char *, int, int);
 void gree();
+gaint dequal(gadouble, gadouble, gadouble);
 void *galloc(size_t,char *);
 
 static gaint imap;
@@ -43,7 +43,7 @@ static gaint adjtyp = 0;  /* Direction adjustment class */
 
 gaint gxwopen (char *, char *);
 gaint gxwread (char *, gaint);
-gaint gxwseek (gaint);
+void gxwseek (gaint);
 void gxwclose (gaint);
 
 struct mapcache {
@@ -164,6 +164,15 @@ char hdr[3],rec[1530];
     type = gagby(hdr,1,1);
     num = gagby(hdr,2,1);
 
+    /* The lowres map has only one type:
+         1 -- coastlines.
+       The mres and hires maps have three types:
+         0 -- coastlines
+	 1 -- political boundaries 
+	 2 -- US state boundaries
+    */
+
+
     /* Read the next record; convert the data points;
        and get the lat/lon bounds for this line segment */
 
@@ -1298,7 +1307,7 @@ char *cdat;
   return (i);
 }
 
-gaint gxwseek (gaint pos) {
+void gxwseek (gaint pos) {
   mcpos = pos;
 }
 
diff --git a/src/mtables.c b/src/mtables.c
deleted file mode 100644
index 5b43b00..0000000
--- a/src/mtables.c
+++ /dev/null
@@ -1,734 +0,0 @@
-
-/* 
- * Include ./configure's header file
- */
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
-
-#define costScale 1024
-int cost[] = {
-  1024,
-  1023,
-  1023,
-  1022,
-  1021,
-  1020,
-  1018,
-  1016,
-  1014,
-  1011,
-  1008,
-  1005,
-  1001,
-  997,
-  993,
-  989,
-  984,
-  979,
-  973,
-  968,
-  962,
-  955,
-  949,
-  942,
-  935,
-  928,
-  920,
-  912,
-  904,
-  895,
-  886,
-  877,
-  868,
-  858,
-  848,
-  838,
-  828,
-  817,
-  806,
-  795,
-  784,
-  772,
-  760,
-  748,
-  736,
-  724,
-  711,
-  698,
-  685,
-  671,
-  658,
-  644,
-  630,
-  616,
-  601,
-  587,
-  572,
-  557,
-  542,
-  527,
-  512,
-  496,
-  480,
-  464,
-  448,
-  432,
-  416,
-  400,
-  383,
-  366,
-  350,
-  333,
-  316,
-  299,
-  282,
-  265,
-  247,
-  230,
-  212,
-  195,
-  177,
-  160,
-  142,
-  124,
-  107,
-  89,
-  71,
-  53,
-  35,
-  17,
-  0,
-  -17,
-  -35,
-  -53,
-  -71,
-  -89,
-  -107,
-  -124,
-  -142,
-  -160,
-  -177,
-  -195,
-  -212,
-  -230,
-  -247,
-  -265,
-  -282,
-  -299,
-  -316,
-  -333,
-  -350,
-  -366,
-  -383,
-  -400,
-  -416,
-  -432,
-  -448,
-  -464,
-  -480,
-  -496,
-  -512,
-  -527,
-  -542,
-  -557,
-  -572,
-  -587,
-  -601,
-  -616,
-  -630,
-  -644,
-  -658,
-  -671,
-  -685,
-  -698,
-  -711,
-  -724,
-  -736,
-  -748,
-  -760,
-  -772,
-  -784,
-  -795,
-  -806,
-  -817,
-  -828,
-  -838,
-  -848,
-  -858,
-  -868,
-  -877,
-  -886,
-  -895,
-  -904,
-  -912,
-  -920,
-  -928,
-  -935,
-  -942,
-  -949,
-  -955,
-  -962,
-  -968,
-  -973,
-  -979,
-  -984,
-  -989,
-  -993,
-  -997,
-  -1001,
-  -1005,
-  -1008,
-  -1011,
-  -1014,
-  -1016,
-  -1018,
-  -1020,
-  -1021,
-  -1022,
-  -1023,
-  -1023,
-  -1024,
-  -1023,
-  -1023,
-  -1022,
-  -1021,
-  -1020,
-  -1018,
-  -1016,
-  -1014,
-  -1011,
-  -1008,
-  -1005,
-  -1001,
-  -997,
-  -993,
-  -989,
-  -984,
-  -979,
-  -973,
-  -968,
-  -962,
-  -955,
-  -949,
-  -942,
-  -935,
-  -928,
-  -920,
-  -912,
-  -904,
-  -895,
-  -886,
-  -877,
-  -868,
-  -858,
-  -848,
-  -838,
-  -828,
-  -817,
-  -806,
-  -795,
-  -784,
-  -772,
-  -760,
-  -748,
-  -736,
-  -724,
-  -711,
-  -698,
-  -685,
-  -671,
-  -658,
-  -644,
-  -630,
-  -616,
-  -601,
-  -587,
-  -572,
-  -557,
-  -542,
-  -527,
-  -512,
-  -496,
-  -480,
-  -464,
-  -448,
-  -432,
-  -416,
-  -400,
-  -383,
-  -366,
-  -350,
-  -333,
-  -316,
-  -299,
-  -282,
-  -265,
-  -247,
-  -230,
-  -212,
-  -195,
-  -177,
-  -160,
-  -142,
-  -124,
-  -107,
-  -89,
-  -71,
-  -53,
-  -35,
-  -17,
-  0,
-  17,
-  35,
-  53,
-  71,
-  89,
-  107,
-  124,
-  142,
-  160,
-  177,
-  195,
-  212,
-  230,
-  247,
-  265,
-  282,
-  299,
-  316,
-  333,
-  350,
-  366,
-  383,
-  400,
-  416,
-  432,
-  448,
-  464,
-  480,
-  496,
-  512,
-  527,
-  542,
-  557,
-  572,
-  587,
-  601,
-  616,
-  630,
-  644,
-  658,
-  671,
-  685,
-  698,
-  711,
-  724,
-  736,
-  748,
-  760,
-  772,
-  784,
-  795,
-  806,
-  817,
-  828,
-  838,
-  848,
-  858,
-  868,
-  877,
-  886,
-  895,
-  904,
-  912,
-  920,
-  928,
-  935,
-  942,
-  949,
-  955,
-  962,
-  968,
-  973,
-  979,
-  984,
-  989,
-  993,
-  997,
-  1001,
-  1005,
-  1008,
-  1011,
-  1014,
-  1016,
-  1018,
-  1020,
-  1021,
-  1022,
-  1023,
-  1023
-};
-#define sintScale 1024
-int sint[] = {
-  0,
-  17,
-  35,
-  53,
-  71,
-  89,
-  107,
-  124,
-  142,
-  160,
-  177,
-  195,
-  212,
-  230,
-  247,
-  265,
-  282,
-  299,
-  316,
-  333,
-  350,
-  366,
-  383,
-  400,
-  416,
-  432,
-  448,
-  464,
-  480,
-  496,
-  512,
-  527,
-  542,
-  557,
-  572,
-  587,
-  601,
-  616,
-  630,
-  644,
-  658,
-  671,
-  685,
-  698,
-  711,
-  724,
-  736,
-  748,
-  760,
-  772,
-  784,
-  795,
-  806,
-  817,
-  828,
-  838,
-  848,
-  858,
-  868,
-  877,
-  886,
-  895,
-  904,
-  912,
-  920,
-  928,
-  935,
-  942,
-  949,
-  955,
-  962,
-  968,
-  973,
-  979,
-  984,
-  989,
-  993,
-  997,
-  1001,
-  1005,
-  1008,
-  1011,
-  1014,
-  1016,
-  1018,
-  1020,
-  1021,
-  1022,
-  1023,
-  1023,
-  1024,
-  1023,
-  1023,
-  1022,
-  1021,
-  1020,
-  1018,
-  1016,
-  1014,
-  1011,
-  1008,
-  1005,
-  1001,
-  997,
-  993,
-  989,
-  984,
-  979,
-  973,
-  968,
-  962,
-  955,
-  949,
-  942,
-  935,
-  928,
-  920,
-  912,
-  904,
-  895,
-  886,
-  877,
-  868,
-  858,
-  848,
-  838,
-  828,
-  817,
-  806,
-  795,
-  784,
-  772,
-  760,
-  748,
-  736,
-  724,
-  711,
-  698,
-  685,
-  671,
-  658,
-  644,
-  630,
-  616,
-  601,
-  587,
-  572,
-  557,
-  542,
-  527,
-  512,
-  496,
-  480,
-  464,
-  448,
-  432,
-  416,
-  400,
-  383,
-  366,
-  350,
-  333,
-  316,
-  299,
-  282,
-  265,
-  247,
-  230,
-  212,
-  195,
-  177,
-  160,
-  142,
-  124,
-  107,
-  89,
-  71,
-  53,
-  35,
-  17,
-  0,
-  -17,
-  -35,
-  -53,
-  -71,
-  -89,
-  -107,
-  -124,
-  -142,
-  -160,
-  -177,
-  -195,
-  -212,
-  -230,
-  -247,
-  -265,
-  -282,
-  -299,
-  -316,
-  -333,
-  -350,
-  -366,
-  -383,
-  -400,
-  -416,
-  -432,
-  -448,
-  -464,
-  -480,
-  -496,
-  -512,
-  -527,
-  -542,
-  -557,
-  -572,
-  -587,
-  -601,
-  -616,
-  -630,
-  -644,
-  -658,
-  -671,
-  -685,
-  -698,
-  -711,
-  -724,
-  -736,
-  -748,
-  -760,
-  -772,
-  -784,
-  -795,
-  -806,
-  -817,
-  -828,
-  -838,
-  -848,
-  -858,
-  -868,
-  -877,
-  -886,
-  -895,
-  -904,
-  -912,
-  -920,
-  -928,
-  -935,
-  -942,
-  -949,
-  -955,
-  -962,
-  -968,
-  -973,
-  -979,
-  -984,
-  -989,
-  -993,
-  -997,
-  -1001,
-  -1005,
-  -1008,
-  -1011,
-  -1014,
-  -1016,
-  -1018,
-  -1020,
-  -1021,
-  -1022,
-  -1023,
-  -1023,
-  -1024,
-  -1023,
-  -1023,
-  -1022,
-  -1021,
-  -1020,
-  -1018,
-  -1016,
-  -1014,
-  -1011,
-  -1008,
-  -1005,
-  -1001,
-  -997,
-  -993,
-  -989,
-  -984,
-  -979,
-  -973,
-  -968,
-  -962,
-  -955,
-  -949,
-  -942,
-  -935,
-  -928,
-  -920,
-  -912,
-  -904,
-  -895,
-  -886,
-  -877,
-  -868,
-  -858,
-  -848,
-  -838,
-  -828,
-  -817,
-  -806,
-  -795,
-  -784,
-  -772,
-  -760,
-  -748,
-  -736,
-  -724,
-  -711,
-  -698,
-  -685,
-  -671,
-  -658,
-  -644,
-  -630,
-  -616,
-  -601,
-  -587,
-  -572,
-  -557,
-  -542,
-  -527,
-  -512,
-  -496,
-  -480,
-  -464,
-  -448,
-  -432,
-  -416,
-  -400,
-  -383,
-  -366,
-  -350,
-  -333,
-  -316,
-  -299,
-  -282,
-  -265,
-  -247,
-  -230,
-  -212,
-  -195,
-  -177,
-  -160,
-  -142,
-  -124,
-  -107,
-  -89,
-  -71,
-  -53,
-  -35,
-  -17
-};
diff --git a/src/stnmap.c b/src/stnmap.c
index 46c68d9..7359105 100644
--- a/src/stnmap.c
+++ b/src/stnmap.c
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 /* This program creates a station map file given the name of a control
@@ -391,7 +390,7 @@ gaint rc;
   rc = fseeko(dfile, fpos, 0);
   if (rc!=0) {
     printf ("  Low Level I/O Error:  Seek error on data file \n");
-    printf ("  Error occurred when seeking to byte %lld \n",fpos);
+    printf ("  Error occurred when seeking to byte %ld \n",fpos);
     printf ("  Possible cause:  Fewer times than expected\n");
     if (pfi->seqflg) printf ("  Possible cause:  Invalid sequential format\n");
     if (pfi->tmplat) printf("  File name = %s\n",fn);
@@ -405,7 +404,7 @@ gaint rc;
   rc = fread (rec, 1, siz, dfile);
   if (rc<siz) {
     printf ("  Low Level I/O Error:  Read error on data file \n");
-    printf ("  Error reading %i bytes at location %lld \n", siz, fpos);
+    printf ("  Error reading %i bytes at location %ld \n", siz, fpos);
     printf ("  Possible cause: Premature EOF\n");
     if (pfi->seqflg) printf ("  Possible cause: Invalid sequential data\n");
     if (pfi->tmplat) printf("  File name = %s\n",fn);
diff --git a/src/wx.h b/src/wx.h
index 0de41a9..f4c3720 100644
--- a/src/wx.h
+++ b/src/wx.h
@@ -1,5 +1,4 @@
-/*  Copyright (C) 1988-2011 by Brian Doty and the 
-    Institute of Global Environment and Society (IGES).  
+/*  Copyright (C) 1988-2015 by the Institute of Global Environment and Society (IGES).  
     See file COPYRIGHT for more information.   */
 
 /*  Constants for generating wx symbols */

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/grads.git



More information about the debian-science-commits mailing list