File indexing completed on 2025-01-18 09:57:59
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019
0020
0021
0022
0023
0024
0025
0026
0027
0028
0029
0030
0031
0032 void G4BorisDriver::SetVerboseLevel(G4int level)
0033 {
0034 fVerbosity = (level != 0);
0035 }
0036
0037 G4int G4BorisDriver::GetVerboseLevel() const
0038 {
0039 return static_cast<G4int>(fVerbosity);
0040 }
0041
0042 G4double G4BorisDriver::ComputeNewStepSize( G4double , G4double hstepCurrent)
0043 {
0044 return hstepCurrent;
0045 }
0046
0047 const G4EquationOfMotion* G4BorisDriver::GetEquationOfMotion() const
0048 {
0049 auto eq = boris->GetEquationOfMotion();
0050 return eq;
0051 }
0052
0053 G4EquationOfMotion* G4BorisDriver::GetEquationOfMotion()
0054 {
0055 auto eq = boris->GetEquationOfMotion();
0056 return eq;
0057 }
0058
0059 #if 0
0060
0061 void G4BorisDriver::
0062 SetEquationOfMotion( G4EquationOfMotion* equation )
0063 {
0064 boris->SetEquationOfMotion(equation);
0065 }
0066 #endif
0067
0068 G4int G4BorisDriver::GetNumberOfVariables() const
0069 {
0070 return boris->GetNumberOfVariables();
0071 }
0072
0073 const G4MagIntegratorStepper*
0074 G4BorisDriver::GetStepper() const
0075 {
0076 return nullptr;
0077 }
0078
0079 G4MagIntegratorStepper*
0080 G4BorisDriver::GetStepper()
0081 {
0082 return nullptr;
0083 }
0084
0085 void G4BorisDriver::CheckStep(const G4ThreeVector& posIn,
0086 const G4ThreeVector& posOut,
0087 G4double hdid) const
0088 {
0089 const G4double endPointDist = (posOut - posIn).mag();
0090 if (endPointDist >= hdid * (1. + CLHEP::perMillion))
0091 {
0092
0093
0094
0095
0096 if (endPointDist >= hdid * (1. + CLHEP::perThousand))
0097 {
0098 G4Exception("G4BorisDriver::CheckStep()",
0099 "GeomField1002", JustWarning,
0100 "endPointDist >= hdid!");
0101 }
0102 else
0103 {
0104 G4cerr << "G4BorisDriver::CheckStep: moved further than curve distance! "
0105 << " curve hdid= " << hdid << " endpoint dist= " << endPointDist
0106 << " ratio - 1 = " << (endPointDist - hdid) / hdid
0107 << " ( > 1.0e-6 threshold to report ) "
0108 << G4endl;
0109 }
0110
0111 }
0112 else
0113 {
0114
0115 }
0116 }
0117