<br><font size=2 face="sans-serif">Sorry I forgot to attach the test bench result in the former email,</font>
<br><font size=2 face="sans-serif">here it is.</font>
<br>
<br>
<br>
<br>
<br>
<br><font size=2 face="sans-serif">Hi,</font>
<br>
<br><font size=2 face="sans-serif">Recently I installed the new version of the GATE v3.0 into my computer</font>
<br><font size=2 face="sans-serif">with Geant4.8.0.p01, CLHEP2.0.2.2, and the compiler is gcc4.0.1 and</font>
<br><font size=2 face="sans-serif">the Linux version is Scientific Linux CERN.</font>
<br>
<br><font size=2 face="sans-serif">After I installed the GATE, I ran the test bench of the PET and the result</font>
<br><font size=2 face="sans-serif">is shown here as the attachment. From the result, you will see there are</font>
<br><font size=2 face="sans-serif">only 7 sectors in the detector ring, which should be 8. </font>
<br><font size=2 face="sans-serif">Then I checked with my own camera geometry and every time the sector numbers</font>
<br><font size=2 face="sans-serif">was short of 1 as what I have defined.</font>
<br>
<br><font size=2 face="sans-serif">I checked the source code of GATE and find such code in GateAngularRepeater.cc</font>
<br><font size=2 face="sans-serif">.</font>
<br><font size=2 face="sans-serif">.</font>
<br><font size=2 face="sans-serif">.</font>
<br><font size=2 face="sans-serif">void GateAngularRepeater::PushMyPlacements(const G4RotationMatrix& currentRotationMatrix,</font>
<br><font size=2 face="sans-serif"> const G4ThreeVector& currentPosition,</font>
<br><font size=2 face="sans-serif"> G4double )</font>
<br><font size=2 face="sans-serif">{</font>
<br><font size=2 face="sans-serif"> G4double dphi ;</font>
<br><font size=2 face="sans-serif"> if ( m_angularSpan == 360. *deg)</font>
<br><font size=2 face="sans-serif"> dphi = GetAngularPitch_1();</font>
<br><font size=2 face="sans-serif"> if ( m_angularSpan != 360. *deg)</font>
<br><font size=2 face="sans-serif"> dphi = GetAngularPitch_2();</font>
<br><font size=2 face="sans-serif">.</font>
<br><font size=2 face="sans-serif">.</font>
<br><font size=2 face="sans-serif">.</font>
<br>
<br>
<br><font size=2 face="sans-serif">I think that the comparision of two float type like this ( m_angularSpan == 360. *deg)</font>
<br><font size=2 face="sans-serif">is dangeous, sometimes it works fine but sometimes it may give wrong result based on what</font>
<br><font size=2 face="sans-serif">kind of compiler, system or cpu are used.</font>
<br>
<br><font size=2 face="sans-serif">So I changed the code as this:</font>
<br>
<br><font size=2 face="sans-serif"> if ( m_angularSpan < 360.0005 *deg && m_angularSpan > 359.9995 *deg)</font>
<br><font size=2 face="sans-serif"> dphi = GetAngularPitch_1();</font>
<br><font size=2 face="sans-serif"> else</font>
<br><font size=2 face="sans-serif"> dphi = GetAngularPitch_2();</font>
<br>
<br><font size=2 face="sans-serif">After recompile the Gate, now the result seems ok.</font>
<br>
<br>
<br><font size=2 face="sans-serif">I also checked the old versions of GATE, they were all coded in the same way and I didn't have</font>
<br><font size=2 face="sans-serif">this problem before. So I think it mostly caused by the different compiler (gcc4). </font>
<br><font size=2 face="sans-serif">This just a reminder to you if you have the same proble in your computer.</font>
<br>
<br>
<br><font size=2 face="sans-serif">Yuxuan</font>
<br>