/[MITgcm]/MITgcm_contrib/high_res_cube/utils/do_the_averages
ViewVC logotype

Contents of /MITgcm_contrib/high_res_cube/utils/do_the_averages

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1 - (show annotations) (download)
Sat Feb 19 15:44:42 2005 UTC (20 years, 5 months ago) by edhill
Branch: MAIN
CVS Tags: HEAD
 o initial check-in

1 #!/bin/bash
2
3 ntot=5
4
5 v1="DRHODR ETANSQ RHOANOSQ RHOAnoma SALT SALTSQ SFLUX"
6 v2="SRELAX TAUX TAUY TFLUX THETA THETASQ TICE TRELAX"
7 v3="URHOMASS USLTMASS UTHMASS UVEL UVELMASS UVELSQ"
8 v4="UV_VEL_Z VRHOMASS VSLTMASS VTHMASS VVEL VVELMASS"
9 v5="VVELSQ WRHOMASS WSLTMASS WTHMASS WU_VEL WVELMASS"
10 v6="WVELSQ WV_VEL"
11 vars="$v1 $v2 $v3 $v4 $v5 $v6"
12
13 test -e ./.dta && rm -rf ./.dta
14 mkdir ./.dta
15
16 for i in $vars ; do
17 spin=t
18 while test $spin = t ; do
19 # echo " spinning on... $i"
20 n=`find ./.dta -type f 2>/dev/null | wc -l`
21 if test $n -lt $ntot ; then
22 (
23 /u/menemenl/bin/average_fields `echo $i".00*.data"` $i.ave > ./.dta/$i 2>&1
24 rm -f ./.dta/$i
25 ) &
26 spin=f
27 fi
28 sleep 1
29 done
30 done
31
32 spin=t
33 while test $spin = t ; do
34 n=`find ./.dta -type f 2>/dev/null | wc -l`
35 if test $n -lt 1 ; then
36 echo "Done!"
37 spin=f
38 fi
39 done

  ViewVC Help
Powered by ViewVC 1.1.22