The built-in log-space arithmetic operations are wonderful. (Thanks so much Neil!)
It sometimes happens that after some log-operations where the result is very close to 0 that it actually goes slightly above 0 as a result of floating point errors, and thus is not a log-probability anymore, which gave me a few headaches. One obvious approach is to surround the result with a check, and if it is positive but not, say, above 1e-8 then round it down to 0, otherwise raise an exception if positive. But this feels like a hack and I was wondering if there was any "good" way to ensure that any correct log-space operation remains a log-probability (i.e., never goes above 0). Thanks, Laurent -- You received this message because you are subscribed to the Google Groups "Racket Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.

