来自「一个用C++编写的积分算法,可以用VC编译.」· 代码 · 共 26 行

TXT
26
字号
#define max   100 
struct  poly
{
	double coff[max];
	int    index[max];
};
class   newton
{private:
	double  coefficient(int k,int n);
public:
    double newtoncores(double a,double b,double (*f)(double),int n);
	double newtoncores(double a,double b,double (*f)(double),int m,int n);
	double romberg(double a,double b,double (*f)(double));
 };
 class  gauss
 {
 private:
	rowgauss(double A[max][max],double B[max],int n);	 
	legendre(double  A[max],int n);	 
	qiebixuefu(double A[max],int n);
    newton(double  A[max],double result[max],int n);
	double derivate(double A[max],double B[max],double x,int n);
 public:
	 double integral(double a,double b,double (*f)(double),int n);
	 
 };

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?