Commit 58d40f7f authored by niklas.baumgarten's avatar niklas.baumgarten
Browse files

adapted utils

parent e38cf85f
......@@ -60,7 +60,7 @@ void fft(vector<complex<double>> &in, vector<complex<double>> &out) {
}
}
void fft(vector<double> &in, vector<double> &out) {
void fft(const vector<double> &in, vector<double> &out) {
int N = in.size();
vector<complex<double>> in_complex;
vector<complex<double>> out_complex;
......@@ -107,7 +107,7 @@ void fft2(const vector<vector<complex<double>>> &in,
delete[] out_arr;
}
void fft2(vector<vector<double>> &in, vector<vector<double>> &out) {
void fft2(const vector<vector<double>> &in, vector<vector<double>> &out) {
int N2 = in.size();
int N1 = in[0].size();
vector<vector<complex<double>>> in_complex;
......
......@@ -7,26 +7,27 @@
#include <complex>
#include <fftw3.h>
std::pair<double, double> linear_fit(std::vector<double> &x, std::vector<double> &y);
std::vector
<double> linspace(const double &start, const double &end, int num);
std::vector<double> linspace(const double &start,
const double &end, int num);
void fft(int N, fftw_complex *in, fftw_complex *out);
void fft(std::vector
<std::complex<double>> &in, std::vector
<std::complex<double>> &out);
void fft(std::vector<std::complex<double>> &in,
std::vector<std::complex<double>> &out);
void fft(std::vector
<double> &in, std::vector
<double> &out);
void fft(const std::vector<double> &in,
std::vector<double> &out);
void fft2(int N2, int N1, fftw_complex *in, fftw_complex *out);
void fft2(const std::vector<std::vector<std::complex<double>>> &in, std::vector<std::vector<std::complex<double>>> &out);
void fft2(const std::vector<std::vector<std::complex<double>>> &in,
std::vector<std::vector<std::complex<double>>> &out);
void fft2(std::vector<std::vector<double>> &in, std::vector<std::vector<double>> &out);
void fft2(const std::vector<std::vector<double>> &in,
std::vector<std::vector<double>> &out);
double calc_mean(const std::vector<double> &vec);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment