-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathREADME
78 lines (46 loc) · 1.75 KB
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
FFTWPP 1.0
1. What is this?
This library makes it easier to use FFTW (http://www.fftw.org) in C++ if you
plan to switch between data types. FFTW uses different function and type names
for different numeric data types. FFTWPP combines all these functions and types
into a templated struct, that just takes your desired data type and gives you
all the types and functions:
e.g.:
typedef fftw::fftwpp<long double> FFTW;
typedef typename FFTW::plan fftwpp_plan;
typedef typename FFTW::complex fftwpp_complex;
# this is fftwl_plan_dft_1d
fftwpp_plan FFTW::plan_dft_1d(...);
Additionaly this library contains a few new datatypes:
typedef typename FFTW::vector fftwvector;
typedef typename FFTW::cvector fftwcvector;
These are std::vectors for real and complex numbers respectively which
internally use fftw[l,f,q,]_malloc() to allocate memory. FFTWs functions
require pointers and the FFTW struct contains a static method to convert them
to pointers:
fftwvector my_data(512*512*10);
auto my_ptr = FFTW::ptr(my_data);
As a special bonus there are also datatypes which are based on
boost::ublas::vector which in turn are then based upon the above vectors
and work in the same way:
typedef typename FFTW::uvector uvector;
typedef typename FFTW::ucvector ucvector;
2. Compilation and Installation:
Compile:
cd build
cmake ..
make
Compile for debugging:
cd build
cmake -DCMAKE_BUILD_TYPE=Debug ..
make
Install locally:
cd build
cmake -DCMAKE_INSTALL_PREFIX=$HOME/local ..
make install
Deinstall:
make uninstall
3. License:
This library is released under the GPL v3, see COPYING
4. Contact:
FFTWPP was written by Alexander Blinne <[email protected]>