4 #ifndef VE_QUATERNION_H
5 #define VE_QUATERNION_H
27 double r()
const {
return r_ ;}
28 double i()
const {
return i_ ;}
29 double j()
const {
return j_ ;}
30 double k()
const {
return k_ ;}
32 void r(
double r) {r_ =
r;}
33 void i(
double i) {i_ =
i;}
34 void j(
double j) {j_ =
j;}
35 void k(
double k) {k_ =
k;}
a_quaternion operator+(const a_quaternion &x, const a_quaternion &y)
a_quaternion operator/(const a_quaternion &x, const a_quaternion &y)
bool operator==(const a_quaternion &a, const a_quaternion &b)
a_quaternion operator*(const a_quaternion &x, const double y)
a_quaternion operator-(a_quaternion &x)
bool operator!=(const a_quaternion &a, const a_quaternion &b)
a_quaternion(double r, double i, double j, double k)
friend std::ostream & operator<<(std::ostream &ost, const a_quaternion &x)
a_quaternion & conjugate()
a_quaternion operator/(const double b)
a_quaternion operator-(const a_quaternion &b)
a_quaternion operator+(const a_quaternion &b)
a_quaternion & operator*=(const double b)
a_quaternion & operator-=(const a_quaternion &b)
a_quaternion operator*(const double b)
a_quaternion & operator/=(const double b)
a_quaternion & operator=(const a_quaternion &b)
a_quaternion & operator+=(const a_quaternion &b)
a_quaternion(const a_quaternion &b)