49 if (plane != NULL )plane->
print();
58 Info(
"process",
"%ld events",
nEvents);
65 if ( mX == NULL )
return;
66 if ( mY== NULL )
return;
70 Double_t QchXmax = 0, QchYmax = 0;
73 for(Int_t i=0;i<
NADC;i++){
77 Int_t nSatX = 0, nSatY = 0, nChX = 0, nChY = 0;
78 for(Int_t j=0;j<
NCHAN;j++){
79 Double_t qchX = 0, qchY = 0;
80 for(Int_t i=0;i<
NADC;i++){
92 if(qchX>QchXmax) QchXmax = qchX;
93 if(qchY>QchYmax) QchYmax = qchY;
95 hQch->Fill(qchX,qchY);
113 hNsat->Fill(nSatX,nSatY);
115 for(Int_t i=0;i<
NADC;i++){
116 if(!(nSatTX[i]==0 && nSatTY[i]==0))
117 hNsat2->Fill(nSatTX[i],nSatTY[i]);
120 Double_t qXtot = 0, qYtot = 0;
121 Double_t qxtot[
NCHAN];
123 for(Int_t j=0;j<
NCHAN;j++){
128 Double_t meanRatio = 0, sigmaRatio = 0;
129 TArrayD* arrRatio =
new TArrayD(NADC);
130 for(Int_t i=0;i<
NADC;i++){
131 arrRatio->AddAt(-1,i);
132 Double_t qXch = 0, qYch = 0;
133 for(Int_t j=0;j<
NCHAN;j++){
134 Double_t qX = mX->
GetData(j,i);
135 Double_t qY = mY->
GetData(j,i);
144 if(qY > -1000) qYch += qY;
149 if(qYch>0 && nSatTX[i] <=1 && nSatTY[i] == 0){
150 for(Int_t j=0;j<
NCHAN;j++){
151 Double_t qcorr = qYtot + qXtot - qxtot[j];
163 if(nSatX<5 && nSatY<5 && (qXch>0 || qYch>0)){
168 if(nSatTX[i]<5 && nSatTY[i]<5 && (qXch>0 || qYch>0)){
173 if(qXch <= 0)
continue;
174 Double_t ratio = qYch/qXch/0.92;
182 ratio = TMath::Log(ratio);
188 sigmaRatio += ratio*ratio;
189 arrRatio->AddAt(ratio,i);
199 sigmaRatio -= meanRatio*meanRatio;
204 Double_t truncM, truncS;
205 TruncMean(arrRatio, truncS, truncM, 0.1, 0.9);
212 hTest->Fill(QchXmax,QchYmax);
213 hRatioTot->Fill(n,TMath::Log(qYtot/qXtot));
228 hRatioVsZ =
new TH2F(
"hRatioVsZ",
";Z",512,0,512,200,-5,5);
229 hRatioVsNchX =
new TH2F(
"hRatioVsNchX",
";N_{chX}",288,0,288,200,-5,5);
230 hRatioVsNchY =
new TH2F(
"hRatioVsNchY",
";N_{chY}",288,0,288,200,-5,5);
233 hRatioTot =
new TH2F(
"hRatioTot",
"",512,0,512,2000,-5.,5.);
234 hRatioTotCut1 =
new TH2F(
"hRatioTotCut1",
"",512,0,512,2000,-5.,5.);
235 hRatioTotCut2 =
new TH2F(
"hRatioTotCut2",
"",512,0,512,2000,-5.,5.);
239 const Int_t nbinsQcl = 1000;
240 Double_t xminQcl = 10;
241 Double_t xmaxQcl = 1e6;
242 Double_t logxminQcl = TMath::Log(xminQcl);
243 Double_t logxmaxQcl = TMath::Log(xmaxQcl);
244 Double_t binwidthQcl = (logxmaxQcl-logxminQcl)/nbinsQcl;
245 Double_t xbinsQcl[nbinsQcl+1];
246 xbinsQcl[0] = xminQcl;
247 for (Int_t i=1;i<=nbinsQcl;i++)
248 xbinsQcl[i] = TMath::Exp(logxminQcl+i*binwidthQcl);
249 hQch =
new TH2F(
"hQch",
";Q_{ch X};Q_{ch Y}",nbinsQcl,xbinsQcl,nbinsQcl,xbinsQcl);
250 for(Int_t i = 0; i<5; i++){
251 for(Int_t j = 0; j<5; j++){
252 hSaturation[i][j] =
new TH2F(Form(
"hSaturation%d_%d",i,j),
";Q_{X};Q_{Y}",nbinsQcl,xbinsQcl,nbinsQcl,xbinsQcl);
253 hSaturation2[i][j] =
new TH2F(Form(
"hSaturation2%d_%d",i,j),
";Q_{X};Q_{Y}",nbinsQcl,xbinsQcl,nbinsQcl,xbinsQcl);
256 hQxVsQyLogLog =
new TH2F(
"hQxVsQyLog",
";Q_{X};Q_{Y}",nbinsQcl,xbinsQcl,nbinsQcl,xbinsQcl);
257 hQxVsQyLog =
new TH2F(
"hQxVsQyLog",
";Q_{X};Q_{Y}",10000,0,1e6,nbinsQcl,xbinsQcl);
258 hQxVsQy =
new TH2F(
"hQxVsQy",
";Q_{X};Q_{Y}",2000,0,1e6,1000,0,1e5);
260 hNsat =
new TH2F(
"hNsat",
";N_{satX};N_{satY}",10,0,10,10,0,10);
261 hNsat2 =
new TH2F(
"hNsat2",
";N_{satX};N_{satY}",10,0,10,10,0,10);
265 hRatio =
new TH1F(
"hRatio",
";Q_{x}/Q_{y}",1000,0.5,1.5);
289 for(Int_t i = 0; i<5; i++){
290 for(Int_t j = 0; j<5; j++){
294 for(Int_t i = 0; i<5; i++){
295 for(Int_t j = 0; j<5; j++){
318 Int_t size = vect->GetSize();
320 Double_t truncMean = 0;
321 Double_t truncSigma = 0;
322 Int_t* index =
new Int_t[size];
323 TMath::Sort(size,vect->GetArray(),index,kFALSE);
324 Int_t t = 0, tLow, tHigh;
327 while(vect->At(index[t])<0&&t<size-1) t++;
328 tLow = TMath::FloorNint(t + (size - t)*tl);
329 tHigh = TMath::FloorNint(t + (size - t)*th);
331 for(Int_t tind = tLow; tind<tHigh; tind++){
332 truncMean += vect->At(index[tind]);
333 truncSigma += vect->At(index[tind])*vect->At(index[tind]);
340 if(tHigh-tLow < 15)
return 0;
342 truncMean /= (tHigh-tLow);
343 truncSigma /= (tHigh-tLow);
344 truncSigma -= truncMean*truncMean;
347 truncS = TMath::Sqrt(truncSigma);
TH1F * hRatio
Redefine empty default.
Double_t TruncMean(TArrayD *vect, Double_t &truncS, Double_t &truncM, Double_t tl, Double_t th)
Double_t GetData(Int_t i, Int_t j)
Set/Get Data Cell.
Bool_t isExist(ULong_t det)
Detecror date exist //! Number of Real Detectors.
TFile * OpenHistFile(const char *ananame)
TH2F * hTruncMeanVsSigmaRatio
Dummy analysis to run as test and example. Give basic histograms of the data.
unpacked dcc data The class contains the data map for DCC or Feminos The data is stored as a 2D TMatr...
void print()
Overloaded method which do all job.
TH2F * hSaturation2[5][5]
HarpoEventHeader * GetHeader()
void Save(char *mode=NULL)
const ULong_t gkNDetectors
HarpoDccMap * GetDccMap(Long_t plane=XDCC)
R__EXTERN HarpoDetSet * gHDetSet