Message: Bug in scorer? Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

None Bug in scorer? 

Forum: Hits, Digitization and Pileup
Date: 30 Jul, 2008
From: Martin Cawley <Martin Cawley>

Using Geant4.9.1.p02 on fedora 8

While trying to get the meshBox scorer to work I have found a couple of problems:-

*	digits_hits/utils/src/G4ScoringBox.cc
Class G4ScoringBox::SetupGeometry()
 		The last argument in the call to G4PVDivision( .... , 
fSize[0]/fSegment[0]*2.) is the width of the mesh box (as in the call to
G4PVReplica) and should be 0.0, the offset of the mesh. This is the same for
all the calls to G4PVDivision in this file. The result is that an extra box
is added to the mesh in one direction which can be easily verified by creating
a meshBox of 2x2x2. The resulting box is 2x2x3.
 		I use Inventor (OIX) for the visualisation and the meshBox
can be seen and verified in it.

*	digits_hits/utils/src/G4VScoreWriter.cc
Class G4VScoreWriter::GetIndex()
 		This took a while to figure out but the index
x + y*fNMeshSegments[0] + z*fNMeshSegments[0] *fNMeshSegments[1] is constructed
differently to where the data is stored in each of files digits_hits/scorer/src/
4PS*3D.cc where the index is contructed as i*fNj*fNk+j*fNk+k. I suggest that
the index in the writer should be
z + y*fNMeshSegments[2] + x*fNMeshSegments [1]*fNMeshSegments[2].
 		After changing it I can now read in (using imagej) the
flux, energy, etc as a 3D image and they make a lot more sense.

I hope this makes sense and is helpful. I have noticed that the beta version 4.9.2 contains the same code.

 Add Message Add Message
to: "Bug in scorer?"

 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 ]