Hi David, the assertion fails! I added a debug macro and found that if: rangeAmin = -nan rangeAmax = -nan then the difference is -nan and the sqrt function conks out with a domain error. Perhaps the vectors being dotted are not being initialized in some cases??? Dean