Re: [xml] XPath mod operator problems
- From: Bjorn Reese <breese mail1 stofanet dk>
- To: xml gnome org
- Subject: Re: [xml] XPath mod operator problems
- Date: Sat, 29 Jun 2002 15:56:27 +0000
Geert Kloosterman wrote:
This means epsilon should be variable, depending on the size of the
numbers being compared. Am I correct?
You are right. Fortunately, we can handle this as follows (unless I've
made another error :)
(1 - epsilon) A < B < (1 + epsilon) A
And in C
#define DBL_EQUAL(a,b) ((((1.0 - DBL_EPSILON) * (a)) < (b)) && \
(((1.0 + DBL_EPSILON) * (a)) > (b)))
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]