ROOT logo
AliRoot » TOF » AliTOFT0

class AliTOFT0: public TTask


 This is a TTask that made the calculation of the Time zero using TOF.
 Description: The algorithm used to calculate the time zero of
 interaction using TOF detector is the following.
 We select in the MonteCarlo some primary particles - or tracks in
 the following - that strike the TOF detector (the larger part are
 pions, kaons or protons).
 We choose a set of 10 selected tracks, for each track You have the
 length of the track when the TOF is reached (a standard TOF hit
 does not contain this additional information, this is the reason
 why we implemented a new time zero dedicated TOF hit class
 AliTOFhitT0; in order to store this type of hit You have to use the
 AliTOFv4T0 as TOF class in Your Config.C. In AliTOFv4T0 the
 StepManager was modified in order to fill the TOF hit branch with
 this type of hits; in fact the AliTOF::AddT0Hit is called rather
 that the usual AliTOF::AddHit), the momentum at generation (from
 TreeK) and the time of flight given by the TOF detector.
 (Observe that the ctor of the AliTOF class, when the AliTOFv4T0
 class is used, is called with the "tzero" option: it is in order
 create the fHits TClonesArray filled with AliTOFhitT0 objects,
 rather than with normal AliTOFhit)
 Then Momentum and time of flight for each track are smeared
 according to known experimental resolution (all sources of error
 have been token into account).
 Let consider now only one set of 10 tracks (the algorithm is the
 same for all sets).
 Assuming the (mass) hypothesis that each track can be AUT a pion,
 AUT a kaon, AUT a proton, we consider all the 3 at 10 possible
 cases.
 For each track in each (mass) configuration
 (a configuration can be
 e.g. pion/pion/kaon/proton/pion/proton/kaon/kaon/pion/pion)
 we calculate the time zero (we know in fact the velocity of the
 track after the assumption about its mass, the time of flight given
 by the TOF, and the corresponding path travelled till the TOF
 detector). Then for each mass configuration we have 10 time zero
 and we can calculate the ChiSquare for the current configuration
 using the weighted mean over all 10 time zero.
 We call the best assignment the mass configuration that gives the
 minimum value of the ChiSquare.
 We plot the weighted mean over all 10 time zero for the best
 assignment, the ChiSquare for the best assignment and the
 corresponding confidence level.
 The strong assumption is the MC selection of primary particles. It
 will be introduced in the future also some more realistic
 simulation about this point.

 Use case:
 root [0] AliTOFT0 * tzero = new AliTOFT0("galice.root")
 Warning in <TDatabasePDG::TDatabasePDG>: object already instantiated
 root [1] tzero->ExecuteTask()
 root [2] tzero->ExecuteTask("tim")
             // available parameters:
             tim - print benchmarking information
             all - print usefull informations about the number of
                   misidentified tracks and a comparison about the
                   true configuration (known from MC) and the best
                   assignment

-- Author: F. Pierella


Function Members (Methods)

public:
AliTOFT0()
AliTOFT0(const AliTOFT0& tzero)
AliTOFT0(char* headerFile, Int_t nEvents = 0)
virtual~AliTOFT0()
virtual voidTTask::Abort()MENU
voidTObject::AbstractMethod(const char* method) const
virtual voidTTask::Add(TTask* task)
virtual voidTObject::AppendPad(Option_t* option = "")
virtual voidTTask::Browse(TBrowser* b)
static TClass*Class()
virtual const char*TObject::ClassName() const
virtual voidTTask::CleanTasks()
virtual voidTTask::Clear(Option_t* option = "")
virtual TObject*TNamed::Clone(const char* newname = "") const
virtual Int_tTNamed::Compare(const TObject* obj) const
virtual voidTTask::Continue()MENU
virtual voidTNamed::Copy(TObject& named) const
virtual voidTObject::Delete(Option_t* option = "")MENU
virtual Int_tTObject::DistancetoPrimitive(Int_t px, Int_t py)
virtual voidTObject::Draw(Option_t* option = "")
virtual voidTObject::DrawClass() constMENU
virtual TObject*TObject::DrawClone(Option_t* option = "") constMENU
virtual voidTObject::Dump() constMENU
virtual voidTObject::Error(const char* method, const char* msgfmt) const
virtual voidExec(Option_t* option)
virtual voidTObject::Execute(const char* method, const char* params, Int_t* error = 0)
virtual voidTObject::Execute(TMethod* method, TObjArray* params, Int_t* error = 0)
virtual voidTObject::ExecuteEvent(Int_t event, Int_t px, Int_t py)
virtual voidTTask::ExecuteTask(Option_t* option = "0")MENU
virtual voidTTask::ExecuteTasks(Option_t* option)
virtual voidTObject::Fatal(const char* method, const char* msgfmt) const
virtual voidTNamed::FillBuffer(char*& buffer)
virtual TObject*TObject::FindObject(const char* name) const
virtual TObject*TObject::FindObject(const TObject* obj) const
Int_tTTask::GetBreakin() const
Int_tTTask::GetBreakout() const
virtual Option_t*TObject::GetDrawOption() const
static Long_tTObject::GetDtorOnly()
virtual const char*TObject::GetIconName() const
TList*TTask::GetListOfTasks() const
virtual const char*TNamed::GetName() const
Int_tGetNEvents() const
virtual char*TObject::GetObjectInfo(Int_t px, Int_t py) const
static Bool_tTObject::GetObjectStat()
virtual Option_t*TObject::GetOption() const
virtual const char*TNamed::GetTitle() const
const char*GetTZeroFile() const
virtual UInt_tTObject::GetUniqueID() const
virtual Bool_tTObject::HandleTimer(TTimer* timer)
virtual ULong_tTNamed::Hash() const
virtual voidTObject::Info(const char* method, const char* msgfmt) const
virtual Bool_tTObject::InheritsFrom(const char* classname) const
virtual Bool_tTObject::InheritsFrom(const TClass* cl) const
virtual voidTObject::Inspect() constMENU
voidTObject::InvertBit(UInt_t f)
virtual TClass*IsA() const
Bool_tTTask::IsActive() const
virtual Bool_tTObject::IsEqual(const TObject* obj) const
virtual Bool_tTTask::IsFolder() const
Bool_tTObject::IsOnHeap() const
virtual Bool_tTNamed::IsSortable() const
Bool_tTObject::IsZombie() const
virtual voidTTask::ls(Option_t* option = "*") constMENU
voidTObject::MayNotUse(const char* method) const
virtual Bool_tTObject::Notify()
voidTObject::Obsolete(const char* method, const char* asOfVers, const char* removedFromVers) const
static voidTObject::operator delete(void* ptr)
static voidTObject::operator delete(void* ptr, void* vp)
static voidTObject::operator delete[](void* ptr)
static voidTObject::operator delete[](void* ptr, void* vp)
void*TObject::operator new(size_t sz)
void*TObject::operator new(size_t sz, void* vp)
void*TObject::operator new[](size_t sz)
void*TObject::operator new[](size_t sz, void* vp)
AliTOFT0&operator=(const AliTOFT0& tzero)
Bool_toperator==(const AliTOFT0& tzero) const
virtual voidTObject::Paint(Option_t* option = "")
virtual voidTObject::Pop()
virtual voidPrint(Option_t* option) const
virtual Int_tTObject::Read(const char* name)
virtual voidTObject::RecursiveRemove(TObject* obj)
voidTObject::ResetBit(UInt_t f)
virtual voidTObject::SaveAs(const char* filename = "", Option_t* option = "") constMENU
virtual voidTObject::SavePrimitive(basic_ostream<char,char_traits<char> >& out, Option_t* option = "")
voidTTask::SetActive(Bool_t active = kTRUE)TOGGLE
voidTObject::SetBit(UInt_t f)
voidTObject::SetBit(UInt_t f, Bool_t set)
voidTTask::SetBreakin(Int_t breakin = 1)TOGGLE
voidTTask::SetBreakout(Int_t breakout = 1)TOGGLE
virtual voidTObject::SetDrawOption(Option_t* option = "")MENU
static voidTObject::SetDtorOnly(void* obj)
voidSetMomBounds(Float_t pLow, Float_t pUp)
virtual voidTNamed::SetName(const char* name)MENU
virtual voidTNamed::SetNameTitle(const char* name, const char* title)
voidSetNEvents(Int_t nEvents)
static voidTObject::SetObjectStat(Bool_t stat)
voidSetTimeResolution(Float_t timeresolution)
virtual voidTNamed::SetTitle(const char* title = "")MENU
voidSetTZeroFile(char* file)
virtual voidTObject::SetUniqueID(UInt_t uid)
virtual voidShowMembers(TMemberInspector&)
virtual Int_tTNamed::Sizeof() const
virtual voidStreamer(TBuffer&)
voidStreamerNVirtual(TBuffer& ClassDef_StreamerNVirtual_b)
virtual voidTObject::SysError(const char* method, const char* msgfmt) const
Bool_tTObject::TestBit(UInt_t f) const
Int_tTObject::TestBits(UInt_t f) const
virtual voidTObject::UseCurrentStyle()
virtual voidTObject::Warning(const char* method, const char* msgfmt) const
virtual Int_tTObject::Write(const char* name = 0, Int_t option = 0, Int_t bufsize = 0)
virtual Int_tTObject::Write(const char* name = 0, Int_t option = 0, Int_t bufsize = 0) const
protected:
virtual voidTObject::DoError(int level, const char* location, const char* fmt, va_list va) const
voidTObject::MakeZombie()

Data Members

protected:
Bool_tTTask::fActivetrue if task is active
Int_tTTask::fBreakin=1 if a break point set at task extry
Int_tTTask::fBreakout=1 if a break point set at task exit
Bool_tTTask::fHasExecutedTrue if task has executed
TStringTNamed::fNameobject identifier
TStringTTask::fOptionOption specified in ExecuteTask
TList*TTask::fTasksList of Tasks
TStringTNamed::fTitleobject title
static TTask*TTask::fgBeginTaskpointer to task initiator
static TTask*TTask::fgBreakPointpointer to current break point
private:
TStringfHeadersFileinput file
Float_tfLowerMomBoundmomentum lower bound for selected primary tracks
Int_tfNeventsNumber of events for which calculate the T0
TStringfT0Fileoutput file; it contains for time being only 3 histos
Float_tfTimeResolutionglobal time resolution used to calculate T0
Float_tfUpperMomBoundmomentum upper bound for selected primary tracks

Class Charts

Inheritance Chart:
TTask
AliTOFT0

Function documentation

AliTOFT0()
 ctor
AliTOFT0(char* headerFile, Int_t nEvents = 0)


AliTOFT0(const AliTOFT0& tzero)
 copy ctr
~AliTOFT0()
 dtor
void Exec(Option_t* option)
 calculate T0 distribution for all events using chisquare

void SetTZeroFile(char* file)
 Set T0 file name

void Print(Option_t* option) const
 Print class content

Bool_t operator==(const AliTOFT0& tzero) const
 Equal operator

const char* GetTZeroFile() const
{return fT0File.Data();}
void SetNEvents(Int_t nEvents)
{fNevents = nEvents;}
void SetTimeResolution(Float_t timeresolution)
{ fTimeResolution=timeresolution;}
Int_t GetNEvents() const
{return fNevents;}
void SetMomBounds(Float_t pLow, Float_t pUp)