Geant4
11.2.2
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4AdjointSimMessenger.hh
Go to the documentation of this file.
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
// G4AdjointSimMessenger
27
//
28
// Class description:
29
//
30
// This class represents the Messenger that defines the G4UI macro commands
31
// allowing the user controlling an adjoint/reverse MC simulation. It calls
32
// methods of G4AdjointSimManager.
33
//
34
// 1) Start an adjoint simulation
35
// ---------------------------------------------------
36
// Command:
37
// -/adjoint/start_run nb: Start an adjoint simulation with a number of
38
// events given by nb.
39
// 2) Definition of the external source
40
// ---------------------------------------------------
41
// The external source represents the real external source of particles till
42
// which adjoint particles are tracked in the reverse tracking mode of the
43
// simulation (see G4AdjointSimManager.hh and G4Application Developer guide for
44
// more infos). The user can define the source as the external surface of a
45
// sphere or of G4 volume of the geometry. He can also set the maximum energy
46
// of the source. If an adjoint particle get an energy higher than this maximum
47
// energy before reaching the external surface source it is killed without
48
// being registered.
49
// Commands:
50
// -/adjoint/DefineSphericalExtSource R X Y Z unit_length
51
// The external source is set on a sphere with radius R and centered on
52
// position (X,Y,Z)
53
// -/adjoint/DefineSphericalExtSourceCenteredOnAVolume pvol_name R unit_length
54
// The external source is set on a sphere with radius R and with its center
55
// position located at the center of the physical volume specified by the
56
// name pvol_name.
57
// -/adjoint/DefineExtSourceOnExtSurfaceOfAVolume pvol_name
58
// The external surface is set as the external boundary of a the physical
59
// volume with name pvol_name.
60
// -/adjoint/SetExtSourceEmax Emax energy_unit
61
// Set the maximum energy of the external source.
62
//
63
// 3) Definition of the adjoint source
64
// ---------------------------------------------------
65
// The adjoint source represents the source from which adjoint primary
66
// particles are generated (see G4AdjointSimManager.hh and G4Application
67
// Developer guide for more infos).
68
// The user can define the source as the external surface of a sphere or of
69
// G4 volume of the geometry. He sets the minimum maximum energy of the
70
// source and defines which type of adjoint primary particles should be
71
// considered.
72
// Commands:
73
// -/adjoint/DefineSphericalAdjSource R X Y Z unit_length
74
// The adjoint source is set on a sphere with radius R and centered on
75
// position (X,Y,Z)
76
// -/adjoint/DefineSphericalAdjSourceCenteredOnAVolume pvol_name R unit_length
77
// The external source is set on a sphere with radius R and with its center
78
// position located at the center of the physical volume specified by the
79
// name pvol_name.
80
// -/adjoint/DefineAdjSourceOnExtSurfaceOfAVolume pvol_name
81
// The external surface is set as the external boundary of a the
82
// physical volume with name pvol_name
83
// -/adjoint/SetAdjSourceEmin Emin energy_unit
84
// Set the minimum energy of the external source
85
// -/adjoint/SetAdjSourceEmax Emax energy_unit
86
// Set the maximum energy of the external source
87
// -/adjoint/ConsiderAsPrimary particle_name
88
// The type of particle specified by "particle_name" will be added in
89
// the list of primary adjoint particles. The list of candidates depends on the
90
// reverse physics processes considered in the simulation. At the most the potential
91
// candidates are (e-, gamma, proton, ion).
92
// -/adjoint/NeglectAsPrimary particle_name
93
// The type of particle specified by "particle_name" will be removed
94
// from the list of primary adjoint particles. The list of candidates depends
95
// on the reverse physics processes considered in the simulation. At the most
96
// the potential candidates are (e-, gamma, proton, ion).
97
98
// --------------------------------------------------------------------
99
// Class Name: G4AdjointSimMessenger
100
// Author: L. Desorgher, 2007-2009
101
// Organisation: SpaceIT GmbH
102
// Contract: ESA contract 21435/08/NL/AT
103
// Customer: ESA/ESTEC
104
// --------------------------------------------------------------------
105
#ifndef G4AdjointSimMessenger_hh
106
#define G4AdjointSimMessenger_hh 1
107
108
#include "
G4UImessenger.hh
"
109
#include "
globals.hh
"
110
111
class
G4AdjointSimManager
;
112
class
G4UIdirectory
;
113
class
G4UIcmdWithAString
;
114
class
G4UIcmdWithAnInteger
;
115
class
G4UIcmdWith3VectorAndUnit
;
116
class
G4UIcmdWithABool
;
117
class
G4UIcmdWithADoubleAndUnit
;
118
class
G4UIcmdWithoutParameter
;
119
class
G4UIcmdWithADouble
;
120
121
// --------------------------------------------------------------------
122
123
class
G4AdjointSimMessenger
:
public
G4UImessenger
124
{
125
public
:
126
G4AdjointSimMessenger
(
G4AdjointSimManager
*);
127
~G4AdjointSimMessenger
()
override
;
128
129
void
SetNewValue
(
G4UIcommand
*,
G4String
)
override
;
130
131
private
:
132
G4AdjointSimManager
* theAdjointRunManager;
133
134
G4UIdirectory
* AdjointSimDir =
nullptr
;
135
G4UIcommand
* beamOnCmd =
nullptr
;
136
137
G4UIcommand
* DefineSpherExtSourceCmd =
nullptr
;
138
G4UIcommand
* DefineSpherExtSourceCenteredOnAVolumeCmd =
nullptr
;
139
G4UIcmdWithAString
* DefineExtSourceOnAVolumeExtSurfaceCmd =
nullptr
;
140
G4UIcmdWithADoubleAndUnit
* setExtSourceEMaxCmd =
nullptr
;
141
142
G4UIcommand
* DefineSpherAdjSourceCmd =
nullptr
;
143
G4UIcommand
* DefineSpherAdjSourceCenteredOnAVolumeCmd =
nullptr
;
144
G4UIcmdWithAString
* DefineAdjSourceOnAVolumeExtSurfaceCmd =
nullptr
;
145
146
G4UIcmdWithADoubleAndUnit
* setAdjSourceEminCmd =
nullptr
;
147
G4UIcmdWithADoubleAndUnit
* setAdjSourceEmaxCmd =
nullptr
;
148
149
G4UIcmdWithAString
* ConsiderParticleAsPrimaryCmd =
nullptr
;
150
G4UIcmdWithAString
* NeglectParticleAsPrimaryCmd =
nullptr
;
151
152
G4UIcmdWithAnInteger
* setNbOfPrimaryFwdGammasPerEventCmd =
nullptr
;
153
G4UIcmdWithAnInteger
* setNbOfPrimaryAdjGammasPerEventCmd =
nullptr
;
154
G4UIcmdWithAnInteger
* setNbOfPrimaryAdjElectronsPerEventCmd =
nullptr
;
155
};
156
157
#endif
G4UImessenger.hh
G4AdjointSimManager
Definition
G4AdjointSimManager.hh:163
G4AdjointSimMessenger
Definition
G4AdjointSimMessenger.hh:124
G4AdjointSimMessenger::~G4AdjointSimMessenger
~G4AdjointSimMessenger() override
Definition
G4AdjointSimMessenger.cc:193
G4AdjointSimMessenger::SetNewValue
void SetNewValue(G4UIcommand *, G4String) override
Definition
G4AdjointSimMessenger.cc:215
G4AdjointSimMessenger::G4AdjointSimMessenger
G4AdjointSimMessenger(G4AdjointSimManager *)
Definition
G4AdjointSimMessenger.cc:54
G4String
Definition
G4String.hh:62
G4UIcmdWith3VectorAndUnit
Definition
G4UIcmdWith3VectorAndUnit.hh:43
G4UIcmdWithABool
Definition
G4UIcmdWithABool.hh:46
G4UIcmdWithADoubleAndUnit
Definition
G4UIcmdWithADoubleAndUnit.hh:42
G4UIcmdWithADouble
Definition
G4UIcmdWithADouble.hh:42
G4UIcmdWithAString
Definition
G4UIcmdWithAString.hh:43
G4UIcmdWithAnInteger
Definition
G4UIcmdWithAnInteger.hh:42
G4UIcmdWithoutParameter
Definition
G4UIcmdWithoutParameter.hh:42
G4UIcommand
Definition
G4UIcommand.hh:52
G4UIdirectory
Definition
G4UIdirectory.hh:42
G4UImessenger
Definition
G4UImessenger.hh:47
globals.hh
geant4-v11.2.2
source
run
include
private
G4AdjointSimMessenger.hh
Generated by
1.12.0