60 _var(
"var",
"variable",this,variable,true,true),
67 ss <<
"RooLinearVar::RooLinearVar(" << GetName()
68 <<
"): ERROR, slope(" << slope.GetName() <<
") and offset("
69 << offs.GetName() <<
") may not depend on variable("
70 << variable.GetName() <<
")";
71 const std::string errMsg = ss.str();
72 coutE(InputArguments) << errMsg << std::endl;
73 throw std::invalid_argument(errMsg);
129 coutE(Eval) <<
"RooLinearVar::setVal(" <<
GetName() <<
"): ERROR: slope is zero, cannot invert relation" << std::endl ;
146 if (!
_var->isJacobianOK(depList)) {
153 if (
_slope->dependsOnValue(*arg)) {
193 os <<
_slope->GetName() <<
" * " <<
_var->GetName() <<
" + " <<
_offset->GetName() ;
221 if (!
_var->hasRange(
name) && !createOnTheFly) {
230 return *transBinning ;
248 std::list<std::string> binningNames(1,
"");
251 binningNames.push_back(binning->GetName());
bool dependsOnValue(const RooAbsCollection &serverList, const RooAbsArg *ignoreArg=nullptr) const
Check whether this object depends on values from an element in the serverList.
RooAbsArg()
Default constructor.
Abstract base class for RooRealVar binning definitions.
double getVal(const RooArgSet *normalisationSet=nullptr) const
Evaluate object.
RooAbsReal()
coverity[UNINIT_CTOR] Default constructor
RooArgSet is a container object that can hold multiple RooAbsArg objects.
Special binning implementation for RooLinearVar that transforms the binning of the RooLinearVar input...
RooRealProxy _slope
Slope of transformation.
bool hasBinning(const char *name) const override
Returns true if binning with given name exists.If a given binning exists on the input variable,...
RooLinkedList _altBinning
!
std::list< std::string > getBinningNames() const override
Get a list of all binning names.
RooLinTransBinning _binning
double jacobian() const override
Return value of Jacobian associated with the transformation.
double evaluate() const override
Calculate current value of this object.
void writeToStream(std::ostream &os, bool compact) const override
Write object contents to stream.
bool isJacobianOK(const RooArgSet &depList) const override
Returns true if Jacobian term associated with current expression tree is indeed constant.
const RooAbsBinning & getBinning(const char *name=nullptr, bool verbose=true, bool createOnTheFly=false, bool shared=true) const override
Const version of getBinning().
void setVal(double value) override
Assign given value to linear transformation: sets input variable to (value-offset)/slope If slope is ...
RooRealProxy _offset
Offset of transformation.
bool readFromStream(std::istream &is, bool compact, bool verbose=false) override
Read object contents from stream.
RooTemplateProxy< RooAbsRealLValue > _var
Input observable.
~RooLinearVar() override
Destructor.
const char * GetName() const override
Returns name of object.
Mother of all ROOT objects.