Go to the documentation of this file.
43 char const *
const varname);
261 for (c1 = 0; c1 < N; c1++) {
262 for (c2 = 0; c2 < N; c2++) {
263 for (c3 = 0; c3 < N; c3++) {
264 sum = sum + U[c1*N+c3]*T[c3*N+c2];
337 for (i = 2; i <= n; i++) {
338 P = (2.0*i-1)*x*P_1/i -(i-1.0)*P_2/i;
346 #ifdef FNFT_ENABLE_SHORT_NAMES
347 #define misc_print_buf(...) fnft__misc_print_buf(__VA_ARGS__)
348 #define misc_rel_err(...) fnft__misc_rel_err(__VA_ARGS__)
349 #define misc_hausdorff_dist(...) fnft__misc_hausdorff_dist(__VA_ARGS__)
350 #define misc_sech(...) fnft__misc_sech(__VA_ARGS__)
351 #define misc_l2norm2(...) fnft__misc_l2norm2(__VA_ARGS__)
352 #define misc_filter(...) fnft__misc_filter(__VA_ARGS__)
353 #define misc_filter_inv(...) fnft__misc_filter_inv(__VA_ARGS__)
354 #define misc_filter_nonreal(...) fnft__misc_filter_nonreal(__VA_ARGS__)
355 #define misc_merge(...) fnft__misc_merge(__VA_ARGS__)
356 #define misc_downsample(...) fnft__misc_downsample(__VA_ARGS__)
357 #define misc_CSINC(...) fnft__misc_CSINC(__VA_ARGS__)
358 #define misc_nextpowerof2(...) fnft__misc_nextpowerof2(__VA_ARGS__)
359 #define misc_resample(...) fnft__misc_resample(__VA_ARGS__)
360 #define misc_mat_mult_proto(...) fnft__misc_mat_mult_proto(__VA_ARGS__)
361 #define misc_mat_mult_2x2(...) fnft__misc_mat_mult_2x2(__VA_ARGS__)
362 #define misc_mat_mult_4x4(...) fnft__misc_mat_mult_4x4(__VA_ARGS__)
363 #define misc_legendre_poly(...) fnft__misc_legendre_poly(__VA_ARGS__)
int32_t FNFT_INT
Definition: fnft_numtypes.h:56
size_t FNFT_UINT
Definition: fnft_numtypes.h:62
FNFT_REAL fnft__misc_rel_err(const FNFT_INT len, FNFT_COMPLEX const *const vec_numer, FNFT_COMPLEX const *const vec_exact)
Relative l1 error between two vectors.
FNFT_UINT fnft__misc_nextpowerof2(const FNFT_UINT number)
Closest larger or equal number that is a power of two.
FNFT_INT fnft__misc_resample(const FNFT_UINT D, const FNFT_REAL eps_t, FNFT_COMPLEX const *const q, const FNFT_REAL delta, FNFT_COMPLEX *const q_new)
Resamples an array.
static void fnft__misc_mat_mult_proto(const FNFT_UINT N, FNFT_COMPLEX *const U, FNFT_COMPLEX *const T, FNFT_COMPLEX *const TM)
Multiples two square matrices of size N.
Definition: fnft__misc.h:257
FNFT_INT fnft__misc_downsample(const FNFT_UINT D, FNFT_COMPLEX const *const q, FNFT_UINT *const Dsub_ptr, FNFT_COMPLEX **qsub_ptr, FNFT_UINT *const first_last_index)
Downsamples an array.
FNFT_COMPLEX fnft__misc_sech(FNFT_COMPLEX Z)
Hyperbolic secant.
FNFT_REAL fnft__misc_hausdorff_dist(const FNFT_UINT lenA, FNFT_COMPLEX const *const vecA, const FNFT_UINT lenB, FNFT_COMPLEX const *const vecB)
Hausdorff distance between two vectors.
FNFT_REAL fnft__misc_l2norm2(const FNFT_UINT N, FNFT_COMPLEX const *const Z, const FNFT_REAL a, const FNFT_REAL b)
Squared l2 norm.
FNFT_INT fnft__misc_filter_nonreal(FNFT_UINT *N_ptr, FNFT_COMPLEX *const vals, const FNFT_REAL tol_im)
Filter array based on specified tolerance.
double complex FNFT_COMPLEX
Definition: fnft_numtypes.h:47
static FNFT_REAL fnft__misc_legendre_poly(const FNFT_UINT n, const FNFT_REAL x)
This routine returns the nth degree Legendre polynomial at x.
Definition: fnft__misc.h:327
FNFT_INT fnft__misc_merge(FNFT_UINT *N_ptr, FNFT_COMPLEX *const vals, FNFT_REAL tol)
Merges elements in an array with distance lower than tol.
double FNFT_REAL
Definition: fnft_numtypes.h:40
FNFT_INT fnft__misc_filter(FNFT_UINT *const N, FNFT_COMPLEX *const vals, FNFT_COMPLEX *const rearrange_as_well, FNFT_REAL const *const bounding_box)
Filters array by retaining elements inside a bounding box.
void fnft__misc_print_buf(const FNFT_INT len, FNFT_COMPLEX const *const buf, char const *const varname)
Helper function for debugging. Prints an array in MATLAB style.
static void fnft__misc_mat_mult_4x4(FNFT_COMPLEX *const U, FNFT_COMPLEX *const T)
Multiples two square matrices of size 4.
Definition: fnft__misc.h:306
FNFT_INT fnft__misc_filter_inv(FNFT_UINT *const N_ptr, FNFT_COMPLEX *const vals, FNFT_COMPLEX *const rearrange_as_well, FNFT_REAL const *const bounding_box)
Filters array by retaining elements outside a bounding box.
static void fnft__misc_mat_mult_2x2(FNFT_COMPLEX *const U, FNFT_COMPLEX *const T)
Multiples two square matrices of size 2.
Definition: fnft__misc.h:285
FNFT_COMPLEX fnft__misc_CSINC(FNFT_COMPLEX x)
Sinc function for complex arguments.