Hi,
in a Mata program I am using the expression
abs((x-y)/z) < 1
where x, y and z are real scalars. Note that in some cases y has been
set to x + z earlier in the program. Although the expression should
evaluate to "false" in these cases, it sometimes does evaluate to "true"
due to roundoff error.
My question now is: Would it be reasonable to code
abs((x-y)/z) < 1-epsilon(1)
Or how would one approach such a problem?
Many thanks,
ben
*
* For searches and help try:
* http://www.stata.com/support/faqs/res/findit.html
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/