Geant4  v4-10.4-release
 모두 클래스 네임스페이스들 파일들 함수 변수 타입정의 열거형 타입 열거형 멤버 Friends 매크로 그룹들 페이지들
G4AdjointTrackingAction.hh
이 파일의 문서화 페이지로 가기
1 //
2 // ********************************************************************
3 // * License and Disclaimer *
4 // * *
5 // * The Geant4 software is copyright of the Copyright Holders of *
6 // * the Geant4 Collaboration. It is provided under the terms and *
7 // * conditions of the Geant4 Software License, included in the file *
8 // * LICENSE and available at http://cern.ch/geant4/license . These *
9 // * include a list of copyright holders. *
10 // * *
11 // * Neither the authors of this software system, nor their employing *
12 // * institutes,nor the agencies providing financial support for this *
13 // * work make any representation or warranty, express or implied, *
14 // * regarding this software system or assume any liability for its *
15 // * use. Please see the license in the file LICENSE and URL above *
16 // * for the full disclaimer and the limitation of liability. *
17 // * *
18 // * This code implementation is the result of the scientific and *
19 // * technical work of the GEANT4 collaboration. *
20 // * By using, copying, modifying or distributing the software (or *
21 // * any work based on the software) you agree to acknowledge its *
22 // * use in resulting scientific publications, and indicate your *
23 // * acceptance of all terms of the Geant4 Software license. *
24 // ********************************************************************
25 //
26 //
27 // $Id: G4AdjointTrackingAction.hh 75409 2013-11-01 00:31:00Z ldesorgh$
28 //
29 //
30 //---------------------------------------------------------------
31 //
32 // G4AdjointTrackingAction.hh
33 //
34 // class description:
35 // This class represents actions taken place at the
36 // the start/end point of processing one track during an adjoint simulation
37 //
38 //---------------------------------------------------------------
39 
40 
41 
42 #ifndef G4AdjointTrackingAction_h
43 #define G4AdjointTrackingAction_h 1
44 #include "globals.hh"
45 #include "G4UserTrackingAction.hh"
46 #include "G4ThreeVector.hh"
47 #include <vector>
49 class G4Track;
54 {
55 
56 //--------
57 public: // with description
58 //--------
59 
60 // Constructor & Destructor
62  virtual ~G4AdjointTrackingAction();
63 
64 // Member functions
65  virtual void PreUserTrackingAction(const G4Track*);
66  virtual void PostUserTrackingAction(const G4Track*);
69 
70 //inline methods
72  theUserFwdTrackingAction = anAction;}
75  inline G4double GetEkinAtEndOfLastAdjointTrack(size_t i=0){ return last_ekin_vec[i];}
82  inline G4int GetLastFwdParticleIndex(size_t i=0){
83  return last_fwd_part_index_vec[i];};
85  inline void SetListOfPrimaryFwdParticles( std::vector<G4ParticleDefinition*>*
86  aListOfParticles){pListOfPrimaryFwdParticles=aListOfParticles;}
87 
88 
89 private:
93 
94 
95  //adjoint particle information on the external surface
96  //-----------------------------
99  G4double last_ekin,last_ekin_nuc; //last_ekin_nuc=last_ekin/nuc, nuc is 1 if not a nucleus
105  std::vector<G4ParticleDefinition*>* pListOfPrimaryFwdParticles;
106 
107  std::vector<G4ThreeVector> last_pos_vec;
108  std::vector<G4ThreeVector> last_direction_vec;
109  std::vector<G4double> last_ekin_vec;
110  std::vector<G4double> last_ekin_nuc_vec;
111  std::vector<G4double> last_cos_th_vec;
112  std::vector<G4double> last_weight_vec;
113  std::vector<G4int> last_fwd_part_PDGEncoding_vec;
114  std::vector<G4int> last_fwd_part_index_vec;
115 
116 };
117 
118 #endif
119 
120 
G4ThreeVector GetDirectionAtEndOfLastAdjointTrack(size_t i=0)
virtual void PreUserTrackingAction(const G4Track *)
G4ThreeVector GetPositionAtEndOfLastAdjointTrack(size_t i=0)
std::vector< G4int > last_fwd_part_PDGEncoding_vec
std::vector< G4double > last_weight_vec
std::vector< G4ThreeVector > last_pos_vec
G4double GetWeightAtEndOfLastAdjointTrack(size_t i=0)
void SetUserForwardTrackingAction(G4UserTrackingAction *anAction)
G4double GetCosthAtEndOfLastAdjointTrack(size_t i=0)
G4AdjointSteppingAction * theAdjointSteppingAction
size_t GetNbOfAdointTracksReachingTheExternalSurface()
G4double GetEkinAtEndOfLastAdjointTrack(size_t i=0)
double G4double
Definition: G4Types.hh:76
bool G4bool
Definition: G4Types.hh:79
std::vector< G4double > last_cos_th_vec
void SetListOfPrimaryFwdParticles(std::vector< G4ParticleDefinition * > *aListOfParticles)
G4AdjointTrackingAction(G4AdjointSteppingAction *anAction)
std::vector< G4double > last_ekin_vec
std::vector< G4double > last_ekin_nuc_vec
std::vector< G4ParticleDefinition * > * pListOfPrimaryFwdParticles
G4double GetEkinNucAtEndOfLastAdjointTrack(size_t i=0)
int G4int
Definition: G4Types.hh:78
std::vector< G4int > last_fwd_part_index_vec
const G4String & GetFwdParticleNameAtEndOfLastAdjointTrack()
G4int GetLastFwdParticleIndex(size_t i=0)
std::vector< G4ThreeVector > last_direction_vec
virtual void PostUserTrackingAction(const G4Track *)
G4UserTrackingAction * theUserFwdTrackingAction
G4int GetFwdParticlePDGEncodingAtEndOfLastAdjointTrack(size_t i=0)