1tan(3M)                 Mathematical Library Functions                 tan(3M)
2
3
4

NAME

6       tan, tanf, tanl - tangent function
7

SYNOPSIS

9       c99 [ flag... ] file... -lm [ library... ]
10       #include <math.h>
11
12       double tan(double x);
13
14
15       float tanf(float x);
16
17
18       long double tanl(long double x);
19
20

DESCRIPTION

22       These  functions  compute  the tangent of their argument x, measured in
23       radians.
24

RETURN VALUES

26       Upon successful completion, these functions return the tangent of x.
27
28
29       If x is NaN, a NaN is returned.
30
31
32       If x is ±0, x is returned.
33
34
35       If x is ±Inf, a domain error occurs and a NaN is returned.
36

ERRORS

38       These functions will fail if:
39
40       Domain Error    The value of x is ±Inf.
41
42                       If   the   integer   expression   (math_errhandling   &
43                       MATH_ERREXCEPT) is non-zero, the invalid floating-point
44                       exception is raised.
45
46

USAGE

48       There are no known floating-point representations such that for a  nor‐
49       mal argument, tan(x) is either overflow or underflow.
50
51
52       An  application  wanting to check for exceptions should call feclearex‐
53       cept(FE_ALL_EXCEPT) before  calling  these  functions.  On  return,  if
54       fetestexcept(FE_INVALID | FE_DIVBYZERO | FE_OVERFLOW | FE_UNDERFLOW) is
55       non-zero, an exception has been raised. An  application  should  either
56       examine the return value or check the floating point exception flags to
57       detect exceptions.
58

ATTRIBUTES

60       See attributes(5) for descriptions of the following attributes:
61
62
63
64
65       ┌─────────────────────────────┬─────────────────────────────┐
66       │      ATTRIBUTE TYPE         │      ATTRIBUTE VALUE        │
67       ├─────────────────────────────┼─────────────────────────────┤
68       │Interface Stability          │Standard                     │
69       ├─────────────────────────────┼─────────────────────────────┤
70       │MT-Level                     │MT-Safe                      │
71       └─────────────────────────────┴─────────────────────────────┘
72

SEE ALSO

74       atan(3M),     feclearexcept(3M),      fetestexcept(3M),      isnan(3M),
75       math.h(3HEAD), attributes(5), standards(5)
76
77
78
79SunOS 5.11                        12 Jul 2006                          tan(3M)
Impressum