66 G4double momentum_mag_square = y[3]*y[3] + y[4]*y[4] + y[5]*y[5];
67 G4double inv_momentum_magnitude = 1.0 / std::sqrt( momentum_mag_square );
69 G4double Energy = std::sqrt(momentum_mag_square + fMass*fMass);
71 G4double cof1 = inv_momentum_magnitude*fMass;
72 G4double inverse_velocity = Energy*inv_momentum_magnitude/c_light;
74 dydx[0] = y[3]*inv_momentum_magnitude;
75 dydx[1] = y[4]*inv_momentum_magnitude;
76 dydx[2] = y[5]*inv_momentum_magnitude;
78 dydx[3] = G[0]*cof1*cof2/c_light;
79 dydx[4] = G[1]*cof1*cof2/c_light;
80 dydx[5] = G[2]*cof1*cof2/c_light;
84 dydx[7] = inverse_velocity;
void SetChargeMomentumMass(G4ChargeState particleCharge, G4double MomentumXc, G4double mass)
G4EqGravityField(G4UniformGravityField *gField)
void EvaluateRhsGivenB(const G4double y[], const G4double Field[], G4double dydx[]) const