ROOT
6.07/01
Reference Guide
ROOT Home Page
Main Page
Tutorials
User's Classes
Namespaces
All Classes
Files
Release Notes
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Groups
Pages
hist
spectrum
inc
TSpectrumTransform.h
Go to the documentation of this file.
1
// @(#)root/spectrum:$Id$
2
// Author: Miroslav Morhac 25/09/06
3
4
/*************************************************************************
5
* Copyright (C) 1995-2006, Rene Brun and Fons Rademakers. *
6
* All rights reserved. *
7
* *
8
* For the licensing terms see $ROOTSYS/LICENSE. *
9
* For the list of contributors see $ROOTSYS/README/CREDITS. *
10
*************************************************************************/
11
#ifndef ROOT_TSpectrumTransform
12
#define ROOT_TSpectrumTransform
13
14
#ifndef ROOT_TNamed
15
#include "
TNamed.h
"
16
#endif
17
18
class
TH1
;
19
20
class
TSpectrumTransform
:
public
TNamed
{
21
22
protected
:
23
Int_t
fSize
;
///< length of transformed data
24
Int_t
fTransformType
;
///< type of transformation (Haar, Walsh, Cosine, Sine, Fourier, Hartley, Fourier-Walsh, Fourier-Haar, Walsh-Haar, Cosine-Walsh, Cosine-Haar, Sine-Walsh, Sine-Haar)
25
Int_t
fDegree
;
///< degree of mixed transform, applies only for Fourier-Walsh, Fourier-Haar, Walsh-Haar, Cosine-Walsh, Cosine-Haar, Sine-Walsh, Sine-Haar transforms
26
Int_t
fDirection
;
///< forward or inverse transform
27
Int_t
fXmin
;
///< first channel of filtered or enhanced region
28
Int_t
fXmax
;
///< last channel of filtered or enhanced region
29
Double_t
fFilterCoeff
;
///< value set in the filtered region
30
Double_t
fEnhanceCoeff
;
///< multiplication coefficient applied in enhanced region;
31
32
public
:
33
enum
{
34
kTransformHaar
=0,
35
kTransformWalsh
=1,
36
kTransformCos
=2,
37
kTransformSin
=3,
38
kTransformFourier
=4,
39
kTransformHartley
=5,
40
kTransformFourierWalsh
=6,
41
kTransformFourierHaar
=7,
42
kTransformWalshHaar
=8,
43
kTransformCosWalsh
=9,
44
kTransformCosHaar
=10,
45
kTransformSinWalsh
=11,
46
kTransformSinHaar
=12,
47
kTransformForward
=0,
48
kTransformInverse
=1
49
};
50
TSpectrumTransform
();
51
TSpectrumTransform
(
Int_t
size);
52
virtual
~TSpectrumTransform
();
53
54
protected
:
55
void
BitReverse
(
Double_t
*working_space,
Int_t
num);
56
void
BitReverseHaar
(
Double_t
*working_space,
Int_t
shift,
Int_t
num,
Int_t
start
);
57
void
Fourier
(
Double_t
*working_space,
Int_t
num,
Int_t
hartley,
Int_t
direction,
Int_t
zt_clear);
58
Int_t
GeneralExe
(
Double_t
*working_space,
Int_t
zt_clear,
Int_t
num,
Int_t
degree,
Int_t
type
);
59
Int_t
GeneralInv
(
Double_t
*working_space,
Int_t
num,
Int_t
degree,
Int_t
type
);
60
void
Haar
(
Double_t
*working_space,
Int_t
num,
Int_t
direction);
61
void
Walsh
(
Double_t
*working_space,
Int_t
num);
62
63
public
:
64
void
Enhance
(
const
Double_t
*source,
Double_t
*destVector);
65
void
FilterZonal
(
const
Double_t
*source,
Double_t
*destVector);
66
void
SetDirection
(
Int_t
direction);
67
void
SetEnhanceCoeff
(
Double_t
enhanceCoeff);
68
void
SetFilterCoeff
(
Double_t
filterCoeff);
69
void
SetRegion
(
Int_t
xmin
,
Int_t
xmax
);
70
void
SetTransformType
(
Int_t
transType,
Int_t
degree);
71
void
Transform
(
const
Double_t
*source,
Double_t
*destVector);
72
73
ClassDef
(
TSpectrumTransform
,1)
//Spectrum Transformer, it calculates classic orthogonal 1D transforms
74
};
75
76
77
#endif
78
TSpectrumTransform::fXmax
Int_t fXmax
last channel of filtered or enhanced region
Definition:
TSpectrumTransform.h:28
TSpectrumTransform::kTransformSin
Definition:
TSpectrumTransform.h:37
TSpectrumTransform::~TSpectrumTransform
virtual ~TSpectrumTransform()
Destructor.
Definition:
TSpectrumTransform.cxx:84
TSpectrumTransform::kTransformInverse
Definition:
TSpectrumTransform.h:48
xmin
float xmin
Definition:
THbookFile.cxx:93
TSpectrumTransform::fDirection
Int_t fDirection
forward or inverse transform
Definition:
TSpectrumTransform.h:26
TSpectrumTransform::SetTransformType
void SetTransformType(Int_t transType, Int_t degree)
This function sets the following parameters for transform:
Definition:
TSpectrumTransform.cxx:2236
TSpectrumTransform::kTransformWalsh
Definition:
TSpectrumTransform.h:35
TSpectrumTransform::fSize
Int_t fSize
length of transformed data
Definition:
TSpectrumTransform.h:23
TSpectrumTransform::kTransformCosWalsh
Definition:
TSpectrumTransform.h:43
Int_t
int Int_t
Definition:
RtypesCore.h:41
TSpectrumTransform
Advanced 1-dimensional orthogonal transform functions.
Definition:
TSpectrumTransform.h:20
TSpectrumTransform::fXmin
Int_t fXmin
first channel of filtered or enhanced region
Definition:
TSpectrumTransform.h:27
TSpectrumTransform::kTransformCosHaar
Definition:
TSpectrumTransform.h:44
TNamed.h
ClassDef
#define ClassDef(name, id)
Definition:
Rtypes.h:254
TNamed
The TNamed class is the base class for all named ROOT classes.
Definition:
TNamed.h:33
TSpectrumTransform::Transform
void Transform(const Double_t *source, Double_t *destVector)
This function transforms the source spectrum.
Definition:
TSpectrumTransform.cxx:740
TSpectrumTransform::SetEnhanceCoeff
void SetEnhanceCoeff(Double_t enhanceCoeff)
This function sets the enhancement coefficient:
Definition:
TSpectrumTransform.cxx:2299
TSpectrumTransform::FilterZonal
void FilterZonal(const Double_t *source, Double_t *destVector)
This function transforms the source spectrum.
Definition:
TSpectrumTransform.cxx:1268
TSpectrumTransform::kTransformSinHaar
Definition:
TSpectrumTransform.h:46
TSpectrumTransform::fFilterCoeff
Double_t fFilterCoeff
value set in the filtered region
Definition:
TSpectrumTransform.h:29
TSpectrumTransform::kTransformHaar
Definition:
TSpectrumTransform.h:34
TSpectrumTransform::GeneralInv
Int_t GeneralInv(Double_t *working_space, Int_t num, Int_t degree, Int_t type)
This function calculates inverse generalized (mixed) transforms Function parameters: ...
Definition:
TSpectrumTransform.cxx:546
TSpectrumTransform::kTransformFourierWalsh
Definition:
TSpectrumTransform.h:40
TSpectrumTransform::SetRegion
void SetRegion(Int_t xmin, Int_t xmax)
This function sets the filtering or enhancement region:
Definition:
TSpectrumTransform.cxx:2263
TSpectrumTransform::Haar
void Haar(Double_t *working_space, Int_t num, Int_t direction)
This function calculates Haar transform of a part of data Function parameters:
Definition:
TSpectrumTransform.cxx:95
TSpectrumTransform::kTransformCos
Definition:
TSpectrumTransform.h:36
xmax
float xmax
Definition:
THbookFile.cxx:93
TSpectrumTransform::BitReverse
void BitReverse(Double_t *working_space, Int_t num)
This function carries out bit-reverse reordering of data Function parameters:
Definition:
TSpectrumTransform.cxx:226
TSpectrumTransform::kTransformFourierHaar
Definition:
TSpectrumTransform.h:41
TSpectrumTransform::kTransformFourier
Definition:
TSpectrumTransform.h:38
TSpectrumTransform::GeneralExe
Int_t GeneralExe(Double_t *working_space, Int_t zt_clear, Int_t num, Int_t degree, Int_t type)
This function calculates generalized (mixed) transforms of different degrees Function parameters: ...
Definition:
TSpectrumTransform.cxx:430
Double_t
double Double_t
Definition:
RtypesCore.h:55
type
int type
Definition:
TGX11.cxx:120
TH1
The TH1 histogram class.
Definition:
TH1.h:80
TSpectrumTransform::fEnhanceCoeff
Double_t fEnhanceCoeff
multiplication coefficient applied in enhanced region;
Definition:
TSpectrumTransform.h:30
TSpectrumTransform::fTransformType
Int_t fTransformType
type of transformation (Haar, Walsh, Cosine, Sine, Fourier, Hartley, Fourier-Walsh, Fourier-Haar, Walsh-Haar, Cosine-Walsh, Cosine-Haar, Sine-Walsh, Sine-Haar)
Definition:
TSpectrumTransform.h:24
TSpectrumTransform::fDegree
Int_t fDegree
degree of mixed transform, applies only for Fourier-Walsh, Fourier-Haar, Walsh-Haar, Cosine-Walsh, Cosine-Haar, Sine-Walsh, Sine-Haar transforms
Definition:
TSpectrumTransform.h:25
start
Definition:
stressThreadPool.C:27
TSpectrumTransform::SetFilterCoeff
void SetFilterCoeff(Double_t filterCoeff)
This function sets the filter coefficient:
Definition:
TSpectrumTransform.cxx:2290
TSpectrumTransform::TSpectrumTransform
TSpectrumTransform()
TSpectrumTransform::kTransformWalshHaar
Definition:
TSpectrumTransform.h:42
TSpectrumTransform::Enhance
void Enhance(const Double_t *source, Double_t *destVector)
This function transforms the source spectrum.
Definition:
TSpectrumTransform.cxx:1778
TSpectrumTransform::Fourier
void Fourier(Double_t *working_space, Int_t num, Int_t hartley, Int_t direction, Int_t zt_clear)
This function calculates Fourier based transform of a part of data Function parameters: ...
Definition:
TSpectrumTransform.cxx:264
TSpectrumTransform::Walsh
void Walsh(Double_t *working_space, Int_t num)
This function calculates Walsh transform of a part of data Function parameters:
Definition:
TSpectrumTransform.cxx:173
TSpectrumTransform::kTransformForward
Definition:
TSpectrumTransform.h:47
TSpectrumTransform::kTransformHartley
Definition:
TSpectrumTransform.h:39
TSpectrumTransform::kTransformSinWalsh
Definition:
TSpectrumTransform.h:45
TSpectrumTransform::SetDirection
void SetDirection(Int_t direction)
This function sets the direction of the transform:
Definition:
TSpectrumTransform.cxx:2277
TSpectrumTransform::BitReverseHaar
void BitReverseHaar(Double_t *working_space, Int_t shift, Int_t num, Int_t start)
This function carries out bit-reverse reordering for Haar transform Function parameters: ...
Definition:
TSpectrumTransform.cxx:385