Problem 263 - program crashes when trying G4UnionSolid()
Summary: program crashes when trying G4UnionSolid()
Status: RESOLVED WORKSFORME
Alias: None
Product: Geant4
Classification: Unclassified
Component: geometry/solids (show other problems)
Version: 3.0
Hardware: PC Linux
: P1 major
Assignee: Vladimir.Grichine
URL:
Depends on:
Blocks:
 
Reported: 2001-06-14 10:08 CEST by cesar.domingo.pardo
Modified: 2002-03-27 09:14 CET (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this problem.
Description cesar.domingo.pardo 2001-06-14 10:08:56 CEST
In my simulation I have created the following volume using G4UnionSolid():

  // Carbon Cross

  G4Tubs* solidTUH = new G4Tubs("TUH",minRadius,maxRadiusTUH,
				 halfLengthTUH,startPhi,deltaPhi);

  G4Tubs* solidTUV = new G4Tubs("TUV",minRadius,maxRadiusTUV,
				 halfLengthTUV,startPhi,deltaPhi);

    G4UnionSolid* solidCCross = new
G4UnionSolid("CCross",solidTUH,solidTUV,&rmCCross,G4ThreeVector());

  G4LogicalVolume* logicCCross = new G4LogicalVolume(solidCCross,Cfiber,"TUH");

  G4VPhysicalVolume* physiCCross = new G4PVPlacement(0,G4ThreeVector(),"CCross",
						     logicCCross,physiWorld,true,0);

When I run the program, after some events (depending on the seed), I obtain the
following message:

Invalid call in G4UnionSolid::DistanceToIn(p),  point p is inside

*** G4Exception: Aborting execution ***
Abort

The gdb backtrace is:
(gdb) backtrace
#0  0x4034bd41 in __kill () from /lib/libc.so.6
#1  0x4034b9b6 in raise (sig=6) at ../sysdeps/posix/raise.c:27
#2  0x4034d0d8 in abort () at ../sysdeps/generic/abort.c:88
#3  0x81b2787 in G4Exception ()
#4  0x805fe96 in G4UnionSolid::DistanceToIn ()
#5  0x810b8ef in G4NormalNavigation::ComputeStep ()
#6  0x810901c in G4Navigator::ComputeStep ()
#7  0x80ef400 in G4Transportation::AlongStepGetPhysicalInteractionLength ()
#8  0x80dde75 in G4SteppingManager::Stepping ()
#9  0x80d7bee in G4TrackingManager::ProcessOneTrack ()
#10 0x80cd7e5 in G4EventManager::ProcessOneEvent ()
#11 0x8063120 in G4RunManager::DoEventLoop ()
#12 0x8062cfe in G4RunManager::BeamOn ()
#13 0x804ad6e in main ()
#14 0x403459cb in __libc_start_main (main=0x804ac20 <main>, argc=1,
argv=0xbffff664, init=0x804a3d4 <_init>,
    fini=0x81e7380 <_fini>, rtld_fini=0x4000ae60 <_dl_fini>,
stack_end=0xbffff65c) at ../sysdeps/generic/libc-start.c:92

Thank you very much in advance.
Comment 1 Gabriele Cosmo 2001-06-14 11:52:59 CEST
Could you please better specify your geometry, or point to an AFS area
or URL where to retrieve your geometry dscription ?
As it is described, we cannot verify it.
Thanks.
Comment 2 Vladimir.Grichine 2002-03-27 09:14:59 CET
The application works stable with statistics more than 300000 (>4 hours) with
Patch-02 0f 28.02.02