Unit 6, lesson 49

The Cotangent Function

How cotangent is built as cosine over sine, where it is undefined and where it is zero, and how its period, asymptotes and decreasing branches fit together.

  • Theory part 97
  • Practice part 98
  • The Six Trigonometric Functions

Tangent compares height to horizontal position on the unit circle. Cotangent turns that comparison around and asks how far across you are for each unit of height. It is easy to treat cotangent as nothing more than one over tangent, but that shortcut gets the domain wrong at exactly the inputs where calculus later needs care, so here cotangent is built on its own from cosine and sine.

Key terms

Cotangent as a cosine-to-sine ratio

Definition For a real number xx, measured in radians, with sin⁡x≠0\sin x \ne 0, the cotangent of xx is

cot⁡x=cos⁡xsin⁡x.\cot x = \frac{\cos x}{\sin x}.

On the unit circle the angle xx gives the point (cos⁡x,sin⁡x)(\cos x, \sin x), so cotangent is the horizontal coordinate divided by the vertical coordinate of that point. The only condition is that the denominator sin⁡x\sin x is not zero. Nothing about cos⁡x\cos x needs to be checked.

In plain words Take the point on the unit circle for your angle and divide its first coordinate by its second. Cotangent exists whenever that point is off the horizontal axis.

Example At x=π3x = \frac{\pi}{3} the point is (12,32)\left(\frac{1}{2}, \frac{\sqrt{3}}{2}\right), so

cot⁡π3=1/23/2=13=33.\cot \frac{\pi}{3} = \frac{1/2}{\sqrt{3}/2} = \frac{1}{\sqrt{3}} = \frac{\sqrt{3}}{3}.

At x=π2x = \frac{\pi}{2} the point is (0,1)(0, 1), and the ratio is 01=0\frac{0}{1} = 0. Tangent is undefined at this angle, yet cotangent has the perfectly good value 00.

Undefined inputs

Definition Cotangent is undefined exactly when sin⁡x=0\sin x = 0, which happens exactly at the integer multiples of π\pi. Its domain is

{ x∈R∣x≠kπ for every integer k }.\begin{gathered} \{\, x \in \mathbb{R} \mid x \ne k\pi \\[0.4em] \text{ for every integer } k \,\}. \end{gathered}

This domain comes straight from the denominator of cos⁡xsin⁡x\frac{\cos x}{\sin x}. It is not the same as the domain of tangent, which excludes π2+kπ\frac{\pi}{2} + k\pi instead.

In plain words Cotangent breaks down where the unit circle point sits on the horizontal axis, at 00, π\pi, 2π2\pi, −π-\pi and so on.

Example At x=πx = \pi the point is (−1,0)(-1, 0). The numerator is −1-1 and the denominator is 00, so cot⁡π\cot \pi is undefined. At x=−π2x = -\frac{\pi}{2} the point is (0,−1)(0, -1), and the ratio is 0−1=0\frac{0}{-1} = 0, so −π2-\frac{\pi}{2} is in the domain even though it is an excluded input for tangent.

Zeros

Definition A zero of cotangent is a number xx in its domain with cot⁡x=0\cot x = 0. A fraction is zero exactly when its numerator is zero and its denominator is not, so cot⁡x=0\cot x = 0 exactly when cos⁡x=0\cos x = 0 and sin⁡x≠0\sin x \ne 0. Since cos⁡x=0\cos x = 0 forces sin⁡x=±1\sin x = \pm 1, the zeros are

x=π2+kπ,k an integer.x = \frac{\pi}{2} + k\pi, \qquad k \text{ an integer}.

In plain words Cotangent is zero where the unit circle point sits on the vertical axis. Those are precisely the places where tangent is undefined.

Example At x=3π2x = \frac{3\pi}{2} the point is (0,−1)(0, -1), so

cot⁡3π2=0−1=0.\cot \frac{3\pi}{2} = \frac{0}{-1} = 0.

At x=π4x = \frac{\pi}{4} the point is (22,22)\left(\frac{\sqrt{2}}{2}, \frac{\sqrt{2}}{2}\right) and the cotangent is 11, not a zero.

Period and odd symmetry

Definition For every xx in the domain, x+πx + \pi is also in the domain and

cot⁡(x+π)=−cos⁡x−sin⁡x=cot⁡x,\cot(x + \pi) = \frac{-\cos x}{-\sin x} = \cot x,

because adding π\pi moves the unit circle point to the opposite point. So π\pi is a period. It is the least positive period. Suppose some pp with 0<p<π0 < p < \pi were a period. Since π2\frac{\pi}{2} is in the domain, so is π2+p\frac{\pi}{2} + p, and cot⁡(π2+p)=cot⁡π2=0\cot\left(\frac{\pi}{2} + p\right) = \cot \frac{\pi}{2} = 0. That would make π2+p\frac{\pi}{2} + p a zero of cotangent strictly between π2\frac{\pi}{2} and 3π2\frac{3\pi}{2}, but the zeros are spaced exactly π\pi apart and none lies there. Cotangent is also odd. For xx in the domain, −x-x is in the domain too, and since cosine is even and sine is odd,

cot⁡(−x)=cos⁡(−x)sin⁡(−x)=cos⁡x−sin⁡x=−cot⁡x.\begin{aligned} \cot(-x) &= \frac{\cos(-x)}{\sin(-x)} \\[0.4em] &= \frac{\cos x}{-\sin x} = -\cot x. \end{aligned}

In plain words The pattern of cotangent repeats every π\pi, which is half a turn and half the period of sine and cosine. Its graph is symmetric about the origin.

Example Since 4π3=π3+π\frac{4\pi}{3} = \frac{\pi}{3} + \pi, the period gives cot⁡4π3=cot⁡π3=33\cot \frac{4\pi}{3} = \cot \frac{\pi}{3} = \frac{\sqrt{3}}{3}. Directly, the point for 4π3\frac{4\pi}{3} is (−12,−32)\left(-\frac{1}{2}, -\frac{\sqrt{3}}{2}\right), and the two minus signs cancel. Oddness gives cot⁡(−π4)=−cot⁡π4=−1\cot\left(-\frac{\pi}{4}\right) = -\cot \frac{\pi}{4} = -1.

Vertical asymptotes

Definition The line x=ax = a is a vertical asymptote of the graph of ff if f(x)f(x) grows without bound, toward ∞\infty or −∞-\infty, as xx approaches aa from at least one side. The graph of cotangent has a vertical asymptote at every excluded input x=kπx = k\pi. Near x=kπx = k\pi the numerator cos⁡x\cos x is close to ±1\pm 1 while the denominator sin⁡x\sin x is close to 00, so the quotient is huge in size. Just to the right of each kπk\pi the values go to ∞\infty, and just to the left they go to −∞-\infty.

In plain words At every multiple of π\pi the graph shoots off to infinity, up on the right side of the gap and down on the left side.

Example Near x=0x = 0 the values behave like this.

xxcot⁡x\cot x
0.10.1about 9.9679.967
0.010.01about 99.99799.997
−0.01-0.01about −99.997-99.997
−0.1-0.1about −9.967-9.967

The same thing happens at a shifted copy. For y=cot⁡(x−π4)y = \cot\left(x - \frac{\pi}{4}\right) the inner angle x−π4x - \frac{\pi}{4} must avoid multiples of π\pi, so the asymptotes are at

x=π4+kπ,k an integer.x = \frac{\pi}{4} + k\pi, \qquad k \text{ an integer}.

The cotangent graph

Definition The graph of y=cot⁡xy = \cot x consists of separate branches, one on each open interval (kπ,(k+1)π)(k\pi, (k+1)\pi) with kk an integer. On each branch cotangent is continuous and decreasing. On (0,π)(0, \pi) this follows from what sine and cosine do there.

  • On (0,π2]\left(0, \frac{\pi}{2}\right] the numerator cos⁡x\cos x decreases and stays ≥0\ge 0, while the denominator sin⁡x\sin x increases and stays positive. A smaller top over a larger bottom gives a smaller quotient, so cot⁡x\cot x decreases.
  • On [π2,π)\left[\frac{\pi}{2}, \pi\right) write cot⁡x=−∣cos⁡x∣sin⁡x\cot x = -\frac{\lvert \cos x \rvert}{\sin x}. Here ∣cos⁡x∣\lvert \cos x \rvert increases from 00 while sin⁡x\sin x decreases and stays positive, so the fraction grows and its negative decreases.

The two pieces share the input π2\frac{\pi}{2}, so cotangent decreases on all of (0,π)(0, \pi). Every other branch repeats this one, because cot⁡(x+kπ)=cot⁡x\cot(x + k\pi) = \cot x. Each branch falls from ∞\infty near its left endpoint to −∞-\infty near its right endpoint, crosses the axis once at its midpoint π2+kπ\frac{\pi}{2} + k\pi, and takes every real value exactly once. The range of cotangent is all of R\mathbb{R}.

In plain words Between neighboring asymptotes the graph comes down from the top, passes through zero halfway across, and drops away to the bottom. Every branch is a copy of the one on (0,π)(0, \pi).

Example On the branch (0,π)(0, \pi) these exact values sketch the curve.

xxπ6\frac{\pi}{6}π4\frac{\pi}{4}π2\frac{\pi}{2}3π4\frac{3\pi}{4}5π6\frac{5\pi}{6}
cot⁡x\cot x3\sqrt{3}1100−1-1−3-\sqrt{3}

To place the branch of y=cot⁡(x−π4)y = \cot\left(x - \frac{\pi}{4}\right) that matches it, require the inner angle to lie in (0,π)(0, \pi).

0<x−π4<πgivesπ4<x<5π4.\begin{gathered} 0 < x - \frac{\pi}{4} < \pi \\[0.4em] \text{gives} \quad \frac{\pi}{4} < x < \frac{5\pi}{4}. \end{gathered}

That branch has its zero where the inner angle is π2\frac{\pi}{2}, at x=3π4x = \frac{3\pi}{4}.

The reciprocal identity

Definition For every real xx with sin⁡x≠0\sin x \ne 0 and cos⁡x≠0\cos x \ne 0, that is, x≠kπ2x \ne \frac{k\pi}{2} for every integer kk,

cot⁡x=1tan⁡x.\cot x = \frac{1}{\tan x}.

Both sides are defined together only on this set. At x=π2+kπx = \frac{\pi}{2} + k\pi the left side is 00 while the right side is undefined, because tan⁡x\tan x itself does not exist there. So the identity is a statement about the common domain, not a definition of cotangent.

In plain words Away from multiples of π2\frac{\pi}{2} you may flip tangent to get cotangent. At the zeros of cotangent the flip fails, so do not use it there.

Example At x=π6x = \frac{\pi}{6}, tangent is 13\frac{1}{\sqrt{3}}, and its reciprocal is 3\sqrt{3}, which matches the table value cot⁡π6=3\cot \frac{\pi}{6} = \sqrt{3}. At x=π2x = \frac{\pi}{2} the ratio definition gives cot⁡π2=0\cot \frac{\pi}{2} = 0, while 1tan⁡(π/2)\frac{1}{\tan(\pi/2)} has no meaning.

Check yourself

  1. Find the exact values of cot⁡5π6\cot \frac{5\pi}{6} and cot⁡(−π2)\cot\left(-\frac{\pi}{2}\right), or say that a value is undefined.
Show the answer

The point for 5π6\frac{5\pi}{6} is (−32,12)\left(-\frac{\sqrt{3}}{2}, \frac{1}{2}\right), so

cot⁡5π6=−3/21/2=−3.\cot \frac{5\pi}{6} = \frac{-\sqrt{3}/2}{1/2} = -\sqrt{3}.

The point for −π2-\frac{\pi}{2} is (0,−1)(0, -1), so the cotangent is 0−1=0\frac{0}{-1} = 0. It is defined even though tangent is not.

  1. Consider y=cot⁡(x+π3)y = \cot\left(x + \frac{\pi}{3}\right). Find the open interval of the branch that contains x=0x = 0, its two asymptotes and its zero.
Show the answer

At x=0x = 0 the inner angle is π3\frac{\pi}{3}, which lies in (0,π)(0, \pi). So the branch is where

0<x+π3<π,that is,−π3<x<2π3.\begin{gathered} 0 < x + \frac{\pi}{3} < \pi, \\[0.4em] \text{that is,} \quad -\frac{\pi}{3} < x < \frac{2\pi}{3}. \end{gathered}

The asymptotes are x=−π3x = -\frac{\pi}{3} and x=2π3x = \frac{2\pi}{3}. The zero is where the inner angle equals π2\frac{\pi}{2}, at x=π6x = \frac{\pi}{6}.

  1. Is the equation cot⁡x=1tan⁡x\cot x = \frac{1}{\tan x} true at x=3π2x = \frac{3\pi}{2}?
Show the answer

No. The left side is 0−1=0\frac{0}{-1} = 0, but tan⁡3π2\tan \frac{3\pi}{2} is undefined because cos⁡3π2=0\cos \frac{3\pi}{2} = 0. The right side has no value, so the reciprocal identity does not apply at this input.

How this lesson connects