#!/bin/bash
#PBS -N nebpar
#PBS -j oe
#PBS -l nodes=4:ppn=2,walltime=160:00:00
#PBS -V

### ---------------------------------------
### BEGINNING OF EXECUTION
### ---------------------------------------

echo The master node of this job is `hostname`
echo The working directory is `echo $PBS_O_WORKDIR`
echo This job runs on the following nodes:
echo `cat $PBS_NODEFILE`

ncpu=`cat $PBS_NODEFILE | wc -w`
echo "Number of processors = $ncpu "
### end of information preamble

cd $PBS_O_WORKDIR

echo $PWD

lamboot $PBS_NODEFILE # starts lam on the specified nodes

#echo $PWD

cmd="mpiexec -np $ncpu bin/sw_mpich scripts/CSD-book/chap7/sect7.3/si-kink-nebmep-parallel.tcl"
time $cmd 

wipe $PBS_NODEFILE

