* provided "as is" without express or implied warranty. *
**************************************************************************/
-#include <TMath.h>
-#include <TString.h>
#include "AliITSresponseSSD.h"
-#include "AliITSgeom.h"
+//////////////////////////////////////////////////
+// Base response class for ITS //
+// It is used to set static data members //
+// connected to parameters equal for all //
+// the SSD modules //
+//////////////////////////////////////////////////
+
+
+const Float_t AliITSresponseSSD::fgkDiffCoeffDefault = 0.;
+const Double_t AliITSresponseSSD::fgkfCouplingPR = 0.01;
+const Double_t AliITSresponseSSD::fgkfCouplingPL = 0.01;
+const Double_t AliITSresponseSSD::fgkfCouplingNR = 0.01;
+const Double_t AliITSresponseSSD::fgkfCouplingNL = 0.01;
+const Int_t AliITSresponseSSD::fgkZSThreshold = 3;
+
ClassImp(AliITSresponseSSD)
//______________________________________________________________________
-AliITSresponseSSD::AliITSresponseSSD(){
- // constructor
+AliITSresponseSSD::AliITSresponseSSD():AliITSresponse(),
+fADCpereV(0),
+fKeVperADC(0),
+fCouplingPR(0),
+fCouplingPL(0),
+fCouplingNR(0),
+fCouplingNL(9),
+fZSThreshold(0){
+ // Default Constructor
- SetDiffCoeff();
- SetNoiseParam();
- SetDataType();
- SetSigmaSpread();
- SetParamOptions();
- SetNDetParam();
- SetADCpereV();
- fDetPar = new Float_t[fNPar];
- if (fNPar==6) {
- fDetPar[0]=10.;
- fDetPar[1]=5.;
- fDetPar[2]=0.02;
- fDetPar[3]=0.02;
- fDetPar[4]=0.02;
- fDetPar[5]=0.03;
- } // end if
+ SetDiffCoeff(fgkDiffCoeffDefault,0.);
+ SetADCpereV();
+ SetKeVperADC();
+ SetCouplings(fgkfCouplingPR,fgkfCouplingPL,fgkfCouplingNR,fgkfCouplingNL);
+ SetZSThreshold(fgkZSThreshold);
}
-//______________________________________________________________________
-AliITSresponseSSD::~AliITSresponseSSD(){
- // destructor
- delete [] fDetPar;
-}
//______________________________________________________________________
-AliITSresponseSSD& AliITSresponseSSD::operator=(const AliITSresponseSSD &src) {
- // = operator.
-
- if(&src == this) return *this;
+AliITSresponseSSD::AliITSresponseSSD(const AliITSresponseSSD &ob) : AliITSresponse(ob),
+fADCpereV(ob.fADCpereV),
+fKeVperADC(ob.fKeVperADC),
+fCouplingPR(ob.fCouplingPR),
+fCouplingPL(ob.fCouplingPL),
+fCouplingNR(ob.fCouplingNR),
+fCouplingNL(ob.fCouplingNL),
+fZSThreshold(ob.fZSThreshold){
+ // Copy constructor
- this->fNPar = src.fNPar;
- for(Int_t i=0;i<this->fNPar;i++) this->fDetPar[i] = src.fDetPar[i];
- this->fNoiseP = src.fNoiseP;
- this->fNoiseN = src.fNoiseN;
- this->fSigmaP = src.fSigmaP;
- this->fSigmaN = src.fSigmaN;
- this->fDiffCoeff = src.fDiffCoeff;
- this->fADCpereV = src.fADCpereV;
- this->fOption1 = src.fOption1;
- this->fOption2 = src.fOption2;
- this->fDataType = src.fDataType;
-
- return *this;
}
-//_________________________________________________________________________
-AliITSresponseSSD::AliITSresponseSSD(const AliITSresponseSSD &src) {
- // copy constructor
- *this = src;
-}
//______________________________________________________________________
-void AliITSresponseSSD::SetDetParam(Float_t *par){
- // set det param
- Int_t i;
-
- for (i=0; i<fNPar; i++) {
- fDetPar[i]=par[i];
- //printf("\n CompressPar %d %d \n",i,fCPar[i]);
- } // end for i
+AliITSresponseSSD& AliITSresponseSSD::operator=(const AliITSresponseSSD& ob){
+ // Assignment operator
+ this->~AliITSresponseSSD();
+ new(this) AliITSresponseSSD(ob);
+ return *this;
}
-//______________________________________________________________________
-void AliITSresponseSSD::GetDetParam(Float_t *par){
- // get det param
- Int_t i;
- for (i=0; i<fNPar; i++) {
- par[i]=fDetPar[i];
- } // end for i
-}