na7
代码说明:
Orthogonal Polynomials Approximation 数值分析,计算正交基多项式的系数 (Given a function f and a set of m >0 distinct points . You are supposed to write a function to approximate f by an orthogonal polynomial using the exact function values at the given m points with a weight assigned to each point . The total error must be no larger than a given tolerance. Format of function int OPA( double (*f)(double t), int m, double x[], double w[], double c[], double*eps ) where the function pointer double (*f)(double t) defines the function f int m is the number of points double x[] contains points double w[] contains the values of a weight function at the given points x[] double c[] contains the coefficients of the approximation polynomial double*eps is passed into the function as the tolerance for the error, and is supposed to be returned as the value of error. The function OPA is supposed to return the degree of the approximation polynomial. Note: a constant Max_n is defined so that if the total error is still not small enough when n = Ma)
文件列表:
na7.cpp,4031,2011-11-25
下载说明:请别用迅雷下载,失败请重下,重下不扣分!