~christopher-hunt08/maus/maus_integrated_kalman

« back to all changes in this revision

Viewing changes to src/common_cpp/Recon/Global/ComPIDVarF.hh

merging in changes in merge branch

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* This file is part of MAUS: http://  micewww.pp.rl.ac.uk:8080/projects/maus
 
2
 * 
 
3
 * MAUS is free software: you can redistribute it and/or modify
 
4
 * it under the terms of the GNU General Public License as published by
 
5
 * the Free Software Foundation, either version 3 of the License, or
 
6
 * (at your option) any later version.
 
7
 * 
 
8
 * MAUS is distributed in the hope that it will be useful,
 
9
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 
10
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
11
 * GNU General Public License for more details.
 
12
 * 
 
13
 * You should have received a copy of the GNU General Public License
 
14
 * along with MAUS.  If not, see <http://  www.gnu.org/licenses/>.
 
15
 */
 
16
 
 
17
 /** @class ComPIDVarF
 
18
 *  @author Celeste Pidcott, University of Warwick
 
19
 *  Comissioning PID variable class, for EMR density, derived
 
20
 *  from PIDBase
 
21
 */
 
22
 
 
23
#ifndef COMPIDVARF_HH
 
24
#define COMPIDVARF_HH
 
25
 
 
26
#include <string>
 
27
#include <utility>
 
28
 
 
29
#include "TLorentzVector.h"
 
30
#include "TH1.h"
 
31
#include "TFile.h"
 
32
 
 
33
#include "DataStructure/Global/Track.hh"
 
34
#include "DataStructure/Global/TrackPoint.hh"
 
35
#include "DataStructure/Global/BasePoint.hh"
 
36
 
 
37
#include "Recon/Global/PIDBase1D.hh"
 
38
 
 
39
namespace MAUS {
 
40
namespace recon {
 
41
namespace global {
 
42
 
 
43
  class ComPIDVarF : public PIDBase1D {
 
44
  public:
 
45
    /// Constructor to create a PDF
 
46
    explicit ComPIDVarF(std::string hypothesis, std::string unique_identifier);
 
47
    /// Constructor to use a PDF to perform PID analysis
 
48
    ComPIDVarF(TFile* file, std::string hypothesis, int minF, int maxF);
 
49
    /// Destructor
 
50
    ~ComPIDVarF();
 
51
 
 
52
  private:
 
53
 
 
54
    /** @brief Calculate value of PID variable
 
55
     *
 
56
     *  @param track The track for which the variable is calculated
 
57
     *
 
58
     *  @return Returns value of PID variable
 
59
     */
 
60
    std::pair<double, double> Calc_Var(MAUS::DataStructure::Global::Track* track);
 
61
 
 
62
    /// Plane density in EMR
 
63
    double EMR_density;
 
64
 
 
65
    /// Name of PID variable
 
66
    static const std::string VARIABLE;
 
67
    /// Number of bins in PDF
 
68
    static const int numBins = 100;
 
69
    /// Minimum value of range of PDF
 
70
    static const int minBinComF = 0;
 
71
    /// Maximum value of range of PDF
 
72
    static const int maxBinComF = 1;
 
73
    /// Minimum value of cut for PID
 
74
    static const int minComF = 0;
 
75
    /// Maximum value of cut for PID
 
76
    static const int maxComF = 1;
 
77
  };
 
78
}
 
79
}
 
80
}
 
81
 
 
82
#endif