Commit e3dcb40f authored by Kostyleva D.A's avatar Kostyleva D.A

AEvent::SetLED method added (leading edge discriminator)

parent c4aaa9d6
......@@ -52,6 +52,7 @@ void AEvent::ProcessEvent() {
SetGraphs();
FindFrontProperties();
SetLED();
// SetGraphs();
SetCFD();
SetChargeCFD();
......@@ -279,3 +280,15 @@ void AEvent::SetMaxAmplitudes() {
fTimeAmpMax = maxAmpT;
}
void AEvent::SetLED(Double_t threshold) {
Double_t time = 0;
const Double_t timeStep = 0.1;
while( time < 200. && fGraphSignal->Eval(time) <= threshold ) {
fTimeLED = time;
time = time + timeStep;
}
//fTimeLED = time;
}
......@@ -48,6 +48,8 @@ private:
Double_t fTimeCFD; //zero-crossing time
Double_t fChargeCFD; //charge of the signal in Coulomb
Double_t fTimeLED; //time of LED threshold crossing
TGraph *fGraphSignal;
TGraph *fGraphCFD;
......@@ -120,7 +122,7 @@ public:
//in range of (tmin,tmax) in ns)
//CFD time is taken as a start point
void SetLED(Double_t threshold = 0.001);
void SetLED(Double_t threshold = 0.015);
//leading edge discriminator
private:
......
......@@ -3,8 +3,8 @@
const Long64_t kFirstEvent = 128;
TFile fr("../data/dataDSR4/Neurad_7_08_NEW.root");
// TFile fr("../data/dataDSR4/analysis_07_8.root");
// TFile fr("../data/dataDSR4/Neurad_7_08_NEW.root");
TFile fr("../data/dataDSR4/analysis_07_8.root");
// TFile fr("../data/dataDSR4/Neurad_081216_2NEW.root");
// TFile fr("../data/dataTektronix/exp18.root");
// TFile fr("../data/dataTektronix/analysisExp7.root");
......@@ -35,6 +35,8 @@
c1->cd(i+1);
histNoise[i]->Draw();
histNoise[i]->Fit("gaus");
gStyle->SetOptFit();
c1->Update();
}
......
//#include "TCanvas.h"
<<<<<<< HEAD
void histCorr(const char *filename = "analysis_07_8.root", const char *foldername = "7_8", const char *ext = ".eps", const Bool_t can1 = 0, const Bool_t can2 = 0, const Bool_t can3 = 0, const Bool_t can4 = 0, const Bool_t can5 = 1)
=======
void histCorr(
// const char *filename = "analysis_07_8.root",
const char *filename = "analysis_08_2.root",
......@@ -10,12 +7,8 @@ void histCorr(
const char *foldername = "8_2",
// const char *ext = ".eps",
const char *ext = ".gif",
<<<<<<< HEAD
const Bool_t can1 = 1, const Bool_t can2 = 1, const Bool_t can3 = 1, const Bool_t can4 = 1, const Bool_t can5 = 1)
>>>>>>> 1612d04b19c3139e125a1642bdb0763585790d84
=======
const Bool_t can1 = 0, const Bool_t can2 = 0, const Bool_t can3 = 0, const Bool_t can4 = 0, const Bool_t can5 = 1)
>>>>>>> 07d2b501d7fd6bf88dd2d6b203a724d53357bbe3
{
gSystem->Load("../libData.so");
TFile *f = new TFile(Form("../data/dataDSR4/%s", filename));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment