]> git.uio.no Git - u/mrichter/AliRoot.git/blame_incremental - EMCAL/AliEMCAL.h
Removing compilation warnings (icc)
[u/mrichter/AliRoot.git] / EMCAL / AliEMCAL.h
... / ...
CommitLineData
1#ifndef ALIEMCAL_H
2#define ALIEMCAL_H
3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5
6/* $Id$ */
7
8//_________________________________________________________________________
9// Base Class for EMCAL
10// holds all geant information of
11// materials, etc.
12//
13//*-- Author: Yves Schutz (SUBATECH)
14
15// --- ROOT system ---
16
17class TString ;
18class TTask ;
19class TFolder ;
20class TRandom ;
21class TGraph;
22class TF1;
23
24// --- AliRoot header files ---
25class AliRawReader;
26#include "AliDetector.h"
27#include "AliEMCALGeometry.h"
28#include "AliEMCALTrigger.h"
29
30class AliEMCAL : public AliDetector {
31
32 public:
33
34 AliEMCAL();
35 AliEMCAL(const char* name, const char* title="");
36 AliEMCAL(const AliEMCAL& emcal) : AliDetector(emcal) {
37 // cpy ctor: no implementation yet
38 // requested by the Coding Convention
39 Fatal("cpy ctor", "not implemented") ;
40 }
41 virtual ~AliEMCAL() ;
42 virtual void AddHit(Int_t, Int_t*, Float_t *) {
43 Fatal("AddHit(Int_t, Int_t*, Float_t *", "not to be used: use AddHit( Int_t shunt, Int_t primary, Int_t track,Int_t id, Float_t *hits )") ;
44 }
45 virtual void Copy(TObject & emcal) const
46 { Copy(dynamic_cast<AliEMCAL&>(emcal)); }
47 virtual void Copy(AliEMCAL & emcal) const;
48 virtual AliDigitizer* CreateDigitizer(AliRunDigitizer* manager) const;
49 virtual void CreateMaterials() ;
50 // virtual void
51 virtual void Digits2Raw();
52
53 using AliDetector::Raw2Digits;
54 virtual void Raw2Digits(AliRawReader *reader);
55
56 virtual void FinishRun() {}
57 virtual AliEMCALGeometry * GetGeometry() const
58 {return AliEMCALGeometry::GetInstance(GetTitle(),"") ; }
59 virtual void Hits2SDigits();
60 virtual Int_t IsVersion(void) const = 0 ;
61
62 virtual AliTriggerDetector* CreateTriggerDetector() const
63 { return new AliEMCALTrigger(); }
64
65 // Raw Read Out
66 Double_t GetRawFormatCapa() const { return fgCapa ; }
67 Double_t GetRawFormatHighCharge() const { return fHighCharge ; }
68 Double_t GetRawFormatHighGain() const { return fHighGain ; }
69 Double_t GetRawFormatHighLowGainFactor() const { return fHighLowGainFactor ; }
70 Double_t GetRawFormatLowCharge() const { return ( fHighCharge * fHighLowGainFactor ) ; }
71 Double_t GetRawFormatLowGain() const { return ( fHighGain / fHighLowGainFactor ) ; }
72 Int_t GetRawFormatLowGainOffset() const { return fLowGainOffset ; }
73 Int_t GetRawFormatOrder() const { return fgOrder ; }
74 Int_t GetRawFormatTimeBins() const { return fgkTimeBins ; }
75 Double_t GetRawFormatTimeMax() const { return fgTimeMax ; }
76 Double_t GetRawFormatTimePeak() const { return fgTimePeak ; }
77 Double_t GetRawFormatTimeTrigger() const { return fgTimeTrigger ; }
78 Int_t GetRawFormatDDLOffset() const { return fgDDLOffset ; }
79 Int_t GetRawFormatThreshold() const { return fgThreshold ; }
80 Int_t GetRawFormatChannelsPerDDL() const { return fgChannelsPerDDL ; }
81 static Double_t RawResponseFunctionMax(Double_t charge, Double_t gain) ;
82 Bool_t RawSampledResponse(Double_t dtime, Double_t damp, Int_t * adcH, Int_t * adcL) const ;
83 //
84 virtual AliLoader* MakeLoader(const char* topfoldername);
85 virtual const TString Version() const {return TString(" ") ; }
86 AliEMCAL & operator = (const AliEMCAL & /*rvalue*/) {
87 Fatal("operator =", "not implemented") ; return *this ; }
88
89protected:
90
91 static Double_t RawResponseFunction(Double_t *x, Double_t *par) ;
92 void FitRaw(Bool_t lowGainFlag, TGraph * gLowGain, TGraph * gHighGain, TF1* signalF, Double_t & energy, Double_t & time) ;
93
94 Int_t fBirkC0; // constants for Birk's Law implementation
95 Double_t fBirkC1; // constants for Birk's Law implementation
96 Double_t fBirkC2; // constants for Birk's Law implementation
97
98 static Double_t fgCapa ; // capacitor of the preamplifier for the raw RO signal
99 Double_t fHighCharge ; // high charge (to convert energy to charge) for the raw RO signal
100 Double_t fHighGain ; // high gain for the raw RO signal
101 Double_t fHighLowGainFactor ; // high to low gain factor for the raw RO signal
102 Int_t fLowGainOffset ; // to separate high from low gain in the DDL
103 static Int_t fgOrder ; // order of the gamma function for the RO signal
104 static const Int_t fgkTimeBins = 256 ; // number of sampling bins of the raw RO signal
105 static Double_t fgTimeMax ; // maximum sampled time of the raw RO signal
106 static Double_t fgTimePeak ; // peaking time of the raw RO signal
107 static Double_t fgTimeTrigger ; // time of the trigger for the RO signal
108 static Int_t fgDDLOffset; // DDL offset
109 static Int_t fgThreshold; // threshold
110 static Int_t fgChannelsPerDDL; // number of channels per DDL
111
112 ClassDef(AliEMCAL,9) // Electromagnetic calorimeter (base class)
113
114 } ;
115
116#endif // ALIEMCAL_H