Geant4-11
Public Member Functions | Protected Member Functions | Protected Attributes | Private Member Functions | Private Attributes | Static Private Attributes | Friends
G4MultiNavigator Class Reference

#include <G4MultiNavigator.hh>

Inheritance diagram for G4MultiNavigator:
G4Navigator

Public Member Functions

void Activate (G4bool flag)
 
void CheckMode (G4bool mode)
 
G4double CheckNextStep (const G4ThreeVector &pGlobalPoint, const G4ThreeVector &pDirection, const G4double pCurrentProposedStepLength, G4double &pNewSafety)
 
G4Navigator * Clone () const
 
G4double ComputeSafety (const G4ThreeVector &globalpoint, const G4double pProposedMaxLength=DBL_MAX, const G4bool keepState=false)
 
G4double ComputeStep (const G4ThreeVector &pGlobalPoint, const G4ThreeVector &pDirection, const G4double pCurrentProposedStepLength, G4double &pNewSafety)
 
G4GRSSolid * CreateGRSSolid () const
 
G4GRSVolume * CreateGRSVolume () const
 
G4TouchableHistory * CreateTouchableHistory () const
 
G4TouchableHistory * CreateTouchableHistory (const G4NavigationHistory *) const
 
G4TouchableHistoryHandle CreateTouchableHistoryHandle () const
 
void EnableBestSafety (G4bool value=false)
 
G4bool EnteredDaughterVolume () const
 
G4bool ExitedMotherVolume () const
 
 G4MultiNavigator ()
 
G4ThreeVector GetCurrentLocalCoordinate () const
 
G4VExternalNavigation * GetExternalNavigation () const
 
virtual G4ThreeVector GetGlobalExitNormal (const G4ThreeVector &E_Pt, G4bool *obtained)
 
const G4AffineTransform & GetGlobalToLocalTransform () const
 
G4ThreeVector GetLastStepEndPoint () const
 
virtual G4ThreeVector GetLocalExitNormal (G4bool *obtained)
 
virtual G4ThreeVector GetLocalExitNormalAndCheck (const G4ThreeVector &E_Pt, G4bool *obtained)
 
const G4AffineTransform GetLocalToGlobalTransform () const
 
G4AffineTransform GetMotherToDaughterTransform (G4VPhysicalVolume *dVolume, G4int dReplicaNo, EVolume dVolumeType)
 
G4Navigator * GetNavigator (G4int n) const
 
G4int GetVerboseLevel () const
 
G4VPhysicalVolume * GetWorldVolume () const
 
void InformLastStep (G4double lastStep, G4bool entersDaughtVol, G4bool exitsMotherVol)
 
G4bool IsActive () const
 
G4bool IsCheckModeActive () const
 
G4VPhysicalVolume * LocateGlobalPointAndSetup (const G4ThreeVector &point, const G4ThreeVector *direction=nullptr, const G4bool pRelativeSearch=true, const G4bool ignoreDirection=true)
 
void LocateGlobalPointAndUpdateTouchable (const G4ThreeVector &position, const G4ThreeVector &direction, G4VTouchable *touchableToUpdate, const G4bool RelativeSearch=true)
 
void LocateGlobalPointAndUpdateTouchable (const G4ThreeVector &position, G4VTouchable *touchableToUpdate, const G4bool RelativeSearch=true)
 
void LocateGlobalPointAndUpdateTouchableHandle (const G4ThreeVector &position, const G4ThreeVector &direction, G4TouchableHandle &oldTouchableToUpdate, const G4bool RelativeSearch=true)
 
void LocateGlobalPointWithinVolume (const G4ThreeVector &position)
 
G4RotationMatrix NetRotation () const
 
G4ThreeVector NetTranslation () const
 
G4double ObtainFinalStep (G4int navigatorId, G4double &pNewSafety, G4double &minStepLast, ELimited &limitedStep)
 
void PrepareNavigators ()
 
void PrepareNewTrack (const G4ThreeVector position, const G4ThreeVector direction)
 
void PrintState () const
 
G4VPhysicalVolume * ResetHierarchyAndLocate (const G4ThreeVector &point, const G4ThreeVector &direction, const G4TouchableHistory &h)
 
void ResetStackAndState ()
 
void SetExternalNavigation (G4VExternalNavigation *externalNav)
 
void SetGeometricallyLimitedStep ()
 
void SetPushVerbosity (G4bool mode)
 
void SetVerboseLevel (G4int level)
 
void SetVoxelNavigation (G4VoxelNavigation *voxelNav)
 
void SetWorldVolume (G4VPhysicalVolume *pWorld)
 
G4int SeverityOfZeroStepping (G4int *noZeroSteps) const
 
 ~G4MultiNavigator ()
 

Protected Member Functions

EVolume CharacteriseDaughters (const G4LogicalVolume *pLog) const
 
void CheckMassWorld ()
 
G4bool CheckOverlapsIterative (G4VPhysicalVolume *vol)
 
G4ThreeVector ComputeLocalAxis (const G4ThreeVector &pVec) const
 
G4ThreeVector ComputeLocalPoint (const G4ThreeVector &rGlobPoint) const
 
G4int GetDaughtersRegularStructureId (const G4LogicalVolume *pLv) const
 
void PrintLimited ()
 
void ResetState ()
 
void RestoreSavedState ()
 
void SetSavedState ()
 
void SetupHierarchy ()
 
EVolume VolumeType (const G4VPhysicalVolume *pVol) const
 
void WhichLimited ()
 

Protected Attributes

G4bool fEnteredDaughter
 
G4bool fExitedMother
 
G4NavigationHistory fHistory
 
G4ThreeVector fLastStepEndPointLocal
 
G4double fSqTol
 
G4ThreeVector fStepEndPoint
 
G4int fVerbose = 0
 
G4bool fWasLimitedByGeometry = false
 
G4double kCarTolerance
 

Private Member Functions

void ComputeStepLog (const G4ThreeVector &pGlobalpoint, G4double moveLenSq) const
 
G4VoxelNavigation & GetVoxelNavigator ()
 

Private Attributes

G4int fAbandonThreshold_NoZeroSteps = 25
 
G4int fActionThreshold_NoZeroSteps = 10
 
G4bool fActive = false
 
G4VPhysicalVolume * fBlockedPhysicalVolume
 
G4int fBlockedReplicaNo
 
G4bool fCalculatedExitNormal
 
G4bool fChangedGrandMotherRefFrame
 
G4bool fCheck = false
 
G4double fCurrentStepSize [fMaxNav]
 
G4bool fEntering
 
G4bool fExiting
 
G4ThreeVector fExitNormal
 
G4ThreeVector fExitNormalGlobalFrame
 
G4ThreeVector fGrandMotherExitNormal
 
G4int fIdNavLimiting = -1
 
G4ThreeVector fLastLocatedPointLocal
 
G4ThreeVector fLastLocatedPosition
 
G4VPhysicalVolume * fLastMassWorld = nullptr
 
G4VPhysicalVolume * fLastMotherPhys = nullptr
 
G4bool fLastStepWasZero
 
G4bool fLastTriedStepComputation = false
 
ELimited fLimitedStep [fMaxNav]
 
G4bool fLimitTruth [fMaxNav]
 
G4bool fLocatedOnEdge
 
G4bool fLocatedOutsideWorld
 
G4VPhysicalVolume * fLocatedVolume [fMaxNav]
 
G4double fMinSafety = -kInfinity
 
G4double fMinSafety_atSafLocation = -1.0
 
G4double fMinSafety_PreStepPt = -1.0
 
G4double fMinStep = -kInfinity
 
G4double fNewSafety [fMaxNav]
 
G4int fNoActiveNavigators = 0
 
G4int fNoLimitingStep = -1
 
G4NormalNavigation fnormalNav
 
G4int fNumberZeroSteps
 
G4ParameterisedNavigation fparamNav
 
G4VExternalNavigation * fpExternalNav = nullptr
 
G4Navigator * fpNavigator [fMaxNav]
 
G4ThreeVector fPreStepLocation
 
G4double fPreviousSafety
 
G4ThreeVector fPreviousSftOrigin
 
G4bool fPushed = false
 
G4VoxelNavigation * fpvoxelNav
 
G4VoxelSafety * fpVoxelSafety
 
G4RegularNavigation fregularNav
 
G4ReplicaNavigation freplicaNav
 
G4ThreeVector fSafetyLocation
 
struct G4Navigator::G4SaveNavigatorState fSaveState
 
G4VPhysicalVolume * fTopPhysical = nullptr
 
G4double fTrueMinStep = -kInfinity
 
G4bool fValidExitNormal
 
G4bool fWarnPush = true
 
G4TransportationManager * pTransportManager
 

Static Private Attributes

static const G4int fMaxNav = 16
 

Friends

std::ostream & operator<< (std::ostream &os, const G4Navigator &n)
 

Detailed Description

Definition at line 54 of file G4MultiNavigator.hh.

Constructor & Destructor Documentation

◆ G4MultiNavigator()

G4MultiNavigator::G4MultiNavigator ( )

Definition at line 46 of file G4MultiNavigator.cc.

47 : G4Navigator()
48{
50 fLastLocatedPosition = Big3Vector;
51 fSafetyLocation = Big3Vector;
52 fPreStepLocation = Big3Vector;
53
54 for(auto num=0; num< fMaxNav; ++num )
55 {
56 fpNavigator[num] = nullptr;
57 fLimitTruth[num] = false;
59 fCurrentStepSize[num] = fNewSafety[num] = -1.0;
60 fLocatedVolume[num] = nullptr;
61 }
62
64
66 if( massNav )
67 {
68 G4VPhysicalVolume* pWorld= massNav->GetWorldVolume();
69 if( pWorld )
70 {
71 SetWorldVolume( pWorld );
72 fLastMassWorld = pWorld;
73 }
74 }
75}
@ kUndefLimited
G4double fCurrentStepSize[fMaxNav]
G4Navigator * fpNavigator[fMaxNav]
G4double fNewSafety[fMaxNav]
G4ThreeVector fSafetyLocation
G4bool fLimitTruth[fMaxNav]
G4VPhysicalVolume * fLocatedVolume[fMaxNav]
G4TransportationManager * pTransportManager
ELimited fLimitedStep[fMaxNav]
G4ThreeVector fPreStepLocation
G4ThreeVector fLastLocatedPosition
static const G4int fMaxNav
G4VPhysicalVolume * fLastMassWorld
void SetWorldVolume(G4VPhysicalVolume *pWorld)
G4VPhysicalVolume * GetWorldVolume() const
static G4TransportationManager * GetTransportationManager()
G4Navigator * GetNavigatorForTracking() const
static const G4double kInfinity
Definition: geomdefs.hh:41

References fCurrentStepSize, fLastLocatedPosition, fLastMassWorld, fLimitedStep, fLimitTruth, fLocatedVolume, fMaxNav, fNewSafety, fpNavigator, fPreStepLocation, fSafetyLocation, G4TransportationManager::GetNavigatorForTracking(), G4TransportationManager::GetTransportationManager(), G4Navigator::GetWorldVolume(), kInfinity, kUndefLimited, pTransportManager, and G4Navigator::SetWorldVolume().

◆ ~G4MultiNavigator()

G4MultiNavigator::~G4MultiNavigator ( )

Definition at line 77 of file G4MultiNavigator.cc.

78{
79}

Member Function Documentation

◆ Activate()

void G4Navigator::Activate ( G4bool  flag)
inlineinherited

◆ CharacteriseDaughters()

EVolume G4Navigator::CharacteriseDaughters ( const G4LogicalVolume *  pLog) const
inlineprotectedinherited

◆ CheckMassWorld()

void G4MultiNavigator::CheckMassWorld ( )
protected

Definition at line 628 of file G4MultiNavigator.cc.

629{
630 G4VPhysicalVolume* navTrackWorld =
632
633 if( navTrackWorld != fLastMassWorld )
634 {
635 G4Exception( "G4MultiNavigator::CheckMassWorld()",
636 "GeomNav0003", FatalException,
637 "Mass world pointer has been changed." );
638 }
639}
@ FatalException
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *description)
Definition: G4Exception.cc:35

References FatalException, fLastMassWorld, G4Exception(), G4TransportationManager::GetNavigatorForTracking(), G4Navigator::GetWorldVolume(), and pTransportManager.

◆ CheckMode()

void G4Navigator::CheckMode ( G4bool  mode)
inlineinherited

◆ CheckNextStep()

G4double G4Navigator::CheckNextStep ( const G4ThreeVector &  pGlobalPoint,
const G4ThreeVector &  pDirection,
const G4double  pCurrentProposedStepLength,
G4double &  pNewSafety 
)
inherited

Definition at line 1255 of file G4Navigator.cc.

1259{
1260 G4double step;
1261
1262 // Save the state, for this parasitic call
1263 //
1264 SetSavedState();
1265
1266 step = ComputeStep ( pGlobalpoint,
1267 pDirection,
1268 pCurrentProposedStepLength,
1269 pNewSafety );
1270
1271 // It is a parasitic call, so attempt to restore the key parts of the state
1272 //
1274 // NOTE: the state of the current subnavigator is NOT restored.
1275 // ***> TODO: restore subnavigator state
1276 // if( last_located) Need Position of last location
1277 // if( last_computed step) Need Endposition of last step
1278
1279 return step;
1280}
double G4double
Definition: G4Types.hh:83
void RestoreSavedState()
Definition: G4Navigator.cc:716
void SetSavedState()
Definition: G4Navigator.cc:682
virtual G4double ComputeStep(const G4ThreeVector &pGlobalPoint, const G4ThreeVector &pDirection, const G4double pCurrentProposedStepLength, G4double &pNewSafety)
Definition: G4Navigator.cc:770

References G4Navigator::ComputeStep(), G4Navigator::RestoreSavedState(), and G4Navigator::SetSavedState().

Referenced by G4SafetyHelper::CheckNextStep().

◆ CheckOverlapsIterative()

G4bool G4Navigator::CheckOverlapsIterative ( G4VPhysicalVolume *  vol)
protectedinherited

Definition at line 2130 of file G4Navigator.cc.

2131{
2132 // Check and report overlaps
2133 //
2134 G4bool foundOverlap = false;
2135 G4int nPoints = 300000, ntrials = 9, numOverlaps = 5;
2136 G4double trialLength = 1.0 * CLHEP::centimeter;
2137 while ( ntrials-- > 0 && !foundOverlap )
2138 {
2139 if ( fVerbose > 1 )
2140 {
2141 G4cout << " ** Running overlap checks in volume "
2142 << vol->GetName()
2143 << " with length = " << trialLength << G4endl;
2144 }
2145 foundOverlap = vol->CheckOverlaps(nPoints, trialLength,
2146 fVerbose, numOverlaps);
2147 trialLength *= 0.1;
2148 if ( trialLength <= 1.0e-5 ) { numOverlaps= 1;}
2149 }
2150 return foundOverlap;
2151}
bool G4bool
Definition: G4Types.hh:86
int G4int
Definition: G4Types.hh:85
#define G4endl
Definition: G4ios.hh:57
G4GLOB_DLL std::ostream G4cout
G4int fVerbose
Definition: G4Navigator.hh:395
virtual G4bool CheckOverlaps(G4int res=1000, G4double tol=0., G4bool verbose=true, G4int errMax=1)
const G4String & GetName() const
static constexpr double centimeter
Definition: SystemOfUnits.h:67

References CLHEP::centimeter, G4VPhysicalVolume::CheckOverlaps(), G4Navigator::fVerbose, G4cout, G4endl, and G4VPhysicalVolume::GetName().

Referenced by G4Navigator::ComputeStep().

◆ Clone()

G4Navigator * G4Navigator::Clone ( ) const
inlineinherited

◆ ComputeLocalAxis()

G4ThreeVector G4Navigator::ComputeLocalAxis ( const G4ThreeVector &  pVec) const
inlineprotectedinherited

◆ ComputeLocalPoint()

G4ThreeVector G4Navigator::ComputeLocalPoint ( const G4ThreeVector &  rGlobPoint) const
inlineprotectedinherited

◆ ComputeSafety()

G4double G4MultiNavigator::ComputeSafety ( const G4ThreeVector &  globalpoint,
const G4double  pProposedMaxLength = DBL_MAX,
const G4bool  keepState = false 
)
virtual

Reimplemented from G4Navigator.

Definition at line 416 of file G4MultiNavigator.cc.

419{
420 // Recompute safety for the relevant point
421
422 G4double minSafety = kInfinity, safety = kInfinity;
423
424 std::vector<G4Navigator*>::iterator pNavigatorIter;
425 pNavigatorIter= pTransportManager-> GetActiveNavigatorsIterator();
426
427 for( auto num=0; num< fNoActiveNavigators; ++pNavigatorIter,++num )
428 {
429 safety = (*pNavigatorIter)->ComputeSafety( position, maxDistance, state);
430 if( safety < minSafety ) { minSafety = safety; }
431 }
432
434 fMinSafety_atSafLocation = minSafety;
435
436#ifdef G4DEBUG_NAVIGATION
437 if( fVerbose > 1 )
438 {
439 G4cout << " G4MultiNavigator::ComputeSafety - returns: "
440 << minSafety << ", at location: " << position << G4endl;
441 }
442#endif
443 return minSafety;
444}
G4double fMinSafety_atSafLocation
#define position
Definition: xmlparse.cc:622

References fMinSafety_atSafLocation, fNoActiveNavigators, fSafetyLocation, G4Navigator::fVerbose, G4cout, G4endl, kInfinity, position, and pTransportManager.

◆ ComputeStep()

G4double G4MultiNavigator::ComputeStep ( const G4ThreeVector &  pGlobalPoint,
const G4ThreeVector &  pDirection,
const G4double  pCurrentProposedStepLength,
G4double &  pNewSafety 
)
virtual

Reimplemented from G4Navigator.

Definition at line 81 of file G4MultiNavigator.cc.

85{
86 G4double safety= 0.0, step=0.0;
87 G4double minSafety= kInfinity, minStep= kInfinity;
88
89 fNoLimitingStep= -1;
90 fIdNavLimiting= -1; // Reset for new step
91
92#ifdef G4DEBUG_NAVIGATION
93 if( fVerbose > 2 )
94 {
95 G4cout << " G4MultiNavigator::ComputeStep : entered " << G4endl;
96 G4cout << " Input position= " << pGlobalPoint
97 << " direction= " << pDirection << G4endl;
98 G4cout << " Requested step= " << proposedStepLength << G4endl;
99 }
100#endif
101
102 std::vector<G4Navigator*>::iterator pNavigatorIter;
103
104 pNavigatorIter= pTransportManager-> GetActiveNavigatorsIterator();
105
106 G4ThreeVector initialPosition = pGlobalPoint;
107 G4ThreeVector initialDirection= pDirection;
108
109 for( auto num=0; num< fNoActiveNavigators; ++pNavigatorIter,++num )
110 {
111 safety= kInfinity;
112
113 step= (*pNavigatorIter)->ComputeStep( initialPosition,
114 initialDirection,
115 proposedStepLength,
116 safety );
117 if( safety < minSafety ){ minSafety = safety; }
118 if( step < minStep ) { minStep= step; }
119
120 fCurrentStepSize[num] = step;
121 fNewSafety[num]= safety;
122 // This is currently the safety from the last sub-step
123
124#ifdef G4DEBUG_NAVIGATION
125 if( fVerbose > 2 )
126 {
127 G4cout << "G4MultiNavigator::ComputeStep : Navigator ["
128 << num << "] -- step size " << step
129 << " safety= " << safety << G4endl;
130 }
131#endif
132 }
133
134 // Save safety value, related position
135 //
136 fPreStepLocation = initialPosition;
137 fMinSafety_PreStepPt = minSafety;
138 fMinStep = minStep;
139
140 if( fMinStep == kInfinity )
141 {
142 fTrueMinStep = proposedStepLength; // Use this below for endpoint !!
143 }
144 else
145 {
146 fTrueMinStep = minStep;
147 }
148
149#ifdef G4DEBUG_NAVIGATION
150 if( fVerbose > 1 )
151 {
152 G4ThreeVector endPosition = initialPosition+fTrueMinStep*initialDirection;
153
154 G4int oldPrec = G4cout.precision(8);
155 G4cout << "G4MultiNavigator::ComputeStep : "
156 << " initialPosition = " << initialPosition
157 << " and endPosition = " << endPosition << G4endl;
158 G4cout.precision( oldPrec );
159 }
160#endif
161
162 pNewSafety = minSafety;
163
164 this->WhichLimited();
165
166#ifdef G4DEBUG_NAVIGATION
167 if( fVerbose > 2 )
168 {
169 G4cout << " G4MultiNavigator::ComputeStep : exits returning "
170 << minStep << G4endl;
171 }
172#endif
173
174 return minStep; // must return kInfinity if do not limit step
175}
G4double fMinSafety_PreStepPt

References fCurrentStepSize, fIdNavLimiting, fMinSafety_PreStepPt, fMinStep, fNewSafety, fNoActiveNavigators, fNoLimitingStep, fPreStepLocation, fTrueMinStep, G4Navigator::fVerbose, G4cout, G4endl, kInfinity, pTransportManager, and WhichLimited().

◆ ComputeStepLog()

void G4Navigator::ComputeStepLog ( const G4ThreeVector &  pGlobalpoint,
G4double  moveLenSq 
) const
privateinherited

Definition at line 2027 of file G4Navigator.cc.

2029{
2030 // The following checks only make sense if the move is larger
2031 // than the tolerance.
2032
2033 const G4double fAccuracyForWarning = kCarTolerance,
2034 fAccuracyForException = 1000*kCarTolerance;
2035
2036 G4ThreeVector OriginalGlobalpoint = fHistory.GetTopTransform().
2037 InverseTransformPoint(fLastLocatedPointLocal);
2038
2039 G4double shiftOriginSafSq = (fPreviousSftOrigin-pGlobalpoint).mag2();
2040
2041 // Check that the starting point of this step is
2042 // within the isotropic safety sphere of the last point
2043 // to a accuracy/precision given by fAccuracyForWarning.
2044 // If so give warning.
2045 // If it fails by more than fAccuracyForException exit with error.
2046 //
2047 if( shiftOriginSafSq >= sqr(fPreviousSafety) )
2048 {
2049 G4double shiftOrigin = std::sqrt(shiftOriginSafSq);
2050 G4double diffShiftSaf = shiftOrigin - fPreviousSafety;
2051
2052 if( diffShiftSaf > fAccuracyForWarning )
2053 {
2054 G4int oldcoutPrec = G4cout.precision(8);
2055 G4int oldcerrPrec = G4cerr.precision(10);
2056 std::ostringstream message, suggestion;
2057 message << "Accuracy error or slightly inaccurate position shift."
2058 << G4endl
2059 << " The Step's starting point has moved "
2060 << std::sqrt(moveLenSq)/mm << " mm " << G4endl
2061 << " since the last call to a Locate method." << G4endl
2062 << " This has resulted in moving "
2063 << shiftOrigin/mm << " mm "
2064 << " from the last point at which the safety "
2065 << " was calculated " << G4endl
2066 << " which is more than the computed safety= "
2067 << fPreviousSafety/mm << " mm at that point." << G4endl
2068 << " This difference is "
2069 << diffShiftSaf/mm << " mm." << G4endl
2070 << " The tolerated accuracy is "
2071 << fAccuracyForException/mm << " mm.";
2072
2073 suggestion << " ";
2074 static G4ThreadLocal G4int warnNow = 0;
2075 if( ((++warnNow % 100) == 1) )
2076 {
2077 message << G4endl
2078 << " This problem can be due to either " << G4endl
2079 << " - a process that has proposed a displacement"
2080 << " larger than the current safety , or" << G4endl
2081 << " - inaccuracy in the computation of the safety";
2082 suggestion << "We suggest that you " << G4endl
2083 << " - find i) what particle is being tracked, and "
2084 << " ii) through what part of your geometry " << G4endl
2085 << " for example by re-running this event with "
2086 << G4endl
2087 << " /tracking/verbose 1 " << G4endl
2088 << " - check which processes you declare for"
2089 << " this particle (and look at non-standard ones)"
2090 << G4endl
2091 << " - in case, create a detailed logfile"
2092 << " of this event using:" << G4endl
2093 << " /tracking/verbose 6 ";
2094 }
2095 G4Exception("G4Navigator::ComputeStep()",
2096 "GeomNav1002", JustWarning,
2097 message, G4String(suggestion.str()));
2098 G4cout.precision(oldcoutPrec);
2099 G4cerr.precision(oldcerrPrec);
2100 }
2101#ifdef G4DEBUG_NAVIGATION
2102 else
2103 {
2104 G4cerr << "WARNING - G4Navigator::ComputeStep()" << G4endl
2105 << " The Step's starting point has moved "
2106 << std::sqrt(moveLenSq) << "," << G4endl
2107 << " which has taken it to the limit of"
2108 << " the current safety. " << G4endl;
2109 }
2110#endif
2111 }
2112 G4double safetyPlus = fPreviousSafety + fAccuracyForException;
2113 if ( shiftOriginSafSq > sqr(safetyPlus) )
2114 {
2115 std::ostringstream message;
2116 message << "May lead to a crash or unreliable results." << G4endl
2117 << " Position has shifted considerably without"
2118 << " notifying the navigator !" << G4endl
2119 << " Tolerated safety: " << safetyPlus << G4endl
2120 << " Computed shift : " << shiftOriginSafSq;
2121 G4Exception("G4Navigator::ComputeStep()", "GeomNav1002",
2122 JustWarning, message);
2123 }
2124}
@ JustWarning
static constexpr double mm
Definition: G4SIunits.hh:95
G4GLOB_DLL std::ostream G4cerr
const G4AffineTransform & GetTopTransform() const
G4double fPreviousSafety
Definition: G4Navigator.hh:429
G4double kCarTolerance
Definition: G4Navigator.hh:377
G4ThreeVector fLastLocatedPointLocal
Definition: G4Navigator.hh:413
G4NavigationHistory fHistory
Definition: G4Navigator.hh:384
G4ThreeVector fPreviousSftOrigin
Definition: G4Navigator.hh:428
T sqr(const T &x)
Definition: templates.hh:128
#define G4ThreadLocal
Definition: tls.hh:77

References G4Navigator::fHistory, G4Navigator::fLastLocatedPointLocal, G4Navigator::fPreviousSafety, G4Navigator::fPreviousSftOrigin, G4cerr, G4cout, G4endl, G4Exception(), G4ThreadLocal, G4NavigationHistory::GetTopTransform(), JustWarning, G4Navigator::kCarTolerance, mm, and sqr().

Referenced by G4Navigator::ComputeStep().

◆ CreateGRSSolid()

G4GRSSolid * G4Navigator::CreateGRSSolid ( ) const
inlineinherited

◆ CreateGRSVolume()

G4GRSVolume * G4Navigator::CreateGRSVolume ( ) const
inlineinherited

◆ CreateTouchableHistory() [1/2]

G4TouchableHistory * G4Navigator::CreateTouchableHistory ( ) const
inlineinherited

◆ CreateTouchableHistory() [2/2]

G4TouchableHistory * G4Navigator::CreateTouchableHistory ( const G4NavigationHistory *  ) const
inlineinherited

◆ CreateTouchableHistoryHandle()

G4TouchableHistoryHandle G4MultiNavigator::CreateTouchableHistoryHandle ( ) const
virtual

Reimplemented from G4Navigator.

Definition at line 449 of file G4MultiNavigator.cc.

450{
451 G4Exception( "G4MultiNavigator::CreateTouchableHistoryHandle()",
452 "GeomNav0001", FatalException,
453 "Getting a touchable from G4MultiNavigator is not defined.");
454
455 G4TouchableHistory* touchHist;
456 touchHist= fpNavigator[0] -> CreateTouchableHistory();
457
458 G4VPhysicalVolume* locatedVolume= fLocatedVolume[0];
459 if( locatedVolume == nullptr )
460 {
461 // Workaround to ensure that the touchable is fixed !! // TODO: fix
462 //
463 touchHist->UpdateYourself( locatedVolume, touchHist->GetHistory() );
464 }
465
466 return G4TouchableHistoryHandle(touchHist);
467}
G4ReferenceCountedHandle< G4TouchableHistory > G4TouchableHistoryHandle
G4TouchableHistory * CreateTouchableHistory() const
void UpdateYourself(G4VPhysicalVolume *pPhysVol, const G4NavigationHistory *history=nullptr)
const G4NavigationHistory * GetHistory() const

References G4Navigator::CreateTouchableHistory(), FatalException, fLocatedVolume, fpNavigator, G4Exception(), G4TouchableHistory::GetHistory(), and G4TouchableHistory::UpdateYourself().

◆ EnableBestSafety()

void G4Navigator::EnableBestSafety ( G4bool  value = false)
inlineinherited

◆ EnteredDaughterVolume()

G4bool G4Navigator::EnteredDaughterVolume ( ) const
inlineinherited

◆ ExitedMotherVolume()

G4bool G4Navigator::ExitedMotherVolume ( ) const
inlineinherited

◆ GetCurrentLocalCoordinate()

G4ThreeVector G4Navigator::GetCurrentLocalCoordinate ( ) const
inlineinherited

◆ GetDaughtersRegularStructureId()

G4int G4Navigator::GetDaughtersRegularStructureId ( const G4LogicalVolume *  pLv) const
inlineprotectedinherited

◆ GetExternalNavigation()

G4VExternalNavigation * G4Navigator::GetExternalNavigation ( ) const
inlineinherited

◆ GetGlobalExitNormal()

G4ThreeVector G4MultiNavigator::GetGlobalExitNormal ( const G4ThreeVector &  E_Pt,
G4bool *  obtained 
)
virtual

Reimplemented from G4Navigator.

Definition at line 683 of file G4MultiNavigator.cc.

685{
686 G4ThreeVector normalGlobalCrd(0.0, 0.0, 0.0);
687 G4bool isObtained = false;
688 // These default values will be used if fNoLimitingStep== 0
689 G4int firstNavigatorId = -1;
690 G4bool oneObtained = false;
691
692 if( fNoLimitingStep == 1 )
693 {
694 // Only message the Navigator which limited the step!
695 normalGlobalCrd = fpNavigator[ fIdNavLimiting ]
696 ->GetGlobalExitNormal( argPoint, &isObtained );
697 *argpObtained = isObtained;
698 }
699 else
700 {
701 if( fNoLimitingStep > 1 )
702 {
703 std::vector<G4Navigator*>::iterator pNavIter=
705
706 for ( auto num = 0; num < fNoActiveNavigators ; ++pNavIter, ++num )
707 {
708 G4ThreeVector oneNormal;
709 if( fLimitTruth[ num ] ) // Did this geometry limit the step ?
710 {
711 G4ThreeVector newNormal =
712 (*pNavIter)->GetGlobalExitNormal( argPoint, &oneObtained );
713 if( oneObtained )
714 {
715 // Keep first one - only if it is valid (ie not null)
716 if( !isObtained && (newNormal.mag2() != 0.0) )
717 {
718 normalGlobalCrd = newNormal;
719 isObtained = oneObtained;
720 firstNavigatorId = num;
721 }
722 else
723 {
724 // Check for clash
725 G4double dotNewPrevious = newNormal.dot( normalGlobalCrd );
726 G4double productMagSq = normalGlobalCrd.mag2()*newNormal.mag2();
727 if( productMagSq > 0.0 )
728 {
729 G4double productMag = std::sqrt( productMagSq );
730 dotNewPrevious /= productMag; // Normalise
731 if( dotNewPrevious < (1 - perThousand) )
732 {
733 *argpObtained = false;
734
735 if( fVerbose > 2 ) // dotNewPrevious <= 0.0 )
736 {
737 std::ostringstream message;
738 message << "Clash of Normal from different Navigators!"
739 << G4endl
740 << " Previous Navigator Id = "
741 << firstNavigatorId << G4endl
742 << " Current Navigator Id = "
743 << num << G4endl;
744 message << " Dot product of 2 normals = "
745 << dotNewPrevious << G4endl;
746 message << " Normal (previous) = "
747 << normalGlobalCrd << G4endl;
748 message << " Normal (current) = " << newNormal << G4endl;
749 G4Exception("G4MultiNavigator::GetGlobalExitNormal()",
750 "GeomNav0002", JustWarning, message);
751 }
752 }
753 else
754 {
755 // Close agreement - Do not change
756 }
757 }
758 }
759 }
760 }
761 } // end for over the Navigators
762
763 // Report if no Normal was obtained
764 if( !oneObtained )
765 {
766 std::ostringstream message;
767 message << "No Normal obtained despite having " << fNoLimitingStep
768 << " candidate Navigators limiting the step!" << G4endl;
769 G4Exception("G4MultiNavigator::GetGlobalExitNormal()", "GeomNav0002",
770 JustWarning, message);
771 }
772
773 } // end if ( fNoLimiting > 1 )
774 } // end else
775
776 *argpObtained = isObtained;
777 return normalGlobalCrd;
778}
static constexpr double perThousand
Definition: G4SIunits.hh:326
double mag2() const
double dot(const Hep3Vector &) const
virtual G4ThreeVector GetGlobalExitNormal(const G4ThreeVector &point, G4bool *valid)
std::vector< G4Navigator * >::iterator GetActiveNavigatorsIterator()

References CLHEP::Hep3Vector::dot(), fIdNavLimiting, fLimitTruth, fNoActiveNavigators, fNoLimitingStep, fpNavigator, G4Navigator::fVerbose, G4endl, G4Exception(), G4TransportationManager::GetActiveNavigatorsIterator(), G4Navigator::GetGlobalExitNormal(), JustWarning, CLHEP::Hep3Vector::mag2(), perThousand, and pTransportManager.

◆ GetGlobalToLocalTransform()

const G4AffineTransform & G4Navigator::GetGlobalToLocalTransform ( ) const
inlineinherited

◆ GetLastStepEndPoint()

G4ThreeVector G4Navigator::GetLastStepEndPoint ( ) const
inlineinherited

Definition at line 304 of file G4Navigator.hh.

304{ return fStepEndPoint;}
G4ThreeVector fStepEndPoint
Definition: G4Navigator.hh:388

References G4Navigator::fStepEndPoint.

◆ GetLocalExitNormal()

G4ThreeVector G4MultiNavigator::GetLocalExitNormal ( G4bool *  obtained)
virtual

Reimplemented from G4Navigator.

Definition at line 783 of file G4MultiNavigator.cc.

784{
785 // If it is the mass navigator, then expect
786 G4ThreeVector normalGlobalCrd(0.0, 0.0, 0.0);
787 G4bool isObtained = false;
788 // These default values will be used if fNoLimitingStep== 0
789
790 if( fNoLimitingStep == 1 )
791 {
792 // Only message the Navigator which limited the step!
793 normalGlobalCrd = fpNavigator[ fIdNavLimiting ]
794 ->GetLocalExitNormal( &isObtained );
795 *argpObtained = isObtained;
796
797 static G4ThreadLocal G4int numberWarnings = 0;
798 G4int noWarningsStart = 10, noModuloWarnings = 100;
799 ++numberWarnings;
800 if( (numberWarnings < noWarningsStart )
801 || (numberWarnings%noModuloWarnings == 0) )
802 {
803 std::ostringstream message;
804 message << "Cannot obtain normal in local coordinates of two or more "
805 << "coordinate systems." << G4endl;
806 G4Exception("G4MultiNavigator::GetGlobalExitNormal()", "GeomNav0002",
807 JustWarning, message);
808 }
809 }
810 else
811 {
812 if( fNoLimitingStep > 1 )
813 {
814 std::ostringstream message;
815 message << "Cannot obtain normal in local coordinates of two or more "
816 << "coordinate systems." << G4endl;
817 G4Exception("G4MultiNavigator::GetGlobalExitNormal()", "GeomNav0002",
818 FatalException, message);
819 }
820 }
821
822 *argpObtained = isObtained;
823 return normalGlobalCrd;
824}
virtual G4ThreeVector GetLocalExitNormal(G4bool *valid)

References FatalException, fIdNavLimiting, fNoLimitingStep, fpNavigator, G4endl, G4Exception(), G4ThreadLocal, G4Navigator::GetLocalExitNormal(), and JustWarning.

Referenced by GetLocalExitNormalAndCheck().

◆ GetLocalExitNormalAndCheck()

G4ThreeVector G4MultiNavigator::GetLocalExitNormalAndCheck ( const G4ThreeVector &  E_Pt,
G4bool *  obtained 
)
virtual

Reimplemented from G4Navigator.

Definition at line 829 of file G4MultiNavigator.cc.

831{
832 return G4MultiNavigator::GetLocalExitNormal( obtained );
833}
virtual G4ThreeVector GetLocalExitNormal(G4bool *obtained)

References GetLocalExitNormal().

◆ GetLocalToGlobalTransform()

const G4AffineTransform G4Navigator::GetLocalToGlobalTransform ( ) const
inlineinherited

◆ GetMotherToDaughterTransform()

G4AffineTransform G4Navigator::GetMotherToDaughterTransform ( G4VPhysicalVolume *  dVolume,
G4int  dReplicaNo,
EVolume  dVolumeType 
)
inherited

Definition at line 1555 of file G4Navigator.cc.

1558{
1559 switch (enteringVolumeType)
1560 {
1561 case kNormal: // Nothing is needed to prepare the transformation
1562 break; // It is stored already in the physical volume (placement)
1563 case kReplica: // Sets the transform in the Replica - tbc
1564 G4Exception("G4Navigator::GetMotherToDaughterTransform()",
1565 "GeomNav0001", FatalException,
1566 "Method NOT Implemented yet for replica volumes.");
1567 break;
1568 case kParameterised:
1569 if( pEnteringPhysVol->GetRegularStructureId() == 0 )
1570 {
1571 G4VPVParameterisation *pParam =
1572 pEnteringPhysVol->GetParameterisation();
1573 G4VSolid* pSolid =
1574 pParam->ComputeSolid(enteringReplicaNo, pEnteringPhysVol);
1575 pSolid->ComputeDimensions(pParam, enteringReplicaNo, pEnteringPhysVol);
1576
1577 // Sets the transform in the Parameterisation
1578 //
1579 pParam->ComputeTransformation(enteringReplicaNo, pEnteringPhysVol);
1580
1581 // Set the correct solid and material in Logical Volume
1582 //
1583 G4LogicalVolume* pLogical = pEnteringPhysVol->GetLogicalVolume();
1584 pLogical->SetSolid( pSolid );
1585 }
1586 break;
1587 case kExternal:
1588 // Expect that nothing is needed to prepare the transformation.
1589 // It is stored already in the physical volume (placement)
1590 break;
1591 }
1592 return G4AffineTransform(pEnteringPhysVol->GetRotation(),
1593 pEnteringPhysVol->GetTranslation()).Invert();
1594}
G4AffineTransform & Invert()
void SetSolid(G4VSolid *pSolid)
virtual G4VSolid * ComputeSolid(const G4int, G4VPhysicalVolume *)
virtual void ComputeTransformation(const G4int, G4VPhysicalVolume *) const =0
virtual void ComputeDimensions(G4VPVParameterisation *p, const G4int n, const G4VPhysicalVolume *pRep)
Definition: G4VSolid.cc:137
@ kNormal
Definition: geomdefs.hh:84
@ kParameterised
Definition: geomdefs.hh:86
@ kExternal
Definition: geomdefs.hh:87
@ kReplica
Definition: geomdefs.hh:85

References G4VSolid::ComputeDimensions(), G4VPVParameterisation::ComputeSolid(), G4VPVParameterisation::ComputeTransformation(), FatalException, G4Exception(), G4VPhysicalVolume::GetLogicalVolume(), G4VPhysicalVolume::GetParameterisation(), G4VPhysicalVolume::GetRegularStructureId(), G4VPhysicalVolume::GetRotation(), G4VPhysicalVolume::GetTranslation(), G4AffineTransform::Invert(), kExternal, kNormal, kParameterised, kReplica, and G4LogicalVolume::SetSolid().

Referenced by G4Navigator::GetLocalExitNormal().

◆ GetNavigator()

G4Navigator * G4MultiNavigator::GetNavigator ( G4int  n) const
inline

Definition at line 136 of file G4MultiNavigator.hh.

137 {
138 if( (n>fNoActiveNavigators) || (n<0) ) { n=0; }
139 return fpNavigator[n];
140 }

References fNoActiveNavigators, fpNavigator, and CLHEP::detail::n.

◆ GetVerboseLevel()

G4int G4Navigator::GetVerboseLevel ( ) const
inlineinherited

◆ GetVoxelNavigator()

G4VoxelNavigation & G4Navigator::GetVoxelNavigator ( )
inlineprivateinherited

◆ GetWorldVolume()

G4VPhysicalVolume * G4Navigator::GetWorldVolume ( ) const
inlineinherited

◆ InformLastStep()

void G4Navigator::InformLastStep ( G4double  lastStep,
G4bool  entersDaughtVol,
G4bool  exitsMotherVol 
)
inherited

Definition at line 2240 of file G4Navigator.cc.

2241{
2242 G4bool zeroStep = ( lastStep == 0.0 );
2243 fLocatedOnEdge = fLastStepWasZero && zeroStep;
2244 fLastStepWasZero = zeroStep;
2245
2246 fExiting = exitsMotherVol;
2247 fEntering = entersDaughtVol;
2248}
G4bool fLocatedOnEdge
Definition: G4Navigator.hh:477
G4bool fExiting
Definition: G4Navigator.hh:465
G4bool fLastStepWasZero
Definition: G4Navigator.hh:475
G4bool fEntering
Definition: G4Navigator.hh:465

References G4Navigator::fEntering, G4Navigator::fExiting, G4Navigator::fLastStepWasZero, and G4Navigator::fLocatedOnEdge.

◆ IsActive()

G4bool G4Navigator::IsActive ( ) const
inlineinherited

Referenced by export_G4Navigator().

◆ IsCheckModeActive()

G4bool G4Navigator::IsCheckModeActive ( ) const
inlineinherited

◆ LocateGlobalPointAndSetup()

G4VPhysicalVolume * G4MultiNavigator::LocateGlobalPointAndSetup ( const G4ThreeVector &  point,
const G4ThreeVector *  direction = nullptr,
const G4bool  pRelativeSearch = true,
const G4bool  ignoreDirection = true 
)
virtual

Reimplemented from G4Navigator.

Definition at line 304 of file G4MultiNavigator.cc.

308{
309 // Locate the point in each geometry
310
311 G4ThreeVector direction(0.0, 0.0, 0.0);
312 G4bool relative = pRelativeSearch;
313 std::vector<G4Navigator*>::iterator pNavIter
315
316 if( pDirection ) { direction = *pDirection; }
317
318#ifdef G4DEBUG_NAVIGATION
319 if( fVerbose > 2 )
320 {
321 G4cout << " Entered G4MultiNavigator::LocateGlobalPointAndSetup() "
322 << G4endl;
323 G4cout << " Locating at position: " << position
324 << ", with direction: " << direction << G4endl
325 << " Relative: " << relative
326 << ", ignore direction: " << ignoreDirection << G4endl;
327 G4cout << " Number of active navigators: " << fNoActiveNavigators
328 << G4endl;
329 }
330#endif
331
332 for ( auto num=0; num< fNoActiveNavigators ; ++pNavIter,++num )
333 {
335 {
336 (*pNavIter)->SetGeometricallyLimitedStep();
337 }
338
339 G4VPhysicalVolume *pLocated
340 = (*pNavIter)->LocateGlobalPointAndSetup( position, &direction,
341 relative, ignoreDirection );
342 // Set the state related to the location
343 //
344 fLocatedVolume[num] = pLocated;
345
346 // Clear state related to the step
347 //
348 fLimitedStep[num] = kDoNot;
349 fCurrentStepSize[num] = 0.0;
350 fLimitTruth[ num ] = false; // Always clear on locating (see Navigator)
351
352#ifdef G4DEBUG_NAVIGATION
353 if( fVerbose > 2 )
354 {
355 G4cout << " Located in world: " << num << ", at: " << position << G4endl
356 << " Used geomLimStp: " << fLimitTruth[num]
357 << ", found in volume: " << pLocated << G4endl;
358 G4cout << " Name = '" ;
359 if( pLocated )
360 {
361 G4cout << pLocated->GetName() << "'";
362 G4cout << " - CopyNo= " << pLocated->GetCopyNo();
363 }
364 else
365 {
366 G4cout << "Null' Id: Not-Set ";
367 }
368 G4cout << G4endl;
369 }
370#endif
371 }
372
373 fWasLimitedByGeometry = false; // Clear on locating
374 G4VPhysicalVolume* volMassLocated = fLocatedVolume[0];
375
376 return volMassLocated;
377}
@ kDoNot
G4bool fWasLimitedByGeometry
Definition: G4Navigator.hh:408
virtual G4int GetCopyNo() const =0

References fCurrentStepSize, fLimitedStep, fLimitTruth, fLocatedVolume, fNoActiveNavigators, G4Navigator::fVerbose, G4Navigator::fWasLimitedByGeometry, G4cout, G4endl, G4TransportationManager::GetActiveNavigatorsIterator(), G4VPhysicalVolume::GetCopyNo(), G4VPhysicalVolume::GetName(), kDoNot, and pTransportManager.

Referenced by PrepareNewTrack(), and ResetHierarchyAndLocate().

◆ LocateGlobalPointAndUpdateTouchable() [1/2]

void G4Navigator::LocateGlobalPointAndUpdateTouchable ( const G4ThreeVector &  position,
const G4ThreeVector &  direction,
G4VTouchable *  touchableToUpdate,
const G4bool  RelativeSearch = true 
)
inlineinherited

◆ LocateGlobalPointAndUpdateTouchable() [2/2]

void G4Navigator::LocateGlobalPointAndUpdateTouchable ( const G4ThreeVector &  position,
G4VTouchable *  touchableToUpdate,
const G4bool  RelativeSearch = true 
)
inlineinherited

◆ LocateGlobalPointAndUpdateTouchableHandle()

void G4Navigator::LocateGlobalPointAndUpdateTouchableHandle ( const G4ThreeVector &  position,
const G4ThreeVector &  direction,
G4TouchableHandle &  oldTouchableToUpdate,
const G4bool  RelativeSearch = true 
)
inlineinherited

◆ LocateGlobalPointWithinVolume()

void G4MultiNavigator::LocateGlobalPointWithinVolume ( const G4ThreeVector &  position)
virtual

Reimplemented from G4Navigator.

Definition at line 382 of file G4MultiNavigator.cc.

383{
384 // Relocate the point in each geometry
385
386 std::vector<G4Navigator*>::iterator pNavIter
388
389#ifdef G4DEBUG_NAVIGATION
390 if( fVerbose > 2 )
391 {
392 G4cout << " Entered G4MultiNavigator::ReLocate() " << G4endl
393 << " Re-locating at position: " << position << G4endl;
394 }
395#endif
396
397 for ( auto num=0; num< fNoActiveNavigators ; ++pNavIter,++num )
398 {
399 // ... none limited the step
400
401 (*pNavIter)->LocateGlobalPointWithinVolume( position );
402
403 // Clear state related to the step
404 //
405 fLimitedStep[num] = kDoNot;
406 fCurrentStepSize[num] = 0.0;
407
408 fLimitTruth[ num ] = false; // Always clear on locating (see Navigator)
409 }
410 fWasLimitedByGeometry = false; // Clear on locating
412}

References fCurrentStepSize, fLastLocatedPosition, fLimitedStep, fLimitTruth, fNoActiveNavigators, G4Navigator::fVerbose, G4Navigator::fWasLimitedByGeometry, G4cout, G4endl, G4TransportationManager::GetActiveNavigatorsIterator(), kDoNot, position, and pTransportManager.

◆ NetRotation()

G4RotationMatrix G4Navigator::NetRotation ( ) const
inlineinherited

◆ NetTranslation()

G4ThreeVector G4Navigator::NetTranslation ( ) const
inlineinherited

◆ ObtainFinalStep()

G4double G4MultiNavigator::ObtainFinalStep ( G4int  navigatorId,
G4double &  pNewSafety,
G4double &  minStepLast,
ELimited &  limitedStep 
)

Definition at line 180 of file G4MultiNavigator.cc.

184{
185 if( navigatorId > fNoActiveNavigators )
186 {
187 std::ostringstream message;
188 message << "Bad Navigator Id!" << G4endl
189 << " Navigator Id = " << navigatorId
190 << " No Active = " << fNoActiveNavigators << ".";
191 G4Exception("G4MultiNavigator::ObtainFinalStep()", "GeomNav0002",
192 FatalException, message);
193 }
194
195 // Prepare the information to return
196 //
197 pNewSafety = fNewSafety[ navigatorId ];
198 limitedStep = fLimitedStep[ navigatorId ];
199 minStep= fMinStep;
200
201#ifdef G4DEBUG_NAVIGATION
202 if( fVerbose > 1 )
203 {
204 G4cout << " G4MultiNavigator::ComputeStep returns "
205 << fCurrentStepSize[ navigatorId ]
206 << " for Navigator " << navigatorId
207 << " Limited step = " << limitedStep
208 << " Safety(mm) = " << pNewSafety / mm << G4endl;
209 }
210#endif
211
212 return fCurrentStepSize[ navigatorId ];
213}

References FatalException, fCurrentStepSize, fLimitedStep, fMinStep, fNewSafety, fNoActiveNavigators, G4Navigator::fVerbose, G4cout, G4endl, G4Exception(), and mm.

Referenced by G4PathFinder::DoNextCurvedStep().

◆ PrepareNavigators()

void G4MultiNavigator::PrepareNavigators ( )

Definition at line 238 of file G4MultiNavigator.cc.

239{
240 // Key purposes:
241 // - Check and cache set of active navigators
242 // - Reset state for new track
243
244#ifdef G4DEBUG_NAVIGATION
245 if( fVerbose > 1 )
246 {
247 G4cout << " Entered G4MultiNavigator::PrepareNavigators() " << G4endl;
248 }
249#endif
250
251 // Message the transportation-manager to find active navigators
252
253 std::vector<G4Navigator*>::iterator pNavigatorIter;
254 fNoActiveNavigators= pTransportManager-> GetNoActiveNavigators();
255
257 {
258 std::ostringstream message;
259 message << "Too many active Navigators / worlds !" << G4endl
260 << " Active Navigators (worlds): "
262 << " which is more than the number allowed: "
263 << fMaxNav << " !";
264 G4Exception("G4MultiNavigator::PrepareNavigators()", "GeomNav0002",
265 FatalException, message);
266 }
267
269 for( auto num=0; num< fNoActiveNavigators; ++pNavigatorIter,++num )
270 {
271 fpNavigator[num] = *pNavigatorIter;
272 fLimitTruth[num] = false;
273 fLimitedStep[num] = kDoNot;
274 fCurrentStepSize[num] = 0.0;
275 fLocatedVolume[num] = nullptr;
276 }
277 fWasLimitedByGeometry = false;
278
279 // Check the world volume of the mass navigator
280 // in case a call to SetWorldVolume() changed it
281
282 G4VPhysicalVolume* massWorld = GetWorldVolume();
283
284 if( (massWorld != fLastMassWorld) && (massWorld!=0) )
285 {
286 // Pass along change to Mass Navigator
287 fpNavigator[0] -> SetWorldVolume( massWorld );
288
289#ifdef G4DEBUG_NAVIGATION
290 if( fVerbose > 0 )
291 {
292 G4cout << " G4MultiNavigator::PrepareNavigators() changed world volume "
293 << " for mass geometry to " << massWorld->GetName() << G4endl;
294 }
295#endif
296
297 fLastMassWorld = massWorld;
298 }
299}

References FatalException, fCurrentStepSize, fLastMassWorld, fLimitedStep, fLimitTruth, fLocatedVolume, fMaxNav, fNoActiveNavigators, fpNavigator, G4Navigator::fVerbose, G4Navigator::fWasLimitedByGeometry, G4cout, G4endl, G4Exception(), G4TransportationManager::GetActiveNavigatorsIterator(), G4VPhysicalVolume::GetName(), G4Navigator::GetWorldVolume(), kDoNot, pTransportManager, and G4Navigator::SetWorldVolume().

Referenced by G4PathFinder::PrepareNewTrack(), and PrepareNewTrack().

◆ PrepareNewTrack()

void G4MultiNavigator::PrepareNewTrack ( const G4ThreeVector  position,
const G4ThreeVector  direction 
)

Definition at line 217 of file G4MultiNavigator.cc.

219{
220#ifdef G4DEBUG_NAVIGATION
221 if( fVerbose > 1 )
222 {
223 G4cout << " Entered G4MultiNavigator::PrepareNewTrack() " << G4endl;
224 }
225#endif
226
228
229 LocateGlobalPointAndSetup( position, &direction, false, false );
230 //
231 // The first location for each Navigator must be non-relative
232 // or else call ResetStackAndState() for each Navigator
233 // Use direction to get correct side of boundary (ignore dir= false)
234}
G4VPhysicalVolume * LocateGlobalPointAndSetup(const G4ThreeVector &point, const G4ThreeVector *direction=nullptr, const G4bool pRelativeSearch=true, const G4bool ignoreDirection=true)

References G4Navigator::fVerbose, G4cout, G4endl, LocateGlobalPointAndSetup(), and PrepareNavigators().

◆ PrintLimited()

void G4MultiNavigator::PrintLimited ( )
protected

Definition at line 530 of file G4MultiNavigator.cc.

531{
532 // Report results -- for checking
533
534 static const G4String StrDoNot("DoNot"), StrUnique("Unique"),
535 StrUndefined("Undefined"),
536 StrSharedTransport("SharedTransport"),
537 StrSharedOther("SharedOther");
538 G4cout << "### G4MultiNavigator::PrintLimited() reports: " << G4endl;
539 G4cout << " Minimum step (true): " << fTrueMinStep
540 << ", reported min: " << fMinStep << G4endl;
541
542#ifdef G4DEBUG_NAVIGATION
543 if(fVerbose>=2)
544 {
545 G4cout << std::setw(5) << " NavId" << " "
546 << std::setw(12) << " step-size " << " "
547 << std::setw(12) << " raw-size " << " "
548 << std::setw(12) << " pre-safety " << " "
549 << std::setw(15) << " Limited / flag" << " "
550 << std::setw(15) << " World " << " "
551 << G4endl;
552 }
553#endif
554
555 for ( auto num = 0; num < fNoActiveNavigators; ++num )
556 {
557 G4double rawStep = fCurrentStepSize[num];
558 G4double stepLen = fCurrentStepSize[num];
559 if( stepLen > fTrueMinStep )
560 {
561 stepLen = fTrueMinStep; // did not limit (went as far as asked)
562 }
563 G4int oldPrec = G4cout.precision(9);
564
565 G4cout << std::setw(5) << num << " "
566 << std::setw(12) << stepLen << " "
567 << std::setw(12) << rawStep << " "
568 << std::setw(12) << fNewSafety[num] << " "
569 << std::setw(5) << (fLimitTruth[num] ? "YES" : " NO") << " ";
570 G4String limitedStr;
571 switch ( fLimitedStep[num] )
572 {
573 case kDoNot : limitedStr = StrDoNot; break;
574 case kUnique : limitedStr = StrUnique; break;
575 case kSharedTransport: limitedStr = StrSharedTransport; break;
576 case kSharedOther : limitedStr = StrSharedOther; break;
577 default : limitedStr = StrUndefined; break;
578 }
579 G4cout << " " << std::setw(15) << limitedStr << " ";
580 G4cout.precision(oldPrec);
581
582 G4Navigator *pNav = fpNavigator[ num ];
583 G4String WorldName( "Not-Set" );
584 if (pNav != nullptr)
585 {
586 G4VPhysicalVolume *pWorld = pNav->GetWorldVolume();
587 if( pWorld )
588 {
589 WorldName = pWorld->GetName();
590 }
591 }
592 G4cout << " " << WorldName ;
593 G4cout << G4endl;
594 }
595}
@ kUnique
@ kSharedOther
@ kSharedTransport

References fCurrentStepSize, fLimitedStep, fLimitTruth, fMinStep, fNewSafety, fNoActiveNavigators, fpNavigator, fTrueMinStep, G4Navigator::fVerbose, G4cout, G4endl, G4VPhysicalVolume::GetName(), G4Navigator::GetWorldVolume(), kDoNot, kSharedOther, kSharedTransport, and kUnique.

◆ PrintState()

void G4Navigator::PrintState ( ) const
inherited

Definition at line 1964 of file G4Navigator.cc.

1965{
1966 G4int oldcoutPrec = G4cout.precision(4);
1967 if( fVerbose >= 4 )
1968 {
1969 G4cout << "The current state of G4Navigator is: " << G4endl;
1970 G4cout << " ValidExitNormal= " << fValidExitNormal // << G4endl
1971 << " ExitNormal = " << fExitNormal // << G4endl
1972 << " Exiting = " << fExiting // << G4endl
1973 << " Entering = " << fEntering // << G4endl
1974 << " BlockedPhysicalVolume= " ;
1976 {
1977 G4cout << "None";
1978 }
1979 else
1980 {
1982 }
1983 G4cout << G4endl
1984 << " BlockedReplicaNo = " << fBlockedReplicaNo // << G4endl
1985 << " LastStepWasZero = " << fLastStepWasZero // << G4endl
1986 << G4endl;
1987 }
1988 if( ( 1 < fVerbose) && (fVerbose < 4) )
1989 {
1990 G4cout << G4endl; // Make sure to line up
1991 G4cout << std::setw(30) << " ExitNormal " << " "
1992 << std::setw( 5) << " Valid " << " "
1993 << std::setw( 9) << " Exiting " << " "
1994 << std::setw( 9) << " Entering" << " "
1995 << std::setw(15) << " Blocked:Volume " << " "
1996 << std::setw( 9) << " ReplicaNo" << " "
1997 << std::setw( 8) << " LastStepZero " << " "
1998 << G4endl;
1999 G4cout << "( " << std::setw(7) << fExitNormal.x()
2000 << ", " << std::setw(7) << fExitNormal.y()
2001 << ", " << std::setw(7) << fExitNormal.z() << " ) "
2002 << std::setw( 5) << fValidExitNormal << " "
2003 << std::setw( 9) << fExiting << " "
2004 << std::setw( 9) << fEntering << " ";
2005 if ( fBlockedPhysicalVolume == nullptr )
2006 { G4cout << std::setw(15) << "None"; }
2007 else
2008 { G4cout << std::setw(15)<< fBlockedPhysicalVolume->GetName(); }
2009 G4cout << std::setw( 9) << fBlockedReplicaNo << " "
2010 << std::setw( 8) << fLastStepWasZero << " "
2011 << G4endl;
2012 }
2013 if( fVerbose > 2 )
2014 {
2015 G4cout.precision(8);
2016 G4cout << " Current Localpoint = " << fLastLocatedPointLocal << G4endl;
2017 G4cout << " PreviousSftOrigin = " << fPreviousSftOrigin << G4endl;
2018 G4cout << " PreviousSafety = " << fPreviousSafety << G4endl;
2019 }
2020 G4cout.precision(oldcoutPrec);
2021}
double z() const
double x() const
double y() const
G4int fBlockedReplicaNo
Definition: G4Navigator.hh:439
G4bool fValidExitNormal
Definition: G4Navigator.hh:474
G4VPhysicalVolume * fBlockedPhysicalVolume
Definition: G4Navigator.hh:438
G4ThreeVector fExitNormal
Definition: G4Navigator.hh:417

References G4Navigator::fBlockedPhysicalVolume, G4Navigator::fBlockedReplicaNo, G4Navigator::fEntering, G4Navigator::fExiting, G4Navigator::fExitNormal, G4Navigator::fLastLocatedPointLocal, G4Navigator::fLastStepWasZero, G4Navigator::fPreviousSafety, G4Navigator::fPreviousSftOrigin, G4Navigator::fValidExitNormal, G4Navigator::fVerbose, G4cout, G4endl, G4VPhysicalVolume::GetName(), CLHEP::Hep3Vector::x(), CLHEP::Hep3Vector::y(), and CLHEP::Hep3Vector::z().

Referenced by G4Navigator::ComputeSafety(), G4Navigator::ComputeStep(), export_G4Navigator(), and G4Navigator::LocateGlobalPointAndSetup().

◆ ResetHierarchyAndLocate()

G4VPhysicalVolume * G4MultiNavigator::ResetHierarchyAndLocate ( const G4ThreeVector &  point,
const G4ThreeVector &  direction,
const G4TouchableHistory &  h 
)
virtual

Reimplemented from G4Navigator.

Definition at line 644 of file G4MultiNavigator.cc.

647{
648 // Reset geometry for all -- and use the touchable for the mass history
649
650 G4VPhysicalVolume* massVolume = nullptr;
651 G4Navigator* pMassNavigator = fpNavigator[0];
652
653 if( pMassNavigator != nullptr )
654 {
655 massVolume= pMassNavigator->ResetHierarchyAndLocate( point, direction,
656 MassHistory);
657 }
658 else
659 {
660 G4Exception("G4MultiNavigator::ResetHierarchyAndLocate()",
661 "GeomNav0002", FatalException,
662 "Cannot reset hierarchy before navigators are initialised.");
663 }
664
665 std::vector<G4Navigator*>::iterator pNavIter=
667
668 for ( auto num = 0; num < fNoActiveNavigators ; ++pNavIter,++num )
669 {
670 G4bool relativeSearch, ignoreDirection;
671
672 (*pNavIter)-> LocateGlobalPointAndSetup( point,
673 &direction,
674 relativeSearch=false,
675 ignoreDirection=false);
676 }
677 return massVolume;
678}
virtual G4VPhysicalVolume * ResetHierarchyAndLocate(const G4ThreeVector &point, const G4ThreeVector &direction, const G4TouchableHistory &h)
Definition: G4Navigator.cc:102

References FatalException, fNoActiveNavigators, fpNavigator, G4Exception(), G4TransportationManager::GetActiveNavigatorsIterator(), LocateGlobalPointAndSetup(), pTransportManager, and G4Navigator::ResetHierarchyAndLocate().

◆ ResetStackAndState()

void G4Navigator::ResetStackAndState ( )
inlineinherited

◆ ResetState()

void G4MultiNavigator::ResetState ( )
protectedvirtual

Reimplemented from G4Navigator.

Definition at line 600 of file G4MultiNavigator.cc.

601{
602 fWasLimitedByGeometry = false;
603
604 G4Exception("G4MultiNavigator::ResetState()", "GeomNav0001",
606 "Cannot reset state for navigators of G4MultiNavigator.");
607/*
608 std::vector<G4Navigator*>::iterator pNavigatorIter;
609 pNavigatorIter = pTransportManager->GetActiveNavigatorsIterator();
610 for( auto num = 0; num< fNoActiveNavigators; ++pNavigatorIter,++num )
611 {
612 // (*pNavigatorIter)->ResetState(); // KEEP THIS comment !!!
613 }
614*/
615}

References FatalException, G4Navigator::fWasLimitedByGeometry, and G4Exception().

◆ RestoreSavedState()

void G4Navigator::RestoreSavedState ( )
protectedinherited

Definition at line 716 of file G4Navigator.cc.

717{
722
725
727
733
734 // The 'expected' behaviour is to restore these too (fix 2014.05.26)
737}
G4bool fExitedMother
Definition: G4Navigator.hh:404
G4bool fEnteredDaughter
Definition: G4Navigator.hh:398
G4bool fLocatedOutsideWorld
Definition: G4Navigator.hh:479
struct G4Navigator::G4SaveNavigatorState fSaveState
G4VPhysicalVolume * spBlockedPhysicalVolume
Definition: G4Navigator.hh:500

References G4Navigator::fBlockedPhysicalVolume, G4Navigator::fBlockedReplicaNo, G4Navigator::fEnteredDaughter, G4Navigator::fEntering, G4Navigator::fExitedMother, G4Navigator::fExiting, G4Navigator::fExitNormal, G4Navigator::fLastLocatedPointLocal, G4Navigator::fLastStepWasZero, G4Navigator::fLocatedOutsideWorld, G4Navigator::fPreviousSafety, G4Navigator::fPreviousSftOrigin, G4Navigator::fSaveState, G4Navigator::fValidExitNormal, G4Navigator::fWasLimitedByGeometry, G4Navigator::G4SaveNavigatorState::sBlockedReplicaNo, G4Navigator::G4SaveNavigatorState::sEnteredDaughter, G4Navigator::G4SaveNavigatorState::sEntering, G4Navigator::G4SaveNavigatorState::sExitedMother, G4Navigator::G4SaveNavigatorState::sExiting, G4Navigator::G4SaveNavigatorState::sExitNormal, G4Navigator::G4SaveNavigatorState::sLastLocatedPointLocal, G4Navigator::G4SaveNavigatorState::sLastStepWasZero, G4Navigator::G4SaveNavigatorState::sLocatedOutsideWorld, G4Navigator::G4SaveNavigatorState::spBlockedPhysicalVolume, G4Navigator::G4SaveNavigatorState::sPreviousSafety, G4Navigator::G4SaveNavigatorState::sPreviousSftOrigin, G4Navigator::G4SaveNavigatorState::sValidExitNormal, and G4Navigator::G4SaveNavigatorState::sWasLimitedByGeometry.

Referenced by G4Navigator::CheckNextStep(), and G4Navigator::ComputeSafety().

◆ SetExternalNavigation()

void G4Navigator::SetExternalNavigation ( G4VExternalNavigation *  externalNav)
inlineinherited

◆ SetGeometricallyLimitedStep()

void G4Navigator::SetGeometricallyLimitedStep ( )
inlineinherited

◆ SetPushVerbosity()

void G4Navigator::SetPushVerbosity ( G4bool  mode)
inlineinherited

◆ SetSavedState()

void G4Navigator::SetSavedState ( )
protectedinherited

Definition at line 682 of file G4Navigator.cc.

683{
684 // Note: the state of dependent objects is not currently saved.
685 // ( This means that the full state is changed by calls between
686 // SetSavedState() and RestoreSavedState();
687
692
695
697
703
704 // Even the safety sphere - if you want to change it do it explicitly!
705 //
708}

References G4Navigator::fBlockedPhysicalVolume, G4Navigator::fBlockedReplicaNo, G4Navigator::fEnteredDaughter, G4Navigator::fEntering, G4Navigator::fExitedMother, G4Navigator::fExiting, G4Navigator::fExitNormal, G4Navigator::fLastLocatedPointLocal, G4Navigator::fLastStepWasZero, G4Navigator::fLocatedOutsideWorld, G4Navigator::fPreviousSafety, G4Navigator::fPreviousSftOrigin, G4Navigator::fSaveState, G4Navigator::fValidExitNormal, G4Navigator::fWasLimitedByGeometry, G4Navigator::G4SaveNavigatorState::sBlockedReplicaNo, G4Navigator::G4SaveNavigatorState::sEnteredDaughter, G4Navigator::G4SaveNavigatorState::sEntering, G4Navigator::G4SaveNavigatorState::sExitedMother, G4Navigator::G4SaveNavigatorState::sExiting, G4Navigator::G4SaveNavigatorState::sExitNormal, G4Navigator::G4SaveNavigatorState::sLastLocatedPointLocal, G4Navigator::G4SaveNavigatorState::sLastStepWasZero, G4Navigator::G4SaveNavigatorState::sLocatedOutsideWorld, G4Navigator::G4SaveNavigatorState::spBlockedPhysicalVolume, G4Navigator::G4SaveNavigatorState::sPreviousSafety, G4Navigator::G4SaveNavigatorState::sPreviousSftOrigin, G4Navigator::G4SaveNavigatorState::sValidExitNormal, and G4Navigator::G4SaveNavigatorState::sWasLimitedByGeometry.

Referenced by G4Navigator::CheckNextStep(), and G4Navigator::ComputeSafety().

◆ SetupHierarchy()

void G4MultiNavigator::SetupHierarchy ( )
protectedvirtual

Reimplemented from G4Navigator.

Definition at line 619 of file G4MultiNavigator.cc.

620{
621 G4Exception( "G4MultiNavigator::SetupHierarchy()",
622 "GeomNav0001", FatalException,
623 "Cannot setup hierarchy for navigators of G4MultiNavigator.");
624}

References FatalException, and G4Exception().

◆ SetVerboseLevel()

void G4Navigator::SetVerboseLevel ( G4int  level)
inlineinherited

◆ SetVoxelNavigation()

void G4Navigator::SetVoxelNavigation ( G4VoxelNavigation *  voxelNav)
inherited

◆ SetWorldVolume()

void G4Navigator::SetWorldVolume ( G4VPhysicalVolume *  pWorld)
inlineinherited

◆ SeverityOfZeroStepping()

G4int G4Navigator::SeverityOfZeroStepping ( G4int *  noZeroSteps) const
inlineinherited

◆ VolumeType()

EVolume G4Navigator::VolumeType ( const G4VPhysicalVolume *  pVol) const
inlineprotectedinherited

◆ WhichLimited()

void G4MultiNavigator::WhichLimited ( )
protected

Definition at line 471 of file G4MultiNavigator.cc.

472{
473 // Flag which processes limited the step
474
475 G4int last=-1;
476 const G4int IdTransport= 0; // Id of Mass Navigator !!
477 G4int noLimited=0;
478 ELimited shared= kSharedOther;
479
480#ifdef G4DEBUG_NAVIGATION
481 if( fVerbose > 2 )
482 {
483 G4cout << " Entered G4MultiNavigator::WhichLimited() " << G4endl;
484 }
485#endif
486
487 // Assume that [IdTransport] is Mass / Transport
488 //
489 G4bool transportLimited = (fCurrentStepSize[IdTransport] == fMinStep)
490 && ( fMinStep!= kInfinity);
491 if( transportLimited )
492 {
493 shared = kSharedTransport;
494 }
495
496 for ( auto num = 0; num < fNoActiveNavigators; ++num )
497 {
498 G4bool limitedStep;
499
500 G4double step = fCurrentStepSize[num];
501
502 limitedStep = ( step == fMinStep ) && ( step != kInfinity);
503
504 fLimitTruth[ num ] = limitedStep;
505 if( limitedStep )
506 {
507 ++noLimited;
508 fLimitedStep[num] = shared;
509 last= num;
510 }
511 else
512 {
513 fLimitedStep[num] = kDoNot;
514 }
515 }
516 if( (last > -1) && (noLimited == 1 ) )
517 {
518 fLimitedStep[ last ] = kUnique;
519 fIdNavLimiting = last;
520 }
521
522 fNoLimitingStep = noLimited;
523
524 return;
525}
ELimited

References fCurrentStepSize, fIdNavLimiting, fLimitedStep, fLimitTruth, fMinStep, fNoActiveNavigators, fNoLimitingStep, G4Navigator::fVerbose, G4cout, G4endl, kDoNot, kInfinity, kSharedOther, kSharedTransport, and kUnique.

Referenced by ComputeStep().

Friends And Related Function Documentation

◆ operator<<

std::ostream & operator<< ( std::ostream &  os,
const G4Navigator &  n 
)
friend

Definition at line 2157 of file G4Navigator.cc.

2158{
2159 // Old version did only the following:
2160 // os << "Current History: " << G4endl << n.fHistory;
2161 // Old behaviour is recovered for fVerbose = 0
2162
2163 // Adapted from G4Navigator::PrintState() const
2164
2165 G4int oldcoutPrec = os.precision(4);
2166 if( n.fVerbose >= 4 )
2167 {
2168 os << "The current state of G4Navigator is: " << G4endl;
2169 os << " ValidExitNormal= " << n.fValidExitNormal << G4endl
2170 << " ExitNormal = " << n.fExitNormal << G4endl
2171 << " Exiting = " << n.fExiting << G4endl
2172 << " Entering = " << n.fEntering << G4endl
2173 << " BlockedPhysicalVolume= " ;
2174 if (n.fBlockedPhysicalVolume==0)
2175 os << "None";
2176 else
2177 os << n.fBlockedPhysicalVolume->GetName();
2178 os << G4endl
2179 << " BlockedReplicaNo = " << n.fBlockedReplicaNo << G4endl
2180 << " LastStepWasZero = " << n.fLastStepWasZero << G4endl
2181 << G4endl;
2182 }
2183 if( ( 1 < n.fVerbose) && (n.fVerbose < 4) )
2184 {
2185 os << G4endl; // Make sure to line up
2186 os << std::setw(30) << " ExitNormal " << " "
2187 << std::setw( 5) << " Valid " << " "
2188 << std::setw( 9) << " Exiting " << " "
2189 << std::setw( 9) << " Entering" << " "
2190 << std::setw(15) << " Blocked:Volume " << " "
2191 << std::setw( 9) << " ReplicaNo" << " "
2192 << std::setw( 8) << " LastStepZero " << " "
2193 << G4endl;
2194 os << "( " << std::setw(7) << n.fExitNormal.x()
2195 << ", " << std::setw(7) << n.fExitNormal.y()
2196 << ", " << std::setw(7) << n.fExitNormal.z() << " ) "
2197 << std::setw( 5) << n.fValidExitNormal << " "
2198 << std::setw( 9) << n.fExiting << " "
2199 << std::setw( 9) << n.fEntering << " ";
2200 if ( n.fBlockedPhysicalVolume==0 )
2201 { os << std::setw(15) << "None"; }
2202 else
2203 { os << std::setw(15)<< n.fBlockedPhysicalVolume->GetName(); }
2204 os << std::setw( 9) << n.fBlockedReplicaNo << " "
2205 << std::setw( 8) << n.fLastStepWasZero << " "
2206 << G4endl;
2207 }
2208 if( n.fVerbose > 2 )
2209 {
2210 os.precision(8);
2211 os << " Current Localpoint = " << n.fLastLocatedPointLocal << G4endl;
2212 os << " PreviousSftOrigin = " << n.fPreviousSftOrigin << G4endl;
2213 os << " PreviousSafety = " << n.fPreviousSafety << G4endl;
2214 }
2215 if( n.fVerbose > 3 || n.fVerbose == 0 )
2216 {
2217 os << "Current History: " << G4endl << n.fHistory;
2218 }
2219
2220 os.precision(oldcoutPrec);
2221 return os;
2222}

Field Documentation

◆ fAbandonThreshold_NoZeroSteps

G4int G4Navigator::fAbandonThreshold_NoZeroSteps = 25
privateinherited

Definition at line 453 of file G4Navigator.hh.

Referenced by G4Navigator::ComputeStep(), and G4Navigator::G4Navigator().

◆ fActionThreshold_NoZeroSteps

G4int G4Navigator::fActionThreshold_NoZeroSteps = 10
privateinherited

Definition at line 451 of file G4Navigator.hh.

Referenced by G4Navigator::ComputeStep(), and G4Navigator::G4Navigator().

◆ fActive

G4bool G4Navigator::fActive = false
privateinherited

Definition at line 456 of file G4Navigator.hh.

◆ fBlockedPhysicalVolume

G4VPhysicalVolume* G4Navigator::fBlockedPhysicalVolume
privateinherited

◆ fBlockedReplicaNo

G4int G4Navigator::fBlockedReplicaNo
privateinherited

◆ fCalculatedExitNormal

G4bool G4Navigator::fCalculatedExitNormal
privateinherited

◆ fChangedGrandMotherRefFrame

G4bool G4Navigator::fChangedGrandMotherRefFrame
privateinherited

◆ fCheck

G4bool G4Navigator::fCheck = false
privateinherited

◆ fCurrentStepSize

G4double G4MultiNavigator::fCurrentStepSize[fMaxNav]
private

◆ fEnteredDaughter

G4bool G4Navigator::fEnteredDaughter
protectedinherited

◆ fEntering

G4bool G4Navigator::fEntering
privateinherited

◆ fExitedMother

G4bool G4Navigator::fExitedMother
protectedinherited

◆ fExiting

G4bool G4Navigator::fExiting
privateinherited

◆ fExitNormal

G4ThreeVector G4Navigator::fExitNormal
privateinherited

◆ fExitNormalGlobalFrame

G4ThreeVector G4Navigator::fExitNormalGlobalFrame
privateinherited

◆ fGrandMotherExitNormal

G4ThreeVector G4Navigator::fGrandMotherExitNormal
privateinherited

◆ fHistory

G4NavigationHistory G4Navigator::fHistory
protectedinherited

◆ fIdNavLimiting

G4int G4MultiNavigator::fIdNavLimiting = -1
private

◆ fLastLocatedPointLocal

G4ThreeVector G4Navigator::fLastLocatedPointLocal
privateinherited

◆ fLastLocatedPosition

G4ThreeVector G4MultiNavigator::fLastLocatedPosition
private

Definition at line 186 of file G4MultiNavigator.hh.

Referenced by G4MultiNavigator(), and LocateGlobalPointWithinVolume().

◆ fLastMassWorld

G4VPhysicalVolume* G4MultiNavigator::fLastMassWorld = nullptr
private

Definition at line 163 of file G4MultiNavigator.hh.

Referenced by CheckMassWorld(), G4MultiNavigator(), and PrepareNavigators().

◆ fLastMotherPhys

G4VPhysicalVolume* G4Navigator::fLastMotherPhys = nullptr
privateinherited

Definition at line 434 of file G4Navigator.hh.

Referenced by G4Navigator::ComputeStep(), and G4Navigator::ResetState().

◆ fLastStepEndPointLocal

G4ThreeVector G4Navigator::fLastStepEndPointLocal
protectedinherited

◆ fLastStepWasZero

G4bool G4Navigator::fLastStepWasZero
privateinherited

◆ fLastTriedStepComputation

G4bool G4Navigator::fLastTriedStepComputation = false
privateinherited

◆ fLimitedStep

ELimited G4MultiNavigator::fLimitedStep[fMaxNav]
private

◆ fLimitTruth

G4bool G4MultiNavigator::fLimitTruth[fMaxNav]
private

◆ fLocatedOnEdge

G4bool G4Navigator::fLocatedOnEdge
privateinherited

◆ fLocatedOutsideWorld

G4bool G4Navigator::fLocatedOutsideWorld
privateinherited

◆ fLocatedVolume

G4VPhysicalVolume* G4MultiNavigator::fLocatedVolume[fMaxNav]
private

◆ fMaxNav

const G4int G4MultiNavigator::fMaxNav = 16
staticprivate

Definition at line 162 of file G4MultiNavigator.hh.

Referenced by G4MultiNavigator(), and PrepareNavigators().

◆ fMinSafety

G4double G4MultiNavigator::fMinSafety = -kInfinity
private

Definition at line 180 of file G4MultiNavigator.hh.

◆ fMinSafety_atSafLocation

G4double G4MultiNavigator::fMinSafety_atSafLocation = -1.0
private

Definition at line 192 of file G4MultiNavigator.hh.

Referenced by ComputeSafety().

◆ fMinSafety_PreStepPt

G4double G4MultiNavigator::fMinSafety_PreStepPt = -1.0
private

Definition at line 196 of file G4MultiNavigator.hh.

Referenced by ComputeStep().

◆ fMinStep

G4double G4MultiNavigator::fMinStep = -kInfinity
private

Definition at line 179 of file G4MultiNavigator.hh.

Referenced by ComputeStep(), ObtainFinalStep(), PrintLimited(), and WhichLimited().

◆ fNewSafety

G4double G4MultiNavigator::fNewSafety[fMaxNav]
private

Definition at line 173 of file G4MultiNavigator.hh.

Referenced by ComputeStep(), G4MultiNavigator(), ObtainFinalStep(), and PrintLimited().

◆ fNoActiveNavigators

G4int G4MultiNavigator::fNoActiveNavigators = 0
private

◆ fNoLimitingStep

G4int G4MultiNavigator::fNoLimitingStep = -1
private

◆ fnormalNav

G4NormalNavigation G4Navigator::fnormalNav
privateinherited

◆ fNumberZeroSteps

G4int G4Navigator::fNumberZeroSteps
privateinherited

Definition at line 449 of file G4Navigator.hh.

Referenced by G4Navigator::ComputeStep(), and G4Navigator::ResetState().

◆ fparamNav

G4ParameterisedNavigation G4Navigator::fparamNav
privateinherited

◆ fpExternalNav

G4VExternalNavigation* G4Navigator::fpExternalNav = nullptr
privateinherited

◆ fpNavigator

G4Navigator* G4MultiNavigator::fpNavigator[fMaxNav]
private

◆ fPreStepLocation

G4ThreeVector G4MultiNavigator::fPreStepLocation
private

Definition at line 194 of file G4MultiNavigator.hh.

Referenced by ComputeStep(), and G4MultiNavigator().

◆ fPreviousSafety

G4double G4Navigator::fPreviousSafety
privateinherited

◆ fPreviousSftOrigin

G4ThreeVector G4Navigator::fPreviousSftOrigin
privateinherited

◆ fPushed

G4bool G4Navigator::fPushed = false
privateinherited

Definition at line 539 of file G4Navigator.hh.

Referenced by G4Navigator::ComputeStep(), and G4Navigator::ResetState().

◆ fpvoxelNav

G4VoxelNavigation* G4Navigator::fpvoxelNav
privateinherited

Definition at line 525 of file G4Navigator.hh.

Referenced by G4Navigator::G4Navigator(), and G4Navigator::~G4Navigator().

◆ fpVoxelSafety

G4VoxelSafety* G4Navigator::fpVoxelSafety
privateinherited

◆ fregularNav

G4RegularNavigation G4Navigator::fregularNav
privateinherited

◆ freplicaNav

G4ReplicaNavigation G4Navigator::freplicaNav
privateinherited

◆ fSafetyLocation

G4ThreeVector G4MultiNavigator::fSafetyLocation
private

Definition at line 190 of file G4MultiNavigator.hh.

Referenced by ComputeSafety(), and G4MultiNavigator().

◆ fSaveState

struct G4Navigator::G4SaveNavigatorState G4Navigator::fSaveState
privateinherited

◆ fSqTol

G4double G4Navigator::fSqTol
protectedinherited

◆ fStepEndPoint

G4ThreeVector G4Navigator::fStepEndPoint
protectedinherited

◆ fTopPhysical

G4VPhysicalVolume* G4Navigator::fTopPhysical = nullptr
privateinherited

Definition at line 517 of file G4Navigator.hh.

◆ fTrueMinStep

G4double G4MultiNavigator::fTrueMinStep = -kInfinity
private

Definition at line 181 of file G4MultiNavigator.hh.

Referenced by ComputeStep(), and PrintLimited().

◆ fValidExitNormal

G4bool G4Navigator::fValidExitNormal
privateinherited

◆ fVerbose

G4int G4Navigator::fVerbose = 0
protectedinherited

◆ fWarnPush

G4bool G4Navigator::fWarnPush = true
privateinherited

Definition at line 539 of file G4Navigator.hh.

Referenced by G4Navigator::ComputeStep().

◆ fWasLimitedByGeometry

G4bool G4Navigator::fWasLimitedByGeometry = false
protectedinherited

◆ kCarTolerance

G4double G4Navigator::kCarTolerance
protectedinherited

◆ pTransportManager

G4TransportationManager* G4MultiNavigator::pTransportManager
private

The documentation for this class was generated from the following files: