1 #include "translations.h"
7 #ifdef QPMS_PACKED_B_MULTIPLIERS
13 void qpms_trans_calculator_multipliers_B_general(
14 qpms_normalisation_t norm
,
15 complex double *dest
, int m
, int n
, int mu
, int nu
, int Qmax
) ;
19 #define MIN(x,y) ((x)<(y)?(x):(y))
22 // Python test: Qmax(M, n, mu, nu) = floor(min(n,nu,(n+nu+1-abs(M+mu))/2))
23 // q in IntegerRange(1, Qmax(-m,n,mu,nu))
26 qpms_trans_calculator
*c
= qpms_trans_calculator_init(lMax
, QPMS_NORMALISATION_XU
);
27 complex double dest
[lMax
+ 2];
29 for(int n
= 1; n
<= lMax
; ++n
)
30 for(int nu
= 1; nu
<= lMax
; ++nu
)
31 for(int m
= -n
; m
<= n
; ++m
)
32 for(int mu
= -nu
; mu
<= nu
; ++mu
){
33 int Qmax_alt
= MIN(n
,MIN(nu
,(n
+nu
+1-abs(mu
-m
))/2));
34 qpms_trans_calculator_multipliers_B_general(QPMS_NORMALISATION_XU_CS
,
35 dest
, m
, n
, mu
, nu
, Qmax_alt
);
36 for(int q
= BQ_OFFSET
; q
<= Qmax_alt
; ++q
) {
37 // int p = n + nu - 2*q;
38 int tubig
= cabs(dest
[q
-BQ_OFFSET
]) > 1e-8;
39 printf("%.16g + %.16g*I, // %d, %d, %d, %d, %d,%s\n",
40 creal(dest
[q
-BQ_OFFSET
]), cimag(dest
[q
-BQ_OFFSET
]), m
, n
, mu
, nu
, q
,
41 q
> Qmax_alt
? (tubig
?" //tubig":" //tu") : "");
48 qpms_trans_calculator_free(c
);