first working FFT including DKS.
This commit is contained in:
@@ -121,6 +121,8 @@ PMusrCanvas::PMusrCanvas()
|
||||
fTimeout = 0;
|
||||
fTimeoutTimer = 0;
|
||||
|
||||
fStartWithFourier = false;
|
||||
fUseDKS = false;
|
||||
fScaleN0AndBkg = true;
|
||||
fValid = false;
|
||||
fAveragedView = false;
|
||||
@@ -185,8 +187,8 @@ PMusrCanvas::PMusrCanvas()
|
||||
*/
|
||||
PMusrCanvas::PMusrCanvas(const Int_t number, const Char_t* title,
|
||||
Int_t wtopx, Int_t wtopy, Int_t ww, Int_t wh,
|
||||
const Bool_t batch, const Bool_t fourier) :
|
||||
fStartWithFourier(fourier), fBatchMode(batch), fPlotNumber(number)
|
||||
const Bool_t batch, const Bool_t fourier, const Bool_t useDKS) :
|
||||
fStartWithFourier(fourier), fUseDKS(useDKS), fBatchMode(batch), fPlotNumber(number)
|
||||
{
|
||||
fTimeout = 0;
|
||||
fTimeoutTimer = 0;
|
||||
@@ -240,8 +242,8 @@ PMusrCanvas::PMusrCanvas(const Int_t number, const Char_t* title,
|
||||
Int_t wtopx, Int_t wtopy, Int_t ww, Int_t wh,
|
||||
PMsrFourierStructure fourierDefault,
|
||||
const PIntVector markerList, const PIntVector colorList,
|
||||
const Bool_t batch, const Bool_t fourier) :
|
||||
fStartWithFourier(fourier), fBatchMode(batch),
|
||||
const Bool_t batch, const Bool_t fourier, const Bool_t useDKS) :
|
||||
fStartWithFourier(fourier), fUseDKS(useDKS), fBatchMode(batch),
|
||||
fPlotNumber(number), fFourier(fourierDefault),
|
||||
fMarkerList(markerList), fColorList(colorList)
|
||||
{
|
||||
@@ -3456,7 +3458,12 @@ void PMusrCanvas::HandleFourier()
|
||||
|
||||
// calculate fourier transform of the theory
|
||||
Int_t powerPad = (Int_t)round(log((endTime-startTime)/fData[i].theory->GetBinWidth(1))/log(2))+3;
|
||||
PFourier fourierTheory(fData[i].theory, fFourier.fUnits, startTime, endTime, fFourier.fDCCorrected, powerPad);
|
||||
Bool_t useFFTW = true;
|
||||
#ifdef HAVE_DKS
|
||||
if ((powerPad >= 20) && fUseDKS)
|
||||
useFFTW = false; // i.e. use DKS
|
||||
#endif
|
||||
PFourier fourierTheory(fData[i].theory, fFourier.fUnits, startTime, endTime, fFourier.fDCCorrected, powerPad, useFFTW);
|
||||
if (!fourierTheory.IsValid()) {
|
||||
cerr << endl << "**SEVERE ERROR** PMusrCanvas::HandleFourier: couldn't invoke PFourier to calculate the Fourier theory ..." << endl;
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user