ClassImp(AliTOFClusterFinder)
AliTOFClusterFinder::AliTOFClusterFinder(AliTOFcalib *calib):
- TNamed("AliTOFClusterFinder",""),
+ TTask("AliTOFClusterFinder",""),
fRunLoader(0),
fTOFLoader(0),
fTreeD(0),
fDigits(new TClonesArray("AliTOFdigit", 4000)),
fRecPoints(new TClonesArray("AliTOFcluster", 4000)),
fNumberOfTofClusters(0),
+ fNumberOfTofTrgPads(0),
fVerbose(0),
fDecoderVersion(0),
fTOFcalib(calib),
//______________________________________________________________________________
AliTOFClusterFinder::AliTOFClusterFinder(AliRunLoader* runLoader, AliTOFcalib *calib):
- TNamed("AliTOFClusterFinder",""),
+ TTask("AliTOFClusterFinder",""),
fRunLoader(runLoader),
fTOFLoader(runLoader->GetLoader("TOFLoader")),
fTreeD(0),
fDigits(new TClonesArray("AliTOFdigit", 4000)),
fRecPoints(new TClonesArray("AliTOFcluster", 4000)),
fNumberOfTofClusters(0),
+ fNumberOfTofTrgPads(0),
fVerbose(0),
fDecoderVersion(0),
fTOFcalib(calib),
//------------------------------------------------------------------------
AliTOFClusterFinder::AliTOFClusterFinder(const AliTOFClusterFinder &source) :
- TNamed(source),
+ TTask(source),
fRunLoader(0),
fTOFLoader(0),
fTreeD(0),
fDigits(source.fDigits),
fRecPoints(source.fRecPoints),
fNumberOfTofClusters(0),
+ fNumberOfTofTrgPads(0),
fVerbose(0),
fDecoderVersion(source.fDecoderVersion),
fTOFcalib(source.fTOFcalib),
if (this == &source)
return *this;
- TNamed::operator=(source);
+ TTask::operator=(source);
fDigits=source.fDigits;
fRecPoints=source.fRecPoints;
fVerbose=source.fVerbose;
fNumberOfTofClusters=0;
}
+ fNumberOfTofTrgPads=0;
+
}
//______________________________________________________________________________
FillRecPoint();
fTreeR->Fill();
- ResetRecpoint();
+// ResetRecpoint();
fTOFLoader = fRunLoader->GetLoader("TOFLoader");
fTOFLoader->WriteRecPoints("OVERWRITE");
FillRecPoint();
clusterTree->Fill();
- ResetRecpoint();
+// ResetRecpoint();
AliDebug(1,Form("Execution time to read TOF digits and to write TOF clusters : R:%.4fs C:%.4fs",
stopwatch.RealTime(),stopwatch.CpuTime()));
TClonesArray * clonesRawData;
Int_t dummy = -1;
- Int_t detectorIndex[5];
- Int_t parTOF[7];
+ Int_t detectorIndex[5]={-1,-1,-1,-1,-1};
+ Int_t parTOF[7]={-1,-1,-1,-1,-1,-1,-1};
ofstream ftxt;
if (fVerbose==2) ftxt.open("TOFdigitsRead.txt",ios::app);
ftxt << " " << tofRawDatum->GetTDCchannel();
}
+ if ( tofRawDatum->GetTRM()==3 &&
+ (tofRawDatum->GetTDC()> 11 && tofRawDatum->GetTDC()< 15) ) FillTOFtriggerMap(indexDDL, tofRawDatum);
+
+ for (Int_t aa=0; aa<5; aa++) detectorIndex[aa] = -1;
+
fTOFRawStream.EquipmentId2VolumeId(indexDDL, tofRawDatum->GetTRM(), tofRawDatum->GetTRMchain(),
tofRawDatum->GetTDC(), tofRawDatum->GetTDCchannel(), detectorIndex);
dummy = detectorIndex[3];
clustersTree->Fill();
- ResetRecpoint();
+// ResetRecpoint();
AliDebug(1, Form("Execution time to read TOF raw data and to write TOF clusters : R:%.4fs C:%.4fs",
stopwatch.RealTime(),stopwatch.CpuTime()));
FillRecPoint();
fTreeR->Fill();
- ResetRecpoint();
+// ResetRecpoint();
fTOFLoader = fRunLoader->GetLoader("TOFLoader");
fTOFLoader->WriteRecPoints("OVERWRITE");
tdcCorr=(Int_t)(timeCorr/AliTOFGeometry::TdcBinWidth()); //the corrected time (tdc counts)
fTofClusters[ii]->SetTDC(tdcCorr);
+
} // loop on clusters
}
tdcBin = TMath::Nint(time / AliTOFGeometry::TdcBinWidth()); //the corrected time (tdc counts)
fTofClusters[ii]->SetTDC(tdcBin);
+ // noferini
+ Float_t pos[3];
+ AliTOFGeometry::GetPosPar(detectorIndex, pos);
+ Float_t length = 0.;
+ for (Int_t ic = 0; ic < 3; ic++) length += pos[ic] * pos[ic];
+ length = TMath::Sqrt(length);
+ Float_t timealligned = tdcBin*24.4 - length * 0.0333564095198152043; // subtract the minimal time in
+
+ if(timealligned > -1000 && timealligned < 24000 && fTOFcalib->IsChannelEnabled(index)){
+ fNumberOfTofTrgPads++;
+ }
+
} // loop on clusters
}
//
fNumberOfTofClusters = 0;
+ fNumberOfTofTrgPads = 0;
if (fRecPoints) fRecPoints->Clear();
}
return;
}
+//-------------------------------------------------------------------------
+void AliTOFClusterFinder::FillTOFtriggerMap(Int_t iDDL, AliTOFrawData *tofRawDatum)
+{
+
+ /* get cluster info */
+ //Int_t trm = tofRawDatum->GetTRM();
+ // Int_t tdc = tofRawDatum->GetTDC();
+// Int_t tdc_ch = tofRawDatum->GetTDCchannel();
+ Int_t chain = tofRawDatum->GetTRMchain();
+ Int_t l0l1 = tofRawDatum->GetL0L1Latency();
+ Double_t corr = l0l1 * AliTOFGeometry::BunchCrossingBinWidth();
+ AliTOFCTPLatency *ctpLatencyObj = fTOFcalib->GetCTPLatency();
+ Float_t ctpLatency = ctpLatencyObj->GetCTPLatency();
+ corr += ctpLatency;
+
+ Double_t timeTOF=tofRawDatum->GetTOF()*AliTOFGeometry::TdcBinWidth();
+ timeTOF-=corr;
+ //Int_t timeRaw_bc = Int_t(timeTOF/1000/24.4); // per ora non usata
+
+ //Int_t timeRaw_bc = Int_t((tofRawDatum->GetTOF()*AliTOFGeometry::TdcBinWidth())/1000/24.4); // per ora non usata
+
+ /*
+ const Int_t crate_CTTM[72] = { 0, 1, 37, 36, 2, 3, 39, 38, 4, 5,
+ 41, 40, 6, 7, 43, 42, 8, 9, 45, 44,
+ 10, 11, 47, 46, 12, 13, 49, 48, 14, 15,
+ 51, 50, 16, 17, 53, 52, 18, 19, 55, 54,
+ 20, 21, 57, 56, 22, 23, 59, 58, 24, 25,
+ 61, 60, 26, 27, 63, 62, 28, 29, 65, 64,
+ 30, 31, 67, 66, 32, 33, 69, 68, 34, 35,
+ 71, 70};
+ */
+
+ Int_t cttmCrate=-1;
+// Int_t cttmBit = tdc_ch + (tdc-12)*AliTOFGeometry::NCh();
+ switch(iDDL%AliTOFGeometry::NDDL()){
+ case 1:
+ cttmCrate=1;
+ break;
+ case 3:
+ cttmCrate=36;
+ break;
+ default:
+ break;
+ }
+ cttmCrate+=2*(Int_t)(iDDL/AliTOFGeometry::NDDL());
+ if(chain==0) {
+ if (iDDL<36) cttmCrate--;
+ else cttmCrate++;
+ }
+
+
+
+
+}
+
// Task: Transform digits/raw data to TOF Clusters, to fill TOF RecPoints
// and feed TOF tracking
-#include "TNamed.h"
+#include "TTask.h"
#include "AliTOFRawStream.h"
class AliLoader;
class AliRunLoader;
class AliRawReader;
+class AliTOFrawData;
class AliTOFGeometry;
class AliTOFcluster;
class AliTOFcalib;
-class AliTOFClusterFinder : public TNamed
+class AliTOFClusterFinder : public TTask
{
enum {kTofMaxCluster=77777}; //maximal number of the TOF clusters
Int_t GetDecoderVersion() const {return fDecoderVersion;} // To get the decoder version
UShort_t GetClusterVolIndex(const Int_t * const ind) const; //Volume Id getter
void GetClusterPars(Int_t *ind, Double_t *pos, Double_t *cov) const; //cluster par getter
+ Int_t GetNumberOfTOFclusters() const {return fNumberOfTofClusters;} // number of clusters getter
+ Int_t GetNumberOfTOFtrgPads() const {return fNumberOfTofTrgPads;} // number of pads getter
protected:
AliRunLoader *fRunLoader; // Pointer to Run Loader
TClonesArray *fRecPoints; // List of reconstructed points
Int_t fNumberOfTofClusters; // Number of TOF Clusters
+ Int_t fNumberOfTofTrgPads; // Number of TOF trigger pads
private:
+ void FillTOFtriggerMap(Int_t iDDL, AliTOFrawData *tofRawDatum);
//Int_t InsertCluster(Int_t *aa, Double_t *bb); // Fills TofClusters Array
//Int_t InsertCluster(Int_t *aa, Double_t *bb, Int_t *cc, Int_t d); // Fills TofClusters Array
AliTOFcalib *fTOFcalib; // pointer to the TOF calibration info
AliTOFRawStream fTOFRawStream; // AliTOFRawStream variable
- ClassDef(AliTOFClusterFinder,7) // To run TOF clustering
+ ClassDef(AliTOFClusterFinder,8) // To run TOF clustering
};
#endif
//_____________________________________________________________________________
AliTOFClusterFinderV1::AliTOFClusterFinderV1(AliTOFcalib *calib):
- TNamed("AliTOFClusterFinderV1",""),
+ TTask("AliTOFClusterFinderV1",""),
fRunLoader(0),
fDigits(new TClonesArray("AliTOFdigit", 4000)),
fRecPoints(new TClonesArray("AliTOFcluster", 4000)),
fNumberOfTofClusters(0),
fNumberOfTofDigits(0),
+ fNumberOfTofTrgPads(0),
fkRecoParam(0),//AliTOFReconstructor::GetRecoParam()),
fMaxDeltaTime(0),//fkRecoParam->GetMaxDeltaTime()),
fVerbose(0),
//_____________________________________________________________________________
AliTOFClusterFinderV1::AliTOFClusterFinderV1(AliRunLoader* runLoader, AliTOFcalib *calib):
- TNamed("AliTOFClusterFinderV1",""),
+ TTask("AliTOFClusterFinderV1",""),
fRunLoader(runLoader),
fDigits(new TClonesArray("AliTOFdigit", 4000)),
fRecPoints(new TClonesArray("AliTOFcluster", 4000)),
fNumberOfTofClusters(0),
fNumberOfTofDigits(0),
+ fNumberOfTofTrgPads(0),
fkRecoParam(0),//AliTOFReconstructor::GetRecoParam()),
fMaxDeltaTime(0),//fkRecoParam->GetMaxDeltaTime()),
fVerbose(0),
//_____________________________________________________________________________
AliTOFClusterFinderV1::AliTOFClusterFinderV1(const AliTOFClusterFinderV1 &source)
- :TNamed(source),
+ :TTask(source),
fRunLoader(0),
fDigits(source.fDigits),
fRecPoints(source.fRecPoints),
fNumberOfTofClusters(0),
fNumberOfTofDigits(0),
+ fNumberOfTofTrgPads(0),
fkRecoParam(0),//AliTOFReconstructor::GetRecoParam()),
fMaxDeltaTime(0),//fkRecoParam->GetMaxDeltaTime()),
fVerbose(0),
for (Int_t ii=0; ii<kTofMaxCluster; ii++) fTofClusters[ii]=source.fTofClusters[ii];
fDigits=source.fDigits;
fRecPoints=source.fRecPoints;
+ fNumberOfTofClusters=source.fNumberOfTofClusters;
+ fNumberOfTofTrgPads=source.fNumberOfTofTrgPads;
+ fNumberOfTofDigits=source.fNumberOfTofDigits;
fVerbose=source.fVerbose;
fDecoderVersion=source.fDecoderVersion;
fTOFcalib=source.fTOFcalib;
Int_t inholes = 0;
+ ResetRecpoint();
+
fDigits->Clear();
TClonesArray &aDigits = *fDigits;
AliDebug(1,Form("Number of found clusters: %d", fNumberOfTofClusters));
- ResetRecpoint();
+// ResetRecpoint();
fTOFdigitMap->Clear();
TStopwatch stopwatch;
stopwatch.Start();
+ ResetRecpoint();
AliDebug(2, "TreeD re-creation");
//TTree *digitsTree = new TTree();
AliDebug(1,Form("Number of found clusters: %d", fNumberOfTofClusters));
- ResetRecpoint();
+// ResetRecpoint();
fTOFdigitMap->Clear();
digit[2] = tofRawDatum->GetTOT();
digit[3] = -1;//tofRawDatum->GetTOF(); //tofND
+ // noferini
+ Float_t pos[3];
+ AliTOFGeometry::GetPosPar(detectorIndex, pos);
+ Float_t length = 0.;
+ for (Int_t ic = 0; ic < 3; ic++) length += pos[ic] * pos[ic];
+ length = TMath::Sqrt(length);
+ Float_t timealligned = tdcCorr*24.4 - length * 0.0333564095198152043; // subtract the minimal time in
+
+ if(status && timealligned > -1000 && timealligned < 24000){
+ fNumberOfTofTrgPads++;
+ }
+
dummy = detectorIndex[3];
detectorIndex[3] = detectorIndex[4];//padx
detectorIndex[4] = dummy;//padz
last = fDigits->GetEntriesFast();
new (aDigits[last]) AliTOFdigit(tracks, detectorIndex, digit);
if (status) fTOFdigitMap->AddDigit(detectorIndex, last);
+
if (fVerbose==2) {
if (indexDDL<10) ftxt << " " << indexDDL;
//
fNumberOfTofClusters = 0;
+ fNumberOfTofTrgPads = 0;
if (fRecPoints) fRecPoints->Clear();
}
//
fNumberOfTofDigits = 0;
+ fNumberOfTofTrgPads = 0;
if (fDigits) fDigits->Clear();
}
// and feed TOF tracking
#include "TObject.h"
-#include "TNamed.h"
+#include "TTask.h"
#include "AliTOFGeometry.h"
#include "AliTOFRawStream.h"
};
-class AliTOFClusterFinderV1 : public TNamed
+class AliTOFClusterFinderV1 : public TTask
{
enum {kTofMaxCluster=77777}; //maximal number of the TOF clusters
void SetMaxDeltaTime(Int_t a) {fMaxDeltaTime = a;}; // to set deltaTime [bin number]
void SetMaxDeltaTime(Float_t a) {fMaxDeltaTime = (Int_t)(a/AliTOFGeometry::TdcBinWidth());}; // to set deltaTime [ps]
Int_t GetMaxDeltaTime() const {return fMaxDeltaTime;};
+ Int_t GetNumberOfTOFclusters() const {return fNumberOfTofClusters;}
+ Int_t GetNumberOfTOFtrgPads() const {return fNumberOfTofTrgPads;}
void SetCalibrateFlag(Bool_t dummy) {fCalibrateTOFtimes = dummy;};
TClonesArray *fRecPoints; // List of reconstructed points
Int_t fNumberOfTofClusters; // Number of TOF Clusters
Int_t fNumberOfTofDigits; // Number of TOF Digits
+ Int_t fNumberOfTofTrgPads; // Number of TOF trigger pads
private:
Bool_t fCalibrateTOFtimes; // used for check
- ClassDef(AliTOFClusterFinderV1,5) // To run TOF clustering
+ ClassDef(AliTOFClusterFinderV1,6) // To run TOF clustering
};
#endif
const Float_t AliTOFGeometry::fgkPhiSec= 20;//sector Phi width (deg)
+Bool_t AliTOFGeometry::fgHoles = 1;//logical for geometry version (w/wo holes)
+
const Float_t AliTOFGeometry::fgkTdcBin = 24.4; // time-of-flight bin width [ps]
const Float_t AliTOFGeometry::fgkToTBin = 48.8; // time-over-threshold bin width [ps]
const Float_t AliTOFGeometry::fgkBunchCrossingBin = fgkTdcBin * 1024; // bunch-crossing bin width [ps]
};
*/
//_____________________________________________________________________________
-AliTOFGeometry::AliTOFGeometry():
- fHoles(1)
+AliTOFGeometry::AliTOFGeometry()
{
//
// AliTOFGeometry default constructor
TGeoManager::Import("geometry.root");
}
//_____________________________________________________________________________
-void AliTOFGeometry::GetPosPar(Int_t *det, Float_t *pos) const
+void AliTOFGeometry::GetPosPar(Int_t *det, Float_t *pos)
{
//
// Returns space point coor (x,y,z) (cm) for Detector
}
//_____________________________________________________________________________
-void AliTOFGeometry::GetDetID( Float_t *pos, Int_t *det) const
+void AliTOFGeometry::GetDetID( Float_t *pos, Int_t *det)
{
//
// Returns Detector Indices (iSect,iPlate,iStrip,iPadX,iPadZ)
if( iplate==4) icopy=istrip+NStripC()+2*NStripB()+NStripA();
icopy++;
snprintf(string2,kSize,"FTOA_0/FLTA_0/FSTR_%i",icopy);
- if(fHoles && (sector==13 || sector==14 || sector==15)){
+ if(fgHoles && (sector==13 || sector==14 || sector==15)){
if(iplate<2) snprintf(string2,kSize,"FTOB_0/FLTB_0/FSTR_%i",icopy);
if(iplate>2) snprintf(string2,kSize,"FTOC_0/FLTC_0/FSTR_%i",icopy);
}
if(plate==4) icopy=strip+NStripC()+2*NStripB()+NStripA();
icopy++;
snprintf(string2,kSize,"FTOA_0/FLTA_0/FSTR_%i",icopy);
- if(fHoles && (sector==13 || sector==14 || sector==15)){
+ if(fgHoles && (sector==13 || sector==14 || sector==15)){
if(plate<2) snprintf(string2,kSize,"FTOB_0/FLTB_0/FSTR_%i",icopy);
if(plate>2) snprintf(string2,kSize,"FTOC_0/FLTC_0/FSTR_%i",icopy);
}
pos[2]=tr[2];
}
//_____________________________________________________________________________
-Int_t AliTOFGeometry::GetPlate(const Float_t * const pos) const
+Int_t AliTOFGeometry::GetPlate(const Float_t * const pos)
{
//
// Returns the Plate index
}
//_____________________________________________________________________________
-Int_t AliTOFGeometry::GetSector(const Float_t * const pos) const
+Int_t AliTOFGeometry::GetSector(const Float_t * const pos)
{
//
// Returns the Sector index
}
//_____________________________________________________________________________
-Int_t AliTOFGeometry::GetStrip(const Float_t * const pos) const
+Int_t AliTOFGeometry::GetStrip(const Float_t * const pos)
{
//
// Returns the Strip index
Float_t posLocal[3];
for (Int_t ii=0; ii<3; ii++) posLocal[ii] = pos[ii];
- AliDebug(1,Form(" posLocal[0] = %f, posLocal[1] = %f, posLocal[2] = %f ",
- posLocal[0],posLocal[1],posLocal[2]));
+// AliDebug(1,Form(" posLocal[0] = %f, posLocal[1] = %f, posLocal[2] = %f ",
+// posLocal[0],posLocal[1],posLocal[2]));
Int_t isector = GetSector(posLocal);
if(isector == -1){
90., (isector+0.5)*fgkPhiSec
};
Rotation(posLocal,angles);
- AliDebug(1,Form(" posLocal[0] = %f, posLocal[1] = %f, posLocal[2] = %f ",
- posLocal[0],posLocal[1],posLocal[2]));
+ // AliDebug(1,Form(" posLocal[0] = %f, posLocal[1] = %f, posLocal[2] = %f ",
+ // posLocal[0],posLocal[1],posLocal[2]));
Float_t step[3] = {0., 0., (fgkRmax+fgkRmin)*0.5};
Translation(posLocal,step);
- AliDebug(1,Form(" posLocal[0] = %f, posLocal[1] = %f, posLocal[2] = %f ",
- posLocal[0],posLocal[1],posLocal[2]));
+ // AliDebug(1,Form(" posLocal[0] = %f, posLocal[1] = %f, posLocal[2] = %f ",
+ // posLocal[0],posLocal[1],posLocal[2]));
// B071/B074/B075 = BTO1/2/3 reference frame -> FTOA = FLTA reference frame
angles[0] = 90.;
angles[5] =270.;
Rotation(posLocal,angles);
- AliDebug(1,Form(" posLocal[0] = %f, posLocal[1] = %f, posLocal[2] = %f ",
- posLocal[0],posLocal[1],posLocal[2]));
+ // AliDebug(1,Form(" posLocal[0] = %f, posLocal[1] = %f, posLocal[2] = %f ",
+ // posLocal[0],posLocal[1],posLocal[2]));
// FTOA/B/C = FLTA/B/C reference frame -> FSTR reference frame
Int_t totStrip=0;
angles[5] = 270.;
}
Rotation(posLoc2,angles);
- AliDebug(1,Form(" strip %2d: posLoc2[0] = %f, posLoc2[1] = %f, posLoc2[2] = %f ",
- istrip, posLoc2[0],posLoc2[1],posLoc2[2]));
+ // AliDebug(1,Form(" strip %2d: posLoc2[0] = %f, posLoc2[1] = %f, posLoc2[2] = %f ",
+ // istrip, posLoc2[0],posLoc2[1],posLoc2[2]));
if ((TMath::Abs(posLoc2[0])<=klstripx*0.5) &&
(TMath::Abs(posLoc2[1])<=khstripy*0.5) &&
iStrip = istrip;
totStrip++;
for (Int_t jj=0; jj<3; jj++) posLocal[jj]=posLoc2[jj];
- AliDebug(2,Form(" posLocal[0] = %f, posLocal[1] = %f, posLocal[2] = %f ",
- posLocal[0],posLocal[1],posLocal[2]));
+ // AliDebug(2,Form(" posLocal[0] = %f, posLocal[1] = %f, posLocal[2] = %f ",
+ // posLocal[0],posLocal[1],posLocal[2]));
- AliDebug(2,Form(" GetAngles(%1i,%2i) = %f, pos[0] = %f, pos[1] = %f, pos[2] = %f",
- iplate, istrip, GetAngles(iplate,istrip), pos[0], pos[1], pos[2]));
+ // AliDebug(2,Form(" GetAngles(%1i,%2i) = %f, pos[0] = %f, pos[1] = %f, pos[2] = %f",
+ // iplate, istrip, GetAngles(iplate,istrip), pos[0], pos[1], pos[2]));
break;
}
- if (totStrip>1) AliInfo(Form("total strip number found %2i",totStrip));
+ // if (totStrip>1) AliInfo(Form("total strip number found %2i",totStrip));
}
}
//_____________________________________________________________________________
-Int_t AliTOFGeometry::GetPadZ(const Float_t * const pos) const
+Int_t AliTOFGeometry::GetPadZ(const Float_t * const pos)
{
//
// Returns the Pad index along Z
}
//_____________________________________________________________________________
-Int_t AliTOFGeometry::GetPadX(const Float_t * const pos) const
+Int_t AliTOFGeometry::GetPadX(const Float_t * const pos)
{
//
// Returns the Pad index along X
}
//_____________________________________________________________________________
-Float_t AliTOFGeometry::GetX(const Int_t * const det) const
+Float_t AliTOFGeometry::GetX(const Int_t * const det)
{
//
// Returns X coordinate (cm)
}
//_____________________________________________________________________________
-Float_t AliTOFGeometry::GetY(const Int_t * const det) const
+Float_t AliTOFGeometry::GetY(const Int_t * const det)
{
//
// Returns Y coordinate (cm)
}
//_____________________________________________________________________________
-Float_t AliTOFGeometry::GetZ(const Int_t * const det) const
+Float_t AliTOFGeometry::GetZ(const Int_t * const det)
{
//
// Returns Z coordinate (cm)
}
//_____________________________________________________________________________
-void AliTOFGeometry::Translation(Float_t *xyz, Float_t translationVector[3]) const
+void AliTOFGeometry::Translation(Float_t *xyz, Float_t translationVector[3])
{
//
// Return the vector xyz translated by translationVector vector
}
//_____________________________________________________________________________
-void AliTOFGeometry::Rotation(Float_t *xyz, Double_t rotationAngles[6]) const
+void AliTOFGeometry::Rotation(Float_t *xyz, Double_t rotationAngles[6])
{
//
// Return the vector xyz rotated according to the rotationAngles angles
}
//_____________________________________________________________________________
-void AliTOFGeometry::InverseRotation(Float_t *xyz, Double_t rotationAngles[6]) const
+void AliTOFGeometry::InverseRotation(Float_t *xyz, Double_t rotationAngles[6])
{
//
// Rotates the vector xyz acordint to the rotationAngles
}
//-------------------------------------------------------------------------
-UShort_t AliTOFGeometry::GetAliSensVolIndex(Int_t isector, Int_t iplate, Int_t istrip) const
+UShort_t AliTOFGeometry::GetAliSensVolIndex(Int_t isector, Int_t iplate, Int_t istrip)
{
//
// Get the index of the TOF alignable volume in the AliGeomManager order.
static Float_t SlewTOTMax() {return fgkSlewTOTMax;};
virtual void ImportGeometry();
- virtual void SetHoles(Bool_t holes) {fHoles = holes;};
- virtual Bool_t GetHoles() const {return fHoles;};
+ virtual void SetHoles(Bool_t holes) {fgHoles = holes;};
+ static Bool_t GetHoles() {return fgHoles;};
virtual Float_t DistanceToPadPar(Int_t *det, const Float_t * const pos, Float_t *dist3d=0) const;
virtual Bool_t IsInsideThePadPar(Int_t *det, const Float_t * const pos) const;
virtual Bool_t IsInsideThePad(TGeoHMatrix *mat, const Float_t * const pos, Float_t *dist3d=0) const;
- virtual void GetVolumePath(const Int_t * const ind, Char_t *path );
- virtual void GetVolumePath(Int_t sector, Char_t *path );
- virtual void GetVolumePath(Int_t sector, Int_t plate, Int_t strip, Char_t *path );
- virtual void GetPos(Int_t *det,Float_t *pos);
- virtual void GetPosPar(Int_t *det,Float_t *pos) const;
- virtual void GetDetID(Float_t *pos,Int_t *det) const;
- virtual Int_t GetPlate(const Float_t * const pos) const;
- virtual Int_t GetStrip(const Float_t * const pos) const;
- virtual Int_t GetSector(const Float_t * const pos) const;
- virtual Int_t GetPadX(const Float_t * const pos) const;
- virtual Int_t GetPadZ(const Float_t * const pos) const;
- virtual Float_t GetX(const Int_t * const det) const ;
- virtual Float_t GetY(const Int_t * const det) const ;
- virtual Float_t GetZ(const Int_t * const det) const ;
+ static void GetVolumePath(const Int_t * const ind, Char_t *path );
+ static void GetVolumePath(Int_t sector, Char_t *path );
+ static void GetVolumePath(Int_t sector, Int_t plate, Int_t strip, Char_t *path );
+ static void GetPos(Int_t *det,Float_t *pos);
+ static void GetPosPar(Int_t *det,Float_t *pos);
+ static void GetDetID(Float_t *pos,Int_t *det);
+ static Int_t GetPlate(const Float_t * const pos);
+ static Int_t GetStrip(const Float_t * const pos);
+ static Int_t GetSector(const Float_t * const pos);
+ static Int_t GetPadX(const Float_t * const pos);
+ static Int_t GetPadZ(const Float_t * const pos);
+ static Float_t GetX(const Int_t * const det);
+ static Float_t GetY(const Int_t * const det);
+ static Float_t GetZ(const Int_t * const det);
virtual void DetToStripRF(Int_t nPadX, Int_t nPadZ,
Float_t &x, Float_t &z) const;
virtual void DetToSectorRF(Int_t vol[5], Double_t coord[4][3]);
- virtual Float_t GetPadDx(const Float_t * const pos);
- virtual Float_t GetPadDy(const Float_t * const pos);
- virtual Float_t GetPadDz(const Float_t * const pos);
- virtual void Translation(Float_t *xyz, Float_t translationVector[3]) const;
- virtual void Rotation(Float_t *xyz, Double_t rotationAngles[6]) const;
- virtual void InverseRotation(Float_t *xyz, Double_t rotationAngles[6]) const;
+ static Float_t GetPadDx(const Float_t * const pos);
+ static Float_t GetPadDy(const Float_t * const pos);
+ static Float_t GetPadDz(const Float_t * const pos);
+ static void Translation(Float_t *xyz, Float_t translationVector[3]);
+ static void Rotation(Float_t *xyz, Double_t rotationAngles[6]);
+ static void InverseRotation(Float_t *xyz, Double_t rotationAngles[6]);
static Float_t GetAngles(Int_t iplate, Int_t istrip) {return fgkAngles[iplate][istrip];};
static Float_t GetHeights(Int_t iplate, Int_t istrip) {return fgkHeights[iplate][istrip];};
static Int_t GetIndex(const Int_t * const detId); // Get channel index from det Id (for calibration mainly)
static void GetVolumeIndices(Int_t index, Int_t *detId); // Get volume index from channel index
- UShort_t GetAliSensVolIndex(Int_t sec, Int_t pla, Int_t str) const; // Get the index of the TOF alignable volume in the AliGeomManager order
+ static UShort_t GetAliSensVolIndex(Int_t sec, Int_t pla, Int_t str); // Get the index of the TOF alignable volume in the AliGeomManager order
static Int_t GetStripNumber(Int_t isector, Int_t iplate, Int_t istrip); // Get the serial number of the TOF alignable volume, i.e. the TOF strip
static Int_t GetStripNumberPerSM(Int_t iplate, Int_t istrip); // Get the serial number of the TOF strip in a TOF SM
static void GetStripAndModule(Int_t iStripPerSM, Int_t &iplate, Int_t &istrip); // Return the module and strip per module corresponding to the strip number per SM
static const Float_t fgkPhiSec; //sector Phi width (deg)
- Bool_t fHoles; //logical for geometry version (w/wo holes)
+ static Bool_t fgHoles; //logical for geometry version (w/wo holes)
static const Float_t fgkAngles[kNPlates][kMaxNstrip]; //Strip Tilt Angles
static const Float_t fgkHeights[kNPlates][kMaxNstrip]; //Strip heights
static const Float_t fgkSlewTOTMin; // min TOT for slewing correction [ns]
static const Float_t fgkSlewTOTMax; // max TOT for slewing correction [ns]
- ClassDef(AliTOFGeometry,8) // TOF Geometry base class
+ ClassDef(AliTOFGeometry,9) // TOF Geometry base class
};
#endif
#include "AliTOFtrackerV1.h"
#include "AliTOFT0maker.h"
#include "AliTOFReconstructor.h"
+#include "AliTOFTriggerMask.h"
+#include "AliTOFTrigger.h"
class TTree;
ClassImp(AliTOFReconstructor)
//____________________________________________________________________
-AliTOFReconstructor::AliTOFReconstructor()
- : AliReconstructor(),
- fTOFcalib(0)/*,
- fTOFT0maker(0)*/
+AliTOFReconstructor::AliTOFReconstructor() :
+ AliReconstructor(),
+ fTOFcalib(0),
+ /*fTOFT0maker(0),*/
+ fNumberOfTofClusters(0),
+ fNumberOfTofTrgPads(0),
+ fClusterFinder(0),
+ fClusterFinderV1(0)
{
//
// ctor
//Retrieving the TOF calibration info
fTOFcalib = new AliTOFcalib();
fTOFcalib->Init();
+ fClusterFinder = new AliTOFClusterFinder(fTOFcalib);
+ fClusterFinderV1 = new AliTOFClusterFinderV1(fTOFcalib);
+
+ TString optionString = GetOption();
+ if (optionString.Contains("DecoderV0")) {
+ fClusterFinder->SetDecoderVersion(0);
+ fClusterFinderV1->SetDecoderVersion(0);
+ }
+ else if (optionString.Contains("DecoderV1")) {
+ fClusterFinder->SetDecoderVersion(1);
+ fClusterFinderV1->SetDecoderVersion(1);
+ }
+ else {
+ fClusterFinder->SetDecoderVersion(2);
+ fClusterFinderV1->SetDecoderVersion(2);
+ }
+
+
#if 0
fTOFcalib->CreateCalObjects();
delete fTOFcalib;
//delete fTOFT0maker;
+ fNumberOfTofClusters = 0;
+ fNumberOfTofTrgPads = 0;
+ delete fClusterFinder;
+ delete fClusterFinderV1;
}
//_____________________________________________________________________________
// use V1 cluster finder if selected
if (optionString.Contains("ClusterizerV1")) {
- static AliTOFClusterFinderV1 tofClus(fTOFcalib);
+ /*
+ AliTOFClusterFinderV1 tofClus(fTOFcalib);
// decoder version option
if (optionString.Contains("DecoderV0")) {
else {
tofClus.SetDecoderVersion(2);
}
-
+
tofClus.Digits2RecPoints(rawReader, clustersTree);
+ */
+
+ fClusterFinderV1->Digits2RecPoints(rawReader, clustersTree);
}
else {
- static AliTOFClusterFinder tofClus(fTOFcalib);
-
+ /*
+ AliTOFClusterFinder tofClus(fTOFcalib);
+
// decoder version option
if (optionString.Contains("DecoderV0")) {
tofClus.SetDecoderVersion(0);
}
tofClus.Digits2RecPoints(rawReader, clustersTree);
- }
+ */
+
+ fClusterFinder->Digits2RecPoints(rawReader, clustersTree);
+ }
+ AliTOFTrigger::PrepareTOFMapFromRaw(rawReader,13600); // 13600 +/- 400 is the value to select the richt bunch crossing (in future from OCDB)
}
//_____________________________________________________________________________
TString optionString = GetOption();
// use V1 cluster finder if selected
if (optionString.Contains("ClusterizerV1")) {
- static AliTOFClusterFinderV1 tofClus(fTOFcalib);
+ /*
+ AliTOFClusterFinderV1 tofClus(fTOFcalib);
// decoder version option
if (optionString.Contains("DecoderV0")) {
}
tofClus.Digits2RecPoints(digitsTree, clustersTree);
+ */
+ fClusterFinderV1->Digits2RecPoints(digitsTree, clustersTree);
}
else {
- static AliTOFClusterFinder tofClus(fTOFcalib);
+ /*
+ AliTOFClusterFinder tofClus(fTOFcalib);
// decoder version option
if (optionString.Contains("DecoderV0")) {
}
tofClus.Digits2RecPoints(digitsTree, clustersTree);
+ */
+
+ fClusterFinder->Digits2RecPoints(digitsTree, clustersTree);
+ AliTOFTrigger::PrepareTOFMapFromDigit(digitsTree);
+
}
}
TString optionString = GetOption();
// use V1 cluster finder if selected
if (optionString.Contains("ClusterizerV1")) {
- static AliTOFClusterFinderV1 tofClus(fTOFcalib);
+ /*
+ AliTOFClusterFinderV1 tofClus(fTOFcalib);
// decoder version option
if (optionString.Contains("DecoderV0")) {
}
tofClus.Raw2Digits(reader, digitsTree);
+ */
+
+ fClusterFinderV1->Digits2RecPoints(reader, digitsTree);
}
else {
- static AliTOFClusterFinder tofClus(fTOFcalib);
+ /*
+ AliTOFClusterFinder tofClus(fTOFcalib);
// decoder version option
if (optionString.Contains("DecoderV0")) {
}
tofClus.Raw2Digits(reader, digitsTree);
+ */
+
+ fClusterFinder->Digits2RecPoints(reader, digitsTree);
+
}
}
// It contains the event_time estiamted by the TOF combinatorial algorithm
//
+
+ // Set here F. Noferini
+ AliTOFTriggerMask *mapTrigger = AliTOFTrigger::GetTOFTriggerMap();
+
+
+ TString optionString = GetOption();
+ if (optionString.Contains("ClusterizerV1")) {
+ fNumberOfTofClusters=fClusterFinderV1->GetNumberOfTOFclusters();
+ fNumberOfTofTrgPads=fClusterFinderV1->GetNumberOfTOFtrgPads();
+ AliInfo(Form(" Number of TOF cluster readout = %d ",fNumberOfTofClusters));
+ AliInfo(Form(" Number of TOF cluster readout in trigger window = %d ",fNumberOfTofTrgPads));
+ } else {
+ fNumberOfTofClusters=fClusterFinder->GetNumberOfTOFclusters();
+ fNumberOfTofTrgPads=fClusterFinder->GetNumberOfTOFtrgPads();
+ AliInfo(Form(" Number of TOF cluster readout = %d ",fNumberOfTofClusters));
+ AliInfo(Form(" Number of TOF cluster readout in trigger window = %d ",fNumberOfTofTrgPads));
+ }
+
if (!GetRecoParam()) AliFatal("cannot get TOF RECO params");
Float_t tofResolution = GetRecoParam()->GetTimeResolution();// TOF time resolution in ps
esdPID->SetTOFResponse(event,(AliESDpid::EStartTimeType_t)GetRecoParam()->GetStartTimeType());
+
+ event->GetTOFHeader()->SetNumberOfTOFclusters(fNumberOfTofClusters);
+ event->GetTOFHeader()->SetNumberOfTOFtrgPads(fNumberOfTofTrgPads);
+ event->GetTOFHeader()->SetTriggerMask(mapTrigger);
+ AliInfo(Form(" Number of readout cluster in trigger window = %d ; number of trgPads from Trigger map = %d",
+ event->GetTOFHeader()->GetNumberOfTOFtrgPads(),
+ event->GetTOFHeader()->GetNumberOfTOFmaxipad()));
+
+ fClusterFinderV1->ResetDigits();
+ fClusterFinderV1->ResetRecpoint();
+ fClusterFinder->ResetRecpoint();
+ fClusterFinderV1->Clear();
+ fClusterFinder->Clear();
+
}
//_____________________________________________________________________________
#include "AliReconstructor.h"
#include "AliTOFRecoParam.h"
+#include "AliTOFClusterFinder.h"
+#include "AliTOFClusterFinderV1.h"
class TTree;
class AliESDEvent;
class AliRawReader;
class AliTOFcalib;
+
//class AliTOFT0maker;
class AliTOFReconstructor: public AliReconstructor {
AliTOFcalib *fTOFcalib; // pointer to TOF calib class
//AliTOFT0maker *fTOFT0maker; // pointer to TOF T0 maker class
- ClassDef(AliTOFReconstructor, 3) // class for the TOF reconstruction
+ Int_t fNumberOfTofClusters; // Number of TOF Clusters
+ Int_t fNumberOfTofTrgPads; // Number of TOF trigger pads
+
+ AliTOFClusterFinder *fClusterFinder;
+ AliTOFClusterFinderV1 *fClusterFinderV1;
+
+ ClassDef(AliTOFReconstructor, 5) // class for the TOF reconstruction
};
#endif
extern AliRun* gAlice;
-AliTOFGeometry* AliTOFTrigger::fgTofGeo = NULL; // TOF geometry needed to get the minimial arrival time for each channel
-
+AliTOFTriggerMask* AliTOFTrigger:: fTOFTrigMap=NULL;
+AliTOFTriggerMask* AliTOFTrigger:: fTOFTrigMask=NULL;
//-------------------------------------------------------------------------
ClassImp(AliTOFTrigger)
fNCrateOn(0),
fNMaxipadOn(0),
fNMaxipadOnAll(0),
- fTOFTrigMask(0),
fStartTimeHit(0.0),
fTimeWidthTrigger(25.0)
SetName("TOF");
CreateInputs();
+ if(!fTOFTrigMap) fTOFTrigMap = new AliTOFTriggerMask();
+
}
//----------------------------------------------------------------------
fNCrateOn(0),
fNMaxipadOn(0),
fNMaxipadOnAll(0),
- fTOFTrigMask(0),
fStartTimeHit(startTimeWindow),
fTimeWidthTrigger(widthTimeWindow)
{
SetName("TOF");
CreateInputs();
+
+ if(!fTOFTrigMap) fTOFTrigMap = new AliTOFTriggerMask();
}
fSel4(tr.fSel4),
fNCrateOn(tr.fNCrateOn),
fNMaxipadOn(tr.fNMaxipadOn),
- fNMaxipadOnAll(tr.fNMaxipadOnAll),
- fTOFTrigMask(0)
+ fNMaxipadOnAll(tr.fNMaxipadOnAll)
{
//copy ctor
for (Int_t i=0;i<kNCTTM;i++) fLTMarray[i] = kFALSE;
fPowerMask[i] = fPowerMask[i-1]*2;
}
- if(tr.fTOFTrigMask){
- fTOFTrigMask = new AliTOFTriggerMask();
- fTOFTrigMask->SetTriggerMaskArray(tr.fTOFTrigMask->GetTriggerMaskArray());
- }
-
SetName(tr.GetName());
//fInputs=&(tr.GetInputs());
CreateInputs();
//----------------------------------------------------------------------
void AliTOFTrigger::Trigger() {
+ fTOFTrigMap->ResetMask();
+ if(!fTOFTrigMask) LoadActiveMask();
+
//triggering method
fSel1=0;
fSel2=0;
for (Int_t i=0;i<kNCTTM;i++){
for (Int_t j=0;j<kNCTTMchannels;j++){
- if (fCTTMmatrixFront[i][j]) nchonFront++;
+ if (fCTTMmatrixFront[i][j]){
+ nchonFront++;
+ fTOFTrigMap->SetON(i,j);
+ }
}
}
for (Int_t i=kNCTTM;i<(kNCTTM*2);i++){
for (Int_t j=0;j<kNCTTMchannels;j++){
- if (fCTTMmatrixBack[i-kNCTTM][j]) nchonBack++;
+ if (fCTTMmatrixBack[i-kNCTTM][j]){
+ nchonBack++;
+ fTOFTrigMap->SetON(i,j);
+ }
}
}
// 3 -> padz
// 4 -> padx
- if(! fgTofGeo) fgTofGeo = new AliTOFGeometry();
-
-
for (Int_t i=0;i<ndigits;i++){
AliTOFdigit * digit = (AliTOFdigit*)tofDigits->UncheckedAt(i);
detind[0] = digit->GetSector();
Float_t timedigit = digit->GetTdcND()*AliTOFGeometry::TdcBinWidth()*1E-3; // time digit in ns
Float_t pos[3];
- fgTofGeo->GetPosPar(detind, pos);
+ AliTOFGeometry::GetPosPar(detind, pos);
Float_t length = 0.;
for (Int_t ic = 0; ic < 3; ic++) length += pos[ic] * pos[ic];
length = TMath::Sqrt(length);
//
// Create LTM matrix by TOF raw data
//
+ fTOFTrigMap->ResetMask();
//initialization
for (Int_t i=0;i<kNLTM;i++){
}
}
+//-----------------------------------------------------------------------------
+void AliTOFTrigger::PrepareTOFMapFromRaw(AliRawReader *fRawReader,Int_t deltaBC) {
+ //
+ // Create LTM matrix by TOF raw data
+ //
+ if(!fTOFTrigMap) fTOFTrigMap = new AliTOFTriggerMask();
+ fTOFTrigMap->ResetMask();
+ LoadActiveMask();
+
+ if(fRawReader){
+ AliTOFRawStream * tofRawStream = new AliTOFRawStream();
+
+ tofRawStream->SetRawReader(fRawReader);
+
+ TClonesArray staticRawData("AliTOFrawData",10000);
+ staticRawData.Clear();
+ TClonesArray * clonesRawData = &staticRawData;
+
+ Int_t indexDDL = 0;
+ Int_t iRawData = 0;
+ AliTOFrawData *tofRawDatum = 0;
+ for (indexDDL=0; indexDDL<AliDAQ::NumberOfDdls("TOF"); indexDDL++) {
+
+ fRawReader->Reset();
+ tofRawStream->LoadRawDataBuffersV2(indexDDL);
+
+ clonesRawData = tofRawStream->GetRawData();
+ for (iRawData = 0; iRawData<clonesRawData->GetEntriesFast(); iRawData++) {
+
+ tofRawDatum = (AliTOFrawData*)clonesRawData->UncheckedAt(iRawData);
+
+ //if (tofRawDatum->GetTOT()==-1 || tofRawDatum->GetTOF()==-1) continue;
+ if (tofRawDatum->GetTOF()==-1) continue;
+
+ Int_t nTRM = tofRawDatum->GetTRM();
+ Int_t iChain = tofRawDatum->GetTRMchain();
+ Int_t iTDC = tofRawDatum->GetTDC();
+ Int_t iCH=tofRawDatum->GetTDCchannel();
+
+ if(nTRM==3 && iTDC>=12 && iTDC<=14 && indexDDL%2==1){ // DDL number to LTM number mapping
+ Int_t iLTMindex=-1;
+ Int_t iChannelIndex=-1;
+ switch(indexDDL%AliTOFGeometry::NDDL()){
+ case 1:
+ iLTMindex=1;
+ break;
+ case 3:
+ iLTMindex=36;
+ break;
+ default:
+ break;
+ }
+ iLTMindex+=2*(Int_t)(indexDDL/AliTOFGeometry::NDDL());
+ if(iChain==0 && indexDDL<36)
+ iLTMindex--;
+ if(iChain==0 && indexDDL>=36)
+ iLTMindex++;
+ iChannelIndex=iCH+iTDC*AliTOFGeometry::NCh()-12*AliTOFGeometry::NCh();
+ Int_t index[2]={iLTMindex,iChannelIndex};
+
+
+ if(fTOFTrigMask->IsON(index[0],index[1]) && TMath::Abs(tofRawDatum->GetTOF()-deltaBC) < 400) fTOFTrigMap->SetON(index[0],index[1]);
+ }
+
+ tofRawDatum = 0;
+ } // while loop
+
+ clonesRawData->Clear();
+
+ } // DDL Loop
+
+
+ delete tofRawStream;
+ tofRawStream = NULL;
+
+ }
+
+}
+//-----------------------------------------------------------------------------
+void AliTOFTrigger::PrepareTOFMapFromDigit(TTree *treeD) {
+ if(!fTOFTrigMap) fTOFTrigMap = new AliTOFTriggerMask();
+ LoadActiveMask();
+
+ fTOFTrigMap->ResetMask();
+ if (treeD == 0x0) {
+ return;
+ }
+
+ TBranch *branch = treeD->GetBranch("TOF");
+ if (!branch) {
+ return;
+ }
+ TClonesArray *tofDigits =new TClonesArray("AliTOFdigit", 1000);
+ branch->SetAddress(&tofDigits);
+ treeD->GetEvent(0);
+ Int_t ndigits = tofDigits->GetEntriesFast();
+ Int_t detind[5]; //detector indexes: 0 -> sector
+ // 1 -> plate(modulo)
+ // 2 -> strip
+ // 3 -> padz
+ // 4 -> padx
+ for (Int_t i=0;i<ndigits;i++){
+ AliTOFdigit * digit = (AliTOFdigit*)tofDigits->UncheckedAt(i);
+ detind[0] = digit->GetSector();
+ detind[1] = digit->GetPlate();
+ detind[2] = digit->GetStrip();
+ detind[3] = digit->GetPadz();
+ detind[4] = digit->GetPadx();
+
+ Int_t indexLTM[2] = {-1,-1};
+ GetLTMIndex(detind,indexLTM);
+
+ if(fTOFTrigMask->IsON(indexLTM[0],indexLTM[1])) fTOFTrigMap->SetON(indexLTM[0],indexLTM[1]);
+ }
+
+}
//-----------------------------------------------------------------------------
void AliTOFTrigger::GetLTMIndex(const Int_t * const detind, Int_t *indexLTM) {
//
indexLTM[1] = detind[2]+19*2;
}
else{
- AliError("Smth Wrong!!!");
+ // AliError("Smth Wrong!!!");
}
}
else {
indexLTM[1] = detind[2]+26;
}
else{
- AliError("Smth Wrong!!!");
+ // AliError("Smth Wrong!!!");
}
}
#include "AliTriggerDetector.h"
#include "AliLog.h"
+#include "TTree.h"
class AliTOFrawData;
class AliTOFTriggerMask;
-class AliTOFGeometry;
class AliTOFTrigger : public AliTriggerDetector
{
Float_t Getdeltamaxro() const {return fdeltamaxro;}
Int_t GetstripWindow() const {return fstripWindow;}
- void LoadActiveMask(); // Load active channel trigger mask
+ static void LoadActiveMask(); // Load active channel trigger mask
void GetMapMatrix(Bool_t map[][24]) const;
void GetMap(Bool_t **map) const;
//void PrintMap(); // to be checked because of warning problems
void CreateLTMMatrix();
void CreateLTMMatrixFromDigits();
void CreateLTMMatrixFromRaw(AliRawReader *fRawReader);
+
+ static AliTOFTriggerMask *GetTOFTriggerMap() {return fTOFTrigMap;}
+ static void PrepareTOFMapFromRaw(AliRawReader *fRawReader,Int_t deltaBC=13600);
+ static void PrepareTOFMapFromDigit(TTree *treeD);
private:
enum{
kNLTMtoTRDchannels = 8 //Number of channels in a CTTM
};
- static AliTOFGeometry *fgTofGeo; // TOF geometry needed to compute the minimal arrival time per channel
+ static AliTOFTriggerMask *fTOFTrigMap; // class with the TOF trigger map
+ static AliTOFTriggerMask *fTOFTrigMask; // class with the TOF trigger mask
AliTOFTrigger& operator=(const AliTOFTrigger &/*source*/); // ass. op.
AliTOFTrigger(const AliTOFTrigger & tr);
void GetCTTMIndex(Int_t *detind, Int_t *indexCTTM);
- void GetLTMIndex(const Int_t * const detind, Int_t *LTMIndex);
+ static void GetLTMIndex(const Int_t * const detind, Int_t *LTMIndex);
Bool_t fLTMmatrix[kNLTM][kNLTMchannels]; //LTM matrix
Bool_t fLTMarray[kNCTTM]; //LTM array for UPpurposes
Bool_t fCTTMmatrixFront[kNCTTM][kNCTTMchannels];//CTTM matrix for TOP FPGA
Int_t fNCrateOn; // number of crate fired
Int_t fNMaxipadOn; // number of Maxipad fired
Int_t fNMaxipadOnAll; // number of Maxipad fired w/o TDC dead mask
- AliTOFTriggerMask *fTOFTrigMask; // class with the TOF trigger mask
// aggiungere larghezza finestra temporale e tempo0 in ns
Float_t fStartTimeHit; // time window start after channel equalization (subtraction of the minimal time per channel default 0 ns)
Float_t fTimeWidthTrigger; // time window width (default 25 ns)
- ClassDef(AliTOFTrigger,2) // TOF Trigger Detector class
+ ClassDef(AliTOFTrigger,3) // TOF Trigger Detector class
};
#endif
{if (index==-1 || index >= fN) return NULL;
return (AliCluster *) fClusters[index];};
Bool_t GetTrackPoint(Int_t index, AliTrackPoint& p) const;
+ Int_t GetNumberOfMatchedTOFtracks() const {return fnmatch;}
void InitCheckHists();
void SaveCheckHists();
void FillClusterArray(TObjArray* arr) const;