数学函数 - cosh

原型:extern float cosh(float x);

用法:#include <math.h>

功能:求x的双曲余弦值

说明:cosh(x)=(e^x+e^(-x))/2

举例:


      // cosh.c
      
      #include <syslib.h>
      #include <math.h>

      main()
      {
        float x;
        
        clrscr();        // clear screen
        textmode(0x00);  // 6 lines per LCD screen
        
        x=PI/4.;
        printf("cosh(%.4f)=%.4f\n",x,cosh(x));
        
        getchar();
        return 0;
      }
      
  
相关函数:sinh,tanh