Skip to content

Latest commit

 

History

History
27 lines (24 loc) · 447 Bytes

std_math_sinh.md

File metadata and controls

27 lines (24 loc) · 447 Bytes

#功能 计算参数x的双曲正弦函数值。 #原型 #include<math.h>
double sinh(double x) #实例

#include <stdio.h>
#include <math.h>

int main ()
{
   double x, ret;
   x = 0.5;

   ret = sinh(x);
   printf("The hyperbolic sine of %lf is %lf\n", x, ret);

   return(0);
}

输出结果为:

The hyperbolic sine of 0.500000 is 0.521095

#备注 双曲正弦函数的公式为sinh(x)=(exp(x) - exp(-x)) / 2.0