libftsh
A Fast Transform for Spherical Harmonics
|
Precompute and save data for direct1 spherical harmonic transform. More...
#include "libftsh.h"
Defines | |
#define | ENTEREXIT 0 |
Functions | |
void | direct1_tofile (int numpts, int band_limit, REAL *node, REAL *weight, FILE *fp) |
void | init_direct1 (Pm_Direct_d **out, int halfpts, int band_limit, REAL *node) |
void | dump_direct1 (int numpts, int band_limit, REAL *node, REAL *weight, Pm_Direct_d *pmn_matrix, FILE *fp) |
Precompute and save data for direct1 spherical harmonic transform.
Summary:
void direct1_tofile | ( | int | numpts, |
int | band_limit, | ||
REAL * | node, | ||
REAL * | weight, | ||
FILE * | fp | ||
) |
This routine initializes the direct transform for spherical harmonics (version 1) and dumps it to a file.
INPUTS:
OUTPUTS: fp - the objects created are written onto the file pointed to by fp, in binary format. The file must be opened before calling this routine.
NOTES:
void dump_direct1 | ( | int | numpts, |
int | band_limit, | ||
REAL * | node, | ||
REAL * | weight, | ||
Pm_Direct_d * | pmn_matrix, | ||
FILE * | fp | ||
) |
This routine dumps the initialization constructed by init_direct1 and general parameters for the direct transform for spherical harmonics, dense version.
INPUTS:
OUTPUTS: fp -- the objects above are written into the file pointed to by fp, in binary format. The file must be opened before calling this routine.
void init_direct1 | ( | Pm_Direct_d ** | out, |
int | halfpts, | ||
int | band_limit, | ||
REAL * | node | ||
) |
This routine initializes for the transform for spherical harmonics, direct version 1. This version simple precomputes the Pm matrices and stores them in dense matrix format.
INPUTS:
OUTPUTS: out -- memory is allocated for band_limit (==order_limit) Pm_Direct_d structures, each representing the matrix for one m. Various bits of memory are allocated for these, and values filled in.