#include <ShipBellField.h>
|
| | ShipBellField () |
| | ShipBellField (const char *name, Double_t Bpeak, Double_t Zmiddle, Int_t fOrient=1, Double_t Btube=500.) |
| | ShipBellField (ShipFieldPar *fieldPar) |
| | ~ShipBellField () override |
| Double_t | GetBx (Double_t x, Double_t y, Double_t z) override |
| Double_t | GetBy (Double_t x, Double_t y, Double_t z) override |
| Double_t | GetBz (Double_t x, Double_t y, Double_t z) override |
| void | IncludeTarget (Double_t xy, Double_t z, Double_t l) |
| void | Print (Option_t *="") const override |
Definition at line 26 of file ShipBellField.h.
◆ ShipBellField() [1/3]
| ShipBellField::ShipBellField |
( |
| ) |
|
◆ ShipBellField() [2/3]
| ShipBellField::ShipBellField |
( |
const char * | name, |
|
|
Double_t | Bpeak, |
|
|
Double_t | Zmiddle, |
|
|
Int_t | fOrient = 1, |
|
|
Double_t | Btube = 500. ) |
|
explicit |
Standard constructor
- Parameters
-
| name | Object name |
| Bpeak | peak field.. |
| Zmiddle | middle of the magnet (global coordinates) |
| Btube | largest radius of the tube ellips (inside) |
Definition at line 36 of file ShipBellField.cxx.
◆ ShipBellField() [3/3]
Constructor from ShipFieldPar
Definition at line 47 of file ShipBellField.cxx.
49 if (!fieldPar) {
50 cerr << "-W- ShipBellField::ShipBellField: empty parameter container!"
51 << endl;
52 fType = 0;
53 } else {
58 }
59}
Double_t GetMiddle() const
Double_t GetBtube() const
◆ ~ShipBellField()
| ShipBellField::~ShipBellField |
( |
| ) |
|
|
overridedefault |
◆ ClassDefOverride()
◆ GetBx()
| Double_t ShipBellField::GetBx |
( |
Double_t | x, |
|
|
Double_t | y, |
|
|
Double_t | z ) |
|
override |
Get components of field at a given point
- Parameters
-
| x,y,z | Point coordinates [cm] |
Definition at line 74 of file ShipBellField.cxx.
74 {
76 return 0.;
77 } else {
78 Double_t zlocal = fabs(z -
fMiddle) / 100.;
79
80
81
82
83 Double_t bx = 0.;
84
85 if ((fabs(x) < 2.7 *
m) && (fabs(y) <
fBtube + 0.2 *
m)) {
86 if (zlocal < 3.8) {
87 bx = 0.14361 * exp(-0.5 * pow((zlocal - 0.45479E-01) / 2.5046, 2.));
88 } else if (zlocal < 11.9) {
89 bx = 0.19532 - 0.61512E-01 * zlocal + 0.68447E-02 * pow(zlocal, 2.) -
90 0.25672E-03 * pow(zlocal, 3.);
91 }
93 }
94
95
96 return bx;
97 }
98}
◆ GetBy()
| Double_t ShipBellField::GetBy |
( |
Double_t | x, |
|
|
Double_t | y, |
|
|
Double_t | z ) |
|
override |
Definition at line 103 of file ShipBellField.cxx.
103 {
104 Double_t by = 0.;
106
109 }
113 }
115 Double_t zlocal = (
z -
fMiddle) / 100.;
116 by =
fPeak / (1. + pow(fabs(zlocal) / 2.1, 6.));
117
118 }
119 return by;
120}
◆ GetBz()
| Double_t ShipBellField::GetBz |
( |
Double_t | x, |
|
|
Double_t | y, |
|
|
Double_t | z ) |
|
override |
◆ IncludeTarget()
| void ShipBellField::IncludeTarget |
( |
Double_t | xy, |
|
|
Double_t | z, |
|
|
Double_t | l ) |
◆ Print()
| void ShipBellField::Print |
( |
Option_t * | = "" | ) |
const |
|
override |
Screen output
Definition at line 128 of file ShipBellField.cxx.
128 {
129 cout << "======================================================" << endl;
130 cout << "---- " << fTitle << " : " << fName << endl;
131 cout << "----" << endl;
132 cout << "---- Field type : Bell" << endl;
133 cout << "----" << endl;
134 cout.precision(4);
135 cout <<
"---- Peak field : " <<
fPeak <<
" kG" << endl;
136 cout <<
"---- Middle (z centre) : " <<
fMiddle <<
" cm" << endl;
137 cout <<
"---- Btube : " <<
fBtube <<
" cm" << endl;
138 cout <<
"---- Orientation : " <<
fOrient << endl;
139 cout <<
"---- Include target : " << (
fInclTarget ?
"yes" :
"no") << endl;
140 cout << "======================================================" << endl;
141}
◆ fBtube
| Double_t ShipBellField::fBtube |
|
private |
◆ fInclTarget
| Bool_t ShipBellField::fInclTarget |
|
private |
◆ fMiddle
| Double_t ShipBellField::fMiddle |
|
private |
◆ fOrient
| Int_t ShipBellField::fOrient {1} |
|
private |
◆ fPeak
| Double_t ShipBellField::fPeak |
|
private |
◆ targetL
| Double_t ShipBellField::targetL |
|
private |
◆ targetXY
| Double_t ShipBellField::targetXY |
|
private |
◆ targetZ0
| Double_t ShipBellField::targetZ0 |
|
private |
The documentation for this class was generated from the following files: