4 #include "cavata_prescription.h"
17 fObsTransform =
nullptr;
72 KVError::Warning(
this,
"MakeScale",
"called with bmax>1.0 - calling MakeAbsoluteScale for absolute impact parameters");
85 void cavata_prescription::make_scale(
Int_t npoints)
88 Int_t nbins = cumul->GetNbinsX();
90 Int_t last_bin = nbins;
92 fIPScale =
new TGraph(npoints);
93 fXSecScale =
new TGraph(npoints);
94 Double_t delta_bin = 1.*(last_bin - first_bin) / (npoints - 1.);
96 for (
int i = 0; i < npoints; i++) {
97 bin = first_bin + i * delta_bin;
98 Double_t et12 = cumul->GetBinCenter(bin);
102 fXSecScale->
SetPoint(i, et12, sigma);
174 return fIPScale->
Eval(*
x);
198 return fXSecScale->
Eval(*
x);
236 if (!fObsTransform) {
237 KVError::Error(
this,
"GetIPDistribution",
"Call MakeScale first to calculate correspondance observable<->i.p.");
240 return HM.
ScaleHisto(obs, fObsTransform, 0, nbinx, -1, 0., Bmax, -1, -1, norm);
274 if (!fObsTransform) {
275 KVError::Error(
this,
"GetIPEvolution",
"Call MakeScale first to calculate correspondance observable<->i.p.");
320 if (!fObsTransformXSec) {
321 KVError::Error(
this,
"GetXSecDistribution",
"Call MakeScale first to calculate correspondance observable<->i.p.");
324 return HM.
ScaleHisto(obs, fObsTransformXSec, 0, nbinx, -1, 0., Smax, -1, -1, norm);
359 if (!fObsTransformXSec) {
360 KVError::Error(
this,
"GetXSecEvolution",
"Call MakeScale first to calculate correspondance observable<->i.p.");
430 Double_t xsecSlice = totXsec / double(nslices);
431 std::vector<Double_t> slices(nslices - 1);
432 for (
int i = 0; i < nslices - 1; ++i) {
455 return (2. / 3.) * (
pow(bmax, 3) -
pow(bmin, 3)) / (
pow(bmax, 2) -
pow(bmin, 2));
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t b
TGraph * ScaleGraph(const TGraph *hh, TF1 *fx=nullptr, TF1 *fy=nullptr) const
TGraphErrors * GetMomentEvolution(TH2 *hh, TString momentx, TString momenty, TString axis="Y", Double_t stat_min=0)
TH1 * ScaleHisto(TH1 *hh, TF1 *fx, TF1 *fy=NULL, Int_t nx=-1, Int_t ny=-1, Double_t xmin=-1., Double_t xmax=-1., Double_t ymin=-1., Double_t ymax=-1., Option_t *norm="")
TH1 * CumulatedHisto(TH1 *hh, TString direction="C", Int_t bmin=-1, Int_t bmax=-1, Option_t *norm="surf")
Impact parameter estimation neglecting using sharp cut-off approximation.
Double_t BTransform(Double_t *, Double_t *)
double GetMeanBForSCA(double bmin, double bmax) const
TGraph * GetIPEvolution(TH2 *obscor, TString moment, TString axis="Y")
std::vector< Double_t > SliceXSec(Int_t nslices, Double_t totXsec)
TGraph * GetXSecEvolution(TH2 *obscor, TString moment, TString axis="Y")
Double_t XTransform(Double_t *, Double_t *)
void MakeScale(Int_t npoints=100, Double_t bmax=1.0)
Double_t GetObservableXSec(Double_t sigma)
static Double_t GetXSecFromIP(Double_t bmax)
double GetSigmaBForSCA(double bmin, double bmax) const
virtual ~cavata_prescription()
Destructor.
TH1 * GetIPDistribution(TH1 *obs, Int_t nbinx=100, Option_t *norm="")
void MakeAbsoluteScale(Int_t npoints=100, Double_t bmax=1.0)
TH1 * GetXSecDistribution(TH1 *obs, Int_t nbinx=100, Option_t *norm="")
virtual void SetPoint(Int_t i, Double_t x, Double_t y)
virtual Double_t Eval(Double_t x, TSpline *spline=nullptr, Option_t *option="") const
const char * Data() const
Expr< UnaryOp< Sqrt< T >, SMatrix< T, D, D2, R >, T >, T, D, D2, R > sqrt(const SMatrix< T, D, D2, R > &rhs)
RVec< PromoteTypes< T0, T1 > > pow(const T0 &x, const RVec< T1 > &v)
void Error(UserClass p, const char *location, const char *va_(fmt),...)
void Warning(UserClass p, const char *location, const char *va_(fmt),...)
Double_t Min(Double_t a, Double_t b)