[gate-users] Hemisphere geometry assignment

Angela M K Foudray afoudray at stanford.edu
Tue Jul 20 06:55:40 CEST 2004


I am trying to get hemispherical phantoms and sources to work.  When I
define a half sphere:

/gate/world/daughters/name hemisphere
/gate/world/daughters/insert sphere
/gate/hemisphere/setMaterial Water
/gate/hemisphere/vis/setColor grey
/gate/hemisphere/geometry/setRmax   7.8 cm
/gate/hemisphere/geometry/setRmin   0.0 cm
/gate/hemisphere/geometry/setThetaStart 0.0 rad
/gate/hemisphere/geometry/setDeltaTheta 1.5708 rad

and try to move its position with the
/gate/hemisphere/placement/setTranslation 0.0 0.0 -3.9 cm

(which looks fine in the OpenGL representation of the phantom), I get
the following error:


 *** Break *** segmentation violation
 Generating stack trace...
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
 0x414e1658 in <unknown> from /lib/libc.so.6
 0x081ce8f6 in GateAnalysis::RecordEndOfEvent(G4Event const*) + 0x954
from Gate
 0x08185266 in GateOutputMgr::RecordEndOfEvent(G4Event const*) + 0x7a
from Gate
 0x0817c651 in GateEventAction::EndOfEventAction(G4Event const*) + 0x163
from Gate
 0x08608396 in G4EventManager::ProcessOneEvent(G4Event*) + 0x738 from
Gate
 0x085a4130 in G4RunManager::DoEventLoop(int, char const*, int) + 0xfe
from Gate
 0x085a3b0d in G4RunManager::BeamOn(int, char const*, int) + 0x47 from
Gate
 0x0816cd39 in GateApplicationMgr::StartDAQ() + 0x1b9 from Gate
 0x0816f3b4 in GateApplicationMgrMessenger::SetNewValue(G4UIcommand*,
G4String) + 0x11e from Gate
 0x087397e1 in G4UIcommand::DoIt(G4String) + 0x11f9 from Gate
 0x08746409 in G4UImanager::ApplyCommand(char const*) + 0x871 from Gate
 0x08745b94 in G4UImanager::ApplyCommand(G4String) + 0x2a from Gate
 0x0832e347 in G4UIterminal::ExecuteCommand(G4String) + 0x53 from Gate
 0x0832dfff in G4UIterminal::SessionStart() + 0x5b from Gate
 0x0816b51d in main + 0x5bb from Gate
 0x414cddc6 in __libc_start_main + 0xc6 from /lib/libc.so.6
 0x0816a941 in TFile::TFile(char const*, char const*, char const*, int)
+ 0x5d from Gate
Abort



So I broke down and moved the detector instead - no problems then... 
until I tried to make a source (background throughout the volume of the
phantom) in the same location (which by the way you cannot verify
visually - why can't we visualize sources?!) with the following
commands:
/gate/source/addSource F18LineSource0
/gate/source/F18LineSource0/setActivity 0.0001 Ci

/gate/source/F18LineSource0/gps/particle e+
/gate/source/F18LineSource0/setForcedUnstableFlag true
/gate/source/F18LineSource0/setForcedHalfLife 6586.2 s
/gate/source/F18LineSource0/gps/energytype Fluor18
/gate/source/F18LineSource0/gps/type Volume
/gate/source/F18LineSource0/gps/shape Sphere
/gate/source/F18LineSource0/gps/mintheta 0 deg
/gate/source/F18LineSource0/gps/maxtheta 90 deg
/gate/source/F18LineSource0/gps/radius 7.0 cm
/gate/source/F18LineSource0/gps/angtype iso
/gate/source/F18LineSource0/gps/centre 0.0 0.0 0.0 cm
/gate/source/F18LineSource0/gps/confine NULL

I get the error that there are free positrons (i.e. my source is not
within my phantom).  Okay, maybe there's a problem with the geometry -
maybe "/gate/source/F18LineSource0/gps/centre 0.0 0.0 0.0 cm" means the
center of the hemisphere - not the whole sphere, so I need to translate
it.  I translate it 3.9 cm with:
/gate/source/F18LineSource0/gps/centre 0.0 0.0 3.9 cm
(as I have translated my detector) and get seemingly the same huge crash
error:

 *** Break *** segmentation violation
 Generating stack trace...
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
/usr/bin/addr2line: Gate: No such file or directory
 0x414e1658 in <unknown> from /lib/libc.so.6
 0x08290b67 in GateTrajectoryNavigator::FindAnnihilationGammasTrackID()
+ 0x657 from Gate
 0x081ce19f in GateAnalysis::RecordEndOfEvent(G4Event const*) + 0x1fd
from Gate
 0x08185266 in GateOutputMgr::RecordEndOfEvent(G4Event const*) + 0x7a
from Gate
 0x0817c651 in GateEventAction::EndOfEventAction(G4Event const*) + 0x163
from Gate
 0x08608396 in G4EventManager::ProcessOneEvent(G4Event*) + 0x738 from
Gate
 0x085a4130 in G4RunManager::DoEventLoop(int, char const*, int) + 0xfe
from Gate
 0x085a3b0d in G4RunManager::BeamOn(int, char const*, int) + 0x47 from
Gate
 0x0816cd39 in GateApplicationMgr::StartDAQ() + 0x1b9 from Gate
 0x0816f3b4 in GateApplicationMgrMessenger::SetNewValue(G4UIcommand*,
G4String) + 0x11e from Gate
 0x087397e1 in G4UIcommand::DoIt(G4String) + 0x11f9 from Gate
 0x08746409 in G4UImanager::ApplyCommand(char const*) + 0x871 from Gate
 0x08745b94 in G4UImanager::ApplyCommand(G4String) + 0x2a from Gate
 0x0832e347 in G4UIterminal::ExecuteCommand(G4String) + 0x53 from Gate
 0x0832dfff in G4UIterminal::SessionStart() + 0x5b from Gate
 0x0816b51d in main + 0x5bb from Gate
 0x414cddc6 in __libc_start_main + 0xc6 from /lib/libc.so.6
 0x0816a941 in TFile::TFile(char const*, char const*, char const*, int)
+ 0x5d from Gate
Abort



As I wrote this, I found out that I can translate the phantom *after* I
have attached it, then it's fine, i.e.:

This is okay:

/gate/world/daughters/name hemisphere
/gate/world/daughters/insert sphere
/gate/hemisphere/setMaterial Water
/gate/hemisphere/vis/setColor grey
/gate/hemisphere/geometry/setRmax   7.8 cm
/gate/hemisphere/geometry/setRmin   0.0 cm
/gate/hemisphere/geometry/setThetaStart 0.0 rad
/gate/hemisphere/geometry/setDeltaTheta 1.5708 rad

/gate/hemisphere/attachPhantomSD
/gate/hemisphere/placement/setTranslation 0.0 0.0 -3.9 cm


This is NOT okay:

/gate/world/daughters/name hemisphere
/gate/world/daughters/insert sphere
/gate/hemisphere/setMaterial Water
/gate/hemisphere/vis/setColor grey
/gate/hemisphere/geometry/setRmax   7.8 cm
/gate/hemisphere/geometry/setRmin   0.0 cm
/gate/hemisphere/geometry/setThetaStart 0.0 rad
/gate/hemisphere/geometry/setDeltaTheta 1.5708 rad
/gate/hemisphere/placement/setTranslation 0.0 0.0 -3.9 cm

/gate/hemisphere/attachPhantomSD



Why would this be?

And now, after moving my phantom the correct way, it looks like it is
okay when I say the center of the source hemisphere is at (0,0,0).  

If nothing else, maybe this will help someone out there!

Ange



More information about the Gate-users mailing list