From 06ae0a12ea9ba09675af3fc1dc19a8a80047c071 Mon Sep 17 00:00:00 2001 From: Andreas Suter Date: Thu, 18 Oct 2018 13:54:05 +0200 Subject: [PATCH] fixed start != t0 phase issue --- src/classes/PFourier.cpp | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/classes/PFourier.cpp b/src/classes/PFourier.cpp index 2178f97f..4c088017 100644 --- a/src/classes/PFourier.cpp +++ b/src/classes/PFourier.cpp @@ -312,7 +312,7 @@ PFourier::PFourier(TH1F *data, Int_t unitTag, Double_t startTime, Double_t endTi // if endTime == 0 set it to the last time slot if (fEndTime == 0.0) { - Int_t last = fData->GetNbinsX(); + Int_t last = fData->GetNbinsX()-1; fEndTime = fData->GetBinCenter(last); } @@ -901,21 +901,21 @@ void PFourier::PrepareFFTwInputData(UInt_t apodizationTag) // 2nd fill fIn if (fUseFFTW) { - for (UInt_t i=0; iGetBinContent(i+t0bin) - mean; + for (UInt_t i=0; iGetBinContent(i+start) - mean; fIn[i][1] = 0.0; } - for (UInt_t i=fNoOfData-t0bin; iGetBinContent(i+t0bin) - mean; + fInDKS[i] = fData->GetBinContent(i+start) - mean; #endif } - for (UInt_t i=fNoOfData-t0bin; i