pre-define maths function in C

sinh arithmetic function in C language with example

sinh arithmetic function in C language with example

In this tutorial, we will discuss sinh arithmetic function in C language with example

Description

sinh arithmetic function in C language returns the hyperbolic sine value of the radians angle x

sinh() : In the C Programming language, the sinh() function is used to calculate hyperbolic sine value of given arguments

 

Declaration

The declaration for the sinh function in C programming Language is

double sinh(double x);

 

Parameter or Arguments list

parameter of sinh() function is

x – this is a floating point value assigned to an angle as the parameter of this function and always measured in radians.

 

Returns

The sinh function returns hyperbolic sine value of x, measured in radians

 

Required header

The required header file for the sinh function in the C language is:

#include <math.h>

Example

Program 1

#include <stdio.h>
#include <stdlib.h>

int main()
{
    double x=0.5,y=1;

    printf("Hyperbolic sine value of %f is:%f\n",x,sinh(x));
    printf("Hyperbolic sine value of %f is:%f\n",y,sinh(y));
    getch();
    return 0;
}

 

When the above program is compiled and run, it will produce the following result

hyperbolic sine value of 0.500000 is: 0.521095
hyperbolic sine value of 1.000000 is: 1.175201

Program 2

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

int main()
{   //define the variable
    double sinhValue;
    double inputValue;
    //get input from user
    printf("Please enter the value to calculate sinh value :");
    scanf("%lf",&inputValue);
    //calculate the Hyperbolic sine value
    sinhValue=sinh(inputValue);
    //display the Hyperbolic sine value
     printf("\nHyperbolic sine value of %lf is %lf\n",inputValue,sinhValue);
    getch();
    return 0;
}


When the above program is compiled and run, it will produce the following result

Please enter the value to calculate sinh value :0.6
Hyperbolic sine value of 0.600000is 0.636654

 

Other C programming language functions that are  similar to the cosine function      

cosh function   in C  language                               

tanh function in C language

abs function in C language

floor function in C language

ceil function in C language

round function in C language

sqrt function in C language

pow function in C language

exp function in C language

log function in C language

log10 function in C language

trunc function in C language

 

 

suggested for you

Function in C language

User defined function in C language

Arithmetic functions in C Language

String function in C language

tanh function in C Programming language
cosh arithmetic function in C language with example
Karmehavannan

I am Mr S.Karmehavannan. Founder and CEO of this website. This website specially designed for the programming learners and very especially programming beginners, this website will gradually lead the learners to develop their programming skill.

Recent Posts

PHP Star Triangle pattern program

PHP Star Triangle pattern program In this tutorial, we will discuss about PHP Star Triangle…

6 months ago

PHP Full Pyramid pattern program

PHP Full Pyramid pattern program In this tutorial, we will discuss about PHP Full Pyramid…

6 months ago

5 methods to add two numbers in Java

5 methods to add two numbers in Java In this tutorial, we will discuss the…

6 months ago

Python Full Pyramid star pattern program

Python full Pyramid star pattern program In this tutorial, we will discuss  the concept of…

9 months ago

Write a function or method to convert C into F -Entered by user

Write a function or method to convert C into F -Entered by the user In…

1 year ago

How to write a function or method to convert Celsius into Fahrenheit

How to write a function or method to convert Celsius into Fahrenheit In this tutorial,…

1 year ago