astro-informatics / s2let

Fast wavelet transforms on the sphere.
http://astro-informatics.github.io/s2let
GNU General Public License v3.0
11 stars 2 forks source link

s2let_spin_lowered_normalization is not defined #13

Open paddyroddy opened 4 years ago

paddyroddy commented 4 years ago

s2let_spin_lowered_normalization is used in here https://github.com/astro-informatics/src_s2let/blob/master/src/main/matlab/s2let_curvelet_tiling.m but has no definition

GasperJu commented 2 years ago

Is this problem solved? Apparently, I'm facing a problem with the code that can be due to this.

paddyroddy commented 2 years ago

don't think so, at least not in main

jasonmcewen commented 2 years ago

I found this helped function in some of the curvelet branches:

/*!
 * Computes the normalization factor for spin-lowered wavelets,
 * which is sqrt((l+s)!/(l-s)!).
 *
 * \param[in]  el    Harmonic index el.
 * \param[in]  spin  Spin number the wavelet was lowered from.
 */
static double s2let_spin_lowered_normalization(int el, int spin)
{
    double factor = 1;
    int s;

    for (s = -ABS(spin)+1; s <= ABS(spin); ++s)
    {
        factor *= el+s;
    }

    if (spin > 0)
        return sqrt(factor);
    else
        return sqrt(1.0/factor);
}

@jenniferyhchan Where was the curvelet implementation left? Did we ever merge into main? I seem to recall that we scratched the C implementation and just went for a Matlab implementation. Is that correct? Perhaps we should delete the old branches or merge to main if appropriate?