11#ifndef CUBBYFLOW_MATRIX_EXPRESSION_IMPL_HPP
12#define CUBBYFLOW_MATRIX_EXPRESSION_IMPL_HPP
20template <
typename T,
size_t Rows,
size_t Cols,
typename D>
23 return static_cast<const D&
>(*this).
GetRows();
26template <
typename T,
size_t Rows,
size_t Cols,
typename D>
29 return static_cast<const D&
>(*this).
GetCols();
32template <
typename T,
size_t Rows,
size_t Cols,
typename D>
35 return GetDerived()(i, j);
38template <
typename T,
size_t Rows,
size_t Cols,
typename D>
44template <
typename T,
size_t Rows,
size_t Cols,
typename D>
45template <
size_t R,
size_t C,
typename E>
56 for (
size_t i = 0; i <
GetRows(); ++i)
58 for (
size_t j = 0; j <
GetCols(); ++j)
70template <
typename T,
size_t Rows,
size_t Cols,
typename D>
76template <
typename T,
size_t Rows,
size_t Cols,
typename D>
81 for (
size_t i = 0; i <
GetRows(); ++i)
83 for (
size_t j = 0; j <
GetCols(); ++j)
92template <
typename T,
size_t Rows,
size_t Cols,
typename D>
98template <
typename T,
size_t Rows,
size_t Cols,
typename D>
103 for (
size_t j = 1; j <
GetCols(); ++j)
108 for (
size_t i = 1; i <
GetRows(); ++i)
110 for (
size_t j = 0; j <
GetCols(); ++j)
119template <
typename T,
size_t Rows,
size_t Cols,
typename D>
124 for (
size_t j = 1; j <
GetCols(); ++j)
126 s = std::max(
s,
Eval(0, j));
140template <
typename T,
size_t Rows,
size_t Cols,
typename D>
150 for (
size_t i = 1; i <
GetRows(); ++i)
152 for (
size_t j = 0; j <
GetCols(); ++j)
161template <
typename T,
size_t Rows,
size_t Cols,
typename D>
166 for (
size_t j = 1; j <
GetCols(); ++j)
171 for (
size_t i = 1; i <
GetRows(); ++i)
173 for (
size_t j = 0; j <
GetCols(); ++j)
182template <
typename T,
size_t Rows,
size_t Cols,
typename D>
197template <
typename T,
size_t Rows,
size_t Cols,
typename D>
205template <
typename T,
size_t Rows,
size_t Cols,
typename D>
213 for (
size_t i = 1; i <
GetRows(); ++i)
217 if (std::fabs(
curr) > std::fabs(
best))
227template <
typename T,
size_t Rows,
size_t Cols,
typename D>
235 for (
size_t i = 1; i <
GetRows(); ++i)
239 if (std::fabs(
curr) < std::fabs(
best))
249template <
typename T,
size_t Rows,
size_t Cols,
typename D>
255template <
typename T,
size_t Rows,
size_t Cols,
typename D>
260 for (
size_t i = 0; i <
GetRows(); ++i)
262 for (
size_t j = 0; j <
GetCols(); ++j)
271template <
typename T,
size_t Rows,
size_t Cols,
typename D>
277template <
typename T,
size_t Rows,
size_t Cols,
typename D>
285template <
typename T,
size_t Rows,
size_t Cols,
typename D>
293template <
typename T,
size_t Rows,
size_t Cols,
typename D>
294template <
size_t R,
size_t C,
typename E>
303template <
typename T,
size_t Rows,
size_t Cols,
typename D>
304template <
size_t R,
size_t C,
typename E>
313template <
typename T,
size_t Rows,
size_t Cols,
typename D>
321template <
typename T,
size_t Rows,
size_t Cols,
typename D>
328template <
typename T,
size_t Rows,
size_t Cols,
typename D>
335template <
typename T,
size_t Rows,
size_t Cols,
typename D>
342template <
typename T,
size_t Rows,
size_t Cols,
typename D>
349template <
typename T,
size_t Rows,
size_t Cols,
typename D>
356template <
typename T,
size_t Rows,
size_t Cols,
typename D>
363template <
typename T,
size_t Rows,
size_t Cols,
typename D>
370template <
typename T,
size_t Rows,
size_t Cols,
typename D>
378template <
typename T,
size_t Rows,
size_t Cols,
typename D>
386template <
typename T,
size_t Rows,
size_t Cols,
typename D>
387template <
size_t R,
size_t C,
typename E,
typename U>
388std::enable_if_t<(IsMatrixSizeDynamic<Rows, Cols>() ||
Cols == 1) &&
398 for (
size_t i = 1; i < GetRows(); ++i)
406template <
typename T,
size_t Rows,
size_t Cols,
typename D>
407template <
size_t R,
size_t C,
typename E,
typename U>
408std::enable_if_t<(IsMatrixSizeDynamic<Rows, Cols>() ||
422template <
typename T,
size_t Rows,
size_t Cols,
typename D>
423template <
size_t R,
size_t C,
typename E,
typename U>
424std::enable_if_t<(IsMatrixSizeDynamic<Rows, Cols>() ||
441template <
typename T,
size_t Rows,
size_t Cols,
typename D>
442template <
size_t R,
size_t C,
typename E,
typename U>
443std::enable_if_t<(IsMatrixSizeDynamic<Rows, Cols>() ||
446 ((
R == 2 ||
R == 3) &&
C == 1)),
451 assert((GetRows() == 2 || GetRows() == 3) && GetCols() == 1 &&
452 normal.GetRows() == GetRows() && normal.GetCols() == 1);
455 return (*
this) - 2 * Dot(normal) * normal;
458template <
typename T,
size_t Rows,
size_t Cols,
typename D>
459template <
size_t R,
size_t C,
typename E,
typename U>
460std::enable_if_t<(IsMatrixSizeDynamic<Rows, Cols>() ||
463 ((
R == 2 ||
R == 3) &&
C == 1)),
468 assert((GetRows() == 2 || GetRows() == 3) && GetCols() == 1 &&
469 normal.GetRows() == GetRows() && normal.GetCols() == 1);
472 return (*
this) - this->Dot(normal) * normal;
475template <
typename T,
size_t Rows,
size_t Cols,
typename D>
477std::enable_if_t<(IsMatrixSizeDynamic<Rows, Cols>() ||
487template <
typename T,
size_t Rows,
size_t Cols,
typename D>
489std::enable_if_t<(IsMatrixSizeDynamic<Rows, Cols>() ||
496 using V = Matrix<T, 3, 1>;
498 V
a(((std::fabs(
Eval(1, 0)) > 0 || std::fabs(
Eval(2, 0)) > 0) ? V(1, 0, 0)
504 return std::make_tuple(
a, b);
507template <
typename T,
size_t Rows,
size_t Cols,
typename D>
510 return static_cast<D&
>(*this);
513template <
typename T,
size_t Rows,
size_t Cols,
typename D>
516 return static_cast<const D&
>(*this);
519template <
typename T,
size_t Rows,
size_t Cols,
typename D>
526template <
typename T,
size_t Rows,
size_t Cols,
typename D>
533template <
typename T,
size_t Rows,
size_t Cols,
typename D>
545template <
typename T,
size_t Rows,
size_t Cols,
typename D>
575template <
typename T,
size_t Rows,
size_t Cols,
typename D>
586 for (
size_t i = 0; i <
m.
GetRows(); ++i)
594 if (std::fabs(
a(
k, i)) >
maxEl)
614 T c = -
a(
k, i) /
a(i, i);
616 for (
size_t j = i; j <
m.
GetRows(); ++j)
624 a(
k, j) +=
c *
a(i, j);
630 for (
size_t i = 0; i <
m.
GetRows(); ++i)
638template <
typename T,
size_t Rows,
size_t Cols,
typename D>
645template <
typename T,
size_t Rows,
size_t Cols,
typename D>
657template <
typename T,
size_t Rows,
size_t Cols,
typename D>
683template <
typename T,
size_t Rows,
size_t Cols,
typename D>
803template <
typename T,
size_t Rows,
size_t Cols,
typename Derived>
820 for (
size_t i = 0; i <
n; ++i)
826 for (
size_t k = i + 1;
k <
n; ++
k)
828 if (std::fabs(
a(
k, i)) >
maxEl)
838 for (
size_t k = i;
k <
n; ++
k)
843 for (
size_t k = 0;
k <
n; ++
k)
850 for (
size_t k = 0;
k <
n; ++
k)
857 T c = -
a(
k, i) /
a(i, i);
859 for (
size_t j = 0; j <
n; ++j)
869 a(
k, j) +=
c *
a(i, j);
875 for (
size_t k = 0;
k <
n; ++
k)
879 for (
size_t j = 0; j <
n; ++j)
888template <
typename T,
size_t Rows,
size_t Cols>
894template <
typename T,
size_t Rows,
size_t Cols>
900template <
typename T,
size_t Rows,
size_t Cols>
906template <
typename T,
size_t Rows,
size_t Cols,
typename M1>
912template <
typename T,
size_t Rows,
size_t Cols,
typename M1>
918template <
typename T,
size_t Rows,
size_t Cols,
typename M1>
929template <
typename T,
size_t Rows,
size_t Cols,
typename M1>
935template <
typename T,
size_t Rows,
size_t Cols,
typename M1>
941template <
typename T,
size_t Rows,
size_t Cols,
typename M1>
952template <
typename T,
size_t Rows,
size_t Cols,
typename M1>
958template <
typename T,
size_t Rows,
size_t Cols,
typename M1>
964template <
typename T,
size_t Rows,
size_t Cols,
typename M1>
971 return (j > i) ? m_mat1(i, j) : 0;
974 return (j >= i) ? m_mat1(i, j) : 0;
979 return (j < i) ? m_mat1(i, j) : 0;
982 return (j <= i) ? m_mat1(i, j) : 0;
985template <
typename T,
size_t Rows,
size_t Cols,
typename M1>
991template <
typename T,
size_t Rows,
size_t Cols,
typename M1>
997template <
typename T,
size_t Rows,
size_t Cols,
typename M1>
1001 return m_mat1(j, i);
1004template <
typename T,
size_t Rows,
size_t Cols,
typename M1,
typename UOp>
1010template <
typename T,
size_t Rows,
size_t Cols,
typename M1,
typename UOp>
1016template <
typename T,
size_t Rows,
size_t Cols,
typename M1,
typename UOp>
1020 return m_op(m_mat1(i, j));
1023template <
typename T,
size_t Rows,
size_t Cols,
typename M1>
1029template <
typename T,
size_t Rows,
size_t Cols,
typename M1>
1035template <
typename T,
size_t Rows,
size_t Cols,
typename M1>
1041template <
typename T,
size_t Rows,
size_t Cols,
typename E1,
typename E2,
1049template <
typename T,
size_t Rows,
size_t Cols,
typename E1,
typename E2,
1057template <
typename T,
size_t Rows,
size_t Cols,
typename E1,
typename E2,
1060 size_t i,
size_t j)
const
1062 return m_op(m_mat1(i, j), m_mat2(i, j));
1065template <
typename T,
size_t Rows,
size_t Cols,
typename M1,
typename M2>
1074template <
typename T,
size_t Rows,
size_t Cols,
typename M1,
typename M2>
1083template <
typename T,
size_t Rows,
size_t Cols,
typename M1,
typename M2>
1092template <
typename T,
size_t Rows,
size_t Cols,
typename M1,
typename M2>
1101template <
typename T,
size_t Rows,
size_t Cols,
typename M1,
typename M2>
1110template <
typename T,
size_t Rows,
size_t Cols,
typename M1,
typename M2>
1119template <
typename T,
size_t Rows,
size_t Cols,
typename M1,
typename BOp>
1126template <
typename T,
size_t Rows,
size_t Cols,
typename M1,
typename BOp>
1133template <
typename T,
size_t Rows,
size_t Cols,
typename M1,
typename BOp>
1135 size_t i,
size_t j)
const
1137 return m_op(m_mat1(i, j), m_scalar2);
1140template <
typename T,
size_t Rows,
size_t Cols,
typename M1>
1148template <
typename T,
size_t Rows,
size_t Cols,
typename M1>
1156template <
typename T,
size_t Rows,
size_t Cols,
typename M1>
1164template <
typename T,
size_t Rows,
size_t Cols,
typename M1>
1172template <
typename T,
size_t Rows,
size_t Cols,
typename M2,
typename BOp>
1179template <
typename T,
size_t Rows,
size_t Cols,
typename M2,
typename BOp>
1186template <
typename T,
size_t Rows,
size_t Cols,
typename M2,
typename BOp>
1188 size_t i,
size_t j)
const
1190 return m_op(m_scalar1, m_mat2(i, j));
1193template <
typename T,
size_t Rows,
size_t Cols,
typename M2>
1201template <
typename T,
size_t Rows,
size_t Cols,
typename M2>
1209template <
typename T,
size_t Rows,
size_t Cols,
typename M2>
1217template <
typename T,
size_t Rows,
size_t Cols,
typename M2>
1225template <
typename T,
size_t Rows,
size_t Cols,
typename M1,
typename M2,
1226 typename M3,
typename TOp>
1233template <
typename T,
size_t Rows,
size_t Cols,
typename M1,
typename M2,
1234 typename M3,
typename TOp>
1241template <
typename T,
size_t Rows,
size_t Cols,
typename M1,
typename M2,
1242 typename M3,
typename TOp>
1244 size_t i,
size_t j)
const
1246 return m_op(m_mat1(i, j), m_mat2(i, j), m_mat3(i, j));
1249template <
typename T,
size_t Rows,
size_t Cols,
typename M1,
typename M2,
1263template <
typename T,
size_t Rows,
size_t Cols,
typename M1,
typename M2>
1269template <
typename T,
size_t Rows,
size_t Cols,
typename M1,
typename M2>
1275template <
typename T,
size_t Rows,
size_t Cols,
typename M1,
typename M2>
1278 T sum = m_mat1(i, 0) * m_mat2(0, j);
1280 for (
size_t k = 1;
k < m_mat1.
GetCols(); ++
k)
1282 sum += m_mat1(i,
k) * m_mat2(
k, j);
1288template <
typename T,
size_t R1,
size_t C1,
size_t R2,
size_t C2,
typename M1,
constexpr size_t GetRows() const
Definition MatrixExpression-Impl.hpp:889
constexpr size_t GetCols() const
Definition MatrixExpression-Impl.hpp:895
constexpr T operator()(size_t, size_t) const
Definition MatrixExpression-Impl.hpp:901
constexpr size_t GetRows() const
Definition MatrixExpression-Impl.hpp:907
T operator()(size_t i, size_t j) const
Definition MatrixExpression-Impl.hpp:919
constexpr size_t GetCols() const
Definition MatrixExpression-Impl.hpp:913
constexpr size_t GetCols() const
Definition MatrixExpression-Impl.hpp:1051
constexpr size_t GetRows() const
Definition MatrixExpression-Impl.hpp:1043
constexpr T operator()(size_t i, size_t j) const
Definition MatrixExpression-Impl.hpp:1059
Base class for matrix expression.
Definition MatrixExpression.hpp:94
ValueType Determinant() const
Definition MatrixExpression-Impl.hpp:198
std::enable_if_t<(IsMatrixSizeDynamic< Rows, Cols >()||((Rows==2||Rows==3) &&Cols==1)) &&(IsMatrixSizeDynamic< R, C >()||((R==2||R==3) &&C==1)), Matrix< U, Rows, 1 > Projected(const MatrixExpression< T, R, C, E > &normal) const
Returns the projected vector to the surface with given surface normal.
std::enable_if_t<(IsMatrixSizeDynamic< Rows, Cols >()||(Rows==2 &&Cols==1)) &&(IsMatrixSizeDynamic< R, C >()||(R==2 &&C==1)), U > Cross(const MatrixExpression< T, R, C, E > &expression) const
Definition MatrixExpression-Impl.hpp:412
bool IsSimilar(const MatrixExpression< T, R, C, E > &m, double tol=std::numeric_limits< double >::epsilon()) const
Definition MatrixExpression-Impl.hpp:46
Matrix< T, Rows, Cols > Inverse() const
Returns inverse matrix.
Definition MatrixExpression-Impl.hpp:371
std::enable_if_t<(IsMatrixSizeDynamic< Rows, Cols >()||(Rows==3 &&Cols==1)), std::tuple< Matrix< U, 3, 1 >, Matrix< U, 3, 1 > > Tangentials() const
Returns the tangential vectors for this vector.
constexpr size_t GetRows() const
Returns the number of rows.
Definition MatrixExpression-Impl.hpp:21
ValueType AbsMin() const
Definition MatrixExpression-Impl.hpp:141
ValueType Avg() const
Definition MatrixExpression-Impl.hpp:93
ValueType Sum() const
Definition MatrixExpression-Impl.hpp:77
size_t SubdominantAxis() const
Definition MatrixExpression-Impl.hpp:228
MatrixTri< T, Rows, Cols, const Derived & > StrictLowerTri() const
Returns strictly lower triangle part of this matrix.
Definition MatrixExpression-Impl.hpp:337
ValueType Length() const
Definition MatrixExpression-Impl.hpp:278
ValueType NormSquared() const
Definition MatrixExpression-Impl.hpp:256
ValueType FrobeniusNorm() const
Definition MatrixExpression-Impl.hpp:272
constexpr size_t GetCols() const
Returns the number of columns.
Definition MatrixExpression-Impl.hpp:27
std::enable_if_t<(IsMatrixSizeDynamic< Rows, Cols >()||(Rows==2 &&Cols==1)), Matrix< U, 2, 1 > Tangential() const
Returns the tangential vector for this vector.
ValueType DistanceTo(const MatrixExpression< T, R, C, E > &other) const
Returns the distance to the other vector.
MatrixTri< T, Rows, Cols, const Derived & > UpperTri() const
Returns upper triangle part of this matrix (including the diagonal).
Definition MatrixExpression-Impl.hpp:358
MatrixDiagonal< T, Rows, Cols, const Derived & > Diagonal() const
Returns diagonal part of this matrix.
Definition MatrixExpression-Impl.hpp:323
MatrixUnaryOp< U, Rows, Cols, const Derived &, TypeCast< T, U > > CastTo() const
ValueType Min() const
Definition MatrixExpression-Impl.hpp:99
MatrixTranspose< T, Rows, Cols, const Derived & > Transposed() const
Definition MatrixExpression-Impl.hpp:365
T Eval(size_t i, size_t j) const
Returns the evaluated value for (i, j).
Definition MatrixExpression-Impl.hpp:33
ValueType LengthSquared() const
Definition MatrixExpression-Impl.hpp:286
constexpr bool IsSquare() const
Returns true if this matrix is a square matrix.
Definition MatrixExpression-Impl.hpp:71
ValueType AbsMax() const
Definition MatrixExpression-Impl.hpp:162
MatrixTri< T, Rows, Cols, const Derived & > LowerTri() const
Returns lower triangle part of this matrix (including the diagonal).
Definition MatrixExpression-Impl.hpp:351
ValueType Norm() const
Definition MatrixExpression-Impl.hpp:250
ValueType DistanceSquaredTo(const MatrixExpression< T, R, C, E > &other) const
Returns the squared distance to the other vector.
size_t DominantAxis() const
Definition MatrixExpression-Impl.hpp:206
ValueType Max() const
Definition MatrixExpression-Impl.hpp:120
Matrix< T, Rows, Cols > Eval() const
Definition MatrixExpression-Impl.hpp:39
std::enable_if_t<(IsMatrixSizeDynamic< Rows, Cols >()||((Rows==2||Rows==3) &&Cols==1)) &&(IsMatrixSizeDynamic< R, C >()||((R==2||R==3) &&C==1)), Matrix< U, Rows, 1 > Reflected(const MatrixExpression< T, R, C, E > &normal) const
Returns the reflection vector to the surface with given surface normal.
Derived & GetDerived()
Returns actual implementation (the subclass).
Definition MatrixExpression-Impl.hpp:508
MatrixScalarElemWiseBinaryOp< T, Rows, Cols, const Derived &, std::divides< T > > Normalized() const
Definition MatrixExpression-Impl.hpp:315
MatrixOffDiagonal< T, Rows, Cols, const Derived & > OffDiagonal() const
Returns off-diagonal part of this matrix.
Definition MatrixExpression-Impl.hpp:330
MatrixTri< T, Rows, Cols, const Derived & > StrictUpperTri() const
Returns strictly upper triangle part of this matrix.
Definition MatrixExpression-Impl.hpp:344
ValueType Trace() const
Definition MatrixExpression-Impl.hpp:183
constexpr size_t GetCols() const
Definition Matrix-Impl.hpp:266
constexpr size_t GetRows() const
Definition Matrix-Impl.hpp:260
constexpr size_t GetRows() const
Definition MatrixExpression-Impl.hpp:1264
constexpr size_t GetCols() const
Definition MatrixExpression-Impl.hpp:1270
T operator()(size_t i, size_t j) const
Definition MatrixExpression-Impl.hpp:1276
constexpr size_t GetCols() const
Definition MatrixExpression-Impl.hpp:936
constexpr size_t GetRows() const
Definition MatrixExpression-Impl.hpp:930
T operator()(size_t i, size_t j) const
Definition MatrixExpression-Impl.hpp:942
constexpr size_t GetCols() const
Definition MatrixExpression-Impl.hpp:1127
constexpr T operator()(size_t i, size_t j) const
Definition MatrixExpression-Impl.hpp:1134
constexpr size_t GetRows() const
Definition MatrixExpression-Impl.hpp:1120
constexpr size_t GetRows() const
Definition MatrixExpression-Impl.hpp:1227
constexpr T operator()(size_t i, size_t j) const
Definition MatrixExpression-Impl.hpp:1243
constexpr size_t GetCols() const
Definition MatrixExpression-Impl.hpp:1235
constexpr T operator()(size_t i, size_t j) const
Definition MatrixExpression-Impl.hpp:998
constexpr size_t GetCols() const
Definition MatrixExpression-Impl.hpp:992
constexpr size_t GetRows() const
Definition MatrixExpression-Impl.hpp:986
constexpr size_t GetCols() const
Definition MatrixExpression-Impl.hpp:959
T operator()(size_t i, size_t j) const
Definition MatrixExpression-Impl.hpp:965
constexpr size_t GetRows() const
Definition MatrixExpression-Impl.hpp:953
constexpr size_t GetCols() const
Definition MatrixExpression-Impl.hpp:1011
constexpr size_t GetRows() const
Definition MatrixExpression-Impl.hpp:1005
constexpr T operator()(size_t i, size_t j) const
Definition MatrixExpression-Impl.hpp:1017
constexpr T operator()(size_t i, size_t j) const
Definition MatrixExpression-Impl.hpp:1187
constexpr size_t GetRows() const
Definition MatrixExpression-Impl.hpp:1173
constexpr size_t GetCols() const
Definition MatrixExpression-Impl.hpp:1180
Definition pybind11Utils.hpp:22
MatrixCSR< T > operator-(const MatrixCSR< T > &a)
Definition MatrixCSR-Impl.hpp:1029
constexpr auto Max(const MatrixExpression< T, Rows, Cols, M1 > &a, const MatrixExpression< T, Rows, Cols, M2 > &b)
Definition MatrixExpression-Impl.hpp:1111
constexpr auto Ceil(const MatrixExpression< T, Rows, Cols, M1 > &a)
Definition MatrixExpression-Impl.hpp:1024
constexpr auto Min(const MatrixExpression< T, Rows, Cols, M1 > &a, const MatrixExpression< T, Rows, Cols, M2 > &b)
Definition MatrixExpression-Impl.hpp:1102
constexpr auto ElemMul(const MatrixExpression< T, Rows, Cols, M1 > &a, const MatrixExpression< T, Rows, Cols, M2 > &b)
Definition MatrixExpression-Impl.hpp:1084
std::enable_if_t< std::is_arithmetic< T >::value, T > AbsMax(T x, T y)
Returns the absolute maximum value among the two inputs.
Definition MathUtils-Impl.hpp:84
std::enable_if_t< std::is_arithmetic< T >::value, T > Clamp(T val, T low, T high)
Returns the clamped value.
Definition MathUtils-Impl.hpp:166
constexpr auto Floor(const MatrixExpression< T, Rows, Cols, M1 > &a)
Definition MatrixExpression-Impl.hpp:1030
Matrix< T, Rows, 1 > Vector
Definition Matrix.hpp:719
MatrixCSR< T > operator+(const MatrixCSR< T > &a, const MatrixCSR< T > &b)
Definition MatrixCSR-Impl.hpp:1035
constexpr auto ElemDiv(const MatrixExpression< T, Rows, Cols, M1 > &a, const MatrixExpression< T, Rows, Cols, M2 > &b)
Definition MatrixExpression-Impl.hpp:1093
MatrixCSR< T > operator/(const MatrixCSR< T > &a, T b)
Definition MatrixCSR-Impl.hpp:1090
Vector< T, 3 > operator*(const Quaternion< T > &q, const Vector< T, 3 > &v)
Returns quaternion q * vector v.
Definition Quaternion-Impl.hpp:543
std::enable_if_t< std::is_arithmetic< T >::value, T > AbsMin(T x, T y)
Returns the absolute minimum value among the two inputs.
Definition MathUtils-Impl.hpp:78