1 #include <qpms/wigner.h>
6 qpms_quat4d_t q4
[8] = {
16 printf("original: (%g, %g, %g)\n", v
.x
, v
.y
, v
.z
);
17 for(int i
= 0; i
< 8; ++i
) {
18 for (int det
= -1; det
< 2; det
+= 2) {
19 const qpms_quat4d_t qr
= q4
[i
];
20 const qpms_quat_t qc
= qpms_quat_2c_from_4d(qr
);
21 const qpms_irot3_t r
= {qc
, det
};
22 const cart3_t w
= qpms_irot3_apply_cart3(r
, v
);
23 printf("[%+g %+g %+g %+g] -> [%+g%+gj %+g%+g] *%+d: ==> (%g, %g, %g)\n",
24 qr
.c1
, qr
.ci
, qr
.cj
, qr
.ck
, creal(qc
.a
), cimag(qc
.a
), creal(qc
.b
), cimag(qc
.b
),