2 -----------------------------------------------------------------
4 Geant4 related files in AliRoot:
5 ================================
6 AliRoot/TGeant4 - source of TGeant4 category
7 AliRoot/AliGeant4 - source of AliGeant4 category
9 AliRoot/AliGeant4/config:
10 configuration scripts:
12 script for generating HTML documentation:
13 doc_XXc++2html.pl, doc_XXddl2html.pl, doc_XXsorthtml.pl,
14 doc_XXcategory.pl where XX = al, g4
15 scripts and template files for automatic generation of G4 test
17 test_create.sh, test_create_in.sh, test_create_struct.sh,
18 test_run.sh, test_run_in.sh, test_run_struct.sh,
19 test_default_det_novis.in, test_default_det_vis.in
20 test_default_genN.in; N = 0,1,2,3
21 test_default_visN.in; N = 1
22 script for generation source directories with files
23 sorted in subdirectories corresponding to subcategories:
26 AliRoot/AliGeant4/doc:
28 README.CodingConvention;
29 CodePrototype.html, G4CodePrototype.html - main code html pages
30 (they are not produced automatically)
31 HTML directory is created here by doc_alc++2html.sh script;
32 HTML documentation of Geant4 can be created by doc_g4c++2html.pl
34 AliRoot/AliGeant4/macro:
35 Detector specific root and G4 macros (in detector subdirectories);
36 Examples of G4 macros:
39 g4libs.C - Root macro for loading G4 and AliRoot libraries
40 g4menu.C - primitive GUI for instantiating TGeant4 and
42 g4Config.C - alternative of Config.C for G4
45 Alice Geant4 related environment variables:
46 ==========================================
47 (used when code is compiled; see config/setup.sh)
50 the path to AliRoot/AliGeant4;
54 if set: the provided Geant4 version and not the default one is set
58 if set: the program is compiled with visualisation (default)
60 geometry, main, visualization
64 if set: the program is compiled with OPACS visualisation
66 geometry, main, visualization
70 if set: the secondary particles are not tracked immediatelly
71 when they are created but after the urgent stack is exhausted
72 if not set: the G4 default stacking is used
73 Categories affected: event
77 if set: only geantino or charged geantino can be shooted
78 Categories affected: main
82 if set: checks for existence fStep, fTrack are performed in TG4StepManager
83 Categories affected: event
89 Can be set running the setup.sh script:
91 . $ALICE_ROOT/AliGeant4/config/setup.sh for zsh users
92 source $ALICE_ROOT/AliGeant4/config/setup.csh for tcsh users
94 The setup script can be added into a user login script:
97 # can be added to .zshenv
98 # Alice and Geant4 default settings
99 . $ALICE_ROOT/AliGeant4/config/setup.sh
101 for tcsh users (not available yet)
102 # can be added to .login
103 # Alice and Geant4 default settings
104 source $ALICE_ROOT/AliGeant4/config/setup.csh
106 Supported systems: HP-aCC, Linux-g++.
118 - perl script using Pavel Binko's ddl2html perl script
119 (http://wwwinfo.cern.ch/~binko/Ddl2Html/Ddl2Html.code)
120 for automatic generating of code documentation in html;
121 creates doc/HTML directory containing *.html files for all
122 *.hh, *.ddl, *.cc, alice.mk, GNUmakefile*, alice_*.(c)sh
123 and *.html index pages according to class categories
124 - calls: doc_alddl2html.pl: modified ddl2html
125 doc_alsorthtml.pl: generates html pages for class
127 - the main page AG4CodePrototype.html with links to category index
128 pages and the alphabetical index page was created manually
132 (in $ALICE_ROOT/bin/tgt_SYSTEM/)
133 aliroot - standard aliroot main;
134 not linked with G4 libs, starts in Root UI;
135 !! cannot be used with all G4 GUIs
136 aligeant4 - main linked with G4 libs, starts in G4 UI
150 terminal is used for typing commands;
151 if Xm is specified Motif Window is open for typing
153 !! when simple terminal used with Xo driver it may
154 freeze the whole X server
155 -> use A. instead of this possibility
158 java GAG GUI is activated;
159 select: GEANT4 -> Execute GEANT4
160 and select aligeant4 executable in file browser
162 Tcl/Tk Momo and GAG GUI is activated;
163 select GAG -> Function -> Run GEANT4
164 and select aligean4 executable in file browser
166 OPACS GUI is activated
170 Use aliroot for running in batch mode with Root macros
171 (*.C) and aligeant4 with G4 macros (*.in):
176 G4 macro "macro.in" can be called from Root macro:
178 (TGeant4*)gMC->ProcessGeantMacro("macro.in");
180 Root macro "macro.C" can be called from G4 macro:
182 /g4mc/rootMacro macro
185 Several examples of Geant4 macros for running aligeant4 in a batch mode
186 are available in $ALICE_ROOT/macro:
188 alirun0.in - the simple macro how to run with default setup
190 alirun1.in - example of interactive particle gun usage and
191 drawing trajectories;
192 alirun2.in - example of special lego run with calling
193 Root macro lego.C from g4 and switching to root UI
196 Alice Geant4 Commands:
197 =======================
201 /aliDet/switchOn modNameVer
205 NONE no modules are selected (default)
206 ALL all available modules (default versions) are selected
207 DDD[n] AliRoot module DDD of n-th version is selected;
208 if n is not specified the default version is selected
209 !! work only during preinit phase;
211 /aliDet/switchOff whichVolume
215 !! work only during preinit phase;
218 list of all modules currently switched on
220 /aliDet/listAvailable
221 list of all available modules
223 /aliDet/fieldValue value
224 define magnetic field in Z direction
226 /aliDet/setAllSensitive bool
227 if true: all logical volumes are associated with sensitive
229 if false: only volumes defined with asensitive tracking
230 medium are associated with sensitive detectors
231 It has lower priority than individual module setting
233 /aliDet/forceAllSensitive
234 If true: force to set all logical volumes sensitive.
235 (Each logical is volume associated with a sensitive
237 It has higher priority than individual module setting
239 /aliDet/writeGeometry true
240 generate g3calls.dat for all built AliRoot detectors
242 /aliDet/readGeometry true
243 build AliRoot detectors from g3calls.dat instead of
244 processing AliModule->CreateGeometry()
246 /aliDet/printMaterials
250 generate geometry XML file
252 Sub-directories /aliDet/XXX/ commands :
253 setFrame * Set detector frame
254 list * List all logical volumes of body detector
255 listLong * List all logical volumes and number of its physical
256 volumes (daughters) that are placed in this LV
257 listDaughters * List daughters of the given logical volumes
258 listLongDaughters * List daughters of the given logical volumes
259 setVolume * Set the current logical volume.
260 setVisibility * Make body detector visible/invisible.
261 setLVTreeVisibility * Make current volume tree visible/invisible.
262 setVolVisibility * Make current volume visible/invisible.
263 setColour * Set colour for all body detector volumes.
264 setLVTreeColour * Set colour for the current volume tree.
265 setVolColour * Set colour for the current volume.
266 setAllSensitive * If true: set all module's logical volumes sensitive.
269 set primary generator action
270 /aliGenerator/set generatorName
272 Gun -> particle gun (default)
273 Geantino -> geantino with random momentum (default);
274 GhargedGeantino -> charged geantino with random momentum;
275 AliGenerator -> generator from AliRoot defined either in
276 Config.C or interactively in Root shell
277 /aliGenerator/nofParticles number
279 Comment: does not set nof particles for AliGenerator
280 ( it has to be set by Aligenerator set method)
281 /aliGenerator/verbose verboseLevel
282 verboseLevel: 0, 1, 2
286 build a gun of particles with given properties
288 /aliGun/listAvailable
289 list of available particles
291 list of the properties of the current gun particle, that
292 can be add to the gun using addGun command
294 set the current particle definition
296 set the current particle momentum
298 set the current particle position
300 set the current particle initial time
302 set the current particle polarization
304 set the current particle momentum direction
306 set the current particle kinetic energy
308 list of all particles in the Alice gun
310 add the current particle to the gun
311 /aliGun/removeParticle i
312 remove the i-th particle from the gun
314 remove all the particles from the gun
317 /aliEvent/drawTracks drawFlag
318 drawFlag: ALL tracks for all particles are drawn
319 CHARGED tracks for charged particles only are drawn
320 NONE no tracks are drawn
321 default value: CHARGED
322 /aliEvent/verbose verboseLevel
323 verboseLevel: 0 no hits information is printed
324 1 number of hits for hits collections stored per event
326 2 full hits information for hits collections stored
331 /aliTracking/verbose verboseLevel
332 verboseLevel: 0 no information from AlTrackingAction is printed
333 1 each 100th primary track id is printed
334 2 each primary track id is printed
336 /aliTracking/loopVerbose loopVerboseLevel
337 set tracking verbose level for detected looping tracks
338 loopVerboseLevel: see /tracking/verbose
342 /aliRunAction/verbose verboseLevel
343 verboseLevel: 0 - 2 no influence on output yet
346 redefinition of /run commands for AliRoot:
347 !! /aliRun commands has to be used instead of /run commands
348 in order to perform AliRun actions, too
350 /aliRun/beamOn nofEvent
352 special lego run from AliRoot
353 (with default lego parameters)
355 set configuration macro name (default Config)
359 setOptical * Set Cerenkov and optical processes.
360 setHadron * Set hadron processes.
361 setSpecialCuts * Set special cuts process.
362 setSpecialFlags * Set special flags process.
363 root * Switch to Root interactive shell.
364 rootMacro * Process Root macro with given name (from file name.C)
365 rootCmd * Process Root command
366 g3Defaults * Set G3 default parameters (cut values, tracking media max
368 setProcessActivation * Activate/inactivate physics processes
369 (for development tests only)