Message: rdecay02 - visualization changes the emission spectrum (histogram h16) Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

Question rdecay02 - visualization changes the emission spectrum (histogram h16) 

Forum: Documentation and Examples
Date: 20 Mar, 2015
From: Norbert Wiehl <Norbert Wiehl>

G4 version 4.10.00

As a Geant4 beginner I used example rdecay02 as starting point for a detector simulation with one-iso.mac and Co-60 as the one source

My problem: As long as I don't use any visualization everything is fine. When I run the same program with visualization (see below for the details) the 2 well known gamma lines of Co60 (1173 keV and 1332 keV) disappear from histogram h16. The remaining spectrum looks very strange (see attached spectra one-iso.gif and one-iso_vis.gif).

I would be deeply gratefull for any help Norbert

Here the details:

To see my detector geometry I add these lines to the main program rdecay02.cc

...
  if (argc == 1)   // Define UI session for interactive mode.
    {
#ifdef G4UI_USE
      G4UIExecutive* ui = new G4UIExecutive(argc, argv);

# --> begin of added lines

#ifdef G4VIS_USE
    UImanager->ApplyCommand("/control/execute init_vis.mac"); 
#endif
# --> end of addes lines

      ui->SessionStart();
      delete ui;
#endif
...

File init_vis.mac (comes from example B1)

# Macro file for the initialization phase of example B1
# when running in interactive mode with visualization
#
# Set some default verbose
#
/control/verbose 2 /control/saveHistory /run/verbose 2
#
# Visualization setting
/control/execute one-iso_vis.mac

File one-iso_vis.mac is the original except the /vis/ commands

##############################################################################
#                                                                         #
################################################################################
#
#/exrdm/phys/SelectPhysics LowEnergy_EM
/run/initialize /run/setCutForRegion Target 10 cm /run/setCutForRegion Detector 10 cm /run/verbose 0 /event/verbose 0
#/tracking/verbose 1
#/particle/select GenericIon
#/particle/property/verbose 1 
/grdm/BRbias 0 /grdm/fBeta 0 #/grdm/verbose 5 /grdm/analogueMC 1

#
#Next lines needed to have  atomic relaxation working 
#
/process/em/fluo true /process/em/auger true # /vis/open OGL 600x600-0+0 /vis/drawVolume
#/vis/viewer/set/viewpointVector 1 0 0
#/vis/viewer/set/lightsVector 1 0 0
#/vis/geometry/set/visibility World 0 false
#/vis/geometry/set/colour Target 0 1 1 1
#/vis/geometry/set/colour Detector 0 0 1 0 1.0
/vis/viewer/set/style surface /vis/viewer/set/viewpointThetaPhi -30 0 /vis/scene/add/axes 0 0 0 5 cm /vis/scene/add/trajectories smooth /vis/modeling/trajectories/create/drawByCharge /vis/modeling/trajectories/drawByCharge-0/default/setDrawStepPts true /vis/modeling/trajectories/drawByCharge-0/default/setStepPtsSize 2
#/vis/filtering/trajectories/create/particleFilter
#/vis/filtering/trajectories/particleFilter-0/add e-
# To superimpose all of the events from a given run:
/vis/scene/endOfEventAction accumulate 100
#
# Re-establish auto refreshing and verbosity:
/vis/viewer/set/autoRefresh true /vis/verbose warnings # /histo/fileName co60 # /gps/position 0 0 0 /gps/energy 2. eV
#/gps/particle proton
#/gps/ion 76 187 0 257.17
#/gps/ion 11 24 0 472
#/gps/ion 81 207 0 1348.2
#/gps/ion 82 201 0 628.9
#/gps/ion  45 105 0 129.6
#/gps/ion  44 105 0 0
#  Tc101[207.7]
#/gps/ion 42 101
#/gps/ion 67 162
#/gps/ion 83 214
#/gps/ion 26 59  
/gps/ion 27 60

#/run/beamOn 100000
#

   Attachment:
      http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2015/03/20/05.55-28892-one-iso.gif
      http://hypernews.slac.stanford.edu/HyperNews/geant4/get/AUX/2015/03/20/05.55-13357-one-iso_vis.gif

Inline Depth:
 1 1
 All All
Outline Depth:
 1 1
 2 2
 All All
Add message: (add)

1 None: Re: rdecay02 - visualization changes the emission spectrum (histogram h16)   (Ivana Hrivnacova - 21 Aug, 2015)
(_ Feedback: Re: rdecay02 - visualization changes the emission spectrum (histogram h16)   (Norbert Wiehl - 03 Sep, 2015)
(_ None: Re: rdecay02 - visualization changes the emission spectrum (histogram h16)   (Ivana Hrivnacova - 03 Sep, 2015)
 Add Message Add Message
to: "rdecay02 - visualization changes the emission spectrum (histogram h16)"

 Subscribe Subscribe

This site runs SLAC HyperNews version 1.11-slac-98, derived from the original HyperNews


[ Geant 4 Home | Geant 4 HyperNews | Search | Request New Forum | Feedback ]