在c++中使用递归方法的问题
Problem using recursive method in c++
我有一个类,在像这样的.h中定义
#ifndef JLLABOUR_H
#define JLLABOUR_H
class JLLabour{
public:
JLLabour(int, int);
double* recursivefft(double*,int);
void FFT(int*);
~JLLabour();
private:
int width;
int height;
};
#endif // JLLABOUR_H
在我的.cpp中,我有递归函数的定义,问题是当我再次调用它时,在编译过程中,它不允许我继续,因为方法还没有定义。我不知道如何解决这个问题,请帮忙。
#include <JLLabour.h>
double* JLLabour::recursivefft(double* x,int asize){
//operations and declartions...
//...
even = recursiveFFT(sum,m); //<-- the problem is here, in the recursion.
odd = recursiveFFT(diff,m);
// more operations....
return result;
}
}
仅供参考,我正在Linux下编译,使用Qt,因为我正在开发一个图形应用程序。。。
C++区分大小写。您的方法称为recursivefft
,而不是recursiveFFT
。
相关文章:
- C++:正在检查LinkedList中的回文-递归方法-错误
- 数组元素打印的递归方法
- 返回不停止函数,递归函数问题?(编程练习,动态规划,Levenshtein 回溯)
- 我对 leetcode 72 上的递归方法感到茫然
- 使用递归方法遇到分段错误
- 我的链接列表反向递归方法的代码的问题是什么?
- 在链接列表中找到值的递归方法
- 我应该如何实现递归方法以找到在C++中形成最大堆的多种方法
- 使用递归方法将矢量作为输入时进行分割故障
- 使用递归方法的类,使用int矢量元素作为输入
- 3D 迷宫递归方法 - C++
- 这种遍历二叉树的递归方法在一些递归后崩溃!为什么?
- 迭代器回到递归方法的开头
- 如何创建一个递归方法来比较两个值
- 为什么将十进制转换为二进制的递归方法比迭代、使用和返回字符串更快
- 递归 N-骑士问题
- 递归方法中的 C++ 凸包
- 如何将查找组合的几个循环代码转换为递归方法
- 删除单向链表最后一个元素的递归方法
- 在c++中使用递归方法的问题