Jpp 20.0.0-195-g190c9e876
the software that should make you happy
Loading...
Searching...
No Matches
JORCACalibrateMuon.sh
Go to the documentation of this file.
1#!/usr/bin/env zsh
2#
3# \author mdejong
4#
5script=${0##*/}
6
7# ------------------------------------------------------------------------------------------
8#
9# Script to run the JCalibrateMuon for ORCA.
10#
11# ------------------------------------------------------------------------------------------
12
13if [ -z $JPP_DIR ]; then
14 echo "Variable JPP_DIR undefined."
15 exit
16fi
17source $JPP_DIR/setenv.sh $JPP_DIR
18
19set_variable DEBUG 2
20set_variable PDF $JPP_DATA/J%p.dat.gz
21set_variable HISTOGRAM 260 -30.0 +100.0
22set_variable: OPTION CALIBRATION_OPTION module # string
23
24if do_usage $*; then
25 usage "$script <detector file> <input file> <output file> [(calibration file)+]"
26fi
27
28if (( $# < 3 )); then
29 fatal "Wrong number of arguments."
30fi
31
32set_variable DETECTOR $argv[1]
33set_variable INPUT_FILE $argv[2]
34set_variable OUTPUT_FILE $argv[3]
35set_array CALIBRATION $argv[4,-1]
36
37PARAMETERS=(
38 TTS_ns 2
39 E_GeV 10.0
40 TMin_ns -50.0
41 TMax_ns +450.0
42 ZMin_m -3.0
43 ZMax_m +9.0
44 R_Hz 7.0e3
45 roadWidth_m 50.0
46 numberOfPrefits 1)
47
48timer_start
49
50eval JCalibrateMuon \
51 -a $DETECTOR \
52 -+${^CALIBRATION} \
53 -f $INPUT_FILE \
54 -o $OUTPUT_FILE \
55 -F $PDF \
56 -@ `make_equation PARAMETERS` \
57 -c \"$HISTOGRAM\" \
58 -R $OPTION \
59 -d $DEBUG --!
60
61CHECK_EXIT_CODE
62
63timer_stop
64timer_print