#! /bin/sh

# input muted shot gathers, these need not be gained.
input=mute_seismic.su
output=deghost_mute_seismic.su

## deghosting parameters
# 0 < r < 1.0 is an estimate of the reflectivity of the sea surface 
# r > .6 is probably unstable

### deghosting parameters ###
#

r=.3
# source and receiver depths
hsource=6
hreceiver=10

### radon transform parameters ###
# f1, f2, and dp are chosen to keep SURADON from cutting high frequencies
#
f1=90
f2=125
pmin=-400
pmax=2000
dp=10

# interoff = minimum offset
# offreff = maximum offset
interoff=-262
offref=-3237

# additional parameter
verbose=1

###
# suppress source and receiver ghost with SUDEGHOST in the tau-p domain
suradon < $input choose=0 igopt=3 interoff=$interoff offref=$offref \
     pmin=$pmin pmax=$pmax dp=$dp f1=$f1 f2=$f2 cdpkey=ep anderson=0  |
sudeghost h=$hreceiver r=$r deghost=1 |
sudeghost h=$hsource r=$r deghost=1 |
suradon choose=4 igopt=3 interoff=-262 offref=-3237 \
     pmin=$pmin pmax=$pmax dp=$dp f1=$f1 f2=$f2 cdpkey=ep anderson=0  > $output

# remove temporary files generated by SURADON
rm radontmp*

exit 0
