#include "hmdcgarcal2maker.h"

HMdcGarCal2Maker


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

class HMdcGarCal2Maker : public TNamed

Inheritance Chart:
TObject
<-
TNamed
<-
HMdcGarCal2Maker

    protected:
void initArrays() void initVariables() public:
HMdcGarCal2Maker(const char* name, const char* title) HMdcGarCal2Maker(const HMdcGarCal2Maker&) ~HMdcGarCal2Maker() void calcBounderies(Int_t, Int_t, Float_t*, Float_t*) Bool_t check(Int_t, Int_t) static TClass* Class() void copyToArray(TH1F*, Int_t, Int_t, Int_t) void copyToHist(TH1F*, Int_t, Int_t, Int_t) void createGraph(Int_t, Int_t, Int_t) void drawBorders(Int_t, Int_t, Int_t) void fillArrays(TH1F*, TH1F*, Int_t, Int_t) void fillControl1D(Int_t, Int_t, TString) void fillControl2D(Int_t, Int_t, TString) void findMax(Int_t) Int_t getBatchMode() Float_t getCutMax(Int_t i) Int_t getHists_1D(Int_t i) Int_t getHists_2D(Int_t i) Int_t getLevelColors(Int_t i) Int_t getMakeMdc(Int_t i) Int_t getMakeType(Int_t i) Int_t getMaxBinNumber(Int_t i) Int_t getMaxCopy() Float_t getMaxErrTime1() Float_t getMaxErrTime2() Int_t getMinCopy() Int_t getNBin1D_Dist() Int_t getNBin2D_Angle() Int_t getNBin2D_Dist() Int_t getNTimes(Int_t i) Int_t getPrintMode() Float_t getSlope() Float_t getSpikeThreshold1() Float_t getSpikeThreshold2() Int_t getSpikeTypes(Int_t i) Int_t getStepSize() Int_t getThreshold() Int_t getVersion() Int_t getVoltage(Int_t i) Bool_t getWriteAscii() Bool_t getWriteHists() virtual TClass* IsA() const void make() HMdcGarCal2Maker& operator=(const HMdcGarCal2Maker&) void plotOverlay(Int_t, Int_t) void printStatus() void readInput() void removeSpikes(Int_t) void replaceBins(TH1F*, Int_t, Int_t, Int_t) void setBatchMode(Bool_t mode) void setCutMax(Float_t c0, Float_t c1, Float_t c2, Float_t c3) void setFileNameIn(TString) void setFileNameOut(TString) void setHists_1D(Int_t i, Int_t j, Int_t k, Int_t l) void setHists_2D(Int_t i, Int_t j, Int_t k, Int_t l) void setLevelColors(Int_t i, Int_t j, Int_t k) void setMakeMdc(Int_t i, Int_t j, Int_t k, Int_t l) void setMakeType(Int_t i, Int_t j, Int_t k, Int_t l) void setMaxBinNumber(Int_t* array) void setMaxCopy(Int_t b) void setMaxErrTime1(Float_t e) void setMaxErrTime2(Float_t e) void setMinCopy(Int_t b) void setNBin1D_Dist(Int_t b) void setNBin2D_Angle(Int_t b) void setNBin2D_Dist(Int_t b) void setNTimes(Int_t s0, Int_t s1, Int_t s2, Int_t s3) void setPrintMode(Bool_t mode) void setSlope(Float_t s0) void setSpikeThresholds(Float_t t1, Float_t t2) void setSpikeTypes(Int_t s0, Int_t s1, Int_t s2, Int_t s3) void setStepSize(Int_t size) void setThreshold(Int_t thresh) void setVersion(Int_t vers) void setVoltage(Int_t s0, Int_t s1, Int_t s2, Int_t s3) void setWriteAscii(Bool_t write) void setWriteHists(Bool_t write) virtual void ShowMembers(TMemberInspector& insp, char* parent) void smoothHist(TH1F*, Int_t) virtual void Streamer(TBuffer& b) void StreamerNVirtual(TBuffer& b) void writeAscii()

Data Members


    protected:
TString fNameAsciiOut ! file name of ascii output file FILE* output ! file pointer to out put TString fNameRootIn ! file name of root input file TFile* inputRoot ! root file pointer TFile* outputHists ! root file pointer static Float_t cutMax[4] ! cut at max drift time Float_t slope ! slope of drift time/bin Int_t voltage[4] ! HV voltage for mdc types TH1F* htime1 ! hist pointer for time1 TH1F* htime2 ! hist pointer for time2 Int_t lastvalidBin[4][18] ! counter of non empty bins static Int_t maxbinNumber[72] max number of bins/hist Float_t mtime1[4][18][100] ! array of time1 Float_t mtime2[4][18][100] ! array of time2 Float_t mtime1_err[4][18][100] ! array of error of time1 Float_t mtime2_err[4][18][100] ! array of error of time2 Float_t mtime1_corr[4][18][100] ! array of corrected time1 Float_t mtime2_corr[4][18][100] ! array of corrected time2 Float_t mtime1_err_corr[4][18][100] ! array of corrected error of time1 Float_t mtime2_err_corr[4][18][100] ! array of corrected error of time2 Float_t max1[4][18] ! max 1 Float_t max2[4][18] ! max 2 Int_t max1bin[4][18] ! bin max 1 Int_t max2bin[4][18] ! bin max 2 Int_t threshold ! threshold value (*stepsize=%) Int_t stepsize ! %/step Bool_t isBatch ! switch batch/no batch mode Bool_t writeHists ! switch write Hists to cal2maker.root or not Bool_t printSpikes ! switch print spikes or not Bool_t writeascii ! switch for write/don't write asciie output Int_t version ! old/new (1/2) file format Float_t maxErrTime1 ! Float_t maxErrTime2 ! Int_t removeSpike[4] ! switch for removing spike types Float_t threshold1 ! threshold for spike removing Float_t threshold2 ! threshold for spike removing Int_t nTimes[4] ! number of smooth's per type Int_t nBin1D_dist ! Int_t nBin2D_angle ! Int_t nBin2D_dist ! Int_t minCopy ! Int_t maxCopy ! Int_t activeHists_1D[4] ! Int_t activeHists_2D[4] ! TGraph* g[4][18][4][3] ! Int_t levelColors[4] ! Int_t makeMdc[4] ! Int_t makeType[4] !

Class Description

 HMdcGarCal2Maker
 Reads Histograms for time1/time2 versus distance from wire from root file
 produced with HMdcGarSignalReader. The values for time1 and time2 and the
 corresponding errors are processed (spike removing, smoothing, cut at max
 value per mdc) for all MDC's and all impact angles for time1, time2,
 error of time1 and error of time2. A root file with the control hists is
 written and an ascii file containing the parameters of HMdcCal2ParSim is
 produced.


HMdcGarCal2Maker(const char* name,const char* title) : TNamed(name,title)
 constructor for HMdcGarCal2Maker
 The parameters are initialized with non valid values.

~HMdcGarCal2Maker()
 destructor of HMdcGarCal2Maker

void setFileNameOut(TString myfile)
 Sets ascii output of HMdcGarCal2Maker

void setFileNameIn(TString myfile)
 Sets root input of HMdcGarCal2Maker

void initVariables()
 inits all variables

void printStatus(void)
 prints the parameters to the screen

Bool_t check(Int_t m,Int_t t)
 Checks if the Mdc m and the type t (t1,t1err,t2,t2err)
 is active in the current setup

void calcBounderies(Int_t mdc,Int_t a,Float_t* cellEdge,Float_t* maxDist)
 Calulates the bounderies of the different cell types of the MDC's underr
 certain impact angle "a". "cellEdge" is the max distances of a track with
 minimum distance at the cell border whereas "maxDist" is the max minimum
 distance of a track just hitting the cell.

void make()
 Main function to be called from the macro.

void fillArrays(TH1F* htime1,TH1F* htime2,Int_t mdctype,Int_t angle)
 Fills values for time1, time2 and the corresponding errors from the hists into
 working arrays.

void findMax(Int_t m)
 finds maximum values inside the array of
 time1err and replacing values after max by
 a constant value.

void removeSpikes(Int_t m)
 Removes spikes from time1err

void copyToHist(TH1F* h,Int_t m,Int_t a,Int_t type)
 Copys workings arrays to hists

void copyToArray(TH1F* h,Int_t m,Int_t a,Int_t type)
 Copy working hists to arrays

void smoothHist(TH1F* h,Int_t type)
 Smooth working hists by number of cycles defined

void replaceBins(TH1F* h,Int_t m,Int_t a,Int_t type)
 Replace the first bins and the bins after the maximum bin of the
 workings hists after smoothing by the original bins of the working arrays.

void createGraph(Int_t m,Int_t t,Int_t l)
 Create Graphs , fill them with the working array and write
 them to disk

void fillControl2D(Int_t mdctype,Int_t type,TString context)
 Fills a 2D Control hist from the working arrays and writes the hist to disk.

void fillControl1D(Int_t mdctype,Int_t type,TString context)
 Fills 1D Control hists (for each impact angle) and writes the hists to disk.

void plotOverlay(Int_t mdctype,Int_t type)
 Plots overlay of Graphs after the differrent working steps
 (raw, spike remove, smooth and replacement of bins).

void drawBorders(Int_t mdctype,Int_t angle,Int_t type)
 Draw lines for max value of Celledge / max distance

void writeAscii()
 Writes the created parameters form the working arrays to an ascii file.

void readInput()
 Reads input file to get the hists for time1 and time2 produced by
 HMdcGarSignalReader.



Inline Functions


                     void initArrays()
                     void setCutMax(Float_t c0, Float_t c1, Float_t c2, Float_t c3)
                    Int_t getVersion()
                     void setVersion(Int_t vers)
                  Float_t getCutMax(Int_t i)
                     void setSlope(Float_t s0)
                  Float_t getSlope()
                     void setThreshold(Int_t thresh)
                    Int_t getThreshold()
                     void setStepSize(Int_t size)
                    Int_t getStepSize()
                     void setBatchMode(Bool_t mode)
                    Int_t getBatchMode()
                     void setPrintMode(Bool_t mode)
                    Int_t getPrintMode()
                     void setWriteHists(Bool_t write)
                   Bool_t getWriteHists()
                     void setWriteAscii(Bool_t write)
                   Bool_t getWriteAscii()
                     void setMaxErrTime1(Float_t e)
                  Float_t getMaxErrTime1()
                     void setMaxErrTime2(Float_t e)
                  Float_t getMaxErrTime2()
                     void setSpikeTypes(Int_t s0, Int_t s1, Int_t s2, Int_t s3)
                    Int_t getSpikeTypes(Int_t i)
                     void setSpikeThresholds(Float_t t1, Float_t t2)
                  Float_t getSpikeThreshold1()
                  Float_t getSpikeThreshold2()
                     void setNTimes(Int_t s0, Int_t s1, Int_t s2, Int_t s3)
                    Int_t getNTimes(Int_t i)
                     void setNBin1D_Dist(Int_t b)
                    Int_t getNBin1D_Dist()
                     void setNBin2D_Dist(Int_t b)
                    Int_t getNBin2D_Dist()
                     void setNBin2D_Angle(Int_t b)
                    Int_t getNBin2D_Angle()
                     void setMinCopy(Int_t b)
                    Int_t getMinCopy()
                     void setMaxCopy(Int_t b)
                    Int_t getMaxCopy()
                     void setHists_1D(Int_t i, Int_t j, Int_t k, Int_t l)
                    Int_t getHists_1D(Int_t i)
                     void setHists_2D(Int_t i, Int_t j, Int_t k, Int_t l)
                    Int_t getHists_2D(Int_t i)
                     void setMakeMdc(Int_t i, Int_t j, Int_t k, Int_t l)
                    Int_t getMakeMdc(Int_t i)
                     void setMakeType(Int_t i, Int_t j, Int_t k, Int_t l)
                    Int_t getMakeType(Int_t i)
                     void setLevelColors(Int_t i, Int_t j, Int_t k)
                    Int_t getLevelColors(Int_t i)
                     void setVoltage(Int_t s0, Int_t s1, Int_t s2, Int_t s3)
                    Int_t getVoltage(Int_t i)
                     void setMaxBinNumber(Int_t* array)
                    Int_t getMaxBinNumber(Int_t i)
                  TClass* Class()
                  TClass* IsA() const
                     void ShowMembers(TMemberInspector& insp, char* parent)
                     void Streamer(TBuffer& b)
                     void StreamerNVirtual(TBuffer& b)
         HMdcGarCal2Maker HMdcGarCal2Maker(const HMdcGarCal2Maker&)
        HMdcGarCal2Maker& operator=(const HMdcGarCal2Maker&)


Last update: Fri Jan 26 12:08:50 2007


ROOT page - Class index - Class Hierarchy - Top of the page

This page has been automatically generated. If you have any comments or suggestions about the page layout send a mail to ROOT support, or contact the developers with any questions or problems regarding ROOT.