133 PndLmdMCPoint*
point = NULL;
137 std::cout<<
"the Nr of points is"<<nPoints<<std::endl;
142 for(Int_t iPoint = 0;iPoint<nPoints;iPoint++)
146 std::cout<<
"No point !"<<std::endl;
155 TVector3 posInL =
fGeoH->MasterToLocalId(point->GetEntryPoint(),point->GetDetName());
156 TVector3 posOutL =
fGeoH->MasterToLocalId(point->GetExitPoint(),point->GetDetName());
159 std::cout<<
"the Entry point in local coordinate is "<<posInL.X()<<
","<<posInL.Y()<<
","<<posInL.Z()<<std::endl;
160 std::cout<<
"the Exit point in local coordinate is "<<posOutL.X()<<
","<<posOutL.Y()<<
","<<posOutL.Z()<<std::endl;
162 Double_t eLoss = point->GetEnergyLoss();
163 std::cout<<
"the eLoss of this point is: "<<eLoss<<endl;
165 TVector3
pos,pos1 = posInL + posOutL;
166 pos.SetXYZ(pos1.X()/2.,pos1.Y()/2.,pos1.Z()/2.);
173 std::vector<PndLmdStrips> leftStrips =
175 posOutL.X(),posOutL.Y(),posOutL.Z(),
177 if(leftStrips.size()!=0){
178 for(std::vector<PndLmdStrips>::const_iterator kit=leftStrips.begin();kit!=leftStrips.end();++kit)
180 AddDigi(iStrip,iPoint,kLMDHitsStrip,point->GetDetName(),
187 cout<<
"the iPoint is: "<<iPoint<<endl;
188 cout<<
"the iStrip is :"<<iStrip-1<<endl;
189 cout<<
"the channel is :"<<chan1<<endl;
190 cout<<
"the information of digis: "<<point->GetDetName()<<
","<<kit->GetCharge()<<endl;
194 }
else std::cout<<
"the left segment is empty"<<std::endl;
197 std::vector<PndLmdStrips> rightStrips =
199 posOutL.X(),posOutL.Y(),posOutL.Z(),
203 if(rightStrips.size()!=0){
204 for(std::vector<PndLmdStrips>::const_iterator kit=rightStrips.begin();
205 kit!=rightStrips.end();++kit){
207 AddDigi(iStrip,iPoint,kLMDHitsStrip,point->GetDetName(),
222 cout<<
"the iPoint is: "<<iPoint<<endl;
223 cout<<
"the iStrip is :"<<iStrip-1<<endl;
224 cout<<
"the channel is :"<<chan2<<endl;
225 cout<<
"the information of digis: "<<point->GetDetName()<<
","<<kit->GetCharge()<<endl;
229 }
else std::cout<<
"the right segment is empty"<<std::endl;
236 std::cout<<
"-I- PndLmdDigiProducer: "<<nPoints<<
" PndLmdMCPoint, "
237 <<iStrip<<
" PndLmdDigis"<<std::endl<<std::endl;
PndLmdCalStrip * fCurrentStripCalLeft
PndLmdDigiPara * fCurrentDigiPar
std::vector< PndLmdStrips > DigiStripFromPoint(Double_t inx, Double_t iny, Double_t inz, Double_t outx, Double_t outy, Double_t outz, Double_t eloss)
TClonesArray * fPointArray
PndLmdGeoHandling * fGeoH
void AddDigi(Int_t &iStrip, Int_t iPoint, Int_t detID, TString detName, Int_t fe, Int_t channel, Double_t charge)
PndLmdCalStrip * fCurrentStripCalRight
Int_t CalFeFromStrip(Int_t stripNr)
PndLmdDigiPara * fDigiParTrap
PndLmdCalStrip * fStripCalTrapLeft
Int_t GetNrFeChannels() const
Int_t CalChannelFromStrip(Int_t stripNr)
Int_t GetNrLeftFe() const
TClonesArray * fStripArray
PndLmdCalStrip * fStripCalTrapRight