<html><head><meta http-equiv="Content-Type" content="text/html charset=iso-8859-1"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Dear Richard -<div><br></div><div> thanks to all your efforts for tracking this down. It sounds really subtle and not at all easy to find - Curtis<br><div apple-content-edited="true">
<span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; font-size: medium; "><div><div>---------</div><div>Curtis A. Meyer<span class="Apple-tab-span" style="white-space: pre; ">                        </span>MCS Associate Dean for Faculty and Graduate Affairs</div><div>Wean: (412) 268-2745<span class="Apple-tab-span" style="white-space: pre; ">        </span>Professor of Physics</div><div>Doherty: (412) 268-3090<span class="Apple-tab-span" style="white-space: pre; ">        </span>Carnegie Mellon University</div><div>Fax: (412) 681-0648<span class="Apple-tab-span" style="white-space: pre; ">        </span>Pittsburgh, PA 15213</div><div><a href="mailto:curtis.meyer@cmu.edu">curtis.meyer@cmu.edu</a><span class="Apple-tab-span" style="white-space: pre; ">        </span>http://www.curtismeyer.com/</div></div><div><br></div></span><br class="Apple-interchange-newline">
</div>
<br><div><div>On Jan 16, 2014, at 6:25 PM, Richard Jones <<a href="mailto:richard.t.jones@uconn.edu">richard.t.jones@uconn.edu</a>> wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div dir="ltr">Hello Offliners,<div><br></div><div>I have diagnosed and fixed the bug that Simon and Paul pointed out back in November, that after my geometry updates related to the Geant4 development, there appeared large holes in the acceptance for charged tracks at backward angles in the CDC. The changes have been checked into subversion. I invite anyone who is interested to check out the updated code and verify that the holes have been healed. The problem was entirely with Geant3, not with mcsmear and not with the reconstruction code.</div>
<div><br></div><div>The source of the bug was code that Simone (Gianni, not Taylor) introduced in Geant321, related to his scheme for virtual divisions. That code employed a short-cut for determining the transverse extents of volumes with cylindrical symmetry when being cut along a cartesian axis. He assumed that if the cos(theta) of the rotated volume is greater than 0.99 then it should be treated as if theta=0. His code is full of approximations like this, and in most cases they are conservative ones that result in intervals that are larger than the actual volume, which is safe. But in the case of the stereo straws, we have cos(6 deg) = 0.995, which results in the projection of the stereo staws onto the x,y plane having a width of only one straw diameter. This is wrong by a whole order of magnitude, and results in straws not being checked for intersections with tracks if the track intersects the straw layer at a point in x that is far from its shunken image in x,y. The image was being taken at the downstream end, which explains why the problems got worse at the upstream end, but really there were problems everywhere.</div>
<div><br></div><div>That was one bug I found, and there was another one that I am not sure impacts us very much, but which I also fixed.</div><div><br></div><div>Someone might be wondering what changed to make this bug suddenly impact us in such a clear way after the recent geometry updates. The reason is somewhat arbitrary, because the straws were changed from straight tubes to "profiled tubes" in order to make them "neck down" to the diameter of the feedthroughs where they punch through the end plates. This change made the code form the "shunken image" of the straw x-y profile (that I referred to above) at the downstream end instead of in the middle of the straw, as it did formerly.</div>
<div><br></div><div>We were LUCKY THIS HAPPENED, because the bug was always there in the simulation code, but the effects were more subtle before, and were only happening near the two end plates, which made them more difficult to notice and diagnose. Now with this fix, any bogus inefficiencies that were seen in the stereo layers near the end-plates are now removed. </div>
<div><br></div><div>Thanks to all of you for your patience with this. We might have gotten away with ignoring it and moving forward with the G4 development, but I think that would have been a mistake. We need both simulations to work during the transition period, and this information may be useful for explaining artifacts in prior simulations that were never fully understood.</div>
<div><br></div><div>-Richard Jones</div></div>
_______________________________________________<br>Halld-offline mailing list<br><a href="mailto:Halld-offline@jlab.org">Halld-offline@jlab.org</a><br>https://mailman.jlab.org/mailman/listinfo/halld-offline</blockquote></div><br></div></body></html>