#
# /user/csl/arnon/Sturgis/algebra: runs SAC-2
#
# from /1f/datools/ecad/dracu: runs the ECAD drc
#
# algebra host datafile
#
set verbose
setenv BASE /user/csl/arnon/SAC2
setenv QEBASE /user/csl/arnon/QEALGS
setenv CHARCARD $BASE/translator/charcard
setenv VAXIMA /user/csl/arnon/MACSYMA/mac
setenv FILE0 $CHARCARD
setenv FILE2 $BASE/interpreter/nullinput
setenv FILE3 $QEBASE/tmp3++
setenv FILE4 $QEBASE/tmp4++
setenv FILE7 $QEBASE/tmp7++
setenv FILE8 $QEBASE/tmp8++
setenv FILE9 $QEBASE/tmp9++

cat /tmp/algebra.lock
if ($status == 0) then
pupftp $1 <<--EOF
store /tmp/algebra.lock WaitMsg.SUM
quit

--EOF
while (-e /tmp/algebra.lock)
sleep 120
end
endif
pwd > /tmp/algebra.lock
date >> /tmp/algebra.lock
limit data 16m
/bin/rm binom.data
pupftp $1 <<--EOF
retrieve $2.inData binom.data
quit

--EOF
date > sturgis.outData
/user/csl/arnon/Sturgis/sturgis.out < binom.data >> sturgis.outData
date >> sturgis.outData
/bin/rm /tmp/algebra.lock
pupftp $1 <<--EOF
store sturgis.outData $2.SUM
quit

--EOF