c语言:用牛顿的迭代法求方程在1.5附近的根

日期:2013-11-14 20:25:13 人气:1

c语言:用牛顿的迭代法求方程在1.5附近的根

#include #include typedef double (*Fun)(double);//函数指针double fun(double x) //原函数 { return 2*pow(x,3.0)-4*pow(x,2.0)+3*x-6;}double dfun(double x) //函数导数 { return 6*x*x-8*x+3;}double newtown(double x0, Fun f, Fun df) 
    A+
热门评论