27#ifndef G4UniformMagneticField_HH
28#define G4UniformMagneticField_HH
41 fFieldComponents[0] = FieldVector.
x();
42 fFieldComponents[1] = FieldVector.
y();
43 fFieldComponents[2] = FieldVector.
z();
51 if ( (vField<0) || (vTheta<0) || (vTheta>pi) || (vPhi<0) || (vPhi>twopi) )
53 G4Exception(
"G4TUniformMagneticField::G4TUniformMagneticField()",
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) ;
66 for (
G4int i=0; i<3; ++i)
67 fFieldComponents[i] = p.fFieldComponents[i];
73 if (&p ==
this)
return *
this;
74 for (
G4int i=0; i<3; ++i)
75 fFieldComponents[i] = p.fFieldComponents[i];
82 B[0]= fFieldComponents[0] ;
83 B[1]= fFieldComponents[1] ;
84 B[2]= fFieldComponents[2] ;
89 fFieldComponents[0] = newFieldVector.
x();
90 fFieldComponents[1] = newFieldVector.
y();
91 fFieldComponents[2] = newFieldVector.
z();
106 this->fFieldComponents[1],
107 this->fFieldComponents[2]) );
G4double B(G4double temperature)
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *description)
CLHEP::Hep3Vector G4ThreeVector