#!/bin/csh
#
#  C-shell script to execute GAMESS elongation test, one job after the next.
#  Each output is put in its own separate log file in the gamess root.
#  Invoke this by typing 'runall-elg'.
#
#   1. elg01 to elg07: Benzyl U-PM3 elongation starts from 4 units
#   2. elg08 to elg22: Polyglycine  RHF/STO-3G starts from 7 units
#                (cut-off starts from 15-unit polyglycine)
#   3. elg23 to elg26: Polyglycine ROHF/STO-3G starts from 7 units
#   4. elg27 to elg30: Polyglycine  UHF/STO-3G starts from 7 units
#
#  The jobs are run in batch queues if DQS is found on the system.
#
#  A script to check the results is ~/gamess/tools/elg/checkelg/checkelg,
#  Edit this file to set the base path to GAMESS, and execute it to be
#  sure all the jobs TERMINATED NORMALLY, and got correct numbers too.
#
chdir /home/gu/gamess
set VERNO=01
#
foreach NUM ( 01 02 03 04 05 06 07 08 09 10 11 12 13 14 15 \
              16 17 18 19 20 21 22 23 24 25 26 27 28 29 30)

  if (-e /usr/local/bin/dqs_execd) then
     gms -v $VERNO -q ti -l elg$NUM.log elg$NUM
     sleep 5
  else
     /home/gu/gamess/rungms elg$NUM $VERNO 1  >&  elg$NUM.log
  endif
end

