Comaprison of double values

Hello every one,
Can somebody help me to write one macro to comapre two double values?
I need to have some thing like this
a <= b and a >= b, where a and b are two double values.
Thanks in advance.
[224 byte] By [aram2k4] at [2007-11-20 1:14:56]
# 1 Re: Comaprison of double values
what do you have so far?
Alin at 2007-11-10 23:19:08 >
# 2 Re: Comaprison of double values
Thank you so much. I wrote one of my own.
aram2k4 at 2007-11-10 23:20:08 >
# 3 Re: Comaprison of double values
Please keep in mind that if your macro refers to a and/or b more than once and you use it with a function call (like sin(x)) or with an expression with a side-effect such as x++, the function will be called (up to) twice and in the second case the value of x may be incremented by 0, 1, or 2 depending on the value of x and the other parameter passed to the macro.

C++ inline functions do not have this problem. See also Inline Functions versus Macros (http://msdn2.microsoft.com/en-us/library/bf6bf4cf.aspx) in MSDN.
Boris K K at 2007-11-10 23:21:02 >
# 4 Re: Comaprison of double values
Have a look at numeric_limits<T>::epsilon() as well.
exterminator at 2007-11-10 23:22:07 >