#!/bin/bash
# PBS submission script for parallel Case 2

# M=8 processors
#PBS -l nodes=4:ppn=2:compute
#PBS -l walltime=00:15:00
#PBS -N DAKOTA_Case3a

# for convenience, set DAKOTA and PATH environment variables
# put . on path to pickup the simulator script
export DAKOTA=/path/to/dakota
export PATH=.:$DAKOTA/bin:$DAKOTA/test:$PATH

# change into this example directory
cd $DAKOTA/tutorial/parallelism/Case3a

# start the mpiexec server to service requests for node subsets
mpiexec -server &

# Case 3a: Run DAKOTA in serial and launch three parallel analysis job at a 
# time, each on 2 processors
$DAKOTA/bin/dakota -i dakota_pstudy.in
