#!/bin/csh -f # See usage comments in 1.0 below # # 1.0 check input parameters to the script # if ($1 == "" || $2 == "" ) then cat <<+++end usage: runtoq.sc intoq_file run_label +++end exit (1) endif # 2.0 make rundir and execute stoq and splt in rundir set rundir = "toq.$2" set xdir = "~millerb/toqPublic" mkdir $rundir cp dskeqdata $rundir cp $1 $rundir/intoqtemp cd $rundir mkdir core #run this case for a number of different mesh sizes #!!!!!!!important!!!!!!! #for this to work the npsi and nthet declaratitions in intoq file # passed to runtoq must have the following form: # # npsi=xx nthet=xx # # also need to have # ieqdsk = 0 # mv dskeqo dskeq.sav # this makes sure old dskeqo doesn't interfere foreach mesh ( 17 33 65 ) @ mesh2 = $mesh + 2 sed "s/npsi=xx/npsi=$mesh2/" intoqtemp > intoqtempx sed "s/nthet=xx/nthet=$mesh/" intoqtempx > intoq if ( -e dskeqo ) then mv dskeqo dskeqi sed "s/ieqdsk=0/ieqdsk=2/" intoq >intoqtempx mv intoqtempx intoq endif rm intoqtempx $xdir/toq.x end # $xdir/splt.x # 3.0 run bootstrap analysis #echo "make toq_jbs.in" #cat >intemp <<'+++end' # $input # runid='xxx' # zeff=2.0 # nlamda=101 # gamma=0.5 # $end #'+++end' # sed "s/xxx/$2/" intemp > toq_jbs.in # rm intemp # echo "run toq_jbs.x" # $xdir/toq_jbs.x # $xdir/jbsplt.x # cp dskgato /$savdir/dskgat$3_$bet00 # cp plot.cgm plot.$3_$bet00 # cp jbs.cgm jbs.$3_$bet00 # cp outtoq out.$3_$bet00 # end cd ..