Reinitialization after soft scattering, bug fixes in the calculation of angle and...
[u/mrichter/AliRoot.git] / MUON / AliMUON.h
CommitLineData
a9e2aefa 1#ifndef ALIMUON_H
2#define ALIMUON_H
3da30618 3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5
6/* $Id$ */
88cb7938 7/* $Id$ */
8
3da30618 9
fe4da5cc 10////////////////////////////////////////////////
5a35ac13 11// AliDetector Class for MUON subsystem //
fe4da5cc 12////////////////////////////////////////////////
13#include "AliDetector.h"
ce3f5e87 14#include "AliMUONData.h"
15#include "AliMUONChamber.h"
a9e2aefa 16
3fa6cfdd 17class AliLoader;
a9e2aefa 18class AliMUONLocalTrigger;
19class AliMUONGlobalTrigger;
20class AliMUONTriggerCircuit;
21class AliMUONTriggerDecision;
a30a000f 22class AliSegmentation;
a9e2aefa 23class AliMUONResponse;
375da359 24class AliMUONMerger;
a9e2aefa 25class AliMUONHit;
26class AliMUONPadHit;
a897a37a 27class AliMUONRawCluster;
30aaba74 28class AliMUONClusterFinderVS;
a9e2aefa 29class AliMUONReconstHit;
1cae9436 30class AliMUONMerger;
31
a9e2aefa 32class TVector;
94de3818 33#include "TObjArray.h"
a9e2aefa 34class TFile;
35class TTree;
fe4da5cc 36
37
fe4da5cc 38class AliMUON : public AliDetector {
39 public:
40 AliMUON();
41 AliMUON(const char *name, const char *title);
a9e2aefa 42 AliMUON(const AliMUON& rMUON);
fe4da5cc 43 virtual ~AliMUON();
ce3f5e87 44
fe4da5cc 45 virtual void BuildGeometry();
fe4da5cc 46 Int_t DistancetoPrimitive(Int_t px, Int_t py);
ce3f5e87 47 AliMUONData* GetMUONData() {return fMUONData;}
48 virtual Int_t IsVersion() const {return 0;}
3fa6cfdd 49
ce3f5e87 50 // MUONLoader definition
3fa6cfdd 51 virtual AliLoader* MakeLoader(const char* topfoldername); //builds standard getter (AliLoader type)
ce3f5e87 52 // Interface with AliMUONData
53 virtual void MakeBranch(Option_t *opt=" ") {GetMUONData()->MakeBranch(opt);}
d652f85c 54 virtual void SetTreeAddress();
ce3f5e87 55 virtual void ResetHits() {GetMUONData()->ResetHits();}
56 virtual void ResetDigits() {GetMUONData()->ResetDigits();}
d652f85c 57 virtual void ResetTrigger() {GetMUONData()->ResetTrigger();}
58 virtual void ResetRawClusters() {GetMUONData()->ResetRawClusters();}
59 virtual void SetSplitLevel(Int_t SplitLevel) {fSplitLevel=SplitLevel;}
a9e2aefa 60 // Cluster Finding
fe311ef1 61 virtual void Digits2Reco();
62 virtual void FindClusters();
a9e2aefa 63 // Digitisation
85a5290f 64 virtual AliDigitizer* CreateDigitizer(AliRunDigitizer* manager);
2ab0c725 65 virtual void SDigits2Digits();
ce3f5e87 66 // Configuration Methods (per station id)
67 //
68 // Set Chamber Segmentation Parameters
69 // id refers to the station and isec to the cathode plane
70 // Set Z values for all chambers
a9e2aefa 71 virtual void SetChambersZ(const Float_t *Z);
72 virtual void SetChambersZToDefault(void);
73 virtual void SetPadSize(Int_t id, Int_t isec, Float_t p1, Float_t p2);
ce3f5e87 74 // Set Signal Generation Parameters
a897a37a 75 virtual void SetSigmaIntegration(Int_t id, Float_t p1);
76 virtual void SetChargeSlope(Int_t id, Float_t p1);
77 virtual void SetChargeSpread(Int_t id, Float_t p1, Float_t p2);
3b3ee6f4 78 virtual void SetMaxAdc(Int_t id, Int_t p1);
ce3f5e87 79 // Set Segmentation and Response Model
a9e2aefa 80 virtual void SetSegmentationModel(Int_t id, Int_t isec,
a30a000f 81 AliSegmentation *segmentation);
a9e2aefa 82 virtual void SetResponseModel(Int_t id, AliMUONResponse *response);
fe4da5cc 83 virtual void SetNsec(Int_t id, Int_t nsec);
ce3f5e87 84 // Set Reconstruction Model
30aaba74 85 virtual void SetReconstructionModel(Int_t id, AliMUONClusterFinderVS *reconstruction);
ce3f5e87 86 // Set Merger/Digitizer
1cae9436 87 virtual void SetMerger(AliMUONMerger* merger);
88 virtual AliMUONMerger* Merger();
89
ce3f5e87 90 // Set Stepping Parameters
a897a37a 91 virtual void SetMaxStepGas(Float_t p1);
92 virtual void SetMaxStepAlu(Float_t p1);
93 virtual void SetMaxDestepGas(Float_t p1);
94 virtual void SetMaxDestepAlu(Float_t p1);
5c1f55c5 95 virtual void SetAcceptance(Bool_t acc=0, Float_t angmin=2, Float_t angmax=9);
ce3f5e87 96
97 // get Trigger answer
a9e2aefa 98 void Trigger(Int_t nev);
ce3f5e87 99 // Return reference to Chamber #id
a9e2aefa 100 virtual AliMUONChamber& Chamber(Int_t id)
ce3f5e87 101 {return *((AliMUONChamber *) (*fChambers)[id]);}
102 // Return reference to Circuit #id
a9e2aefa 103 virtual AliMUONTriggerCircuit& TriggerCircuit(Int_t id)
104 {return *((AliMUONTriggerCircuit *) (*fTriggerCircuits)[id]);}
ce3f5e87 105 // Retrieve pad hits for a given Hit
a9e2aefa 106 virtual AliMUONPadHit* FirstPad(AliMUONHit *hit, TClonesArray *padHits);
107 virtual AliMUONPadHit* NextPad(TClonesArray *padHits);
ce3f5e87 108 // Return pointers to digits
a9e2aefa 109 AliMUONRawCluster *RawCluster(Int_t ichamber, Int_t icathod,
110 Int_t icluster);
ce3f5e87 111 // Copy Operator
a9e2aefa 112 AliMUON& operator = (const AliMUON& rhs);
a897a37a 113
ce3f5e87 114
fe4da5cc 115 protected:
1bd26093 116 Int_t fNCh; // Number of chambers
ce3f5e87 117 Int_t fNTrackingCh; // Number of tracking chambers*
118 AliMUONData* fMUONData; // Data container for MUON subsystem
d652f85c 119 Int_t fSplitLevel; // Splitlevel when making branches in outfiles.
ce3f5e87 120 TObjArray* fChambers; // List of Tracking Chambers
121 TObjArray* fTriggerCircuits; // List of Trigger Circuits
122
123 //
fe4da5cc 124 Bool_t fAccCut; //Transport acceptance cut
125 Float_t fAccMin; //Minimum acceptance cut used during transport
126 Float_t fAccMax; //Minimum acceptance cut used during transport
ce3f5e87 127 //
128 // Stepping Parameters
129 Float_t fMaxStepGas; // Maximum step size inside the chamber gas
130 Float_t fMaxStepAlu; // Maximum step size inside the chamber aluminum
131 Float_t fMaxDestepGas; // Maximum relative energy loss in gas
132 Float_t fMaxDestepAlu; // Maximum relative energy loss in aluminum
133
134 // Pad Iterator
135 Int_t fMaxIterPad; // Maximum pad index
136 Int_t fCurIterPad; // Current pad index
137 // Background eent for event mixing
138 Text_t *fFileName; // ! File with background hits
139 AliMUONMerger *fMerger; // ! pointer to merger
140
141 ClassDef(AliMUON,3) // MUON Detector base class
a897a37a 142};
fe4da5cc 143#endif
144