public:

TSpectrum TSpectrum() TSpectrum TSpectrum(Int_t maxpositions, Float_t resolution = 1) TSpectrum TSpectrum(const TSpectrum&) virtual void ~TSpectrum() virtual const char* Background(TH1* hist, int niter, Option_t* option = "goff") const virtual const char* Background1(float* spectrum, int size, int niter) const virtual const char* Background2(float** spectrum, int sizex, int sizey, int niter) const static TClass* Class() virtual const char* Deconvolution1(float* source, float* resp, int size, int niter) const virtual const char* Deconvolution2(float** source, float** resp, int sizex, int sizey, int niter) const virtual TH1* GetHistogram() const virtual Int_t GetNPeaks() const virtual Float_t* GetPositionX() const virtual Float_t* GetPositionY() const virtual TClass* IsA() const virtual int PeakEvaluate(double* temp, int size, int xmax, double xmin) virtual Int_t Search(TH1* hist, Double_t sigma, Option_t* option = "goff") virtual Int_t Search1(float* spectrum, int size, double sigma) virtual Int_t Search2(float** source, int sizex, int sizey, double sigma) virtual void SetResolution(Float_t resolution = 1) virtual void ShowMembers(TMemberInspector& insp, char* parent) virtual void Streamer(TBuffer& b) void StreamerNVirtual(TBuffer& b)

protected:

Int_t fMaxPeaksMaximum number of peaks to be foundInt_t fNPeaksnumber of peaks foundFloat_t* fPosition!array of current peak positionsFloat_t* fPositionX!X position of peaksFloat_t* fPositionY!Y position of peaksFloat_t fResolutionresolution of the neighboring peaksTH1* fHistogramresulting histogram

THIS CLASS CONTAINS ADVANCED SPECTRA PROCESSING FUNCTIONS. ONE-DIMENSIONAL BACKGROUND ESTIMATION FUNCTION TWO-DIMENSIONAL BACKGROUND ESTIMATION FUNCTION ONE-DIMENSIONAL DECONVOLUTION FUNCTION TWO-DIMENSIONAL DECONVOLUTION FUNCTION ONE-DIMENSIONAL PEAK SEARCH FUNCTION TWO-DIMENSIONAL PEAK SEARCH FUNCTION These functions were written by: Miroslav Morhac Institute of Physics Slovak Academy of Sciences Dubravska cesta 9, 842 28 BRATISLAVA SLOVAKIA email:fyzimiro@savba.sk, fax:+421 7 54772479 The original code in C has been repackaged as a C++ class by R.Brun // The algorithms in this class have been published at the following references: [1] M.Morhac et al.: Background elimination methods for multidimensional coincidence gamma-ray spectra. Nuclear Instruments and Methods in Physics Research A 401 (1997) 113- 132. [2] M.Morhac et al.: Efficient one- and two-dimensional Gold deconvolution and its application to gamma-ray spectra decomposition. Nuclear Instruments and Methods in Physics Research A 401 (1997) 385-408. [3] M.Morhac et al.: Identification of peaks in multidimensional coincidence gamma-ray spectra. Submitted for publication in Nuclear Instruments and Methods in Physics Research A. These NIM papers are also available as Postscript files from: /* ftp://root.cern.ch/root/SpectrumDec.ps.gz ftp://root.cern.ch/root/SpectrumSrc.ps.gz ftp://root.cern.ch/root/SpectrumBck.ps.gz */

TSpectrum() :TNamed("Spectrum","Miroslav Morhac peak finder")

TSpectrum(Int_t maxpositions, Float_t resolution) :TNamed("Spectrum","Miroslav Morhac peak finder")

maxpositions: maximum number of peaks resolution: determines resolution of the neighboring peaks default value is 1 correspond to 3 sigma distance between peaks. Higher values allow higher resolution (smaller distance between peaks. May be set later through SetResolution.

~TSpectrum()

const char* Background(TH1 *h,int number_of_iterations, Option_t *option)

ONE-DIMENSIONAL BACKGROUND ESTIMATION FUNCTION This function calculates background spectrum from source in h. The result is placed in the vector pointed by spectrum pointer. Function parameters: spectrum: pointer to the vector of source spectrum size: length of spectrum and working space vectors number_of_iterations, for details we refer to manual

const char* Background1(float *spectrum,int size,int number_of_iterations)

ONE-DIMENSIONAL BACKGROUND ESTIMATION FUNCTION This function calculates background spectrum from source spectrum. The result is placed in the vector pointed by spectrum pointer. Function parameters: spectrum: pointer to the vector of source spectrum size: length of spectrum and working space vectors number_of_iterations, for details we refer to manual

const char* Background2(float **spectrum,int sizex,int sizey,int number_of_iterations)

TWO-DIMENSIONAL BACKGROUND ESTIMATION FUNCTION This function calculates background spectrum from source spectrum. The result is placed to the array pointed by spectrum pointer. Function parameters: spectrum: pointer to the array of source spectrum sizex: x length of spectrum and working space arrays sizey: y length of spectrum and working space arrays number_of_iterations, for details we refer to manual

const char* Deconvolution1(float *source,float *resp,int size,int number_of_iterations)

ONE-DIMENSIONAL DECONVOLUTION FUNCTION This function calculates deconvolution from source spectrum according to response spectrum The result is placed in the vector pointed by source pointer. Function parameters: source: pointer to the vector of source spectrum res: pointer to the vector of response spectrum size: length of source and response spectra number_of_iterations, for details we refer to manual

const char* Deconvolution2(float** source,float** resp,int sizex,int sizey,int number_of_iterations)

TWO-DIMENSIONAL DECONVOLUTION FUNCTION This function calculates deconvolution from source spectrum according to response spectrum The result is placed in the matrix pointed by source pointer. Function parameters: source: pointer to the matrix of source spectrum resp: pointer to the matrix of response spectrum sizex: x length of source and response spectra sizey: y length of source and response spectra number_of_iterations, for details we refer to manual

Int_t Search(TH1 *hin, Double_t sigma, Option_t *option)

ONE-DIMENSIONAL PEAK SEARCH FUNCTION This function searches for peaks in source spectrum in hin The number of found peaks and their positions are written into the members fNpeaks and fPositionX. Function parameters: hin: pointer to the histogram of source spectrum sigma: sigma of searched peaks, for details we refer to manual if option is not equal to "goff" (goff is the default), then a polymarker object is created and added to the list of functions of the histogram. The histogram is drawn with the specified option and the polymarker object drawn on top of the histogram. The polymarker coordinates correspond to the npeaks peaks found in the histogram. A pointer to the polymarker object can be retrieved later via: TList *functions = hin->GetListOfFunctions(); TPolyMarker *pm = (TPolyMarker*)functions->FindObject("TPolyMarker")

Int_t Search1(float *spectrum,int size,double sigma)

ONE-DIMENSIONAL PEAK SEARCH FUNCTION This function searches for peaks in source spectrum The number of found peaks and their positions are written into the members fNpeaks and fPositionX. Function parameters: source: pointer to the vector of source spectrum size: length of source spectrum sigma: sigma of searched peaks, for details we refer to manual

Int_t PeakEvaluate(double *temp,int size,int xmax,double xmin)

Int_t Search2(float **source,int sizex,int sizey,double sigma)

TWO-DIMENSIONAL PEAK SEARCH FUNCTION This function searches for peaks in source spectrum The number of found peaks and their positions are written into the members fNPeaks, fPositionX and fPositionY. Function parameters: source: pointer to the vector of source spectrum sizex: x length of source spectrum sizey: y length of source spectrum sigma: sigma of searched peaks, for details we refer to manual

void SetResolution(Float_t resolution)

resolution: determines resolution of the neighboring peaks default value is 1 correspond to 3 sigma distance between peaks. Higher values allow higher resolution (smaller distance between peaks. May be set later through SetResolution.

TH1* GetHistogram() const Int_t GetNPeaks() const Float_t* GetPositionX() const Float_t* GetPositionY() const TClass* Class() TClass* IsA() const void ShowMembers(TMemberInspector& insp, char* parent) void Streamer(TBuffer& b) void StreamerNVirtual(TBuffer& b) TSpectrum TSpectrum(const TSpectrum&)

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.