NFFT Logo 3.0 API Reference
Main Page | Modules | Data Structures | Directories | File List | Data Fields | Globals

linogram_fft_test
[Polar FFT]


Functions

int linogram_grid (int T, int R, double *x, double *w)
 Generates the points x with weights w for the linogram grid with T slopes and R offsets.
int linogram_dft (fftw_complex *f_hat, int NN, fftw_complex *f, int T, int R, int m)
 discrete pseudo-polar FFT
int linogram_fft (fftw_complex *f_hat, int NN, fftw_complex *f, int T, int R, int m)
 NFFT-based pseudo-polar FFT.
int inverse_linogram_fft (fftw_complex *f, int T, int R, fftw_complex *f_hat, int NN, int max_i, int m)
 NFFT-based inverse pseudo-polar FFT.
int comparison_fft (FILE *fp, int N, int T, int R)
 Comparison of the FFTW, linogram FFT, and inverse linogram FFT.
int main (int argc, char **argv)
 test program for various parameters

Variables

double GLOBAL_elapsed_time

Function Documentation

int linogram_grid int  T,
int  R,
double *  x,
double *  w
 

Generates the points x with weights w for the linogram grid with T slopes and R offsets.

return the number of knots

Definition at line 25 of file linogram_fft_test.c.

Referenced by inverse_linogram_fft(), linogram_dft(), linogram_fft(), and main().

int linogram_dft fftw_complex *  f_hat,
int  NN,
fftw_complex *  f,
int  T,
int  R,
int  m
 

discrete pseudo-polar FFT

< index for nodes and freqencies

< plan for the nfft-2D

< knots and associated weights

< number of knots

< oversampling factor sigma=2

< oversampling factor sigma=2

init two dimensional NFFT plan

init nodes from linogram grid

init Fourier coefficients from given image

NFFT-2D

copy result

finalise the plans and free the variables

Definition at line 55 of file linogram_fft_test.c.

References nfft_plan::f, nfft_plan::f_hat, FFT_OUT_OF_PLACE, FFTW_INIT, GLOBAL_elapsed_time, linogram_grid(), nfft_plan::M_total, MALLOC_F, MALLOC_F_HAT, MALLOC_X, nfft_plan::N_total, ndft_trafo(), nfft_finalize(), nfft_init_guru(), nfft_second(), PRE_PHI_HUT, PRE_PSI, and nfft_plan::x.

Referenced by comparison_fft(), and main().

int linogram_fft fftw_complex *  f_hat,
int  NN,
fftw_complex *  f,
int  T,
int  R,
int  m
 

NFFT-based pseudo-polar FFT.

< index for nodes and freqencies

< plan for the nfft-2D

< knots and associated weights

< number of knots

< oversampling factor sigma=2

< oversampling factor sigma=2

init two dimensional NFFT plan

init nodes from linogram grid

precompute psi, the entries of the matrix B

init Fourier coefficients from given image

NFFT-2D

copy result

finalise the plans and free the variables

Definition at line 112 of file linogram_fft_test.c.

References nfft_plan::f, nfft_plan::f_hat, FFT_OUT_OF_PLACE, FFTW_INIT, GLOBAL_elapsed_time, linogram_grid(), nfft_plan::M_total, MALLOC_F, MALLOC_F_HAT, MALLOC_X, nfft_plan::N_total, nfft_finalize(), nfft_plan::nfft_flags, nfft_init_guru(), nfft_precompute_full_psi(), nfft_precompute_lin_psi(), nfft_precompute_psi(), nfft_second(), nfft_trafo(), PRE_FULL_PSI, PRE_LIN_PSI, PRE_PHI_HUT, PRE_PSI, and nfft_plan::x.

Referenced by comparison_fft(), and main().

int inverse_linogram_fft fftw_complex *  f,
int  T,
int  R,
fftw_complex *  f_hat,
int  NN,
int  max_i,
int  m
 

NFFT-based inverse pseudo-polar FFT.

< index for nodes and freqencies

< plan for the nfft-2D

< plan for the inverse nfft

< knots and associated weights

< index for iterations

< number of knots

< oversampling factor sigma=2

< oversampling factor sigma=2

init two dimensional NFFT plan

init two dimensional infft plan

init nodes, given samples and weights

precompute psi, the entries of the matrix B

initialise damping factors

initialise some guess f_hat_0

solve the system

copy result

finalise the plans and free the variables

Definition at line 178 of file linogram_fft_test.c.

References CGNR, infft_plan::f_hat_iter, FFT_OUT_OF_PLACE, FFTW_INIT, infft_plan::flags, GLOBAL_elapsed_time, infft_before_loop(), infft_finalize(), infft_init_advanced(), infft_loop_one_step(), linogram_grid(), nfft_plan::M_total, MALLOC_F, MALLOC_F_HAT, MALLOC_X, infft_plan::mv, nfft_plan::N, nfft_plan::N_total, nfft_finalize(), nfft_plan::nfft_flags, nfft_init_guru(), nfft_precompute_full_psi(), nfft_precompute_lin_psi(), nfft_precompute_psi(), nfft_second(), infft_plan::p_hat_iter, PRE_FULL_PSI, PRE_LIN_PSI, PRE_PHI_HUT, PRE_PSI, PRECOMPUTE_DAMP, PRECOMPUTE_WEIGHT, infft_plan::w, infft_plan::w_hat, nfft_plan::x, and infft_plan::y.

Referenced by comparison_fft(), and main().

int main int  argc,
char **  argv
 

test program for various parameters

< linogram FFT size NxN

< number of directions/offsets

< number of knots of linogram grid

< knots and associated weights

< number of iterations

Hence, comparison of the FFTW, linogram FFT, and inverse linogram FFT

generate knots of linogram grid

load data

direct linogram FFT

Test of the linogram FFT with different m

fast linogram FFT

error of fast linogram FFT

Test of the inverse linogram FFT for different m in dependece of the iteration number

inverse linogram FFT

compute maximum error

free the variables

Definition at line 339 of file linogram_fft_test.c.

References comparison_fft(), inverse_linogram_fft(), linogram_dft(), linogram_fft(), linogram_grid(), and nfft_error_l_infty_complex().


Generated on 1 Nov 2006 by Doxygen 1.4.4