- Trending Categories
- Data Structure
- Networking
- RDBMS
- Operating System
- Java
- iOS
- HTML
- CSS
- Android
- Python
- C Programming
- C++
- C#
- MongoDB
- MySQL
- Javascript
- PHP

- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who

# Explain important functions in math.h library functions using C language

All mathematical related functions are stored in math.h header file in C programming language. The functions are explained below in detail.

## sin()

This function is used to find the sin value of its argument.

The syntax of sin() function is as follows −

double sin(double a);

For example,

double a=sin(3.14/2);

The output is as follows −

a=1 (approx.)

## cos()

It is used to find the cos value of its argument.

The syntax for cos() function is as follows −

double cos(double a);

For example,

double a=cos(3.14/2);

The output is as follows −

a=0 (approx.)

## tan()

It is used to find the tan value of its argument.

The syntax for tan() function is as follows −

double tan (double a);

For example,

double a=tan(3.14/2);

## exp()

It is used to find the exponent value of its argument.

The syntax for exp() is as follows −

double exp (double a);

For example,

double a=exp(4.6);

## floor()

It is used to round down a float number.

The syntax for floor() function is as follows −

Double floor(double a);

For example,

Double a=floor(93.58);

The output is as follows −

A=93

## ceil()

It is used to round up a float number.

The syntax for ceil() function is as follows −

Double ceil(double a);

For example,

Double a=ceil(93.58);

The output is as follows −

A=94

## abs()

It is used to find the absolute value of an integer.

The syntax for abs() function is as follows −

int abs(int a);

For example,

Int a= abs(-6);

The output is as follows −

a=6

## pow()

It is used to find the power of a value.

The syntax for pow() function is as follows −

double pow(double a,double b);

For example,

double x=pow(2,3)

The output is as follows −

x=8

## sqrt()

It is used to find the square root value of its argument.

The syntax for sqrt() function is as follows −

double sqrt(double a);

For example,

double x=sqrt(36);

The output is as follows −

x=6

- Related Questions & Answers
- Explain fgetc() and fputc() functions in C language
- Explain string library functions with suitable examples in C
- Explain the functions putw() and getw() in C language
- Explain unformatted input and output functions in C language
- What are JavaScript Math Functions?
- Explain scope rules related to the functions in C language
- Explain putc() and getc() functions of files in C language
- What are the C library functions?
- Explain C Error handling functions
- Wide char and library functions in C++
- Functions in Rust programming language
- Explain Generator functions in JavaScript?
- Explain shorthand functions in JavaScript?
- What are the predefined functions in C language?
- What are string searching functions in C language?