#!/bin/bash scriptDir="$(dirname "$0")" source $scriptDir/config.txt dirM="${dirBI}../SparseMatrix" export dirBI #matrix="tub100.rb" #matrix="sherman2.rb" matrix="HV15R.rb" procs=(2 20 40 80 160) msm=(0 1) mss=(1 2) mrm=(0 1) is_syncs=(1 0) qty=1 if [ $# -ge 1 ] then qty=$1 fi echo "$dirM/$matrix" for proc in "${procs[@]}" do echo "------------------------------------------run np=$proc next=0" for proc_c in "${procs[@]}" do if [ $proc -ne $proc_c ] then max_numP=$proc if [ "$proc_c" -gt "$proc" ]; then max_numP=$proc_c fi node_qty=$(($max_numP / 20)) if [ $node_qty -eq 0 ] then node_qty=1 fi sbatch -p P1 -N $node_qty $dirBI/Exec/generalRun.sh $proc $dirM/$matrix $proc_c $qty fi done done echo "End"