[Dart-dev] [5058] DART/trunk/observations/MADIS/shell_scripts/windowing.csh: Fix the tests that select which input files might possibly

nancy at ucar.edu nancy at ucar.edu
Tue Jul 5 17:10:26 MDT 2011


Revision: 5058
Author:   nancy
Date:     2011-07-05 17:10:26 -0600 (Tue, 05 Jul 2011)
Log Message:
-----------
Fix the tests that select which input files might possibly
have observations in the current window.  It was not adding
the files directly before 0Z for the files which themselves
start at 0Z and don't include obs that are before the analysis
time.

Modified Paths:
--------------
    DART/trunk/observations/MADIS/shell_scripts/windowing.csh

-------------- next part --------------
Modified: DART/trunk/observations/MADIS/shell_scripts/windowing.csh
===================================================================
--- DART/trunk/observations/MADIS/shell_scripts/windowing.csh	2011-06-30 23:23:53 UTC (rev 5057)
+++ DART/trunk/observations/MADIS/shell_scripts/windowing.csh	2011-07-05 23:10:26 UTC (rev 5058)
@@ -219,7 +219,7 @@
     # NAMES:  the pattern here must match how you choose how you chose
     # to name the obs_seq files converted from each of the original MADIS files.
     # there are a variety of strings available to help you construct a
-    # filename: $this_type is metar, # marine, etc.  ${fbef},${aft} is 
+    # filename: $this_type is metar, marine, etc.  ${fbef},${faft} is 
     # a time string YYYYMMDDHH.  if you choose to name the obs_seq files
     # something other than the full time string, you can parse them up
     # the same as $curtime above.  if you do change the name scheme,
@@ -234,7 +234,8 @@
       echo $src_base_dir/obs_seq_${this_type}_${faftdy}  >>! obstemp
     endif
 
-    while ( $gwbef[1] >= $gobef[1] && $gwbef[2] > $gobef[2]) 
+    while ( ( $gwbef[1] >  $gobef[1] )  || \
+            ( $gwbef[1] == $gobef[1] && $gwbef[2] > $gobef[2] ) )
       set  wbef=(`echo  $wbef  -1h    | ./advance_time` )
       set gwbef=(`echo  $wbef   0  -g | ./advance_time` )
 
@@ -254,7 +255,8 @@
       #echo 'back start:' $wbef \( $gwbef \) to $waft \( $gwaft \)
     end
 
-    while ( $gwaft[1] <= $goaft[1] && $gwaft[2] < $goaft[2]) 
+    while ( ( $gwaft[1] <  $goaft[1] ) || \
+            ( $gwaft[1] == $goaft[1] && $gwaft[2] < $goaft[2]) )
       set  waft=(`echo  $waft  +1h    | ./advance_time` )
       set gwaft=(`echo  $waft   0  -g | ./advance_time` )
 
@@ -286,7 +288,7 @@
         -e "s/ASEC/$goaft[2]/" input.nml.template >! input.nml
 
     # run obs_seq_tool
-    ./obs_sequence_tool
+    ./obs_sequence_tool 
  
     # do something with the output, and clear the input
     # if you want to change the output filename, do it here 


More information about the Dart-dev mailing list