33#include "G4MagneticField.hh"
35#include "G4ChordFinder.hh"
36#include "G4FieldManager.hh"
37#include "G4MagIntegratorStepper.hh"
38#include "G4Mag_UsualEqRhs.hh"
39#include "G4PropagatorInField.hh"
40#include "G4TransportationManager.hh"
42#include "CLHEP/Random/RandGauss.h"
43#include "CLHEP/Random/RanecuEngine.h"
44#include "G4CashKarpRKF45.hh"
45#include "G4ClassicalRK4.hh"
46#include "G4ExplicitEuler.hh"
47#include "G4HelixExplicitEuler.hh"
48#include "G4HelixImplicitEuler.hh"
49#include "G4HelixSimpleRunge.hh"
50#include "G4ImplicitEuler.hh"
51#include "G4RKG3_Stepper.hh"
52#include "G4SimpleHeum.hh"
53#include "G4SimpleRunge.hh"
54#include "Randomize.hh"
56#include "GaudiKernel/MsgStream.h"
57#include "GaudiKernel/SmartDataPtr.h"
59#include "CLHEP/Geometry/Point3D.h"
60#include "CLHEP/Geometry/Vector3D.h"
61#include "CLHEP/Units/PhysicalConstants.h"
62#include "GaudiKernel/Bootstrap.h"
63#include "GaudiKernel/ISvcLocator.h"
66#include "SimUtil/ReadBoostRoot.hh"
69#include "G4SystemOfUnits.hh"
71#ifndef ENABLE_BACKWARDS_COMPATIBILITY
74#ifndef ENABLE_BACKWARDS_COMPATIBILITY
83 ISvcLocator* svcLocator = Gaudi::svcLocator();
84 StatusCode sc = svcLocator->service(
"MagneticFieldSvc",
m_pIMF );
85 if ( sc != StatusCode::SUCCESS )
86 { G4cout <<
"Unable to open Magnetic field service" << G4endl; }
103 HepPoint3D r( x, y, z );
107 else m_pIMF->uniFieldVector( r, b );
125 fEquation =
new G4Mag_UsualEqRhs(
this );
130 fFieldManager = G4TransportationManager::GetTransportationManager()->GetFieldManager();
131 G4cout <<
"before CreateStepperAndChordFinder" << G4endl;
141 G4cout <<
"The minimal step is equal to " <<
fMinStep / mm <<
" mm" << G4endl;
156 G4PropagatorInField* fieldPropagator =
157 G4TransportationManager::GetTransportationManager()->GetPropagatorInField();
158 G4cout <<
"LargestAcceptableStep is " << fieldPropagator->GetLargestAcceptableStep() / m
161 G4cout <<
"field has created" << G4endl;
162 G4cout <<
"fDelta_One_Step_Value is " <<
fFieldManager->GetDeltaOneStep() << G4endl;
163 G4cout <<
"fDelta_Intersection_Val is " <<
fFieldManager->GetDeltaIntersection() << G4endl;
164 G4cout <<
"fEpsilonMin is " <<
fFieldManager->GetMinimumEpsilonStep() << G4endl;
165 G4cout <<
"fEpsilonMax is " <<
fFieldManager->GetMaximumEpsilonStep() << G4endl;
181 G4cout <<
"G4ExplicitEuler is called" << G4endl;
185 G4cout <<
"G4ImplicitEuler is called" << G4endl;
189 G4cout <<
"G4SimpleRunge is called" << G4endl;
193 G4cout <<
"G4SimpleHeum is called" << G4endl;
197 G4cout <<
"G4ClassicalRK4 (default) is called" << G4endl;
201 G4cout <<
"G4HelixExplicitEuler is called" << G4endl;
205 G4cout <<
"G4HelixImplicitEuler is called" << G4endl;
209 G4cout <<
"G4HelixSimpleRunge is called" << G4endl;
213 G4cout <<
"G4CashKarpRKF45 is called" << G4endl;
217 G4cout <<
"G4RKG3_Stepper is called" << G4endl;
226 fFieldManager = G4TransportationManager::GetTransportationManager()->GetFieldManager();
230 fFieldManager = G4TransportationManager::GetTransportationManager()->GetFieldManager();
234 fFieldManager = G4TransportationManager::GetTransportationManager()->GetFieldManager();
238 fFieldManager = G4TransportationManager::GetTransportationManager()->GetFieldManager();
HepGeom::Vector3D< double > HepVector3D
HepGeom::Point3D< double > HepPoint3D
G4Mag_UsualEqRhs * fEquation
void SetMaximumEpsilonStep(double newvalue)
void CreateStepperAndChordFinder()
G4MagIntegratorStepper * fStepper
G4FieldManager * fFieldManager
void SetDeltaIntersection(double newvalue)
G4ChordFinder * fChordFinder
BesMagneticFieldMessenger * fFieldMessenger
void GetFieldValue(const double Point[3], double *Bfield) const
void SetMinimumEpsilonStep(double newvalue)
void SetDeltaOneStep(double newvalue)