55 G4double yTemp[8], dydxTemp[6], yIn[8] ;
57 for(i=0;i<nvar;i++) yIn[i]=yInput[i];
67 for(i=0;i<3;i++)BfldIn[i]=B[i];
84 yErr[i] = yOut[i] - yTemp[i] ;
85 yOut[i] += yErr[i]*by15 ;
114 G4Exception(
"G4RKG3_Stepper::StepWithEst()",
"GeomField0001",
147 mom=std::sqrt(tIn[3]*tIn[3]+tIn[4]*tIn[4]+tIn[5]*tIn[5]);
151 K1[i] = Step * dydx[i+3]*inverse_mom;
152 tTemp[i] = tIn[i] + Step*(c1*tIn[i+3]*inverse_mom + c2*K1[i]) ;
153 tTemp[i+3] = tIn[i+3] + c1*K1[i]*mom ;
162 K2[i] = Step * yderiv[i+3]*inverse_mom;
163 tTemp[i+3] = tIn[i+3] + c1*K2[i]*mom ;
171 K3[i] = Step * yderiv[i+3]*inverse_mom;
172 tTemp[i] = tIn[i] + Step*(tIn[i+3]*inverse_mom + c1*K3[i]) ;
173 tTemp[i+3] = tIn[i+3] + K3[i]*mom ;
183 K4[i] = Step * yderiv[i+3]*inverse_mom;
184 tOut[i] = tIn[i] + Step*(tIn[i+3]*inverse_mom+ (K1[i] + K2[i] + K3[i])*c3) ;
185 tOut[i+3] = tIn[i+3] + mom*(K1[i] + 2*K2[i] + 2*K3[i] +K4[i])*c3 ;
203 if (fyInitial != fyFinal) {
206 distChord = distLine;
208 distChord = (fyMidPoint-fyInitial).mag();