Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Borland C++ 2.x ( with Turbo C ) - <b>sinh() calculate hyperbolic sine</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 sinh()                  Calculate Hyperbolic Sine

 #include   <math.h>

 double     sinh(x);                     Hyperbolic sine
 double     x;                           Angle, in radians

    sinh() calculates the hyperbolic sine of 'x' radians.

       Returns:     Hyperbolic sine of 'x'.  If the result is too large,
                    matherr() is called with an OVERFLOW error, 'errno'
                    (defined in <errno.h>) is set to ERANGE (defined in
                    <errno.h>), and the value 'HUGE_VAL' (defined in
                    <math.h>) is returned.

         Notes:     Error handling can be modified with the matherr()
                    function.

                    OVERFLOW first occurs with 'x' greater than 7.0E2

   -------------------------------- Example ---------------------------------

    The following statements print the hyperbolic sine of pi/2 and 220 pi
    radians and check for overflow.

           #include <math.h>        /* for sinh()*/
           #include <stdio.h>       /* for printf() */
           #include <errno.h>      /* for errno and ERANGE */

           main()
           {
               double hsine, pi = 3.1415926535;

               hsine = sinh(pi/2.0);
               printf("hyperbolic sine of pi/2 = %e\n", hsine);
               errno = 0;
               hsine = sinh(220.0 * pi);
               if (errno == ERANGE)
                   printf("ERANGE error in sinh()\n");
               printf("hyperbolic sine of 220 * pi = %e\n", hsine);
           }


See Also: asin() cos() cosh() matherr() sin() tan()

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson