next up previous contents
Next: PMT Simulation Up: Detector Geometry Previous: Extending the Geometry   Contents

Avoiding and Curing Numerical Problems

The basic geometry routines of any Monte Carlo are subjected to a particularly virulent form of Murphy's Law. Not only will every possible (and impossible) situation arrive, but also it is guaranteed to happen at the point of maximun inconvenience - i.e. about 10 hours into the ``definitive'' run. Points will be in two or more regions simulataneously or in no region at all. Tracks will travel in the planes of any flat surface and strike any intersection between two surfaces with a pinpoint accuracy that would be the envy of any tactical force commander. In order to combat these problems we have to try both prevention and cure. Prevention is dealt with by the following:-

To help cure problems we need to be able to reproduce bugs when they crop up. Keeping a short history of previous calls to the geometry interface routines that can be dumped when an error occurs will help here.


next up previous contents
Next: PMT Simulation Up: Detector Geometry Previous: Extending the Geometry   Contents
sno Guest Acct 2009-09-09