Loading...
Searching...
No Matches
Vector.h File Reference
#include <cmath>
#include <initializer_list>
#include <iosfwd>
#include <array>
#include <type_traits>
#include "LoopUnroller.h"

Classes

class  PLMD::VectorTyped< T, n >
 Class implementing fixed size vectors of doubles. More...
 

Namespaces

namespace  PLMD
 
namespace  PLMD::Versors
 

Typedefs

typedef Vector3d PLMD::Vector
 Alias for three dimensional vectors.
 
typedef VectorGeneric< 1 > PLMD::Vector1d
 Alias for one dimensional vectors.
 
typedef VectorTyped< float, 1 > PLMD::Vector1f
 Alias for one dimensional vectors.
 
typedef VectorGeneric< 2 > PLMD::Vector2d
 Alias for two dimensional vectors.
 
typedef VectorTyped< float, 2 > PLMD::Vector2f
 Alias for two dimensional vectors.
 
typedef VectorGeneric< 3 > PLMD::Vector3d
 Alias for three dimensional vectors.
 
typedef VectorTyped< float, 3 > PLMD::Vector3f
 Alias for three dimensional vectors.
 
typedef VectorGeneric< 4 > PLMD::Vector4d
 Alias for four dimensional vectors.
 
typedef VectorTyped< float, 4 > PLMD::Vector4f
 Alias for four dimensional vectors.
 
typedef VectorGeneric< 5 > PLMD::Vector5d
 Alias for five dimensional vectors.
 
typedef VectorTyped< float, 5 > PLMD::Vector5f
 Alias for five dimensional vectors.
 
template<unsigned n>
using PLMD::VectorGeneric = VectorTyped<double, n>
 
template<typename T>
using PLMD::VectorT = VectorTyped<T,3>
 Alias for three dimensional vectors of any type:
 

Functions

template<typename T>
constexpr VectorTyped< T, 3 > PLMD::crossProduct (const VectorTyped< T, 3 > &v1, const VectorTyped< T, 3 > &v2)
 
template<typename T, unsigned n>
constexpr VectorTyped< T, n > PLMD::delta (const VectorTyped< T, n > &v1, const VectorTyped< T, n > &v2)
 
template<typename T, unsigned n>
constexpr T PLMD::dotProduct (const VectorTyped< T, n > &v1, const VectorTyped< T, n > &v2)
 
template<typename T, unsigned n>
constexpr T PLMD::modulo (const VectorTyped< T, n > &v)
 
template<typename T, unsigned n>
constexpr T PLMD::modulo2 (const VectorTyped< T, n > &v)
 
template<typename T, typename J, unsigned n>
constexpr VectorTyped< T, n > PLMD::operator* (J s, VectorTyped< T, n >v)
 
template<typename T, typename J, unsigned n>
constexpr VectorTyped< T, n > PLMD::operator* (VectorTyped< T, n > v, J s)
 
template<typename T, unsigned n>
constexpr VectorTyped< T, n > PLMD::operator+ (const VectorTyped< T, n > &v1, const VectorTyped< T, n > &v2)
 
template<typename T, unsigned n>
constexpr VectorTyped< T, n > PLMD::operator- (VectorTyped< T, n >v1, const VectorTyped< T, n > &v2)
 
template<typename T, typename J, unsigned n>
constexpr VectorTyped< T, n > PLMD::operator/ (const VectorTyped< T, n > &v, J s)
 
template<typename T, unsigned n>
std::ostream & PLMD::operator<< (std::ostream &os, const VectorTyped< T, n > &v)
 
template<typename T, typename TT, unsigned n>
constexpr VectorTyped< T, n > PLMD::sumT (const VectorTyped< T, n > &v1, const VectorTyped< TT, n > &v2)
 

Variables

template<typename T>
constexpr auto PLMD::Versors::xm
 
template<typename T>
constexpr auto PLMD::Versors::xp
 
template<typename T>
constexpr auto PLMD::Versors::ym
 
template<typename T>
constexpr auto PLMD::Versors::yp
 
template<typename T>
constexpr auto PLMD::Versors::zm
 
template<typename T>
constexpr auto PLMD::Versors::zp