寻求二维傅里叶变换C++程序(急!在线等!)

来源:百度知道 编辑:UC知道 时间:2024/05/26 06:05:09
我所需要的这个程序,不是直接进行运行计算,而是希望作为另外一个程序的头文件进行调用,不知道各位大侠能不能帮帮我!谢谢!
如能提供逆变换的程序,我将另外加分!

快速傅里叶变换(二维)源程序
#include <stdio.h>
#include <stdlib.h>
#include <math.h>

#define PI 3.1415927

struct COMPLEX

{

float re;

float im;

} cplx , * Hfield , * S , * R , * w;

int n , m;
int ln , lm;

void initiate ();
void dfft ();
void rdfft ();
void showresult ();
void fft (int l , int k);
int reverse (int t , int k);
void W (int l);
int loop (int l);
void conjugate ();

void add (struct COMPLEX * x , struct COMPLEX * y , struct COMPLEX * z);
void sub (struct COMPLEX * x , struct COMPLEX * y , struct COMPLEX * z);
void mul (struct COMPLEX * x , struct COMPLEX * y , struct COMPLEX * z);
struct COMPLEX * Hread(int i , int j);
void Hwrite (int i , int j , struct COMPLEX x);

int main ()

{

initiate ();