Ssht
1.3.3
Fast and exact spin spherical harmonic transforms
|
Macros | |
#define | NREPEAT 5 |
#define | MAX(a, b) ((a) > (b) ? (a) : (b)) |
Functions | |
double | ran2_dp (int idum) |
void | ssht_test_gen_flm_complex (complex double *flm, int L, int spin, int seed) |
void | ssht_test_gen_flm_real (complex double *flm, int L, int seed) |
void | ssht_test_gen_lb_flm_complex (complex double *flm, int L_zero, int L, int spin, int seed) |
void | ssht_test_gen_lb_flm_real (complex double *flm, int L0, int L, int seed) |
int | null_test (const complex double *X, int n) |
int | nan_test (const complex double *X, int n) |
int | main (int argc, char *argv[]) |
Applies SSHT algorithms to perform inverse and forward spherical harmonic transforms (respectively) to check that the original signal is reconstructed exactly (to numerical precision). Test is performed on a random signal with harmonic coefficients uniformly sampled from (-1,1).
Usage: ssht_test B spin [B0], e.g. ssht_test 64 2 32
#define MAX | ( | a, | |
b | |||
) | ((a) > (b) ? (a) : (b)) |
#define NREPEAT 5 |
int main | ( | int | argc, |
char * | argv[] | ||
) |
Null and Nan Tests!
Harmonic Coefficients
Harmonic Coefficients
Null and Nan Tests!
Harmonic Coefficients
Harmonic Coefficients
Null and Nan Tests!
Harmonic Coefficients
Harmonic Coefficients
Null and Nan Tests!
Harmonic Coefficients
Harmonic Coefficients
Null and Nan Tests!
Harmonic Coefficients
Harmonic Coefficients
Null and Nan Tests!
Harmonic Coefficients
Harmonic Coefficients
Null and Nan Tests!
Harmonic Coefficients
Harmonic Coefficients
Null and Nan Tests!
Harmonic Coefficients
Harmonic Coefficients
Null and Nan Tests!
Harmonic Coefficients
Harmonic Coefficients
Null and Nan Tests!
Harmonic Coefficients
Harmonic Coefficients
Null and Nan Tests!
Harmonic Coefficients
Harmonic Coefficients
Null and Nan Tests!
Harmonic Coefficients
Harmonic Coefficients
Null and Nan Tests!
Harmonic Coefficients
Harmonic Coefficients
Null and Nan Tests!
Harmonic Coefficients
Harmonic Coefficients
Null and Nan Tests!
Harmonic Coefficients
Harmonic Coefficients
Null and Nan Tests!
Harmonic Coefficients
Harmonic Coefficients
int nan_test | ( | const complex double * | X, |
int | n | ||
) |
Test for nan vector
[in] | X | vector of complex double |
[in] | n | length of X. |
Y | returns int 1 if no nans, 0 if nan entires exist. i.e. 0 = fail, 1 = pass. |
int null_test | ( | const complex double * | X, |
int | n | ||
) |
Test for null vector
[in] | X | vector of complex double |
[in] | n | length of X. |
Y | returns int 0 if all zeros, 1 if non-zero i.e. 0 = fail, 1 = pass. |
double ran2_dp | ( | int | idum | ) |
Generate uniform deviate in range [0,1) given seed. (Using double precision.)
[in] | idum | Seed. |
ran_dp | Generated uniform deviate. |
void ssht_test_gen_flm_complex | ( | complex double * | flm, |
int | L, | ||
int | spin, | ||
int | seed | ||
) |
Generate random spherical harmonic coefficients of a complex signal.
[out] | flm | Random spherical harmonic coefficients generated. |
[in] | L | Harmonic band-limit. |
[in] | spin | Spin number. |
[in] | seed | Integer seed required for random number generator. |
none |
void ssht_test_gen_flm_real | ( | complex double * | flm, |
int | L, | ||
int | seed | ||
) |
Generate random spherical harmonic coefficients of a real spin=0 signal.
[out] | flm | Random spherical harmonic coefficients generated. |
[in] | L | Harmonic band-limit. |
[in] | seed | Integer seed required for random number generator. |
none |
void ssht_test_gen_lb_flm_complex | ( | complex double * | flm, |
int | L0, | ||
int | L, | ||
int | spin, | ||
int | seed | ||
) |
Generate random spherical harmonic coefficients of a complex signal with lower band-limit.
[out] | flm | Random spherical harmonic coefficients generated. |
[in] | L0 | Lower harmonic band-limit. |
[in] | L | Upper harmonic band-limit. |
[in] | spin | Spin number. |
[in] | seed | Integer seed required for random number generator. |
none |
void ssht_test_gen_lb_flm_real | ( | complex double * | flm, |
int | L0, | ||
int | L, | ||
int | seed | ||
) |
Generate random spherical harmonic coefficients of a real spin=0 signal with lower band-limit.
[out] | flm | Random spherical harmonic coefficients generated. |
[in] | L0 | Lower harmonic band-limit. |
[in] | L | Upper harmonic band-limit. |
[in] | seed | Integer seed required for random number generator. |
none |