Changeset 3053 for trunk


Ignore:
Timestamp:
02/08/04 20:41:14 (21 years ago)
Author:
gaug
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/Changelog

    r3051 r3053  
    2020   * manalysis/MHPedestalPixel.cc
    2121     - increased number of bins in for charges plot
     22
     23   * mtools/MFFT.[h,cc]
     24     - possibility to have PSD directly from TArray
    2225
    2326
  • trunk/MagicSoft/Mars/mtools/MFFT.h

    r2854 r3053  
    2929  void Swap(Double_t &a, Double_t &b)   { Double_t c = a;  a = b;  b = c;  }
    3030
    31   void TransformF(const Int_t isign);
    32   void TransformD(const Int_t isign); 
     31  void TransformF(const Int_t isign, TArrayF &data);
     32  void TransformD(const Int_t isign, TArrayD &data); 
    3333  void RealFTF(const Int_t isign);
    3434  void RealFTD(const Int_t isign);
     
    3636  void CheckDim(Int_t a);
    3737  TH1 *CheckHist(const TH1 *hist, const Int_t flag);
     38
     39  Float_t ApplyWindow(const Int_t j, const Float_t a, const Float_t b) const
     40    {
     41
     42      return 1.0-TMath::Abs((j-a)*b);      // Bartlett
     43      // return 1.0;                        // Square
     44      // return 1.0-(((j-a)*b)*((j-a)*b));   // Welch
     45     
     46    }
    3847 
    3948  Int_t   fDim;
    4049  TArrayF fDataF;
    4150  TArrayD fDataD; 
     51  TArrayF fWindowF;
     52  TArrayD fWindowD; 
    4253
    4354public:
     
    5869  Double_t* RealFunctionIFFT(const Int_t n, const Double_t *data); 
    5970 
     71  TH1F* PowerSpectrumDensity(const TH1 *hist);
    6072  TH1F* PowerSpectrumDensity(const TH1F *hist);
     73  TH1F* PowerSpectrumDensity(const TH1I *hist); 
    6174  TH1D* PowerSpectrumDensity(const TH1D *hist);
     75
     76  TArrayF* PowerSpectrumDensity(const TArrayF *array);
     77  TArrayD* PowerSpectrumDensity(const TArrayD *array);
     78 
     79  TArrayF*  RealFunctionSpectrum(const TArrayF *data);
    6280 
    6381  ClassDef(MFFT,0)  // Class to perform a Fast Fourier Transform
Note: See TracChangeset for help on using the changeset viewer.