Problem 1812 - Spurious warning about overlap for G4Sphere inside a G4Tubs
Summary: Spurious warning about overlap for G4Sphere inside a G4Tubs
Status: RESOLVED INVALID
Alias: None
Product: Geant4
Classification: Unclassified
Component: geometry (show other problems)
Version: 10.1
Hardware: PC Linux
: P5 trivial
Assignee: Gabriele Cosmo
URL:
Depends on:
Blocks:
 
Reported: 2016-01-13 14:36 CET by Amnon Harel
Modified: 2016-01-13 15:32 CET (History)
0 users

See Also:


Attachments
A simplified reproduction (TestGeometry.cc), an OpenGL screenshot, and an output extract. (6.78 KB, application/x-compressed-tar)
2016-01-13 14:36 CET, Amnon Harel
Details

Note You need to log in before you can comment on or make changes to this problem.
Description Amnon Harel 2016-01-13 14:36:22 CET
Created attachment 373 [details]
A simplified reproduction (TestGeometry.cc), an OpenGL screenshot, and an output extract.

When placing a G4Sphere (or a G4Orb) inside a hollow G4Tubs, I get spurious warnings about overlaps. However, the OpenGL display clearly shows that, as planned, there is no overlap. 

A simplified example is attached, together with a screen shot showing that there is no overlap and an extract from the output log showing the spurious warning.
Comment 1 Gabriele Cosmo 2016-01-13 15:32:29 CET
The error message is correct as the setup is clearly wrong.
You're creating an empty tube, therefore the sphere must be placed inside the world, not inside the tube!
i.e. replace:
  new G4PVPlacement( 0, G4ThreeVector(  0, 0, 0 ), orb_log, "Orb", tube_log, false, 0, check_overlaps );
with:
  new G4PVPlacement( 0, G4ThreeVector(  0, 0, 0 ), orb_log, "Orb", world_log, false, 0, check_overlaps );