Rosetta  2020.11
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Classes | Namespaces | Functions
xyzVector.hh File Reference

Fast (x,y,z)-coordinate numeric vector. More...

#include <numeric/xyzVector.fwd.hh>
#include <numeric/xyzMatrix.fwd.hh>
#include <numeric/xyz.functions.fwd.hh>
#include <numeric/trig.functions.hh>
#include <platform/types.hh>
#include <stdexcept>
#include <utility/assert.hh>
#include <cmath>
#include <ObjexxFCL/FArrayTraits.hh>
#include <utility/string_util.hh>
#include <utility/excn/Exceptions.hh>
#include <boost/functional/hash.hpp>
#include <cstdlib>

Classes

class  numeric::xyzVector< typename >
 xyzVector: Fast (x,y,z)-coordinate numeric vector More...
 
struct  ObjexxFCL::FArrayTraits< numeric::xyzVector< T > >
 Specialization for FArrayTraits, to allow reasonable default constructor in FArray context. More...
 

Namespaces

 numeric
 Unit headers.
 
 ObjexxFCL
 

Functions

template<typename T >
platform::Size numeric::hash_value (xyzVector< T > const &v)
 
template<typename T >
xyzVector< Tnumeric::operator+ (xyzVector< T > const &a, xyzVector< T > const &b)
 xyzVector + xyzVector More...
 
template<typename T >
xyzVector< Tnumeric::operator+ (xyzVector< T > const &v, T const &t)
 xyzVector + T More...
 
template<typename T >
xyzVector< Tnumeric::operator+ (T const &t, xyzVector< T > const &v)
 T + xyzVector. More...
 
template<typename T >
xyzVector< Tnumeric::operator- (xyzVector< T > const &a, xyzVector< T > const &b)
 xyzVector - xyzVector More...
 
template<typename T >
xyzVector< Tnumeric::operator- (xyzVector< T > const &v, T const &t)
 xyzVector - T More...
 
template<typename T >
xyzVector< Tnumeric::operator- (T const &t, xyzVector< T > const &v)
 T - xyzVector. More...
 
template<typename T >
xyzVector< Tnumeric::operator* (xyzVector< T > const &v, T const &t)
 xyzVector * T More...
 
template<typename T >
xyzVector< Tnumeric::operator* (T const &t, xyzVector< T > const &v)
 T * xyzVector. More...
 
template<typename T >
xyzVector< Tnumeric::operator/ (xyzVector< T > const &v, T const &t)
 xyzVector / T More...
 
template<typename T >
void numeric::add (xyzVector< T > const &a, xyzVector< T > const &b, xyzVector< T > &r)
 Add: xyzVector + xyzVector. More...
 
template<typename T >
void numeric::add (xyzVector< T > const &v, T const &t, xyzVector< T > &r)
 Add: xyzVector + T. More...
 
template<typename T >
void numeric::add (T const &t, xyzVector< T > const &v, xyzVector< T > &r)
 Add: T + xyzVector. More...
 
template<typename T >
void numeric::subtract (xyzVector< T > const &a, xyzVector< T > const &b, xyzVector< T > &r)
 Subtract: xyzVector - xyzVector. More...
 
template<typename T >
void numeric::subtract (xyzVector< T > const &v, T const &t, xyzVector< T > &r)
 Subtract: xyzVector - T. More...
 
template<typename T >
void numeric::subtract (T const &t, xyzVector< T > const &v, xyzVector< T > &r)
 Subtract: T - xyzVector. More...
 
template<typename T >
void numeric::multiply (xyzVector< T > const &v, T const &t, xyzVector< T > &r)
 Multiply: xyzVector * T. More...
 
template<typename T >
void numeric::multiply (T const &t, xyzVector< T > const &v, xyzVector< T > &r)
 Multiply: T * xyzVector. More...
 
template<typename T >
void numeric::divide (xyzVector< T > const &v, T const &t, xyzVector< T > &r)
 Divide: xyzVector / T. More...
 
template<typename T >
xyzVector< Tnumeric::min (xyzVector< T > const &a, xyzVector< T > const &b)
 xyzVector with min coordinates of two xyzVectors More...
 
template<typename T >
xyzVector< Tnumeric::max (xyzVector< T > const &a, xyzVector< T > const &b)
 xyzVector with max coordinates of two xyzVectors More...
 
template<typename T >
T numeric::dot (xyzVector< T > const &a, xyzVector< T > const &b)
 Distance. More...
 
template<typename T >
T numeric::dot_product (xyzVector< T > const &a, xyzVector< T > const &b)
 Dot product. More...
 
template<typename T >
T numeric::inner_product (xyzVector< T > const &a, xyzVector< T > const &b)
 Inner product ( == dot product ) More...
 
template<typename T >
xyzVector< Tnumeric::cross (xyzVector< T > const &a, xyzVector< T > const &b)
 Cross product. More...
 
template<typename T >
xyzVector< Tnumeric::cross_product (xyzVector< T > const &a, xyzVector< T > const &b)
 Cross product. More...
 
template<typename T >
void numeric::cross (xyzVector< T > const &a, xyzVector< T > const &b, xyzVector< T > &c)
 Cross product: Return via argument (slightly faster) More...
 
template<typename T >
void numeric::cross_product (xyzVector< T > const &a, xyzVector< T > const &b, xyzVector< T > &c)
 Cross product: Return via argument (slightly faster) More...
 
template<typename T >
xyzVector< Tnumeric::midpoint (xyzVector< T > const &a, xyzVector< T > const &b)
 Midpoint of 2 xyzVectors. More...
 
template<typename T >
void numeric::midpoint (xyzVector< T > const &a, xyzVector< T > const &b, xyzVector< T > &m)
 Midpoint of 2 xyzVectors: Return via argument (slightly faster) More...
 
template<typename T >
xyzVector< Tnumeric::center (xyzVector< T > const &a, xyzVector< T > const &b)
 Center of 2 xyzVectors. More...
 
template<typename T >
void numeric::center (xyzVector< T > const &a, xyzVector< T > const &b, xyzVector< T > &m)
 Center of 2 xyzVectors: Return via argument (slightly faster) More...
 
template<typename T >
xyzVector< Tnumeric::center (xyzVector< T > const &a, xyzVector< T > const &b, xyzVector< T > const &c)
 Center of 3 xyzVectors. More...
 
template<typename T >
void numeric::center (xyzVector< T > const &a, xyzVector< T > const &b, xyzVector< T > const &c, xyzVector< T > &m)
 Center of 3 xyzVectors: Return via argument (slightly faster) More...
 
template<typename T >
xyzVector< Tnumeric::center (xyzVector< T > const &a, xyzVector< T > const &b, xyzVector< T > const &c, xyzVector< T > const &d)
 Center of 4 xyzVectors. More...
 
template<typename T >
void numeric::center (xyzVector< T > const &a, xyzVector< T > const &b, xyzVector< T > const &c, xyzVector< T > const &d, xyzVector< T > &m)
 Center of 4 xyzVectors: Return via argument (slightly faster) More...
 
template<typename T >
T numeric::angle_of (xyzVector< T > const &a, xyzVector< T > const &b)
 Angle between two vectors (in radians on [ 0, pi ]) More...
 
template<typename T >
T numeric::angle_of (xyzVector< T > const &a, xyzVector< T > const &b, xyzVector< T > const &c)
 Angle formed by three consecutive points (in radians on [ 0, pi ]) More...
 
template<typename T >
T numeric::cos_of (xyzVector< T > const &a, xyzVector< T > const &b)
 Cosine of angle between two vectors. More...
 
template<typename T >
T numeric::cos_of (xyzVector< T > const &a, xyzVector< T > const &b, xyzVector< T > const &c)
 Cosine of angle formed by three consecutive points. More...
 
template<typename T >
T numeric::sin_of (xyzVector< T > const &a, xyzVector< T > const &b)
 Sine of angle between two vectors. More...
 
template<typename T >
T numeric::sin_of (xyzVector< T > const &a, xyzVector< T > const &b, xyzVector< T > const &c)
 Sine of angle formed by three consecutive points. More...
 
template<typename T >
bool numeric::operator== (xyzVector< T > const &a, xyzVector< T > const &b)
 xyzVector == xyzVector More...
 
template<typename T >
bool numeric::operator!= (xyzVector< T > const &a, xyzVector< T > const &b)
 xyzVector != xyzVector More...
 
template<typename T >
bool numeric::operator< (xyzVector< T > const &a, xyzVector< T > const &b)
 xyzVector < xyzVector More...
 
template<typename T >
bool numeric::operator<= (xyzVector< T > const &a, xyzVector< T > const &b)
 xyzVector <= xyzVector More...
 
template<typename T >
bool numeric::operator>= (xyzVector< T > const &a, xyzVector< T > const &b)
 xyzVector >= xyzVector More...
 
template<typename T >
bool numeric::operator> (xyzVector< T > const &a, xyzVector< T > const &b)
 xyzVector > xyzVector More...
 
template<typename T >
bool numeric::operator== (xyzVector< T > const &v, T const &t)
 xyzVector == T More...
 
template<typename T >
bool numeric::operator!= (xyzVector< T > const &v, T const &t)
 xyzVector != T More...
 
template<typename T >
bool numeric::operator< (xyzVector< T > const &v, T const &t)
 xyzVector < T More...
 
template<typename T >
bool numeric::operator<= (xyzVector< T > const &v, T const &t)
 xyzVector <= T More...
 
template<typename T >
bool numeric::operator>= (xyzVector< T > const &v, T const &t)
 xyzVector >= T More...
 
template<typename T >
bool numeric::operator> (xyzVector< T > const &v, T const &t)
 xyzVector > T More...
 
template<typename T >
bool numeric::operator== (T const &t, xyzVector< T > const &v)
 T == xyzVector. More...
 
template<typename T >
bool numeric::operator!= (T const &t, xyzVector< T > const &v)
 T != xyzVector. More...
 
template<typename T >
bool numeric::operator< (T const &t, xyzVector< T > const &v)
 T < xyzVector. More...
 
template<typename T >
bool numeric::operator<= (T const &t, xyzVector< T > const &v)
 T <= xyzVector. More...
 
template<typename T >
bool numeric::operator>= (T const &t, xyzVector< T > const &v)
 T >= xyzVector. More...
 
template<typename T >
bool numeric::operator> (T const &t, xyzVector< T > const &v)
 T > xyzVector. More...
 
template<typename T >
bool numeric::equal_length (xyzVector< T > const &a, xyzVector< T > const &b)
 Equal length? More...
 
template<typename T >
bool numeric::not_equal_length (xyzVector< T > const &a, xyzVector< T > const &b)
 Not equal length? More...
 
template<typename U >
void numeric::subtract (xyzVector< U > const &a, xyzVector< U > const &b, xyzVector< U > &r)
 Subtract: xyzVector - xyzVector. More...
 
template<typename U >
void numeric::subtract (xyzVector< U > const &v, U const &t, xyzVector< U > &r)
 Subtract: xyzVector - Value. More...
 
template<typename U >
void numeric::subtract (U const &t, xyzVector< U > const &v, xyzVector< U > &r)
 Subtract: Value - xyzVector. More...
 
template<typename U >
void numeric::multiply (xyzVector< U > const &v, U const &t, xyzVector< U > &r)
 Multiply: xyzVector * Value. More...
 
template<typename U >
void numeric::multiply (U const &t, xyzVector< U > const &v, xyzVector< U > &r)
 Multiply: Value * xyzVector. More...
 
template<typename T >
xyzVector< Tnumeric::update_operation (xyzVector< T > const &a, xyzVector< T > const &b)
 
template<typename T >
xyzVector< Tnumeric::update_5way_operation (xyzVector< T > const &a, xyzVector< T > const &b, xyzVector< T > const &c, xyzVector< T > const &d, xyzVector< T > const &e)
 
template<typename U >
numeric::angle_of (xyzVector< U > const &a, xyzVector< U > const &b)
 Angle between two vectors (in radians on [ 0, pi ]) More...
 
template<typename U >
numeric::angle_of (xyzVector< U > const &a, xyzVector< U > const &b, xyzVector< U > const &c)
 Angle formed by three consecutive points (in radians on [ 0, pi ]) More...
 
template<typename U >
numeric::cos_of (xyzVector< U > const &a, xyzVector< U > const &b)
 Cosine of angle between two vectors. More...
 
template<typename U >
numeric::cos_of (xyzVector< U > const &a, xyzVector< U > const &b, xyzVector< U > const &c)
 Cosine of angle formed by three consecutive points. More...
 
template<typename U >
numeric::sin_of (xyzVector< U > const &a, xyzVector< U > const &b)
 Sine of angle between two vectors. More...
 
template<typename U >
numeric::sin_of (xyzVector< U > const &a, xyzVector< U > const &b, xyzVector< U > const &c)
 Sine of angle formed by three consecutive points. More...
 
template<typename U >
xyzVector< U > numeric::min (xyzVector< U > const &a, xyzVector< U > const &b)
 xyzVector with min coordinates of two xyzVectors More...
 
template<typename U >
xyzVector< U > numeric::max (xyzVector< U > const &a, xyzVector< U > const &b)
 xyzVector with max coordinates of two xyzVectors More...
 
template<typename U >
xyzVector< U > numeric::cross (xyzVector< U > const &a, xyzVector< U > const &b)
 Cross product. More...
 
template<typename U >
xyzVector< U > numeric::cross_product (xyzVector< U > const &a, xyzVector< U > const &b)
 Cross product. More...
 
template<typename U >
void numeric::cross (xyzVector< U > const &a, xyzVector< U > const &b, xyzVector< U > &c)
 Cross product: Return via argument (slightly faster) More...
 
template<typename U >
void numeric::cross_product (xyzVector< U > const &a, xyzVector< U > const &b, xyzVector< U > &c)
 Cross product: Return via argument (slightly faster) More...
 
template<typename U >
xyzVector< U > numeric::midpoint (xyzVector< U > const &a, xyzVector< U > const &b)
 Midpoint of 2 xyzVectors. More...
 
template<typename U >
void numeric::midpoint (xyzVector< U > const &a, xyzVector< U > const &b, xyzVector< U > &m)
 Midpoint of 2 xyzVectors: Return via argument (slightly faster) More...
 
template<typename U >
xyzVector< U > numeric::center (xyzVector< U > const &a, xyzVector< U > const &b)
 Center of 2 xyzVectors. More...
 
template<typename U >
void numeric::center (xyzVector< U > const &a, xyzVector< U > const &b, xyzVector< U > &m)
 Center of 2 xyzVectors: Return via argument (slightly faster) More...
 
template<typename U >
xyzVector< U > numeric::center (xyzVector< U > const &a, xyzVector< U > const &b, xyzVector< U > const &c)
 Center of 3 xyzVectors. More...
 
template<typename U >
void numeric::center (xyzVector< U > const &a, xyzVector< U > const &b, xyzVector< U > const &c, xyzVector< U > &m)
 Center of 3 xyzVectors: Return via argument (slightly faster) More...
 
template<typename U >
xyzVector< U > numeric::center (xyzVector< U > const &a, xyzVector< U > const &b, xyzVector< U > const &c, xyzVector< U > const &d)
 Center of 4 xyzVectors. More...
 
template<typename U >
void numeric::center (xyzVector< U > const &a, xyzVector< U > const &b, xyzVector< U > const &c, xyzVector< U > const &d, xyzVector< U > &m)
 Center of 4 xyzVectors: Return via argument (slightly faster) More...
 
template<typename U >
void numeric::add (xyzVector< U > const &a, xyzVector< U > const &b, xyzVector< U > &r)
 Add: xyzVector + xyzVector. More...
 
template<typename U >
void numeric::add (xyzVector< U > const &v, U const &t, xyzVector< U > &r)
 Add: xyzVector + Value. More...
 
template<typename U >
void numeric::add (U const &t, xyzVector< U > const &v, xyzVector< U > &r)
 Add: Value + xyzVector. More...
 
template<typename U >
bool numeric::equal_length (xyzVector< U > const &a, xyzVector< U > const &b)
 Equal length? More...
 
template<typename U >
bool numeric::not_equal_length (xyzVector< U > const &a, xyzVector< U > const &b)
 Not equal length? More...
 
template<typename U >
numeric::dot (xyzVector< U > const &a, xyzVector< U > const &b)
 Dot product. More...
 
template<typename U >
numeric::inner_product (xyzVector< U > const &a, xyzVector< U > const &b)
 Inner product ( == dot product ) More...
 
template<typename U >
void numeric::divide (xyzVector< U > const &v, U const &t, xyzVector< U > &r)
 Divide: xyzVector / Value. More...
 

Detailed Description

Fast (x,y,z)-coordinate numeric vector.

Author
Frank M. D'Ippolito (Objex.nosp@m.x@ob.nosp@m.jexx..nosp@m.com)
Stuart G. Mentzer (Stuar.nosp@m.t_Me.nosp@m.ntzer.nosp@m.@obj.nosp@m.exx.c.nosp@m.om)
Remarks
  • Inline, loop-free functions for speed
  • Non-virtual destructor for speed: Not set up for use as a base class
  • Pointer constructor and assignment not available for xyzVectors of pointers
  • Numeric vector semantics: spatial partial ordering