wfmath 1.0.3
A math library for the Worldforge system.
WFMath Namespace Reference

Generic library namespace. More...

Classes

class  AtlasInType
 
class  AtlasOutType
 
class  AxisBox
 A dim dimensional axis-aligned box. More...
 
class  Ball
 A dim dimensional ball. More...
 
struct  ColinearVectors
 An error thrown by certain functions when passed parallel vectors. More...
 
class  Line
 A dim dimensional line. More...
 
struct  LinePointData
 
class  MTRand
 
struct  numeric_constants
 
struct  numeric_constants< double >
 
struct  numeric_constants< float >
 
struct  ParseError
 An error thrown by operator>>() when it fails to parse wfmath types. More...
 
class  Point
 A dim dimensional point. More...
 
class  Poly2Orient
 
struct  Poly2OrientIntersectData
 
class  Poly2Reorient
 
class  Polygon
 A polygon, all of whose points lie in a plane, embedded in dim dimensions. More...
 
class  Polygon< 2 >
 The 2D specialization of the Polygon<> template. More...
 
struct  PolyReader
 
class  Quaternion
 A normalized quaternion. More...
 
class  RotBox
 A dim dimensional box, lying at an arbitrary angle. More...
 
class  RotMatrix
 A dim dimensional rotation matrix. Technically, a member of the group O(dim). More...
 
class  Segment
 A line segment embedded in dim dimensions. More...
 
class  Shape
 A fake class which documents the generic parts of the WFMath interface. More...
 
class  TimeDiff
 The difference between two timestamps. More...
 
class  TimeStamp
 A time stamp. More...
 
class  Vector
 A dim dimensional vector. More...
 
class  ZeroPrimitive
 Utility class for providing zero primitives. This class will only work with simple structures such as Vector or Point which provide a m_elem structure. In order for it to access the m_elem structure it must be declared as a friend class of the class it will provide an instance of. More...
 

Typedefs

typedef Atlas::Message::WrongTypeException _AtlasBadParse
 
typedef double CoordType
 Basic floating point type. More...
 

Enumerations

enum  Poly2ReorientType {
  WFMATH_POLY2REORIENT_NONE , WFMATH_POLY2REORIENT_CLEAR_AXIS2 , WFMATH_POLY2REORIENT_CLEAR_BOTH_AXES , WFMATH_POLY2REORIENT_MOVE_AXIS2_TO_AXIS1 ,
  WFMATH_POLY2REORIENT_SCALE1_CLEAR2
}
 

Functions

AtlasOutType _ArrayToAtlas (const CoordType *array, unsigned len)
 
void _ArrayFromAtlas (CoordType *array, unsigned len, const AtlasInType &a)
 
bool _ListNumCheck (const Atlas::Message::ListType &list, int dim)
 
template<template< int > class ShapeT>
void _AddCorner (ShapeT< 3 > &shape, const Atlas::Message::ListType &point)
 
template<template< int > class ShapeT>
void _AddCorner (ShapeT< 2 > &shape, const Atlas::Message::ListType &point)
 
template<template< int > class ShapeT, int dim>
void _CornersFromAtlas (ShapeT< dim > &shape, const Atlas::Message::Element &message)
 
template bool Intersection< 3 > (const AxisBox< 3 > &, const AxisBox< 3 > &, AxisBox< 3 > &)
 
template bool Intersection< 2 > (const AxisBox< 2 > &, const AxisBox< 2 > &, AxisBox< 2 > &)
 
template AxisBox< 3 > Union< 3 > (const AxisBox< 3 > &, const AxisBox< 3 > &)
 
template AxisBox< 2 > Union< 2 > (const AxisBox< 2 > &, const AxisBox< 2 > &)
 
template AxisBox< 3 > BoundingBox< 3, std::vector > (const std::vector< AxisBox< 3 >, std::allocator< AxisBox< 3 > > > &)
 
template AxisBox< 2 > BoundingBox< 2, std::vector > (const std::vector< AxisBox< 2 >, std::allocator< AxisBox< 2 > > > &)
 
template AxisBox< 3 > BoundingBox< 3, std::vector > (const std::vector< Point< 3 >, std::allocator< Point< 3 > > > &)
 
template AxisBox< 2 > BoundingBox< 2, std::vector > (const std::vector< Point< 2 >, std::allocator< Point< 2 > > > &)
 
template<int dim>
bool Intersection (const AxisBox< dim > &a1, const AxisBox< dim > &a2, AxisBox< dim > &out)
 
template<int dim>
AxisBox< dim > Union (const AxisBox< dim > &a1, const AxisBox< dim > &a2)
 
template<int dim>
std::ostream & operator<< (std::ostream &os, const AxisBox< dim > &m)
 
template<int dim>
std::istream & operator>> (std::istream &is, AxisBox< dim > &m)
 
template<int dim, template< class, class > class container>
AxisBox< dim > BoundingBox (const container< AxisBox< dim >, std::allocator< AxisBox< dim > > > &c)
 Get the axis-aligned bounding box for a set of boxes. More...
 
template<int dim, template< class, class > class container>
AxisBox< dim > BoundingBox (const container< Point< dim >, std::allocator< Point< dim > > > &c)
 Get the axis-aligned bounding box for a set of points. More...
 
template Ball< 2 > BoundingSphere< 2, std::vector > (std::vector< Point< 2 >, std::allocator< Point< 2 > > > const &)
 
template Ball< 2 > BoundingSphereSloppy< 2, std::vector > (std::vector< Point< 2 >, std::allocator< Point< 2 > > > const &)
 
template Ball< 3 > BoundingSphere< 3, std::vector > (std::vector< Point< 3 >, std::allocator< Point< 3 > > > const &)
 
template Ball< 3 > BoundingSphereSloppy< 3, std::vector > (std::vector< Point< 3 >, std::allocator< Point< 3 > > > const &)
 
template<int dim, template< class, class > class container>
Ball< dim > BoundingSphere (const container< Point< dim >, std::allocator< Point< dim > > > &c)
 get the minimal bounding sphere for a set of points More...
 
template<int dim, template< class, class > class container>
Ball< dim > BoundingSphereSloppy (const container< Point< dim >, std::allocator< Point< dim > > > &c)
 get a bounding sphere for a set of points More...
 
template<int dim>
std::ostream & operator<< (std::ostream &os, const Ball< dim > &m)
 
template<int dim>
std::istream & operator>> (std::istream &is, Ball< dim > &m)
 
void _CartToPolar (const CoordType *in, CoordType *out)
 
void _PolarToCart (const CoordType *in, CoordType *out)
 
void _CartToSpherical (const CoordType *in, CoordType *out)
 
void _SphericalToCart (const CoordType *in, CoordType *out)
 
bool Equal (double x1, double x2, double epsilon)
 
bool Equal (float x1, float x2, float epsilon)
 
double _ScaleEpsilon (double x1, double x2, double epsilon)
 
float _ScaleEpsilon (float x1, float x2, float epsilon)
 
CoordType _ScaleEpsilon (const CoordType *x1, const CoordType *x2, int length, CoordType epsilon)
 
template<class C >
bool Equal (const C &c1, const C &c2, CoordType epsilon=numeric_constants< CoordType >::epsilon())
 Test for equality up to precision epsilon. More...
 
CoordType FloatMax (CoordType a, CoordType b)
 
CoordType FloatMin (CoordType a, CoordType b)
 
CoordType FloatClamp (CoordType val, CoordType min, CoordType max)
 
double DoubleMax (double a, double b)
 
double DoubleMin (double a, double b)
 
double DoubleClamp (double val, double min, double max)
 
std::string IntToString (unsigned long val)
 
std::string IntToString (long val)
 
std::string IntToString (unsigned int val)
 
std::string IntToString (int val)
 
std::string IntToString (unsigned short val)
 
std::string IntToString (short val)
 
template<>
bool Intersect< 2 > (const RotBox< 2 > &r, const AxisBox< 2 > &b, bool proper)
 
template<>
bool Intersect< 3 > (const RotBox< 3 > &r, const AxisBox< 3 > &b, bool proper)
 
template bool Intersect< 2 > (const Point< 2 > &, const Point< 2 > &, bool)
 
template bool Intersect< 3 > (const Point< 3 > &, const Point< 3 > &, bool)
 
template bool Contains< 2 > (const Point< 2 > &, const Point< 2 > &, bool)
 
template bool Contains< 3 > (const Point< 3 > &, const Point< 3 > &, bool)
 
template bool Intersect< Point< 2 >, AxisBox< 2 > > (const Point< 2 > &, const AxisBox< 2 > &, bool)
 
template bool Intersect< Point< 3 >, AxisBox< 3 > > (const Point< 3 > &, const AxisBox< 3 > &, bool)
 
template bool Contains< 2 > (const Point< 2 > &, const AxisBox< 2 > &, bool)
 
template bool Contains< 3 > (const Point< 3 > &, const AxisBox< 3 > &, bool)
 
template bool Intersect< 2 > (const AxisBox< 2 > &, const Point< 2 > &, bool)
 
template bool Intersect< 3 > (const AxisBox< 3 > &, const Point< 3 > &, bool)
 
template bool Contains< 2 > (const AxisBox< 2 > &, const Point< 2 > &, bool)
 
template bool Contains< 3 > (const AxisBox< 3 > &, const Point< 3 > &, bool)
 
template bool Intersect< 2 > (const AxisBox< 2 > &, const AxisBox< 2 > &, bool)
 
template bool Intersect< 3 > (const AxisBox< 3 > &, const AxisBox< 3 > &, bool)
 
template bool Contains< 2 > (const AxisBox< 2 > &, const AxisBox< 2 > &, bool)
 
template bool Contains< 3 > (const AxisBox< 3 > &, const AxisBox< 3 > &, bool)
 
template bool Intersect< Point< 2 >, Ball< 2 > > (const Point< 2 > &, const Ball< 2 > &, bool)
 
template bool Intersect< Point< 3 >, Ball< 3 > > (const Point< 3 > &, const Ball< 3 > &, bool)
 
template bool Contains< 2 > (const Point< 2 > &, const Ball< 2 > &, bool)
 
template bool Contains< 3 > (const Point< 3 > &, const Ball< 3 > &, bool)
 
template bool Intersect< 2 > (const Ball< 2 > &, const Point< 2 > &, bool)
 
template bool Intersect< 3 > (const Ball< 3 > &, const Point< 3 > &, bool)
 
template bool Contains< 2 > (const Ball< 2 > &, const Point< 2 > &, bool)
 
template bool Contains< 3 > (const Ball< 3 > &, const Point< 3 > &, bool)
 
template bool Intersect< AxisBox< 2 >, Ball< 2 > > (const AxisBox< 2 > &, const Ball< 2 > &, bool)
 
template bool Intersect< AxisBox< 3 >, Ball< 3 > > (const AxisBox< 3 > &, const Ball< 3 > &, bool)
 
template bool Contains< 2 > (const AxisBox< 2 > &, const Ball< 2 > &, bool)
 
template bool Contains< 3 > (const AxisBox< 3 > &, const Ball< 3 > &, bool)
 
template bool Intersect< 2 > (const Ball< 2 > &, const AxisBox< 2 > &, bool)
 
template bool Intersect< 3 > (const Ball< 3 > &, const AxisBox< 3 > &, bool)
 
template bool Contains< 2 > (const Ball< 2 > &, const AxisBox< 2 > &, bool)
 
template bool Contains< 3 > (const Ball< 3 > &, const AxisBox< 3 > &, bool)
 
template bool Intersect< 2 > (const Ball< 2 > &, const Ball< 2 > &, bool)
 
template bool Intersect< 3 > (const Ball< 3 > &, const Ball< 3 > &, bool)
 
template bool Contains< 2 > (const Ball< 2 > &, const Ball< 2 > &, bool)
 
template bool Contains< 3 > (const Ball< 3 > &, const Ball< 3 > &, bool)
 
template bool Intersect< Point< 2 >, Segment< 2 > > (const Point< 2 > &, const Segment< 2 > &, bool)
 
template bool Intersect< Point< 3 >, Segment< 3 > > (const Point< 3 > &, const Segment< 3 > &, bool)
 
template bool Contains< 2 > (const Point< 2 > &, const Segment< 2 > &, bool)
 
template bool Contains< 3 > (const Point< 3 > &, const Segment< 3 > &, bool)
 
template bool Intersect< 2 > (const Segment< 2 > &, const Point< 2 > &, bool)
 
template bool Intersect< 3 > (const Segment< 3 > &, const Point< 3 > &, bool)
 
template bool Contains< 2 > (const Segment< 2 > &, const Point< 2 > &, bool)
 
template bool Contains< 3 > (const Segment< 3 > &, const Point< 3 > &, bool)
 
template bool Intersect< AxisBox< 2 >, Segment< 2 > > (const AxisBox< 2 > &, const Segment< 2 > &, bool)
 
template bool Intersect< AxisBox< 3 >, Segment< 3 > > (const AxisBox< 3 > &, const Segment< 3 > &, bool)
 
template bool Contains< 2 > (const AxisBox< 2 > &, const Segment< 2 > &, bool)
 
template bool Contains< 3 > (const AxisBox< 3 > &, const Segment< 3 > &, bool)
 
template bool Intersect< 2 > (const Segment< 2 > &, const AxisBox< 2 > &, bool)
 
template bool Intersect< 3 > (const Segment< 3 > &, const AxisBox< 3 > &, bool)
 
template bool Contains< 2 > (const Segment< 2 > &, const AxisBox< 2 > &, bool)
 
template bool Contains< 3 > (const Segment< 3 > &, const AxisBox< 3 > &, bool)
 
template bool Intersect< Ball< 2 >, Segment< 2 > > (const Ball< 2 > &, const Segment< 2 > &, bool)
 
template bool Intersect< Ball< 3 >, Segment< 3 > > (const Ball< 3 > &, const Segment< 3 > &, bool)
 
template bool Contains< 2 > (const Ball< 2 > &, const Segment< 2 > &, bool)
 
template bool Contains< 3 > (const Ball< 3 > &, const Segment< 3 > &, bool)
 
template bool Intersect< 2 > (const Segment< 2 > &, const Ball< 2 > &, bool)
 
template bool Intersect< 3 > (const Segment< 3 > &, const Ball< 3 > &, bool)
 
template bool Contains< 2 > (const Segment< 2 > &, const Ball< 2 > &, bool)
 
template bool Contains< 3 > (const Segment< 3 > &, const Ball< 3 > &, bool)
 
template bool Intersect< 2 > (const Segment< 2 > &, const Segment< 2 > &, bool)
 
template bool Intersect< 3 > (const Segment< 3 > &, const Segment< 3 > &, bool)
 
template bool Contains< 2 > (const Segment< 2 > &, const Segment< 2 > &, bool)
 
template bool Contains< 3 > (const Segment< 3 > &, const Segment< 3 > &, bool)
 
template bool Intersect< Point< 2 >, RotBox< 2 > > (const Point< 2 > &, const RotBox< 2 > &, bool)
 
template bool Intersect< Point< 3 >, RotBox< 3 > > (const Point< 3 > &, const RotBox< 3 > &, bool)
 
template bool Contains< 2 > (const Point< 2 > &, const RotBox< 2 > &, bool)
 
template bool Contains< 3 > (const Point< 3 > &, const RotBox< 3 > &, bool)
 
template bool Intersect< 2 > (const RotBox< 2 > &, const Point< 2 > &, bool)
 
template bool Intersect< 3 > (const RotBox< 3 > &, const Point< 3 > &, bool)
 
template bool Contains< 2 > (const RotBox< 2 > &, const Point< 2 > &, bool)
 
template bool Contains< 3 > (const RotBox< 3 > &, const Point< 3 > &, bool)
 
template bool Intersect< AxisBox< 2 >, RotBox< 2 > > (const AxisBox< 2 > &, const RotBox< 2 > &, bool)
 
template bool Intersect< AxisBox< 3 >, RotBox< 3 > > (const AxisBox< 3 > &, const RotBox< 3 > &, bool)
 
template bool Contains< 2 > (const AxisBox< 2 > &, const RotBox< 2 > &, bool)
 
template bool Contains< 3 > (const AxisBox< 3 > &, const RotBox< 3 > &, bool)
 
template bool Contains< 2 > (const RotBox< 2 > &, const AxisBox< 2 > &, bool)
 
template bool Contains< 3 > (const RotBox< 3 > &, const AxisBox< 3 > &, bool)
 
template bool Intersect< Ball< 2 >, RotBox< 2 > > (const Ball< 2 > &, const RotBox< 2 > &, bool)
 
template bool Intersect< Ball< 3 >, RotBox< 3 > > (const Ball< 3 > &, const RotBox< 3 > &, bool)
 
template bool Contains< 2 > (const Ball< 2 > &, const RotBox< 2 > &, bool)
 
template bool Contains< 3 > (const Ball< 3 > &, const RotBox< 3 > &, bool)
 
template bool Intersect< 2 > (const RotBox< 2 > &, const Ball< 2 > &, bool)
 
template bool Intersect< 3 > (const RotBox< 3 > &, const Ball< 3 > &, bool)
 
template bool Contains< 2 > (const RotBox< 2 > &, const Ball< 2 > &, bool)
 
template bool Contains< 3 > (const RotBox< 3 > &, const Ball< 3 > &, bool)
 
template bool Intersect< Segment< 2 >, RotBox< 2 > > (const Segment< 2 > &, const RotBox< 2 > &, bool)
 
template bool Intersect< Segment< 3 >, RotBox< 3 > > (const Segment< 3 > &, const RotBox< 3 > &, bool)
 
template bool Contains< 2 > (const Segment< 2 > &, const RotBox< 2 > &, bool)
 
template bool Contains< 3 > (const Segment< 3 > &, const RotBox< 3 > &, bool)
 
template bool Intersect< 2 > (const RotBox< 2 > &, const Segment< 2 > &, bool)
 
template bool Intersect< 3 > (const RotBox< 3 > &, const Segment< 3 > &, bool)
 
template bool Contains< 2 > (const RotBox< 2 > &, const Segment< 2 > &, bool)
 
template bool Contains< 3 > (const RotBox< 3 > &, const Segment< 3 > &, bool)
 
template bool Intersect< 2 > (const RotBox< 2 > &, const RotBox< 2 > &, bool)
 
template bool Intersect< 3 > (const RotBox< 3 > &, const RotBox< 3 > &, bool)
 
template bool Contains< 2 > (const RotBox< 2 > &, const RotBox< 2 > &, bool)
 
template bool Contains< 3 > (const RotBox< 3 > &, const RotBox< 3 > &, bool)
 
template<class S1 , class S2 >
bool Intersect (const S1 &s1, const S2 &s2, bool proper)
 
template<int dim>
bool Intersect (const Point< dim > &p1, const Point< dim > &p2, bool proper)
 
template<int dim, class S >
bool Contains (const S &s, const Point< dim > &p, bool proper)
 
template<int dim>
bool Contains (const Point< dim > &p1, const Point< dim > &p2, bool proper)
 
template<int dim>
bool Intersect (const AxisBox< dim > &b, const Point< dim > &p, bool proper)
 
template<int dim>
bool Contains (const Point< dim > &p, const AxisBox< dim > &b, bool proper)
 
template<int dim>
bool Intersect (const AxisBox< dim > &b1, const AxisBox< dim > &b2, bool proper)
 
template<int dim>
bool Contains (const AxisBox< dim > &outer, const AxisBox< dim > &inner, bool proper)
 
template<int dim>
bool Intersect (const Ball< dim > &b, const Point< dim > &p, bool proper)
 
template<int dim>
bool Contains (const Point< dim > &p, const Ball< dim > &b, bool proper)
 
template<int dim>
bool Intersect (const Ball< dim > &b, const AxisBox< dim > &a, bool proper)
 
template<int dim>
bool Contains (const Ball< dim > &b, const AxisBox< dim > &a, bool proper)
 
template<int dim>
bool Contains (const AxisBox< dim > &a, const Ball< dim > &b, bool proper)
 
template<int dim>
bool Intersect (const Ball< dim > &b1, const Ball< dim > &b2, bool proper)
 
template<int dim>
bool Contains (const Ball< dim > &outer, const Ball< dim > &inner, bool proper)
 
template<int dim>
bool Intersect (const Segment< dim > &s, const Point< dim > &p, bool proper)
 
template<int dim>
bool Contains (const Point< dim > &p, const Segment< dim > &s, bool proper)
 
template<int dim>
bool Intersect (const Segment< dim > &s, const AxisBox< dim > &b, bool proper)
 
template<int dim>
bool Contains (const Segment< dim > &s, const AxisBox< dim > &b, bool proper)
 
template<int dim>
bool Contains (const AxisBox< dim > &b, const Segment< dim > &s, bool proper)
 
template<int dim>
bool Intersect (const Segment< dim > &s, const Ball< dim > &b, bool proper)
 
template<int dim>
bool Contains (const Ball< dim > &b, const Segment< dim > &s, bool proper)
 
template<int dim>
bool Contains (const Segment< dim > &s, const Ball< dim > &b, bool proper)
 
template<int dim>
bool Intersect (const Segment< dim > &s1, const Segment< dim > &s2, bool proper)
 
template<int dim>
bool Contains (const Segment< dim > &s1, const Segment< dim > &s2, bool proper)
 
template<int dim>
bool Intersect (const RotBox< dim > &r, const Point< dim > &p, bool proper)
 
template<int dim>
bool Contains (const Point< dim > &p, const RotBox< dim > &r, bool proper)
 
template<int dim>
bool Intersect (const RotBox< dim > &r, const AxisBox< dim > &b, bool proper)
 
template<int dim>
bool Contains (const RotBox< dim > &r, const AxisBox< dim > &b, bool proper)
 
template<int dim>
bool Contains (const AxisBox< dim > &b, const RotBox< dim > &r, bool proper)
 
template<int dim>
bool Intersect (const RotBox< dim > &r, const Ball< dim > &b, bool proper)
 
template<int dim>
bool Contains (const RotBox< dim > &r, const Ball< dim > &b, bool proper)
 
template<int dim>
bool Contains (const Ball< dim > &b, const RotBox< dim > &r, bool proper)
 
template<int dim>
bool Intersect (const RotBox< dim > &r, const Segment< dim > &s, bool proper)
 
template<int dim>
bool Contains (const RotBox< dim > &r, const Segment< dim > &s, bool proper)
 
template<int dim>
bool Contains (const Segment< dim > &s, const RotBox< dim > &r, bool proper)
 
template<int dim>
bool Intersect (const RotBox< dim > &r1, const RotBox< dim > &r2, bool proper)
 
template<int dim>
bool Contains (const RotBox< dim > &outer, const RotBox< dim > &inner, bool proper)
 
bool _Less (CoordType x1, CoordType x2, bool proper)
 
bool _LessEq (CoordType x1, CoordType x2, bool proper)
 
bool _Greater (CoordType x1, CoordType x2, bool proper)
 
bool _GreaterEq (CoordType x1, CoordType x2, bool proper)
 
template<int dim>
bool Intersect (const Polygon< dim > &r, const Point< dim > &p, bool proper)
 
template<int dim>
bool Contains (const Point< dim > &p, const Polygon< dim > &r, bool proper)
 
template<int dim>
bool Intersect (const Polygon< dim > &p, const AxisBox< dim > &b, bool proper)
 
template<int dim>
bool Contains (const Polygon< dim > &p, const AxisBox< dim > &b, bool proper)
 
template<int dim>
bool Contains (const AxisBox< dim > &b, const Polygon< dim > &p, bool proper)
 
template<int dim>
bool Intersect (const Polygon< dim > &p, const Ball< dim > &b, bool proper)
 
template<int dim>
bool Contains (const Polygon< dim > &p, const Ball< dim > &b, bool proper)
 
template<int dim>
bool Contains (const Ball< dim > &b, const Polygon< dim > &p, bool proper)
 
template<int dim>
bool Intersect (const Polygon< dim > &p, const Segment< dim > &s, bool proper)
 
template<int dim>
bool Contains (const Polygon< dim > &p, const Segment< dim > &s, bool proper)
 
template<int dim>
bool Contains (const Segment< dim > &s, const Polygon< dim > &p, bool proper)
 
template<int dim>
bool Intersect (const Polygon< dim > &p, const RotBox< dim > &r, bool proper)
 
template<int dim>
bool Contains (const Polygon< dim > &p, const RotBox< dim > &r, bool proper)
 
template<int dim>
bool Contains (const RotBox< dim > &r, const Polygon< dim > &p, bool proper)
 
template<int dim>
bool Intersect (const Polygon< dim > &p1, const Polygon< dim > &p2, bool proper)
 
template<int dim>
bool Contains (const Polygon< dim > &outer, const Polygon< dim > &inner, bool proper)
 
std::ostream & operator<< (std::ostream &os, MTRand const &mtrand)
 
std::istream & operator>> (std::istream &is, MTRand &mtrand)
 
template CoordType SquaredDistance< 3 > (const Point< 3 > &, const Point< 3 > &)
 
template CoordType SquaredDistance< 2 > (const Point< 2 > &, const Point< 2 > &)
 
template Point< 3 > Midpoint< 3 > (const Point< 3 > &, const Point< 3 > &, CoordType)
 
template Point< 2 > Midpoint< 2 > (const Point< 2 > &, const Point< 2 > &, CoordType)
 
template Point< 3 > Barycenter< 3, std::vector > (const std::vector< Point< 3 > > &)
 
template Point< 3 > Barycenter< 3, std::vector, std::list > (const std::vector< Point< 3 > > &, const std::list< CoordType > &)
 
template Point< 2 > Barycenter< 2, std::vector > (const std::vector< Point< 2 > > &)
 
template Point< 2 > Barycenter< 2, std::vector, std::list > (const std::vector< Point< 2 > > &, const std::list< CoordType > &)
 
template Vector< 3 > operator-<3 > (const Point< 3 > &, const Point< 3 > &)
 
template Vector< 2 > operator-<2 > (const Point< 2 > &, const Point< 2 > &)
 
template Point< 3 > operator-<3 > (const Point< 3 > &, const Vector< 3 > &)
 
template Point< 2 > operator-<2 > (const Point< 2 > &, const Vector< 2 > &)
 
template Point< 3 > & operator-=<3 > (Point< 3 > &, const Vector< 3 > &)
 
template Point< 2 > & operator-=<2 > (Point< 2 > &, const Vector< 2 > &)
 
template Point< 3 > operator+<3 > (const Vector< 3 > &, const Point< 3 > &)
 
template Point< 2 > operator+<2 > (const Vector< 2 > &, const Point< 2 > &)
 
template Point< 3 > operator+<3 > (const Point< 3 > &, const Vector< 3 > &)
 
template Point< 2 > operator+<2 > (const Point< 2 > &, const Vector< 2 > &)
 
template Point< 3 > & operator+=<3 > (Point< 3 > &, const Vector< 3 > &)
 
template Point< 2 > & operator+=<2 > (Point< 2 > &, const Vector< 2 > &)
 
template<int dim>
Point< dim > & operator+= (Point< dim > &p, const Vector< dim > &v)
 
template<int dim>
Point< dim > & operator-= (Point< dim > &p, const Vector< dim > &v)
 
template<int dim>
Vector< dim > operator- (const Point< dim > &c1, const Point< dim > &c2)
 
template<int dim>
Point< dim > operator+ (const Point< dim > &c, const Vector< dim > &v)
 
template<int dim>
Point< dim > operator+ (const Vector< dim > &v, const Point< dim > &c)
 
template<int dim>
Point< dim > operator- (const Point< dim > &c, const Vector< dim > &v)
 
template<int dim>
CoordType SquaredDistance (const Point< dim > &p1, const Point< dim > &p2)
 
template<int dim>
CoordType Distance (const Point< dim > &p1, const Point< dim > &p2)
 
template<int dim>
CoordType SloppyDistance (const Point< dim > &p1, const Point< dim > &p2)
 
template<int dim, template< class, class > class container>
Point< dim > Barycenter (const container< Point< dim >, std::allocator< Point< dim > > > &c)
 Find the center of a set of points, all weighted equally. More...
 
template<int dim, template< class, class > class container, template< class, class > class container2>
Point< dim > Barycenter (const container< Point< dim >, std::allocator< Point< dim > > > &c, const container2< CoordType, std::allocator< CoordType > > &weights)
 Find the center of a set of points with the given weights. More...
 
template<int dim>
Point< dim > Midpoint (const Point< dim > &p1, const Point< dim > &p2, CoordType dist=0.5)
 
template<int dim>
std::ostream & operator<< (std::ostream &os, const Point< dim > &m)
 
template<int dim>
std::istream & operator>> (std::istream &is, Point< dim > &m)
 
template<int dim>
std::ostream & operator<< (std::ostream &os, const Polygon< dim > &r)
 
template<int dim>
std::istream & operator>> (std::istream &is, Polygon< dim > &r)
 
template<int dim>
int Intersect (const Poly2Orient< dim > &, const Poly2Orient< dim > &, Poly2OrientIntersectData &)
 
template<int dim>
bool _PolyContainsBox (const Poly2Orient< dim > &orient, const Polygon< 2 > &poly, const Point< dim > &corner, const Vector< dim > &size, bool proper)
 
bool PolyPolyIntersect (const Polygon< 2 > &poly1, const Polygon< 2 > &poly2, int intersect_dim, const Poly2OrientIntersectData &data, bool proper)
 
bool PolyPolyContains (const Polygon< 2 > &outer, const Polygon< 2 > &inner, int intersect_dim, const Poly2OrientIntersectData &data, bool proper)
 
template bool Intersect< Point< 2 >, Polygon< 2 > > (const Point< 2 > &, const Polygon< 2 > &, bool)
 
template bool Intersect< Point< 3 >, Polygon< 3 > > (const Point< 3 > &, const Polygon< 3 > &, bool)
 
template bool Contains< 3 > (const Point< 3 > &, const Polygon< 3 > &, bool)
 
template bool Intersect< 3 > (const Polygon< 3 > &, const Point< 3 > &, bool)
 
template bool Contains< 3 > (const Polygon< 3 > &, const Point< 3 > &, bool)
 
template bool Intersect< AxisBox< 2 >, Polygon< 2 > > (const AxisBox< 2 > &, const Polygon< 2 > &, bool)
 
template bool Intersect< AxisBox< 3 >, Polygon< 3 > > (const AxisBox< 3 > &, const Polygon< 3 > &, bool)
 
template bool Contains< 3 > (const AxisBox< 3 > &, const Polygon< 3 > &, bool)
 
template bool Intersect< 3 > (const Polygon< 3 > &, const AxisBox< 3 > &, bool)
 
template bool Contains< 3 > (const Polygon< 3 > &, const AxisBox< 3 > &, bool)
 
template bool Intersect< Ball< 2 >, Polygon< 2 > > (const Ball< 2 > &, const Polygon< 2 > &, bool)
 
template bool Intersect< Ball< 3 >, Polygon< 3 > > (const Ball< 3 > &, const Polygon< 3 > &, bool)
 
template bool Contains< 3 > (const Ball< 3 > &, const Polygon< 3 > &, bool)
 
template bool Intersect< 3 > (const Polygon< 3 > &, const Ball< 3 > &, bool)
 
template bool Contains< 3 > (const Polygon< 3 > &, const Ball< 3 > &, bool)
 
template bool Intersect< Segment< 2 >, Polygon< 2 > > (const Segment< 2 > &, const Polygon< 2 > &, bool)
 
template bool Intersect< Segment< 3 >, Polygon< 3 > > (const Segment< 3 > &, const Polygon< 3 > &, bool)
 
template bool Contains< 3 > (const Segment< 3 > &, const Polygon< 3 > &, bool)
 
template bool Intersect< 3 > (const Polygon< 3 > &, const Segment< 3 > &, bool)
 
template bool Contains< 3 > (const Polygon< 3 > &, const Segment< 3 > &, bool)
 
template bool Intersect< RotBox< 2 >, Polygon< 2 > > (const RotBox< 2 > &, const Polygon< 2 > &, bool)
 
template bool Intersect< RotBox< 3 >, Polygon< 3 > > (const RotBox< 3 > &, const Polygon< 3 > &, bool)
 
template bool Contains< 3 > (const RotBox< 3 > &, const Polygon< 3 > &, bool)
 
template bool Intersect< 3 > (const Polygon< 3 > &, const RotBox< 3 > &, bool)
 
template bool Contains< 3 > (const Polygon< 3 > &, const RotBox< 3 > &, bool)
 
template bool Intersect< 3 > (const Polygon< 3 > &, const Polygon< 3 > &, bool)
 
template bool Contains< 3 > (const Polygon< 3 > &, const Polygon< 3 > &, bool)
 
template<>
bool Intersect< 2 > (const Polygon< 2 > &r, const Point< 2 > &p, bool proper)
 
template<>
bool Contains< 2 > (const Point< 2 > &p, const Polygon< 2 > &r, bool proper)
 
template<>
bool Intersect< 2 > (const Polygon< 2 > &p, const AxisBox< 2 > &b, bool proper)
 
template<>
bool Contains< 2 > (const Polygon< 2 > &p, const AxisBox< 2 > &b, bool proper)
 
template<>
bool Contains< 2 > (const AxisBox< 2 > &b, const Polygon< 2 > &p, bool proper)
 
template<>
bool Intersect< 2 > (const Polygon< 2 > &p, const Ball< 2 > &b, bool proper)
 
template<>
bool Contains< 2 > (const Polygon< 2 > &p, const Ball< 2 > &b, bool proper)
 
template<>
bool Contains< 2 > (const Ball< 2 > &b, const Polygon< 2 > &p, bool proper)
 
template<>
bool Intersect< 2 > (const Polygon< 2 > &p, const Segment< 2 > &s, bool proper)
 
template<>
bool Contains< 2 > (const Polygon< 2 > &p, const Segment< 2 > &s, bool proper)
 
template<>
bool Contains< 2 > (const Segment< 2 > &s, const Polygon< 2 > &p, bool proper)
 
template<>
bool Intersect< 2 > (const Polygon< 2 > &p, const RotBox< 2 > &r, bool proper)
 
template<>
bool Contains< 2 > (const Polygon< 2 > &p, const RotBox< 2 > &r, bool proper)
 
template<>
bool Contains< 2 > (const RotBox< 2 > &r, const Polygon< 2 > &p, bool proper)
 
template<>
bool Intersect< 2 > (const Polygon< 2 > &p1, const Polygon< 2 > &p2, bool proper)
 
template<>
bool Contains< 2 > (const Polygon< 2 > &outer, const Polygon< 2 > &inner, bool proper)
 
template<>
bool Intersect (const Polygon< 2 > &r, const Point< 2 > &p, bool proper)
 
template<>
bool Contains (const Point< 2 > &p, const Polygon< 2 > &r, bool proper)
 
template<>
bool Intersect (const Polygon< 2 > &p, const AxisBox< 2 > &b, bool proper)
 
template<>
bool Contains (const Polygon< 2 > &p, const AxisBox< 2 > &b, bool proper)
 
template<>
bool Contains (const AxisBox< 2 > &b, const Polygon< 2 > &p, bool proper)
 
template<>
bool Intersect (const Polygon< 2 > &p, const Ball< 2 > &b, bool proper)
 
template<>
bool Contains (const Polygon< 2 > &p, const Ball< 2 > &b, bool proper)
 
template<>
bool Contains (const Ball< 2 > &b, const Polygon< 2 > &p, bool proper)
 
template<>
bool Intersect (const Polygon< 2 > &p, const Segment< 2 > &s, bool proper)
 
template<>
bool Contains (const Polygon< 2 > &p, const Segment< 2 > &s, bool proper)
 
template<>
bool Contains (const Segment< 2 > &s, const Polygon< 2 > &p, bool proper)
 
template<>
bool Intersect (const Polygon< 2 > &p, const RotBox< 2 > &r, bool proper)
 
template<>
bool Contains (const Polygon< 2 > &p, const RotBox< 2 > &r, bool proper)
 
template<>
bool Contains (const RotBox< 2 > &r, const Polygon< 2 > &p, bool proper)
 
template<>
bool Intersect (const Polygon< 2 > &p1, const Polygon< 2 > &p2, bool proper)
 
template<>
bool Contains (const Polygon< 2 > &outer, const Polygon< 2 > &inner, bool proper)
 
template<typename FloatT >
FloatT GaussianConditional (FloatT mean, FloatT stddev, FloatT val)
 Gives the conditional probability of the Gaussian distribution at position val. More...
 
template<typename FloatT >
FloatT Gaussian (FloatT mean, FloatT stddev, FloatT val)
 Gives the value of the Gaussian distribution at position val. More...
 
template<typename FloatT >
FloatT PoissonConditional (FloatT mean, unsigned int step)
 Gives the conditional probability of the Poisson distribution at position step. More...
 
template<typename FloatT >
FloatT Poisson (FloatT mean, unsigned int step)
 Gives the value of the Poisson distribution at position step. More...
 
template<typename FloatT >
FloatT Factorial (unsigned int n)
 Gives n! More...
 
template<typename FloatT >
FloatT LogFactorial (unsigned int n)
 Gives the natural log of n! More...
 
template<typename FloatT >
FloatT Gamma (FloatT z)
 Euler's Gamma function. More...
 
template<typename FloatT >
FloatT LogGamma (FloatT z)
 The natural log of Euler's Gamma function. More...
 
template float GaussianConditional< float > (float mean, float stddev, float val)
 
template float Gaussian< float > (float mean, float stddev, float val)
 
template float PoissonConditional< float > (float mean, unsigned int step)
 
template float Poisson< float > (float mean, unsigned int step)
 
template float LogFactorial< float > (unsigned int n)
 
template float Factorial< float > (unsigned int n)
 
template float LogGamma< float > (float z)
 
template float Gamma< float > (float z)
 
template double GaussianConditional< double > (double mean, double stddev, double val)
 
template double Gaussian< double > (double mean, double stddev, double val)
 
template double PoissonConditional< double > (double mean, unsigned int step)
 
template double Poisson< double > (double mean, unsigned int step)
 
template double LogFactorial< double > (unsigned int n)
 
template double Factorial< double > (unsigned int n)
 
template double LogGamma< double > (double z)
 
template double Gamma< double > (double z)
 
template<int dim>
std::ostream & operator<< (std::ostream &os, const RotBox< dim > &r)
 
template<int dim>
std::istream & operator>> (std::istream &is, RotBox< dim > &r)
 
bool _MatrixSetValsImpl (const int size, CoordType *vals, bool &flip, CoordType *buf1, CoordType *buf2, CoordType precision)
 
bool _MatrixInverseImpl (const int size, CoordType *in, CoordType *out)
 
template RotMatrix< 2 > operator*<2 > (RotMatrix< 2 > const &, RotMatrix< 2 > const &)
 
template RotMatrix< 3 > operator*<3 > (RotMatrix< 3 > const &, RotMatrix< 3 > const &)
 
template RotMatrix< 2 > ProdInv< 2 > (RotMatrix< 2 > const &, RotMatrix< 2 > const &)
 
template RotMatrix< 3 > ProdInv< 3 > (RotMatrix< 3 > const &, RotMatrix< 3 > const &)
 
template Vector< 2 > operator*<2 > (Vector< 2 > const &, RotMatrix< 2 > const &)
 
template Vector< 3 > operator*<3 > (Vector< 3 > const &, RotMatrix< 3 > const &)
 
template Vector< 2 > operator*<2 > (RotMatrix< 2 > const &, Vector< 2 > const &)
 
template Vector< 3 > operator*<3 > (RotMatrix< 3 > const &, Vector< 3 > const &)
 
template Vector< 2 > ProdInv< 2 > (Vector< 2 > const &, RotMatrix< 2 > const &)
 
template Vector< 3 > ProdInv< 3 > (Vector< 3 > const &, RotMatrix< 3 > const &)
 
template Vector< 3 > Prod< 3 > (Vector< 3 > const &, RotMatrix< 3 > const &)
 
template Vector< 2 > Prod< 2 > (Vector< 2 > const &, RotMatrix< 2 > const &)
 
template RotMatrix< 3 > Prod< 3 > (RotMatrix< 3 > const &, RotMatrix< 3 > const &)
 
template RotMatrix< 2 > Prod< 2 > (RotMatrix< 2 > const &, RotMatrix< 2 > const &)
 
template<int dim>
RotMatrix< dim > Prod (const RotMatrix< dim > &m1, const RotMatrix< dim > &m2)
 returns m1 * m2 More...
 
template<int dim>
RotMatrix< dim > ProdInv (const RotMatrix< dim > &m1, const RotMatrix< dim > &m2)
 returns m1 * m2^-1 More...
 
template<int dim>
RotMatrix< dim > InvProd (const RotMatrix< dim > &m1, const RotMatrix< dim > &m2)
 returns m1^-1 * m2 More...
 
template<int dim>
RotMatrix< dim > InvProdInv (const RotMatrix< dim > &m1, const RotMatrix< dim > &m2)
 returns m1^-1 * m2^-1 More...
 
template<int dim>
Vector< dim > Prod (const RotMatrix< dim > &m, const Vector< dim > &v)
 returns m * v More...
 
template<int dim>
Vector< dim > InvProd (const RotMatrix< dim > &m, const Vector< dim > &v)
 returns m^-1 * v More...
 
template<int dim>
Vector< dim > Prod (const Vector< dim > &v, const RotMatrix< dim > &m)
 returns v * m More...
 
template<int dim>
Vector< dim > ProdInv (const Vector< dim > &v, const RotMatrix< dim > &m)
 return v * m^-1 More...
 
template<int dim>
RotMatrix< dim > operator* (const RotMatrix< dim > &m1, const RotMatrix< dim > &m2)
 returns m1 * m2 More...
 
template<int dim>
Vector< dim > operator* (const RotMatrix< dim > &m, const Vector< dim > &v)
 
template<int dim>
Vector< dim > operator* (const Vector< dim > &v, const RotMatrix< dim > &m)
 
template<int dim>
std::ostream & operator<< (std::ostream &os, const RotMatrix< dim > &m)
 
template<int dim>
std::istream & operator>> (std::istream &is, RotMatrix< dim > &m)
 
template<int dim>
std::ostream & operator<< (std::ostream &os, const Segment< dim > &s)
 
template<int dim>
std::istream & operator>> (std::istream &is, Segment< dim > &s)
 
template<class C >
void Shuffle (std::vector< C > &v)
 Randomly reorder the contents of a std::vector. More...
 
template std::ostream & operator<<< 3 > (std::ostream &os, const Vector< 3 > &r)
 
template std::istream & operator>>< 3 > (std::istream &is, Vector< 3 > &r)
 
template std::ostream & operator<<< 2 > (std::ostream &os, const Vector< 2 > &r)
 
template std::istream & operator>>< 2 > (std::istream &is, Vector< 2 > &r)
 
template std::ostream & operator<<< 3 > (std::ostream &os, const Point< 3 > &r)
 
template std::istream & operator>>< 3 > (std::istream &is, Point< 3 > &r)
 
template std::ostream & operator<<< 2 > (std::ostream &os, const Point< 2 > &r)
 
template std::istream & operator>>< 2 > (std::istream &is, Point< 2 > &r)
 
template std::ostream & operator<<< 3 > (std::ostream &os, const RotMatrix< 3 > &r)
 
template std::istream & operator>>< 3 > (std::istream &is, RotMatrix< 3 > &r)
 
template std::ostream & operator<<< 2 > (std::ostream &os, const RotMatrix< 2 > &r)
 
template std::istream & operator>>< 2 > (std::istream &is, RotMatrix< 2 > &r)
 
template std::ostream & operator<<< 3 > (std::ostream &os, const AxisBox< 3 > &r)
 
template std::istream & operator>>< 3 > (std::istream &is, AxisBox< 3 > &r)
 
template std::ostream & operator<<< 2 > (std::ostream &os, const AxisBox< 2 > &r)
 
template std::istream & operator>>< 2 > (std::istream &is, AxisBox< 2 > &r)
 
template std::ostream & operator<<< 3 > (std::ostream &os, const Ball< 3 > &r)
 
template std::istream & operator>>< 3 > (std::istream &is, Ball< 3 > &r)
 
template std::ostream & operator<<< 2 > (std::ostream &os, const Ball< 2 > &r)
 
template std::istream & operator>>< 2 > (std::istream &is, Ball< 2 > &r)
 
template std::ostream & operator<<< 3 > (std::ostream &os, const Segment< 3 > &r)
 
template std::istream & operator>>< 3 > (std::istream &is, Segment< 3 > &r)
 
template std::ostream & operator<<< 2 > (std::ostream &os, const Segment< 2 > &r)
 
template std::istream & operator>>< 2 > (std::istream &is, Segment< 2 > &r)
 
template std::ostream & operator<<< 3 > (std::ostream &os, const RotBox< 3 > &r)
 
template std::istream & operator>>< 3 > (std::istream &is, RotBox< 3 > &r)
 
template std::ostream & operator<<< 2 > (std::ostream &os, const RotBox< 2 > &r)
 
template std::istream & operator>>< 2 > (std::istream &is, RotBox< 2 > &r)
 
template std::ostream & operator<<< 3 > (std::ostream &os, const Polygon< 3 > &r)
 
template std::istream & operator>>< 3 > (std::istream &is, Polygon< 3 > &r)
 
void WriteCoordList (std::ostream &os, const CoordType *d, const int num)
 
void ReadCoordList (std::istream &is, CoordType *d, const int num)
 
CoordType GetEpsilon (std::istream &is)
 
template<>
std::ostream & operator<< (std::ostream &os, const Polygon< 2 > &r)
 
template<>
std::istream & operator>> (std::istream &is, Polygon< 2 > &r)
 
std::ostream & operator<< (std::ostream &os, const Quaternion &q)
 
std::istream & operator>> (std::istream &is, Quaternion &q)
 
template<class C >
std::string ToString (const C &c, std::streamsize precision=6)
 Output a WFMath type as a string. More...
 
template<class C >
void FromString (C &c, const std::string &s, std::streamsize=6)
 Parse a WFMath type from a string. More...
 
template<int dim>
std::ostream & operator<< (std::ostream &os, const Vector< dim > &v)
 
template<int dim>
std::istream & operator>> (std::istream &is, Vector< dim > &v)
 
template<>
std::ostream & operator<< (std::ostream &os, const Polygon< 2 > &r)
 
template<>
std::istream & operator>> (std::istream &is, Polygon< 2 > &r)
 
template<int dim>
std::ostream & operator<< (std::ostream &os, const Line< dim > &r)
 
TimeDiffoperator+= (TimeDiff &val, const TimeDiff &d)
 
TimeDiffoperator-= (TimeDiff &val, const TimeDiff &d)
 
TimeDiff operator+ (const TimeDiff &a, const TimeDiff &b)
 
TimeDiff operator- (const TimeDiff &a, const TimeDiff &b)
 
bool operator< (const TimeDiff &a, const TimeDiff &b)
 
bool operator== (const TimeDiff &a, const TimeDiff &b)
 
bool operator< (const TimeStamp &a, const TimeStamp &b)
 
bool operator== (const TimeStamp &a, const TimeStamp &b)
 
TimeStampoperator+= (TimeStamp &a, const TimeDiff &d)
 
TimeStampoperator-= (TimeStamp &a, const TimeDiff &d)
 
TimeStamp operator+ (const TimeStamp &a, const TimeDiff &d)
 
TimeStamp operator- (const TimeStamp &a, const TimeDiff &d)
 
TimeDiff operator- (const TimeStamp &a, const TimeStamp &b)
 
bool operator> (const TimeDiff &a, const TimeDiff &b)
 
bool operator<= (const TimeDiff &a, const TimeDiff &b)
 
bool operator>= (const TimeDiff &a, const TimeDiff &b)
 
bool operator!= (const TimeDiff &a, const TimeDiff &b)
 
TimeStamp operator+ (TimeDiff msec, const TimeStamp &a)
 
bool operator> (const TimeStamp &a, const TimeStamp &b)
 
bool operator<= (const TimeStamp &a, const TimeStamp &b)
 
bool operator>= (const TimeStamp &a, const TimeStamp &b)
 
bool operator!= (const TimeStamp &a, const TimeStamp &b)
 
CoordType Cross (const Vector< 2 > &v1, const Vector< 2 > &v2)
 2D only: get the z component of the cross product of two vectors More...
 
Vector< 3 > Cross (const Vector< 3 > &v1, const Vector< 3 > &v2)
 3D only: get the cross product of two vectors More...
 
template Vector< 3 > & operator-= (Vector< 3 > &v1, const Vector< 3 > &v2)
 
template Vector< 2 > & operator-= (Vector< 2 > &v1, const Vector< 2 > &v2)
 
template Vector< 3 > & operator+= (Vector< 3 > &v1, const Vector< 3 > &v2)
 
template Vector< 2 > & operator+= (Vector< 2 > &v1, const Vector< 2 > &v2)
 
template Vector< 3 > & operator*= (Vector< 3 > &v1, CoordType d)
 
template Vector< 2 > & operator*= (Vector< 2 > &v1, CoordType d)
 
template Vector< 3 > & operator/= (Vector< 3 > &v1, CoordType d)
 
template Vector< 2 > & operator/= (Vector< 2 > &v1, CoordType d)
 
template CoordType Dot< 3 > (const Vector< 3 > &, const Vector< 3 > &)
 
template CoordType Dot< 2 > (const Vector< 2 > &, const Vector< 2 > &)
 
template CoordType Angle< 3 > (const Vector< 3 > &, const Vector< 3 > &)
 
template Vector< 3 > operator-<3 > (const Vector< 3 > &)
 
template Vector< 3 > operator*<3 > (CoordType, const Vector< 3 > &)
 
template Vector< 2 > operator*<2 > (CoordType, const Vector< 2 > &)
 
template Vector< 3 > operator*<3 > (const Vector< 3 > &, CoordType)
 
template Vector< 2 > operator*<2 > (const Vector< 2 > &, CoordType)
 
template Vector< 3 > operator/<3 > (const Vector< 3 > &, CoordType)
 
template Vector< 2 > operator/<2 > (const Vector< 2 > &, CoordType)
 
template Vector< 3 > operator+<3 > (const Vector< 3 > &, const Vector< 3 > &)
 
template Vector< 2 > operator+<2 > (const Vector< 2 > &, const Vector< 2 > &)
 
template Vector< 3 > operator-<3 > (const Vector< 3 > &, const Vector< 3 > &)
 
template Vector< 2 > operator-<2 > (const Vector< 2 > &, const Vector< 2 > &)
 
template<int dim>
Vector< dim > & operator+= (Vector< dim > &v1, const Vector< dim > &v2)
 
template<int dim>
Vector< dim > & operator-= (Vector< dim > &v1, const Vector< dim > &v2)
 
template<int dim>
Vector< dim > & operator*= (Vector< dim > &v, CoordType d)
 
template<int dim>
Vector< dim > & operator/= (Vector< dim > &v, CoordType d)
 
template<int dim>
Vector< dim > operator+ (const Vector< dim > &v1, const Vector< dim > &v2)
 
template<int dim>
Vector< dim > operator- (const Vector< dim > &v1, const Vector< dim > &v2)
 
template<int dim>
Vector< dim > operator- (const Vector< dim > &v)
 
template<int dim>
Vector< dim > operator* (CoordType d, const Vector< dim > &v)
 
template<int dim>
Vector< dim > operator* (const Vector< dim > &v, CoordType d)
 
template<int dim>
Vector< dim > operator/ (const Vector< dim > &v, CoordType d)
 
template<int dim>
CoordType Dot (const Vector< dim > &v1, const Vector< dim > &v2)
 
template<int dim>
CoordType Angle (const Vector< dim > &v, const Vector< dim > &u)
 
template<int dim>
bool Parallel (const Vector< dim > &v1, const Vector< dim > &v2, bool &same_dir)
 Check if two vectors are parallel. More...
 
template<int dim>
bool Parallel (const Vector< dim > &v1, const Vector< dim > &v2)
 Check if two vectors are parallel. More...
 
template<int dim>
bool Perpendicular (const Vector< dim > &v1, const Vector< dim > &v2)
 Check if two vectors are perpendicular. More...
 

Detailed Description

Generic library namespace.

Timing related primitives in a portable fashion - note this is for interval / elapsed time measurement, not displaying a human readable time.

Typedef Documentation

◆ _AtlasBadParse

typedef Atlas::Message::WrongTypeException WFMath::_AtlasBadParse

Definition at line 51 of file atlasconv.h.

◆ CoordType

typedef double WFMath::CoordType

Basic floating point type.

Definition at line 140 of file const.h.

Enumeration Type Documentation

◆ Poly2ReorientType

enum WFMath::Poly2ReorientType

Definition at line 170 of file polygon.h.

Function Documentation

◆ _AddCorner() [1/2]

template<template< int > class ShapeT>
void WFMath::_AddCorner ( ShapeT< 2 > &  shape,
const Atlas::Message::ListType &  point 
)
inline

Definition at line 346 of file atlasconv.h.

◆ _AddCorner() [2/2]

template<template< int > class ShapeT>
void WFMath::_AddCorner ( ShapeT< 3 > &  shape,
const Atlas::Message::ListType &  point 
)
inline

Definition at line 335 of file atlasconv.h.

◆ _ArrayFromAtlas()

void WFMath::_ArrayFromAtlas ( CoordType array,
unsigned  len,
const AtlasInType a 
)
inline

Definition at line 88 of file atlasconv.h.

◆ _ArrayToAtlas()

AtlasOutType WFMath::_ArrayToAtlas ( const CoordType array,
unsigned  len 
)
inline

Definition at line 78 of file atlasconv.h.

◆ _CartToPolar()

void WFMath::_CartToPolar ( const CoordType in,
CoordType out 
)
inline

Definition at line 40 of file basis.h.

◆ _CartToSpherical()

void WFMath::_CartToSpherical ( const CoordType in,
CoordType out 
)
inline

Definition at line 54 of file basis.h.

◆ _CornersFromAtlas()

template<template< int > class ShapeT, int dim>
void WFMath::_CornersFromAtlas ( ShapeT< dim > &  shape,
const Atlas::Message::Element &  message 
)
inline

Definition at line 357 of file atlasconv.h.

◆ _Greater()

bool WFMath::_Greater ( CoordType  x1,
CoordType  x2,
bool  proper 
)
inline

Definition at line 45 of file intersect_decls.h.

◆ _GreaterEq()

bool WFMath::_GreaterEq ( CoordType  x1,
CoordType  x2,
bool  proper 
)
inline

Definition at line 50 of file intersect_decls.h.

◆ _Less()

bool WFMath::_Less ( CoordType  x1,
CoordType  x2,
bool  proper 
)
inline

Definition at line 35 of file intersect_decls.h.

◆ _LessEq()

bool WFMath::_LessEq ( CoordType  x1,
CoordType  x2,
bool  proper 
)
inline

Definition at line 40 of file intersect_decls.h.

◆ _ListNumCheck()

bool WFMath::_ListNumCheck ( const Atlas::Message::ListType &  list,
int  dim 
)
inline

Definition at line 324 of file atlasconv.h.

◆ _MatrixInverseImpl()

bool WFMath::_MatrixInverseImpl ( const int  size,
CoordType in,
CoordType out 
)

Definition at line 302 of file rotmatrix.cpp.

◆ _MatrixSetValsImpl()

bool WFMath::_MatrixSetValsImpl ( const int  size,
CoordType vals,
bool &  flip,
CoordType buf1,
CoordType buf2,
CoordType  precision 
)

Definition at line 160 of file rotmatrix.cpp.

◆ _PolarToCart()

void WFMath::_PolarToCart ( const CoordType in,
CoordType out 
)
inline

Definition at line 47 of file basis.h.

◆ _PolyContainsBox()

template<int dim>
bool WFMath::_PolyContainsBox ( const Poly2Orient< dim > &  orient,
const Polygon< 2 > &  poly,
const Point< dim > &  corner,
const Vector< dim > &  size,
bool  proper 
)

Definition at line 398 of file polygon_intersect.cpp.

◆ _ScaleEpsilon() [1/3]

CoordType WFMath::_ScaleEpsilon ( const CoordType x1,
const CoordType x2,
int  length,
CoordType  epsilon 
)

Definition at line 93 of file const.cpp.

◆ _ScaleEpsilon() [2/3]

double WFMath::_ScaleEpsilon ( double  x1,
double  x2,
double  epsilon 
)

Definition at line 71 of file const.cpp.

◆ _ScaleEpsilon() [3/3]

float WFMath::_ScaleEpsilon ( float  x1,
float  x2,
float  epsilon 
)

Definition at line 82 of file const.cpp.

◆ _SphericalToCart()

void WFMath::_SphericalToCart ( const CoordType in,
CoordType out 
)
inline

Definition at line 62 of file basis.h.

◆ Angle()

template<int dim>
CoordType WFMath::Angle ( const Vector< dim > &  v,
const Vector< dim > &  u 
)

Definition at line 160 of file vector_funcs.h.

◆ Barycenter() [1/2]

template<int dim, template< class, class > class container>
Point< dim > WFMath::Barycenter ( const container< Point< dim >, std::allocator< Point< dim > > > &  c)

Find the center of a set of points, all weighted equally.

Definition at line 186 of file point_funcs.h.

References Barycenter().

Referenced by Barycenter(), and WFMath::Line< dim >::getCenter().

◆ Barycenter() [2/2]

template<int dim, template< class, class > class container, template< class, class > class container2>
Point< dim > WFMath::Barycenter ( const container< Point< dim >, std::allocator< Point< dim > > > &  c,
const container2< CoordType, std::allocator< CoordType > > &  weights 
)

Find the center of a set of points with the given weights.

If the number of points and the number of weights are not equal, the excess of either is ignored. The weights (or that subset which is used, if there are more weights than points), must not sum to zero.

Definition at line 138 of file point_funcs.h.

References Barycenter(), and WFMath::Point< dim >::setValid().

◆ BoundingBox() [1/2]

template<int dim, template< class, class > class container>
AxisBox< dim > WFMath::BoundingBox ( const container< AxisBox< dim >, std::allocator< AxisBox< dim > > > &  c)

Get the axis-aligned bounding box for a set of boxes.

Definition at line 130 of file axisbox_funcs.h.

References WFMath::Point< dim >::setValid().

◆ BoundingBox() [2/2]

template<int dim, template< class, class > class container>
AxisBox< dim > WFMath::BoundingBox ( const container< Point< dim >, std::allocator< Point< dim > > > &  c)

Get the axis-aligned bounding box for a set of points.

Definition at line 158 of file axisbox_funcs.h.

References WFMath::Point< dim >::setValid().

◆ BoundingSphere()

template<int dim, template< class, class > class container>
Ball< dim > WFMath::BoundingSphere ( const container< Point< dim >, std::allocator< Point< dim > > > &  c)

get the minimal bounding sphere for a set of points

Definition at line 57 of file ball_funcs.h.

References WFMath::Point< dim >::setValid().

◆ BoundingSphereSloppy()

template<int dim, template< class, class > class container>
Ball< dim > WFMath::BoundingSphereSloppy ( const container< Point< dim >, std::allocator< Point< dim > > > &  c)

get a bounding sphere for a set of points

Definition at line 92 of file ball_funcs.h.

References Midpoint(), and WFMath::Point< dim >::setValid().

◆ Contains() [1/32]

template<int dim>
bool WFMath::Contains ( const AxisBox< dim > &  a,
const Ball< dim > &  b,
bool  proper 
)
inline

Definition at line 159 of file intersect.h.

◆ Contains() [2/32]

template<int dim>
bool WFMath::Contains ( const AxisBox< dim > &  b,
const Polygon< dim > &  p,
bool  proper 
)
inline

Definition at line 461 of file polygon_intersect.cpp.

◆ Contains() [3/32]

template<int dim>
bool WFMath::Contains ( const AxisBox< dim > &  b,
const RotBox< dim > &  r,
bool  proper 
)
inline

Definition at line 416 of file intersect.h.

◆ Contains() [4/32]

template<int dim>
bool WFMath::Contains ( const AxisBox< dim > &  b,
const Segment< dim > &  s,
bool  proper 
)
inline

Definition at line 275 of file intersect.h.

◆ Contains() [5/32]

template<int dim>
bool WFMath::Contains ( const AxisBox< dim > &  outer,
const AxisBox< dim > &  inner,
bool  proper 
)
inline

Definition at line 100 of file intersect.h.

◆ Contains() [6/32]

template<int dim>
bool WFMath::Contains ( const Ball< dim > &  b,
const AxisBox< dim > &  a,
bool  proper 
)
inline

Definition at line 145 of file intersect.h.

◆ Contains() [7/32]

template<int dim>
bool WFMath::Contains ( const Ball< dim > &  b,
const Polygon< dim > &  p,
bool  proper 
)
inline

Definition at line 505 of file polygon_intersect.cpp.

◆ Contains() [8/32]

template<int dim>
bool WFMath::Contains ( const Ball< dim > &  b,
const RotBox< dim > &  r,
bool  proper 
)
inline

Definition at line 438 of file intersect.h.

◆ Contains() [9/32]

template<int dim>
bool WFMath::Contains ( const Ball< dim > &  b,
const Segment< dim > &  s,
bool  proper 
)
inline

Definition at line 307 of file intersect.h.

◆ Contains() [10/32]

template<int dim>
bool WFMath::Contains ( const Ball< dim > &  outer,
const Ball< dim > &  inner,
bool  proper 
)
inline

Definition at line 179 of file intersect.h.

◆ Contains() [11/32]

template<int dim>
bool WFMath::Contains ( const Point< dim > &  p,
const AxisBox< dim > &  b,
bool  proper 
)
inline

Definition at line 83 of file intersect.h.

◆ Contains() [12/32]

template<int dim>
bool WFMath::Contains ( const Point< dim > &  p,
const Ball< dim > &  b,
bool  proper 
)
inline

Definition at line 120 of file intersect.h.

◆ Contains() [13/32]

template<int dim>
bool WFMath::Contains ( const Point< dim > &  p,
const Polygon< dim > &  r,
bool  proper 
)
inline

Definition at line 353 of file polygon_intersect.cpp.

◆ Contains() [14/32]

template<int dim>
bool WFMath::Contains ( const Point< dim > &  p,
const RotBox< dim > &  r,
bool  proper 
)
inline

Definition at line 390 of file intersect.h.

◆ Contains() [15/32]

template<int dim>
bool WFMath::Contains ( const Point< dim > &  p,
const Segment< dim > &  s,
bool  proper 
)
inline

Definition at line 210 of file intersect.h.

◆ Contains() [16/32]

template<int dim>
bool WFMath::Contains ( const Point< dim > &  p1,
const Point< dim > &  p2,
bool  proper 
)
inline

Definition at line 65 of file intersect.h.

◆ Contains() [17/32]

template<int dim>
bool WFMath::Contains ( const Polygon< dim > &  outer,
const Polygon< dim > &  inner,
bool  proper 
)
inline

Definition at line 668 of file polygon_intersect.cpp.

◆ Contains() [18/32]

template<int dim>
bool WFMath::Contains ( const Polygon< dim > &  p,
const AxisBox< dim > &  b,
bool  proper 
)
inline

Definition at line 455 of file polygon_intersect.cpp.

◆ Contains() [19/32]

template<int dim>
bool WFMath::Contains ( const Polygon< dim > &  p,
const Ball< dim > &  b,
bool  proper 
)
inline

Definition at line 488 of file polygon_intersect.cpp.

◆ Contains() [20/32]

template<int dim>
bool WFMath::Contains ( const Polygon< dim > &  p,
const RotBox< dim > &  r,
bool  proper 
)
inline

Definition at line 623 of file polygon_intersect.cpp.

◆ Contains() [21/32]

template<int dim>
bool WFMath::Contains ( const Polygon< dim > &  p,
const Segment< dim > &  s,
bool  proper 
)
inline

Definition at line 555 of file polygon_intersect.cpp.

◆ Contains() [22/32]

template<int dim>
bool WFMath::Contains ( const RotBox< dim > &  outer,
const RotBox< dim > &  inner,
bool  proper 
)
inline

Definition at line 484 of file intersect.h.

◆ Contains() [23/32]

template<int dim>
bool WFMath::Contains ( const RotBox< dim > &  r,
const AxisBox< dim > &  b,
bool  proper 
)
inline

Definition at line 406 of file intersect.h.

◆ Contains() [24/32]

template<int dim>
bool WFMath::Contains ( const RotBox< dim > &  r,
const Ball< dim > &  b,
bool  proper 
)
inline

Definition at line 430 of file intersect.h.

◆ Contains() [25/32]

template<int dim>
bool WFMath::Contains ( const RotBox< dim > &  r,
const Polygon< dim > &  p,
bool  proper 
)
inline

Definition at line 632 of file polygon_intersect.cpp.

◆ Contains() [26/32]

template<int dim>
bool WFMath::Contains ( const RotBox< dim > &  r,
const Segment< dim > &  s,
bool  proper 
)
inline

Definition at line 456 of file intersect.h.

◆ Contains() [27/32]

template<int dim, class S >
bool WFMath::Contains ( const S &  s,
const Point< dim > &  p,
bool  proper 
)
inline

Definition at line 59 of file intersect.h.

◆ Contains() [28/32]

template<int dim>
bool WFMath::Contains ( const Segment< dim > &  s,
const AxisBox< dim > &  b,
bool  proper 
)
inline

Definition at line 254 of file intersect.h.

◆ Contains() [29/32]

template<int dim>
bool WFMath::Contains ( const Segment< dim > &  s,
const Ball< dim > &  b,
bool  proper 
)
inline

Definition at line 313 of file intersect.h.

◆ Contains() [30/32]

template<int dim>
bool WFMath::Contains ( const Segment< dim > &  s,
const Polygon< dim > &  p,
bool  proper 
)
inline

Definition at line 571 of file polygon_intersect.cpp.

◆ Contains() [31/32]

template<int dim>
bool WFMath::Contains ( const Segment< dim > &  s,
const RotBox< dim > &  r,
bool  proper 
)
inline

Definition at line 466 of file intersect.h.

◆ Contains() [32/32]

template<int dim>
bool WFMath::Contains ( const Segment< dim > &  s1,
const Segment< dim > &  s2,
bool  proper 
)
inline

Definition at line 361 of file intersect.h.

◆ Contains< 2 >() [1/10]

template<>
bool WFMath::Contains< 2 > ( const AxisBox< 2 > &  b,
const Polygon< 2 > &  p,
bool  proper 
)

Definition at line 1394 of file polygon_intersect.cpp.

◆ Contains< 2 >() [2/10]

template<>
bool WFMath::Contains< 2 > ( const Ball< 2 > &  b,
const Polygon< 2 > &  p,
bool  proper 
)

Definition at line 1444 of file polygon_intersect.cpp.

◆ Contains< 2 >() [3/10]

template<>
bool WFMath::Contains< 2 > ( const Point< 2 > &  p,
const Polygon< 2 > &  r,
bool  proper 
)

Definition at line 1223 of file polygon_intersect.cpp.

◆ Contains< 2 >() [4/10]

template<>
bool WFMath::Contains< 2 > ( const Polygon< 2 > &  outer,
const Polygon< 2 > &  inner,
bool  proper 
)

Definition at line 1813 of file polygon_intersect.cpp.

◆ Contains< 2 >() [5/10]

template<>
bool WFMath::Contains< 2 > ( const Polygon< 2 > &  p,
const AxisBox< 2 > &  b,
bool  proper 
)

Definition at line 1307 of file polygon_intersect.cpp.

◆ Contains< 2 >() [6/10]

template<>
bool WFMath::Contains< 2 > ( const Polygon< 2 > &  p,
const Ball< 2 > &  b,
bool  proper 
)

Definition at line 1424 of file polygon_intersect.cpp.

◆ Contains< 2 >() [7/10]

template<>
bool WFMath::Contains< 2 > ( const Polygon< 2 > &  p,
const RotBox< 2 > &  r,
bool  proper 
)

Definition at line 1664 of file polygon_intersect.cpp.

◆ Contains< 2 >() [8/10]

template<>
bool WFMath::Contains< 2 > ( const Polygon< 2 > &  p,
const Segment< 2 > &  s,
bool  proper 
)

Definition at line 1479 of file polygon_intersect.cpp.

◆ Contains< 2 >() [9/10]

template<>
bool WFMath::Contains< 2 > ( const RotBox< 2 > &  r,
const Polygon< 2 > &  p,
bool  proper 
)

Definition at line 1775 of file polygon_intersect.cpp.

◆ Contains< 2 >() [10/10]

template<>
bool WFMath::Contains< 2 > ( const Segment< 2 > &  s,
const Polygon< 2 > &  p,
bool  proper 
)

Definition at line 1559 of file polygon_intersect.cpp.

◆ Cross() [1/2]

CoordType WFMath::Cross ( const Vector< 2 > &  v1,
const Vector< 2 > &  v2 
)

2D only: get the z component of the cross product of two vectors

Definition at line 102 of file vector.cpp.

Referenced by WFMath::Quaternion::rotation().

◆ Cross() [2/2]

Vector< 3 > WFMath::Cross ( const Vector< 3 > &  v1,
const Vector< 3 > &  v2 
)

3D only: get the cross product of two vectors

Definition at line 109 of file vector.cpp.

◆ Distance()

template<int dim>
CoordType WFMath::Distance ( const Point< dim > &  p1,
const Point< dim > &  p2 
)

Definition at line 55 of file point.h.

◆ Dot()

template<int dim>
CoordType WFMath::Dot ( const Vector< dim > &  v1,
const Vector< dim > &  v2 
)

Definition at line 206 of file vector_funcs.h.

◆ DoubleClamp()

double WFMath::DoubleClamp ( double  val,
double  min,
double  max 
)
inline

Definition at line 179 of file const.h.

◆ DoubleMax()

double WFMath::DoubleMax ( double  a,
double  b 
)
inline

Definition at line 175 of file const.h.

◆ DoubleMin()

double WFMath::DoubleMin ( double  a,
double  b 
)
inline

Definition at line 177 of file const.h.

◆ Equal() [1/3]

template<class C >
bool WFMath::Equal ( const C &  c1,
const C &  c2,
CoordType  epsilon = numeric_constants<CoordType>::epsilon() 
)
inline

Test for equality up to precision epsilon.

Returns true if the difference between the numbers is less than epsilon. Note that epsilon is multiplied by 2 raised to the power of the exponent of the smaller number. So, for example, Equal(0.00010000, 0.00010002, 1.0e-4) will not compare equal, but Equal(0.00010000, 0.00010002, 1.0e-3) will.

Definition at line 158 of file const.h.

◆ Equal() [2/3]

bool WFMath::Equal ( double  x1,
double  x2,
double  epsilon 
)

Definition at line 55 of file const.cpp.

◆ Equal() [3/3]

bool WFMath::Equal ( float  x1,
float  x2,
float  epsilon 
)

Definition at line 63 of file const.cpp.

◆ Factorial()

template<typename FloatT >
FloatT WFMath::Factorial ( unsigned int  n)

Gives n!

Definition at line 141 of file probability.cpp.

References LogGamma().

◆ FloatClamp()

CoordType WFMath::FloatClamp ( CoordType  val,
CoordType  min,
CoordType  max 
)
inline

Definition at line 172 of file const.h.

◆ FloatMax()

CoordType WFMath::FloatMax ( CoordType  a,
CoordType  b 
)
inline

Definition at line 168 of file const.h.

◆ FloatMin()

CoordType WFMath::FloatMin ( CoordType  a,
CoordType  b 
)
inline

Definition at line 170 of file const.h.

◆ FromString()

template<class C >
void WFMath::FromString ( C &  c,
const std::string &  s,
std::streamsize  = 6 
)
inline

Parse a WFMath type from a string.

This uses operator>>() in its backend.

Definition at line 110 of file stream.h.

◆ Gamma()

template<typename FloatT >
FloatT WFMath::Gamma ( FloatT  z)

Euler's Gamma function.

Definition at line 173 of file probability.cpp.

References LogGamma(), and WFMath::numeric_constants< FloatType >::pi().

◆ Gaussian()

template<typename FloatT >
FloatT WFMath::Gaussian ( FloatT  mean,
FloatT  stddev,
FloatT  val 
)

Gives the value of the Gaussian distribution at position val.

Definition at line 78 of file probability.cpp.

References WFMath::numeric_constants< FloatType >::sqrt2(), and WFMath::numeric_constants< FloatType >::sqrt_pi().

Referenced by GaussianConditional().

◆ GaussianConditional()

template<typename FloatT >
FloatT WFMath::GaussianConditional ( FloatT  mean,
FloatT  stddev,
FloatT  val 
)

Gives the conditional probability of the Gaussian distribution at position val.

The probability that a Gaussian random variable will fall between val and val + delta, given that it is already known to be not less than val, is given by this function multiplied by delta (for small delta).

Definition at line 51 of file probability.cpp.

References Gaussian().

◆ GetEpsilon()

CoordType WFMath::GetEpsilon ( std::istream &  is)

Definition at line 263 of file stream.cpp.

◆ Intersect() [1/22]

template<int dim>
bool WFMath::Intersect ( const AxisBox< dim > &  b,
const Point< dim > &  p,
bool  proper 
)
inline

Definition at line 73 of file intersect.h.

◆ Intersect() [2/22]

template<int dim>
bool WFMath::Intersect ( const AxisBox< dim > &  b1,
const AxisBox< dim > &  b2,
bool  proper 
)
inline

Definition at line 89 of file intersect.h.

◆ Intersect() [3/22]

template<int dim>
bool WFMath::Intersect ( const Ball< dim > &  b,
const AxisBox< dim > &  a,
bool  proper 
)
inline

Definition at line 126 of file intersect.h.

◆ Intersect() [4/22]

template<int dim>
bool WFMath::Intersect ( const Ball< dim > &  b,
const Point< dim > &  p,
bool  proper 
)
inline

Definition at line 113 of file intersect.h.

◆ Intersect() [5/22]

template<int dim>
bool WFMath::Intersect ( const Ball< dim > &  b1,
const Ball< dim > &  b2,
bool  proper 
)
inline

Definition at line 170 of file intersect.h.

◆ Intersect() [6/22]

template<int dim>
bool WFMath::Intersect ( const Point< dim > &  p1,
const Point< dim > &  p2,
bool  proper 
)
inline

Definition at line 53 of file intersect.h.

◆ Intersect() [7/22]

template<int dim>
int WFMath::Intersect ( const Poly2Orient< dim > &  o1,
const Poly2Orient< dim > &  o2,
Poly2OrientIntersectData data 
)

Definition at line 138 of file polygon_intersect.cpp.

◆ Intersect() [8/22]

template<int dim>
bool WFMath::Intersect ( const Polygon< dim > &  p,
const AxisBox< dim > &  b,
bool  proper 
)

Definition at line 371 of file polygon_intersect.cpp.

◆ Intersect() [9/22]

template<int dim>
bool WFMath::Intersect ( const Polygon< dim > &  p,
const Ball< dim > &  b,
bool  proper 
)
inline

Definition at line 471 of file polygon_intersect.cpp.

◆ Intersect() [10/22]

template<int dim>
bool WFMath::Intersect ( const Polygon< dim > &  p,
const RotBox< dim > &  r,
bool  proper 
)

Definition at line 590 of file polygon_intersect.cpp.

◆ Intersect() [11/22]

template<int dim>
bool WFMath::Intersect ( const Polygon< dim > &  p,
const Segment< dim > &  s,
bool  proper 
)

Definition at line 526 of file polygon_intersect.cpp.

◆ Intersect() [12/22]

template<int dim>
bool WFMath::Intersect ( const Polygon< dim > &  p1,
const Polygon< dim > &  p2,
bool  proper 
)
inline

Definition at line 654 of file polygon_intersect.cpp.

◆ Intersect() [13/22]

template<int dim>
bool WFMath::Intersect ( const Polygon< dim > &  r,
const Point< dim > &  p,
bool  proper 
)
inline

Definition at line 344 of file polygon_intersect.cpp.

◆ Intersect() [14/22]

template<int dim>
bool WFMath::Intersect ( const RotBox< dim > &  r,
const Ball< dim > &  b,
bool  proper 
)
inline

Definition at line 422 of file intersect.h.

◆ Intersect() [15/22]

template<int dim>
bool WFMath::Intersect ( const RotBox< dim > &  r,
const Point< dim > &  p,
bool  proper 
)
inline

Definition at line 369 of file intersect.h.

◆ Intersect() [16/22]

template<int dim>
bool WFMath::Intersect ( const RotBox< dim > &  r,
const Segment< dim > &  s,
bool  proper 
)
inline

Definition at line 446 of file intersect.h.

◆ Intersect() [17/22]

template<int dim>
bool WFMath::Intersect ( const RotBox< dim > &  r1,
const RotBox< dim > &  r2,
bool  proper 
)
inline

Definition at line 476 of file intersect.h.

◆ Intersect() [18/22]

template<class S1 , class S2 >
bool WFMath::Intersect ( const S1 &  s1,
const S2 &  s2,
bool  proper 
)
inline

Definition at line 45 of file intersect.h.

◆ Intersect() [19/22]

template<int dim>
bool WFMath::Intersect ( const Segment< dim > &  s,
const AxisBox< dim > &  b,
bool  proper 
)

Definition at line 216 of file intersect.h.

◆ Intersect() [20/22]

template<int dim>
bool WFMath::Intersect ( const Segment< dim > &  s,
const Ball< dim > &  b,
bool  proper 
)

Definition at line 281 of file intersect.h.

◆ Intersect() [21/22]

template<int dim>
bool WFMath::Intersect ( const Segment< dim > &  s,
const Point< dim > &  p,
bool  proper 
)
inline

Definition at line 194 of file intersect.h.

◆ Intersect() [22/22]

template<int dim>
bool WFMath::Intersect ( const Segment< dim > &  s1,
const Segment< dim > &  s2,
bool  proper 
)

Definition at line 319 of file intersect.h.

◆ Intersect< 2 >() [1/7]

template<>
bool WFMath::Intersect< 2 > ( const Polygon< 2 > &  p,
const AxisBox< 2 > &  b,
bool  proper 
)

Definition at line 1236 of file polygon_intersect.cpp.

◆ Intersect< 2 >() [2/7]

template<>
bool WFMath::Intersect< 2 > ( const Polygon< 2 > &  p,
const Ball< 2 > &  b,
bool  proper 
)

Definition at line 1404 of file polygon_intersect.cpp.

◆ Intersect< 2 >() [3/7]

template<>
bool WFMath::Intersect< 2 > ( const Polygon< 2 > &  p,
const RotBox< 2 > &  r,
bool  proper 
)

Definition at line 1569 of file polygon_intersect.cpp.

◆ Intersect< 2 >() [4/7]

template<>
bool WFMath::Intersect< 2 > ( const Polygon< 2 > &  p,
const Segment< 2 > &  s,
bool  proper 
)

Definition at line 1456 of file polygon_intersect.cpp.

◆ Intersect< 2 >() [5/7]

template<>
bool WFMath::Intersect< 2 > ( const Polygon< 2 > &  p1,
const Polygon< 2 > &  p2,
bool  proper 
)

Definition at line 1785 of file polygon_intersect.cpp.

◆ Intersect< 2 >() [6/7]

template<>
bool WFMath::Intersect< 2 > ( const Polygon< 2 > &  r,
const Point< 2 > &  p,
bool  proper 
)

Definition at line 1196 of file polygon_intersect.cpp.

◆ Intersect< 2 >() [7/7]

template<>
bool WFMath::Intersect< 2 > ( const RotBox< 2 > &  r,
const AxisBox< 2 > &  b,
bool  proper 
)

Definition at line 68 of file intersect.cpp.

◆ Intersect< 3 >()

template<>
bool WFMath::Intersect< 3 > ( const RotBox< 3 > &  r,
const AxisBox< 3 > &  b,
bool  proper 
)

Definition at line 113 of file intersect.cpp.

◆ Intersection()

template<int dim>
bool WFMath::Intersection ( const AxisBox< dim > &  a1,
const AxisBox< dim > &  a2,
AxisBox< dim > &  out 
)

Definition at line 40 of file axisbox_funcs.h.

◆ IntToString() [1/6]

std::string WFMath::IntToString ( int  val)
inline

Definition at line 36 of file int_to_string.h.

◆ IntToString() [2/6]

std::string WFMath::IntToString ( long  val)

Definition at line 67 of file int_to_string.cpp.

◆ IntToString() [3/6]

std::string WFMath::IntToString ( short  val)
inline

Definition at line 38 of file int_to_string.h.

◆ IntToString() [4/6]

std::string WFMath::IntToString ( unsigned int  val)
inline

Definition at line 35 of file int_to_string.h.

◆ IntToString() [5/6]

std::string WFMath::IntToString ( unsigned long  val)

Definition at line 41 of file int_to_string.cpp.

◆ IntToString() [6/6]

std::string WFMath::IntToString ( unsigned short  val)
inline

Definition at line 37 of file int_to_string.h.

◆ InvProd() [1/2]

template<int dim>
Vector< dim > WFMath::InvProd ( const RotMatrix< dim > &  m,
const Vector< dim > &  v 
)
inline

returns m^-1 * v

Definition at line 177 of file rotmatrix_funcs.h.

◆ InvProd() [2/2]

template<int dim>
RotMatrix< dim > WFMath::InvProd ( const RotMatrix< dim > &  m1,
const RotMatrix< dim > &  m2 
)
inline

returns m1^-1 * m2

Definition at line 116 of file rotmatrix_funcs.h.

Referenced by Prod().

◆ InvProdInv()

template<int dim>
RotMatrix< dim > WFMath::InvProdInv ( const RotMatrix< dim > &  m1,
const RotMatrix< dim > &  m2 
)
inline

returns m1^-1 * m2^-1

Definition at line 138 of file rotmatrix_funcs.h.

◆ LogFactorial()

template<typename FloatT >
FloatT WFMath::LogFactorial ( unsigned int  n)

Gives the natural log of n!

Definition at line 157 of file probability.cpp.

References LogGamma().

◆ LogGamma()

template<typename FloatT >
FloatT WFMath::LogGamma ( FloatT  z)

The natural log of Euler's Gamma function.

Definition at line 184 of file probability.cpp.

References WFMath::numeric_constants< FloatType >::log2(), and WFMath::numeric_constants< FloatType >::log_pi().

Referenced by Factorial(), Gamma(), and LogFactorial().

◆ Midpoint()

template<int dim>
Point< dim > WFMath::Midpoint ( const Point< dim > &  p1,
const Point< dim > &  p2,
CoordType  dist = 0.5 
)
inline

The default value of 0.5 for dist gives the midpoint. A value of 0 gives p1, and 1 gives p2. Values of dist outside the [0, 1] range are allowed, and give points on the line which are not on the segment bounded by p1 and p2.

Definition at line 219 of file point_funcs.h.

Referenced by BoundingSphereSloppy().

◆ operator!=() [1/2]

bool WFMath::operator!= ( const TimeDiff a,
const TimeDiff b 
)
inline

Definition at line 109 of file timestamp.h.

◆ operator!=() [2/2]

bool WFMath::operator!= ( const TimeStamp a,
const TimeStamp b 
)
inline

Definition at line 168 of file timestamp.h.

◆ operator*() [1/5]

template<int dim>
Vector< dim > WFMath::operator* ( const RotMatrix< dim > &  m,
const Vector< dim > &  v 
)
inline

Definition at line 212 of file rotmatrix_funcs.h.

◆ operator*() [2/5]

template<int dim>
RotMatrix< dim > WFMath::operator* ( const RotMatrix< dim > &  m1,
const RotMatrix< dim > &  m2 
)
inline

returns m1 * m2

Definition at line 206 of file rotmatrix_funcs.h.

References Prod().

◆ operator*() [3/5]

template<int dim>
Vector< dim > WFMath::operator* ( const Vector< dim > &  v,
const RotMatrix< dim > &  m 
)
inline

Definition at line 218 of file rotmatrix_funcs.h.

◆ operator*() [4/5]

template<int dim>
Vector< dim > WFMath::operator* ( const Vector< dim > &  v,
CoordType  d 
)
inline

Definition at line 420 of file vector.h.

◆ operator*() [5/5]

template<int dim>
Vector< dim > WFMath::operator* ( CoordType  d,
const Vector< dim > &  v 
)
inline

Definition at line 430 of file vector.h.

◆ operator*=()

template<int dim>
Vector< dim > & WFMath::operator*= ( Vector< dim > &  v,
CoordType  d 
)

Definition at line 103 of file vector_funcs.h.

◆ operator+() [1/6]

template<int dim>
Point< dim > WFMath::operator+ ( const Point< dim > &  c,
const Vector< dim > &  v 
)
inline

Definition at line 278 of file point.h.

◆ operator+() [2/6]

TimeDiff WFMath::operator+ ( const TimeDiff a,
const TimeDiff b 
)

Definition at line 110 of file timestamp.cpp.

◆ operator+() [3/6]

TimeStamp WFMath::operator+ ( const TimeStamp a,
const TimeDiff d 
)

Definition at line 212 of file timestamp.cpp.

◆ operator+() [4/6]

template<int dim>
Point< dim > WFMath::operator+ ( const Vector< dim > &  v,
const Point< dim > &  c 
)
inline

Definition at line 288 of file point.h.

◆ operator+() [5/6]

template<int dim>
Vector< dim > WFMath::operator+ ( const Vector< dim > &  v1,
const Vector< dim > &  v2 
)
inline

Definition at line 400 of file vector.h.

◆ operator+() [6/6]

TimeStamp WFMath::operator+ ( TimeDiff  msec,
const TimeStamp a 
)
inline

Definition at line 163 of file timestamp.h.

◆ operator+=() [1/4]

template<int dim>
Point< dim > & WFMath::operator+= ( Point< dim > &  p,
const Vector< dim > &  v 
)
inline

Definition at line 100 of file point_funcs.h.

◆ operator+=() [2/4]

TimeDiff & WFMath::operator+= ( TimeDiff val,
const TimeDiff d 
)

Definition at line 86 of file timestamp.cpp.

◆ operator+=() [3/4]

TimeStamp & WFMath::operator+= ( TimeStamp a,
const TimeDiff d 
)

Definition at line 190 of file timestamp.cpp.

◆ operator+=() [4/4]

template<int dim>
Vector< dim > & WFMath::operator+= ( Vector< dim > &  v1,
const Vector< dim > &  v2 
)

Definition at line 79 of file vector_funcs.h.

◆ operator-() [1/7]

template<int dim>
Point< dim > WFMath::operator- ( const Point< dim > &  c,
const Vector< dim > &  v 
)
inline

Definition at line 298 of file point.h.

◆ operator-() [2/7]

template<int dim>
Vector< dim > WFMath::operator- ( const Point< dim > &  c1,
const Point< dim > &  c2 
)
inline

Definition at line 86 of file point_funcs.h.

◆ operator-() [3/7]

TimeDiff WFMath::operator- ( const TimeDiff a,
const TimeDiff b 
)

Definition at line 115 of file timestamp.cpp.

◆ operator-() [4/7]

TimeStamp WFMath::operator- ( const TimeStamp a,
const TimeDiff d 
)

Definition at line 218 of file timestamp.cpp.

◆ operator-() [5/7]

TimeDiff WFMath::operator- ( const TimeStamp a,
const TimeStamp b 
)

Definition at line 224 of file timestamp.cpp.

◆ operator-() [6/7]

template<int dim>
Vector< dim > WFMath::operator- ( const Vector< dim > &  v)

Definition at line 124 of file vector_funcs.h.

◆ operator-() [7/7]

template<int dim>
Vector< dim > WFMath::operator- ( const Vector< dim > &  v1,
const Vector< dim > &  v2 
)
inline

Definition at line 410 of file vector.h.

◆ operator-=() [1/4]

template<int dim>
Point< dim > & WFMath::operator-= ( Point< dim > &  p,
const Vector< dim > &  v 
)
inline

Definition at line 112 of file point_funcs.h.

◆ operator-=() [2/4]

TimeDiff & WFMath::operator-= ( TimeDiff val,
const TimeDiff d 
)

Definition at line 98 of file timestamp.cpp.

◆ operator-=() [3/4]

TimeStamp & WFMath::operator-= ( TimeStamp a,
const TimeDiff d 
)

Definition at line 201 of file timestamp.cpp.

◆ operator-=() [4/4]

template<int dim>
Vector< dim > & WFMath::operator-= ( Vector< dim > &  v1,
const Vector< dim > &  v2 
)

Definition at line 91 of file vector_funcs.h.

◆ operator/()

template<int dim>
Vector< dim > WFMath::operator/ ( const Vector< dim > &  v,
CoordType  d 
)
inline

Definition at line 440 of file vector.h.

◆ operator/=()

template<int dim>
Vector< dim > & WFMath::operator/= ( Vector< dim > &  v,
CoordType  d 
)

Definition at line 113 of file vector_funcs.h.

◆ operator<() [1/2]

bool WFMath::operator< ( const TimeDiff a,
const TimeDiff b 
)

Definition at line 120 of file timestamp.cpp.

◆ operator<() [2/2]

bool WFMath::operator< ( const TimeStamp a,
const TimeStamp b 
)

Definition at line 176 of file timestamp.cpp.

◆ operator<<() [1/13]

template<int dim>
std::ostream & WFMath::operator<< ( std::ostream &  os,
const AxisBox< dim > &  m 
)
inline

Definition at line 188 of file stream.h.

◆ operator<<() [2/13]

template<int dim>
std::ostream & WFMath::operator<< ( std::ostream &  os,
const Ball< dim > &  m 
)
inline

Definition at line 214 of file stream.h.

◆ operator<<() [3/13]

template<int dim>
std::ostream & WFMath::operator<< ( std::ostream &  os,
const Line< dim > &  r 
)
inline

Definition at line 307 of file stream.h.

◆ operator<<() [4/13]

template<int dim>
std::ostream & WFMath::operator<< ( std::ostream &  os,
const Point< dim > &  m 
)
inline

Definition at line 173 of file stream.h.

◆ operator<<() [5/13]

template<>
std::ostream & WFMath::operator<< ( std::ostream &  os,
const Polygon< 2 > &  r 
)

Definition at line 278 of file stream.cpp.

◆ operator<<() [6/13]

template<>
std::ostream & WFMath::operator<< ( std::ostream &  os,
const Polygon< 2 > &  r 
)

Definition at line 278 of file stream.cpp.

◆ operator<<() [7/13]

template<int dim>
std::ostream & WFMath::operator<< ( std::ostream &  os,
const Polygon< dim > &  r 
)
inline

Definition at line 186 of file stream.cpp.

◆ operator<<() [8/13]

std::ostream & WFMath::operator<< ( std::ostream &  os,
const Quaternion q 
)

Definition at line 325 of file stream.cpp.

◆ operator<<() [9/13]

template<int dim>
std::ostream & WFMath::operator<< ( std::ostream &  os,
const RotBox< dim > &  r 
)
inline

Definition at line 267 of file stream.h.

◆ operator<<() [10/13]

template<int dim>
std::ostream & WFMath::operator<< ( std::ostream &  os,
const RotMatrix< dim > &  m 
)
inline

Definition at line 136 of file stream.h.

◆ operator<<() [11/13]

template<int dim>
std::ostream & WFMath::operator<< ( std::ostream &  os,
const Segment< dim > &  s 
)
inline

Definition at line 241 of file stream.h.

◆ operator<<() [12/13]

template<int dim>
std::ostream & WFMath::operator<< ( std::ostream &  os,
const Vector< dim > &  v 
)
inline

Definition at line 121 of file stream.h.

◆ operator<<() [13/13]

std::ostream & WFMath::operator<< ( std::ostream &  os,
MTRand const &  mtrand 
)

Definition at line 360 of file stream.cpp.

◆ operator<=() [1/2]

bool WFMath::operator<= ( const TimeDiff a,
const TimeDiff b 
)
inline

Definition at line 107 of file timestamp.h.

◆ operator<=() [2/2]

bool WFMath::operator<= ( const TimeStamp a,
const TimeStamp b 
)
inline

Definition at line 166 of file timestamp.h.

◆ operator==() [1/2]

bool WFMath::operator== ( const TimeDiff a,
const TimeDiff b 
)

Definition at line 125 of file timestamp.cpp.

◆ operator==() [2/2]

bool WFMath::operator== ( const TimeStamp a,
const TimeStamp b 
)

Definition at line 184 of file timestamp.cpp.

◆ operator>() [1/2]

bool WFMath::operator> ( const TimeDiff a,
const TimeDiff b 
)
inline

Definition at line 106 of file timestamp.h.

◆ operator>() [2/2]

bool WFMath::operator> ( const TimeStamp a,
const TimeStamp b 
)
inline

Definition at line 165 of file timestamp.h.

◆ operator>=() [1/2]

bool WFMath::operator>= ( const TimeDiff a,
const TimeDiff b 
)
inline

Definition at line 108 of file timestamp.h.

◆ operator>=() [2/2]

bool WFMath::operator>= ( const TimeStamp a,
const TimeStamp b 
)
inline

Definition at line 167 of file timestamp.h.

◆ operator>>() [1/12]

template<int dim>
std::istream & WFMath::operator>> ( std::istream &  is,
AxisBox< dim > &  m 
)
inline

Definition at line 194 of file stream.h.

◆ operator>>() [2/12]

template<int dim>
std::istream & WFMath::operator>> ( std::istream &  is,
Ball< dim > &  m 
)
inline

Definition at line 221 of file stream.h.

◆ operator>>() [3/12]

std::istream & WFMath::operator>> ( std::istream &  is,
MTRand mtrand 
)

Definition at line 366 of file stream.cpp.

◆ operator>>() [4/12]

template<int dim>
std::istream & WFMath::operator>> ( std::istream &  is,
Point< dim > &  m 
)
inline

Definition at line 180 of file stream.h.

◆ operator>>() [5/12]

template<>
std::istream & WFMath::operator>> ( std::istream &  is,
Polygon< 2 > &  r 
)

Definition at line 297 of file stream.cpp.

◆ operator>>() [6/12]

template<>
std::istream & WFMath::operator>> ( std::istream &  is,
Polygon< 2 > &  r 
)

Definition at line 297 of file stream.cpp.

◆ operator>>() [7/12]

template<int dim>
std::istream & WFMath::operator>> ( std::istream &  is,
Polygon< dim > &  r 
)

Definition at line 68 of file stream.cpp.

◆ operator>>() [8/12]

std::istream & WFMath::operator>> ( std::istream &  is,
Quaternion q 
)

Definition at line 330 of file stream.cpp.

◆ operator>>() [9/12]

template<int dim>
std::istream & WFMath::operator>> ( std::istream &  is,
RotBox< dim > &  r 
)
inline

Definition at line 275 of file stream.h.

◆ operator>>() [10/12]

template<int dim>
std::istream & WFMath::operator>> ( std::istream &  is,
RotMatrix< dim > &  m 
)
inline

Definition at line 149 of file stream.h.

◆ operator>>() [11/12]

template<int dim>
std::istream & WFMath::operator>> ( std::istream &  is,
Segment< dim > &  s 
)
inline

Definition at line 247 of file stream.h.

◆ operator>>() [12/12]

template<int dim>
std::istream & WFMath::operator>> ( std::istream &  is,
Vector< dim > &  v 
)
inline

Definition at line 128 of file stream.h.

◆ Parallel() [1/2]

template<int dim>
bool WFMath::Parallel ( const Vector< dim > &  v1,
const Vector< dim > &  v2 
)
inline

Check if two vectors are parallel.

Convienience wrapper if you don't care about same_dir

Definition at line 462 of file vector.h.

References Parallel().

◆ Parallel() [2/2]

template<int dim>
bool WFMath::Parallel ( const Vector< dim > &  v1,
const Vector< dim > &  v2,
bool &  same_dir 
)
inline

Check if two vectors are parallel.

Returns true if the vectors are parallel. For parallel vectors, same_dir is set to true if they point the same direction, and false if they point opposite directions

Definition at line 450 of file vector.h.

References Parallel(), and WFMath::Vector< dim >::sqrMag().

Referenced by Parallel().

◆ Perpendicular()

template<int dim>
bool WFMath::Perpendicular ( const Vector< dim > &  v1,
const Vector< dim > &  v2 
)

Check if two vectors are perpendicular.

Definition at line 233 of file vector_funcs.h.

References Perpendicular().

Referenced by Perpendicular().

◆ Poisson()

template<typename FloatT >
FloatT WFMath::Poisson ( FloatT  mean,
unsigned int  step 
)

Gives the value of the Poisson distribution at position step.

Definition at line 109 of file probability.cpp.

Referenced by PoissonConditional().

◆ PoissonConditional()

template<typename FloatT >
FloatT WFMath::PoissonConditional ( FloatT  mean,
unsigned int  step 
)

Gives the conditional probability of the Poisson distribution at position step.

Returns the probability that a Poisson random variable will have value step, given that it is already known not to be less than step.

Definition at line 90 of file probability.cpp.

References Poisson().

◆ PolyPolyContains()

bool WFMath::PolyPolyContains ( const Polygon< 2 > &  outer,
const Polygon< 2 > &  inner,
int  intersect_dim,
const Poly2OrientIntersectData data,
bool  proper 
)

Definition at line 1133 of file polygon_intersect.cpp.

◆ PolyPolyIntersect()

bool WFMath::PolyPolyIntersect ( const Polygon< 2 > &  poly1,
const Polygon< 2 > &  poly2,
int  intersect_dim,
const Poly2OrientIntersectData data,
bool  proper 
)

Definition at line 991 of file polygon_intersect.cpp.

◆ Prod() [1/3]

template<int dim>
Vector< dim > WFMath::Prod ( const RotMatrix< dim > &  m,
const Vector< dim > &  v 
)
inline

returns m * v

Definition at line 160 of file rotmatrix_funcs.h.

◆ Prod() [2/3]

template<int dim>
RotMatrix< dim > WFMath::Prod ( const RotMatrix< dim > &  m1,
const RotMatrix< dim > &  m2 
)
inline

◆ Prod() [3/3]

template<int dim>
Vector< dim > WFMath::Prod ( const Vector< dim > &  v,
const RotMatrix< dim > &  m 
)
inline

returns v * m

This is the function to use to rotate a Vector v using a Matrix m

Definition at line 194 of file rotmatrix_funcs.h.

References InvProd().

◆ ProdInv() [1/2]

template<int dim>
RotMatrix< dim > WFMath::ProdInv ( const RotMatrix< dim > &  m1,
const RotMatrix< dim > &  m2 
)
inline

returns m1 * m2^-1

Definition at line 94 of file rotmatrix_funcs.h.

◆ ProdInv() [2/2]

template<int dim>
Vector< dim > WFMath::ProdInv ( const Vector< dim > &  v,
const RotMatrix< dim > &  m 
)
inline

return v * m^-1

Definition at line 200 of file rotmatrix_funcs.h.

References Prod().

◆ ReadCoordList()

void WFMath::ReadCoordList ( std::istream &  is,
CoordType d,
const int  num 
)

Definition at line 246 of file stream.cpp.

◆ Shuffle()

template<class C >
void WFMath::Shuffle ( std::vector< C > &  v)

Randomly reorder the contents of a std::vector.

For things like shuffling a deck of cards, etc.

Definition at line 40 of file shuffle.h.

◆ SloppyDistance()

template<int dim>
CoordType WFMath::SloppyDistance ( const Point< dim > &  p1,
const Point< dim > &  p2 
)

Definition at line 58 of file point.h.

◆ SquaredDistance()

template<int dim>
CoordType WFMath::SquaredDistance ( const Point< dim > &  p1,
const Point< dim > &  p2 
)
inline

Definition at line 124 of file point_funcs.h.

◆ ToString()

template<class C >
std::string WFMath::ToString ( const C &  c,
std::streamsize  precision = 6 
)
inline

Output a WFMath type as a string.

This uses operator<<() in its backend.

Definition at line 100 of file stream.h.

◆ Union()

template<int dim>
AxisBox< dim > WFMath::Union ( const AxisBox< dim > &  a1,
const AxisBox< dim > &  a2 
)

Definition at line 56 of file axisbox_funcs.h.

◆ WriteCoordList()

void WFMath::WriteCoordList ( std::ostream &  os,
const CoordType d,
const int  num 
)

Definition at line 238 of file stream.cpp.