Created attachment 26 [details] Detector construction showing exactly what I'm doing I'm trying to implement an off-axis parabolic mirror by using a G4SubtractionSolid. I construct a cylinder and a paraboloid, and then subtract the paraboloid (offset appropriately by a G4Transform3D) from the cylinder. To test my mirror, I have constructed a rudimentary simulation that centers my mirror (made of perfectly reflective silver) in a world volume filled with air and fire a collimated beam of optical photons at the mirror. Photons are launched in the +x-direction, and I control the orientation of the mirror. When the mirror is aligned parallel to the incoming beam, Geant initializes the photon... and then sits there forever... Here is an example of the output: > Idle> /run/beamOn 1 > /run/beamOn 1 > > [CUT OUT EXCESS VERBOSITY] > > Start closing geometry. > G4GeometryManager::ReportVoxelStats -- Voxel Statistics > > Total memory consumed for geometry optimisation: 0 kByte > Total CPU time elapsed for geometry optimisation: 0 seconds > Start Run processing. > > ********************************************************************** > *********************************** > * G4Track Information: Particle = opticalphoton, Track ID = > 1, Parent ID = 0 > ********************************************************************** > *********************************** > > Step# X(mm) Y(mm) Z(mm) KinE(MeV) dE(MeV) StepLeng > TrackLeng NextVolume ProcName > 0 -200 -12.8 -8.02 2.48e-06 0 > 0 0 World initStep When I tilt the mirror to *any other angle* (including being off by only 1.0*deg from parallel), Geant tracks the photons successfully. Here's a sample output when the mirror was only 1.0*deg away from being aligned the way I need it to be: > Idle> /run/beamOn 1 > /run/beamOn 1 > > [IDENTICAL EXCESS VERBOSITY SNIPPED] > > Start Run processing. > > ********************************************************************** > *********************************** > * G4Track Information: Particle = opticalphoton, Track ID = > 1, Parent ID = 0 > ********************************************************************** > *********************************** > > Step# X(mm) Y(mm) Z(mm) KinE(MeV) dE(MeV) StepLeng > TrackLeng NextVolume ProcName > 0 -200 -4.22 -3.69 2.48e-06 0 > 0 0 World initStep > Photon at Boundary! > Old Momentum Direction: (1,0,0) > Old Polarization: (1,0,0) > New Momentum Direction: > (-0.05293133382954407,0.02184222449822722,-0.9983592495329496) > New Polarization: > (0.05293133382954407,-0.02184222449822722,0.9983592495329496) > *** SpikeReflection *** > 1 3.48 -4.22 -3.69 2.48e-06 0 203 > 203 Mirror Transportation > 2 3.48 -4.22 -3.69 2.48e-06 0 0 > 203 World Transportation > 3 -22.8 6.64 -500 2.48e-06 0 497 > 701 OutOfWorld Transportation > > Run terminated. > Run Summary > Number of events processed : 1 > User=0s Real=0s Sys=0s > 1 event has been kept for refreshing and/or reviewing. The only difference I observe in the failed run is some mention of the geometry optimization. I'm very new to Geant, and thus reached the limits of my ability to debug things very rapidly. Please help! Thanks, Jon Toebbe <jtoebbe@mines.edu>
Dear Jonathan, Thank you for reporting this problem. I could reproduce it and I'm working on the fix. Best Regards, Tatiana
The problem was in G4Paraboloid in DistanceOut(p,v), mainly the numerical precision error in solving quadratic equation when one of the cofficient is very small. The fix will be available in the next release.