1 | |
---|
2 | LXe Example |
---|
3 | ----------- |
---|
4 | |
---|
5 | ************** |
---|
6 | *Classes Used* |
---|
7 | ************** |
---|
8 | |
---|
9 | main() |
---|
10 | ------ |
---|
11 | |
---|
12 | ==> Use G4UItcsh if available |
---|
13 | |
---|
14 | ==> Provide interactive and macro mode |
---|
15 | |
---|
16 | G4VModularPhysicsList |
---|
17 | ------------------ |
---|
18 | (class: LXePhysicsList) |
---|
19 | |
---|
20 | ==> Registers General, EM, Muon, and Optical physics lists |
---|
21 | |
---|
22 | ==> define particles; including *** G4OpticalPhoton *** |
---|
23 | define processes; including *** G4Cerenkov *** |
---|
24 | *** G4Scintillation *** |
---|
25 | *** G4OpAbsorption *** |
---|
26 | *** G4OpRayleigh *** |
---|
27 | *** G4OpBoundaryProcess *** |
---|
28 | *** G4OpWLS *** |
---|
29 | |
---|
30 | G4VUserDetectorConstruction |
---|
31 | --------------------------- |
---|
32 | (class: LXeDetectorConstruction) |
---|
33 | |
---|
34 | ==> define material: LXe (liquid xenon), Aluminum, Air, Vacuum, Glass,... |
---|
35 | define G4Box geometry with aluminum housing and LXe volume inside |
---|
36 | define G4Tubs placed around the housing walls |
---|
37 | define G4Sphere to demonstrate skin surfaces inside volumes |
---|
38 | *** add G4MaterialPropertiesTable to G4Material *** |
---|
39 | *** define G4OpticalSurface(s) *** |
---|
40 | *** define G4LogicalBorderSurface(s) *** |
---|
41 | *** define G4LogicalSkinSurface(s) *** |
---|
42 | *** add G4MaterialPropertiesTable to G4OpticalSurface(s)*** |
---|
43 | |
---|
44 | ==> Mesenger to change many of the dectector geometry properties |
---|
45 | |
---|
46 | ==> Uses a alternative style of geometry definition. See "Geometry" section. |
---|
47 | |
---|
48 | G4VUserPrimaryGeneratorAction |
---|
49 | ----------------------------- |
---|
50 | (class: LXePrimaryGeneratorAction) |
---|
51 | |
---|
52 | ==> Use G4ParticleGun to shoot a 511 keV gamma through the housing into |
---|
53 | liquid xenon scintillator |
---|
54 | |
---|
55 | G4UserStackingAction |
---|
56 | -------------------- |
---|
57 | (class: LXeStackingAction) |
---|
58 | |
---|
59 | ==> show how to count the number of secondary particles in an event |
---|
60 | differentiates between different creator processes |
---|
61 | |
---|
62 | G4UserRunAction |
---|
63 | --------------- |
---|
64 | (class: LXeRunAction) |
---|
65 | |
---|
66 | ==> Call recorder class for begin and end of run |
---|
67 | |
---|
68 | G4UserSteppingAction |
---|
69 | -------------------- |
---|
70 | (class: LXeSteppingAction) |
---|
71 | |
---|
72 | ==> Identify which secondaries were generated during a particular step |
---|
73 | |
---|
74 | ==> ***Count reflections/absorptions/detections due to G4OpBoundaryProcess*** |
---|
75 | ***Count absorptions due to G4OpAbsorption *** |
---|
76 | Manually trigger a sensitive detector when a boundary process detects |
---|
77 | |
---|
78 | ==> Call recorder class at end of step |
---|
79 | |
---|
80 | G4UserTrackingAction |
---|
81 | ____________________ |
---|
82 | (class: LXeTrackingAction) |
---|
83 | |
---|
84 | ==> Determine if the trajectory should be drawn by checking if it hit the |
---|
85 | sphere(if enabled) and a pmt. |
---|
86 | |
---|
87 | ==> Call recorder class at end of track |
---|
88 | |
---|
89 | G4UserEventAction |
---|
90 | ----------------- |
---|
91 | (class: LXeEventAction) |
---|
92 | |
---|
93 | ==> Triggers drawing of trajectories |
---|
94 | |
---|
95 | ==> Calculates and stores data in a G4VUserEventInformation object |
---|
96 | |
---|
97 | ==> Outputs basic event data at end of event |
---|
98 | |
---|
99 | ==> Decides if the random seed should be saved for this event |
---|
100 | |
---|
101 | ==> Call recorder class at begin and end of event |
---|
102 | |
---|
103 | G4VSensitiveDetector |
---|
104 | -------------------- |
---|
105 | (classes: LXePMTSD, LXeScintSD) |
---|
106 | |
---|
107 | ==> Basic sensitive detectors keeping hit collections |
---|
108 | Keep one G4VHit object per hit |
---|
109 | or |
---|
110 | Keep one G4VHit object per volume containing hits |
---|
111 | |
---|
112 | ==> LXePMTSD decides if the hits it is creating should be redrawn |
---|
113 | |
---|
114 | G4VHit |
---|
115 | ------ |
---|
116 | (classes: LXePMTHit, LXeScintHIT) |
---|
117 | |
---|
118 | ==> Store individual hit positions |
---|
119 | or |
---|
120 | Store a count of hits in a particular volume |
---|
121 | |
---|
122 | ==> Selectively redraw volumes containing hits at the end of event |
---|
123 | |
---|
124 | G4VUserEventInformation & G4VUserTrackInformation |
---|
125 | ------------------------------------------------- |
---|
126 | (classes: LXeUserEventInformation, LXeUserTrackInformation) |
---|
127 | |
---|
128 | ==> Store aditional information along with the G4Event/G4Track objects |
---|
129 | |
---|
130 | G4VSteppingVerbose |
---|
131 | ------------------ |
---|
132 | (classes: LXeSteppingVerbose) |
---|
133 | |
---|
134 | ==> Custom verbose stepping output to use G4BestUnit and print current volume |
---|
135 | rather than next volume |
---|
136 | ==> Same as ExN03SteppingVerbose but output reformated to fit nicer into |
---|
137 | tables. |
---|
138 | |
---|
139 | G4UImessenger |
---|
140 | ------------- |
---|
141 | (classes: LXeDetectorMessenger, LXeEventMessenger, LXeSteppingMessenger) |
---|
142 | |
---|
143 | ==> Create /LXe and /LXe/detector interactive command folders |
---|
144 | |
---|
145 | ==> Create new commands |
---|
146 | |
---|
147 | ==> See interactive help when running the example for descriptions of commands |
---|
148 | |
---|
149 | G4Trajectory |
---|
150 | ------------ |
---|
151 | (class: LXeTrajectory) |
---|
152 | |
---|
153 | ==> Derived from G4Trajectory to use most of the basic trajectory functions |
---|
154 | already defined |
---|
155 | |
---|
156 | ==> Uses a coppied and modified version of DrawTrajectory from G4VTrajectory |
---|
157 | to enable/disable drawing of individual trajectories and to redefine |
---|
158 | the colours used |
---|
159 | |
---|
160 | G4VisManager |
---|
161 | ------------ |
---|
162 | (class: LXeVisManager) |
---|
163 | |
---|
164 | ==> Initialize graphics systems geant4 is configured for |
---|
165 | |
---|
166 | RecorderBase |
---|
167 | ------------ |
---|
168 | |
---|
169 | ==> Virtual class provided for recording of simulation data |
---|
170 | |
---|
171 | ==> Derive your own implementation from it and instantiate the recorder |
---|
172 | object in main() |
---|
173 | |
---|
174 | ==> For full description see RecorderBase.hh |
---|
175 | |
---|
176 | ********** |
---|
177 | *Geometry* |
---|
178 | ********** |
---|
179 | The way the geometry is constructed is an experiment for a new, more object |
---|
180 | oriented, way to construct geometry. It seperates the concept of how a volume |
---|
181 | is built from where it is placed. Each major volume in the geometry is defined |
---|
182 | as a class derived from G4PVPlacement. In this example, just the main LXe |
---|
183 | volume, the WLS scintillator slab, and the WLS fibers were chosen. To place |
---|
184 | one of these volumes, simply create an instance of it with the appropriate |
---|
185 | rotation, translation, and mother volumes. |
---|
186 | |
---|
187 | ------- |
---|
188 | LXeMainVolume(G4RotationMatrix *pRot, |
---|
189 | const G4ThreeVector &tlate, |
---|
190 | G4LogicalVolume *pMotherLogical, |
---|
191 | G4bool pMany, |
---|
192 | G4int pCopyNo, |
---|
193 | LXeDetectorConstruction* c); |
---|
194 | ------- |
---|
195 | |
---|
196 | Also necessary are the pMany and pCopyNo variables with the same usage as in |
---|
197 | G4PVPlacement. Additionally, the detector construction must be passed to the |
---|
198 | main volume as a way to communicate the many parameters to the volume and its |
---|
199 | sub-volumes. The communication is done from the CopyValues() function which |
---|
200 | retrieves the information from the detector constructor. |
---|
201 | |
---|
202 | Notably, the name and logical volume parameters are no longer part of the |
---|
203 | constructor. This is because they are both to be decided by the volume itself. |
---|
204 | The volume must specify its own name and a temporary logical volume. The |
---|
205 | constructor will then procede to define its logical volume in the normal way. |
---|
206 | Once complete, the logical volume can be assigned to the physical volume using |
---|
207 | the SetLogicalVolume() function. |
---|
208 | |
---|
209 | To handle instances of the same type of volume, a new logical volume should not |
---|
210 | be defined for each one. Instead, the logical volume is kept as a static member |
---|
211 | and defined only once. |
---|
212 | |
---|
213 | ------ |
---|
214 | if(!housing_log || updated){ |
---|
215 | //... |
---|
216 | //Define logical volume |
---|
217 | //... |
---|
218 | } |
---|
219 | SetLogicalVolume(housing_log); |
---|
220 | ------ |
---|
221 | |
---|
222 | The updated variable is to signal that the volume needs to be updated and a new |
---|
223 | logical volume made. |
---|
224 | |
---|
225 | *********************************** |
---|
226 | *Modifying the geometry at runtime* |
---|
227 | *********************************** |
---|
228 | This example allows the user to modify the geometry definition at runtime. This |
---|
229 | is accomplished through LXeDetecotrMessenger, a derived class of G4UImessenger. |
---|
230 | The commands it adds change variables stored in LXeDetectorConstructor that |
---|
231 | are used when constructing the geometry. After changing these variables |
---|
232 | the /LXe/detector/update command must be issued to reconstruct the geometry |
---|
233 | with the new values. |
---|
234 | |
---|
235 | ------ |
---|
236 | void LXeDetectorConstruction::UpdateGeometry(){ |
---|
237 | // clean-up previous geometry |
---|
238 | G4SolidStore::GetInstance()->Clean(); |
---|
239 | G4LogicalVolumeStore::GetInstance()->Clean(); |
---|
240 | G4PhysicalVolumeStore::GetInstance()->Clean(); |
---|
241 | |
---|
242 | //define new one |
---|
243 | G4RunManager::GetRunManager()->DefineWorldVolume(ConstructDetector()); |
---|
244 | G4RunManager::GetRunManager()->GeometryHasBeenModified(); |
---|
245 | } |
---|
246 | |
---|
247 | ************************ |
---|
248 | *PMT sensitive detector* |
---|
249 | ************************ |
---|
250 | The PMT sensitive detector cannot be triggered like a normal sensitive detector |
---|
251 | because the sensitive volume does not allow photons to pass through it. Rather, |
---|
252 | it detects them in the OpBoundary process based on an efficiency set on the |
---|
253 | skin of the volume. |
---|
254 | |
---|
255 | ------ |
---|
256 | |
---|
257 | G4OpticalSurface* photocath_opsurf= |
---|
258 | new G4OpticalSurface("photocath_opsurf",glisur,polished, |
---|
259 | dielectric_metal); |
---|
260 | G4double photocath_EFF[num]={1.,1.}; |
---|
261 | G4double photocath_REFL[num]={0.,0.}; |
---|
262 | G4MaterialPropertiesTable* photocath_mt = new G4MaterialPropertiesTable(); |
---|
263 | photocath_mt->AddProperty("EFFICIENCY",Ephoton,photocath_EFF,num); |
---|
264 | photocath_mt->AddProperty("REFLECTIVITY",Ephoton,photocath_REFL,num); |
---|
265 | photocath_opsurf->SetMaterialPropertiesTable(photocath_mt); |
---|
266 | new G4LogicalSkinSurface("photocath_surf",photocath_log,photocath_opsurf); |
---|
267 | |
---|
268 | ------ |
---|
269 | |
---|
270 | A normal sensitive detector would have its ProcessHits |
---|
271 | function called for each step by a particle inside the volume. So, to record |
---|
272 | these hits with a sensitive detector we watched the status of the OpBoundary |
---|
273 | process from the stepping manager whenever a photon hit the sensitive volume |
---|
274 | of the pmt. If the status was 'Detection', we retrieve the sensitive detector |
---|
275 | from G4SDManager and call its ProcessHits function. |
---|
276 | |
---|
277 | ------ |
---|
278 | |
---|
279 | boundaryStatus=boundary->GetStatus(); |
---|
280 | //Check to see if the particle was actually at a boundary |
---|
281 | //Otherwise the boundary status may not be valid |
---|
282 | //Prior to Geant4.6.0-p1 this would not have been enough to check |
---|
283 | if(thePostPoint->GetStepStatus()==fGeomBoundary){ |
---|
284 | switch(boundaryStatus){ |
---|
285 | //... |
---|
286 | case Detection: //Note, this assumes that the volume causing detection |
---|
287 | //is the photocathode because it is the only one with |
---|
288 | //non-zero efficiency |
---|
289 | { |
---|
290 | //Trigger sensitive detector manually since photon is |
---|
291 | //absorbed but status was Detection |
---|
292 | G4SDManager* SDman = G4SDManager::GetSDMpointer(); |
---|
293 | G4String sdName="/LXeDet/pmtSD"; |
---|
294 | LXePMTSD* pmtSD = (LXePMTSD*)SDman |
---|
295 | ->FindSensitiveDetector(sdName); |
---|
296 | if(pmtSD) |
---|
297 | pmtSD->ProcessHits_constStep(theStep,NULL); |
---|
298 | break; |
---|
299 | } |
---|
300 | //... |
---|
301 | } |
---|
302 | |
---|
303 | ********************** |
---|
304 | *Modular Physics List* |
---|
305 | ********************** |
---|
306 | Using a modular physics list is an easy way to organize the physics list into |
---|
307 | categories for easier maintenance. It can also assist with testing code |
---|
308 | by making it easy to disable an entire category of physics at once if |
---|
309 | necessary. The physics list instantiated in main() is a derived class of |
---|
310 | G4VModularPhysics list rather than the usual G4VUserPhysicsList. The only |
---|
311 | function aside from the constructor that is necessary in this class is |
---|
312 | SetCuts(). The constructor must register the other physics lists individually. |
---|
313 | |
---|
314 | RegisterPhysics( new LXeGeneralPhysics("general") ); |
---|
315 | |
---|
316 | The other physics lists (the modules) are derived from G4VPhysicsConstructor |
---|
317 | and it is necessary to write the ConstructParticle() and ConstructProcess() |
---|
318 | functions for each list. They work in the same way as in G4VUserPhysicsList. |
---|
319 | |
---|
320 | Do not create instances of the individual physics processes as members of the |
---|
321 | modules. Instead, use pointers to the processes and create the instances |
---|
322 | in the ConstructProcess() function. The reason for this is that the materials |
---|
323 | needed to build physics tables for the processes will not have been created |
---|
324 | at the time that the modules are created but will have been created before the |
---|
325 | ConstructProcess() function is called. |
---|
326 | |
---|
327 | ********************************************************** |
---|
328 | *Selectively drawing trajectories or highlighting volumes* |
---|
329 | ********************************************************** |
---|
330 | In a simulation such as this one, where an average of 6000 trajectories are |
---|
331 | generated in a small space, there is little use in drawing all of them. There |
---|
332 | are two ways to select which ones to draw. The first of which is to decide |
---|
333 | while looping through the trajectory container which ones to draw and only call |
---|
334 | DrawTrajectory on the important ones. However, trajectories only contain a |
---|
335 | small portion of the information from the track it represents. This may not |
---|
336 | be enough to decide if a trajectory is worth drawing. |
---|
337 | |
---|
338 | The alternative is to define your own trajectory class to store additional |
---|
339 | information to help decide if it should be drawn. To use your custom trajectory |
---|
340 | you must create it in the PreUserTrackingAction: |
---|
341 | |
---|
342 | fpTrackingManager->SetTrajectory(new LXeTrajectory(aTrack)); |
---|
343 | |
---|
344 | Then at any point you can get access to the trajectory you can update the extra |
---|
345 | information within it. When it comes to drawing, you can then use this to |
---|
346 | decide if you want to call DrawTrajectory. Or you can call DrawTrajectory for |
---|
347 | all trajectories and have the logic decide how and if a trajectory should |
---|
348 | be drawn inside the DrawTrajectory function itself. |
---|
349 | |
---|
350 | Selectively highlighting volumes is useful to show which volumes were hit. To |
---|
351 | do this, you simply need a pointer to the physical volume. With that, you can |
---|
352 | modify its vis attributes and instruct the vis manager to redraw the volume |
---|
353 | with the new vis attributes. |
---|
354 | |
---|
355 | ------ |
---|
356 | G4VisAttributes attribs(G4Colour(1.,0.,0.)); |
---|
357 | attribs.SetForceSolid(true); |
---|
358 | G4RotationMatrix rot; |
---|
359 | if(physVol->GetRotation())//If a rotation is defined use it |
---|
360 | rot=*(physVol->GetRotation()); |
---|
361 | G4Transform3D trans(rot,physVol->GetTranslation());//Create transform |
---|
362 | pVVisManager->Draw(*physVol,attribs,trans);//Draw it |
---|
363 | ------ |
---|
364 | |
---|
365 | In this case, it is done in Draw function of a PMT hit but it can be placed |
---|
366 | anywhere. The logic to decide if it should be drawn or not may be similar to |
---|
367 | the logic used in choosing which trajectories to draw. |
---|
368 | |
---|
369 | See /LXe/detector/volumes/sphere in "UI commands" below for info on what |
---|
370 | trajectories are drawn in this simulation. |
---|
371 | |
---|
372 | **************************** |
---|
373 | *Saving random engine seeds* |
---|
374 | **************************** |
---|
375 | At times it may be necessary to review a particular event of interest. To do |
---|
376 | this without redoing an entire run, which may take a long time, you must store |
---|
377 | the random engine seed from the beginning of the event. The run manager |
---|
378 | has some functions that help in this task. |
---|
379 | |
---|
380 | G4RunManager::SetRandomNumberStore(G4bool) |
---|
381 | |
---|
382 | When set to true, this causes the run manager to write the seed for the |
---|
383 | beginning of the current run to CurrentRun.rndm and the current event to |
---|
384 | CurrentEvent.rndm. However, at the beginning of each event this file will be |
---|
385 | overwritten with the new event. To keep a copy for a particular event there is |
---|
386 | a function to copy this file to run###evt###.rndm. |
---|
387 | |
---|
388 | G4RunManager::rndmSaveThisEvent() |
---|
389 | |
---|
390 | This can be done for every event so you can review any event you like but this |
---|
391 | may be awkward for runs with very large numbers of events. Instead, implement |
---|
392 | some form of logic in EndOfEventAction to decide if the event is worth saving. |
---|
393 | If it is, then call rndmSaveThisEvent(). By default, these files are stored in |
---|
394 | the current working directory. There is a function to change this as well. |
---|
395 | Typically you would call that at the same time SetRandomNumberStore. The |
---|
396 | directory to save in must exist first. GEANT4 will not create it for you. |
---|
397 | |
---|
398 | G4RunManager::SetRandomNumberStoreDir(G4String) |
---|
399 | |
---|
400 | ************** |
---|
401 | *RecorderBase* |
---|
402 | ************** |
---|
403 | RecorderBase is a virtual class to serve as a template for how to add |
---|
404 | histogram functionality to a GEANT4 application. To use it, derive a |
---|
405 | class from it and instantiate that in main(). Each of your user action classes |
---|
406 | to do any recording must have a pointer to this instance. Then at the end of |
---|
407 | the critical functions in each user action, call the appropriate recorder |
---|
408 | function. The recorder functions and the functions to call them from are listed |
---|
409 | here: |
---|
410 | |
---|
411 | RecordBeginOfRun(const G4Run*) |
---|
412 | -Call from BeginOfRunAction() |
---|
413 | RecordEndOfRun(const G4Run*) |
---|
414 | -Call from EndOfRunAction() |
---|
415 | RecordBeginOfEvent(const G4Event*) |
---|
416 | -Call from BeginOfEventAction() |
---|
417 | RecordEndOfEvent(const G4Event*) |
---|
418 | -Call from EndOfEventAction() |
---|
419 | RecordTrack(const G4Track*) |
---|
420 | -Call from PostUserTrackingAction() |
---|
421 | RecordStep(const G4Step*) |
---|
422 | -Call from UserSteppingAction() |
---|
423 | |
---|
424 | For the reasoning behind why it is done this way see RecorderBase.hh |
---|
425 | |
---|
426 | ************* |
---|
427 | *UI commands* |
---|
428 | ************* |
---|
429 | The method to define UI commands is well documented in the GEANT4 documentation |
---|
430 | so will not be discussed here. This is a description of the commands added to |
---|
431 | this example. |
---|
432 | |
---|
433 | Directories: |
---|
434 | /LXe/ - All custom commands belong below this directory |
---|
435 | /LXe/detector/ - Geometry related commands |
---|
436 | /LXe/detector/volumes/ - Commands to enable/disable volumes in the geometry |
---|
437 | |
---|
438 | Commands: |
---|
439 | /LXe/saveThreshold <int, default = 4500> |
---|
440 | -Specifies a threshold for saving the random seed for an event. If the number |
---|
441 | of photons generated in an event is below this number then the random seed is |
---|
442 | saved to ./random/run###evt###.rndm. See "Saving random engine seeds". |
---|
443 | |
---|
444 | /LXe/eventVerbose <int, default = 1> |
---|
445 | -Enables end of event verbose data to be printed. This includes information |
---|
446 | counted and calculated by the user action classes. |
---|
447 | |
---|
448 | /LXe/pmtThreshold <int, default = 1> |
---|
449 | -Sets the PMT threshold in # of photons being detected by the PMT. PMTs below |
---|
450 | with fewer hits than the threshold will not count as being hit and will also |
---|
451 | not be highlighted at the end of the event. |
---|
452 | |
---|
453 | /LXe/oneStepPrimaries <bool> |
---|
454 | -This causes primary particles to be killed after going only one step inside |
---|
455 | the scintillator volume. This is useful to view the photons generated during |
---|
456 | the initial conversion of the primary particle. |
---|
457 | |
---|
458 | /LXe/forceDrawPhotons <bool> |
---|
459 | -Forces all optical photon trajectories to be drawn at the end of the event |
---|
460 | regardless of the scheme mentioned in /LXe/detector/volumes/sphere below. |
---|
461 | |
---|
462 | /LXe/forceDrawNoPhotons <bool> |
---|
463 | -Forces all optical photon trajectories to NOT be drawn at the end of the |
---|
464 | event regardless of the scheme mentioned in /LXe/detector/volumes/sphere below. |
---|
465 | -If /LXe/forceDrawPhotons is set to true, this has no effect. |
---|
466 | |
---|
467 | /LXe/detector/dimensions <double x y z> <unit, default = cm> |
---|
468 | -Sets the dimensions of the main scintillator volume. |
---|
469 | |
---|
470 | /LXe/detector/housingThickness <double> |
---|
471 | -Sets the thickness of the housing surrounding the main detector volume. |
---|
472 | |
---|
473 | /LXe/detector/pmtRadius <double> <unit, default = cm> |
---|
474 | -Sets the radius of the PMTs |
---|
475 | |
---|
476 | /LXe/detector/nx |
---|
477 | /LXe/detector/ny |
---|
478 | /LXe/detector/nz |
---|
479 | -Sets the number of PMTs placed in a row along each axis. |
---|
480 | |
---|
481 | /LXe/detector/reflectivity <double> |
---|
482 | -Sets the reflectivity of the inside of the aluminum housing. The geometry |
---|
483 | uses a default value of 1.00 for a fully reflective surface. |
---|
484 | |
---|
485 | /LXe/detector/nfibers <int> |
---|
486 | -Sets the number of WLS fibers placed in the WLS scintillator slab. The |
---|
487 | geometry uses a default value of 15 fibers. |
---|
488 | |
---|
489 | /LXe/detector/scintYieldFactor <double> |
---|
490 | -Sets the yield factor for the scintillation process. This is cumulative with |
---|
491 | the yield factor set on individual materials. Set to 0 to produce no |
---|
492 | scintillation photons. |
---|
493 | |
---|
494 | /LXe/detector/update |
---|
495 | -Builds the new geometry based on any parameters that have been updated with |
---|
496 | the other UI commands. ***This must be called for the changes to take effect*** |
---|
497 | |
---|
498 | /LXe/detector/defaults |
---|
499 | -Resets all detector values customizable with commands above to their defaults. |
---|
500 | |
---|
501 | /LXe/detector/volumes/sphere <bool> |
---|
502 | -Enables/disables the sphere placed inside the main scintillator volume. When |
---|
503 | the sphere is enabled, only photons that hit the sphere and hit a PMT are |
---|
504 | drawn. If it is disabled, then all photons that hit PMTs are drawn. |
---|
505 | |
---|
506 | /LXe/detector/volumes/wls <bool> |
---|
507 | -Enables/disables the WLS scintillator slab containing WLS fibers. By default |
---|
508 | this is not part of the geometry. Enabling it will place it behind the LXe |
---|
509 | scintillator volume. |
---|
510 | |
---|
511 | /LXe/detector/volumes/lxe <bool> |
---|
512 | -Enables/disables the main LXe scintillator volume. By default this is part of |
---|
513 | the geometry. |
---|
514 | |
---|
515 | ************* |
---|
516 | *Macro files* |
---|
517 | ************* |
---|
518 | The following are the macro files included in this example and what they do. |
---|
519 | |
---|
520 | LXe.in |
---|
521 | -This produces a standard event with a 511 keV gamma fired into the LXe volume. |
---|
522 | All values are left at their default states but verbose output has been |
---|
523 | enabled. |
---|
524 | |
---|
525 | cerenkov.mac |
---|
526 | -This is to demonstrate the cerenkov process. It disables the scintillation |
---|
527 | process and uses a 200MeV mu+ to produce cerenkov photons. The volume has |
---|
528 | been resized and the number of pmts has been increased to more accurately |
---|
529 | show the cone. OneStepPrimaries has been enabled so that the cone does not fill |
---|
530 | itself in as the muon slows down. |
---|
531 | |
---|
532 | wls.mac |
---|
533 | -This disables the main volume and enables the WLS slab volume. It sets the |
---|
534 | particle gun to use an e- to produce scintillation in the slab which will be |
---|
535 | absorbed by the WLS fibers and re-emited at a different wavelength. |
---|
536 | |
---|
537 | vis.mac |
---|
538 | -This is a standard vis.mac file to tell the vis manager how to visualize the |
---|
539 | simulation. |
---|
540 | |
---|
541 | photon.mac |
---|
542 | -A very simple test in which the gun is set to produce a single photon inside |
---|
543 | the main scintillator volume. |
---|
544 | |
---|
545 | reviewEvent.mac |
---|
546 | -This is to review an event by loading in a random seed and running the event |
---|
547 | with verbose output. Modify the file to specify the filename of the random |
---|
548 | seed. |
---|
549 | |
---|
550 | defaults.mac |
---|
551 | -This resets all values that can be changed with the /LXe/ commands back to |
---|
552 | their initial configuration including those that are not reset with |
---|
553 | /LXe/detector/defaults |
---|