ECCE @ EIC Software
Reference for
ECCE @ EIC
simulation and reconstruction software on GitHub
Home page
Related Pages
Modules
Namespaces
Classes
Files
External Links
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
G4AdjointPrimaryGenerator.hh
Go to the documentation of this file.
Or view
the newest version in sPHENIX GitHub for file G4AdjointPrimaryGenerator.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
//
28
// Module: G4AdjointPrimaryGenerator
29
// Author: L. Desorgher
30
// Organisation: SpaceIT GmbH
31
// Contract: ESA contract 21435/08/NL/AT
32
// Customer: ESA/ESTEC
34
//
35
// CHANGE HISTORY
36
// --------------
37
// ChangeHistory:
38
// November 2009 creation by L. Desorgher, Splitting of G4AdjointPrimaryGeneratorAction in two classes G4AdjointPrimaryGeneratorAction and G4AdjointPrimaryGenerator
39
//
40
//-------------------------------------------------------------
41
// Documentation:
42
// This class represents the Primary Generator that generate vertex (energy,position and direction) of primary adjoint particles.
43
// It is used by G4AdjointPrimaryGeneratorAction. If the adjoint source is selected by the user as being on the external boundary of a volume
44
// it uses the class G4AdjointPosOnPhysVolGenerator to generate the vertex positions and directions. Otherwise G4SingleParticleSource is used.
45
//
46
//
47
//
48
#ifndef G4AdjointPrimaryGenerator_h
49
#define G4AdjointPrimaryGenerator_h 1
50
#include "
globals.hh
"
51
#include"
G4ThreeVector.hh
"
52
#include <vector>
53
#include <map>
54
#include <iterator>
55
#include"
G4PhysicsOrderedFreeVector.hh
"
56
57
58
class
G4AdjointPosOnPhysVolGenerator
;
59
class
G4Event
;
60
class
G4SingleParticleSource
;
61
class
G4ParticleDefinition
;
62
class
G4Navigator
;
63
65
//
66
class
G4AdjointPrimaryGenerator
67
{
public
:
68
G4AdjointPrimaryGenerator
();
69
~G4AdjointPrimaryGenerator
();
70
71
public
:
//public methods
72
73
void
GenerateAdjointPrimaryVertex
(
G4Event
* anEvt,
G4ParticleDefinition
* adj_part,
G4double
E1,
G4double
E2);
74
void
GenerateFwdPrimaryVertex
(
G4Event
* anEvt,
G4ParticleDefinition
* adj_part,
G4double
E1,
G4double
E2);
75
void
SetSphericalAdjointPrimarySource
(
G4double
radius
,
G4ThreeVector
pos
);
76
void
SetAdjointPrimarySourceOnAnExtSurfaceOfAVolume
(
const
G4String
& volume_name);
77
void
ComputeAccumulatedDepthVectorAlongBackRay
(
G4ThreeVector
glob_pos,
78
G4ThreeVector
direction,
79
G4double
ekin,
80
G4ParticleDefinition
* aPartDef);
81
G4double
SampleDistanceAlongBackRayAndComputeWeightCorrection
(
G4double
& weight_corr);
82
83
84
private
:
//attributes
85
86
//The class responsible for the random generation of positions and direction of primaries for adjoint source set on the external surface of
87
//a G4 volume
88
G4AdjointPosOnPhysVolGenerator
*
theG4AdjointPosOnPhysVolGenerator
;
89
90
G4SingleParticleSource
*
theSingleParticleSource
;
91
92
//Type of adjoint source
93
//--------------------
94
G4String
type_of_adjoint_source
;
//Spherical ExtSurfaceOfAVolume
95
G4double
radius_spherical_source
;
96
G4ThreeVector
center_spherical_source
;
97
G4Navigator
*
fLinearNavigator
;
98
G4PhysicsOrderedFreeVector
*
theAccumulatedDepthVector
;
99
//G4PhysicsOrderedFreeVector* theAccumulatedCSDepthVector;
100
101
//Disable copy constructor and assignement operator
102
G4AdjointPrimaryGenerator
(
const
G4AdjointPrimaryGenerator
&);
103
G4AdjointPrimaryGenerator
&
operator=
(
const
G4AdjointPrimaryGenerator
&);
104
105
106
107
};
108
#endif
109
geant4
tree
geant4-10.6-release
source
event
include
G4AdjointPrimaryGenerator.hh
Built by
Jin Huang
. updated:
Wed Jun 29 2022 17:25:13
using
1.8.2 with
ECCE GitHub integration