Problem 1078

Summary: checkoverlaps in G4PVParameterised / potential bug
Product: Geant4 Reporter: Evaristo Cisbani <evaristo.cisbani>
Component: geometry/volumesAssignee: Gabriele Cosmo <Gabriele.Cosmo>
Status: RESOLVED FIXED    
Severity: minor    
Priority: P5    
Version: 9.2   
Hardware: All   
OS: All   

Description Evaristo Cisbani 2009-09-18 12:24:06 CEST
I defined a relatively simple parameterised volume made of layers of
identical surface but different thickness and material (to simulate a
GEM chamber).

When I enabled the CheckOverlaps I got an unexpected overlap warning
between two layers that are separated by several mm.

Looking at the code of CheckOverlaps in G4PVParameterised.cc (version
4.9.2.p02) it seems to me that the line:

G4AffineTransform Td( GetRotation(), GetTranslation() );

should be moved inside the "pos" loop, right before the definition of
"md"

Does it sound correct ?
Comment 1 Gabriele Cosmo 2009-09-21 12:32:03 CEST
Thanks for reporting this. The fix has been now introduced in the development tree and will be included in a future patch or release. The correct fix is actually the following, adopt:
    G4ThreeVector md = Td.Inverse().TransformPoint(*pos);
in place of:
    G4ThreeVector md = Td.Invert().TransformPoint(*pos);