CbmRoot
BoltzmannDistribution.h
Go to the documentation of this file.
1 #ifndef BOLTZMANNDISTRIBUTION_H
2 #define BOLTZMANNDISTRIBUTION_H
3 
4 //#include <cmath>
5 #include "TMath.h"
6 #include "TSpline.h"
7 #include "common/Acceptance.h"
8 #include <iostream>
9 //#include <omp.h>
10 
11 
13  std::vector<double> xlag32, wlag32;
14  std::vector<double> xleg32, wleg32;
15  double fMass;
16  int fPDGID;
18  double fYmin, fYmax, fYcm, fWidth;
19  // double fNorm;
21  fAcceptance; //fAcceptanceSTS, fAcceptanceSTSTOF;
23  TSpline3 fTamt;
24  TSpline3 fNormT, fNormT4pi;
25 
26 public:
27  BoltzmannDistribution(double mass = 0.938,
28  int PDGID = 2212,
29  bool fUseAcc = false,
30  double ymin = -3.,
31  double ymax = 3.,
32  double ycm = 2.,
33  double width = 1.);
34 
35  virtual ~BoltzmannDistribution(void) {}
36 
37  double GetT(double amt) { return fTamt.Eval(amt); }
38 
39  double GetA(double multiplicity, double T) {
40  if (!fUseAcceptance)
41  return multiplicity;
42  else
43  return multiplicity * fNormT4pi.Eval(T) / fNormT.Eval(T);
44  }
45 
46  double GetAerror(double multiplicity, double T, double multerr, double Terr) {
47  if (!fUseAcceptance)
48  return multerr;
49  else
50  return TMath::Sqrt(
51  fNormT4pi.Eval(T) / fNormT.Eval(T) * fNormT4pi.Eval(T) / fNormT.Eval(T)
52  * multerr * multerr
53  + multiplicity * multiplicity / fNormT.Eval(T) / fNormT.Eval(T)
54  * fNormT4pi.Derivative(T) * fNormT4pi.Derivative(T) * Terr * Terr
55  + multiplicity * multiplicity / fNormT.Eval(T) / fNormT.Eval(T)
56  / fNormT.Eval(T) / fNormT.Eval(T) * fNormT4pi.Eval(T)
57  * fNormT4pi.Eval(T) * fNormT.Derivative(T) * fNormT.Derivative(T)
58  * Terr * Terr);
59  }
60 
61  double fmt(double amt, double T);
62 
63  double dTdmt(double amt) { return fTamt.Derivative(amt); }
64 
65  double mtAv(double T);
66  double mtAv2(double T);
67  double Normalization(double T);
68  double Normalization4pi(double T);
69 
70  double dndy(double y, double A, double T);
71 };
72 
73 #endif
BoltzmannDistribution::mtAv
double mtAv(double T)
Definition: BoltzmannDistribution.cxx:80
BoltzmannDistribution::GetT
double GetT(double amt)
Definition: BoltzmannDistribution.h:37
BoltzmannDistribution::fMass
double fMass
Definition: BoltzmannDistribution.h:15
BoltzmannDistribution::fmt
double fmt(double amt, double T)
Definition: BoltzmannDistribution.cxx:110
BoltzmannDistribution::Normalization4pi
double Normalization4pi(double T)
Definition: BoltzmannDistribution.cxx:150
BoltzmannDistribution::fUseAcceptance
bool fUseAcceptance
Definition: BoltzmannDistribution.h:17
BoltzmannDistribution::fYmax
double fYmax
Definition: BoltzmannDistribution.h:18
BoltzmannDistribution::xlag32
std::vector< double > xlag32
Definition: BoltzmannDistribution.h:13
BoltzmannDistribution::xleg32
std::vector< double > xleg32
Definition: BoltzmannDistribution.h:14
BoltzmannDistribution::fYmin
double fYmin
Definition: BoltzmannDistribution.h:18
BoltzmannDistribution::Normalization
double Normalization(double T)
Definition: BoltzmannDistribution.cxx:127
Acceptance::AcceptanceFunction
Definition: Acceptance.h:10
BoltzmannDistribution::GetA
double GetA(double multiplicity, double T)
Definition: BoltzmannDistribution.h:39
BoltzmannDistribution::fWidth
double fWidth
Definition: BoltzmannDistribution.h:18
BoltzmannDistribution::~BoltzmannDistribution
virtual ~BoltzmannDistribution(void)
Definition: BoltzmannDistribution.h:35
Acceptance::ReconstructionEfficiencyFunction
Definition: Acceptance.h:19
BoltzmannDistribution::dTdmt
double dTdmt(double amt)
Definition: BoltzmannDistribution.h:63
BoltzmannDistribution::BoltzmannDistribution
BoltzmannDistribution(double mass=0.938, int PDGID=2212, bool fUseAcc=false, double ymin=-3., double ymax=3., double ycm=2., double width=1.)
Definition: BoltzmannDistribution.cxx:10
BoltzmannDistribution::dndy
double dndy(double y, double A, double T)
Definition: BoltzmannDistribution.cxx:170
BoltzmannDistribution::mtAv2
double mtAv2(double T)
Definition: BoltzmannDistribution.cxx:101
BoltzmannDistribution::wleg32
std::vector< double > wleg32
Definition: BoltzmannDistribution.h:14
BoltzmannDistribution::fYcm
double fYcm
Definition: BoltzmannDistribution.h:18
BoltzmannDistribution::fNormT
TSpline3 fNormT
Definition: BoltzmannDistribution.h:24
BoltzmannDistribution::fAcceptance
Acceptance::AcceptanceFunction fAcceptance
Definition: BoltzmannDistribution.h:21
BoltzmannDistribution::fTamt
TSpline3 fTamt
Definition: BoltzmannDistribution.h:23
BoltzmannDistribution::wlag32
std::vector< double > wlag32
Definition: BoltzmannDistribution.h:13
Acceptance.h
BoltzmannDistribution::GetAerror
double GetAerror(double multiplicity, double T, double multerr, double Terr)
Definition: BoltzmannDistribution.h:46
BoltzmannDistribution
Definition: BoltzmannDistribution.h:12
y
Double_t y
Definition: CbmMvdSensorDigiToHitTask.cxx:68
BoltzmannDistribution::fReconstructionEfficiency
Acceptance::ReconstructionEfficiencyFunction fReconstructionEfficiency
Definition: BoltzmannDistribution.h:22
BoltzmannDistribution::fNormT4pi
TSpline3 fNormT4pi
Definition: BoltzmannDistribution.h:24
BoltzmannDistribution::fPDGID
int fPDGID
Definition: BoltzmannDistribution.h:16