why while loop in AEvent::SetToT goes forever without second condition?
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 "<<fAmpMid<<endl;
while( fGraphSignal->Eval(time) >= fAmpMid && time < fTimeMid + ns) {
//cout<<"timeback "<<timeBack<<endl;
//cout<<"fGraphSignal->Eval(time) "<<fGraphSignal->Eval(time)<<endl;
//cout<<endl;
//if(timeBack>150.) {return;}
timeBack = time;
time = time + timeStep;
}
//cout<<"timeback "<<timeBack<<endl;
fToT = timeBack - fTimeMid;
//cout<<"ftot "<<fToT<<endl;