# 4. Graphs of tan, cot, sec and csc

by M. Bourne

The graphs of `tan x`, `cot x`, `sec x` and `csc x` are not as common as the sine and cosine curves that we met earlier in this chapter. However, they do occur in engineering and science problems.

They are interesting curves because they have **discontinuities**. For certain values of *x*, the tangent, cotangent, secant and cosecant curves are not defined, and so there is a gap in the curve.

[For more on this topic, go to Continuous and Discontinuous Functions in an earlier chapter.]

Recall from Trigonometric Functions, that `tan x`* *is defined as:

`tan x=(text(sin)\ x)/(text(cos)\ x)`

For some values of *x*, the function `cos x`* *has value `0`. For example, when `x=pi/2`, the value of `cos {:π/2:}` is `0`, and when `x=(3pi)/2`, we have `cos{:(3π)/2:}=0`.

When this happens, we have `0` in the denominator of the fraction and this means the fraction is **undefined**. So there will be a "gap" in the function at that point. This gap is called a **discontinuity**.

The same thing happens with `cot x`, `sec x` and `csc x` for different values of `x`. For each one, the denominator will have value `0` for certain values of *x*.

## The Graph of *y* = tan *x*

Sketch *y* = tan *x*.

#### Solution

As we saw above,

`tan x=(sin x)/(cos x)`

This means the function will have a discontinuity where cos *x* = 0.
That is, when *x* takes any of the values:

`x = ..., -(5π)/2, -(3π)/2, -π/2, π/2, (3π)/2, (5π)/2, ...`

It is very important to keep these values in mind when sketching this graph.

When setting up a table of values, make sure you include `x`-values either side of the discontinuities.

Recall that `-(3pi)/2=-4.7124` and `-pi/2= 1.5708`. So we take values quite near these discontinuities.

`x` | -4.7 | -4.5 | -4 | -3.5 | -3.14 | -1.58 | -1.56 | -1 | 0 | 0.5 | 1 | 1.5 | 1.57 |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|

`tanx` | -80.7 | -4.6 | -1.2 | -0.37 | 0 | 108 | -92 | -1.6 | 0 | 0.55 | 1.6 | 14.1 | 1,256 |

Notice that either side of `-pi/2`, (our values of -1.58 and 01.56 in the table above), we jump from a large positive number (108), to a small negative number (-92).

If we continue our table, we will get similar values (because this is a periodic graph). So we are ready to sketch our curve.

Graph of *y *= tan *x*:

Note that there are vertical **asymptotes** (the gray dotted lines) where the denominator of `tan x`* *has value zero.

(An asymptote is a straight line that the curve gets closer and closer to, without actually touching it. You can see more examples of asymptotes in a later chapter, Curve Sketching Using Differentiation.)

Note also that the graph of `y = tan x` is **periodic** with period *π*. This means it repeats itself after each *π* as we go left to right on the graph.

### Interactive Tangent Curve

You can see an animation of the tangent function in this interactive.

You can change the amount of energy in the wave by changing the radius of the circle with the slider. The units on the horizontal axis are **radians** (in decimal form). Recall that:

π radians = 3.14 radians = 180°.

So the graph shown is from `0` to 2*π*. The vertical lines that appear are the asymptotes.

You can also drag the red dot (slowly) on the circle to generate the tan curve.

*t = θ = *0

*y =* 100 tan(0) *=* 0

Frame rate = 0 fps

Copyright © www.intmath.com

(For more on periodic functions and to see `y = tan x` using degrees, rather than radians, see Trigonometric Functions of Any Angle.)

## The Graph of *y* = cot *x*

*y*

*x*

Recall from Trigonometric Functions that:

`cot x=1/tanx = (cos x)/(sin x)`

We now have to consider when `sin x`* *has value zero, because this will determine where our asymptotes should go.

The function will have a discontinuity where `sin x = 0`, that is, when

` x = ..., -3π, -2π, -π, 0, π, 2π, 3π, 4π, 5π, ...`

Considering the values of cos *x* and sin *x* for different values of *x* (or more simply, finding the values of `1/tanx`), we can set up a table of values. We can then sketch the graph of `y = cot x` as follows.

### Interactive Cotangent curve

You can getter a better understanding of the cotangent curve using this interactive.

Run the animation and observe the features of the graph. Then change the radius of the circle (and run the animation again) to see the effect of different energy levels. The asymptotes are a key feature of this graph.

Note that the cotangent curve, like all trigonometric graphs, is **periodic**. The value of `t=theta` (the position of the green dot as it moves around the circle) doesn't seem to be related to the curve, but remember the cot curve involves a reciprocal ratio.

*t = θ = *0

*y =* 100 cot(0) *=* `oo`

Frame rate = 0 fps

Copyright © www.intmath.com

## The Graph of *y* = sec *x*

*y*

*x*

We could laboriously draw up a table with millions of values, or we could work smart and recall that

`sec x=1/(cos x)`

We know the sketch for *y* = cos *x* and we can easily derive the sketch for *y* = sec *x**,* by finding the reciprocal of each *y*-value. (That is, finding `1/y` for each value of *y* on the curve `y = cos x`.)

For example (angles are in radians):

`x` | 0 | 1 | 1.55 | 2 | 3 | 4 |
---|---|---|---|---|---|---|

`y = cos x` | 1 | 0.54 | 0.02 | -0.42 | -0.99 | -0.65 |

`sec x = 1/(cos x)` | 1 | 1.85 | 48.09 | -2.4 | -1.01 | -1.53 |

I included a value just less than `π/2=1.57` so that we could get an idea of what goes on there. When `cos x` is very small, `sec x`* *will be very large.

After applying this concept throughout the range of *x*-values, we can proceed to sketch the graph of `y = sec x`.

First, we graph `y = cos x` and then `y = sec x` immediately below it. Compare the *y*-values in each of the 2 graphs and assure yourself they are the reciprocal of each other.

*y* = cos *x*

*y* = sec *x*

We draw vertical asymptotes at the values where `y = sec x` is not defined. That is, when `x = ..., -(5π)/2, -(3π)/2, -π/2, π/2, (3π)/2, (5π)/2, ...`

You will notice that these are the same asymptotes that we drew for `y = tan x`, which is not surprising, because they both have `cos x` on the bottom of the fraction.

### Interactive Secant curve

As before, run the animation and observe the features of the graph. Then change the radius of the circle (and run the animation again) to see the effect of different energy levels.

You can see the graph of the cosine curve (in light color) as a guide.

*t = θ = *0

*y =* 100 sec(0) *=* 0

Frame rate = 0 fps

Copyright © www.intmath.com

### Exercise

### Need Graph Paper?

Sketch

y= cscx

Try to sketch it before checking your answer with this cosecant graph interactive.

You can see the graph of the sine curve (in light color) as a guide.

*t = θ = *0

*y =* 100 csc(0) *=* 0

Frame rate = 0 fps

Copyright © www.intmath.com

You may also be interested in:

- What are the frequencies of music notes?
- Graphs of y = a sin(bx+c) and y = acos(bx+c)
- Composite Trigonometric Curves
- Lissajous Figures

The next section in this chapter shows some Applications of Trigonometric Graphs.

### Search IntMath, blog and Forum

### Online Algebra Solver

This algebra solver can solve a wide range of math problems.

Go to: Online algebra solver

### Trigonometry Lessons on DVD

Easy to understand trigonometry lessons on DVD. See samples before you commit.

More info: Trigonometry videos

### The IntMath Newsletter

Sign up for the free **IntMath Newsletter**. Get math study tips, information, news and updates each fortnight. Join thousands of satisfied students, teachers and parents!