#! /bin/sh
# The idea is to low pass filter the data to get rid of the ground
# roll.  Since the raw data is dominated by the ground roll, apply
# suspecfx to the raw data to estimate the ground roll frequency content.
demo=filt1

perc=90   # accept value in Scales book
tpow=3.2  # accept value in oz25.H

supsimage <data.su  \
	title="Original Data"\
	label1="Time (sec)" label2="Offset (km)" >${demo}.1.eps

sugain <data.su tpow=$tpow |
supsimage perc=$perc \
	title="Data with tpow=$tpow perc=$perc"\
	label1="Time (sec)" label2="Offset (km)" >${demo}.2.eps

suspecfx <data.su  |
supsimage  \
	title="FX spectrum"\
	label1="Freq (Hz)" label2="Offset (km)" >${demo}.3.eps

f=0,15,40,50
amps=0.,0.,1.,1.
sufilter <data.su f=$f amps=$amps |
sugain tpow=$tpow |
supsimage  perc=$perc \
	title="f=$f amps=$amps tpow=$tpow perc=$perc"\
	label1="Time (sec)" label2="Offset (km)" >${demo}.4.eps
 
echo 
echo "Output PostScript files:"

echo -n "     "
for i in ${demo}.*.eps
do
	 echo -n "$i "
done
echo
echo "You may view these with your PostScript Previewer"

exit 0
