@@ -81,7 +81,7 @@ multGlauberNBDFitter::multGlauberNBDFitter(const char* name, const char* title)
8181 // Named constructor
8282 fNpart = new double [fMaxNpNcPairs ];
8383 fNcoll = new double [fMaxNpNcPairs ];
84- fContent = new long [fMaxNpNcPairs ];
84+ fContent = new int64_t [fMaxNpNcPairs ];
8585
8686 // NBD
8787 fNBD ->SetNpx (45000 );
@@ -180,7 +180,7 @@ double multGlauberNBDFitter::GlauberProbDistrib(const double* x, const double* p
180180 // ______________________________________________________
181181 // Actually evaluate function
182182 int lStartBin = fhNanc->FindBin (0.0 ) + 1 ;
183- for (long iNanc = lStartBin; iNanc < fhNanc->GetNbinsX () + 1 ; ++iNanc) {
183+ for (int64_t iNanc = lStartBin; iNanc < fhNanc->GetNbinsX () + 1 ; ++iNanc) {
184184 double lNancestors = fhNanc->GetBinCenter (iNanc);
185185 double lNancestorCount = fhNanc->GetBinContent (iNanc);
186186
@@ -209,7 +209,7 @@ double multGlauberNBDFitter::TrentoProbDistrib(const double* x, const double* pa
209209 double lProbability = 0.0 ;
210210 // ______________________________________________________
211211 // Actually ealuate function
212- for (long iNSrc = 1 ; iNSrc < fhNSources->GetNbinsX () + 1 ; ++iNSrc) {
212+ for (int64_t iNSrc = 1 ; iNSrc < fhNSources->GetNbinsX () + 1 ; ++iNSrc) {
213213 double lNsources = fhNSources->GetBinCenter (iNSrc);
214214 double lThisMu = lNsources * par[Index (FitPar::mu)];
215215 double lThisk = lNsources * par[Index (FitPar::k)];
@@ -294,7 +294,7 @@ void multGlauberNBDFitter::SetFitOptions(const TString& lOpt)
294294}
295295
296296// ________________________________________________________________
297- void multGlauberNBDFitter::SetFitNpx (const long lNpx)
297+ void multGlauberNBDFitter::SetFitNpx (const int64_t lNpx)
298298{
299299 fFitNpx = lNpx;
300300}
@@ -400,7 +400,7 @@ bool multGlauberNBDFitter::InitializeNpNc()
400400 if (fhNpNc->GetBinContent (fhNpNc->FindBin (xbin, ybin)) != 0 ) {
401401 fNpart [fNNpNcPairs ] = xbin;
402402 fNcoll [fNNpNcPairs ] = ybin;
403- fContent [fNNpNcPairs ] = static_cast <long >(fhNpNc->GetBinContent (fhNpNc->FindBin (xbin, ybin)));
403+ fContent [fNNpNcPairs ] = static_cast <int64_t >(fhNpNc->GetBinContent (fhNpNc->FindBin (xbin, ybin)));
404404 fNNpNcPairs ++;
405405 }
406406 }
@@ -431,12 +431,12 @@ double multGlauberNBDFitter::ContinuousNBD(const double n, const double mu, cons
431431 if (n + k > NumStabilityThreshold) {
432432 // log method for handling large numbers
433433 F = std::lgamma (n + k) - std::lgamma (n + 1 .) - std::lgamma (k);
434- f = n * std::log (mu / k) - (n + k) * std::log ( 1.0 + mu / k);
434+ f = n * std::log (mu / k) - (n + k) * std::log1p ( mu / k);
435435 F = F + f;
436436 F = std::exp (F);
437437 } else {
438438 F = std::tgamma (n + k) / (std::tgamma (n + 1 .) * std::tgamma (k));
439- f = n * std::log (mu / k) - (n + k) * std::log ( 1.0 + mu / k);
439+ f = n * std::log (mu / k) - (n + k) * std::log1p ( mu / k);
440440 f = std::exp (f);
441441 F *= f;
442442 }
@@ -529,7 +529,7 @@ void multGlauberNBDFitter::CalculateAvNpNc(TProfile* lNPartProf, TProfile* lNCol
529529 }
530530 }
531531
532- for (long lMultValue = 1 ; lMultValue < lHiRange; lMultValue++) {
532+ for (int64_t lMultValue = 1 ; lMultValue < lHiRange; lMultValue++) {
533533 double lNancestorCount = fContent [ibin];
534534 double lThisMu = lNancestors * fMu ;
535535 double lThisk = lNancestors * fk;
0 commit comments