29template<
class Iterator>
34 std::multimap<TString, int >
parMap;
35 for (Iterator it = begin; it != end; ++it) {
36 parMap.insert( std::make_pair( *it, std::distance(begin,it) ) );
42 std::pair <std::multimap<TString,int>::iterator, std::multimap<TString,int>::iterator>
ret;
45 for (std::multimap<TString,int>::iterator it=
ret.first; it!=
ret.second; ++it) {
77 Fatal(
"InitializeDataMembers",
"Invalid input function -- abort");
90 for (
int i=0; i<
npar; i++)
97 for (
int i=0; i <
npar; i++)
133 fFunctions = std::vector<std::unique_ptr<TF1>>(0);
134 fCoeffs = std::vector < Double_t >(0) ;
153 std::vector < Double_t >
coeffs(2);
167 std::vector < Double_t >
coeffs(3);
197 for (
int i=0; i<
nofobj; i++)
256 nsum.TF1NormSum::Copy(*
this);
265 rhs.TF1NormSum::Copy(*
this);
290 std::vector<double> params(
GetNpar() );
328 for (
int i = 0; i <
npar; ++i) {
353 const double params[] = {
p0,
p1,
p2,
p3,
p4,
p5,
p6,
p7,
p8,
p9,
p10};
377 Warning(
"SetRange",
"Invalid range: %f >= %f",
a,
b);
424 ((
TF1NormSum &)obj).fFunctions[
n] = std::unique_ptr<TF1>(
f);
ROOT::Detail::TRangeCast< T, true > TRangeDynCast
TRangeDynCast is an adapter class that allows the typed iteration through a TCollection.
void FixDuplicateNames(Iterator begin, Iterator end)
Function to find and rename duplicate parameters with the same name.
winID h TVirtualViewer3D TVirtualGLPainter p
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 Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char Pixmap_t Pixmap_t PictureAttributes_t attr const char char ret_data h unsigned char height h offset
void * New(ENewType defConstructor=kClassNew, Bool_t quiet=kFALSE) const
Return a pointer to a newly allocated object of this class.
Class adding two functions: c1*f1+c2*f2.
void Copy(TObject &obj) const override
Copy this to obj.
Double_t fScale
Fixed Scale parameter to normalize function (e.g. bin width)
const char * GetParName(Int_t ipar) const
void GetRange(Double_t &a, Double_t &b) const
TF1NormSum & operator=(const TF1NormSum &rhs)
Operator =.
TClass * IsA() const override
Double_t fXmax
Maximal bound of range of NormSum.
std::vector< TString > fParNames
Parameter names.
void SetRange(Double_t a, Double_t b) override
Double_t fXmin
Minimal bound of range of NormSum.
std::vector< double > GetParameters() const
Return array of parameters.
double operator()(const Double_t *x, const Double_t *p) override
Overload the parenthesis to add the functions.
void Update() override
Update the component functions of the normalized sum.
std::vector< std::unique_ptr< TF1 > > fFunctions
Vector of size fNOfFunctions containing TF1 functions.
void InitializeDataMembers(const std::vector< TF1 * > &functions, const std::vector< Double_t > &coeffs, Double_t scale)
void SetParameters(const Double_t *params) override
Initialize array of all parameters.
std::vector< Double_t > fCoeffs
Vector of size afNOfFunctions containing coefficients in front of each function.
Int_t GetNpar() const
Return the number of (non constant) parameters including the coefficients: for 2 functions: c1,...
unsigned int fNOfFunctions
Number of functions to add.
std::vector< Int_t > fCstIndexes
Vector with size of fNOfFunctions containing the index of the constant parameter/ function (the remov...
static void InitStandardFunctions()
Create the basic function objects.
Collectable string class.
Mother of all ROOT objects.
virtual void Warning(const char *method, const char *msgfmt,...) const
Issue warning message.
virtual void Error(const char *method, const char *msgfmt,...) const
Issue error message.
virtual void Fatal(const char *method, const char *msgfmt,...) const
Issue fatal error message.
TObjArray * Tokenize(const TString &delim) const
This function is used to isolate sequential tokens in a TString.
static TString Format(const char *fmt,...)
Static method which formats a string using a printf style format descriptor and return a TString.
static uint64_t sum(uint64_t i)