![]() |
3.2.3 |
Required for test if (ths->k == one_over_x) More...
Modules | |
fastsum_matlab | |
fastsum_test |
Data Structures | |
struct | fastsum_plan_ |
plan for fast summation algorithm More... |
Macros | |
#define | NF_KUB |
Include header for C99 complex datatype. | |
#define | EXACT_NEARFIELD (1U<< 0) |
Constant symbols. | |
#define | NEARFIELD_BOXES (1U<< 1) |
Typedefs | |
typedef double _Complex(* | kernel )(double, int, const double *) |
typedef struct fastsum_plan_ | fastsum_plan |
plan for fast summation algorithm |
Functions | |
int | max_i (int a, int b) |
max | |
double | fak (int n) |
factorial | |
double | binom (int n, int m) |
binomial coefficient | |
double | BasisPoly (int m, int r, double xx) |
basis polynomial for regularized kernel | |
double _Complex | regkern (kernel k, double xx, int p, const double *param, double a, double b) |
regularized kernel with K_I arbitrary and K_B smooth to zero | |
double _Complex | regkern1 (kernel k, double xx, int p, const double *param, double a, double b) |
regularized kernel with K_I arbitrary and K_B periodized (used in 1D) | |
double _Complex | regkern2 (kernel k, double xx, int p, const double *param, double a, double b) |
regularized kernel for even kernels with K_I even and K_B mirrored | |
double _Complex | regkern3 (kernel k, double xx, int p, const double *param, double a, double b) |
regularized kernel for even kernels with K_I even and K_B mirrored smooth to K(1/2) (used in dD, d>1) | |
double _Complex | linintkern (const double x, const double _Complex *Add, const int Ad, const double a) |
linear spline interpolation in near field with even kernels | |
double _Complex | quadrintkern (const double x, const double _Complex *Add, const int Ad, const double a) |
double _Complex | kubintkern (const double x, const double _Complex *Add, const int Ad, const double a) |
cubic spline interpolation in near field with even kernels | |
double _Complex | kubintkern1 (const double x, const double _Complex *Add, const int Ad, const double a) |
cubic spline interpolation in near field with arbitrary kernels | |
void | quicksort (int d, int t, double *x, double _Complex *alpha, int N) |
quicksort algorithm for source knots and associated coefficients | |
static void | BuildBox (fastsum_plan *ths) |
initialize box-based search data structures | |
static double _Complex | calc_SearchBox (int d, double *y, double *x, double _Complex *alpha, int start, int end_lt, const double _Complex *Add, const int Ad, int p, double a, const kernel k, const double *param, const unsigned flags) |
inner computation function for box-based near field correction | |
static double _Complex | SearchBox (double *y, fastsum_plan *ths) |
box-based near field correction | |
void | BuildTree (int d, int t, double *x, double _Complex *alpha, int N) |
recursive sort of source knots dimension by dimension to get tree structure | |
double _Complex | SearchTree (const int d, const int t, const double *x, const double _Complex *alpha, const double *xmin, const double *xmax, const int N, const kernel k, const double *param, const int Ad, const double _Complex *Add, const int p, const unsigned flags) |
fast search in tree of source knots for near field computation | |
void | fastsum_init_guru (fastsum_plan *ths, int d, int N_total, int M_total, kernel k, double *param, unsigned flags, int nn, int m, int p, double eps_I, double eps_B) |
initialization of fastsum plan | |
void | fastsum_finalize (fastsum_plan *ths) |
finalization of fastsum plan | |
void | fastsum_exact (fastsum_plan *ths) |
direct computation of sums | |
void | fastsum_precompute (fastsum_plan *ths) |
precomputation for fastsum | |
void | fastsum_trafo (fastsum_plan *ths) |
fast NFFT-based summation | |
double _Complex | gaussian (double x, int der, const double *param) |
double _Complex | multiquadric (double x, int der, const double *param) |
double _Complex | inverse_multiquadric (double x, int der, const double *param) |
double _Complex | logarithm (double x, int der, const double *param) |
double _Complex | thinplate_spline (double x, int der, const double *param) |
double _Complex | one_over_square (double x, int der, const double *param) |
double _Complex | one_over_modulus (double x, int der, const double *param) |
double _Complex | one_over_x (double x, int der, const double *param) |
double _Complex | inverse_multiquadric3 (double x, int der, const double *param) |
double _Complex | sinc_kernel (double x, int der, const double *param) |
double _Complex | cosc (double x, int der, const double *param) |
double _Complex | kcot (double x, int der, const double *param) |
double _Complex | one_over_cube (double x, int der, const double *param) |
Required for test if (ths->k == one_over_x)
#define NF_KUB |
void fastsum_init_guru | ( | fastsum_plan * | ths, |
int | d, | ||
int | N_total, | ||
int | M_total, | ||
kernel | k, | ||
double * | param, | ||
unsigned | flags, | ||
int | nn, | ||
int | m, | ||
int | p, | ||
double | eps_I, | ||
double | eps_B | ||
) |
initialization of fastsum plan
initialize fast summation plan
ths | The pointer to a fastsum plan. |
d | The dimension of the problem. |
N_total | The number of source knots x. |
M_total | The number of target knots y. |
kernel | The kernel function. |
param | The parameters for the kernel function. |
flags | Fastsum flags. |
nn | The expansion degree. |
m | The cut-off parameter for the NFFT. |
p | The degree of smoothness. |
eps_I | The inner boundary. |
eps_B | the outer boundary. |
Definition at line 600 of file fastsum.c.
References fastsum_plan_::Ad, fastsum_plan_::Add, fastsum_plan_::alpha, fastsum_plan_::b, fastsum_plan_::d, fastsum_plan_::eps_B, fastsum_plan_::eps_I, EXACT_NEARFIELD, fastsum_plan_::f, fastsum_plan_::flags, fastsum_plan_::k, fastsum_plan_::kernel_param, fastsum_plan_::M_total, max_i(), fastsum_plan_::mv1, fastsum_plan_::mv2, fastsum_plan_::n, fastsum_plan_::N_total, nfft_malloc(), fastsum_plan_::p, fastsum_plan_::x, and fastsum_plan_::y.
void fastsum_finalize | ( | fastsum_plan * | ths | ) |
finalization of fastsum plan
finalize plan
ths | The pointer to a fastsum plan. |
Definition at line 742 of file fastsum.c.
References fastsum_plan_::Add, fastsum_plan_::alpha, fastsum_plan_::b, EXACT_NEARFIELD, fastsum_plan_::f, fastsum_plan_::flags, fastsum_plan_::mv1, fastsum_plan_::mv2, nfft_free(), fastsum_plan_::x, and fastsum_plan_::y.
void fastsum_exact | ( | fastsum_plan * | ths | ) |
direct computation of sums
direct summation
ths | The pointer to a fastsum plan. |
Definition at line 775 of file fastsum.c.
References fastsum_plan_::alpha, fastsum_plan_::d, fastsum_plan_::f, fastsum_plan_::k, fastsum_plan_::kernel_param, fastsum_plan_::M_total, fastsum_plan_::N_total, fastsum_plan_::x, and fastsum_plan_::y.
void fastsum_precompute | ( | fastsum_plan * | ths | ) |
precomputation for fastsum
sort source nodes, precompute Fourier coefficients, etc.
ths | The pointer to a fastsum plan. |
Definition at line 802 of file fastsum.c.
References fastsum_plan_::Ad, fastsum_plan_::Add, fastsum_plan_::alpha, fastsum_plan_::b, BuildBox(), BuildTree(), fastsum_plan_::d, nfft_plan::d, fastsum_plan_::eps_B, fastsum_plan_::eps_I, EXACT_NEARFIELD, nfft_plan::f, fastsum_plan_::flags, fastsum_plan_::k, fastsum_plan_::kernel_param, nfft_plan::M_total, fastsum_plan_::MEASURE_TIME_t, fastsum_plan_::mv1, fastsum_plan_::mv2, fastsum_plan_::n, nfft_plan::N, fastsum_plan_::N_total, nfft_fftshift_complex(), nfft_plan::nfft_flags, nfft_precompute_lin_psi(), fastsum_plan_::p, regkern1(), regkern3(), fastsum_plan_::x, nfft_plan::x, and fastsum_plan_::y.
void fastsum_trafo | ( | fastsum_plan * | ths | ) |
fast NFFT-based summation
fast NFFT-based summation algorithm
ths | The pointer to a fastsum plan. |
Definition at line 940 of file fastsum.c.
References fastsum_plan_::Ad, fastsum_plan_::Add, fastsum_plan_::alpha, fastsum_plan_::b, fastsum_plan_::d, fastsum_plan_::eps_I, fastsum_plan_::f, nfft_plan::f, nfft_plan::f_hat, fastsum_plan_::flags, fastsum_plan_::k, fastsum_plan_::kernel_param, fastsum_plan_::M_total, fastsum_plan_::MEASURE_TIME_t, fastsum_plan_::mv1, fastsum_plan_::mv2, fastsum_plan_::N_total, nfft_plan::N_total, nfft_trafo(), fastsum_plan_::p, SearchBox(), SearchTree(), fastsum_plan_::x, and fastsum_plan_::y.