22 return { x - other.
x, y - other.
y , z - other.
z };
27 return x*x + y * y + z *
z;
31 return { x * scalar , y * scalar , z * scalar };
35 return x * s.
x + y * s.
y + z * s.
z;
64 for(
auto i = 0;
i < 3;
i++ )
66 for(
auto j = 0;
j < 3;
j++ )
78 for(
auto i = 0;
i < 3;
i++ )
80 for(
auto j = 0;
j < 3;
j++ )
83 for(
auto l = 0; l < 3; l++ )
85 sum += mat[
i][l] * other.
mat[l][
j];
97 res.
x = mat[0][0] * other.
x + mat[0][1] * other.
y + mat[0][2] * other.
z;
98 res.
y = mat[1][0] * other.
x + mat[1][1] * other.
y + mat[1][2] * other.
z;
99 res.
z = mat[2][0] * other.
x + mat[2][1] * other.
y + mat[2][2] * other.
z;
105 std::vector< double >
res;
106 for(
auto i = 0;
i < 3;
i++ )
108 for(
auto j = 0;
j < 3;
j++ )
110 res.push_back( mat[
i][
j] );
151 return { rot[0], rot[3], rot[6],
152 rot[1], rot[4], rot[7],
153 rot[2], rot[5], rot[8] };
165 return alpha == other.
alpha && beta == other.
beta && gamma == other.
gamma;
169 return !(*
this == other);
173 return (alpha < other.
alpha) ||
174 (alpha == other.
alpha && beta < other.
beta) ||
175 (alpha == other.
alpha && beta == other.
beta && gamma < other.
gamma);
190 double get_fx()
const {
return k_mat.rot[0]; }
191 double get_fy()
const {
return k_mat.rot[4]; }
192 double get_ppx()
const {
return k_mat.rot[2]; }
193 double get_ppy()
const {
return k_mat.rot[5]; }
rotation_in_angles extract_angles_from_rotation(const double r[9])
bool operator<(const rotation_in_angles &other)
double3x3 operator*(const double3x3 &other)
double3 operator*(const double3 &other)
const int N_BASIC_DIRECTIONS
bool operator!=(const double3 d)
double & operator[](int i)
double operator*(const double3 &s) const
double3 operator-(const double3 &other)
matrix_3x3 transposed() const
k_matrix(matrix_3x3 const &mat)
bool operator!=(const rotation_in_angles &other)
bool operator==(const rotation_in_angles &other)
std::vector< double > to_vector()
matrix_3x3 extract_rotation_from_angles(const rotation_in_angles &rot_angles)
double3 operator*(const double &scalar) const
bool operator==(const double3 d)