#!/bin/bash #-- fix params of simulation -------------------------------------------------- #numer of events used for resolution study SIMEVENTS=100000 #SIMEVENTS=100 #Declare array with elements for knoss stat. study #ARRAY=(100000 50000 20000 10000 5000 2000 1000 500 200 100) #ARRAY=(100) #ARRAY=(100000) #ARRAY=(100000 50000 20000 10000 5000 2000 1000 500 200 100) ARRAY=(100 200 500 1000 2000 5000 10000 20000 50000 100000) # get number of elements in the array ELEMENTS=${#ARRAY[@]} #Declare array with elements for misalignment scale #ARRAYD=(0 10 20 30 40 50 70 100 150 200 250 300 350 400 450 500) #mum #ARRAYD=(0 10 50 100 150 200 250 300 350 400 450 500) #mum #ARRAYD=(0 10 20 30 40 50 70 100 150 200 250 300 350 400 450 500) #mum ARRAYD=(0 25 50 100 150 200 250 300 350 400) #mum #ARRAYD=(25) #mum ELEMENTSD=${#ARRAYD[@]} #ARRAYA=(0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15) # 1e-3 rad ARRAYA=(0 3 6 9) # 1e-3 rad #ARRAYA=(3 6 9) # 1e-3 rad #ARRAYA=(0) # 1e-3 rad # get number of elements in the array ELEMENTSA=${#ARRAYA[@]} #--------------------------------------------------------------------------------------- # reads number of Events, name of run and verbose Level path="test" #verbose=0 mom=0 #echo Enter storage-folder: #read folder #echo "Storage Path: $folder!" # echo Enter verbosity Level: # read verbose # echo "Verbosity Level is: $verbose!" echo Enter momentum from "1.5, 4.06, 8.9, 11.91, 15 [GeV/c]": read mom echo "Beam momentum is: $mom!" #mom=1.5 momStr=`echo $mom | sed -e '{ s/\./_/g; }'` cd /home/karavdin/pandaRoot12/macro/lmd source config.sh for (( i=0;i<$ELEMENTS;i++)); do for (( ia=0;ia<$ELEMENTSA;ia++)); do for (( j=0;j<$ELEMENTSD;j++)); do T="$(date)" echo ${T} ": Now we'll add info about test with "${ARRAY[${i}]} "events for misalignment ~ "${ARRAYD[${j}]} "mum and" ${ARRAYA[${ia}]} "*10e-3 rad" # #---------------------------------------------------------------------- pathname="/home/karavdin/datastorage/AlignmentStudy/mom_"${momStr}"/"misalign_${ARRAYD[${j}]}mum_${ARRAYA[${ia}]}_10e-3radDOF111111_${ARRAY[${i}]}_events # resfile="/home/karavdin/datastorage/AlignmentStudy/mom_"${momStr}"/RotStudy_"${ARRAYA[${ia}]}"mrad" # pathname="/home/karavdin/datastorage/AlignmentSamplesStudy/momentum_"${momStr}"/"misalign_${ARRAYD[${j}]}mum_${ARRAYA[${ia}]}_10e-3radDOF111111_${ARRAY[${i}]}_events # resfile="/home/karavdin/datastorage/AlignmentSamplesStudy/momentum_"${momStr}"/RotStudy_"${ARRAYA[${ia}]}"mrad" # resfile="/home/karavdin/datastorage/AlignmentStudy/mom_"${momStr}"/StatStudy_"${ARRAY[${i}]}"tracks_"${ARRAYA[${ia}]}"mrad" # time root -l -b -q GenAlignEffect.C\(\"${pathname}/\",${ARRAYD[${j}]},${j},${ARRAYA[${ia}]},${ELEMENTSD},\"${resfile}\"\) # depend vs. DeltaTrans resfile="/home/karavdin/datastorage/AlignmentStudy/mom_"${momStr}"/StatStudy_"${ARRAYD[${j}]}"mum_"${ARRAYA[${ia}]}"mrad" time root -l -b -q GenAlignEffect.C\(\"${pathname}/\",${ARRAY[${i}]},${i},${ARRAYA[${ia}]},${ELEMENTS},\"${resfile}\"\) # depend vs. Number of trks # # #---------------------------------------------------------------------- done done done echo "results saved in " ${pathname} exit