#!/bin/bash # Schlick, 2003-08-25 # ----------------------------------------------------------------- # this script is called from stm.c # after finnishing data aquisition # # functions: # 1. create doppler spectra on a grid # 2. calculate current data from spectra # 3. calculate wave data from spectra # ----------------------------------------------------------------- # # Copyright (c) 2003, 2005 by # University of Hamburg, Institute of Oceanography. # All rights reserved. # # This software is furnished under a license and may be used and copied # only in accordance of the terms of such license and with the inclusion # of the above copyright notice. This software or any other copies # hereof may not be provided or otherwise made be available to any other # person. No title to and ownership of the software is hereby # transferred. # # The information in this software is subject to change without notice # and should not be construed as a commitment by the University of # Hamburg, Institute of Oceanography. # # - insert data set for simulations ------------------------------- # ----------------------------------------------------------------- # #case `hostname` in # ifmwera1) SIMDATA="/home/wera/data/20022900000_koo.SORT" ;; # ifmwera2) SIMDATA="/home/wera/data/20022900010_kna.SORT" ;; # *) echo "error: wrong hostname" ;; #esac #cp $SIMDATA $1 # Process raw data (sort) to gridded spectra # ----------------------------------------------------------------- NAME_IN=$1 NAME_OUT=`ls -1 "$NAME_IN" | /home/wera/etc/ext_spec` echo "INPUT to wera16_grid: "$NAME_IN echo "OUTPUT from wera16_grid: "$NAME_OUT /home/wera/Fortran/wera16_grid $NAME_IN $NAME_OUT if [ $? = 0 ]; then echo "SUCCESS: wera16_grid, OUTPUT="$NAME_OUT echo "SUCCESS: wera16_grid, OUTPUT="$NAME_OUT |logger -p user.info -tPROCESS_SORT # Process gridded spectra (spec) to radial currents (spawned proc) # ---------------------------------------------------------------- NAME_IN=$NAME_OUT NAME_OUT_RAD=`ls -1 "$NAME_IN" | /home/wera/etc/ext_rad` . /home/wera/etc/proc_rad.sh $NAME_IN $NAME_OUT_RAD & # Process gridded spectra (spec) to waves (spawned proc) # ----------------------------------------------------------------- NAME_IN=$NAME_OUT NAME_OUT_WAV=`ls -1 "$NAME_IN" | /home/wera/etc/ext_wrad` . /home/wera/etc/proc_wav.sh $NAME_IN $NAME_OUT_WAV & else echo " " echo "process_SORT.sh: Error processing wera16_grid" echo "ERROR: wera16_grid" |logger -p user.info -tPROCESS_SORT echo " " fi # Checking disk space and switch link to second disk # if 98% filled # ----------------------------------------------------------------- #. /home/wera/etc/switch_link.sh exit