1 #ifndef ALI_TPC_EX_BB_SHAPE_H
2 #define ALI_TPC_EX_BB_SHAPE_H
4 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5 * See cxx source for full Copyright notice */
7 // _________________________________________________________________
10 // <h2>AliExBBShape class </h2>
11 // The class calculates the space point distortions due to the B field
12 // shape imperfections using a second order technique based on integrals
13 // over Bz (e.g. int By/Bz) obtained via the AliMagF class. The essential
14 // input for this class is the magnetic field maps which can be set via the function SetBField.
16 // The class allows "effective Omega Tau" corrections.
18 // Begin_Macro(source)
20 // gROOT->SetStyle("Plain"); gStyle->SetPalette(1);
21 // TCanvas *c2 = new TCanvas("cAliTPCExBBShape","cAliTPCExBBShape",500,300);
22 // AliTPCExBBShape exb;
23 // AliMagF mag("mag","mag"); // 0.5 Tesla (solenoid)
24 // exb.SetBField(&mag); // use Bfield from AliMagF
25 // exb.SetOmegaTauT1T2(-0.32,1.,1.); // values ideally from OCDB
26 // exb.CreateHistoDRPhiinZR(0,100,100)->Draw("surf2");
32 // Date: 27/04/2010 <br>
33 // Authors: Magnus Mager, Jim Thomas, Stefan Rossegger
35 // _________________________________________________________________
37 #include "AliTPCCorrection.h"
41 class AliTPCExBBShape : public AliTPCCorrection {
44 virtual ~AliTPCExBBShape();
46 // initialization and update functions
48 virtual void Update(const TTimeStamp &timeStamp);
50 // common setters and getters for ExB
51 virtual void SetOmegaTauT1T2(Float_t omegaTau,Float_t t1,Float_t t2) {
53 const Float_t wt1=t1*omegaTau; fC1=wt1/(1.+wt1*wt1);
54 const Float_t wt2=t2*omegaTau; fC2=wt2*wt2/(1.+wt2*wt2);
56 void SetC1C2(Float_t c1,Float_t c2) {fC1=c1;fC2=c2;} // CAUTION: USE WITH CARE
57 Float_t GetC1() const {return fC1;}
58 Float_t GetC2() const {return fC2;}
60 // setters and getters for the magentic field map
61 void SetBField(const AliMagF *bField) {fBField=(AliMagF*)bField;}
62 AliMagF* GetBField() const {return fBField;}
64 virtual void GetCorrection(const Float_t x[],const Short_t roc,Float_t dx[]);
65 void GetBxAndByOverBz(const Float_t x[],const Short_t roc,Float_t BxByOverBz[]);
67 virtual void Print(Option_t* option="") const;
68 static Double_t GetBFieldXYZ(Double_t gx, Double_t gy, Double_t gz, Int_t axisType);
71 Float_t fC1; // coefficient C1 (compare Jim Thomas's notes for definitions)
72 Float_t fC2; // coefficient C2 (compare Jim Thomas's notes for definitions)
74 AliMagF *fBField; // pointer to magnetic field
76 AliTPCExBBShape & operator =(const AliTPCExBBShape);
77 AliTPCExBBShape(const AliTPCExBBShape&); //dummy copy contructor
79 ClassDef(AliTPCExBBShape,2);