#!/bin/sh 

# This shell script was designed to convert the COCORP Recording Parameters
# into table (HTML 3.0) for the WWW 5/5/95.  SCG

#First take out all the New Lines in the file

read line
echo $line > tf
read line
echo $line >> tf
echo "<BODY>" >> tf
echo "<TABLE BORDER=1>" >> tf
read line
read line
read dum area dum
read dum line dum
echo "<TR><TH COLSPAN=10><H1><BR>COCORP "$area $line"</H1></TH></TR>" >> tf
read dum dum start dum
echo "<tr><td><B>Start Date</B></td><td> "$start"</td><td>" >> tf
read dum dum end dum
echo "<B>End Date</B></td><td> "$end"</td><td>" >> tf
read dum dum dum sd dum
echo "<B>Date of Startup </B></td><td> "$sd"</td><td>" >> tf
read dum cont dum
echo "<TR><td><B>Contractor </B></td><td>$cont</td><td>" >> tf
read dum dum num dum
echo "<B>Crew Number </B></td><td>$num</td>" >> tf
read dum dum sname1 sname2 dum
read dum dum coverage dum
read dum dum name1 name2
echo "<TR><TH COLSPAN=6><tr><td>" >> tf
echo "<b>COCORP Honcho  </b></td><td>$name1 $name2 </td><td>" >> tf
echo "<B>Startup Supervisor</B></td><td> $sname1 $sname2 </td><td>" >> tf
echo "<b>Surface Coverage </b> </td><td>$coverage  </td>" >> tf
echo "<TR><TH COLSPAN=10><H3><BR>PARAMETERS</H3></TH></TR>" >> tf
read dum dum rs dum
echo "<tr><td><b>Recording System  </b></td><td> $rs</td><td>" >> tf
read dum dum fold dum
read dum dum dum channels dum
echo "<b>No. of Channels </b></td><td>" $channels "</td><td>" >> tf
read dum dum sr dum
read dum dum dum ggs dum
echo "<b>Geophone Group Spacing </b></td><td>$ggs </td><td>" >> tf
read dum dum aaf dum
read dum dum ss dum
echo "<b>Source Spacing </b></td><td>$ss </td><td>" >> tf
read dum dum dum sfreq dum
read dum dum dum efreq dum
read dum dum dum offset dum
echo "<b>Source/Nearest Receiver Offset </b></td><td>$offset </td>" >> tf
read dum dum duration dum
read dum pp dum
echo "<tr><td><b>Push/Pull </b></td><td>$pp </td><td>" >> tf
read dum dum dum time dum
read dum dum dum os dum
echo "<b>Offend of Split </b></td><td>$os </td><td>" >> tf
read dum dum dum crt dum
read dum dum nr dum
echo "<b>Noise Reject </b></td><td>$nr </td><td>" >> tf
read dum dum dum ud dum
read dum dum vpower dum
echo "<b>Vibrator Power </b></td><td>$vpower </td><td>" >> tf
echo "<b>Stacking Fold  </b></td><td>$fold  </td>" >> tf
echo "<tr><td><b>Sampling Interval </b></td><td>$sr </td><td>" >> tf
echo "<b>Antialias Filter </b></td><td>$aaf </td><td>" >> tf
echo "<b>Sweep Freq. Start </b></td><td>$sfreq </td><td>" >> tf
echo "<b>Sweep Freq. End </b></td><td>$efreq </td><td>" >> tf 
echo "<b>Sweep Duration </b></td><td>$duration </td>" >> tf
echo "<tr><td><b>Total Record Time </b></td><td>$time </td><td>" >> tf
echo "<b>Correlated Record Length </b></td><td>$crt </td><td>" >> tf
echo "<b>Upsweep or Downsweep </b></td><td>$ud </td>" >> tf
read dum dum dum dum dum ns dum
echo "<td><b>Number of Sweeps per VP</b></td><td> $ns </td><td>" >> tf
read dum dum geotype dum
read dum dum dum dum geohz dum
read dum dum dum dum dum geostat dum
read dum dum dum dum geospace dum
read dum dum weightsch dum
read dum dum dum dum geoarrlen dum
read dum dum vibtype dum
read dum dum notch dum
echo "<b>Notch Filter </b></td><td> $notch </td>" >> tf
echo "<TR><TH COLSPAN=10><H3><BR>Geophone Array</H3></TH></TR>" >> tf
echo "<tr><td><b>Geophone Type </b></td><td>$geotype</td>" >> tf
echo "<th colspan=2><b>Natural Frequency of Geophone </b></td><td>$geohz </td>" >> tf
echo "<th colspan=3><b>Number of Geophones per Station </b></td><td>$geostat </td><td>" >> tf
echo "<tr><th colspan=2><b>Spacing Between Geophone Elements </b></td><td>$geospace</td><td>" >> tf
echo "<b>Weighting Scheme </b></td><td>$weightsch </td>" >> tf
echo "<b><th colspan=3>Total Geophone Array Length </b></td><td>$geoarrlen </td>" >> tf
echo "<tr><th colspan=10><H3><BR>Source Array</H3></TH></TR>" >> tf
echo "<tr><td><b>Vibrator Type </b></td><td>$vibtype </td>" >> tf
read dum dum dum dum novib dum
echo "<tr><th colspan=8><b>Primary Array</td><tr><td><b>No. of Vibrators</td><td></b>$novib </td><td>" >> tf
read dum dum dum dum vspace dum
echo "<th colspan=2><b>Spacing Between Vibrators</b></td><td>  $vspace m</td><td>" >> tf
read dum dum dum dum dum smbs dum
echo "<th colspan=2><b>Source Moveup Between Sweeps  </b></td><td>$smbs m</td>" >> tf
read dum dum dum dum dum dum dum dum firvib dum
echo "<tr><td><th colspan=4><b>1st Vibrator starts (relative to the flag)</b></td><td> $firvib m</td><td>" >> tf
read dum dum dum dum dum arraylength dum
echo "<th colspan=2><b>Array Source Array Length</td><td>  $arraylength m</td>" >> tf
read dum dum dum dum novib dum
echo "<tr><th colspan=8><b>Backup Array</td><tr><td><b>No. of Vibrators</td><td></b> $novib </td><td>" >> tf
read dum dum dum dum vibspace dum
echo "<th colspan=2><b>Spacing Between Vibrators</b></td><td>  $vibspace m</td><td>" >> tf
read dum dum dum dum dum smbs dum
echo "<th colspan=2><b>Source Moveup Between Sweeps  </b></td><td>$smbs m</td>" >> tf
read dum dum dum dum dum dum dum dum vsrf dum
echo "<tr><td><th colspan=4><b>1st Vibrator starts (relative to the flag)</b></td><td> $vsrf m</td><td>" >> tf
read dum dum dum dum dum arraylength dum
echo "<th colspan=2><b>Array Source Array Length</td><td>  $arraylength  m</td>" >> tf
echo "</TABLE>" >> tf
