SourceForge Logo Tiny Vector Matrix library using Expression Templates Sourceforge Project Page

Namespaces | Defines | Functions
include/tvmet/VectorOperators.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

namespace  tvmet
 

The namespace for the Tiny Vector Matrix using Expression Templates Libary.


Defines

#define TVMET_DECLARE_MACRO(NAME, OP)
#define TVMET_DECLARE_MACRO(NAME, OP)
#define TVMET_DECLARE_MACRO(NAME, OP, POD)
#define TVMET_DECLARE_MACRO(NAME, OP)
#define TVMET_DECLARE_MACRO(NAME, OP)
#define TVMET_DECLARE_MACRO(NAME, OP)
#define TVMET_DECLARE_MACRO(NAME, OP, TP)
#define TVMET_DECLARE_MACRO(NAME, OP)
#define TVMET_IMPLEMENT_MACRO(NAME, OP)
#define TVMET_IMPLEMENT_MACRO(NAME, OP)
#define TVMET_IMPLEMENT_MACRO(NAME, OP, POD)
#define TVMET_IMPLEMENT_MACRO(NAME, OP)
#define TVMET_IMPLEMENT_MACRO(NAME, OP)
#define TVMET_IMPLEMENT_MACRO(NAME, OP)
#define TVMET_IMPLEMENT_MACRO(NAME, OP, TP)
#define TVMET_IMPLEMENT_MACRO(NAME, OP)

Functions

template<class T , std::size_t Sz>
std::ostream & tvmet::operator<< (std::ostream &os, const Vector< T, Sz > &rhs) TVMET_CXX_ALWAYS_INLINE
 tvmet::TVMET_DECLARE_MACRO (add_eq,+=) TVMET_DECLARE_MACRO(sub_eq
 tvmet::TVMET_IMPLEMENT_MACRO (add_eq,+=) TVMET_IMPLEMENT_MACRO(sub_eq

Define Documentation

#define TVMET_DECLARE_MACRO (   NAME,
  OP 
)
Value:
template<class T1, class T2, std::size_t Sz>        \
Vector<T1, Sz>&               \
operator OP (Vector<T1, Sz>& lhs,         \
       const Vector<T2, Sz>& rhs) TVMET_CXX_ALWAYS_INLINE;  \
                  \
template<class T, class E, std::size_t Sz>        \
Vector<T, Sz>&                \
operator OP (Vector<T, Sz>& lhs,          \
       const XprVector<E, Sz>& rhs) TVMET_CXX_ALWAYS_INLINE;
#define TVMET_DECLARE_MACRO (   NAME,
  OP 
)
#define TVMET_DECLARE_MACRO (   NAME,
  OP 
)
Value:
template<class T, std::size_t Sz>           \
XprVector<                  \
  XprBinOp<                 \
    Fcnl_##NAME< std::complex<T>, std::complex<T> >,        \
    VectorConstReference< std::complex<T>, Sz>,         \
    XprLiteral< std::complex<T> >           \
  >,                    \
  Sz                    \
>                   \
operator OP (const Vector<std::complex<T>, Sz>& lhs,        \
       const std::complex<T>& rhs) TVMET_CXX_ALWAYS_INLINE;   \
                    \
template<class T, std::size_t Sz>           \
XprVector<                  \
  XprBinOp<                 \
    Fcnl_##NAME< std::complex<T>, std::complex<T> >,        \
    XprLiteral< std::complex<T> >,            \
    VectorConstReference< std::complex<T>, Sz>          \
  >,                    \
  Sz                    \
>                   \
operator OP (const std::complex<T>& lhs,          \
       const Vector< std::complex<T>, Sz>& rhs) TVMET_CXX_ALWAYS_INLINE;
#define TVMET_DECLARE_MACRO (   NAME,
  OP 
)
Value:
template <class T, std::size_t Sz>        \
XprVector<              \
  XprUnOp<              \
    Fcnl_##NAME<T>,           \
    VectorConstReference<T, Sz>         \
  >,                \
  Sz                \
>               \
operator OP (const Vector<T, Sz>& rhs) TVMET_CXX_ALWAYS_INLINE;
#define TVMET_DECLARE_MACRO (   NAME,
  OP 
)
#define TVMET_DECLARE_MACRO (   NAME,
  OP,
  POD 
)
Value:
template<class T, std::size_t Sz>       \
XprVector<              \
  XprBinOp<             \
    Fcnl_##NAME< T, POD >,          \
    VectorConstReference<T, Sz>,        \
    XprLiteral< POD >           \
  >,                \
  Sz                \
>               \
operator OP (const Vector<T, Sz>& lhs,        \
       POD rhs) TVMET_CXX_ALWAYS_INLINE;      \
                \
template<class T, std::size_t Sz>       \
XprVector<              \
  XprBinOp<             \
    Fcnl_##NAME< POD, T>,         \
    XprLiteral< POD >,            \
    VectorConstReference<T, Sz>         \
  >,                \
  Sz                \
>               \
operator OP (POD lhs,             \
       const Vector<T, Sz>& rhs) TVMET_CXX_ALWAYS_INLINE;
#define TVMET_DECLARE_MACRO (   NAME,
  OP 
)
Value:
template<class T, std::size_t Sz>           \
XprVector<                  \
  XprBinOp<                 \
    Fcnl_##NAME< std::complex<T>, std::complex<T> >,        \
    VectorConstReference< std::complex<T>, Sz>,         \
    XprLiteral< std::complex<T> >           \
  >,                    \
  Sz                    \
>                   \
operator OP (const Vector<std::complex<T>, Sz>& lhs,        \
       const std::complex<T>& rhs) TVMET_CXX_ALWAYS_INLINE;   \
                    \
template<class T, std::size_t Sz>           \
XprVector<                  \
  XprBinOp<                 \
    Fcnl_##NAME< std::complex<T>, std::complex<T> >,        \
    XprLiteral< std::complex<T> >,            \
    VectorConstReference< std::complex<T>, Sz>          \
  >,                    \
  Sz                    \
>                   \
operator OP (const std::complex<T>& lhs,          \
       const Vector< std::complex<T>, Sz>& rhs) TVMET_CXX_ALWAYS_INLINE;
#define TVMET_DECLARE_MACRO (   NAME,
  OP,
  TP 
)
Value:
template<class T, std::size_t Sz>         \
XprVector<                \
  XprBinOp<               \
    Fcnl_##NAME< T, TP >,           \
    VectorConstReference<T, Sz>,          \
    XprLiteral< TP >              \
  >,                  \
  Sz                  \
>                 \
operator OP (const Vector<T, Sz>& lhs, TP rhs) TVMET_CXX_ALWAYS_INLINE; \
                  \
template<class T, std::size_t Sz>         \
XprVector<                \
  XprBinOp<               \
    Fcnl_##NAME< TP, T>,            \
    XprLiteral< TP >,             \
    VectorConstReference<T, Sz>           \
  >,                  \
  Sz                  \
>                 \
operator OP (TP lhs, const Vector<T, Sz>& rhs) TVMET_CXX_ALWAYS_INLINE;
#define TVMET_IMPLEMENT_MACRO (   NAME,
  OP 
)
Value:
template<class T1, class T2, std::size_t Sz>      \
inline Vector<T1, Sz>&            \
operator OP (Vector<T1, Sz>& lhs, const Vector<T2, Sz>& rhs) {  \
  return lhs.M_##NAME(rhs);         \
}               \
                \
template<class T, class E, std::size_t Sz>      \
inline Vector<T, Sz>&           \
operator OP (Vector<T, Sz>& lhs, const XprVector<E, Sz>& rhs) { \
  return lhs.M_##NAME(rhs);         \
}
#define TVMET_IMPLEMENT_MACRO (   NAME,
  OP 
)
Value:
template <class T, std::size_t Sz>          \
inline                  \
XprVector<                \
  XprUnOp<                \
    Fcnl_##NAME<T>,             \
    VectorConstReference<T, Sz>           \
  >,                  \
  Sz                  \
>                 \
operator OP (const Vector<T, Sz>& rhs) {        \
  typedef XprUnOp<              \
    Fcnl_##NAME<T>,             \
    VectorConstReference<T, Sz>           \
  >                expr_type; \
  return XprVector<expr_type, Sz>(expr_type(rhs.const_ref()));    \
}
#define TVMET_IMPLEMENT_MACRO (   NAME,
  OP,
  POD 
)
Value:
template<class T, std::size_t Sz>     \
inline              \
XprVector<            \
  XprBinOp<           \
    Fcnl_##NAME< T, POD >,        \
    VectorConstReference<T, Sz>,      \
    XprLiteral< POD >         \
  >,              \
  Sz              \
>             \
operator OP (const Vector<T, Sz>& lhs, POD rhs) { \
  return NAME (lhs, rhs);       \
}             \
              \
template<class T, std::size_t Sz>     \
inline              \
XprVector<            \
  XprBinOp<           \
    Fcnl_##NAME< POD, T>,       \
    XprLiteral< POD >,          \
    VectorConstReference<T, Sz>       \
  >,              \
  Sz              \
>             \
operator OP (POD lhs, const Vector<T, Sz>& rhs) { \
  return NAME (lhs, rhs);       \
}
#define TVMET_IMPLEMENT_MACRO (   NAME,
  OP 
)
Value:
template<class T, std::size_t Sz>     \
inline              \
XprVector<            \
  XprBinOp<           \
    Fcnl_##NAME< std::complex<T>, std::complex<T> >,  \
    VectorConstReference< std::complex<T>, Sz>,   \
    XprLiteral< std::complex<T> >     \
  >,              \
  Sz              \
>             \
operator OP (const Vector<std::complex<T>, Sz>& lhs,  \
       const std::complex<T>& rhs) {    \
  return NAME (lhs, rhs);       \
}             \
              \
template<class T, std::size_t Sz>     \
inline              \
XprVector<            \
  XprBinOp<           \
    Fcnl_##NAME< std::complex<T>, std::complex<T> >,  \
    XprLiteral< std::complex<T> >,      \
    VectorConstReference< std::complex<T>, Sz>    \
  >,              \
  Sz              \
>             \
operator OP (const std::complex<T>& lhs,    \
       const Vector< std::complex<T>, Sz>& rhs) { \
  return NAME (lhs, rhs);       \
}
#define TVMET_IMPLEMENT_MACRO (   NAME,
  OP 
)
#define TVMET_IMPLEMENT_MACRO (   NAME,
  OP,
  TP 
)
#define TVMET_IMPLEMENT_MACRO (   NAME,
  OP 
)
#define TVMET_IMPLEMENT_MACRO (   NAME,
  OP 
)
 All Classes Namespaces Files Functions Variables Typedefs Enumerator Friends Defines

Author: