> 其他 >
指针对函数操作int(*p)()用矩形法求定积分通用函数求sinx,cosx,(1+x)^2,范围分别是0-1,(-1)-1,1-2
sin、cos已在系统的数学函数库中,程序开头要用#include “math.h”;而(1+x)2函数须自编.
人气:327 ℃ 时间:2020-04-13 12:43:48
解答
结果小数位后面第5位就不准确了#include "Stdio.h"#include "Math.h"#define N 1000000long int i;double dx,sum;int main(void){double sinfun(double,double);double cosfun(double,double);double myfun(double,d...
推荐
猜你喜欢
© 2025 79432.Com All Rights Reserved.
电脑版|手机版