Rosetta 3.3
Public Types | Public Member Functions | Friends
numeric::sphericalVector< T > Class Template Reference

sphericalVector: Fast spherical-coordinate numeric vector More...

#include <sphericalVector.hh>

Collaboration diagram for numeric::sphericalVector< T >:
Collaboration graph
[legend]

List of all members.

Public Types

typedefValue
typedef T & Reference
typedef T const & ConstReference
typedef T * Pointer
typedef T const * ConstPointer
typedefvalue_type
typedef T & reference
typedef T const & const_reference
typedef T * pointer
typedef T const * const_pointer
typedef void iterator_category
typedef void difference_type

Public Member Functions

 sphericalVector ()
 Default constructor.
 sphericalVector (sphericalVector const &v)
 Copy constructor.
template<typename U >
 sphericalVector (sphericalVector< U > const &v)
 Copy constructor.
 sphericalVector (Value const &phi_a, Value const &theta_a, Value const &radius_a)
 Triple value constructor.
template<typename U >
 sphericalVector (U const *p)
 Pointer to contiguous values constructor.
 ~sphericalVector ()
 Destructor.
sphericalVectoroperator= (sphericalVector const &v)
 Copy assignment.
template<typename U >
sphericalVectoroperator= (sphericalVector< U > const &v)
 Copy assignment.
template<typename U >
sphericalVectoroperator= (U const *p)
 Assignment from pointer to contiguous values.
template<typename U >
sphericalVectoroperator+= (sphericalVector< U > const &v)
 += xyzVector
template<typename U >
sphericalVectoroperator-= (sphericalVector< U > const &v)
 -= xyzVector
template<typename U >
sphericalVectorscaled_assign (Value const &t, sphericalVector< U > const &v)
 Assign Value * xyzVector.
template<typename U >
sphericalVectorscaled_add (Value const &t, sphericalVector< U > const &v)
 Add Value * xyzVector.
template<typename U >
sphericalVectorscaled_sub (Value const &t, sphericalVector< U > const &v)
 Subtract Value * xyzVector.
sphericalVectoroperator= (Value const &t)
 = Value
sphericalVectoroperator+= (Value const &t)
 += Value
sphericalVectoroperator-= (Value const &t)
 -= Value
sphericalVectoroperator*= (Value const &t)
 *= Value
sphericalVectoroperator/= (Value const &t)
 /= Value
sphericalVectorassign (Value const &phi_a, Value const &theta_a, Value const &radius_a)
 Triple value assignment.
sphericalVectorclear ()
 Clear.
sphericalVectorzero ()
 Zero.
sphericalVectormin (sphericalVector const &v)
 Set minimum coordinates wrt another xyzVector.
sphericalVectormax (sphericalVector const &v)
 Set maximum coordinates wrt another xyzVector.
Value const & phi () const
 Value x const.
Valuephi ()
 Value x.
Value const & theta () const
 Value y const.
Valuetheta ()
 Value y.
Value const & radius () const
 Value z const.
Valueradius ()
 Value z.
void phi (Value const &phi_a)
 x assignment
void theta (Value const &theta_a)
 y assignment
void radius (Value const &radius_a)
 z assignment

Friends

sphericalVector operator+ (sphericalVector const &a, sphericalVector const &b)
 sphericalVector + sphericalVector
sphericalVector operator+ (sphericalVector const &v, Value const &t)
 sphericalVector + Value
sphericalVector operator+ (Value const &t, sphericalVector const &v)
 Value + sphericalVector.
sphericalVector operator- (sphericalVector const &a, sphericalVector const &b)
 sphericalVector - sphericalVector
sphericalVector operator- (sphericalVector const &v, Value const &t)
 sphericalVector - Value
sphericalVector operator- (Value const &t, sphericalVector const &v)
 Value - sphericalVector.
sphericalVector operator* (sphericalVector const &v, Value const &t)
 sphericalVector * Value
sphericalVector operator* (Value const &t, sphericalVector const &v)
 Value * xyzVector.
sphericalVector operator/ (sphericalVector const &v, Value const &t)
 xyzVector / Value
void add (sphericalVector const &a, sphericalVector const &b, sphericalVector &r)
 Add: xyzVector + xyzVector.
void add (sphericalVector const &v, Value const &t, sphericalVector &r)
 Add: xyzVector + Value.
void add (Value const &t, sphericalVector const &v, sphericalVector &r)
 Add: Value + xyzVector.
void subtract (sphericalVector const &a, sphericalVector const &b, sphericalVector &r)
 Subtract: xyzVector - xyzVector.
void subtract (sphericalVector const &v, Value const &t, sphericalVector &r)
 Subtract: xyzVector - Value.
void subtract (Value const &t, sphericalVector const &v, sphericalVector &r)
 Subtract: Value - sphericalVector.
void multiply (sphericalVector const &v, Value const &t, sphericalVector &r)
 Multiply: xyzVector * Value.
void multiply (Value const &t, sphericalVector const &v, sphericalVector &r)
 Multiply: Value * xyzVector.
void divide (sphericalVector const &v, Value const &t, sphericalVector &r)
 Divide: xyzVector / Value.
sphericalVector min (sphericalVector const &a, sphericalVector const &b)
 xyzVector with min coordinates of two xyzVectors
sphericalVector max (sphericalVector const &a, sphericalVector const &b)
 sphericalVector with max coordinates of two sphericalVector
bool operator== (sphericalVector const &a, sphericalVector const &b)
 sphericalVector == sphericalVector
bool operator!= (sphericalVector const &a, sphericalVector const &b)
 sphericalVector != sphericalVector

Detailed Description

template<typename T>
class numeric::sphericalVector< T >

sphericalVector: Fast spherical-coordinate numeric vector


Member Typedef Documentation

template<typename T>
typedef T const* numeric::sphericalVector< T >::const_pointer
template<typename T>
typedef T const& numeric::sphericalVector< T >::const_reference
template<typename T>
typedef T const* numeric::sphericalVector< T >::ConstPointer
template<typename T>
typedef T const& numeric::sphericalVector< T >::ConstReference
template<typename T>
typedef void numeric::sphericalVector< T >::difference_type
template<typename T>
typedef void numeric::sphericalVector< T >::iterator_category
template<typename T>
typedef T* numeric::sphericalVector< T >::pointer
template<typename T>
typedef T* numeric::sphericalVector< T >::Pointer
template<typename T>
typedef T& numeric::sphericalVector< T >::reference
template<typename T>
typedef T& numeric::sphericalVector< T >::Reference
template<typename T>
typedef T numeric::sphericalVector< T >::Value
template<typename T>
typedef T numeric::sphericalVector< T >::value_type

Constructor & Destructor Documentation

template<typename T>
numeric::sphericalVector< T >::sphericalVector ( ) [inline]

Default constructor.

Note:
Values are uninitialized for efficiency
template<typename T>
numeric::sphericalVector< T >::sphericalVector ( sphericalVector< T > const &  v) [inline]

Copy constructor.

template<typename T>
template<typename U >
numeric::sphericalVector< T >::sphericalVector ( sphericalVector< U > const &  v) [inline]

Copy constructor.

template<typename T>
numeric::sphericalVector< T >::sphericalVector ( Value const &  phi_a,
Value const &  theta_a,
Value const &  radius_a 
) [inline]

Triple value constructor.

template<typename T>
template<typename U >
numeric::sphericalVector< T >::sphericalVector ( U const *  p) [inline, explicit]

Pointer to contiguous values constructor.

Note:
U must be assignable to a Value
Warning:
No way to check that argument points to three values
Argument missing an & operator will quietly call the uniform value constructor
template<typename T>
numeric::sphericalVector< T >::~sphericalVector ( ) [inline]

Destructor.


Member Function Documentation

template<typename T>
sphericalVector& numeric::sphericalVector< T >::assign ( Value const &  phi_a,
Value const &  theta_a,
Value const &  radius_a 
) [inline]

Triple value assignment.

template<typename T>
sphericalVector& numeric::sphericalVector< T >::clear ( ) [inline]

Clear.

template<typename T>
sphericalVector& numeric::sphericalVector< T >::max ( sphericalVector< T > const &  v) [inline]

Set maximum coordinates wrt another xyzVector.

template<typename T>
sphericalVector& numeric::sphericalVector< T >::min ( sphericalVector< T > const &  v) [inline]

Set minimum coordinates wrt another xyzVector.

template<typename T>
sphericalVector& numeric::sphericalVector< T >::operator*= ( Value const &  t) [inline]

*= Value

References sd::t.

template<typename T>
sphericalVector& numeric::sphericalVector< T >::operator+= ( Value const &  t) [inline]

+= Value

References sd::t.

template<typename T>
template<typename U >
sphericalVector& numeric::sphericalVector< T >::operator+= ( sphericalVector< U > const &  v) [inline]
template<typename T>
template<typename U >
sphericalVector& numeric::sphericalVector< T >::operator-= ( sphericalVector< U > const &  v) [inline]
template<typename T>
sphericalVector& numeric::sphericalVector< T >::operator-= ( Value const &  t) [inline]

-= Value

References sd::t.

template<typename T>
sphericalVector& numeric::sphericalVector< T >::operator/= ( Value const &  t) [inline]

/= Value

template<typename T>
template<typename U >
sphericalVector& numeric::sphericalVector< T >::operator= ( sphericalVector< U > const &  v) [inline]

Copy assignment.

template<typename T>
sphericalVector& numeric::sphericalVector< T >::operator= ( Value const &  t) [inline]

= Value

References sd::t.

template<typename T>
sphericalVector& numeric::sphericalVector< T >::operator= ( sphericalVector< T > const &  v) [inline]

Copy assignment.

template<typename T>
template<typename U >
sphericalVector& numeric::sphericalVector< T >::operator= ( U const *  p) [inline]

Assignment from pointer to contiguous values.

Warning:
No way to check that argument points to three values

References docking::p.

template<typename T>
Value const& numeric::sphericalVector< T >::phi ( ) const [inline]

Value x const.

Referenced by numeric::spherical_to_xyz(), and numeric::xyz_to_spherical().

template<typename T>
Value& numeric::sphericalVector< T >::phi ( ) [inline]

Value x.

template<typename T>
void numeric::sphericalVector< T >::phi ( Value const &  phi_a) [inline]

x assignment

template<typename T>
Value& numeric::sphericalVector< T >::radius ( ) [inline]

Value z.

template<typename T>
Value const& numeric::sphericalVector< T >::radius ( ) const [inline]

Value z const.

Referenced by numeric::spherical_to_xyz(), and numeric::xyz_to_spherical().

template<typename T>
void numeric::sphericalVector< T >::radius ( Value const &  radius_a) [inline]

z assignment

template<typename T>
template<typename U >
sphericalVector& numeric::sphericalVector< T >::scaled_add ( Value const &  t,
sphericalVector< U > const &  v 
) [inline]

Add Value * xyzVector.

Note:
Avoids temporary of += Value * xyzVector
template<typename T>
template<typename U >
sphericalVector& numeric::sphericalVector< T >::scaled_assign ( Value const &  t,
sphericalVector< U > const &  v 
) [inline]

Assign Value * xyzVector.

Note:
Avoids temporary of = Value * xyzVector
template<typename T>
template<typename U >
sphericalVector& numeric::sphericalVector< T >::scaled_sub ( Value const &  t,
sphericalVector< U > const &  v 
) [inline]

Subtract Value * xyzVector.

Note:
Avoids temporary of -= Value * xyzVector
template<typename T>
void numeric::sphericalVector< T >::theta ( Value const &  theta_a) [inline]

y assignment

template<typename T>
Value& numeric::sphericalVector< T >::theta ( ) [inline]

Value y.

template<typename T>
Value const& numeric::sphericalVector< T >::theta ( ) const [inline]

Value y const.

Referenced by numeric::spherical_to_xyz(), and numeric::xyz_to_spherical().

template<typename T>
sphericalVector& numeric::sphericalVector< T >::zero ( ) [inline]

Zero.


Friends And Related Function Documentation

template<typename T>
void add ( sphericalVector< T > const &  a,
sphericalVector< T > const &  b,
sphericalVector< T > &  r 
) [friend]
template<typename T>
void add ( sphericalVector< T > const &  v,
Value const &  t,
sphericalVector< T > &  r 
) [friend]

Add: xyzVector + Value.

template<typename T>
void add ( Value const &  t,
sphericalVector< T > const &  v,
sphericalVector< T > &  r 
) [friend]

Add: Value + xyzVector.

template<typename T>
void divide ( sphericalVector< T > const &  v,
Value const &  t,
sphericalVector< T > &  r 
) [friend]

Divide: xyzVector / Value.

template<typename T>
sphericalVector max ( sphericalVector< T > const &  a,
sphericalVector< T > const &  b 
) [friend]

sphericalVector with max coordinates of two sphericalVector

template<typename T>
sphericalVector min ( sphericalVector< T > const &  a,
sphericalVector< T > const &  b 
) [friend]

xyzVector with min coordinates of two xyzVectors

template<typename T>
void multiply ( Value const &  t,
sphericalVector< T > const &  v,
sphericalVector< T > &  r 
) [friend]

Multiply: Value * xyzVector.

template<typename T>
void multiply ( sphericalVector< T > const &  v,
Value const &  t,
sphericalVector< T > &  r 
) [friend]

Multiply: xyzVector * Value.

template<typename T>
bool operator!= ( sphericalVector< T > const &  a,
sphericalVector< T > const &  b 
) [friend]
template<typename T>
sphericalVector operator* ( Value const &  t,
sphericalVector< T > const &  v 
) [friend]

Value * xyzVector.

template<typename T>
sphericalVector operator* ( sphericalVector< T > const &  v,
Value const &  t 
) [friend]

sphericalVector * Value

template<typename T>
sphericalVector operator+ ( sphericalVector< T > const &  v,
Value const &  t 
) [friend]

sphericalVector + Value

template<typename T>
sphericalVector operator+ ( sphericalVector< T > const &  a,
sphericalVector< T > const &  b 
) [friend]
template<typename T>
sphericalVector operator+ ( Value const &  t,
sphericalVector< T > const &  v 
) [friend]

Value + sphericalVector.

template<typename T>
sphericalVector operator- ( sphericalVector< T > const &  a,
sphericalVector< T > const &  b 
) [friend]
template<typename T>
sphericalVector operator- ( sphericalVector< T > const &  v,
Value const &  t 
) [friend]

sphericalVector - Value

template<typename T>
sphericalVector operator- ( Value const &  t,
sphericalVector< T > const &  v 
) [friend]

Value - sphericalVector.

template<typename T>
sphericalVector operator/ ( sphericalVector< T > const &  v,
Value const &  t 
) [friend]

xyzVector / Value

template<typename T>
bool operator== ( sphericalVector< T > const &  a,
sphericalVector< T > const &  b 
) [friend]
template<typename T>
void subtract ( Value const &  t,
sphericalVector< T > const &  v,
sphericalVector< T > &  r 
) [friend]

Subtract: Value - sphericalVector.

template<typename T>
void subtract ( sphericalVector< T > const &  a,
sphericalVector< T > const &  b,
sphericalVector< T > &  r 
) [friend]

Subtract: xyzVector - xyzVector.

template<typename T>
void subtract ( sphericalVector< T > const &  v,
Value const &  t,
sphericalVector< T > &  r 
) [friend]

Subtract: xyzVector - Value.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines