Skip to content
Snippets Groups Projects
Commit f1a007f6 authored by clement's avatar clement
Browse files

Implementation in TParis of the TRef at mapfinger 99

parent dd397e66
No related branches found
No related tags found
No related merge requests found
......@@ -75,4 +75,6 @@
7 6 4 5 0 228 -154 53
7 7 4 6 0 228 -154 0
7 8 4 7 0 228 -154 -53
//Special channels for TRef
100 100 5 15 0 0 0 0
END
......@@ -281,15 +281,21 @@ bool TParis::InitNumexo2(Char_t *fileNumexo2){
DetId =((TObjString* )toks->At(1))->GetString().Atoi();
board = ((TObjString* )toks->At(2))->GetString().Atoi();
channel = ((TObjString* )toks->At(3))->GetString().Atoi();
MapFinger[board][channel]=ClusterId*9+DetId;
Channel_in_Cluster[MapFinger[board][channel]]=ClusterId;
v1[MapFinger[board][channel]].SetX(((TObjString* )toks->At(5))->GetString().Atof());
v1[MapFinger[board][channel]].SetY(((TObjString* )toks->At(6))->GetString().Atof());
v1[MapFinger[board][channel]].SetZ(((TObjString* )toks->At(7))->GetString().Atof());
Paris_Angle[MapFinger[board][channel]][0]=v1[MapFinger[board][channel]].Theta();
Paris_Angle[MapFinger[board][channel]][1]=v1[MapFinger[board][channel]].Phi();
//cout<<"Paris Angles :: "<<MapFinger[board][channel]<< " "<< Paris_Angle[MapFinger[board][channel]][0]<<" "<<Paris_Angle[MapFinger[board][channel]][1]<<" "<<endl;
if(ClusterId==100&&DetId==100){//T REF detected
MapFinger[board][channel]=99; //99 value
}
else{
MapFinger[board][channel]=ClusterId*9+DetId;
Channel_in_Cluster[MapFinger[board][channel]]=ClusterId;
v1[MapFinger[board][channel]].SetX(((TObjString* )toks->At(5))->GetString().Atof());
v1[MapFinger[board][channel]].SetY(((TObjString* )toks->At(6))->GetString().Atof());
v1[MapFinger[board][channel]].SetZ(((TObjString* )toks->At(7))->GetString().Atof());
Paris_Angle[MapFinger[board][channel]][0]=v1[MapFinger[board][channel]].Theta();
Paris_Angle[MapFinger[board][channel]][1]=v1[MapFinger[board][channel]].Phi();
//cout<<"Paris Angles :: "<<MapFinger[board][channel]<< " "<< Paris_Angle[MapFinger[board][channel]][0]<<" "<<Paris_Angle[MapFinger[board][channel]][1]<<" "<<endl;
}
}
//cerr<<"ClusterId " <<ClusterId<<" DetId "<<DetId<<" board "<<board<<" channel "<<channel<<" Z " <<((TObjString* )toks->At(7))->GetString().Atof()<<endl;
......@@ -322,7 +328,7 @@ bool TParis::IsMFMParis(MFMParisFrame *frame)
TVector3 v1Local;
float NaISize = 150. ; //mm - to be confirmed
float LaBrSize = 40.; //mm - to be confirmed
bool IsNotTref = true;
Board=CristalId=-10;
int localDTS;
......@@ -345,10 +351,10 @@ bool TParis::IsMFMParis(MFMParisFrame *frame)
localMapFinger=MapFinger[Board][CristalId];
if(localMapFinger==99)IsNotTref=false;
if(debug)cerr<<" (*) MapFinger:: "<<localMapFinger<<endl;
if(debug&&localMapFinger==1100)cerr<<" (*) MapFinger:: is TRef"<<endl;
if(CristalId>=0&&localMapFinger>=0){
result=true;
......@@ -365,7 +371,7 @@ bool TParis::IsMFMParis(MFMParisFrame *frame)
}
if(frame->GetTimeStamp()==0)cerr<<"TParis :: MapFinger : CristalId : Board = "<<localMapFinger<<" : " <<CristalId<<" : "<<Board<<endl;
if(result&&DuplicatedEvent==false&&frame->GetQLong()>0){
if(result&&DuplicatedEvent==false&&frame->GetQLong()>0&&IsNotTref){
if(debug)cerr<<" (*) Push Data "<<endl;
......@@ -599,6 +605,19 @@ bool TParis::IsMFMParis(MFMParisFrame *frame)
//if(localDTS<0)printf("\033[31m********* Time Stamp Error :: TParis back in future !!! ********* \033[m \n");
PrevTS= fParisData->GetfTimeStamps(localMapFinger);
}
else if(IsNotTref==false){ //So it is TRef
fParisData->SetParisDetectorNbr(localMapFinger); //should be 99
fParisData->SetParisCfd(frame->GetCfd());
fParisData->SetfTimeStamps(frame->GetTimeStamp(),localMapFinger);
fParisData->SetParisQShort(0);
fParisData->SetParisQLong(0);
fParisData->SetParisTheta(0);
fParisData->SetParisPhi(0);
fParisData->SetParisQShortCond(0) ;
fParisData->SetParisQLongCond(0) ;
fParisData->SetParisQCompton(0) ;
}
return result;
}
......
......@@ -34,8 +34,8 @@ class TParis : public TDetector {
int prevBoard, prevChannel,tag;
double prevQ,prevQ2;
float ClusterAddB[9],ClusterCalo[9],Beta;
int BoardCounter[5][16];
int MapFinger[5][16];
int BoardCounter[6][16];
int MapFinger[6][16];
TVector3 v1[80];
TH1F * fMyHistoParisQShort[80];
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment