[Dart-dev] DART/branches Revision: 11736

dart at ucar.edu dart at ucar.edu
Wed Jun 14 18:01:26 MDT 2017


thoar at ucar.edu
2017-06-14 18:01:25 -0600 (Wed, 14 Jun 2017)
331
pmo compiles and runs up to the point that the variable list must be constructed
from the constituent base variable names.

A key step is to create the state.vars file by running 

  shell_scripts/populate_state_vars.pl ../templates/EXAMPLE.restart.dat true

This file is read in place of reading a variable list in the input.nml




Modified: DART/branches/coamps/models/coamps_nest/coamps_domain_mod.f90
===================================================================
--- DART/branches/coamps/models/coamps_nest/coamps_domain_mod.f90	2017-06-14 23:00:38 UTC (rev 11735)
+++ DART/branches/coamps/models/coamps_nest/coamps_domain_mod.f90	2017-06-15 00:01:25 UTC (rev 11736)
@@ -205,10 +205,12 @@
 
         call initialize_grid(coamps_datahd, domain%static_grid)
 
-        call initialize_nests(dtg, coamps_datahd, domain)
+        call initialize_nests(filename, dtg, coamps_datahd, domain)
 
         call initialize_vertical(coamps_datahd, domain%vertical)
 
+        call dump_domain_info(domain, .true.)
+
         domain%is_initialized = .true.
     end subroutine initialize_domain
 
@@ -759,8 +761,9 @@
   !   IN  dtg               date-time-group of forecast
   !   IN  datahd            datahd record to source
   ! INOUT domain            COAMPS domain to populate
-  subroutine initialize_nests(dtg, datahd, domain)
-    character(len=10),           intent(in)    :: dtg
+  subroutine initialize_nests(filename, dtg, datahd, domain)
+    character(len=*),            intent(in)    :: filename
+    character(len=*),            intent(in)    :: dtg
     real(kind=r8), dimension(:), intent(in)    :: datahd
     type(coamps_domain),         intent(inout) :: domain 
 
@@ -777,7 +780,7 @@
     do cur_nest_id = 1, domain%nest_count
         call set_nest_id(domain%nests(cur_nest_id), cur_nest_id)
 
-        call initialize_nest(domain%nests(cur_nest_id), dtg, datahd)    
+        call initialize_nest(filename, domain%nests(cur_nest_id), dtg, datahd)    
 
         ! Interface this nest with the other nests
         parent_nest_id = get_parent_nest_id(domain%nests(cur_nest_id))

Modified: DART/branches/coamps/models/coamps_nest/coamps_nest_mod.f90
===================================================================
--- DART/branches/coamps/models/coamps_nest/coamps_nest_mod.f90	2017-06-14 23:00:38 UTC (rev 11735)
+++ DART/branches/coamps/models/coamps_nest/coamps_nest_mod.f90	2017-06-15 00:01:25 UTC (rev 11736)
@@ -24,6 +24,11 @@
 
     use utilities_mod, only: E_ERR, error_handler, get_unit
 
+    use netcdf_utilities_mod, only : nc_check
+
+    use netcdf
+    use typesizes
+
     implicit none
 
     private
@@ -233,9 +238,10 @@
     ! INOUT nest              COAMPS nest to initialize
     !   IN  dtg               COAMPS date-time-group
     !   IN  datahd            datahd record to source
-    subroutine initialize_nest(nest, dtg, datahd)
+    subroutine initialize_nest(filename, nest, dtg, datahd)
+        character(len=*),            intent(in)    :: filename
         type(coamps_nest),           intent(inout) :: nest
-        character(len=10),           intent(in)    :: dtg
+        character(len=*),            intent(in)    :: dtg
         real(kind=r8), dimension(:), intent(in)    :: datahd
 
         integer :: nest_offset
@@ -256,7 +262,7 @@
         nest%nest_level = int(datahd(DATAHD_NEST_LEVEL + nest_offset))
 
         call initialize_list(nest%child_nests)
-        call read_terrain_height(nest, dtg)
+        call read_terrain_height(filename, nest, dtg)
 
         nullify(nest%iminf)
         nullify(nest%imaxf)
@@ -1144,20 +1150,21 @@
     !  PARAMETERS
     ! INOUT nest              The nest to add terrain data to
     !   IN  dtg               COAMPS date-time group
-    subroutine read_terrain_height(nest, dtg)
+
+    subroutine read_terrain_height(filename, nest, dtg)
+
+        character(len=*),  intent(in)    :: filename
         type(coamps_nest), intent(inout) :: nest
-        character(len=10), intent(in)    :: dtg
+        character(len=*),  intent(in)    :: dtg
 
+        character(len=*), parameter :: routine = 'read_terrain_height'
+
         character(len=64) :: terrht_name
-        integer           :: terrht_unit
-        integer           :: terrht_record_len
-        integer           :: r4_len
+        integer           :: terrht_unit, VarID
+        integer           :: io
+        integer           :: alloc_status
+        integer           :: dealloc_status


More information about the Dart-dev mailing list