sinl
Sine function
Interface
#include <math.h>
double | sin (double x) |
long | sinl (long double x) |
float | sinf (float x) |
#include <complex.h>
complex | sin (complex x) |
double complex | csin (double complex x) |
float complex | csinf (float complex x) |
long double complex | csinl (long double complex x) |
Description
The sin functions compute the sine of x (measured in radians). The complex sine is defined byExample:
Example - Sine function
Workings
#include <stdio.h> #include <math.h> int main(void) { double x = 0.31415926; double result = sin(x); printf("The sine of %lf is %lf\n", x, result); return 0; }
Solution
Output:
The sine of 0.314159 is 0.309017