Welcome to collectivesolver - Programming & Software Q&A with code examples. A website with trusted programming answers. All programs are tested and work.

Contact: aviboots(AT)netvision.net.il

Buy a domain name - Register cheap domain names from $0.99 - Namecheap

Scalable Hosting That Grows With You

Secure & Reliable Web Hosting, Free Domain, Free SSL, 1-Click WordPress Install, Expert 24/7 Support

Semrush - keyword research tool

Boost your online presence with premium web hosting and servers

Disclosure: My content contains affiliate links.

39,907 questions

51,839 answers

573 users

How to use sinh() function to get the hyperbolic sine of an angle of N radians in C

1 Answer

0 votes
#include <stdio.h>     
#include <math.h>
 
#define PI 3.14159265
 
int main(int argc, char **argv)
{   
	printf("sinh(PI / 6) = %f\n", sinh(PI / 6));
    printf("sinh(PI / 2) = %f\n", sinh(PI / 2));
	printf("sinh(PI / 180) = %f\n", sinh(PI / 180));
    printf("sinh(-2 * PI / 4) = %f\n", sinh(-2 * PI / 4));
    printf("sinh(+0) = %f\n", sinh(0.0));
    printf("sinh(-0) = %f\n", sinh(-0.0));
    printf("sinh(+1) = %f\n", sinh(1.0));
    printf("sinh(-1) = %f\n", sinh(-1.0));
    printf("sinh(log(2.0)) = %f\n", sinh(log(2.0)));
  
    return 0;
}
 
/*
run:
   
sinh(PI / 6) = 0.547853
sinh(PI / 2) = 2.301299
sinh(PI / 180) = 0.017454
sinh(-2 * PI / 4) = -2.301299
sinh(+0) = 0.000000
sinh(-0) = -0.000000
sinh(+1) = 1.175201
sinh(-1) = -1.175201
sinh(log(2.0)) = 0.750000

*/

 



answered Mar 30, 2016 by avibootz
...