Main Page   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   File Members  

ixlib_numeric.hh File Reference

#include <cstring>
#include <ixlib_base.hh>
#include <ixlib_exgen.hh>

Go to the source code of this file.

Namespaces

namespace  ixion

Defines

#define NUM_MIN(a, b)   ( (a)<(b) ? (a) : (b) )
#define NUM_MAX(a, b)   ( (a)>(b) ? (a) : (b) )
#define NUM_ABS(a)   ( (a)<0 ? (-(a)) : (a) )
#define NUM_LIMIT(lower, value, upper)   ( NUM_MAX(lower,NUM_MIN(upper,vallue)) )
#define NUM_INBOUND(lower, value, upper)   (((lower) <= (value)) && ((value) <= (upper)))
#define NUM_OVERLAP(a1, a2, b1, b2)   ((((a1)<=(b1))&&((a2)>(b1)))||(((a1)<(b2))&&((a2)>(b2)))||(((a1)>=(b1))&&((a2)<=(b2))))
#define NUM_CIRCLEINC(index, size)   ( ((index)+1) >= (size) ? 0 : ((index)+1) )
#define NUM_CIRCLEDIST(head, tail, size)   ( (head)<(tail) ? ((head)+(size)-(tail)) : ((head)-(tail)) )


Define Documentation

#define NUM_ABS      ( (a)<0 ? (-(a)) : (a) )
 

Definition at line 31 of file ixlib_numeric.hh.

Referenced by ixion::float_random::init(), and ixion::number_traits::norm().

#define NUM_CIRCLEDIST head,
tail,
size       ( (head)<(tail) ? ((head)+(size)-(tail)) : ((head)-(tail)) )
 

Definition at line 42 of file ixlib_numeric.hh.

Referenced by ixion::ring_queue::size().

#define NUM_CIRCLEINC index,
size       ( ((index)+1) >= (size) ? 0 : ((index)+1) )
 

Definition at line 40 of file ixlib_numeric.hh.

#define NUM_INBOUND lower,
value,
upper       (((lower) <= (value)) && ((value) <= (upper)))
 

Definition at line 36 of file ixlib_numeric.hh.

#define NUM_LIMIT lower,
value,
upper       ( NUM_MAX(lower,NUM_MIN(upper,vallue)) )
 

Definition at line 34 of file ixlib_numeric.hh.

#define NUM_MAX a,
     ( (a)>(b) ? (a) : (b) )
 

Definition at line 30 of file ixlib_numeric.hh.

#define NUM_MIN a,
     ( (a)<(b) ? (a) : (b) )
 

Definition at line 29 of file ixlib_numeric.hh.

#define NUM_OVERLAP a1,
a2,
b1,
b2       ((((a1)<=(b1))&&((a2)>(b1)))||(((a1)<(b2))&&((a2)>(b2)))||(((a1)>=(b1))&&((a2)<=(b2))))
 

Definition at line 38 of file ixlib_numeric.hh.

Referenced by ixion::rectangle::intersects().


Generated on Wed Oct 31 17:12:24 2001 for ixlib by doxygen1.2.11.1 written by Dimitri van Heesch, © 1997-2001