18#include "BDSFieldMag.hh"
19#include "BDSFieldMagGlobalPlacement.hh"
21#include "G4ThreeVector.hh"
24BDSFieldMagGlobalPlacement::BDSFieldMagGlobalPlacement(
BDSFieldMag* fieldIn):
27 finiteStrength = field->FiniteStrength();
30BDSFieldMagGlobalPlacement::~BDSFieldMagGlobalPlacement()
36 const G4double t)
const
39 {
return G4ThreeVector();}
45 const G4double t)
const
47 G4bool foundAPlacementVolume =
false;
48 G4ThreeVector localPosition =
ConvertToLocal(position, foundAPlacementVolume);
49 if (!foundAPlacementVolume)
50 {
return G4ThreeVector();}
virtual G4ThreeVector GetFieldTransformed(const G4ThreeVector &position, const G4double t) const
virtual G4ThreeVector GetField(const G4ThreeVector &position, const G4double t=0) const
BDSFieldMag * field
The field on which this is based.
Interface for static magnetic fields that may or may not be local.
virtual G4ThreeVector GetFieldTransformed(const G4ThreeVector &position, const G4double t) const
Get the field value after applying transform for local offset.
G4bool finiteStrength
Flag to cache whether finite nor not.
G4ThreeVector ConvertToLocal(const G4ThreeVector &globalPosition, G4bool &foundAPlacementVolume) const
G4ThreeVector ConvertAxisToGlobal(const G4ThreeVector &localAxis) const