Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-09-15 08:58:34

0001 //
0002 // ********************************************************************
0003 // * License and Disclaimer                                           *
0004 // *                                                                  *
0005 // * The  Geant4 software  is  copyright of the Copyright Holders  of *
0006 // * the Geant4 Collaboration.  It is provided  under  the terms  and *
0007 // * conditions of the Geant4 Software License,  included in the file *
0008 // * LICENSE and available at  http://cern.ch/geant4/license .  These *
0009 // * include a list of copyright holders.                             *
0010 // *                                                                  *
0011 // * Neither the authors of this software system, nor their employing *
0012 // * institutes,nor the agencies providing financial support for this *
0013 // * work  make  any representation or  warranty, express or implied, *
0014 // * regarding  this  software system or assume any liability for its *
0015 // * use.  Please see the license in the file  LICENSE  and URL above *
0016 // * for the full disclaimer and the limitation of liability.         *
0017 // *                                                                  *
0018 // * This  code  implementation is the result of  the  scientific and *
0019 // * technical work of the GEANT4 collaboration.                      *
0020 // * By using,  copying,  modifying or  distributing the software (or *
0021 // * any work based  on the software)  you  agree  to acknowledge its *
0022 // * use  in  resulting  scientific  publications,  and indicate your *
0023 // * acceptance of all terms of the Geant4 Software license.          *
0024 // ********************************************************************
0025 //
0026 // class G4ErrorPropagationNavigator
0027 //
0028 // Class Description:
0029 //
0030 // Class for performing double navigation in the detector geometry and
0031 // on the target surface for error propagation. It overloads ComputeStep()
0032 // and ComputeSafety() methods.
0033 
0034 // Created. P. Arce, September 2004
0035 // --------------------------------------------------------------------
0036 
0037 #ifndef G4ErrorPropagationNavigator_hh
0038 #define G4ErrorPropagationNavigator_hh 1
0039 
0040 #include "G4Navigator.hh"
0041 #include "G4ThreeVector.hh"
0042 
0043 class G4ErrorPropagationNavigator : public G4Navigator
0044 {
0045   public:
0046 
0047     G4ErrorPropagationNavigator() = default;
0048    ~G4ErrorPropagationNavigator() override = default;
0049   
0050     G4double ComputeStep (const G4ThreeVector &pGlobalPoint,
0051                           const G4ThreeVector &pDirection,
0052                           const G4double pCurrentProposedStepLength,
0053                                 G4double &pNewSafety) override;
0054       // Calls the navigation in the detector geometry and then checks
0055       // if the distance to surface is smaller than the proposed step
0056 
0057     G4double ComputeSafety(const G4ThreeVector &globalpoint,
0058                            const G4double pProposedMaxLength = DBL_MAX,
0059                            const G4bool keepState = true) override;
0060       // Calls the navigation in the detector geometry and then checks
0061       // if the distance to surface is smaller than the proposed safety
0062   
0063     G4ThreeVector GetGlobalExitNormal(const G4ThreeVector& point,
0064                                             G4bool* valid) override;
0065       // Return Exit Surface Normal and validity too. Can only be called if
0066       // the Navigator's last Step has crossed a volume geometrical boundary.
0067       // Normal points out of the volume exited and/or into the volume entered.
0068 
0069     G4double TargetSafetyFromPoint( const G4ThreeVector &pGlobalpoint );
0070       // Isotropic safety for 'Target' 
0071    
0072     //-- NOT implemented, as it is difficult to define the coordinate system:
0073     // G4ThreeVector GetLocalExitNormal(G4bool* valid);
0074     // G4ThreeVector GetLocalExitNormalAndCheck(const G4ThreeVector& point,
0075     //                                               G4bool* valid);
0076     // Convention:
0077     //   The *local* normal is in the coordinate system of the *final* volume.
0078 };
0079 
0080 #endif