TSpectrum3.h

Go to the documentation of this file.
00001 // @(#)root/spectrum:$Id: TSpectrum3.h 20882 2007-11-19 11:31:26Z rdm $
00002 // Author: Miroslav Morhac   25/09/2006
00003 
00004 /*************************************************************************
00005  * Copyright (C) 1995-2006, Rene Brun and Fons Rademakers.               *
00006  * All rights reserved.                                                  *
00007  *                                                                       *
00008  * For the licensing terms see $ROOTSYS/LICENSE.                         *
00009  * For the list of contributors see $ROOTSYS/README/CREDITS.             *
00010  *************************************************************************/
00011 #ifndef ROOT_TSpectrum3
00012 #define ROOT_TSpectrum3
00013 
00014 #ifndef ROOT_TNamed
00015 #include "TNamed.h"
00016 #endif
00017 
00018 class TH1;
00019 
00020 class TSpectrum3 : public TNamed {
00021 protected:
00022    Int_t         fMaxPeaks;       //Maximum number of peaks to be found
00023    Int_t         fNPeaks;         //number of peaks found
00024    Float_t      *fPosition;       //[fNPeaks] array of current peak positions
00025    Float_t      *fPositionX;      //[fNPeaks] X positions of peaks
00026    Float_t      *fPositionY;      //[fNPeaks] Y positions of peaks
00027    Float_t      *fPositionZ;      //[fNPeaks] Z positions of peaks
00028    Float_t       fResolution;     //resolution of the neighboring peaks
00029    TH1          *fHistogram;      //resulting histogram
00030 
00031 public:
00032    enum {
00033        kBackIncreasingWindow =0,
00034        kBackDecreasingWindow =1,
00035        kBackSuccessiveFiltering =0,
00036        kBackOneStepFiltering =1
00037    };
00038 
00039    TSpectrum3();
00040    TSpectrum3(Int_t maxpositions, Float_t resolution=1);
00041    virtual ~TSpectrum3();
00042    virtual const char *Background(const TH1 *hist,int niter, Option_t *option="goff");
00043    const char         *Background(float ***spectrum,Int_t ssizex, Int_t ssizey, Int_t ssizez, Int_t numberIterationsX,Int_t numberIterationsY, Int_t numberIterationsZ, Int_t direction,Int_t filterType);
00044    const char         *Deconvolution(float ***source, const float ***resp, Int_t ssizex, Int_t ssizey, Int_t ssizez,Int_t numberIterations, Int_t numberRepetitions, Double_t boost);
00045    TH1                *GetHistogram() const {return fHistogram;}
00046    Int_t               GetNPeaks() const {return fNPeaks;}
00047    Float_t            *GetPositionX() const {return fPositionX;}
00048    Float_t            *GetPositionY() const {return fPositionY;}
00049    Float_t            *GetPositionZ() const {return fPositionZ;}
00050    virtual void        Print(Option_t *option="") const;
00051    virtual Int_t       Search(const TH1 *hist, Double_t sigma=2, Option_t *option="goff", Double_t threshold=0.05);
00052    Int_t               SearchFast(const float ***source, float ***dest, Int_t ssizex, Int_t ssizey, Int_t ssizez, Double_t sigma, Double_t threshold, Bool_t markov, Int_t averWindow);
00053    Int_t               SearchHighRes(const float ***source,float ***dest, Int_t ssizex, Int_t ssizey, Int_t ssizez, Double_t sigma, Double_t threshold, Bool_t backgroundRemove,Int_t deconIterations, Bool_t markov, Int_t averWindow);
00054    void                SetResolution(Float_t resolution=1);
00055    const char         *SmoothMarkov(float ***source, Int_t ssizex, Int_t ssizey, Int_t ssizez, Int_t averWindow);
00056 
00057    ClassDef(TSpectrum3,1)  //Peak Finder, Background estimator, Markov smoothing and Deconvolution for 3-D histograms
00058 };
00059 
00060 #endif
00061 
00062 

Generated on Tue Jul 5 14:24:33 2011 for ROOT_528-00b_version by  doxygen 1.5.1