<p><b>dwj07@fsu.edu</b> 2013-03-22 13:32:26 -0600 (Fri, 22 Mar 2013)</p><p><br>
        -- TRUNK COMMIT --<br>
<br>
        Merging xml_registry branch to trunk.<br>
<br>
        Merges from the trunk need to account for the change in Registry now.<br>
</p><hr noshade><pre><font color="gray">Index: trunk/mpas
===================================================================
--- trunk/mpas        2013-03-22 17:48:50 UTC (rev 2662)
+++ trunk/mpas        2013-03-22 19:32:26 UTC (rev 2663)
Property changes on: trunk/mpas
___________________________________________________________________
Modified: svn:mergeinfo
## -33,3 +33,4 ##
 /branches/scratch_indication:2555-2656
 /branches/source_renaming:1082-1113
 /branches/time_manager:924-962
+/branches/xml_registry:2610-2662
\ No newline at end of property
Modified: trunk/mpas/src/Makefile
===================================================================
--- trunk/mpas/src/Makefile        2013-03-22 17:48:50 UTC (rev 2662)
+++ trunk/mpas/src/Makefile        2013-03-22 19:32:26 UTC (rev 2663)
@@ -10,7 +10,6 @@
 
 all: mpas
 
-
 mpas: reg_includes externals frame ops dycore drver
         $(LINKER) $(LDFLAGS) -o $(CORE)_model.exe driver/*.o -L. -ldycore -lops -lframework $(LIBS) -I./external/esmf_time_f90 -L./external/esmf_time_f90 -lesmf_time
 
@@ -23,7 +22,7 @@
 
 reg_includes: 
         ( cd registry; $(MAKE) CC="$(SCC)" )
-        ( cd inc; $(CPP) ../core_$(CORE)/Registry | ../registry/parse > Registry.processed)
+        ( cd inc; $(CPP) ../core_$(CORE)/Registry.xml | ../registry/parse > Registry.processed)
 
 frame: reg_includes externals
         ( cd framework; $(MAKE) CPPFLAGS="$(CPPFLAGS)" CPPINCLUDES="$(CPPINCLUDES)" all ) 
Copied: trunk/mpas/src/core_hyd_atmos/Registry.xml (from rev 2662, branches/xml_registry/src/core_hyd_atmos/Registry.xml)
===================================================================
--- trunk/mpas/src/core_hyd_atmos/Registry.xml                                (rev 0)
+++ trunk/mpas/src/core_hyd_atmos/Registry.xml        2013-03-22 19:32:26 UTC (rev 2663)
@@ -0,0 +1,179 @@
+<?xml version="1.0"?>
+<registry>
+        <dims>
+                <dim name="nCells"/>
+                <dim name="nEdges"/>
+                <dim name="maxEdges"/>
+                <dim name="maxEdges2"/>
+                <dim name="nVertices"/>
+                <dim name="TWO"                definition="2"/>
+                <dim name="vertexDegree"/>
+                <dim name="FIFTEEN"            definition="15"/>
+                <dim name="TWENTYONE"          definition="21"/>
+                <dim name="R3"                 definition="3"/>
+                <dim name="nVertLevels"        definition="namelist:config_nvertlevels"/>
+                <dim name="nVertLevelsP1"      definition="nVertLevels+1"/>
+        </dims>
+        <nml_record name="sw_model">
+                <nml_option name="config_test_case"                  type="integer"       default_value="5"/>
+                <nml_option name="config_time_integration"           type="character"     default_value="SRK3"/>
+                <nml_option name="config_dt"                         type="real"          default_value="172.8"/>
+                <nml_option name="config_calendar_type"              type="character"     default_value="360day"/>
+                <nml_option name="config_start_time"                 type="character"     default_value="0000-01-01_00:00:00"/>
+                <nml_option name="config_stop_time"                  type="character"     default_value="none"/>
+                <nml_option name="config_run_duration"               type="character"     default_value="none"/>
+                <nml_option name="config_h_mom_eddy_visc2"           type="real"          default_value="0.0"/>
+                <nml_option name="config_h_mom_eddy_visc4"           type="real"          default_value="0.0"/>
+                <nml_option name="config_v_mom_eddy_visc2"           type="real"          default_value="0.0"/>
+                <nml_option name="config_h_theta_eddy_visc2"         type="real"          default_value="0.0"/>
+                <nml_option name="config_h_theta_eddy_visc4"         type="real"          default_value="0.0"/>
+                <nml_option name="config_v_theta_eddy_visc2"         type="real"          default_value="0.0"/>
+                <nml_option name="config_number_of_sub_steps"        type="integer"       default_value="4"/>
+                <nml_option name="config_theta_adv_order"            type="integer"       default_value="2"/>
+                <nml_option name="config_scalar_adv_order"           type="integer"       default_value="2"/>
+                <nml_option name="config_positive_definite"          type="logical"       default_value="false"/>
+                <nml_option name="config_monotonic"                  type="logical"       default_value="true"/>
+                <nml_option name="config_mp_physics"                 type="integer"       default_value="0"/>
+                <nml_option name="config_apvm_upwinding"             type="real"          default_value="0.5"/>
+                <nml_option name="config_num_halos"                  type="integer"       default_value="2"/>
+        </nml_record>
+        <nml_record name="dimensions">
+                <nml_option name="config_nvertlevels"                type="integer"       default_value="26"/>
+        </nml_record>
+        <nml_record name="io">
+                <nml_option name="config_input_name"                 type="character"     default_value="grid.nc"/>
+                <nml_option name="config_output_name"                type="character"     default_value="output.nc"/>
+                <nml_option name="config_restart_name"               type="character"     default_value="restart.nc"/>
+                <nml_option name="config_output_interval"            type="character"     default_value="06:00:00"/>
+                <nml_option name="config_frames_per_outfile"         type="integer"       default_value="0"/>
+                <nml_option name="config_pio_num_iotasks"            type="integer"       default_value="0"/>
+                <nml_option name="config_pio_stride"                 type="integer"       default_value="1"/>
+        </nml_record>
+        <nml_record name="decomposition">
+                <nml_option name="config_block_decomp_file_prefix"   type="character"     default_value="graph.info.part."/>
+                <nml_option name="config_number_of_blocks"           type="integer"       default_value="0"/>
+                <nml_option name="config_explicit_proc_decomp"       type="logical"       default_value=".false."/>
+                <nml_option name="config_proc_decomp_file_prefix"    type="character"     default_value="graph.info.part."/>
+        </nml_record>
+        <nml_record name="restart">
+                <nml_option name="config_do_restart"                 type="logical"       default_value="false"/>
+                <nml_option name="config_restart_interval"           type="character"     default_value="none"/>
+        </nml_record>
+        <var_struct name="state" time_levs="2">
+                <var_array name="scalars" type="real" dimensions="nVertLevels nCells Time">
+                        <var name="qv"                 array_group="moist"       streams="iro"/>
+                        <var name="qc"                 array_group="moist"       streams="iro"/>
+                        <var name="qr"                 array_group="moist"       streams="iro"/>
+                </var_array>
+                <var name="xtime"                             type="text"     dimensions="Time"                        streams="ro"/>
+                <var name="u"                                 type="real"     dimensions="nVertLevels nEdges Time"     streams="iro"/>
+                <var name="theta"                             type="real"     dimensions="nVertLevels nCells Time"     streams="iro"/>
+                <var name="surface_pressure"                  type="real"     dimensions="nCells Time"                 streams="iro"/>
+                <var name="h"                                 type="real"     dimensions="nVertLevels nCells Time"     streams="ro"/>
+                <var name="ww"                                type="real"     dimensions="nVertLevelsP1 nCells Time"   streams="ro"/>
+                <var name="w"                                 type="real"     dimensions="nVertLevelsP1 nCells Time"   streams="ro"/>
+                <var name="pressure"                          type="real"     dimensions="nVertLevelsP1 nCells Time"   streams="ro"/>
+                <var name="geopotential"                      type="real"     dimensions="nVertLevelsP1 nCells Time"   streams="ro"/>
+                <var name="alpha"                             type="real"     dimensions="nVertLevels nCells Time"     streams="iro"/>
+                <var name="v"                                 type="real"     dimensions="nVertLevels nEdges Time"     streams="o"/>
+                <var name="divergence"                        type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="vorticity"                         type="real"     dimensions="nVertLevels nVertices Time"  streams="o"/>
+                <var name="pv_edge"                           type="real"     dimensions="nVertLevels nEdges Time"     streams="o"/>
+                <var name="h_edge"                            type="real"     dimensions="nVertLevels nEdges Time"     streams="o"/>
+                <var name="ke"                                type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="pv_vertex"                         type="real"     dimensions="nVertLevels nVertices Time"  streams="o"/>
+                <var name="pv_cell"                           type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="vh"                                type="real"     dimensions="nVertLevels nEdges Time"/>
+                <var name="circulation"                       type="real"     dimensions="nVertLevels nVertices Time"/>
+                <var name="gradPVt"                           type="real"     dimensions="nVertLevels nEdges Time"/>
+                <var name="gradPVn"                           type="real"     dimensions="nVertLevels nEdges Time"/>
+        </var_struct>
+        <var_struct name="mesh" time_levs="0">
+                <var_array name="scalars_old" type="real" dimensions="nVertLevels nCells">
+                        <var name="qv_old"             array_group="moist_old"/>
+                        <var name="qc_old"             array_group="moist_old"/>
+                        <var name="qr_old"             array_group="moist_old"/>
+                </var_array>
+                <var name="latCell"                           type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="lonCell"                           type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="xCell"                             type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="yCell"                             type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="zCell"                             type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="indexToCellID"                     type="integer"  dimensions="nCells"                      streams="iro"/>
+                <var name="latEdge"                           type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="lonEdge"                           type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="xEdge"                             type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="yEdge"                             type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="zEdge"                             type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="indexToEdgeID"                     type="integer"  dimensions="nEdges"                      streams="iro"/>
+                <var name="latVertex"                         type="real"     dimensions="nVertices"                   streams="iro"/>
+                <var name="lonVertex"                         type="real"     dimensions="nVertices"                   streams="iro"/>
+                <var name="xVertex"                           type="real"     dimensions="nVertices"                   streams="iro"/>
+                <var name="yVertex"                           type="real"     dimensions="nVertices"                   streams="iro"/>
+                <var name="zVertex"                           type="real"     dimensions="nVertices"                   streams="iro"/>
+                <var name="indexToVertexID"                   type="integer"  dimensions="nVertices"                   streams="iro"/>
+                <var name="cellsOnEdge"                       type="integer"  dimensions="TWO nEdges"                  streams="iro"/>
+                <var name="nEdgesOnCell"                      type="integer"  dimensions="nCells"                      streams="iro"/>
+                <var name="nEdgesOnEdge"                      type="integer"  dimensions="nEdges"                      streams="iro"/>
+                <var name="edgesOnCell"                       type="integer"  dimensions="maxEdges nCells"             streams="iro"/>
+                <var name="edgesOnEdge"                       type="integer"  dimensions="maxEdges2 nEdges"            streams="iro"/>
+                <var name="weightsOnEdge"                     type="real"     dimensions="maxEdges2 nEdges"            streams="iro"/>
+                <var name="dvEdge"                            type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="dcEdge"                            type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="angleEdge"                         type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="areaCell"                          type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="areaTriangle"                      type="real"     dimensions="nVertices"                   streams="iro"/>
+                <var name="edgeNormalVectors"                 type="real"     dimensions="R3 nEdges"                   streams="o"/>
+                <var name="localVerticalUnitVectors"          type="real"     dimensions="R3 nCells"                   streams="o"/>
+                <var name="cellTangentPlane"                  type="real"     dimensions="R3 TWO nCells"               streams="o"/>
+                <var name="cellsOnCell"                       type="integer"  dimensions="maxEdges nCells"             streams="iro"/>
+                <var name="verticesOnCell"                    type="integer"  dimensions="maxEdges nCells"             streams="iro"/>
+                <var name="verticesOnEdge"                    type="integer"  dimensions="TWO nEdges"                  streams="iro"/>
+                <var name="edgesOnVertex"                     type="integer"  dimensions="vertexDegree nVertices"      streams="iro"/>
+                <var name="cellsOnVertex"                     type="integer"  dimensions="vertexDegree nVertices"      streams="iro"/>
+                <var name="kiteAreasOnVertex"                 type="real"     dimensions="vertexDegree nVertices"      streams="iro"/>
+                <var name="fEdge"                             type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="fVertex"                           type="real"     dimensions="nVertices"                   streams="iro"/>
+                <var name="h_s"                               type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="rdnu"                              type="real"     dimensions="nVertLevels"                 streams="iro"/>
+                <var name="rdnw"                              type="real"     dimensions="nVertLevels"                 streams="iro"/>
+                <var name="fnm"                               type="real"     dimensions="nVertLevels"                 streams="iro"/>
+                <var name="fnp"                               type="real"     dimensions="nVertLevels"                 streams="iro"/>
+                <var name="dbn"                               type="real"     dimensions="nVertLevels"                 streams="iro"/>
+                <var name="dnu"                               type="real"     dimensions="nVertLevels"                 streams="iro"/>
+                <var name="dnw"                               type="real"     dimensions="nVertLevels"                 streams="iro"/>
+                <var name="uhAvg"                             type="real"     dimensions="nVertLevels nEdges"/>
+                <var name="wwAvg"                             type="real"     dimensions="nVertLevelsP1 nCells"/>
+                <var name="qtot"                              type="real"     dimensions="nVertLevels nCells"/>
+                <var name="cqu"                               type="real"     dimensions="nVertLevels nEdges"/>
+                <var name="h_diabatic"                        type="real"     dimensions="nVertLevels nCells"/>
+                <var name="dpsdt"                             type="real"     dimensions="nCells"/>
+                <var name="u_old"                             type="real"     dimensions="nVertLevels nEdges"/>
+                <var name="ww_old"                            type="real"     dimensions="nVertLevelsP1 nCells"/>
+                <var name="theta_old"                         type="real"     dimensions="nVertLevels nCells"/>
+                <var name="h_edge_old"                        type="real"     dimensions="nVertLevels nEdges"/>
+                <var name="h_old"                             type="real"     dimensions="nVertLevels nCells"/>
+                <var name="pressure_old"                      type="real"     dimensions="nVertLevelsP1 nCells"/>
+                <var name="deriv_two"                         type="real"     dimensions="FIFTEEN TWO nEdges"          streams="o"/>
+                <var name="advCells"                          type="integer"  dimensions="TWENTYONE nCells"/>
+                <var name="coeffs_reconstruct"                type="real"     dimensions="R3 maxEdges nCells"/>
+        </var_struct>
+        <var_struct name="diag" time_levs="1">
+                <var name="uReconstructX"                     type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="uReconstructY"                     type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="uReconstructZ"                     type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="uReconstructZonal"                 type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="uReconstructMeridional"            type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+        </var_struct>
+        <var_struct name="tend" time_levs="1">
+                <var_array name="scalars" type="real" dimensions="nVertLevels nCells Time">
+                        <var name="tend_qv"            array_group="moist"        name_in_code="qv"/>
+                        <var name="tend_qc"            array_group="moist"        name_in_code="qc"/>
+                        <var name="tend_qr"            array_group="moist"        name_in_code="qr"/>
+                </var_array>
+                <var name="tend_h"                            type="real"     dimensions="nVertLevels nCells Time"    name_in_code="h"/>
+                <var name="tend_u"                            type="real"     dimensions="nVertLevels nEdges Time"    name_in_code="u"/>
+                <var name="tend_vh"                           type="real"     dimensions="nVertLevels nEdges Time"    name_in_code="vh"/>
+                <var name="tend_theta"                        type="real"     dimensions="nVertLevels nCells Time"    name_in_code="theta"/>
+        </var_struct>
+</registry>
Copied: trunk/mpas/src/core_init_nhyd_atmos/Registry.xml (from rev 2662, branches/xml_registry/src/core_init_nhyd_atmos/Registry.xml)
===================================================================
--- trunk/mpas/src/core_init_nhyd_atmos/Registry.xml                                (rev 0)
+++ trunk/mpas/src/core_init_nhyd_atmos/Registry.xml        2013-03-22 19:32:26 UTC (rev 2663)
@@ -0,0 +1,279 @@
+<?xml version="1.0"?>
+<registry>
+
+<!-- **************************************************************************************** -->
+<!-- ************************************** Dimensions ************************************** -->
+<!-- **************************************************************************************** -->
+
+        <dims>
+                <dim name="nCells"/>
+                <dim name="nEdges"/>
+                <dim name="maxEdges"/>
+                <dim name="maxEdges2"/>
+                <dim name="nVertices"/>
+                <dim name="TWO"                definition="2"/>
+                <dim name="THREE"              definition="3"/>
+                <dim name="vertexDegree"/>
+                <dim name="FIFTEEN"            definition="15"/>
+                <dim name="TWENTYONE"          definition="21"/>
+                <dim name="R3"                 definition="3"/>
+                <dim name="nVertLevels"        definition="namelist:config_nvertlevels"/>
+                <dim name="nSoilLevels"        definition="namelist:config_nsoillevels"/>
+                <dim name="nFGLevels"          definition="namelist:config_nfglevels"/>
+                <dim name="nFGSoilLevels"      definition="namelist:config_nfgsoillevels"/>
+                <dim name="nVertLevelsP1"      definition="nVertLevels+1"/>
+                <dim name="nMonths"            definition="namelist:config_months"/>
+        </dims>
+
+
+<!-- **************************************************************************************** -->
+<!-- ************************************** Namelists *************************************** -->
+<!-- **************************************************************************************** -->
+
+        <nml_record name="nhyd_model">
+                <nml_option name="config_test_case"             type="integer"       default_value="7"/>
+                <nml_option name="config_calendar_type"         type="character"     default_value="gregorian"/>
+                <nml_option name="config_start_time"            type="character"     default_value="none"/>
+                <nml_option name="config_stop_time"             type="character"     default_value="none"/>
+                <nml_option name="config_theta_adv_order"       type="integer"       default_value="3"/>
+                <nml_option name="config_coef_3rd_order"        type="real"          default_value="0.25"/>
+                <nml_option name="config_num_halos"             type="integer"       default_value="2"/>
+        </nml_record>
+
+        <nml_record name="dcmip">
+                <nml_option name="config_dcmip_case"            type="character"     default_value="2-0-0"/>
+                <nml_option name="config_planet_scale"          type="real"          default_value="1.0"/>
+                <nml_option name="config_rotation_rate_scale"   type="real"          default_value="1.0"/>
+        </nml_record>
+
+        <nml_record name="dimensions">
+                <nml_option name="config_nvertlevels"           type="integer"       default_value="26"/>
+                <nml_option name="config_nsoillevels"           type="integer"       default_value="4"/>
+                <nml_option name="config_nfglevels"             type="integer"       default_value="27"/>
+                <nml_option name="config_nfgsoillevels"         type="integer"       default_value="4"/>
+                <nml_option name="config_months"                type="integer"       default_value="12"/>
+        </nml_record>
+
+        <nml_record name="data_sources">
+                <nml_option name="config_geog_data_path"        type="character"     default_value="/mmm/users/wrfhelp/WPS_GEOG/"/>
+                <nml_option name="config_met_prefix"            type="character"     default_value="FILE"/>
+                <nml_option name="config_sfc_prefix"            type="character"     default_value="FILE"/>
+                <nml_option name="config_fg_interval"           type="integer"       default_value="21600"/>
+        </nml_record>
+
+        <nml_record name="vertical_grid">
+                <nml_option name="config_ztop"                  type="real"          default_value="28000.0"/>
+                <nml_option name="config_nsmterrain"            type="integer"       default_value="2"/>
+                <nml_option name="config_smooth_surfaces"       type="logical"       default_value="false"/>
+        </nml_record>
+
+        <nml_record name="preproc_stages">
+                <nml_option name="config_static_interp"         type="logical"       default_value="true"/>
+                <nml_option name="config_vertical_grid"         type="logical"       default_value="true"/>
+                <nml_option name="config_met_interp"            type="logical"       default_value="true"/>
+                <nml_option name="config_input_sst"             type="logical"       default_value="false"/>
+                <nml_option name="config_frac_seaice"           type="logical"       default_value="false"/>
+        </nml_record>
+
+        <nml_record name="io">
+                <nml_option name="config_input_name"            type="character"     default_value="grid.nc"/>
+                <nml_option name="config_sfc_update_name"       type="character"     default_value="sfc_update.nc"/>
+                <nml_option name="config_output_name"           type="character"     default_value="init.nc"/>
+                <nml_option name="config_restart_name"          type="character"     default_value="restart.nc"/>
+                <nml_option name="config_frames_per_outfile"    type="integer"       default_value="0"/>
+                <nml_option name="config_pio_num_iotasks"       type="integer"       default_value="0"/>
+                <nml_option name="config_pio_stride"            type="integer"       default_value="1"/>
+        </nml_record>
+
+        <nml_record name="decomposition">
+                <nml_option name="config_block_decomp_file_prefix"   type="character"     default_value="graph.info.part."/>
+                <nml_option name="config_number_of_blocks"           type="integer"       default_value="0"/>
+                <nml_option name="config_explicit_proc_decomp"       type="logical"       default_value=".false."/>
+                <nml_option name="config_proc_decomp_file_prefix"    type="character"     default_value="graph.info.part."/>
+        </nml_record>
+
+        <nml_record name="restart">
+                <nml_option name="config_restart_interval"      type="integer"       default_value="0"/>
+                <nml_option name="config_do_restart"            type="logical"       default_value="false"/>
+                <nml_option name="config_restart_time"          type="real"          default_value="172800.0"/>
+        </nml_record>
+
+
+<!-- **************************************************************************************** -->
+<!-- ************************************** Variables *************************************** -->
+<!-- **************************************************************************************** -->
+
+        <var_struct name="mesh" time_levs="0">
+                <var name="latCell"                      type="real"     dimensions="nCells"                      streams="io"/>
+                <var name="lonCell"                      type="real"     dimensions="nCells"                      streams="io"/>
+                <var name="xCell"                        type="real"     dimensions="nCells"                      streams="io"/>
+                <var name="yCell"                        type="real"     dimensions="nCells"                      streams="io"/>
+                <var name="zCell"                        type="real"     dimensions="nCells"                      streams="io"/>
+                <var name="indexToCellID"                type="integer"  dimensions="nCells"                      streams="io"/>
+                <var name="latEdge"                      type="real"     dimensions="nEdges"                      streams="io"/>
+                <var name="lonEdge"                      type="real"     dimensions="nEdges"                      streams="io"/>
+                <var name="xEdge"                        type="real"     dimensions="nEdges"                      streams="io"/>
+                <var name="yEdge"                        type="real"     dimensions="nEdges"                      streams="io"/>
+                <var name="zEdge"                        type="real"     dimensions="nEdges"                      streams="io"/>
+                <var name="indexToEdgeID"                type="integer"  dimensions="nEdges"                      streams="io"/>
+                <var name="latVertex"                    type="real"     dimensions="nVertices"                   streams="io"/>
+                <var name="lonVertex"                    type="real"     dimensions="nVertices"                   streams="io"/>
+                <var name="xVertex"                      type="real"     dimensions="nVertices"                   streams="io"/>
+                <var name="yVertex"                      type="real"     dimensions="nVertices"                   streams="io"/>
+                <var name="zVertex"                      type="real"     dimensions="nVertices"                   streams="io"/>
+                <var name="indexToVertexID"              type="integer"  dimensions="nVertices"                   streams="io"/>
+                <var name="cellsOnEdge"                  type="integer"  dimensions="TWO nEdges"                  streams="io"/>
+                <var name="nEdgesOnCell"                 type="integer"  dimensions="nCells"                      streams="io"/>
+                <var name="nEdgesOnEdge"                 type="integer"  dimensions="nEdges"                      streams="io"/>
+                <var name="edgesOnCell"                  type="integer"  dimensions="maxEdges nCells"             streams="io"/>
+                <var name="edgesOnEdge"                  type="integer"  dimensions="maxEdges2 nEdges"            streams="io"/>
+                <var name="weightsOnEdge"                type="real"     dimensions="maxEdges2 nEdges"            streams="io"/>
+                <var name="dvEdge"                       type="real"     dimensions="nEdges"                      streams="io"/>
+                <var name="dcEdge"                       type="real"     dimensions="nEdges"                      streams="io"/>
+                <var name="angleEdge"                    type="real"     dimensions="nEdges"                      streams="io"/>
+                <var name="areaCell"                     type="real"     dimensions="nCells"                      streams="io"/>
+                <var name="areaTriangle"                 type="real"     dimensions="nVertices"                   streams="io"/>
+                <var name="edgeNormalVectors"            type="real"     dimensions="R3 nEdges"                   streams="io"/>
+                <var name="localVerticalUnitVectors"     type="real"     dimensions="R3 nCells"                   streams="io"/>
+                <var name="cellTangentPlane"             type="real"     dimensions="R3 TWO nCells"               streams="io"/>
+                <var name="cellsOnCell"                  type="integer"  dimensions="maxEdges nCells"             streams="io"/>
+                <var name="verticesOnCell"               type="integer"  dimensions="maxEdges nCells"             streams="io"/>
+                <var name="verticesOnEdge"               type="integer"  dimensions="TWO nEdges"                  streams="io"/>
+                <var name="edgesOnVertex"                type="integer"  dimensions="vertexDegree nVertices"      streams="io"/>
+                <var name="cellsOnVertex"                type="integer"  dimensions="vertexDegree nVertices"      streams="io"/>
+                <var name="kiteAreasOnVertex"            type="real"     dimensions="vertexDegree nVertices"      streams="io"/>
+                <var name="fEdge"                        type="real"     dimensions="nEdges"                      streams="io"/>
+                <var name="fVertex"                      type="real"     dimensions="nVertices"                   streams="io"/>
+                <var name="meshDensity"                  type="real"     dimensions="nCells"                      streams="iro"/>
+
+                <!-- coefficients for vertical extrapolation to the surface -->
+                <var name="cf1"                          type="real"     dimensions=""                            streams="io"/>
+                <var name="cf2"                          type="real"     dimensions=""                            streams="io"/>
+                <var name="cf3"                          type="real"     dimensions=""                            streams="io"/>
+
+                <!-- static terrestrial fields -->
+                <var name="ter"                                  type="real"     dimensions="nCells"              streams="io"/>
+                <var name="landmask"                             type="integer"  dimensions="nCells"              streams="io"/>
+                <var name="ivgtyp"   name_in_code="lu_index"     type="integer"  dimensions="nCells"              streams="io"/>
+                <var name="isltyp"   name_in_code="soilcat_top"  type="integer"  dimensions="nCells"              streams="io"/>
+                <var name="soilcat_bot"                          type="integer"  dimensions="nCells"              streams="io"/>
+                <var name="snoalb"                               type="real"     dimensions="nCells"              streams="io"/>
+                <var name="soiltemp"                             type="real"     dimensions="nCells"              streams="io"/>
+                <var name="greenfrac"                            type="real"     dimensions="nMonths nCells"      streams="io"/>
+                <var name="shdmin"                               type="real"     dimensions="nCells"              streams="io"/>
+                <var name="shdmax"                               type="real"     dimensions="nCells"              streams="io"/>
+                <var name="albedo12m"                            type="real"     dimensions="nMonths nCells"      streams="io"/>
+
+                <!-- description of the vertical grid structure -->
+                <var name="hx"                         type="real"     dimensions="nVertLevelsP1 nCells"        streams="io"/>
+                <var name="zgrid"                      type="real"     dimensions="nVertLevelsP1 nCells"        streams="io"/>
+                <var name="rdzw"                       type="real"     dimensions="nVertLevels"                 streams="io"/>
+                <var name="dzu"                        type="real"     dimensions="nVertLevels"                 streams="io"/>
+                <var name="rdzu"                       type="real"     dimensions="nVertLevels"                 streams="io"/>
+                <var name="fzm"                        type="real"     dimensions="nVertLevels"                 streams="io"/>
+                <var name="fzp"                        type="real"     dimensions="nVertLevels"                 streams="io"/>
+                <var name="zx"                         type="real"     dimensions="nVertLevelsP1 nEdges"        streams="io"/>
+                <var name="zz"                         type="real"     dimensions="nVertLevelsP1 nCells"        streams="io"/>
+                <var name="zb"                         type="real"     dimensions="nVertLevelsP1 TWO nEdges"    streams="io"/>
+                <var name="zb3"                        type="real"     dimensions="nVertLevelsP1 TWO nEdges"    streams="io"/>
+
+                <!-- W-Rayleigh damping coefficient -->
+                <var name="dss"                        type="real"     dimensions="nVertLevels nCells"          streams="io"/>
+
+                <var name="u_init"                     type="real"     dimensions="nVertLevels"                 streams="io"/>
+                <var name="t_init"                     type="real"     dimensions="nVertLevels nCells"          streams="io"/>
+                <var name="qv_init"                    type="real"     dimensions="nVertLevels"                 streams="io"/>
+
+                <!-- variables needed for advection -->
+                <var name="deriv_two"                  type="real"     dimensions="FIFTEEN TWO nEdges"          streams="io"/>
+                <var name="advCells"                   type="integer"  dimensions="TWENTYONE nCells"            streams="io"/>
+
+                <!-- deformation calculation weights -->
+                <var name="defc_a"                     type="real"     dimensions="maxEdges nCells"             streams="io"/>
+                <var name="defc_b"                     type="real"     dimensions="maxEdges nCells"             streams="io"/>
+
+                <!-- arrays required for reconstruction of velocity field -->
+                <var name="coeffs_reconstruct"         type="real"     dimensions="R3 maxEdges nCells"          streams="io"/>
+        </var_struct>
+
+        <var_struct name="state" time_levs="2">
+                <var name="xtime"                      type="text"     dimensions="Time"                        streams="so"/>
+                <var name="u"                          type="real"     dimensions="nVertLevels nEdges Time"     streams="o"/>
+                <var name="w"                          type="real"     dimensions="nVertLevelsP1 nCells Time"   streams="o"/>
+                <var name="rho_zz"                     type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="theta_m"                    type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+
+                <var_array name="scalars" type="real" dimensions="nVertLevels nCells Time">
+                        <var name="qv"      array_group="moist"       streams="o"/>
+                        <var name="qc"      array_group="moist"       streams="o"/>
+                        <var name="qr"      array_group="moist"       streams="o"/>
+                </var_array>
+        </var_struct>
+
+        <var_struct name="fg" time_levs="1">
+                
+                <!-- horizontally interpolated from first-guess data -->
+                <var name="u_fg"       name_in_code="u"       type="real"     dimensions="nFGLevels nEdges Time"/>
+                <var name="v_fg"       name_in_code="v"       type="real"     dimensions="nFGLevels nEdges Time"/>
+                <var name="t_fg"       name_in_code="t"       type="real"     dimensions="nFGLevels nCells Time"/>
+                <var name="p_fg"       name_in_code="p"       type="real"     dimensions="nFGLevels nCells Time"/>
+                <var name="z_fg"       name_in_code="z"       type="real"     dimensions="nFGLevels nCells Time"/>
+                <var name="rh_fg"      name_in_code="rh"      type="real"     dimensions="nFGLevels nCells Time"/>
+                <var name="soilz_fg"   name_in_code="soilz"   type="real"     dimensions="nCells Time"                 streams="io"/>
+                <var name="psfc_fg"    name_in_code="psfc"    type="real"     dimensions="nCells Time"/>
+                <var name="pmsl_fg"    name_in_code="pmsl"    type="real"     dimensions="nCells Time"/>
+                <var name="dz_fg"                             type="real"     dimensions="nFGSoilLevels nCells Time"   streams="io"/>
+                <var name="dzs_fg"                            type="real"     dimensions="nFGSoilLevels nCells Time"   streams="io"/>
+                <var name="zs_fg"                             type="real"     dimensions="nFGSoilLevels nCells Time"   streams="io"/>
+                <var name="st_fg"                             type="real"     dimensions="nFGSoilLevels nCells Time"   streams="io"/>
+                <var name="sm_fg"                             type="real"     dimensions="nFGSoilLevels nCells Time"   streams="io"/>
+
+                <!-- horizontally interpolated from first-guess data, and should be read in by model -->
+                <var name="dz"                                type="real"     dimensions="nSoilLevels nCells Time"     streams="io"/>
+                <var name="dzs"                               type="real"     dimensions="nSoilLevels nCells Time"     streams="io"/>
+                <var name="zs"                                type="real"     dimensions="nSoilLevels nCells Time"     streams="io"/>
+                <var name="sh2o"                              type="real"     dimensions="nSoilLevels nCells Time"     streams="io"/>
+                <var name="smois"                             type="real"     dimensions="nSoilLevels nCells Time"     streams="io"/>
+                <var name="tslb"                              type="real"     dimensions="nSoilLevels nCells Time"     streams="io"/>
+                <var name="smcrel"                            type="real"     dimensions="nSoilLevels nCells Time"     streams="io"/>
+                <var name="tmn"                               type="real"     dimensions="nCells Time"                 streams="io"/>
+                <var name="skintemp"                          type="real"     dimensions="nCells Time"                 streams="io"/>
+                <var name="sst"                               type="real"     dimensions="nCells Time"                 streams="iso"/>
+                <var name="snow"                              type="real"     dimensions="nCells Time"                 streams="io"/>
+                <var name="snowc"                             type="real"     dimensions="nCells Time"                 streams="io"/>
+                <var name="snowh"                             type="real"     dimensions="nCells Time"                 streams="io"/>
+                <var name="xice"                              type="real"     dimensions="nCells Time"                 streams="iso"/>
+                <var name="seaice"                            type="real"     dimensions="nCells Time"                 streams="io"/>
+                <var name="gfs_z"                             type="real"     dimensions="nVertLevels nCells Time"/>
+                <var name="vegfra"                            type="real"     dimensions="nCells Time"                 streams="io"/>
+                <var name="sfc_albbck"                        type="real"     dimensions="nCells Time"                 streams="io"/>
+                <var name="xland"                             type="real"     dimensions="nCells Time"                 streams="io"/>
+        </var_struct>
+
+        <var_struct name="diag" time_levs="1">
+                <var name="pressure_p"                        type="real"     dimensions="nVertLevels nCells Time"/>
+                <var name="rho"                               type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="theta"                             type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="v"                                 type="real"     dimensions="nVertLevels nEdges Time"     streams="o"/>
+                <var name="uReconstructX"                     type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="uReconstructY"                     type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="uReconstructZ"                     type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="uReconstructZonal"                 type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="uReconstructMeridional"            type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="exner"                             type="real"     dimensions="nVertLevels nCells Time"/>
+                <var name="exner_base"                        type="real"     dimensions="nVertLevels nCells Time"     streams="io"/>
+                <var name="rtheta_base"                       type="real"     dimensions="nVertLevels nCells Time"/>
+                <var name="pressure"                          type="real"     dimensions="nVertLevels nCells Time"/>
+                <var name="pressure_base"                     type="real"     dimensions="nVertLevels nCells Time"     streams="io"/>
+                <var name="rho_base"                          type="real"     dimensions="nVertLevels nCells Time"     streams="io"/>
+                <var name="theta_base"                        type="real"     dimensions="nVertLevels nCells Time"     streams="io"/>
+                <var name="cqw"                               type="real"     dimensions="nVertLevels nCells Time"/>
+                <var name="surface_pressure"                  type="real"     dimensions="nCells Time"                 streams="io"/>
+
+                <!-- coupled variables needed by the solver, but not output -->
+                <var name="ru"                                type="real"     dimensions="nVertLevels nEdges Time"/>
+                <var name="rw"                                type="real"     dimensions="nVertLevelsP1 nCells Time"/>
+                <var name="rtheta_p"                          type="real"     dimensions="nVertLevels nCells Time"/>
+                <var name="rho_p"                             type="real"     dimensions="nVertLevels nCells Time"/>
+        </var_struct>
+</registry>
Copied: trunk/mpas/src/core_nhyd_atmos/Registry.xml (from rev 2662, branches/xml_registry/src/core_nhyd_atmos/Registry.xml)
===================================================================
--- trunk/mpas/src/core_nhyd_atmos/Registry.xml                                (rev 0)
+++ trunk/mpas/src/core_nhyd_atmos/Registry.xml        2013-03-22 19:32:26 UTC (rev 2663)
@@ -0,0 +1,917 @@
+<?xml version="1.0"?>
+<registry>
+
+<!-- **************************************************************************************** -->
+<!-- ************************************** Dimensions ************************************** -->
+<!-- **************************************************************************************** -->
+
+        <dims>
+                <dim name="nCells"/>
+                <dim name="nEdges"/>
+                <dim name="maxEdges"/>
+                <dim name="maxEdges2"/>
+                <dim name="nVertices"/>
+                <dim name="TWO"                definition="2"/>
+                <dim name="THREE"              definition="3"/>
+                <dim name="vertexDegree"/>
+                <dim name="FIFTEEN"            definition="15"/>
+                <dim name="TWENTYONE"          definition="21"/>
+                <dim name="R3"                 definition="3"/>
+                <dim name="nVertLevels"/>
+                <dim name="nVertLevelsP1"      definition="nVertLevels+1"/>
+                <dim name="nMonths"            definition="namelist:months"/>
+                <dim name="nSoilLevels"        definition="namelist:num_soil_layers"/>
+                <dim name="nLags"              definition="namelist:input_soil_temperature_lag"/>
+                <dim name="nOznLevels"         definition="namelist:noznlev"/>
+                <dim name="nAerLevels"         definition="namelist:naerlev"/>
+                <dim name="cam_dim1"           definition="namelist:camdim1"/>
+                <dim name="nVertLevelsP2"      definition="nVertLevels+2"/>
+        </dims>
+
+
+<!-- **************************************************************************************** -->
+<!-- ************************************** Namelists *************************************** -->
+<!-- **************************************************************************************** -->
+
+        <nml_record name="nhyd_model">
+                <nml_option name="config_time_integration"           type="character"     default_value="SRK3"/>
+                <nml_option name="config_dt"                         type="real"          default_value="600.0"/>
+                <nml_option name="config_calendar_type"              type="character"     default_value="gregorian"/>
+                <nml_option name="config_start_time"                 type="character"     default_value="0000-01-01_00:00:00"/>
+                <nml_option name="config_stop_time"                  type="character"     default_value="none"/>
+                <nml_option name="config_run_duration"               type="character"     default_value="none"/>
+                <nml_option name="config_sfc_update_interval"        type="character"     default_value="none"/>
+                <nml_option name="config_horiz_mixing"               type="character"     default_value="2d_smagorinsky"/>
+                <nml_option name="config_h_mom_eddy_visc2"           type="real"          default_value="0.0"/>
+                <nml_option name="config_h_mom_eddy_visc4"           type="real"          default_value="0.0"/>
+                <nml_option name="config_v_mom_eddy_visc2"           type="real"          default_value="0.0"/>
+                <nml_option name="config_h_theta_eddy_visc2"         type="real"          default_value="0.0"/>
+                <nml_option name="config_h_theta_eddy_visc4"         type="real"          default_value="0.0"/>
+                <nml_option name="config_v_theta_eddy_visc2"         type="real"          default_value="0.0"/>
+                <nml_option name="config_number_of_sub_steps"        type="integer"       default_value="4"/>
+                <nml_option name="config_w_adv_order"                type="integer"       default_value="3"/>
+                <nml_option name="config_theta_adv_order"            type="integer"       default_value="3"/>
+                <nml_option name="config_scalar_adv_order"           type="integer"       default_value="3"/>
+                <nml_option name="config_u_vadv_order"               type="integer"       default_value="3"/>
+                <nml_option name="config_w_vadv_order"               type="integer"       default_value="3"/>
+                <nml_option name="config_theta_vadv_order"           type="integer"       default_value="3"/>
+                <nml_option name="config_scalar_vadv_order"          type="integer"       default_value="3"/>
+                <nml_option name="config_coef_3rd_order"             type="real"          default_value="0.25"/>
+                <nml_option name="config_scalar_advection"           type="logical"       default_value="true"/>
+                <nml_option name="config_positive_definite"          type="logical"       default_value="false"/>
+                <nml_option name="config_monotonic"                  type="logical"       default_value="true"/>
+                <nml_option name="config_mix_full"                   type="logical"       default_value="true"/>
+                <nml_option name="config_len_disp"                   type="real"          default_value="120000.0"/>
+                <nml_option name="config_epssm"                      type="real"          default_value="0.1"/>
+                <nml_option name="config_smdiv"                      type="real"          default_value="0.1"/>
+                <nml_option name="config_newpx"                      type="logical"       default_value="false"/>
+                <nml_option name="config_apvm_upwinding"             type="real"          default_value="0.5"/>
+                <nml_option name="config_h_ScaleWithMesh"            type="logical"       default_value="false"/>
+                <nml_option name="config_num_halos"                  type="integer"       default_value="2"/>
+        </nml_record>
+
+        <nml_record name="damping">
+                <nml_option name="config_zd"                         type="real"          default_value="22000.0"/>
+                <nml_option name="config_xnutr"                      type="real"          default_value="0.0"/>
+        </nml_record>
+
+        <nml_record name="io">
+                <nml_option name="config_input_name"                 type="character"     default_value="init.nc"/>
+                <nml_option name="config_sfc_update_name"            type="character"     default_value="sfc_update.nc"/>
+                <nml_option name="config_output_name"                type="character"     default_value="output.nc"/>
+                <nml_option name="config_restart_name"               type="character"     default_value="restart.nc"/>
+                <nml_option name="config_output_interval"            type="character"     default_value="06:00:00"/>
+                <nml_option name="config_frames_per_outfile"         type="integer"       default_value="0"/>
+                <nml_option name="config_pio_num_iotasks"            type="integer"       default_value="0"/>
+                <nml_option name="config_pio_stride"                 type="integer"       default_value="1"/>
+        </nml_record>
+
+        <nml_record name="decomposition">
+                <nml_option name="config_block_decomp_file_prefix"   type="character"     default_value="graph.info.part."/>
+                <nml_option name="config_number_of_blocks"           type="integer"       default_value="0"/>
+                <nml_option name="config_explicit_proc_decomp"       type="logical"       default_value=".false."/>
+                <nml_option name="config_proc_decomp_file_prefix"    type="character"     default_value="graph.info.part."/>
+        </nml_record>
+
+        <nml_record name="restart">
+                <nml_option name="config_do_restart"                 type="logical"       default_value="false"/>
+                <nml_option name="config_do_DAcycling"               type="logical"       default_value="false"/>
+                <nml_option name="config_restart_interval"           type="character"     default_value="none"/>
+        </nml_record>
+
+
+<!-- **************************************************************************************** -->
+<!-- ************************************** Variables *************************************** -->
+<!-- **************************************************************************************** -->
+
+        <var_struct name="mesh" time_levs="0">
+
+                <!-- horizontal grid structure -->
+                <var name="latCell"                   type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="lonCell"                   type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="xCell"                     type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="yCell"                     type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="zCell"                     type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="indexToCellID"             type="integer"  dimensions="nCells"                      streams="iro"/>
+                <var name="latEdge"                   type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="lonEdge"                   type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="xEdge"                     type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="yEdge"                     type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="zEdge"                     type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="indexToEdgeID"             type="integer"  dimensions="nEdges"                      streams="iro"/>
+                <var name="latVertex"                 type="real"     dimensions="nVertices"                   streams="iro"/>
+                <var name="lonVertex"                 type="real"     dimensions="nVertices"                   streams="iro"/>
+                <var name="xVertex"                   type="real"     dimensions="nVertices"                   streams="iro"/>
+                <var name="yVertex"                   type="real"     dimensions="nVertices"                   streams="iro"/>
+                <var name="zVertex"                   type="real"     dimensions="nVertices"                   streams="iro"/>
+                <var name="indexToVertexID"           type="integer"  dimensions="nVertices"                   streams="iro"/>
+                <var name="cellsOnEdge"               type="integer"  dimensions="TWO nEdges"                  streams="iro"/>
+                <var name="nEdgesOnCell"              type="integer"  dimensions="nCells"                      streams="iro"/>
+                <var name="nEdgesOnEdge"              type="integer"  dimensions="nEdges"                      streams="iro"/>
+                <var name="edgesOnCell"               type="integer"  dimensions="maxEdges nCells"             streams="iro"/>
+                <var name="edgesOnEdge"               type="integer"  dimensions="maxEdges2 nEdges"            streams="iro"/>
+                <var name="weightsOnEdge"             type="real"     dimensions="maxEdges2 nEdges"            streams="iro"/>
+                <var name="dvEdge"                    type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="dcEdge"                    type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="angleEdge"                 type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="areaCell"                  type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="areaTriangle"              type="real"     dimensions="nVertices"                   streams="iro"/>
+                <var name="edgeNormalVectors"         type="real"     dimensions="R3 nEdges"                   streams="iro"/>
+                <var name="localVerticalUnitVectors"  type="real"     dimensions="R3 nCells"                   streams="iro"/>
+                <var name="cellTangentPlane"          type="real"     dimensions="R3 TWO nCells"               streams="iro"/>
+                <var name="cellsOnCell"               type="integer"  dimensions="maxEdges nCells"             streams="iro"/>
+                <var name="verticesOnCell"            type="integer"  dimensions="maxEdges nCells"             streams="iro"/>
+                <var name="verticesOnEdge"            type="integer"  dimensions="TWO nEdges"                  streams="iro"/>
+                <var name="edgesOnVertex"             type="integer"  dimensions="vertexDegree nVertices"      streams="iro"/>
+                <var name="cellsOnVertex"             type="integer"  dimensions="vertexDegree nVertices"      streams="iro"/>
+                <var name="kiteAreasOnVertex"         type="real"     dimensions="vertexDegree nVertices"      streams="iro"/>
+                <var name="fEdge"                     type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="fVertex"                   type="real"     dimensions="nVertices"                   streams="iro"/>
+                <var name="meshDensity"               type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="meshScalingDel2"           type="real"     dimensions="nEdges"                      streams="ro"/>
+                <var name="meshScalingDel4"           type="real"     dimensions="nEdges"                      streams="ro"/>
+
+                <!-- coefficients for vertical extrapolation to the surface -->
+                <var name="cf1"                       type="real"     dimensions=""                            streams="iro"/>
+                <var name="cf2"                       type="real"     dimensions=""                            streams="iro"/>
+                <var name="cf3"                       type="real"     dimensions=""                            streams="iro"/>
+
+                <!-- coefficients used by "newpx" horizontal pressure gradient option -->
+                <var name="cpr"                       type="real"     dimensions="THREE nEdges"                streams="ro"/>
+                <var name="cpl"                       type="real"     dimensions="THREE nEdges"                streams="ro"/>
+
+                <!-- description of the vertical grid structure -->
+                <var name="hx"                        type="real"     dimensions="nVertLevelsP1 nCells"        streams="iro"/>
+                <var name="zgrid"                     type="real"     dimensions="nVertLevelsP1 nCells"        streams="iro"/>
+                <var name="rdzw"                      type="real"     dimensions="nVertLevels"                 streams="iro"/>
+                <var name="dzu"                       type="real"     dimensions="nVertLevels"                 streams="iro"/>
+                <var name="rdzu"                      type="real"     dimensions="nVertLevels"                 streams="iro"/>
+                <var name="fzm"                       type="real"     dimensions="nVertLevels"                 streams="iro"/>
+                <var name="fzp"                       type="real"     dimensions="nVertLevels"                 streams="iro"/>
+                <var name="zx"                        type="real"     dimensions="nVertLevelsP1 nEdges"        streams="iro"/>
+                <var name="zz"                        type="real"     dimensions="nVertLevelsP1 nCells"        streams="iro"/>
+                <var name="zb"                        type="real"     dimensions="nVertLevelsP1 TWO nEdges"    streams="iro"/>
+                <var name="zb3"                       type="real"     dimensions="nVertLevelsP1 TWO nEdges"    streams="iro"/>
+                <var name="pzm"                       type="real"     dimensions="nVertLevels nCells"          streams="r"/>
+                <var name="pzp"                       type="real"     dimensions="nVertLevels nCells"          streams="r"/>
+
+                <!-- W-Rayleigh damping coefficients -->
+                <var name="dss"                       type="real"     dimensions="nVertLevels nCells"          streams="iro"/>
+
+                <var name="u_init"                    type="real"     dimensions="nVertLevels"                 streams="iro"/>
+                <var name="t_init"                    type="real"     dimensions="nVertLevels nCells"          streams="iro"/>
+                <var name="qv_init"                   type="real"     dimensions="nVertLevels"                 streams="iro"/>
+
+                <!-- Space needed for advection -->
+                <var name="deriv_two"                 type="real"     dimensions="FIFTEEN TWO nEdges"          streams="ir"/>
+                <var name="advCells"                  type="integer"  dimensions="TWENTYONE nCells"            streams="ir"/>
+                <var name="adv_coefs"                 type="real"     dimensions="FIFTEEN nEdges"/>
+                <var name="adv_coefs_3rd"             type="real"     dimensions="FIFTEEN nEdges"/>
+                <var name="advCellsForEdge"           type="integer"  dimensions="FIFTEEN nEdges"/>
+                <var name="nAdvCellsForEdge"          type="integer"  dimensions="nEdges"/>
+
+                <!-- Space needed for deformation calculation weights -->
+                <var name="defc_a"                    type="real"     dimensions="maxEdges nCells"             streams="iro"/>
+                <var name="defc_b"                    type="real"     dimensions="maxEdges nCells"             streams="iro"/>
+
+                <!-- Arrays required for reconstruction of velocity field -->
+                <var name="coeffs_reconstruct"        type="real"     dimensions="R3 maxEdges nCells"          streams="iro"/>
+                <var name="east"                      type="real"     dimensions="R3 nCells"                   streams="r"/>
+                <var name="north"                     type="real"     dimensions="R3 nCells"                   streams="r"/>
+
+                <!-- Arrays needed only in the CAM LW and SW radiation codes: Ozone -->
+                <var name="pin"                       type="real"     dimensions="nOznLevels nCells"/>
+                <var name="ozmixm"                    type="real"     dimensions="nMonths nOznLevels nCells"/>
+
+                <!-- Arrays needed only in the CAM LW and SW radiation codes: Aerosols -->
+                <var name="m_hybi"                    type="real"     dimensions="nAerLevels nCells"/>
+        </var_struct>
+
+        <var_struct name="state" time_levs="2">
+
+                <var name="xtime"     type="text"     dimensions="Time"                        streams="iro"/>
+
+                <!-- Prognostic variables: read from input, saved in restart, and written to output -->
+                <var name="u"         type="real"     dimensions="nVertLevels nEdges Time"     streams="iro"/>
+                <var name="w"         type="real"     dimensions="nVertLevelsP1 nCells Time"   streams="iro"/>
+                <var name="rho_zz"    type="real"     dimensions="nVertLevels nCells Time"     streams="r"/>
+                <var name="theta_m"   type="real"     dimensions="nVertLevels nCells Time"     streams="r"/>
+                <var name="m_ps"      type="real"     dimensions="nCells Time"/>
+                <var_array name="scalars" type="real" dimensions="nVertLevels nCells Time">
+                        <var name="qv"      array_group="moist"       streams="iro"/>
+                        <var name="qc"      array_group="moist"       streams="iro"/>
+                        <var name="qr"      array_group="moist"       streams="iro"/>
+                        <var name="qi"      array_group="moist"       streams="iro"/>
+                        <var name="qs"      array_group="moist"       streams="iro"/>
+                        <var name="qg"      array_group="moist"       streams="iro"/>
+                        <var name="qnr"     array_group="number"      streams="iro"/>
+                        <var name="qni"     array_group="number"      streams="iro"/>
+                </var_array>
+
+                <var_array name="aerosols" type="real" dimensions="nAerLevels nCells Time">
+                        <var name="sul"     array_group="aer_cam"/>
+                        <var name="sslt"    array_group="aer_cam"/>
+                        <var name="dust1"   array_group="aer_cam"/>
+                        <var name="dust2"   array_group="aer_cam"/>
+                        <var name="dust3"   array_group="aer_cam"/>
+                        <var name="dust4"   array_group="aer_cam"/>
+                        <var name="ocpho"   array_group="aer_cam"/>
+                        <var name="bcpho"   array_group="aer_cam"/>
+                        <var name="ocphi"   array_group="aer_cam"/>
+                        <var name="bcphi"   array_group="aer_cam"/>
+                        <var name="bg"      array_group="aer_cam"/>
+                        <var name="volc"    array_group="aer_cam"/>
+                </var_array>
+        </var_struct>
+
+        <var_struct name="diag" time_levs="1">
+
+                <!-- coefficients for the vertical tridiagonal solve -->
+                <!-- Note:  these could be local but...              -->
+                <var name="cofrz"                   type="real"     dimensions="nVertLevels Time"/>
+                <var name="cofwr"                   type="real"     dimensions="nVertLevels nCells Time"/>
+                <var name="cofwz"                   type="real"     dimensions="nVertLevels nCells Time"/>
+                <var name="coftz"                   type="real"     dimensions="nVertLevelsP1 nCells Time"/>
+                <var name="cofwt"                   type="real"     dimensions="nVertLevels nCells Time"/>
+                <var name="a_tri"                   type="real"     dimensions="nVertLevels nCells Time"/>
+                <var name="alpha_tri"               type="real"     dimensions="nVertLevels nCells Time"/>
+                <var name="gamma_tri"               type="real"     dimensions="nVertLevels nCells Time"/>
+
+                <!-- state variables diagnosed from prognostic state -->
+                <var name="pressure_p"              type="real"     dimensions="nVertLevels nCells Time"     streams="ro"/>
+
+                <!-- Diagnostic fields: only written to output                                                           -->
+                <!-- NOTE: added the "r" option to rho,theta,uReconstructZonal,and uReconstructMeridional for use of the -->
+                <!-- non-hydrostatic dynamical core in a data assimilation framework. NOTE that the "r" option is not    -->
+                <!-- needed for those 4 variables to get bit for bit restart capabilities, otherwise.                    -->
+                <var name="rho"                     type="real"     dimensions="nVertLevels nCells Time"     streams="iro"/>
+                <var name="theta"                   type="real"     dimensions="nVertLevels nCells Time"     streams="iro"/>
+                <var name="rh"                      type="real"     dimensions="nVertLevels nCells Time"     streams="iro"/>
+                <var name="v"                       type="real"     dimensions="nVertLevels nEdges Time"     streams="o"/>
+                <var name="divergence"              type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="vorticity"               type="real"     dimensions="nVertLevels nVertices Time"  streams="o"/>
+                <var name="pv_edge"                 type="real"     dimensions="nVertLevels nEdges Time"     streams="o"/>
+                <var name="rho_edge"                type="real"     dimensions="nVertLevels nEdges Time"     streams="o"/>
+                <var name="ke"                      type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="pv_vertex"               type="real"     dimensions="nVertLevels nVertices Time"  streams="o"/>
+                <var name="pv_cell"                 type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+
+                <!-- reconstructed horizontal velocity vectors at cell centers -->
+                <var name="uReconstructX"           type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="uReconstructY"           type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="uReconstructZ"           type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="uReconstructZonal"       type="real"     dimensions="nVertLevels nCells Time"     streams="ro"/>
+                <var name="uReconstructMeridional"  type="real"     dimensions="nVertLevels nCells Time"     streams="ro"/>
+
+                <!-- Other diagnostic variables -->
+                <var name="rv"                      type="real"     dimensions="nVertLevels nEdges Time"     streams="r"/>
+                <var name="circulation"             type="real"     dimensions="nVertLevels nVertices Time"  streams="r"/>
+                <var name="gradPVt"                 type="real"     dimensions="nVertLevels nEdges Time"/>
+                <var name="gradPVn"                 type="real"     dimensions="nVertLevels nEdges Time"/>
+                <var name="h_divergence"            type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+
+                <var name="exner"                   type="real"     dimensions="nVertLevels nCells Time"     streams="ro"/>
+                <var name="exner_base"              type="real"     dimensions="nVertLevels nCells Time"     streams="iro"/>
+                <var name="rtheta_base"             type="real"     dimensions="nVertLevels nCells Time"     streams="r"/>
+                <var name="pressure_base"           type="real"     dimensions="nVertLevels nCells Time"     streams="iro"/>
+                <var name="rho_base"                type="real"     dimensions="nVertLevels nCells Time"     streams="iro"/>
+                <var name="theta_base"              type="real"     dimensions="nVertLevels nCells Time"     streams="iro"/>
+
+                <var name="ruAvg"                   type="real"     dimensions="nVertLevels nEdges Time"/>
+                <var name="wwAvg"                   type="real"     dimensions="nVertLevelsP1 nCells Time"/>
+                <var name="cqu"                     type="real"     dimensions="nVertLevels nEdges Time"/>
+                <var name="cqw"                     type="real"     dimensions="nVertLevels nCells Time"/>
+
+                <!-- coupled variables needed by solver, but not output -->
+                <var name="ru"                      type="real"     dimensions="nVertLevels nEdges Time"     streams="r"/>
+                <var name="ru_p"                    type="real"     dimensions="nVertLevels nEdges Time"     streams="r"/>
+                <var name="ru_save"                 type="real"     dimensions="nVertLevels nEdges Time"/>
+
+                <var name="rw"                      type="real"     dimensions="nVertLevelsP1 nCells Time"   streams="r"/>
+                <var name="rw_p"                    type="real"     dimensions="nVertLevelsP1 nCells Time"   streams="r"/>
+                <var name="rw_save"                 type="real"     dimensions="nVertLevelsP1 nCells Time"/>
+
+                <var name="rtheta_p"                type="real"     dimensions="nVertLevels nCells Time"     streams="r"/>
+                <var name="rtheta_pp"               type="real"     dimensions="nVertLevels nCells Time"/>
+                <var name="rtheta_p_save"           type="real"     dimensions="nVertLevels nCells Time"/>
+                <var name="rtheta_pp_old"           type="real"     dimensions="nVertLevels nCells Time"/>
+
+                <var name="rho_p"                   type="real"     dimensions="nVertLevels nCells Time"     streams="r"/>
+                <var name="rho_pp"                  type="real"     dimensions="nVertLevels nCells Time"/>
+                <var name="rho_p_save"              type="real"     dimensions="nVertLevels nCells Time"/>
+
+                <var name="kdiff"                   type="real"     dimensions="nVertLevels nCells Time"/>
+
+                <var name="surface_pressure"        type="real"     dimensions="nCells Time"                 streams="iro"/>
+                <var name="surface_temperature"     type="real"     dimensions="nCells Time"                 streams="o"/>
+        </var_struct>
+
+        <var_struct name="tend" time_levs="1">
+
+                
+                <!-- tendencies for prognostic variables -->
+                <var name="tend_u"             name_in_code="u"           type="real"     dimensions="nVertLevels nEdges Time"     streams="o"/>
+                <var name="tend_w"             name_in_code="w"           type="real"     dimensions="nVertLevelsP1 nCells Time"   streams="o"/>
+                <var name="tend_rho"           name_in_code="rho_zz"      type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="tend_theta"         name_in_code="theta_m"     type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="rt_diabatic_tend"                              type="real"     dimensions="nVertLevels nCells Time"     streams="r"/>
+                <var name="euler_tend_u"       name_in_code="u_euler"     type="real"     dimensions="nVertLevels nEdges Time"/>
+                <var name="euler_tend_w"       name_in_code="w_euler"     type="real"     dimensions="nVertLevelsP1 nCells Time"/>
+                <var name="euler_tend_theta"   name_in_code="theta_euler" type="real"     dimensions="nVertLevels nCells Time"/>
+
+                <!-- scalar tendencies -->
+                <var_array name="scalars" type="real" dimensions="nVertLevels nCells Time">
+                        <var name="tend_qv"    name_in_code="qv"        array_group="moist"       streams="o"/>
+                        <var name="tend_qc"    name_in_code="qc"        array_group="moist"       streams="o"/>
+                        <var name="tend_qr"    name_in_code="qr"        array_group="moist"       streams="o"/>
+                        <var name="tend_qi"    name_in_code="qi"        array_group="moist"       streams="o"/>
+                        <var name="tend_qs"    name_in_code="qs"        array_group="moist"       streams="o"/>
+                        <var name="tend_qg"    name_in_code="qg"        array_group="moist"       streams="o"/>
+                        <var name="tend_qnr"   name_in_code="qnr"       array_group="number"      streams="o"/>
+                        <var name="tend_qni"   name_in_code="qni"       array_group="number"      streams="o"/>
+                </var_array>
+        </var_struct>
+
+
+
+<!-- ================================================================================================== -->
+<!--  DECLARATIONS OF ALL PHYSICS VARIABLES (will need to be moved to a Physics Registry shared by the  -->
+<!--  hydrostatic and non-hydrostatic dynamical cores):                                                 -->
+<!-- ================================================================================================== -->
+
+
+        <nml_record name="physics">
+                <!-- NAMELIST VARIABLES ADDED FOR INITIALIZATION OF SURFACE CHARACTERISTICS: -->
+                <nml_option name="input_landuse_data"                type="character"     default_value="USGS"/>
+                <nml_option name="input_soil_data"                   type="character"     default_value="STAS"/>
+                <nml_option name="input_soil_temperature_lag"        type="integer"       default_value="140"/>
+                <nml_option name="num_soil_layers"                   type="integer"       default_value="4"/>
+                <nml_option name="months"                            type="integer"       default_value="12"/>
+
+                <!-- ... DIMENSION NEEDED FOR OZONE AND AEROSOLS CONCENTRATIONS IN THE CAM LONGWAVE AND SHORTWAVE -->
+                <!-- ... RADIATION PARAMETERIZATIONS.                                                             -->
+                <nml_option name="noznlev"                           type="integer"       default_value="59"/>
+                <nml_option name="naerlev"                           type="integer"       default_value="29"/>
+                <nml_option name="camdim1"                           type="integer"       default_value="4"/>
+
+                <!-- NAMELIST VARIABLES ADDED FOR PHYSICS CONFIGURATION: -->
+                <nml_option name="config_frac_seaice"                type="logical"       default_value="false"/>
+                <nml_option name="config_sfc_albedo"                 type="logical"       default_value="false"/>
+                <nml_option name="config_sfc_snowalbedo"             type="logical"       default_value="false"/>
+                <nml_option name="config_sst_update"                 type="logical"       default_value="false"/>
+                <nml_option name="config_sstdiurn_update"            type="logical"       default_value="false"/>
+                <nml_option name="config_deepsoiltemp_update"        type="logical"       default_value="false"/>
+
+                <nml_option name="config_n_physics"                  type="integer"       default_value="1"/>
+                <nml_option name="config_n_microp"                   type="integer"       default_value="1"/>
+                <nml_option name="config_n_conv"                     type="integer"       default_value="1"/>
+                <nml_option name="config_n_pbl"                      type="integer"       default_value="1"/>
+                <nml_option name="config_n_lsm"                      type="integer"       default_value="1"/>
+                <nml_option name="config_n_eddy"                     type="integer"       default_value="1"/>
+                <nml_option name="config_n_radt_lw"                  type="integer"       default_value="1"/>
+                <nml_option name="config_n_radt_sw"                  type="integer"       default_value="1"/>
+
+                <nml_option name="config_radtlw_interval"            type="character"     default_value="none"/>
+                <nml_option name="config_radtsw_interval"            type="character"     default_value="none"/>
+                <nml_option name="config_conv_interval"              type="character"     default_value="none"/>
+                <nml_option name="config_pbl_interval"               type="character"     default_value="none"/>
+                <nml_option name="config_camrad_abs_update"          type="character"     default_value="06:00:00"/>
+                <nml_option name="config_greeness_update"            type="character"     default_value="24:00:00"/>
+                <nml_option name="config_bucket_update"              type="character"     default_value="none"/>
+
+                <nml_option name="config_microp_scheme"              type="character"     default_value="off"/>
+                <nml_option name="config_conv_shallow_scheme"        type="character"     default_value="off"/>
+                <nml_option name="config_conv_deep_scheme"           type="character"     default_value="off"/>
+                <nml_option name="config_eddy_scheme"                type="character"     default_value="off"/>
+                <nml_option name="config_lsm_scheme"                 type="character"     default_value="off"/>
+                <nml_option name="config_pbl_scheme"                 type="character"     default_value="off"/>
+                <nml_option name="config_radt_cld_scheme"            type="character"     default_value="off"/>
+                <nml_option name="config_radt_lw_scheme"             type="character"     default_value="off"/>
+                <nml_option name="config_radt_sw_scheme"             type="character"     default_value="off"/>
+                <nml_option name="config_sfclayer_scheme"            type="character"     default_value="off"/>
+
+                <nml_option name="config_bucket_radt"                type="real"          default_value="0.0_RKIND"/>
+                <nml_option name="config_bucket_rainc"               type="real"          default_value="0.0_RKIND"/>
+                <nml_option name="config_bucket_rainnc"              type="real"          default_value="0.0_RKIND"/>
+        </nml_record>
+
+        <var_struct name="diag_physics" time_levs="1">
+
+                <!-- ================================================================================================= -->
+                <!-- ... ARRAYS AND VARIABLES FOR UPDATING THE DEEP SOIL TEMPERATURE:                                  -->
+                <!-- ================================================================================================= -->
+                <!-- nsteps_accum: number of accumulated time-step in a day.                                           -->
+                <!-- ndays_accum : number of accumulated days in a year.                                               -->
+                <!-- tlag        : daily mean surface temperature of prior days                                    [K] -->
+                <!-- tday_accum  : accumulated daily surface temperature for current day                           [K] -->
+                <!-- tyear_mean  : annual mean surface temperature                                                 [K] -->
+                <!-- tyear_accum : accumulated yearly surface temperature for current year                         [K] -->
+
+                <var name="nsteps_accum"  type="real"     dimensions="nCells Time"                 streams="r"/>
+                <var name="ndays_accum"   type="real"     dimensions="nCells Time"                 streams="r"/>
+
+                <var name="tlag"          type="real"     dimensions="nLags nCells Time"           streams="r"/>
+                <var name="tday_accum"    type="real"     dimensions="nCells Time"                 streams="r"/>
+                <var name="tyear_mean"    type="real"     dimensions="nCells Time"                 streams="r"/>
+                <var name="tyear_accum"   type="real"     dimensions="nCells Time"                 streams="r"/>
+
+
+                <!-- ================================================================================================== -->
+                <!-- ... PARAMETERIZATION OF CLOUD MICROPHYSICS:                                                        -->
+                <!-- ================================================================================================== -->
+                <!-- i_rainnc  : counter related to how often rainnc is being reset relative to its bucket value   (-)  -->
+                <!-- rainnc    : accumulated total time-step grid-scale precipitation                             (mm)  -->
+                <!-- rainncv   : time-step total grid-scale precipitation                                         (mm)  -->
+                <!-- snownc    : accumulated grid-scale precipitation of snow                                     (mm)  -->
+                <!-- snowncv   : time-step grid-scale precipitation of snow                                       (mm)  -->
+                <!-- graupelnc : accumulated grid-scale precipitation of graupel                                  (mm)  -->
+                <!-- graupelncv: time-step grid-scale precipitation of graupel                                    (mm)  -->
+                <!-- sr        : time-step ratio of frozen versus total grid-scale precipitation                   (-)  -->
+
+                <var name="i_rainnc"      type="integer"  dimensions="nCells Time"                 streams="ro"/>
+                <var name="sr"            type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="rainncv"       type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="snowncv"       type="real"     dimensions="nCells Time"                 streams="o"/>
+                <var name="graupelncv"    type="real"     dimensions="nCells Time"                 streams="o"/>
+
+                <var name="rainnc"        type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="snownc"        type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="graupelnc"     type="real"     dimensions="nCells Time"                 streams="ro"/>
+
+                <var name="qsat"          type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="relhum"        type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+
+                <!-- ================================================================================================== -->
+                <!-- ... PARAMETERIZATION OF CONVECTION:                                                                -->
+                <!-- ================================================================================================== -->
+                <!-- i_rainc   : counter related to how often rainc is begin reset relative to its bucket value    (-)  -->
+                <!-- cuprec    : convective precipitation rate                                                  (mm/s)  -->
+                <!-- rainc     : accumulated time-step convective precipitation                                   (mm)  -->
+                <!-- raincv    : time-step convective precipitation                                               (mm)  -->
+
+                <var name="i_rainc"       type="integer"  dimensions="nCells Time"                 streams="ro"/>
+                <var name="cuprec"        type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="rainc"         type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="raincv"        type="real"     dimensions="nCells Time"                 streams="ro"/>
+
+                <!-- ... KAIN_FRITSCH:                                                                                 -->
+                <!-- cubot     : lowest level of convection                                                        (-) -->
+                <!-- cutop     : highest level of convection                                                       (-) -->
+                <!-- nca       : relaxation time for KF parameterization of convection                             (s) -->
+                <!-- wavg0     : average vertical velocity (KF scheme only)                                    (m s-1) -->
+
+                <var name="nca"           type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="cubot"         type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="cutop"         type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="w0avg"         type="real"     dimensions="nVertLevels nCells Time"     streams="ro"/>
+
+
+                <!-- ================================================================================================== -->
+                <!-- ... PARAMETERIZATION OF PLANETARY BOUNDARY LAYER PROCESSES:                                        -->
+                <!-- ================================================================================================== -->
+                <!-- kpbl      : index of PBL top                                                                  (-)  -->
+                <!-- hpbl      : PBL height                                                                        (m)  -->
+                <!-- exch_h    : exchange coefficient                                                              (-)  -->
+
+                <var name="kpbl"          type="integer"  dimensions="nCells Time"                 streams="ro"/>
+                <var name="hpbl"          type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="exch_h"        type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+
+                <!-- ================================================================================================== -->
+                <!-- ... PARAMETERIZATION OF SURFACE LAYER PROCESSES:                                                   -->
+                <!-- ================================================================================================== -->
+                <!--  br        :bulk richardson number                                                             [-] -->
+                <!--  cd        :drag coefficient at 10m                                                            [-] -->
+                <!--  cda       :drag coefficient at lowest model level                                             [-] -->
+                <!--  chs       :???                                                                                    -->
+                <!--  chs2      :???                                                                                    -->
+                <!--  cqs2      :???                                                                                    -->
+                <!--  ck        :enthalpy exchange coefficient at 10 m                                              [-] -->
+                <!--  cka       :enthalpy exchange coefficient at lowest model level                                [-] -->
+                <!--  cpm       :???                                                                                    -->
+                <!--  flhc      :exchange coefficient for heat                                                      [-] -->
+                <!--  flqc      :exchange coefficient for moisture                                                  [-] -->
+                <!--  gz1oz0    :log of z1 over z0                                                                  [-] -->
+                <!--  hfx       :upward heat flux at the surface                                               [W/m2/s] -->
+                <!--  lh        :latent heat flux at the surface                                                 [W/m2] -->
+                <!--  mavail    :surface moisture availability                                                      [-] -->
+                <!--  mol       :T* in similarity theory                                                            [K] -->
+                <!--  psih      :similarity theory for heat                                                         [-] -->
+                <!--  psim      :similarity theory for momentum                                                     [-] -->
+                <!--  qfx       :upward moisture flux at the surface                                          [kg/m2/s] -->
+                <!--  qgh       :???                                                                                    -->
+                <!--  qsfc      :specific humidity at lower boundary                                            [kg/kg] -->
+                <!--  regime    :flag indicating PBL regime (stable_p,unstable_p,etc...)                            [-] -->
+                <!--  rmol      :1 / Monin Ob length                                                                [-] -->
+                <!--  ust       :u* in similarity theory                                                          [m/s] -->
+                <!--  ustm      :u* in similarity theory without vconv                                            [m/s] -->
+                <!--  zol       :z/L height over Monin-Obukhov length                                               [-] -->
+                <!--  znt       :time-varying roughness length                                                      [m] -->
+                <!--  wspd      :wind speed                                                                       [m/s] -->
+                <!--  DIAGNOSTICS:                                                                                      -->
+                <!--  q2        :specific humidity at 2m                                                        [kg/kg] -->
+                <!--  u10       :u at 10 m                                                                        [m/s] -->
+                <!--  v10       :v at 10 m                                                                        [m/s] -->
+                <!--  t2m       :temperature at 2m                                                                  [K] -->
+                <!--  th2m      :potential temperature at 2m                                                        [K] -->
+                <var name="hfx"           type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="mavail"        type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="mol"           type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="qfx"           type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="qsfc"          type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="ust"           type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="ustm"          type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="zol"           type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="znt"           type="real"     dimensions="nCells Time"                 streams="ro"/>
+
+                <var name="br"            type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="cd"            type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="cda"           type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="chs"           type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="chs2"          type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="cqs2"          type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="ck"            type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="cka"           type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="cpm"           type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="flhc"          type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="flqc"          type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="gz1oz0"        type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="lh"            type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="psim"          type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="psih"          type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="qgh"           type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="regime"        type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="rmol"          type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="wspd"          type="real"     dimensions="nCells Time"                 streams="ro"/>
+
+                <!-- DIAGNOSTICS: -->
+                <var name="u10"           type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="v10"           type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="q2"            type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="t2m"           type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="th2m"          type="real"     dimensions="nCells Time"                 streams="ro"/>
+
+                <!-- ================================================================================================== -->
+                <!-- ... PARAMETERIZATION OF SHORTWAVE RADIATION:                                                       -->
+                <!-- ================================================================================================== -->
+                <!--  coszr     :cosine of the solar zenith angle                                                   [-] -->
+                <!--  gsw       :net shortwave flux at surface                                                  [W m-2] -->
+                <!--  swcf      :shortwave cloud forcing at top-of-atmosphere                                   [W m-2] -->
+                <!--  swdnb     :all-sky downwelling shortwave flux at bottom-of-atmosphere                     [W m-2] -->
+                <!--  swdnbc    :clear-sky downwelling shortwave flux at bottom-of-atmosphere                   [W m-2] -->
+                <!--  swdnt     :all-sky downwelling shortwave flux at top-of-atmosphere                        [W m-2] -->
+                <!--  swdntc    :clear-sky downwelling shortwave flux at top-of-atmosphere                      [W m-2] -->
+                <!--  swupb     :all-sky upwelling shortwave flux at bottom-of-atmosphere                       [W m-2] -->
+                <!--  swupbc    :clear-sky upwelling shortwave flux at bottom-of-atmosphere                     [W m-2] -->
+                <!--  swupt     :all-sky upwelling shortwave flux at top-of-atmosphere                          [W m-2] -->
+                <!--  swuptc    :clear-sky upwelling shortwave flux at top-of-atmosphere                        [W m-2] -->
+                <!--  acswdnb   :accumulated all-sky downwelling shortwave flux at bottom-of-atmosphere         [J m-2] -->
+                <!--  acswdnbc  :accumulated clear-sky downwelling shortwave flux at bottom-of-atmosphere       [J m-2] -->
+                <!--  acswdnt   :accumulated all-sky downwelling shortwave flux at top-of-atmosphere            [J m-2] -->
+                <!--  acswdntc  :accumulated clear-sky downwelling shortwave flux at top-of-atmosphere          [J m-2] -->
+                <!--  acswupb   :accumulated all-sky upwelling shortwave flux at bottom-of-atmosphere           [J m-2] -->
+                <!--  acswupbc  :accumulated clear-sky upwelling shortwave flux at bottom-of-atmosphere         [J m-2] -->
+                <!--  acswupt   :accumulated all-sky upwelling shortwave flux at top-of-atmosphere              [J m-2] -->
+                <!--  acswuptc  :accumulated clear-sky upwelling shortwave flux at top-of-atmosphere            [J m-2] -->
+                <!--  swdnflx   :                                                                                       -->
+                <!--  swdnflxc  :                                                                                       -->
+                <!--  swupflx   :                                                                                       -->
+                <!--  swupflxc  :                                                                                       -->
+
+                <!--  i_acswdnb : counter related to how often swdnb is begin reset relative to its bucket value    (-) -->
+                <!--  i_acswdnbc: counter related to how often swdnbc is begin reset relative to its bucket value   (-) -->
+                <!--  i_acswdnt : counter related to how often swdnt is begin reset relative to its bucket value    (-) -->
+                <!--  i_acswdntc: counter related to how often swdntc is begin reset relative to its bucket value   (-) -->
+                <!--  i_acswupb : counter related to how often swupb is begin reset relative to its bucket value    (-) -->
+                <!--  i_acswupbc: counter related to how often swupbc is begin reset relative to its bucket value   (-) -->
+                <!--  i_acswupt : counter related to how often swupt is begin reset relative to its bucket value    (-) -->
+                <!--  i_acswuptc: counter related to how often swuptc is begin reset relative to its bucket value   (-) -->
+
+                <var name="i_acswdnb"     type="integer"  dimensions="nCells Time"                 streams="ro"/>
+                <var name="i_acswdnbc"    type="integer"  dimensions="nCells Time"                 streams="ro"/>
+                <var name="i_acswdnt"     type="integer"  dimensions="nCells Time"                 streams="ro"/>
+                <var name="i_acswdntc"    type="integer"  dimensions="nCells Time"                 streams="ro"/>
+                <var name="i_acswupb"     type="integer"  dimensions="nCells Time"                 streams="ro"/>
+                <var name="i_acswupbc"    type="integer"  dimensions="nCells Time"                 streams="ro"/>
+                <var name="i_acswupt"     type="integer"  dimensions="nCells Time"                 streams="ro"/>
+                <var name="i_acswuptc"    type="integer"  dimensions="nCells Time"                 streams="ro"/>
+
+                <var name="coszr"         type="real"     dimensions="nCells Time"                 streams="o"/>
+                <var name="swcf"          type="real"     dimensions="nCells Time"                 streams="o"/>
+                <var name="swdnb"         type="real"     dimensions="nCells Time"                 streams="o"/>
+                <var name="swdnbc"        type="real"     dimensions="nCells Time"                 streams="o"/>
+                <var name="swdnt"         type="real"     dimensions="nCells Time"                 streams="o"/>
+                <var name="swdntc"        type="real"     dimensions="nCells Time"                 streams="o"/>
+                <var name="swupb"         type="real"     dimensions="nCells Time"                 streams="o"/>
+                <var name="swupbc"        type="real"     dimensions="nCells Time"                 streams="o"/>
+                <var name="swupt"         type="real"     dimensions="nCells Time"                 streams="o"/>
+                <var name="swuptc"        type="real"     dimensions="nCells Time"                 streams="o"/>
+                <var name="acswdnb"       type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="acswdnbc"      type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="acswdnt"       type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="acswdntc"      type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="acswupb"       type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="acswupbc"      type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="acswupt"       type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="acswuptc"      type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="gsw"           type="real"     dimensions="nCells Time"                 streams="ro"/>
+
+                <!-- RRTMG SW ONLY: -->
+                <var name="swdnflx"       type="real"     dimensions="nVertLevelsP2 nCells Time"   streams="o"/>
+                <var name="swdnflxc"      type="real"     dimensions="nVertLevelsP2 nCells Time"   streams="o"/>
+                <var name="swupflx"       type="real"     dimensions="nVertLevelsP2 nCells Time"   streams="o"/>
+                <var name="swupflxc"      type="real"     dimensions="nVertLevelsP2 nCells Time"   streams="o"/>
+
+
+                <!-- ================================================================================================== -->
+                <!-- ... PARAMETERIZATION OF LONGWAVE RADIATION:                                                        -->
+                <!-- ================================================================================================== -->
+
+                <!--  note: glw is the same diagnostic as lwdnb and is used in the land-surface scheme for the calcula- -->
+                <!--        tion of the surface budget. glw is always an output argument to the subroutine rrtmg_lwrad. -->
+                <!--        in contrast,lwdnb is an optional ouput argument to the subroutine rrtmg_lwrad depending on  -->
+                <!--        the presence of lwupt (or not).                                                             -->
+
+                <!--  glw       :all-sky downwelling longwave flux at bottom-of-atmosphere                      [W m-2] -->
+                <!--  lwcf      :longwave cloud forcing at top-of-atmosphere                                    [W m-2] -->
+                <!--  lwdnb     :all-sky downwelling longwave flux at bottom-of-atmosphere                      [W m-2] -->
+                <!--  lwdnbc    :clear-sky downwelling longwave flux at bottom-of-atmosphere                    [W m-2] -->
+                <!--  lwdnt     :all-sky downwelling longwave flux at top-of-atmosphere                         [W m-2] -->
+                <!--  lwdntc    :clear-sky downwelling longwave flux at top-of-atmosphere                       [W m-2] -->
+                <!--  lwupb     :all-sky upwelling longwave flux at bottom-of-atmosphere                        [W m-2] -->
+                <!--  lwupbc    :clear-sky upwelling longwave flux at bottom-of-atmosphere                      [W m-2] -->
+                <!--  lwupt     :all-sky upwelling longwave flux at top-of-atmosphere                           [W m-2] -->
+                <!--  lwuptc    :clear-sky upwelling longwave flux at top-of-atmosphere                         [W m-2] -->
+                <!--  aclwdnb   :accumulated all-sky downwelling longwave flux at bottom-of-atmosphere          [J m-2] -->
+                <!--  aclwdnbc  :accumulated clear-sky downwelling longwave flux at bottom-of-atmosphere        [J m-2] -->
+                <!--  aclwdnt   :accumulated all-sky downwelling longwave flux at top-of-atmosphere             [J m-2] -->
+                <!--  aclwdntc  :accumulated clear-sky downwelling longwave flux at top-of-atmosphere           [J m-2] -->
+                <!--  aclwupb   :accumulated all-sky upwelling longwave flux at bottom-of-atmosphere            [J m-2] -->
+                <!--  aclwupbc  :accumulated clear-sky upwelling longwave flux at bottom-of-atmosphere          [J m-2] -->
+                <!--  aclwupt   :accumulated all-sky upwelling longwave flux at top-of-atmosphere               [J m-2] -->
+                <!--  aclwuptc  :accumulated clear-sky upwelling longwave flux at top-of-atmosphere             [J m-2] -->
+                <!--  lwdnflx   :                                                                                       -->
+                <!--  lwdnflxc  :                                                                                       -->
+                <!--  lwupflx   :                                                                                       -->
+                <!--  lwupflxc  :                                                                                       -->
+                <!--  olrtoa    :outgoing longwave radiation at top-of-the-atmosphere                           [W m-2] -->
+
+                <!--  i_aclwdnb : counter related to how often lwdnb is begin reset relative to its bucket value    (-) -->
+                <!--  i_aclwdnbc: counter related to how often lwdnbc is begin reset relative to its bucket value   (-) -->
+                <!--  i_aclwdnt : counter related to how often lwdnt is begin reset relative to its bucket value    (-) -->
+                <!--  i_aclwdntc: counter related to how often lwdntc is begin reset relative to its bucket value   (-) -->
+                <!--  i_aclwupb : counter related to how often lwupb is begin reset relative to its bucket value    (-) -->
+                <!--  i_aclwupbc: counter related to how often lwupbc is begin reset relative to its bucket value   (-) -->
+                <!--  i_aclwupt : counter related to how often lwupt is begin reset relative to its bucket value    (-) -->
+                <!--  i_aclwuptc: counter related to how often lwuptc is begin reset relative to its bucket value   (-) -->
+
+                <var name="i_aclwdnb"     type="integer"  dimensions="nCells Time"                 streams="ro"/>
+                <var name="i_aclwdnbc"    type="integer"  dimensions="nCells Time"                 streams="ro"/>
+                <var name="i_aclwdnt"     type="integer"  dimensions="nCells Time"                 streams="ro"/>
+                <var name="i_aclwdntc"    type="integer"  dimensions="nCells Time"                 streams="ro"/>
+                <var name="i_aclwupb"     type="integer"  dimensions="nCells Time"                 streams="ro"/>
+                <var name="i_aclwupbc"    type="integer"  dimensions="nCells Time"                 streams="ro"/>
+                <var name="i_aclwupt"     type="integer"  dimensions="nCells Time"                 streams="ro"/>
+                <var name="i_aclwuptc"    type="integer"  dimensions="nCells Time"                 streams="ro"/>
+
+                <var name="lwcf"          type="real"     dimensions="nCells Time"                 streams="o"/>
+                <var name="lwdnb"         type="real"     dimensions="nCells Time"                 streams="o"/>
+                <var name="lwdnbc"        type="real"     dimensions="nCells Time"                 streams="o"/>
+                <var name="lwdnt"         type="real"     dimensions="nCells Time"                 streams="o"/>
+                <var name="lwdntc"        type="real"     dimensions="nCells Time"                 streams="o"/>
+                <var name="lwupb"         type="real"     dimensions="nCells Time"                 streams="o"/>
+                <var name="lwupbc"        type="real"     dimensions="nCells Time"                 streams="o"/>
+                <var name="lwupt"         type="real"     dimensions="nCells Time"                 streams="o"/>
+                <var name="lwuptc"        type="real"     dimensions="nCells Time"                 streams="o"/>
+                <var name="aclwdnb"       type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="aclwdnbc"      type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="aclwdnt"       type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="aclwdntc"      type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="aclwupb"       type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="aclwupbc"      type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="aclwupt"       type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="aclwuptc"      type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="olrtoa"        type="real"     dimensions="nCells Time"                 streams="o"/>
+                <var name="glw"           type="real"     dimensions="nCells Time"                 streams="ro"/>
+
+                <!-- ... RRTMG LW ONLY: -->
+                <!-- var name="lwdnflx"       type="real"     dimensions="nVertLevelsP2 nCells Time"   streams="o" -->
+                <!-- var name="lwdnflxc"      type="real"     dimensions="nVertLevelsP2 nCells Time"   streams="o" -->
+                <!-- var name="lwupflx"       type="real"     dimensions="nVertLevelsP2 nCells Time"   streams="o" -->
+                <!-- var name="lwupflxc"      type="real"     dimensions="nVertLevelsP2 nCells Time"   streams="o" -->
+
+
+                <!-- ================================================================================================== -->
+                <!-- ... ADDITIONAL "RADIATION" ARRAYS NEEDED ONLY IN THE "CAM" LW AND SW RADIATION CODES:              -->
+                <!-- ================================================================================================== -->
+
+                <!-- INFRARED ABSORPTION: -->
+                <var name="absnxt"        type="real"     dimensions="nVertLevels cam_dim1 nCells Time"/>
+                <var name="abstot"        type="real"     dimensions="nVertLevelsP1 nVertLevelsP1 nCells Time"/>
+                <var name="emstot"        type="real"     dimensions="nVertLevelsP1 nCells Time"/>
+
+
+                <!-- ================================================================================================== -->
+                <!-- ... PARAMERIZATION OF CLOUDINESS:                                                                  -->
+                <!-- ================================================================================================== -->
+                <var name="cldfrac"       type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+
+
+                <!-- ================================================================================================== -->
+                <!-- ... PARAMETERIZATION OF LAND-SURFACE SCHEME:                                                       -->
+                <!-- ================================================================================================== -->
+
+                <!-- acsnom         :accumulated melted snow                                                   [kg m-2] -->
+                <!-- acsnow         :accumulated snow                                                          [kg m-2] -->
+                <!-- canwat         :canopy water                                                              [kg m-2] -->
+                <!-- chklowq        :surface saturation flag                                                        [-] -->
+                <!-- grdflx         :ground heat flux                                                           [W m-2] -->
+                <!-- lai            :leaf area index                                                                [-] -->
+                <!-- noahres        :residual of the noah land-surface scheme energy budget                     [W m-2] -->
+                <!-- potevp         :potential evaporation                                                      [W m-2] -->
+                <!-- qz0            :specific humidity at znt                                                 [kg kg-1] -->
+                <!-- rib            :??                                                                                 -->
+                <!-- sfc_albedo     :surface albedo                                                                 [-] -->
+                <!-- sfc_embck      :background emissivity                                                          [-] -->
+                <!-- sfc_emiss      :surface emissivity                                                             [-] -->
+                <!-- sfcrunoff      :surface runoff                                                             [m s-1] -->
+                <!-- smstav         :moisture availability                                                          [-] -->
+                <!-- smstot         :total moisture                                                            [m3 m-3] -->
+                <!-- snopcx         :snow phase change heat flux                                                [W m-2] -->
+                <!-- snotime        :??                                                                                 -->
+                <!-- sstsk          : skin sea-surface temperature                                                  [K] -->
+                <!-- sstsk_diur     : skin sea-surface temperature difference                                       [K] -->
+                <!-- thc            :thermal inertia                                               [Cal cm-1 K-1 s-0.5] -->
+                <!-- udrunoff       :sub-surface runoff                                                         [m s-1] -->
+                <!-- xicem          :ice mask from previous time-step                                               [-] -->
+                <!-- z0             :background roughness length                                                    [m] -->
+                <!-- zs             :depth of centers of soil layers                                                [m] -->
+
+                <var name="acsnom"        type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="acsnow"        type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="canwat"        type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="chklowq"       type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="grdflx"        type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="lai"           type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="noahres"       type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="potevp"        type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="qz0"           type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="rib"           type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="sfc_albedo"    type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="sfc_emiss"     type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="sfc_emibck"    type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="sfcrunoff"     type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="smstav"        type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="smstot"        type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="snopcx"        type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="snotime"       type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="sstsk"         type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="sstsk_diur"    type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="thc"           type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="udrunoff"      type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="xicem"         type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="z0"            type="real"     dimensions="nCells Time"                 streams="ro"/>
+                <var name="zs"            type="real"     dimensions="nCells Time"                 streams="ro"/>
+        </var_struct>
+
+        <var_struct name="tend_physics" time_levs="1">
+ 
+                <!-- ================================================================================================== -->
+                <!-- TENDENCIES FROM PARAMETERIZATION OF CONVECTION:                                                    -->
+                <!-- ================================================================================================== -->
+                <!-- rthcuten  : tendency of potential temperature due to cumulus convection                   (K s-1)  -->
+                <!-- rqvcuten  : tendency of water vapor mixing ratio due to cumulus convection            (kg/kg s-1)  -->
+                <!-- rqccuten  : tendency of cloud water mixing ratio due to cumulus convection            (kg/kg s-1)  -->
+                <!-- rqicuten  : tendency of cloud ice mixing ratio due to cumulus convection              (kg/kg s-1)  -->
+
+                <var name="rthcuten"    type="real"     dimensions="nVertLevels nCells Time"     streams="ro"/>
+                <var name="rqvcuten"    type="real"     dimensions="nVertLevels nCells Time"     streams="ro"/>
+                <var name="rqccuten"    type="real"     dimensions="nVertLevels nCells Time"     streams="ro"/>
+                <var name="rqicuten"    type="real"     dimensions="nVertLevels nCells Time"     streams="ro"/>
+
+                <!-- KAIN_FRITSCH -->
+                <!-- rqrcuten  : tendency of rain mixing ratio due to cumulus convection                   (kg/kg s-1) -->
+                <!-- rqscuten  : tendency of snow mixing ratio due to cumulus convection                   (kg/kg s-1) -->
+
+                <var name="rqrcuten"    type="real"     dimensions="nVertLevels nCells Time"     streams="ro"/>
+                <var name="rqscuten"    type="real"     dimensions="nVertLevels nCells Time"     streams="ro"/>
+
+                <!-- TIEDTKE -->
+                <!-- rucuten   : tendency of zonal wind due to cumulus convection                              (m/s-1) -->
+                <!-- rvcuten   : tendency of meridional wind due to cumulus convection                         (m/s-1) -->
+                <!-- rqvdynten : tendency of water vapor due to horizontal and vertical advections         (kg/kg/s-1) -->
+                <var name="rqvdynten"   type="real"     dimensions="nVertLevels nCells Time"     streams="ro"/>
+                <var name="rucuten"     type="real"     dimensions="nVertLevels nCells Time"     streams="ro"/>
+                <var name="rvcuten"     type="real"     dimensions="nVertLevels nCells Time"     streams="ro"/>
+
+
+                <!-- ================================================================================================== -->
+                <!-- ... TENDENCIES FROM PARAMETERIZATION OF PLANETARY BOUNDARY LAYER PROCESSES:                        -->
+                <!-- ================================================================================================== -->
+                <!-- rublten   : tendency of zonal wind due to pbl processes                                   (m s-1)  -->
+                <!-- rvblten   : tendency of meridional wind due to pbl processes                              (m s-1)  -->
+                <!-- rthblten  : tendency of potential temperature due to pbl processes                        (K s-1)  -->
+                <!-- rqvblten  : tendency of water vapor mixing ratio due to pbl processes                 (kg/kg s-1)  -->
+                <!-- rqcblten  : tendency of cloud water mixing ratio due to pbl processes                 (kg/kg s-1)  -->
+                <!-- rqiblten  : tendency of cloud ice mixing ratio due to pbl processes                   (kg/kg s-1)  -->
+
+                <var name="rublten"     type="real"     dimensions="nVertLevels nCells Time"     streams="ro"/>
+                <var name="rvblten"     type="real"     dimensions="nVertLevels nCells Time"     streams="ro"/>
+                <var name="rthblten"    type="real"     dimensions="nVertLevels nCells Time"     streams="ro"/>
+                <var name="rqvblten"    type="real"     dimensions="nVertLevels nCells Time"     streams="ro"/>
+                <var name="rqcblten"    type="real"     dimensions="nVertLevels nCells Time"     streams="ro"/>
+                <var name="rqiblten"    type="real"     dimensions="nVertLevels nCells Time"     streams="ro"/>
+
+
+                <!-- ================================================================================================== -->
+                <!-- ... TENDENCIES FROM PARAMETERIZATION OF LONGWAVE RADIATION:                                        -->
+                <!-- ================================================================================================== -->
+                <!--  rthratensw:uncoupled theta tendency due to shortwave radiation                            [K s-1] -->
+                <!--  rthratenlw:uncoupled theta tendency due to longwave radiation                             [K s-1] -->
+
+                <var name="rthratensw"  type="real"     dimensions="nVertLevels nCells Time"     streams="ro"/>
+                <var name="rthratenlw"  type="real"     dimensions="nVertLevels nCells Time"     streams="ro"/>
+        </var_struct>
+
+        <var_struct name="sfc_input" time_levs="0">
+
+                <!-- ================================================================================================== -->
+                <!-- ... SURFACE CHARACTERISTICS THAT NEED TO BE READ FROM GRID.NC:                                     -->
+                <!-- ================================================================================================== -->
+
+                <!--  albedo12m      :monthly climatological albedo                                                 [-] -->
+                <!--  greenfrac      :monthly climatological greeness fraction                                      [-] -->
+                <!--  isltyp         :dominant soil category                                                        [-] -->
+                <!--  ivgtyp         :dominant vegetation category                                                  [-] -->
+                <!--  landmask       :=0 for ocean;=1 for land                                                      [-] -->
+                <!--  sfc_albbck     :background albedo                                                             [-] -->
+                <!--  shdmin         :minimum areal fractional coverage of annual green vegetation                  [-] -->
+                <!--  shdmax         :maximum areal fractional coverage of annual green vegetation                  [-] -->
+                <!--  skintemp       :skin temperature                                                              [K] -->
+                <!--  snoalb         :annual max snow albedo                                                        [-] -->
+                <!--  snow           :snow water equivalent                                                    [kg m-2] -->
+                <!--  sst            :sea-surface temperature                                                       [K] -->
+                <!--  snowc          :flag indicating snow coverage (1 for snow cover)                              [-] -->
+                <!--  snowh          :physical snow depth                                                           [m] -->
+                <!--  ter            :terrain height                                                                [-] -->
+                <!--  tmn            :soil temperature at lower boundary                                            [K] -->
+                <!--  vegfra         :vegetation fraction                                                           [-] -->
+                <!--  seaice         :sea-ice mask (=1 when xice is greater than 0; =0 otherwise)                   [-] -->
+                <!--  xice           :fractional sea-ice coverage                                                   [-] -->
+                <!--  xland          :land mask    (1 for land; 2 for water)                                        [-] -->
+
+                <!--  dzs            :thickness of soil layers                                                      [m] -->
+                <!--  smcrel         :soil moisture threshold below which transpiration begins to stress            [-] -->
+                <!--  sh2o           :soil liquid water                                                        [m3 m-3] -->
+                <!--  smois          :soil moisture                                                            [m3 m-3] -->
+                <!--  tslb           :soil temperature                                                              [K] -->
+
+                <var name="isltyp"      type="integer"  dimensions="nCells"                      streams="iro"/>
+                <var name="ivgtyp"      type="integer"  dimensions="nCells"                      streams="iro"/>
+                <var name="landmask"    type="integer"  dimensions="nCells"                      streams="iro"/>
+                <var name="shdmin"      type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="shdmax"      type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="snoalb"      type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="ter"         type="real"     dimensions="nCells"                      streams="io"/>
+                <var name="albedo12m"   type="real"     dimensions="nMonths nCells"              streams="iro"/>
+                <var name="greenfrac"   type="real"     dimensions="nMonths nCells"              streams="iro"/>
+
+                <var name="sfc_albbck"  type="real"     dimensions="nCells Time"                 streams="iro"/>
+                <var name="skintemp"    type="real"     dimensions="nCells Time"                 streams="iro"/>
+                <var name="snow"        type="real"     dimensions="nCells Time"                 streams="iro"/>
+                <var name="snowc"       type="real"     dimensions="nCells Time"                 streams="iro"/>
+                <var name="snowh"       type="real"     dimensions="nCells Time"                 streams="iro"/>
+                <var name="sst"         type="real"     dimensions="nCells Time"                 streams="isro"/>
+                <var name="tmn"         type="real"     dimensions="nCells Time"                 streams="iro"/>
+                <var name="vegfra"      type="real"     dimensions="nCells Time"                 streams="iro"/>
+                <var name="seaice"      type="real"     dimensions="nCells Time"                 streams="iro"/>
+                <var name="xice"        type="real"     dimensions="nCells Time"                 streams="isro"/>
+                <var name="xland"       type="real"     dimensions="nCells Time"                 streams="iro"/>
+
+                <var name="dzs"         type="real"     dimensions="nSoilLevels nCells Time"     streams="iro"/>
+                <var name="smcrel"      type="real"     dimensions="nSoilLevels nCells Time"     streams="ro"/>
+                <var name="sh2o"        type="real"     dimensions="nSoilLevels nCells Time"     streams="iro"/>
+                <var name="smois"       type="real"     dimensions="nSoilLevels nCells Time"     streams="iro"/>
+                <var name="tslb"        type="real"     dimensions="nSoilLevels nCells Time"     streams="iro"/>
+        </var_struct>
+</registry>
Index: trunk/mpas/src/core_ocean
===================================================================
--- trunk/mpas/src/core_ocean        2013-03-22 17:48:50 UTC (rev 2662)
+++ trunk/mpas/src/core_ocean        2013-03-22 19:32:26 UTC (rev 2663)
Property changes on: trunk/mpas/src/core_ocean
___________________________________________________________________
Modified: svn:mergeinfo
## -35,3 +35,4 ##
 /branches/scratch_indication/src/core_ocean:2555-2656
 /branches/source_renaming/src/core_ocean:1082-1113
 /branches/time_manager/src/core_ocean:924-962
+/branches/xml_registry/src/core_ocean:2610-2662
\ No newline at end of property
Copied: trunk/mpas/src/core_ocean/Registry.xml (from rev 2662, branches/xml_registry/src/core_ocean/Registry.xml)
===================================================================
--- trunk/mpas/src/core_ocean/Registry.xml                                (rev 0)
+++ trunk/mpas/src/core_ocean/Registry.xml        2013-03-22 19:32:26 UTC (rev 2663)
@@ -0,0 +1,1071 @@
+<?xml version="1.0"?>
+<registry>
+        <dims>
+                <dim name="nCells" units="unitless"
+                     description="The number of polygons in the primary grid."
+                />
+                <dim name="nEdges" units="unitless"
+                     description="The number of edge midpoints in either the primary or dual grid."
+                />
+                <dim name="maxEdges" units="unitless"
+                     description="The largest number of edges any polygon within the grid has."
+                />
+                <dim name="maxEdges2" units="unitless"
+                     description="Two times the largest number of edges any polygon within the grid has."
+                />
+                <dim name="nAdvectionCells" definition="maxEdges2+0" units="unitless"
+                     description="The largest number of advection cells for any edge."
+                />
+                <dim name="nVertices" units="unitless"
+                     description="The total number of cells in the dual grid. Also the number of corners in the primary grid."
+                />
+                <dim name="TWO" definition="2" units="unitless"
+                     description="The number two as a dimension."
+                />
+                <dim name="R3" definition="3" units="unitless"
+                     description="The number three as a dimension."
+                />
+                <dim name="FIFTEEN" definition="15" units="unitless"
+                     description="The number 15 as a dimension."
+                />
+                <dim name="TWENTYONE" definition="21" units="unitless"
+                     description="The number 21 as a dimension."
+                />
+                <dim name="vertexDegree" units="unitless"
+                     description="The number of cells or edges touching each vertex."
+                />
+                <dim name="nVertLevels" units="unitless"
+                     description="The number of levels in the vertical direction. All vertical levels share the same horizontal locations."
+                />
+                <dim name="nVertLevelsP1" definition="nVertLevels+1" units="unitless"
+                     description="The number of interfaces in the vertical direction."
+                />
+                <dim name="nMonths" units="unitless"
+                         description="The number of forcing slices in the monthly forcing fields. {\bf \color{red} Deprecated. Should be removed.}"
+                />
+        </dims>
+        <nml_record name="time_management">
+                <nml_option name="config_do_restart" type="logical" default_value=".false." units="unitless"
+                            description="Determines if the initial conditions should be read from a restart file, or an input file."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_start_time" type="character" default_value="'0000-01-01_00:00:00'" units="unitless"
+                            description="Timestamp describing the initial time of the simulation. If it is set to 'file', the initial time is read from restart_timestamp."
+                            possible_values="'YYYY-MM-DD_HH:MM:SS' or 'file'"
+                />
+                <nml_option name="config_stop_time" type="character" default_value="'none'" units="unitless"
+                            description="Timestamp descriping the final time of the simulation. If it is set to 'none' the final time is determined from config_start_time and config_run_duration."
+                            possible_values="'YYYY-MM-DD_HH:MM:SS' or 'none'"
+                />
+                <nml_option name="config_run_duration" type="character" default_value="'0_06:00:00'" units="unitless"
+                            description="Timestamp describing the length of the simulation. If it is set to 'none' the duraction is determined from config_start_time and config_stop_time. config_run_duration overrides inconsistent values of config_stop_time."
+                            possible_values="'DDDD_HH:MM:SS' or 'none'"
+                />
+                <nml_option name="config_calendar_type" type="character" default_value="'360day'" units="unitless"
+                            description="Selection of the type of calendar that should be used in the simulation."
+                            possible_values="'gregorian', 'gregorian_noleap', or '360day'"
+                />
+        </nml_record>
+        <nml_record name="io">
+                <nml_option name="config_input_name" type="character" default_value="'grid.nc'" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_output_name" type="character" default_value="'output.nc'" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_restart_name" type="character" default_value="'restart.nc'" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_restart_interval" type="character" default_value="'0_06:00:00'" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_output_interval" type="character" default_value="'0_06:00:00'" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_stats_interval" type="character" default_value="'0_01:00:00'" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_write_stats_on_startup" type="logical" default_value=".true." units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_write_output_on_startup" type="logical" default_value=".true." units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_frames_per_outfile" type="integer" default_value="1000" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_pio_num_iotasks" type="integer" default_value="0" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_pio_stride" type="integer" default_value="1" units=""
+                            description=""
+                            possible_values=""
+                />
+        </nml_record>
+        <nml_record name="time_integration">
+                <nml_option name="config_dt" type="real" default_value="3000.0" units="s"
+                            description="Length of model time-step."
+                            possible_values="Any positive real value, but limited by CFL condition."
+                />
+                <nml_option name="config_time_integrator" type="character" default_value="'split_explicit'" units="unitless"
+                            description="Time integration method."
+                            possible_values="'split_explicit', 'RK4', 'unsplit_explicit'"
+                />
+        </nml_record>
+        <nml_record name="grid">
+                <nml_option name="config_num_halos" type="integer" default_value="3" units="unitless"
+                            description="Determines the number of halo cells extending from a blocks owned cells (Called the 0-Halo). The default of 3 is the minimum that can be used with monotonic advection."
+                            possible_values="Any positive interger value."
+                />
+                <nml_option name="config_vert_coord_movement" type="character" default_value="'uniform_stretching'" units="unitless"
+                            description="Determines the vertical coordinate movement type. 'uniform_stretching' distrubtes SSH perturbations through all vertical levels, 'fixed' places them all in the top level, 'user_specified' allows the input file to determine the distribution, and 'isopycnal' causes levels to be pure isopycnal."
+                            possible_values="'uniform_stretching', 'fixed', 'user_specified', 'isopycnal'"
+                />
+                <nml_option name="config_alter_ICs_for_pbcs" type="character" default_value="'zlevel_pbcs_off'" units="unitless"
+                            description="Determines the method of alteration for partial bottom cells. 'zlevel_pbcs_on' alters the initial conditions for partial bottom cells, 'zlevel_pbcs_off' alters the initial conditions to have full cells everwhere, and 'off' does nothing to the initial conditions."
+                            possible_values="'zlevel_pbcs_on', 'zlevel_pbcs_off', 'off'"
+                />
+                <nml_option name="config_min_pbc_fraction" type="real" default_value="0.10" units="unitless"
+                            description="Determines the minimum fraction of a cell altering the initial conditions can create."
+                            possible_values="Any real between 0 and 1."
+                />
+                <nml_option name="config_check_ssh_consistency" type="logical" default_value=".true." units=""
+                            description="Enables a check to determine if the SSH is consistent across relevant variables."
+                            possible_values=""
+                />
+        </nml_record>
+        <nml_record name="decomposition">
+                <nml_option name="config_block_decomp_file_prefix" type="character" default_value="'graph.info.part.'" units="unitless"
+                            description="Defines the prefix for the block decomposition file. Can include a path. The number of blocks is appended to the end of the prefix at run-time."
+                                        possible_values="Any path/prefix to a block decomposition file."
+                />
+                <nml_option name="config_number_of_blocks" type="integer" default_value="0" units="unitless"
+                            description="Determines the number of blocks a simulation should be run with. If it is set to 0, the number of blocks is the same as the number of MPI tasks at run-time."
+                                        possible_values="Any integer $>=$ 0."
+                />
+                <nml_option name="config_explicit_proc_decomp" type="logical" default_value=".false." units="unitless"
+                            description="Determines if an explicit processor decomposition should be used. This is only useful if multiple blocks per processor are used."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_proc_decomp_file_prefix" type="character" default_value="'graph.info.part.'" units="unitless"
+                            description="Defines the prefix for the processor decomposition file. This file is only read if config_explicit_proc_decomp is .true. The number of processors is appended to the end of the prefix at run-time."
+                                        possible_values="Any path/prefix to a processor decomposition file."
+                />
+        </nml_record>
+        <nml_record name="hmix">
+                <nml_option name="config_hmix_ScaleWithMesh" type="logical" default_value=".false." units="unitless"
+                            description="If false, del2 and del4 coefficients are constant throughout the mesh (equivalent to setting $\rho_m=1$ throughout the mesh).  If true, these coefficients scale as mesh density to the -3/4 power."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_visc_vorticity_term" type="logical" default_value=".true." units="unitless"
+                            description="{\color{red} TO BE DELETED}"
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_apvm_scale_factor" type="real" default_value="0.0" units="unitless"
+                            description="Anticipated potential vorticity (APV) method scale factor, $c_{apv}$.  When zero, APV is off."
+                            possible_values="Any non-negative number, typically between zero and one."
+                />
+        </nml_record>
+        <nml_record name="hmix_del2">
+                <nml_option name="config_use_mom_del2" type="logical" default_value=".false." units="unitless"
+                            description="If true, Laplacian horizontal mixing is used on the momentum equation."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_use_tracer_del2" type="logical" default_value=".false." units="unitless"
+                            description="If true, Laplacian horizontal mixing is used on the tracer equation."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_mom_del2" type="real" default_value="0.0" units="m^2 s^{-1}"
+                            description="Horizonal viscosity, $</font>
<font color="gray">u_h$."
+                            possible_values="any positive real"
+                />
+                <nml_option name="config_tracer_del2" type="real" default_value="0.0" units="m^2 s^{-1}"
+                            description="Horizonal diffusion, $\kappa_h$."
+                            possible_values="any positive real"
+                />
+                <nml_option name="config_vorticity_del2_scale" type="real" default_value="1.0" units="unitless"
+                            description="{\color{red} TO BE DELETED}"
+                            possible_values=""
+                />
+        </nml_record>
+        <nml_record name="hmix_del4">
+                <nml_option name="config_use_mom_del4" type="logical" default_value=".true." units="unitless"
+                            description="If true, biharmonic horizontal mixing is used on the momentum equation."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_use_tracer_del4" type="logical" default_value=".false." units="unitless"
+                            description="If true, biharmonic horizontal mixing is used on the tracer equation."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_mom_del4" type="real" default_value="5.0e13" units="m^4 s^{-1}"
+                            description="Coefficient for horizontal biharmonic operator on momentum."
+                            possible_values="any positive real"
+                />
+                <nml_option name="config_tracer_del4" type="real" default_value="0.0" units="m^4 s^{-1}"
+                            description="Coefficient for horizontal biharmonic operator on tracers."
+                            possible_values="any positive real"
+                />
+                <nml_option name="config_vorticity_del4_scale" type="real" default_value="1.0" units=""
+                            description="{\color{red} TO BE DELETED}"
+                            possible_values=""
+                />
+        </nml_record>
+        <nml_record name="hmix_Leith">
+                <nml_option name="config_use_Leith_del2" type="logical" default_value=".false." units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_Leith_parameter" type="real" default_value="1.0" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_Leith_dx" type="real" default_value="15000.0" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_Leith_visc2_max" type="real" default_value="2.5e3" units=""
+                            description=""
+                            possible_values=""
+                />
+        </nml_record>
+        <nml_record name="standard_GM">
+                <nml_option name="config_h_kappa" type="real" default_value="0.0" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_h_kappa_q" type="real" default_value="0.0" units=""
+                            description=""
+                            possible_values=""
+                />
+        </nml_record>
+        <nml_record name="Rayleigh_damping">
+                <nml_option name="config_Rayleigh_friction" type="logical" default_value=".false." units="unitless"
+                            description="If true, Rayleigh friction is included in the momentum equation."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_Rayleigh_damping_coeff" type="real" default_value="0.0" units="s^{-1}"
+                            description="Inverse-time coefficient for the Rayleigh damping term, $c_R$."
+                            possible_values="Any positive real value."
+                />
+        </nml_record>
+        <nml_record name="vmix">
+                <nml_option name="config_convective_visc" type="real" default_value="1.0" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_convective_diff" type="real" default_value="1.0" units=""
+                            description=""
+                            possible_values=""
+                />
+        </nml_record>
+        <nml_record name="vmix_const">
+                <nml_option name="config_use_const_visc" type="logical" default_value=".false." units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_use_const_diff" type="logical" default_value=".false." units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_vert_visc" type="real" default_value="2.5e-4" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_vert_diff" type="real" default_value="2.5e-5" units=""
+                            description=""
+                            possible_values=""
+                />
+        </nml_record>
+        <nml_record name="vmix_rich">
+                <nml_option name="config_use_rich_visc" type="logical" default_value=".true." units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_use_rich_diff" type="logical" default_value=".true." units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_bkrd_vert_visc" type="real" default_value="1.0e-4" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_bkrd_vert_diff" type="real" default_value="1.0e-5" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_rich_mix" type="real" default_value="0.005" units=""
+                            description=""
+                            possible_values=""
+                />
+        </nml_record>
+        <nml_record name="vmix_tanh">
+                <nml_option name="config_use_tanh_visc" type="logical" default_value=".false." units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_use_tanh_diff" type="logical" default_value=".false." units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_max_visc_tanh" type="real" default_value="2.5e-1" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_min_visc_tanh" type="real" default_value="1.0e-4" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_max_diff_tanh" type="real" default_value="2.5e-2" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_min_diff_tanh" type="real" default_value="1.0e-5" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_zMid_tanh" type="real" default_value="-100" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_zWidth_tanh" type="real" default_value="100" units=""
+                            description=""
+                            possible_values=""
+                />
+        </nml_record>
+        <nml_record name="forcing">
+                <nml_option name="config_use_monthly_forcing" type="logical" default_value=".false." units="unitless"
+                            description="Controls time frequency of forcing.  If false, a constant forcing is used, provided by the input fields u_src, temperatureRestore, and salinityRestore.  If true, forcing is interpolated between monthly fields given by windStressMonthly, temperatureRestoreMonthly, and salinityRestoreMonthly."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_restoreTS" type="logical" default_value=".false." units="unitless"
+                            description="If true, the restoring term is activated in the tracer equation for temperature and salinity."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_restoreT_timescale" type="real" default_value="90.0" units="days"
+                            description="Restoring timescale for temperature, $\tau_r.$"
+                            possible_values="any positive real value, but typically between 30 and 90 days."
+                />
+                <nml_option name="config_restoreS_timescale" type="real" default_value="90.0" units="days"
+                            description="Restoring timescale for salinity, $\tau_r$."
+                            possible_values="any positive real value, but typically between 30 and 90 days."
+                />
+        </nml_record>
+        <nml_record name="advection">
+                <nml_option name="config_vert_tracer_adv" type="character" default_value="'stencil'" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_vert_tracer_adv_order" type="integer" default_value="3" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_horiz_tracer_adv_order" type="integer" default_value="3" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_coef_3rd_order" type="real" default_value="0.25" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_monotonic" type="logical" default_value=".true." units=""
+                            description=""
+                            possible_values=""
+                />
+        </nml_record>
+        <nml_record name="bottom_drag">
+                <nml_option name="config_bottom_drag_coeff" type="real" default_value="1.0e-3" units="unitless"
+                            description="Dimensionless bottom drag coefficient, $c_{drag}$."
+                            possible_values="any positive real, typically 1.0e-3"
+                />
+        </nml_record>
+        <nml_record name="pressure_gradient">
+                <nml_option name="config_pressure_gradient_type" type="character" default_value="'pressure_and_zmid'" units="unitless"
+                            description="Form of pressure gradient terms in momentum equation. For most applications, the gradient of pressure and layer mid-depth are appropriate.  For isopycnal coordinates, one may use the gradient of the Montgomery potential."
+                            possible_values="'pressure_and_zmid' or 'MontgomeryPotential'"
+                />
+                <nml_option name="config_rho0" type="real" default_value="1014.65" units="kg m^{-3}"
+                            description="Density used as a coefficient of the pressure gradient terms, $\rho_0$.  This is a constant due to the Boussinesq approximation."
+                            possible_values="any positive real, but typically 1000-1035"
+                />
+        </nml_record>
+        <nml_record name="eos">
+                <nml_option name="config_eos_type" type="character" default_value="'jm'" units=""
+                            description=""
+                            possible_values=""
+                />
+        </nml_record>
+        <nml_record name="eos_linear">
+                <nml_option name="config_eos_linear_alpha" type="real" default_value="2.55e-1" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_eos_linear_beta" type="real" default_value="7.64e-1" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_eos_linear_Tref" type="real" default_value="19.0" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_eos_linear_Sref" type="real" default_value="35.0" units=""
+                            description=""
+                            possible_values=""
+                />
+                <nml_option name="config_eos_linear_rhoref" type="real" default_value="1025.022" units=""
+                            description=""
+                            possible_values=""
+                />
+        </nml_record>
+        <nml_record name="split_explicit_ts">
+                <nml_option name="config_n_ts_iter" type="integer" default_value="2" units="unitless"
+                            description="number of large iterations over stages 1-3"
+                            possible_values="any positive integer, but typically 1, 2, or 3"
+                />
+                <nml_option name="config_n_bcl_iter_beg" type="integer" default_value="1" units="unitless"
+                            description="number of iterations of stage 1 (baroclinic solve) on the first split-explicit iteration"
+                            possible_values="any positive integer, but typically 1, 2, or 3"
+                />
+                <nml_option name="config_n_bcl_iter_mid" type="integer" default_value="2" units="unitless"
+                            description="number of iterations of stage 1 (baroclinic solve) on any split-explicit iterations between first and last"
+                            possible_values="any positive integer, but typically 1, 2, or 3"
+                />
+                <nml_option name="config_n_bcl_iter_end" type="integer" default_value="2" units="unitless"
+                            description="number of iterations of stage 1 (baroclinic solve) on the last split-explicit iteration"
+                            possible_values="any positive integer, but typically 1, 2, or 3"
+                />
+                <nml_option name="config_n_btr_subcycles" type="integer" default_value="20" units="unitless"
+                            description="number of barotropic subcycles in stage 2"
+                            possible_values="any positive integer, typically between 10 and 100"
+                />
+                <nml_option name="config_n_btr_cor_iter" type="integer" default_value="2" units="unitless"
+                            description="number of iterations of the velocity corrector step in stage 2"
+                            possible_values="any positive integer, but typically 1, 2, or 3"
+                />
+                <nml_option name="config_u_correction" type="logical" default_value=".true." units="unitless"
+                            description="If true, the velocity correction term is included in the horizontal advection of thickness and tracers"
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_btr_subcycle_loop_factor" type="integer" default_value="2" units="unitless"
+                            description="Barotropic subcycles proceed from $t$ to $t+n\Delta t$, where $n$ is this configuration option."
+                            possible_values="Any positive integer, but typically 1 or 2"
+                />
+                <nml_option name="config_btr_gam1_uWt1" type="real" default_value="0.5" units="unitless"
+                            description="Weighting of velocity in the SSH predictor step in stage 2.  When zero, previous subcycle time is used; when one, new subcycle time is used."
+                            possible_values="between 0 and 1"
+                />
+                <nml_option name="config_btr_gam2_SSHWt1" type="real" default_value="1.0" units="unitless"
+                            description="Weighting of SSH in the velocity corrector step in stage 2.  When zero, previous subcycle time is used; when one, new subcycle time is used."
+                            possible_values="between 0 and 1"
+                />
+                <nml_option name="config_btr_gam3_uWt2" type="real" default_value="1.0" units="unitless"
+                            description="Weighting of velocity in the SSH corrector step in stage 2.  When zero, previous subcycle time is used; when one, new subcycle time is used."
+                            possible_values="between 0 and 1"
+                />
+                <nml_option name="config_btr_solve_SSH2" type="logical" default_value=".false." units="unitless"
+                            description="If true, execute the SSH corrector step in stage 2"
+                            possible_values=".true. or .false."
+                />
+        </nml_record>
+        <nml_record name="debug">
+                <nml_option name="config_check_zlevel_consistency" type="logical" default_value=".false." units="unitless"
+                            description="Enables a run-time check for consistency for a zlevel grid. Ensures relevant variables correctly define the bottom of the ocean."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_filter_btr_mode" type="logical" default_value=".false." units="unitless"
+                            description="Enables filtering of the barotropic mode."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_prescribe_velocity" type="logical" default_value=".false." units="unitless"
+                            description="Enables a prescribed velocity field. This velocity field is read on input, and remains constant through a simulation."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_prescribe_thickness" type="logical" default_value=".false." units="unitless"
+                            description="Enables a prescribed thickness field. This thickness field is read on input, and remains constant through a simulation."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_include_KE_vertex" type="logical" default_value=".false." units="unitless"
+                            description=""
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_check_tracer_monotonicity" type="logical" default_value=".false." units="unitless"
+                            description="Enables a change on tracer monotonicity at the end of the monotonic advection routine. Only used if config_monotonic is set to .true."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_disable_h_all_tend" type="logical" default_value=".false." units="unitless"
+                            description="Disables all tendencies on the thickness field."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_disable_h_hadv" type="logical" default_value=".false." units="unitless"
+                            description="Disable tendencies on the thickness field from horizontal advection."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_disable_h_vadv" type="logical" default_value=".false." units="unitless"
+                            description="Disables tendencies on the thickness field from vertical advection."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_disable_u_all_tend" type="logical" default_value=".false." units="unitless"
+                            description="Disables all tendencies on the velocity field."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_disable_u_coriolis" type="logical" default_value=".false." units="unitless"
+                            description="Diables tendencies on the velocity field from the Coriolis force."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_disable_u_pgrad" type="logical" default_value=".false." units="unitless"
+                            description="Disables tendencies on the velocity field from the horizontal pressure gradient."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_disable_u_hmix" type="logical" default_value=".false." units="unitless"
+                            description="Disables tendencies on the velocity field from horizontal mixing."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_disable_u_windstress" type="logical" default_value=".false." units="unitless"
+                            description="Disables tendencies on the velocity field from horizontal wind stress."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_disable_u_vmix" type="logical" default_value=".false." units="unitless"
+                            description="Disables tendencies on the velocity field from vertical mixing."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_disable_u_vadv" type="logical" default_value=".false." units="unitless"
+                            description="Disables tendencies on the velocity field from vertical advection."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_disable_tr_all_tend" type="logical" default_value=".false." units="unitless"
+                            description="Disables all tendencies on tracer fields."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_disable_tr_adv" type="logical" default_value=".false." units="unitless"
+                            description="Disables tendencies on tracer fields from advection, both horizontal and vertical."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_disable_tr_hmix" type="logical" default_value=".false." units="unitless"
+                            description="Disables tendencies on tracer fields from horizontal mixing."
+                            possible_values=".true. or .false."
+                />
+                <nml_option name="config_disable_tr_vmix" type="logical" default_value=".false." units="unitless"
+                            description="Disables tendencies on tracer fields from vertical mixing."
+                            possible_values=".true. or .false."
+                />
+        </nml_record>
+        <var_struct name="state" time_levs="2">
+                <var_array name="tracers" type="real" dimensions="nVertLevels nCells Time">
+                        <var name="temperature" array_group="dynamics" streams="iro" units="degrees Celsius"
+                             description="potential temperature"
+                        />
+                        <var name="salinity" array_group="dynamics" streams="iro" units="grams salt per kilogram seawater"
+                             description="salinity"
+                        />
+                        <var name="tracer1" array_group="testing" streams="iro" units="unitless"
+                             description="A tracer with value 1.0 to test conservation.  {\color{red} REMOVE THIS VARIABLE}"
+                        />
+                </var_array>
+                <var name="xtime" type="text" dimensions="Time" streams="ro" units="unitless"
+                     description="model time, with format 'YYYY-MM-DD_HH:MM:SS'"
+                />
+                <var name="u" type="real" dimensions="nVertLevels nEdges Time" streams="ir" units="m s^{-1}"
+                     description="horizonal velocity, normal component to an edge"
+                />
+                <var name="h" type="real" dimensions="nVertLevels nCells Time" streams="iro" units="m"
+                     description="layer thickness"
+                />
+                <var name="rho" type="real" dimensions="nVertLevels nCells Time" streams="iro" units="kg m^{-3}"
+                     description="density"
+                />
+                <var name="uBtr" type="real" dimensions="nEdges Time" streams="r" units="m s^{-1}"
+                     description="barotropic velocity, used in split-explicit time-stepping"
+                />
+                <var name="ssh" type="real" dimensions="nCells Time" streams="o" units="m"
+                     description="sea surface height"
+                />
+                <var name="uBtrSubcycle" type="real" dimensions="nEdges Time" units="m s^{-1}"
+                     description="barotropic velocity, used in subcycling in stage 2 of split-explicit time-stepping"
+                />
+                <var name="sshSubcycle" type="real" dimensions="nCells Time" units="m"
+                     description="sea surface height, used in subcycling in stage 2 of split-explicit time-stepping"
+                />
+                <var name="FBtr" type="real" dimensions="nEdges Time" units="m^2 s^{-1}"
+                     description="Barotropic thickness flux at each edge, used to advance sea surface height in each subcycle of stage 2 of the split-explicit algorithm."
+                />
+                <var name="GBtrForcing" type="real" dimensions="nEdges Time" units="m s^{-2}"
+                     description="Barotropic tendency computed from the baroclinic equations in stage 1 of the split-explicit algorithm."
+                />
+                <var name="uBcl" type="real" dimensions="nVertLevels nEdges Time" units="m s^{-1}"
+                     description="baroclinic velocity, used in split-explicit time-stepping"
+                />
+                <var name="zMid" type="real" dimensions="nVertLevels nCells Time" units="m"
+                     description="z-coordinate of the mid-depth of the layer"
+                />
+                <var name="v" type="real" dimensions="nVertLevels nEdges Time" units="m s^{-1}"
+                     description="horizontal velocity, tangential to an edge"
+                />
+                <var name="uTransport" type="real" dimensions="nVertLevels nEdges Time" units="m s^{-1}"
+                     description="horizontal velocity used to transport mass and tracers"
+                />
+                <var name="uBolusGM" type="real" dimensions="nVertLevels nEdges Time" units=""
+                     description=""
+                />
+                <var name="uBolusGMX" type="real" dimensions="nVertLevels nEdges Time" units=""
+                     description=""
+                />
+                <var name="uBolusGMY" type="real" dimensions="nVertLevels nEdges Time" units=""
+                     description=""
+                />
+                <var name="uBolusGMZ" type="real" dimensions="nVertLevels nEdges Time" units=""
+                     description=""
+                />
+                <var name="uBolusGMZonal" type="real" dimensions="nVertLevels nEdges Time" streams="o" units=""
+                     description=""
+                />
+                <var name="uBolusGMMeridional" type="real" dimensions="nVertLevels nEdges Time" streams="o" units=""
+                     description=""
+                />
+                <var name="hEddyFlux" type="real" dimensions="nVertLevels nEdges Time" units=""
+                     description=""
+                />
+                <var name="h_kappa" type="real" dimensions="nVertLevels nEdges Time" units=""
+                     description=""
+                />
+                <var name="h_kappa_q" type="real" dimensions="nVertLevels nEdges Time" units=""
+                     description=""
+                />
+                <var name="divergence" type="real" dimensions="nVertLevels nCells Time" streams="o" units="s^{-1}"
+                     description="divergence of horizonal velocity"
+                />
+                <var name="vorticity" type="real" dimensions="nVertLevels nVertices Time" streams="o" units="s^{-1}"
+                     description="curl of horizontal velocity"
+                />
+                <var name="Vor_edge" type="real" dimensions="nVertLevels nEdges Time" units="s^{-1}"
+                     description="vorticity averaged from vertices to edges"
+                />
+                <var name="h_edge" type="real" dimensions="nVertLevels nEdges Time" units="m"
+                     description="layer thickness averaged from cell center to edges"
+                />
+                <var name="h_vertex" type="real" dimensions="nVertLevels nVertices Time" units="m"
+                     description="layer thickness averaged from cell center to vertices"
+                />
+                <var name="ke" type="real" dimensions="nVertLevels nCells Time" streams="o" units="m^2 s^{-2}"
+                     description="kinetic energy of horizonal velocity"
+                />
+                <var name="kev" type="real" dimensions="nVertLevels nVertices Time" streams="o" units="m^2 s^{-2}"
+                     description="kinetic energy of horizonal velocity defined at vertices"
+                />
+                <var name="kevc" type="real" dimensions="nVertLevels nCells Time" streams="o" units="m^2 s^{-2}"
+                     description="kinetic energy of horizonal velocity defined at vertices"
+                />
+                <var name="ke_edge" type="real" dimensions="nVertLevels nEdges Time" units="m^2 s^{-2}"
+                     description="kinetic energy of horizonal velocity defined at edges"
+                />
+                <var name="Vor_vertex" type="real" dimensions="nVertLevels nVertices Time" units="s^{-1}"
+                     description="curl of horizontal velocity defined at vertices"
+                />
+                <var name="Vor_cell" type="real" dimensions="nVertLevels nCells Time" streams="o" units="s^{-1}"
+                     description="curl of horizontal velocity defined at cell centers"
+                />
+                <var name="uReconstructX" type="real" dimensions="nVertLevels nCells Time" units="m s^{-1}"
+                     description="component of horizontal velocity in the x-direction (cartesian)"
+                />
+                <var name="uReconstructY" type="real" dimensions="nVertLevels nCells Time" units="m s^{-1}"
+                     description="component of horizontal velocity in the y-direction (cartesian)"
+                />
+                <var name="uReconstructZ" type="real" dimensions="nVertLevels nCells Time" units="m s^{-1}"
+                     description="component of horizontal velocity in the z-direction (cartesian)"
+                />
+                <var name="uReconstructZonal" type="real" dimensions="nVertLevels nCells Time" streams="o" units="m s^{-1}"
+                     description="component of horizontal velocity in the eastward direction"
+                />
+                <var name="uReconstructMeridional" type="real" dimensions="nVertLevels nCells Time" streams="o" units="m s^{-1}"
+                     description="component of horizontal velocity in the northward"
+                />
+                <var name="uSrcReconstructX" type="real" dimensions="nVertLevels nCells Time" units="N m^{-2}"
+                     description="wind stress in the x-direction (cartesian)"
+                />
+                <var name="uSrcReconstructY" type="real" dimensions="nVertLevels nCells Time" units="N m^{-2}"
+                     description="wind stress in the y-direction (cartesian)"
+                />
+                <var name="uSrcReconstructZ" type="real" dimensions="nVertLevels nCells Time" units="N m^{-2}"
+                     description="wind stress in the z-direction (cartesian)"
+                />
+                <var name="uSrcReconstructZonal" type="real" dimensions="nVertLevels nCells Time" streams="o" units="N m^{-2}"
+                     description="wind stress in the eastward direction"
+                />
+                <var name="uSrcReconstructMeridional" type="real" dimensions="nVertLevels nCells Time" streams="o" units="N m^{-2}"
+                     description="wind stress in the northward direction"
+                />
+                <var name="MontPot" type="real" dimensions="nVertLevels nCells Time" units="m^2 s^{-2}"
+                     description="Montgomery potential, may be used as the pressure for isopycnal coordinates."
+                />
+                <var name="pressure" type="real" dimensions="nVertLevels nCells Time" units="N m^{-2}"
+                     description="pressure used in the momentum equation"
+                />
+                <var name="wTop" type="real" dimensions="nVertLevelsP1 nCells Time" units="m s^{-1}"
+                     description="vertical transport through the layer interface at the top of the cell"
+                />
+                <var name="vertVelocityTop" type="real" dimensions="nVertLevelsP1 nCells Time" units="m s^{-1}"
+                     description="vertical velocity defined at center (horizonally) and top (vertically) of cell"
+                />
+                <var name="rhoDisplaced" type="real" dimensions="nVertLevels nCells Time" units="kg m^{-3}"
+                     description="potential density displaced to the mid-depth of top layer"
+                />
+                <var name="BruntVaisalaFreqTop" type="real" dimensions="nVertLevels nCells Time" streams="o" units="s^{-2}"
+                     description="Brunt Vaisala frequency defined at the center (horizontally) and top (vertically) of cell"
+                />
+                <var name="viscosity" type="real" dimensions="nVertLevels nEdges Time" streams="o" units="m^2 s^{-1}"
+                     description="horizontal viscosity"
+                />
+                <var name="vh" type="real" dimensions="nVertLevels nEdges Time" units="m^2 s^{-1}"
+                     description="thickness flux in the tangent direction (from vertex1 to vertex2)"
+                />
+                <var name="circulation" type="real" dimensions="nVertLevels nVertices Time" units="m^2 s^{-1}"
+                     description="area-integrated vorticity"
+                />
+                <var name="gradVor_t" type="real" dimensions="nVertLevels nEdges Time" units="s^{-1} m^{-1}"
+                     description="gradient of vorticity in the tangent direction (from vertex1 to vertex2)"
+                />
+                <var name="gradVor_n" type="real" dimensions="nVertLevels nEdges Time" units="s^{-1} m^{-1}"
+                     description="gradient of vorticity in the normal direction (from cell1 to cell2)"
+                />
+                <var name="areaCellGlobal" type="real" dimensions="Time" streams="o" units="m^2"
+                     description="sum of the areaCell variable over the full domain, used to normalize global statistics"
+                />
+                <var name="areaEdgeGlobal" type="real" dimensions="Time" streams="o" units="m^2"
+                     description="sum of the areaEdge variable over the full domain, used to normalize global statistics"
+                />
+                <var name="areaTriangleGlobal" type="real" dimensions="Time" streams="o" units="m^2"
+                     description="sum of the areaTriangle variable over the full domain, used to normalize global statistics"
+                />
+                <var name="volumeCellGlobal" type="real" dimensions="Time" streams="o" units="m^3"
+                     description="sum of the volumeCell variable over the full domain, used to normalize global statistics"
+                />
+                <var name="volumeEdgeGlobal" type="real" dimensions="Time" streams="o" units="m^3"
+                     description="sum of the volumeEdge variable over the full domain, used to normalize global statistics"
+                />
+                <var name="CFLNumberGlobal" type="real" dimensions="Time" streams="o" units="unitless"
+                     description="maximum CFL number over the full domain"
+                />
+                <var name="nAccumulate" type="real" dimensions="Time" streams="o" units="unitless"
+                     description="number of timesteps in time-averaged variables"
+                />
+                <var name="acc_ssh" type="real" dimensions="nCells Time" streams="o" units="m"
+                     description="time-averaged sea surface height"
+                />
+                <var name="acc_sshVar" type="real" dimensions="nCells Time" streams="o" units="m"
+                     description="variance of sea surface height"
+                />
+                <var name="acc_uReconstructZonal" type="real" dimensions="nVertLevels nCells Time" streams="o" units="m s^{-1}"
+                     description="time-averaged velocity in the eastward direction"
+                />
+                <var name="acc_uReconstructMeridional" type="real" dimensions="nVertLevels nCells Time" streams="o" units="m s^{-1}"
+                     description="time-averaged velocity in the northward direction"
+                />
+                <var name="acc_uReconstructZonalVar" type="real" dimensions="nVertLevels nCells Time" streams="o" units="m s^{-1}"
+                     description="variance of velocity in the eastward direction"
+                />
+                <var name="acc_uReconstructMeridionalVar" type="real" dimensions="nVertLevels nCells Time" streams="o" units="m s^{-1}"
+                     description="variance of velocity in the northward direction"
+                />
+                <var name="acc_u" type="real" dimensions="nVertLevels nEdges Time" streams="o" units="m s^{-1}"
+                     description="time-averaged velocity, normal to cell edge"
+                />
+                <var name="acc_uVar" type="real" dimensions="nVertLevels nEdges Time" streams="o" units="m s^{-1}"
+                     description="variance of velocity, normal to cell edge"
+                />
+                <var name="acc_vertVelocityTop" type="real" dimensions="nVertLevelsP1 nCells Time" streams="o" units="m s^{-1}"
+                     description="time-averaged vertical velocity at top of cell"
+                />
+        </var_struct>
+        <var_struct name="mesh" time_levs="0">
+                <var name="latCell" type="real" dimensions="nCells" streams="iro" units="radians"
+                         description="Latitude location of cell centers in radians."
+                />
+                <var name="lonCell" type="real" dimensions="nCells" streams="iro" units="radians"
+                     description="Longitude location of cell centers in radians."
+                />
+                <var name="xCell" type="real" dimensions="nCells" streams="iro" units="unitless"
+                     description="X Coordinate in cartesian space of cell centers."
+                />
+                <var name="yCell" type="real" dimensions="nCells" streams="iro" units="unitless"
+                     description="Y Coordinate in cartesian space of cell centers."
+                />
+                <var name="zCell" type="real" dimensions="nCells" streams="iro" units="unitless"
+                     description="Z Coordinate in cartesian space of cell centers."
+                />
+                <var name="indexToCellID" type="integer" dimensions="nCells" streams="iro" units="unitless"
+                     description="List of global cell IDs."
+                />
+                <var name="latEdge" type="real" dimensions="nEdges" streams="iro" units="radians"
+                     description="Latitude location of edge midpoints in radians."
+                />
+                <var name="lonEdge" type="real" dimensions="nEdges" streams="iro" units="radians"
+                     description="Longitude location of edge midpoints in radians."
+                />
+                <var name="xEdge" type="real" dimensions="nEdges" streams="iro" units="unitless"
+                     description="X Coordinate in cartesian space of edge midpoints."
+                />
+                <var name="yEdge" type="real" dimensions="nEdges" streams="iro" units="unitless"
+                     description="Y Coordinate in cartesian space of edge midpoints."
+                />
+                <var name="zEdge" type="real" dimensions="nEdges" streams="iro" units="unitless"
+                     description="Z Coordinate in cartesian space of edge midpoints."
+                />
+                <var name="indexToEdgeID" type="integer" dimensions="nEdges" streams="iro" units="unitless"
+                     description="List of global edge IDs."
+                />
+                <var name="latVertex" type="real" dimensions="nVertices" streams="iro" units="radians"
+                     description="Latitude location of vertices in radians."
+                />
+                <var name="lonVertex" type="real" dimensions="nVertices" streams="iro" units="radians"
+                     description="Longitude location of vertices in radians."
+                />
+                <var name="xVertex" type="real" dimensions="nVertices" streams="iro" units="unitless"
+                     description="X Coordinate in cartesian space of vertices."
+                />
+                <var name="yVertex" type="real" dimensions="nVertices" streams="iro" units="unitless"
+                     description="Y Coordinate in cartesian space of vertices."
+                />
+                <var name="zVertex" type="real" dimensions="nVertices" streams="iro" units="unitless"
+                     description="Z Coordinate in cartesian space of vertices."
+                />
+                <var name="indexToVertexID" type="integer" dimensions="nVertices" streams="iro" units="unitless"
+                     description="List of global vertex IDs."
+                />
+                <var name="meshDensity" type="real" dimensions="nCells" streams="iro" units="unitless"
+                     description="Value of density function used to generate a particular mesh at cell centers."
+                />
+                <var name="meshScalingDel2" type="real" dimensions="nEdges" streams="ro" units="unitless"
+                     description="Coefficient to Laplacian mixing terms in momentum and tracer equations, so that viscosity and diffusion scale with mesh."
+                />
+                <var name="meshScalingDel4" type="real" dimensions="nEdges" streams="ro" units="unitless"
+                     description="Coefficient to biharmonic mixing terms in momentum and tracer equations, so that biharmonic viscosity and diffusion coefficients scale with mesh."
+                />
+                <var name="meshScaling" type="real" dimensions="nEdges" streams="ro" units="unitless"
+                     description="Coefficient used for mesh scaling, such as the Leith parameter."
+                />
+                <var name="cellsOnEdge" type="integer" dimensions="TWO nEdges" streams="iro" units="unitless"
+                     description="List of cells that straddle each edge."
+                />
+                <var name="nEdgesOnCell" type="integer" dimensions="nCells" streams="iro" units="unitless"
+                     description="Number of edges that border each cell."
+                />
+                <var name="nEdgesOnEdge" type="integer" dimensions="nEdges" streams="iro" units="unitless"
+                     description="Number of edges that surround each of the cells that straddle each edge. These edges are used to reconstruct the tangential velocities."
+                />
+                <var name="edgesOnCell" type="integer" dimensions="maxEdges nCells" streams="iro" units="unitless"
+                     description="List of edges that border each cell."
+                />
+                <var name="edgesOnEdge" type="integer" dimensions="maxEdges2 nEdges" streams="iro" units="unitless"
+                     description="List of edges that border each of the cells that straddle each edge."
+                />
+                <var name="weightsOnEdge" type="real" dimensions="maxEdges2 nEdges" streams="iro" units="unitless"
+                     description="Reconstruction weights associated with each of the edgesOnEdge."
+                />
+                <var name="dvEdge" type="real" dimensions="nEdges" streams="iro" units="m"
+                     description="Length of each edge, computed as the distance between verticesOnEdge."
+                />
+                <var name="dcEdge" type="real" dimensions="nEdges" streams="iro" units="m"
+                     description="Length of each edge, computed as the distance between cellsOnEdge."
+                />
+                <var name="angleEdge" type="real" dimensions="nEdges" streams="iro" units="radians"
+                     description="Angle the edge normal makes with local eastward direction."
+                />
+                <var name="areaCell" type="real" dimensions="nCells" streams="iro" units="m^2"
+                     description="Area of each cell in the primary grid."
+                />
+                <var name="areaTriangle" type="real" dimensions="nVertices" streams="iro" units="m^2"
+                     description="Area of each cell (triangle) in the dual grid."
+                />
+                <var name="edgeNormalVectors" type="real" dimensions="R3 nEdges" streams="o" units="unitless"
+                     description="Normal vector defined at an edge."
+                />
+                <var name="localVerticalUnitVectors" type="real" dimensions="R3 nCells" streams="o" units="unitless"
+                     description="Unit surface normal vectors defined at cell centers."
+                />
+                <var name="cellTangentPlane" type="real" dimensions="R3 TWO nCells" streams="o" units="unitless"
+                     description="The two vectors that define a tangent plane at a cell center."
+                />
+                <var name="cellsOnCell" type="integer" dimensions="maxEdges nCells" streams="iro" units="unitless"
+                     description="List of cells that neighbor each cell."
+                />
+                <var name="verticesOnCell" type="integer" dimensions="maxEdges nCells" streams="iro" units="unitless"
+                     description="List of vertices that border each cell."
+                />
+                <var name="verticesOnEdge" type="integer" dimensions="TWO nEdges" streams="iro" units="unitless"
+                     description="List of vertices that straddle each edge."
+                />
+                <var name="edgesOnVertex" type="integer" dimensions="vertexDegree nVertices" streams="iro" units="unitless"
+                     description="List of edges that share a vertex as an endpoint."
+                />
+                <var name="cellsOnVertex" type="integer" dimensions="vertexDegree nVertices" streams="iro" units="unitless"
+                     description="List of cells that share a vertex."
+                />
+                <var name="kiteAreasOnVertex" type="real" dimensions="vertexDegree nVertices" streams="iro" units="m^2"
+                     description="Area of the portions of each dual cell that are part of each cellsOnVertex."
+                />
+                <var name="fEdge" type="real" dimensions="nEdges" streams="iro" units="s^{-1}"
+                     description="Coriolis parameter at edges."
+                />
+                <var name="fVertex" type="real" dimensions="nVertices" streams="iro" units="s^{-1}"
+                     description="Coriolis parameter at vertices."
+                />
+                <var name="bottomDepth" type="real" dimensions="nCells" streams="iro" units="m"
+                     description="Depth of the bottom of the ocean. Given as a positive distance from sea level."
+                />
+                <var name="deriv_two" type="real" dimensions="maxEdges2 TWO nEdges" units=""
+                     description="Value of the second derivative of the polynomial used for reconstruction of cell center quantities at edges."
+                />
+                <var name="adv_coefs" type="real" dimensions="nAdvectionCells nEdges" units=""
+                     description="Weighting coefficients used for reconstruction of cell center quantities at edges. Used in advection routines."
+                />
+                <var name="adv_coefs_2nd" type="real" dimensions="nAdvectionCells nEdges" units=""
+                     description="Weighting coefficients used for reconstruction of cell center quantities at edges. Used in advection routines."
+                />
+                <var name="adv_coefs_3rd" type="real" dimensions="nAdvectionCells nEdges" units=""
+                        description="Wegihting coefficients used for reconstruction of cell center quantities at edges. Used in advection routines."
+                />
+                <var name="advCellsForEdge" type="integer" dimensions="nAdvectionCells nEdges" units="unitless"
+                     description="List of cells used to reconstruct a cell quantity at an edge. Used in advection routines."
+                />
+                <var name="nAdvCellsForEdge" type="integer" dimensions="nEdges" units="unitless"
+                     description="Number of cells used in reconstruction of cell center quantities at an edge. Used in advection routines."
+                />
+                <var name="highOrderAdvectionMask" type="integer" dimensions="nVertLevels nEdges" units="unitless"
+                     description="Mask for high order advection. Values are 1 if high order is used, and 0 if not."
+                />
+                <var name="lowOrderAdvectionMask" type="integer" dimensions="nVertLevels nEdges" units="unitless"
+                     description="Mask for low order advection. Values are 1 if low order is used, and 0 if not."
+                />
+                <var name="defc_a" type="real" dimensions="maxEdges nCells" units=""
+                     description="Variable used with advection setup to compute advection coefficients. Deformation weight coefficients."
+                />
+                <var name="defc_b" type="real" dimensions="maxEdges nCells" units=""
+                     description="Variable used with advection setup to compute advection coefficients. Deformation weight coefficients."
+                />
+                <var name="kdiff" type="real" dimensions="nVertLevels nCells Time" units=""
+                         description="{\color{red} TO BE REMOVED}"
+                />
+                <var name="coeffs_reconstruct" type="real" dimensions="R3 maxEdges nCells" units=""
+                         description="{\color{red} TO BE REMOVED}"
+                />
+                <var name="maxLevelCell" type="integer" dimensions="nCells" streams="iro" units="unitless"
+                     description="Index to the last active ocean cell in each column."
+                />
+                <var name="maxLevelEdgeTop" type="integer" dimensions="nEdges" units="unitless"
+                     description="Index to the last edge in a column with active ocean cells on both sides of it."
+                />
+                <var name="maxLevelEdgeBot" type="integer" dimensions="nEdges" units="unitless"
+                     description="Index to the last edge in a column with at least one active ocean cell on either side of it."
+                />
+                <var name="maxLevelVertexTop" type="integer" dimensions="nVertices" units="unitless"
+                     description="Index to the last vertex in a column with all active cells around it."
+                />
+                <var name="maxLevelVertexBot" type="integer" dimensions="nVertices" units="unitless"
+                     description="Index to the last vertex in a column with at least one active ocean cell around it."
+                />
+                <var name="refBottomDepth" type="real" dimensions="nVertLevels" streams="iro" units="m"
+                     description="Reference depth of ocean for each vertical level. Used in 'z-level' type runs."
+                />
+                <var name="refBottomDepthTopOfCell" type="real" dimensions="nVertLevelsP1" units="m"
+                     description="Reference depth of ocean for each vertical interface. Used in 'z-level' type runs."
+                />
+                <var name="hZLevel" type="real" dimensions="nVertLevels" streams="iro" units="m"
+                        description="{\color{red} TO BE REMOVED}"
+                />
+                <var name="vertCoordMovementWeights" type="real" dimensions="nVertLevels" streams="iro" units="unitless"
+                     description="Weights used for distribution of sea surface heigh purturbations through multiple vertical levels."
+                />
+                <var name="boundaryEdge" type="integer" dimensions="nVertLevels nEdges" units="unitless"
+                     description="Mask for determining boundary edges. A boundary edge has only one active ocean cell neighboring it."
+                />
+                <var name="boundaryVertex" type="integer" dimensions="nVertLevels nVertices" units="unitless"
+                     description="Mask for determining boundary vertices. A boundary vertex has at least one inactive cell neighboring it."
+                />
+                <var name="boundaryCell" type="integer" dimensions="nVertLevels nCells" units="unitless"
+                     description="Mask for determining boundary cells. A boundary cell has at least one inactive cell neighboring it."
+                />
+                <var name="edgeMask" type="integer" dimensions="nVertLevels nEdges" streams="o" units="unitless"
+                     description="Mask on edges that determines if computations should be done on edge."
+                />
+                <var name="vertexMask" type="integer" dimensions="nVertLevels nVertices" streams="o" units="unitless"
+                     description="Mask on vertices that determines if computations should be done on vertice."
+                />
+                <var name="cellMask" type="integer" dimensions="nVertLevels nCells" streams="o" units="unitless"
+                     description="Mask on cells that determines if computations should be done on cell."
+                />
+                <var name="u_src" type="real" dimensions="nVertLevels nEdges" streams="ir" units="N m^{-2}"
+                     description="Velocity forcing field. Defines a forcing at an edge."
+                />
+                <var name="temperatureRestore" type="real" dimensions="nCells" streams="ir" units="^\circ C"
+                     description="Temperature restoring field, for restoring temperature at the surface."
+                />
+                <var name="salinityRestore" type="real" dimensions="nCells" streams="ir" units="PSU"
+                     description="Salinity restoring field, for restoring salinity at the surface."
+                />
+                <var name="windStressMonthly" type="real" dimensions="nMonths nEdges" streams="ir" units="N m^{-2}"
+                     description="Monthly wind stress field, defined at the surface for use in monthly forcing."
+                />
+                <var name="temperatureRestoreMonthly" type="real" dimensions="nMonths nCells" streams="ir" units="^\circ C"
+                     description="Monthly temperature restorying field, defined at the surface for use in monthly forcing."
+                />
+                <var name="salinityRestoreMonthly" type="real" dimensions="nMonths nCells" streams="ir" units="PSU"
+                     description="Monthly salinity resotring field, defined at the surface, for use in monthly forcing."
+                />
+                <var name="edgeSignOnCell" type="integer" dimensions="maxEdges nCells" units="unitless"
+                     description="Sign of edge contributions to a cell for each edge on cell. Used for bit-reproducible loops. Represents directionality of vector connecting cells."
+                />
+                <var name="edgeSignOnVertex" type="integer" dimensions="maxEdges nVertices" units="unitless"
+                     description="Sign of edge contributions to a vertex for each edge on vertex. Used for bit-reproducible loops. Represents directionality of vector connecting vertices."
+                />
+                <var name="kiteIndexOnCell" type="integer" dimensions="maxEdges nCells" units="unitless"
+                     description="Index of kite in dual grid, based on verticesOnCell."
+                />
+                <var name="seaSurfacePressure" type="real" dimensions="nCells Time" streams="ir" units="Pa"
+                     description="Pressure defined at the sea surface."
+                />
+        </var_struct>
+        <var_struct name="tend" time_levs="1">
+                <var_array name="tracers" type="real" dimensions="nVertLevels nCells Time">
+                        <var name="tend_temperature" array_group="dynamics" units="K s^{-1}" name_in_code="temperature"
+                             description="time tendency of potential temperature"
+                        />
+                        <var name="tend_salinity" array_group="dynamics" units="PSU s^{-1}" name_in_code="salinity"
+                             description="time tendency of salinity measured as change in practical salinity units per second"
+                        />
+                        <var name="tend_tracer1" array_group="testing" units="tracer s^{-1}" name_in_code="tracer1"
+                             description="time tendency of an arbitary tracer"
+                        />
+                </var_array>
+                <var name="tend_u" type="real" dimensions="nVertLevels nEdges Time" units="m s^{-2}" name_in_code="u"
+                     description="time tendency of normal component of velocity"
+                />
+                <var name="tend_h" type="real" dimensions="nVertLevels nCells Time" units="m s^{-1}" name_in_code="h"
+                     description="time tendency of layer thickness"
+                />
+                <var name="tend_ssh" type="real" dimensions="nCells Time" units="m s^{-1}" name_in_code="ssh"
+                     description="time tendency of sea-surface height"
+                />
+        </var_struct>
+        <var_struct name="diagnostics" time_levs="1">
+                <var name="RiTopOfCell" type="real" dimensions="nVertLevelsP1 nCells Time" units="nondimensional"
+                     description="gradient Richardson number defined at the center (horizontally) and top (vertically)"
+                />
+                <var name="RiTopOfEdge" type="real" dimensions="nVertLevelsP1 nEdges Time" units="nondimensional"
+                     description="gradient Richardson number defined at the edge (horizontally) and top (vertically)"
+                />
+                <var name="vertViscTopOfEdge" type="real" dimensions="nVertLevelsP1 nEdges Time" units="m^2 s^{-1}"
+                     description="vertical viscosity defined at the edge (horizontally) and top (vertically)"
+                />
+                <var name="vertDiffTopOfCell" type="real" dimensions="nVertLevelsP1 nCells Time" units="m^2 s^{-1}"
+                     description="vertical diffusion defined at the edge (horizontally) and top (vertically)"
+                />
+        </var_struct>
+</registry>
Copied: trunk/mpas/src/core_sw/Registry.xml (from rev 2662, branches/xml_registry/src/core_sw/Registry.xml)
===================================================================
--- trunk/mpas/src/core_sw/Registry.xml                                (rev 0)
+++ trunk/mpas/src/core_sw/Registry.xml        2013-03-22 19:32:26 UTC (rev 2663)
@@ -0,0 +1,146 @@
+<?xml version="1.0"?>
+<registry>
+        <dims>
+                <dim name="nCells"/>
+                <dim name="nEdges"/>
+                <dim name="maxEdges"/>
+                <dim name="maxEdges2"/>
+                <dim name="nVertices"/>
+                <dim name="TWO"                definition="2"/>
+                <dim name="R3"                 definition="3"/>
+                <dim name="FIFTEEN"            definition="15"/>
+                <dim name="TWENTYONE"          definition="21"/>
+                <dim name="vertexDegree"/>
+                <dim name="nVertLevels"/>
+                <dim name="nTracers"/>
+        </dims>
+        <nml_record name="sw_model">
+                <nml_option name="config_test_case"                  type="integer"       default_value="5"/>
+                <nml_option name="config_time_integration"           type="character"     default_value="RK4"/>
+                <nml_option name="config_dt"                         type="real"          default_value="172.8"/>
+                <nml_option name="config_calendar_type"              type="character"     default_value="360day"/>
+                <nml_option name="config_start_time"                 type="character"     default_value="0000-01-01_00:00:00"/>
+                <nml_option name="config_stop_time"                  type="character"     default_value="none"/>
+                <nml_option name="config_run_duration"               type="character"     default_value="none"/>
+                <nml_option name="config_stats_interval"             type="integer"       default_value="100"/>
+                <nml_option name="config_h_ScaleWithMesh"            type="logical"       default_value="false"/>
+                <nml_option name="config_h_mom_eddy_visc2"           type="real"          default_value="0.0"/>
+                <nml_option name="config_h_mom_eddy_visc4"           type="real"          default_value="0.0"/>
+                <nml_option name="config_h_tracer_eddy_diff2"        type="real"          default_value="0.0"/>
+                <nml_option name="config_h_tracer_eddy_diff4"        type="real"          default_value="0.0"/>
+                <nml_option name="config_thickness_adv_order"        type="integer"       default_value="2"/>
+                <nml_option name="config_tracer_adv_order"           type="integer"       default_value="2"/>
+                <nml_option name="config_positive_definite"          type="logical"       default_value="false"/>
+                <nml_option name="config_monotonic"                  type="logical"       default_value="false"/>
+                <nml_option name="config_wind_stress"                type="logical"       default_value="false"/>
+                <nml_option name="config_bottom_drag"                type="logical"       default_value="false"/>
+                <nml_option name="config_apvm_upwinding"             type="real"          default_value="0.5"/>
+                <nml_option name="config_num_halos"                  type="integer"       default_value="2"/>
+        </nml_record>
+        <nml_record name="io">
+                <nml_option name="config_input_name"                 type="character"     default_value="grid.nc"/>
+                <nml_option name="config_output_name"                type="character"     default_value="output.nc"/>
+                <nml_option name="config_restart_name"               type="character"     default_value="restart.nc"/>
+                <nml_option name="config_output_interval"            type="character"     default_value="06:00:00"/>
+                <nml_option name="config_frames_per_outfile"         type="integer"       default_value="0"/>
+                <nml_option name="config_pio_num_iotasks"            type="integer"       default_value="0"/>
+                <nml_option name="config_pio_stride"                 type="integer"       default_value="1"/>
+        </nml_record>
+        <nml_record name="decomposition">
+                <nml_option name="config_block_decomp_file_prefix"   type="character"     default_value="graph.info.part."/>
+                <nml_option name="config_number_of_blocks"           type="integer"       default_value="0"/>
+                <nml_option name="config_explicit_proc_decomp"       type="logical"       default_value=".false."/>
+                <nml_option name="config_proc_decomp_file_prefix"    type="character"     default_value="graph.info.part."/>
+        </nml_record>
+        <nml_record name="restart">
+                <nml_option name="config_do_restart"                 type="logical"       default_value="false"/>
+                <nml_option name="config_restart_interval"           type="character"     default_value="none"/>
+        </nml_record>
+        <var_struct name="state" time_levs="2">
+                <var name="xtime"                             type="text"     dimensions="Time"                        streams="ro"/>
+                <var name="u"                                 type="real"     dimensions="nVertLevels nEdges Time"     streams="iro"/>
+                <var name="h"                                 type="real"     dimensions="nVertLevels nCells Time"     streams="iro"/>
+                <var name="tracers"                           type="real"     dimensions="nTracers nVertLevels nCells Time" streams="iro"/>
+                <var name="v"                                 type="real"     dimensions="nVertLevels nEdges Time"     streams="o"/>
+                <var name="divergence"                        type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="vorticity"                         type="real"     dimensions="nVertLevels nVertices Time"  streams="o"/>
+                <var name="vorticity_cell"                    type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="pv_edge"                           type="real"     dimensions="nVertLevels nEdges Time"     streams="o"/>
+                <var name="h_edge"                            type="real"     dimensions="nVertLevels nEdges Time"     streams="o"/>
+                <var name="ke"                                type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="pv_vertex"                         type="real"     dimensions="nVertLevels nVertices Time"  streams="o"/>
+                <var name="pv_cell"                           type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="uReconstructX"                     type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="uReconstructY"                     type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="uReconstructZ"                     type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="uReconstructZonal"                 type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="uReconstructMeridional"            type="real"     dimensions="nVertLevels nCells Time"     streams="o"/>
+                <var name="vh"                                type="real"     dimensions="nVertLevels nEdges Time"/>
+                <var name="circulation"                       type="real"     dimensions="nVertLevels nVertices Time"/>
+                <var name="gradPVt"                           type="real"     dimensions="nVertLevels nEdges Time"/>
+                <var name="gradPVn"                           type="real"     dimensions="nVertLevels nEdges Time"/>
+                <var name="h_vertex"                          type="real"     dimensions="nVertLevels nVertices Time"/>
+        </var_struct>
+        <var_struct name="mesh" time_levs="0">
+                <var name="latCell"                           type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="lonCell"                           type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="xCell"                             type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="yCell"                             type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="zCell"                             type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="indexToCellID"                     type="integer"  dimensions="nCells"                      streams="iro"/>
+                <var name="latEdge"                           type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="lonEdge"                           type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="xEdge"                             type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="yEdge"                             type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="zEdge"                             type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="indexToEdgeID"                     type="integer"  dimensions="nEdges"                      streams="iro"/>
+                <var name="latVertex"                         type="real"     dimensions="nVertices"                   streams="iro"/>
+                <var name="lonVertex"                         type="real"     dimensions="nVertices"                   streams="iro"/>
+                <var name="xVertex"                           type="real"     dimensions="nVertices"                   streams="iro"/>
+                <var name="yVertex"                           type="real"     dimensions="nVertices"                   streams="iro"/>
+                <var name="zVertex"                           type="real"     dimensions="nVertices"                   streams="iro"/>
+                <var name="indexToVertexID"                   type="integer"  dimensions="nVertices"                   streams="iro"/>
+                <var name="meshDensity"                       type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="meshScalingDel2"                   type="real"     dimensions="nEdges"                      streams="ro"/>
+                <var name="meshScalingDel4"                   type="real"     dimensions="nEdges"                      streams="ro"/>
+                <var name="cellsOnEdge"                       type="integer"  dimensions="TWO nEdges"                  streams="iro"/>
+                <var name="nEdgesOnCell"                      type="integer"  dimensions="nCells"                      streams="iro"/>
+                <var name="nEdgesOnEdge"                      type="integer"  dimensions="nEdges"                      streams="iro"/>
+                <var name="edgesOnCell"                       type="integer"  dimensions="maxEdges nCells"             streams="iro"/>
+                <var name="edgesOnEdge"                       type="integer"  dimensions="maxEdges2 nEdges"            streams="iro"/>
+                <var name="weightsOnEdge"                     type="real"     dimensions="maxEdges2 nEdges"            streams="iro"/>
+                <var name="dvEdge"                            type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="dcEdge"                            type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="angleEdge"                         type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="areaCell"                          type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="areaTriangle"                      type="real"     dimensions="nVertices"                   streams="iro"/>
+                <var name="edgeNormalVectors"                 type="real"     dimensions="R3 nEdges"                   streams="o"/>
+                <var name="localVerticalUnitVectors"          type="real"     dimensions="R3 nCells"                   streams="o"/>
+                <var name="cellTangentPlane"                  type="real"     dimensions="R3 TWO nCells"               streams="o"/>
+                <var name="cellsOnCell"                       type="integer"  dimensions="maxEdges nCells"             streams="iro"/>
+                <var name="verticesOnCell"                    type="integer"  dimensions="maxEdges nCells"             streams="iro"/>
+                <var name="verticesOnEdge"                    type="integer"  dimensions="TWO nEdges"                  streams="iro"/>
+                <var name="edgesOnVertex"                     type="integer"  dimensions="vertexDegree nVertices"      streams="iro"/>
+                <var name="cellsOnVertex"                     type="integer"  dimensions="vertexDegree nVertices"      streams="iro"/>
+                <var name="kiteAreasOnVertex"                 type="real"     dimensions="vertexDegree nVertices"      streams="iro"/>
+                <var name="fEdge"                             type="real"     dimensions="nEdges"                      streams="iro"/>
+                <var name="fVertex"                           type="real"     dimensions="nVertices"                   streams="iro"/>
+                <var name="fCell"                             type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="h_s"                               type="real"     dimensions="nCells"                      streams="iro"/>
+                <var name="deriv_two"                         type="real"     dimensions="FIFTEEN TWO nEdges"          streams="o"/>
+                <var name="advCells"                          type="integer"  dimensions="TWENTYONE nCells"/>
+                <var name="defc_a"                            type="real"     dimensions="maxEdges nCells"/>
+                <var name="defc_b"                            type="real"     dimensions="maxEdges nCells"/>
+                <var name="kdiff"                             type="real"     dimensions="nVertLevels nCells Time"/>
+                <var name="coeffs_reconstruct"                type="real"     dimensions="R3 maxEdges nCells"/>
+                <var name="boundaryEdge"                      type="integer"  dimensions="nVertLevels nEdges"          streams="iro"/>
+                <var name="boundaryVertex"                    type="integer"  dimensions="nVertLevels nVertices"       streams="iro"/>
+                <var name="boundaryCell"                      type="integer"  dimensions="nVertLevels nCells"          streams="iro"/>
+                <var name="u_src"                             type="real"     dimensions="nVertLevels nEdges"          streams="iro"/>
+        </var_struct>
+        <var_struct name="tend" time_levs="1">
+                <var name="tend_u"                            type="real"     dimensions="nVertLevels nEdges Time"           name_in_code="u"/>
+                <var name="tend_h"                            type="real"     dimensions="nVertLevels nCells Time"           name_in_code="h"/>
+                <var name="tend_tracers"                      type="real"     dimensions="nTracers nVertLevels nCells Time"  name_in_code="tracers"/>
+        </var_struct>
+</registry>
Modified: trunk/mpas/src/registry/Makefile
===================================================================
--- trunk/mpas/src/registry/Makefile        2013-03-22 17:48:50 UTC (rev 2662)
+++ trunk/mpas/src/registry/Makefile        2013-03-22 19:32:26 UTC (rev 2663)
@@ -1,9 +1,12 @@
 .SUFFIXES: .c .o
 
-OBJS = parse.o dictionary.o gen_inc.o fortprintf.o
+OBJS = parse.o dictionary.o gen_inc.o fortprintf.o ezxml/ezxml.o
 
 all: parse
 
+ezxml/ezxml.o:
+        (cd ezxml; $(CC) -c ezxml.c)
+
 parse: $(OBJS)
         $(CC) -o $@ $(OBJS)
 
Copied: trunk/mpas/src/registry/Registry.xsd (from rev 2662, branches/xml_registry/src/registry/Registry.xsd)
===================================================================
--- trunk/mpas/src/registry/Registry.xsd                                (rev 0)
+++ trunk/mpas/src/registry/Registry.xsd        2013-03-22 19:32:26 UTC (rev 2663)
@@ -0,0 +1,119 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"  elementFormDefault="qualified"  attributeFormDefault="unqualified" >
+        <xs:element name="registry" >
+                <xs:complexType>
+                        <xs:sequence>
+                                <!-- The dims element contains all dimensions -->
+                                <xs:element name="dims" >
+                                        <xs:complexType>
+                                                <xs:sequence>
+                                                        <!-- Each dimension is an independent child of the <dims></dims> element. -->
+                                                        <xs:element name="dim"  maxOccurs="unbounded" >
+                                                                <xs:complexType>
+                                                                        <!-- The name attribute should specify the name of the dimension. -->
+                                                                        <xs:attribute name="name"  type="xs:string" use="required"/>
+                                                                        <!-- The definition attribute is used to define a dimension based on other pre-defined dimensions -->
+                                                                        <xs:attribute name="definition"  type="xs:string" use="optional"/>
+                                                                        <!-- The units attribute defines the units of the dimension. -->
+                                                                        <xs:attribute name="units"  type="xs:string" use="optional"/>
+                                                                        <!-- The description attribute describes the dimensions. -->
+                                                                        <xs:attribute name="description"  type="xs:string" use="optional"/>
+                                                                </xs:complexType>
+                                                        </xs:element>
+                                                </xs:sequence>
+                                        </xs:complexType>
+                                </xs:element>
+                                <!-- The nml_record element contains all namelist options for a particular namelist record -->
+                                <xs:element name="nml_record"  maxOccurs="unbounded" >
+                                        <xs:complexType>
+                                                <xs:sequence>
+                                                        <!-- The nml_option element defines a particular namelist option that lives within the defined nml_record -->
+                                                        <xs:element name="nml_option"  maxOccurs="unbounded" >
+                                                                <xs:complexType>
+                                                                        <!-- The name attribute defines the name of the namelist option. This is how it would look in a namelist file. -->
+                                                                        <xs:attribute name="name"  type="xs:string" use="required"/>
+                                                                        <!-- The type attribute defines the type of the particular namelist option. Options are real, integer, character, and logical. -->
+                                                                        <xs:attribute name="type"  type="xs:string" use="required"/>
+                                                                        <!-- The default_value attribute defines the default value of the namelist option. This is used if the option is omitted from a namelist file. -->
+                                                                        <xs:attribute name="default_value"  type="xs:string" use="required"/>
+                                                                        <!-- The units attribute defines the units for the particular namelist option. -->
+                                                                        <xs:attribute name="units"  type="xs:string" use="optional"/>
+                                                                        <!-- The description attribute describes the namelist option. -->
+                                                                        <xs:attribute name="description"  type="xs:string" use="optional"/>
+                                                                        <!-- The possible_values attribute defines what values are allowable for the namelist option. -->
+                                                                        <xs:attribute name="possible_values"  type="xs:string" use="optional"/>
+                                                                </xs:complexType>
+                                                        </xs:element>
+                                                </xs:sequence>
+                                                <!-- The name attribute defines the name of the namelist record. This would be seen as &name in the actual namelist. -->
+                                                <xs:attribute name="name"  type="xs:string" use="required"/>
+                                        </xs:complexType>
+                                </xs:element>
+                                <!-- The var_struct element defines a grouping of variables. This is similar to mesh, or state and lives at the domain % blocklist level. -->
+                                <xs:element name="var_struct"  maxOccurs="unbounded" >
+                                        <xs:complexType>
+                                                <xs:sequence>
+                                                        <!-- The var_array element defines an array of variables. 
+                                                                 Within the code all constituent variables are merged into a one higher dimension array, for ease of use.
+                                                                 When written to the output file, they will be named their individual names. -->
+                                                        <xs:element name="var_array" maxOccurs="unbounded" minOccurs="0" >
+                                                                <xs:complexType>
+                                                                        <xs:sequence>
+                                                                                <!-- This specific var element defines a variable that is a constituent to a particular var_array group. -->
+                                                                                <xs:element name="var"  maxOccurs="unbounded" minOccurs="0" >
+                                                                                        <xs:complexType>
+                                                                                                <!-- The name attribute is the name of the variable. This how it will be displayed in the output file. -->
+                                                                                                <xs:attribute name="name"  type="xs:string" use="required"/>
+                                                                                                <!-- The array_group attribute is used to group variables within the var_array for ease of use. -->
+                                                                                                <xs:attribute name="array_group"  type="xs:string" use="required"/>
+                                                                                                <!-- The streams attribute defines the streams this variable is included in. Allowable values are omitted, i, r, o and any combination of i, r, and o. -->
+                                                                                                <xs:attribute name="streams"  type="xs:string" use="optional"/>
+                                                                                                <!-- The name_in_code attribute defines the name of the variable in the code, if it should be different then in the input/output/restart streams. -->
+                                                                                                <xs:attribute name="name_in_code"  type="xs:string" use="optional"/>
+                                                                                                <!-- The units attribute defines the units of the particular variable -->
+                                                                                                <xs:attribute name="units"  type="xs:string" use="optional"/>
+                                                                                                <!-- The description attribute describes the particular variable -->
+                                                                                                <xs:attribute name="description"  type="xs:string" use="optional"/>
+                                                                                        </xs:complexType>
+                                                                                </xs:element>
+                                                                        </xs:sequence>
+                                                                        <!-- The name attribute is the name of the var_array that will be seen in the code. -->
+                                                                        <xs:attribute name="name"  type="xs:string" use="required"/>
+                                                                        <!-- The type attribute defines the type of all constituents for the var_array. Valid options are real, integer, logical, and character -->
+                                                                        <xs:attribute name="type"  type="xs:string" use="required"/>
+                                                                        <!-- The dimensions attribute defines the dimensions of each individual constituent. This does not include the collapsed dimension. -->
+                                                                        <xs:attribute name="dimensions"  type="xs:string" use="required"/>
+                                                                        <!-- The persistence attribute determines if the var_array is persistence or scratch. Valid options are persistent, and scratch. -->
+                                                                        <xs:attribute name="persistence"  type="xs:string" use="optional"/>
+                                                                </xs:complexType>
+                                                        </xs:element>
+                                                        <!-- This var element defines a variable that does not live within a var_array group. -->
+                                                        <xs:element name="var"  maxOccurs="unbounded" minOccurs="0" >
+                                                                <xs:complexType>
+                                                                        <!-- The name attribute defines the name in the NetCDF files of this variable. -->
+                                                                        <xs:attribute name="name"  type="xs:string" use="required"/>
+                                                                        <!-- The type attribute defines the type within MPAS of the variable. -->
+                                                                        <xs:attribute name="type"  type="xs:string" use="required"/>
+                                                                        <!-- The dimensions attribute defines the dimensions of the variable. -->
+                                                                        <xs:attribute name="dimensions"  type="xs:string" use="required"/>
+                                                                        <!-- The streams attribute defines the streams this variable is included in. -->
+                                                                        <xs:attribute name="streams"  type="xs:string" use="optional"/>
+                                                                        <!-- The name_in_code attribute defines the name of the variable within MPAS (if different from name). -->
+                                                                        <xs:attribute name="name_in_code"  type="xs:string" use="optional"/>
+                                                                        <!-- The units attribute defines the units of the variable. -->
+                                                                        <xs:attribute name="units"  type="xs:string" use="optional"/>
+                                                                        <!-- The description attribute provides a brief description of the variable. -->
+                                                                        <xs:attribute name="description"  type="xs:string" use="optional"/>
+                                                                </xs:complexType>
+                                                        </xs:element>
+                                                </xs:sequence>
+                                                <!-- The name attribute defines the name of the var_struct. This would be similar to mesh, or state. -->
+                                                <xs:attribute name="name"  type="xs:string" use="required"/>
+                                                <!-- The time_levs attribute defines the number of time levels this var_struct contains. -->
+                                                <xs:attribute name="time_levs"  type="xs:int" use="required"/>
+                                        </xs:complexType>
+                                </xs:element>
+                        </xs:sequence>
+                </xs:complexType>
+        </xs:element>
+</xs:schema>
Modified: trunk/mpas/src/registry/gen_inc.c
===================================================================
--- trunk/mpas/src/registry/gen_inc.c        2013-03-22 17:48:50 UTC (rev 2662)
+++ trunk/mpas/src/registry/gen_inc.c        2013-03-22 19:32:26 UTC (rev 2663)
@@ -1161,7 +1161,10 @@
             for(i=1; i<=ntime_levs; i++) 
             {
                                 fortprintf(fd, "         if(associated(next) .and. associated(prev)) then</font>
<font color="red">");        
-                                fortprintf(fd, "           call mpas_create_%s_links(b %% %s %% time_levs(%i) %% %s, prev = prev %% %s %% time_levs(%i) %% %s, next = next %% %s %% time_levs(%i) %% %s)</font>
<font color="blue">", group_ptr->name, group_ptr->name, i, group_ptr->name, i, group_ptr->name, group_ptr->name, i, group_ptr->name);
+//                                fortprintf(fd, "           call mpas_create_%s_links(b %% %s %% time_levs(%i) %% %s, prev = prev %% %s %% time_levs(%i) %% %s, next = next %% %s %% time_levs(%i) %% %s)</font>
<font color="blue">", group_ptr->name, group_ptr->name, i, group_ptr->name, i, group_ptr->name, group_ptr->name, i, group_ptr->name);
+                                fortprintf(fd, "           call mpas_create_%s_links(b %% %s %% time_levs(%i) %% %s, ", group_ptr->name, group_ptr->name, i, group_ptr->name, i);
+                                fortprintf(fd, " prev = prev %% %s %% time_levs(%i) %% %s,", group_ptr->name, i, group_ptr->name);
+                                fortprintf(fd, " next = next %% %s %% time_levs(%i) %% %s)</font>
<font color="black">", group_ptr->name, i, group_ptr->name);
                                 fortprintf(fd, "         else if(associated(next)) then</font>
<font color="black">");        
                                 fortprintf(fd, "           call mpas_create_%s_links(b %% %s %% time_levs(%i) %% %s, next = next %% %s %% time_levs(%i) %% %s)</font>
<font color="black">", group_ptr->name, group_ptr->name, i, group_ptr->name, group_ptr->name, i, group_ptr->name);
                                 fortprintf(fd, "         else if(associated(prev)) then</font>
<font color="gray">");        
@@ -1389,7 +1392,7 @@
 void gen_reads(struct group_list * groups, struct variable * vars, struct dimension * dims)
 {
    struct variable * var_ptr;
-   struct variable_list * var_list_ptr;
+   struct variable_list * var_list_ptr, *var_list_ptr2;
    struct dimension * dim_ptr;
    struct dimension_list * dimlist_ptr, * lastdim;
    struct group_list * group_ptr;
@@ -2119,8 +2122,10 @@
 /*            fortprintf(fd, "         write(0,*) \'adding input field %s\'</font>
<font color="black">", var_ptr->super_array); */
             fortprintf(fd, "         call MPAS_streamAddField(input_obj %% io_stream, %s %% %s, nferr)</font>
<font color="blue">", struct_deref, var_ptr->super_array);
             while (var_list_ptr && strncmp(super_array, var_list_ptr->var->super_array, 1024) == 0) {
+                           var_list_ptr2 = var_list_ptr;
                var_list_ptr = var_list_ptr->next;
             }
+                        var_list_ptr = var_list_ptr2;
          }
          else {
             fortprintf(fd, "      if ((%s %% %s %% ioinfo %% input .and. input_obj %% stream == STREAM_INPUT) .or. &</font>
<font color="gray">", struct_deref, var_ptr->name_in_code);
@@ -2176,8 +2181,10 @@
 /*                     fortprintf(fd, "         write(0,*) \'exchange halo for %s\'</font>
<font color="black">", var_ptr->super_array); */
                      fortprintf(fd, "         call mpas_dmpar_exch_halo_field(%s %% %s)</font>
<font color="blue">", struct_deref, var_ptr->super_array);
                      while (var_list_ptr && strncmp(super_array, var_list_ptr->var->super_array, 1024) == 0) {
+                                                var_list_ptr2 = var_list_ptr;
                         var_list_ptr = var_list_ptr->next;
                      }
+                                         var_list_ptr = var_list_ptr2;
                   }
                   else {
                      fortprintf(fd, "      if ((%s %% %s %% ioinfo %% input .and. input_obj %% stream == STREAM_INPUT) .or. &</font>
<font color="gray">", struct_deref, var_ptr->name_in_code);
@@ -2383,7 +2390,7 @@
 void gen_writes(struct group_list * groups, struct variable * vars, struct dimension * dims, struct namelist * namelists)
 {
    struct variable * var_ptr;
-   struct variable_list * var_list_ptr;
+   struct variable_list * var_list_ptr, *var_list_ptr2;
    struct dimension * dim_ptr;
    struct dimension_list * dimlist_ptr, * lastdim;
    struct group_list * group_ptr;
@@ -2565,8 +2572,10 @@
             memcpy(super_array, var_ptr->super_array, 1024);
             fortprintf(fd, "         call MPAS_streamAddField(output_obj %% io_stream, %s %% %s, ierr)</font>
<font color="blue">", struct_deref, super_array);
             while (var_list_ptr && strncmp(super_array, var_list_ptr->var->super_array, 1024) == 0) {
+                           var_list_ptr2 = var_list_ptr;
                var_list_ptr = var_list_ptr->next;
             }
+                        var_list_ptr = var_list_ptr2;
          }
          else {
             fortprintf(fd, "      if ((%s %% %s %% ioinfo %% output .and. output_obj %% stream == OUTPUT) .or. &</font>
<font color="gray">", struct_deref, var_ptr->name_in_code);
Modified: trunk/mpas/src/registry/parse.c
===================================================================
--- trunk/mpas/src/registry/parse.c        2013-03-22 17:48:50 UTC (rev 2662)
+++ trunk/mpas/src/registry/parse.c        2013-03-22 19:32:26 UTC (rev 2663)
@@ -3,6 +3,7 @@
 #include <string.h>
 #include "registry_types.h"
 #include "gen_inc.h"
+#include "ezxml/ezxml.h"
 
 int parse_reg(FILE *, struct namelist **, struct dimension **, struct variable **, struct group_list **);
 int getword(FILE *, char *);
@@ -30,9 +31,16 @@
    nls = NULL;
    dims = NULL;
    vars = NULL;
+  
+   if (parse_reg_xml(regfile, &nls, &dims, &vars, &groups)) {
+      return 1;
+   }
+  
+/* Old Parser
    if (parse_reg(regfile, &nls, &dims, &vars, &groups)) {
       return 1;
    }
+*/
 
    sort_vars(vars);
    sort_group_vars(groups);
@@ -45,7 +53,391 @@
    return 0;
 }
 
+int parse_reg_xml(FILE * regfile, struct namelist **nls, struct dimension ** dims, struct variable ** vars, struct group_list ** groups)
+{
+        struct namelist * nls_ptr, *nls_ptr2;
+        struct namelist * nls_chk_ptr;
+        struct dimension * dim_ptr, *dim_ptr2;
+        struct variable * var_ptr, *var_ptr2;
+        struct dimension_list * dimlist_ptr;
+        struct dimension * dimlist_cursor;
+        struct group_list * grouplist_ptr;
+        struct variable_list * vlist_cursor;
 
+        ezxml_t registry = ezxml_parse_fp(regfile);
+        ezxml_t dims_xml, dim_xml;
+        ezxml_t structs_xml, var_arr_xml, var_xml;
+        ezxml_t nmlrecs_xml, nmlopt_xml;
+
+        const char *dimname, *dimunits, *dimdesc, *dimdef;
+        const char *nmlrecname, *nmloptname, *nmlopttype, *nmloptval, *nmloptunits, *nmloptdesc, *nmloptposvals;
+        const char *structname, *structlevs;
+        const char *vararrname, *vararrtype, *vararrdims, *vararrpersistence;
+        const char *varname, *varpersistence, *vartype, *vardims, *varunits, *vardesc, *vararrgroup, *varstreams;
+        const char *varname_in_code;
+
+        char dimensions[2048];
+        char *dimension_list;
+        char dimension_buffer[128];
+        char streams_buffer[128];
+
+        NEW_NAMELIST(nls_ptr)
+        NEW_DIMENSION(dim_ptr)
+        NEW_VARIABLE(var_ptr)
+        NEW_GROUP_LIST(grouplist_ptr);
+        *nls = nls_ptr;
+        *dims = dim_ptr;
+        *vars = var_ptr;
+        *groups = grouplist_ptr;
+
+        // Parse Namelist Records
+        for (nmlrecs_xml = ezxml_child(registry, "nml_record"); nmlrecs_xml; nmlrecs_xml = nmlrecs_xml->next){
+                nmlrecname = ezxml_attr(nmlrecs_xml, "name");
+                for (nmlopt_xml = ezxml_child(nmlrecs_xml, "nml_option"); nmlopt_xml; nmlopt_xml = nmlopt_xml->next){
+                        nmloptname = ezxml_attr(nmlopt_xml, "name");
+                        nmlopttype = ezxml_attr(nmlopt_xml, "type");
+                        nmloptval = ezxml_attr(nmlopt_xml, "default_value");
+                        nmloptunits = ezxml_attr(nmlopt_xml, "units");
+                        nmloptdesc = ezxml_attr(nmlopt_xml, "description");
+                        nmloptposvals = ezxml_attr(nmlopt_xml, "possible_values");
+
+                        snprintf(nls_ptr->record, 1024, "%s", nmlrecname);
+                        snprintf(nls_ptr->name, 1024, "%s", nmloptname);
+
+                        if(strncmp(nmlopttype, "real", 1024) == 0){
+                                nls_ptr->vtype = REAL;
+                        } else if(strncmp(nmlopttype, "integer", 1024) == 0){
+                                nls_ptr->vtype = INTEGER;
+                        } else if(strncmp(nmlopttype, "logical", 1024) == 0){
+                                nls_ptr->vtype = LOGICAL;
+                        } else if(strncmp(nmlopttype, "character", 1024) == 0){
+                                nls_ptr->vtype = CHARACTER;
+                        }
+
+                        switch(nls_ptr->vtype){
+                                case REAL:
+                                        nls_ptr->defval.rval = (float)atof(nmloptval);
+                                        break;
+                                case INTEGER:
+                                        nls_ptr->defval.ival = atoi(nmloptval);
+                                        break;
+                                case LOGICAL:
+                                        if(strncmp(nmloptval, "true", 1024) ==0){
+                                                nls_ptr->defval.lval = 1;
+                                        } else if (strncmp(nmloptval, "false", 1024) == 0){
+                                                nls_ptr->defval.lval = 0;
+                                        }
+                                        break;
+                                case CHARACTER:
+                                        snprintf(nls_ptr->defval.cval, 32, "%s", nmloptval);
+                                        break;
+                        }
+
+                        NEW_NAMELIST(nls_ptr->next)
+                        nls_ptr2 = nls_ptr;
+                        nls_ptr = nls_ptr->next;
+                }
+        }
+
+        if(nls_ptr2->next) free(nls_ptr2->next);
+        nls_ptr2->next = NULL;
+
+        // Parse Dimensions
+        for (dims_xml = ezxml_child(registry, "dims"); dims_xml; dims_xml = dims_xml->next){
+                for (dim_xml = ezxml_child(dims_xml, "dim"); dim_xml; dim_xml = dim_xml->next){
+                        dimname = ezxml_attr(dim_xml, "name");
+                        dimdef = ezxml_attr(dim_xml, "definition");        
+                        dimunits = ezxml_attr(dim_xml, "units");
+                        dimdesc = ezxml_attr(dim_xml, "description");
+
+                        dim_ptr->namelist_defined = 0;
+
+                        snprintf(dim_ptr->name_in_file, 1024, "%s", dimname);
+                        if(dimdef == NULL){
+                                snprintf(dim_ptr->name_in_code, 1024, "%s", dimname);
+                                dim_ptr->constant_value = -1;
+                        } else {
+                                snprintf(dim_ptr->name_in_code, 1024, "%s", dimdef);
+                                // Check namelist defined ??
+                                dim_ptr->constant_value = is_integer_constant(dim_ptr->name_in_code);
+                                if(strncmp(dim_ptr->name_in_code, "namelist:", 9) == 0) {
+                                        dim_ptr->namelist_defined = 1;
+                                        snprintf(dim_ptr->name_in_code, 1024, "%s", (dim_ptr->name_in_code)+9);
+
+                                        /* Check that the referenced namelist variable is defined as an integer variable */
+                                        nls_chk_ptr = (*nls)->next;
+                                        while (nls_chk_ptr) {
+                                                if (strncmp(nls_chk_ptr->name, dim_ptr->name_in_code, 1024) == 0) {
+                                                        if (nls_chk_ptr->vtype != INTEGER) {
+                                                                printf("</font>
<font color="black">Registry error: Namelist variable %s must be an integer for namelist-derived dimension %s</font>
<font color="black"></font>
<font color="blue">", nls_chk_ptr->name, dim_ptr->name_in_file);
+                                                                return 1;
+                                                        }
+                                                        break;
+                                                } 
+                                                nls_chk_ptr = nls_chk_ptr->next;
+                                        }
+                                        if (!nls_chk_ptr) {
+                                                printf("</font>
<font color="black">Registry error: Namelist variable %s not defined for namelist-derived dimension %s</font>
<font color="black"></font>
<font color="blue">", dim_ptr->name_in_code, dim_ptr->name_in_file);
+                                                return 1;
+                                        }
+
+                                }
+                        }
+
+                        NEW_DIMENSION(dim_ptr->next)
+                        dim_ptr2 = dim_ptr;
+                        dim_ptr = dim_ptr->next;
+                }   
+        }
+
+        if(dim_ptr2->next) free(dim_ptr2->next);
+        dim_ptr2->next = NULL;
+
+        // Parse Variable Structures
+        for(structs_xml = ezxml_child(registry, "var_struct"); structs_xml; structs_xml = structs_xml->next){
+                structname = ezxml_attr(structs_xml, "name");
+                structlevs = ezxml_attr(structs_xml, "time_levs");
+
+                grouplist_ptr = *groups;
+                while(grouplist_ptr->next) grouplist_ptr = grouplist_ptr->next;
+                NEW_GROUP_LIST(grouplist_ptr->next);
+                grouplist_ptr = grouplist_ptr->next;
+                snprintf(grouplist_ptr->name, 1024, "%s", structname);
+                vlist_cursor = NULL;
+
+                // Parse variable arrays
+                for(var_arr_xml = ezxml_child(structs_xml, "var_array"); var_arr_xml; var_arr_xml = var_arr_xml->next){
+                        vararrname = ezxml_attr(var_arr_xml, "name");
+                        vararrtype = ezxml_attr(var_arr_xml, "type");
+                        vararrdims = ezxml_attr(var_arr_xml, "dimensions");
+                        vararrpersistence = ezxml_attr(var_arr_xml, "persistence");
+
+                        //Parse variables in variable arrays
+                        for(var_xml = ezxml_child(var_arr_xml, "var"); var_xml; var_xml = var_xml->next){
+                                varname = ezxml_attr(var_xml, "name");
+                                varunits = ezxml_attr(var_xml, "units");
+                                vardesc = ezxml_attr(var_xml, "description");
+                                varstreams = ezxml_attr(var_xml, "streams");
+                                vararrgroup = ezxml_attr(var_xml, "array_group");
+                                varname_in_code = ezxml_attr(var_xml, "name_in_code");
+
+                                if(vlist_cursor == NULL){
+                                        NEW_VARIABLE_LIST(grouplist_ptr->vlist);
+                                        vlist_cursor = grouplist_ptr->vlist;
+                                } else {
+                                        NEW_VARIABLE_LIST(vlist_cursor->next);
+                                        vlist_cursor->next->prev = vlist_cursor;
+                                        vlist_cursor = vlist_cursor->next;
+                                }
+                                vlist_cursor->var = var_ptr;
+                                vlist_cursor->next = NULL;
+
+                                var_ptr->ndims = 0;
+                                var_ptr->timedim = 0;
+                                var_ptr->iostreams = 0;
+
+                                snprintf(var_ptr->name_in_file, 1024, "%s", varname);
+
+                                if(vararrpersistence == NULL){
+                                        var_ptr->persistence = PERSISTENT;
+                                } else {
+                                        if(strncmp(vararrpersistence, "persistent", 1024) == 0){
+                                                var_ptr->persistence = PERSISTENT;
+                                        } else if(strncmp(vararrpersistence, "scratch", 1024) == 0){
+                                                var_ptr->persistence = SCRATCH;
+                                        }
+                                }
+
+                                if(strncmp(vararrtype, "real", 1024) == 0){
+                                        var_ptr->vtype = REAL;
+                                } else if(strncmp(vararrtype, "integer", 1024) == 0){
+                                        var_ptr->vtype = INTEGER;
+                                } else if(strncmp(vararrtype, "logical", 1024) == 0){
+                                        var_ptr->vtype = LOGICAL;
+                                } else if(strncmp(vararrtype, "text", 1024) == 0){
+                                        var_ptr->vtype = CHARACTER;
+                                }
+
+                                NEW_DIMENSION_LIST(dimlist_ptr)
+                                var_ptr->dimlist = dimlist_ptr;
+
+                                snprintf(dimensions,2048, "%s", vararrdims);
+                                dimension_list = strtok(dimensions, " ");
+                                while(dimension_list != NULL){
+                                        snprintf(dimension_buffer, 128, "%s", dimension_list);
+                                        if(strncmp(dimension_buffer, "Time", 1024) == 0){
+                                                var_ptr->timedim = 1;
+                                        } else {
+                                                NEW_DIMENSION_LIST(dimlist_ptr->next)
+                                                dimlist_ptr->next->prev = dimlist_ptr;
+                                                dimlist_ptr = dimlist_ptr->next;
+
+                                                dimlist_cursor = (*dims);
+                                                while(dimlist_cursor && (strncmp(dimension_buffer, dimlist_cursor->name_in_file, 1024) != 0)){
+                                                        dimlist_cursor = dimlist_cursor->next;
+                                                }
+                                                if (dimlist_cursor) {
+                                                        dimlist_ptr->dim = dimlist_cursor;
+                                                } else {
+                                                        fprintf(stderr, "Error: Unknown dimension %s for variable %s</font>
<font color="blue">", dimension_buffer, var_ptr->name_in_file);
+                                                        return 1;
+                                                }
+                                                var_ptr->ndims++;
+                                        }
+                                        dimension_list = strtok(NULL, " ");
+                                }
+                                dimlist_ptr = var_ptr->dimlist;
+                                if(var_ptr->dimlist) var_ptr->dimlist = var_ptr->dimlist->next;
+                                free(dimlist_ptr);
+
+                                var_ptr->ntime_levs = atoi(structlevs);
+
+                                if(varstreams != NULL){
+                                        snprintf(streams_buffer, 128, "%s", varstreams);
+                                        if(strchr(streams_buffer, (int)'i')) var_ptr->iostreams |= INPUT0;
+                                        if(strchr(streams_buffer, (int)'s')) var_ptr->iostreams |= SFC0;
+                                        if(strchr(streams_buffer, (int)'r')) var_ptr->iostreams |= RESTART0;
+                                        if(strchr(streams_buffer, (int)'o')) var_ptr->iostreams |= OUTPUT0;
+                                }
+
+                                if(varname_in_code == NULL){
+                                        snprintf(var_ptr->name_in_code, 1024, "%s", varname);
+                                } else {
+                                        snprintf(var_ptr->name_in_code, 1024, "%s", varname_in_code);
+                                }
+
+                                snprintf(var_ptr->super_array, 1024, "%s", vararrname);
+                                snprintf(var_ptr->array_class, 1024, "%s", vararrgroup);
+
+                                NEW_VARIABLE(var_ptr->next);
+                                var_ptr2 = var_ptr;
+                                var_ptr = var_ptr->next;
+                        }
+                }
+
+                for(var_xml = ezxml_child(structs_xml, "var"); var_xml; var_xml = var_xml->next){
+                        varname = ezxml_attr(var_xml, "name");
+                        varpersistence = ezxml_attr(var_xml, "persistence");
+                        vartype = ezxml_attr(var_xml, "type");
+                        vardims = ezxml_attr(var_xml, "dimensions");
+                        varunits = ezxml_attr(var_xml, "units");
+                        vardesc = ezxml_attr(var_xml, "description");
+                        varstreams = ezxml_attr(var_xml, "streams");
+                        varname_in_code = ezxml_attr(var_xml, "name_in_code");
+
+                        if(vlist_cursor == NULL){
+                                NEW_VARIABLE_LIST(grouplist_ptr->vlist);
+                                vlist_cursor = grouplist_ptr->vlist;
+                        } else {
+                                NEW_VARIABLE_LIST(vlist_cursor->next);
+                                vlist_cursor->next->prev = vlist_cursor;
+                                vlist_cursor = vlist_cursor->next;
+                        }
+                        vlist_cursor->var = var_ptr;
+                        vlist_cursor->next = NULL;
+
+                        var_ptr->ndims = 0;
+                        var_ptr->timedim = 0;
+                        var_ptr->iostreams = 0;
+
+                        snprintf(var_ptr->name_in_file, 1024, "%s", varname);
+
+                        if(varpersistence == NULL){
+                                var_ptr->persistence = PERSISTENT;
+                        } else {
+                                if(strncmp(varpersistence, "persistent", 1024) == 0){
+                                        var_ptr->persistence = PERSISTENT;
+                                } else if(strncmp(varpersistence, "scratch", 1024) == 0){
+                                        var_ptr->persistence = SCRATCH;
+                                }
+                        }
+
+                        if(strncmp(vartype, "real", 1024) == 0){
+                                var_ptr->vtype = REAL;
+                        } else if(strncmp(vartype, "integer", 1024) == 0){
+                                var_ptr->vtype = INTEGER;
+                        } else if(strncmp(vartype, "logical", 1024) == 0){
+                                var_ptr->vtype = LOGICAL;
+                        } else if(strncmp(vartype, "text", 1024) == 0){
+                                var_ptr->vtype = CHARACTER;
+                        }
+
+                        NEW_DIMENSION_LIST(dimlist_ptr)
+                        var_ptr->dimlist = dimlist_ptr;
+
+                        snprintf(dimensions, 2048, "%s", vardims);
+                        dimension_list = strtok(dimensions, " ");
+                        while(dimension_list != NULL){
+                                snprintf(dimension_buffer, 128, "%s", dimension_list);
+                                if(strncmp(dimension_buffer, "Time", 1024) == 0){
+                                        var_ptr->timedim = 1;
+                                } else {
+                                        NEW_DIMENSION_LIST(dimlist_ptr->next)
+                                        dimlist_ptr->next->prev = dimlist_ptr;
+                                        dimlist_ptr = dimlist_ptr->next;
+
+                                        dimlist_cursor = (*dims);
+                                        while(dimlist_cursor && (strncmp(dimension_buffer, dimlist_cursor->name_in_file, 1024) != 0) )
+                                                dimlist_cursor = dimlist_cursor->next;
+                                        if (dimlist_cursor) {
+                                                dimlist_ptr->dim = dimlist_cursor;
+                                        } else {
+                                                fprintf(stderr, "Error: Unknown dimension %s for variable %s</font>
<font color="gray">", dimension_buffer, var_ptr->name_in_file);
+                                                return 1;
+                                        }
+                                        var_ptr->ndims++;
+                                }
+                                dimension_list = strtok(NULL, " ");
+                        }
+
+                        dimlist_ptr = var_ptr->dimlist;
+                        if(var_ptr->dimlist) var_ptr->dimlist = var_ptr->dimlist->next;
+                        free(dimlist_ptr);
+
+                        var_ptr->ntime_levs = atoi(structlevs);
+
+                        if(varstreams != NULL){
+                                snprintf(streams_buffer, 128, "%s", varstreams);
+                                if(strchr(streams_buffer, (int)'i')) {
+                                        var_ptr->iostreams |= INPUT0;
+                                }
+                                if(strchr(streams_buffer, (int)'s')) {
+                                        var_ptr->iostreams |= SFC0;
+                                }
+                                if(strchr(streams_buffer, (int)'r')) {
+                                        var_ptr->iostreams |= RESTART0;
+                                }
+                                if(strchr(streams_buffer, (int)'o')) {
+                                        var_ptr->iostreams |= OUTPUT0;
+                                }
+                        }
+
+                        if(varname_in_code == NULL){
+                                snprintf(var_ptr->name_in_code, 1024, "%s", varname);
+                        } else {
+                                snprintf(var_ptr->name_in_code, 1024, "%s", varname_in_code);
+                        }
+
+                        snprintf(var_ptr->super_array, 1024, "-");
+                        snprintf(var_ptr->array_class, 1024, "-");
+
+                        NEW_VARIABLE(var_ptr->next);
+                        var_ptr2 = var_ptr;
+                        var_ptr = var_ptr->next;
+                }
+        }
+
+        if(var_ptr2->next) free(var_ptr2->next);
+        var_ptr2->next = NULL;
+
+        grouplist_ptr = *groups;
+        if ((*groups)->next) *groups = (*groups)->next;
+        if (grouplist_ptr) free(grouplist_ptr);
+
+        return 0;
+}
+
+
 int parse_reg(FILE * regfile, struct namelist ** nls, struct dimension ** dims, struct variable ** vars, struct group_list ** groups)
 {
    char word[1024];
@@ -228,7 +620,6 @@
             vlist_cursor->var = var_ptr;
          }
 
-
          getword(regfile, var_ptr->super_array);
          getword(regfile, var_ptr->array_class);
 
@@ -402,7 +793,7 @@
          memcpy(super_array, var_ptr->var->super_array, 1024);
          var_ptr2_prev = var_ptr;
          var_ptr2 = var_ptr->next;
-         if (var_ptr2 && strncmp(super_array, var_ptr2->var->super_array, 1024) != 0) {
+         if (var_ptr2 != NULL && strncmp(super_array, var_ptr2->var->super_array, 1024) != 0) {
             while (var_ptr2) {
                if (strncmp(super_array, var_ptr2->var->super_array, 1024) == 0) {
                   var_ptr2_prev->next = var_ptr2->next;
</font>
</pre>