Rosetta  2020.46
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Namespaces | Functions
xyz.functions.hh File Reference

xyzVector and xyzMatrix functions More...

#include <numeric/conversions.hh>
#include <numeric/NumericTraits.hh>
#include <numeric/trig.functions.hh>
#include <numeric/xyzVector.hh>
#include <numeric/xyzMatrix.hh>
#include <numeric/sphericalVector.hh>
#include <utility/string_util.hh>
#include <utility/vector1.hh>
#include <cmath>
#include <cstdlib>
#include <vector>
#include <ObjexxFCL/FArray2D.hh>

Namespaces

 numeric
 Unit headers.
 

Functions

template<typename T >
xyzVector< Tnumeric::closest_point_on_line (xyzVector< T > const &p1, xyzVector< T > const &p2, xyzVector< T > const &q)
 xyzMatrix * xyzVector More...
 
template<typename T >
xyzVector< Tnumeric::center_of_mass (utility::vector1< xyzVector< T > > const &coords)
 calculate center of mass for coordinates More...
 
template<typename T >
xyzVector< Tnumeric::product (xyzMatrix< T > const &m, xyzVector< T > const &v)
 xyzMatrix * xyzVector product More...
 
template<typename T >
xyzVector< T > & numeric::inplace_product (xyzMatrix< T > const &m, xyzVector< T > &v)
 xyzMatrix * xyzVector in-place product More...
 
template<typename T >
xyzVector< Tnumeric::transpose_product (xyzMatrix< T > const &m, xyzVector< T > const &v)
 xyzMatrix^T * xyzVector product More...
 
template<typename T >
xyzVector< T > & numeric::inplace_transpose_product (xyzMatrix< T > const &m, xyzVector< T > &v)
 xyzMatrix^T * xyzVector in-place transpose product More...
 
template<typename T >
xyzMatrix< Tnumeric::outer_product (xyzVector< T > const &a, xyzVector< T > const &b)
 xyzVector xyzVector outer product More...
 
template<typename T >
xyzMatrix< Tnumeric::projection_matrix (xyzVector< T > const &v)
 geometric center More...
 
template<typename T >
xyzMatrix< Tnumeric::inverse (xyzMatrix< T > const &a)
 
template<typename T >
void numeric::angle_radians (xyzVector< T > const &p1, xyzVector< T > const &p2, xyzVector< T > const &p3, T &angle)
 Plane angle in radians: angle value passed. More...
 
template<typename T >
T numeric::angle_radians (xyzVector< T > const &p1, xyzVector< T > const &p2, xyzVector< T > const &p3)
 Plane angle in radians: angle value returned. More...
 
double numeric::angle_radians_double (xyzVector< double > const &p1, xyzVector< double > const &p2, xyzVector< double > const &p3)
 
template<typename T >
T numeric::angle_degrees (xyzVector< T > const &p1, xyzVector< T > const &p2, xyzVector< T > const &p3)
 Plane angle in degrees: angle value returned. More...
 
double numeric::angle_degrees_double (xyzVector< double > const &p1, xyzVector< double > const &p2, xyzVector< double > const &p3)
 
template<typename T >
T numeric::angle_radians (xyzVector< T > const &p1, xyzVector< T > const &p2, xyzVector< T > const &p3, xyzVector< T > const &p4)
 Angle between two vectors in radians. More...
 
double numeric::angle_radians_double (xyzVector< double > const &p1, xyzVector< double > const &p2, xyzVector< double > const &p3, xyzVector< double > const &p4)
 
template<typename T >
T numeric::angle_degrees (xyzVector< T > const &p1, xyzVector< T > const &p2, xyzVector< T > const &p3, xyzVector< T > const &p4)
 Angle between two vectors in radians. More...
 
double numeric::angle_degrees_double (xyzVector< double > const &p1, xyzVector< double > const &p2, xyzVector< double > const &p3, xyzVector< double > const &p4)
 
template<typename T >
void numeric::dihedral_radians (xyzVector< T > const &p1, xyzVector< T > const &p2, xyzVector< T > const &p3, xyzVector< T > const &p4, T &angle)
 Dihedral (torsion) angle in radians: angle value passed. More...
 
void numeric::dihedral_radians_double (xyzVector< double > const &p1, xyzVector< double > const &p2, xyzVector< double > const &p3, xyzVector< double > const &p4, double &angle)
 
template<typename T >
T numeric::dihedral_radians (xyzVector< T > const &p1, xyzVector< T > const &p2, xyzVector< T > const &p3, xyzVector< T > const &p4)
 Dihedral (torsion) angle in radians: angle value returned. More...
 
double numeric::dihedral_radians_double (xyzVector< double > const &p1, xyzVector< double > const &p2, xyzVector< double > const &p3, xyzVector< double > const &p4)
 
template<typename T >
void numeric::dihedral_degrees (xyzVector< T > const &p1, xyzVector< T > const &p2, xyzVector< T > const &p3, xyzVector< T > const &p4, T &angle)
 Dihedral (torsion) angle in degrees: angle value passed. More...
 
void numeric::dihedral_degrees_double (xyzVector< double > const &p1, xyzVector< double > const &p2, xyzVector< double > const &p3, xyzVector< double > const &p4, double &angle)
 
template<typename T >
T numeric::dihedral_degrees (xyzVector< T > const &p1, xyzVector< T > const &p2, xyzVector< T > const &p3, xyzVector< T > const &p4)
 Dihedral (torsion) angle in degrees: angle value returned. More...
 
double numeric::dihedral_degrees_double (xyzVector< double > const &p1, xyzVector< double > const &p2, xyzVector< double > const &p3, xyzVector< double > const &p4)
 
template<typename T >
void numeric::dihedral (xyzVector< T > const &p1, xyzVector< T > const &p2, xyzVector< T > const &p3, xyzVector< T > const &p4, T &angle)
 Dihedral (torsion) angle in degrees: angle value passed. More...
 
void numeric::dihedral_double (xyzVector< double > const &p1, xyzVector< double > const &p2, xyzVector< double > const &p3, xyzVector< double > const &p4, double &angle)
 
template<typename T >
T numeric::dihedral (xyzVector< T > const &p1, xyzVector< T > const &p2, xyzVector< T > const &p3, xyzVector< T > const &p4)
 Dihedral (torsion) angle in degrees: angle value returned. More...
 
double numeric::dihedral_double (xyzVector< double > const &p1, xyzVector< double > const &p2, xyzVector< double > const &p3, xyzVector< double > const &p4)
 
template<typename T >
xyzMatrix< Tnumeric::rotation_matrix (xyzVector< T > const &axis_angle)
 
template<typename T >
xyzMatrix< Tnumeric::rotation_matrix (xyzVector< T > const &axis, T const &theta)
 Rotation matrix for rotation about an axis by an angle in radians. More...
 
template<typename T >
xyzMatrix< Tnumeric::rotation_matrix_radians (xyzVector< T > const &axis, T const &theta)
 Rotation matrix for rotation about an axis by an angle in radians. More...
 
template<typename T >
xyzMatrix< Tnumeric::rotation_matrix_degrees (xyzVector< T > const &axis, T const &theta)
 Rotation matrix for rotation about an axis by an angle in degrees. More...
 
template<typename T >
xyzMatrix< Tnumeric::x_rotation_matrix (T const &theta)
 Rotation matrix for rotation about the x axis by an angle in radians. More...
 
template<typename T >
xyzMatrix< Tnumeric::x_rotation_matrix_radians (T const &theta)
 Rotation matrix for rotation about the x axis by an angle in radians. More...
 
template<typename T >
xyzMatrix< Tnumeric::x_rotation_matrix_degrees (T const &theta)
 Rotation matrix for rotation about the x axis by an angle in degrees. More...
 
template<typename T >
xyzMatrix< Tnumeric::y_rotation_matrix (T const &theta)
 Rotation matrix for rotation about the y axis by an angle in radians. More...
 
template<typename T >
xyzMatrix< Tnumeric::y_rotation_matrix_radians (T const &theta)
 Rotation matrix for rotation about the y axis by an angle in radians. More...
 
template<typename T >
xyzMatrix< Tnumeric::y_rotation_matrix_degrees (T const &theta)
 Rotation matrix for rotation about the y axis by an angle in degrees. More...
 
template<typename T >
xyzMatrix< Tnumeric::z_rotation_matrix (T const &theta)
 Rotation matrix for rotation about the z axis by an angle in radians. More...
 
template<typename T >
xyzMatrix< Tnumeric::z_rotation_matrix_radians (T const &theta)
 Rotation matrix for rotation about the z axis by an angle in radians. More...
 
template<typename T >
xyzMatrix< Tnumeric::z_rotation_matrix_degrees (T const &theta)
 Rotation matrix for rotation about the z axis by an angle in degrees. More...
 
template<typename T >
xyzMatrix< Tnumeric::alignVectorSets (xyzVector< T > A1, xyzVector< T > B1, xyzVector< T > A2, xyzVector< T > B2)
 Helper function to find the rotation to optimally transform the vectors A1-B1 to vectors A2-B2. More...
 
template<typename T >
T numeric::rotation_angle (xyzMatrix< T > const &R)
 Transformation from rotation matrix to magnitude of helical rotation. More...
 
template<typename T >
xyzVector< Tnumeric::rotation_axis (xyzMatrix< T > const &R, T &theta)
 Transformation from rotation matrix to helical axis of rotation. More...
 
template<typename T >
xyzVector< Tnumeric::rotation_axis_angle (xyzMatrix< T > const &R)
 Transformation from rotation matrix to compact axis-angle representation. More...
 
template<typename T >
xyzVector< Tnumeric::eigenvalue_jacobi (xyzMatrix< T > const &a, T const &tol)
 Classic Jacobi algorithm for the eigenvalues of a real symmetric matrix. More...
 
template<typename T >
xyzVector< Tnumeric::eigenvector_jacobi (xyzMatrix< T > const &a, T const &tol, xyzMatrix< T > &J)
 Classic Jacobi algorithm for the eigenvalues and eigenvectors of a real symmetric matrix. More...
 
template<typename T >
void numeric::jacobi_rotation (xyzMatrix< T > const &m, int const i, int const j, xyzMatrix< T > &r)
 Jacobi rotation. More...
 
template<typename T >
sphericalVector< Tnumeric::xyz_to_spherical (xyzVector< T > const &xyz)
 
template<typename T >
xyzVector< Tnumeric::spherical_to_xyz (sphericalVector< T > const &spherical)
 
template<typename T >
xyzVector< Tnumeric::comma_seperated_string_to_xyz (std::string triplet)
 convert a string of comma separated values "0.2,0.4,0.3" to an xyzVector More...
 
template<typename T >
ObjexxFCL::FArray2D< Tnumeric::vector_of_xyzvectors_to_FArray (utility::vector1< xyzVector< T > > const &input)
 convert a vector1 of xyzVectors to an FArray2D More...
 
template<typename T >
utility::vector1< xyzVector< T > > numeric::FArray_to_vector_of_xyzvectors (ObjexxFCL::FArray2D< T > const &input)
 convert an FArray2D to a vector of xyzVectors More...
 
template<typename T >
numeric::xyzMatrix< Tnumeric::FArray_to_xyzmatrix (ObjexxFCL::FArray2D< T > const &input)
 convert a 3x3 FArray 2D to an xyzMatrix More...
 
template<typename T >
ObjexxFCL::FArray2D< Tnumeric::xyzmatrix_to_FArray (numeric::xyzMatrix< T > const &input)
 convert an xyzMatrix to a 3x3 FArray 2D More...
 
template<typename T >
void numeric::angles_between_0_180 (xyzVector< T > &angles)
 
template<typename T >
xyzMatrix< Tnumeric::rotation_matrix_from_euler_angles_ZYZ (xyzVector< T > const &angles)
 
template<typename T >
xyzMatrix< Tnumeric::rotation_matrix_from_euler_angles_ZXZ (xyzVector< T > const &angles)
 
template<typename T >
xyzMatrix< Tnumeric::rotation_matrix_from_euler_angles_ZYX (xyzVector< T > const &angles)
 
template<typename T >
xyzVector< Tnumeric::euler_angles_from_rotation_matrix_ZYZ (xyzMatrix< T > const &rotM)
 
template<typename T >
xyzVector< Tnumeric::euler_angles_from_rotation_matrix_ZXZ (xyzMatrix< T > const &rotM)
 
template<typename T >
xyzVector< Tnumeric::euler_angles_from_rotation_matrix_ZYX (xyzMatrix< T > const &rotM)
 

Detailed Description

xyzVector and xyzMatrix functions

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)