Belle II Software development
PDF1Dim.h
1/**************************************************************************
2 * basf2 (Belle II Analysis Software Framework) *
3 * Author: The Belle II Collaboration *
4 * *
5 * See git log for contributors and copyright holders. *
6 * This file is licensed under LGPL-3.0, see LICENSE.md. *
7 **************************************************************************/
8
9#pragma once
10
11#include <top/reconstruction_cpp/PDFConstructor.h>
12#include <vector>
13#include <TH1F.h>
14
15namespace Belle2 {
20 namespace TOP {
21
25 class PDF1Dim {
26
27 public:
28
35 PDF1Dim(const PDFConstructor& pdfConstructor, double binSize, double timeWindow);
36
41 double getBinSize() const {return m_binSize;}
42
47 int getModuleID() const {return m_moduleID;}
48
55 TH1F getHistogram(std::string name, std::string title) const;
56
61 const std::vector<double>& getPhotonTimes() const {return m_times;}
62
67 int getNumOfPhotons() const {return m_times.size();}
68
73 double getExpectedSignal() const {return m_expectedSignal;}
74
80
85 double getExpectedBG() const {return m_expectedBG;}
86
91 double getTminPDF() const {return m_tminPDF;}
92
97 double getTmaxPDF() const {return m_tmaxPDF;}
98
103 double getTminFot() const {return m_tminFot;}
104
109 double getTmaxFot() const {return m_tmaxFot;}
110
115 double getMinT0() const {return m_minT0;}
116
121 double getMaxT0() const {return m_maxT0;}
122
127 int getNumBinsT0() const {return m_numBinsT0;}
128
134 double getLogL(double timeShift) const;
135
136
137 private:
138
139 int m_moduleID = 0;
140 int m_numBins = 0;
141 double m_minTime = 0;
142 double m_maxTime = 0;
144 std::vector<double> m_times;
145 double m_tminPDF = 0;
146 double m_tmaxPDF = 0;
147 double m_tminFot = 0;
148 double m_tmaxFot = 0;
149 double m_minT0 = 0;
150 double m_maxT0 = 0;
151 int m_numBinsT0 = 0;
152 double m_expectedBG = 0;
153 double m_expectedSignal = 0;
154 double m_expectedDelta = 0;
156 double m_bkg = 0;
157 double m_binSize = 0;
158 std::vector<double> m_logF;
159 double m_logBkg = 0;
161 };
162
163 } // namespace TOP
165} // namespace Belle2
Binned one dimensional PDF (a projection of PDF to time axis)
Definition: PDF1Dim.h:25
int m_numBinsT0
number of bins for T0 finder w/ same bin size as PDF
Definition: PDF1Dim.h:151
double getExpectedSignal() const
Returns expected number of signal photons.
Definition: PDF1Dim.h:73
double getLogL(double timeShift) const
Returns log likelihood.
Definition: PDF1Dim.cc:92
double getTmaxFot() const
Returns maximal time of selected photons.
Definition: PDF1Dim.h:109
double m_binSize
bin size
Definition: PDF1Dim.h:157
double m_expectedSignal
expected number of signal photons
Definition: PDF1Dim.h:153
double m_tmaxPDF
maximal time of signal PDF
Definition: PDF1Dim.h:146
double m_tmaxFot
maximal time of photons
Definition: PDF1Dim.h:148
TH1F getHistogram(std::string name, std::string title) const
Returns binned one dimensional PDF (projection to time axis)
Definition: PDF1Dim.cc:108
double m_logBkg
log(m_bkg)
Definition: PDF1Dim.h:159
double getTminPDF() const
Returns minimal time of signal PDF.
Definition: PDF1Dim.h:91
double m_expectedDelta
expected number of delta-ray photons
Definition: PDF1Dim.h:154
double m_maxTime
upper edge of the last bin
Definition: PDF1Dim.h:142
double m_minTime
lower edge of the first bin
Definition: PDF1Dim.h:141
const std::vector< double > & getPhotonTimes() const
Returns photon times of selected photons in a given slot.
Definition: PDF1Dim.h:61
double getExpectedDeltaPhotons() const
Returns expected number of delta-ray photons.
Definition: PDF1Dim.h:79
double getMaxT0() const
Returns upper edge of the T0 search region.
Definition: PDF1Dim.h:121
double getMinT0() const
Returns lower edge of the T0 search region.
Definition: PDF1Dim.h:115
double m_maxT0
maximal T0
Definition: PDF1Dim.h:150
int m_numBins
number of bins for signal PDF
Definition: PDF1Dim.h:140
double getExpectedBG() const
Returns expected number of background photons.
Definition: PDF1Dim.h:85
double getTmaxPDF() const
Returns maximal time of signal PDF.
Definition: PDF1Dim.h:97
int m_moduleID
slot number
Definition: PDF1Dim.h:139
double getBinSize() const
Returns actual bin size used.
Definition: PDF1Dim.h:41
double m_expectedBG
expected number of background photons
Definition: PDF1Dim.h:152
std::vector< double > m_times
photon times, from a given slot
Definition: PDF1Dim.h:144
int getModuleID() const
Returns slot number.
Definition: PDF1Dim.h:47
int getNumBinsT0() const
Returns number of bins the T0 search region.
Definition: PDF1Dim.h:127
double m_tminPDF
minimal time of signal PDF
Definition: PDF1Dim.h:145
double m_bkg
background [photons/bin]
Definition: PDF1Dim.h:156
double m_minT0
minimal T0
Definition: PDF1Dim.h:149
std::vector< double > m_logF
log(PDF) values
Definition: PDF1Dim.h:158
double getTminFot() const
Returns minimal time of selected photons.
Definition: PDF1Dim.h:103
double m_tminFot
minimal time of photons
Definition: PDF1Dim.h:147
int getNumOfPhotons() const
Returns number of photons.
Definition: PDF1Dim.h:67
PDF construction and log likelihood determination for a given track and particle hypothesis.
Abstract base class for different kinds of events.