Deformable registration in D

Don Clugston dac at nospam.com.au
Fri Aug 3 00:02:53 PDT 2007


Robert Jacques wrote:
>> Exp with finite support, how does this go?
> 
> The support of a function is basically the range in which its non-zero. 
> See http://en.wikipedia.org/wiki/Support_(mathematics) for more details. 
> I’m specifically using it to calculate the Gaussian, which is 
> essentially exp(-x) where x > 0 (x is a distance). So I have a few small 
> x’s which become relatively large exp(-x) and many large x’s that become 
> really tiny exp(-x). By approximating all those large x’s (tiny exp(-x)) 
> with zero (i.e. making the support finite) I don’t have to calculate as 
> many exp functions, which speeds up the computation.


What cutoff are you using? Denormals are only generated for x around -11300 for 
80-bit reals, but for floats they'll happen for x between about -85 and -105. 
IIRC, denormals are ~100 times slower than normals on x87, so could easily be 
performance killers.



More information about the Digitalmars-d-announce mailing list