#include <G4MagIntegratorStepper.hh>
Inheritance diagram for G4MagIntegratorStepper:
Public Member Functions | |
G4MagIntegratorStepper (G4EquationOfMotion *Equation, G4int numIntegrationVariables, G4int numStateVariables=12) | |
virtual | ~G4MagIntegratorStepper () |
virtual void | Stepper (const G4double y[], const G4double dydx[], G4double h, G4double yout[], G4double yerr[])=0 |
virtual G4double | DistChord () const =0 |
virtual void | ComputeRightHandSide (const G4double y[], G4double dydx[]) |
void | NormaliseTangentVector (G4double vec[6]) |
void | NormalisePolarizationVector (G4double vec[12]) |
void | RightHandSide (const double y[], double dydx[]) |
G4int | GetNumberOfVariables () const |
G4int | GetNumberOfStateVariables () const |
virtual G4int | IntegratorOrder () const =0 |
G4EquationOfMotion * | GetEquationOfMotion () |
void | SetEquationOfMotion (G4EquationOfMotion *newEquation) |
Definition at line 52 of file G4MagIntegratorStepper.hh.
G4MagIntegratorStepper::G4MagIntegratorStepper | ( | G4EquationOfMotion * | Equation, | |
G4int | numIntegrationVariables, | |||
G4int | numStateVariables = 12 | |||
) |
Definition at line 36 of file G4MagIntegratorStepper.cc.
00039 : fEquation_Rhs(Equation), 00040 fNoIntegrationVariables(num_integration_vars), 00041 fNoStateVariables(num_state_vars) 00042 // fNumberOfVariables( std::max(num_var,fNoStateVariables) ) 00043 { 00044 }
G4MagIntegratorStepper::~G4MagIntegratorStepper | ( | ) | [virtual] |
Reimplemented in G4NystromRK4.
Definition at line 50 of file G4MagIntegratorStepper.cc.
References RightHandSide().
Referenced by G4MagInt_Driver::AccurateAdvance().
00051 { 00052 this->RightHandSide( y, dydx ); 00053 }
virtual G4double G4MagIntegratorStepper::DistChord | ( | ) | const [pure virtual] |
G4EquationOfMotion * G4MagIntegratorStepper::GetEquationOfMotion | ( | ) | [inline] |
Definition at line 30 of file G4MagIntegratorStepper.icc.
Referenced by G4ErrorPropagatorManager::InitFieldForBackwards(), G4MagHelicalStepper::MagFieldEvaluate(), G4MagInt_Driver::SetChargeMomentumMass(), and G4RKG3_Stepper::StepNoErr().
G4int G4MagIntegratorStepper::GetNumberOfStateVariables | ( | ) | const [inline] |
Definition at line 52 of file G4MagIntegratorStepper.icc.
Referenced by G4SimpleRunge::G4SimpleRunge(), G4MagErrorStepper::Stepper(), and G4ConstRK4::Stepper().
G4int G4MagIntegratorStepper::GetNumberOfVariables | ( | ) | const [inline] |
Definition at line 45 of file G4MagIntegratorStepper.icc.
Referenced by G4ImplicitEuler::DumbStepper(), G4ExplicitEuler::DumbStepper(), G4ClassicalRK4::DumbStepper(), G4ChordFinder::G4ChordFinder(), G4MagErrorStepper::Stepper(), and G4CashKarpRKF45::Stepper().
virtual G4int G4MagIntegratorStepper::IntegratorOrder | ( | ) | const [pure virtual] |
Implemented in G4CashKarpRKF45, G4ClassicalRK4, G4ConstRK4, G4ExactHelixStepper, G4ExplicitEuler, G4HelixExplicitEuler, G4HelixHeum, G4HelixImplicitEuler, G4HelixMixedStepper, G4HelixSimpleRunge, G4ImplicitEuler, G4NystromRK4, G4RKG3_Stepper, G4SimpleHeum, and G4SimpleRunge.
Referenced by G4MagInt_Driver::G4MagInt_Driver(), G4MagInt_Driver::ReSetParameters(), and G4MagErrorStepper::Stepper().
void G4MagIntegratorStepper::NormalisePolarizationVector | ( | G4double | vec[12] | ) | [inline] |
Definition at line 76 of file G4MagIntegratorStepper.icc.
Referenced by G4SimpleHeum::DumbStepper(), and G4ClassicalRK4::DumbStepper().
00077 { 00078 G4double drds2 = vec[9]*vec[9]+vec[10]*vec[10]+vec[11]*vec[11]; 00079 00080 if( drds2 > 0. ) 00081 { 00082 if( std::fabs(drds2 - 1.0) > 1.e-14 ) 00083 { 00084 G4double normx = 1.0 / std::sqrt(drds2); 00085 for(G4int i=9;i<12;i++) { vec[i] *= normx; } 00086 } 00087 } 00088 }
void G4MagIntegratorStepper::NormaliseTangentVector | ( | G4double | vec[6] | ) | [inline] |
Definition at line 64 of file G4MagIntegratorStepper.icc.
00065 { 00066 G4double drds2 = vec[3]*vec[3]+vec[4]*vec[4]+vec[5]*vec[5]; 00067 00068 if( std::fabs(drds2 - 1.0) > 1.e-14 ) 00069 { 00070 G4double normx = 1.0 / std::sqrt(drds2); 00071 for(G4int i=3;i<6;i++) { vec[i] *= normx; } 00072 } 00073 }
void G4MagIntegratorStepper::RightHandSide | ( | const double | y[], | |
double | dydx[] | |||
) | [inline] |
Definition at line 58 of file G4MagIntegratorStepper.icc.
Referenced by ComputeRightHandSide(), G4SimpleRunge::DumbStepper(), G4SimpleHeum::DumbStepper(), G4ImplicitEuler::DumbStepper(), G4ClassicalRK4::DumbStepper(), G4MagErrorStepper::Stepper(), and G4CashKarpRKF45::Stepper().
00059 { 00060 fEquation_Rhs-> RightHandSide(y, dydx); 00061 }
void G4MagIntegratorStepper::SetEquationOfMotion | ( | G4EquationOfMotion * | newEquation | ) | [inline] |
Definition at line 36 of file G4MagIntegratorStepper.icc.
Referenced by G4ErrorPropagatorManager::InitFieldForBackwards().
virtual void G4MagIntegratorStepper::Stepper | ( | const G4double | y[], | |
const G4double | dydx[], | |||
G4double | h, | |||
G4double | yout[], | |||
G4double | yerr[] | |||
) | [pure virtual] |
Implemented in G4CashKarpRKF45, G4ConstRK4, G4ExactHelixStepper, G4HelixMixedStepper, G4MagErrorStepper, G4MagHelicalStepper, G4NystromRK4, and G4RKG3_Stepper.