Import Geant4 11.4.0.beta source tree

This commit is contained in:
Gabriele Cosmo
2025-06-26 09:17:29 +02:00
parent 20a218bbe1
commit a499fb82e9
1941 changed files with 203285 additions and 95593 deletions
@@ -23,7 +23,7 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
// class G4ErrorPropagationNavigator
// G4ErrorPropagationNavigator
//
// Class Description:
//
@@ -31,50 +31,78 @@
// on the target surface for error propagation. It overloads ComputeStep()
// and ComputeSafety() methods.
// Created. P. Arce, September 2004
// Author: Pedro Arce (CIEMAT), September 2004
// --------------------------------------------------------------------
#ifndef G4ErrorPropagationNavigator_hh
#define G4ErrorPropagationNavigator_hh 1
#include "G4Navigator.hh"
#include "G4ThreeVector.hh"
/**
* @brief G4ErrorPropagationNavigator is a class for performing double
* navigation in the detector geometry and on the target surface for error
* propagation. It overloads ComputeStep() and ComputeSafety() methods.
*/
class G4ErrorPropagationNavigator : public G4Navigator
{
public:
/**
* Constructor and Destructor.
*/
G4ErrorPropagationNavigator() = default;
~G4ErrorPropagationNavigator() override = default;
~G4ErrorPropagationNavigator() override = default;
G4double ComputeStep (const G4ThreeVector &pGlobalPoint,
const G4ThreeVector &pDirection,
/**
* Calls the navigation in the detector geometry and then checks
* if the distance to surface is smaller than the proposed step.
* @param[in] pGlobalPoint The point in global coordinates system.
* @param[in] pDirection The normalised vector direction.
* @param[in] pCurrentProposedStepLength Current proposed step length.
* @param[in,out] newSafety New safety.
* @returns Length from current point to next boundary surface along
* @p pDirection.
*/
G4double ComputeStep (const G4ThreeVector& pGlobalPoint,
const G4ThreeVector& pDirection,
const G4double pCurrentProposedStepLength,
G4double &pNewSafety) override;
// Calls the navigation in the detector geometry and then checks
// if the distance to surface is smaller than the proposed step
G4double ComputeSafety(const G4ThreeVector &globalpoint,
/**
* Calls the navigation in the detector geometry and then checks
* if the distance to surface is smaller than the proposed safety.
* @param[in] globalpoint The point in global coordinates system.
* The point must be within the current volume.
* @param[in] pProposedMaxLength The proposed maximum length is used
* to avoid volume safety calculations.
* @param[in] keepState Flag to instruct keeping the state (default true)
* to ensure minimum side effects from the call.
* @returns Length from current point to closest boundary surface.
* The value returned is usually an underestimate.
*/
G4double ComputeSafety(const G4ThreeVector& globalpoint,
const G4double pProposedMaxLength = DBL_MAX,
const G4bool keepState = true) override;
// Calls the navigation in the detector geometry and then checks
// if the distance to surface is smaller than the proposed safety
/**
* Returns Exit Surface Normal and validity too. Can only be called if
* the Navigator's last Step has crossed a volume geometrical boundary.
* Normal points out of the volume exited and/or into the volume entered.
* @param[in] point Point in global coordinates system to compare to.
* @param[in,out] valid Flag indicating if normal is valid.
* @returns A Exit Surface Normal vector and validity too.
*/
G4ThreeVector GetGlobalExitNormal(const G4ThreeVector& point,
G4bool* valid) override;
// Return Exit Surface Normal and validity too. Can only be called if
// the Navigator's last Step has crossed a volume geometrical boundary.
// Normal points out of the volume exited and/or into the volume entered.
G4double TargetSafetyFromPoint( const G4ThreeVector &pGlobalpoint );
// Isotropic safety for 'Target'
//-- NOT implemented, as it is difficult to define the coordinate system:
// G4ThreeVector GetLocalExitNormal(G4bool* valid);
// G4ThreeVector GetLocalExitNormalAndCheck(const G4ThreeVector& point,
// G4bool* valid);
// Convention:
// The *local* normal is in the coordinate system of the *final* volume.
/**
* Computes the isotropic safety for 'Target'.
* @param[in] pGlobalpoint Point in global coordinates system.
* @returns The isotropic safety value.
*/
G4double TargetSafetyFromPoint( const G4ThreeVector& pGlobalpoint );
};
#endif