#!/bin/bash
#MSUB -r paral-bandpw_03   # Job name
#MSUB -T 1000            # Elapsed time of the job
#MSUB -A tgcc0002        # Project number
#MSUB -n 108             # Number of processors
#MSUB -o paral-bandpw_03.o # Standard output
#MSUB -e paral-bandpw_03.e # Error output

set -x

ABINIT=/ccc/work/cont005/pa0397/bottinf/6.10.1-public/curie/src/98_main/abinit
TMPDIR=$SCRATCHDIR/paral-bandpw_03
mkdir $TMPDIR
cd $TMPDIR

rm -rf *log *.out *.in *.files
cp $BRIDGE_MSUB_PWD/tparal_bandpw_03.in     $TMPDIR/
cp $BRIDGE_MSUB_PWD/tparal_bandpw_03.files  $TMPDIR/
cp $BRIDGE_MSUB_PWD/79au.pspnc      $TMPDIR/
echo "npband 27 npfft 4 bandpp 1" >>$TMPDIR/tparal_bandpw_03.in

ccc_mprun $ABINIT < tparal_bandpw_03.files > tparal_bandpw_03.log

cp $TMPDIR/tparal_bandpw_03.out $BRIDGE_MSUB_PWD/tparal_bandpw_03.bandpp1.out
cp $TMPDIR/tparal_bandpw_03.log $BRIDGE_MSUB_PWD/tparal_bandpw_03.bandpp1.log

rm -rf *log *.out *.in *.files
cp $BRIDGE_MSUB_PWD/tparal_bandpw_03.in     $TMPDIR/
cp $BRIDGE_MSUB_PWD/tparal_bandpw_03.files  $TMPDIR/
cp $BRIDGE_MSUB_PWD/79au.pspnc      $TMPDIR/
echo "npband 27 npfft 4 bandpp 2" >>$TMPDIR/tparal_bandpw_03.in

ccc_mprun $ABINIT < tparal_bandpw_03.files > tparal_bandpw_03.log

cp $TMPDIR/tparal_bandpw_03.out $BRIDGE_MSUB_PWD/tparal_bandpw_03.bandpp2.out
cp $TMPDIR/tparal_bandpw_03.log $BRIDGE_MSUB_PWD/tparal_bandpw_03.bandpp2.log

rm -rf *log *.out *.in *.files
cp $BRIDGE_MSUB_PWD/tparal_bandpw_03.in     $TMPDIR/
cp $BRIDGE_MSUB_PWD/tparal_bandpw_03.files  $TMPDIR/
cp $BRIDGE_MSUB_PWD/79au.pspnc      $TMPDIR/
echo "npband 54 npfft 2 bandpp 1" >>$TMPDIR/tparal_bandpw_03.in

ccc_mprun $ABINIT < tparal_bandpw_03.files > tparal_bandpw_03.log

cp $TMPDIR/tparal_bandpw_03.out $BRIDGE_MSUB_PWD/tparal_bandpw_03.054-02.out
cp $TMPDIR/tparal_bandpw_03.log $BRIDGE_MSUB_PWD/tparal_bandpw_03.054-02.log

