|
| double | coeffs_c_inner (long long n, long long i, long long k, long long dim) |
| | Computes cₙ,ᵢ,ₖ= ∏_{j=i+1}^{⌊n/2⌋-k} (2n+d−2−4k−2j).
|
| |
| double | coeffs_c_outer (long long n, long long k, long long dim) |
| | Computes cₙ,ₖ=2⁻ᵏ/ cₙ,₀,ₖ ∏ⱼ₌₁ᵏ(2n+d−2j)∕((2n+d+2−4j)(2n+d−4j)).
|
| |
| void | coeffs_c_inner_hpdyad (unsigned int n, unsigned int i, unsigned int k, unsigned int dim, hpdyad_t *out) |
| | Computes cₙ,ᵢ,ₖ= ∏_{j=i+1}^{⌊n/2⌋-k} (2n+d−2−4k−2j) as hpdyad.
|
| |
| void | harmonic_h_inner_term_scalar_hpdyad (unsigned int n, unsigned int i, unsigned int k, unsigned int dim, hpdyad_t *out) |
| | Computes (-2)**(-i) · c_{n,i,k} · binom(i+k,k) as hpdyad.
|
| |
| void | harmonic_h_inner_term_multi_hpdyad (unsigned int dim, const unsigned int *alpha, const unsigned int *beta, const unsigned int *theta1, const unsigned int *theta2, hpdyad_t *out) |
| | Computes binom(i,β) × binom(α,θ₁) × θ₂!/(θ₂−θ₁)! as hpdyad.
|
| |
| double | harmonic_h_inner_sum (unsigned int k, unsigned int dim, const unsigned int *alpha, const unsigned int *gamma, unsigned int alphaAbs) |
| | Computes the inner sum h_inner(α,γ,k) using exact hpdyad arithmetic.
|
| |
| unsigned long long | precompute_harmonic_h_inner_chunk_size (unsigned int alphaAbs, unsigned int kMax, unsigned int dim, const unsigned int *alpha, unsigned long long *chunk_offset, unsigned long long *valid_count) |
| | Computes chunk offsets and valid entry counts for precomputed inner harmonic sums corresponding to k = 0, ..., floor(|alpha|/2). For each k, chunk_offset[k] stores the starting offset in the coeffs array where values corresponding to |gamma| = |alpha| - k are stored. valid_count[k] stores the number of valid gamma for that k.
|
| |
| void | precompute_harmonic_h_inner_sum (unsigned int alphaAbs, unsigned int dim, const unsigned int *alpha, const unsigned long long *chunk_offset, double *coeffs, unsigned int *exponents) |
| | Precomputes and stores inner harmonic sums h_inner(α,γ,k) and exponents (2γ-α) for all k = 0, ..., floor(|alpha|/2) and all gamma with |gamma| = |alpha| - k satisfying 2γ[i] >= α[i]. Coefficients are stored in coeffs starting at offsets given by chunk_offset[k]. Exponents are stored in exponents with stride dim, i.e., exponent i for entry n of chunk k is at exponents[(chunk_offset[k] + n) * dim + i]. Gamma is iterated in graded lexicographic order with total degree |alpha| - k.
|
| |
| double | harmonic_h (unsigned int k, unsigned int dim, const double *z, unsigned int alphaAbs, const unsigned long long *chunk_offset, const unsigned long long *valid_count, const double *coeffs, const unsigned int *exponents) |
| | Calculates the homogeneous harmonic polynomial h₍α,k₎ of degree |α|−2k such that y^α = ∑ₖ (y·y)^k h₍α,k₎(y); explicitly, h₍α,k₎(y)=c_{|α|,k} ∑{|γ|=|α|−k} y^{2γ−α} h_inner(α,γ,k). Uses precomputed coefficients and exponents to avoid multi-index iteration.
|
| |
Calculates the harmonic polynomials.
| void precompute_harmonic_h_inner_sum |
( |
unsigned int | alphaAbs, |
|
|
unsigned int | dim, |
|
|
const unsigned int * | alpha, |
|
|
const unsigned long long * | chunk_offset, |
|
|
double * | coeffs, |
|
|
unsigned int * | exponents ) |
Precomputes and stores inner harmonic sums h_inner(α,γ,k) and exponents (2γ-α) for all k = 0, ..., floor(|alpha|/2) and all gamma with |gamma| = |alpha| - k satisfying 2γ[i] >= α[i]. Coefficients are stored in coeffs starting at offsets given by chunk_offset[k]. Exponents are stored in exponents with stride dim, i.e., exponent i for entry n of chunk k is at exponents[(chunk_offset[k] + n) * dim + i]. Gamma is iterated in graded lexicographic order with total degree |alpha| - k.
Precomputes and stores inner harmonic sums h_inner(α,γ,k) and exponents (2γ-α) for all k = 0, ..., floor(|alpha|/2) and all gamma with |gamma| = |alpha| - k satisfying 2γ[i] >= α[i]. Coefficients are stored in coeffs starting at offsets given by chunk_offset[k]. Exponents are stored in exponents with stride dim, i.e., exponent i for entry n of chunk k is at exponents[(chunk_offset[k] + n) * dim + i]. Gamma is ordered identically to harmonic_h_update_outer_index.
- Parameters
-
| [in] | alphaAbs | total of alpha. |
| [in] | dim | dimension of alpha and gamma. |
| [in] | alpha | upper multi-index. |
| [in] | chunk_offset | starting offsets for each k. |
| [out] | coeffs | array storing precomputed inner harmonic sums. |
| [out] | exponents | array storing precomputed exponents (2γ-α), size = totalSize * dim. |