]> git.uio.no Git - u/mrichter/AliRoot.git/blame - ITS/AliITSresponseSDD.cxx
Bug fix in the creation of the AliITSgeom::fShape entry for SPD. Now there is both...
[u/mrichter/AliRoot.git] / ITS / AliITSresponseSDD.cxx
CommitLineData
b0f5e3fc 1/**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
3 * *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
6 * *
7 * Permission to use, copy, modify and distribute this software and its *
8 * documentation strictly for non-commercial purposes is hereby granted *
9 * without fee, provided that the above copyright notice appears in all *
10 * copies and that both the copyright notice and this permission notice *
11 * appear in the supporting documentation. The authors make no claims *
12 * about the suitability of this software for any purpose. It is *
13 * provided "as is" without express or implied warranty. *
14 **************************************************************************/
15
1ca7869b 16#include <TString.h>
17
b0f5e3fc 18#include "AliITSresponseSDD.h"
b0f5e3fc 19
b0f5e3fc 20
21//___________________________________________
22ClassImp(AliITSresponseSDD)
23
24AliITSresponseSDD::AliITSresponseSDD()
25{
26 // constructor
27 SetMaxAdc();
28 SetDiffCoeff();
b0f5e3fc 29 SetDriftSpeed();
e8189707 30 SetNSigmaIntegration();
7551c5b2 31 SetNLookUp();
b0f5e3fc 32 // SetClock();
33 SetNoiseParam();
7551c5b2 34 SetNoiseAfterElectronics();
35 SetElectronics();
36 SetDynamicRange();
37 SetChargeLoss();
b0f5e3fc 38 SetMinVal();
39 SetParamOptions();
40 SetZeroSupp();
41 SetDataType();
42 SetFilenames();
43 SetOutputOption();
fa1750f9 44 SetDo10to8();
b0f5e3fc 45}
46
47//__________________________________________________________________________
48AliITSresponseSDD::AliITSresponseSDD(const AliITSresponseSDD &source){
49 // Copy Constructor
50 if(&source == this) return;
e8189707 51 Int_t i;
7e2ac9e7 52 for(i=0;i<8;i++){this->fCPar[i] = source.fCPar[i];}
b0f5e3fc 53 this->fNoise = source.fNoise;
54 this->fBaseline = source.fBaseline;
7551c5b2 55 this->fNoiseAfterEl = source.fNoiseAfterEl;
56 this->fDynamicRange = source.fDynamicRange;
57 this->fChargeLoss = source.fChargeLoss;
b0f5e3fc 58 this->fTemperature = source.fTemperature;
59 this->fDriftSpeed = source.fDriftSpeed;
e8189707 60 this->fNsigmas = source.fNsigmas;
b0f5e3fc 61 this->fMaxAdc = source.fMaxAdc;
62 this->fDiffCoeff = source.fDiffCoeff;
e8189707 63 this->fDiffCoeff1 = source.fDiffCoeff1;
b0f5e3fc 64 this->fZeroSuppFlag = source.fZeroSuppFlag;
65 this->fMinVal = source.fMinVal;
66 this->fWrite = source.fWrite;
fa1750f9 67 this->fBitComp = source.fBitComp;
b0f5e3fc 68 this->fOption = source.fOption;
69 this->fParam1 = source.fParam1;
70 return;
71}
72
73//_________________________________________________________________________
74AliITSresponseSDD&
75 AliITSresponseSDD::operator=(const AliITSresponseSDD &source) {
76 // Assignment operator
77 if(&source == this) return *this;
e8189707 78 Int_t i;
7e2ac9e7 79 for(i=0;i<8;i++){this->fCPar[i] = source.fCPar[i];}
b0f5e3fc 80 this->fNoise = source.fNoise;
81 this->fBaseline = source.fBaseline;
7551c5b2 82 this->fNoiseAfterEl = source.fNoiseAfterEl;
83 this->fDynamicRange = source.fDynamicRange;
84 this->fChargeLoss = source.fChargeLoss;
b0f5e3fc 85 this->fTemperature = source.fTemperature;
86 this->fDriftSpeed = source.fDriftSpeed;
e8189707 87 this->fNsigmas = source.fNsigmas;
b0f5e3fc 88 this->fMaxAdc = source.fMaxAdc;
89 this->fDiffCoeff = source.fDiffCoeff;
e8189707 90 this->fDiffCoeff1 = source.fDiffCoeff1;
b0f5e3fc 91 this->fZeroSuppFlag = source.fZeroSuppFlag;
92 this->fMinVal = source.fMinVal;
93 this->fWrite = source.fWrite;
fa1750f9 94 this->fBitComp = source.fBitComp;
b0f5e3fc 95 this->fOption = source.fOption;
96 this->fParam1 = source.fParam1;
97 return *this;
98}
99
100void AliITSresponseSDD::SetCompressParam(Int_t cp[8])
101{
102 // set compression param
e8189707 103
b0f5e3fc 104 Int_t i;
e8189707 105 for (i=0; i<8; i++) {
b0f5e3fc 106 fCPar[i]=cp[i];
107 //printf("\n CompressPar %d %d \n",i,fCPar[i]);
108
109 }
110}
111void AliITSresponseSDD::GiveCompressParam(Int_t cp[8])
112{
113 // give compression param
e8189707 114
b0f5e3fc 115 Int_t i;
e8189707 116 for (i=0; i<8; i++) {
b0f5e3fc 117 cp[i]=fCPar[i];
118 }
119}
7551c5b2 120
121void AliITSresponseSDD::Print()
122{
123 // Print SDD response Parameters
124
125 cout << "**************************************************" << endl;
126 cout << " Silicon Drift Detector Response Parameters " << endl;
127 cout << "**************************************************" << endl;
128 cout << "Diffusion Coefficients: " << fDiffCoeff << ", " << fDiffCoeff1 << endl;
129
130 cout << "Hardware compression parameters: " << endl;
131 for(Int_t i=0; i<8; i++) cout << "fCPar[" << i << "] = " << fCPar[i] << endl;
132 cout << "Noise before electronics (arbitrary units): " << fNoise << endl;
133 cout << "Baseline (ADC units): " << fBaseline << endl;
134 cout << "Noise after electronics (ADC units): " << fNoiseAfterEl << endl;
135
136 cout << "Dynamic Range: " << fDynamicRange << endl;
137 cout << "Charge Loss: " << fChargeLoss << endl;
138 cout << "Temperature: " << fTemperature << endl;
139 cout << "Drift Speed: " << fDriftSpeed << endl;
140 cout << "Electronics (1=PASCAL, 2=OLA): " << fElectronics << endl;
141
142 cout << "N. of Sigma for signal integration: " << fNsigmas << endl;
143 cout << "N. of bins in lookup table: " << fNcomps << endl;
144
145 cout << "Max. ADC Value: " << fMaxAdc << endl;
146 cout << "Min. Value: " << fMinVal << endl;
147
148 cout << "Zero suppression flag: " << fZeroSuppFlag << endl;
149 cout << "**************************************************" << endl;
150
151
152
153}
154
155
156