This repository has been archived by the owner on Oct 7, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
do_sim3
executable file
·95 lines (79 loc) · 2.97 KB
/
do_sim3
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
#!/bin/bash
num=6
nevent=10000000
mkdir -p results6
cd results6
# gold
mat=Au
mkdir -p $mat
cd $mat
for length in 15 10 5 20; do
for anOD in 15 25 30 60; do
filetemp=${mat}_${length}.mac
echo "/B1/det/setCollimatorLength ${length} cm" > $filetemp
echo "/B1/det/setInnerCollimatorOD ${anOD} mm" >> $filetemp
echo "/B1/det/setCollimatorMaterial G4_${mat}" >> $filetemp
echo "/process/setVerbose 0 all" >> $filetemp
echo "/vis/verbose 0" >> $filetemp
echo "/control/verbose 0" >> $filetemp
echo "/run/verbose 0" >> $filetemp
echo "/event/verbose 0" >> $filetemp
echo "/tracking/verbose 0" >> $filetemp
echo "/run/initialize" >> $filetemp
echo "/run/beamOn ${nevent}" >> $filetemp
echo "/B1/det/printConfigInfo" >> $filetemp
../../bin/ebl1 -b --run=$num $filetemp &> ${mat}_${length}.log
mv EBL_sim_output_${num}.root bubble_${mat}_${length}cm_${anOD}mm_${num}.root
root -b -q "../../make_plots.cxx(\"${mat}\",${length},${num},${anOD})"
done
done
cd ..
# silver
mat=Ag
mkdir -p $mat
cd $mat
for length in 15 10 5 20; do
for anOD in 15 25 30 60; do
filetemp=${mat}_${length}.mac
echo "/B1/det/setCollimatorLength ${length} cm" > $filetemp
echo "/B1/det/setInnerCollimatorOD ${anOD} mm" >> $filetemp
echo "/B1/det/setCollimatorMaterial G4_${mat}" >> $filetemp
echo "/process/setVerbose 0 all" >> $filetemp
echo "/vis/verbose 0" >> $filetemp
echo "/control/verbose 0" >> $filetemp
echo "/run/verbose 0" >> $filetemp
echo "/event/verbose 0" >> $filetemp
echo "/tracking/verbose 0" >> $filetemp
echo "/run/initialize" >> $filetemp
echo "/run/beamOn ${nevent}" >> $filetemp
echo "/B1/det/printConfigInfo" >> $filetemp
../../bin/ebl1 -b --run=$num $filetemp &> ${mat}_${length}.log
mv EBL_sim_output_${num}.root bubble_${mat}_${length}cm_${anOD}mm_${num}.root
root -b -q "../../make_plots.cxx(\"${mat}\",${length},${num},${anOD})"
done
done
cd ..
# copper
mat=Cu
mkdir -p $mat
cd $mat
for length in 15 10 5 20; do
for anOD in 15 25 30 60; do
filetemp=${mat}_${length}.mac
echo "/B1/det/setCollimatorLength ${length} cm" > $filetemp
echo "/B1/det/setInnerCollimatorOD ${anOD} mm" >> $filetemp
echo "/B1/det/setCollimatorMaterial G4_${mat}" >> $filetemp
echo "/process/setVerbose 0 all" >> $filetemp
echo "/vis/verbose 0" >> $filetemp
echo "/control/verbose 0" >> $filetemp
echo "/run/verbose 0" >> $filetemp
echo "/event/verbose 0" >> $filetemp
echo "/tracking/verbose 0" >> $filetemp
echo "/run/initialize" >> $filetemp
echo "/run/beamOn ${nevent}" >> $filetemp
echo "/B1/det/printConfigInfo" >> $filetemp
../../bin/ebl1 -b --run=$num $filetemp &> ${mat}_${length}.log
mv EBL_sim_output_${num}.root bubble_${mat}_${length}cm_${anOD}mm_${num}.root
root -b -q "../../make_plots.cxx(\"${mat}\",${length},${num},${anOD})"
done
done