9 #ifndef MAG_MAGNETICFIELD_H 10 #define MAG_MAGNETICFIELD_H 17 #include "Geant4/G4ThreeVector.hh" 20 #include "TGeoVolume.h" 32 std::vector<std::vector<float>>
br;
33 std::vector<std::vector<float>>
bz;
34 size_t nr()
const {
return br.size(); };
48 using Field3D = std::vector<std::vector<std::vector<float>>>;
92 virtual std::vector<MagneticFieldDescription>
const& Fields()
const = 0;
95 virtual size_t NumFields()
const = 0;
101 virtual std::string
const& MagnetizedVolume(
size_t f)
const = 0;
104 virtual G4ThreeVector
const FieldAtPoint(G4ThreeVector
const& p=G4ThreeVector(0))
const = 0;
109 virtual G4ThreeVector
const UniformFieldInVolume(std::string
const& volName)
const = 0;
119 #endif // MAG_MAGNETICFIELD_H G4ThreeVector fField
description of the field (uniform only)
std::vector< std::vector< float > > br
float fScaleFactor
Used to scale the magnetic field.
std::string fFieldMapFilename
file name for reading in the field map
TGeoVolume * fGeoVol
pointer to TGeoVolume with the field
MagFieldMode_t fMode
type of field used
RZFieldMap fRZFieldMap
RZ field map if needed.
std::vector< std::vector< float > > bz
enum mag::MagneticFieldMode MagFieldMode_t
std::vector< std::vector< std::vector< float >>> Field3D
G4String fVolume
G4 volume containing the field.
XYZFieldMap fXYZFieldMap
XYZ field map if needed.