[Dart-dev] DART/branches Revision: 11645
dart at ucar.edu
dart at ucar.edu
Thu May 18 16:55:44 MDT 2017
thoar at ucar.edu
2017-05-18 16:55:43 -0600 (Thu, 18 May 2017)
657
streamlining the lmdz_to_dart.f90 code, removing some unused interface routines.
The model_mod.f90 has problems. I put in some debug statements that are getting committed.
When compiling with bounds checking ... when vert_coord = pressure,
At line 795 of file ../../../models/LMDZ/model_mod.f90
Fortran runtime error: Index '362' of dimension 1 of array 'phis%vals' above upper bound of 361
When vert_coord = log_invP
TJH scale height p_surface, p_above -888888.00000000000 15000.000000000000
(and it blows up when taking the log of that ratio ...)
The model_reff variable does not have a valid value before scale_height() is called.
Modified: DART/branches/LMDZ_trunk/models/LMDZ/dart_to_lmdz.f90
===================================================================
--- DART/branches/LMDZ_trunk/models/LMDZ/dart_to_lmdz.f90 2017-05-18 17:15:40 UTC (rev 11644)
+++ DART/branches/LMDZ_trunk/models/LMDZ/dart_to_lmdz.f90 2017-05-18 22:55:43 UTC (rev 11645)
@@ -24,9 +24,10 @@
initialize_utilities, finalize_utilities, &
logfileunit, nmlfileunit, do_nml_file, do_nml_term, &
check_namelist_read, find_namelist_in_file
-use model_mod, only : data_2d_type,data_3d_type, init_model_instance, write_lmdz_init, &
- vector_to_prog_var, static_init_model, get_model_size
-use assim_model_mod, only : aread_state_restart, open_restart_read, close_restart
+use model_mod, only : data_2d_type, data_3d_type, init_model_instance, &
+ write_lmdz_init, vector_to_prog_var, static_init_model, &
+ get_model_size
+use assim_model_mod, only : aread_state_restart, open_restart_read, close_restart
use time_manager_mod, only : time_type, print_time, print_date
implicit none
@@ -52,7 +53,7 @@
!----------------------------------------------------------------------
type(data_2d_type) :: PS_local
-type(data_3d_type) :: T_local,U_local,V_local,Q_local,CLDLIQ_local
+type(data_3d_type) :: T_local, U_local, V_local, Q_local, CLDLIQ_local
type(time_type) :: model_time, adv_to_time
real(r8), allocatable :: statevector(:)
integer :: file_unit, vecsize, iunit, io
Modified: DART/branches/LMDZ_trunk/models/LMDZ/lmdz_to_dart.f90
===================================================================
--- DART/branches/LMDZ_trunk/models/LMDZ/lmdz_to_dart.f90 2017-05-18 17:15:40 UTC (rev 11644)
+++ DART/branches/LMDZ_trunk/models/LMDZ/lmdz_to_dart.f90 2017-05-18 22:55:43 UTC (rev 11645)
@@ -22,10 +22,9 @@
use utilities_mod, only : initialize_utilities, finalize_utilities, do_output, &
check_namelist_read, find_namelist_in_file, nmlfileunit, &
do_nml_file, do_nml_term
-use model_mod, only : data_2d_type,data_3d_type, init_model_instance, end_model_instance, &
- prog_var_to_vector, read_lmdz_init, static_init_model,PS,T,U,V,Q,CLDLIQ
-use assim_model_mod, only : static_init_assim_model, get_model_size, &
- open_restart_write, awrite_state_restart, close_restart
+use model_mod, only : get_model_size, init_model_instance, end_model_instance, &
+ prog_var_to_vector, read_lmdz_init, PS,T,U,V,Q,CLDLIQ
+use assim_model_mod, only : open_restart_write, awrite_state_restart, close_restart
use time_manager_mod, only : time_type
implicit none
@@ -47,29 +46,21 @@
! allocatable storage to read in a native format for lmdz state
-real(r8), allocatable :: statevector(:)
-type(time_type) :: model_time
-integer :: iunit, x_size, io
+real(r8), allocatable :: statevector(:)
+type(time_type) :: model_time
+integer :: iunit, x_size, io
call initialize_utilities('lmdz_to_dart')
-! Read the namelist entry
+! Read the namelist
call find_namelist_in_file("input.nml", "lmdz_to_dart_nml", iunit)
read(iunit, nml = lmdz_to_dart_nml, iostat = io)
call check_namelist_read(iunit, io, "lmdz_to_dart_nml")
! Record the namelist values
-
-! do_nml_file () : *** return whether nml should be written to nml file
-
if (do_nml_file()) write(nmlfileunit, nml=lmdz_to_dart_nml)
if (do_nml_term()) write( * , nml=lmdz_to_dart_nml)
-! Static init assim model sets the output file format (binary/ascii)
-! call static_init_model()
-
-call static_init_assim_model()
-
! Allocate the local state vector
x_size = get_model_size()
allocate(statevector(x_size))
Modified: DART/branches/LMDZ_trunk/models/LMDZ/model_mod.f90
===================================================================
--- DART/branches/LMDZ_trunk/models/LMDZ/model_mod.f90 2017-05-18 17:15:40 UTC (rev 11644)
+++ DART/branches/LMDZ_trunk/models/LMDZ/model_mod.f90 2017-05-18 22:55:43 UTC (rev 11645)
@@ -121,8 +121,9 @@
ens_mean_for_model
public :: &
- data_2d_type,data_3d_type,PS,T,U,V,Q,CLDLIQ, prog_var_to_vector, &
- vector_to_prog_var, read_lmdz_init, read_lmdz_init_size, &
+ data_2d_type, data_3d_type, PS, T, U, V, Q, CLDLIQ, &
+ prog_var_to_vector, &
+ vector_to_prog_var, read_lmdz_init, &
init_model_instance, end_model_instance, write_lmdz_init, coord_index
!----------------------------------------------------------------------------
@@ -174,8 +175,8 @@
end type grid_1D_type
!-------
More information about the Dart-dev
mailing list