of sine, cosine and tangent of degree 7 (pink) for a full cycle centered on the origin.
G. H. Hardy noted in his 1908 work
A Course of Pure Mathematics that the definition of the trigonometric functions in terms of the unit circle is not satisfactory, because it depends implicitly on a notion of angle that can be measured by a real number. Thus in modern analysis, trigonometric functions are usually constructed without reference to geometry. Various ways exist in the literature for defining the trigonometric functions in a manner suitable for analysis; they include: • Using the "geometry" of the unit circle, which requires formulating the arc length of a circle (or area of a sector) analytically. • By using an infinite product expansion.
Definition by differential equations Sine and cosine can be defined as the unique solution to the
initial value problem: \frac{d}{dx}\sin x= \cos x,\ \frac{d}{dx}\cos x= -\sin x,\ \sin(0)=0,\ \cos(0)=1. Differentiating again, \frac{d^2}{dx^2}\sin x = \frac{d}{dx}\cos x = -\sin x and \frac{d^2}{dx^2}\cos x = -\frac{d}{dx}\sin x = -\cos x, so both sine and cosine are solutions of the same
ordinary differential equation y''+y=0\,. Sine is the unique solution with and ; cosine is the unique solution with and . One can then prove, as a theorem, that solutions \cos,\sin are periodic, having the same period. Writing this period as 2\pi is then a definition of the real number \pi which is independent of geometry. Applying the
quotient rule to the tangent \tan x = \sin x / \cos x, \frac{d}{dx}\tan x = \frac{\cos^2 x + \sin^2 x}{\cos^2 x} = 1+\tan^2 x\,, so the tangent function satisfies the ordinary differential equation y' = 1 + y^2\,. It is the unique solution with .
Power series expansion The basic trigonometric functions can be defined by the following
power series expansions. These series are also known as the
Taylor series or
Maclaurin series of these trigonometric functions: \begin{align} \sin x &= x - \frac{x^3}{3!} + \frac{x^5}{5!} - \frac{x^7}{7!} + \cdots &&= \sum_{n=0}^\infty (-1)^n \frac{x^{2n+1}}{(2n+1)!} \\ \cos x & = 1 - \frac{x^2}{2!} + \frac{x^4}{4!} - \frac{x^6}{6!} + \cdots &&= \sum_{n=0}^\infty (-1)^n \frac{x^{2n}}{(2n)!} \end{align} The
radius of convergence of these series is infinite. Therefore, the sine and the cosine can be extended to
entire functions (also called "sine" and "cosine"), which are (by definition)
complex-valued functions that are defined and
holomorphic on the whole
complex plane. Term-by-term differentiation shows that the sine and cosine defined by the series obey the differential equation discussed previously, and conversely one can obtain these series from elementary recursion relations derived from the differential equation. Being defined as fractions of entire functions, the other trigonometric functions may be extended to
meromorphic functions, that is functions that are holomorphic in the whole complex plane, except some isolated points called
poles. Here, the poles are the numbers of the form (2k+1)\frac \pi 2 for the tangent and the secant, or k\pi for the cotangent and the cosecant, where is an arbitrary integer. Recurrences relations may also be computed for the coefficients of the
Taylor series of the other trigonometric functions. These series have a finite
radius of convergence. Their coefficients have a
combinatorial interpretation: they enumerate
alternating permutations of finite sets. More precisely, defining : , the -th
up/down number, : , the -th
Bernoulli number, and : , is the -th
Euler number, one has the following series expansions: \begin{align} \tan x & {} = \sum_{n=0}^\infty \frac{U_{2n+1}}{(2n+1)!}x^{2n+1} \\[8mu] & {} = \sum_{n=1}^\infty \frac{(-1)^{n-1} 2^{2n} \left(2^{2n}-1\right) B_{2n}}{(2n)!}x^{2n-1} \\[5mu] & {} = x + \frac{1}{3}x^3 + \frac{2}{15}x^5 + \frac{17}{315}x^7 + \cdots, \qquad \text{for } |x| \begin{align} \csc x &= \sum_{n=0}^\infty \frac{(-1)^{n+1} 2 \left(2^{2n-1}-1\right) B_{2n}}{(2n)!}x^{2n-1} \\[5mu] &= x^{-1} + \frac{1}{6}x + \frac{7}{360}x^3 + \frac{31}{15120}x^5 + \cdots, \qquad \text{for } 0 \begin{align} \sec x &= \sum_{n=0}^\infty \frac{U_{2n}}{(2n)!}x^{2n} = \sum_{n=0}^\infty \frac{(-1)^n E_{2n}}{(2n)!}x^{2n} \\[5mu] &= 1 + \frac{1}{2}x^2 + \frac{5}{24}x^4 + \frac{61}{720}x^6 + \cdots, \qquad \text{for } |x| \begin{align} \cot x &= \sum_{n=0}^\infty \frac{(-1)^n 2^{2n} B_{2n}}{(2n)!}x^{2n-1} \\[5mu] &= x^{-1} - \frac{1}{3}x - \frac{1}{45}x^3 - \frac{2}{945}x^5 - \cdots, \qquad \text{for } 0
Continued fraction expansion The following
continued fractions are valid in the whole complex plane: \sin x = \cfrac{x}{1 + \cfrac{x^2}{2\cdot3-x^2 + \cfrac{2\cdot3 x^2}{4\cdot5-x^2 + \cfrac{4\cdot5 x^2}{6\cdot7-x^2 + \ddots}}}} \cos x = \cfrac{1}{1 + \cfrac{x^2}{1 \cdot 2 - x^2 + \cfrac{1 \cdot 2x^2}{3 \cdot 4 - x^2 + \cfrac{3 \cdot 4x^2}{5 \cdot 6 - x^2 + \ddots}}}} \tan x = \cfrac{x}{1 - \cfrac{x^2}{3 - \cfrac{x^2}{5 - \cfrac{x^2}{7 - \ddots}}}}=\cfrac{1}{\cfrac{1}{x} - \cfrac{1}{\cfrac{3}{x} - \cfrac{1}{\cfrac{5}{x} - \cfrac{1}{\cfrac{7}{x} - \ddots}}}} The last one was used in the historically first
proof that π is irrational. There is a rapidly convergent continued fraction for \tan(x): \tan x=1+\cfrac{5x^2}{T_{0}+5x^2}, T_{k}= (4k+1)(4k+3)(4k+5)-4x^2(4k+3)+ \cfrac{x^2(4k+1)}{1+ \cfrac{x^2(4k+9)}{T_{k+1}}} Let x=1 then the following continued fraction representation gives (asymptotically) 12.68 new correct decimal places per cycle: \tan 1=1+\cfrac{5}{T_{0}+5}, T_{k}= (4k+1)(4k+3)(4k+5)-4(4k+3)+ \cfrac{4k+1}{1+ \cfrac{4k+9}{T_{k+1}}}
Partial fraction expansion There is a series representation as
partial fraction expansion where just translated
reciprocal functions are summed up, such that the
poles of the cotangent function and the reciprocal functions match: \sin z = z \prod_{n=1}^\infty \left(1-\frac{z^2}{n^2 \pi^2}\right), \quad z\in\mathbb C. This may be obtained from the partial fraction decomposition of \cot z given above, which is the
logarithmic derivative of \sin z. From this, it can be deduced also that \cos z = \prod_{n=1}^\infty \left(1-\frac{z^2}{(n-1/2)^2 \pi^2}\right), \quad z\in\mathbb C.
Euler's formula and the exponential function Euler's formula relates sine and cosine to the
exponential function: e^{ix} = \cos x + i\sin x. This formula is commonly considered for real values of , but it remains true for all complex values.
Proof: Let f_1(x)=\cos x + i\sin x, and f_2(x)=e^{ix}. One has df_j(x)/dx= if_j(x) for . The
quotient rule implies thus that d/dx\, (f_1(x)/f_2(x))=0. Therefore, f_1(x)/f_2(x) is a constant function, which equals , as f_1(0)=f_2(0)=1. This proves the formula. One has \begin{align} e^{ix} &= \cos x + i\sin x\\[5pt] e^{-ix} &= \cos x - i\sin x. \end{align} Solving this
linear system in sine and cosine, one can express them in terms of the exponential function: \begin{align}\sin x &= \frac{e^{i x} - e^{-i x}}{2i}\\[5pt] \cos x &= \frac{e^{i x} + e^{-i x}}{2}. \end{align} When is real, this may be rewritten as \cos x = \operatorname{Re}\left(e^{i x}\right), \qquad \sin x = \operatorname{Im}\left(e^{i x}\right). Most
trigonometric identities can be proved by expressing trigonometric functions in terms of the complex exponential function by using above formulas, and then using the identity e^{a+b}=e^ae^b for simplifying the result. Euler's formula can also be used to define the basic trigonometric function directly, as follows, using the language of
topological groups. The set U of complex numbers of unit modulus is a compact and connected topological group, which has a neighborhood of the identity that is homeomorphic to the real line. Therefore, it is isomorphic as a topological group to the one-dimensional torus group \mathbb R/\mathbb Z, via an isomorphism e:\mathbb R/\mathbb Z\to U. In simple terms, e(t) = \exp(2\pi i t), and this isomorphism is unique up to taking complex conjugates. For a nonzero real number a (the
base), the function t\mapsto e(t/a) defines an isomorphism of the group \mathbb R/a\mathbb Z\to U. The real and imaginary parts of e(t/a) are the cosine and sine, where a is used as the base for measuring angles. For example, when a=2\pi, we get the measure in radians, and the usual trigonometric functions. When a=360, we get the sine and cosine of angles measured in degrees. Note that a=2\pi is the unique value at which the derivative \frac{d}{dt} e(t/a) becomes a
unit vector with positive imaginary part at t=0. This fact can, in turn, be used to define the constant 2\pi.
Definition via integration Another way to define the trigonometric functions in analysis is using integration. For a real number t, put \theta(t) = \int_0^t \frac{d\tau}{1+\tau^2}=\arctan t where this defines this inverse tangent function. Also, \pi is defined by \frac12\pi = \int_0^\infty \frac{d\tau}{1+\tau^2} a definition that goes back to
Karl Weierstrass. On the interval -\pi/2, the trigonometric functions are defined by inverting the relation \theta = \arctan t. Thus we define the trigonometric functions by \tan\theta = t,\quad \cos\theta = (1+t^2)^{-1/2},\quad \sin\theta = t(1+t^2)^{-1/2} where the point (t,\theta) is on the graph of \theta=\arctan t and the positive square root is taken. This defines the trigonometric functions on (-\pi/2,\pi/2). The definition can be extended to all real numbers by first observing that, as \theta\to\pi/2, t\to\infty, and so \cos\theta = (1+t^2)^{-1/2}\to 0 and \sin\theta = t(1+t^2)^{-1/2}\to 1. Thus \cos\theta and \sin\theta are extended continuously so that \cos(\pi/2)=0,\sin(\pi/2)=1. Now the conditions \cos(\theta+\pi)=-\cos(\theta) and \sin(\theta+\pi)=-\sin(\theta) define the sine and cosine as periodic functions with period 2\pi, for all real numbers. Proving the basic properties of sine and cosine, including the fact that sine and cosine are analytic, one may first establish the addition formulae. First, \arctan s + \arctan t = \arctan \frac{s+t}{1-st} holds, provided \arctan s+\arctan t\in(-\pi/2,\pi/2), since \arctan s + \arctan t= \int_{-s}^t\frac{d\tau}{1+\tau^2}=\int_0^{\frac{s+t}{1-st}}\frac{d\tau}{1+\tau^2} after the substitution \tau \to \frac{s+\tau}{1-s\tau}. In particular, the limiting case as s\to\infty gives \arctan t + \frac{\pi}{2} = \arctan(-1/t),\quad t\in (-\infty,0). Thus we have \sin\left(\theta + \frac{\pi}{2}\right) = \frac{-1}{t\sqrt{1+(-1/t)^2}} = \frac{-1}{\sqrt{1+t^2}} = -\cos(\theta) and \cos\left(\theta + \frac{\pi}{2}\right) = \frac{1}{\sqrt{1+(-1/t)^2}} = \frac{t}{\sqrt{1+t^2}} = \sin(\theta). So the sine and cosine functions are related by translation over a quarter period \pi/2.
Definitions using functional equations One can also define the trigonometric functions using various
functional equations. For example, the sine and the cosine form the unique pair of
continuous functions that satisfy the difference formula \cos(x- y) = \cos x\cos y + \sin x\sin y\, and the added condition 0
In the complex plane The sine and cosine of a
complex number z=x+iy can be expressed in terms of real sines, cosines, and
hyperbolic functions as follows: \begin{align}\sin z &= \sin x \cosh y + i \cos x \sinh y\\[5pt] \cos z &= \cos x \cosh y - i \sin x \sinh y\end{align} By taking advantage of
domain coloring, it is possible to graph the trigonometric functions as complex-valued functions. Various features unique to the complex functions can be seen from the graph; for example, the sine and cosine functions can be seen to be unbounded as the imaginary part of z becomes larger (since the color white represents infinity), and the fact that the functions contain simple
zeros or poles is apparent from the fact that the hue cycles around each zero or pole exactly once. Comparing these graphs with those of the corresponding Hyperbolic functions highlights the relationships between the two. == Periodicity and asymptotes ==