libftsh
A Fast Transform for Spherical Harmonics
|
Local Cosine Transform based on FFTW. More...
#include "libftsh.h"
Defines | |
#define | ENTEREXIT 0 |
Functions | |
void | lctw (REAL *fcn, Ftrigtw_Plan *main_plan) |
void | lctw_init (Ftrigtw_Plan *main_plan, int flags, int numpts) |
Local Cosine Transform based on FFTW.
Summary:
void lctw | ( | REAL * | fcn, |
Ftrigtw_Plan * | main_plan | ||
) |
Computes the local cosine transform of fcn and puts the coeficients back into fcn.
The local cosine transform is also known as the type 4 discrete cosine transform.
This is the LCT at half integer points. Is its own inverse.
INPUTS:
OUTPUT: fcn. Puts the coefficients in fcn. specifically: \[ f(k) =norm \sum_{j=0}^{numpts-1} f(j) \cos\left(\pi\frac{(k+1/2)(j+1/2)}{numpts}\right) \]
numpts-1 (k+0.5) (j+0.5) fcn[k]= SUM fcn[j] cos( PI ---------------- ) *norm j=0 numpts
set for \(L^2\) normalization.
NOTES:
void lctw_init | ( | Ftrigtw_Plan * | main_plan, |
int | flags, | ||
int | numpts | ||
) |
This routine initializes for lctw
We initialize trigonometic things used by the lct and dct portions, and call the initailizer for the fftw real transform (forward).
INPUTS:
OUTPUTS: main_plan is filled in:
NOTES: