--- calo/flight/CaloProfile/inc/CaloProfile.h 2009/08/11 14:23:08 1.6 +++ calo/flight/CaloProfile/inc/CaloProfile.h 2009/08/13 15:56:38 1.9 @@ -5,7 +5,13 @@ #ifndef caloprofile_h #define caloprofile_h +#define EMPTY -1 +#define MAX 50 + #include +#include +#include +#include #include #include #include @@ -23,11 +29,17 @@ #include #include #include +#include #include using namespace std; +struct stack{ + char data[MAX]; + int top; +}; + /** * */ @@ -107,6 +119,11 @@ Float_t etmax; Float_t asymm; Float_t X0pl; + Float_t defE0; + Float_t umax; + Float_t lmax; + TString sumax; + TString slmax; Int_t fitresult; // Bool_t no18x; @@ -115,10 +132,14 @@ Bool_t maskXO; Bool_t maskYO; // + Bool_t xyaverage; + // Float_t eplane[2][22]; // CaloLevel2 *clp; // + Float_t Evaluate(TString s, Float_t max); // expression must be of the form "5*t"."t+10","t-(4*t)"... + // public: // @@ -131,6 +152,7 @@ void SetCaloLevel2Pointer(CaloLevel2 *cp){ clp = cp;}; // Float_t Get_E0(){this->Fit(); return E0;}; + Float_t Get_defE0(){this->Fit(); return defE0;}; Float_t Get_a(){this->Fit(); return a;}; Float_t Get_b(){this->Fit(); return b;}; Float_t Get_errE0(){this->Fit(); return errE0;}; @@ -156,6 +178,9 @@ void SetDebug(Bool_t d){ debug=d; }; void UsePlane18X(){ no18x=false; }; // + void UseAverage(){ xyaverage = true;}; + void UseAllMeas(){ xyaverage = false;}; + // void MaskSection(TString); void UnMaskSection(TString); void UnMaskSections(); @@ -168,6 +193,14 @@ Int_t GetNoWcalo(){return NC;}; ///< Get the number of W planes used as calorimeter. void SetEnergies(Float_t myene[][22]); // + void SetLowerLimit(Float_t l){ lmax = l; }; + void SetUpperLimit(Float_t u){ umax = u; }; + void SetLowerLimit(TString sl){ slmax = sl; };// expression must be of the form "5*t"."t+10","t-(4*t)"... where t will be replaced by the fitted maximum (X0) + void SetUpperLimit(TString su){ sumax = su; };// expression must be of the form "5*t"."t+10","t-(4*t)"... where t will be replaced by the fitted maximum (X0) + // + Float_t GetLowerLimit(){ return lmax;}; + Float_t GetUpperLimit(){ return umax;}; + // void Clear(); void Clear(Option_t *option){Clear();}; void Delete();