CbmRoot
CbmFieldMapDistorted.cxx
Go to the documentation of this file.
1 // -------------------------------------------------------------------------
2 // ----- CbmFieldMapDistorted source file -----
3 // ----- Created 18/01/08 by E.Litvinenko -----
4 // -------------------------------------------------------------------------
5 #include "CbmFieldMapDistorted.h"
6 
7 #include "CbmFieldConst.h" // for CbmFieldConst
8 #include "CbmFieldMapSym1.h" // for CbmFieldMapSym1
9 #include "CbmFieldMapSym2.h" // for CbmFieldMapSym2
10 #include "CbmFieldMapSym3.h" // for CbmFieldMapSym3
11 #include "CbmFieldPar.h" // for CbmFieldPar, kTypeDistorted
12 
13 #include <FairField.h> // for FairField
14 
15 #include <TFile.h> // for TFile, gFile
16 #include <TFormula.h> // for TFormula
17 #include <TH1.h> // for TH1D
18 #include <TSystem.h> // for TSystem, gSystem, kFileExists
19 
20 #include <iostream> // for operator<<, endl, ostream, basic_ostream
21 #include <string.h> // for strlen
22 
23 using std::cerr;
24 using std::cout;
25 using std::endl;
26 
27 // ------------- Default constructor ----------------------------------
29  : CbmFieldMap()
30  , fParentField(nullptr)
31  , fTypeOfParent(1)
32  , fDistortionFilename("")
33  , fBxDistortionFormulaMult(nullptr)
34  , fBxDistortionFormulaAdd(nullptr)
35  , fByDistortionFormulaMult(nullptr)
36  , fByDistortionFormulaAdd(nullptr)
37  , fBzDistortionFormulaMult(nullptr)
38  , fBzDistortionFormulaAdd(nullptr) {
39  fType = kTypeDistorted;
40 }
41 // ------------------------------------------------------------------------
42 
43 
44 // ------------- Standard constructor (with FieldMap Parent Field ) ---------------------------------
46  const char* pfDistortionFilename,
47  const char* parentName,
48  const char* fileTypeParent,
49  Int_t pfTypeOfParent)
50  : CbmFieldMap()
51  , fParentField(nullptr)
52  , fTypeOfParent(pfTypeOfParent)
53  , fDistortionFilename(pfDistortionFilename)
54  , fBxDistortionFormulaMult(nullptr)
55  , fBxDistortionFormulaAdd(nullptr)
56  , fByDistortionFormulaMult(nullptr)
57  , fByDistortionFormulaAdd(nullptr)
58  , fBzDistortionFormulaMult(nullptr)
59  , fBzDistortionFormulaAdd(nullptr) {
60  fName = mapName;
61  fType = kTypeDistorted;
62 
63  switch (pfTypeOfParent) {
64  case 3:
65  fParentField = new CbmFieldMapSym3(parentName, fileTypeParent);
66  break;
67  case 2:
68  fParentField = new CbmFieldMapSym2(parentName, fileTypeParent);
69  break;
70  case 5:
71  fParentField = new CbmFieldMapSym1(parentName, fileTypeParent);
72  break;
73  default: fParentField = new CbmFieldMap(parentName, fileTypeParent); break;
74  }
75 }
76 // ------------------------------------------------------------------------
77 
78 // ------------- Constructor (with Constant Parent Field ) -------------------------
80  Double_t xMax,
81  Double_t yMin,
82  Double_t yMax,
83  Double_t zMin,
84  Double_t zMax,
85  Double_t bX,
86  Double_t bY,
87  Double_t bZ,
88  const char* mapName,
89  const char* pfDistortionFilename,
90  const char* parentname)
91  : CbmFieldMap()
92  , fParentField(new CbmFieldConst(parentname,
93  xMin,
94  xMax,
95  yMin,
96  yMax,
97  zMin,
98  zMax,
99  bX,
100  bY,
101  bZ))
102  , fTypeOfParent(0)
103  , fDistortionFilename(pfDistortionFilename)
104  , fBxDistortionFormulaMult(nullptr)
105  , fBxDistortionFormulaAdd(nullptr)
106  , fByDistortionFormulaMult(nullptr)
107  , fByDistortionFormulaAdd(nullptr)
108  , fBzDistortionFormulaMult(nullptr)
109  , fBzDistortionFormulaAdd(nullptr) {
110  fName = mapName;
111  fType = kTypeDistorted;
112 }
113 
114 
115 // ------------- Constructor from CbmFieldPar -------------------------
117  : CbmFieldMap()
118  , fParentField(nullptr)
119  , fTypeOfParent(0)
120  , fDistortionFilename("")
121  , fBxDistortionFormulaMult(nullptr)
122  , fBxDistortionFormulaAdd(nullptr)
123  , fByDistortionFormulaMult(nullptr)
124  , fByDistortionFormulaAdd(nullptr)
125  , fBzDistortionFormulaMult(nullptr)
126  , fBzDistortionFormulaAdd(nullptr) {
127  if (fieldPar) {
128  fieldPar->MapName(fName);
129  fType = fieldPar->GetType();
130 
131  if (
132  fType
133  == kTypeDistorted) { // normal case of distorted field map parameters as input
134 
135  fTypeOfParent = fieldPar->GetTypeOfParent();
136 
137  TString parentName;
138  fieldPar->GetParentName(parentName);
139 
140  switch (fTypeOfParent) {
141  case 3:
142  fParentField = new CbmFieldMapSym3(parentName.Data(), "R");
143  break;
144  case 2:
145  fParentField = new CbmFieldMapSym2(parentName.Data(), "R");
146  break;
147  case 5:
148  fParentField = new CbmFieldMapSym1(parentName.Data(), "R");
149  break;
150  case 0:
151  fParentField = new CbmFieldConst(parentName.Data(),
152  fieldPar->GetXmin(),
153  fieldPar->GetXmax(),
154  fieldPar->GetYmin(),
155  fieldPar->GetYmax(),
156  fieldPar->GetZmin(),
157  fieldPar->GetZmax(),
158  fieldPar->GetBx(),
159  fieldPar->GetBy(),
160  fieldPar->GetBz());
161  break;
162  default: fParentField = new CbmFieldMap(parentName.Data(), "R"); break;
163  }
164 
165  if ((fParentField) && (fTypeOfParent)) { // for field map parent
167  ->SetPosition(fieldPar->GetPositionX(),
168  fieldPar->GetPositionY(),
169  fieldPar->GetPositionZ());
170  ((CbmFieldMap*) fParentField)->SetScale(fieldPar->GetScale());
171  }
172 
174  } else { // try to create a distorted field map from the parameters of constant field or normal field map as input
175  switch (fType) {
176  case 3: fParentField = new CbmFieldMapSym3(fieldPar); break;
177  case 2: fParentField = new CbmFieldMapSym2(fieldPar); break;
178  case 5: fParentField = new CbmFieldMapSym1(fieldPar); break;
179  case 0: fParentField = new CbmFieldConst(fieldPar); break;
180  default: fParentField = new CbmFieldMap(fieldPar); break;
181  }
182  fType = kTypeDistorted;
183  fDistortionFilename = "";
184  }
185  }
186 }
187 // ------------------------------------------------------------------------
188 
189 
190 // ------------ Destructor --------------------------------------------
192 // ------------------------------------------------------------------------
193 
194 
195 // ----------- Intialisation ------------------------------------------
197  fParentField->Init();
198  fParentField->Print("");
201 
202  // Fill values needed in the Print() function. This is needed to allow
203  // a constant Print() function.
204  Double_t po[3], b[3];
205  po[0] = 0;
206  po[1] = 0;
207  po[2] = 0;
208  GetFieldValue(po, b);
209  fBxOrigin = b[0];
210  fByOrigin = b[1];
211  fBzOrigin = b[2];
212 }
213 // ------------------------------------------------------------------------
214 
215 
216 // ------------- Set from parent CbmField -------------------------
217 void CbmFieldMapDistorted::SetFromParent(FairField* field) {
218  fTypeOfParent = 0;
219  fParentField = field;
220 
221  if (field) {
222  fTypeOfParent = field->GetType();
223 
224  CbmFieldConst* field0 = 0;
225  CbmFieldMap* field1 = 0;
226 
227  switch (fTypeOfParent) {
228 
229  case 0:
230  field0 = (CbmFieldConst*) field;
231  fXmin = field0->GetXmin();
232  fXmax = field0->GetXmax();
233  fYmin = field0->GetYmin();
234  fZmax = field0->GetYmax();
235  fZmin = field0->GetZmin();
236  fZmax = field0->GetZmax();
237  break;
238 
239  default:
240  field1 = (CbmFieldMap*) field;
241  fXmin = field1->GetXmin();
242  fXmax = field1->GetXmax();
243  fYmin = field1->GetYmin();
244  fZmax = field1->GetYmax();
245  fZmin = field1->GetZmin();
246  fZmax = field1->GetZmax();
247 
248  fNx = field1->GetNx();
249  fNy = field1->GetNy();
250  fNz = field1->GetNz();
251 
252  fXstep = field1->GetXstep();
253  fYstep = field1->GetYstep();
254  fZstep = field1->GetZstep();
255 
256  fScale = field1->GetScale();
257  fPosX = field1->GetPositionX();
258  fPosY = field1->GetPositionY();
259  fPosZ = field1->GetPositionZ();
260  break;
261  }
262  }
263 }
264 // ------------------------------------------------------------------------
265 
266 // ----------- Read Distortion Formulas from Distortion File ------------------------------------------
268  TFile* filesave = gFile;
269  gFile = 0;
270  if (filename) {
271  if (strlen(filename)) { fDistortionFilename = filename; }
272  }
273  if (fDistortionFilename.Data()) {
274  if (strlen(fDistortionFilename.Data())) {
275  if (gSystem->AccessPathName(fDistortionFilename + ".root", kFileExists)) {
276  cerr << "CbmFieldMapDistorted::ReadDistortionInformation Warning: file "
277  << (fDistortionFilename.Data()) << " not exists yet !!!" << endl;
278  } else {
279  TFile* f = new TFile(fDistortionFilename + ".root");
280  if (f) {
282  (TFormula*) f->Get("BxDistortionFormulaMult");
284  (TFormula*) f->Get("BxDistortionFormulaAdd");
286  (TFormula*) f->Get("ByDistortionFormulaMult");
288  (TFormula*) f->Get("ByDistortionFormulaAdd");
290  (TFormula*) f->Get("BzDistortionFormulaMult");
292  (TFormula*) f->Get("BzDistortionFormulaAdd");
293  f->Close();
294  } else {
295  cerr << "CbmFieldMapDistorted::ReadDistortionInformation ERROR: file "
296  << (fDistortionFilename.Data()) << " can not be read !!!"
297  << endl;
298  }
299  }
300  }
301  }
302  gFile = filesave;
303 }
304 
305 // ----------- Write Distortion Formulas to Distortion File ------------------------------------------
307  TFile* filesave = gFile;
308  gFile = 0;
309 
310  if (filename) {
311  if (strlen(filename)) { fDistortionFilename = filename; }
312  }
313 
314  if (fDistortionFilename.Data()) {
315  if (strlen(fDistortionFilename.Data())) {
316  TFile* f = new TFile(fDistortionFilename + ".root", "RECREATE");
317  if (f) {
318 
320  fBxDistortionFormulaMult->Write("BxDistortionFormulaMult");
322  fBxDistortionFormulaAdd->Write("BxDistortionFormulaAdd");
323 
325  fByDistortionFormulaMult->Write("ByDistortionFormulaMult");
327  fByDistortionFormulaAdd->Write("ByDistortionFormulaAdd");
328 
330  fBzDistortionFormulaMult->Write("BzDistortionFormulaMult");
332  fBzDistortionFormulaAdd->Write("BzDistortionFormulaAdd");
333 
334  f->Write();
335  f->Close();
336  }
337  }
338  }
339  gFile = filesave;
340 }
341 
342 // ---------------Getter and Setter for Distortion Formulas------------------------------
343 TFormula*
344 CbmFieldMapDistorted::GetDistortionFormula(const char* component_option,
345  const char* action_option) {
346  // component_option: "x","y","z"; action_option: "m","a"
347 
348  TString co = component_option;
349  TString ao = action_option;
350 
351  if (co.Contains("y") && ao.Contains("m")) return fByDistortionFormulaMult;
352  if (co.Contains("y") && ao.Contains("a")) return fByDistortionFormulaAdd;
353 
354  if (co.Contains("x") && ao.Contains("m")) return fBxDistortionFormulaMult;
355  if (co.Contains("x") && ao.Contains("a")) return fBxDistortionFormulaAdd;
356 
357  if (co.Contains("z") && ao.Contains("m")) return fBzDistortionFormulaMult;
358  if (co.Contains("z") && ao.Contains("a")) return fBzDistortionFormulaAdd;
359 
360  return 0;
361 }
362 
363 Bool_t
364 CbmFieldMapDistorted::SetDistortionFormula(TFormula* parDistortionFormula,
365  const char* component_option,
366  const char* action_option) {
367  TString co = component_option;
368  TString ao = action_option;
369  Int_t counter = 0;
370 
371  if (co.Contains("y") && ao.Contains("m")) {
372  fByDistortionFormulaMult = parDistortionFormula;
373  counter++;
374  }
375  if (co.Contains("y") && ao.Contains("a")) {
376  fByDistortionFormulaAdd = parDistortionFormula;
377  counter++;
378  }
379 
380  if (co.Contains("x") && ao.Contains("m")) {
381  fBxDistortionFormulaMult = parDistortionFormula;
382  counter++;
383  }
384  if (co.Contains("x") && ao.Contains("a")) {
385  fBxDistortionFormulaAdd = parDistortionFormula;
386  counter++;
387  }
388 
389  if (co.Contains("z") && ao.Contains("m")) {
390  fBzDistortionFormulaMult = parDistortionFormula;
391  counter++;
392  }
393  if (co.Contains("z") && ao.Contains("a")) {
394  fBzDistortionFormulaAdd = parDistortionFormula;
395  counter++;
396  }
397  return (counter > 0);
398 }
399 
400 Bool_t
401 CbmFieldMapDistorted::SetDistortionFormula(const char* parDistortionFormulaText,
402  const char* component_option,
403  const char* action_option) {
404  TString co = component_option;
405  TString ao = action_option;
406  Int_t counter = 0;
407 
408  if (co.Contains("y") && ao.Contains("m")) {
410  new TFormula("ByDistortionFormulaMult", parDistortionFormulaText);
411  counter++;
412  }
413  if (co.Contains("y") && ao.Contains("a")) {
415  new TFormula("ByDistortionFormulaAdd", parDistortionFormulaText);
416  counter++;
417  }
418 
419  if (co.Contains("x") && ao.Contains("m")) {
421  new TFormula("BxDistortionFormulaMult", parDistortionFormulaText);
422  counter++;
423  }
424  if (co.Contains("x") && ao.Contains("a")) {
426  new TFormula("BxDistortionFormulaAdd", parDistortionFormulaText);
427  counter++;
428  }
429 
430  if (co.Contains("z") && ao.Contains("m")) {
432  new TFormula("BzDistortionFormulaMult", parDistortionFormulaText);
433  counter++;
434  }
435  if (co.Contains("z") && ao.Contains("a")) {
437  new TFormula("BzDistortionFormulaAdd", parDistortionFormulaText);
438  counter++;
439  }
440  return (counter > 0);
441 }
442 // ------------------------------------------------------------------------
443 
444 // ----------- Get x component of the field ---------------------------
445 Double_t CbmFieldMapDistorted::GetBx(Double_t x, Double_t y, Double_t z) {
446  Double_t bx = fParentField->GetBx(x, y, z);
447 
449  bx *= fBxDistortionFormulaMult->Eval(x, y, z);
450  }
451 
452  if (fBxDistortionFormulaAdd) { bx += fBxDistortionFormulaAdd->Eval(x, y, z); }
453 
454  return bx;
455 }
456 
457 // ----------- Get y component of the field ---------------------------
458 Double_t CbmFieldMapDistorted::GetBy(Double_t x, Double_t y, Double_t z) {
459  Double_t by = fParentField->GetBy(x, y, z);
460 
462  by *= fByDistortionFormulaMult->Eval(x, y, z);
463  }
464  if (fByDistortionFormulaAdd) { by += fByDistortionFormulaAdd->Eval(x, y, z); }
465 
466  return by;
467 }
468 
469 // ----------- Get z component of the field ---------------------------
470 Double_t CbmFieldMapDistorted::GetBz(Double_t x, Double_t y, Double_t z) {
471  Double_t bz = fParentField->GetBz(x, y, z);
472 
474  bz *= fBzDistortionFormulaMult->Eval(x, y, z);
475  }
476  if (fBzDistortionFormulaAdd) { bz += fBzDistortionFormulaAdd->Eval(x, y, z); }
477 
478  return bz;
479 }
480 
481 void CbmFieldMapDistorted::Print(Option_t*) const {
482  cout << "============================================================="
483  << endl;
484  cout << "---- " << fTitle << " : " << fName << endl;
485 
486  cout << "== Parent Field: ==" << endl;
487  fParentField->Print("");
488  cout << "==============================" << endl;
489 
490  cout << "== Distortion Information File : ==" << endl;
491  cout << fDistortionFilename << endl;
492  cout << "==============================" << endl;
493 
494  cout << "== Bx Distortion Formula Mult : ==" << endl;
496  cout << fBxDistortionFormulaMult->GetExpFormula("p") << endl;
497  cout << "== Bx Distortion Formula Add : ==" << endl;
499  cout << fBxDistortionFormulaAdd->GetExpFormula("p") << endl;
500  cout << "==============================" << endl;
501 
502  cout << "== By Distortion Formula Mult : ==" << endl;
504  cout << fByDistortionFormulaMult->GetExpFormula("p") << endl;
505  cout << "== By Distortion Formula Add : ==" << endl;
507  cout << fByDistortionFormulaAdd->GetExpFormula("p") << endl;
508  cout << "==============================" << endl;
509 
510  cout << "== Bz Distortion Formula Mult : ==" << endl;
512  cout << fBzDistortionFormulaMult->GetExpFormula("p") << endl;
513  cout << "== Bz Distortion Formula Add : ==" << endl;
515  cout << fBzDistortionFormulaAdd->GetExpFormula("p") << endl;
516  cout << "==============================" << endl;
517 
518 
519  cout << "---- Distorted field at origin is ( " << fBxOrigin << ", "
520  << fByOrigin << ", " << fBzOrigin << ") kG" << endl;
521 
522  cout << "============================================================="
523  << endl;
524 }
525 // ------------------------------------------------------------------------
526 
527 
528 // ----- Set the position of the field centre in global coordinates -----
529 void CbmFieldMapDistorted::SetPosition(Double_t x, Double_t y, Double_t z) {
530  fPosX = x;
531  fPosY = y;
532  fPosZ = z;
533  if (fTypeOfParent) ((CbmFieldMap*) fParentField)->SetPosition(x, y, z);
534 }
535 // ------------------------------------------------------------------------
536 
537 // ---------------------Set a global field scaling factor------------------
538 void CbmFieldMapDistorted::SetScale(Double_t factor) {
539  fScale = factor;
540  if (fTypeOfParent) ((CbmFieldMap*) fParentField)->SetScale(factor);
541 }
542 // ------------------------------------------------------------------------
543 
544 // ---------------------Plot distorted and parend field (By component)-----
545 void CbmFieldMapDistorted::PlotBy(Int_t n, Double_t zmin, Double_t zmax) {
546  TH1D *h, *hp;
547  Int_t n0 = n;
548  if (!n) n0 = 1;
549  Double_t dz = (zmax - zmin) / n0;
550 
551  h = new TH1D("hField", fName, n, zmin, zmax);
552  for (Int_t i = 0; i < n0; i++)
553  h->SetBinContent(i + 1, GetBy(0., 0., zmin + i * dz));
554  h->SetLineWidth(2);
555  h->Draw();
556 
557  if (fParentField) {
558  hp = new TH1D("hFieldParent", fParentField->GetName(), n, zmin, zmax);
559  for (Int_t i = 0; i < n0; i++)
560  hp->SetBinContent(i + 1, fParentField->GetBy(0., 0., zmin + i * dz));
561  hp->SetLineColor(2);
562  hp->Draw("sames");
563  }
564 }
565 // ------------------------------------------------------------------------
CbmFieldMap::GetYstep
Double_t GetYstep() const
Definition: CbmFieldMap.h:140
CbmFieldMap::GetZstep
Double_t GetZstep() const
Definition: CbmFieldMap.h:141
CbmFieldMapSym3
Definition: CbmFieldMapSym3.h:35
f
float f
Definition: L1/vectors/P4_F32vec4.h:24
CbmFieldMapDistorted::SetDistortionFormula
virtual Bool_t SetDistortionFormula(TFormula *parDistortionFormula, const char *component_option="y", const char *action_option="m")
Definition: CbmFieldMapDistorted.cxx:364
CbmFieldPar::GetPositionY
Double_t GetPositionY() const
Definition: CbmFieldPar.h:69
CbmFieldPar::GetYmax
Double_t GetYmax() const
Definition: CbmFieldPar.h:61
CbmFieldPar::GetParentName
void GetParentName(TString &parentname)
Definition: CbmFieldPar.h:76
CbmFieldMapDistorted::Init
virtual void Init()
Definition: CbmFieldMapDistorted.cxx:196
CbmFieldMap::fYmin
Double_t fYmin
Definition: CbmFieldMap.h:210
CbmFieldMapDistorted::fTypeOfParent
Int_t fTypeOfParent
Definition: CbmFieldMapDistorted.h:129
CbmFieldMap::fScale
Double_t fScale
Definition: CbmFieldMap.h:201
CbmFieldPar::GetXmax
Double_t GetXmax() const
Definition: CbmFieldPar.h:59
CbmFieldPar::GetXmin
Double_t GetXmin() const
Definition: CbmFieldPar.h:58
CbmFieldMap::fBxOrigin
Double_t fBxOrigin
Interpolated field (1-dim)
Definition: CbmFieldMap.h:230
CbmFieldMapDistorted::fParentField
FairField * fParentField
Definition: CbmFieldMapDistorted.h:126
i
int i
Definition: L1/vectors/P4_F32vec4.h:25
CbmFieldMapDistorted::fBxDistortionFormulaMult
TFormula * fBxDistortionFormulaMult
Definition: CbmFieldMapDistorted.h:135
CbmFieldMap::GetBy
TArrayF * GetBy() const
Definition: CbmFieldMap.h:159
CbmFieldMap::GetPositionY
Double_t GetPositionY() const
Definition: CbmFieldMap.h:149
CbmFieldMap::fXmin
Double_t fXmin
Definition: CbmFieldMap.h:209
CbmFieldMapDistorted::fByDistortionFormulaAdd
TFormula * fByDistortionFormulaAdd
Definition: CbmFieldMapDistorted.h:138
CbmFieldMapSym2
Definition: CbmFieldMapSym2.h:35
CbmFieldMap::fPosZ
Double_t fPosZ
Definition: CbmFieldMap.h:205
CbmFieldMapDistorted::fBzDistortionFormulaAdd
TFormula * fBzDistortionFormulaAdd
Definition: CbmFieldMapDistorted.h:140
CbmFieldPar::GetYmin
Double_t GetYmin() const
Definition: CbmFieldPar.h:60
CbmFieldMap::fNz
Int_t fNz
Definition: CbmFieldMap.h:215
CbmFieldMap::GetXmin
Double_t GetXmin() const
Definition: CbmFieldMap.h:133
CbmFieldMap::fNy
Int_t fNy
Definition: CbmFieldMap.h:215
CbmFieldPar::GetPositionX
Double_t GetPositionX() const
Definition: CbmFieldPar.h:68
CbmFieldMapDistorted::SetFromParent
virtual void SetFromParent(FairField *field)
Definition: CbmFieldMapDistorted.cxx:217
CbmFieldMap::GetNx
Int_t GetNx() const
Definition: CbmFieldMap.h:142
CbmFieldMap::GetNy
Int_t GetNy() const
Definition: CbmFieldMap.h:143
CbmFieldMap::GetPositionZ
Double_t GetPositionZ() const
Definition: CbmFieldMap.h:150
CbmFieldMapDistorted::GetDistortionFormula
virtual TFormula * GetDistortionFormula(const char *component_option="y", const char *action_option="m")
Definition: CbmFieldMapDistorted.cxx:344
CbmFieldMap::fXstep
Double_t fXstep
Definition: CbmFieldMap.h:209
CbmFieldMap::GetXmax
Double_t GetXmax() const
Definition: CbmFieldMap.h:136
CbmFieldMap::fPosX
Double_t fPosX
Definition: CbmFieldMap.h:205
CbmFieldConst::GetZmax
Double_t GetZmax() const
Definition: CbmFieldConst.h:95
CbmFieldMap::fBzOrigin
Double_t fBzOrigin
y-component of the field at the origin
Definition: CbmFieldMap.h:232
CbmFieldPar::GetTypeOfParent
Int_t GetTypeOfParent() const
Definition: CbmFieldPar.h:77
CbmFieldConst.h
CbmFieldConst::GetXmin
Double_t GetXmin() const
Definition: CbmFieldConst.h:90
CbmFieldMap::fZstep
Double_t fZstep
Definition: CbmFieldMap.h:211
CbmFieldPar::GetScale
Double_t GetScale() const
Definition: CbmFieldPar.h:71
CbmFieldConst::GetXmax
Double_t GetXmax() const
Definition: CbmFieldConst.h:91
CbmFieldMap::fZmin
Double_t fZmin
Definition: CbmFieldMap.h:211
h
Data class with information on a STS local track.
CbmFieldMap::GetBz
TArrayF * GetBz() const
Definition: CbmFieldMap.h:160
CbmFieldMap
Definition: CbmFieldMap.h:34
CbmFieldMapDistorted::SetScale
virtual void SetScale(Double_t factor)
Definition: CbmFieldMapDistorted.cxx:538
CbmFieldMapSym1
Definition: CbmFieldMapSym1.h:33
CbmFieldMap::GetXstep
Double_t GetXstep() const
Definition: CbmFieldMap.h:139
CbmFieldMap::fPosY
Double_t fPosY
Definition: CbmFieldMap.h:205
CbmFieldMapDistorted::fBxDistortionFormulaAdd
TFormula * fBxDistortionFormulaAdd
Definition: CbmFieldMapDistorted.h:136
CbmFieldMapDistorted::fDistortionFilename
TString fDistortionFilename
Definition: CbmFieldMapDistorted.h:132
CbmFieldPar.h
CbmFieldMapDistorted::PlotBy
void PlotBy(Int_t n=250, Double_t zmin=-50, Double_t zmax=450)
Definition: CbmFieldMapDistorted.cxx:545
CbmFieldMap::GetZmin
Double_t GetZmin() const
Definition: CbmFieldMap.h:135
CbmFieldConst::GetZmin
Double_t GetZmin() const
Definition: CbmFieldConst.h:94
CbmFieldMapSym3.h
CbmFieldMapDistorted::Print
virtual void Print(Option_t *="") const
Definition: CbmFieldMapDistorted.cxx:481
CbmFieldMapDistorted::CbmFieldMapDistorted
CbmFieldMapDistorted()
Definition: CbmFieldMapDistorted.cxx:28
CbmFieldMap::GetYmax
Double_t GetYmax() const
Definition: CbmFieldMap.h:137
CbmFieldMapDistorted::fByDistortionFormulaMult
TFormula * fByDistortionFormulaMult
getter/setter options: ("x","m"), ("x","a")
Definition: CbmFieldMapDistorted.h:137
CbmFieldPar::GetBx
Double_t GetBx() const
Definition: CbmFieldPar.h:64
CbmFieldPar::GetPositionZ
Double_t GetPositionZ() const
Definition: CbmFieldPar.h:70
CbmFieldConst::GetYmin
Double_t GetYmin() const
Definition: CbmFieldConst.h:92
CbmFieldPar::GetBy
Double_t GetBy() const
Definition: CbmFieldPar.h:65
CbmFieldPar::MapName
void MapName(TString &name)
Definition: CbmFieldPar.h:67
CbmFieldMap::fYstep
Double_t fYstep
Definition: CbmFieldMap.h:210
counter
int counter
Definition: CbmMvdSensorDigiToHitTask.cxx:72
CbmFieldMap::fZmax
Double_t fZmax
Definition: CbmFieldMap.h:211
CbmFieldPar::GetZmin
Double_t GetZmin() const
Definition: CbmFieldPar.h:62
CbmFieldMap::GetNz
Int_t GetNz() const
Definition: CbmFieldMap.h:144
CbmFieldMapDistorted.h
CbmFieldPar::GetType
Int_t GetType() const
Definition: CbmFieldPar.h:57
x
Double_t x
Definition: CbmMvdSensorDigiToHitTask.cxx:68
CbmFieldMap::GetZmax
Double_t GetZmax() const
Definition: CbmFieldMap.h:138
CbmFieldMapDistorted::SetPosition
virtual void SetPosition(Double_t x, Double_t y, Double_t z)
Definition: CbmFieldMapDistorted.cxx:529
CbmFieldMapDistorted::WriteDistortionInformation
void WriteDistortionInformation(const char *filename=0)
Definition: CbmFieldMapDistorted.cxx:306
CbmFieldMapDistorted::fBzDistortionFormulaMult
TFormula * fBzDistortionFormulaMult
getter/setter options: ("y","m"), ("y","a")
Definition: CbmFieldMapDistorted.h:139
y
Double_t y
Definition: CbmMvdSensorDigiToHitTask.cxx:68
CbmFieldMapDistorted::~CbmFieldMapDistorted
virtual ~CbmFieldMapDistorted()
Definition: CbmFieldMapDistorted.cxx:191
kTypeDistorted
const int kTypeDistorted
Definition: CbmFieldPar.h:29
CbmFieldConst
Definition: CbmFieldConst.h:28
CbmFieldMapSym2.h
CbmFieldPar::GetZmax
Double_t GetZmax() const
Definition: CbmFieldPar.h:63
CbmFieldPar::GetDistortionFilename
void GetDistortionFilename(TString &filename)
Definition: CbmFieldPar.h:73
CbmFieldConst::GetYmax
Double_t GetYmax() const
Definition: CbmFieldConst.h:93
CbmFieldMap::GetScale
Double_t GetScale() const
Definition: CbmFieldMap.h:154
CbmFieldMap::fNx
Int_t fNx
Definition: CbmFieldMap.h:215
CbmFieldMap::CbmFieldMap
CbmFieldMap()
Definition: CbmFieldMap.cxx:34
CbmFieldPar
Definition: CbmFieldPar.h:31
CbmFieldPar::GetBz
Double_t GetBz() const
Definition: CbmFieldPar.h:66
CbmFieldMapSym1.h
CbmFieldMapDistorted::ReadDistortionInformation
void ReadDistortionInformation(const char *filename=0)
Definition: CbmFieldMapDistorted.cxx:267
CbmFieldMap::fByOrigin
Double_t fByOrigin
x-component of the field at the origin
Definition: CbmFieldMap.h:231
CbmFieldMap::fXmax
Double_t fXmax
Definition: CbmFieldMap.h:209
CbmFieldMap::GetPositionX
Double_t GetPositionX() const
Definition: CbmFieldMap.h:148
CbmFieldMap::GetYmin
Double_t GetYmin() const
Definition: CbmFieldMap.h:134
CbmFieldMap::GetBx
TArrayF * GetBx() const
Definition: CbmFieldMap.h:158