2 #include "translations.h"
11 complex double result_A
, result_B
;
12 } testcase_single_trans_t
;
14 testcase_single_trans_t testcases_Taylor
[] = {
15 #include "testcases_taylor"
22 qpms_trans_calculator
*c
= qpms_trans_calculator_init(lMax
, QPMS_NORMALIZATION_TAYLOR
);
23 for( int rr
= 0; rr
< repete
; rr
++)
24 for(testcase_single_trans_t
*tc
= testcases_Taylor
; tc
->J
!= QPMS_BESSEL_UNDEF
; tc
++) {
25 //if (tc->n > 40 || tc->nu > 40 ) continue;
26 complex double A_array
[c
->nelem
* c
->nelem
];
27 complex double B_array
[c
->nelem
* c
->nelem
];
28 qpms_trans_calculator_get_AB_arrays(c
, A_array
, B_array
, c
->nelem
, 1, tc
->kdlj
, true, tc
->J
);
30 complex double A
= qpms_trans_single_A_Taylor(tc
->m
, tc
->n
, tc
->mu
, tc
->nu
, tc
->kdlj
, true, tc
->J
);
31 complex double B
= qpms_trans_single_B_Taylor(tc
->m
, tc
->n
, tc
->mu
, tc
->nu
, tc
->kdlj
, true, tc
->J
);
32 printf("A = %.16f+%.16fj, relerr=%.16f, J=%d\n",
33 creal(A
), cimag(A
), (0 == cabs(tc
->result_A
- A
)) ? 0 :
34 cabs(tc
->result_A
- A
)/((cabs(A
) < cabs(tc
->result_A
)) ? cabs(A
) : cabs(tc
->result_A
)),
36 printf("B = %.16f+%.16fj, relerr=%.16f, J=%d\n",
37 creal(B
), cimag(B
), (0 == cabs(tc
->result_B
- B
)) ? 0 :
38 cabs(tc
->result_B
- B
)/((cabs(B
) < cabs(tc
->result_B
)) ? cabs(B
) : cabs(tc
->result_B
)),