Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
RooLinearCombination.h
Go to the documentation of this file.
1// Author: Rahul Balasubramanian, Nikhef 08 Apr 2021
2/*****************************************************************************
3 * Project: RooFit *
4 * Package: RooFitCore *
5 * File: $Id: RooAbsReal.h,v 1.75 2007/07/13 21:50:24 wouter Exp $
6 * Authors: *
7 * WV, Wouter Verkerke, UC Santa Barbara, verkerke@slac.stanford.edu *
8 * DK, David Kirkby, UC Irvine, dkirkby@uci.edu *
9 * *
10 * Copyright (c) 2000-2005, Regents of the University of California *
11 * and Stanford University. All rights reserved. *
12 * *
13 * Redistribution and use in source and binary forms, *
14 * with or without modification, are permitted according to the terms *
15 * listed in LICENSE (http://roofit.sourceforge.net/license.txt) *
16 *****************************************************************************/
17#ifndef ROO_LINEAR_COMB
18#define ROO_LINEAR_COMB
19
20#include "RooFit/Floats.h"
21
22#include <list>
23#include <ostream>
24#include <vector>
25
26#include "RooAbsReal.h"
27#include "RooArgSet.h"
28#include "RooListProxy.h"
29
32 std::vector<RooFit::SuperFloat> _coefficients;
33 mutable RooArgSet *_nset; //!
34
35public:
37 RooLinearCombination(const char *name);
38 RooLinearCombination(const RooLinearCombination &other, const char *name);
39 virtual void printArgs(std::ostream &os) const override;
41 virtual TObject *clone(const char *newname) const override;
43 void setCoefficient(size_t idx, RooFit::SuperFloat c);
45 virtual Double_t evaluate() const override;
46 virtual std::list<Double_t> *binBoundaries(RooAbsRealLValue &obs,
47 Double_t xlo,
48 Double_t xhi) const override;
49 virtual std::list<Double_t> *plotSamplingHint(RooAbsRealLValue &obs,
50 Double_t xlo,
51 Double_t xhi) const override;
52
54};
55
56#endif
#define c(i)
Definition RSha256.hxx:101
double Double_t
Definition RtypesCore.h:59
#define ClassDefOverride(name, id)
Definition Rtypes.h:329
char name[80]
Definition TGX11.cxx:110
RooAbsRealLValue is the common abstract base class for objects that represent a real value that may a...
RooAbsReal is the common abstract base class for objects that represent a real value and implements f...
Definition RooAbsReal.h:64
RooArgSet is a container object that can hold multiple RooAbsArg objects.
Definition RooArgSet.h:35
RooLinearCombination is a class that helps perform linear combination of floating point numbers and p...
virtual std::list< Double_t > * binBoundaries(RooAbsRealLValue &obs, Double_t xlo, Double_t xhi) const override
Retrieve bin boundaries if this distribution is binned in obs.
virtual TObject * clone(const char *newname) const override
void add(RooFit::SuperFloat c, RooAbsReal *t)
void setCoefficient(size_t idx, RooFit::SuperFloat c)
virtual std::list< Double_t > * plotSamplingHint(RooAbsRealLValue &obs, Double_t xlo, Double_t xhi) const override
Interface for returning an optional hint for initial sampling points when constructing a curve projec...
RooFit::SuperFloat getCoefficient(size_t idx)
virtual Double_t evaluate() const override
Evaluate this PDF / function / constant. Needs to be overridden by all derived classes.
virtual void printArgs(std::ostream &os) const override
Print object arguments, ie its proxies.
std::vector< RooFit::SuperFloat > _coefficients
RooListProxy is the concrete proxy for RooArgList objects.
Mother of all ROOT objects.
Definition TObject.h:41
double SuperFloat
Definition Floats.h:29