Skip to content
Snippets Groups Projects
  • Whitney Armstrong's avatar
    c4d09cd1
    modified: do_sim3 · c4d09cd1
    Whitney Armstrong authored
    	modified:   include/B1DetectorConstruction.hh
    	modified:   include/B1DetectorMessenger.hh
    	modified:   src/B1DetectorConstruction.cc
    	modified:   src/B1DetectorMessenger.cc
    c4d09cd1
    History
    modified: do_sim3
    Whitney Armstrong authored
    	modified:   include/B1DetectorConstruction.hh
    	modified:   include/B1DetectorMessenger.hh
    	modified:   src/B1DetectorConstruction.cc
    	modified:   src/B1DetectorMessenger.cc
do_sim3 2.97 KiB
#!/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