gem/oq-hazardlib — pull request #125 by monellid (2013-06-12 14:22:34+00:00)
Title: refactor algorithm for calculating planar surface coordinates

This patch simply refactor the algorithm used to compute planar surface coordinates generated by PointSources.

With the current algorithm PointSources close to the poles generate invalid ruptures throwing this exception ("surface's angles are not right"). This has been found using Graeme's input for the global model

It seems that by simply rearranging the way coordinates are computed (rather then moving along the perimeter, compute coordinates with respect to rupture center) solves the issue, presumably because in this way numerical errors are not propagated from one corner to the other.