diff --git a/dataClasses/AEvent.cpp b/dataClasses/AEvent.cpp index 7ecf7814aa023ae07c30fe9c866f08d684658eed..07d29de21c28959806f6b1567ced2f10b1d684dd 100644 --- a/dataClasses/AEvent.cpp +++ b/dataClasses/AEvent.cpp @@ -65,6 +65,7 @@ void AEvent::ProcessEvent(Bool_t bSmooth) { SetChargeCFD(); SetChargeLED(); SetChargeTF(); + SetToT(); // SmoothGraphs(); @@ -86,6 +87,8 @@ void AEvent::Reset() { fTime10=0.; fTime90=0.; fTimeMid=0.; + fToT=-100.; + fAmpMid=0.; fAmpMax = 0.; fTimeAmpMax = 0.; fTimeCFD = -100.; @@ -249,6 +252,7 @@ void AEvent::FindFrontProperties() { fEdgeXi = fit1->GetChisquare(); fTimeMid = (fTime90 -fTime10)*0.5 + fTime10; //time point between fTime90 and fTime10 + fAmpMid = fGraphSignal->Eval(fTimeMid); //adding point where fit function crosses zero Double_t a = 0, b = 0; @@ -427,3 +431,29 @@ void AEvent::SetLED(Double_t threshold) { // сделать через функцию getpoint и цикл по точкам от } + +void AEvent::SetToT() { + + Double_t time = fTimeMid; + Double_t timeBack = 0; + const Double_t ns = 15.; //withing this interval signal should end for sure, in nanosec + + const Double_t timeStep = 0.05; + + //cout<<"fAmpMid "<Eval(time) >= fAmpMid && time < fTimeMid + ns) { + //cout<<"timeback "<Eval(time) "<Eval(time)<150.) {return;} + timeBack = time; + time = time + timeStep; + } + //cout<<"timeback "<SetRange(t10[k], t90[k]); //gr[k]->Fit(f1, "RQ"); } - c1->Print(Form("../macros/picsDRS4/file%s/signals%s", foldername, ext)); + //c1->Print(Form("../macros/picsDRS4/file%s/signals%s", foldername, ext)); // c1->cd(2); // tr->Draw("gAmp.Draw()","","goff",1,124); }