#include <G4TUniformMagneticField.hh>
Definition at line 34 of file G4TUniformMagneticField.hh.
◆ G4TUniformMagneticField() [1/3]
G4TUniformMagneticField::G4TUniformMagneticField |
( |
const G4ThreeVector & | FieldVector | ) |
|
|
inline |
Definition at line 38 of file G4TUniformMagneticField.hh.
40 {
41 fFieldComponents[0] = FieldVector.
x();
42 fFieldComponents[1] = FieldVector.
y();
43 fFieldComponents[2] = FieldVector.
z();
44 }
Referenced by Clone().
◆ G4TUniformMagneticField() [2/3]
Definition at line 47 of file G4TUniformMagneticField.hh.
50 {
51 if ( (vField<0) || (vTheta<0) || (vTheta>pi) || (vPhi<0) || (vPhi>twopi) )
52 {
53 G4Exception(
"G4TUniformMagneticField::G4TUniformMagneticField()",
55 }
56 fFieldComponents[0] = vField*std::sin(vTheta)*std::cos(vPhi) ;
57 fFieldComponents[1] = vField*std::sin(vTheta)*std::sin(vPhi) ;
58 fFieldComponents[2] = vField*std::cos(vTheta) ;
59 }
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *description)
◆ ~G4TUniformMagneticField()
virtual G4TUniformMagneticField::~G4TUniformMagneticField |
( |
| ) |
|
|
inlinevirtual |
◆ G4TUniformMagneticField() [3/3]
◆ Clone()
Reimplemented from G4Field.
Definition at line 103 of file G4TUniformMagneticField.hh.
104 {
106 this->fFieldComponents[1],
107 this->fFieldComponents[2]) );
108 }
CLHEP::Hep3Vector G4ThreeVector
◆ GetConstantFieldValue()
G4ThreeVector G4TUniformMagneticField::GetConstantFieldValue |
( |
| ) |
const |
|
inline |
Definition at line 94 of file G4TUniformMagneticField.hh.
95 {
97 fFieldComponents[1],
98 fFieldComponents[2]);
100 }
G4double B(G4double temperature)
◆ GetFieldValue()
void G4TUniformMagneticField::GetFieldValue |
( |
const G4double | yTrack[4], |
|
|
G4double * | B ) const |
|
inlinevirtual |
◆ operator=()
Definition at line 70 of file G4TUniformMagneticField.hh.
72 {
73 if (&p == this) return *this;
74 for (
G4int i=0; i<3; ++i)
75 fFieldComponents[i] = p.fFieldComponents[i];
76 return *this;
77 }
◆ SetFieldValue()
void G4TUniformMagneticField::SetFieldValue |
( |
const G4ThreeVector & | newFieldVector | ) |
|
|
inline |
Definition at line 87 of file G4TUniformMagneticField.hh.
88 {
89 fFieldComponents[0] = newFieldVector.
x();
90 fFieldComponents[1] = newFieldVector.
y();
91 fFieldComponents[2] = newFieldVector.
z();
92 }
The documentation for this class was generated from the following file: