Problem 1887 - G4CutTubs crash
Summary: G4CutTubs crash
Status: RESOLVED FIXED
Alias: None
Product: Geant4
Classification: Unclassified
Component: geometry/solids (show other problems)
Version: 10.2
Hardware: All Linux
: P4 critical
Assignee: Evgueni.Tcherniaev
URL:
Depends on:
Blocks:
 
Reported: 2016-09-07 16:54 CEST by Vladimir.Ivantchenko
Modified: 2016-11-02 17:12 CET (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this problem.
Description Vladimir.Ivantchenko 2016-09-07 16:54:30 CEST
New CMS tracker prepared for 2017 run tried to use CMSG4CutBubs solid to describe geometry of the support structure. Unfortunately, this is not possible due to crash in class constructor in line#125. The check is too strong.

Examples of such solid are following:


 <CutTubs name="PixelForwardInnerDiskOuterRing_seg_1"
rMin="114.850000000000" rMax="117.350000000000" dz="8.750000000000"
startPhi="1.519000000000" deltaPhi="0.138000000000" lx="0.396977347389"
ly="0.006830142398" lz="-0.917802993466" tx="0.000000000000"
ty="-0.000000000000" tz="1.000000000000"/>

<CutTubs name="PixelForwardInnerDiskOuterRing_seg_9"
rMin="114.850000000000" rMax="117.350000000000" dz="10.250000000000"
startPhi="4.626000000000" deltaPhi="0.138000000000" lx="-0.000000000000"
ly="-0.000000000000" lz="-1.000000000000" tx="0.396976074899"
ty="-0.006903705033" tz="0.917802993466"/>

<CutTubs name="PixelForwardInnerDiskInnerRing_seg_7"
rMin="36.850000000000" rMax="39.350000000000" dz="11.500000000000"
startPhi="4.284000000000" deltaPhi="0.587000000000" lx="0.519034630113"
ly="-0.070439789349" lz="-0.851845812820" tx="0.000000000000"
ty="0.000000000000" tz="1.000000000000"/>

<CutTubs name="PixelForwardOuterDiskOuterRing_seg_1"
rMin="165.300000000000" rMax="167.400000000000" dz="7.250000000000"
startPhi="1.547000000000" deltaPhi="0.084000000000" lx="0.445675398753"
ly="0.008113825570" lz="-0.895157865843" tx="0.140831388398"
ty="0.002563931784" tz="0.990030275444"/>

<CutTubs name="PixelForwardOuterDiskOuterRing_seg_9"
rMin="165.300000000000" rMax="167.400000000000" dz="14.000000000000"
startPhi="4.580000000000" deltaPhi="0.078000000000" lx="0.076048884849"
ly="-0.007122847173" lz="-0.997078648935" tx="0.356128404368"
ty="-0.033355495000" tz="0.933841512547"/>

 <CutTubs name="PixelForwardOuterDiskOuterRing_seg_10"
rMin="165.300000000000" rMax="167.400000000000" dz="8.000000000000"
startPhi="4.658000000000" deltaPhi="0.078000000000" lx="0.223951360659"
ly="-0.003446655180" lz="-0.974594227680" tx="0.357644702165"
ty="-0.005504221818" tz="0.933841512547"/>

<CutTubs name="PixelForwardOuterDiskInnerRing_seg_1"
rMin="87.550000000000" rMax="90.050000000000" dz="7.750000000000"
startPhi="1.525000000000" deltaPhi="0.103000000000" lx="0.474673112860"
ly="0.002707409674" lz="-0.880158000509" tx="0.653290351156"
ty="0.003726195078" tz="0.757098297817"/>

<CutTubs name="PixelForwardOuterDiskInnerRing_seg_10"
rMin="87.550000000000" rMax="90.050000000000" dz="7.250000000000"
startPhi="4.597000000000" deltaPhi="0.173000000000" lx="0.500494999912"
ly="-0.014462813885" lz="-0.865618612368" tx="0.359647955152"
ty="-0.010392754054" tz="0.933030191911"/>
Comment 1 Gabriele Cosmo 2016-09-07 16:56:11 CEST
Can you please report the G4Exception you get from G4CutTubs?
Comment 2 Vladimir.Ivantchenko 2016-09-07 17:02:25 CEST
More information. The exception is looked like:

 *** G4Exception : GeomSolids0002
    issued by : G4CutTubs::G4CutTubs() Invalid Low or High Normal to 
    Z plane; Crossing Cutted Planes.
    Invalid Norm to Z plane ((0.519035,-0.0704398,-0.851846) and  (0,0,1)) in
    solid: PixelForwardInnerDiskInnerRing_seg_7

By the way, G4Exception printout is incomplete. Normally one should see all parameters of a solid if they are not correct and not only normals.
Comment 3 Evgueni.Tcherniaev 2016-09-14 09:32:38 CEST
A little change of the parameters of the solid PixelForwardInnerDiskInnerRing_seg_7 can be considered as a quick (temporary) solution of the problem.

First solution: slight change of the inclination of the cut plane (around 1 degree) , normal=(0.503275,-0.0704247,-0.861252) can be use instead of normal=(0.519035,-0.0704398,-0.851846)

Second solution: increase length of the solid, dz=12.0 can be used instead of dz=11.5
Comment 4 Evgueni.Tcherniaev 2016-11-02 17:09:38 CET
Check for intersection of cutting planes has been disabled as too strict.