18#include "BDSFieldEM.hh"
19#include "BDSFieldEMGlobalPlacement.hh"
21#include "G4ThreeVector.hh"
26BDSFieldEMGlobalPlacement::BDSFieldEMGlobalPlacement(
BDSFieldEM* fieldIn):
29 finiteStrength = field->FiniteStrength();
32BDSFieldEMGlobalPlacement::~BDSFieldEMGlobalPlacement()
38 const G4double t)
const
41 {
return std::make_pair(G4ThreeVector(),G4ThreeVector());}
47 const G4double t)
const
49 G4bool foundAPlacementVolume =
false;
50 G4ThreeVector localPosition =
ConvertToLocal(position, foundAPlacementVolume);
51 if (!foundAPlacementVolume)
52 {
return std::make_pair(G4ThreeVector(),G4ThreeVector());}
virtual std::pair< G4ThreeVector, G4ThreeVector > GetField(const G4ThreeVector &position, const G4double t) const
virtual std::pair< G4ThreeVector, G4ThreeVector > GetFieldTransformed(const G4ThreeVector &position, const G4double t) const
BDSFieldEM * field
The field on which this is based.
Interface for BDSIM electro-magnetic fields that may or may not be local.
virtual std::pair< G4ThreeVector, 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