编程表达式求函数值题

loading 分享 2026-11-12 下载文档

例如: fun( 6.66, 8 ) = 0.307 fun( 6.66, 15 )= 0.930

(提示:若第 i-1 项的值为 t ,则第 i 项的值为 -t*x*x/(2*i-3)/(2*i-2)) ***************************************************************/ double fun ( double x, int n )

/*===================================================================*/ {

double y=0.0;

return y; }

/*-----------------------------------------------------------------------*/ 9.下述函数 double fun(double x, int n) 的功能是计算如下 公式的值:(其中 x^n 表示 x 的 n 次方,n! 为 n 的阶乘) x^2 x^4 x^6 x^(2*n-2) fun( x, n )= 1 + ─── + ─── + ─── + … ───── 2! 4! 6! (2*n-2)! 前 n 项之和,其中 n≥1 。 例如: fun( 6.66, 8 ) = 389.443 fun( 6.66, 15 )= 390.276

(提示:若第 i-1 项的值为 t ,则第 i 项的值为 t*x*x/(2*i-3)/(2*i-2)) ***************************************************************/ ***************************************************************/ double fun ( double x, int n )

/*========================================================*/ {

double y=0.0;

return y; }

/*-----------------------------------------------------------------------*/


编程表达式求函数值题.doc 将本文的Word文档下载到电脑
搜索更多关于: 编程表达式求函数值题 的文档
相关推荐
相关阅读