[Dart-dev] DART/branches Revision: 12343
dart at ucar.edu
dart at ucar.edu
Wed Jan 17 14:03:13 MST 2018
nancy at ucar.edu
2018-01-17 14:03:12 -0700 (Wed, 17 Jan 2018)
89
don't convert VERTISUNDEF obs/state, and
remove some of the debugging print statements.
Modified: DART/branches/recam/models/cam-fv/model_mod.f90
===================================================================
--- DART/branches/recam/models/cam-fv/model_mod.f90 2018-01-17 20:42:35 UTC (rev 12342)
+++ DART/branches/recam/models/cam-fv/model_mod.f90 2018-01-17 21:03:12 UTC (rev 12343)
@@ -2889,15 +2889,12 @@
ens_size = 1
-!print *, 'convert_vertical_state, num = ', num
do i=1,num
current_vert_type = nint(query_location(locs(i)))
if ( current_vert_type == which_vert ) cycle
-
if ( current_vert_type == VERTISUNDEF) cycle
-!print *, 'i = ', i, ' current vert_type = ', current_vert_type
select case (which_vert)
case (VERTISPRESSURE)
call state_vertical_to_pressure( ens_handle, ens_size, locs(i), loc_indx(i), loc_qtys(i) )
@@ -2911,7 +2908,6 @@
write(string1,*)'unable to convert vertical state "', which_vert, '"'
call error_handler(E_MSG,routine,string1,source,revision,revdate)
end select
-!print *, 'vloc now = ', query_location(locs(i), 'VLOC')
enddo
istatus = 0
@@ -2936,13 +2932,11 @@
if (is_surface_field(myqty)) then
-!print *, 'surface field ', iloc, jloc, vloc
level_one = 1
call get_values_from_single_level(ens_handle, ens_size, QTY_SURFACE_PRESSURE, &
iloc, jloc, level_one, surface_pressure, status1)
if (status1 /= 0) then
-!print *, 'err - status1 = ', status1
return
endif
call set_vertical(location, surface_pressure(1), VERTISPRESSURE)
@@ -2993,6 +2987,12 @@
level_one = 1
+! by definition
+if (query_location(location) == VERTISSURFACE) then
+ call set_vertical(location, -log(1.0_r8), VERTISSCALEHEIGHT)
+ return
+endif
+
! build a height column and a scaleheight column and find the levels?
call get_model_variable_indices(location_indx, iloc, jloc, vloc)
@@ -3151,6 +3151,7 @@
do i=1,num
current_vert_type = nint(query_location(locs(i)))
if ( current_vert_type == which_vert ) cycle
+ if ( current_vert_type == VERTISUNDEF) cycle
select case (which_vert)
case (VERTISPRESSURE)
@@ -3157,8 +3158,6 @@
call obs_vertical_to_pressure( ens_handle, locs(i), my_status(i))
case (VERTISHEIGHT)
call obs_vertical_to_height( ens_handle, locs(i), my_status(i))
-!call write_location(0, locs(i), charstring=string1)
-!print *, 'converting vert height to: '//trim(string1)
case (VERTISLEVEL)
call obs_vertical_to_level( ens_handle, locs(i), my_status(i))
case (VERTISSCALEHEIGHT)
@@ -3186,11 +3185,6 @@
ens_size = 1
-if (query_location(location) == VERTISUNDEF) then
- my_status = 0
- return
-endif
-
qty = QTY_PRESSURE
if (query_location(location) == VERTISSURFACE) then
qty = QTY_SURFACE_PRESSURE
More information about the Dart-dev
mailing list