C 库函数 - cosh()
C 语言教程
· 2019-02-23 07:12:43
描述
C 库函数 double cosh(double x) 返回 x 的双曲余弦。
声明
下面是 cosh() 函数的声明。
double cosh(double x)
参数
- x -- 浮点值。
返回值
该函数返回 x 的双曲余弦。
实例
下面的实例演示了 cosh() 函数的用法。
#include <stdio.h>
#include <math.h>
int main ()
{
double x;
x = 0.5;
printf("%lf 的双曲余弦是 %lf\n", x, cosh(x));
x = 1.0;
printf("%lf 的双曲余弦是 %lf\n", x, cosh(x));
x = 1.5;
printf("%lf 的双曲余弦是 %lf\n", x, cosh(x));
return(0);
}
让我们编译并运行上面的程序,这将产生以下结果:
0.500000 的双曲余弦是 1.127626 1.000000 的双曲余弦是 1.543081 1.500000 的双曲余弦是 2.352410
点击查看所有 C 语言教程 文章: https://codercto.com/courses/l/17.html
The Four
Scott Galloway / Portfolio / 2017-10-3 / USD 28.00
NEW YORK TIMES BESTSELLER USA TODAY BESTSELLER Amazon, Apple, Facebook, and Google are the four most influential companies on the planet. Just about everyone thinks they know how they got there.......一起来看看 《The Four》 这本书的介绍吧!