1 #ifndef __JCALIBRATE__JFITTOT__
2 #define __JCALIBRATE__JFITTOT__
10 #include "TFitResult.h"
26 namespace JCALIBRATE {}
27 namespace JPP {
using namespace JCALIBRATE; }
29 namespace JCALIBRATE {
192 range.getLowerLimit(),
193 range.getUpperLimit(),
230 const Int_t NgainSpread = this->
getModelParameter(&JFitToT::JFitToTParameters::gainSpread);
231 const Int_t Nnormalization = this->
getModelParameter(&JFitToT::JFitToTParameters::normalization);
235 SetParName(Nnormalization,
MAKE_CSTRING(
"normalization"));
238 h1.FindBin(this->GetXmax()));
249 const TFitResultPtr
result = h1.Fit(
this, option.c_str());
267 Double_t
getValue(
const Double_t* x,
const Double_t* par)
269 const double tot_ns = x[0];
277 const double Whist = par[2];
static Int_t getNumberOfModelParameters()
Get number of model parameters.
JFitToT(const JPMTParameters ¶meters, const JRange< double > &range)
Constructor.
JFitParameter_t getModelParameter(Double_t JFitToTParameters::*p) const
Get model parameter.
const Double_t getModelParameter(const int i) const
Get model parameter.
double gainSpread
gain spread [unit]
JFitToTParameters(const Double_t *data)
Copy constructor.
static const double FITTOT_GAIN_MAX
Default maximal gain.
Double_t gainSpread
PMT gain spread.
static const double FITTOT_GAIN_MIN
Default minimal gain.
Double_t * getModelParameters()
Get model parameters.
*fatal Wrong number of arguments esac JCookie sh typeset Z DETECTOR typeset Z SOURCE_RUN typeset Z TARGET_RUN set_variable PARAMETERS_FILE $WORKDIR parameters
#define MAKE_CSTRING(A)
Make C-string.
then for HISTOGRAM in h0 h1
Double_t getValue(const Double_t *x, const Double_t *par)
Get rate as a function of the fit parameters.
Parametrisation of time-over-threshold distribution.
Fit parameters for two-fold coincidence rate due to K40.
const JPMTAnalogueSignalProcessor & getCPU() const
Access method for the analogue signal processor.
JPMTAnalogueSignalProcessor cpu
static const std::string FITTOT_SUFFIX
const Double_t * getModelParameters() const
Get model parameters.
Auxiliary data structure for a parameter index and its value.
JFitToTParameters(const JPMTParameters ¶meters)
Constructor.
static const char FITTOT_SEPARATOR
static const double FITTOT_GAINSPREAD_MAX
Default maximal gain spread.
bool setParLimits(TF1 &f1, const Int_t index, Double_t xmin, Double_t xmax)
Set fit parameter limits.
z range($ZMAX-$ZMIN)< $MINIMAL_DZ." fi fi mv $WORKDIR/fit.root $MODULE_ROOT typeset -Z 4 STRING typeset -Z 2 FLOOR JPlot1D -f $
PMT analogue signal processor.
then $JPP_DIR examples JDetector JToT o $OUTPUT_FILE n N $NPE P gain
Auxiliary class to define a range between two values.
void setModelParameters(const Double_t *data)
Set model parameters.
void setModelParameter(const int i, const Double_t value)
Set model parameter.
double getIntegralOfTimeOverThresholdProbability(const double Tmin, const double Tmax, const int NPE) const
Get cumulative probability of time-over-threshold distribution.
double getTimeOverThresholdProbability(const double tot_ns, const int NPE) const
Get probability of having a pulse with specific time-over-threshold.
PMT analogue signal processor.
static const double FITTOT_GAINSPREAD_MIN
Default minimal gain spread.
Data structure for PMT parameters.
TFitResultPtr operator()(TH1 &h1, const std::string &option)
Fit histogram.
static const std::string FITTOT_FNAME