43 using namespace field_utils;
69 yOutput[i] = yTemp[i] = yInput[i];
80 b31 = 3./52., b32 = 9./52.,
81 b41 = 12955./26244., b42 = -15925./8748., b43 = 12350./6561.,
82 b51 = -10383./52480., b52 = 13923./10496., b53 = -176553./199424.,
83 b54 = 505197./997120.,
84 b61 = 1403./7236., b62 = -429./268., b63 = 733330./309339.,
85 b64 = -7884./8911., b65 = 104960./113967.,
86 b71 = 181./2700., b72 = 0., b73 = 656903./1846800.,
87 b74 = 19683./106400., b75 = 34112./110565., b76 = 67./800.;
90 dc1 = b71 - 11377./154575.,
92 dc3 = b73 - 35378291./105729300.,
93 dc4 = b74 - 343359./1522850.,
94 dc5 = b75 - 535952./1947645.,
95 dc6 = b76 - 134./17175.,
100 yTemp[i] = yInput[i] + hstep * b21 * dydx[i];
104 yTemp[i] = yInput[i] + hstep * (b31 * dydx[i] + b32 * ak2[i]);
108 yTemp[i] = yInput[i] + hstep * (b41 * dydx[i] + b42 * ak2[i] +
113 yTemp[i] = yInput[i] + hstep * (b51 * dydx[i] + b52 * ak2[i] +
114 b53 * ak3[i] + b54 * ak4[i]);
118 yTemp[i] = yInput[i] + hstep * (b61 * dydx[i] + b62 * ak2[i] +
119 b63 * ak3[i] + b64 * ak4[i] +
124 yOutput[i] = yInput[i] + hstep * (b71 * dydx[i] + b72 * ak2[i] +
125 b73 * ak3[i] + b74 * ak4[i] +
126 b75 * ak5[i] + b76 * ak6[i]);
128 if (dydxOutput && yError) {
131 yError[i] = hstep * (dc1 * dydx[i] + dc2 * ak2[i] + dc3 * ak3[i] +
132 dc4 * ak4[i] + dc5 * ak5[i] + dc6 * ak6[i] +
133 dc7 * dydxOutput[i]);
144 copyArray(
fyIn, yInput);
145 copyArray(
fdydx, dydx);
150 copyArray(yOutput,
fyOut);
161 copyArray(
fyIn, yInput);
162 copyArray(
fdydx, dydx);
167 copyArray(yOutput,
fyOut);
virtual G4double DistChord() const override
static G4double Distline(const G4ThreeVector &OtherPnt, const G4ThreeVector &LinePntA, const G4ThreeVector &LinePntB)
G4ThreeVector makeVector(const ArrayType &array, Value3D value)
G4RK547FEq2(G4EquationOfMotion *EqRhs, G4int integrationVariables=6)
void makeStep(const G4double yInput[], const G4double dydx[], const G4double hstep, G4double yOutput[], G4double *dydxOutput=nullptr, G4double *yError=nullptr) const
G4double fyIn[G4FieldTrack::ncompSVEC]
G4double fdydx[G4FieldTrack::ncompSVEC]
G4int GetNumberOfStateVariables() const
void RightHandSide(const double y[], double dydx[]) const
static const G4double ak2
G4double fyOut[G4FieldTrack::ncompSVEC]
virtual void Stepper(const G4double yInput[], const G4double dydx[], G4double hstep, G4double yOutput[], G4double yError[]) override
G4double fdydxOut[G4FieldTrack::ncompSVEC]
G4int GetNumberOfVariables() const