library: libRooFit #include "RooFormulaVar.h"

# RooFormulaVar

class description - source file - inheritance tree (.pdf)

## class RooFormulaVar : public RooAbsReal

| Inheritance Chart:

`TObject`

<-

`TNamed`

`RooPrintable`

<-

`RooAbsArg`

<-

`RooAbsReal`

<-

`RooFormulaVar`

        protected:

          virtual Double_t evaluate() const
               RooFormula& formula() const
            virtual Bool_t isValidReal(Double_t value, Bool_t printError) const
            virtual Bool_t redirectServersHook(const RooAbsCollection& newServerList, Bool_t mustReplaceAll, Bool_t nameChange, Bool_t isRecursive)

        public:

                           RooFormulaVar()
                           RooFormulaVar(const char* name, const char* title, const char* formula, const RooArgList& dependents)
                           RooFormulaVar(const char* name, const char* title, const RooArgList& dependents)
                           RooFormulaVar(const RooFormulaVar& other, const char* name = "0")
                   virtual ~RooFormulaVar()
            static TClass* Class()
          virtual TObject* clone(const char* newname) const
          virtual Double_t defaultErrorLevel() const
                      void dumpFormula()
                RooAbsArg* getParameter(const char* name) const
                RooAbsArg* getParameter(Int_t index) const
           virtual TClass* IsA() const
                    Bool_t ok() const
              virtual void printToStream(ostream& os, RooPrintable::PrintOption opt = Standard, TString indent = ) const
            virtual Bool_t readFromStream(istream& is, Bool_t compact, Bool_t verbose = kFALSE)
              virtual void ShowMembers(TMemberInspector& insp, char* parent)
              virtual void Streamer(TBuffer& b)
                      void StreamerNVirtual(TBuffer& b)
              virtual void writeToStream(ostream& os, Bool_t compact) const

### Data Members

        protected:

          RooListProxy _actualVars
           RooFormula* _formula     Formula engine
               TString _formExpr

## Class Description

RooFormulaVar(const char *name, const char *title, const char* formula, const RooArgList& dependents) : RooAbsReal(name,title), _actualVars("actualVars","Variables used by formula expression",this), _formula(0), _formExpr(formula)

     Constructor with formula expression and list of input variables
       RooFormula tmpFormula(name,formula,dependents) ;

RooFormulaVar(const char *name, const char *title, const RooArgList& dependents) : RooAbsReal(name,title), _actualVars("actualVars","Variables used by formula expression",this), _formula(0), _formExpr(title)

     Constructor with formula expression, title and list of input variables
       RooFormula tmpFormula(name,title,dependents) ;

RooFormulaVar(const RooFormulaVar& other, const char* name) : RooAbsReal(other, name), _actualVars("actualVars",this,other._actualVars), _formula(0), _formExpr(other._formExpr)

     Copy constructor

~RooFormulaVar()

     Destructor

RooFormula& formula() const

Double_t evaluate() const

     Calculate current value of object

Bool_t isValidReal(Double_t /*value*/, Bool_t /*printError*/) const

     Check if given value is valid

Bool_t redirectServersHook(const RooAbsCollection& newServerList, Bool_t mustReplaceAll, Bool_t nameChange, Bool_t /*isRecursive*/)

     Propagate server change information to embedded RooFormula object

void printToStream(ostream& os, PrintOption opt, TString indent) const

     Print info about this object to the specified stream.

Bool_t readFromStream(istream& /*is*/, Bool_t /*compact*/, Bool_t /*verbose*/)

     Read object contents from given stream

void writeToStream(ostream& os, Bool_t compact) const

     Write object contents to given stream

Double_t defaultErrorLevel() const

     See if we contain a RooNLLVar or RooChi2Var object

### Inline Functions

            RooFormulaVar RooFormulaVar(const RooFormulaVar& other, const char* name = "0")
                 TObject* clone(const char* newname) const
                   Bool_t ok() const
               RooAbsArg* getParameter(const char* name) const
               RooAbsArg* getParameter(Int_t index) const
                     void dumpFormula()
                  TClass* Class()
                  TClass* IsA() const
                     void ShowMembers(TMemberInspector& insp, char* parent)
                     void Streamer(TBuffer& b)
                     void StreamerNVirtual(TBuffer& b)

Last update: Tue Jun 28 18:12:24 2005
Copyright (c) 2000-2005, Regents of the University of California *