Jpp
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
JPhysics/JShowerNPE.sh
Go to the documentation of this file.
1 #!/bin/zsh
2 #
3 # \author lquinn
4 #
5 version=1.0
6 script=${0##*/}
7 
8 # ------------------------------------------------------------------------------------------
9 #
10 # Utility script to plot tabulated PDFs.
11 #
12 # ------------------------------------------------------------------------------------------
13 
14 
15 if [ -z $JPP_DIR ]; then
16  echo "Variable JPP_DIR undefined."
17  exit
18 fi
19 
20 
21 source $JPP_DIR/setenv.sh $JPP_DIR
22 
23 
24 set_variable NORTH "0.00 0.00"
25 set_variable EAST "1.57 0.00"
26 set_variable SOUTH "3.14 0.00"
27 set_variable WEST "1.57 3.14"
28 
31 set_variable YMAX 2e+2
32 set_variable YMIN 1e-9
33 
34 set_variable PDF $JPP_DATA/J%p.dat
35 
36 
37 if ( do_usage $* ); then
38  usage "$script [energy]"
39 fi
40 
41 case $# in
42  1) set_variable E $1;;
43 esac
44 
45 
46 for dir in NORTH EAST SOUTH WEST; do
47 
48  echo "Generating $dir."
49 
50  eval D=\$$dir
51 
52  if (( 1 )); then
53 
54  $JPP_DIR/examples/JPhysics/JShowerNPE \
55  -P ${PDF} \
56  -D "${D}" \
57  -E "${E}" \
58  -N 10 \
59  -o $WORKDIR/F\[${dir}\].root --!
60 
61  fi
62 
63  if (( 1 )); then
64 
65  JPlot2D \
66  -f $WORKDIR/F\[${dir}\].root:h0 \
67  -z "$YMIN $YMAX" -Z \
68  -T "${dir} E = ${E} GeV" \
69  -O "colz" \
70  -\> "D [m]" \
71  -\< "cos #theta_{0}" \
72  -o $WORKDIR/NPE-${dir}-${E}GeV.gif -B
73  fi
74 done
do echo Generating $dir eval D
Definition: JDrawLED.sh:50
void set_variable(const std::string &name, const std::string &value)
Set environment variable.
exit
Definition: JPizza.sh:36
do set_array DAQHEADER JPrintDAQHeader f
Definition: JTuneHV.sh:79
then for dir in NORTH EAST SOUTH WEST
Definition: JDrawLED.sh:46
fatal Invalid number of arguments esac let YMIN
Definition: testToT.sh:39
then echo
then usage $script< detector file >< inputfile >< outputfile > fi case set_variable PDF
do set_variable OUTPUT_DIRECTORY $WORKDIR T
do $DIR JTransitTime o
Definition: JTransitTime.sh:44
then awk F
* usage
then display $WORKDIR
Definition: plot-Domino.sh:127
then fatal Wrong number of arguments fi set_variable DETECTOR $argv[1] set_variable INPUT_FILE $argv[2] eval JPrintDetector a $DETECTOR O IDENTIFIER eval JPrintDetector a $DETECTOR O SUMMARY source JAcoustics sh $DETECTOR_ID typeset A TRIPODS get_tripods $WORKDIR tripod txt TRIPODS for EMITTER in
Definition: JCanberra.sh:36
then usage $script[input file[working directory[option]]] nWhere option can be N
Definition: JMuonPostfit.sh:37
version
Definition: JCalibratePMT.sh:7
then usage $script< detector file >< inputfile > fi case set_variable WORKDIR
Definition: JLegolas.sh:28
then usage $script[input file[working directory[option]]] nWhere option can be E
Definition: JMuonPostfit.sh:37
then $DIR JPlotNPE PDG P
Definition: JPlotNPE-PDG.sh:60
esac done
Definition: JAddHDE.sh:21