168 *selection = CandidateForSelection ;
178 #ifdef G4DEBUG_TRANSPORT 181 G4cout <<
"G4CoupledTransportation::AlongStepGPIL> called in volume " 193 startMassSafety = 0.0;
194 startFullSafety= 0.0;
200 G4double mag_shift= std::sqrt(MagSqShift);
228 G4bool fieldExertsForce = false ;
247 if( (particleCharge != 0.0)
249 || (gravityOn && (restMass != 0.0))
252 fieldExertsForce =
true;
258 if( fieldExertsForce )
293 if( equationOfMotion )
299 G4cerr <<
" ERROR > Cannot find valid Equation of motion - Unable to pass Charge, Momentum and Mass " <<
G4endl;
305 track.GetGlobalTime(),
307 track.GetMomentumDirection(),
308 track.GetKineticEnergy(),
323 if( currentMinimumStep > 0 )
353 G4cerr <<
" Error in determining geometries limiting the step" <<
G4endl;
356 G4Exception(
"G4CoupledTransportation::AlongStepGetPhysicalInteractionLength()",
358 "Incompatible conditions - was limited by a geometry?");
368 geometryStepLength =
std::min( lengthAlongCurve, currentMinimumStep);
376 fPreviousSftOrigin = startPosition ;
381 #ifdef G4DEBUG_TRANSPORT 384 G4cout <<
"G4Transport:CompStep> " 385 <<
" called the pathfinder for a new step at " << startPosition
386 <<
" and obtained step = " << lengthAlongCurve <<
G4endl;
387 G4cout <<
" New safety (preStep) = " << newMassSafety
388 <<
" versus precalculated = " << startMassSafety <<
G4endl;
393 startMassSafety = newMassSafety ;
394 startFullSafety = newFullSafety ;
402 geometryStepLength = lengthAlongCurve= 0.0 ;
411 endTrackState= aFieldTrack;
415 if( startMassSafety == 0.0 )
424 if( !fieldExertsForce )
434 #ifdef G4DEBUG_TRANSPORT 465 G4double absEdiff = std::fabs(startEnergy- endEnergy);
490 safetyProposal= startFullSafety;
496 && ( particleCharge != 0.0 ) )
526 #ifdef G4DEBUG_TRANSPORT 528 G4cout <<
"***Transportation::AlongStepGPIL ** " <<
G4endl ;
530 <<
" give safety values: Mass= " << endMassSafety
531 <<
" All= " << endFullSafety <<
G4endl ;
532 G4cout <<
" Adding endpoint distance " << fEndpointDistance
533 <<
" to obtain pseudo-safety= " << safetyProposal <<
G4endl ;
539 G4cout <<
"***Transportation::AlongStepGPIL ** " <<
G4endl ;
541 <<
" gives safety endpoint value = " << startFullSafety - fEndpointDistance
542 <<
" using start-point value " << startFullSafety
543 <<
" and endpointDistance " << fEndpointDistance <<
G4endl;
548 proposedSafetyForStart= safetyProposal;
551 return geometryStepLength ;
G4double GetMagneticMoment() const
G4double fPreviousFullSafety
G4bool fAnyGeometryLimitedStep
G4double ObtainSafety(G4int navId, G4ThreeVector &globalCenterPoint)
G4SafetyHelper * fpSafetyHelper
virtual void SetChargeMomentumMass(G4ChargeState particleCharge, G4double MomentumXc, G4double MassXc2)=0
G4bool IsParticleLooping() const
CLHEP::Hep3Vector G4ThreeVector
G4double fTransportEndKineticEnergy
G4bool fMassGeometryLimitedStep
G4bool DoesFieldChangeEnergy() const
G4bool fEndGlobalTimeComputed
G4double GetTotalMomentum() const
static const double perThousand
G4ThreeVector fTransportEndMomentumDir
G4double fEndpointDistance
G4double fPreviousMassSafety
virtual void ConfigureForTrack(const G4Track *)
G4EquationOfMotion * GetEquationOfMotion()
G4bool fParticleIsLooping
G4GLOB_DLL std::ostream G4cout
void ReportInexactEnergy(G4double startEnergy, G4double endEnergy)
G4ThreeVector fPreviousSftOrigin
G4bool IsGravityActive() const
G4double GetPDGMagneticMoment() const
G4double ComputeStep(const G4FieldTrack &pFieldTrack, G4double pCurrentProposedStepLength, G4int navigatorId, G4int stepNo, G4double &pNewSafety, ELimited &limitedStep, G4FieldTrack &EndState, G4VPhysicalVolume *currentVolume)
G4double GetPDGSpin() const
const G4MagIntegratorStepper * GetStepper() const
G4double ComputeSafety(const G4ThreeVector &globalPoint)
G4FieldManager * FindAndSetFieldManager(G4VPhysicalVolume *pCurrentPhysVol)
G4ThreeVector fTransportEndSpin
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *comments)
static const double perMillion
const G4String & GetName() const
G4double GetCharge() const
G4double GetCurrentSafety() const
const G4ThreeVector & GetMomentumDirection() const
G4ChordFinder * GetChordFinder()
G4FieldManager * GetCurrentFieldManager()
static G4bool fUseMagneticMoment
unsigned int GetNumberGeometriesLimitingStep() const
G4double fCandidateEndGlobalTime
void SetCurrentSafety(G4double val, const G4ThreeVector &pos)
G4ParticleDefinition * GetDefinition() const
G4PathFinder * fPathFinder
G4MagInt_Driver * GetIntegrationDriver()
G4ThreeVector fTransportEndPosition
G4PropagatorInField * fFieldPropagator
const G4Field * GetDetectorField() const
G4GLOB_DLL std::ostream G4cerr
G4ParticleChangeForTransport fParticleChange